letta-client 0.1.156__py3-none-any.whl → 0.1.157__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.
letta_client/__init__.py CHANGED
@@ -131,7 +131,6 @@ from .types import (
131
131
  LettaRequestConfig,
132
132
  LettaResponse,
133
133
  LettaStopReason,
134
- LettaStopReasonStopReason,
135
134
  LettaStreamingRequest,
136
135
  LettaUsageStatistics,
137
136
  LettaUserMessageContentUnion,
@@ -197,6 +196,7 @@ from .types import (
197
196
  SseServerConfig,
198
197
  StdioServerConfig,
199
198
  Step,
199
+ StopReasonType,
200
200
  SupervisorManager,
201
201
  SupervisorManagerUpdate,
202
202
  SystemMessage,
@@ -468,7 +468,6 @@ __all__ = [
468
468
  "LettaRequestConfig",
469
469
  "LettaResponse",
470
470
  "LettaStopReason",
471
- "LettaStopReasonStopReason",
472
471
  "LettaStreamingRequest",
473
472
  "LettaUsageStatistics",
474
473
  "LettaUserMessageContentUnion",
@@ -539,6 +538,7 @@ __all__ = [
539
538
  "SseServerConfig",
540
539
  "StdioServerConfig",
541
540
  "Step",
541
+ "StopReasonType",
542
542
  "SupervisorManager",
543
543
  "SupervisorManagerUpdate",
544
544
  "SystemMessage",
@@ -16,7 +16,7 @@ class BaseClientWrapper:
16
16
  headers: typing.Dict[str, str] = {
17
17
  "X-Fern-Language": "Python",
18
18
  "X-Fern-SDK-Name": "letta-client",
19
- "X-Fern-SDK-Version": "0.1.156",
19
+ "X-Fern-SDK-Version": "0.1.157",
20
20
  }
21
21
  if self.token is not None:
22
22
  headers["Authorization"] = f"Bearer {self.token}"
@@ -130,7 +130,6 @@ from .letta_request import LettaRequest
130
130
  from .letta_request_config import LettaRequestConfig
131
131
  from .letta_response import LettaResponse
132
132
  from .letta_stop_reason import LettaStopReason
133
- from .letta_stop_reason_stop_reason import LettaStopReasonStopReason
134
133
  from .letta_streaming_request import LettaStreamingRequest
135
134
  from .letta_usage_statistics import LettaUsageStatistics
136
135
  from .letta_user_message_content_union import LettaUserMessageContentUnion
@@ -200,6 +199,7 @@ from .source import Source
200
199
  from .sse_server_config import SseServerConfig
201
200
  from .stdio_server_config import StdioServerConfig
202
201
  from .step import Step
202
+ from .stop_reason_type import StopReasonType
203
203
  from .supervisor_manager import SupervisorManager
204
204
  from .supervisor_manager_update import SupervisorManagerUpdate
205
205
  from .system_message import SystemMessage
@@ -378,7 +378,6 @@ __all__ = [
378
378
  "LettaRequestConfig",
379
379
  "LettaResponse",
380
380
  "LettaStopReason",
381
- "LettaStopReasonStopReason",
382
381
  "LettaStreamingRequest",
383
382
  "LettaUsageStatistics",
384
383
  "LettaUserMessageContentUnion",
@@ -444,6 +443,7 @@ __all__ = [
444
443
  "SseServerConfig",
445
444
  "StdioServerConfig",
446
445
  "Step",
446
+ "StopReasonType",
447
447
  "SupervisorManager",
448
448
  "SupervisorManagerUpdate",
449
449
  "SystemMessage",
@@ -4,6 +4,7 @@ from ..core.unchecked_base_model import UncheckedBaseModel
4
4
  import typing
5
5
  from .letta_message_union import LettaMessageUnion
6
6
  import pydantic
7
+ from .letta_stop_reason import LettaStopReason
7
8
  from .letta_usage_statistics import LettaUsageStatistics
8
9
  from ..core.pydantic_utilities import IS_PYDANTIC_V2
9
10
 
@@ -23,6 +24,7 @@ class LettaResponse(UncheckedBaseModel):
23
24
  The messages returned by the agent.
24
25
  """
25
26
 
27
+ stop_reason: LettaStopReason
26
28
  usage: LettaUsageStatistics = pydantic.Field()
27
29
  """
28
30
  The usage statistics of the agent.
@@ -3,13 +3,13 @@
3
3
  from ..core.unchecked_base_model import UncheckedBaseModel
4
4
  import typing
5
5
  import pydantic
6
- from .letta_stop_reason_stop_reason import LettaStopReasonStopReason
6
+ from .stop_reason_type import StopReasonType
7
7
  from ..core.pydantic_utilities import IS_PYDANTIC_V2
8
8
 
9
9
 
10
10
  class LettaStopReason(UncheckedBaseModel):
11
11
  """
12
- Letta provided stop reason for why agent loop ended.
12
+ The stop reason from Letta indicating why agent loop stopped execution.
13
13
  """
14
14
 
15
15
  message_type: typing.Optional[typing.Literal["stop_reason"]] = pydantic.Field(default=None)
@@ -17,7 +17,10 @@ class LettaStopReason(UncheckedBaseModel):
17
17
  The type of the message.
18
18
  """
19
19
 
20
- stop_reason: LettaStopReasonStopReason
20
+ stop_reason: StopReasonType = pydantic.Field()
21
+ """
22
+ The reason why execution stopped.
23
+ """
21
24
 
22
25
  if IS_PYDANTIC_V2:
23
26
  model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
@@ -2,6 +2,6 @@
2
2
 
3
3
  import typing
4
4
 
5
- LettaStopReasonStopReason = typing.Union[
6
- typing.Literal["end_turn", "error", "invalid_tool_call", "max_steps", "no_tool_call"], typing.Any
5
+ StopReasonType = typing.Union[
6
+ typing.Literal["end_turn", "error", "invalid_tool_call", "max_steps", "no_tool_call", "tool_rule"], typing.Any
7
7
  ]
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: letta-client
3
- Version: 0.1.156
3
+ Version: 0.1.157
4
4
  Summary:
5
5
  Requires-Python: >=3.8,<4.0
6
6
  Classifier: Intended Audience :: Developers
@@ -1,4 +1,4 @@
1
- letta_client/__init__.py,sha256=7u0luArqfecdYLSMewasD0fxBxN9gF3fXJizNWKmwvQ,17318
1
+ letta_client/__init__.py,sha256=3sbezRbLEKZ-rnaS6-nXun5XE7OV0MRTHIsZV_0jhoQ,17296
2
2
  letta_client/agents/__init__.py,sha256=3oFWVxaaxkphkjGJVk31Llb9ll9dKoCGx3B_r3qqtes,1716
3
3
  letta_client/agents/blocks/__init__.py,sha256=FTtvy8EDg9nNNg9WCatVgKTRYV8-_v1roeGPAKoa_pw,65
4
4
  letta_client/agents/blocks/client.py,sha256=ecE03lE5tP1AtCMFLT9FzdYyQMx_D7NI5m42b41pV40,24684
@@ -62,7 +62,7 @@ letta_client/client_side_access_tokens/types/client_side_access_tokens_create_re
62
62
  letta_client/client_side_access_tokens/types/client_side_access_tokens_create_response_policy_data_item_access_item.py,sha256=R-H25IpNp9feSrW8Yj3h9O3UTMVvFniQJElogKxLuoE,254
63
63
  letta_client/core/__init__.py,sha256=OKbX2aCZXgHCDUsCouqv-OiX32xA6eFFCKIUH9M5Vzk,1591
64
64
  letta_client/core/api_error.py,sha256=RE8LELok2QCjABadECTvtDp7qejA1VmINCh6TbqPwSE,426
65
- letta_client/core/client_wrapper.py,sha256=qYScC7kO2sbo1qhstEPj1w5fdEAUL6BomWfIp4Nq42M,1998
65
+ letta_client/core/client_wrapper.py,sha256=9GkWd2xxe4Mx486XARKuDwdQ8DkirLsKAp8cOct4mTg,1998
66
66
  letta_client/core/datetime_utils.py,sha256=nBys2IsYrhPdszxGKCNRPSOCwa-5DWOHG95FB8G9PKo,1047
67
67
  letta_client/core/file.py,sha256=d4NNbX8XvXP32z8KpK2Xovv33nFfruIrpz0QWxlgpZk,2663
68
68
  letta_client/core/http_client.py,sha256=Z77OIxIbL4OAB2IDqjRq_sYa5yNYAWfmdhdCSSvh6Y4,19552
@@ -150,7 +150,7 @@ letta_client/tools/types/add_mcp_server_request.py,sha256=EieZjfOT95sjkpxXdqy7gl
150
150
  letta_client/tools/types/add_mcp_server_response_item.py,sha256=pb3A4IoP7Qpen0UDDniXrASYEJZWnYnnrZThtPkvZt4,270
151
151
  letta_client/tools/types/delete_mcp_server_response_item.py,sha256=hKc4uehqcubO8BzpgMlvk2jJAjHXOWRM_zmWsCz_vZE,273
152
152
  letta_client/tools/types/list_mcp_servers_response_value.py,sha256=AIoXu4bO8QNSU7zjL1jj0Rg4313wVtPaTt13W0aevLQ,273
153
- letta_client/types/__init__.py,sha256=2e-vGb4Xk9AWaVhsOBlh3DREgh3WfbAdEHPQUGvBnpY,21755
153
+ letta_client/types/__init__.py,sha256=4sJJKkC2a_9Tt-jwNSuO_he06cojsUlkYpk45V3cL3Q,21720
154
154
  letta_client/types/action_model.py,sha256=y1e2XMv3skFaNJIBdYoBKgiORzGh05aOVvu-qVR9uHg,1240
155
155
  letta_client/types/action_parameters_model.py,sha256=LgKf5aPZG3-OHGxFdXiSokIDgce8c02xPYIAY05VgW8,828
156
156
  letta_client/types/action_response_model.py,sha256=yq2Fd9UU8j7vvtE3VqXUoRRvDzWcfJPj_95ynGdeHCs,824
@@ -279,9 +279,8 @@ letta_client/types/letta_message_content_union.py,sha256=ypGyeR8PGqPGaAWtLWjDkWw
279
279
  letta_client/types/letta_message_union.py,sha256=TTQwlur2CZNdZ466Nb_2TFcSFXrgoMliaNzD33t7Ktw,603
280
280
  letta_client/types/letta_request.py,sha256=vhS3qQYxNN2dlE_kXWPW3BJekBDMTSRp1MXmj4-ztfQ,1659
281
281
  letta_client/types/letta_request_config.py,sha256=b6K4QtDdHjcZKfBb1fugUuoPrT2N4d5TTB0PIRNI2SU,1085
282
- letta_client/types/letta_response.py,sha256=i5gAUTgWzIst_RP8I_zSh0GSnLIS3z--1BmK6EF1mkQ,1315
283
- letta_client/types/letta_stop_reason.py,sha256=urH4dc6Y6o_5rS8shE-qiUgBs1cM6DmCyTgrTNPXiN0,874
284
- letta_client/types/letta_stop_reason_stop_reason.py,sha256=cssk6ZibCFcf4sR6O71fC1kasDxuul5WntxLIIaRdZU,226
282
+ letta_client/types/letta_response.py,sha256=5brJ39B8PxTBpm5_clL9XGP1SQ1pox-G0gxMDkitMlw,1395
283
+ letta_client/types/letta_stop_reason.py,sha256=5uqJibhaT6LFTj6Sf6m0VJKS1FJzIIgymjZTvu2a0Zk,931
285
284
  letta_client/types/letta_streaming_request.py,sha256=YJ_6ge5xrzQjOs2UTY3FxwhTv6QoCi9XWv5Rod01W1E,1884
286
285
  letta_client/types/letta_usage_statistics.py,sha256=k6V72J2TEPd-RQBuUQxF3oylrAMcuSKBskd2nnZmGOw,1886
287
286
  letta_client/types/letta_user_message_content_union.py,sha256=3Gbs3mRk-tJj2z0Mf-BNDomWHEytQd3OTUN4xnEVsuE,229
@@ -347,6 +346,7 @@ letta_client/types/source.py,sha256=BsfE9yrefXREQtskGZnR-TFGqmHkFKIGHC5udtHUi14,
347
346
  letta_client/types/sse_server_config.py,sha256=b-h5FLm5MELZ5A9bwZt-02Zx_f3UbfKAQS--yHQVOQU,844
348
347
  letta_client/types/stdio_server_config.py,sha256=dEQ7bguiLikGemLxYZJ3JCmmEQgAMsSPO_P52oHZSl0,1091
349
348
  letta_client/types/step.py,sha256=-5KHfBc6NZnYGLXHJMK6Bdyw2ae0G1zPFzsURjPiN3c,3133
349
+ letta_client/types/stop_reason_type.py,sha256=PyYTS9bIvCSDfzyG4wJyk6bi9fCdDBNsoleLd7nMJYI,228
350
350
  letta_client/types/supervisor_manager.py,sha256=VdR1ySp4k43apxM8Bb5uNoBvADsvz8oMEEtDy2F5K6M,676
351
351
  letta_client/types/supervisor_manager_update.py,sha256=UJ_TcWcF_PK152Gni0tgRCe3bthCgJbQHCZIb5LLsL0,711
352
352
  letta_client/types/system_message.py,sha256=Dn1GkT1INUGLHkwBsqJL0HtkcGXx0CAKqzSl34jZ4xM,1302
@@ -398,6 +398,6 @@ letta_client/voice/__init__.py,sha256=7hX85553PiRMtIMM12a0DSoFzsglNiUziYR2ekS84Q
398
398
  letta_client/voice/client.py,sha256=STjswa5oOLoP59QwTJvQwi73kgn0UzKOaXc2CsTRI4k,6912
399
399
  letta_client/voice/types/__init__.py,sha256=FRc3iKRTONE4N8Lf1IqvnqWZ2kXdrFFvkL7PxVcR8Ew,212
400
400
  letta_client/voice/types/create_voice_chat_completions_request_body.py,sha256=ZLfKgNK1T6IAwLEvaBVFfy7jEAoPUXP28n-nfmHkklc,391
401
- letta_client-0.1.156.dist-info/METADATA,sha256=bc9GJPKvPfTNAESMSJeKDYwYoA_bAEnh-rlEWHEyAU8,5093
402
- letta_client-0.1.156.dist-info/WHEEL,sha256=Zb28QaM1gQi8f4VCBhsUklF61CTlNYfs9YAZn-TOGFk,88
403
- letta_client-0.1.156.dist-info/RECORD,,
401
+ letta_client-0.1.157.dist-info/METADATA,sha256=w7z6ETlR-Zej8k3g0BRow7q-pGW1J-Lb6heUnwbnZpQ,5093
402
+ letta_client-0.1.157.dist-info/WHEEL,sha256=Zb28QaM1gQi8f4VCBhsUklF61CTlNYfs9YAZn-TOGFk,88
403
+ letta_client-0.1.157.dist-info/RECORD,,