@letta-ai/letta-client 1.0.0-alpha.7 → 1.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +248 -0
- package/README.md +282 -319
- package/client.d.mts +61 -36
- package/client.d.mts.map +1 -1
- package/client.d.ts +61 -36
- package/client.d.ts.map +1 -1
- package/client.js +53 -23
- package/client.js.map +1 -1
- package/client.mjs +53 -23
- package/client.mjs.map +1 -1
- package/core/pagination.d.mts +96 -0
- package/core/pagination.d.mts.map +1 -0
- package/core/pagination.d.ts +96 -0
- package/core/pagination.d.ts.map +1 -0
- package/core/pagination.js +199 -0
- package/core/pagination.js.map +1 -0
- package/core/pagination.mjs +191 -0
- package/core/pagination.mjs.map +1 -0
- package/core/streaming.d.mts +33 -0
- package/core/streaming.d.mts.map +1 -0
- package/core/streaming.d.ts +33 -0
- package/core/streaming.d.ts.map +1 -0
- package/core/streaming.js +276 -0
- package/core/streaming.js.map +1 -0
- package/core/streaming.mjs +271 -0
- package/core/streaming.mjs.map +1 -0
- package/index.d.mts +1 -0
- package/index.d.mts.map +1 -1
- package/index.d.ts +1 -0
- package/index.d.ts.map +1 -1
- package/index.js +3 -1
- package/index.js.map +1 -1
- package/index.mjs +1 -0
- package/index.mjs.map +1 -1
- package/internal/decoders/line.d.mts +17 -0
- package/internal/decoders/line.d.mts.map +1 -0
- package/internal/decoders/line.d.ts +17 -0
- package/internal/decoders/line.d.ts.map +1 -0
- package/internal/decoders/line.js +113 -0
- package/internal/decoders/line.js.map +1 -0
- package/internal/decoders/line.mjs +108 -0
- package/internal/decoders/line.mjs.map +1 -0
- package/internal/parse.d.mts.map +1 -1
- package/internal/parse.d.ts.map +1 -1
- package/internal/parse.js +10 -0
- package/internal/parse.js.map +1 -1
- package/internal/parse.mjs +10 -0
- package/internal/parse.mjs.map +1 -1
- package/internal/request-options.d.mts +2 -0
- package/internal/request-options.d.mts.map +1 -1
- package/internal/request-options.d.ts +2 -0
- package/internal/request-options.d.ts.map +1 -1
- package/internal/request-options.js.map +1 -1
- package/internal/request-options.mjs.map +1 -1
- package/internal/tslib.js +17 -17
- package/package.json +21 -1
- package/pagination.d.mts +2 -0
- package/pagination.d.mts.map +1 -0
- package/pagination.d.ts +2 -0
- package/pagination.d.ts.map +1 -0
- package/pagination.js +6 -0
- package/pagination.js.map +1 -0
- package/pagination.mjs +2 -0
- package/pagination.mjs.map +1 -0
- package/resources/access-tokens.d.mts +105 -0
- package/resources/access-tokens.d.mts.map +1 -0
- package/resources/access-tokens.d.ts +105 -0
- package/resources/access-tokens.d.ts.map +1 -0
- package/resources/access-tokens.js +30 -0
- package/resources/access-tokens.js.map +1 -0
- package/resources/access-tokens.mjs +26 -0
- package/resources/access-tokens.mjs.map +1 -0
- package/resources/agents/agents.d.mts +517 -160
- package/resources/agents/agents.d.mts.map +1 -1
- package/resources/agents/agents.d.ts +517 -160
- package/resources/agents/agents.d.ts.map +1 -1
- package/resources/agents/agents.js +16 -21
- package/resources/agents/agents.js.map +1 -1
- package/resources/agents/agents.mjs +17 -22
- package/resources/agents/agents.mjs.map +1 -1
- package/resources/agents/archives.d.mts +31 -0
- package/resources/agents/archives.d.mts.map +1 -0
- package/resources/agents/archives.d.ts +31 -0
- package/resources/agents/archives.d.ts.map +1 -0
- package/resources/agents/archives.js +24 -0
- package/resources/agents/archives.js.map +1 -0
- package/resources/agents/archives.mjs +20 -0
- package/resources/agents/archives.mjs.map +1 -0
- package/resources/agents/blocks.d.mts +33 -55
- package/resources/agents/blocks.d.mts.map +1 -1
- package/resources/agents/blocks.d.ts +33 -55
- package/resources/agents/blocks.d.ts.map +1 -1
- package/resources/agents/blocks.js +2 -1
- package/resources/agents/blocks.js.map +1 -1
- package/resources/agents/blocks.mjs +2 -1
- package/resources/agents/blocks.mjs.map +1 -1
- package/resources/agents/files.d.mts +39 -79
- package/resources/agents/files.d.mts.map +1 -1
- package/resources/agents/files.d.ts +39 -79
- package/resources/agents/files.d.ts.map +1 -1
- package/resources/agents/files.js +5 -1
- package/resources/agents/files.js.map +1 -1
- package/resources/agents/files.mjs +5 -1
- package/resources/agents/files.mjs.map +1 -1
- package/resources/agents/folders.d.mts +50 -79
- package/resources/agents/folders.d.mts.map +1 -1
- package/resources/agents/folders.d.ts +50 -79
- package/resources/agents/folders.d.ts.map +1 -1
- package/resources/agents/folders.js +5 -1
- package/resources/agents/folders.js.map +1 -1
- package/resources/agents/folders.mjs +5 -1
- package/resources/agents/folders.mjs.map +1 -1
- package/resources/agents/groups.d.mts +6 -28
- package/resources/agents/groups.d.mts.map +1 -1
- package/resources/agents/groups.d.ts +6 -28
- package/resources/agents/groups.d.ts.map +1 -1
- package/resources/agents/groups.js +5 -1
- package/resources/agents/groups.js.map +1 -1
- package/resources/agents/groups.mjs +5 -1
- package/resources/agents/groups.mjs.map +1 -1
- package/resources/agents/identities.d.mts +31 -0
- package/resources/agents/identities.d.mts.map +1 -0
- package/resources/agents/identities.d.ts +31 -0
- package/resources/agents/identities.d.ts.map +1 -0
- package/resources/agents/identities.js +24 -0
- package/resources/agents/identities.js.map +1 -0
- package/resources/agents/identities.mjs +20 -0
- package/resources/agents/identities.mjs.map +1 -0
- package/resources/agents/index.d.mts +9 -7
- package/resources/agents/index.d.mts.map +1 -1
- package/resources/agents/index.d.ts +9 -7
- package/resources/agents/index.d.ts.map +1 -1
- package/resources/agents/index.js +5 -1
- package/resources/agents/index.js.map +1 -1
- package/resources/agents/index.mjs +2 -0
- package/resources/agents/index.mjs.map +1 -1
- package/resources/agents/messages.d.mts +668 -422
- package/resources/agents/messages.d.mts.map +1 -1
- package/resources/agents/messages.d.ts +668 -422
- package/resources/agents/messages.d.ts.map +1 -1
- package/resources/agents/messages.js +27 -26
- package/resources/agents/messages.js.map +1 -1
- package/resources/agents/messages.mjs +27 -26
- package/resources/agents/messages.mjs.map +1 -1
- package/resources/agents/tools.d.mts +9 -30
- package/resources/agents/tools.d.mts.map +1 -1
- package/resources/agents/tools.d.ts +9 -30
- package/resources/agents/tools.d.ts.map +1 -1
- package/resources/agents/tools.js +5 -1
- package/resources/agents/tools.js.map +1 -1
- package/resources/agents/tools.mjs +5 -1
- package/resources/agents/tools.mjs.map +1 -1
- package/resources/archives/archives.d.mts +115 -0
- package/resources/archives/archives.d.mts.map +1 -0
- package/resources/archives/archives.d.ts +115 -0
- package/resources/archives/archives.d.ts.map +1 -0
- package/resources/archives/archives.js +50 -0
- package/resources/archives/archives.js.map +1 -0
- package/resources/archives/archives.mjs +45 -0
- package/resources/archives/archives.mjs.map +1 -0
- package/resources/archives/index.d.mts +3 -0
- package/resources/archives/index.d.mts.map +1 -0
- package/resources/archives/index.d.ts +3 -0
- package/resources/archives/index.d.ts.map +1 -0
- package/resources/archives/index.js +9 -0
- package/resources/archives/index.js.map +1 -0
- package/resources/archives/index.mjs +4 -0
- package/resources/archives/index.mjs.map +1 -0
- package/resources/archives/passages.d.mts +113 -0
- package/resources/archives/passages.d.mts.map +1 -0
- package/resources/archives/passages.d.ts +113 -0
- package/resources/archives/passages.d.ts.map +1 -0
- package/resources/archives/passages.js +32 -0
- package/resources/archives/passages.js.map +1 -0
- package/resources/archives/passages.mjs +28 -0
- package/resources/archives/passages.mjs.map +1 -0
- package/resources/archives.d.mts +1 -130
- package/resources/archives.d.mts.map +1 -1
- package/resources/archives.d.ts +1 -130
- package/resources/archives.d.ts.map +1 -1
- package/resources/archives.js +2 -37
- package/resources/archives.js.map +1 -1
- package/resources/archives.mjs +1 -35
- package/resources/archives.mjs.map +1 -1
- package/resources/batches/batches.d.mts +52 -34
- package/resources/batches/batches.d.mts.map +1 -1
- package/resources/batches/batches.d.ts +52 -34
- package/resources/batches/batches.d.ts.map +1 -1
- package/resources/batches/batches.js +2 -1
- package/resources/batches/batches.js.map +1 -1
- package/resources/batches/batches.mjs +2 -1
- package/resources/batches/batches.mjs.map +1 -1
- package/resources/batches/index.d.mts +2 -2
- package/resources/batches/index.d.mts.map +1 -1
- package/resources/batches/index.d.ts +2 -2
- package/resources/batches/index.d.ts.map +1 -1
- package/resources/batches/index.js.map +1 -1
- package/resources/batches/index.mjs.map +1 -1
- package/resources/batches/messages.d.mts +6 -30
- package/resources/batches/messages.d.mts.map +1 -1
- package/resources/batches/messages.d.ts +6 -30
- package/resources/batches/messages.d.ts.map +1 -1
- package/resources/batches/messages.js +2 -1
- package/resources/batches/messages.js.map +1 -1
- package/resources/batches/messages.mjs +2 -1
- package/resources/batches/messages.mjs.map +1 -1
- package/resources/blocks/agents.d.mts +6 -28
- package/resources/blocks/agents.d.mts.map +1 -1
- package/resources/blocks/agents.d.ts +6 -28
- package/resources/blocks/agents.d.ts.map +1 -1
- package/resources/blocks/agents.js +5 -1
- package/resources/blocks/agents.js.map +1 -1
- package/resources/blocks/agents.mjs +5 -1
- package/resources/blocks/agents.mjs.map +1 -1
- package/resources/blocks/blocks.d.mts +108 -48
- package/resources/blocks/blocks.d.mts.map +1 -1
- package/resources/blocks/blocks.d.ts +108 -48
- package/resources/blocks/blocks.d.ts.map +1 -1
- package/resources/blocks/blocks.js +3 -8
- package/resources/blocks/blocks.js.map +1 -1
- package/resources/blocks/blocks.mjs +3 -8
- package/resources/blocks/blocks.mjs.map +1 -1
- package/resources/blocks/index.d.mts +2 -2
- package/resources/blocks/index.d.mts.map +1 -1
- package/resources/blocks/index.d.ts +2 -2
- package/resources/blocks/index.d.ts.map +1 -1
- package/resources/blocks/index.js.map +1 -1
- package/resources/blocks/index.mjs.map +1 -1
- package/resources/folders/files.d.mts +75 -97
- package/resources/folders/files.d.mts.map +1 -1
- package/resources/folders/files.d.ts +75 -97
- package/resources/folders/files.d.ts.map +1 -1
- package/resources/folders/files.js +5 -1
- package/resources/folders/files.js.map +1 -1
- package/resources/folders/files.mjs +5 -1
- package/resources/folders/files.mjs.map +1 -1
- package/resources/folders/folders.d.mts +11 -44
- package/resources/folders/folders.d.mts.map +1 -1
- package/resources/folders/folders.d.ts +11 -44
- package/resources/folders/folders.d.ts.map +1 -1
- package/resources/folders/folders.js +2 -7
- package/resources/folders/folders.js.map +1 -1
- package/resources/folders/folders.mjs +2 -7
- package/resources/folders/folders.mjs.map +1 -1
- package/resources/folders/index.d.mts +2 -2
- package/resources/folders/index.d.mts.map +1 -1
- package/resources/folders/index.d.ts +2 -2
- package/resources/folders/index.d.ts.map +1 -1
- package/resources/folders/index.js.map +1 -1
- package/resources/folders/index.mjs.map +1 -1
- package/resources/groups/groups.d.mts +17 -67
- package/resources/groups/groups.d.mts.map +1 -1
- package/resources/groups/groups.d.ts +17 -67
- package/resources/groups/groups.d.ts.map +1 -1
- package/resources/groups/groups.js +6 -28
- package/resources/groups/groups.js.map +1 -1
- package/resources/groups/groups.mjs +6 -28
- package/resources/groups/groups.mjs.map +1 -1
- package/resources/groups/index.d.mts +2 -2
- package/resources/groups/index.d.mts.map +1 -1
- package/resources/groups/index.d.ts +2 -2
- package/resources/groups/index.d.ts.map +1 -1
- package/resources/groups/index.js.map +1 -1
- package/resources/groups/index.mjs.map +1 -1
- package/resources/groups/messages.d.mts +145 -79
- package/resources/groups/messages.d.mts.map +1 -1
- package/resources/groups/messages.d.ts +145 -79
- package/resources/groups/messages.d.ts.map +1 -1
- package/resources/groups/messages.js +18 -10
- package/resources/groups/messages.js.map +1 -1
- package/resources/groups/messages.mjs +18 -10
- package/resources/groups/messages.mjs.map +1 -1
- package/resources/identities/agents.d.mts +6 -28
- package/resources/identities/agents.d.mts.map +1 -1
- package/resources/identities/agents.d.ts +6 -28
- package/resources/identities/agents.d.ts.map +1 -1
- package/resources/identities/agents.js +2 -1
- package/resources/identities/agents.js.map +1 -1
- package/resources/identities/agents.mjs +2 -1
- package/resources/identities/agents.mjs.map +1 -1
- package/resources/identities/blocks.d.mts +7 -29
- package/resources/identities/blocks.d.mts.map +1 -1
- package/resources/identities/blocks.d.ts +7 -29
- package/resources/identities/blocks.d.ts.map +1 -1
- package/resources/identities/blocks.js +2 -1
- package/resources/identities/blocks.js.map +1 -1
- package/resources/identities/blocks.mjs +2 -1
- package/resources/identities/blocks.mjs.map +1 -1
- package/resources/identities/identities.d.mts +30 -65
- package/resources/identities/identities.d.mts.map +1 -1
- package/resources/identities/identities.d.ts +30 -65
- package/resources/identities/identities.d.ts.map +1 -1
- package/resources/identities/identities.js +7 -29
- package/resources/identities/identities.js.map +1 -1
- package/resources/identities/identities.mjs +7 -29
- package/resources/identities/identities.mjs.map +1 -1
- package/resources/identities/index.d.mts +3 -3
- package/resources/identities/index.d.mts.map +1 -1
- package/resources/identities/index.d.ts +3 -3
- package/resources/identities/index.d.ts.map +1 -1
- package/resources/identities/index.js.map +1 -1
- package/resources/identities/index.mjs.map +1 -1
- package/resources/identities/properties.d.mts +1 -1
- package/resources/identities/properties.d.ts +1 -1
- package/resources/identities/properties.js +1 -1
- package/resources/identities/properties.mjs +1 -1
- package/resources/index.d.mts +13 -11
- package/resources/index.d.mts.map +1 -1
- package/resources/index.d.ts +13 -11
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js +6 -2
- package/resources/index.js.map +1 -1
- package/resources/index.mjs +3 -1
- package/resources/index.mjs.map +1 -1
- package/resources/mcp-servers/index.d.mts +3 -0
- package/resources/mcp-servers/index.d.mts.map +1 -0
- package/resources/mcp-servers/index.d.ts +3 -0
- package/resources/mcp-servers/index.d.ts.map +1 -0
- package/resources/mcp-servers/index.js +9 -0
- package/resources/mcp-servers/index.js.map +1 -0
- package/resources/mcp-servers/index.mjs +4 -0
- package/resources/mcp-servers/index.mjs.map +1 -0
- package/resources/mcp-servers/mcp-servers.d.mts +349 -0
- package/resources/mcp-servers/mcp-servers.d.mts.map +1 -0
- package/resources/mcp-servers/mcp-servers.d.ts +349 -0
- package/resources/mcp-servers/mcp-servers.d.ts.map +1 -0
- package/resources/mcp-servers/mcp-servers.js +69 -0
- package/resources/mcp-servers/mcp-servers.js.map +1 -0
- package/resources/mcp-servers/mcp-servers.mjs +64 -0
- package/resources/mcp-servers/mcp-servers.mjs.map +1 -0
- package/resources/mcp-servers/tools.d.mts +42 -0
- package/resources/mcp-servers/tools.d.mts.map +1 -0
- package/resources/mcp-servers/tools.d.ts +42 -0
- package/resources/mcp-servers/tools.d.ts.map +1 -0
- package/resources/mcp-servers/tools.js +36 -0
- package/resources/mcp-servers/tools.js.map +1 -0
- package/resources/mcp-servers/tools.mjs +32 -0
- package/resources/mcp-servers/tools.mjs.map +1 -0
- package/resources/mcp-servers.d.mts +2 -0
- package/resources/mcp-servers.d.mts.map +1 -0
- package/resources/mcp-servers.d.ts +2 -0
- package/resources/mcp-servers.d.ts.map +1 -0
- package/resources/mcp-servers.js +6 -0
- package/resources/mcp-servers.js.map +1 -0
- package/resources/mcp-servers.mjs +3 -0
- package/resources/mcp-servers.mjs.map +1 -0
- package/resources/models/embeddings.d.mts +6 -2
- package/resources/models/embeddings.d.mts.map +1 -1
- package/resources/models/embeddings.d.ts +6 -2
- package/resources/models/embeddings.d.ts.map +1 -1
- package/resources/models/embeddings.js +5 -1
- package/resources/models/embeddings.js.map +1 -1
- package/resources/models/embeddings.mjs +5 -1
- package/resources/models/embeddings.mjs.map +1 -1
- package/resources/models/index.d.mts +1 -1
- package/resources/models/index.d.mts.map +1 -1
- package/resources/models/index.d.ts +1 -1
- package/resources/models/index.d.ts.map +1 -1
- package/resources/models/index.js.map +1 -1
- package/resources/models/index.mjs.map +1 -1
- package/resources/models/models.d.mts +180 -4
- package/resources/models/models.d.mts.map +1 -1
- package/resources/models/models.d.ts +180 -4
- package/resources/models/models.d.ts.map +1 -1
- package/resources/models/models.js +5 -1
- package/resources/models/models.js.map +1 -1
- package/resources/models/models.mjs +5 -1
- package/resources/models/models.mjs.map +1 -1
- package/resources/runs/index.d.mts +3 -3
- package/resources/runs/index.d.mts.map +1 -1
- package/resources/runs/index.d.ts +3 -3
- package/resources/runs/index.d.ts.map +1 -1
- package/resources/runs/index.js.map +1 -1
- package/resources/runs/index.mjs.map +1 -1
- package/resources/runs/messages.d.mts +8 -28
- package/resources/runs/messages.d.mts.map +1 -1
- package/resources/runs/messages.d.ts +8 -28
- package/resources/runs/messages.d.ts.map +1 -1
- package/resources/runs/messages.js +10 -2
- package/resources/runs/messages.js.map +1 -1
- package/resources/runs/messages.mjs +10 -2
- package/resources/runs/messages.mjs.map +1 -1
- package/resources/runs/runs.d.mts +10 -36
- package/resources/runs/runs.d.mts.map +1 -1
- package/resources/runs/runs.d.ts +10 -36
- package/resources/runs/runs.d.ts.map +1 -1
- package/resources/runs/runs.js +2 -1
- package/resources/runs/runs.js.map +1 -1
- package/resources/runs/runs.mjs +3 -2
- package/resources/runs/runs.mjs.map +1 -1
- package/resources/runs/steps.d.mts +6 -26
- package/resources/runs/steps.d.mts.map +1 -1
- package/resources/runs/steps.d.ts +6 -26
- package/resources/runs/steps.d.ts.map +1 -1
- package/resources/runs/steps.js +5 -1
- package/resources/runs/steps.js.map +1 -1
- package/resources/runs/steps.mjs +5 -1
- package/resources/runs/steps.mjs.map +1 -1
- package/resources/steps/index.d.mts +2 -2
- package/resources/steps/index.d.mts.map +1 -1
- package/resources/steps/index.d.ts +2 -2
- package/resources/steps/index.d.ts.map +1 -1
- package/resources/steps/index.js.map +1 -1
- package/resources/steps/index.mjs +1 -1
- package/resources/steps/index.mjs.map +1 -1
- package/resources/steps/messages.d.mts +14 -28
- package/resources/steps/messages.d.mts.map +1 -1
- package/resources/steps/messages.d.ts +14 -28
- package/resources/steps/messages.d.ts.map +1 -1
- package/resources/steps/messages.js +5 -1
- package/resources/steps/messages.js.map +1 -1
- package/resources/steps/messages.mjs +5 -1
- package/resources/steps/messages.mjs.map +1 -1
- package/resources/steps/steps.d.mts +17 -44
- package/resources/steps/steps.d.mts.map +1 -1
- package/resources/steps/steps.d.ts +17 -44
- package/resources/steps/steps.d.ts.map +1 -1
- package/resources/steps/steps.js +3 -11
- package/resources/steps/steps.js.map +1 -1
- package/resources/steps/steps.mjs +3 -11
- package/resources/steps/steps.mjs.map +1 -1
- package/resources/templates/agents.d.mts +9 -14
- package/resources/templates/agents.d.mts.map +1 -1
- package/resources/templates/agents.d.ts +9 -14
- package/resources/templates/agents.d.ts.map +1 -1
- package/resources/templates/agents.js +2 -3
- package/resources/templates/agents.js.map +1 -1
- package/resources/templates/agents.mjs +2 -3
- package/resources/templates/agents.mjs.map +1 -1
- package/resources/tools.d.mts +6 -68
- package/resources/tools.d.mts.map +1 -1
- package/resources/tools.d.ts +6 -68
- package/resources/tools.d.ts.map +1 -1
- package/resources/tools.js +2 -7
- package/resources/tools.js.map +1 -1
- package/resources/tools.mjs +2 -7
- package/resources/tools.mjs.map +1 -1
- package/src/client.ts +274 -127
- package/src/core/pagination.ts +334 -0
- package/src/core/streaming.ts +331 -0
- package/src/index.ts +1 -0
- package/src/internal/decoders/line.ts +135 -0
- package/src/internal/parse.ts +14 -0
- package/src/internal/request-options.ts +2 -0
- package/src/pagination.ts +2 -0
- package/src/resources/access-tokens.ts +163 -0
- package/src/resources/agents/agents.ts +722 -242
- package/src/resources/agents/archives.ts +51 -0
- package/src/resources/agents/blocks.ts +50 -63
- package/src/resources/agents/files.ts +47 -90
- package/src/resources/agents/folders.ts +58 -88
- package/src/resources/agents/groups.ts +11 -35
- package/src/resources/agents/identities.ts +51 -0
- package/src/resources/agents/index.ts +40 -12
- package/src/resources/agents/messages.ts +941 -550
- package/src/resources/agents/tools.ts +13 -37
- package/src/resources/archives/archives.ts +170 -0
- package/src/resources/archives/index.ts +17 -0
- package/src/resources/archives/passages.ts +150 -0
- package/src/resources/archives.ts +1 -178
- package/src/resources/batches/batches.ts +74 -46
- package/src/resources/batches/index.ts +2 -2
- package/src/resources/batches/messages.ts +12 -37
- package/src/resources/blocks/agents.ts +11 -35
- package/src/resources/blocks/blocks.ts +130 -64
- package/src/resources/blocks/index.ts +3 -3
- package/src/resources/folders/files.ts +90 -113
- package/src/resources/folders/folders.ts +14 -55
- package/src/resources/folders/index.ts +2 -2
- package/src/resources/groups/groups.ts +21 -102
- package/src/resources/groups/index.ts +2 -4
- package/src/resources/groups/messages.ts +215 -103
- package/src/resources/identities/agents.ts +12 -35
- package/src/resources/identities/blocks.ts +13 -36
- package/src/resources/identities/identities.ts +35 -107
- package/src/resources/identities/index.ts +3 -4
- package/src/resources/identities/properties.ts +1 -1
- package/src/resources/index.ts +55 -18
- package/src/resources/mcp-servers/index.ts +25 -0
- package/src/resources/mcp-servers/mcp-servers.ts +460 -0
- package/src/resources/mcp-servers/tools.ts +69 -0
- package/src/resources/mcp-servers.ts +3 -0
- package/src/resources/models/embeddings.ts +6 -2
- package/src/resources/models/index.ts +2 -0
- package/src/resources/models/models.ts +260 -3
- package/src/resources/runs/index.ts +2 -3
- package/src/resources/runs/messages.ts +18 -37
- package/src/resources/runs/runs.ts +14 -54
- package/src/resources/runs/steps.ts +11 -33
- package/src/resources/steps/index.ts +7 -2
- package/src/resources/steps/messages.ts +25 -35
- package/src/resources/steps/steps.ts +20 -61
- package/src/resources/templates/agents.ts +14 -17
- package/src/resources/tools.ts +8 -92
- package/src/streaming.ts +2 -0
- package/src/version.ts +1 -1
- package/streaming.d.mts +2 -0
- package/streaming.d.mts.map +1 -0
- package/streaming.d.ts +2 -0
- package/streaming.d.ts.map +1 -0
- package/streaming.js +6 -0
- package/streaming.js.map +1 -0
- package/streaming.mjs +2 -0
- package/streaming.mjs.map +1 -0
- package/version.d.mts +1 -1
- package/version.d.mts.map +1 -1
- package/version.d.ts +1 -1
- package/version.d.ts.map +1 -1
- package/version.js +1 -1
- package/version.js.map +1 -1
- package/version.mjs +1 -1
- package/version.mjs.map +1 -1
|
@@ -1,37 +1,45 @@
|
|
|
1
1
|
import { APIResource } from "../../core/resource.mjs";
|
|
2
2
|
import * as AgentsAPI from "./agents.mjs";
|
|
3
|
-
import * as ArchivesAPI from "../archives.mjs";
|
|
4
3
|
import * as ToolsAPI from "../tools.mjs";
|
|
4
|
+
import * as ArchivesAPI from "./archives.mjs";
|
|
5
|
+
import { ArchiveAttachParams, ArchiveAttachResponse, ArchiveDetachParams, ArchiveDetachResponse, Archives } from "./archives.mjs";
|
|
5
6
|
import * as BlocksAPI from "./blocks.mjs";
|
|
6
|
-
import { Block, BlockAttachParams, BlockDetachParams, BlockListParams,
|
|
7
|
+
import { Block, BlockAttachParams, BlockDetachParams, BlockListParams, BlockRetrieveParams, BlockUpdate, BlockUpdateParams, Blocks } from "./blocks.mjs";
|
|
7
8
|
import * as FilesAPI from "./files.mjs";
|
|
8
|
-
import { FileCloseAllResponse, FileCloseParams, FileCloseResponse, FileListParams, FileListResponse, FileOpenParams, FileOpenResponse, Files } from "./files.mjs";
|
|
9
|
+
import { FileCloseAllResponse, FileCloseParams, FileCloseResponse, FileListParams, FileListResponse, FileListResponsesNextFilesPage, FileOpenParams, FileOpenResponse, Files } from "./files.mjs";
|
|
9
10
|
import * as FoldersAPI from "./folders.mjs";
|
|
10
|
-
import { FolderAttachParams, FolderDetachParams, FolderListParams, FolderListResponse, Folders } from "./folders.mjs";
|
|
11
|
+
import { FolderAttachParams, FolderDetachParams, FolderListParams, FolderListResponse, FolderListResponsesArrayPage, Folders } from "./folders.mjs";
|
|
11
12
|
import * as GroupsAPI from "./groups.mjs";
|
|
12
|
-
import { GroupListParams,
|
|
13
|
+
import { GroupListParams, Groups } from "./groups.mjs";
|
|
14
|
+
import * as IdentitiesAPI from "./identities.mjs";
|
|
15
|
+
import { Identities, IdentityAttachParams, IdentityAttachResponse, IdentityDetachParams, IdentityDetachResponse } from "./identities.mjs";
|
|
13
16
|
import * as MessagesAPI from "./messages.mjs";
|
|
14
|
-
import { ApprovalCreate, ApprovalRequestMessage, ApprovalResponseMessage, AssistantMessage, HiddenReasoningMessage, ImageContent, JobStatus, JobType, LettaAssistantMessageContentUnion,
|
|
17
|
+
import { ApprovalCreate, ApprovalRequestMessage, ApprovalResponseMessage, ApprovalReturn, AssistantMessage, EventMessage, HiddenReasoningMessage, ImageContent, InternalMessage, JobStatus, JobType, LettaAssistantMessageContentUnion, LettaRequest, LettaResponse, LettaStreamingRequest, LettaStreamingResponse, LettaUserMessageContentUnion, Message, MessageCancelParams, MessageCancelResponse, MessageCreateAsyncParams, MessageCreateParams, MessageCreateParamsNonStreaming, MessageCreateParamsStreaming, MessageListParams, MessageResetParams, MessageRole, MessageStreamParams, MessageType, Messages, MessagesArrayPage, OmittedReasoningContent, ReasoningContent, ReasoningMessage, RedactedReasoningContent, Run, SummaryMessage, SystemMessage, TextContent, ToolCall, ToolCallContent, ToolCallDelta, ToolCallMessage, ToolReturn, ToolReturnContent, UpdateAssistantMessage, UpdateReasoningMessage, UpdateSystemMessage, UpdateUserMessage, UserMessage } from "./messages.mjs";
|
|
15
18
|
import * as AgentsToolsAPI from "./tools.mjs";
|
|
16
|
-
import { ToolAttachParams, ToolDetachParams, ToolListParams,
|
|
19
|
+
import { ToolAttachParams, ToolDetachParams, ToolListParams, ToolUpdateApprovalParams, Tools } from "./tools.mjs";
|
|
20
|
+
import * as ArchivesArchivesAPI from "../archives/archives.mjs";
|
|
17
21
|
import * as BlocksBlocksAPI from "../blocks/blocks.mjs";
|
|
18
22
|
import * as GroupsGroupsAPI from "../groups/groups.mjs";
|
|
19
|
-
import * as
|
|
23
|
+
import * as IdentitiesIdentitiesAPI from "../identities/identities.mjs";
|
|
20
24
|
import * as ModelsAPI from "../models/models.mjs";
|
|
25
|
+
import * as RunsAPI from "../runs/runs.mjs";
|
|
21
26
|
import { APIPromise } from "../../core/api-promise.mjs";
|
|
27
|
+
import { ArrayPage, type ArrayPageParams, PagePromise } from "../../core/pagination.mjs";
|
|
22
28
|
import { type Uploadable } from "../../core/uploads.mjs";
|
|
23
29
|
import { RequestOptions } from "../../internal/request-options.mjs";
|
|
24
30
|
export declare class Agents extends APIResource {
|
|
31
|
+
messages: MessagesAPI.Messages;
|
|
32
|
+
blocks: BlocksAPI.Blocks;
|
|
25
33
|
tools: AgentsToolsAPI.Tools;
|
|
26
34
|
folders: FoldersAPI.Folders;
|
|
27
35
|
files: FilesAPI.Files;
|
|
28
|
-
blocks: BlocksAPI.Blocks;
|
|
29
36
|
groups: GroupsAPI.Groups;
|
|
30
|
-
|
|
37
|
+
archives: ArchivesAPI.Archives;
|
|
38
|
+
identities: IdentitiesAPI.Identities;
|
|
31
39
|
/**
|
|
32
40
|
* Create an agent.
|
|
33
41
|
*/
|
|
34
|
-
create(
|
|
42
|
+
create(body: AgentCreateParams, options?: RequestOptions): APIPromise<AgentState>;
|
|
35
43
|
/**
|
|
36
44
|
* Get the state of the agent.
|
|
37
45
|
*/
|
|
@@ -43,15 +51,11 @@ export declare class Agents extends APIResource {
|
|
|
43
51
|
/**
|
|
44
52
|
* Get a list of all agents.
|
|
45
53
|
*/
|
|
46
|
-
list(query?: AgentListParams | null | undefined, options?: RequestOptions):
|
|
54
|
+
list(query?: AgentListParams | null | undefined, options?: RequestOptions): PagePromise<AgentStatesArrayPage, AgentState>;
|
|
47
55
|
/**
|
|
48
56
|
* Delete an agent.
|
|
49
57
|
*/
|
|
50
58
|
delete(agentID: string, options?: RequestOptions): APIPromise<unknown>;
|
|
51
|
-
/**
|
|
52
|
-
* Get the total number of agents.
|
|
53
|
-
*/
|
|
54
|
-
count(options?: RequestOptions): APIPromise<AgentCountResponse>;
|
|
55
59
|
/**
|
|
56
60
|
* Export the serialized JSON representation of an agent, formatted with
|
|
57
61
|
* indentation.
|
|
@@ -63,6 +67,7 @@ export declare class Agents extends APIResource {
|
|
|
63
67
|
*/
|
|
64
68
|
importFile(params: AgentImportFileParams, options?: RequestOptions): APIPromise<AgentImportFileResponse>;
|
|
65
69
|
}
|
|
70
|
+
export type AgentStatesArrayPage = ArrayPage<AgentState>;
|
|
66
71
|
export interface AgentEnvironmentVariable {
|
|
67
72
|
/**
|
|
68
73
|
* The ID of the agent this environment variable belongs to.
|
|
@@ -109,16 +114,6 @@ export interface AgentEnvironmentVariable {
|
|
|
109
114
|
* Representation of an agent's state. This is the state of the agent at a given
|
|
110
115
|
* time, and is persisted in the DB backend. The state has all the information
|
|
111
116
|
* needed to recreate a persisted agent.
|
|
112
|
-
*
|
|
113
|
-
* Parameters: id (str): The unique identifier of the agent. name (str): The name
|
|
114
|
-
* of the agent (must be unique to the user). created_at (datetime): The datetime
|
|
115
|
-
* the agent was created. message_ids (List[str]): The ids of the messages in the
|
|
116
|
-
* agent's in-context memory. memory (Memory): The in-context memory of the agent.
|
|
117
|
-
* tools (List[str]): The tools used by the agent. This includes any memory editing
|
|
118
|
-
* functions specified in `memory`. system (str): The system prompt used by the
|
|
119
|
-
* agent. llm_config (LLMConfig): The LLM configuration used by the agent.
|
|
120
|
-
* embedding_config (EmbeddingConfig): The embedding configuration used by the
|
|
121
|
-
* agent.
|
|
122
117
|
*/
|
|
123
118
|
export interface AgentState {
|
|
124
119
|
/**
|
|
@@ -134,15 +129,18 @@ export interface AgentState {
|
|
|
134
129
|
*/
|
|
135
130
|
blocks: Array<BlocksAPI.Block>;
|
|
136
131
|
/**
|
|
137
|
-
*
|
|
132
|
+
* @deprecated Deprecated: Use `embedding` field instead. The embedding
|
|
133
|
+
* configuration used by the agent.
|
|
138
134
|
*/
|
|
139
135
|
embedding_config: ModelsAPI.EmbeddingConfig;
|
|
140
136
|
/**
|
|
141
|
-
* The LLM configuration used by
|
|
137
|
+
* @deprecated Deprecated: Use `model` field instead. The LLM configuration used by
|
|
138
|
+
* the agent.
|
|
142
139
|
*/
|
|
143
140
|
llm_config: ModelsAPI.LlmConfig;
|
|
144
141
|
/**
|
|
145
|
-
* @deprecated The in-context memory of the
|
|
142
|
+
* @deprecated Deprecated: Use `blocks` field instead. The in-context memory of the
|
|
143
|
+
* agent.
|
|
146
144
|
*/
|
|
147
145
|
memory: AgentState.Memory;
|
|
148
146
|
/**
|
|
@@ -150,7 +148,8 @@ export interface AgentState {
|
|
|
150
148
|
*/
|
|
151
149
|
name: string;
|
|
152
150
|
/**
|
|
153
|
-
* The sources used by the
|
|
151
|
+
* @deprecated Deprecated: Use `folders` field instead. The sources used by the
|
|
152
|
+
* agent.
|
|
154
153
|
*/
|
|
155
154
|
sources: Array<AgentState.Source>;
|
|
156
155
|
/**
|
|
@@ -185,6 +184,10 @@ export interface AgentState {
|
|
|
185
184
|
* The description of the agent.
|
|
186
185
|
*/
|
|
187
186
|
description?: string | null;
|
|
187
|
+
/**
|
|
188
|
+
* The embedding model handle used by the agent (format: provider/model-name).
|
|
189
|
+
*/
|
|
190
|
+
embedding?: string | null;
|
|
188
191
|
/**
|
|
189
192
|
* If set to True, memory management will move to a background agent thread.
|
|
190
193
|
*/
|
|
@@ -200,9 +203,10 @@ export interface AgentState {
|
|
|
200
203
|
/**
|
|
201
204
|
* The identities associated with this agent.
|
|
202
205
|
*/
|
|
203
|
-
identities?: Array<
|
|
206
|
+
identities?: Array<IdentitiesIdentitiesAPI.Identity>;
|
|
204
207
|
/**
|
|
205
|
-
* @deprecated
|
|
208
|
+
* @deprecated Deprecated: Use `identities` field instead. The ids of the
|
|
209
|
+
* identities associated with this agent.
|
|
206
210
|
*/
|
|
207
211
|
identity_ids?: Array<string>;
|
|
208
212
|
/**
|
|
@@ -213,6 +217,10 @@ export interface AgentState {
|
|
|
213
217
|
* The duration in milliseconds of the agent's last run.
|
|
214
218
|
*/
|
|
215
219
|
last_run_duration_ms?: number | null;
|
|
220
|
+
/**
|
|
221
|
+
* The stop reason from the agent's last run.
|
|
222
|
+
*/
|
|
223
|
+
last_stop_reason?: RunsAPI.StopReasonType | null;
|
|
216
224
|
/**
|
|
217
225
|
* The id of the user that made this object.
|
|
218
226
|
*/
|
|
@@ -243,7 +251,16 @@ export interface AgentState {
|
|
|
243
251
|
[key: string]: unknown;
|
|
244
252
|
} | null;
|
|
245
253
|
/**
|
|
246
|
-
*
|
|
254
|
+
* The model handle used by the agent (format: provider/model-name).
|
|
255
|
+
*/
|
|
256
|
+
model?: string | null;
|
|
257
|
+
/**
|
|
258
|
+
* The model settings used by the agent.
|
|
259
|
+
*/
|
|
260
|
+
model_settings?: OpenAIModelSettings | AnthropicModelSettings | GoogleAIModelSettings | GoogleVertexModelSettings | AzureModelSettings | XaiModelSettings | GroqModelSettings | DeepseekModelSettings | TogetherModelSettings | BedrockModelSettings | null;
|
|
261
|
+
/**
|
|
262
|
+
* @deprecated Deprecated: Use `managed_group` field instead. The multi-agent group
|
|
263
|
+
* that this agent manages.
|
|
247
264
|
*/
|
|
248
265
|
multi_agent_group?: GroupsGroupsAPI.Group | null;
|
|
249
266
|
/**
|
|
@@ -256,7 +273,7 @@ export interface AgentState {
|
|
|
256
273
|
*/
|
|
257
274
|
project_id?: string | null;
|
|
258
275
|
/**
|
|
259
|
-
* The response format used by the agent
|
|
276
|
+
* The response format used by the agent
|
|
260
277
|
*/
|
|
261
278
|
response_format?: TextResponseFormat | JsonSchemaResponseFormat | JsonObjectResponseFormat | null;
|
|
262
279
|
/**
|
|
@@ -286,7 +303,8 @@ export interface AgentState {
|
|
|
286
303
|
}
|
|
287
304
|
export declare namespace AgentState {
|
|
288
305
|
/**
|
|
289
|
-
* @deprecated The in-context memory of the
|
|
306
|
+
* @deprecated Deprecated: Use `blocks` field instead. The in-context memory of the
|
|
307
|
+
* agent.
|
|
290
308
|
*/
|
|
291
309
|
interface Memory {
|
|
292
310
|
/**
|
|
@@ -317,7 +335,8 @@ export declare namespace AgentState {
|
|
|
317
335
|
*/
|
|
318
336
|
is_open: boolean;
|
|
319
337
|
/**
|
|
320
|
-
* Unique identifier of the
|
|
338
|
+
* @deprecated Deprecated: Use `folder_id` field instead. Unique identifier of the
|
|
339
|
+
* source.
|
|
321
340
|
*/
|
|
322
341
|
source_id: string;
|
|
323
342
|
/**
|
|
@@ -379,10 +398,6 @@ export declare namespace AgentState {
|
|
|
379
398
|
metadata?: {
|
|
380
399
|
[key: string]: unknown;
|
|
381
400
|
} | null;
|
|
382
|
-
/**
|
|
383
|
-
* The id of the template.
|
|
384
|
-
*/
|
|
385
|
-
name?: string | null;
|
|
386
401
|
/**
|
|
387
402
|
* Preserve the block on template migration.
|
|
388
403
|
*/
|
|
@@ -395,18 +410,25 @@ export declare namespace AgentState {
|
|
|
395
410
|
* Whether the agent has read-only access to the block.
|
|
396
411
|
*/
|
|
397
412
|
read_only?: boolean;
|
|
413
|
+
/**
|
|
414
|
+
* The id of the template.
|
|
415
|
+
*/
|
|
416
|
+
template_id?: string | null;
|
|
417
|
+
/**
|
|
418
|
+
* Name of the block if it is a template.
|
|
419
|
+
*/
|
|
420
|
+
template_name?: string | null;
|
|
398
421
|
}
|
|
399
422
|
}
|
|
400
423
|
/**
|
|
401
|
-
* Representation of a source, which is a collection of
|
|
402
|
-
*
|
|
403
|
-
* Parameters: id (str): The ID of the source name (str): The name of the source.
|
|
404
|
-
* embedding_config (EmbeddingConfig): The embedding configuration used by the
|
|
405
|
-
* source. user_id (str): The ID of the user that created the source. metadata
|
|
406
|
-
* (dict): Metadata associated with the source. description (str): The description
|
|
407
|
-
* of the source.
|
|
424
|
+
* (Deprecated: Use Folder) Representation of a source, which is a collection of
|
|
425
|
+
* files and passages.
|
|
408
426
|
*/
|
|
409
427
|
interface Source {
|
|
428
|
+
/**
|
|
429
|
+
* The human-friendly ID of the Source
|
|
430
|
+
*/
|
|
431
|
+
id: string;
|
|
410
432
|
/**
|
|
411
433
|
* The embedding configuration used by the source.
|
|
412
434
|
*/
|
|
@@ -415,10 +437,6 @@ export declare namespace AgentState {
|
|
|
415
437
|
* The name of the source.
|
|
416
438
|
*/
|
|
417
439
|
name: string;
|
|
418
|
-
/**
|
|
419
|
-
* The human-friendly ID of the Source
|
|
420
|
-
*/
|
|
421
|
-
id?: string;
|
|
422
440
|
/**
|
|
423
441
|
* The timestamp when the source was created.
|
|
424
442
|
*/
|
|
@@ -452,13 +470,104 @@ export declare namespace AgentState {
|
|
|
452
470
|
/**
|
|
453
471
|
* The vector database provider used for this source's passages
|
|
454
472
|
*/
|
|
455
|
-
vector_db_provider?:
|
|
473
|
+
vector_db_provider?: ArchivesArchivesAPI.VectorDBProvider;
|
|
456
474
|
}
|
|
457
475
|
}
|
|
458
476
|
/**
|
|
459
477
|
* Enum to represent the type of agent.
|
|
460
478
|
*/
|
|
461
479
|
export type AgentType = 'memgpt_agent' | 'memgpt_v2_agent' | 'letta_v1_agent' | 'react_agent' | 'workflow_agent' | 'split_thread_agent' | 'sleeptime_agent' | 'voice_convo_agent' | 'voice_sleeptime_agent';
|
|
480
|
+
export interface AnthropicModelSettings {
|
|
481
|
+
/**
|
|
482
|
+
* The maximum number of tokens the model can generate.
|
|
483
|
+
*/
|
|
484
|
+
max_output_tokens?: number;
|
|
485
|
+
/**
|
|
486
|
+
* Whether to enable parallel tool calling.
|
|
487
|
+
*/
|
|
488
|
+
parallel_tool_calls?: boolean;
|
|
489
|
+
/**
|
|
490
|
+
* The type of the provider.
|
|
491
|
+
*/
|
|
492
|
+
provider_type?: 'anthropic';
|
|
493
|
+
/**
|
|
494
|
+
* The temperature of the model.
|
|
495
|
+
*/
|
|
496
|
+
temperature?: number;
|
|
497
|
+
/**
|
|
498
|
+
* The thinking configuration for the model.
|
|
499
|
+
*/
|
|
500
|
+
thinking?: AnthropicModelSettings.Thinking;
|
|
501
|
+
/**
|
|
502
|
+
* Soft control for how verbose model output should be, used for GPT-5 models.
|
|
503
|
+
*/
|
|
504
|
+
verbosity?: 'low' | 'medium' | 'high' | null;
|
|
505
|
+
}
|
|
506
|
+
export declare namespace AnthropicModelSettings {
|
|
507
|
+
/**
|
|
508
|
+
* The thinking configuration for the model.
|
|
509
|
+
*/
|
|
510
|
+
interface Thinking {
|
|
511
|
+
/**
|
|
512
|
+
* The maximum number of tokens the model can use for extended thinking.
|
|
513
|
+
*/
|
|
514
|
+
budget_tokens?: number;
|
|
515
|
+
/**
|
|
516
|
+
* The type of thinking to use.
|
|
517
|
+
*/
|
|
518
|
+
type?: 'enabled' | 'disabled';
|
|
519
|
+
}
|
|
520
|
+
}
|
|
521
|
+
/**
|
|
522
|
+
* Azure OpenAI model configuration (OpenAI-compatible).
|
|
523
|
+
*/
|
|
524
|
+
export interface AzureModelSettings {
|
|
525
|
+
/**
|
|
526
|
+
* The maximum number of tokens the model can generate.
|
|
527
|
+
*/
|
|
528
|
+
max_output_tokens?: number;
|
|
529
|
+
/**
|
|
530
|
+
* Whether to enable parallel tool calling.
|
|
531
|
+
*/
|
|
532
|
+
parallel_tool_calls?: boolean;
|
|
533
|
+
/**
|
|
534
|
+
* The type of the provider.
|
|
535
|
+
*/
|
|
536
|
+
provider_type?: 'azure';
|
|
537
|
+
/**
|
|
538
|
+
* The response format for the model.
|
|
539
|
+
*/
|
|
540
|
+
response_format?: TextResponseFormat | JsonSchemaResponseFormat | JsonObjectResponseFormat | null;
|
|
541
|
+
/**
|
|
542
|
+
* The temperature of the model.
|
|
543
|
+
*/
|
|
544
|
+
temperature?: number;
|
|
545
|
+
}
|
|
546
|
+
/**
|
|
547
|
+
* AWS Bedrock model configuration.
|
|
548
|
+
*/
|
|
549
|
+
export interface BedrockModelSettings {
|
|
550
|
+
/**
|
|
551
|
+
* The maximum number of tokens the model can generate.
|
|
552
|
+
*/
|
|
553
|
+
max_output_tokens?: number;
|
|
554
|
+
/**
|
|
555
|
+
* Whether to enable parallel tool calling.
|
|
556
|
+
*/
|
|
557
|
+
parallel_tool_calls?: boolean;
|
|
558
|
+
/**
|
|
559
|
+
* The type of the provider.
|
|
560
|
+
*/
|
|
561
|
+
provider_type?: 'bedrock';
|
|
562
|
+
/**
|
|
563
|
+
* The response format for the model.
|
|
564
|
+
*/
|
|
565
|
+
response_format?: TextResponseFormat | JsonSchemaResponseFormat | JsonObjectResponseFormat | null;
|
|
566
|
+
/**
|
|
567
|
+
* The temperature of the model.
|
|
568
|
+
*/
|
|
569
|
+
temperature?: number;
|
|
570
|
+
}
|
|
462
571
|
/**
|
|
463
572
|
* A ToolRule represents a tool that can be invoked by the agent.
|
|
464
573
|
*/
|
|
@@ -547,6 +656,138 @@ export interface ContinueToolRule {
|
|
|
547
656
|
prompt_template?: string | null;
|
|
548
657
|
type?: 'continue_loop';
|
|
549
658
|
}
|
|
659
|
+
/**
|
|
660
|
+
* Deepseek model configuration (OpenAI-compatible).
|
|
661
|
+
*/
|
|
662
|
+
export interface DeepseekModelSettings {
|
|
663
|
+
/**
|
|
664
|
+
* The maximum number of tokens the model can generate.
|
|
665
|
+
*/
|
|
666
|
+
max_output_tokens?: number;
|
|
667
|
+
/**
|
|
668
|
+
* Whether to enable parallel tool calling.
|
|
669
|
+
*/
|
|
670
|
+
parallel_tool_calls?: boolean;
|
|
671
|
+
/**
|
|
672
|
+
* The type of the provider.
|
|
673
|
+
*/
|
|
674
|
+
provider_type?: 'deepseek';
|
|
675
|
+
/**
|
|
676
|
+
* The response format for the model.
|
|
677
|
+
*/
|
|
678
|
+
response_format?: TextResponseFormat | JsonSchemaResponseFormat | JsonObjectResponseFormat | null;
|
|
679
|
+
/**
|
|
680
|
+
* The temperature of the model.
|
|
681
|
+
*/
|
|
682
|
+
temperature?: number;
|
|
683
|
+
}
|
|
684
|
+
export interface GoogleAIModelSettings {
|
|
685
|
+
/**
|
|
686
|
+
* The maximum number of tokens the model can generate.
|
|
687
|
+
*/
|
|
688
|
+
max_output_tokens?: number;
|
|
689
|
+
/**
|
|
690
|
+
* Whether to enable parallel tool calling.
|
|
691
|
+
*/
|
|
692
|
+
parallel_tool_calls?: boolean;
|
|
693
|
+
/**
|
|
694
|
+
* The type of the provider.
|
|
695
|
+
*/
|
|
696
|
+
provider_type?: 'google_ai';
|
|
697
|
+
/**
|
|
698
|
+
* The response schema for the model.
|
|
699
|
+
*/
|
|
700
|
+
response_schema?: TextResponseFormat | JsonSchemaResponseFormat | JsonObjectResponseFormat | null;
|
|
701
|
+
/**
|
|
702
|
+
* The temperature of the model.
|
|
703
|
+
*/
|
|
704
|
+
temperature?: number;
|
|
705
|
+
/**
|
|
706
|
+
* The thinking configuration for the model.
|
|
707
|
+
*/
|
|
708
|
+
thinking_config?: GoogleAIModelSettings.ThinkingConfig;
|
|
709
|
+
}
|
|
710
|
+
export declare namespace GoogleAIModelSettings {
|
|
711
|
+
/**
|
|
712
|
+
* The thinking configuration for the model.
|
|
713
|
+
*/
|
|
714
|
+
interface ThinkingConfig {
|
|
715
|
+
/**
|
|
716
|
+
* Whether to include thoughts in the model's response.
|
|
717
|
+
*/
|
|
718
|
+
include_thoughts?: boolean;
|
|
719
|
+
/**
|
|
720
|
+
* The thinking budget for the model.
|
|
721
|
+
*/
|
|
722
|
+
thinking_budget?: number;
|
|
723
|
+
}
|
|
724
|
+
}
|
|
725
|
+
export interface GoogleVertexModelSettings {
|
|
726
|
+
/**
|
|
727
|
+
* The maximum number of tokens the model can generate.
|
|
728
|
+
*/
|
|
729
|
+
max_output_tokens?: number;
|
|
730
|
+
/**
|
|
731
|
+
* Whether to enable parallel tool calling.
|
|
732
|
+
*/
|
|
733
|
+
parallel_tool_calls?: boolean;
|
|
734
|
+
/**
|
|
735
|
+
* The type of the provider.
|
|
736
|
+
*/
|
|
737
|
+
provider_type?: 'google_vertex';
|
|
738
|
+
/**
|
|
739
|
+
* The response schema for the model.
|
|
740
|
+
*/
|
|
741
|
+
response_schema?: TextResponseFormat | JsonSchemaResponseFormat | JsonObjectResponseFormat | null;
|
|
742
|
+
/**
|
|
743
|
+
* The temperature of the model.
|
|
744
|
+
*/
|
|
745
|
+
temperature?: number;
|
|
746
|
+
/**
|
|
747
|
+
* The thinking configuration for the model.
|
|
748
|
+
*/
|
|
749
|
+
thinking_config?: GoogleVertexModelSettings.ThinkingConfig;
|
|
750
|
+
}
|
|
751
|
+
export declare namespace GoogleVertexModelSettings {
|
|
752
|
+
/**
|
|
753
|
+
* The thinking configuration for the model.
|
|
754
|
+
*/
|
|
755
|
+
interface ThinkingConfig {
|
|
756
|
+
/**
|
|
757
|
+
* Whether to include thoughts in the model's response.
|
|
758
|
+
*/
|
|
759
|
+
include_thoughts?: boolean;
|
|
760
|
+
/**
|
|
761
|
+
* The thinking budget for the model.
|
|
762
|
+
*/
|
|
763
|
+
thinking_budget?: number;
|
|
764
|
+
}
|
|
765
|
+
}
|
|
766
|
+
/**
|
|
767
|
+
* Groq model configuration (OpenAI-compatible).
|
|
768
|
+
*/
|
|
769
|
+
export interface GroqModelSettings {
|
|
770
|
+
/**
|
|
771
|
+
* The maximum number of tokens the model can generate.
|
|
772
|
+
*/
|
|
773
|
+
max_output_tokens?: number;
|
|
774
|
+
/**
|
|
775
|
+
* Whether to enable parallel tool calling.
|
|
776
|
+
*/
|
|
777
|
+
parallel_tool_calls?: boolean;
|
|
778
|
+
/**
|
|
779
|
+
* The type of the provider.
|
|
780
|
+
*/
|
|
781
|
+
provider_type?: 'groq';
|
|
782
|
+
/**
|
|
783
|
+
* The response format for the model.
|
|
784
|
+
*/
|
|
785
|
+
response_format?: TextResponseFormat | JsonSchemaResponseFormat | JsonObjectResponseFormat | null;
|
|
786
|
+
/**
|
|
787
|
+
* The temperature of the model.
|
|
788
|
+
*/
|
|
789
|
+
temperature?: number;
|
|
790
|
+
}
|
|
550
791
|
/**
|
|
551
792
|
* Represents the initial tool rule configuration.
|
|
552
793
|
*/
|
|
@@ -657,6 +898,43 @@ export interface MessageCreate {
|
|
|
657
898
|
*/
|
|
658
899
|
type?: 'message' | null;
|
|
659
900
|
}
|
|
901
|
+
export interface OpenAIModelSettings {
|
|
902
|
+
/**
|
|
903
|
+
* The maximum number of tokens the model can generate.
|
|
904
|
+
*/
|
|
905
|
+
max_output_tokens?: number;
|
|
906
|
+
/**
|
|
907
|
+
* Whether to enable parallel tool calling.
|
|
908
|
+
*/
|
|
909
|
+
parallel_tool_calls?: boolean;
|
|
910
|
+
/**
|
|
911
|
+
* The type of the provider.
|
|
912
|
+
*/
|
|
913
|
+
provider_type?: 'openai';
|
|
914
|
+
/**
|
|
915
|
+
* The reasoning configuration for the model.
|
|
916
|
+
*/
|
|
917
|
+
reasoning?: OpenAIModelSettings.Reasoning;
|
|
918
|
+
/**
|
|
919
|
+
* The response format for the model.
|
|
920
|
+
*/
|
|
921
|
+
response_format?: TextResponseFormat | JsonSchemaResponseFormat | JsonObjectResponseFormat | null;
|
|
922
|
+
/**
|
|
923
|
+
* The temperature of the model.
|
|
924
|
+
*/
|
|
925
|
+
temperature?: number;
|
|
926
|
+
}
|
|
927
|
+
export declare namespace OpenAIModelSettings {
|
|
928
|
+
/**
|
|
929
|
+
* The reasoning configuration for the model.
|
|
930
|
+
*/
|
|
931
|
+
interface Reasoning {
|
|
932
|
+
/**
|
|
933
|
+
* The reasoning effort to use when generating text reasoning models
|
|
934
|
+
*/
|
|
935
|
+
reasoning_effort?: 'none' | 'minimal' | 'low' | 'medium' | 'high';
|
|
936
|
+
}
|
|
937
|
+
}
|
|
660
938
|
/**
|
|
661
939
|
* A ToolRule that only allows a child tool to be called if the parent has been
|
|
662
940
|
* called.
|
|
@@ -731,9 +1009,57 @@ export interface TextResponseFormat {
|
|
|
731
1009
|
*/
|
|
732
1010
|
type?: 'text';
|
|
733
1011
|
}
|
|
734
|
-
|
|
1012
|
+
/**
|
|
1013
|
+
* Together AI model configuration (OpenAI-compatible).
|
|
1014
|
+
*/
|
|
1015
|
+
export interface TogetherModelSettings {
|
|
1016
|
+
/**
|
|
1017
|
+
* The maximum number of tokens the model can generate.
|
|
1018
|
+
*/
|
|
1019
|
+
max_output_tokens?: number;
|
|
1020
|
+
/**
|
|
1021
|
+
* Whether to enable parallel tool calling.
|
|
1022
|
+
*/
|
|
1023
|
+
parallel_tool_calls?: boolean;
|
|
1024
|
+
/**
|
|
1025
|
+
* The type of the provider.
|
|
1026
|
+
*/
|
|
1027
|
+
provider_type?: 'together';
|
|
1028
|
+
/**
|
|
1029
|
+
* The response format for the model.
|
|
1030
|
+
*/
|
|
1031
|
+
response_format?: TextResponseFormat | JsonSchemaResponseFormat | JsonObjectResponseFormat | null;
|
|
1032
|
+
/**
|
|
1033
|
+
* The temperature of the model.
|
|
1034
|
+
*/
|
|
1035
|
+
temperature?: number;
|
|
1036
|
+
}
|
|
1037
|
+
/**
|
|
1038
|
+
* xAI model configuration (OpenAI-compatible).
|
|
1039
|
+
*/
|
|
1040
|
+
export interface XaiModelSettings {
|
|
1041
|
+
/**
|
|
1042
|
+
* The maximum number of tokens the model can generate.
|
|
1043
|
+
*/
|
|
1044
|
+
max_output_tokens?: number;
|
|
1045
|
+
/**
|
|
1046
|
+
* Whether to enable parallel tool calling.
|
|
1047
|
+
*/
|
|
1048
|
+
parallel_tool_calls?: boolean;
|
|
1049
|
+
/**
|
|
1050
|
+
* The type of the provider.
|
|
1051
|
+
*/
|
|
1052
|
+
provider_type?: 'xai';
|
|
1053
|
+
/**
|
|
1054
|
+
* The response format for the model.
|
|
1055
|
+
*/
|
|
1056
|
+
response_format?: TextResponseFormat | JsonSchemaResponseFormat | JsonObjectResponseFormat | null;
|
|
1057
|
+
/**
|
|
1058
|
+
* The temperature of the model.
|
|
1059
|
+
*/
|
|
1060
|
+
temperature?: number;
|
|
1061
|
+
}
|
|
735
1062
|
export type AgentDeleteResponse = unknown;
|
|
736
|
-
export type AgentCountResponse = number;
|
|
737
1063
|
export type AgentExportFileResponse = string;
|
|
738
1064
|
/**
|
|
739
1065
|
* Response model for imported agents
|
|
@@ -746,216 +1072,228 @@ export interface AgentImportFileResponse {
|
|
|
746
1072
|
}
|
|
747
1073
|
export interface AgentCreateParams {
|
|
748
1074
|
/**
|
|
749
|
-
*
|
|
1075
|
+
* The type of agent.
|
|
750
1076
|
*/
|
|
751
1077
|
agent_type?: AgentType;
|
|
752
1078
|
/**
|
|
753
|
-
*
|
|
1079
|
+
* @deprecated Deprecated: No longer used. The base template id of the agent.
|
|
754
1080
|
*/
|
|
755
1081
|
base_template_id?: string | null;
|
|
756
1082
|
/**
|
|
757
|
-
*
|
|
1083
|
+
* The ids of the blocks used by the agent.
|
|
758
1084
|
*/
|
|
759
1085
|
block_ids?: Array<string> | null;
|
|
760
1086
|
/**
|
|
761
|
-
*
|
|
1087
|
+
* The context window limit used by the agent.
|
|
762
1088
|
*/
|
|
763
1089
|
context_window_limit?: number | null;
|
|
764
1090
|
/**
|
|
765
|
-
*
|
|
1091
|
+
* The description of the agent.
|
|
766
1092
|
*/
|
|
767
1093
|
description?: string | null;
|
|
768
1094
|
/**
|
|
769
|
-
*
|
|
770
|
-
* the format provider/model-name.
|
|
1095
|
+
* The embedding model handle used by the agent (format: provider/model-name).
|
|
771
1096
|
*/
|
|
772
1097
|
embedding?: string | null;
|
|
773
1098
|
/**
|
|
774
|
-
*
|
|
1099
|
+
* @deprecated Deprecated: No longer used. The embedding chunk size used by the
|
|
1100
|
+
* agent.
|
|
775
1101
|
*/
|
|
776
1102
|
embedding_chunk_size?: number | null;
|
|
777
1103
|
/**
|
|
778
|
-
*
|
|
779
|
-
* parameters.
|
|
1104
|
+
* Configuration for embedding model connection and processing parameters.
|
|
780
1105
|
*/
|
|
781
1106
|
embedding_config?: ModelsAPI.EmbeddingConfig | null;
|
|
782
1107
|
/**
|
|
783
|
-
*
|
|
784
|
-
* model.
|
|
1108
|
+
* @deprecated Deprecated: Use `model` field to configure reasoning instead.
|
|
1109
|
+
* Whether to enable internal extended thinking step for a reasoner model.
|
|
785
1110
|
*/
|
|
786
1111
|
enable_reasoner?: boolean | null;
|
|
787
1112
|
/**
|
|
788
|
-
*
|
|
789
|
-
* thread.
|
|
1113
|
+
* If set to True, memory management will move to a background agent thread.
|
|
790
1114
|
*/
|
|
791
1115
|
enable_sleeptime?: boolean | null;
|
|
792
1116
|
/**
|
|
793
|
-
*
|
|
1117
|
+
* The ids of the folders used by the agent.
|
|
1118
|
+
*/
|
|
1119
|
+
folder_ids?: Array<string> | null;
|
|
1120
|
+
/**
|
|
1121
|
+
* @deprecated Deprecated: please use the 'create agents from a template' endpoint
|
|
794
1122
|
* instead.
|
|
795
1123
|
*/
|
|
796
1124
|
from_template?: string | null;
|
|
797
1125
|
/**
|
|
798
|
-
*
|
|
1126
|
+
* @deprecated Deprecated: No longer used. If set to True, the agent will be
|
|
1127
|
+
* hidden.
|
|
799
1128
|
*/
|
|
800
1129
|
hidden?: boolean | null;
|
|
801
1130
|
/**
|
|
802
|
-
*
|
|
1131
|
+
* The ids of the identities associated with this agent.
|
|
803
1132
|
*/
|
|
804
1133
|
identity_ids?: Array<string> | null;
|
|
805
1134
|
/**
|
|
806
|
-
*
|
|
807
|
-
*
|
|
1135
|
+
* If true, attaches the Letta base tool rules (e.g. deny all tools not explicitly
|
|
1136
|
+
* allowed).
|
|
808
1137
|
*/
|
|
809
1138
|
include_base_tool_rules?: boolean | null;
|
|
810
1139
|
/**
|
|
811
|
-
*
|
|
812
|
-
* functions).
|
|
1140
|
+
* If true, attaches the Letta core tools (e.g. core_memory related functions).
|
|
813
1141
|
*/
|
|
814
1142
|
include_base_tools?: boolean;
|
|
815
1143
|
/**
|
|
816
|
-
*
|
|
1144
|
+
* @deprecated If true, automatically creates and attaches a default data source
|
|
817
1145
|
* for this agent.
|
|
818
1146
|
*/
|
|
819
1147
|
include_default_source?: boolean;
|
|
820
1148
|
/**
|
|
821
|
-
*
|
|
822
|
-
*
|
|
1149
|
+
* If true, attaches the Letta multi-agent tools (e.g. sending a message to another
|
|
1150
|
+
* agent).
|
|
823
1151
|
*/
|
|
824
1152
|
include_multi_agent_tools?: boolean;
|
|
825
1153
|
/**
|
|
826
|
-
*
|
|
1154
|
+
* The initial set of messages to put in the agent's in-context memory.
|
|
827
1155
|
*/
|
|
828
1156
|
initial_message_sequence?: Array<MessageCreate> | null;
|
|
829
1157
|
/**
|
|
830
|
-
*
|
|
831
|
-
*
|
|
1158
|
+
* Configuration for Language Model (LLM) connection and generation parameters.
|
|
1159
|
+
*
|
|
1160
|
+
* .. deprecated:: LLMConfig is deprecated and should not be used as an input or
|
|
1161
|
+
* return type in API calls. Use the schemas in letta.schemas.model (ModelSettings,
|
|
1162
|
+
* OpenAIModelSettings, etc.) instead. For conversion, use the \_to_model() method
|
|
1163
|
+
* or Model.\_from_llm_config() method.
|
|
832
1164
|
*/
|
|
833
1165
|
llm_config?: ModelsAPI.LlmConfig | null;
|
|
834
1166
|
/**
|
|
835
|
-
*
|
|
836
|
-
*
|
|
1167
|
+
* Maximum number of files that can be open at once for this agent. Setting this
|
|
1168
|
+
* too high may exceed the context window, which will break the agent.
|
|
837
1169
|
*/
|
|
838
1170
|
max_files_open?: number | null;
|
|
839
1171
|
/**
|
|
840
|
-
*
|
|
841
|
-
*
|
|
1172
|
+
* @deprecated Deprecated: Use `model` field to configure reasoning tokens instead.
|
|
1173
|
+
* The maximum number of tokens to generate for reasoning step.
|
|
842
1174
|
*/
|
|
843
1175
|
max_reasoning_tokens?: number | null;
|
|
844
1176
|
/**
|
|
845
|
-
*
|
|
846
|
-
*
|
|
1177
|
+
* @deprecated Deprecated: Use `model` field to configure max output tokens
|
|
1178
|
+
* instead. The maximum number of tokens to generate, including reasoning step.
|
|
847
1179
|
*/
|
|
848
1180
|
max_tokens?: number | null;
|
|
849
1181
|
/**
|
|
850
|
-
*
|
|
1182
|
+
* The blocks to create in the agent's in-context memory.
|
|
851
1183
|
*/
|
|
852
1184
|
memory_blocks?: Array<BlocksBlocksAPI.CreateBlock> | null;
|
|
853
1185
|
/**
|
|
854
|
-
*
|
|
1186
|
+
* @deprecated Deprecated: Only relevant for creating agents from a template. Use
|
|
1187
|
+
* the 'create agents from a template' endpoint instead.
|
|
855
1188
|
*/
|
|
856
1189
|
memory_variables?: {
|
|
857
1190
|
[key: string]: string;
|
|
858
1191
|
} | null;
|
|
859
1192
|
/**
|
|
860
|
-
*
|
|
861
|
-
*
|
|
862
|
-
*
|
|
1193
|
+
* If set to True, the agent will not remember previous messages (though the agent
|
|
1194
|
+
* will still retain state via core memory blocks and archival/recall memory). Not
|
|
1195
|
+
* recommended unless you have an advanced use case.
|
|
863
1196
|
*/
|
|
864
1197
|
message_buffer_autoclear?: boolean;
|
|
865
1198
|
/**
|
|
866
|
-
*
|
|
1199
|
+
* The metadata of the agent.
|
|
867
1200
|
*/
|
|
868
1201
|
metadata?: {
|
|
869
1202
|
[key: string]: unknown;
|
|
870
1203
|
} | null;
|
|
871
1204
|
/**
|
|
872
|
-
*
|
|
873
|
-
* format provider/model-name, as an alternative to specifying llm_config.
|
|
1205
|
+
* The model handle for the agent to use (format: provider/model-name).
|
|
874
1206
|
*/
|
|
875
1207
|
model?: string | null;
|
|
876
1208
|
/**
|
|
877
|
-
*
|
|
1209
|
+
* The model settings for the agent.
|
|
1210
|
+
*/
|
|
1211
|
+
model_settings?: OpenAIModelSettings | AnthropicModelSettings | GoogleAIModelSettings | GoogleVertexModelSettings | AzureModelSettings | XaiModelSettings | GroqModelSettings | DeepseekModelSettings | TogetherModelSettings | BedrockModelSettings | null;
|
|
1212
|
+
/**
|
|
1213
|
+
* The name of the agent.
|
|
878
1214
|
*/
|
|
879
1215
|
name?: string;
|
|
880
1216
|
/**
|
|
881
|
-
*
|
|
1217
|
+
* @deprecated Deprecated: Use `model` field to configure parallel tool calls
|
|
1218
|
+
* instead. If set to True, enables parallel tool calling.
|
|
882
1219
|
*/
|
|
883
1220
|
parallel_tool_calls?: boolean | null;
|
|
884
1221
|
/**
|
|
885
|
-
*
|
|
886
|
-
*
|
|
1222
|
+
* The per-file view window character limit for this agent. Setting this too high
|
|
1223
|
+
* may exceed the context window, which will break the agent.
|
|
887
1224
|
*/
|
|
888
1225
|
per_file_view_window_char_limit?: number | null;
|
|
889
1226
|
/**
|
|
890
|
-
* @deprecated
|
|
891
|
-
*
|
|
892
|
-
*
|
|
1227
|
+
* @deprecated Deprecated: Project should now be passed via the X-Project header
|
|
1228
|
+
* instead of in the request body. If using the SDK, this can be done via the
|
|
1229
|
+
* x_project parameter.
|
|
893
1230
|
*/
|
|
894
1231
|
project?: string | null;
|
|
895
1232
|
/**
|
|
896
|
-
*
|
|
1233
|
+
* @deprecated Deprecated: No longer used. The id of the project the agent belongs
|
|
1234
|
+
* to.
|
|
897
1235
|
*/
|
|
898
1236
|
project_id?: string | null;
|
|
899
1237
|
/**
|
|
900
|
-
*
|
|
1238
|
+
* @deprecated Deprecated: Use `model` field to configure reasoning instead.
|
|
1239
|
+
* Whether to enable reasoning for this agent.
|
|
901
1240
|
*/
|
|
902
1241
|
reasoning?: boolean | null;
|
|
903
1242
|
/**
|
|
904
|
-
*
|
|
1243
|
+
* The response format for the agent.
|
|
905
1244
|
*/
|
|
906
1245
|
response_format?: TextResponseFormat | JsonSchemaResponseFormat | JsonObjectResponseFormat | null;
|
|
907
1246
|
/**
|
|
908
|
-
*
|
|
1247
|
+
* The environment variables for tool execution specific to this agent.
|
|
909
1248
|
*/
|
|
910
1249
|
secrets?: {
|
|
911
1250
|
[key: string]: string;
|
|
912
1251
|
} | null;
|
|
913
1252
|
/**
|
|
914
|
-
*
|
|
1253
|
+
* @deprecated Deprecated: Use `folder_ids` field instead. The ids of the sources
|
|
1254
|
+
* used by the agent.
|
|
915
1255
|
*/
|
|
916
1256
|
source_ids?: Array<string> | null;
|
|
917
1257
|
/**
|
|
918
|
-
*
|
|
1258
|
+
* The system prompt used by the agent.
|
|
919
1259
|
*/
|
|
920
1260
|
system?: string | null;
|
|
921
1261
|
/**
|
|
922
|
-
*
|
|
1262
|
+
* The tags associated with the agent.
|
|
923
1263
|
*/
|
|
924
1264
|
tags?: Array<string> | null;
|
|
925
1265
|
/**
|
|
926
|
-
*
|
|
1266
|
+
* @deprecated Deprecated: No longer used.
|
|
927
1267
|
*/
|
|
928
1268
|
template?: boolean;
|
|
929
1269
|
/**
|
|
930
|
-
*
|
|
1270
|
+
* @deprecated Deprecated: No longer used. The id of the template the agent belongs
|
|
1271
|
+
* to.
|
|
931
1272
|
*/
|
|
932
1273
|
template_id?: string | null;
|
|
933
1274
|
/**
|
|
934
|
-
*
|
|
1275
|
+
* The timezone of the agent (IANA format).
|
|
935
1276
|
*/
|
|
936
1277
|
timezone?: string | null;
|
|
937
1278
|
/**
|
|
938
|
-
*
|
|
1279
|
+
* @deprecated Deprecated: Use `secrets` field instead. Environment variables for
|
|
1280
|
+
* tool execution.
|
|
939
1281
|
*/
|
|
940
1282
|
tool_exec_environment_variables?: {
|
|
941
1283
|
[key: string]: string;
|
|
942
1284
|
} | null;
|
|
943
1285
|
/**
|
|
944
|
-
*
|
|
1286
|
+
* The ids of the tools used by the agent.
|
|
945
1287
|
*/
|
|
946
1288
|
tool_ids?: Array<string> | null;
|
|
947
1289
|
/**
|
|
948
|
-
*
|
|
1290
|
+
* The tool rules governing the agent.
|
|
949
1291
|
*/
|
|
950
1292
|
tool_rules?: Array<ChildToolRule | InitToolRule | TerminalToolRule | ConditionalToolRule | ContinueToolRule | RequiredBeforeExitToolRule | MaxCountPerStepToolRule | ParentToolRule | RequiresApprovalToolRule> | null;
|
|
951
1293
|
/**
|
|
952
|
-
*
|
|
1294
|
+
* The tools used by the agent.
|
|
953
1295
|
*/
|
|
954
1296
|
tools?: Array<string> | null;
|
|
955
|
-
/**
|
|
956
|
-
* Header param: The project slug to associate with the agent (cloud only).
|
|
957
|
-
*/
|
|
958
|
-
'X-Project'?: string;
|
|
959
1297
|
}
|
|
960
1298
|
export interface AgentRetrieveParams {
|
|
961
1299
|
/**
|
|
@@ -989,8 +1327,7 @@ export interface AgentUpdateParams {
|
|
|
989
1327
|
*/
|
|
990
1328
|
description?: string | null;
|
|
991
1329
|
/**
|
|
992
|
-
* The embedding
|
|
993
|
-
* provider/model-name.
|
|
1330
|
+
* The embedding model handle used by the agent (format: provider/model-name).
|
|
994
1331
|
*/
|
|
995
1332
|
embedding?: string | null;
|
|
996
1333
|
/**
|
|
@@ -1001,6 +1338,10 @@ export interface AgentUpdateParams {
|
|
|
1001
1338
|
* If set to True, memory management will move to a background agent thread.
|
|
1002
1339
|
*/
|
|
1003
1340
|
enable_sleeptime?: boolean | null;
|
|
1341
|
+
/**
|
|
1342
|
+
* The ids of the folders used by the agent.
|
|
1343
|
+
*/
|
|
1344
|
+
folder_ids?: Array<string> | null;
|
|
1004
1345
|
/**
|
|
1005
1346
|
* If set to True, the agent will be hidden.
|
|
1006
1347
|
*/
|
|
@@ -1017,8 +1358,17 @@ export interface AgentUpdateParams {
|
|
|
1017
1358
|
* The duration in milliseconds of the agent's last run.
|
|
1018
1359
|
*/
|
|
1019
1360
|
last_run_duration_ms?: number | null;
|
|
1361
|
+
/**
|
|
1362
|
+
* The stop reason from the agent's last run.
|
|
1363
|
+
*/
|
|
1364
|
+
last_stop_reason?: RunsAPI.StopReasonType | null;
|
|
1020
1365
|
/**
|
|
1021
1366
|
* Configuration for Language Model (LLM) connection and generation parameters.
|
|
1367
|
+
*
|
|
1368
|
+
* .. deprecated:: LLMConfig is deprecated and should not be used as an input or
|
|
1369
|
+
* return type in API calls. Use the schemas in letta.schemas.model (ModelSettings,
|
|
1370
|
+
* OpenAIModelSettings, etc.) instead. For conversion, use the \_to_model() method
|
|
1371
|
+
* or Model.\_from_llm_config() method.
|
|
1022
1372
|
*/
|
|
1023
1373
|
llm_config?: ModelsAPI.LlmConfig | null;
|
|
1024
1374
|
/**
|
|
@@ -1027,8 +1377,8 @@ export interface AgentUpdateParams {
|
|
|
1027
1377
|
*/
|
|
1028
1378
|
max_files_open?: number | null;
|
|
1029
1379
|
/**
|
|
1030
|
-
*
|
|
1031
|
-
*
|
|
1380
|
+
* @deprecated Deprecated: Use `model` field to configure max output tokens
|
|
1381
|
+
* instead. The maximum number of tokens to generate, including reasoning step.
|
|
1032
1382
|
*/
|
|
1033
1383
|
max_tokens?: number | null;
|
|
1034
1384
|
/**
|
|
@@ -1048,16 +1398,20 @@ export interface AgentUpdateParams {
|
|
|
1048
1398
|
[key: string]: unknown;
|
|
1049
1399
|
} | null;
|
|
1050
1400
|
/**
|
|
1051
|
-
* The
|
|
1052
|
-
* provider/model-name, as an alternative to specifying llm_config.
|
|
1401
|
+
* The model handle used by the agent (format: provider/model-name).
|
|
1053
1402
|
*/
|
|
1054
1403
|
model?: string | null;
|
|
1404
|
+
/**
|
|
1405
|
+
* The model settings for the agent.
|
|
1406
|
+
*/
|
|
1407
|
+
model_settings?: OpenAIModelSettings | AnthropicModelSettings | GoogleAIModelSettings | GoogleVertexModelSettings | AzureModelSettings | XaiModelSettings | GroqModelSettings | DeepseekModelSettings | TogetherModelSettings | BedrockModelSettings | null;
|
|
1055
1408
|
/**
|
|
1056
1409
|
* The name of the agent.
|
|
1057
1410
|
*/
|
|
1058
1411
|
name?: string | null;
|
|
1059
1412
|
/**
|
|
1060
|
-
*
|
|
1413
|
+
* @deprecated Deprecated: Use `model` field to configure parallel tool calls
|
|
1414
|
+
* instead. If set to True, enables parallel tool calling.
|
|
1061
1415
|
*/
|
|
1062
1416
|
parallel_tool_calls?: boolean | null;
|
|
1063
1417
|
/**
|
|
@@ -1070,10 +1424,12 @@ export interface AgentUpdateParams {
|
|
|
1070
1424
|
*/
|
|
1071
1425
|
project_id?: string | null;
|
|
1072
1426
|
/**
|
|
1427
|
+
* @deprecated Deprecated: Use `model` field to configure reasoning instead.
|
|
1073
1428
|
* Whether to enable reasoning for this agent.
|
|
1074
1429
|
*/
|
|
1075
1430
|
reasoning?: boolean | null;
|
|
1076
1431
|
/**
|
|
1432
|
+
* @deprecated Deprecated: Use `model` field to configure response format instead.
|
|
1077
1433
|
* The response format for the agent.
|
|
1078
1434
|
*/
|
|
1079
1435
|
response_format?: TextResponseFormat | JsonSchemaResponseFormat | JsonObjectResponseFormat | null;
|
|
@@ -1084,7 +1440,8 @@ export interface AgentUpdateParams {
|
|
|
1084
1440
|
[key: string]: string;
|
|
1085
1441
|
} | null;
|
|
1086
1442
|
/**
|
|
1087
|
-
* The ids of the sources
|
|
1443
|
+
* @deprecated Deprecated: Use `folder_ids` field instead. The ids of the sources
|
|
1444
|
+
* used by the agent.
|
|
1088
1445
|
*/
|
|
1089
1446
|
source_ids?: Array<string> | null;
|
|
1090
1447
|
/**
|
|
@@ -1118,11 +1475,7 @@ export interface AgentUpdateParams {
|
|
|
1118
1475
|
*/
|
|
1119
1476
|
tool_rules?: Array<ChildToolRule | InitToolRule | TerminalToolRule | ConditionalToolRule | ContinueToolRule | RequiredBeforeExitToolRule | MaxCountPerStepToolRule | ParentToolRule | RequiresApprovalToolRule> | null;
|
|
1120
1477
|
}
|
|
1121
|
-
export interface AgentListParams {
|
|
1122
|
-
/**
|
|
1123
|
-
* Cursor for pagination
|
|
1124
|
-
*/
|
|
1125
|
-
after?: string | null;
|
|
1478
|
+
export interface AgentListParams extends ArrayPageParams {
|
|
1126
1479
|
/**
|
|
1127
1480
|
* @deprecated Whether to sort agents oldest to newest (True) or newest to oldest
|
|
1128
1481
|
* (False, default)
|
|
@@ -1132,10 +1485,6 @@ export interface AgentListParams {
|
|
|
1132
1485
|
* Search agents by base template ID
|
|
1133
1486
|
*/
|
|
1134
1487
|
base_template_id?: string | null;
|
|
1135
|
-
/**
|
|
1136
|
-
* Cursor for pagination
|
|
1137
|
-
*/
|
|
1138
|
-
before?: string | null;
|
|
1139
1488
|
/**
|
|
1140
1489
|
* Search agents by identifier keys
|
|
1141
1490
|
*/
|
|
@@ -1157,9 +1506,9 @@ export interface AgentListParams {
|
|
|
1157
1506
|
*/
|
|
1158
1507
|
include_relationships?: Array<string> | null;
|
|
1159
1508
|
/**
|
|
1160
|
-
*
|
|
1509
|
+
* Filter agents by their last stop reason.
|
|
1161
1510
|
*/
|
|
1162
|
-
|
|
1511
|
+
last_stop_reason?: RunsAPI.StopReasonType | null;
|
|
1163
1512
|
/**
|
|
1164
1513
|
* If True, only returns agents that match ALL given tags. Otherwise, return agents
|
|
1165
1514
|
* that have ANY of the passed-in tags.
|
|
@@ -1169,15 +1518,6 @@ export interface AgentListParams {
|
|
|
1169
1518
|
* Name of the agent
|
|
1170
1519
|
*/
|
|
1171
1520
|
name?: string | null;
|
|
1172
|
-
/**
|
|
1173
|
-
* Sort order for agents by creation time. 'asc' for oldest first, 'desc' for
|
|
1174
|
-
* newest first
|
|
1175
|
-
*/
|
|
1176
|
-
order?: 'asc' | 'desc';
|
|
1177
|
-
/**
|
|
1178
|
-
* Field to sort by
|
|
1179
|
-
*/
|
|
1180
|
-
order_by?: 'created_at' | 'last_run_completion';
|
|
1181
1521
|
/**
|
|
1182
1522
|
* Search agents by project ID - this will default to your default project on cloud
|
|
1183
1523
|
*/
|
|
@@ -1223,12 +1563,21 @@ export interface AgentImportFileParams {
|
|
|
1223
1563
|
*/
|
|
1224
1564
|
append_copy_suffix?: boolean;
|
|
1225
1565
|
/**
|
|
1226
|
-
* Body param:
|
|
1227
|
-
|
|
1566
|
+
* Body param: Embedding handle to override with.
|
|
1567
|
+
*/
|
|
1568
|
+
embedding?: string | null;
|
|
1569
|
+
/**
|
|
1570
|
+
* @deprecated Body param: Environment variables as a JSON string to pass to the
|
|
1571
|
+
* agent for tool execution. Use 'secrets' instead.
|
|
1228
1572
|
*/
|
|
1229
1573
|
env_vars_json?: string | null;
|
|
1230
1574
|
/**
|
|
1231
|
-
* Body param:
|
|
1575
|
+
* Body param: If provided, overrides the agent name with this value.
|
|
1576
|
+
*/
|
|
1577
|
+
name?: string | null;
|
|
1578
|
+
/**
|
|
1579
|
+
* @deprecated Body param: Override import with specific embedding handle. Use
|
|
1580
|
+
* 'embedding' instead.
|
|
1232
1581
|
*/
|
|
1233
1582
|
override_embedding_handle?: string | null;
|
|
1234
1583
|
/**
|
|
@@ -1238,13 +1587,19 @@ export interface AgentImportFileParams {
|
|
|
1238
1587
|
*/
|
|
1239
1588
|
override_existing_tools?: boolean;
|
|
1240
1589
|
/**
|
|
1241
|
-
* Body param: If provided, overrides the agent name with this value.
|
|
1590
|
+
* @deprecated Body param: If provided, overrides the agent name with this value.
|
|
1591
|
+
* Use 'name' instead.
|
|
1242
1592
|
*/
|
|
1243
1593
|
override_name?: string | null;
|
|
1244
1594
|
/**
|
|
1245
|
-
* Body param: The project ID to associate the uploaded agent with.
|
|
1595
|
+
* @deprecated Body param: The project ID to associate the uploaded agent with.
|
|
1596
|
+
* This is now passed via headers.
|
|
1246
1597
|
*/
|
|
1247
1598
|
project_id?: string | null;
|
|
1599
|
+
/**
|
|
1600
|
+
* Body param: Secrets as a JSON string to pass to the agent for tool execution.
|
|
1601
|
+
*/
|
|
1602
|
+
secrets?: string | null;
|
|
1248
1603
|
/**
|
|
1249
1604
|
* Body param: If set to True, strips all messages from the agent before importing.
|
|
1250
1605
|
*/
|
|
@@ -1255,12 +1610,14 @@ export interface AgentImportFileParams {
|
|
|
1255
1610
|
'x-override-embedding-model'?: string;
|
|
1256
1611
|
}
|
|
1257
1612
|
export declare namespace Agents {
|
|
1258
|
-
export { type AgentEnvironmentVariable as AgentEnvironmentVariable, type AgentState as AgentState, type AgentType as AgentType, type ChildToolRule as ChildToolRule, type ConditionalToolRule as ConditionalToolRule, type ContinueToolRule as ContinueToolRule, type InitToolRule as InitToolRule, type JsonObjectResponseFormat as JsonObjectResponseFormat, type JsonSchemaResponseFormat as JsonSchemaResponseFormat, type LettaMessageContentUnion as LettaMessageContentUnion, type MaxCountPerStepToolRule as MaxCountPerStepToolRule, type MessageCreate as MessageCreate, type ParentToolRule as ParentToolRule, type RequiredBeforeExitToolRule as RequiredBeforeExitToolRule, type RequiresApprovalToolRule as RequiresApprovalToolRule, type TerminalToolRule as TerminalToolRule, type TextResponseFormat as TextResponseFormat, type
|
|
1259
|
-
export {
|
|
1260
|
-
export {
|
|
1261
|
-
export {
|
|
1262
|
-
export {
|
|
1263
|
-
export {
|
|
1264
|
-
export {
|
|
1613
|
+
export { type AgentEnvironmentVariable as AgentEnvironmentVariable, type AgentState as AgentState, type AgentType as AgentType, type AnthropicModelSettings as AnthropicModelSettings, type AzureModelSettings as AzureModelSettings, type BedrockModelSettings as BedrockModelSettings, type ChildToolRule as ChildToolRule, type ConditionalToolRule as ConditionalToolRule, type ContinueToolRule as ContinueToolRule, type DeepseekModelSettings as DeepseekModelSettings, type GoogleAIModelSettings as GoogleAIModelSettings, type GoogleVertexModelSettings as GoogleVertexModelSettings, type GroqModelSettings as GroqModelSettings, type InitToolRule as InitToolRule, type JsonObjectResponseFormat as JsonObjectResponseFormat, type JsonSchemaResponseFormat as JsonSchemaResponseFormat, type LettaMessageContentUnion as LettaMessageContentUnion, type MaxCountPerStepToolRule as MaxCountPerStepToolRule, type MessageCreate as MessageCreate, type OpenAIModelSettings as OpenAIModelSettings, type ParentToolRule as ParentToolRule, type RequiredBeforeExitToolRule as RequiredBeforeExitToolRule, type RequiresApprovalToolRule as RequiresApprovalToolRule, type TerminalToolRule as TerminalToolRule, type TextResponseFormat as TextResponseFormat, type TogetherModelSettings as TogetherModelSettings, type XaiModelSettings as XaiModelSettings, type AgentDeleteResponse as AgentDeleteResponse, type AgentExportFileResponse as AgentExportFileResponse, type AgentImportFileResponse as AgentImportFileResponse, type AgentStatesArrayPage as AgentStatesArrayPage, type AgentCreateParams as AgentCreateParams, type AgentRetrieveParams as AgentRetrieveParams, type AgentUpdateParams as AgentUpdateParams, type AgentListParams as AgentListParams, type AgentExportFileParams as AgentExportFileParams, type AgentImportFileParams as AgentImportFileParams, };
|
|
1614
|
+
export { Messages as Messages, type ApprovalCreate as ApprovalCreate, type ApprovalRequestMessage as ApprovalRequestMessage, type ApprovalResponseMessage as ApprovalResponseMessage, type ApprovalReturn as ApprovalReturn, type AssistantMessage as AssistantMessage, type EventMessage as EventMessage, type HiddenReasoningMessage as HiddenReasoningMessage, type ImageContent as ImageContent, type InternalMessage as InternalMessage, type JobStatus as JobStatus, type JobType as JobType, type LettaAssistantMessageContentUnion as LettaAssistantMessageContentUnion, type LettaRequest as LettaRequest, type LettaResponse as LettaResponse, type LettaStreamingRequest as LettaStreamingRequest, type LettaStreamingResponse as LettaStreamingResponse, type LettaUserMessageContentUnion as LettaUserMessageContentUnion, type Message as Message, type MessageRole as MessageRole, type MessageType as MessageType, type OmittedReasoningContent as OmittedReasoningContent, type ReasoningContent as ReasoningContent, type ReasoningMessage as ReasoningMessage, type RedactedReasoningContent as RedactedReasoningContent, type Run as Run, type SummaryMessage as SummaryMessage, type SystemMessage as SystemMessage, type TextContent as TextContent, type ToolCall as ToolCall, type ToolCallContent as ToolCallContent, type ToolCallDelta as ToolCallDelta, type ToolCallMessage as ToolCallMessage, type ToolReturn as ToolReturn, type ToolReturnContent as ToolReturnContent, type UpdateAssistantMessage as UpdateAssistantMessage, type UpdateReasoningMessage as UpdateReasoningMessage, type UpdateSystemMessage as UpdateSystemMessage, type UpdateUserMessage as UpdateUserMessage, type UserMessage as UserMessage, type MessageCancelResponse as MessageCancelResponse, type MessagesArrayPage as MessagesArrayPage, type MessageCreateParams as MessageCreateParams, type MessageCreateParamsNonStreaming as MessageCreateParamsNonStreaming, type MessageCreateParamsStreaming as MessageCreateParamsStreaming, type MessageListParams as MessageListParams, type MessageCancelParams as MessageCancelParams, type MessageCreateAsyncParams as MessageCreateAsyncParams, type MessageResetParams as MessageResetParams, type MessageStreamParams as MessageStreamParams, };
|
|
1615
|
+
export { Blocks as Blocks, type Block as Block, type BlockUpdate as BlockUpdate, type BlockRetrieveParams as BlockRetrieveParams, type BlockUpdateParams as BlockUpdateParams, type BlockListParams as BlockListParams, type BlockAttachParams as BlockAttachParams, type BlockDetachParams as BlockDetachParams, };
|
|
1616
|
+
export { Tools as Tools, type ToolListParams as ToolListParams, type ToolAttachParams as ToolAttachParams, type ToolDetachParams as ToolDetachParams, type ToolUpdateApprovalParams as ToolUpdateApprovalParams, };
|
|
1617
|
+
export { Folders as Folders, type FolderListResponse as FolderListResponse, type FolderListResponsesArrayPage as FolderListResponsesArrayPage, type FolderListParams as FolderListParams, type FolderAttachParams as FolderAttachParams, type FolderDetachParams as FolderDetachParams, };
|
|
1618
|
+
export { Files as Files, type FileListResponse as FileListResponse, type FileCloseResponse as FileCloseResponse, type FileCloseAllResponse as FileCloseAllResponse, type FileOpenResponse as FileOpenResponse, type FileListResponsesNextFilesPage as FileListResponsesNextFilesPage, type FileListParams as FileListParams, type FileCloseParams as FileCloseParams, type FileOpenParams as FileOpenParams, };
|
|
1619
|
+
export { Groups as Groups, type GroupListParams as GroupListParams };
|
|
1620
|
+
export { Archives as Archives, type ArchiveAttachResponse as ArchiveAttachResponse, type ArchiveDetachResponse as ArchiveDetachResponse, type ArchiveAttachParams as ArchiveAttachParams, type ArchiveDetachParams as ArchiveDetachParams, };
|
|
1621
|
+
export { Identities as Identities, type IdentityAttachResponse as IdentityAttachResponse, type IdentityDetachResponse as IdentityDetachResponse, type IdentityAttachParams as IdentityAttachParams, type IdentityDetachParams as IdentityDetachParams, };
|
|
1265
1622
|
}
|
|
1266
1623
|
//# sourceMappingURL=agents.d.mts.map
|