用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
直接命令不会经过审查 Prompt;运行前请先检查来源。
npx skills add https://github.com/ricardoquesada/regenerator2000 --skill add-mcp-tool命令会保持在同一行。复制前请横向滚动并检查完整内容。
想先保存到本地?可下载 SkillsMP 当前能够提供的文件。
基于 SOC 职业分类
正在显示 SKILL.md
| name | add-mcp-tool |
| description | Streamlines the process of adding new tools to the MCP server. |
Use this workflow when adding a new tool to the crates/regenerator2000-core/src/mcp/handler.rs server.
Before writing code, confirm with the user:
r2000_get_memory)address: u16, length: u16)Vec<u8>)list_toolsIn crates/regenerator2000-core/src/mcp/handler.rs:
define_tool! macro or manually add the JSON definition inside the list_tools function.Example:
json!({
"name": "r2000_my_tool",
"description": "Description of what the tool does.",
"inputSchema": {
"type": "object",
"properties": {
"arg1": { "type": "string", "description": "..." }
},
"required": ["arg1"]
}
})
In crates/regenerator2000-core/src/mcp/handler.rs:
handle_tool_call_internal.Example:
"r2000_my_tool" => {
let arg1 = args["arg1"].as_str().ok_or(McpError::InvalidParams("Missing arg1".to_string()))?;
let result = my_tool_impl(app_state, arg1)?;
Ok(json!({ "content": [{ "type": "text", "text": result }] }))
}
In crates/regenerator2000-core/src/mcp/handler.rs (or a sub-module):
[tool_name]_impl.&mut AppState (or &AppState if read-only).Result<Value, McpError> or a specific type.In tests/verify_mcp.py:
test_[tool_name](client).client.rpc("tools/call", { ... }).if __name__ == "__main__": block.verify-mcp skill:
.agent/skills/verify-mcp/scripts/verify.sh
docs/mcp.md exists, update the "Tools" section with the new tool definition.