
Deep Agents Memory
A solid reference for setting up memory and file persistence in Deep Agents. The skill covers the three main backend types: StateBackend for ephemeral storage within a thread, StoreBackend for cross-session persistence, and CompositeBackend for routing different paths to different storage types. The examples show practical patterns like routing /memories/ to persistent storage while keeping working files ephemeral. The FilesystemBackend section includes proper security warnings about never using it in web servers. Most useful when you need to understand the tradeoffs between storage backends or set up hybrid storage patterns where some data persists and other data doesn't.
- skills.sh installs
- 19.8K
- GitHub stars
- 1.3K
- last updated
- Aug 21, 2026
Install
$ npx -y skills add langchain-ai/langchain-skills --skill deep-agents-memory --agent claude-codeInstalls into .claude/skills of the current project.
Files
Short-term (StateBackend): Persists within a single thread, lost when thread ends Long-term (StoreBackend): Persists across threads and sessions Hybrid (CompositeBackend): Route different paths to different backends
FilesystemMiddleware provides tools: ls, read_file, write_file, edit_file, glob, grep
| Use Case | Backend | Why |
|---|---|---|
| Temporary working files | StateBackend | Default, no setup |
| Local development CLI | FilesystemBackend | Direct disk access |
| Cross-session memory | StoreBackend | Persists across threads |
| Hybrid storage | CompositeBackend | Mix ephemeral + persistent |
from deepagents import create_deep_agent
Sponsors
Details
- Repository
- github.com/langchain-ai/langchain-skills
- Category
- AI & Agent Building
More from langchain-ai/langchain-skills
All 15- Langgraph Fundamentals18.9K
- Langgraph Persistence18.8K
- Langchain Rag18.4K
- Langchain Fundamentals18.2K
- Langgraph Human In The Loop18K
- Langchain Middleware17K
- Deep Agents Orchestration16.8K
- Langchain Dependencies16.8K
- Deep Agents Core16.7K
- Managed Deep Agents10K
- Langgraph Cli9.7K
- Swarm9.5K
- Ecosystem Primer8.8K
- Framework Selection7.7K