
- File operations - read, write, and edit files in your project with tools that enable agents to manage and modify code and documentation.
- Shell command execution - execute shell commands to run tests, build projects, manage dependencies, and interact with version control systems.
- Web search - search the web for up-to-date information and documentation (requires Tavily API key).
- HTTP requests - make HTTP requests to APIs and external services for data fetching and integration tasks.
- Task planning and tracking - break down complex tasks into discrete steps and track progress through the built-in todo system.
- Memory storage and retrieval - store and retrieve information across sessions, enabling agents to remember project conventions and learned patterns.
- Human-in-the-loop - require human approval for sensitive tool operations.
- Skills - extend agent capabilities with custom expertise and instructions stored in skill directories.
- MCP tools - load external tools from Model Context Protocol servers via auto-discovered or explicit config files.
Full list of built-in tools
Full list of built-in tools
Built-in tools
The agent comes with the following built-in tools which are available without configuration:| Tool | Description | Human-in-the-Loop |
|---|---|---|
ls | List files and directories | - |
read_file | Read contents of a file; supports images (.png, .jpg, .jpeg, .gif, .webp) as multimodal content | - |
write_file | Create or overwrite a file | Required1 |
edit_file | Make targeted edits to existing files | Required1 |
glob | Find files matching a pattern (e.g., **/*.py) | - |
grep | Search for text patterns across files | - |
shell | Execute shell commands (local mode) | Required1 |
execute | Execute commands in remote sandbox (sandbox mode) | Required1 |
web_search | Search the web using Tavily API | Required1 |
fetch_url | Fetch and convert web pages to markdown | Required1 |
task | Delegate work to subagents for parallel execution | Required1 |
write_todos | Create and manage task lists for complex work | - |
auto-approve option:Quickstart
Set model credentials
Select the model provider(s) you want to use and set credentials as environment variables.
- OpenAI
- Anthropic
- Google
- Vertex AI
Export as an environment variable:
Additional installation and configuration options
Additional installation and configuration options
Each model provider requires installing its corresponding LangChain integration package. These are available as optional extras when installing the CLI:For the full list of supported providers and configuration options, see Custom model providers.On first launch (when no Enable web search (optional):API keys can be set as environment variables or in a
[models].default or [models].recent is set), the CLI auto-selects the first available startup credential in this order: OPENAI_API_KEY, ANTHROPIC_API_KEY, GOOGLE_API_KEY, then GOOGLE_CLOUD_PROJECT (Vertex AI). This startup fallback is intentionally narrow; other supported providers (for example, Groq) are still available via --model, /model, or a saved default model..env file.Tracing with LangSmith
Enable LangSmith tracing to see agent operations in a LangSmith project:-
Enable LangSmith tracing:
-
Configure agent tracing for deep agent operations such as tool calls and agent decisions:
-
If you are building a LangChain app with deep agents, and want to separate agent traces from your app’s traces, also configure
LANGSMITH_PROJECT:
Configuration
Each agent has its own configuration directory at~/.deepagents/<agent_name>/. The default agent name is agent.
Command-line options
Command-line options
| Option | Description |
|---|---|
-a, --agent NAME | Use named agent with separate memory (default: agent) |
-M, --model MODEL | Use a specific model (provider:model) |
--model-params JSON | Extra kwargs to pass to the model as a JSON string (e.g., '{"temperature": 0.7}') |
--default-model [MODEL] | Set the default model |
--clear-default-model | Clear the default model |
-r, --resume [ID] | Resume a session: -r for most recent, -r <ID> for a specific thread |
-m, --message TEXT | Initial prompt to auto-submit when the session starts (interactive mode) |
-n, --non-interactive TEXT | Run a single task non-interactively and exit. Shell is disabled unless --shell-allow-list is set |
-q, --quiet | Clean output for piping—only the agent’s response goes to stdout. Requires -n or piped stdin |
--no-stream | Buffer the full response and write to stdout at once instead of streaming. Requires -n or piped stdin |
--auto-approve | Auto-approve all tool calls without prompting (disables human-in-the-loop). Toggle with Shift+Tab during an interactive session |
--shell-allow-list LIST | Comma-separated shell commands to auto-approve, 'recommended' for safe defaults, or 'all' to allow any command. Applies to both -n and interactive modes |
--sandbox TYPE | Remote sandbox for code execution: none (default), modal, daytona, runloop, langsmith |
--sandbox-id ID | Reuse an existing sandbox (skips creation and cleanup) |
--sandbox-setup PATH | Path to setup script to run in sandbox after creation |
--mcp-config PATH | Add an explicit MCP config as the highest-precedence source (merged with auto-discovered configs) |
--no-mcp | Disable all MCP tool loading |
--trust-project-mcp | Trust project-level MCP configs with stdio servers (skip approval prompt) |
-v, --version | Display version |
-h, --help | Show help |
CLI commands
CLI commands
| Command | Description |
|---|---|
deepagents help | Show help |
deepagents list | List all agents |
deepagents reset --agent NAME | Clear agent memory and reset to default |
deepagents reset --agent NAME --target SOURCE | Copy memory from another agent |
deepagents skills list [--project] | List all skills (alias: ls) |
deepagents skills create NAME [--project] | Create a new skill with template SKILL.md |
deepagents skills info NAME [--project] | Show detailed information about a skill |
deepagents skills delete NAME [--project] [-f] | Delete a skill and its contents |
deepagents threads list [--agent NAME] [--limit N] | List sessions (alias: ls). Default limit: 20. -n is a short flag for --limit |
deepagents threads delete ID | Delete a session |
Interactive mode
Type naturally as you would in a chat interface. The agent will use its built-in tools, skills, and memory to help you with tasks.Slash commands
Slash commands
Use these commands within the CLI session:
/model- Open the interactive model selector. The selector shows a detail footer with context window size, input modalities, and capabilities for the highlighted model/model <provider:model>- Switch directly to a specific model (e.g.,/model anthropic:claude-sonnet-4-5)/model --model-params JSON [provider:model]- Switch with extra model constructor params (e.g.,/model --model-params '{"temperature": 0.7}' anthropic:claude-sonnet-4-5). UseTabto autocomplete the currently highlighted model name/model --default <provider:model>- Set a persistent default model/model --default --clear- Clear the saved default model/remember [context]- Review conversation and update memory and skills. Optionally pass additional context/tokens- Display current context window token usage/clear- Clear conversation history and start a new thread/threads- Browse and resume previous conversation threads. Supports fuzzy search, configurable columns (thread_id,agent_name,messages,created_at,updated_at,git_branch,initial_prompt), sort order toggle, and inline deletion withCtrl+D. Column visibility and sort preferences persist toconfig.toml/reload- Refresh runtime configuration (API keys,.envchanges, project root, shell allow-list) without restarting the session. Conversation state is preserved. Reports which fields changed (API keys are masked). Does not reload the active model or agent graph/trace- Open the current thread in LangSmith (requiresLANGSMITH_API_KEY)/changelog- Open the CLI changelog in your browser/docs- Open the documentation in your browser/feedback- Open the GitHub issues page to file a bug report or feature request/version- Show installeddeepagents-cliand SDK versions/help- Show help and available commands/quit- Exit the CLI
Shell commands
Shell commands
Type
! to enter shell mode, then type your command.Keyboard shortcuts
Keyboard shortcuts
General
| Shortcut | Action |
|---|---|
Enter | Submit prompt |
Shift+Enter, Ctrl+J, Alt+Enter, or Ctrl+Enter | Insert newline |
Ctrl+A | Select all text in input |
@filename | Auto-complete files and inject content |
Shift+Tab or Ctrl+T | Toggle auto-approve |
Ctrl+E | Expand/collapse the most recent tool output |
Escape | Interrupt current operation |
Ctrl+C | Interrupt or quit |
Ctrl+D | Exit |
Non-interactive mode and piping
Use-n to run a single task without launching the interactive UI:
-n or -m, the piped content is prepended to the flag’s value.
The maximum piped input size is 10 MiB.
-q for clean output suitable for piping into other commands, and --no-stream to buffer the full response (instead of streaming) before writing to stdout:
--shell-allow-list to enable it:
Switch models
You can switch models during a session without restarting the CLI using the/model command, or at launch with the --model flag:
/model with no arguments to open an interactive model selector that displays available models grouped by provider. The selector shows a detail footer for the highlighted model with context window size, input modalities (text, image, audio, PDF, video), and capabilities (reasoning, tool calling, structured output). Values overridden by --profile-override or config.toml are marked with a yellow * prefix.
You can also pass extra model constructor parameters when switching mid-session using --model-params:
params. --model-params cannot be combined with --default.
For full details on switching models, setting a default, and configuring custom providers, see Model providers. For config.toml reference and lifecycle hooks, see Configuration.
Teach your agent project conventions
As you use the agent, it automatically stores information in~/.deepagents/<agent_name>/memories/ as markdown files using a memory-first protocol:
- Research: Searches memory for relevant context before starting tasks
- Response: Checks memory when uncertain during execution
- Learning: Automatically saves new information for future sessions
Customize your deep agent
There are two primary ways to customize any agent:-
Memory: Global and project-specific
AGENTS.mdfiles which are loaded in full at session start. Use memory for general coding style and preferences. - Skills: Global and project-specific context, conventions, guidelines, or instructions. Use skills for context that is only required when performing specific tasks.
Provide project or user context
AGENTS.md files provide persistent memory that is always loaded at session start.
You can provide global user memory for the agent in ~/.deepagents/<agent_name>/AGENTS.md.
This file is always loaded when you start a new deep agent session.
The agent may also read its memory files when answering project-specific questions or when you reference past work or patterns.
For project-specific memory, you can add context to .deepagents/AGENTS.md in any project’s root folder as long as the project uses git.
When you start the CLI from anywhere within the project’s folder, the CLI will find the project’s root folder by checking for a containing .git folder.
Both global and project-level AGENTS.md files are loaded together and appended to the system prompt at startup.
The agent will update them as you use the agent and provide it with additional information on how it should behave, feedback on its work, or instructions to remember something.
The agent will also update its memory if it identifies patterns or preferences from your interactions.
If you would like to explicitly prompt your deep agent to update skills and memory based on the current context from the thread use the /remember command which loads a custom instruction to review the context and perform updates.
To add more structured project knowledge in additional memory files, you can add them in .deepagents/ and reference them in the AGENTS.md file.
You must reference additional files in the AGENTS.md file for the agent to be aware of these files.
The additional files will not be read on startup but the agent can reference and update them when needed.
When to use global vs. project `AGENTS.md`
When to use global vs. project `AGENTS.md`
Global
AGENTS.md (~/.deepagents/agent/AGENTS.md)- Your personality, style, and universal coding preferences
- General tone and communication style
- Universal coding preferences (formatting, type hints, etc.)
- Tool usage patterns that apply everywhere
- Workflows and methodologies that don’t change per-project
AGENTS.md (.deepagents/AGENTS.md in project root)- Project-specific context and conventions
- Project architecture and design patterns
- Coding conventions specific to this codebase
- Testing strategies and deployment processes
- Team guidelines and project structure
Use remote sandboxes
Execute code in isolated remote environments for safety and flexibility. Remote sandboxes provide the following benefits:- Safety: Protect your local machine from potentially harmful code execution
- Clean environments: Use specific dependencies or OS configurations without local setup
- Parallel execution: Run multiple agents simultaneously in isolated environments
- Long-running tasks: Execute time-intensive operations without blocking your machine
- Reproducibility: Ensure consistent execution environments across teams
-
Configure your sandbox provider (Runloop, Daytona, or Modal):
-
Run the CLI with a sandbox:
The agent runs locally but executes all code operations in the remote sandbox. Optional setup scripts can configure environment variables, clone repositories, and prepare dependencies.
-
(Optional) Create a
setup.shfile to configure your sandbox environment:Store secrets in a local.envfile for the setup script to access.
Use MCP tools
Extend the CLI with tools from external MCP (Model Context Protocol) servers. Place a.mcp.json at your project root and the CLI discovers it automatically. See the MCP tools guide for configuration format, auto-discovery, and troubleshooting.
Use skills
Skills are reusable agent capabilities that provide specialized workflows and domain knowledge. You can use skills to provide your deep agent with new capabilities and expertise. Deep agent skills follow the Agent Skills standard. Once you have added skills your deep agent will automatically make use of them and update them as you use the agent and provide it with additional information. If you would like to explicitly prompt your deep agent to update skills and memory based on the current context from the thread use the/remember command which loads a custom instruction to review the context and perform updates.
Add skills
-
Start by creating a skill:
- User skill
- Project skill
This will generate the correct the following files in your~/.deepagents/<agent_name>folder: -
Open the generated
SKILL.mdand edit the file to include your instructions. -
Optionally add additional scripts or other resources to the
test-skillfolder. For more information, see Examples.
.git folder.
When you start the CLI from anywhere within the project’s folder, the CLI will find the project’s root folder by checking for a containing .git folder.
For each skill, the CLI reads the name and the description from the SKILL.md file’s frontmatter.
As you use the CLI, if a task matches the skill’s description, the agent will read the skill file and follow its instructions.
List skills
To see the lists you have installed, run:- User skill
- Project skill
- User skill
- Project skill
Connect these docs to Claude, VSCode, and more via MCP for real-time answers.

