@vibecheckai/cli 3.9.1 → 4.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (86) hide show
  1. package/README.md +1 -1
  2. package/bin/runners/context/generators/cursor-enhanced.js +99 -13
  3. package/mcp-server/.eslintrc.json +24 -0
  4. package/mcp-server/README.md +425 -135
  5. package/mcp-server/SPEC.md +583 -0
  6. package/mcp-server/configs/README.md +172 -0
  7. package/mcp-server/configs/claude-desktop-pro.json +31 -0
  8. package/mcp-server/configs/claude-desktop-with-workspace.json +25 -0
  9. package/mcp-server/configs/claude-desktop.json +19 -0
  10. package/mcp-server/configs/cursor-mcp.json +21 -0
  11. package/mcp-server/configs/windsurf-mcp.json +17 -0
  12. package/mcp-server/mcp-config.example.json +9 -0
  13. package/mcp-server/package-lock.json +1631 -0
  14. package/mcp-server/package.json +49 -34
  15. package/mcp-server/src/cli.ts +185 -0
  16. package/mcp-server/src/index.ts +85 -0
  17. package/mcp-server/src/server.ts +1933 -0
  18. package/mcp-server/src/services/cache-service.ts +466 -0
  19. package/mcp-server/src/services/cli-service.ts +345 -0
  20. package/mcp-server/src/services/context-manager.ts +717 -0
  21. package/mcp-server/src/services/firewall-service.ts +662 -0
  22. package/mcp-server/src/services/git-service.ts +671 -0
  23. package/mcp-server/src/services/index.ts +52 -0
  24. package/mcp-server/src/services/prompt-builder-service.ts +1031 -0
  25. package/mcp-server/src/services/session-service.ts +550 -0
  26. package/mcp-server/src/services/tier-service.ts +470 -0
  27. package/mcp-server/src/types.ts +351 -0
  28. package/mcp-server/tsconfig.json +16 -27
  29. package/package.json +6 -6
  30. package/mcp-server/.guardrail/audit/audit.log.jsonl +0 -2
  31. package/mcp-server/.specs/architecture.mdc +0 -90
  32. package/mcp-server/.specs/security.mdc +0 -30
  33. package/mcp-server/HARDENING_SUMMARY.md +0 -299
  34. package/mcp-server/agent-checkpoint.js +0 -364
  35. package/mcp-server/agent-firewall-interceptor.js +0 -500
  36. package/mcp-server/architect-tools.js +0 -707
  37. package/mcp-server/audit-mcp.js +0 -206
  38. package/mcp-server/authority-tools.js +0 -569
  39. package/mcp-server/codebase-architect-tools.js +0 -838
  40. package/mcp-server/conductor/conflict-resolver.js +0 -588
  41. package/mcp-server/conductor/execution-planner.js +0 -544
  42. package/mcp-server/conductor/index.js +0 -377
  43. package/mcp-server/conductor/lock-manager.js +0 -615
  44. package/mcp-server/conductor/request-queue.js +0 -550
  45. package/mcp-server/conductor/session-manager.js +0 -500
  46. package/mcp-server/conductor/tools.js +0 -510
  47. package/mcp-server/consolidated-tools.js +0 -1170
  48. package/mcp-server/deprecation-middleware.js +0 -282
  49. package/mcp-server/handlers/index.ts +0 -15
  50. package/mcp-server/handlers/tool-handler.ts +0 -593
  51. package/mcp-server/hygiene-tools.js +0 -428
  52. package/mcp-server/index-v1.js +0 -698
  53. package/mcp-server/index.js +0 -2940
  54. package/mcp-server/intelligence-tools.js +0 -664
  55. package/mcp-server/intent-drift-tools.js +0 -873
  56. package/mcp-server/intent-firewall-interceptor.js +0 -529
  57. package/mcp-server/lib/api-client.cjs +0 -13
  58. package/mcp-server/lib/cache-wrapper.cjs +0 -383
  59. package/mcp-server/lib/error-envelope.js +0 -138
  60. package/mcp-server/lib/executor.ts +0 -499
  61. package/mcp-server/lib/index.ts +0 -29
  62. package/mcp-server/lib/logger.cjs +0 -30
  63. package/mcp-server/lib/rate-limiter.js +0 -166
  64. package/mcp-server/lib/sandbox.test.ts +0 -519
  65. package/mcp-server/lib/sandbox.ts +0 -395
  66. package/mcp-server/lib/types.ts +0 -267
  67. package/mcp-server/logger.js +0 -173
  68. package/mcp-server/manifest.json +0 -473
  69. package/mcp-server/mdc-generator.js +0 -298
  70. package/mcp-server/premium-tools.js +0 -1275
  71. package/mcp-server/proof-tools.js +0 -571
  72. package/mcp-server/registry/tool-registry.js +0 -586
  73. package/mcp-server/registry/tools.json +0 -619
  74. package/mcp-server/registry.test.ts +0 -340
  75. package/mcp-server/test-mcp.js +0 -108
  76. package/mcp-server/test-tools.js +0 -36
  77. package/mcp-server/tests/tier-gating.test.js +0 -297
  78. package/mcp-server/tier-auth.js +0 -767
  79. package/mcp-server/tools/index.js +0 -72
  80. package/mcp-server/tools-reorganized.ts +0 -244
  81. package/mcp-server/tools-v3.js +0 -1004
  82. package/mcp-server/truth-context.js +0 -622
  83. package/mcp-server/truth-firewall-tools.js +0 -2183
  84. package/mcp-server/vibecheck-2.0-tools.js +0 -761
  85. package/mcp-server/vibecheck-mcp-server-3.2.0.tgz +0 -0
  86. package/mcp-server/vibecheck-tools.js +0 -1075
