导师mcp服务器
  ](<>)   ](https://github.com/cyanheads/mentor-mcp-server)
模型上下文协议服务器通过AI驱动的Deepseek-Reasoning(R1)指导能力为LLM代理提供第二意见,包括通过Deepseek API进行代码审查、设计评论、写作反馈和创意集思广益。通过专家的第二意见和可操作的见解,为您的法学硕士代理的成功做好准备。
模型上下文协议
模型上下文协议(MCP)实现了以下之间的通信:
- 客户:Claude Desktop、IDE和其他MCP兼容客户端
- 服务器:用于任务管理和自动化的工具和资源
- LLM代理:利用服务器功能的AI模型
目录
特性
代码分析
- 全面的代码审查
- 漏洞检测和预防
- 风格和最佳实践评估
- 性能优化建议
- 安全漏洞评估
设计与建筑
- UI/UX设计评论
- 架构图分析
- 设计模式建议
- 可访问性评估
- 一致性检查
内容增强
- 撰写反馈和改进
- 语法和风格分析
- 文件审查
- 内容清晰度评估
- 结构建议
战略规划
- 功能增强头脑风暴
- 关于方法的第二意见
- 创新建议
- 可行性分析
- 用户价值评估
安装
# Clone the repository
git clone git@github.com:cyanheads/mentor-mcp-server.git
cd mentor-mcp-server
# Install dependencies
npm install
# Build the project
npm run build配置
添加到MCP客户端设置中:
{
"mcpServers": {
"mentor": {
"command": "node",
"args": ["build/index.js"],
"env": {
"DEEPSEEK_API_KEY": "your_api_key",
"DEEPSEEK_MODEL": "deepseek-reasoner",
"DEEPSEEK_MAX_TOKENS": "8192",
"DEEPSEEK_MAX_RETRIES": "3",
"DEEPSEEK_TIMEOUT": "30000"
}
}
}
}环境变量
| 变量 | 必填 | 默认 | 描述 |
|---|---|---|---|
| DEEPSEK_API_KEY | 是 | - | 您的Deepsseek API密钥 |
| DEEPSEK_MODEL | 是 | 深度搜索推理器 | 深度搜索模型名称 |
| DEEPSEK_MAX_TOKENS | 否 | 8192 | 每个请求的最大令牌数 |
| DEEPSEK_MAX_RETRIES | 否 | 3 | 重试尝试次数 |
| DEEPSEK_TIMEOUT | 否 | 30000 | 请求超时(毫秒) |
工具
代码审查
mentor-mcp-server
code_review
{
"file_path": "src/app.ts",
"language": "typescript"
}
设计评论
mentor-mcp-server
design_critique
{
"design_document": "path/to/design.fig",
"design_type": "web UI"
}
撰写反馈
mentor-mcp-server
writing_feedback
{
"text": "Documentation content...",
"writing_type": "documentation"
}
功能增强
mentor-mcp-server
brainstorm_enhancements
{
"concept": "User authentication system"
}
例子
每个工具的使用和输出的详细示例可以在 示例 目录:
- 第二意见示例 -身份验证系统需求分析
- 代码审查示例 -详细的TypeScript代码审查,包括安全性和性能见解
- 设计评论示例 -仪表板设计的全面UI/UX反馈
- 撰写反馈示例 -文件改进建议
- 头脑风暴增强示例 -具有实现细节的功能构思
每个示例都包括请求格式和示例响应,展示了该工具的功能和输出结构。
发展
# Build TypeScript code
npm run build
# Start the server
npm run start
# Development with watch mode
npm run dev
# Clean build artifacts
npm run clean项目结构
src/
├── api/ # API integration modules
├── tools/ # Tool implementations
│ ├── second-opinion/
│ ├── code-review/
│ ├── design-critique/
│ ├── writing-feedback/
│ └── brainstorm-enhancements/
├── types/ # TypeScript type definitions
├── utils/ # Utility functions
├── config.ts # Server configuration
├── index.ts # Entry point
└── server.ts # Main server implementation许可证
Apache许可证2.0。看 许可证 了解更多信息。
______________________________________________________________________
Built with the Model Context Protocol

