curl -LsSf https://langch.in/dcode | bash
# With model provider extras
# OpenAI, Anthropic, and Gemini are included by default
DEEPAGENTS_CODE_EXTRAS="nvidia,ollama" curl -LsSf https://langch.in/dcode | bash
Run:
dcode
The fastest way to start using Deep Agents. deepagents-code is a pre-built coding agent in your terminal — similar to Claude Code or Cursor — powered by any LLM that supports tool calling. One install command and you're up and running, no code required.
What deepagents-code adds on top of the SDK:
See our Releases and Versioning policies.
As an open-source project in a rapidly developing field, we are extremely open to contributions, whether it be in the form of a new feature, improved infrastructure, or better documentation.
For detailed information on how to contribute, see the Contributing Guide.
This project was primarily inspired by Claude Code, and initially was largely an attempt to see what made Claude Code general purpose, and make it even more so.
OSC 9;4 progress states.
Metadata for a custom subagent loaded from filesystem.
A transport-independent event delivered from outside the TUI.
Source of external events for the Textual app.
Line-delimited JSON event source over a local Unix domain socket.
State for local context middleware.
Inject local context (git state, project structure, etc.) into the system prompt.
Explicit user/project path context for project-sensitive behavior.
How an option's raw env/TOML value is coerced to a typed value.
One user-tunable configuration option and where it can be set.
Client that talks to a LangGraph server over HTTP+SSE.
User-facing OAuth interaction surface shared by CLI and TUI.
Default OAuthInteraction that drives the flow via stdin/stdout.
Validate shell commands against an allow-list without HITL interrupts.
Stable identifiers for notification actions dispatched by the app.
One button/action row in the notification modal.
Typed payload for a missing-dependency notification.
Typed payload for an update-available notification.
A single notice waiting for user action.
In-memory store of pending notifications.
Runtime context passed via context= to the LangGraph graph.
Character set mode for TUI display.
Character glyphs for TUI display.
Global settings and environment detection for deepagents-code.
Mutable session state shared across the app, adapter, and agent.
Base class for typed LangSmith project URL lookup failures.
The langsmith package is not installed.
The LangSmith project URL lookup exceeded its hard timeout.
The LangSmith SDK call raised — auth, 404, network, etc.
Result of creating a chat model, bundling the model with its metadata.
Full configuration payload passed from the app to the server subprocess.
Raised when installed extras cannot be determined safely.
Install status for one optional dependency extra.
Discriminator for ConfigResolutionError reasons.
Structured error returned when a login target cannot be resolved.
Successful resolution of a merged MCP config for login.
Resolved server config plus enough context for error messages.
Classification that controls whether a command can skip the message queue.
A single slash-command definition.
A single autocomplete entry for the slash-command controller.
Data used to render HITL previews.
Line and byte level metrics for a file operation.
Track a single filesystem tool call.
Collect file operation metrics during an interaction.
Middleware that provides an ask_user tool for interactive questioning.
Deterministic chat model for integration tests.
Represents a queued user message awaiting processing.
Textual message carrying an external prompt or command.
An action deferred until the current busy state resolves.
Session state for the Textual app.
Main Textual application for deepagents-code.
Posted by the background server-startup worker on success.
Posted by the background server-startup worker on failure.
Result from running the Textual application.
A single choice option for a multiple choice question.
A question to ask the user.
Request payload sent via interrupt when asking the user questions.
Widget result when the user submits answers.
Widget result when the user cancels the prompt.
Token stats for a single model within a session.
Stats accumulated over a single agent turn (or full session).
Raised when model configuration or creation fails.
Raised when no credentials are configured for any default-resolvable provider.
Raised when neither the app nor init_chat_model can infer a provider.
Raised when a provider is selected but its API key env var is unset.
Raised when a provider is selected but its LangChain package is not installed.
Credential readiness state for a model provider.
Origin of a CONFIGURED credential, used to discriminate display.
Credential readiness information for a provider.
A model specification in provider:model format.
Profile data for a model with override tracking.
Configuration for a model provider.
Parsed model configuration from config.toml.
Coalesced thread-selector configuration read from a single TOML parse.
Extends agent state with per-checkpoint facts restored on resume.
Persists per-checkpoint resume facts after each model call.
A dangerous Unicode character found in text.
Safety analysis output for a URL string.
Manages a langgraph dev server subprocess.
Thread metadata returned by list_threads.
Revert agent edits to the managed onboarding-name memory block.
Swap the model or per-call settings from runtime.context.
Complete set of semantic colors for one theme variant.
Metadata for a registered theme.
Represents a pasted image with its base64 encoding.
Represents a pasted video with its base64 encoding.
Unified parse result for dropped-path payload detection.
Track pasted images and videos in the current conversation.
Raised when a downloaded archive fails SHA-256 verification.
Metadata for a single MCP tool.
Metadata for a configured MCP server and its tools.
An MCP configuration file is malformed or structurally invalid.
Lazy, per-server cache of persistent MCP sessions.
Adapter for rendering agent output to Textual widgets.
Parsed MCP server config entry.
File-backed TokenStorage under ~/.deepagents/.state/mcp-tokens/.
Raised when an MCP server needs interactive re-authentication.
Raised when the HITL interrupt loop exceeds _MAX_HITL_ITERATIONS rounds.
Mutable state accumulated while iterating over the agent stream.
Best-effort background LangSmith thread URL lookup state.
Successful offload result.
Offload was a no-op — conversation is within the retention budget.
Raised when the model cannot be created for offloading.
A persisted API key credential.
A persisted OAuth subscription credential.
Result of a credential write that may have warnings to surface.
Configuration for a single config-declared sandbox provider.
Parsed [sandboxes] configuration from config.toml.
How to install the package that provides a sandbox backend.
Static description of a sandbox provider used by the registry.
Base error for sandbox provider operations.
Raised when the requested sandbox cannot be found.
Interface for creating and deleting sandbox backends.
Merged view of built-in, entry-point, and config sandbox providers.
Slack-hosted MCP: loopback Authorization Code with a public client.
GitHub-hosted MCP: RFC 8628 Device Authorization Grant.
Outcome of a provider's pre-handshake run_login step.
Base class for provider-specific OAuth dispatch.
Fallback provider for spec-compliant MCP servers with no quirks.
Extended skill metadata for CLI display, adds source tracking.
Structured prompt and checkpoint metadata for a skill invocation.
Modal asking whether to restart the server after an MCP login.
Confirmation overlay for /mcp reconnect --force with no pending login.
Animated spinner using charset-appropriate frames.
Animated loading indicator with status text and elapsed time.
Result of formatting tool output for display.
Widget displaying a user message.
Widget displaying a queued (pending) user message in grey.
Widget displaying a skill invocation with collapsible body.
Widget displaying an assistant message with markdown support.
Widget displaying a tool call with collapsible output.
Widget displaying a diff with syntax highlighting.
Widget displaying an error message.
Widget displaying an app message.
Widget displaying a summarization completion notification.
Modal dialog for switching between available agents.
Strategy for building a tool's HITL approval widget.
Renderer for write_file tool - shows full file content.
Renderer for task tool — interrupt description provides full context.
Renderer for edit_file tool - shows unified diff.
Modal dialog for managing startup warning preferences.
Result of handling a key event in the completion system.
Protocol for views that can display completion suggestions.
Protocol for completion controllers.
Controller for / slash command completion.
Controller for @ file completion with fuzzy matching from current cwd.
Manages multiple completion controllers, delegating to the active one.
Manages command history with file persistence.
Modal that shows self-update progress and a bounded log tail.
Posted when the changelog row is clicked with the mouse.
Modal dedicated to the update-available notification.
A clickable completion option in the autocomplete popup.
Message sent when a completion option is clicked.
Popup widget that displays completion suggestions as clickable options.
Message sent when a completion option is clicked.
TextArea subclass with custom key handling for chat input.
Message sent when text is submitted.
Request previous history entry.
Request next history entry.
Message sent when paste payload resolves to file paths.
Posted when the user presses a printable key or backspace.
Chat input widget with prompt, multi-line text, autocomplete, and history.
Message sent when input is submitted.
Message sent when input mode changes.
Posted when the user presses a printable key or backspace in the input.
Modal asking whether to switch cwd before resuming a thread.
Soft-wrapping text input for free-form ask-user questions.
Posted when the user presses Enter to submit the answer.
Interactive widget for asking the user questions.
Message sent when user submits all answers.
Message sent when user cancels the ask_user prompt.
Modal dialog for theme selection with live preview.
Outcome of an AuthPromptScreen interaction.
Confirmation overlay shown before clearing a stored credential.
Modal that captures and persists an API key for one provider.
Modal that lists configured providers and lets the user manage keys.
Approval menu using standard Textual patterns.
Message sent when user makes a decision.
A selectable tool item in the MCP viewer.
Read-only modal for a failed MCP server's error details.
A selectable server-header row in the MCP viewer.
Modal viewer for active MCP servers and their tools.
First-step onboarding screen that asks for the user's name.
Onboarding screen that summarizes installed optional integrations.
A clickable thread option in the selector.
Message sent when a thread option is clicked.
Emit scroll changes so the parent can refresh the overflow indicator.
Message sent when the controls pane scroll position changes.
Confirmation modal shown before deleting a thread.
Scope dropdown overlay that consumes option navigation while focused.
Scope dropdown that keeps focus contained while its menu is open.
Modal dialog for browsing and resuming threads.
A label that displays a model name, right-aligned with smart truncation.
Status bar showing mode, auto-approve, cwd, git branch, tokens, and model.
Posted when an _ActionOption is clicked with the mouse.
Modal displaying a single notification's title, body, and actions.
Modal asking whether to restart the server after a successful install.
Types of messages in the chat.
Status of a tool call.
In-memory message data for virtualization.
Manages message data and widget window for virtualization.
Dismissal payload identifying which action the user picked.
Posted when a notification row is clicked with the mouse.
Posted when the user picks SUPPRESS from a notification's detail modal.
Modal listing pending notifications with drill-in details.
Confirmation overlay for installing an arbitrary --package.
Base class for tool approval widgets.
Generic approval widget for unknown tools.
Approval widget for write_file - shows file content with syntax highlighting.
Approval widget for edit_file - shows clean diff with colors.
Welcome banner displayed at startup.
Widget for displaying a unified diff with syntax highlighting.
Raised by MCPLoginScreen.action_cancel when the user cancels the flow.
Modal that renders the OAuth login flow and collects user input.
A clickable model option in the selector.
Message sent when a model option is clicked.
Full-screen modal for model selection.
Reset the terminal's dynamic default background color with OSC 111.
Fetch the LangSmith project URL, raising on any failure.
Validate that the model has required capabilities for deepagents.
Check that langchain-quickjs is installed for the --interpreter flag.
Neutralize control characters and deceptive Unicode in untrusted text.
Return " (released Nd ago)" for version, or "" when unknown.