新增技能包指导构建高质量 MCP servers,支持 Python/Node
用于创建高质量 MCP(Model Context Protocol)servers 的指南,这些 servers 使 LLMs 能通过精心设计的工具与外部服务交互。
在构建 MCP servers 以集成外部 API 或服务时使用,无论使用 Python(FastMCP)还是 Node/TypeScript(MCP SDK)。
Skill 会改变智能体的行为并可能包含可执行脚本。安装前请先阅读其 SKILL.md 与脚本,社区来源尤其要谨慎。
npx skills add anthropics/skills -s mcp-builder
npx skills add anthropics/skills -s mcp-builder -g
npx skills add anthropics/skills -l
git clone --depth 1 https://github.com/anthropics/skills.git /tmp/skills-src && cp -r /tmp/skills-src/skills/mcp-builder ~/.claude/skills/
命令使用开源的 skills CLI(vercel-labs/skills),支持 Claude Code、Cursor、Codex 等多种智能体。
摘自项目自己的说明,具体以项目主页为准。
Create MCP (Model Context Protocol) servers that enable LLMs to interact with external services through well-designed tools. The quality of an MCP server is measured by how well it enables LLMs to accomplish real-world tasks.
Creating a high-quality MCP server involves four main phases:
API Coverage vs. Workflow Tools: Balance comprehensive API endpoint coverage with specialized workflow tools. Workflow tools can be more convenient for specific tasks, while comprehensive coverage gives agents flexibility to compose operations. Performance varies by client—some clients benefit from code execution that combines basic tools, while others work better with higher-level workflows. When uncertain, prioritize comprehensive API coverage.
Tool Naming and Discoverability:
Clear, descriptive tool names help agents find the right tools quickly. Use consistent prefixes (e.g., github_create_issue, github_list_repos) and action-oriented naming.
Context Management: Agents benefit from concise tool descriptions and the ability to filter/paginate results. Design tools that return focused, relevant data. Some clients support code execution which can help agents filter and process data efficiently.
Actionable Error Messages: Error messages should guide agents toward solutions with specific suggestions and next steps.
Navigate the MCP specification:
Start with the sitemap to find relevant pages: https://modelcontextprotocol.io/sitemap.xml
Then fetch specific pages with .md suffix for markdown format (e.g., https://modelcontextprotocol.io/specification/draft.md).
Key pages to review:
Recommended stack:
Load framework documentation:
…