@@ -1,211 +1,501 @@
1
- # vibecheck MCP Server v4.0
1
+ # VibeCheck MCP Standard
2
2
 
3
- Professional Model Context Protocol server for vibecheck AI.
3
+ <p align="center">
4
+ <strong>The Official Model Context Protocol Implementation for AI Agent Security</strong>
5
+ </p>
4
6
 
5
- > "Stop shipping pretend features."
7
+ <p align="center">
8
+ <a href="https://npmjs.com/package/@vibecheck/mcp-standard"><img src="https://img.shields.io/npm/v/@vibecheck/mcp-standard?style=flat-square" alt="npm version"></a>
9
+ <a href="https://npmjs.com/package/@vibecheck/mcp-standard"><img src="https://img.shields.io/npm/dm/@vibecheck/mcp-standard?style=flat-square" alt="npm downloads"></a>
10
+ <a href="https://github.com/guardiavault-oss/VIBEYCHECK/blob/main/mcp-server/SPEC.md"><img src="https://img.shields.io/badge/MCP-Standard%20v1.0-blue?style=flat-square" alt="MCP Standard"></a>
11
+ </p>
6
12
 
7
- ## Installation
13
+ <p align="center">
14
+ <a href="#installation">Installation</a> •
15
+ <a href="./SPEC.md">Protocol Specification</a> •
16
+ <a href="#integrations">Integrations</a> •
17
+ <a href="#available-tools">Tools</a>
18
+ </p>
8
19
 
9
- ```bash
10
- npm install -g @vibecheckai/cli
11
- ```
20
+ ---
12
21
 
13
- ## Configuration
22
+ ## What is MCP Standard?
14
23
 
15
- Add to your AI IDE's MCP configuration:
24
+ **VibeCheck MCP Standard** is the official, production-ready implementation of the Model Context Protocol for AI agent security. It provides:
16
25
 
17
- ```json
18
- {
19
- "mcpServers": {
20
- "vibecheck": {
21
- "command": "npx",
22
- "args": ["@vibecheckai/cli", "mcp"]
23
- }
24
- }
25
- }
26
- ```
27
-
28
- See [MCP-QUICK-START.md](../docs/MCP-QUICK-START.md) for editor-specific setup.
26
+ - **Intent-Based Security**: Agents declare intent before making changes
27
+ - **Hallucination Detection**: Catch fake APIs, phantom methods, and invented routes
28
+ - **Claim Verification**: Verify what AI agents claim they did
29
+ - **Firewall Enforcement**: Block unauthorized actions in real-time
29
30
 
30
- ## Development
31
+ ### Integrations
31
32
 
