MCP Catalogs
首页

mcp-chain-of-draft-prompt-tool

by brendancopley·19·综合分 40

一个实现链式草稿(CoD)推理的 MCP 服务器,可在减少令牌用量的同时提升 LLM 响应质量。

ai-llmproductivitydeveloper-tools
3
Forks
1
活跃 Issue
8 个月前
最近提交
2 天前
收录于

概述

MCP 链式草稿提示工具将标准提示转换为链式草稿格式,通过最多减少 92.4% 的令牌使用量来增强推理能力。该工具支持多种 LLM 提供商,包括 Anthropic Claude、OpenAI GPT 模型、Mistral AI 以及通过 Ollama 或自定义端点使用的本地模型。工具自动处理提示转换、LLM 处理和结果格式化,同时保持高精度。

试试问 AI

装完之后,这里有 5 个你可以让 AI 做的事:

:通过减少令牌使用实现成本高效的 LLM 推理
:为复杂问题解决任务提供增强的准确性
:与 Claude Desktop 和 Dive GUI 集成以改进工作流程
:什么是链式草稿(CoD)推理?
:支持哪些 LLM 提供商?

什么时候选它

当您需要增强推理质量同时显著减少令牌成本时,特别是在 CoT 方法成本过高或速度过慢的任务中,应选择此工具。

什么时候不要选它

如果您对复杂任务需要极高精度,而 CoD 的简洁方法可能缺乏足够细节,或者您偏好无需配置步骤的完整开箱即用解决方案,则不应选择此工具。

此 server 暴露的工具

从 README 抽取出 7 个工具
  • chain_of_draft_solve

    Solve a problem using Chain of Draft reasoning

  • math_solve

    Solve a math problem with Chain of Draft

  • code_solve

    Solve a coding problem with Chain of Draft

  • logic_solve

    Solve a logic problem with Chain of Draft

  • get_performance_stats

    Get performance statistics for Chain of Draft vs Chain of Thought

  • get_token_reduction

    Get token reduction statistics when using Chain of Draft

  • analyze_problem_complexity

    Analyze the complexity of a given problem

可对比工具

mcp-cot-prompt-toolllm-tools-mcpmcp-reasoning-tool

安装

安装

Python 安装

  1. 克隆仓库
  2. 安装依赖:

``bash pip install -r requirements.txt ``

  1. .env 文件中配置 API 密钥:

`` ANTHROPIC_API_KEY=your_api_key_here ``

  1. 运行服务器:

``bash python server.py ``

Claude Desktop 集成

添加到您的 claude_desktop_config.json

{
    "mcpServers": {
        "chain-of-draft-prompt-tool": {
            "command": "python3",
            "args": ["/absolute/path/to/cod/server.py"],
            "env": {
                "ANTHROPIC_API_KEY": "your_api_key_here"
            }
        }
    }
}

FAQ

什么是链式草稿(CoD)推理?
链式草稿是一种推理方法,使用非常简洁的步骤(通常不超过 5 个单词)来保持准确性,同时显著减少与传统链式思维(CoT)相比的令牌使用量。
支持哪些 LLM 提供商?
该工具支持 Anthropic Claude、OpenAI GPT 模型、Mistral AI,以及通过 Ollama 或兼容 OpenAI API 的自定义端点使用的本地模型。

mcp-chain-of-draft-prompt-tool 对比

GitHub →

最后更新于 · 由 README + GitHub 公开数据自动生成。