阻止AI对实现内容撒谎! 跟踪AI声称的内容与实际执行的内容。
✨ 超精简响应 - 输出减少90% 🔄 组合工具 - 单一调用代替两个独立工具 ⚡ 无缝工作流 - 非常适合AI配对编程 🎯 Cursor MCP 兼容 - 与Cursor IDE无缝集成
是否曾遇到过AI说“我已经给你的函数添加了错误处理”但实际上并没有?或者声称“实现了用户认证”但只是加了一条评论?
SlopWatch 实时捕捉AI的谎言。
Smithery 自动处理托管、认证和更新
对于Cursor IDE:
{
"mcpServers": {
"slopwatch": {
"command": "npx",
"args": ["slopwatch-mcp-server"]
}
}
}
手动Cursor设置:
Cmd+Shift+J,Windows上使用Ctrl+Shift+J)npx slopwatch-mcp-server对于Claude桌面版:
在你的claude_desktop_config.json中添加:
{
"mcpServers": {
"slopwatch": {
"command": "npx",
"args": ["slopwatch-mcp-server"]
}
}
}
全局NPM安装:
npm install -g slopwatch-mcp-server
适用于AI实现某项功能并验证:
// AI实现代码,然后在一个调用中验证:
slopwatch_claim_and_verify({
claim: "为calculateSum函数添加输入验证",
originalFileContents: {
"utils/math.js": "function calculateSum(a, b) { return a + b; }"
},
updatedFileContents: {
"utils/math.js": "function calculateSum(a, b) {\n if (typeof a !== 'number' || typeof b !== 'number') {\n throw new Error('无效输入');\n }\n return a + b;\n}"
}
});
// 响应:"✅ 通过 (87%)"
当你希望先声明再实施时:
// 第一步:注册声明
slopwatch_claim({
claim: "为用户登录添加错误处理",
fileContents: {
"auth.js": "function login(user) { return authenticate(user); }"
}
});
// 响应:"声明ID:abc123"
// 第二步:实施后验证
slopwatch_verify({
claimId: "abc123",
updatedFileContents: {
"auth.js": "function login(user) {\n try {\n return authenticate(user);\n } catch (error) {\n throw new Error('登录失败');\n }\n}"
}
});
// 响应:"✅ 通过 (92%)"
| 工具 | 描述 | 响应 |
|---|---|---|
slopwatch_claim_and_verify | ⭐ 推荐 - 在一个调用中声明和验证 | ✅ 通过 (87%) |
slopwatch_status | 获取责任统计信息 | 准确率:95% (19/20) |
slopwatch_setup_rules | 生成.cursorrules以自动执行 | 最小规则内容 |
SlopWatch专门设计用于Cursor IDE和AI配对编程:
1. AI:“我将在你的函数中添加错误处理”
2. SlopWatch:自动跟踪声明
3. AI:实现代码
4. SlopWatch:验证实现是否符合声明
5. 结果:✅ 通过 (92%) 或 ❌ 失败 (23%)
// AI说:“我将在你的API端点添加速率限制”
slopwatch_claim_and_verify({
claim: "在/api/users端点添加速率限制中间件",
originalFileContents: {
"routes/users.js": "app.get('/api/users', (req, res) => { ... })"
},
updatedFileContents: {
"routes/users.js": "const rateLimit = require('express-rate-limit');\nconst limiter = rateLimit({ windowMs: 15*60*1000, max: 100 });\napp.get('/api/users', limiter, (req, res) => { ... })"
}
});
// 结果:✅ 通过 (94%)
// AI声称:“使用CSS Grid增加了响应式设计”
slopwatch_claim_and_verify({
claim: "使用CSS Grid使UserCard组件具有响应性",
originalFileContents: {
"components/UserCard.jsx": "const UserCard = () => <div className=\"user-card\">...</div>"
},
updatedFileContents: {
"components/UserCard.jsx": "const UserCard = () => <div className=\"user-card grid-responsive\">...</div>",
"styles/UserCard.css": ".grid-responsive { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 1rem; }"
}
});
// 结果:✅ 通过 (89%)
跟踪AI的诚实度随时间的变化:
slopwatch_status();
// 返回:"准确率:95% (19/20)"
生成自动问责规则:
slopwatch_setup_rules();
这会创建一个.cursorrules文件,自动执行SlopWatch验证所有AI实现。
SlopWatch分析:
npm cache clean --force并重新安装通过在环境中设置DEBUG=true启用详细日志记录。
我们欢迎贡献!请参阅我们的贡献指南了解详情。
MIT 许可证 - 详情请参阅LICENSE
由❤️为Cursor社区制作
停止AI对实现内容撒谎。今天就开始使用SlopWatch!