32
- ```bash
33
- cd mcp-server
34
- npm install
35
- npm start
36
- ```
33
+ | Platform | Package | Status |
34
+ |----------|---------|--------|
35
+ | **GitHub Actions** | `vibecheck/vibecheck-action` | Production |
36
+ | **CI Pipelines** | `@vibecheck/ci-sdk` | Production |
37
+ | **Cursor IDE** | Native MCP | Production |
38
+ | **Claude Desktop** | Native MCP | Production |
39
+ | **Windsurf** | Native MCP | Production |
37
40
 
38
41
  ---
39
42
 
40
- ## Core MCP Tools (v4.0)
43
+ ## Why VibeCheck MCP Standard Exists
41
44
 
42
- These are the primary tools available via MCP:
45
+ **LLMs hallucinate tools, APIs, routes, and success states.**
43
46
 
44
- | Tool | Description |
45
- |------|-------------|
46
- | `vibecheck_audit` | 🔍 Static analysis - routes, secrets, contracts |
47
- | `vibecheck_ship` | 🚀 Verdict engine - SHIP / WARN / BLOCK |
48
- | `vibecheck_prove` | 🔬 Full proof loop: audit → reality → ship |
49
- | `vibecheck_fix` | 🛠️ Mission-based auto-fix with safety gates |
50
- | `vibecheck_reality` | 🧪 Browser-based runtime verification |
51
- | `vibecheck_forge` | 📝 Generate AI IDE rules (.cursorrules, .windsurf) |
52
- | `vibecheck_shield` | 🛡️ Agent Firewall controls |
53
- | `vibecheck_doctor` | 🏥 Environment health check |
54
- | `vibecheck_checkpoint` | 📍 Snapshot & restore, baseline comparison |
55
- | `vibecheck_polish` | ✨ Production polish - final cleanup |
47
+ Traditional linters run *after* the damage is done. By the time you catch a fake API call or phantom library method, the code is already committed.
56
48
 
57
- ---
49
+ **VibeCheck MCP intercepts AI actions BEFORE execution** and requires proof before allowing writes, commits, or tool calls.
50
+
51
+ ```
52
+ ┌─────────────────────────────────────────────────────────────────┐
53
+ │ THE HALLUCINATION PROBLEM │
54
+ ├─────────────────────────────────────────────────────────────────┤
55
+ │ │
56
+ │ AI Agent: "I'll call the /api/v2/users endpoint" │
57
+ │ │
58
+ │ Reality: That endpoint doesn't exist. │
59
+ │ The AI made it up. │
60
+ │ It will fail at runtime. │
61
+ │ │
62
+ │ Traditional Tools: ✗ Catch this AFTER code is written │
63
+ │ VibeCheck MCP: ✓ Block this BEFORE code is written │
64
+ │ │
65
+ └─────────────────────────────────────────────────────────────────┘
66
+ ```
58
67
 
59
- ## Shield (Agent Firewall) Tools
68
+ ---
60
69
 
61
- Control the Agent Firewall via MCP:
70
+ ## Architecture
62
71
 
63
- | Tool | Description |
64
- |------|-------------|
65
- | `vibecheck_shield_status` | Get firewall status |
66
- | `vibecheck_shield_enforce` | Enable enforcement mode |
67
- | `vibecheck_shield_observe` | Enable observe-only mode |
68
- | `vibecheck_shield_lock` | Hard lockdown (all rules enforced) |
69
- | `vibecheck_shield_unlock` | Release lock |
70
- | `vibecheck_shield_verify` | Verify claims/prompts |
72
+ ```
73
+ ┌──────────────────────────────────────────────────────────────────┐
74
+ │ AI IDE / Agent │
75
+ │ (Cursor, Claude, Windsurf, etc.) │
76
+ └────────────────────────────┬─────────────────────────────────────┘
77
+ MCP Protocol
78
+
79
+ ┌──────────────────────────────────────────────────────────────────┐
80
+ │ VibeCheck MCP Server │
81
+ │ ┌────────────────┐ ┌────────────────┐ ┌────────────────┐ │
82
+ │ │ Agent Firewall │ │ Proof Engine │ │ Context Manager│ │
83
+ │ │ (Intent-based │ │ (Reality Mode │ │ (Smart file │ │
84
+ │ │ gating) │ │ + Audit) │ │ selection) │ │
85
+ │ └───────┬────────┘ └───────┬────────┘ └───────┬────────┘ │
86
+ │ │ │ │ │
87
+ │ ▼ ▼ ▼ │
88
+ │ ┌─────────────────────────────────────────────────────────────┐│
89
+ │ │ VibeCheck CLI Engine ││
90
+ │ │ audit · ship · prove · fix · reality · forge · checkpoint ││
91
+ │ └─────────────────────────────────────────────────────────────┘│
92
+ └──────────────────────────────────────────────────────────────────┘
93
+
94
+
95
+ ┌──────────────────────────────────────────────────────────────────┐
96
+ │ Your Codebase │
97
+ │ (Protected by intent verification & proof gates) │
98
+ └──────────────────────────────────────────────────────────────────┘
99
+ ```
71
100
 
