letta-nightly 0.11.7.dev20250917104122__py3-none-any.whl → 0.11.7.dev20250918104055__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/agent.py +3 -3
- letta/agents/agent_loop.py +2 -1
- letta/agents/base_agent.py +1 -1
- letta/agents/letta_agent_v2.py +3 -3
- letta/agents/temporal/activities/__init__.py +4 -0
- letta/agents/temporal/activities/example_activity.py +7 -0
- letta/agents/temporal/activities/prepare_messages.py +10 -0
- letta/agents/temporal/temporal_agent_workflow.py +56 -0
- letta/agents/temporal/types.py +25 -0
- letta/agents/voice_agent.py +2 -2
- letta/orm/agent.py +4 -3
- letta/prompts/prompt_generator.py +4 -4
- letta/schemas/agent.py +4 -193
- letta/schemas/enums.py +15 -0
- letta/schemas/memory.py +216 -103
- letta/schemas/step.py +5 -1
- letta/schemas/tool_rule.py +34 -44
- letta/server/rest_api/routers/v1/steps.py +29 -0
- letta/server/server.py +2 -2
- letta/services/agent_manager.py +4 -6
- letta/services/helpers/agent_manager_helper.py +4 -4
- letta/services/step_manager.py +26 -0
- letta/services/summarizer/summarizer.py +25 -3
- letta/services/tool_executor/sandbox_tool_executor.py +2 -2
- letta/services/tool_sandbox/base.py +135 -8
- letta/settings.py +2 -2
- {letta_nightly-0.11.7.dev20250917104122.dist-info → letta_nightly-0.11.7.dev20250918104055.dist-info}/METADATA +2 -2
- {letta_nightly-0.11.7.dev20250917104122.dist-info → letta_nightly-0.11.7.dev20250918104055.dist-info}/RECORD +31 -27
- letta/templates/template_helper.py +0 -53
- {letta_nightly-0.11.7.dev20250917104122.dist-info → letta_nightly-0.11.7.dev20250918104055.dist-info}/WHEEL +0 -0
- {letta_nightly-0.11.7.dev20250917104122.dist-info → letta_nightly-0.11.7.dev20250918104055.dist-info}/entry_points.txt +0 -0
- {letta_nightly-0.11.7.dev20250917104122.dist-info → letta_nightly-0.11.7.dev20250918104055.dist-info}/licenses/LICENSE +0 -0
letta/services/agent_manager.py
CHANGED
@@ -50,15 +50,13 @@ from letta.otel.tracing import trace_method
|
|
50
50
|
from letta.prompts.prompt_generator import PromptGenerator
|
51
51
|
from letta.schemas.agent import (
|
52
52
|
AgentState as PydanticAgentState,
|
53
|
-
AgentType,
|
54
53
|
CreateAgent,
|
55
54
|
InternalTemplateAgentCreate,
|
56
55
|
UpdateAgent,
|
57
|
-
get_prompt_template_for_agent_type,
|
58
56
|
)
|
59
57
|
from letta.schemas.block import DEFAULT_BLOCKS, Block as PydanticBlock, BlockUpdate
|
60
58
|
from letta.schemas.embedding_config import EmbeddingConfig
|
61
|
-
from letta.schemas.enums import ProviderType, TagMatchMode, ToolType, VectorDBProvider
|
59
|
+
from letta.schemas.enums import AgentType, ProviderType, TagMatchMode, ToolType, VectorDBProvider
|
62
60
|
from letta.schemas.file import FileMetadata as PydanticFileMetadata
|
63
61
|
from letta.schemas.group import Group as PydanticGroup, ManagerType
|
64
62
|
from letta.schemas.llm_config import LLMConfig
|
@@ -1794,7 +1792,7 @@ class AgentManager:
|
|
1794
1792
|
|
1795
1793
|
# note: we only update the system prompt if the core memory is changed
|
1796
1794
|
# this means that the archival/recall memory statistics may be someout out of date
|
1797
|
-
curr_memory_str =
|
1795
|
+
curr_memory_str = agent_state.memory.compile(
|
1798
1796
|
sources=agent_state.sources,
|
1799
1797
|
tool_usage_rules=tool_rules_solver.compile_tool_rule_prompts(),
|
1800
1798
|
max_files_open=agent_state.max_files_open,
|
@@ -1984,7 +1982,7 @@ class AgentManager:
|
|
1984
1982
|
agent_state = await self.get_agent_by_id_async(agent_id=agent_id, actor=actor, include_relationships=["memory", "sources"])
|
1985
1983
|
system_message = await self.message_manager.get_message_by_id_async(message_id=agent_state.message_ids[0], actor=actor)
|
1986
1984
|
temp_tool_rules_solver = ToolRulesSolver(agent_state.tool_rules)
|
1987
|
-
new_memory_str =
|
1985
|
+
new_memory_str = new_memory.compile(
|
1988
1986
|
sources=agent_state.sources,
|
1989
1987
|
tool_usage_rules=temp_tool_rules_solver.compile_tool_rule_prompts(),
|
1990
1988
|
max_files_open=agent_state.max_files_open,
|
@@ -2008,7 +2006,7 @@ class AgentManager:
|
|
2008
2006
|
agent_state.memory = Memory(
|
2009
2007
|
blocks=blocks,
|
2010
2008
|
file_blocks=agent_state.memory.file_blocks,
|
2011
|
-
|
2009
|
+
agent_type=agent_state.agent_type,
|
2012
2010
|
)
|
2013
2011
|
|
2014
2012
|
# NOTE: don't do this since re-buildin the memory is handled at the start of the step
|
@@ -32,9 +32,9 @@ from letta.orm.sources_agents import SourcesAgents
|
|
32
32
|
from letta.otel.tracing import trace_method
|
33
33
|
from letta.prompts import gpt_system
|
34
34
|
from letta.prompts.prompt_generator import PromptGenerator
|
35
|
-
from letta.schemas.agent import AgentState
|
35
|
+
from letta.schemas.agent import AgentState
|
36
36
|
from letta.schemas.embedding_config import EmbeddingConfig
|
37
|
-
from letta.schemas.enums import MessageRole
|
37
|
+
from letta.schemas.enums import AgentType, MessageRole
|
38
38
|
from letta.schemas.letta_message_content import TextContent
|
39
39
|
from letta.schemas.memory import Memory
|
40
40
|
from letta.schemas.message import Message, MessageCreate
|
@@ -245,7 +245,7 @@ def compile_system_message(
|
|
245
245
|
timezone: str,
|
246
246
|
user_defined_variables: Optional[dict] = None,
|
247
247
|
append_icm_if_missing: bool = True,
|
248
|
-
template_format: Literal["f-string", "mustache"
|
248
|
+
template_format: Literal["f-string", "mustache"] = "f-string",
|
249
249
|
previous_message_count: int = 0,
|
250
250
|
archival_memory_size: int | None = 0,
|
251
251
|
tool_rules_solver: Optional[ToolRulesSolver] = None,
|
@@ -311,7 +311,7 @@ def compile_system_message(
|
|
311
311
|
raise ValueError(f"Failed to format system prompt - {str(e)}. System prompt value:\n{system_prompt}")
|
312
312
|
|
313
313
|
else:
|
314
|
-
# TODO support for mustache
|
314
|
+
# TODO support for mustache
|
315
315
|
raise NotImplementedError(template_format)
|
316
316
|
|
317
317
|
return formatted_prompt
|
letta/services/step_manager.py
CHANGED
@@ -9,12 +9,14 @@ from sqlalchemy.orm import Session
|
|
9
9
|
from letta.helpers.singleton import singleton
|
10
10
|
from letta.orm.errors import NoResultFound
|
11
11
|
from letta.orm.job import Job as JobModel
|
12
|
+
from letta.orm.message import Message as MessageModel
|
12
13
|
from letta.orm.sqlalchemy_base import AccessType
|
13
14
|
from letta.orm.step import Step as StepModel
|
14
15
|
from letta.orm.step_metrics import StepMetrics as StepMetricsModel
|
15
16
|
from letta.otel.tracing import get_trace_id, trace_method
|
16
17
|
from letta.schemas.enums import StepStatus
|
17
18
|
from letta.schemas.letta_stop_reason import LettaStopReason, StopReasonType
|
19
|
+
from letta.schemas.message import Message as PydanticMessage
|
18
20
|
from letta.schemas.openai.chat_completion_response import UsageStatistics
|
19
21
|
from letta.schemas.step import Step as PydanticStep
|
20
22
|
from letta.schemas.step_metrics import StepMetrics as PydanticStepMetrics
|
@@ -237,6 +239,30 @@ class StepManager:
|
|
237
239
|
await session.commit()
|
238
240
|
return step.to_pydantic()
|
239
241
|
|
242
|
+
@enforce_types
|
243
|
+
@trace_method
|
244
|
+
async def list_step_messages_async(
|
245
|
+
self,
|
246
|
+
step_id: str,
|
247
|
+
actor: PydanticUser,
|
248
|
+
before: str | None = None,
|
249
|
+
after: str | None = None,
|
250
|
+
limit: int = 100,
|
251
|
+
ascending: bool = False,
|
252
|
+
) -> List[PydanticMessage]:
|
253
|
+
async with db_registry.async_session() as session:
|
254
|
+
messages = MessageModel.list(
|
255
|
+
db_session=session,
|
256
|
+
before=before,
|
257
|
+
after=after,
|
258
|
+
ascending=ascending,
|
259
|
+
limit=limit,
|
260
|
+
actor=actor,
|
261
|
+
join_model=StepModel,
|
262
|
+
join_conditions=[MessageModel.step.id == step_id],
|
263
|
+
)
|
264
|
+
return [message.to_pydantic() for message in messages]
|
265
|
+
|
240
266
|
@enforce_types
|
241
267
|
@trace_method
|
242
268
|
async def update_step_stop_reason(self, actor: PydanticUser, step_id: str, stop_reason: StopReasonType) -> PydanticStep:
|
@@ -19,7 +19,6 @@ from letta.services.agent_manager import AgentManager
|
|
19
19
|
from letta.services.message_manager import MessageManager
|
20
20
|
from letta.services.summarizer.enums import SummarizationMode
|
21
21
|
from letta.system import package_summarize_message_no_counts
|
22
|
-
from letta.templates.template_helper import render_template
|
23
22
|
from letta.utils import safe_create_task
|
24
23
|
|
25
24
|
logger = get_logger(__name__)
|
@@ -280,8 +279,7 @@ class Summarizer:
|
|
280
279
|
formatted_evicted_messages = [f"{i}. {msg}" for (i, msg) in enumerate(formatted_evicted_messages)]
|
281
280
|
formatted_in_context_messages = [f"{i + offset}. {msg}" for (i, msg) in enumerate(formatted_in_context_messages)]
|
282
281
|
|
283
|
-
summary_request_text =
|
284
|
-
"summary_request_text.j2",
|
282
|
+
summary_request_text = build_summary_request_text(
|
285
283
|
retain_count=retain_count,
|
286
284
|
evicted_messages=formatted_evicted_messages,
|
287
285
|
in_context_messages=formatted_in_context_messages,
|
@@ -304,6 +302,30 @@ def simple_formatter(messages: List[Message], include_system: bool = False) -> s
|
|
304
302
|
return "\n".join(json.dumps(msg) for msg in parsed_messages)
|
305
303
|
|
306
304
|
|
305
|
+
def build_summary_request_text(retain_count: int, evicted_messages: List[str], in_context_messages: List[str]) -> str:
|
306
|
+
parts: List[str] = []
|
307
|
+
if retain_count == 0:
|
308
|
+
parts.append(
|
309
|
+
"You’re a memory-recall helper for an AI that is about to forget all prior messages. Scan the conversation history and write crisp notes that capture any important facts or insights about the conversation history."
|
310
|
+
)
|
311
|
+
else:
|
312
|
+
parts.append(
|
313
|
+
f"You’re a memory-recall helper for an AI that can only keep the last {retain_count} messages. Scan the conversation history, focusing on messages about to drop out of that window, and write crisp notes that capture any important facts or insights about the human so they aren’t lost."
|
314
|
+
)
|
315
|
+
|
316
|
+
if evicted_messages:
|
317
|
+
parts.append("\n(Older) Evicted Messages:")
|
318
|
+
for item in evicted_messages:
|
319
|
+
parts.append(f" {item}")
|
320
|
+
|
321
|
+
if retain_count > 0 and in_context_messages:
|
322
|
+
parts.append("\n(Newer) In-Context Messages:")
|
323
|
+
for item in in_context_messages:
|
324
|
+
parts.append(f" {item}")
|
325
|
+
|
326
|
+
return "\n".join(parts) + "\n"
|
327
|
+
|
328
|
+
|
307
329
|
def simple_message_wrapper(openai_msg: dict) -> Message:
|
308
330
|
"""Extremely simple way to map from role/content to Message object w/ throwaway dummy fields"""
|
309
331
|
|
@@ -36,7 +36,7 @@ class SandboxToolExecutor(ToolExecutor):
|
|
36
36
|
) -> ToolExecutionResult:
|
37
37
|
# Store original memory state
|
38
38
|
if agent_state:
|
39
|
-
orig_memory_str =
|
39
|
+
orig_memory_str = agent_state.memory.compile()
|
40
40
|
else:
|
41
41
|
orig_memory_str = None
|
42
42
|
|
@@ -89,7 +89,7 @@ class SandboxToolExecutor(ToolExecutor):
|
|
89
89
|
|
90
90
|
# Verify memory integrity
|
91
91
|
if agent_state:
|
92
|
-
new_memory_str =
|
92
|
+
new_memory_str = agent_state.memory.compile()
|
93
93
|
assert orig_memory_str == new_memory_str, "Memory should not be modified in a sandbox tool"
|
94
94
|
|
95
95
|
# Update agent memory if needed
|
@@ -13,7 +13,6 @@ from letta.services.helpers.tool_execution_helper import add_imports_and_pydanti
|
|
13
13
|
from letta.services.helpers.tool_parser_helper import convert_param_to_str_value, parse_function_arguments
|
14
14
|
from letta.services.sandbox_config_manager import SandboxConfigManager
|
15
15
|
from letta.services.tool_manager import ToolManager
|
16
|
-
from letta.templates.template_helper import render_template
|
17
16
|
from letta.types import JsonDict, JsonValue
|
18
17
|
|
19
18
|
|
@@ -79,11 +78,8 @@ class AsyncToolSandboxBase(ABC):
|
|
79
78
|
async def generate_execution_script(self, agent_state: Optional[AgentState], wrap_print_with_markers: bool = False) -> str:
|
80
79
|
"""
|
81
80
|
Generate code to run inside of execution sandbox. Serialize the agent state and arguments, call the tool,
|
82
|
-
then base64-encode/pickle the result.
|
81
|
+
then base64-encode/pickle the result. Constructs the python file.
|
83
82
|
"""
|
84
|
-
# Select the appropriate template based on whether the function is async
|
85
|
-
TEMPLATE_NAME = "sandbox_code_file_async.py.j2" if self.is_async_function else "sandbox_code_file.py.j2"
|
86
|
-
|
87
83
|
future_import = False
|
88
84
|
schema_code = None
|
89
85
|
|
@@ -106,11 +102,10 @@ class AsyncToolSandboxBase(ABC):
|
|
106
102
|
|
107
103
|
agent_state_pickle = pickle.dumps(agent_state) if self.inject_agent_state else None
|
108
104
|
|
109
|
-
|
110
|
-
TEMPLATE_NAME,
|
105
|
+
code = self._render_sandbox_code(
|
111
106
|
future_import=future_import,
|
112
107
|
inject_agent_state=self.inject_agent_state,
|
113
|
-
schema_imports=schema_code,
|
108
|
+
schema_imports=schema_code or "",
|
114
109
|
agent_state_pickle=agent_state_pickle,
|
115
110
|
tool_args=tool_args,
|
116
111
|
tool_source_code=self.tool.source_code,
|
@@ -120,6 +115,138 @@ class AsyncToolSandboxBase(ABC):
|
|
120
115
|
start_marker=self.LOCAL_SANDBOX_RESULT_START_MARKER,
|
121
116
|
use_top_level_await=self.use_top_level_await(),
|
122
117
|
)
|
118
|
+
return code
|
119
|
+
|
120
|
+
def _render_sandbox_code(
|
121
|
+
self,
|
122
|
+
*,
|
123
|
+
future_import: bool,
|
124
|
+
inject_agent_state: bool,
|
125
|
+
schema_imports: str,
|
126
|
+
agent_state_pickle: bytes | None,
|
127
|
+
tool_args: str,
|
128
|
+
tool_source_code: str,
|
129
|
+
local_sandbox_result_var_name: str,
|
130
|
+
invoke_function_call: str,
|
131
|
+
wrap_print_with_markers: bool,
|
132
|
+
start_marker: bytes,
|
133
|
+
use_top_level_await: bool,
|
134
|
+
) -> str:
|
135
|
+
lines: list[str] = []
|
136
|
+
if future_import:
|
137
|
+
lines.append("from __future__ import annotations")
|
138
|
+
lines.extend(
|
139
|
+
[
|
140
|
+
"from typing import *",
|
141
|
+
"import pickle",
|
142
|
+
"import sys",
|
143
|
+
"import base64",
|
144
|
+
"import struct",
|
145
|
+
"import hashlib",
|
146
|
+
]
|
147
|
+
)
|
148
|
+
if self.is_async_function:
|
149
|
+
lines.append("import asyncio")
|
150
|
+
|
151
|
+
if inject_agent_state:
|
152
|
+
lines.extend(["import letta", "from letta import *"]) # noqa: F401
|
153
|
+
|
154
|
+
if schema_imports:
|
155
|
+
lines.append(schema_imports.rstrip())
|
156
|
+
|
157
|
+
if agent_state_pickle is not None:
|
158
|
+
lines.append(f"agent_state = pickle.loads({repr(agent_state_pickle)})")
|
159
|
+
else:
|
160
|
+
lines.append("agent_state = None")
|
161
|
+
|
162
|
+
if tool_args:
|
163
|
+
lines.append(tool_args.rstrip())
|
164
|
+
|
165
|
+
if tool_source_code:
|
166
|
+
lines.append(tool_source_code.rstrip())
|
167
|
+
|
168
|
+
if not self.is_async_function:
|
169
|
+
# sync variant
|
170
|
+
lines.append(f"_function_result = {invoke_function_call}")
|
171
|
+
lines.extend(
|
172
|
+
[
|
173
|
+
"try:",
|
174
|
+
" from pydantic import BaseModel, ConfigDict",
|
175
|
+
" from typing import Any",
|
176
|
+
"",
|
177
|
+
" class _TempResultWrapper(BaseModel):",
|
178
|
+
" model_config = ConfigDict(arbitrary_types_allowed=True)",
|
179
|
+
" result: Any",
|
180
|
+
"",
|
181
|
+
" _wrapped = _TempResultWrapper(result=_function_result)",
|
182
|
+
" _serialized_result = _wrapped.model_dump()['result']",
|
183
|
+
"except ImportError:",
|
184
|
+
' print("Pydantic not available in sandbox environment, falling back to string conversion")',
|
185
|
+
" _serialized_result = str(_function_result)",
|
186
|
+
"except Exception as e:",
|
187
|
+
' print(f"Failed to serialize result with Pydantic wrapper: {e}")',
|
188
|
+
" _serialized_result = str(_function_result)",
|
189
|
+
"",
|
190
|
+
f"{local_sandbox_result_var_name} = {{",
|
191
|
+
' "results": _serialized_result,',
|
192
|
+
' "agent_state": agent_state',
|
193
|
+
"}",
|
194
|
+
f"{local_sandbox_result_var_name}_pkl = pickle.dumps({local_sandbox_result_var_name})",
|
195
|
+
]
|
196
|
+
)
|
197
|
+
else:
|
198
|
+
# async variant
|
199
|
+
lines.extend(
|
200
|
+
[
|
201
|
+
"async def _async_wrapper():",
|
202
|
+
f" _function_result = await {invoke_function_call}",
|
203
|
+
" try:",
|
204
|
+
" from pydantic import BaseModel, ConfigDict",
|
205
|
+
" from typing import Any",
|
206
|
+
"",
|
207
|
+
" class _TempResultWrapper(BaseModel):",
|
208
|
+
" model_config = ConfigDict(arbitrary_types_allowed=True)",
|
209
|
+
" result: Any",
|
210
|
+
"",
|
211
|
+
" _wrapped = _TempResultWrapper(result=_function_result)",
|
212
|
+
" _serialized_result = _wrapped.model_dump()['result']",
|
213
|
+
" except ImportError:",
|
214
|
+
' print("Pydantic not available in sandbox environment, falling back to string conversion")',
|
215
|
+
" _serialized_result = str(_function_result)",
|
216
|
+
" except Exception as e:",
|
217
|
+
' print(f"Failed to serialize result with Pydantic wrapper: {e}")',
|
218
|
+
" _serialized_result = str(_function_result)",
|
219
|
+
"",
|
220
|
+
" return {",
|
221
|
+
' "results": _serialized_result,',
|
222
|
+
' "agent_state": agent_state',
|
223
|
+
" }",
|
224
|
+
]
|
225
|
+
)
|
226
|
+
if use_top_level_await:
|
227
|
+
lines.append(f"{local_sandbox_result_var_name} = await _async_wrapper()")
|
228
|
+
else:
|
229
|
+
lines.append(f"{local_sandbox_result_var_name} = asyncio.run(_async_wrapper())")
|
230
|
+
lines.append(f"{local_sandbox_result_var_name}_pkl = pickle.dumps({local_sandbox_result_var_name})")
|
231
|
+
|
232
|
+
if wrap_print_with_markers:
|
233
|
+
lines.extend(
|
234
|
+
[
|
235
|
+
f"data_checksum = hashlib.md5({local_sandbox_result_var_name}_pkl).hexdigest().encode('ascii')",
|
236
|
+
f"{local_sandbox_result_var_name}_msg = (",
|
237
|
+
f" {repr(start_marker)} +",
|
238
|
+
f" struct.pack('>I', len({local_sandbox_result_var_name}_pkl)) +",
|
239
|
+
" data_checksum +",
|
240
|
+
f" {local_sandbox_result_var_name}_pkl",
|
241
|
+
")",
|
242
|
+
f"sys.stdout.buffer.write({local_sandbox_result_var_name}_msg)",
|
243
|
+
"sys.stdout.buffer.flush()",
|
244
|
+
]
|
245
|
+
)
|
246
|
+
else:
|
247
|
+
lines.append(f"base64.b64encode({local_sandbox_result_var_name}_pkl).decode('utf-8')")
|
248
|
+
|
249
|
+
return "\n".join(lines) + "\n"
|
123
250
|
|
124
251
|
def initialize_param(self, name: str, raw_value: JsonValue) -> str:
|
125
252
|
"""
|
letta/settings.py
CHANGED
@@ -42,8 +42,8 @@ class ToolSettings(BaseSettings):
|
|
42
42
|
def sandbox_type(self) -> SandboxType:
|
43
43
|
if self.e2b_api_key:
|
44
44
|
return SandboxType.E2B
|
45
|
-
elif self.modal_token_id and self.modal_token_secret:
|
46
|
-
|
45
|
+
# elif self.modal_token_id and self.modal_token_secret:
|
46
|
+
# return SandboxType.MODAL
|
47
47
|
else:
|
48
48
|
return SandboxType.LOCAL
|
49
49
|
|
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.4
|
2
2
|
Name: letta-nightly
|
3
|
-
Version: 0.11.7.
|
3
|
+
Version: 0.11.7.dev20250918104055
|
4
4
|
Summary: Create LLM agents with long-term memory and custom tools
|
5
5
|
Author-email: Letta Team <contact@letta.com>
|
6
6
|
License: Apache License
|
@@ -25,7 +25,6 @@ Requires-Dist: grpcio>=1.68.1
|
|
25
25
|
Requires-Dist: html2text>=2020.1.16
|
26
26
|
Requires-Dist: httpx-sse>=0.4.0
|
27
27
|
Requires-Dist: httpx>=0.28.0
|
28
|
-
Requires-Dist: jinja2>=3.1.5
|
29
28
|
Requires-Dist: letta-client>=0.1.319
|
30
29
|
Requires-Dist: llama-index-embeddings-openai>=0.3.1
|
31
30
|
Requires-Dist: llama-index>=0.12.2
|
@@ -64,6 +63,7 @@ Requires-Dist: sqlalchemy[asyncio]>=2.0.41
|
|
64
63
|
Requires-Dist: sqlmodel>=0.0.16
|
65
64
|
Requires-Dist: structlog>=25.4.0
|
66
65
|
Requires-Dist: tavily-python>=0.7.2
|
66
|
+
Requires-Dist: temporalio>=1.8.0
|
67
67
|
Requires-Dist: tqdm>=4.66.1
|
68
68
|
Requires-Dist: trafilatura
|
69
69
|
Requires-Dist: typer>=0.15.2
|
@@ -1,5 +1,5 @@
|
|
1
1
|
letta/__init__.py,sha256=ZwTfnKwttBN_OlSwb4a3-r8foHZiqx9VfpbsM3BT7xA,1620
|
2
|
-
letta/agent.py,sha256=
|
2
|
+
letta/agent.py,sha256=xP13DDysFq-h3Ny7DiTN5ZC2txRripMNvPFt8dfFDbE,89498
|
3
3
|
letta/config.py,sha256=JFGY4TWW0Wm5fTbZamOwWqk5G8Nn-TXyhgByGoAqy2c,12375
|
4
4
|
letta/constants.py,sha256=8QzePPRAQvlC2diFt4v_HhD_x8MNbvWFe5Ad40SqNA8,16195
|
5
5
|
letta/embeddings.py,sha256=d2o1nOVTaofBk6j-WwsE0_ugvxa1nIOcceqGuJ4w_pc,2045
|
@@ -9,7 +9,7 @@ letta/log.py,sha256=-hkEaSIru3cvO8ynHPWb91jemJHzgWjmVc3fqGJrjvU,2294
|
|
9
9
|
letta/main.py,sha256=wj4cawl4HP2ok-CqKVvqzSiOMahHC4t8FWxvuKKTWUA,317
|
10
10
|
letta/memory.py,sha256=l5iNhLAR_xzgTb0GBlQx4SVgH8kuZh8siJdC_CFPKEs,4278
|
11
11
|
letta/pytest.ini,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
12
|
-
letta/settings.py,sha256=
|
12
|
+
letta/settings.py,sha256=u-OL3mxyenrz_tVEw-1eZnV7W0osVFfQysXczq7IiGA,15014
|
13
13
|
letta/streaming_interface.py,sha256=rPMfwUcjqITWk2tVqFQm1hmP99tU2IOHg9gU2dgPSo8,16400
|
14
14
|
letta/streaming_utils.py,sha256=ZRFGFpQqn9ujCEbgZdLM7yTjiuNNvqQ47sNhV8ix-yQ,16553
|
15
15
|
letta/system.py,sha256=kHF7n3Viq7gV5UIUEXixod2gWa2jroUgztpEzMC1Sew,8925
|
@@ -18,8 +18,8 @@ letta/adapters/letta_llm_adapter.py,sha256=11wkOkEQfPXUuJoJxbK22wCa-8gnWiDAb3UOX
|
|
18
18
|
letta/adapters/letta_llm_request_adapter.py,sha256=Hv4Ox55KQ79qisNyCV1vrAz4mPnPRZQKksl6CdHgPgA,4772
|
19
19
|
letta/adapters/letta_llm_stream_adapter.py,sha256=4sCjBF_KvuWUad2pAAtlnwUmLO8H356tV8RcAY5Y_90,7599
|
20
20
|
letta/agents/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
21
|
-
letta/agents/agent_loop.py,sha256=
|
22
|
-
letta/agents/base_agent.py,sha256=
|
21
|
+
letta/agents/agent_loop.py,sha256=aXPcTuGrqllmw-3Fl8z_PKzRIusVzO5WhiLySqLPOs0,885
|
22
|
+
letta/agents/base_agent.py,sha256=TAc5quD9KRMKOurz_-ZHoAPZe13ZWFlE6sDjaPqN-fk,8518
|
23
23
|
letta/agents/base_agent_v2.py,sha256=t7XtUv3RZNvKwk1uqmSKxAV_2ZGSXYektlzyhXB3N-M,2558
|
24
24
|
letta/agents/ephemeral_agent.py,sha256=el-SUF_16vv_7OouIR-6z0pAE9Yc0PLibygvfCKwqfo,2736
|
25
25
|
letta/agents/ephemeral_summary_agent.py,sha256=tOldA_daa_PduTJ2RA7fAo9Rv6sUb-C_9dJaD6iujS4,4454
|
@@ -27,9 +27,14 @@ letta/agents/exceptions.py,sha256=BQY4D4w32OYHM63CM19ko7dPwZiAzUs3NbKvzmCTcJg,31
|
|
27
27
|
letta/agents/helpers.py,sha256=eCHsvZEkTe0L_uZHYkfNAztsEJW0FTnKZMgVbqlI0Yg,11618
|
28
28
|
letta/agents/letta_agent.py,sha256=-qLbq_vuQnT_EpJoR4uT-4s6NLvNZl_J4U4N771eU6E,99236
|
29
29
|
letta/agents/letta_agent_batch.py,sha256=17RpYVXpGh9dlKxdMOLMCOHWFsi6N5S9FJHxooxkJCI,27998
|
30
|
-
letta/agents/letta_agent_v2.py,sha256=
|
31
|
-
letta/agents/voice_agent.py,sha256=
|
30
|
+
letta/agents/letta_agent_v2.py,sha256=XnuX5wb_tr3ybWnMdlg47dPoKFYVg-OZ_IX2zHgrYXI,59992
|
31
|
+
letta/agents/voice_agent.py,sha256=DlmpObZ2vHIsO4NPOCpOQ0NmCY6umwaubESRHN3o_f8,23357
|
32
32
|
letta/agents/voice_sleeptime_agent.py,sha256=_JzCbWBOKrmo1cTaqZFTrQudpJEapwAyrXYtAHUILGo,8675
|
33
|
+
letta/agents/temporal/temporal_agent_workflow.py,sha256=b_2G5_5zpBcsOHT_hHEX7u-a1ms3D1Sdb1Eiu-UrSCY,2224
|
34
|
+
letta/agents/temporal/types.py,sha256=dUPgEnx-s8ftL7dtygqSz0ODKV_t1Kq3qzqUF_ax8ak,663
|
35
|
+
letta/agents/temporal/activities/__init__.py,sha256=c_qgOfdf7gBrf-TilUhyoNcopV0qccJhkFy6VvI86Co,153
|
36
|
+
letta/agents/temporal/activities/example_activity.py,sha256=FKevH3E-AQAvzpNPI3XflTgyA5ultTiQTLSnBmsYo0I,231
|
37
|
+
letta/agents/temporal/activities/prepare_messages.py,sha256=0BQRvO8FJ8Jp4O04ExcYEfpNRxrAuH_NKJ4_IgXjSMY,323
|
33
38
|
letta/cli/cli.py,sha256=tKtghlX36Rp0_HbkMosvlAapL07JXhA0vKLGTNKnxSQ,1615
|
34
39
|
letta/cli/cli_load.py,sha256=paAyDq6e-8D1ZWo8JvXIiA1N7FeKcQMSWgcr2vU_1Gs,319
|
35
40
|
letta/client/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
@@ -154,7 +159,7 @@ letta/local_llm/webui/settings.py,sha256=gmLHfiOl1u4JmlAZU2d2O8YKF9lafdakyjwR_ft
|
|
154
159
|
letta/openai_backcompat/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
155
160
|
letta/openai_backcompat/openai_object.py,sha256=GSzeCTwLpLD2fH4X8wVqzwdmoTjKK2I4PnriBY453lc,13505
|
156
161
|
letta/orm/__init__.py,sha256=oBQ8_9ynUrh3aotFMXnqa5womb-GYbE0-ibJk4nYnNM,1678
|
157
|
-
letta/orm/agent.py,sha256=
|
162
|
+
letta/orm/agent.py,sha256=qr4C3ZMoKZwqUfbGdXwD6Yz6qC1JH879FI6INJ2uWKE,17357
|
158
163
|
letta/orm/agents_tags.py,sha256=-rWR8DoEiHM4yc9vAHgHuvjIwgMXMWzKnTKFlBBu3TQ,1076
|
159
164
|
letta/orm/archive.py,sha256=82engq9ZfNrp1yu8QS5df4vsIwQC33CADZA-05doNko,3920
|
160
165
|
letta/orm/archives_agents.py,sha256=hIhaIRQPuNv-etQVWnIQhEomiumLC1OWR-T_s0Y7snM,1273
|
@@ -226,7 +231,7 @@ letta/plugins/plugins.py,sha256=Um9avvRxz4d5vJQTudLJCwv5EDUtIlVQZw8Xlf4S3Gw,2079
|
|
226
231
|
letta/prompts/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
227
232
|
letta/prompts/gpt_summarize.py,sha256=dbOsMdc6VGApFtXv7ZfqsGN2SZ_31K_nUWMLBTcChrY,1146
|
228
233
|
letta/prompts/gpt_system.py,sha256=Y-Wj8n8PFHwGjbsJhb-dghNXXQts5zrnBRI1FfDkocg,907
|
229
|
-
letta/prompts/prompt_generator.py,sha256=
|
234
|
+
letta/prompts/prompt_generator.py,sha256=yqsCilNNiUHcVYzQA0uk7b4Q01d37pm38k8S5H3-YxE,8902
|
230
235
|
letta/prompts/system_prompts/__init__.py,sha256=ak_AgWgx7oEQ9woxSyCWz7qvGogbsY2_cO501C_eD0I,735
|
231
236
|
letta/prompts/system_prompts/memgpt_chat.py,sha256=WEeP-RqjROG0a3Pqt-fQJSMj0ocE0Zt-4c5I3HXroNA,5438
|
232
237
|
letta/prompts/system_prompts/memgpt_generate_tool.py,sha256=k6X0DgWDxJz1ma31LT4V4HqfLjQHBYVs2-QAjbuQIek,6613
|
@@ -238,13 +243,13 @@ letta/prompts/system_prompts/summary_system_prompt.py,sha256=-jy_PL6Cwxjs3p3AiTR
|
|
238
243
|
letta/prompts/system_prompts/voice_chat.py,sha256=WLhjlVsVcQPc5S6y5hgw1SdVhdhtflNiwdpfSx3abwk,1871
|
239
244
|
letta/prompts/system_prompts/voice_sleeptime.py,sha256=2rgZYqJEqSp5bcEAXNuqM1PVsvPF1vm8sAqmhoOfQow,3714
|
240
245
|
letta/prompts/system_prompts/workflow.py,sha256=mth_46sY9JWx0rV-kqiGcu2IZGzZQfKY345qBUjvP-s,852
|
241
|
-
letta/schemas/agent.py,sha256=
|
246
|
+
letta/schemas/agent.py,sha256=XUABr2jWneARpbVW0j9Omfn_KCX6cE41RDs9PpZDGrE,22323
|
242
247
|
letta/schemas/agent_file.py,sha256=ueNumYpINPrOBHEeJeSLQdbgs2VKPpqvbfOZA4UGbRI,14884
|
243
248
|
letta/schemas/archive.py,sha256=bZCls6-lMaPKiH-jJBYFEW5saI1Qw2S6mv2wB8YaBUo,1883
|
244
249
|
letta/schemas/block.py,sha256=0vvkfwDq_WRT1Lm2E89FwqKPyZpRho7nA_BOxAZlYbI,7447
|
245
250
|
letta/schemas/embedding_config.py,sha256=ZaD40UeeAX6A9C6bQVhrKwNDiMEuOn7-5uHcj9_T_D0,3740
|
246
251
|
letta/schemas/embedding_config_overrides.py,sha256=lkTa4y-EQ2RnaEKtKDM0sEAk7EwNa67REw8DGNNtGQY,84
|
247
|
-
letta/schemas/enums.py,sha256=
|
252
|
+
letta/schemas/enums.py,sha256=XYJLxI3V-TDrPeq_wGZ8_zfN1WqnsFOt7-c51RRskgU,5255
|
248
253
|
letta/schemas/environment_variables.py,sha256=VRtzOjdeQdHcSHXisk7oJUQlheruxhSWNS0xqlfGzbs,2429
|
249
254
|
letta/schemas/file.py,sha256=78aTJuYqhhTu95hKFmcJmCa5_wJMZ521aiRzPM2plAM,6242
|
250
255
|
letta/schemas/folder.py,sha256=OpTj9idfGx6CEKDySeDEu3ZNDYjl8jJ02CH96RWPAVk,3309
|
@@ -263,7 +268,7 @@ letta/schemas/llm_batch_job.py,sha256=xr7RmMc9ItmL344vcIn1MJaT2nOf0F7qEHrsXkQNFQ
|
|
263
268
|
letta/schemas/llm_config.py,sha256=8nyi9r3o3feh_hUy6pdRWp3E6M612xZhvV3gkFB4aqE,13642
|
264
269
|
letta/schemas/llm_config_overrides.py,sha256=E6qJuVA8TwAAy3VjGitJ5jSQo5PbN-6VPcZOF5qhP9A,1815
|
265
270
|
letta/schemas/mcp.py,sha256=Wiu3FL5qupaHFaMqKFp-w1Ev6ShQ5dPfAtKIMGmRiF8,15527
|
266
|
-
letta/schemas/memory.py,sha256=
|
271
|
+
letta/schemas/memory.py,sha256=Mvzl58IHIxRzXgejC-GSV6KNvtmqpesrj0nie_zjeKg,20188
|
267
272
|
letta/schemas/message.py,sha256=zgDFz87xBRnkGFCp4xqpi4CdRysiAOWRRs10Ddlh0ew,55855
|
268
273
|
letta/schemas/npm_requirement.py,sha256=HkvBF7KjHUH-MG-RAEYJHO2MLRS2rxFUcmbpbZVznLk,457
|
269
274
|
letta/schemas/organization.py,sha256=TXrHN4IBQnX-mWvRuCOH57XZSLYCVOY0wWm2_UzDQIA,1279
|
@@ -278,11 +283,11 @@ letta/schemas/sandbox_config.py,sha256=iw3-QS7PNy649tdynTJUxBbaruprykYAuGO6q28w-
|
|
278
283
|
letta/schemas/secret.py,sha256=1vq33Z-Oe2zSeVnGuj6j04YoO0Y9LxX1bmkprg6C1NA,15659
|
279
284
|
letta/schemas/source.py,sha256=Uxsm8-XA3vuIt5Ihu_l2Aau7quuqmyIDg7qIryklUqY,3565
|
280
285
|
letta/schemas/source_metadata.py,sha256=_dGjuXhGcVMlc53ja9yuk16Uj64ggEzilRDgmkqYfNs,1334
|
281
|
-
letta/schemas/step.py,sha256=
|
286
|
+
letta/schemas/step.py,sha256=o7AQDXImVyO2XK-S6RafMYOgfORQRE_XE9m_5e4QVlM,3572
|
282
287
|
letta/schemas/step_metrics.py,sha256=u9dGPbc0AkXsMaqU09m4XtAu8EDjprakDBnISAFWseU,1606
|
283
288
|
letta/schemas/tool.py,sha256=Yxj36CKnBDtKaidSoTUZvd7GuUcciDGHaCjAhk6DcdA,15099
|
284
289
|
letta/schemas/tool_execution_result.py,sha256=17tMU01ACtpA41MTeWPqnF0uFpOYeaprORgGAd4XztA,895
|
285
|
-
letta/schemas/tool_rule.py,sha256=
|
290
|
+
letta/schemas/tool_rule.py,sha256=Opn6EgSyr3uP0-mbaS6EWoKrzaSwIDr1PEHL1d7d6gU,12618
|
286
291
|
letta/schemas/usage.py,sha256=9SSTH5kUliwiVF14b-yKbDcmxQBOLg4YH5xhXDbW9UU,1281
|
287
292
|
letta/schemas/user.py,sha256=GanbgD80N33FBjWKkv-MvUO01C0GHzrYmJ-o80wgLLI,1481
|
288
293
|
letta/schemas/openai/chat_completion_request.py,sha256=MZjNm5R-1_e3Ar6UsQvLCG5jKkzFh-zevdUWix03aXQ,4496
|
@@ -322,7 +327,7 @@ letta/server/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
322
327
|
letta/server/constants.py,sha256=yAdGbLkzlOU_dLTx0lKDmAnj0ZgRXCEaIcPJWO69eaE,92
|
323
328
|
letta/server/db.py,sha256=AULPiuS0b_EmNsQIS9b0yy3WBTpJv41vqF6Hxq9VXYg,17854
|
324
329
|
letta/server/generate_openapi_schema.sh,sha256=14Q6r0fbNNVVdf4X3Z-H0ZtyrVw5zYLzL5Doom3kM9k,351
|
325
|
-
letta/server/server.py,sha256=
|
330
|
+
letta/server/server.py,sha256=OkODdquY1sWkRC17CP10z-nysX97S4ddDCgFxtdPsPc,109265
|
326
331
|
letta/server/startup.sh,sha256=z-Fea-7LiuS_aG1tJqS8JAsDQaamwC_kuDhv9D3PPPY,2698
|
327
332
|
letta/server/utils.py,sha256=rRvW6L1lzau4u9boamiyZH54lf5tQ91ypXzUW9cfSPA,1667
|
328
333
|
letta/server/rest_api/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
@@ -362,7 +367,7 @@ letta/server/rest_api/routers/v1/providers.py,sha256=_gKcCbEN2tW7c0BO7_cMFEYdhhs
|
|
362
367
|
letta/server/rest_api/routers/v1/runs.py,sha256=3GzFN1T5n6sqmBTV7oisFyapjWipWQ2Zqtx3QJV7DpE,13254
|
363
368
|
letta/server/rest_api/routers/v1/sandbox_configs.py,sha256=FULVD8W-lhrhQSrLmpXVgDJpkulkRyKnxvZZtwDL52A,9065
|
364
369
|
letta/server/rest_api/routers/v1/sources.py,sha256=8fkCbprC4PZlcf5HnBYj2-8PjWFIkL0TWZBlp95N7nE,22319
|
365
|
-
letta/server/rest_api/routers/v1/steps.py,sha256=
|
370
|
+
letta/server/rest_api/routers/v1/steps.py,sha256=OIExfKSwilCmtrVHhF80h8g3yqhf5ww533FIw7N8noI,8251
|
366
371
|
letta/server/rest_api/routers/v1/tags.py,sha256=rGPO5GaVBn18hu7D3Ysyo45ka47g9DUir3UVh433DEc,1826
|
367
372
|
letta/server/rest_api/routers/v1/telemetry.py,sha256=8rzSii17BK8BjRRfV4Yr6mrKrbZEHySlUaQBGBWhxwY,1124
|
368
373
|
letta/server/rest_api/routers/v1/tools.py,sha256=OIlqmx-pLfWVXYxCrHzZORsnaLTSx1tFKwKVMDlQ5vc,50424
|
@@ -380,7 +385,7 @@ letta/server/ws_api/protocol.py,sha256=5mDgpfNZn_kNwHnpt5Dsuw8gdNH298sgxTGed3etz
|
|
380
385
|
letta/server/ws_api/server.py,sha256=_16TQafm509rqRztZYqo0HKKZoe8ccBrNftd_kbIJTE,5833
|
381
386
|
letta/services/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
382
387
|
letta/services/agent_file_manager.py,sha256=bgYTyQA90Iqo3W-LprPtyyOKf2itoqivcRhh4EOUXss,30847
|
383
|
-
letta/services/agent_manager.py,sha256=
|
388
|
+
letta/services/agent_manager.py,sha256=16ADzA-4OFLe0tDfS8AHkDjFA1qJELrXYpt-r54UDWQ,170057
|
384
389
|
letta/services/agent_serialization_manager.py,sha256=A3bOAjC73P6f9VWUOzXYiG_LXmFVzYFwtr_RJnFcZvc,46947
|
385
390
|
letta/services/archive_manager.py,sha256=xuvqHLjr5t_QVi7pwPbcxt_BYeSOOnxvSKvox64Xq9k,16388
|
386
391
|
letta/services/block_manager.py,sha256=mohj12QqHenSBbBx0Xmry1Rw25Gy5DSljOITzAwqMtw,33683
|
@@ -398,7 +403,7 @@ letta/services/per_agent_lock_manager.py,sha256=cMaW8r-qhucQbiK27jVqz8wzhlr2yuRN
|
|
398
403
|
letta/services/provider_manager.py,sha256=93IlJurJDAIP8FVfblI9CW1myWNISiZJia0t8E6gaHg,11244
|
399
404
|
letta/services/sandbox_config_manager.py,sha256=BwN3bebiFvcliTJpRkbOwGxmV5dUJ8B64kFfXAgAqDw,25989
|
400
405
|
letta/services/source_manager.py,sha256=IteOcn9ydoO7KARoPh-JuuYwO4jWcsBoTsrkGWvDk9c,18864
|
401
|
-
letta/services/step_manager.py,sha256=
|
406
|
+
letta/services/step_manager.py,sha256=psAer1Akg8DfHCFN1nRaMBv6WfVsh8b8hCmevmQC5LM,21883
|
402
407
|
letta/services/telemetry_manager.py,sha256=vES00FtL33aifIZs1ijE9yYrnzwE-zfgy-fhX4wRn94,3431
|
403
408
|
letta/services/tool_manager.py,sha256=Iz7noHEv4A3gZBa6H4rJul4onygCgjIw1GqxHrmmr5c,44857
|
404
409
|
letta/services/user_manager.py,sha256=XuG9eFrvax69sONx7t_D5kgpt5zNwyER-MhqLSDs8L4,9949
|
@@ -421,7 +426,7 @@ letta/services/file_processor/parser/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeu
|
|
421
426
|
letta/services/file_processor/parser/base_parser.py,sha256=WfnXP6fL-xQz4eIHEWa6-ZNEAARbF_alowqH4BAUzJo,238
|
422
427
|
letta/services/file_processor/parser/markitdown_parser.py,sha256=BpCM82ocDKbNTKhb2Zu3ffYUXR5fqudiUiwxmmUePg4,3715
|
423
428
|
letta/services/file_processor/parser/mistral_parser.py,sha256=NmCdVdpAB5f-VjILJp85pz2rSjlghKEg7qKTFzZLhP8,2384
|
424
|
-
letta/services/helpers/agent_manager_helper.py,sha256=
|
429
|
+
letta/services/helpers/agent_manager_helper.py,sha256=9rtIOvryf9Jw-8ZhA2UHDpL-Aam87xIR4vESFfenxX8,50880
|
425
430
|
letta/services/helpers/tool_execution_helper.py,sha256=45L7woJ98jK5MQAnhE_4NZdCeyOOzC4328FTQPM7iTA,9159
|
426
431
|
letta/services/helpers/tool_parser_helper.py,sha256=gJ-XwvqIgVPlnPVbseHL0YPfTUtk6svqC43-U4VcM5k,4467
|
427
432
|
letta/services/mcp/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
@@ -433,7 +438,7 @@ letta/services/mcp/streamable_http_client.py,sha256=d-5wmrZ7MjLTFbaAUAITEC699TBz
|
|
433
438
|
letta/services/mcp/types.py,sha256=8LYlBwWvdbvfy6ZdXJoin-7QmgmJC7samYXjQZL4KZs,1662
|
434
439
|
letta/services/summarizer/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
435
440
|
letta/services/summarizer/enums.py,sha256=lo2E1DKB-s2Ydx4PcLia1PIRUOY5yTSsFt_0EZVV2r0,279
|
436
|
-
letta/services/summarizer/summarizer.py,sha256=
|
441
|
+
letta/services/summarizer/summarizer.py,sha256=mnagbPoGvvQqgFIIdSX0kZTp4KokAVG4E8skcFtEflA,20041
|
437
442
|
letta/services/tool_executor/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
438
443
|
letta/services/tool_executor/builtin_tool_executor.py,sha256=QKPFXbgzYQobqWRuFs9RhVcQ1d53q8-yV_GFdR2IX88,9718
|
439
444
|
letta/services/tool_executor/composio_tool_executor.py,sha256=BmQokzS1Ze-8oyHSWNX_T2dQ-Y-YqKuShbz8B1czIIk,2284
|
@@ -441,12 +446,12 @@ letta/services/tool_executor/core_tool_executor.py,sha256=bd9x0M9Ttj3FqoIUU66k2F
|
|
441
446
|
letta/services/tool_executor/files_tool_executor.py,sha256=nlXk0w-t_dLiN7fpUrnBrHGIwWIEmSkcXa7b_YJs2ME,37781
|
442
447
|
letta/services/tool_executor/mcp_tool_executor.py,sha256=2zEXmkKsH-IGbMG2Xw1S9op4eL21g25RA4vGImB29KY,2000
|
443
448
|
letta/services/tool_executor/multi_agent_tool_executor.py,sha256=LIg9yh8BlfYokP_29WryLZPPSMqEsJUwc0mZGMlhc00,5724
|
444
|
-
letta/services/tool_executor/sandbox_tool_executor.py,sha256=
|
449
|
+
letta/services/tool_executor/sandbox_tool_executor.py,sha256=bwMeoQehXdUvCDli-QMkyVn6HM6_mHOSDqPWlrlrRJc,6214
|
445
450
|
letta/services/tool_executor/tool_execution_manager.py,sha256=Jz05CfUJAiVngwLV_qAgY8LwSHZGmp7poRcVJxOJPRE,6950
|
446
451
|
letta/services/tool_executor/tool_execution_sandbox.py,sha256=mDK8ZrtC-Fe8MY9gmhONMsjxiiSCJtL4bTrpECKksgQ,25908
|
447
452
|
letta/services/tool_executor/tool_executor_base.py,sha256=4b1GU0LZc8iwbM3TisqBVOxsE2H6BiFZ3-r11IrtZ1U,1566
|
448
453
|
letta/services/tool_sandbox/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
449
|
-
letta/services/tool_sandbox/base.py,sha256=
|
454
|
+
letta/services/tool_sandbox/base.py,sha256=BhpAU657kqmtsFCYxxrEgMqawl9Fz8cOhfuePmszlUI,13476
|
450
455
|
letta/services/tool_sandbox/e2b_sandbox.py,sha256=7h7quhbJRV1eIztZPVPgJLYwgHS3ZiaaMvTPrt01F1U,10294
|
451
456
|
letta/services/tool_sandbox/local_sandbox.py,sha256=4DnzszQ0VRIKo9kejfYyp4UTOQW_NTTfebhjeLtqOIs,11992
|
452
457
|
letta/services/tool_sandbox/modal_constants.py,sha256=AaXPxSlCj2BhfY5DGwQvqHXfikpurhV2iFsN7zxM3Is,454
|
@@ -459,10 +464,9 @@ letta/templates/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
459
464
|
letta/templates/sandbox_code_file.py.j2,sha256=eXga5J_04Z8-pGdwfOCDjcRnMceIqcF5ii0rUY3lmq4,2270
|
460
465
|
letta/templates/sandbox_code_file_async.py.j2,sha256=lb7nh_P2W9VZHzU_9TxSCEMUod7SDziPXgvT75xVds0,2748
|
461
466
|
letta/templates/summary_request_text.j2,sha256=ZttQwXonW2lk4pJLYzLK0pmo4EO4EtUUIXjgXKiizuc,842
|
462
|
-
letta/templates/template_helper.py,sha256=HkG3zwRc5NVGmSTQu5PUTpz7LevK43bzXVaQuN8urf0,1634
|
463
467
|
letta/types/__init__.py,sha256=hokKjCVFGEfR7SLMrtZsRsBfsC7yTIbgKPLdGg4K1eY,147
|
464
|
-
letta_nightly-0.11.7.
|
465
|
-
letta_nightly-0.11.7.
|
466
|
-
letta_nightly-0.11.7.
|
467
|
-
letta_nightly-0.11.7.
|
468
|
-
letta_nightly-0.11.7.
|
468
|
+
letta_nightly-0.11.7.dev20250918104055.dist-info/METADATA,sha256=cqEH7fCArhF3PxAVUcyA7a2DAN_gPOdVNCdzEpcf8Ew,24546
|
469
|
+
letta_nightly-0.11.7.dev20250918104055.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
|
470
|
+
letta_nightly-0.11.7.dev20250918104055.dist-info/entry_points.txt,sha256=m-94Paj-kxiR6Ktu0us0_2qfhn29DzF2oVzqBE6cu8w,41
|
471
|
+
letta_nightly-0.11.7.dev20250918104055.dist-info/licenses/LICENSE,sha256=mExtuZ_GYJgDEI38GWdiEYZizZS4KkVt2SF1g_GPNhI,10759
|
472
|
+
letta_nightly-0.11.7.dev20250918104055.dist-info/RECORD,,
|
@@ -1,53 +0,0 @@
|
|
1
|
-
import asyncio
|
2
|
-
import os
|
3
|
-
|
4
|
-
from jinja2 import Environment, FileSystemLoader, StrictUndefined, Template
|
5
|
-
|
6
|
-
from letta.otel.tracing import trace_method
|
7
|
-
|
8
|
-
TEMPLATE_DIR = os.path.dirname(__file__)
|
9
|
-
|
10
|
-
# Synchronous environment (for backward compatibility)
|
11
|
-
jinja_env = Environment(
|
12
|
-
loader=FileSystemLoader(TEMPLATE_DIR),
|
13
|
-
undefined=StrictUndefined,
|
14
|
-
trim_blocks=True,
|
15
|
-
lstrip_blocks=True,
|
16
|
-
)
|
17
|
-
|
18
|
-
# Async-enabled environment
|
19
|
-
jinja_async_env = Environment(
|
20
|
-
loader=FileSystemLoader(TEMPLATE_DIR),
|
21
|
-
undefined=StrictUndefined,
|
22
|
-
trim_blocks=True,
|
23
|
-
lstrip_blocks=True,
|
24
|
-
enable_async=True, # Enable async support
|
25
|
-
)
|
26
|
-
|
27
|
-
|
28
|
-
@trace_method
|
29
|
-
def render_template(template_name: str, **kwargs):
|
30
|
-
"""Synchronous template rendering function (kept for backward compatibility)"""
|
31
|
-
template = jinja_env.get_template(template_name)
|
32
|
-
return template.render(**kwargs)
|
33
|
-
|
34
|
-
|
35
|
-
@trace_method
|
36
|
-
async def render_template_async(template_name: str, **kwargs):
|
37
|
-
"""Asynchronous template rendering function that doesn't block the event loop"""
|
38
|
-
template = jinja_async_env.get_template(template_name)
|
39
|
-
return await template.render_async(**kwargs)
|
40
|
-
|
41
|
-
|
42
|
-
@trace_method
|
43
|
-
async def render_template_in_thread(template_name: str, **kwargs):
|
44
|
-
"""Asynchronously render a template from a string"""
|
45
|
-
template = jinja_env.get_template(template_name)
|
46
|
-
return await asyncio.to_thread(template.render, **kwargs)
|
47
|
-
|
48
|
-
|
49
|
-
@trace_method
|
50
|
-
async def render_string_async(template_string: str, **kwargs):
|
51
|
-
"""Asynchronously render a template from a string"""
|
52
|
-
template = Template(template_string, enable_async=True)
|
53
|
-
return await template.render_async(**kwargs)
|
File without changes
|
File without changes
|