deepagents is a standalone library built on top of LangChain’s core building blocks for agents. It uses the LangGraph runtime for durable execution, streaming, human-in-the-loop, and other features.
The deepagents library contains:
- Deep Agents SDK: A package for building agents that can handle any task
- Deep Agents CLI: A coding tool built on top of the
deepagentspackage
Create a deep agent
When to use the Deep Agents
Use the Deep Agents SDK when you want to build agents that can:- Handle complex, multi-step tasks that require planning and decomposition
- Manage large amounts of context through file system tools
- Delegate work to specialized subagents for context isolation
- Persist memory across conversations and threads
create_agent or building a custom LangGraph workflow.
Use the Deep Agents CLI when you want to use an interactive deep agent on the command-line for coding or other tasks:
- Customize agents with skills and memory.
- Teach agents as you use them about your preferences, common patterns, and custom project knowledge.
- Execute code on your machine or in sandboxes.
Core capabilities
Planning and task decomposition
Deep agents include a built-in
write_todos tool that enables agents to break down complex tasks into discrete steps, track progress, and adapt plans as new information emerges.Context management
File system tools (
ls, read_file, write_file, edit_file) allow agents to offload large context to in-memory or filesystem storage, preventing context window overflow and enabling work with variable-length tool results.Subagent spawning
A built-in
task tool enables agents to spawn specialized subagents for context isolation. This keeps the main agent’s context clean while still going deep on specific subtasks.Long-term memory
Extend agents with persistent memory across threads using LangGraph’s Memory Store. Agents can save and retrieve information from previous conversations.
Get started
SDK Quickstart
Build your first deep agent
Customization
Learn about customization options for the SDK
Sandboxes
Execute code in isolated environments
CLI
Use the Deep Agents CLI
Reference
See the
deepagents API reference