72
101
  ---
73
102
 
74
- ## Intent & Approval Tools
75
-
76
- For declaring AI intent and approving changes:
103
+ ## Used in Production
77
104
 
78
- | Tool | Description |
79
- |------|-------------|
80
- | `vibecheck_intent_start` | 🎯 Declare intent before making changes |
81
- | `vibecheck_intent_check` | Check if changes align with stated intent |
82
- | `vibecheck_intent_complete` | ✅ Complete step and generate proof artifact |
83
- | `vibecheck_approve` | 👍 Review and approve session changes |
105
+ - **Cursor IDE** - Deep MCP integration with Agent Firewall
106
+ - **Claude Desktop** - Intent-based code generation workflows
107
+ - **Windsurf** - Real-time hallucination detection
108
+ - **CI/CD Pipelines** - Automated proof generation and blocking
84
109
 
85
110
  ---
86
111
 
87
- ## Checkpoint Tools
112
+ ## Tier Model v4.0
113
+
114
+ | Tier | Price | Commands | Focus |
115
+ |------|-------|----------|-------|
116
+ | **FREE** | $0/mo | 11 | Inspect & Observe |
117
+ | **PRO** | $49/mo | 12 | Fix, Prove & Enforce |
118
+
119
+ ### FREE Tier ($0/mo)
120
+ - 100 scans/month
121
+ - 1,000 files/scan max
122
+ - Report formats: HTML, MD, JSON
123
+ - Agent Firewall: **observe mode only**
124
+
125
+ ### PRO Tier ($49/mo)
126
+ - Unlimited scans
127
+ - Unlimited files
128
+ - All report formats: HTML, MD, JSON, SARIF, CSV, PDF
129
+ - Agent Firewall: **enforce mode**
130
+ - Full MCP server access
131
+
132
+ ## World-Class Features
133
+
134
+ ### Session Management
135
+ Complete agent session tracking with:
136
+ - **Trust Scoring**: Dynamic trust score based on behavior (0-100)
137
+ - **Metrics Tracking**: Success rates, latency, call counts by category
138
+ - **Health Monitoring**: Automatic issue detection and reporting
139
+ - **Audit Trail**: Complete history of all tool calls and state changes
140
+
141
+ ### Git Integration
142
+ Deep git integration for code change analysis:
143
+ - **Status Tracking**: Staged, unstaged, untracked files with ahead/behind counts
144
+ - **Diff Analysis**: Risk assessment for changes with pattern detection
145
+ - **Intent Verification**: Check if changes match declared intent (PRO)
146
+ - **Snapshot Creation**: Quick stash for saving work (PRO)
147
+ - **File History**: Track changes to specific files
148
+
149
+ ### Context Management
150
+ Intelligent context handling for large codebases:
151
+ - **Project Analysis**: Framework, language, structure detection
152
+ - **Smart Context Windows**: Relevance-scored file selection for queries
153
+ - **Import Tracing**: Find related files based on dependencies
154
+ - **File Categorization**: Automatic categorization (api, component, config, etc.)
155
+
156
+ ### Performance & Caching
157
+ Built for speed with:
158
+ - **LRU Caching**: Intelligent caching with TTL and eviction
159
+ - **Disk Persistence**: Optional disk cache for expensive operations
160
+ - **Batch Operations**: Efficient handling of multiple files
161
+
162
+ ### Agent Firewall
163
+ Control AI agent actions with intent-based security:
164
+ - **Intent-First Approach**: Set intent before AI writes code
165
+ - **Three Modes**: `off`, `observe`, `enforce`
166
+ - **Claim Verification**: Verify AI claims against codebase state
167
+ - **Action Gating**: Block sensitive operations without proper intent
168
+
169
+ ### Prompt Builder
170
+ Intelligent prompt templates for production-ready code:
171
+ - **50+ Templates**: Authentication, API, database, frontend, testing, etc.
172
+ - **Auto-Detection**: Detects best template from user input
173
+ - **Workspace Context**: Automatically detects framework, database, styling
174
+ - **Quality Analysis**: Scores prompts for completeness, specificity, clarity
175
+
176
+ ### CLI Integration
177
+ Full access to VibeCheck CLI commands:
178
+ - `audit` - Security audit
179
+ - `ship` - Deploy readiness
180
+ - `forge` - Generate AI rules
181
+ - `fix` - Auto-fix findings
182
+ - `checkpoint` - Code snapshots
183
+ - `packs` - Report bundles
184
+ - `reality` - Browser testing
88
185
 
