@vibecheckai/cli 3.7.0 → 3.9.0

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 (118) hide show
  1. package/README.md +135 -63
  2. package/bin/_deprecations.js +447 -19
  3. package/bin/_router.js +1 -1
  4. package/bin/registry.js +347 -280
  5. package/bin/runners/context/generators/cursor-enhanced.js +2439 -0
  6. package/bin/runners/lib/agent-firewall/enforcement/gateway.js +1059 -0
  7. package/bin/runners/lib/agent-firewall/enforcement/index.js +98 -0
  8. package/bin/runners/lib/agent-firewall/enforcement/mode.js +318 -0
  9. package/bin/runners/lib/agent-firewall/enforcement/orchestrator.js +484 -0
  10. package/bin/runners/lib/agent-firewall/enforcement/proof-artifact.js +418 -0
  11. package/bin/runners/lib/agent-firewall/enforcement/schemas/change-event.schema.json +173 -0
  12. package/bin/runners/lib/agent-firewall/enforcement/schemas/intent.schema.json +181 -0
  13. package/bin/runners/lib/agent-firewall/enforcement/schemas/verdict.schema.json +222 -0
  14. package/bin/runners/lib/agent-firewall/enforcement/verdict-v2.js +333 -0
  15. package/bin/runners/lib/agent-firewall/index.js +200 -0
  16. package/bin/runners/lib/agent-firewall/integration/index.js +20 -0
  17. package/bin/runners/lib/agent-firewall/integration/ship-gate.js +437 -0
  18. package/bin/runners/lib/agent-firewall/intent/alignment-engine.js +634 -0
  19. package/bin/runners/lib/agent-firewall/intent/auto-detect.js +426 -0
  20. package/bin/runners/lib/agent-firewall/intent/index.js +102 -0
  21. package/bin/runners/lib/agent-firewall/intent/schema.js +352 -0
  22. package/bin/runners/lib/agent-firewall/intent/store.js +283 -0
  23. package/bin/runners/lib/agent-firewall/interception/fs-interceptor.js +502 -0
  24. package/bin/runners/lib/agent-firewall/interception/index.js +23 -0
  25. package/bin/runners/lib/agent-firewall/interceptor/base.js +7 -3
  26. package/bin/runners/lib/agent-firewall/session/collector.js +451 -0
  27. package/bin/runners/lib/agent-firewall/session/index.js +26 -0
  28. package/bin/runners/lib/artifact-envelope.js +540 -0
  29. package/bin/runners/lib/auth-shared.js +977 -0
  30. package/bin/runners/lib/checkpoint.js +941 -0
  31. package/bin/runners/lib/cleanup/engine.js +571 -0
  32. package/bin/runners/lib/cleanup/index.js +53 -0
  33. package/bin/runners/lib/cleanup/output.js +375 -0
  34. package/bin/runners/lib/cleanup/rules.js +1060 -0
  35. package/bin/runners/lib/doctor/diagnosis-receipt.js +454 -0
  36. package/bin/runners/lib/doctor/failure-signatures.js +526 -0
  37. package/bin/runners/lib/doctor/fix-script.js +336 -0
  38. package/bin/runners/lib/doctor/modules/build-tools.js +453 -0
  39. package/bin/runners/lib/doctor/modules/index.js +62 -3
  40. package/bin/runners/lib/doctor/modules/os-quirks.js +706 -0
  41. package/bin/runners/lib/doctor/modules/repo-integrity.js +485 -0
  42. package/bin/runners/lib/doctor/safe-repair.js +384 -0
  43. package/bin/runners/lib/engine/ast-cache.js +210 -210
  44. package/bin/runners/lib/engine/auth-extractor.js +211 -211
  45. package/bin/runners/lib/engine/billing-extractor.js +112 -112
  46. package/bin/runners/lib/engine/enforcement-extractor.js +100 -100
  47. package/bin/runners/lib/engine/env-extractor.js +207 -207
  48. package/bin/runners/lib/engine/express-extractor.js +208 -208
  49. package/bin/runners/lib/engine/extractors.js +849 -849
  50. package/bin/runners/lib/engine/index.js +207 -207
  51. package/bin/runners/lib/engine/repo-index.js +514 -514
  52. package/bin/runners/lib/engine/types.js +124 -124
  53. package/bin/runners/lib/engines/attack-detector.js +1192 -0
  54. package/bin/runners/lib/entitlements-v2.js +2 -2
  55. package/bin/runners/lib/missions/briefing.js +427 -0
  56. package/bin/runners/lib/missions/checkpoint.js +753 -0
  57. package/bin/runners/lib/missions/hardening.js +851 -0
  58. package/bin/runners/lib/missions/plan.js +421 -32
  59. package/bin/runners/lib/missions/safety-gates.js +645 -0
  60. package/bin/runners/lib/missions/schema.js +478 -0
  61. package/bin/runners/lib/packs/bundle.js +675 -0
  62. package/bin/runners/lib/packs/evidence-pack.js +671 -0
  63. package/bin/runners/lib/packs/pack-factory.js +837 -0
  64. package/bin/runners/lib/packs/permissions-pack.js +686 -0
  65. package/bin/runners/lib/packs/proof-graph-pack.js +779 -0
  66. package/bin/runners/lib/safelist/index.js +96 -0
  67. package/bin/runners/lib/safelist/integration.js +334 -0
  68. package/bin/runners/lib/safelist/matcher.js +696 -0
  69. package/bin/runners/lib/safelist/schema.js +948 -0
  70. package/bin/runners/lib/safelist/store.js +438 -0
  71. package/bin/runners/lib/schemas/ship-manifest.schema.json +251 -0
  72. package/bin/runners/lib/ship-gate.js +832 -0
  73. package/bin/runners/lib/ship-manifest.js +1153 -0
  74. package/bin/runners/lib/ship-output.js +1 -1
  75. package/bin/runners/lib/unified-cli-output.js +710 -383
  76. package/bin/runners/lib/upsell.js +3 -3
  77. package/bin/runners/lib/why-tree.js +650 -0
  78. package/bin/runners/runAllowlist.js +33 -4
  79. package/bin/runners/runApprove.js +240 -1122
  80. package/bin/runners/runAudit.js +692 -0
  81. package/bin/runners/runAuth.js +325 -29
  82. package/bin/runners/runCheckpoint.js +442 -494
  83. package/bin/runners/runCleanup.js +343 -0
  84. package/bin/runners/runDoctor.js +269 -19
  85. package/bin/runners/runFix.js +411 -32
  86. package/bin/runners/runForge.js +411 -0
  87. package/bin/runners/runIntent.js +906 -0
  88. package/bin/runners/runKickoff.js +878 -0
  89. package/bin/runners/runLaunch.js +2000 -0
  90. package/bin/runners/runLink.js +785 -0
  91. package/bin/runners/runMcp.js +1741 -837
  92. package/bin/runners/runPacks.js +2089 -0
  93. package/bin/runners/runPolish.js +41 -0
  94. package/bin/runners/runReality.js +178 -1
  95. package/bin/runners/runSafelist.js +1190 -0
  96. package/bin/runners/runScan.js +21 -9
  97. package/bin/runners/runShield.js +1282 -0
  98. package/bin/runners/runShip.js +395 -16
  99. package/bin/vibecheck.js +34 -6
  100. package/mcp-server/README.md +117 -158
  101. package/mcp-server/handlers/index.ts +2 -2
  102. package/mcp-server/handlers/tool-handler.ts +50 -11
  103. package/mcp-server/index.js +16 -0
  104. package/mcp-server/intent-firewall-interceptor.js +529 -0
  105. package/mcp-server/lib/executor.ts +5 -5
  106. package/mcp-server/lib/index.ts +14 -4
  107. package/mcp-server/lib/sandbox.test.ts +4 -4
  108. package/mcp-server/lib/sandbox.ts +2 -2
  109. package/mcp-server/manifest.json +473 -0
  110. package/mcp-server/package.json +1 -1
  111. package/mcp-server/registry/tool-registry.js +315 -523
  112. package/mcp-server/registry/tools.json +442 -428
  113. package/mcp-server/registry.test.ts +18 -12
  114. package/mcp-server/tier-auth.js +68 -11
  115. package/mcp-server/tools-v3.js +70 -16
  116. package/mcp-server/tsconfig.json +1 -0
  117. package/package.json +2 -1
  118. package/bin/runners/runProof.zip +0 -0
