From 53d3e1338068d3dc896984b7265f97f2e18f488b Mon Sep 17 00:00:00 2001 From: fern-api <115122769+fern-api[bot]@users.noreply.github.com> Date: Sat, 18 Jan 2025 17:49:23 +0000 Subject: [PATCH] Release 0.1.10 --- package.json | 2 +- reference.md | 26 ++++--- src/api/resources/agents/client/Client.ts | 36 +++++----- .../client/requests/AgentsListRequest.ts | 6 +- .../client/requests/CreateAgentRequest.ts | 4 +- .../resources/archivalMemory/client/Client.ts | 16 ++--- .../agents/resources/context/client/Client.ts | 4 +- .../resources/coreMemory/client/Client.ts | 28 ++++---- .../memoryVariables/client/Client.ts | 4 +- .../resources/messages/client/Client.ts | 32 ++++----- .../client/requests/LettaStreamingRequest.ts | 8 +-- .../messages/types/MessagesListResponse.ts | 2 +- .../types/MessagesListResponseItem.ts | 39 ----------- .../agents/resources/messages/types/index.ts | 1 - .../resources/recallMemory/client/Client.ts | 4 +- .../agents/resources/sources/client/Client.ts | 4 +- .../resources/templates/client/Client.ts | 12 ++-- .../agents/resources/tools/client/Client.ts | 12 ++-- .../types/AgentsSearchRequestSearchItem.ts | 5 ++ .../AgentsSearchRequestSearchItemTags.ts | 8 +++ src/api/resources/agents/types/index.ts | 1 + src/api/resources/blocks/client/Client.ts | 28 ++++---- src/api/resources/health/client/Client.ts | 4 +- src/api/resources/jobs/client/Client.ts | 16 ++--- src/api/resources/models/client/Client.ts | 8 +-- src/api/resources/providers/client/Client.ts | 16 ++--- src/api/resources/runs/client/Client.ts | 68 ++++++------------- .../client/requests/GetRunMessagesRequest.ts | 26 +------ src/api/resources/sources/client/Client.ts | 32 ++++----- .../sources/resources/files/client/Client.ts | 12 ++-- .../resources/passages/client/Client.ts | 4 +- src/api/resources/tag/client/Client.ts | 4 +- src/api/resources/tools/client/Client.ts | 48 ++++++------- .../EmbeddingConfigEmbeddingEndpointType.ts | 2 + ...seMessagesItem.ts => LettaMessageUnion.ts} | 18 ++--- src/api/types/LettaRequest.ts | 8 +-- src/api/types/LettaRequestConfig.ts | 12 ++++ src/api/types/LettaResponse.ts | 2 +- src/api/types/LlmConfigModelEndpointType.ts | 4 +- src/api/types/Run.ts | 2 + src/api/types/ToolType.ts | 3 +- src/api/types/index.ts | 3 +- .../client/requests/CreateAgentRequest.ts | 5 ++ .../client/requests/LettaStreamingRequest.ts | 15 +--- .../messages/types/MessagesListResponse.ts | 6 +- .../types/MessagesListResponseItem.ts | 64 ----------------- .../agents/resources/messages/types/index.ts | 1 - .../types/AgentsSearchRequestSearchItem.ts | 7 ++ .../AgentsSearchRequestSearchItemTags.ts | 22 ++++++ .../resources/agents/types/index.ts | 1 + .../resources/runs/client/getRunMessages.ts | 8 +-- .../EmbeddingConfigEmbeddingEndpointType.ts | 2 + ...seMessagesItem.ts => LettaMessageUnion.ts} | 46 ++++++------- src/serialization/types/LettaRequest.ts | 18 +---- src/serialization/types/LettaRequestConfig.ts | 30 ++++++++ src/serialization/types/LettaResponse.ts | 6 +- .../types/LlmConfigModelEndpointType.ts | 4 +- src/serialization/types/Run.ts | 3 + src/serialization/types/ToolType.ts | 3 +- src/serialization/types/index.ts | 3 +- src/version.ts | 2 +- yarn.lock | 24 +++---- 62 files changed, 385 insertions(+), 459 deletions(-) delete mode 100644 src/api/resources/agents/resources/messages/types/MessagesListResponseItem.ts create mode 100644 src/api/resources/agents/types/AgentsSearchRequestSearchItemTags.ts rename src/api/types/{LettaResponseMessagesItem.ts => LettaMessageUnion.ts} (66%) create mode 100644 src/api/types/LettaRequestConfig.ts delete mode 100644 src/serialization/resources/agents/resources/messages/types/MessagesListResponseItem.ts create mode 100644 src/serialization/resources/agents/types/AgentsSearchRequestSearchItemTags.ts rename src/serialization/types/{LettaResponseMessagesItem.ts => LettaMessageUnion.ts} (55%) create mode 100644 src/serialization/types/LettaRequestConfig.ts diff --git a/package.json b/package.json index 2a3db9e..702ed96 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@letta-ai/letta-client", - "version": "0.1.9", + "version": "0.1.10", "private": false, "repository": "https://github.com/letta-ai/letta-node", "main": "./index.js", diff --git a/reference.md b/reference.md index 03fd513..18da6bc 100644 --- a/reference.md +++ b/reference.md @@ -3018,7 +3018,7 @@ await client.runs.deleteRun("run_id"); -
client.runs.getRunMessages(runId, { ...params }) -> Letta.LettaSchemasMessageMessage[] +
client.runs.getRunMessages(runId, { ...params }) -> Letta.LettaMessageUnion[]
@@ -3035,17 +3035,15 @@ Get messages associated with a run with filtering options. Args: run_id: ID of the run cursor: Cursor for pagination -start_date: Filter messages after this date -end_date: Filter messages before this date limit: Maximum number of messages to return -query_text: Search text in message content ascending: Sort order by creation time -tags: Filter by message tags -match_all_tags: If true, match all tags. If false, match any tag -role: Filter by message role (user/assistant/system/tool) -tool_name: Filter by tool call name +role: Filter by role (user/assistant/system/tool) +return_message_object: Whether to return Message objects or LettaMessage objects user_id: ID of the user making the request +Returns: +A list of messages associated with the run. Default is List[LettaMessage]. +
@@ -4473,7 +4471,7 @@ await client.agents.messages.list("agent_id");
-
client.agents.messages.create(agentId, { ...params }) -> Letta.LettaResponse +
client.agents.messages.send(agentId, { ...params }) -> Letta.LettaResponse
@@ -4502,7 +4500,7 @@ This endpoint accepts a message from a user and processes it through the agent.
```typescript -await client.agents.messages.create("agent_id", { +await client.agents.messages.send("agent_id", { messages: [ { role: "user", @@ -4714,7 +4712,7 @@ for await (const item of response) {
-
client.agents.messages.createAsync(agentId, { ...params }) -> Letta.Run +
client.agents.messages.sendAsync(agentId, { ...params }) -> Letta.Run
@@ -4726,8 +4724,8 @@ for await (const item of response) {
-Asynchronously process a user message and return a job ID. -The actual processing happens in the background, and the status can be checked using the job ID. +Asynchronously process a user message and return a run object. +The actual processing happens in the background, and the status can be checked using the run ID.
@@ -4743,7 +4741,7 @@ The actual processing happens in the background, and the status can be checked u
```typescript -await client.agents.messages.createAsync("agent_id", { +await client.agents.messages.sendAsync("agent_id", { messages: [ { role: "user", diff --git a/src/api/resources/agents/client/Client.ts b/src/api/resources/agents/client/Client.ts index 766fd92..245714a 100644 --- a/src/api/resources/agents/client/Client.ts +++ b/src/api/resources/agents/client/Client.ts @@ -104,7 +104,7 @@ export class Agents { request: Letta.AgentsListRequest = {}, requestOptions?: Agents.RequestOptions, ): Promise { - const { name, tags, matchAllTags, cursor, limit } = request; + const { name, tags, matchAllTags, cursor, limit, queryText } = request; const _queryParams: Record = {}; if (name != null) { _queryParams["name"] = name; @@ -123,13 +123,17 @@ export class Agents { } if (cursor != null) { - _queryParams["cursor"] = cursor.toString(); + _queryParams["cursor"] = cursor; } if (limit != null) { _queryParams["limit"] = limit.toString(); } + if (queryText != null) { + _queryParams["query_text"] = queryText; + } + const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( (await core.Supplier.get(this._options.baseUrl)) ?? @@ -141,8 +145,8 @@ export class Agents { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -226,8 +230,8 @@ export class Agents { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -308,8 +312,8 @@ export class Agents { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -389,8 +393,8 @@ export class Agents { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -469,8 +473,8 @@ export class Agents { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -562,8 +566,8 @@ export class Agents { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -649,8 +653,8 @@ export class Agents { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), diff --git a/src/api/resources/agents/client/requests/AgentsListRequest.ts b/src/api/resources/agents/client/requests/AgentsListRequest.ts index df17ac9..c734ada 100644 --- a/src/api/resources/agents/client/requests/AgentsListRequest.ts +++ b/src/api/resources/agents/client/requests/AgentsListRequest.ts @@ -22,9 +22,13 @@ export interface AgentsListRequest { /** * Cursor for pagination */ - cursor?: number; + cursor?: string; /** * Limit for pagination */ limit?: number; + /** + * Search agents by name + */ + queryText?: string; } diff --git a/src/api/resources/agents/client/requests/CreateAgentRequest.ts b/src/api/resources/agents/client/requests/CreateAgentRequest.ts index d86e1d9..8843942 100644 --- a/src/api/resources/agents/client/requests/CreateAgentRequest.ts +++ b/src/api/resources/agents/client/requests/CreateAgentRequest.ts @@ -35,8 +35,10 @@ export interface CreateAgentRequest { embeddingConfig?: Letta.EmbeddingConfig; /** The initial set of messages to put in the agent's in-context memory. */ initialMessageSequence?: Letta.MessageCreate[]; - /** The LLM configuration used by the agent. */ + /** If true, attaches the Letta core tools (e.g. archival_memory and core_memory related functions). */ includeBaseTools?: boolean; + /** If true, attaches the Letta multi-agent tools (e.g. sending a message to another agent). */ + includeMultiAgentTools?: boolean; /** The description of the agent. */ description?: string; /** The metadata of the agent. */ diff --git a/src/api/resources/agents/resources/archivalMemory/client/Client.ts b/src/api/resources/agents/resources/archivalMemory/client/Client.ts index 417352a..449b11d 100644 --- a/src/api/resources/agents/resources/archivalMemory/client/Client.ts +++ b/src/api/resources/agents/resources/archivalMemory/client/Client.ts @@ -59,8 +59,8 @@ export class ArchivalMemory { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -161,8 +161,8 @@ export class ArchivalMemory { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -250,8 +250,8 @@ export class ArchivalMemory { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -339,8 +339,8 @@ export class ArchivalMemory { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), diff --git a/src/api/resources/agents/resources/context/client/Client.ts b/src/api/resources/agents/resources/context/client/Client.ts index 7c9c5f9..df65ab3 100644 --- a/src/api/resources/agents/resources/context/client/Client.ts +++ b/src/api/resources/agents/resources/context/client/Client.ts @@ -56,8 +56,8 @@ export class Context { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), diff --git a/src/api/resources/agents/resources/coreMemory/client/Client.ts b/src/api/resources/agents/resources/coreMemory/client/Client.ts index f706ee1..185a958 100644 --- a/src/api/resources/agents/resources/coreMemory/client/Client.ts +++ b/src/api/resources/agents/resources/coreMemory/client/Client.ts @@ -59,8 +59,8 @@ export class CoreMemory { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -143,8 +143,8 @@ export class CoreMemory { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -229,8 +229,8 @@ export class CoreMemory { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -317,8 +317,8 @@ export class CoreMemory { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -407,8 +407,8 @@ export class CoreMemory { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -491,8 +491,8 @@ export class CoreMemory { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -582,8 +582,8 @@ export class CoreMemory { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), diff --git a/src/api/resources/agents/resources/memoryVariables/client/Client.ts b/src/api/resources/agents/resources/memoryVariables/client/Client.ts index 06a57ec..eacfd52 100644 --- a/src/api/resources/agents/resources/memoryVariables/client/Client.ts +++ b/src/api/resources/agents/resources/memoryVariables/client/Client.ts @@ -61,8 +61,8 @@ export class MemoryVariables { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), diff --git a/src/api/resources/agents/resources/messages/client/Client.ts b/src/api/resources/agents/resources/messages/client/Client.ts index c577e76..323ba13 100644 --- a/src/api/resources/agents/resources/messages/client/Client.ts +++ b/src/api/resources/agents/resources/messages/client/Client.ts @@ -84,8 +84,8 @@ export class Messages { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -154,14 +154,14 @@ export class Messages { * @throws {@link Letta.UnprocessableEntityError} * * @example - * await client.agents.messages.create("agent_id", { + * await client.agents.messages.send("agent_id", { * messages: [{ * role: "user", * text: "text" * }] * }) */ - public async create( + public async send( agentId: string, request: Letta.LettaRequest, requestOptions?: Messages.RequestOptions, @@ -177,8 +177,8 @@ export class Messages { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -268,8 +268,8 @@ export class Messages { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -350,8 +350,8 @@ export class Messages { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -423,8 +423,8 @@ export class Messages { } /** - * Asynchronously process a user message and return a job ID. - * The actual processing happens in the background, and the status can be checked using the job ID. + * Asynchronously process a user message and return a run object. + * The actual processing happens in the background, and the status can be checked using the run ID. * * @param {string} agentId * @param {Letta.LettaRequest} request @@ -433,14 +433,14 @@ export class Messages { * @throws {@link Letta.UnprocessableEntityError} * * @example - * await client.agents.messages.createAsync("agent_id", { + * await client.agents.messages.sendAsync("agent_id", { * messages: [{ * role: "user", * text: "text" * }] * }) */ - public async createAsync( + public async sendAsync( agentId: string, request: Letta.LettaRequest, requestOptions?: Messages.RequestOptions, @@ -456,8 +456,8 @@ export class Messages { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), diff --git a/src/api/resources/agents/resources/messages/client/requests/LettaStreamingRequest.ts b/src/api/resources/agents/resources/messages/client/requests/LettaStreamingRequest.ts index 34d7b71..52cb371 100644 --- a/src/api/resources/agents/resources/messages/client/requests/LettaStreamingRequest.ts +++ b/src/api/resources/agents/resources/messages/client/requests/LettaStreamingRequest.ts @@ -16,12 +16,8 @@ import * as Letta from "../../../../../../index"; export interface LettaStreamingRequest { /** The messages to be sent to the agent. */ messages: Letta.MessageCreate[]; - /** Whether the server should parse specific tool call arguments (default `send_message`) as `AssistantMessage` objects. */ - useAssistantMessage?: boolean; - /** The name of the designated message tool. */ - assistantMessageToolName?: string; - /** The name of the message argument in the designated message tool. */ - assistantMessageToolKwarg?: string; + /** Configuration options for the LettaRequest. */ + config?: Letta.LettaRequestConfig; /** Flag to determine if individual tokens should be streamed. Set to True for token streaming (requires stream_steps = True). */ streamTokens?: boolean; } diff --git a/src/api/resources/agents/resources/messages/types/MessagesListResponse.ts b/src/api/resources/agents/resources/messages/types/MessagesListResponse.ts index 811d5ed..66bf2df 100644 --- a/src/api/resources/agents/resources/messages/types/MessagesListResponse.ts +++ b/src/api/resources/agents/resources/messages/types/MessagesListResponse.ts @@ -4,4 +4,4 @@ import * as Letta from "../../../../../index"; -export type MessagesListResponse = Letta.LettaSchemasMessageMessage[] | Letta.agents.MessagesListResponseItem[]; +export type MessagesListResponse = Letta.LettaSchemasMessageMessage[] | Letta.LettaMessageUnion[]; diff --git a/src/api/resources/agents/resources/messages/types/MessagesListResponseItem.ts b/src/api/resources/agents/resources/messages/types/MessagesListResponseItem.ts deleted file mode 100644 index 9c24b5d..0000000 --- a/src/api/resources/agents/resources/messages/types/MessagesListResponseItem.ts +++ /dev/null @@ -1,39 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Letta from "../../../../../index"; - -export type MessagesListResponseItem = - | Letta.agents.MessagesListResponseItem.SystemMessage - | Letta.agents.MessagesListResponseItem.UserMessage - | Letta.agents.MessagesListResponseItem.ReasoningMessage - | Letta.agents.MessagesListResponseItem.ToolCallMessage - | Letta.agents.MessagesListResponseItem.ToolReturnMessage - | Letta.agents.MessagesListResponseItem.AssistantMessage; - -export namespace MessagesListResponseItem { - export interface SystemMessage extends Letta.SystemMessageOutput { - messageType: "system_message"; - } - - export interface UserMessage extends Letta.UserMessageOutput { - messageType: "user_message"; - } - - export interface ReasoningMessage extends Letta.ReasoningMessage { - messageType: "reasoning_message"; - } - - export interface ToolCallMessage extends Letta.ToolCallMessage { - messageType: "tool_call_message"; - } - - export interface ToolReturnMessage extends Letta.ToolReturnMessage { - messageType: "tool_return_message"; - } - - export interface AssistantMessage extends Letta.AssistantMessageOutput { - messageType: "assistant_message"; - } -} diff --git a/src/api/resources/agents/resources/messages/types/index.ts b/src/api/resources/agents/resources/messages/types/index.ts index 8472685..70efe3d 100644 --- a/src/api/resources/agents/resources/messages/types/index.ts +++ b/src/api/resources/agents/resources/messages/types/index.ts @@ -1,3 +1,2 @@ -export * from "./MessagesListResponseItem"; export * from "./MessagesListResponse"; export * from "./LettaStreamingResponse"; diff --git a/src/api/resources/agents/resources/recallMemory/client/Client.ts b/src/api/resources/agents/resources/recallMemory/client/Client.ts index 7bdce23..f28639d 100644 --- a/src/api/resources/agents/resources/recallMemory/client/Client.ts +++ b/src/api/resources/agents/resources/recallMemory/client/Client.ts @@ -59,8 +59,8 @@ export class RecallMemory { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), diff --git a/src/api/resources/agents/resources/sources/client/Client.ts b/src/api/resources/agents/resources/sources/client/Client.ts index b810f46..c359f86 100644 --- a/src/api/resources/agents/resources/sources/client/Client.ts +++ b/src/api/resources/agents/resources/sources/client/Client.ts @@ -56,8 +56,8 @@ export class Sources { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), diff --git a/src/api/resources/agents/resources/templates/client/Client.ts b/src/api/resources/agents/resources/templates/client/Client.ts index c29309c..ed8bb09 100644 --- a/src/api/resources/agents/resources/templates/client/Client.ts +++ b/src/api/resources/agents/resources/templates/client/Client.ts @@ -70,8 +70,8 @@ export class Templates { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -157,8 +157,8 @@ export class Templates { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -251,8 +251,8 @@ export class Templates { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), diff --git a/src/api/resources/agents/resources/tools/client/Client.ts b/src/api/resources/agents/resources/tools/client/Client.ts index a87c12d..dc28b15 100644 --- a/src/api/resources/agents/resources/tools/client/Client.ts +++ b/src/api/resources/agents/resources/tools/client/Client.ts @@ -56,8 +56,8 @@ export class Tools { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -142,8 +142,8 @@ export class Tools { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -230,8 +230,8 @@ export class Tools { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), diff --git a/src/api/resources/agents/types/AgentsSearchRequestSearchItem.ts b/src/api/resources/agents/types/AgentsSearchRequestSearchItem.ts index 101f69b..8a9b7de 100644 --- a/src/api/resources/agents/types/AgentsSearchRequestSearchItem.ts +++ b/src/api/resources/agents/types/AgentsSearchRequestSearchItem.ts @@ -7,6 +7,7 @@ import * as Letta from "../../../index"; export type AgentsSearchRequestSearchItem = | Letta.AgentsSearchRequestSearchItem.Version | Letta.AgentsSearchRequestSearchItem.Name + | Letta.AgentsSearchRequestSearchItem.Tags | Letta.AgentsSearchRequestSearchItem.OrderBy; export namespace AgentsSearchRequestSearchItem { @@ -18,6 +19,10 @@ export namespace AgentsSearchRequestSearchItem { field: "name"; } + export interface Tags extends Letta.AgentsSearchRequestSearchItemTags { + field: "tags"; + } + export interface OrderBy extends Letta.AgentsSearchRequestSearchItemOrderBy { field: "order_by"; } diff --git a/src/api/resources/agents/types/AgentsSearchRequestSearchItemTags.ts b/src/api/resources/agents/types/AgentsSearchRequestSearchItemTags.ts new file mode 100644 index 0000000..124e56c --- /dev/null +++ b/src/api/resources/agents/types/AgentsSearchRequestSearchItemTags.ts @@ -0,0 +1,8 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +export interface AgentsSearchRequestSearchItemTags { + operator: "contains"; + value: string[]; +} diff --git a/src/api/resources/agents/types/index.ts b/src/api/resources/agents/types/index.ts index a514949..5b13dd7 100644 --- a/src/api/resources/agents/types/index.ts +++ b/src/api/resources/agents/types/index.ts @@ -3,6 +3,7 @@ export * from "./UpdateAgentToolRulesItem"; export * from "./AgentsSearchRequestSearchItemVersion"; export * from "./AgentsSearchRequestSearchItemNameOperator"; export * from "./AgentsSearchRequestSearchItemName"; +export * from "./AgentsSearchRequestSearchItemTags"; export * from "./AgentsSearchRequestSearchItemOrderByValue"; export * from "./AgentsSearchRequestSearchItemOrderByDirection"; export * from "./AgentsSearchRequestSearchItemOrderBy"; diff --git a/src/api/resources/blocks/client/Client.ts b/src/api/resources/blocks/client/Client.ts index d84e233..dce9dee 100644 --- a/src/api/resources/blocks/client/Client.ts +++ b/src/api/resources/blocks/client/Client.ts @@ -71,8 +71,8 @@ export class Blocks { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -154,8 +154,8 @@ export class Blocks { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -234,8 +234,8 @@ export class Blocks { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -313,8 +313,8 @@ export class Blocks { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -397,8 +397,8 @@ export class Blocks { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -489,8 +489,8 @@ export class Blocks { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -575,8 +575,8 @@ export class Blocks { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), diff --git a/src/api/resources/health/client/Client.ts b/src/api/resources/health/client/Client.ts index 68e7d7e..66613b2 100644 --- a/src/api/resources/health/client/Client.ts +++ b/src/api/resources/health/client/Client.ts @@ -51,8 +51,8 @@ export class Health { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), diff --git a/src/api/resources/jobs/client/Client.ts b/src/api/resources/jobs/client/Client.ts index 7401b0c..20da7fc 100644 --- a/src/api/resources/jobs/client/Client.ts +++ b/src/api/resources/jobs/client/Client.ts @@ -62,8 +62,8 @@ export class Jobs { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -143,8 +143,8 @@ export class Jobs { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -224,8 +224,8 @@ export class Jobs { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -305,8 +305,8 @@ export class Jobs { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), diff --git a/src/api/resources/models/client/Client.ts b/src/api/resources/models/client/Client.ts index 3c36123..86133ad 100644 --- a/src/api/resources/models/client/Client.ts +++ b/src/api/resources/models/client/Client.ts @@ -51,8 +51,8 @@ export class Models { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -114,8 +114,8 @@ export class Models { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), diff --git a/src/api/resources/providers/client/Client.ts b/src/api/resources/providers/client/Client.ts index 85abe35..3b8041b 100644 --- a/src/api/resources/providers/client/Client.ts +++ b/src/api/resources/providers/client/Client.ts @@ -69,8 +69,8 @@ export class Providers { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -157,8 +157,8 @@ export class Providers { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -245,8 +245,8 @@ export class Providers { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -335,8 +335,8 @@ export class Providers { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), diff --git a/src/api/resources/runs/client/Client.ts b/src/api/resources/runs/client/Client.ts index 8fc740b..a4172b8 100644 --- a/src/api/resources/runs/client/Client.ts +++ b/src/api/resources/runs/client/Client.ts @@ -55,8 +55,8 @@ export class Runs { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -135,8 +135,8 @@ export class Runs { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -216,8 +216,8 @@ export class Runs { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -297,8 +297,8 @@ export class Runs { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -361,17 +361,15 @@ export class Runs { * Args: * run_id: ID of the run * cursor: Cursor for pagination - * start_date: Filter messages after this date - * end_date: Filter messages before this date * limit: Maximum number of messages to return - * query_text: Search text in message content * ascending: Sort order by creation time - * tags: Filter by message tags - * match_all_tags: If true, match all tags. If false, match any tag - * role: Filter by message role (user/assistant/system/tool) - * tool_name: Filter by tool call name + * role: Filter by role (user/assistant/system/tool) + * return_message_object: Whether to return Message objects or LettaMessage objects * user_id: ID of the user making the request * + * Returns: + * A list of messages associated with the run. Default is List[LettaMessage]. + * * @param {string} runId * @param {Letta.GetRunMessagesRequest} request * @param {Runs.RequestOptions} requestOptions - Request-specific configuration. @@ -385,53 +383,25 @@ export class Runs { runId: string, request: Letta.GetRunMessagesRequest = {}, requestOptions?: Runs.RequestOptions, - ): Promise { - const { cursor, startDate, endDate, limit, queryText, ascending, tags, matchAllTags, role, toolName } = request; + ): Promise { + const { cursor, limit, ascending, role } = request; const _queryParams: Record = {}; if (cursor != null) { _queryParams["cursor"] = cursor; } - if (startDate != null) { - _queryParams["start_date"] = startDate.toISOString(); - } - - if (endDate != null) { - _queryParams["end_date"] = endDate.toISOString(); - } - if (limit != null) { _queryParams["limit"] = limit.toString(); } - if (queryText != null) { - _queryParams["query_text"] = queryText; - } - if (ascending != null) { _queryParams["ascending"] = ascending.toString(); } - if (tags != null) { - if (Array.isArray(tags)) { - _queryParams["tags"] = tags.map((item) => item); - } else { - _queryParams["tags"] = tags; - } - } - - if (matchAllTags != null) { - _queryParams["match_all_tags"] = matchAllTags.toString(); - } - if (role != null) { _queryParams["role"] = role; } - if (toolName != null) { - _queryParams["tool_name"] = toolName; - } - const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( (await core.Supplier.get(this._options.baseUrl)) ?? @@ -443,8 +413,8 @@ export class Runs { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -525,8 +495,8 @@ export class Runs { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), diff --git a/src/api/resources/runs/client/requests/GetRunMessagesRequest.ts b/src/api/resources/runs/client/requests/GetRunMessagesRequest.ts index 19f393a..6874e36 100644 --- a/src/api/resources/runs/client/requests/GetRunMessagesRequest.ts +++ b/src/api/resources/runs/client/requests/GetRunMessagesRequest.ts @@ -13,40 +13,16 @@ export interface GetRunMessagesRequest { * Cursor for pagination */ cursor?: string; - /** - * Filter messages after this date - */ - startDate?: Date; - /** - * Filter messages before this date - */ - endDate?: Date; /** * Maximum number of messages to return */ limit?: number; - /** - * Search text in message content - */ - queryText?: string; /** * Sort order by creation time */ ascending?: boolean; /** - * Filter by message tags - */ - tags?: string | string[]; - /** - * If true, match all tags. If false, match any tag - */ - matchAllTags?: boolean; - /** - * Filter by message role + * Filter by role */ role?: Letta.MessageRole; - /** - * Filter by tool call name - */ - toolName?: string; } diff --git a/src/api/resources/sources/client/Client.ts b/src/api/resources/sources/client/Client.ts index 743eca6..5373f28 100644 --- a/src/api/resources/sources/client/Client.ts +++ b/src/api/resources/sources/client/Client.ts @@ -69,8 +69,8 @@ export class Sources { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -150,8 +150,8 @@ export class Sources { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -230,8 +230,8 @@ export class Sources { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -312,8 +312,8 @@ export class Sources { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -392,8 +392,8 @@ export class Sources { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -475,8 +475,8 @@ export class Sources { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -567,8 +567,8 @@ export class Sources { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -661,8 +661,8 @@ export class Sources { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), diff --git a/src/api/resources/sources/resources/files/client/Client.ts b/src/api/resources/sources/resources/files/client/Client.ts index b418e44..88e99b1 100644 --- a/src/api/resources/sources/resources/files/client/Client.ts +++ b/src/api/resources/sources/resources/files/client/Client.ts @@ -66,8 +66,8 @@ export class Files { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -166,8 +166,8 @@ export class Files { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -249,8 +249,8 @@ export class Files { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), diff --git a/src/api/resources/sources/resources/passages/client/Client.ts b/src/api/resources/sources/resources/passages/client/Client.ts index cc29699..472c960 100644 --- a/src/api/resources/sources/resources/passages/client/Client.ts +++ b/src/api/resources/sources/resources/passages/client/Client.ts @@ -56,8 +56,8 @@ export class Passages { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), diff --git a/src/api/resources/tag/client/Client.ts b/src/api/resources/tag/client/Client.ts index 8342e40..babaf86 100644 --- a/src/api/resources/tag/client/Client.ts +++ b/src/api/resources/tag/client/Client.ts @@ -70,8 +70,8 @@ export class Tag { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), diff --git a/src/api/resources/tools/client/Client.ts b/src/api/resources/tools/client/Client.ts index 9b27d43..3044ec9 100644 --- a/src/api/resources/tools/client/Client.ts +++ b/src/api/resources/tools/client/Client.ts @@ -56,8 +56,8 @@ export class Tools { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -137,8 +137,8 @@ export class Tools { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -217,8 +217,8 @@ export class Tools { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -299,8 +299,8 @@ export class Tools { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -393,8 +393,8 @@ export class Tools { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -480,8 +480,8 @@ export class Tools { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -567,8 +567,8 @@ export class Tools { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -648,8 +648,8 @@ export class Tools { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -737,8 +737,8 @@ export class Tools { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -818,8 +818,8 @@ export class Tools { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -902,8 +902,8 @@ export class Tools { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), @@ -988,8 +988,8 @@ export class Tools { headers: { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@letta-ai/letta-client", - "X-Fern-SDK-Version": "0.1.9", - "User-Agent": "@letta-ai/letta-client/0.1.9", + "X-Fern-SDK-Version": "0.1.10", + "User-Agent": "@letta-ai/letta-client/0.1.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, ...(await this._getCustomAuthorizationHeaders()), diff --git a/src/api/types/EmbeddingConfigEmbeddingEndpointType.ts b/src/api/types/EmbeddingConfigEmbeddingEndpointType.ts index fa15b7a..d116064 100644 --- a/src/api/types/EmbeddingConfigEmbeddingEndpointType.ts +++ b/src/api/types/EmbeddingConfigEmbeddingEndpointType.ts @@ -8,6 +8,7 @@ export type EmbeddingConfigEmbeddingEndpointType = | "openai" | "anthropic" + | "bedrock" | "cohere" | "google_ai" | "azure" @@ -26,6 +27,7 @@ export type EmbeddingConfigEmbeddingEndpointType = export const EmbeddingConfigEmbeddingEndpointType = { Openai: "openai", Anthropic: "anthropic", + Bedrock: "bedrock", Cohere: "cohere", GoogleAi: "google_ai", Azure: "azure", diff --git a/src/api/types/LettaResponseMessagesItem.ts b/src/api/types/LettaMessageUnion.ts similarity index 66% rename from src/api/types/LettaResponseMessagesItem.ts rename to src/api/types/LettaMessageUnion.ts index 0a4c195..6b5a9b5 100644 --- a/src/api/types/LettaResponseMessagesItem.ts +++ b/src/api/types/LettaMessageUnion.ts @@ -4,15 +4,15 @@ import * as Letta from "../index"; -export type LettaResponseMessagesItem = - | Letta.LettaResponseMessagesItem.SystemMessage - | Letta.LettaResponseMessagesItem.UserMessage - | Letta.LettaResponseMessagesItem.ReasoningMessage - | Letta.LettaResponseMessagesItem.ToolCallMessage - | Letta.LettaResponseMessagesItem.ToolReturnMessage - | Letta.LettaResponseMessagesItem.AssistantMessage; - -export namespace LettaResponseMessagesItem { +export type LettaMessageUnion = + | Letta.LettaMessageUnion.SystemMessage + | Letta.LettaMessageUnion.UserMessage + | Letta.LettaMessageUnion.ReasoningMessage + | Letta.LettaMessageUnion.ToolCallMessage + | Letta.LettaMessageUnion.ToolReturnMessage + | Letta.LettaMessageUnion.AssistantMessage; + +export namespace LettaMessageUnion { export interface SystemMessage extends Letta.SystemMessageOutput { messageType: "system_message"; } diff --git a/src/api/types/LettaRequest.ts b/src/api/types/LettaRequest.ts index 196a4ee..c679f7a 100644 --- a/src/api/types/LettaRequest.ts +++ b/src/api/types/LettaRequest.ts @@ -7,10 +7,6 @@ import * as Letta from "../index"; export interface LettaRequest { /** The messages to be sent to the agent. */ messages: Letta.MessageCreate[]; - /** Whether the server should parse specific tool call arguments (default `send_message`) as `AssistantMessage` objects. */ - useAssistantMessage?: boolean; - /** The name of the designated message tool. */ - assistantMessageToolName?: string; - /** The name of the message argument in the designated message tool. */ - assistantMessageToolKwarg?: string; + /** Configuration options for the LettaRequest. */ + config?: Letta.LettaRequestConfig; } diff --git a/src/api/types/LettaRequestConfig.ts b/src/api/types/LettaRequestConfig.ts new file mode 100644 index 0000000..3827fed --- /dev/null +++ b/src/api/types/LettaRequestConfig.ts @@ -0,0 +1,12 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +export interface LettaRequestConfig { + /** Whether the server should parse specific tool call arguments (default `send_message`) as `AssistantMessage` objects. */ + useAssistantMessage?: boolean; + /** The name of the designated message tool. */ + assistantMessageToolName?: string; + /** The name of the message argument in the designated message tool. */ + assistantMessageToolKwarg?: string; +} diff --git a/src/api/types/LettaResponse.ts b/src/api/types/LettaResponse.ts index 3c36e60..1dad9ff 100644 --- a/src/api/types/LettaResponse.ts +++ b/src/api/types/LettaResponse.ts @@ -14,7 +14,7 @@ import * as Letta from "../index"; */ export interface LettaResponse { /** The messages returned by the agent. */ - messages: Letta.LettaResponseMessagesItem[]; + messages: Letta.LettaMessageUnion[]; /** The usage statistics of the agent. */ usage: Letta.LettaUsageStatistics; } diff --git a/src/api/types/LlmConfigModelEndpointType.ts b/src/api/types/LlmConfigModelEndpointType.ts index 6d8b382..48a3b18 100644 --- a/src/api/types/LlmConfigModelEndpointType.ts +++ b/src/api/types/LlmConfigModelEndpointType.ts @@ -22,7 +22,8 @@ export type LlmConfigModelEndpointType = | "vllm" | "hugging-face" | "mistral" - | "together"; + | "together" + | "bedrock"; export const LlmConfigModelEndpointType = { Openai: "openai", Anthropic: "anthropic", @@ -41,4 +42,5 @@ export const LlmConfigModelEndpointType = { HuggingFace: "hugging-face", Mistral: "mistral", Together: "together", + Bedrock: "bedrock", } as const; diff --git a/src/api/types/Run.ts b/src/api/types/Run.ts index 29c24b3..58c388f 100644 --- a/src/api/types/Run.ts +++ b/src/api/types/Run.ts @@ -33,4 +33,6 @@ export interface Run { jobType?: Letta.JobType; /** The human-friendly ID of the Run */ id?: string; + /** The request configuration for the run. */ + requestConfig?: Letta.LettaRequestConfig; } diff --git a/src/api/types/ToolType.ts b/src/api/types/ToolType.ts index 864b1bb..d53d718 100644 --- a/src/api/types/ToolType.ts +++ b/src/api/types/ToolType.ts @@ -2,9 +2,10 @@ * This file was auto-generated by Fern from our API Definition. */ -export type ToolType = "custom" | "letta_core" | "letta_memory_core"; +export type ToolType = "custom" | "letta_core" | "letta_memory_core" | "letta_multi_agent_core"; export const ToolType = { Custom: "custom", LettaCore: "letta_core", LettaMemoryCore: "letta_memory_core", + LettaMultiAgentCore: "letta_multi_agent_core", } as const; diff --git a/src/api/types/index.ts b/src/api/types/index.ts index 9db0701..6e483f2 100644 --- a/src/api/types/index.ts +++ b/src/api/types/index.ts @@ -52,7 +52,7 @@ export * from "./JobType"; export * from "./LlmConfigModelEndpointType"; export * from "./LlmConfig"; export * from "./LettaRequest"; -export * from "./LettaResponseMessagesItem"; +export * from "./LettaRequestConfig"; export * from "./LettaResponse"; export * from "./LettaUsageStatistics"; export * from "./LocalSandboxConfig"; @@ -116,3 +116,4 @@ export * from "./LettaSchemasOpenaiChatCompletionsToolCallInput"; export * from "./LettaSchemasOpenaiChatCompletionsToolCallOutput"; export * from "./LettaSchemasOpenaiChatCompletionsToolCallFunction"; export * from "./LettaSchemasToolTool"; +export * from "./LettaMessageUnion"; diff --git a/src/serialization/resources/agents/client/requests/CreateAgentRequest.ts b/src/serialization/resources/agents/client/requests/CreateAgentRequest.ts index 58a5a64..b9fcc5b 100644 --- a/src/serialization/resources/agents/client/requests/CreateAgentRequest.ts +++ b/src/serialization/resources/agents/client/requests/CreateAgentRequest.ts @@ -39,6 +39,10 @@ export const CreateAgentRequest: core.serialization.Schema< core.serialization.list(MessageCreate).optional(), ), includeBaseTools: core.serialization.property("include_base_tools", core.serialization.boolean().optional()), + includeMultiAgentTools: core.serialization.property( + "include_multi_agent_tools", + core.serialization.boolean().optional(), + ), description: core.serialization.string().optional(), metadata: core.serialization.property( "metadata_", @@ -76,6 +80,7 @@ export declare namespace CreateAgentRequest { embedding_config?: EmbeddingConfig.Raw | null; initial_message_sequence?: MessageCreate.Raw[] | null; include_base_tools?: boolean | null; + include_multi_agent_tools?: boolean | null; description?: string | null; metadata_?: Record | null; llm?: string | null; diff --git a/src/serialization/resources/agents/resources/messages/client/requests/LettaStreamingRequest.ts b/src/serialization/resources/agents/resources/messages/client/requests/LettaStreamingRequest.ts index 055243e..a8971a9 100644 --- a/src/serialization/resources/agents/resources/messages/client/requests/LettaStreamingRequest.ts +++ b/src/serialization/resources/agents/resources/messages/client/requests/LettaStreamingRequest.ts @@ -6,30 +6,21 @@ import * as serializers from "../../../../../../index"; import * as Letta from "../../../../../../../api/index"; import * as core from "../../../../../../../core"; import { MessageCreate } from "../../../../../../types/MessageCreate"; +import { LettaRequestConfig } from "../../../../../../types/LettaRequestConfig"; export const LettaStreamingRequest: core.serialization.Schema< serializers.agents.LettaStreamingRequest.Raw, Letta.agents.LettaStreamingRequest > = core.serialization.object({ messages: core.serialization.list(MessageCreate), - useAssistantMessage: core.serialization.property("use_assistant_message", core.serialization.boolean().optional()), - assistantMessageToolName: core.serialization.property( - "assistant_message_tool_name", - core.serialization.string().optional(), - ), - assistantMessageToolKwarg: core.serialization.property( - "assistant_message_tool_kwarg", - core.serialization.string().optional(), - ), + config: LettaRequestConfig.optional(), streamTokens: core.serialization.property("stream_tokens", core.serialization.boolean().optional()), }); export declare namespace LettaStreamingRequest { export interface Raw { messages: MessageCreate.Raw[]; - use_assistant_message?: boolean | null; - assistant_message_tool_name?: string | null; - assistant_message_tool_kwarg?: string | null; + config?: LettaRequestConfig.Raw | null; stream_tokens?: boolean | null; } } diff --git a/src/serialization/resources/agents/resources/messages/types/MessagesListResponse.ts b/src/serialization/resources/agents/resources/messages/types/MessagesListResponse.ts index ae82a9c..63a1ba3 100644 --- a/src/serialization/resources/agents/resources/messages/types/MessagesListResponse.ts +++ b/src/serialization/resources/agents/resources/messages/types/MessagesListResponse.ts @@ -6,16 +6,16 @@ import * as serializers from "../../../../../index"; import * as Letta from "../../../../../../api/index"; import * as core from "../../../../../../core"; import { LettaSchemasMessageMessage } from "../../../../../types/LettaSchemasMessageMessage"; -import { MessagesListResponseItem } from "./MessagesListResponseItem"; +import { LettaMessageUnion } from "../../../../../types/LettaMessageUnion"; export const MessagesListResponse: core.serialization.Schema< serializers.agents.MessagesListResponse.Raw, Letta.agents.MessagesListResponse > = core.serialization.undiscriminatedUnion([ core.serialization.list(LettaSchemasMessageMessage), - core.serialization.list(MessagesListResponseItem), + core.serialization.list(LettaMessageUnion), ]); export declare namespace MessagesListResponse { - export type Raw = LettaSchemasMessageMessage.Raw[] | MessagesListResponseItem.Raw[]; + export type Raw = LettaSchemasMessageMessage.Raw[] | LettaMessageUnion.Raw[]; } diff --git a/src/serialization/resources/agents/resources/messages/types/MessagesListResponseItem.ts b/src/serialization/resources/agents/resources/messages/types/MessagesListResponseItem.ts deleted file mode 100644 index cac5efa..0000000 --- a/src/serialization/resources/agents/resources/messages/types/MessagesListResponseItem.ts +++ /dev/null @@ -1,64 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as serializers from "../../../../../index"; -import * as Letta from "../../../../../../api/index"; -import * as core from "../../../../../../core"; -import { SystemMessageOutput } from "../../../../../types/SystemMessageOutput"; -import { UserMessageOutput } from "../../../../../types/UserMessageOutput"; -import { ReasoningMessage } from "../../../../../types/ReasoningMessage"; -import { ToolCallMessage } from "../../../../../types/ToolCallMessage"; -import { ToolReturnMessage } from "../../../../../types/ToolReturnMessage"; -import { AssistantMessageOutput } from "../../../../../types/AssistantMessageOutput"; - -export const MessagesListResponseItem: core.serialization.Schema< - serializers.agents.MessagesListResponseItem.Raw, - Letta.agents.MessagesListResponseItem -> = core.serialization - .union(core.serialization.discriminant("messageType", "message_type"), { - system_message: SystemMessageOutput, - user_message: UserMessageOutput, - reasoning_message: ReasoningMessage, - tool_call_message: ToolCallMessage, - tool_return_message: ToolReturnMessage, - assistant_message: AssistantMessageOutput, - }) - .transform({ - transform: (value) => value, - untransform: (value) => value, - }); - -export declare namespace MessagesListResponseItem { - export type Raw = - | MessagesListResponseItem.SystemMessage - | MessagesListResponseItem.UserMessage - | MessagesListResponseItem.ReasoningMessage - | MessagesListResponseItem.ToolCallMessage - | MessagesListResponseItem.ToolReturnMessage - | MessagesListResponseItem.AssistantMessage; - - export interface SystemMessage extends SystemMessageOutput.Raw { - message_type: "system_message"; - } - - export interface UserMessage extends UserMessageOutput.Raw { - message_type: "user_message"; - } - - export interface ReasoningMessage extends ReasoningMessage.Raw { - message_type: "reasoning_message"; - } - - export interface ToolCallMessage extends ToolCallMessage.Raw { - message_type: "tool_call_message"; - } - - export interface ToolReturnMessage extends ToolReturnMessage.Raw { - message_type: "tool_return_message"; - } - - export interface AssistantMessage extends AssistantMessageOutput.Raw { - message_type: "assistant_message"; - } -} diff --git a/src/serialization/resources/agents/resources/messages/types/index.ts b/src/serialization/resources/agents/resources/messages/types/index.ts index 8472685..70efe3d 100644 --- a/src/serialization/resources/agents/resources/messages/types/index.ts +++ b/src/serialization/resources/agents/resources/messages/types/index.ts @@ -1,3 +1,2 @@ -export * from "./MessagesListResponseItem"; export * from "./MessagesListResponse"; export * from "./LettaStreamingResponse"; diff --git a/src/serialization/resources/agents/types/AgentsSearchRequestSearchItem.ts b/src/serialization/resources/agents/types/AgentsSearchRequestSearchItem.ts index 74315bb..28ae4d3 100644 --- a/src/serialization/resources/agents/types/AgentsSearchRequestSearchItem.ts +++ b/src/serialization/resources/agents/types/AgentsSearchRequestSearchItem.ts @@ -7,6 +7,7 @@ import * as Letta from "../../../../api/index"; import * as core from "../../../../core"; import { AgentsSearchRequestSearchItemVersion } from "./AgentsSearchRequestSearchItemVersion"; import { AgentsSearchRequestSearchItemName } from "./AgentsSearchRequestSearchItemName"; +import { AgentsSearchRequestSearchItemTags } from "./AgentsSearchRequestSearchItemTags"; import { AgentsSearchRequestSearchItemOrderBy } from "./AgentsSearchRequestSearchItemOrderBy"; export const AgentsSearchRequestSearchItem: core.serialization.Schema< @@ -16,6 +17,7 @@ export const AgentsSearchRequestSearchItem: core.serialization.Schema< .union("field", { version: AgentsSearchRequestSearchItemVersion, name: AgentsSearchRequestSearchItemName, + tags: AgentsSearchRequestSearchItemTags, order_by: AgentsSearchRequestSearchItemOrderBy, }) .transform({ @@ -27,6 +29,7 @@ export declare namespace AgentsSearchRequestSearchItem { export type Raw = | AgentsSearchRequestSearchItem.Version | AgentsSearchRequestSearchItem.Name + | AgentsSearchRequestSearchItem.Tags | AgentsSearchRequestSearchItem.OrderBy; export interface Version extends AgentsSearchRequestSearchItemVersion.Raw { @@ -37,6 +40,10 @@ export declare namespace AgentsSearchRequestSearchItem { field: "name"; } + export interface Tags extends AgentsSearchRequestSearchItemTags.Raw { + field: "tags"; + } + export interface OrderBy extends AgentsSearchRequestSearchItemOrderBy.Raw { field: "order_by"; } diff --git a/src/serialization/resources/agents/types/AgentsSearchRequestSearchItemTags.ts b/src/serialization/resources/agents/types/AgentsSearchRequestSearchItemTags.ts new file mode 100644 index 0000000..8a39365 --- /dev/null +++ b/src/serialization/resources/agents/types/AgentsSearchRequestSearchItemTags.ts @@ -0,0 +1,22 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../../../index"; +import * as Letta from "../../../../api/index"; +import * as core from "../../../../core"; + +export const AgentsSearchRequestSearchItemTags: core.serialization.ObjectSchema< + serializers.AgentsSearchRequestSearchItemTags.Raw, + Letta.AgentsSearchRequestSearchItemTags +> = core.serialization.object({ + operator: core.serialization.stringLiteral("contains"), + value: core.serialization.list(core.serialization.string()), +}); + +export declare namespace AgentsSearchRequestSearchItemTags { + export interface Raw { + operator: "contains"; + value: string[]; + } +} diff --git a/src/serialization/resources/agents/types/index.ts b/src/serialization/resources/agents/types/index.ts index a514949..5b13dd7 100644 --- a/src/serialization/resources/agents/types/index.ts +++ b/src/serialization/resources/agents/types/index.ts @@ -3,6 +3,7 @@ export * from "./UpdateAgentToolRulesItem"; export * from "./AgentsSearchRequestSearchItemVersion"; export * from "./AgentsSearchRequestSearchItemNameOperator"; export * from "./AgentsSearchRequestSearchItemName"; +export * from "./AgentsSearchRequestSearchItemTags"; export * from "./AgentsSearchRequestSearchItemOrderByValue"; export * from "./AgentsSearchRequestSearchItemOrderByDirection"; export * from "./AgentsSearchRequestSearchItemOrderBy"; diff --git a/src/serialization/resources/runs/client/getRunMessages.ts b/src/serialization/resources/runs/client/getRunMessages.ts index 5c913d2..6bd161c 100644 --- a/src/serialization/resources/runs/client/getRunMessages.ts +++ b/src/serialization/resources/runs/client/getRunMessages.ts @@ -5,13 +5,13 @@ import * as serializers from "../../../index"; import * as Letta from "../../../../api/index"; import * as core from "../../../../core"; -import { LettaSchemasMessageMessage } from "../../../types/LettaSchemasMessageMessage"; +import { LettaMessageUnion } from "../../../types/LettaMessageUnion"; export const Response: core.serialization.Schema< serializers.runs.getRunMessages.Response.Raw, - Letta.LettaSchemasMessageMessage[] -> = core.serialization.list(LettaSchemasMessageMessage); + Letta.LettaMessageUnion[] +> = core.serialization.list(LettaMessageUnion); export declare namespace Response { - export type Raw = LettaSchemasMessageMessage.Raw[]; + export type Raw = LettaMessageUnion.Raw[]; } diff --git a/src/serialization/types/EmbeddingConfigEmbeddingEndpointType.ts b/src/serialization/types/EmbeddingConfigEmbeddingEndpointType.ts index 99852fc..59f1caf 100644 --- a/src/serialization/types/EmbeddingConfigEmbeddingEndpointType.ts +++ b/src/serialization/types/EmbeddingConfigEmbeddingEndpointType.ts @@ -12,6 +12,7 @@ export const EmbeddingConfigEmbeddingEndpointType: core.serialization.Schema< > = core.serialization.enum_([ "openai", "anthropic", + "bedrock", "cohere", "google_ai", "azure", @@ -33,6 +34,7 @@ export declare namespace EmbeddingConfigEmbeddingEndpointType { export type Raw = | "openai" | "anthropic" + | "bedrock" | "cohere" | "google_ai" | "azure" diff --git a/src/serialization/types/LettaResponseMessagesItem.ts b/src/serialization/types/LettaMessageUnion.ts similarity index 55% rename from src/serialization/types/LettaResponseMessagesItem.ts rename to src/serialization/types/LettaMessageUnion.ts index c3d0fae..71342fc 100644 --- a/src/serialization/types/LettaResponseMessagesItem.ts +++ b/src/serialization/types/LettaMessageUnion.ts @@ -12,31 +12,29 @@ import { ToolCallMessage } from "./ToolCallMessage"; import { ToolReturnMessage } from "./ToolReturnMessage"; import { AssistantMessageOutput } from "./AssistantMessageOutput"; -export const LettaResponseMessagesItem: core.serialization.Schema< - serializers.LettaResponseMessagesItem.Raw, - Letta.LettaResponseMessagesItem -> = core.serialization - .union(core.serialization.discriminant("messageType", "message_type"), { - system_message: SystemMessageOutput, - user_message: UserMessageOutput, - reasoning_message: ReasoningMessage, - tool_call_message: ToolCallMessage, - tool_return_message: ToolReturnMessage, - assistant_message: AssistantMessageOutput, - }) - .transform({ - transform: (value) => value, - untransform: (value) => value, - }); - -export declare namespace LettaResponseMessagesItem { +export const LettaMessageUnion: core.serialization.Schema = + core.serialization + .union(core.serialization.discriminant("messageType", "message_type"), { + system_message: SystemMessageOutput, + user_message: UserMessageOutput, + reasoning_message: ReasoningMessage, + tool_call_message: ToolCallMessage, + tool_return_message: ToolReturnMessage, + assistant_message: AssistantMessageOutput, + }) + .transform({ + transform: (value) => value, + untransform: (value) => value, + }); + +export declare namespace LettaMessageUnion { export type Raw = - | LettaResponseMessagesItem.SystemMessage - | LettaResponseMessagesItem.UserMessage - | LettaResponseMessagesItem.ReasoningMessage - | LettaResponseMessagesItem.ToolCallMessage - | LettaResponseMessagesItem.ToolReturnMessage - | LettaResponseMessagesItem.AssistantMessage; + | LettaMessageUnion.SystemMessage + | LettaMessageUnion.UserMessage + | LettaMessageUnion.ReasoningMessage + | LettaMessageUnion.ToolCallMessage + | LettaMessageUnion.ToolReturnMessage + | LettaMessageUnion.AssistantMessage; export interface SystemMessage extends SystemMessageOutput.Raw { message_type: "system_message"; diff --git a/src/serialization/types/LettaRequest.ts b/src/serialization/types/LettaRequest.ts index 1e0f8d2..d9f05bc 100644 --- a/src/serialization/types/LettaRequest.ts +++ b/src/serialization/types/LettaRequest.ts @@ -6,29 +6,17 @@ import * as serializers from "../index"; import * as Letta from "../../api/index"; import * as core from "../../core"; import { MessageCreate } from "./MessageCreate"; +import { LettaRequestConfig } from "./LettaRequestConfig"; export const LettaRequest: core.serialization.ObjectSchema = core.serialization.object({ messages: core.serialization.list(MessageCreate), - useAssistantMessage: core.serialization.property( - "use_assistant_message", - core.serialization.boolean().optional(), - ), - assistantMessageToolName: core.serialization.property( - "assistant_message_tool_name", - core.serialization.string().optional(), - ), - assistantMessageToolKwarg: core.serialization.property( - "assistant_message_tool_kwarg", - core.serialization.string().optional(), - ), + config: LettaRequestConfig.optional(), }); export declare namespace LettaRequest { export interface Raw { messages: MessageCreate.Raw[]; - use_assistant_message?: boolean | null; - assistant_message_tool_name?: string | null; - assistant_message_tool_kwarg?: string | null; + config?: LettaRequestConfig.Raw | null; } } diff --git a/src/serialization/types/LettaRequestConfig.ts b/src/serialization/types/LettaRequestConfig.ts new file mode 100644 index 0000000..fae3668 --- /dev/null +++ b/src/serialization/types/LettaRequestConfig.ts @@ -0,0 +1,30 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../index"; +import * as Letta from "../../api/index"; +import * as core from "../../core"; + +export const LettaRequestConfig: core.serialization.ObjectSchema< + serializers.LettaRequestConfig.Raw, + Letta.LettaRequestConfig +> = core.serialization.object({ + useAssistantMessage: core.serialization.property("use_assistant_message", core.serialization.boolean().optional()), + assistantMessageToolName: core.serialization.property( + "assistant_message_tool_name", + core.serialization.string().optional(), + ), + assistantMessageToolKwarg: core.serialization.property( + "assistant_message_tool_kwarg", + core.serialization.string().optional(), + ), +}); + +export declare namespace LettaRequestConfig { + export interface Raw { + use_assistant_message?: boolean | null; + assistant_message_tool_name?: string | null; + assistant_message_tool_kwarg?: string | null; + } +} diff --git a/src/serialization/types/LettaResponse.ts b/src/serialization/types/LettaResponse.ts index 4ca1552..0cf2777 100644 --- a/src/serialization/types/LettaResponse.ts +++ b/src/serialization/types/LettaResponse.ts @@ -5,18 +5,18 @@ import * as serializers from "../index"; import * as Letta from "../../api/index"; import * as core from "../../core"; -import { LettaResponseMessagesItem } from "./LettaResponseMessagesItem"; +import { LettaMessageUnion } from "./LettaMessageUnion"; import { LettaUsageStatistics } from "./LettaUsageStatistics"; export const LettaResponse: core.serialization.ObjectSchema = core.serialization.object({ - messages: core.serialization.list(LettaResponseMessagesItem), + messages: core.serialization.list(LettaMessageUnion), usage: LettaUsageStatistics, }); export declare namespace LettaResponse { export interface Raw { - messages: LettaResponseMessagesItem.Raw[]; + messages: LettaMessageUnion.Raw[]; usage: LettaUsageStatistics.Raw; } } diff --git a/src/serialization/types/LlmConfigModelEndpointType.ts b/src/serialization/types/LlmConfigModelEndpointType.ts index 43354bc..a8a145a 100644 --- a/src/serialization/types/LlmConfigModelEndpointType.ts +++ b/src/serialization/types/LlmConfigModelEndpointType.ts @@ -27,6 +27,7 @@ export const LlmConfigModelEndpointType: core.serialization.Schema< "hugging-face", "mistral", "together", + "bedrock", ]); export declare namespace LlmConfigModelEndpointType { @@ -47,5 +48,6 @@ export declare namespace LlmConfigModelEndpointType { | "vllm" | "hugging-face" | "mistral" - | "together"; + | "together" + | "bedrock"; } diff --git a/src/serialization/types/Run.ts b/src/serialization/types/Run.ts index 11970e6..f9576da 100644 --- a/src/serialization/types/Run.ts +++ b/src/serialization/types/Run.ts @@ -7,6 +7,7 @@ import * as Letta from "../../api/index"; import * as core from "../../core"; import { JobStatus } from "./JobStatus"; import { JobType } from "./JobType"; +import { LettaRequestConfig } from "./LettaRequestConfig"; export const Run: core.serialization.ObjectSchema = core.serialization.object({ createdById: core.serialization.property("created_by_id", core.serialization.string().optional()), @@ -21,6 +22,7 @@ export const Run: core.serialization.ObjectSchema | null; job_type?: JobType.Raw | null; id?: string | null; + request_config?: LettaRequestConfig.Raw | null; } } diff --git a/src/serialization/types/ToolType.ts b/src/serialization/types/ToolType.ts index 53d8e4b..5345c0d 100644 --- a/src/serialization/types/ToolType.ts +++ b/src/serialization/types/ToolType.ts @@ -10,8 +10,9 @@ export const ToolType: core.serialization.Schema