89
- Pre-write validation and time machine:
186
+ ## Installation
90
187
 
91
- | Tool | Description |
92
- |------|-------------|
93
- | `vibecheck_checkpoint` | 🛡️ Validate code before writing - blocks on issues |
94
- | `vibecheck_checkpoint_status` | 📊 Get current checkpoint status |
95
- | `vibecheck_checkpoint_restore` | ⏪ Restore to a previous checkpoint |
96
- | `vibecheck_checkpoint_compare` | 📈 Compare baseline vs current |
188
+ ```bash
189
+ npm install @vibecheck/mcp-standard
190
+ ```
97
191
 
98
- ---
192
+ Or run directly with npx:
99
193
 
100
- ## Report & Artifact Tools
194
+ ```bash
195
+ npx @vibecheck/mcp-standard
196
+ ```
101
197
 
102
- Generate outputs and evidence:
198
+ ### Quick Start for CI/CD
103
199
 
104
- | Tool | Description |
105
- |------|-------------|
106
- | `vibecheck_packs_evidence` | 📦 Bundle videos, traces, screenshots |
107
- | `vibecheck_packs_report` | 📄 Generate HTML/MD/SARIF reports |
108
- | `vibecheck_packs_graph` | 📊 Proof graph visualization |
109
- | `vibecheck_seal` | 🏆 Generate ship badge and attestation |
200
+ ```bash
201
+ # GitHub Actions - use the official action
202
+ - uses: vibecheck/vibecheck-action@v1
203
+ with:
204
+ api-key: ${{ secrets.VIBECHECK_API_KEY }}
110
205
 
111
- ---
206
+ # Or use the CI SDK
207
+ npm install @vibecheck/ci-sdk
208
+ ```
209
+
210
+ ## Configuration
112
211
 
113
- ## Example Usage
212
+ ### Cursor IDE
114
213
 
115
- ### Run Analysis
214
+ Add to your `.cursor/mcp.json`:
116
215
 
117
216
  ```json
118
217
  {
119
- "tool": "vibecheck_audit",
120
- "arguments": {
121
- "path": ".",
122
- "profile": "full"
218
+ "mcpServers": {
219
+ "vibecheck": {
220
+ "command": "npx",
221
+ "args": ["@vibecheck/mcp-standard"],
222
+ "env": {}
223
+ }
123
224
  }
124
225
  }
125
226
  ```
126
227
 
127
- ### Get Ship Verdict
228
+ ### Claude Desktop
229
+
230
+ Add to your Claude Desktop config (`~/Library/Application Support/Claude/claude_desktop_config.json` on macOS):
128
231
 
129
232
  ```json
130
233
  {
131
- "tool": "vibecheck_ship",
132
- "arguments": {
133
- "path": "."
234
+ "mcpServers": {
235
+ "vibecheck": {
236
+ "command": "npx",
237
+ "args": ["@vibecheck/mcp-standard"],
238
+ "env": {}
239
+ }
134
240
  }
135
241
  }
136
242
  ```
