Official agent skill

Deep Agents

by langchain-ai in langchain-ai/docs

Build batteries-included agents with planning, context management, subagent delegation, and sandboxed execution.

OfficialMITAuto-check passedAgent Workflows

Install Deep Agents

skills CLI
$ npx skills add langchain-ai/docs --skill deep-agents -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install langchain-ai/docs deep-agents --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/langchain-ai/docs.git skills-src && mkdir -p .claude/skills && cp -r skills-src/src/.mintlify/skills/deep-agents .claude/skills/deep-agents && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
deep-agents
GitHub stars
426
Token cost
~1.1k tokens
SKILL.md length
299 words
Files
1
Skills in repo
17
Repo updated
First seen
Licence
MIT

At a glance

Build batteries-included agents with planning, context management, subagent delegation, and sandboxed execution.

  • Multi-step tasks that need built-in capabilities
  • SKILL.md covers When to use, When NOT to use, Install and Quick reference, plus 3 more sections
  • Calls pip and npm; reaches reference.langchain.com
  • Tasks that involve Context engineering

What it does

Deep Agents is an agent skill from langchain-ai/docs, published by the product's own GitHub organization. Build batteries-included agents with planning, context management, subagent delegation, and sandboxed execution. Use for complex, multi-step tasks that need built-in capabilities.

Its SKILL.md is about 1.1k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts. Compatibility notes: Python 3.10+, Node.js 22+. Requires a model that supports tool calling.

It sits in Agent Workflows, covering Context engineering, Subagents and Building AI agents. It works with LangChain and LangGraph. The repository describes itself as: Unified LangChain documentation. The licence is MIT.

When your agent uses it

  • Multi-step tasks that need built-in capabilities
  • Tasks that involve Context engineering
  • Tasks that involve Subagents

Example prompts

  • “/deep-agents”

Requirements

  • Python 3
  • Node.js
  • Compatibility (from SKILL.md): Python 3.10+, Node.js 22+. Requires a model that supports tool calling.

What it can do on your machine

Read from SKILL.md and the folder at commit be3028f. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Shell commands in SKILL.md call:

    • pip
    • npm

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    Hosts in commands or code, which the agent is likely to contact:

    • reference.langchain.com

    Also links to:

    • docs.langchain.com

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

  • Compatibility

    Python 3.10+, Node.js 22+. Requires a model that supports tool calling.

    From compatibility in the SKILL.md frontmatter.

Context cost

Deep Agents loads about 1.1k tokens when it runs. Until then it costs about 48 tokens; SKILL.md has 299 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~48
When it runs · the whole SKILL.md, loaded when a task matches
~1.1k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from langchain-ai/docs at commit be3028f, republished under its MIT licence (© langchain-ai). 299 words, ~1,066 tokens.