package/README.md CHANGED
@@ -1,4 +1,4 @@
1
- # vibecheck CLI v3.1.8
1
+ # vibecheck CLI v4.0
2
2
 
3
3
  **Ship with confidence. One verdict: SHIP | WARN | BLOCK**
4
4
 
@@ -9,97 +9,127 @@ The CLI that catches AI hallucinations before they ship. Dead routes, fake data,
9
9
  ```bash
10
10
  npm install -g @vibecheckai/cli
11
11
  # or
12
- npx @vibecheckai/cli ship
12
+ npx @vibecheckai/cli --help
13
13
  ```
14
14
 
15
15
  ## Quick Start
16
16
 
17
17
  ```bash
18
- # 1. Setup your project
19
- vibecheck init --local
18
+ # 1. Setup your project (one-time)
19
+ vibecheck link
20
20
 
21
- # 2. Scan for issues
22
- vibecheck scan
21
+ # 2. 60-second onboarding (recommended)
22
+ vibecheck kickoff
23
23
 
24
- # 3. Get ship verdict
24
+ # 3. Run analysis
25
+ vibecheck audit
26
+
27
+ # 4. Get ship verdict (PRO)
25
28
  vibecheck ship
26
29
 
27
- # 4. Full proof loop (PRO tier)
30
+ # 5. Full proof loop (PRO)
28
31
  vibecheck prove
29
-
30
- # 5. Runtime verification
31
- vibecheck reality --url http://localhost:3000
32
32
  ```
