letta-client 0.1.6__py3-none-any.whl → 0.1.10__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.

Files changed (216) hide show
  1. {letta → letta_client}/__init__.py +33 -27
  2. {letta → letta_client}/agents/__init__.py +40 -29
  3. {letta → letta_client}/agents/archival_memory/client.py +25 -25
  4. letta_client/agents/client.py +1328 -0
  5. {letta → letta_client}/agents/context/client.py +7 -7
  6. letta_client/agents/core_memory/client.py +1080 -0
  7. letta_client/agents/memory_variables/__init__.py +5 -0
  8. {letta/agents/memory → letta_client/agents/memory_variables}/client.py +43 -42
  9. letta_client/agents/memory_variables/types/__init__.py +5 -0
  10. letta/agents/types/agents_get_agent_variables_response.py → letta_client/agents/memory_variables/types/memory_variables_get_response.py +3 -3
  11. {letta → letta_client}/agents/messages/client.py +240 -25
  12. {letta → letta_client}/agents/messages/types/letta_streaming_response.py +21 -16
  13. {letta → letta_client}/agents/messages/types/messages_list_response_item.py +19 -14
  14. {letta → letta_client}/agents/recall_memory/client.py +7 -7
  15. {letta → letta_client}/agents/sources/client.py +7 -7
  16. letta_client/agents/templates/__init__.py +5 -0
  17. letta_client/agents/templates/client.py +578 -0
  18. letta_client/agents/templates/types/__init__.py +5 -0
  19. letta/agents/types/agents_migrate_response.py → letta_client/agents/templates/types/templates_migrate_response.py +3 -3
  20. {letta → letta_client}/agents/tools/client.py +19 -19
  21. letta_client/agents/types/__init__.py +33 -0
  22. letta_client/agents/types/agents_search_request_combinator.py +5 -0
  23. letta/agents/types/agents_search_deployed_agents_request_search_item.py → letta_client/agents/types/agents_search_request_search_item.py +17 -20
  24. letta/agents/types/agents_search_deployed_agents_request_search_item_name.py → letta_client/agents/types/agents_search_request_search_item_name.py +4 -6
  25. letta_client/agents/types/agents_search_request_search_item_name_operator.py +5 -0
  26. letta_client/agents/types/agents_search_request_search_item_order_by.py +22 -0
  27. letta_client/agents/types/agents_search_request_search_item_order_by_direction.py +5 -0
  28. letta_client/agents/types/agents_search_request_search_item_order_by_value.py +5 -0
  29. letta/agents/types/agents_search_deployed_agents_request_search_item_version.py → letta_client/agents/types/agents_search_request_search_item_version.py +2 -2
  30. {letta → letta_client}/blocks/client.py +39 -39
  31. {letta → letta_client}/client.py +10 -2
  32. {letta → letta_client}/core/__init__.py +4 -0
  33. {letta → letta_client}/core/client_wrapper.py +1 -1
  34. letta_client/core/unchecked_base_model.py +305 -0
  35. {letta → letta_client}/health/client.py +5 -5
  36. {letta → letta_client}/jobs/client.py +25 -25
  37. {letta → letta_client}/models/client.py +9 -9
  38. letta_client/providers/client.py +597 -0
  39. letta_client/runs/client.py +876 -0
  40. {letta → letta_client}/sources/client.py +49 -49
  41. {letta → letta_client}/sources/files/client.py +17 -17
  42. {letta → letta_client}/sources/passages/client.py +7 -7
  43. letta_client/tools/__init__.py +2 -0
  44. {letta → letta_client}/tools/client.py +101 -81
  45. {letta → letta_client}/types/__init__.py +8 -0
  46. {letta → letta_client}/types/action_model.py +2 -2
  47. {letta → letta_client}/types/action_parameters_model.py +2 -2
  48. {letta → letta_client}/types/action_response_model.py +2 -2
  49. {letta → letta_client}/types/agent_environment_variable.py +2 -7
  50. {letta → letta_client}/types/agent_state.py +5 -8
  51. letta_client/types/agent_type.py +7 -0
  52. {letta → letta_client}/types/app_auth_scheme.py +2 -2
  53. {letta → letta_client}/types/app_model.py +2 -2
  54. {letta → letta_client}/types/archival_memory_summary.py +2 -2
  55. {letta → letta_client}/types/assistant_file.py +2 -2
  56. {letta → letta_client}/types/assistant_message_input.py +2 -2
  57. {letta → letta_client}/types/assistant_message_output.py +2 -2
  58. {letta → letta_client}/types/auth_request.py +2 -2
  59. {letta → letta_client}/types/auth_response.py +2 -2
  60. {letta → letta_client}/types/auth_scheme_field.py +2 -2
  61. {letta → letta_client}/types/block.py +2 -7
  62. {letta → letta_client}/types/block_update.py +2 -2
  63. {letta → letta_client}/types/chat_completion_request.py +2 -2
  64. {letta → letta_client}/types/chat_completion_response.py +2 -2
  65. {letta → letta_client}/types/child_tool_rule.py +2 -2
  66. {letta → letta_client}/types/choice.py +2 -2
  67. {letta → letta_client}/types/conditional_tool_rule.py +2 -2
  68. {letta → letta_client}/types/conflict_error_body.py +2 -2
  69. {letta → letta_client}/types/context_window_overview.py +2 -2
  70. {letta → letta_client}/types/create_assistant_file_request.py +2 -2
  71. {letta → letta_client}/types/create_assistant_request.py +2 -2
  72. {letta → letta_client}/types/create_block.py +2 -2
  73. {letta → letta_client}/types/delete_assistant_file_response.py +2 -2
  74. {letta → letta_client}/types/delete_assistant_response.py +2 -2
  75. {letta → letta_client}/types/e_2_b_sandbox_config.py +2 -2
  76. {letta → letta_client}/types/embedding_config.py +2 -2
  77. {letta → letta_client}/types/file_metadata.py +2 -7
  78. {letta → letta_client}/types/function_call_input.py +2 -2
  79. {letta → letta_client}/types/function_call_output.py +2 -2
  80. {letta → letta_client}/types/function_schema.py +2 -2
  81. {letta → letta_client}/types/health.py +2 -2
  82. {letta → letta_client}/types/http_validation_error.py +2 -2
  83. {letta → letta_client}/types/init_tool_rule.py +2 -2
  84. {letta → letta_client}/types/internal_server_error_body.py +2 -2
  85. {letta → letta_client}/types/job.py +7 -6
  86. letta_client/types/job_type.py +5 -0
  87. {letta → letta_client}/types/letta_request.py +7 -2
  88. {letta → letta_client}/types/letta_response.py +2 -2
  89. {letta → letta_client}/types/letta_response_messages_item.py +19 -14
  90. {letta → letta_client}/types/letta_schemas_letta_message_tool_call.py +2 -2
  91. {letta → letta_client}/types/letta_schemas_message_message.py +2 -7
  92. {letta → letta_client}/types/letta_schemas_openai_chat_completion_request_tool.py +2 -2
  93. {letta → letta_client}/types/letta_schemas_openai_chat_completion_request_tool_call.py +2 -2
  94. {letta → letta_client}/types/letta_schemas_openai_chat_completion_request_tool_call_function.py +2 -2
  95. {letta → letta_client}/types/letta_schemas_openai_chat_completion_response_message.py +2 -2
  96. {letta → letta_client}/types/letta_schemas_openai_chat_completion_response_tool_call.py +2 -2
  97. {letta → letta_client}/types/letta_schemas_openai_chat_completions_tool_call_function.py +2 -2
  98. {letta → letta_client}/types/letta_schemas_openai_chat_completions_tool_call_input.py +2 -2
  99. {letta → letta_client}/types/letta_schemas_openai_chat_completions_tool_call_output.py +2 -2
  100. {letta → letta_client}/types/letta_schemas_tool_tool.py +9 -8
  101. {letta → letta_client}/types/letta_usage_statistics.py +2 -2
  102. {letta → letta_client}/types/llm_config.py +2 -2
  103. {letta → letta_client}/types/local_sandbox_config.py +2 -2
  104. {letta → letta_client}/types/log_prob_token.py +2 -2
  105. {letta → letta_client}/types/memory.py +2 -2
  106. {letta → letta_client}/types/message_content_log_prob.py +2 -2
  107. {letta → letta_client}/types/message_create.py +2 -2
  108. {letta → letta_client}/types/not_found_error_body.py +2 -2
  109. {letta → letta_client}/types/open_ai_assistant.py +2 -2
  110. {letta → letta_client}/types/organization.py +2 -2
  111. {letta → letta_client}/types/organization_create.py +2 -2
  112. {letta → letta_client}/types/passage.py +2 -7
  113. letta_client/types/provider.py +38 -0
  114. {letta → letta_client}/types/reasoning_message.py +2 -2
  115. {letta → letta_client}/types/recall_memory_summary.py +2 -2
  116. {letta → letta_client}/types/response_format.py +2 -2
  117. letta_client/types/run.py +77 -0
  118. {letta → letta_client}/types/sandbox_config.py +2 -7
  119. {letta → letta_client}/types/sandbox_config_create.py +2 -2
  120. {letta → letta_client}/types/sandbox_config_update.py +2 -2
  121. {letta → letta_client}/types/sandbox_environment_variable.py +2 -7
  122. {letta → letta_client}/types/sandbox_environment_variable_create.py +2 -2
  123. {letta → letta_client}/types/sandbox_environment_variable_update.py +2 -2
  124. {letta → letta_client}/types/source.py +2 -7
  125. {letta → letta_client}/types/system_message_input.py +2 -2
  126. {letta → letta_client}/types/system_message_output.py +2 -2
  127. {letta → letta_client}/types/terminal_tool_rule.py +2 -2
  128. {letta → letta_client}/types/tool_call_delta.py +2 -2
  129. {letta → letta_client}/types/tool_call_function_output.py +2 -2
  130. {letta → letta_client}/types/tool_call_message.py +2 -2
  131. {letta → letta_client}/types/tool_create.py +2 -2
  132. {letta → letta_client}/types/tool_function_choice.py +2 -2
  133. {letta → letta_client}/types/tool_input.py +2 -2
  134. {letta → letta_client}/types/tool_message.py +2 -2
  135. {letta → letta_client}/types/tool_return_message.py +2 -2
  136. letta_client/types/tool_type.py +5 -0
  137. {letta → letta_client}/types/usage_statistics.py +2 -2
  138. {letta → letta_client}/types/user.py +2 -7
  139. {letta → letta_client}/types/user_create.py +2 -7
  140. {letta → letta_client}/types/user_message_input.py +2 -2
  141. {letta → letta_client}/types/user_message_output.py +2 -2
  142. {letta → letta_client}/types/user_update.py +2 -7
  143. {letta → letta_client}/types/validation_error.py +2 -2
  144. {letta_client-0.1.6.dist-info → letta_client-0.1.10.dist-info}/METADATA +7 -7
  145. letta_client-0.1.10.dist-info/RECORD +204 -0
  146. letta/agents/client.py +0 -2644
  147. letta/agents/memory/__init__.py +0 -5
  148. letta/agents/memory/messages/client.py +0 -147
  149. letta/agents/memory_blocks/client.py +0 -364
  150. letta/agents/types/__init__.py +0 -47
  151. letta/agents/types/agents_search_deployed_agents_request_combinator.py +0 -5
  152. letta/agents/types/agents_search_deployed_agents_request_search_item_name_operator.py +0 -7
  153. letta/agents/types/agents_search_deployed_agents_request_search_item_order_by.py +0 -26
  154. letta/agents/types/agents_search_deployed_agents_request_search_item_order_by_direction.py +0 -5
  155. letta/agents/types/agents_search_deployed_agents_request_search_item_order_by_value.py +0 -7
  156. letta/types/agent_type.py +0 -8
  157. letta_client-0.1.6.dist-info/RECORD +0 -193
  158. {letta → letta_client}/agents/archival_memory/__init__.py +0 -0
  159. {letta → letta_client}/agents/context/__init__.py +0 -0
  160. {letta/agents/memory/messages → letta_client/agents/core_memory}/__init__.py +0 -0
  161. {letta → letta_client}/agents/messages/__init__.py +0 -0
  162. {letta → letta_client}/agents/messages/types/__init__.py +0 -0
  163. {letta → letta_client}/agents/messages/types/messages_list_response.py +0 -0
  164. {letta/agents/memory_blocks → letta_client/agents/recall_memory}/__init__.py +0 -0
  165. {letta/agents/recall_memory → letta_client/agents/sources}/__init__.py +0 -0
  166. {letta/agents/sources → letta_client/agents/tools}/__init__.py +0 -0
  167. {letta → letta_client}/agents/types/create_agent_request_tool_rules_item.py +0 -0
  168. {letta → letta_client}/agents/types/update_agent_tool_rules_item.py +0 -0
  169. {letta/agents/tools → letta_client/blocks}/__init__.py +0 -0
  170. {letta → letta_client}/core/api_error.py +0 -0
  171. {letta → letta_client}/core/datetime_utils.py +0 -0
  172. {letta → letta_client}/core/file.py +0 -0
  173. {letta → letta_client}/core/http_client.py +0 -0
  174. {letta → letta_client}/core/jsonable_encoder.py +0 -0
  175. {letta → letta_client}/core/pydantic_utilities.py +0 -0
  176. {letta → letta_client}/core/query_encoder.py +0 -0
  177. {letta → letta_client}/core/remove_none_from_dict.py +0 -0
  178. {letta → letta_client}/core/request_options.py +0 -0
  179. {letta → letta_client}/core/serialization.py +0 -0
  180. {letta → letta_client}/environment.py +0 -0
  181. {letta → letta_client}/errors/__init__.py +0 -0
  182. {letta → letta_client}/errors/conflict_error.py +0 -0
  183. {letta → letta_client}/errors/internal_server_error.py +0 -0
  184. {letta → letta_client}/errors/not_found_error.py +0 -0
  185. {letta → letta_client}/errors/unprocessable_entity_error.py +0 -0
  186. {letta/blocks → letta_client/health}/__init__.py +0 -0
  187. {letta/health → letta_client/jobs}/__init__.py +0 -0
  188. {letta/jobs → letta_client/models}/__init__.py +0 -0
  189. {letta/models → letta_client/providers}/__init__.py +0 -0
  190. {letta → letta_client}/py.typed +0 -0
  191. {letta/sources/files → letta_client/runs}/__init__.py +0 -0
  192. {letta → letta_client}/sources/__init__.py +0 -0
  193. {letta/sources/passages → letta_client/sources/files}/__init__.py +0 -0
  194. {letta/tools → letta_client/sources/passages}/__init__.py +0 -0
  195. {letta → letta_client}/types/agent_state_tool_rules_item.py +0 -0
  196. {letta → letta_client}/types/app_auth_scheme_auth_mode.py +0 -0
  197. {letta → letta_client}/types/chat_completion_request_function_call.py +0 -0
  198. {letta → letta_client}/types/chat_completion_request_messages_item.py +0 -0
  199. {letta → letta_client}/types/chat_completion_request_stop.py +0 -0
  200. {letta → letta_client}/types/chat_completion_request_tool_choice.py +0 -0
  201. {letta → letta_client}/types/embedding_config_embedding_endpoint_type.py +0 -0
  202. {letta → letta_client}/types/job_status.py +0 -0
  203. {letta → letta_client}/types/llm_config_model_endpoint_type.py +0 -0
  204. {letta → letta_client}/types/message_create_role.py +0 -0
  205. {letta → letta_client}/types/message_role.py +0 -0
  206. {letta → letta_client}/types/not_found_error_body_message.py +0 -0
  207. {letta → letta_client}/types/sandbox_config_create_config.py +0 -0
  208. {letta → letta_client}/types/sandbox_config_update_config.py +0 -0
  209. {letta → letta_client}/types/sandbox_type.py +0 -0
  210. {letta → letta_client}/types/tool_call_message_tool_call.py +0 -0
  211. {letta → letta_client}/types/tool_return_message_status.py +0 -0
  212. {letta → letta_client}/types/tool_rule_type.py +0 -0
  213. {letta → letta_client}/types/user_message_input_content.py +0 -0
  214. {letta → letta_client}/types/validation_error_loc_item.py +0 -0
  215. {letta → letta_client}/version.py +0 -0
  216. {letta_client-0.1.6.dist-info → letta_client-0.1.10.dist-info}/WHEEL +0 -0