137
243
 
138
- ### Full Proof Loop
244
+ ### With Workspace Path
139
245
 
140
246
  ```json
141
247
  {
142
- "tool": "vibecheck_prove",
143
- "arguments": {
144
- "url": "http://localhost:3000",
145
- "maxFixRounds": 3
248
+ "mcpServers": {
249
+ "vibecheck": {
250
+ "command": "npx",
251
+ "args": ["@vibecheck/mcp-standard", "--workspace", "/path/to/project"],
252
+ "env": {}
253
+ }
146
254
  }
147
255
  }
148
256
  ```
149
257
 
150
- ### Runtime Verification
258
+ ### With Firewall Mode
151
259
 
152
260
  ```json
153
261
  {
154
- "tool": "vibecheck_reality",
155
- "arguments": {
156
- "url": "http://localhost:3000",
157
- "headed": false,
158
- "maxPages": 18,
159
- "maxDepth": 2
262
+ "mcpServers": {
263
+ "vibecheck": {
264
+ "command": "npx",
265
+ "args": ["@vibecheck/mcp-standard", "--firewall-mode", "observe"],
266
+ "env": {}
267
+ }
160
268
  }
161
269
  }
162
270
  ```
163
271
 
164
- ### AI-Powered Fixes
272
+ ## Available Tools
273
+
274
+ ### FREE CLI Tools (11)
275
+
276
+ | Tool | Description | Tier |
277
+ |------|-------------|------|
278
+ | `vibecheck_doctor` | Health check on project setup | FREE |
279
+ | `vibecheck_audit` | Comprehensive security audit | FREE |
280
+ | `vibecheck_forge` | Generate AI rules (.cursorrules, etc.) | FREE |
281
+ | `vibecheck_packs` | Generate report bundles (HTML, MD, JSON) | FREE |
282
+ | `vibecheck_tier` | Get subscription tier and usage info | FREE |
283
+
284
+ ### PRO CLI Tools (12)
285
+
286
+ | Tool | Description | Tier |
287
+ |------|-------------|------|
288
+ | `vibecheck_ship` | Get ship verdict (SHIP/WARN/BLOCK) | 🔒 PRO |
289
+ | `vibecheck_fix` | Plan or apply security fixes | 🔒 PRO |
290
+ | `vibecheck_checkpoint` | Create/restore code snapshots | 🔒 PRO |
291
+ | `vibecheck_reality` | Browser-based testing | 🔒 PRO |
292
+
293
+ ### Firewall Tools
294
+
295
+ | Tool | Description | Tier |
296
+ |------|-------------|------|
297
+ | `firewall_status` | Get current firewall status | FREE |
298
+ | `firewall_set_mode` | Set firewall mode (enforce = PRO only) | FREE/🔒 PRO |
299
+ | `firewall_set_intent` | Set intent before making changes | 🔒 PRO |
300
+ | `firewall_get_intent` | Get current intent | 🔒 PRO |
301
+ | `firewall_clear_intent` | Clear current intent | 🔒 PRO |
302
+ | `firewall_check` | Run comprehensive shield check | 🔒 PRO |
303
+ | `firewall_verify_claim` | Verify an AI claim | 🔒 PRO |
304
+ | `firewall_gate_action` | Check if action is allowed | 🔒 PRO |
305
+ | `firewall_get_templates` | Get intent templates | 🔒 PRO |
306
+
307
+ ### Prompt Builder Tools (FREE)
308
+
309
+ | Tool | Description | Tier |
310
+ |------|-------------|------|
311
+ | `prompt_get_templates` | Get available prompt templates | FREE |
312
+ | `prompt_get_categories` | Get template categories | FREE |
313
+ | `prompt_detect_template` | Detect template from input | FREE |
314
+ | `prompt_build` | Build enhanced prompt | FREE |
315
+ | `prompt_get_context` | Get workspace context | FREE |
316
+ | `prompt_get_suggestions` | Get smart suggestions | FREE |
317
+
318
+ ### Session Management Tools (FREE)
319
+
320
+ | Tool | Description | Tier |
321
+ |------|-------------|------|
322
+ | `session_info` | Get current session info and metrics | FREE |
323
+ | `session_metrics` | Detailed session statistics | FREE |
324
+ | `session_history` | Recent tool call history | FREE |
325
+ | `session_health` | Session health and trust score | FREE |
326
+
327
+ ### Git Integration Tools
328
+
329
+ | Tool | Description | Tier |
330
+ |------|-------------|------|
331
+ | `git_status` | Comprehensive git status | FREE |
332
+ | `git_diff` | Diff analysis with risk assessment | FREE |
333
+ | `git_diff_intent_check` | Check diff against declared intent | 🔒 PRO |
334
+ | `git_commits` | Recent commit history | FREE |
335
+ | `git_branches` | List all branches | FREE |
336
+ | `git_file_history` | File commit history | FREE |
337
+ | `git_snapshot` | Create git stash snapshot | 🔒 PRO |
338
+
339
+ ### Context Management Tools (FREE)
340
+
341
+ | Tool | Description | Tier |
342
+ |------|-------------|------|
343
+ | `context_project` | Project structure analysis | FREE |
344
+ | `context_window` | Smart context window for queries | FREE |
345
+ | `context_find_files` | Find files by pattern | FREE |
346
+ | `context_related_files` | Find related files by imports | FREE |
347
+ | `context_file_info` | Detailed file information | FREE |
348
+
349
+ ### Cache & Health Tools (FREE)
350
+
351
+ | Tool | Description | Tier |
352
+ |------|-------------|------|
353
+ | `cache_stats` | Cache hit rate and statistics | FREE |
354
+ | `cache_clear` | Clear cache entries | FREE |
355
+ | `health_check` | Comprehensive health check | FREE |
356
+
357
+ ## Available Resources
358
+
359
+ | URI | Description |
360
+ |-----|-------------|
361
+ | `vibecheck://status` | Server status and configuration |
362
+ | `vibecheck://tier` | Subscription tier info |
363
+ | `vibecheck://session` | Current session info |
364
+ | `vibecheck://firewall/stats` | Firewall statistics |
365
+ | `vibecheck://firewall/log` | Recent action log |
366
+ | `vibecheck://git/status` | Git repository status |
367
+ | `vibecheck://context` | Detected workspace context |
368
+ | `vibecheck://project` | Project structure |
369
+ | `vibecheck://health` | Health check status |
370
+ | `vibecheck://cache` | Cache statistics |
371
+
372
+ ## Usage Examples
373
+
374
+ ### Setting Intent Before Code Changes
165
375
 
