用cc skill调用codex做代码审核

skill相关的系统提示是这样的,两个技能占用344字符,约等于100token,平均1个技能50token
以一个context7 mcp为例,提供两个工具占用3113字符,约等于889.4token

Only use skills listed in <available_skills> below
- Do not invoke a skill that is already running
- Do not use this tool for built-in CLI commands (like /help, /clear, etc.)
</skills_instructions>

<available_skills>
<skill>
<name>
context7-auto-research
</name>
<description>
自动使用Context7进行文档研究,当用户需要代码生成、配置步骤或库/API文档时无需明确请求即可自动获取最新信息 (user)
</description>
<location>
user
</location>
</skill>
<skill>
<name>
version-bump
</name>
<description>
升级项目版本号并提交git,支持patch/minor/major版本升级或指定具体版本号 (project)
</description>
<location>
managed
</location>
</skill>
<skill>
<name>
codex-review
</name>
<description>
调用 codex 命令行进行代码审核,自动收集当前文件修改和任务状态一并发送 (user) (project)
</description>
<location>
managed
</location>
</skill>
</available_skills>

一个context7 mcp附带两个工具

{
    "name": "mcp__context7__resolve-library-id",
    "description": "Resolves a package/product name to a Context7-compatible library ID and returns a list of matching libraries.\n\nYou 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.\n\nSelection Process:\n1. Analyze the query to understand what library/package the user is looking for\n2. Return the most relevant match based on:\n- Name similarity to the query (exact matches prioritized)\n- Description relevance to the query's intent\n- Documentation coverage (prioritize libraries with higher Code Snippet counts)\n- Source reputation (consider libraries with High or Medium reputation more authoritative)\n- Benchmark Score: Quality indicator (100 is the highest score)\n\nResponse Format:\n- Return the selected library ID in a clearly marked section\n- Provide a brief explanation for why this library was chosen\n- If multiple good matches exist, acknowledge this but proceed with the most relevant one\n- If no good matches exist, clearly state this and suggest query refinements\n\nFor ambiguous queries, request clarification before proceeding with a best-guess match.",
    "input_schema": {
        "type": "object",
        "properties": {
            "libraryName": {
                "type": "string",
                "description": "Library name to search for and retrieve a Context7-compatible library ID."
            }
        },
        "required": [
            "libraryName"
        ],
        "additionalProperties": false,
        "$schema": "http://json-schema.org/draft-07/schema#"
    }
},
{
    "name": "mcp__context7__get-library-docs",
    "description": "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.",
    "input_schema": {
        "type": "object",
        "properties": {
            "context7CompatibleLibraryID": {
                "type": "string",
                "description": "Exact Context7-compatible library ID (e.g., '/mongodb/docs', '/vercel/next.js', '/supabase/supabase', '/vercel/next.js/v14.3.0-canary.87') retrieved from 'resolve-library-id' or directly from user query in the format '/org/project' or '/org/project/version'."
            },
            "mode": {
                "type": "string",
                "enum": [
                    "code",
                    "info"
                ],
                "default": "code",
                "description": "Documentation mode: 'code' for API references and code examples (default), 'info' for conceptual guides, narrative information, and architectural questions."
            },
            "topic": {
                "type": "string",
                "description": "Topic to focus documentation on (e.g., 'hooks', 'routing')."
            },
            "page": {
                "type": "integer",
                "minimum": 1,
                "maximum": 10,
                "description": "Page number for pagination (start: 1, default: 1). If the context is not sufficient, try page=2, page=3, page=4, etc. with the same topic."
            }
        },
        "required": [
            "context7CompatibleLibraryID"
        ],
        "additionalProperties": false,
        "$schema": "http://json-schema.org/draft-07/schema#"
    }
}
5 Likes