33
33
 
34
- ## Commands
34
+ ## Command Reference
35
35
 
36
- ### Setup Commands
36
+ ### Tiers
37
37
 
38
- | Command | Tier | Description |
39
- |---------|------|-------------|
40
- | `vibecheck init` | FREE | Project setup (`--local` or `--connect`) |
41
- | `vibecheck doctor` | FREE | Environment diagnostics |
42
- | `vibecheck watch` | FREE | Continuous mode - re-runs on changes |
38
+ | Tier | Price | Description |
39
+ |------|-------|-------------|
40
+ | **FREE** | $0 | Inspect & Observe |
41
+ | **PRO** | $49/mo | Fix, Prove & Enforce |
43
42
 
44
- ### Proof Loop
43
+ ---
45
44
 
46
- | Command | Tier | Description |
47
- |---------|------|-------------|
48
- | `vibecheck scan` | FREE | Static analysis - routes, secrets, contracts |
49
- | `vibecheck ship` | FREE | Verdict engine - SHIP / WARN / BLOCK |
50
- | `vibecheck reality` | FREE* | Browser-based runtime verification |
51
- | `vibecheck prove` | PRO | Full loop: scanrealityshipfix |
52
- | `vibecheck fix` | FREE* | AI-powered auto-fix (plan-only on FREE) |
53
- | `vibecheck report` | FREE | Generate HTML/MD/SARIF reports |
45
+ ### FREE Tier Commands
46
+
47
+ | Command | Aliases | Description |
48
+ |---------|---------|-------------|
49
+ | `link` | `init`, `setup`, `configure` | Instant project binding (<10s, zero questions) |
50
+ | `kickoff` | `quickstart`, `qs`, `start`, `onboard` | 60-second dopamine: linkforgeauditship |
51
+ | `doctor` | `health`, `diag` | Environment + dependency + config health check |
52
+ | `watch` | `w`, `dev` | Continuous mode - re-runs on changes |
53
+ | `forge` | `context`, `ctx`, `rules`, `ai-rules`, `mdc`, `brain` | AI Brain Generator - minimal but lethal rules |
54
+ | `audit` | `scan`, `s`, `check` | Convincing wrongness detector |
55
+ | `auth` | `login`, `logout`, `whoami` | Authentication management |
56
+ | `safelist` | `allowlist`, `al`, `suppress` | Responsible finding suppression with justification & expiry |
57
+ | `labs` | — | Experimental & beta features |
58
+ | `packs` | `report`, `html`, `artifact`, `evidence-pack` | Unified artifact generation (evidence, reports, graphs) |
59
+ | `ci` | — | One-command enterprise CI wiring (GitHub Actions) |
54
60
 