Download SKILL.mdSave it as .claude/skills/deep-agents/SKILL.md (or your agent's skills folder).
name
deep-agents
description
Build batteries-included agents with planning, context management, subagent delegation, and sandboxed execution. Use for complex, multi-step tasks that need built-in capabilities.
compatibility
Python 3.10+, Node.js 22+. Requires a model that supports tool calling.
license
MIT
metadata.author
langchain-ai
metadata.version
1.0

Deep Agents

Deep Agents is the easiest way to start building agents powered by LLMs—with built-in capabilities for task planning, file systems for context management, subagent delegation, and long-term memory. It is an "agent harness" built on LangChain core building blocks and the LangGraph runtime.

When to use

Use Deep Agents when you need to:

  • Build agents fast with sensible defaults and minimal configuration
  • Handle complex, multi-step tasks that benefit from automatic planning
  • Manage context with a built-in virtual filesystem for large inputs
  • Delegate subtasks to specialized subagents
  • Run code safely in sandboxed execution environments
  • Use a terminal agent via Deep Agents Code

When NOT to use

  • For simple tool-calling agents without planning or subagents, use LangChain agents instead—lighter weight
  • For custom graph-based orchestration with explicit control flow, use LangGraph directly
  • Deep Agents is the highest-level abstraction—it trades flexibility for convenience

Install

bash
# Python
pip install deepagents

# JavaScript/TypeScript
npm install deepagents langchain @langchain/core

Quick reference

Create a deep agent
python
# pip install deepagents langchain-anthropic
from deepagents import create_deep_agent

def get_weather(city: str) -> str:
    """Get weather for a given city."""
    return f"It's always sunny in {city}!"

agent = create_deep_agent(
    model="anthropic:claude-sonnet-4-6",
    tools=[get_weather],
    system_prompt="You are a helpful assistant",
)

result = agent.invoke(
    {"messages": [{"role": "user", "content": "What is the weather in SF?"}]}
)
Use Deep Agents Code
bash
# Install Deep Agents Code
pip install deepagents-code

# Run an interactive terminal agent
deepagents
Built-in capabilities
CapabilityDescription
PlanningAutomatic task decomposition for complex requests
File systemVirtual filesystem for reading, writing, and managing context
SubagentsSpawn child agents for parallel subtask execution
Context managementAutomatic context compression for long conversations
Sandboxed executionRun code in isolated environments (Modal, Runloop, Daytona)
ProtocolsACP, MCP, and A2A support for interoperability

Key documentation

  • Overview—What Deep Agents is and how it compares to LangChain and LangGraph
  • Quickstart—Build your first deep agent
  • Customization—Configure models, tools, and behavior
  • Context engineering—Manage context for complex tasks
  • Subagents—Delegate work to child agents
  • Sandboxes—Run code in isolated environments
  • Code—Deep Agents Code, the terminal agent interface
  • Deploy—Deploy to production

API reference

For SDK class and method details, use the LangChain API Reference site:

  • MCP server: https://reference.langchain.com/mcp
  • langchain—Core building blocks that Deep Agents is built on
  • langgraph—Runtime that powers Deep Agents' durable execution
  • langsmith—Trace, evaluate, and deploy your deep agents

© langchain-ai, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in src/.mintlify/skills/deep-agents of langchain-ai/docs.

Open the folder on GitHubat commit be3028f

Compare with similar skills

Deep Agents next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Deep Agents compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Deep Agents this skilllangchain-ai/docs426—~1.1kAutomated safety check: PassMIT
Deep Agents Corelangchain-ai/langchain-skills1.3k—~3.1kAutomated safety check: PassMIT
Langchain Deep Agentsjeremylongshore/tons-of-skills-marketplace2.8k—~4.9kAutomated safety check: PassMIT
Magic ResumeMagic-Resume/Magic-Resume101—~663Automated safety check: PassMIT
Mem0 Platform SDKmem0ai/mem067k1 repos~2.2kAutomated safety check: PassApache-2.0
Pydantic AI Harnesspydantic/pydantic-ai20k—~4.9kAutomated safety check: PassMIT

Similar skills

  • Deep Agents Core

    langchain-ai/langchain-skills

    Official

    Explains how to build agents with the Deep Agents framework: create_deep_agent, the built-in middleware, the harness, SKILL.md format and configuration options.

    1.3k GitHub stars~3.1k tokensUpdated today
    AI & LLM EngineeringAuto-check passed
  • Langchain Deep Agents

    jeremylongshore/tons-of-skills-marketplace

    Build a LangGraph 1.0 Deep Agent — planner + subagents + virtual filesystem + reflection loop — without the state-growth and prompt-inheritance traps.

    2.8k GitHub stars~4.9k tokensUpdated today
    AI & LLM EngineeringAuto-check passed
  • Magic Resume

    Magic-Resume/Magic-Resume

    How AI agents integrate with Magic Resume — read and safely edit a user's resumes through the native MCP server (@magic-resume/mcp).

    101 GitHub stars~663 tokensUpdated 4 days ago
    Agent WorkflowsAuto-check passed
  • Adds persistent memory to AI apps with the Mem0 Python and TypeScript SDKs: store, search, update and delete user memories, with framework integrations.

    67k GitHub starsUsed in 1 repo~2.2k tokens
    AI & LLM EngineeringAuto-check passed
  • Pydantic AI Harness

    pydantic/pydantic-ai

    Official

    Adds optional capabilities to Pydantic AI agents from pydantic-ai-harness, led by Code Mode, which runs many tool calls as one sandboxed Python script.

    20k GitHub stars~4.9k tokensUpdated today
    AI & LLM EngineeringAuto-check passed
  • Add Example Agent

    GetBindu/Bindu

    Add a new self-contained example agent under examples/. An agent skill from GetBindu/Bindu.

    10k GitHub stars~1.1k tokensUpdated 1 mo ago
    AI & LLM EngineeringAuto-check: notes

More from langchain-ai/docs

All 17 skills in this repo
  • Add Docs Page

    langchain-ai/docs

    Official

    Add, move, rename, or delete a page on the LangChain docs site.

    426 GitHub stars~2k tokensUpdated today
    Auto-check passed
  • Docs Code Samples

    langchain-ai/docs

    Official

    A skill your agent uses when migrating inline code samples from LangChain docs (MDX files) into external, testable code files that are extracted by this repo’s snippet scripts and used as Mintlify…

    426 GitHub stars~4.6k tokensUpdated today
    Auto-check passed
  • Docs Edit

    langchain-ai/docs

    Official

    Edit a docs page that already has an open pull request, or revise a page in place.

    426 GitHub stars~1.9k tokensUpdated today
    Auto-check passed
  • Docs Restructure

    langchain-ai/docs

    Official

    Restructure documentation that spans several pages. An agent skill from langchain-ai/docs.

    426 GitHub stars~1.7k tokensUpdated today
    Auto-check passed
  • Docs Team Voice

    langchain-ai/docs

    Official

    Write or revise documentation prose so it reads like the rest of this site, in the docs team's shared voice.

    426 GitHub stars~1.5k tokensUpdated today
    Auto-check passed
  • Langchain

    langchain-ai/docs

    Official

    Build agents with a prebuilt architecture and integrations for any model or tool.

    426 GitHub stars~1.1k tokensUpdated today
    Auto-check passed

Questions about Deep Agents

What does Deep Agents do?

Build batteries-included agents with planning, context management, subagent delegation, and sandboxed execution. Deep Agents is an agent skill from langchain-ai/docs, published by the product's own GitHub organization. Build batteries-included agents with planning, context management, subagent delegation, and sandboxed execution.

When should I use Deep Agents?

Deep Agents fits situations like: multi-step tasks that need built-in capabilities; tasks that involve Context engineering; tasks that involve Subagents.

How do I install Deep Agents in Claude Code?

Run `npx skills add langchain-ai/docs --skill deep-agents -a claude-code`. Or copy the skill folder (src/.mintlify/skills/deep-agents in langchain-ai/docs) into .claude/skills/deep-agents in your project. Claude Code loads it when a task matches its description.

How do I install Deep Agents in Codex?

Run `npx skills add langchain-ai/docs --skill deep-agents -a codex`. Or copy the skill folder (src/.mintlify/skills/deep-agents in langchain-ai/docs) into .agents/skills/deep-agents in your project. Codex loads it when a task matches its description.

Can I use Deep Agents in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add langchain-ai/docs --skill deep-agents -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/deep-agents, .gemini/skills/deep-agents, .github/skills/deep-agents and .opencode/skills/deep-agents in your project.

What does Deep Agents need to run?

Going by SKILL.md and its folder, Deep Agents needs the command-line tools its instructions call (pip and npm). Our summary lists: Python 3; Node.js. Compatibility (from SKILL.md): Python 3.10+, Node.js 22+. Requires a model that supports tool calling..

Does Deep Agents access the network?

SKILL.md names 2 domains. In commands or code: reference.langchain.com; the agent is likely to contact it when it follows the instructions. As links in the text: docs.langchain.com. This is read from the text; nothing was executed.

Is Deep Agents safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Deep Agents use?

Deep Agents is published under the MIT licence (declared in SKILL.md). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Deep Agents use?

About 1.1k tokens (SKILL.md is roughly 4.3k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Deep Agents?

Skills that share tags, products or a category with Deep Agents: Deep Agents Core (langchain-ai/langchain-skills, 1.3k stars), Langchain Deep Agents (jeremylongshore/tons-of-skills-marketplace, 2.8k stars), Magic Resume (Magic-Resume/Magic-Resume, 101 stars) and Mem0 Platform SDK (mem0ai/mem0, 67k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Deep Agents?

langchain-ai (a GitHub organization, an official publisher) maintains it in langchain-ai/docs, which has 426 GitHub stars. The repository holds 17 skills in this directory. The repository was last updated on October 9, 2026.

Source: langchain-ai/docs on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.