Loading...
Loading...
Compare original and translation side by side
STOP - Before providing ANY response about Claude Agent SDK:
- INVOKE
skilldocs-management- QUERY using keywords: Agent SDK, TypeScript SDK, Python SDK, sessions, custom tools, permissions, or related topics
- BASE all responses EXCLUSIVELY on official documentation loaded
Skipping this step results in outdated or incorrect information.
停 - 在提供任何关于Claude Agent SDK的响应之前:
- 调用
技能docs-management- 查询时使用关键词:Agent SDK、TypeScript SDK、Python SDK、sessions、custom tools、permissions或相关主题
- 所有响应完全基于加载的官方文档
跳过此步骤会导致信息过时或错误。
| doc_id | Topic |
|---|---|
| platform-claude-com-docs-en-agent-sdk-overview | SDK overview and getting started |
| platform-claude-com-docs-en-agent-sdk-typescript | TypeScript SDK API reference |
| platform-claude-com-docs-en-agent-sdk-python | Python SDK API reference |
| platform-claude-com-docs-en-agent-sdk-sessions | Session management and resumption |
| platform-claude-com-docs-en-agent-sdk-streaming-vs-single-mode | Input mode selection |
| platform-claude-com-docs-en-agent-sdk-custom-tools | Creating custom tools |
| platform-claude-com-docs-en-agent-sdk-permissions | Permission configuration |
| platform-claude-com-docs-en-agent-sdk-modifying-system-prompts | System prompt customization |
| platform-claude-com-docs-en-agent-sdk-cost-tracking | Cost and usage tracking |
| platform-claude-com-docs-en-agent-sdk-todo-tracking | Todo list integration |
| platform-claude-com-docs-en-agent-sdk-structured-outputs | Structured output features |
| platform-claude-com-docs-en-agent-sdk-hosting | Production hosting patterns |
| platform-claude-com-docs-en-agent-sdk-mcp | MCP server integration |
| platform-claude-com-docs-en-agent-sdk-plugins | Plugin loading |
| platform-claude-com-docs-en-agent-sdk-subagents | Subagent usage |
| platform-claude-com-docs-en-agent-sdk-skills | Skills integration |
| platform-claude-com-docs-en-agent-sdk-slash-commands | Slash command usage |
| doc_id | 主题 |
|---|---|
| platform-claude-com-docs-en-agent-sdk-overview | SDK概述与入门指南 |
| platform-claude-com-docs-en-agent-sdk-typescript | TypeScript SDK API参考 |
| platform-claude-com-docs-en-agent-sdk-python | Python SDK API参考 |
| platform-claude-com-docs-en-agent-sdk-sessions | 会话管理与恢复 |
| platform-claude-com-docs-en-agent-sdk-streaming-vs-single-mode | 输入模式选择 |
| platform-claude-com-docs-en-agent-sdk-custom-tools | 创建自定义工具 |
| platform-claude-com-docs-en-agent-sdk-permissions | 权限配置 |
| platform-claude-com-docs-en-agent-sdk-modifying-system-prompts | 系统提示自定义 |
| platform-claude-com-docs-en-agent-sdk-cost-tracking | 成本与使用量追踪 |
| platform-claude-com-docs-en-agent-sdk-todo-tracking | 待办事项列表集成 |
| platform-claude-com-docs-en-agent-sdk-structured-outputs | 结构化输出功能 |
| platform-claude-com-docs-en-agent-sdk-hosting | 生产环境托管模式 |
| platform-claude-com-docs-en-agent-sdk-mcp | MCP服务器集成 |
| platform-claude-com-docs-en-agent-sdk-plugins | 插件加载 |
| platform-claude-com-docs-en-agent-sdk-subagents | 子Agent使用 |
| platform-claude-com-docs-en-agent-sdk-skills | 技能集成 |
| platform-claude-com-docs-en-agent-sdk-slash-commands | 斜杠命令使用 |
| Topic | Keywords |
|---|---|
| Overview | "Agent SDK", "Claude Agent SDK overview", "why use Agent SDK" |
| Installation | "Agent SDK installation", "npm install claude-agent-sdk", "pip install claude-agent-sdk" |
| SDK Options | "SDK options", "TypeScript SDK", "Python SDK" |
| Migration | "Claude Code SDK migration", "migration guide" |
| 主题 | 关键词 |
|---|---|
| 概述 | "Agent SDK"、"Claude Agent SDK overview"、"why use Agent SDK" |
| 安装 | "Agent SDK installation"、"npm install claude-agent-sdk"、"pip install claude-agent-sdk" |
| SDK选项 | "SDK options"、"TypeScript SDK"、"Python SDK" |
| 迁移 | "Claude Code SDK migration"、"migration guide" |
| Topic | Keywords |
|---|---|
| API Key | "Agent SDK authentication", "ANTHROPIC_API_KEY" |
| Bedrock | "CLAUDE_CODE_USE_BEDROCK", "Bedrock SDK" |
| Vertex | "CLAUDE_CODE_USE_VERTEX", "Vertex SDK" |
| 主题 | 关键词 |
|---|---|
| API密钥 | "Agent SDK authentication"、"ANTHROPIC_API_KEY" |
| Bedrock | "CLAUDE_CODE_USE_BEDROCK"、"Bedrock SDK" |
| Vertex | "CLAUDE_CODE_USE_VERTEX"、"Vertex SDK" |
| Topic | Keywords |
|---|---|
| Session Management | "session management SDK", "session ID", "getting session ID" |
| Resumption | "session resumption", "resume option", "continuing sessions" |
| Forking | "forking sessions", "forkSession", "session branching" |
| 主题 | 关键词 |
|---|---|
| 会话管理 | "session management SDK"、"session ID"、"getting session ID" |
| 恢复 | "session resumption"、"resume option"、"continuing sessions" |
| 分叉 | "forking sessions"、"forkSession"、"session branching" |
| Topic | Keywords |
|---|---|
| Overview | "streaming vs single mode", "input modes SDK" |
| Streaming Mode | "streaming input mode", "recommended mode" |
| Single Mode | "single input mode", "non-streaming" |
| 主题 | 关键词 |
|---|---|
| 概述 | "streaming vs single mode"、"input modes SDK" |
| 流式模式 | "streaming input mode"、"recommended mode" |
| 单次模式 | "single input mode"、"non-streaming" |
| Topic | Keywords |
|---|---|
| Creating Tools | "custom tools SDK", "creating custom tools" |
| Tool Schema | "tool schema", "tool definition SDK" |
| Tool Handlers | "tool handlers", "tool execution SDK" |
| 主题 | 关键词 |
|---|---|
| 创建工具 | "custom tools SDK"、"creating custom tools" |
| 工具Schema | "tool schema"、"tool definition SDK" |
| 工具处理器 | "tool handlers"、"tool execution SDK" |
| Topic | Keywords |
|---|---|
| Tool Permissions | "allowedTools", "disallowedTools", "tool permissions SDK" |
| Permission Mode | "permissionMode SDK", "permission strategy" |
| Handling Permissions | "handling permissions SDK", "permission callbacks" |
| 主题 | 关键词 |
|---|---|
| 工具权限 | "allowedTools"、"disallowedTools"、"tool permissions SDK" |
| 权限模式 | "permissionMode SDK"、"permission strategy" |
| 权限处理 | "handling permissions SDK"、"permission callbacks" |
| Topic | Keywords |
|---|---|
| Overview | "modifying system prompts", "system prompts SDK" |
| CLAUDE.md | "CLAUDE.md SDK", "settingSources", "project instructions" |
| Append System Prompt | "appendSystemPrompt", "custom instructions" |
| Output Style | "outputStyle SDK", "agent persona" |
| 主题 | 关键词 |
|---|---|
| 概述 | "modifying system prompts"、"system prompts SDK" |
| CLAUDE.md | "CLAUDE.md SDK"、"settingSources"、"project instructions" |
| 追加系统提示 | "appendSystemPrompt"、"custom instructions" |
| 输出样式 | "outputStyle SDK"、"agent persona" |
| Topic | Keywords |
|---|---|
| Cost Tracking | "cost tracking SDK", "token usage", "billing SDK" |
| Todo Tracking | "todo tracking SDK", "todo lists SDK", "task management" |
| 主题 | 关键词 |
|---|---|
| 成本追踪 | "cost tracking SDK"、"token usage"、"billing SDK" |
| 待办事项追踪 | "todo tracking SDK"、"todo lists SDK"、"task management" |
| Topic | Keywords |
|---|---|
| Structured Outputs | "structured outputs SDK", "JSON results", "validated outputs" |
| Schema Definition | "output schema SDK", "result validation" |
| 主题 | 关键词 |
|---|---|
| 结构化输出 | "structured outputs SDK"、"JSON results"、"validated outputs" |
| Schema定义 | "output schema SDK"、"result validation" |
| Topic | Keywords |
|---|---|
| Hosting Overview | "hosting Agent SDK", "production deployment" |
| Ephemeral Sessions | "ephemeral sessions", "pattern 1 hosting" |
| Persistent Sessions | "persistent sessions", "pattern 2 hosting" |
| 主题 | 关键词 |
|---|---|
| 托管概述 | "hosting Agent SDK"、"production deployment" |
| 临时会话 | "ephemeral sessions"、"pattern 1 hosting" |
| 持久会话 | "persistent sessions"、"pattern 2 hosting" |
| Topic | Keywords |
|---|---|
| Plugins | "plugins SDK", "loading plugins", "programmatic plugins" |
| MCP Integration | "MCP SDK", "MCP servers SDK", "extending with MCP" |
| 主题 | 关键词 |
|---|---|
| 插件 | "plugins SDK"、"loading plugins"、"programmatic plugins" |
| MCP集成 | "MCP SDK"、"MCP servers SDK"、"extending with MCP" |
| Topic | Keywords |
|---|---|
| Branding Guidelines | "agent branding", "Claude Agent naming", "SDK branding" |
| 主题 | 关键词 |
|---|---|
| 品牌指南 | "agent branding"、"Claude Agent naming"、"SDK branding" |
| Topic | Keywords |
|---|---|
| Subagents | "subagents SDK", "SDK subagents", "subagent integration" |
| Skills | "skills SDK", "SDK skills", "agent skills SDK" |
| Slash Commands | "slash commands SDK", "SDK commands", "custom commands SDK" |
| 主题 | 关键词 |
|---|---|
| 子Agent | "subagents SDK"、"SDK subagents"、"subagent integration" |
| 技能 | "skills SDK"、"SDK skills"、"agent skills SDK" |
| 斜杠命令 | "slash commands SDK"、"SDK commands"、"custom commands SDK" |
| Topic | Keywords |
|---|---|
| TypeScript Reference | "TypeScript SDK reference", "TypeScript API" |
| Python Reference | "Python SDK reference", "Python API" |
| Changelog | "SDK changelog", "SDK updates" |
| 主题 | 关键词 |
|---|---|
| TypeScript参考 | "TypeScript SDK reference"、"TypeScript API" |
| Python参考 | "Python SDK reference"、"Python API" |
| 更新日志 | "SDK changelog"、"SDK updates" |
User asks: "How do I create a custom tool in the Agent SDK?"
1. Invoke docs-management skill
2. Use keywords: "custom tools SDK", "creating custom tools"
3. Load official documentation
4. Provide guidance based EXCLUSIVELY on official docs用户提问:“如何在Agent SDK中创建自定义工具?”
1. 调用docs-management技能
2. 使用关键词:"custom tools SDK"、"creating custom tools"
3. 加载官方文档
4. 完全基于官方文档提供指导User asks: "I want to build an agent with sessions, custom tools, and cost tracking"
1. Invoke docs-management skill with multiple queries:
- "session management SDK", "session resumption"
- "custom tools SDK", "creating custom tools"
- "cost tracking SDK", "token usage"
2. Synthesize guidance from official documentation用户提问:“我想要构建一个包含会话、自定义工具和成本追踪功能的Agent”
1. 使用多个查询调用docs-management技能:
- "session management SDK"、"session resumption"
- "custom tools SDK"、"creating custom tools"
- "cost tracking SDK"、"token usage"
2. 整合官方文档中的指导内容User reports: "My session resumption isn't working"
1. Invoke docs-management skill
2. Use keywords: "session management SDK", "resume option", "session ID"
3. Check official docs for session patterns
4. Guide user through proper session handling用户反馈:“我的会话无法恢复”
1. 调用docs-management技能
2. 使用关键词:"session management SDK"、"resume option"、"session ID"
3. 查阅官方文档中的会话模式
4. 引导用户正确处理会话| Issue | Keywords for docs-management |
|---|---|
| Authentication failing | "Agent SDK authentication", "ANTHROPIC_API_KEY" |
| Session not resuming | "session resumption", "resume option" |
| Custom tool not working | "custom tools SDK", "tool handlers" |
| Permissions blocking | "allowedTools", "permissionMode SDK" |
| System prompt not loading | "CLAUDE.md SDK", "settingSources" |
| Cost tracking issues | "cost tracking SDK", "token usage" |
| Structured output invalid | "structured outputs SDK", "schema definition" |
| Streaming not working | "streaming input mode", "streaming vs single" |
| 问题 | docs-management查询关键词 |
|---|---|
| 身份验证失败 | "Agent SDK authentication"、"ANTHROPIC_API_KEY" |
| 会话无法恢复 | "session resumption"、"resume option" |
| 自定义工具无法工作 | "custom tools SDK"、"tool handlers" |
| 权限被阻止 | "allowedTools"、"permissionMode SDK" |
| 系统提示未加载 | "CLAUDE.md SDK"、"settingSources" |
| 成本追踪问题 | "cost tracking SDK"、"token usage" |
| 结构化输出无效 | "structured outputs SDK"、"schema definition" |
| 流式功能无法工作 | "streaming input mode"、"streaming vs single" |
When working with Agent SDK + MCP integration:
1. Use agent-sdk-development for SDK-specific guidance
2. Use mcp-integration for MCP server configuration
3. Both skills delegate to docs-management for official documentation处理Agent SDK + MCP集成时:
1. 使用agent-sdk-development获取SDK相关指导
2. 使用mcp-integration获取MCP服务器配置指导
3. 两个技能均委托给docs-management获取官方文档