55
- ### Quality & Checkpoints
61
+ ---
56
62
 
57
- | Command | Tier | Description |
58
- |---------|------|-------------|
59
- | `vibecheck polish` | FREE | Production polish analyzer (0-100 score) |
60
- | `vibecheck checkpoint` | FREE* | Compare baseline vs current, hallucination scoring |
63
+ ### PRO Tier Commands
64
+
65
+ | Command | Aliases | Description |
66
+ |---------|---------|-------------|
67
+ | `intent` | — | Declare intent for Agent Firewall enforcement |
68
+ | `approve` | — | Review and approve session changes |
69
+ | `shield` | `guard`, `ai-guard`, `firewall`, `validate` | Agent Firewall - intercept, validate, and enforce AI actions |
70
+ | `launch` | `gate`, `ci-gate`, `enforce` | Pre-release validation wizard |
71
+ | `reality` | `browser`, `e2e` | Browser-based runtime verification |
72
+ | `prove` | `p`, `verify` | Full proof loop with runtime verification |
73
+ | `ship` | — | Verdict engine - SHIP / WARN / BLOCK |
74
+ | `seal` | `badge`, `attest` | Generate ship badge and attestation |
75
+ | `fix` | `f`, `repair`, `missions` | Mission-based auto-fix with safety gates |
76
+ | `checkpoint` | `cp`, `snap`, `snapshot`, `timemachine` | Time machine - snapshot & restore |
77
+ | `polish` | `prod`, `final` | Production polish - final cleanup before deploy |
78
+ | `mcp` | — | Start MCP server for AI IDEs |
61
79
 
62
- ### Truth System (AI Guardrails)
80
+ ---
63
81
 
64
- | Command | Tier | Description |
65
- |---------|------|-------------|
66
- | `vibecheck context` | FREE | Generate .cursorrules, .windsurf/rules, MDC |
67
- | `vibecheck guard` | FREE | Validate AI claims against truth |
82
+ ### Shield Subcommands (Agent Firewall)
68
83
 
69
- ### Automation
84
+ ```bash
85
+ vibecheck shield status # Show firewall status
86
+ vibecheck shield enforce # Enable enforcement mode
87
+ vibecheck shield observe # Enable observe-only mode
88
+ vibecheck shield lock # Hard lockdown (all rules)
89
+ vibecheck shield unlock # Release lock
90
+ vibecheck shield verify # Verify claims/prompts
91
+ vibecheck shield install # Install IDE hooks
92
+ vibecheck shield stats # Show statistics
93
+ ```
70
94
 
71
- | Command | Tier | Description |
72
- |---------|------|-------------|
73
- | `vibecheck mcp` | STARTER | Start MCP server for AI IDEs |
74
- | `vibecheck ai-test` | PRO | AI autonomous test |
95
+ ---
75
96
 
76
- ### Account
97
+ ### Packs Subcommands (Artifacts)
77
98
 
78
- | Command | Tier | Description |
79
- |---------|------|-------------|
80
- | `vibecheck login` | FREE | Authenticate with API key |
81
- | `vibecheck logout` | FREE | Remove stored credentials |
82
- | `vibecheck whoami` | FREE | Show current user and plan |
99
+ ```bash
100
+ vibecheck packs evidence # Bundle videos, traces, screenshots
101
+ vibecheck packs report # Generate HTML/MD/SARIF reports
102
+ vibecheck packs graph # Proof graph visualization
103
+ ```
104
+
105
+ ---
83
106
 
84
- *Commands marked with * have limited functionality on FREE tier
107
+ ### Auth Subcommands
85
108
 
86
- ## Pricing
109
+ ```bash
110
+ vibecheck auth login # Authenticate with API key
111
+ vibecheck auth logout # Remove stored credentials
112
+ vibecheck auth whoami # Show current user and plan
113
+ vibecheck auth --check # Verify authentication status
114
+ vibecheck auth --refresh # Refresh credentials
115
+ ```
87
116
 
