/memories/agent/, shared by every caller. Managed Deep Agents do not have durable memory by default.
Managed Deep Agents is in public beta and available on LangSmith Cloud in the US region only.
Project structure
The optional memory declaration lives at the project root:Memory compared to related state
Memory is not your system prompt. Define always-on behavior in instructions and task-specific procedures in skills; use memory for durable knowledge the agent learns while it runs.
Enable memory
Export a namedmemory declaration with the "agent" scope:
memory.py
scope="none".
How the agent uses memory
Enabling memory mounts one Context Hub tree,memories/agent, at /memories/agent/ in the agent filesystem:
Keep hot memory compact because it consumes context on every run. Put detailed material—such as procedures, decision logs, and research notes—in cold files, and link to them from hot memory when useful.
The agent reads and updates memory with
read_file, edit_file, and write_file. Writes elsewhere, including elsewhere under /memories/, are not durable.
How the agent decides what to remember
The agent decides what to remember based on prompting. To make the policy explicit, add guidance like the following toinstructions.md and adapt it to your application:
Distinguish instructions from memory
instructions.md defines how the agent should behave. Memory stores knowledge the agent learns and uses across threads. Use instructions to tell the agent what kinds of shared knowledge are worth remembering.
instructions.md is always read-only. The agent never updates it. Deploys sync project-owned instructions and skills, but do not overwrite durable content already stored under memories/agent in Context Hub.
Connect these docs to Claude, VSCode, and more via MCP for real-time answers.

