letta-client 0.1.318__py3-none-any.whl → 0.1.320__py3-none-any.whl
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.
Potentially problematic release.
This version of letta-client might be problematic. Click here for more details.
- letta_client/__init__.py +51 -9
- letta_client/agents/__init__.py +6 -2
- letta_client/agents/client.py +50 -213
- letta_client/agents/files/client.py +51 -6
- letta_client/agents/files/raw_client.py +94 -9
- letta_client/agents/messages/__init__.py +2 -2
- letta_client/agents/messages/client.py +116 -26
- letta_client/agents/messages/raw_client.py +121 -19
- letta_client/agents/messages/types/__init__.py +2 -2
- letta_client/agents/messages/types/{messages_preview_raw_payload_request.py → messages_preview_request.py} +1 -1
- letta_client/agents/raw_client.py +50 -253
- letta_client/agents/types/__init__.py +4 -0
- letta_client/agents/types/agents_list_request_order.py +5 -0
- letta_client/agents/types/agents_list_request_order_by.py +5 -0
- letta_client/archives/__init__.py +7 -0
- letta_client/archives/client.py +362 -0
- letta_client/archives/raw_client.py +448 -0
- letta_client/archives/types/__init__.py +7 -0
- letta_client/archives/types/list_archives_request_order.py +5 -0
- letta_client/base_client.py +3 -6
- letta_client/batches/__init__.py +5 -0
- letta_client/batches/client.py +68 -8
- letta_client/batches/messages/__init__.py +7 -0
- letta_client/{messages → batches/messages}/client.py +50 -43
- letta_client/{messages → batches/messages}/raw_client.py +52 -45
- letta_client/batches/messages/types/__init__.py +7 -0
- letta_client/batches/messages/types/messages_list_request_order.py +5 -0
- letta_client/batches/raw_client.py +71 -6
- letta_client/batches/types/__init__.py +7 -0
- letta_client/batches/types/batches_list_request_order.py +5 -0
- letta_client/blocks/__init__.py +3 -1
- letta_client/blocks/agents/__init__.py +3 -0
- letta_client/blocks/agents/client.py +57 -2
- letta_client/blocks/agents/raw_client.py +51 -0
- letta_client/blocks/agents/types/__init__.py +7 -0
- letta_client/blocks/agents/types/agents_list_request_order.py +5 -0
- letta_client/blocks/client.py +25 -4
- letta_client/blocks/raw_client.py +25 -4
- letta_client/blocks/types/__init__.py +7 -0
- letta_client/blocks/types/blocks_list_request_order.py +5 -0
- letta_client/core/client_wrapper.py +2 -2
- letta_client/errors/__init__.py +9 -1
- letta_client/errors/internal_server_error.py +10 -0
- letta_client/folders/__init__.py +14 -2
- letta_client/folders/agents/__init__.py +7 -0
- letta_client/folders/agents/client.py +176 -0
- letta_client/folders/agents/raw_client.py +182 -0
- letta_client/folders/agents/types/__init__.py +7 -0
- letta_client/folders/agents/types/agents_list_request_order.py +5 -0
- letta_client/folders/client.py +96 -86
- letta_client/folders/files/__init__.py +3 -0
- letta_client/folders/files/client.py +49 -10
- letta_client/folders/files/raw_client.py +41 -10
- letta_client/folders/files/types/__init__.py +7 -0
- letta_client/folders/files/types/files_list_request_order.py +5 -0
- letta_client/folders/passages/__init__.py +3 -0
- letta_client/folders/passages/client.py +43 -14
- letta_client/folders/passages/raw_client.py +35 -14
- letta_client/folders/passages/types/__init__.py +7 -0
- letta_client/folders/passages/types/passages_list_request_order.py +5 -0
- letta_client/folders/raw_client.py +83 -104
- letta_client/folders/types/__init__.py +7 -0
- letta_client/folders/types/folders_list_request_order.py +5 -0
- letta_client/groups/__init__.py +4 -2
- letta_client/groups/client.py +27 -6
- letta_client/groups/messages/__init__.py +2 -2
- letta_client/groups/messages/client.py +39 -18
- letta_client/groups/messages/raw_client.py +35 -14
- letta_client/groups/messages/types/__init__.py +2 -1
- letta_client/groups/messages/types/messages_list_request_order.py +5 -0
- letta_client/groups/raw_client.py +27 -6
- letta_client/groups/types/__init__.py +2 -1
- letta_client/groups/types/groups_list_request_order.py +5 -0
- letta_client/identities/__init__.py +12 -2
- letta_client/identities/agents/__init__.py +7 -0
- letta_client/identities/agents/client.py +177 -0
- letta_client/identities/agents/raw_client.py +183 -0
- letta_client/identities/agents/types/__init__.py +7 -0
- letta_client/identities/agents/types/agents_list_request_order.py +5 -0
- letta_client/identities/blocks/__init__.py +7 -0
- letta_client/identities/blocks/client.py +177 -0
- letta_client/identities/blocks/raw_client.py +183 -0
- letta_client/identities/blocks/types/__init__.py +7 -0
- letta_client/identities/blocks/types/blocks_list_request_order.py +5 -0
- letta_client/identities/client.py +37 -0
- letta_client/identities/raw_client.py +27 -0
- letta_client/identities/types/__init__.py +7 -0
- letta_client/identities/types/identities_list_request_order.py +5 -0
- letta_client/jobs/client.py +10 -2
- letta_client/jobs/raw_client.py +10 -2
- letta_client/models/__init__.py +3 -0
- letta_client/models/client.py +3 -0
- letta_client/{embedding_models → models/embeddings}/client.py +14 -14
- letta_client/{embedding_models → models/embeddings}/raw_client.py +10 -10
- letta_client/providers/__init__.py +3 -0
- letta_client/providers/client.py +151 -82
- letta_client/providers/raw_client.py +165 -72
- letta_client/providers/types/__init__.py +7 -0
- letta_client/providers/types/providers_list_request_order.py +5 -0
- letta_client/runs/__init__.py +2 -1
- letta_client/runs/client.py +21 -0
- letta_client/runs/messages/__init__.py +3 -0
- letta_client/runs/messages/client.py +15 -49
- letta_client/runs/messages/raw_client.py +13 -49
- letta_client/runs/messages/types/__init__.py +7 -0
- letta_client/runs/messages/types/messages_list_request_order.py +5 -0
- letta_client/runs/raw_client.py +21 -0
- letta_client/steps/__init__.py +13 -3
- letta_client/steps/client.py +32 -83
- letta_client/steps/feedback/client.py +21 -6
- letta_client/steps/feedback/raw_client.py +29 -6
- letta_client/steps/messages/__init__.py +7 -0
- letta_client/steps/messages/client.py +177 -0
- letta_client/steps/messages/raw_client.py +183 -0
- letta_client/steps/messages/types/__init__.py +8 -0
- letta_client/steps/messages/types/messages_list_request_order.py +5 -0
- letta_client/steps/messages/types/messages_list_response_item.py +25 -0
- letta_client/steps/metrics/client.py +110 -0
- letta_client/steps/metrics/raw_client.py +122 -0
- letta_client/steps/raw_client.py +17 -107
- letta_client/steps/trace/__init__.py +4 -0
- letta_client/steps/trace/client.py +110 -0
- letta_client/steps/trace/raw_client.py +122 -0
- letta_client/steps/types/__init__.py +2 -1
- letta_client/steps/types/steps_list_request_order.py +5 -0
- letta_client/tags/__init__.py +3 -0
- letta_client/tags/client.py +57 -4
- letta_client/tags/raw_client.py +49 -2
- letta_client/tags/types/__init__.py +7 -0
- letta_client/tags/types/tags_list_request_order.py +5 -0
- letta_client/telemetry/client.py +8 -0
- letta_client/telemetry/raw_client.py +8 -0
- letta_client/templates/__init__.py +64 -0
- letta_client/templates/agents/__init__.py +58 -0
- letta_client/templates/agents/types/__init__.py +66 -0
- letta_client/templates/agents/types/agents_create_response.py +6 -0
- letta_client/templates/agents/types/agents_create_response_group.py +52 -0
- letta_client/templates/agents/types/agents_create_response_group_base_template_id.py +12 -0
- letta_client/templates/agents/types/agents_create_response_group_base_template_id_item.py +5 -0
- letta_client/templates/agents/types/agents_create_response_group_deployment_id.py +12 -0
- letta_client/templates/agents/types/agents_create_response_group_deployment_id_item.py +5 -0
- letta_client/templates/agents/types/agents_create_response_group_hidden.py +12 -0
- letta_client/templates/agents/types/agents_create_response_group_hidden_item.py +5 -0
- letta_client/templates/agents/types/agents_create_response_group_last_processed_message_id.py +14 -0
- letta_client/templates/agents/types/agents_create_response_group_last_processed_message_id_item.py +5 -0
- letta_client/templates/agents/types/agents_create_response_group_manager_agent_id.py +12 -0
- letta_client/templates/agents/types/agents_create_response_group_manager_agent_id_item.py +5 -0
- letta_client/templates/agents/types/agents_create_response_group_manager_type.py +7 -0
- letta_client/templates/agents/types/agents_create_response_group_max_message_buffer_length.py +14 -0
- letta_client/templates/agents/types/agents_create_response_group_max_message_buffer_length_item.py +5 -0
- letta_client/templates/agents/types/agents_create_response_group_max_turns.py +12 -0
- letta_client/templates/agents/types/agents_create_response_group_max_turns_item.py +5 -0
- letta_client/templates/agents/types/agents_create_response_group_min_message_buffer_length.py +14 -0
- letta_client/templates/agents/types/agents_create_response_group_min_message_buffer_length_item.py +5 -0
- letta_client/templates/agents/types/agents_create_response_group_project_id.py +12 -0
- letta_client/templates/agents/types/agents_create_response_group_project_id_item.py +5 -0
- letta_client/templates/agents/types/agents_create_response_group_shared_block_ids.py +5 -0
- letta_client/templates/agents/types/agents_create_response_group_sleeptime_agent_frequency.py +14 -0
- letta_client/templates/agents/types/agents_create_response_group_sleeptime_agent_frequency_item.py +5 -0
- letta_client/templates/agents/types/agents_create_response_group_template_id.py +12 -0
- letta_client/templates/agents/types/agents_create_response_group_template_id_item.py +5 -0
- letta_client/templates/agents/types/agents_create_response_group_termination_token.py +12 -0
- letta_client/templates/agents/types/agents_create_response_group_termination_token_item.py +5 -0
- letta_client/templates/agents/types/agents_create_response_group_turns_counter.py +12 -0
- letta_client/templates/agents/types/agents_create_response_group_turns_counter_item.py +5 -0
- letta_client/templates/client.py +260 -0
- letta_client/templates/raw_client.py +395 -0
- letta_client/templates/types/__init__.py +8 -0
- letta_client/templates/types/templates_get_template_snapshot_response.py +4 -0
- letta_client/templates/types/templates_get_template_snapshot_response_blocks_item.py +1 -0
- letta_client/templates/types/templates_get_template_snapshot_response_relationships_item.py +23 -0
- letta_client/templates/types/templates_migrate_deployment_response.py +21 -0
- letta_client/templates/types/templates_set_current_template_from_snapshot_response.py +21 -0
- letta_client/tools/__init__.py +2 -0
- letta_client/tools/client.py +47 -20
- letta_client/tools/raw_client.py +43 -26
- letta_client/tools/types/__init__.py +2 -0
- letta_client/tools/types/tools_list_request_order.py +5 -0
- letta_client/types/__init__.py +10 -2
- letta_client/types/agent_state.py +5 -0
- letta_client/types/archive.py +77 -0
- letta_client/types/batch_job.py +6 -0
- letta_client/types/{body_export_agent_serialized.py → body_export_agent.py} +1 -1
- letta_client/types/child_tool_rule.py +1 -1
- letta_client/types/conditional_tool_rule.py +1 -1
- letta_client/types/continue_tool_rule.py +1 -1
- letta_client/types/deployment_entity.py +2 -0
- letta_client/types/init_tool_rule.py +1 -1
- letta_client/types/internal_server_error_body.py +20 -0
- letta_client/types/internal_template_agent_create.py +5 -0
- letta_client/types/job.py +6 -0
- letta_client/types/letta_schemas_agent_file_agent_schema.py +5 -0
- letta_client/types/max_count_per_step_tool_rule.py +1 -1
- letta_client/types/memory.py +7 -1
- letta_client/types/memory_agent_type.py +7 -0
- letta_client/types/parent_tool_rule.py +1 -1
- letta_client/types/required_before_exit_tool_rule.py +1 -1
- letta_client/types/requires_approval_tool_rule.py +1 -1
- letta_client/types/run.py +6 -0
- letta_client/types/source.py +6 -0
- letta_client/types/step.py +1 -1
- letta_client/types/stop_reason_type.py +1 -0
- letta_client/types/terminal_tool_rule.py +1 -1
- letta_client/types/vector_db_provider.py +5 -0
- letta_client/voice/client.py +2 -8
- letta_client/voice/raw_client.py +0 -8
- {letta_client-0.1.318.dist-info → letta_client-0.1.320.dist-info}/METADATA +9 -9
- {letta_client-0.1.318.dist-info → letta_client-0.1.320.dist-info}/RECORD +211 -114
- /letta_client/{embedding_models → models/embeddings}/__init__.py +0 -0
- /letta_client/{messages → steps/metrics}/__init__.py +0 -0
- {letta_client-0.1.318.dist-info → letta_client-0.1.320.dist-info}/WHEEL +0 -0
letta_client/tools/client.py
CHANGED
|
@@ -19,6 +19,7 @@ from .types.delete_mcp_server_response_item import DeleteMcpServerResponseItem
|
|
|
19
19
|
from .types.list_mcp_servers_response_value import ListMcpServersResponseValue
|
|
20
20
|
from .types.streaming_response import StreamingResponse
|
|
21
21
|
from .types.test_mcp_server_request import TestMcpServerRequest
|
|
22
|
+
from .types.tools_list_request_order import ToolsListRequestOrder
|
|
22
23
|
from .types.update_mcp_server_request import UpdateMcpServerRequest
|
|
23
24
|
from .types.update_mcp_server_response import UpdateMcpServerResponse
|
|
24
25
|
|
|
@@ -274,8 +275,11 @@ class ToolsClient:
|
|
|
274
275
|
def list(
|
|
275
276
|
self,
|
|
276
277
|
*,
|
|
278
|
+
before: typing.Optional[str] = None,
|
|
277
279
|
after: typing.Optional[str] = None,
|
|
278
280
|
limit: typing.Optional[int] = None,
|
|
281
|
+
order: typing.Optional[ToolsListRequestOrder] = None,
|
|
282
|
+
order_by: typing.Optional[typing.Literal["created_at"]] = None,
|
|
279
283
|
name: typing.Optional[str] = None,
|
|
280
284
|
names: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
|
|
281
285
|
tool_ids: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
|
|
@@ -286,15 +290,27 @@ class ToolsClient:
|
|
|
286
290
|
request_options: typing.Optional[RequestOptions] = None,
|
|
287
291
|
) -> typing.List[Tool]:
|
|
288
292
|
"""
|
|
289
|
-
Get a list of all tools available to agents
|
|
293
|
+
Get a list of all tools available to agents.
|
|
290
294
|
|
|
291
295
|
Parameters
|
|
292
296
|
----------
|
|
297
|
+
before : typing.Optional[str]
|
|
298
|
+
Tool ID cursor for pagination. Returns tools that come before this tool ID in the specified sort order
|
|
299
|
+
|
|
293
300
|
after : typing.Optional[str]
|
|
301
|
+
Tool ID cursor for pagination. Returns tools that come after this tool ID in the specified sort order
|
|
294
302
|
|
|
295
303
|
limit : typing.Optional[int]
|
|
304
|
+
Maximum number of tools to return
|
|
305
|
+
|
|
306
|
+
order : typing.Optional[ToolsListRequestOrder]
|
|
307
|
+
Sort order for tools by creation time. 'asc' for oldest first, 'desc' for newest first
|
|
308
|
+
|
|
309
|
+
order_by : typing.Optional[typing.Literal["created_at"]]
|
|
310
|
+
Field to sort by
|
|
296
311
|
|
|
297
312
|
name : typing.Optional[str]
|
|
313
|
+
Filter by single tool name
|
|
298
314
|
|
|
299
315
|
names : typing.Optional[typing.Union[str, typing.Sequence[str]]]
|
|
300
316
|
Filter by specific tool names
|
|
@@ -333,8 +349,11 @@ class ToolsClient:
|
|
|
333
349
|
client.tools.list()
|
|
334
350
|
"""
|
|
335
351
|
_response = self._raw_client.list(
|
|
352
|
+
before=before,
|
|
336
353
|
after=after,
|
|
337
354
|
limit=limit,
|
|
355
|
+
order=order,
|
|
356
|
+
order_by=order_by,
|
|
338
357
|
name=name,
|
|
339
358
|
names=names,
|
|
340
359
|
tool_ids=tool_ids,
|
|
@@ -624,16 +643,12 @@ class ToolsClient:
|
|
|
624
643
|
)
|
|
625
644
|
return _response.data
|
|
626
645
|
|
|
627
|
-
def list_composio_apps(
|
|
628
|
-
self, *, user_id: typing.Optional[str] = None, request_options: typing.Optional[RequestOptions] = None
|
|
629
|
-
) -> typing.List[AppModel]:
|
|
646
|
+
def list_composio_apps(self, *, request_options: typing.Optional[RequestOptions] = None) -> typing.List[AppModel]:
|
|
630
647
|
"""
|
|
631
648
|
Get a list of all Composio apps
|
|
632
649
|
|
|
633
650
|
Parameters
|
|
634
651
|
----------
|
|
635
|
-
user_id : typing.Optional[str]
|
|
636
|
-
|
|
637
652
|
request_options : typing.Optional[RequestOptions]
|
|
638
653
|
Request-specific configuration.
|
|
639
654
|
|
|
@@ -652,7 +667,7 @@ class ToolsClient:
|
|
|
652
667
|
)
|
|
653
668
|
client.tools.list_composio_apps()
|
|
654
669
|
"""
|
|
655
|
-
_response = self._raw_client.list_composio_apps(
|
|
670
|
+
_response = self._raw_client.list_composio_apps(request_options=request_options)
|
|
656
671
|
return _response.data
|
|
657
672
|
|
|
658
673
|
def list_composio_actions_by_app(
|
|
@@ -722,15 +737,13 @@ class ToolsClient:
|
|
|
722
737
|
return _response.data
|
|
723
738
|
|
|
724
739
|
def list_mcp_servers(
|
|
725
|
-
self, *,
|
|
740
|
+
self, *, request_options: typing.Optional[RequestOptions] = None
|
|
726
741
|
) -> typing.Dict[str, ListMcpServersResponseValue]:
|
|
727
742
|
"""
|
|
728
743
|
Get a list of all configured MCP servers
|
|
729
744
|
|
|
730
745
|
Parameters
|
|
731
746
|
----------
|
|
732
|
-
user_id : typing.Optional[str]
|
|
733
|
-
|
|
734
747
|
request_options : typing.Optional[RequestOptions]
|
|
735
748
|
Request-specific configuration.
|
|
736
749
|
|
|
@@ -749,7 +762,7 @@ class ToolsClient:
|
|
|
749
762
|
)
|
|
750
763
|
client.tools.list_mcp_servers()
|
|
751
764
|
"""
|
|
752
|
-
_response = self._raw_client.list_mcp_servers(
|
|
765
|
+
_response = self._raw_client.list_mcp_servers(request_options=request_options)
|
|
753
766
|
return _response.data
|
|
754
767
|
|
|
755
768
|
def add_mcp_server(
|
|
@@ -1292,8 +1305,11 @@ class AsyncToolsClient:
|
|
|
1292
1305
|
async def list(
|
|
1293
1306
|
self,
|
|
1294
1307
|
*,
|
|
1308
|
+
before: typing.Optional[str] = None,
|
|
1295
1309
|
after: typing.Optional[str] = None,
|
|
1296
1310
|
limit: typing.Optional[int] = None,
|
|
1311
|
+
order: typing.Optional[ToolsListRequestOrder] = None,
|
|
1312
|
+
order_by: typing.Optional[typing.Literal["created_at"]] = None,
|
|
1297
1313
|
name: typing.Optional[str] = None,
|
|
1298
1314
|
names: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
|
|
1299
1315
|
tool_ids: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
|
|
@@ -1304,15 +1320,27 @@ class AsyncToolsClient:
|
|
|
1304
1320
|
request_options: typing.Optional[RequestOptions] = None,
|
|
1305
1321
|
) -> typing.List[Tool]:
|
|
1306
1322
|
"""
|
|
1307
|
-
Get a list of all tools available to agents
|
|
1323
|
+
Get a list of all tools available to agents.
|
|
1308
1324
|
|
|
1309
1325
|
Parameters
|
|
1310
1326
|
----------
|
|
1327
|
+
before : typing.Optional[str]
|
|
1328
|
+
Tool ID cursor for pagination. Returns tools that come before this tool ID in the specified sort order
|
|
1329
|
+
|
|
1311
1330
|
after : typing.Optional[str]
|
|
1331
|
+
Tool ID cursor for pagination. Returns tools that come after this tool ID in the specified sort order
|
|
1312
1332
|
|
|
1313
1333
|
limit : typing.Optional[int]
|
|
1334
|
+
Maximum number of tools to return
|
|
1335
|
+
|
|
1336
|
+
order : typing.Optional[ToolsListRequestOrder]
|
|
1337
|
+
Sort order for tools by creation time. 'asc' for oldest first, 'desc' for newest first
|
|
1338
|
+
|
|
1339
|
+
order_by : typing.Optional[typing.Literal["created_at"]]
|
|
1340
|
+
Field to sort by
|
|
1314
1341
|
|
|
1315
1342
|
name : typing.Optional[str]
|
|
1343
|
+
Filter by single tool name
|
|
1316
1344
|
|
|
1317
1345
|
names : typing.Optional[typing.Union[str, typing.Sequence[str]]]
|
|
1318
1346
|
Filter by specific tool names
|
|
@@ -1359,8 +1387,11 @@ class AsyncToolsClient:
|
|
|
1359
1387
|
asyncio.run(main())
|
|
1360
1388
|
"""
|
|
1361
1389
|
_response = await self._raw_client.list(
|
|
1390
|
+
before=before,
|
|
1362
1391
|
after=after,
|
|
1363
1392
|
limit=limit,
|
|
1393
|
+
order=order,
|
|
1394
|
+
order_by=order_by,
|
|
1364
1395
|
name=name,
|
|
1365
1396
|
names=names,
|
|
1366
1397
|
tool_ids=tool_ids,
|
|
@@ -1683,15 +1714,13 @@ class AsyncToolsClient:
|
|
|
1683
1714
|
return _response.data
|
|
1684
1715
|
|
|
1685
1716
|
async def list_composio_apps(
|
|
1686
|
-
self, *,
|
|
1717
|
+
self, *, request_options: typing.Optional[RequestOptions] = None
|
|
1687
1718
|
) -> typing.List[AppModel]:
|
|
1688
1719
|
"""
|
|
1689
1720
|
Get a list of all Composio apps
|
|
1690
1721
|
|
|
1691
1722
|
Parameters
|
|
1692
1723
|
----------
|
|
1693
|
-
user_id : typing.Optional[str]
|
|
1694
|
-
|
|
1695
1724
|
request_options : typing.Optional[RequestOptions]
|
|
1696
1725
|
Request-specific configuration.
|
|
1697
1726
|
|
|
@@ -1718,7 +1747,7 @@ class AsyncToolsClient:
|
|
|
1718
1747
|
|
|
1719
1748
|
asyncio.run(main())
|
|
1720
1749
|
"""
|
|
1721
|
-
_response = await self._raw_client.list_composio_apps(
|
|
1750
|
+
_response = await self._raw_client.list_composio_apps(request_options=request_options)
|
|
1722
1751
|
return _response.data
|
|
1723
1752
|
|
|
1724
1753
|
async def list_composio_actions_by_app(
|
|
@@ -1806,15 +1835,13 @@ class AsyncToolsClient:
|
|
|
1806
1835
|
return _response.data
|
|
1807
1836
|
|
|
1808
1837
|
async def list_mcp_servers(
|
|
1809
|
-
self, *,
|
|
1838
|
+
self, *, request_options: typing.Optional[RequestOptions] = None
|
|
1810
1839
|
) -> typing.Dict[str, ListMcpServersResponseValue]:
|
|
1811
1840
|
"""
|
|
1812
1841
|
Get a list of all configured MCP servers
|
|
1813
1842
|
|
|
1814
1843
|
Parameters
|
|
1815
1844
|
----------
|
|
1816
|
-
user_id : typing.Optional[str]
|
|
1817
|
-
|
|
1818
1845
|
request_options : typing.Optional[RequestOptions]
|
|
1819
1846
|
Request-specific configuration.
|
|
1820
1847
|
|
|
@@ -1841,7 +1868,7 @@ class AsyncToolsClient:
|
|
|
1841
1868
|
|
|
1842
1869
|
asyncio.run(main())
|
|
1843
1870
|
"""
|
|
1844
|
-
_response = await self._raw_client.list_mcp_servers(
|
|
1871
|
+
_response = await self._raw_client.list_mcp_servers(request_options=request_options)
|
|
1845
1872
|
return _response.data
|
|
1846
1873
|
|
|
1847
1874
|
async def add_mcp_server(
|
letta_client/tools/raw_client.py
CHANGED
|
@@ -29,6 +29,7 @@ from .types.delete_mcp_server_response_item import DeleteMcpServerResponseItem
|
|
|
29
29
|
from .types.list_mcp_servers_response_value import ListMcpServersResponseValue
|
|
30
30
|
from .types.streaming_response import StreamingResponse
|
|
31
31
|
from .types.test_mcp_server_request import TestMcpServerRequest
|
|
32
|
+
from .types.tools_list_request_order import ToolsListRequestOrder
|
|
32
33
|
from .types.update_mcp_server_request import UpdateMcpServerRequest
|
|
33
34
|
from .types.update_mcp_server_response import UpdateMcpServerResponse
|
|
34
35
|
|
|
@@ -348,8 +349,11 @@ class RawToolsClient:
|
|
|
348
349
|
def list(
|
|
349
350
|
self,
|
|
350
351
|
*,
|
|
352
|
+
before: typing.Optional[str] = None,
|
|
351
353
|
after: typing.Optional[str] = None,
|
|
352
354
|
limit: typing.Optional[int] = None,
|
|
355
|
+
order: typing.Optional[ToolsListRequestOrder] = None,
|
|
356
|
+
order_by: typing.Optional[typing.Literal["created_at"]] = None,
|
|
353
357
|
name: typing.Optional[str] = None,
|
|
354
358
|
names: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
|
|
355
359
|
tool_ids: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
|
|
@@ -360,15 +364,27 @@ class RawToolsClient:
|
|
|
360
364
|
request_options: typing.Optional[RequestOptions] = None,
|
|
361
365
|
) -> HttpResponse[typing.List[Tool]]:
|
|
362
366
|
"""
|
|
363
|
-
Get a list of all tools available to agents
|
|
367
|
+
Get a list of all tools available to agents.
|
|
364
368
|
|
|
365
369
|
Parameters
|
|
366
370
|
----------
|
|
371
|
+
before : typing.Optional[str]
|
|
372
|
+
Tool ID cursor for pagination. Returns tools that come before this tool ID in the specified sort order
|
|
373
|
+
|
|
367
374
|
after : typing.Optional[str]
|
|
375
|
+
Tool ID cursor for pagination. Returns tools that come after this tool ID in the specified sort order
|
|
368
376
|
|
|
369
377
|
limit : typing.Optional[int]
|
|
378
|
+
Maximum number of tools to return
|
|
379
|
+
|
|
380
|
+
order : typing.Optional[ToolsListRequestOrder]
|
|
381
|
+
Sort order for tools by creation time. 'asc' for oldest first, 'desc' for newest first
|
|
382
|
+
|
|
383
|
+
order_by : typing.Optional[typing.Literal["created_at"]]
|
|
384
|
+
Field to sort by
|
|
370
385
|
|
|
371
386
|
name : typing.Optional[str]
|
|
387
|
+
Filter by single tool name
|
|
372
388
|
|
|
373
389
|
names : typing.Optional[typing.Union[str, typing.Sequence[str]]]
|
|
374
390
|
Filter by specific tool names
|
|
@@ -400,8 +416,11 @@ class RawToolsClient:
|
|
|
400
416
|
"v1/tools/",
|
|
401
417
|
method="GET",
|
|
402
418
|
params={
|
|
419
|
+
"before": before,
|
|
403
420
|
"after": after,
|
|
404
421
|
"limit": limit,
|
|
422
|
+
"order": order,
|
|
423
|
+
"order_by": order_by,
|
|
405
424
|
"name": name,
|
|
406
425
|
"names": names,
|
|
407
426
|
"tool_ids": tool_ids,
|
|
@@ -808,15 +827,13 @@ class RawToolsClient:
|
|
|
808
827
|
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
|
|
809
828
|
|
|
810
829
|
def list_composio_apps(
|
|
811
|
-
self, *,
|
|
830
|
+
self, *, request_options: typing.Optional[RequestOptions] = None
|
|
812
831
|
) -> HttpResponse[typing.List[AppModel]]:
|
|
813
832
|
"""
|
|
814
833
|
Get a list of all Composio apps
|
|
815
834
|
|
|
816
835
|
Parameters
|
|
817
836
|
----------
|
|
818
|
-
user_id : typing.Optional[str]
|
|
819
|
-
|
|
820
837
|
request_options : typing.Optional[RequestOptions]
|
|
821
838
|
Request-specific configuration.
|
|
822
839
|
|
|
@@ -828,9 +845,6 @@ class RawToolsClient:
|
|
|
828
845
|
_response = self._client_wrapper.httpx_client.request(
|
|
829
846
|
"v1/tools/composio/apps",
|
|
830
847
|
method="GET",
|
|
831
|
-
headers={
|
|
832
|
-
"user-id": str(user_id) if user_id is not None else None,
|
|
833
|
-
},
|
|
834
848
|
request_options=request_options,
|
|
835
849
|
)
|
|
836
850
|
try:
|
|
@@ -958,15 +972,13 @@ class RawToolsClient:
|
|
|
958
972
|
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
|
|
959
973
|
|
|
960
974
|
def list_mcp_servers(
|
|
961
|
-
self, *,
|
|
975
|
+
self, *, request_options: typing.Optional[RequestOptions] = None
|
|
962
976
|
) -> HttpResponse[typing.Dict[str, ListMcpServersResponseValue]]:
|
|
963
977
|
"""
|
|
964
978
|
Get a list of all configured MCP servers
|
|
965
979
|
|
|
966
980
|
Parameters
|
|
967
981
|
----------
|
|
968
|
-
user_id : typing.Optional[str]
|
|
969
|
-
|
|
970
982
|
request_options : typing.Optional[RequestOptions]
|
|
971
983
|
Request-specific configuration.
|
|
972
984
|
|
|
@@ -978,9 +990,6 @@ class RawToolsClient:
|
|
|
978
990
|
_response = self._client_wrapper.httpx_client.request(
|
|
979
991
|
"v1/tools/mcp/servers",
|
|
980
992
|
method="GET",
|
|
981
|
-
headers={
|
|
982
|
-
"user-id": str(user_id) if user_id is not None else None,
|
|
983
|
-
},
|
|
984
993
|
request_options=request_options,
|
|
985
994
|
)
|
|
986
995
|
try:
|
|
@@ -1726,8 +1735,11 @@ class AsyncRawToolsClient:
|
|
|
1726
1735
|
async def list(
|
|
1727
1736
|
self,
|
|
1728
1737
|
*,
|
|
1738
|
+
before: typing.Optional[str] = None,
|
|
1729
1739
|
after: typing.Optional[str] = None,
|
|
1730
1740
|
limit: typing.Optional[int] = None,
|
|
1741
|
+
order: typing.Optional[ToolsListRequestOrder] = None,
|
|
1742
|
+
order_by: typing.Optional[typing.Literal["created_at"]] = None,
|
|
1731
1743
|
name: typing.Optional[str] = None,
|
|
1732
1744
|
names: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
|
|
1733
1745
|
tool_ids: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
|
|
@@ -1738,15 +1750,27 @@ class AsyncRawToolsClient:
|
|
|
1738
1750
|
request_options: typing.Optional[RequestOptions] = None,
|
|
1739
1751
|
) -> AsyncHttpResponse[typing.List[Tool]]:
|
|
1740
1752
|
"""
|
|
1741
|
-
Get a list of all tools available to agents
|
|
1753
|
+
Get a list of all tools available to agents.
|
|
1742
1754
|
|
|
1743
1755
|
Parameters
|
|
1744
1756
|
----------
|
|
1757
|
+
before : typing.Optional[str]
|
|
1758
|
+
Tool ID cursor for pagination. Returns tools that come before this tool ID in the specified sort order
|
|
1759
|
+
|
|
1745
1760
|
after : typing.Optional[str]
|
|
1761
|
+
Tool ID cursor for pagination. Returns tools that come after this tool ID in the specified sort order
|
|
1746
1762
|
|
|
1747
1763
|
limit : typing.Optional[int]
|
|
1764
|
+
Maximum number of tools to return
|
|
1765
|
+
|
|
1766
|
+
order : typing.Optional[ToolsListRequestOrder]
|
|
1767
|
+
Sort order for tools by creation time. 'asc' for oldest first, 'desc' for newest first
|
|
1768
|
+
|
|
1769
|
+
order_by : typing.Optional[typing.Literal["created_at"]]
|
|
1770
|
+
Field to sort by
|
|
1748
1771
|
|
|
1749
1772
|
name : typing.Optional[str]
|
|
1773
|
+
Filter by single tool name
|
|
1750
1774
|
|
|
1751
1775
|
names : typing.Optional[typing.Union[str, typing.Sequence[str]]]
|
|
1752
1776
|
Filter by specific tool names
|
|
@@ -1778,8 +1802,11 @@ class AsyncRawToolsClient:
|
|
|
1778
1802
|
"v1/tools/",
|
|
1779
1803
|
method="GET",
|
|
1780
1804
|
params={
|
|
1805
|
+
"before": before,
|
|
1781
1806
|
"after": after,
|
|
1782
1807
|
"limit": limit,
|
|
1808
|
+
"order": order,
|
|
1809
|
+
"order_by": order_by,
|
|
1783
1810
|
"name": name,
|
|
1784
1811
|
"names": names,
|
|
1785
1812
|
"tool_ids": tool_ids,
|
|
@@ -2186,15 +2213,13 @@ class AsyncRawToolsClient:
|
|
|
2186
2213
|
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
|
|
2187
2214
|
|
|
2188
2215
|
async def list_composio_apps(
|
|
2189
|
-
self, *,
|
|
2216
|
+
self, *, request_options: typing.Optional[RequestOptions] = None
|
|
2190
2217
|
) -> AsyncHttpResponse[typing.List[AppModel]]:
|
|
2191
2218
|
"""
|
|
2192
2219
|
Get a list of all Composio apps
|
|
2193
2220
|
|
|
2194
2221
|
Parameters
|
|
2195
2222
|
----------
|
|
2196
|
-
user_id : typing.Optional[str]
|
|
2197
|
-
|
|
2198
2223
|
request_options : typing.Optional[RequestOptions]
|
|
2199
2224
|
Request-specific configuration.
|
|
2200
2225
|
|
|
@@ -2206,9 +2231,6 @@ class AsyncRawToolsClient:
|
|
|
2206
2231
|
_response = await self._client_wrapper.httpx_client.request(
|
|
2207
2232
|
"v1/tools/composio/apps",
|
|
2208
2233
|
method="GET",
|
|
2209
|
-
headers={
|
|
2210
|
-
"user-id": str(user_id) if user_id is not None else None,
|
|
2211
|
-
},
|
|
2212
2234
|
request_options=request_options,
|
|
2213
2235
|
)
|
|
2214
2236
|
try:
|
|
@@ -2336,15 +2358,13 @@ class AsyncRawToolsClient:
|
|
|
2336
2358
|
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
|
|
2337
2359
|
|
|
2338
2360
|
async def list_mcp_servers(
|
|
2339
|
-
self, *,
|
|
2361
|
+
self, *, request_options: typing.Optional[RequestOptions] = None
|
|
2340
2362
|
) -> AsyncHttpResponse[typing.Dict[str, ListMcpServersResponseValue]]:
|
|
2341
2363
|
"""
|
|
2342
2364
|
Get a list of all configured MCP servers
|
|
2343
2365
|
|
|
2344
2366
|
Parameters
|
|
2345
2367
|
----------
|
|
2346
|
-
user_id : typing.Optional[str]
|
|
2347
|
-
|
|
2348
2368
|
request_options : typing.Optional[RequestOptions]
|
|
2349
2369
|
Request-specific configuration.
|
|
2350
2370
|
|
|
@@ -2356,9 +2376,6 @@ class AsyncRawToolsClient:
|
|
|
2356
2376
|
_response = await self._client_wrapper.httpx_client.request(
|
|
2357
2377
|
"v1/tools/mcp/servers",
|
|
2358
2378
|
method="GET",
|
|
2359
|
-
headers={
|
|
2360
|
-
"user-id": str(user_id) if user_id is not None else None,
|
|
2361
|
-
},
|
|
2362
2379
|
request_options=request_options,
|
|
2363
2380
|
)
|
|
2364
2381
|
try:
|
|
@@ -10,6 +10,7 @@ from .delete_mcp_server_response_item import DeleteMcpServerResponseItem
|
|
|
10
10
|
from .list_mcp_servers_response_value import ListMcpServersResponseValue
|
|
11
11
|
from .streaming_response import StreamingResponse
|
|
12
12
|
from .test_mcp_server_request import TestMcpServerRequest
|
|
13
|
+
from .tools_list_request_order import ToolsListRequestOrder
|
|
13
14
|
from .update_mcp_server_request import UpdateMcpServerRequest
|
|
14
15
|
from .update_mcp_server_response import UpdateMcpServerResponse
|
|
15
16
|
|
|
@@ -22,6 +23,7 @@ __all__ = [
|
|
|
22
23
|
"ListMcpServersResponseValue",
|
|
23
24
|
"StreamingResponse",
|
|
24
25
|
"TestMcpServerRequest",
|
|
26
|
+
"ToolsListRequestOrder",
|
|
25
27
|
"UpdateMcpServerRequest",
|
|
26
28
|
"UpdateMcpServerResponse",
|
|
27
29
|
]
|
letta_client/types/__init__.py
CHANGED
|
@@ -21,6 +21,7 @@ from .approval_request_message_tool_call import ApprovalRequestMessageToolCall
|
|
|
21
21
|
from .approval_response_message import ApprovalResponseMessage
|
|
22
22
|
from .archival_memory_search_response import ArchivalMemorySearchResponse
|
|
23
23
|
from .archival_memory_search_result import ArchivalMemorySearchResult
|
|
24
|
+
from .archive import Archive
|
|
24
25
|
from .assistant_message import AssistantMessage
|
|
25
26
|
from .assistant_message_content import AssistantMessageContent
|
|
26
27
|
from .audio import Audio
|
|
@@ -34,7 +35,7 @@ from .batch_job import BatchJob
|
|
|
34
35
|
from .block import Block
|
|
35
36
|
from .block_schema import BlockSchema
|
|
36
37
|
from .block_update import BlockUpdate
|
|
37
|
-
from .
|
|
38
|
+
from .body_export_agent import BodyExportAgent
|
|
38
39
|
from .chat_completion_allowed_tool_choice_param import ChatCompletionAllowedToolChoiceParam
|
|
39
40
|
from .chat_completion_allowed_tools_param import ChatCompletionAllowedToolsParam
|
|
40
41
|
from .chat_completion_allowed_tools_param_mode import ChatCompletionAllowedToolsParamMode
|
|
@@ -155,6 +156,7 @@ from .imported_agents_response import ImportedAgentsResponse
|
|
|
155
156
|
from .init_tool_rule import InitToolRule
|
|
156
157
|
from .input_audio import InputAudio
|
|
157
158
|
from .input_audio_format import InputAudioFormat
|
|
159
|
+
from .internal_server_error_body import InternalServerErrorBody
|
|
158
160
|
from .internal_template_agent_create import InternalTemplateAgentCreate
|
|
159
161
|
from .internal_template_agent_create_response_format import InternalTemplateAgentCreateResponseFormat
|
|
160
162
|
from .internal_template_agent_create_tool_rules_item import InternalTemplateAgentCreateToolRulesItem
|
|
@@ -217,6 +219,7 @@ from .mcp_tool import McpTool
|
|
|
217
219
|
from .mcp_tool_execute_request import McpToolExecuteRequest
|
|
218
220
|
from .mcp_tool_health import McpToolHealth
|
|
219
221
|
from .memory import Memory
|
|
222
|
+
from .memory_agent_type import MemoryAgentType
|
|
220
223
|
from .message import Message
|
|
221
224
|
from .message_content_item import MessageContentItem
|
|
222
225
|
from .message_create import MessageCreate
|
|
@@ -346,6 +349,7 @@ from .user_message_content import UserMessageContent
|
|
|
346
349
|
from .user_update import UserUpdate
|
|
347
350
|
from .validation_error import ValidationError
|
|
348
351
|
from .validation_error_loc_item import ValidationErrorLocItem
|
|
352
|
+
from .vector_db_provider import VectorDbProvider
|
|
349
353
|
from .voice_sleeptime_manager import VoiceSleeptimeManager
|
|
350
354
|
from .voice_sleeptime_manager_update import VoiceSleeptimeManagerUpdate
|
|
351
355
|
from .web_search_options import WebSearchOptions
|
|
@@ -373,6 +377,7 @@ __all__ = [
|
|
|
373
377
|
"ApprovalResponseMessage",
|
|
374
378
|
"ArchivalMemorySearchResponse",
|
|
375
379
|
"ArchivalMemorySearchResult",
|
|
380
|
+
"Archive",
|
|
376
381
|
"AssistantMessage",
|
|
377
382
|
"AssistantMessageContent",
|
|
378
383
|
"Audio",
|
|
@@ -386,7 +391,7 @@ __all__ = [
|
|
|
386
391
|
"Block",
|
|
387
392
|
"BlockSchema",
|
|
388
393
|
"BlockUpdate",
|
|
389
|
-
"
|
|
394
|
+
"BodyExportAgent",
|
|
390
395
|
"ChatCompletionAllowedToolChoiceParam",
|
|
391
396
|
"ChatCompletionAllowedToolsParam",
|
|
392
397
|
"ChatCompletionAllowedToolsParamMode",
|
|
@@ -507,6 +512,7 @@ __all__ = [
|
|
|
507
512
|
"InitToolRule",
|
|
508
513
|
"InputAudio",
|
|
509
514
|
"InputAudioFormat",
|
|
515
|
+
"InternalServerErrorBody",
|
|
510
516
|
"InternalTemplateAgentCreate",
|
|
511
517
|
"InternalTemplateAgentCreateResponseFormat",
|
|
512
518
|
"InternalTemplateAgentCreateToolRulesItem",
|
|
@@ -561,6 +567,7 @@ __all__ = [
|
|
|
561
567
|
"McpToolExecuteRequest",
|
|
562
568
|
"McpToolHealth",
|
|
563
569
|
"Memory",
|
|
570
|
+
"MemoryAgentType",
|
|
564
571
|
"Message",
|
|
565
572
|
"MessageContentItem",
|
|
566
573
|
"MessageCreate",
|
|
@@ -676,6 +683,7 @@ __all__ = [
|
|
|
676
683
|
"UserUpdate",
|
|
677
684
|
"ValidationError",
|
|
678
685
|
"ValidationErrorLocItem",
|
|
686
|
+
"VectorDbProvider",
|
|
679
687
|
"VoiceSleeptimeManager",
|
|
680
688
|
"VoiceSleeptimeManagerUpdate",
|
|
681
689
|
"WebSearchOptions",
|
|
@@ -133,6 +133,11 @@ class AgentState(UncheckedBaseModel):
|
|
|
133
133
|
default=None
|
|
134
134
|
)
|
|
135
135
|
"""
|
|
136
|
+
Deprecated: use `secrets` field instead.
|
|
137
|
+
"""
|
|
138
|
+
|
|
139
|
+
secrets: typing.Optional[typing.List[AgentEnvironmentVariable]] = pydantic.Field(default=None)
|
|
140
|
+
"""
|
|
136
141
|
The environment variables for tool execution specific to this agent.
|
|
137
142
|
"""
|
|
138
143
|
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
# This file was auto-generated by Fern from our API Definition.
|
|
2
|
+
|
|
3
|
+
import datetime as dt
|
|
4
|
+
import typing
|
|
5
|
+
|
|
6
|
+
import pydantic
|
|
7
|
+
from ..core.pydantic_utilities import IS_PYDANTIC_V2
|
|
8
|
+
from ..core.unchecked_base_model import UncheckedBaseModel
|
|
9
|
+
from .vector_db_provider import VectorDbProvider
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
class Archive(UncheckedBaseModel):
|
|
13
|
+
"""
|
|
14
|
+
Representation of an archive - a collection of archival passages that can be shared between agents.
|
|
15
|
+
|
|
16
|
+
Parameters:
|
|
17
|
+
id (str): The unique identifier of the archive.
|
|
18
|
+
name (str): The name of the archive.
|
|
19
|
+
description (str): A description of the archive.
|
|
20
|
+
organization_id (str): The organization this archive belongs to.
|
|
21
|
+
created_at (datetime): The creation date of the archive.
|
|
22
|
+
metadata (dict): Additional metadata for the archive.
|
|
23
|
+
"""
|
|
24
|
+
|
|
25
|
+
created_by_id: typing.Optional[str] = pydantic.Field(default=None)
|
|
26
|
+
"""
|
|
27
|
+
The id of the user that made this object.
|
|
28
|
+
"""
|
|
29
|
+
|
|
30
|
+
last_updated_by_id: typing.Optional[str] = pydantic.Field(default=None)
|
|
31
|
+
"""
|
|
32
|
+
The id of the user that made this object.
|
|
33
|
+
"""
|
|
34
|
+
|
|
35
|
+
created_at: dt.datetime = pydantic.Field()
|
|
36
|
+
"""
|
|
37
|
+
The creation date of the archive
|
|
38
|
+
"""
|
|
39
|
+
|
|
40
|
+
updated_at: typing.Optional[dt.datetime] = pydantic.Field(default=None)
|
|
41
|
+
"""
|
|
42
|
+
The timestamp when the object was last updated.
|
|
43
|
+
"""
|
|
44
|
+
|
|
45
|
+
name: str = pydantic.Field()
|
|
46
|
+
"""
|
|
47
|
+
The name of the archive
|
|
48
|
+
"""
|
|
49
|
+
|
|
50
|
+
description: typing.Optional[str] = pydantic.Field(default=None)
|
|
51
|
+
"""
|
|
52
|
+
A description of the archive
|
|
53
|
+
"""
|
|
54
|
+
|
|
55
|
+
vector_db_provider: typing.Optional[VectorDbProvider] = pydantic.Field(default=None)
|
|
56
|
+
"""
|
|
57
|
+
The vector database provider used for this archive's passages
|
|
58
|
+
"""
|
|
59
|
+
|
|
60
|
+
metadata: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = pydantic.Field(default=None)
|
|
61
|
+
"""
|
|
62
|
+
Additional metadata
|
|
63
|
+
"""
|
|
64
|
+
|
|
65
|
+
id: typing.Optional[str] = pydantic.Field(default=None)
|
|
66
|
+
"""
|
|
67
|
+
The human-friendly ID of the Archive
|
|
68
|
+
"""
|
|
69
|
+
|
|
70
|
+
if IS_PYDANTIC_V2:
|
|
71
|
+
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
|
|
72
|
+
else:
|
|
73
|
+
|
|
74
|
+
class Config:
|
|
75
|
+
frozen = True
|
|
76
|
+
smart_union = True
|
|
77
|
+
extra = pydantic.Extra.allow
|
letta_client/types/batch_job.py
CHANGED
|
@@ -8,6 +8,7 @@ from ..core.pydantic_utilities import IS_PYDANTIC_V2
|
|
|
8
8
|
from ..core.unchecked_base_model import UncheckedBaseModel
|
|
9
9
|
from .job_status import JobStatus
|
|
10
10
|
from .job_type import JobType
|
|
11
|
+
from .stop_reason_type import StopReasonType
|
|
11
12
|
|
|
12
13
|
|
|
13
14
|
class BatchJob(UncheckedBaseModel):
|
|
@@ -41,6 +42,11 @@ class BatchJob(UncheckedBaseModel):
|
|
|
41
42
|
The unix timestamp of when the job was completed.
|
|
42
43
|
"""
|
|
43
44
|
|
|
45
|
+
stop_reason: typing.Optional[StopReasonType] = pydantic.Field(default=None)
|
|
46
|
+
"""
|
|
47
|
+
The reason why the job was stopped.
|
|
48
|
+
"""
|
|
49
|
+
|
|
44
50
|
metadata: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = pydantic.Field(default=None)
|
|
45
51
|
"""
|
|
46
52
|
The metadata of the job.
|
|
@@ -11,7 +11,7 @@ from .letta_serialize_schemas_pydantic_agent_schema_agent_schema import (
|
|
|
11
11
|
)
|
|
12
12
|
|
|
13
13
|
|
|
14
|
-
class
|
|
14
|
+
class BodyExportAgent(UncheckedBaseModel):
|
|
15
15
|
spec: typing.Optional[AgentFileSchema] = None
|
|
16
16
|
legacy_spec: typing.Optional[LettaSerializeSchemasPydanticAgentSchemaAgentSchema] = None
|
|
17
17
|
|
|
@@ -20,7 +20,7 @@ class ChildToolRule(UncheckedBaseModel):
|
|
|
20
20
|
type: typing.Literal["constrain_child_tools"] = "constrain_child_tools"
|
|
21
21
|
prompt_template: typing.Optional[str] = pydantic.Field(default=None)
|
|
22
22
|
"""
|
|
23
|
-
Optional
|
|
23
|
+
Optional template string (ignored).
|
|
24
24
|
"""
|
|
25
25
|
|
|
26
26
|
children: typing.List[str] = pydantic.Field()
|
|
@@ -20,7 +20,7 @@ class ConditionalToolRule(UncheckedBaseModel):
|
|
|
20
20
|
type: typing.Literal["conditional"] = "conditional"
|
|
21
21
|
prompt_template: typing.Optional[str] = pydantic.Field(default=None)
|
|
22
22
|
"""
|
|
23
|
-
Optional
|
|
23
|
+
Optional template string (ignored).
|
|
24
24
|
"""
|
|
25
25
|
|
|
26
26
|
default_child: typing.Optional[str] = pydantic.Field(default=None)
|