wxyh
MCP 服务配置
复制以下 JSON 到 OPClaw 或其他 MCP 客户端的配置文件中即可使用
{
"mcpServers": {
"context7": {
"args": [
"-y",
"@upstash/context7-mcp"
],
"command": "npx"
}
}
}
该服务需要配置环境变量:wxyh
可用工具 (2 个)
该服务在 MCP 协议中暴露的工具,AI 可按需调用
resolve-library-id 1 个参数 需填 1 项
Resolves a package/product name to a Context7-compatible library ID and returns a list of matching libraries. You MUST call this function before 'get-library-docs' to obtain a valid Context7-compatible library ID UNLESS the user explicitly provides a library ID in the format '/org/project' or '/org/project/version' in their query. Selection Process: 1. Analyze the query to understand what library/package the user is looking for 2. Return the most relevant match based on: - Name similarity to the query (exact matches prioritized) - Description relevance to the query's intent - Documentation coverage (prioritize libraries with higher Code Snippet counts) - Source reputation (consider libraries with High or Medium reputation more authoritative) - Benchmark Score: Quality indicator (100 is the highest score) Response Format: - Return the selected library ID in a clearly marked section - Provide a brief explanation for why this library was chosen - If multiple good matches exist, acknowledge this but proceed with the most relevant one - If no good matches exist, clearly state this and suggest query refinements For ambiguous queries, request clarification before proceeding with a best-guess match.
必填参数:libraryName
get-library-docs 4 个参数 需填 1 项
Fetches up-to-date documentation for a library. You must call 'resolve-library-id' first to obtain the exact Context7-compatible library ID required to use this tool, UNLESS the user explicitly provides a library ID in the format '/org/project' or '/org/project/version' in their query. Use mode='code' (default) for API references and code examples, or mode='info' for conceptual guides, narrative information, and architectural questions.
必填参数:context7CompatibleLibraryID
服务介绍
当然,可以帮您翻译该文档。请提供需要翻译的具体内容或文本。如果直接提供了链接,我可能无法直接访问以获取内容。您可以将相关段落复制到这里吗?这样我可以更准确地进行翻译。