создание и маунт папки /workspace

This commit is contained in:
Егор Кандрушин 2026-04-08 15:00:01 +03:00
parent a176dcac52
commit 745512aa4b
5 changed files with 16 additions and 2 deletions

View file

@ -2,6 +2,7 @@ import os
from deepagents import create_deep_agent
from langchain_openai import ChatOpenAI
from langgraph.checkpoint.memory import MemorySaver
from deepagents.backends.local_shell import LocalShellBackend
def create_agent():
@ -11,9 +12,14 @@ def create_agent():
api_key=os.environ["PROVIDER_API_KEY"],
)
workspace_dir = os.environ["WORKSPACE_DIR"]
backend = LocalShellBackend(workspace_dir,
virtual_mode=True)
return create_deep_agent(
model=model,
system_prompt="You are a helpful assistant.",
checkpointer=MemorySaver(),
backend=backend,
)