88
- | Tier | Price | Features |
89
- |------|-------|----------|
90
- | FREE | $0 | init --local, scan, ship (static), doctor, polish, report (HTML/MD), context, guard, checkpoint (basic) |
91
- | STARTER | $39/mo | + init --connect, scan --autofix, report (SARIF/CSV), mcp, reality (basic) |
92
- | PRO | $49/mo | + prove, fix --apply, checkpoint (hallucination), reality (advanced), ai-test |
117
+ ---
93
118
 
94
119
  ## What It Catches
95
120
 
96
- - **Dead Routes** - Client calls API that doesn't exist → BLOCK
97
- - **Ghost Auth** - Sensitive endpoint without auth → BLOCK
98
- - **Exposed Secrets** - API keys in code → BLOCK
99
- - **Fake Success** - Success UI without API confirmation BLOCK
100
- - **Env Gaps** - Used env vars not in .env.example → WARN
101
- - **Stripe Violations** - Unverified webhooks BLOCK
102
- - **Owner Mode Bypass** - Debug flags in production → BLOCK
121
+ | Issue | Severity | Description |
122
+ |-------|----------|-------------|
123
+ | Dead Routes | BLOCK | Client calls API that doesn't exist |
124
+ | Ghost Auth | BLOCK | Sensitive endpoint without auth |
125
+ | Exposed Secrets | BLOCK | API keys in code |
126
+ | Fake Success | BLOCK | Success UI without API confirmation |
127
+ | Env Gaps | WARN | Used env vars not in .env.example |
128
+ | Stripe Violations | BLOCK | Unverified webhooks |
129
+ | Owner Mode Bypass | BLOCK | Debug flags in production |
130
+ | Mock Data | BLOCK | Fake/fixture data in production |
131
+
132
+ ---
103
133
 
104
134
  ## Ship Verdict
105
135
 
@@ -109,7 +139,16 @@ vibecheck reality --url http://localhost:3000
109
139
  ╚═════════════════════════════════════════════════════════════════╝
110
140
  ```
111
141
 
112
- Exit codes: `0` = SHIP, `1` = WARN, `2` = BLOCK, `3` = Feature not allowed, `4` = Unknown command
142
+ ### Exit Codes
143
+
144
+ | Code | Status | Meaning |
145
+ |------|--------|---------|
146
+ | `0` | ✅ SHIP | All checks passed |
147
+ | `2` | 🚫 BLOCK | Violations found (CI failure) |
148
+ | `3` | ⚠️ UPGRADE | Feature requires higher tier |
149
+ | `4` | ❌ ERROR | Misconfiguration / env error |
150
+
151
+ ---
113
152
 
114
153
  ## MCP Server
115
154
 
@@ -126,6 +165,20 @@ Connect vibecheck to AI coding agents (Cursor, Windsurf, Claude):
126
165
  }
127
166
  ```
128
167
 
168
+ ### Available MCP Tools
169
+
170
+ | Tool | Description |
171
+ |------|-------------|
172
+ | `vibecheck_audit` | Run static analysis |
173
+ | `vibecheck_ship` | Get ship verdict |
174
+ | `vibecheck_fix` | Apply AI-powered fixes |
175
+ | `vibecheck_prove` | Full proof loop |
176
+ | `vibecheck_shield` | Agent Firewall controls |
177
+ | `vibecheck_forge` | Generate IDE rules |
178
+ | `vibecheck_reality` | Runtime verification |
179
+
180
+ ---
181
+
129
182
  ## Configuration
130
183
 
131
184
  Create `.vibecheck/config.json`:
@@ -138,6 +191,25 @@ Create `.vibecheck/config.json`:
138
191
  }
139
192
  ```
140
193
 
194
+ Or `vibecheck.config.json` in project root:
195
+
196
+ ```json
197
+ {
198
+ "version": "4.0.0",
199
+ "checks": ["integrity", "security", "hygiene"],
200
+ "output": ".vibecheck",
201
+ "policy": {
202
+ "failOn": ["critical", "high"],
203
+ "allowlist": {
204
+ "domains": ["api.stripe.com"],
205
+ "paths": ["src/testing/*"]
206
+ }
207
+ }
208
+ }
209
+ ```
210
+
211
+ ---
212
+
141
213
  ## License
142
214
 
143
215
  MIT © Vibecheck AI