mcpField
M
MCP Advanced Reasoning Server for Cursor AI

MCP Advanced Reasoning Server for Cursor AI

本地服务
github.com/AzDeltaQQAI 与智能体1384 周前更新

关于 MCP Advanced Reasoning Server for Cursor AI

MCP Advanced Reasoning Server for Cursor AI 是一个面向 Cursor AI 对话的推理工具服务,提供多种推理方式。README 指出其当前响应使用占位内容,并非生产级推理算法。

主要功能

  1. 01MCTS 推理工具
  2. 02Beam search 推理工具
  3. 03R1 Transformer 推理工具
  4. 04Transformer 与 MCTS 混合模式
  5. 05自动执行多步推理

适用场景

  1. 01为复杂问题探索多条路径
  2. 02使用 R1 分析算法
  3. 03用混合推理考虑代码重构方案

MCP 相关

它向 Cursor AI 等 MCP 客户端提供 MCTS、beam search、R1 Transformer 和混合模式等推理工具。

配置

本地服务的配置在各客户端中通用,复制后粘贴到客户端的 MCP 配置文件即可。

暂未收录安装方式

我们还没有获取到这个服务的安装包或远程地址,请按项目 README 中的说明安装。

代码仓库

工具

还没有获取到工具列表

本地服务需要在你的电脑上运行后才能读取工具,维护者暂未提供工具列表。

详细介绍

值得一提:

https://github.com/Jacck/mcp-reasoner

感谢 Jacck 提供这个创意。

面向 Cursor AI 的高级推理 MCP 服务

一个为 Cursor AI 中的 Claude 提供高级推理能力的模型上下文协议(MCP)服务。

功能

  • 蒙特卡洛树搜索(MCTS):使用 MCTS 推理处理复杂的问题求解任务。
  • 束搜索:同时探索多条推理路径。
  • R1 Transformer:利用基于 Transformer 的推理处理复杂问题。
  • 混合推理:结合 Transformer 分析和 MCTS,增强推理能力。
  • 自动迭代推理:所有多步推理方法都会在一次工具调用中自动完成所有推理步骤。

安装

npm install
npm run build

使用方法

在 Cursor AI 中配置
  1. 首先构建服务:

    cd mcp-reasoning-server
    npm run build
    
  2. 打开 Cursor AI

  3. 前往 Settings > Features > MCP

  4. 点击“+ Add new global MCP server”按钮

  5. 输入以下详细信息:

    • 在命令字段中输入:node C:\\Users\\[YourUsername]\\path\\to\\mcp-reasoning-server\\dist\\index.js
    • 确保使用项目 dist/index.js 文件的完整路径
    • Windows 路径请使用双反斜杠
  6. 点击“Add”

  7. 在列表中找到你的服务(初始状态会显示为“Disabled”)

  8. 点击“Disabled”,将其切换为“Enabled”

  9. 点击刷新按钮,加载可用工具

  10. 命令提示符窗口将自动打开——这表示你的服务正在运行

  11. 只要命令提示符窗口保持打开状态,推理工具就可以使用

或者,你也可以手动编辑 Cursor MCP 配置文件 C:\Users\[Username]\.cursor\mcp.json(Windows):

{
  "mcpServers": {
    "mcp-reasoner": {
      "command": "node",
      "args": ["C:\\Users\\[Username]\\path\\to\\mcp-reasoning-server\\dist\\index.js"]
    }
  }
}
重要说明
  • 服务运行:只有在命令提示符窗口打开且服务正在运行时,工具才可用
  • 进行更改:如果修改了服务代码,必须先运行 npm run build 重新构建,然后再重启
  • 重启:要重启服务,请关闭命令提示符窗口,然后在 Cursor Settings 中关闭再重新启用该服务
使用推理工具

你可以在与 Claude 的 Cursor AI 对话中直接使用推理工具:

MCTS 推理

使用 /reason-mcts 命令并在其后输入你的查询,以启动基于 MCTS 的推理链:

/reason-mcts How can I optimize the performance of this React component?
束搜索推理

使用 /reason-beam 命令进行基于束搜索的推理:

/reason-beam What architecture would be best for this microservice system?
R1 Transformer 推理

使用 /reason-r1 命令进行单步、基于 Transformer 的推理:

/reason-r1 Analyze the complexity of this algorithm.
混合推理

使用 /reason-hybrid 命令结合 Transformer 和 MCTS 推理:

/reason-hybrid How should we approach refactoring this legacy codebase?
Claude 集成

为了让 Claude 更方便地使用这些推理工具,你可以添加以下自定义指令:

When I use commands like /reason-mcts, /reason-beam, /reason-r1, or /reason-hybrid in chat, interpret them as requests to use the corresponding reasoning tools:

/reason-mcts: Use the reason_mcts tool with the text following the command as the query
Example: "/reason-mcts How do I solve this problem?" should call the reason_mcts tool

/reason-beam: Use the reason_beam tool with the text following the command as the query
Example: "/reason-beam What's the best approach for this complex problem?" should call the reason_beam tool

/reason-r1: Use the reason_r1 tool with the text following the command as the query
Example: "/reason-r1 Analyze this code for performance issues" should call the reason_r1 tool

/reason-hybrid: Use the reason_hybrid tool with the text following the command as the query
Example: "/reason-hybrid How should we restructure this architecture?" should call the reason_hybrid tool

When these commands are used, extract the text after the command as the query parameter and use the corresponding tool to perform advanced reasoning.

开发

项目结构
  • src/index.ts:服务的主入口
  • src/tools/reasoning-tools.ts:推理工具的实现
  • src/tools/reasoning-wrapper.ts:便于在 Cursor 中使用的命令包装器
  • src/utils/errors.ts:错误处理实用程序
自动迭代推理

推理工具经过实现,可在一次工具调用中自动完成所有内部推理步骤。每种推理方法都遵循以下流程:

  1. 初始化第一个思考/步骤
  2. 自动生成后续思考/步骤
  3. 返回所有思考以及最终结果

这种方法可确保推理过程完整完成,无需手动多次调用工具。

添加新的推理方法

要添加新的推理方法,请按以下步骤操作:

  1. 在 src/tools/reasoning-tools.ts 中添加新的工具实现
  2. 在 src/tools/reasoning-wrapper.ts 中添加对应的命令包装器
  3. 参照现有工具的模式,定义参数和响应格式
  4. 如果是多步推理方法,请实现自动迭代
  5. 使用 npm run build 重新构建项目

局限性

这是一个模拟推理服务。在生产环境的实现中,你应连接到实际的推理算法,而不是使用当前的占位响应。

许可证

ISC

评论

支持 Markdown

第一次接触 MCP?

从协议是什么,到在客户端里装上第一个服务,这几条回答覆盖了大多数入门问题。

一个开放协议,规定了 AI 应用如何以统一方式连接外部工具与数据源。客户端负责与模型对话,MCP 服务负责提供工具、资源和提示模板,两者通过标准消息通信,同一个服务可以被不同客户端复用。