RISEN Prompt工程MCP工具
一个强大的模型上下文协议(MCP)服务器,可帮助您使用RISEN框架创建、验证、管理和优化提示。
什么是RISEN?
RISEN是一个结构化的快速工程框架,由5个部分组成:
- Role:定义人工智能的角色/专业知识
- 一、指令:任务的明确指令
- S步骤:流程分解
- E期望:期望的结果/形式
- Narrowing:约束或创意元素
特性
🎯 核心功能
- 模板管理:创建、存储和组织RISEN提示模板
- 可变支持:使用
{{variables}}用于动态、可重用的提示 - 验证引擎:实时结构检查和质量评分
- 性能跟踪:通过评级和分析监控即时有效性
- AI建议:根据最佳实践获得改进建议
🚀 高级功能
- A/B测试:比较不同的提示变化
- 跨AI集成:与您的跨AI工具配合使用,在多个模型上测试提示
- 知识库集成:保存成功的提示以供将来参考
- 自然语言转换:将常规请求转换为RISEN格式
- 模板库:常见任务的预构建模板
安装
- 克隆存储库:
git clone https://github.com/YOUR_USERNAME/mcp-risen-prompts.git
cd mcp-risen-prompts- 安装依赖项:
npm install- 测试服务器:
npm test- 服务器现在已准备好在Claude Desktop中配置
配置
添加到您的Claude Desktop配置中:
macOS
~/Library/Application Support/Claude/claude_desktop_config.json
视窗
%APPDATA%\Claude\claude_desktop_config.json
{
"mcpServers": {
"risen-prompts": {
"command": "node",
"args": ["/path/to/mcp-risen-prompts/server.js"]
}
}
}使用示例
创建模板
Use risen_create to make a new template:
- Name: "Code Review"
- Role: "Senior software engineer with 15+ years experience"
- Instructions: "Review the provided code for quality and security"
- Steps: ["Analyze structure", "Check for bugs", "Suggest improvements"]
- Expectations: "Detailed line-by-line feedback with examples"
- Narrowing: "Focus on critical issues first"执行模板
Use risen_execute with variables:
- Template ID: [your-template-id]
- Variables: {"language": "Python", "framework": "Django"}跟踪性能
After using a prompt, track its effectiveness:
- Use risen_track
- Rate 1-5 stars
- Add notes about what worked/didn't workMCP工具可用
- risen_create -创建新的RISEN模板
- risen_validate -检查结构并获得建议
- risen_execute -运行带有变量的模板
- risen_track -记录绩效指标
- risen_search -按标签/评级查找模板
- 上升分析 -深入了解模板性能
- risen_建议 -基于人工智能的改进建议
- risen_convert -将自然语言转换为RISEN
模板示例
博客文章作者
Role: Content strategist and SEO expert
Instructions: Write an engaging blog post about {{topic}}
Steps:
1. Research keywords and trends
2. Create compelling headline
3. Develop main points with examples
4. Include statistics and sources
5. Write conclusion with CTA
Expectations: 1500-2000 words, SEO-optimized, engaging tone
Narrowing: Use conversational tone, include 3-5 keywords naturally数据分析
Role: Data scientist specializing in {{domain}}
Instructions: Analyze {{dataset}} to uncover insights
Steps:
1. Perform exploratory data analysis
2. Identify key trends and patterns
3. Run statistical tests
4. Create visualizations
5. Provide recommendations
Expectations: Clear insights with statistical backing
Narrowing: Focus on {{specific_metrics}} and business impact质量评分
模板根据以下因素评分(满分100分):
- 角色特异性(20分)
- 指令清晰度(20分)
- 步骤细节(20分)
- 期望指标(20分)
- 聚焦范围缩小(20分)
最佳实践
- 具体:“助理”等模糊角色的得分低于“具有AWS专业知识的高级Python开发人员”
- 使用变量:使模板可重复使用
{{variables}} - 可衡量的期望:包括数字(字数、所需示例等)
- 明确步骤:每个步骤都应该是可操作的和具体的
- 测试和迭代:使用跟踪功能随时间改进模板
与其他MCP工具集成
使用跨AI工具
在多个AI模型中执行相同的RISEN提示:
- 创建/选择RISEN模板
- 使用Cross-AI在ChatGPT、Gemini和Claude上运行它
- 比较结果并跟踪哪种模型表现最佳
有知识库
保存成功的提示以供将来参考:
- 创建并测试RISEN提示
- 一旦证明有效,保存到知识库
- 按主题搜索和检索经过验证的提示
故障排除
模板未验证?
- 确保所有必填字段都已填写
- 检查步骤是否为数组,而不是字符串
- 验证变量是否正确声明
变量不替换?
- 使用精确的语法:
{{variable_name}} - 确保变量名在声明和使用中匹配
- 检查执行时所有变量是否都有值
低质量分数?
- 为每个组件添加更多细节
- 在预期中纳入具体指标
- 在角色中使用特定领域的语言
未来路线图
- \[\]可视化模板生成器UI
- \[\]社区模板市场
- \[\]高级分析仪表板
- \[\]提示链接工作流
- \[\]导出/导入模板包
- \[\]团队协作功能
贡献
发现错误或有功能请求?请随时贡献!
许可证
MIT许可证-可根据需要自由使用和修改。