@@ -7,7 +7,7 @@ from .passages.client import PassagesClient
7
7
  from ..core.request_options import RequestOptions
8
8
  from ..types.source import Source
9
9
  from ..core.jsonable_encoder import jsonable_encoder
10
- from ..core.pydantic_utilities import parse_obj_as
10
+ from ..core.unchecked_base_model import construct_type
11
11
  from ..errors.unprocessable_entity_error import UnprocessableEntityError
12
12
  from ..types.http_validation_error import HttpValidationError
13
13
  from json.decoder import JSONDecodeError
@@ -46,7 +46,7 @@ class SourcesClient:
46
46
 
47
47
  Examples
48
48
  --------
49
- from letta import Letta
49
+ from letta_client import Letta
50
50
 
51
51
  client = Letta(
52
52
  token="YOUR_TOKEN",
@@ -64,7 +64,7 @@ class SourcesClient:
64
64
  if 200 <= _response.status_code < 300:
65
65
  return typing.cast(
66
66
  Source,
67
- parse_obj_as(
67
+ construct_type(
68
68
  type_=Source, # type: ignore
69
69
  object_=_response.json(),
70
70
  ),
@@ -73,7 +73,7 @@ class SourcesClient:
73
73
  raise UnprocessableEntityError(
74
74
  typing.cast(
75
75
  HttpValidationError,
76
- parse_obj_as(
76
+ construct_type(
77
77
  type_=HttpValidationError, # type: ignore
78
78
  object_=_response.json(),
79
79
  ),
@@ -104,7 +104,7 @@ class SourcesClient:
104
104
 
105
105
  Examples
106
106
  --------
107
- from letta import Letta
107
+ from letta_client import Letta
108
108
 
109
109
  client = Letta(
110
110
  token="YOUR_TOKEN",
@@ -122,7 +122,7 @@ class SourcesClient:
122
122
  if 200 <= _response.status_code < 300:
123
123
  return typing.cast(
124
124
  typing.Optional[typing.Any],
125
- parse_obj_as(
125
+ construct_type(
126
126
  type_=typing.Optional[typing.Any], # type: ignore
127
127
  object_=_response.json(),
128
128
  ),
@@ -131,7 +131,7 @@ class SourcesClient:
131
131
  raise UnprocessableEntityError(
132
132
  typing.cast(
133
133
  HttpValidationError,
134
- parse_obj_as(
134
+ construct_type(
135
135
  type_=HttpValidationError, # type: ignore
136
136
  object_=_response.json(),
137
137
  ),
@@ -181,7 +181,7 @@ class SourcesClient:
181
181
 
182
182
  Examples
183
183
  --------
184
- from letta import Letta
184
+ from letta_client import Letta
185
185
 
186
186
  client = Letta(
187
187
  token="YOUR_TOKEN",
@@ -211,7 +211,7 @@ class SourcesClient:
211
211
  if 200 <= _response.status_code < 300:
212
212
  return typing.cast(
213
213
  Source,
214
- parse_obj_as(
214
+ construct_type(
215
215
  type_=Source, # type: ignore
216
216
  object_=_response.json(),
217
217
  ),
@@ -220,7 +220,7 @@ class SourcesClient:
220
220
  raise UnprocessableEntityError(
221
221
  typing.cast(
222
222
  HttpValidationError,
223
- parse_obj_as(
223
+ construct_type(
224
224
  type_=HttpValidationError, # type: ignore
225
225
  object_=_response.json(),
226
226
  ),
@@ -249,7 +249,7 @@ class SourcesClient:
249
249
 
250
250
  Examples
251
251
  --------
252
- from letta import Letta
252
+ from letta_client import Letta
253
253
 
254
254
  client = Letta(
255
255
  token="YOUR_TOKEN",
@@ -267,7 +267,7 @@ class SourcesClient:
267
267
  if 200 <= _response.status_code < 300:
268
268
  return typing.cast(
269
269
  str,
270
- parse_obj_as(
270
+ construct_type(
271
271
  type_=str, # type: ignore
272
272
  object_=_response.json(),
273
273
  ),
@@ -276,7 +276,7 @@ class SourcesClient:
276
276
  raise UnprocessableEntityError(
277
277
  typing.cast(
278
278
  HttpValidationError,
279
- parse_obj_as(
279
+ construct_type(
280
280
  type_=HttpValidationError, # type: ignore
281
281
  object_=_response.json(),
282
282
  ),
@@ -303,7 +303,7 @@ class SourcesClient:
303
303
 
304
304
  Examples
305
305
  --------
306
- from letta import Letta
306
+ from letta_client import Letta
307
307
 
308
308
  client = Letta(
309
309
  token="YOUR_TOKEN",
@@ -319,7 +319,7 @@ class SourcesClient:
319
319
  if 200 <= _response.status_code < 300:
320
320
  return typing.cast(
321
321
  typing.List[Source],
322
- parse_obj_as(
322
+ construct_type(
323
323
  type_=typing.List[Source], # type: ignore
324
324
  object_=_response.json(),
325
325
  ),
@@ -328,7 +328,7 @@ class SourcesClient:
328
328
  raise UnprocessableEntityError(
329
329
  typing.cast(
330
330
  HttpValidationError,
331
- parse_obj_as(
331
+ construct_type(
332
332
  type_=HttpValidationError, # type: ignore
333
333
  object_=_response.json(),
334
334
  ),
@@ -375,7 +375,7 @@ class SourcesClient:
375
375
 
376
376
  Examples
377
377
  --------
378
- from letta import Letta
378
+ from letta_client import Letta
379
379
 
380
380
  client = Letta(
381
381
  token="YOUR_TOKEN",
@@ -405,7 +405,7 @@ class SourcesClient:
405
405
  if 200 <= _response.status_code < 300:
406
406
  return typing.cast(
407
407
  Source,
408
- parse_obj_as(
408
+ construct_type(
409
409
  type_=Source, # type: ignore
410
410
  object_=_response.json(),
411
411
  ),
@@ -414,7 +414,7 @@ class SourcesClient:
414
414
  raise UnprocessableEntityError(
415
415
  typing.cast(
416
416
  HttpValidationError,
417
- parse_obj_as(
417
+ construct_type(
418
418
  type_=HttpValidationError, # type: ignore
419
419
  object_=_response.json(),
420
420
  ),
@@ -448,7 +448,7 @@ class SourcesClient:
448
448
 
449
449
  Examples
450
450
  --------
451
- from letta import Letta
451
+ from letta_client import Letta
452
452
 
453
453
  client = Letta(
454
454
  token="YOUR_TOKEN",
@@ -470,7 +470,7 @@ class SourcesClient:
470
470
  if 200 <= _response.status_code < 300:
471
471
  return typing.cast(
472
472
  Source,
473
- parse_obj_as(
473
+ construct_type(
474
474
  type_=Source, # type: ignore
475
475
  object_=_response.json(),
476
476
  ),
@@ -479,7 +479,7 @@ class SourcesClient:
479
479
  raise UnprocessableEntityError(
480
480
  typing.cast(
481
481
  HttpValidationError,
482
- parse_obj_as(
482
+ construct_type(
483
483
  type_=HttpValidationError, # type: ignore
484
484
  object_=_response.json(),
485
485
  ),
@@ -513,7 +513,7 @@ class SourcesClient:
513
513
 
514
514
  Examples
515
515
  --------
516
- from letta import Letta
516
+ from letta_client import Letta
517
517
 
518
518
  client = Letta(
519
519
  token="YOUR_TOKEN",
@@ -535,7 +535,7 @@ class SourcesClient:
535
535
  if 200 <= _response.status_code < 300:
536
536
  return typing.cast(
537
537
  Source,
538
- parse_obj_as(
538
+ construct_type(
539
539
  type_=Source, # type: ignore
540
540
  object_=_response.json(),
541
541
  ),
@@ -544,7 +544,7 @@ class SourcesClient:
544
544
  raise UnprocessableEntityError(
545
545
  typing.cast(
546
546
  HttpValidationError,
547
- parse_obj_as(
547
+ construct_type(
548
548
  type_=HttpValidationError, # type: ignore
549
549
  object_=_response.json(),
550
550
  ),
@@ -582,7 +582,7 @@ class AsyncSourcesClient:
582
582
  --------
583
583
  import asyncio
584
584
 
585
- from letta import AsyncLetta
585
+ from letta_client import AsyncLetta
586
586
 
587
587
  client = AsyncLetta(
588
588
  token="YOUR_TOKEN",
@@ -606,7 +606,7 @@ class AsyncSourcesClient:
606
606
  if 200 <= _response.status_code < 300:
607
607
  return typing.cast(
608
608
  Source,
609
- parse_obj_as(
609
+ construct_type(
610
610
  type_=Source, # type: ignore
611
611
  object_=_response.json(),
612
612
  ),
@@ -615,7 +615,7 @@ class AsyncSourcesClient:
615
615
  raise UnprocessableEntityError(
616
616
  typing.cast(
617
617
  HttpValidationError,
618
- parse_obj_as(
618
+ construct_type(
619
619
  type_=HttpValidationError, # type: ignore
620
620
  object_=_response.json(),
621
621
  ),
@@ -648,7 +648,7 @@ class AsyncSourcesClient:
648
648
  --------
649
649
  import asyncio
650
650
 
651
- from letta import AsyncLetta
651
+ from letta_client import AsyncLetta
652
652
 
653
653
  client = AsyncLetta(
654
654
  token="YOUR_TOKEN",
@@ -672,7 +672,7 @@ class AsyncSourcesClient:
672
672
  if 200 <= _response.status_code < 300:
673
673
  return typing.cast(
674
674
  typing.Optional[typing.Any],
675
- parse_obj_as(
675
+ construct_type(
676
676
  type_=typing.Optional[typing.Any], # type: ignore
677
677
  object_=_response.json(),
678
678
  ),
@@ -681,7 +681,7 @@ class AsyncSourcesClient:
681
681
  raise UnprocessableEntityError(
682
682
  typing.cast(
683
683
  HttpValidationError,
684
- parse_obj_as(
684
+ construct_type(
685
685
  type_=HttpValidationError, # type: ignore
686
686
  object_=_response.json(),
687
687
  ),
@@ -733,7 +733,7 @@ class AsyncSourcesClient:
733
733
  --------
734
734
  import asyncio
735
735
 
736
- from letta import AsyncLetta
736
+ from letta_client import AsyncLetta
737
737
 
738
738
  client = AsyncLetta(
739
739
  token="YOUR_TOKEN",
@@ -769,7 +769,7 @@ class AsyncSourcesClient:
769
769
  if 200 <= _response.status_code < 300:
770
770
  return typing.cast(
771
771
  Source,
772
- parse_obj_as(
772
+ construct_type(
773
773
  type_=Source, # type: ignore
774
774
  object_=_response.json(),
775
775
  ),
@@ -778,7 +778,7 @@ class AsyncSourcesClient:
778
778
  raise UnprocessableEntityError(
779
779
  typing.cast(
780
780
  HttpValidationError,
781
- parse_obj_as(
781
+ construct_type(
782
782
  type_=HttpValidationError, # type: ignore
783
783
  object_=_response.json(),
784
784
  ),
@@ -809,7 +809,7 @@ class AsyncSourcesClient:
809
809
  --------
810
810
  import asyncio
811
811
 
812
- from letta import AsyncLetta
812
+ from letta_client import AsyncLetta
813
813
 
814
814
  client = AsyncLetta(
815
815
  token="YOUR_TOKEN",
@@ -833,7 +833,7 @@ class AsyncSourcesClient:
833
833
  if 200 <= _response.status_code < 300:
834
834
  return typing.cast(
835
835
  str,
836
- parse_obj_as(
836
+ construct_type(
837
837
  type_=str, # type: ignore
838
838
  object_=_response.json(),
839
839
  ),
@@ -842,7 +842,7 @@ class AsyncSourcesClient:
842
842
  raise UnprocessableEntityError(
843
843
  typing.cast(
844
844
  HttpValidationError,
845
- parse_obj_as(
845
+ construct_type(
846
846
  type_=HttpValidationError, # type: ignore
847
847
  object_=_response.json(),
848
848
  ),
@@ -871,7 +871,7 @@ class AsyncSourcesClient:
871
871
  --------
872
872
  import asyncio
873
873
 
874
- from letta import AsyncLetta
874
+ from letta_client import AsyncLetta
875
875
 
876
876
  client = AsyncLetta(
877
877
  token="YOUR_TOKEN",
@@ -893,7 +893,7 @@ class AsyncSourcesClient:
893
893
  if 200 <= _response.status_code < 300:
894
894
  return typing.cast(
895
895
  typing.List[Source],
896
- parse_obj_as(
896
+ construct_type(
897
897
  type_=typing.List[Source], # type: ignore
898
898
  object_=_response.json(),
899
899
  ),
@@ -902,7 +902,7 @@ class AsyncSourcesClient:
902
902
  raise UnprocessableEntityError(
903
903
  typing.cast(
904
904
  HttpValidationError,
905
- parse_obj_as(
905
+ construct_type(
906
906
  type_=HttpValidationError, # type: ignore
907
907
  object_=_response.json(),
908
908
  ),
@@ -951,7 +951,7 @@ class AsyncSourcesClient:
951
951
  --------
952
952
  import asyncio
953
953
 
954
- from letta import AsyncLetta
954
+ from letta_client import AsyncLetta
955
955
 
956
956
  client = AsyncLetta(
957
957
  token="YOUR_TOKEN",
@@ -987,7 +987,7 @@ class AsyncSourcesClient:
987
987
  if 200 <= _response.status_code < 300:
988
988
  return typing.cast(
989
989
  Source,
990
- parse_obj_as(
990
+ construct_type(
991
991
  type_=Source, # type: ignore
992
992
  object_=_response.json(),
993
993
  ),
@@ -996,7 +996,7 @@ class AsyncSourcesClient:
996
996
  raise UnprocessableEntityError(
997
997
  typing.cast(
998
998
  HttpValidationError,
999
- parse_obj_as(
999
+ construct_type(
1000
1000
  type_=HttpValidationError, # type: ignore
1001
1001
  object_=_response.json(),
1002
1002
  ),
@@ -1032,7 +1032,7 @@ class AsyncSourcesClient:
1032
1032
  --------
1033
1033
  import asyncio
1034
1034
 
1035
- from letta import AsyncLetta
1035
+ from letta_client import AsyncLetta
1036
1036
 
1037
1037
  client = AsyncLetta(
1038
1038
  token="YOUR_TOKEN",
@@ -1060,7 +1060,7 @@ class AsyncSourcesClient:
1060
1060
  if 200 <= _response.status_code < 300:
1061
1061
  return typing.cast(
1062
1062
  Source,
1063
- parse_obj_as(
1063
+ construct_type(
1064
1064
  type_=Source, # type: ignore
1065
1065
  object_=_response.json(),
1066
1066
  ),
@@ -1069,7 +1069,7 @@ class AsyncSourcesClient:
1069
1069
  raise UnprocessableEntityError(
1070
1070
  typing.cast(
1071
1071
  HttpValidationError,
1072
- parse_obj_as(
1072
+ construct_type(
1073
1073
  type_=HttpValidationError, # type: ignore
1074
1074
  object_=_response.json(),
1075
1075
  ),
@@ -1105,7 +1105,7 @@ class AsyncSourcesClient:
1105
1105
  --------
1106
1106
  import asyncio
1107
1107
 
1108
- from letta import AsyncLetta
1108
+ from letta_client import AsyncLetta
1109
1109
 
1110
1110
  client = AsyncLetta(
1111
1111
  token="YOUR_TOKEN",
@@ -1133,7 +1133,7 @@ class AsyncSourcesClient:
1133
1133
  if 200 <= _response.status_code < 300:
1134
1134
  return typing.cast(
1135
1135
  Source,
1136
- parse_obj_as(
1136
+ construct_type(
1137
1137
  type_=Source, # type: ignore
1138
1138
  object_=_response.json(),
1139
1139
  ),
@@ -1142,7 +1142,7 @@ class AsyncSourcesClient:
1142
1142
  raise UnprocessableEntityError(
1143
1143
  typing.cast(
1144
1144
  HttpValidationError,
1145
- parse_obj_as(
1145
+ construct_type(
1146
1146
  type_=HttpValidationError, # type: ignore
1147
1147
  object_=_response.json(),
1148
1148
  ),
@@ -6,7 +6,7 @@ from ... import core
6
6
  from ...core.request_options import RequestOptions
7
7
  from ...types.job import Job
8
8
  from ...core.jsonable_encoder import jsonable_encoder
9
- from ...core.pydantic_utilities import parse_obj_as
9
+ from ...core.unchecked_base_model import construct_type
10
10
  from ...errors.unprocessable_entity_error import UnprocessableEntityError
11
11
  from ...types.http_validation_error import HttpValidationError
12
12
  from json.decoder import JSONDecodeError
@@ -45,7 +45,7 @@ class FilesClient:
45
45
 
46
46
  Examples
47
47
  --------
48
- from letta import Letta
48
+ from letta_client import Letta
49
49
 
50
50
  client = Letta(
51
51
  token="YOUR_TOKEN",
@@ -68,7 +68,7 @@ class FilesClient:
68
68
  if 200 <= _response.status_code < 300:
69
69
  return typing.cast(
70
70
  Job,
71
- parse_obj_as(
71
+ construct_type(
72
72
  type_=Job, # type: ignore
73
73
  object_=_response.json(),
74
74
  ),
@@ -77,7 +77,7 @@ class FilesClient:
77
77
  raise UnprocessableEntityError(
78
78
  typing.cast(
79
79
  HttpValidationError,
80
- parse_obj_as(
80
+ construct_type(
81
81
  type_=HttpValidationError, # type: ignore
82
82
  object_=_response.json(),
83
83
  ),
@@ -119,7 +119,7 @@ class FilesClient:
119
119
 
120
120
  Examples
121
121
  --------
122
- from letta import Letta
122
+ from letta_client import Letta
123
123
 
124
124
  client = Letta(
125
125
  token="YOUR_TOKEN",
@@ -141,7 +141,7 @@ class FilesClient:
141
141
  if 200 <= _response.status_code < 300:
142
142
  return typing.cast(
143
143
  typing.List[FileMetadata],
144
- parse_obj_as(
144
+ construct_type(
145
145
  type_=typing.List[FileMetadata], # type: ignore
146
146
  object_=_response.json(),
147
147
  ),
@@ -150,7 +150,7 @@ class FilesClient:
150
150
  raise UnprocessableEntityError(
151
151
  typing.cast(
152
152
  HttpValidationError,
153
- parse_obj_as(
153
+ construct_type(
154
154
  type_=HttpValidationError, # type: ignore
155
155
  object_=_response.json(),
156
156
  ),
@@ -180,7 +180,7 @@ class FilesClient:
180
180
 
181
181
  Examples
182
182
  --------
183
- from letta import Letta
183
+ from letta_client import Letta
184
184
 
185
185
  client = Letta(
186
186
  token="YOUR_TOKEN",
@@ -202,7 +202,7 @@ class FilesClient:
202
202
  raise UnprocessableEntityError(
203
203
  typing.cast(
204
204
  HttpValidationError,
205
- parse_obj_as(
205
+ construct_type(
206
206
  type_=HttpValidationError, # type: ignore
207
207
  object_=_response.json(),
208
208
  ),
@@ -243,7 +243,7 @@ class AsyncFilesClient:
243
243
  --------
244
244
  import asyncio
245
245
 
246
- from letta import AsyncLetta
246
+ from letta_client import AsyncLetta
247
247
 
248
248
  client = AsyncLetta(
249
249
  token="YOUR_TOKEN",
@@ -272,7 +272,7 @@ class AsyncFilesClient:
272
272
  if 200 <= _response.status_code < 300:
273
273
  return typing.cast(
274
274
  Job,
275
- parse_obj_as(
275
+ construct_type(
276
276
  type_=Job, # type: ignore
277
277
  object_=_response.json(),
278
278
  ),
@@ -281,7 +281,7 @@ class AsyncFilesClient:
281
281
  raise UnprocessableEntityError(
282
282
  typing.cast(
283
283
  HttpValidationError,
284
- parse_obj_as(
284
+ construct_type(
285
285
  type_=HttpValidationError, # type: ignore
286
286
  object_=_response.json(),
287
287
  ),
@@ -325,7 +325,7 @@ class AsyncFilesClient:
325
325
  --------
326
326
  import asyncio
327
327
 
328
- from letta import AsyncLetta
328
+ from letta_client import AsyncLetta
329
329
 
330
330
  client = AsyncLetta(
331
331
  token="YOUR_TOKEN",
@@ -353,7 +353,7 @@ class AsyncFilesClient:
353
353
  if 200 <= _response.status_code < 300:
354
354
  return typing.cast(
355
355
  typing.List[FileMetadata],
356
- parse_obj_as(
356
+ construct_type(
357
357
  type_=typing.List[FileMetadata], # type: ignore
358
358
  object_=_response.json(),
359
359
  ),
@@ -362,7 +362,7 @@ class AsyncFilesClient:
362
362
  raise UnprocessableEntityError(
363
363
  typing.cast(
364
364
  HttpValidationError,
365
- parse_obj_as(
365
+ construct_type(
366
366
  type_=HttpValidationError, # type: ignore
367
367
  object_=_response.json(),
368
368
  ),
@@ -396,7 +396,7 @@ class AsyncFilesClient:
396
396
  --------
397
397
  import asyncio
398
398
 
399
- from letta import AsyncLetta
399
+ from letta_client import AsyncLetta
400
400
 
401
401
  client = AsyncLetta(
402
402
  token="YOUR_TOKEN",
@@ -424,7 +424,7 @@ class AsyncFilesClient:
424
424
  raise UnprocessableEntityError(
425
425
  typing.cast(
426
426
  HttpValidationError,
427
- parse_obj_as(
427
+ construct_type(
428
428
  type_=HttpValidationError, # type: ignore
429
429
  object_=_response.json(),
430
430
  ),
@@ -5,7 +5,7 @@ import typing
5
5
  from ...core.request_options import RequestOptions
6
6
  from ...types.passage import Passage
7
7
  from ...core.jsonable_encoder import jsonable_encoder
8
- from ...core.pydantic_utilities import parse_obj_as
8
+ from ...core.unchecked_base_model import construct_type
9
9
  from ...errors.unprocessable_entity_error import UnprocessableEntityError
10
10
  from ...types.http_validation_error import HttpValidationError
11
11
  from json.decoder import JSONDecodeError
@@ -35,7 +35,7 @@ class PassagesClient:
35
35
 
36
36
  Examples
37
37
  --------
38
- from letta import Letta
38
+ from letta_client import Letta
39
39
 
40
40
  client = Letta(
41
41
  token="YOUR_TOKEN",
@@ -53,7 +53,7 @@ class PassagesClient:
53
53
  if 200 <= _response.status_code < 300:
54
54
  return typing.cast(
55
55
  typing.List[Passage],
56
- parse_obj_as(
56
+ construct_type(
57
57
  type_=typing.List[Passage], # type: ignore
58
58
  object_=_response.json(),
59
59
  ),
@@ -62,7 +62,7 @@ class PassagesClient:
62
62
  raise UnprocessableEntityError(
63
63
  typing.cast(
64
64
  HttpValidationError,
65
- parse_obj_as(
65
+ construct_type(
66
66
  type_=HttpValidationError, # type: ignore
67
67
  object_=_response.json(),
68
68
  ),
@@ -100,7 +100,7 @@ class AsyncPassagesClient:
100
100
  --------
101
101
  import asyncio
102
102
 
103
- from letta import AsyncLetta
103
+ from letta_client import AsyncLetta
104
104
 
105
105
  client = AsyncLetta(
106
106
  token="YOUR_TOKEN",
@@ -124,7 +124,7 @@ class AsyncPassagesClient:
124
124
  if 200 <= _response.status_code < 300:
125
125
  return typing.cast(
126
126
  typing.List[Passage],
127
- parse_obj_as(
127
+ construct_type(
128
128
  type_=typing.List[Passage], # type: ignore
129
129
  object_=_response.json(),
130
130
  ),
@@ -133,7 +133,7 @@ class AsyncPassagesClient:
133
133
  raise UnprocessableEntityError(
134
134
  typing.cast(
135
135
  HttpValidationError,
136
- parse_obj_as(
136
+ construct_type(
137
137
  type_=HttpValidationError, # type: ignore
138
138
  object_=_response.json(),
139
139
  ),
@@ -0,0 +1,2 @@
1
+ # This file was auto-generated by Fern from our API Definition.
2
+