166
- ```json
167
- {
168
- "tool": "vibecheck_fix",
169
- "arguments": {
170
- "apply": true,
171
- "autopilot": false,
172
- "maxMissions": 8
173
- }
174
- }
175
376
  ```
377
+ Agent: I'll set an intent first before making changes.
176
378
 
177
- ### Generate IDE Rules
379
+ [Calls firewall_set_intent with template="Bug Fix"]
178
380
 
179
- ```json
180
- {
181
- "tool": "vibecheck_forge",
182
- "arguments": {
183
- "format": "cursor",
184
- "enhanced": true
185
- }
186
- }
381
+ Now I can make minimal changes to fix the bug.
187
382
  ```
188
383
 
189
- ---
384
+ ### Building Enhanced Prompts
190
385
 
191
- ## Resources
386
+ ```
387
+ User: I need to add OAuth login with Google and GitHub
192
388
 
193
- - `vibecheck://rules` - Generated AI rules
194
- - `vibecheck://truthpack` - Repo reality index
195
- - `vibecheck://status` - Server status and health
389
+ Agent: Let me build an enhanced prompt for that.
196
390
 
197
- ---
391
+ [Calls prompt_detect_template with input="OAuth login Google GitHub"]
392
+ [Calls prompt_build with templateId="auth-oauth" and answers]
198
393
 
