Token导航 LogoToken导航TokenDH.com
AI Consultation MCP logo
AI代理stdio官方级别未说明来源级核验

AI Consultation MCP

MCP Server

ai-consultation-mcp

一个基于模型上下文协议(MCP)的服务器,使AI代理能够从其他AI模型获取第二意见,丰富其工作过程中的视角。

工具数

12

提示词数

0

GitHub Stars

0

资源数

0
AI代理TypeScriptClaudeClaudeCursorWindsurfCline

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

作者 / 组织

menesekinci

提供方

menesekinci

最后核验

2026/5/17 20:21

运行时

Node.js

快速接入

先看主来源和安装命令,再打开仓库或文档;下面只保留这个条目的关键接入事实。

命令预览

npx ai-consultation-mcp --install

详细介绍

代理咨询MCP

](https://www.npmjs.com/package/ai-consultation-mcp) ![License: MIT](https://opensource.org/licenses/MIT)

MCP(模型上下文协议)服务器,使AI代理能够获得 第二意见 从其他人工智能模型中,丰富他们在工作中的视角。

目的当人工智能代理处理复杂任务时,单一视角可能会导致盲点或次优解决方案。这个MCP服务器允许像Claude Code这样的代理咨询DeepSeek和OpenAI模型,以获得替代观点、验证或不同的问题解决策略。

特性

  • 中央守护进程架构:基于SQLite的中央守护进程,在所有连接的客户端之间实现WebSocket实时同步
  • 多工具自动安装:自动检测和配置用于Claude代码、游标、Windsurf、Cline、Continue、Zed、Roo代码、OpenCode和VSCode副本的MCP
  • 多提供商支持:

- 开放人工智能:gpt-5.2,gpt-5.2-pro - 深度求索:deepseek聊天,deepseek推理器

  • 专业咨询模式:调试、代码分析、架构审查、计划验证、概念解释
  • 对话管理:继续与上下文进行多回合对话(最多5条消息,以防止无限循环)
  • 实时Web用户界面:配置提供程序、API密钥,并通过WebSocket通过实时更新查看对话历史记录
  • 加密存储:API密钥在静止时使用AES-256-GCM加密
  • RAG+内存:上传文档(txt、md、pdf、docx),添加记忆笔记,并在咨询期间使用它们

快速入门(2个步骤)

# 1. Auto-install to all detected AI tools
npx ai-consultation-mcp --install

# 2. Configure your API key in the Web UI that opens automatically
# Done! Restart your AI tools and start using

安装

选项1:npm(推荐)

安装和使用MCP服务器的最简单方法:

# Auto-install to all detected AI tools
npx ai-consultation-mcp --install

# Or install globally
npm install -g ai-consultation-mcp
ai-consultation-mcp --install

选项2:来自GitHub

克隆存储库并从源代码构建:

# Clone the repository
git clone https://github.com/menesekinci/ai-consultation-mcp.git
cd ai-consultation-mcp

# Install dependencies
npm install

# Build
npm run build

# Run the installer
npm start -- --install

自动安装功能

--install 旗帜将:

  • 扫描已安装的AI工具(Claude Code、Cursor、Windsurf、OpenCode、VSCode Copilot、Cline、Continue、Zed、Roo Code)
  • 将MCP配置添加到每个检测到的工具中
  • 打开Web UI以配置API密钥
  • 显示需要重新启动哪些工具

支持的AI工具

工具配置位置
克劳德代码~/.claude/mcp.json
光标~/.cursor/mcp.json
风帆冲浪~/.codeium/windsurf/mcp_config.json
OpenCode~/.config/opencode/opencode.json
VSCode副驾驶~/Library/Application Support/Code/User/mcp.json
ClineVSCode全局存储
继续~/.continue/config.json
Zed~/.config/zed/settings.json
Roo代码VSCode全局存储

手动安装(克劳德代码)

增添 ~/.claude/mcp.json:

{
  "mcpServers": {
    "agent-consultation": {
      "command": "npx",
      "args": ["-y", "ai-consultation-mcp"]
    }
  }
}

建筑

中央守护进程+WebSocket

MCP服务器使用 中央守护程序架构 为了获得强大的多客户端支持:

┌─────────────────────────────────────────────────────────────────┐
│                      CENTRAL DAEMON                              │
│  ┌─────────────┐  ┌─────────────┐  ┌─────────────────────────┐  │
│  │ SQLite DB   │  │ WebSocket   │  │ HTTP API               │  │
│  │ (WAL mode)  │  │ Server      │  │ /api/*                 │  │
│  │             │  │             │  │                         │  │
│  │ - config    │  │ - sync      │  │ - config CRUD          │  │
│  │ - convos    │  │ - broadcast │  │ - provider CRUD        │  │
│  │ - history   │  │ - rooms     │  │ - chat history         │  │
│  └─────────────┘  └─────────────┘  └─────────────────────────┘  │
└───────────────────────────┬─────────────────────────────────────┘
                            │
            ┌───────────────┼───────────────┐
            │               │               │
            ▼               ▼               ▼
    ┌───────────────┐ ┌───────────────┐ ┌───────────────┐
    │ MCP Proxy     │ │ MCP Proxy     │ │ Web UI        │
    │ (Claude Code) │ │ (Cursor)      │ │ (Browser)     │
    │               │ │               │ │               │
    │ stdio ↔ WS    │ │ stdio ↔ WS    │ │ WS Client     │
    └───────────────┘ └───────────────┘ └───────────────┘

优点:

  • ✅ SQLite+WAL模式下无比赛条件
  • ✅ 所有连接的客户端之间的实时同步
  • ✅ 自动守护进程生命周期管理
  • ✅ 持续对话历史
默认运行时:守护进程/代理架构是默认和推荐的模式。 --legacy 为了兼容性而保留,但已弃用。

配置

设置API密钥

npx ai-consultation-mcp --config

这将打开一个web UI,您可以在其中:

  • 为所有支持的提供程序添加/更新API密钥
  • 测试API密钥有效性
  • 设置默认和回退模型
  • 实时查看对话历史记录
  • 管理RAG文档和内存笔记

支持的提供商

提供程序型号API密钥
开放人工智能gpt-5.2, gpt-5.2-pro获取API密钥
深度求索deepseek-reasoner (默认), deepseek-chat获取API密钥

模型特点

模型提供者上下文最大输出功能
gpt-5.2OpenAI400K400K推理,旗舰级品质
gpt-5.2-proOpenAI400K400K更多计算,更高质量
deepseek聊天deepseek128K8K快速,非常实惠
deepseek推理器deepseek64K64K思维链

用法

配置后,您的AI助手可以使用以下工具:

咨询代理

从另一个AI模型那里获得第二种意见。

Parameters:
- question (required): The question or problem to get advice on
- mode (optional): Consultation mode - debug, analyzeCode, reviewArchitecture, validatePlan, explainConcept, general
- context (optional): Additional context like code snippets or error messages
- docIds (optional): Restrict RAG to these document IDs
- docTitles (optional): Restrict RAG to matching document titles

继续对话

继续现有的咨询对话。

Parameters:
- conversationId (required): The conversation ID from a previous consultation
- message (required): Your follow-up message
- docIds (optional): Restrict RAG to these document IDs
- docTitles (optional): Restrict RAG to matching document titles

end_conversation

结束积极的咨询对话。

Parameters:
- conversationId (required): The conversation ID to end

rag_search

使用可选过滤器搜索RAG文档。

Parameters:
- query (required): Search query
- docIds (optional): Restrict to document IDs
- docTitles (optional): Restrict to document titles
- folder (optional): Restrict to folder
- topK (optional): Number of results (default 4)
- minScore (optional): Minimum similarity score (default 0.35)

rag_list_docs

列出可用的RAG文件。

Parameters:
- folder (optional): Restrict to folder

rag_list_folders

列出可用的RAG文件夹。

rag_list_memories

列出结构化记忆笔记。

rag_get.doc_chunks

获取文档的所有块。

Parameters:
- documentId (required)

rag_add_memory

添加记忆笔记(嵌入并可由RAG搜索)。

Parameters:
- category (required): architecture | backend | db | auth | config | flow | other
- title (required): Short memory title
- content (required): Memory content

rag_upload_files

使用文件路径将本地文件上传到RAG索引。

Parameters:
- paths (required): Array of file paths to upload
- ifExists (optional): skip | allow | replace (default: skip)
- folder (optional): Folder name

示例

{
  "tool": "rag_upload_files",
  "paths": ["Architecture/trendyol-go-api-context7.md", "docs/migros.md"],
  "ifExists": "skip",
  "folder": "food/migros"
}

rag_update_doc_folder

更新文档文件夹。

Parameters:
- documentId (required)
- folder (required)

rag_bulk_update_folders

批量更新文档文件夹。

Parameters:
- mappings (required): [{ documentId, folder }]

示例

在Claude Code中,您可以这样使用它:

“你能就这个架构决策咨询DeepSeek吗?我不确定使用monorepo是否是这种微服务设置的正确选择。”

然后克劳德会打电话给 consult_agent 使用工具回答您的问题并提供答案。

咨询方式

模式描述
debug专注于发现错误、分析错误并提出修复建议
analyzeCode代码审查侧重于质量、模式和改进
reviewArchitecture评估架构决策并提出替代方案
validatePlan审查实施计划的完整性和风险
explainConcept清楚地解释技术概念
general通用咨询

RAG/内存

MCP服务器包括一个用于上下文咨询的本地RAG(检索增强生成)管道。 文件夹(命名空间)可用于限定文档的范围。一个常见的流程是:

  1. rag_list_folders
  2. rag_list_docs 随着 folder
  3. rag_search 随着 folder 和/或特定 docIds

启动本地嵌入服务器

python3 -m venv .venv
source .venv/bin/activate
pip install -r scripts/embedding_server_requirements.txt
python scripts/embedding_server.py

服务器正在监听 http://127.0.0.1:7999/embed 默认情况下。您可以用以下命令覆盖 RAG_EMBED_URL.

添加记忆笔记

{
  "tool": "rag_add_memory",
  "category": "auth",
  "title": "Login flow",
  "content": "POST /auth/login -> validate -> issue JWT -> response Authorization header"
}

Web UI RAG功能

  • 上传多个文档(txt、md、pdf、docx)
  • 选择文档以确定搜索范围
  • 带有顶级K/minScore控件的RAG测试
  • 实时文档管理

发展

# Clone the repo
git clone https://github.com/menesekinci/ai-consultation-mcp.git
cd ai-consultation-mcp

# Install dependencies
npm install

# Run in development mode
npm run dev

# Run daemon in development mode
npm run dev:daemon

# Build for production
npm run build

# Run tests
npm test

安全

  • API密钥加密:所有API密钥在静止时使用AES-256-GCM加密
  • 仅限本地:Web UI只能在本地主机上访问
  • 无日志:从未记录API密钥
  • SQLite WAL模式:符合ACID标准的数据库操作可防止数据损坏

许可证

麻省理工学院

目录标签

目录标签

AI代理TypeScriptClaude本地部署模型咨询多模型协作实时同步RAG

支持客户端

ClaudeCursorWindsurfCline

接入字段

传输方式(transport,传输协议)

stdio

鉴权方式(authType,认证方式)

api-key

运行时(runtime,运行环境)

Node.js

来源包(packageName,安装包名)

ai-consultation-mcp

工具数量(toolCount,工具数)

12

资源数量(resourceCount,资源数)

0

提示词数量(promptCount,提示词数)

0

权限和风险

stdioapi-key部署方式未说明

接入前请确认传输方式、认证方式和部署位置,并根据实际工具能力限制访问范围。

安装前确认

不要直接授予不必要的文件、网络或账号权限;先核对安装命令和配置内容。

来源信息

继续浏览同类 MCP