Skip to main content

Documentation Index

Fetch the complete documentation index at: https://nvd-54.mintlify.app/llms.txt

Use this file to discover all available pages before exploring further.

将自定义同步子智能体定义为 markdown 文件,以便 CLI 智能体可以将专门的任务委派给它们。
异步子智能体目前在深度智能体 CLI 中不可用。
每个子智能体都有自己的文件夹和一个 AGENTS.md 文件:
.deepagents/agents/{subagent-name}/AGENTS.md   # 项目级
~/.deepagents/{agent}/agents/{subagent-name}/AGENTS.md  # 用户级
同名时项目级子智能体会覆盖用户级子智能体(参见优先级规则)。 frontmatter 需要 namedescription(与 SubAgent 字典规范相同)。markdown 正文将成为子智能体的 system_prompt。除了基本规范外,AGENTS.md 文件还支持可选的 model frontmatter 字段,用于覆盖该子智能体使用的主智能体模型。使用 provider:model-name 格式(例如 anthropic:claude-opus-4-7openai:gpt-5.5)。省略则继承主智能体的模型。
其他 SubAgent 字段(toolsmiddlewareinterrupt_onskills)目前无法通过 AGENTS.md frontmatter 配置——以这种方式定义的自定义子智能体会继承主智能体的工具。如需完全控制,请直接使用 SDK。

文件格式

子智能体 AGENTS.md 文件使用 YAML frontmatter 加 markdown 正文:
---
name: researcher
description: Research topics on the web before writing content
model: anthropic:claude-haiku-4-5-20251001
---

You are a research assistant with access to web search.

## Your Process
1. Search for relevant information
2. Summarize findings clearly

示例:高性价比子智能体

对简单的委派任务使用更便宜、更快速的模型,同时让主智能体保持使用更强大的模型:
---
name: general-purpose
description: General-purpose agent for research and multi-step tasks
model: anthropic:claude-haiku-4-5-20251001
---

You are a general-purpose assistant. Complete the task efficiently and return a concise summary.
这将覆盖内置的通用子智能体,将所有委派的任务路由到更便宜的模型。详见覆盖通用子智能体