199
- ## Documentation
394
+ Here's your production-ready implementation plan...
395
+ ```
200
396
 
201
- - [MCP Quick Start](../docs/MCP-QUICK-START.md)
202
- - [Full CLI Documentation](../docs/CLI-REFERENCE.md)
203
- - [Agent Firewall Spec](../docs/AGENT_FIREWALL_V2_SPEC.md)
397
+ ### Verifying Claims
204
398
 
205
- ---
399
+ ```
400
+ Agent: I only added a new API route, nothing else.
401
+
402
+ [Calls firewall_verify_claim with claim="I only added a new API route"]
403
+
404
+ Verification result: VERIFIED with 95% confidence
405
+ ```
406
+
407
+ ## Firewall Modes
408
+
409
+ ### Off (FREE)
410
+ Firewall is disabled. All actions are allowed without restrictions.
411
+
412
+ ### Observe (FREE)
413
+ Firewall is active but permissive:
414
+ - Actions are logged
415
+ - Warnings are issued for sensitive operations without intent
416
+ - No blocking occurs
417
+ - **Available on FREE tier**
418
+
419
+ ### Enforce (🔒 PRO)
420
+ Firewall is strict:
421
+ - Intent is required for write/execute/sensitive actions
422
+ - Actions violating intent constraints are blocked
423
+ - All actions are logged
424
+ - **Requires PRO subscription ($49/mo)**
425
+
426
+ ## Intent Templates
427
+
428
+ Pre-defined templates for common tasks:
429
+
430
+ | Template | Constraints |
431
+ |----------|-------------|
432
+ | Add Auth | Use existing middleware, no new env vars, no billing changes |
433
+ | Add Route | No new env vars, no auth changes, follow patterns |
434
+ | Bug Fix | Minimal changes, no new deps, no unrelated refactoring |
435
+ | Refactor | No behavior changes, preserve tests, no new features |
436
+ | Add Feature | Use existing patterns, add tests, update docs |
437
+ | Payment Flow | No auth changes, preserve integrations, add audit logging |
438
+ | Database Migration | Create rollback, no data deletion, test in staging |
439
+ | Dependency Update | One major version at a time, run tests, check breaking changes |
440
+
441
+ ## Programmatic Usage
442
+
443
+ ```typescript
444
+ import { VibecheckMcpServer } from '@vibecheck/mcp-standard';
445
+
446
+ const server = new VibecheckMcpServer({
447
+ workspacePath: '/path/to/project',
448
+ defaultFirewallMode: 'observe',
449
+ logLevel: 'info',
450
+ });
451
+
452
+ await server.run();
453
+ ```
454
+
455
+ ### Using Services Directly
456
+
457
+ ```typescript
458
+ import { CliService, FirewallService, PromptBuilderService } from '@vibecheck/mcp-standard';
459
+
460
+ // CLI Service
461
+ const cli = new CliService('/path/to/project');
462
+ const auditResult = await cli.audit();
463
+
464
+ // Firewall Service
465
+ const firewall = new FirewallService(cli);
466
+ await firewall.setIntent('Add new API route', ['No auth changes']);
467
+ const gateResult = firewall.gateAction('create file', 'write');
468
+
469
+ // Prompt Builder
470
+ const promptBuilder = new PromptBuilderService('/path/to/project');
471
+ const context = await promptBuilder.detectWorkspaceContext();
472
+ const prompt = await promptBuilder.buildPrompt('auth-oauth', 'Add OAuth', { providers: ['google'] });
473
+ ```
474
+
475
+ ## Developer Mode
476
+
477
+ For local development only (blocked in production/CI):
478
+
479
+ ```bash
480
+ VIBECHECK_DEV_PRO=1 NODE_ENV=development npx @vibecheck/mcp-standard
481
+ ```
482
+
483
+ **Security:** This bypass is blocked when:
484
+ - `NODE_ENV=production`
485
+ - `CI=true`
486
+
487
+ ## Upgrading
488
+
489
+ ```bash
490
+ vibecheck auth login
491
+ # Then visit: https://vibecheckai.dev/pricing
492
+ ```
493
+
494
+ ## Requirements
495
+
496
+ - Node.js >= 18.0.0
497
+ - VibeCheck CLI (optional, for full functionality)
206
498
 
207
- ## Privacy & Trust
499
+ ## License
208
500
 
209
- - Runs locally
210
- - Artifacts saved to `.vibecheck/`
211
- - No upload unless you explicitly export/share
501
+ MIT