@vibecheckai/cli 3.7.0 → 3.8.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 (99) 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 +622 -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/session/collector.js +451 -0
  26. package/bin/runners/lib/agent-firewall/session/index.js +26 -0
  27. package/bin/runners/lib/artifact-envelope.js +540 -0
  28. package/bin/runners/lib/auth-shared.js +977 -0
  29. package/bin/runners/lib/checkpoint.js +941 -0
  30. package/bin/runners/lib/cleanup/engine.js +571 -0
  31. package/bin/runners/lib/cleanup/index.js +53 -0
  32. package/bin/runners/lib/cleanup/output.js +375 -0
  33. package/bin/runners/lib/cleanup/rules.js +1060 -0
  34. package/bin/runners/lib/doctor/diagnosis-receipt.js +454 -0
  35. package/bin/runners/lib/doctor/failure-signatures.js +526 -0
  36. package/bin/runners/lib/doctor/fix-script.js +336 -0
  37. package/bin/runners/lib/doctor/modules/build-tools.js +453 -0
  38. package/bin/runners/lib/doctor/modules/index.js +62 -3
  39. package/bin/runners/lib/doctor/modules/os-quirks.js +706 -0
  40. package/bin/runners/lib/doctor/modules/repo-integrity.js +485 -0
  41. package/bin/runners/lib/doctor/safe-repair.js +384 -0
  42. package/bin/runners/lib/engines/attack-detector.js +1192 -0
  43. package/bin/runners/lib/entitlements-v2.js +2 -2
  44. package/bin/runners/lib/missions/briefing.js +427 -0
  45. package/bin/runners/lib/missions/checkpoint.js +753 -0
  46. package/bin/runners/lib/missions/hardening.js +851 -0
  47. package/bin/runners/lib/missions/plan.js +421 -32
  48. package/bin/runners/lib/missions/safety-gates.js +645 -0
  49. package/bin/runners/lib/missions/schema.js +478 -0
  50. package/bin/runners/lib/packs/bundle.js +675 -0
  51. package/bin/runners/lib/packs/evidence-pack.js +671 -0
  52. package/bin/runners/lib/packs/pack-factory.js +837 -0
  53. package/bin/runners/lib/packs/permissions-pack.js +686 -0
  54. package/bin/runners/lib/packs/proof-graph-pack.js +779 -0
  55. package/bin/runners/lib/safelist/index.js +96 -0
  56. package/bin/runners/lib/safelist/integration.js +334 -0
  57. package/bin/runners/lib/safelist/matcher.js +696 -0
  58. package/bin/runners/lib/safelist/schema.js +948 -0
  59. package/bin/runners/lib/safelist/store.js +438 -0
  60. package/bin/runners/lib/schemas/ship-manifest.schema.json +251 -0
  61. package/bin/runners/lib/ship-gate.js +832 -0
  62. package/bin/runners/lib/ship-manifest.js +1153 -0
  63. package/bin/runners/lib/ship-output.js +1 -1
  64. package/bin/runners/lib/unified-cli-output.js +710 -383
  65. package/bin/runners/lib/upsell.js +3 -3
  66. package/bin/runners/lib/why-tree.js +650 -0
  67. package/bin/runners/runAllowlist.js +33 -4
  68. package/bin/runners/runApprove.js +240 -1122
  69. package/bin/runners/runAudit.js +692 -0
  70. package/bin/runners/runAuth.js +325 -29
  71. package/bin/runners/runCheckpoint.js +442 -494
  72. package/bin/runners/runCleanup.js +343 -0
  73. package/bin/runners/runDoctor.js +269 -19
  74. package/bin/runners/runFix.js +411 -32
  75. package/bin/runners/runForge.js +411 -0
  76. package/bin/runners/runIntent.js +906 -0
  77. package/bin/runners/runKickoff.js +878 -0
  78. package/bin/runners/runLaunch.js +2000 -0
  79. package/bin/runners/runLink.js +785 -0
  80. package/bin/runners/runMcp.js +1741 -837
  81. package/bin/runners/runPacks.js +2089 -0
  82. package/bin/runners/runPolish.js +41 -0
  83. package/bin/runners/runSafelist.js +1190 -0
  84. package/bin/runners/runScan.js +21 -9
  85. package/bin/runners/runShield.js +1282 -0
  86. package/bin/runners/runShip.js +395 -16
  87. package/bin/vibecheck.js +34 -6
  88. package/mcp-server/README.md +117 -158
  89. package/mcp-server/handlers/tool-handler.ts +3 -3
  90. package/mcp-server/index.js +16 -0
  91. package/mcp-server/intent-firewall-interceptor.js +529 -0
  92. package/mcp-server/manifest.json +473 -0
  93. package/mcp-server/package.json +1 -1
  94. package/mcp-server/registry/tool-registry.js +315 -523
  95. package/mcp-server/registry/tools.json +442 -428
  96. package/mcp-server/tier-auth.js +68 -11
  97. package/mcp-server/tools-v3.js +70 -16
  98. package/package.json +1 -1
  99. package/bin/runners/runProof.zip +0 -0
package/bin/registry.js CHANGED
@@ -1,12 +1,18 @@
1
1
  /**
2
2
  * Vibecheck CLI Command Registry
3
3
  *
4
+ * ═══════════════════════════════════════════════════════════════════════════════
5
+ * VERSION 4.0.0 - CLEAN & TIGHT
6
+ * ═══════════════════════════════════════════════════════════════════════════════
7
+ *
4
8
  * Single source of truth for the public CLI surface.
5
9
  * If it isn't here, it does not exist.
6
10
  *
7
- * Simple 2-tier model:
11
+ * 2-tier model:
8
12
  * - FREE ($0): Inspect & Observe
9
- * - PRO ($69/mo): Fix, Prove & Enforce
13
+ * - PRO ($49/mo): Fix, Prove & Enforce
14
+ *
15
+ * @version 4.0.0
10
16
  */
11
17
 
12
18
  "use strict";
@@ -15,33 +21,32 @@
15
21
  // CLI COMMANDS (2-tier: FREE / PRO)
16
22
  // ─────────────────────────────────────────────────────────────
17
23
  const ALLOWED_COMMANDS = new Set([
18
- // FREE (14) - Inspect & Observe
19
- "init", // one-time setup
20
- "quickstart", // 2-minute onboarding (NEW)
21
- "doctor", // health check
22
- "watch", // continuous mode
23
- "scan", // static analysis
24
- "report", // generate reports
25
- "context", // generate IDE rules
26
- "classify", // Authority: inventory (read-only)
27
- "login", // authenticate
28
- "logout", // remove credentials
29
- "whoami", // show current user
30
- "allowlist", // manage finding allowlist
31
- "evidence-pack", // bundle proof artifacts
32
- "labs", // experimental features
33
-
34
- // PRO (9) - Fix, Prove & Enforce
35
- "ship", // verdict engine (GO/NO-GO)
36
- "fix", // AI-powered fixes
37
- "prove", // runtime proof
38
- "reality", // browser verification
39
- "gate", // CI/CD enforcement
40
- "guard", // AI guardrails
41
- "mcp", // MCP server
42
- "checkpoint", // baseline comparison
43
- "approve", // Authority: verdicts
44
- "polish", // production polish
24
+ // FREE - Setup & Observe
25
+ "link",
26
+ "kickoff",
27
+ "doctor",
28
+ "watch",
29
+ "forge",
30
+ "audit",
31
+ "auth",
32
+ "safelist",
33
+ "labs",
34
+ "packs",
35
+ "ci",
36
+
37
+ // PRO - Enforce, Prove & Ship
38
+ "intent",
39
+ "approve",
40
+ "shield",
41
+ "launch",
42
+ "reality",
43
+ "prove",
44
+ "ship",
45
+ "seal",
46
+ "fix",
47
+ "polish",
48
+ "checkpoint",
49
+ "mcp",
45
50
  ]);
46
51
 
47
52
  function assertAllowedOnly(obj) {
@@ -52,41 +57,40 @@ function assertAllowedOnly(obj) {
52
57
  }
53
58
 
54
59
  // ─────────────────────────────────────────────────────────────
55
- // COMMANDS - 2-Tier: FREE and PRO ($69/mo)
60
+ // COMMANDS - Canonical Only
56
61
  // ─────────────────────────────────────────────────────────────
57
62
  const COMMANDS = {
58
63
  // ══════════════════════════════════════════════════════════════
59
- // FREE TIER - Inspect & Observe
64
+ // FREE TIER
60
65
  // ══════════════════════════════════════════════════════════════
61
66
 
62
- init: {
63
- description: "One-time setup (config + contracts + scripts)",
64
- longDescription: "Initialize vibecheck in your project. Creates configuration files, sets up IDE rules, and optionally connects to the dashboard.",
67
+ link: {
68
+ description: "Instant project binding (<10s, zero questions)",
69
+ longDescription: "Bind your project to VibeCheck in under 10 seconds. Auto-detects package manager, framework, runtime, monorepo structure, and CI. Creates .vibecheck/project.json receipt with smart next-step suggestion.",
65
70
  tier: "free",
66
71
  category: "setup",
67
- aliases: ["setup", "configure"],
68
- runner: () => require("./runners/runInit").runInit,
72
+ runner: () => require("./runners/runLink").runLink,
69
73
  examples: [
70
- { command: "vibecheck init", description: "Interactive setup wizard" },
71
- { command: "vibecheck init --local", description: "Quick local-only setup" },
72
- { command: "vibecheck init --quick", description: "Non-interactive defaults" },
74
+ { command: "vibecheck link", description: "Instant project binding" },
75
+ { command: "vibecheck link --force", description: "Re-link existing project" },
76
+ { command: "vibecheck link --json", description: "JSON output for CI" },
73
77
  ],
74
- related: ["quickstart", "doctor", "scan"],
78
+ related: ["kickoff", "doctor", "audit"],
75
79
  },
76
80
 
77
- quickstart: {
78
- description: "2-minute onboarding: doctorctxscan → ship report",
79
- longDescription: "Get your first proof in under 2 minutes. Runs the complete verification pipeline with sensible defaults.",
81
+ kickoff: {
82
+ description: "60-second dopamine: linkforgeaudit → ship (auto-detects project type)",
83
+ longDescription: "First run experience that gets you to value in 60 seconds. Auto-detects project intent (frontend, API, full-stack, library), runs optimized pipeline, produces shareable summary with clear next steps.",
80
84
  tier: "free",
81
85
  category: "setup",
82
- aliases: ["qs", "start", "onboard"],
83
- runner: () => require("./runners/runQuickstart").runQuickstart,
86
+ runner: () => require("./runners/runKickoff").runKickoff,
84
87
  examples: [
85
- { command: "vibecheck quickstart", description: "Run full 2-minute onboarding" },
86
- { command: "vibecheck quickstart --fast", description: "Skip optional checks" },
87
- { command: "vibecheck quickstart --no-open", description: "Don't open report in browser" },
88
+ { command: "vibecheck kickoff", description: "60-second first run" },
89
+ { command: "vibecheck kickoff --fast", description: "30-second fast mode" },
90
+ { command: "vibecheck kickoff --tier minimal", description: "Minimal AI rules" },
91
+ { command: "vibecheck kickoff --no-ship", description: "Skip ship verdict" },
88
92
  ],
89
- related: ["init", "scan", "ship"],
93
+ related: ["link", "forge", "audit", "ship"],
90
94
  },
91
95
 
92
96
  doctor: {
@@ -94,14 +98,13 @@ const COMMANDS = {
94
98
  longDescription: "Comprehensive diagnostics for your development environment.",
95
99
  tier: "free",
96
100
  category: "setup",
97
- aliases: ["health", "diag"],
98
101
  runner: () => require("./runners/runDoctor").runDoctor,
99
102
  examples: [
100
103
  { command: "vibecheck doctor", description: "Run all health checks" },
101
104
  { command: "vibecheck doctor --fix", description: "Auto-fix detected issues" },
102
105
  { command: "vibecheck doctor --json", description: "Output as JSON" },
103
106
  ],
104
- related: ["init", "scan"],
107
+ related: ["link", "audit"],
105
108
  },
106
109
 
107
110
  watch: {
@@ -109,210 +112,194 @@ const COMMANDS = {
109
112
  longDescription: "File watcher that automatically re-runs scans when your code changes.",
110
113
  tier: "free",
111
114
  category: "setup",
112
- aliases: ["w", "dev"],
113
115
  runner: () => require("./runners/runWatch").runWatch,
114
116
  examples: [
115
117
  { command: "vibecheck watch", description: "Start watching" },
116
118
  { command: "vibecheck watch --path ./src", description: "Watch specific directory" },
117
119
  ],
118
- related: ["scan"],
119
- },
120
-
121
- scan: {
122
- description: "Static code analysis; use --allowlist for false positives",
123
- longDescription: "Scan your codebase for route integrity issues, security vulnerabilities, and code quality problems.",
124
- tier: "free",
125
- category: "proof",
126
- aliases: ["s", "check"],
127
- runner: () => require("./runners/runScan").runScan,
128
- examples: [
129
- { command: "vibecheck scan", description: "Quick scan" },
130
- { command: "vibecheck scan --profile full", description: "Full scan" },
131
- { command: "vibecheck scan --allowlist list", description: "View suppressed findings" },
132
- ],
133
- related: ["ship", "fix", "report"],
134
- },
135
-
136
- report: {
137
- description: "Generate HTML/MD/SARIF reports",
138
- longDescription: "Create shareable reports from scan results.",
139
- tier: "free",
140
- category: "output",
141
- aliases: ["html", "artifact"],
142
- runner: () => require("./runners/runReport").runReport,
143
- examples: [
144
- { command: "vibecheck report", description: "Generate HTML report" },
145
- { command: "vibecheck report --format md", description: "Markdown report" },
146
- { command: "vibecheck report --format sarif", description: "SARIF for GitHub" },
147
- ],
148
- related: ["scan"],
120
+ related: ["audit"],
149
121
  },
150
122
 
151
- context: {
152
- description: "Generate IDE rules (.cursorrules, MDC, Copilot)",
153
- longDescription: "Generate project-aware AI coding rules for your IDE.",
123
+ forge: {
124
+ description: "🔥 AI Brain Generator - minimal but lethal rules",
125
+ longDescription: "Generate the smallest set of rules that produce the biggest accuracy lift. Creates .cursorrules, MDC specs, AI contracts, truthpacks, subagents, skills, and hooks. 5-10 rules max by default, expandable tiers.",
154
126
  tier: "free",
155
127
  category: "truth",
156
- aliases: ["rules", "ai-rules", "mdc", "ctx"],
157
- runner: () => require("./runners/runContext").runContext,
128
+ runner: () => require("./runners/runForge").runForge,
158
129
  examples: [
159
- { command: "vibecheck context", description: "Generate all IDE rules" },
160
- { command: "vibecheck context --format cursor", description: ".cursorrules only" },
130
+ { command: "vibecheck forge", description: "Standard tier (10 rules)" },
131
+ { command: "vibecheck forge minimal", description: "Minimal tier (5 rules)" },
132
+ { command: "vibecheck forge extended", description: "Extended tier (20 rules)" },
133
+ { command: "vibecheck forge --no-incremental", description: "Full regeneration" },
161
134
  ],
162
- related: ["scan", "guard"],
135
+ related: ["audit", "shield", "mcp"],
163
136
  },
164
137
 
165
- classify: {
166
- description: "Inventory authority - duplication & legacy code maps",
167
- longDescription: "Read-only inventory of your codebase including duplication maps and legacy code detection.",
138
+ audit: {
139
+ description: "Convincing wrongness detector - find code that LOOKS done but DOESN'T work",
140
+ longDescription: "Find code that LOOKS done but DOESN'T work. Detects dead routes, ghost env vars, fake success UI, auth drift, mock landmines, silent failures, optimistic bombs, and paid theater.",
168
141
  tier: "free",
169
- category: "authority",
170
- aliases: ["inventory", "audit"],
171
- runner: () => require("./runners/runClassify").runClassify,
142
+ category: "analysis",
143
+ runner: () => require("./runners/runAudit").runAudit,
172
144
  examples: [
173
- { command: "vibecheck classify", description: "Quick inventory" },
174
- { command: "vibecheck classify --json", description: "JSON output" },
145
+ { command: "vibecheck audit", description: "Quick scan for convincing wrongness" },
146
+ { command: "vibecheck audit --deep", description: "Deep scan with cross-file analysis" },
147
+ { command: "vibecheck audit --fail-on critical --sarif", description: "CI mode with SARIF output" },
148
+ { command: "vibecheck audit --threshold high", description: "Show only critical and high findings" },
175
149
  ],
176
- related: ["approve", "scan"],
150
+ related: ["ship", "fix", "packs", "safelist"],
177
151
  },
178
152
 
179
- login: {
180
- description: "Authenticate with API key",
181
- longDescription: "Connect your CLI to the vibecheck API.",
153
+ auth: {
154
+ description: "Authentication management (login, logout, me, --check, --refresh)",
155
+ longDescription: "Manage your VibeCheck authentication. Subcommands: login, logout, whoami/me. Flags: --check (validate without prompting), --refresh (force entitlements refresh).",
182
156
  tier: "free",
183
157
  category: "account",
184
- aliases: ["auth", "signin"],
185
- runner: () => require("./runners/runAuth").runLogin,
158
+ runner: () => require("./runners/runAuth").runAuth,
186
159
  skipAuth: true,
187
160
  examples: [
188
- { command: "vibecheck login", description: "Interactive login" },
189
- { command: "vibecheck login --key YOUR_API_KEY", description: "Login with key" },
161
+ { command: "vibecheck auth login", description: "Interactive login" },
162
+ { command: "vibecheck auth login --key YOUR_API_KEY", description: "Login with key (CI/scripts)" },
163
+ { command: "vibecheck auth logout", description: "Clear all credentials" },
164
+ { command: "vibecheck auth whoami", description: "Show user info (alias: me)" },
165
+ { command: "vibecheck auth --check", description: "Validate auth without prompting (CI)" },
166
+ { command: "vibecheck auth --refresh", description: "Force refresh entitlements from API" },
190
167
  ],
191
- related: ["logout", "whoami"],
168
+ related: [],
192
169
  },
193
170
 
194
- logout: {
195
- description: "Remove stored credentials",
171
+ safelist: {
172
+ description: "Responsible finding suppression with justification & expiry",
173
+ longDescription: "A scalpel, not a trash can. Suppress findings responsibly with required justification, owner accountability, and optional expiration. Supports repo-wide and local-only scopes.",
196
174
  tier: "free",
197
- category: "account",
198
- aliases: ["signout"],
199
- runner: () => require("./runners/runAuth").runLogout,
200
- skipAuth: true,
175
+ category: "config",
176
+ runner: () => require("./runners/runSafelist").runSafelist,
201
177
  examples: [
202
- { command: "vibecheck logout", description: "Clear credentials" },
178
+ { command: "vibecheck safelist", description: "List safelist entries" },
179
+ { command: "vibecheck safelist add --id MOCK_DATA_xyz --reason 'Test fixture data' --category false-positive --owner 'Dev Team'", description: "Add with required fields" },
180
+ { command: "vibecheck safelist add --pattern 'lorem' --reason 'Placeholder text' --category test-fixture --owner 'QA' --expires 30", description: "Add pattern with expiry" },
181
+ { command: "vibecheck safelist report", description: "Show suppression health report" },
182
+ { command: "vibecheck safelist remove --id SL_abc123", description: "Remove entry" },
183
+ { command: "vibecheck safelist clean", description: "Remove expired entries" },
203
184
  ],
204
- related: ["login", "whoami"],
185
+ related: ["audit", "ship"],
205
186
  },
206
187
 
207
- whoami: {
208
- description: "Show current user and plan",
188
+ labs: {
189
+ description: "Experimental & beta features",
190
+ longDescription: "Access experimental features that are in development.",
209
191
  tier: "free",
210
- category: "account",
211
- aliases: ["me", "user"],
212
- runner: () => require("./runners/runAuth").runWhoami,
192
+ category: "experimental",
193
+ runner: () => require("./runners/runLabs").runLabs,
213
194
  skipAuth: true,
214
195
  examples: [
215
- { command: "vibecheck whoami", description: "Show user info" },
216
- ],
217
- related: ["login", "logout"],
218
- },
219
-
220
- allowlist: {
221
- description: "Manage finding allowlist for false positives",
222
- longDescription: "Add, remove, or view allowlist entries to suppress known false positives. Supports patterns, file scopes, and expiration.",
223
- tier: "free",
224
- category: "setup",
225
- aliases: ["al", "suppress"],
226
- runner: () => require("./runners/runAllowlist").runAllowlist,
227
- examples: [
228
- { command: "vibecheck allowlist", description: "List allowlist entries" },
229
- { command: "vibecheck allowlist add --id MOCK_DATA_xyz --reason 'Test fixture'", description: "Add by ID" },
230
- { command: "vibecheck allowlist add --pattern 'lorem' --reason 'Placeholder'", description: "Add pattern" },
231
- { command: "vibecheck allowlist remove --id AL_abc123", description: "Remove entry" },
196
+ { command: "vibecheck labs", description: "List available features" },
197
+ { command: "vibecheck labs ai-agent --url http://localhost:3000", description: "AI agent" },
198
+ { command: "vibecheck labs security-audit", description: "Security audit" },
232
199
  ],
233
- related: ["scan", "ship"],
200
+ related: ["audit", "fix"],
234
201
  },
235
202
 
236
- "evidence-pack": {
237
- description: "Bundle proof artifacts into shareable packs",
238
- longDescription: "Creates shareable evidence packs from proof runs. Bundles videos, traces, screenshots, and findings.",
203
+ packs: {
204
+ description: "Artifact factory V2 - ZIP bundle + manifest + HTML index",
205
+ longDescription: "Turn results into shareable evidence bundles with stable naming, reproducible builds, and cross-links to ship/reality/shield receipts. Subcommands: bundle, evidence, permissions, graph, report, list, cleanup.",
239
206
  tier: "free",
240
207
  category: "output",
241
- aliases: ["pack", "bundle"],
242
- runner: () => require("./runners/runEvidencePack").runEvidencePack,
208
+ runner: () => require("./runners/runPacks").runPacks,
243
209
  examples: [
244
- { command: "vibecheck evidence-pack", description: "Bundle latest run" },
245
- { command: "vibecheck evidence-pack --run-id abc123", description: "Bundle specific run" },
246
- { command: "vibecheck evidence-pack --markdown", description: "Markdown report" },
247
- { command: "vibecheck evidence-pack --no-videos", description: "Exclude large files" },
210
+ { command: "vibecheck packs", description: "Create all-in-one evidence bundle (V2)" },
211
+ { command: "vibecheck packs bundle", description: "ZIP bundle + manifest + HTML index" },
212
+ { command: "vibecheck packs evidence", description: "Bundle videos, traces, screenshots" },
213
+ { command: "vibecheck packs permissions", description: "AuthZ matrix, roles, protected routes" },
214
+ { command: "vibecheck packs graph", description: "Proof graph with receipt cross-links" },
215
+ { command: "vibecheck packs report --format html", description: "Generate HTML report" },
216
+ { command: "vibecheck packs report --format sarif", description: "SARIF for GitHub" },
217
+ { command: "vibecheck packs list", description: "List existing packs and bundles" },
218
+ { command: "vibecheck packs cleanup", description: "Remove old packs (keeps 5 recent)" },
248
219
  ],
249
- related: ["prove", "reality"],
220
+ related: ["prove", "reality", "ship", "fix", "launch"],
221
+ aliases: ["bundle", "artifacts"],
250
222
  },
251
223
 
252
- labs: {
253
- description: "Experimental & beta features",
254
- longDescription: "Access experimental features that are in development. Features may change or be removed without notice.",
224
+ ci: {
225
+ description: "One-command enterprise CI wiring (GitHub Actions)",
226
+ longDescription: "Wire up enterprise-grade GitHub Actions CI from zero. Auto-detects your stack (Next.js, Fastify, etc.), package manager, Node version, and creates optimized workflows with SARIF output, PR comments, and status checks.",
255
227
  tier: "free",
256
- category: "setup",
257
- aliases: ["experimental", "beta"],
258
- runner: () => require("./runners/runLabs").runLabs,
259
- skipAuth: true,
228
+ category: "ci",
229
+ runner: () => require("./runners/runCI").runCI,
260
230
  examples: [
261
- { command: "vibecheck labs", description: "List available features" },
262
- { command: "vibecheck labs ai-agent --url http://localhost:3000", description: "AI agent" },
263
- { command: "vibecheck labs security-audit", description: "Security audit" },
264
- { command: "vibecheck labs smart-fix", description: "AI-powered fixes" },
231
+ { command: "vibecheck ci", description: "Auto-detect and create CI workflows" },
232
+ { command: "vibecheck ci --dry-run", description: "Preview without creating files" },
233
+ { command: "vibecheck ci --full", description: "Create all workflows (audit, ship, e2e, security)" },
234
+ { command: "vibecheck ci --validate", description: "Validate existing workflows" },
265
235
  ],
266
- related: ["scan", "fix"],
236
+ related: ["link", "audit", "ship", "packs"],
267
237
  },
268
238
 
269
239
  // ══════════════════════════════════════════════════════════════
270
- // PRO TIER ($69/mo) - Fix, Prove & Enforce
240
+ // PRO TIER
271
241
  // ══════════════════════════════════════════════════════════════
272
242
 
273
- ship: {
274
- description: "Verdict engine - SHIP / WARN / BLOCK",
275
- longDescription: "The final word on whether your code is ready to ship. Combines all scan results and generates a clear verdict.",
243
+ intent: {
244
+ description: "Declare intent for Agent Firewall enforcement",
245
+ longDescription: "Manage intent declarations for the Agent Firewall v2.",
276
246
  tier: "pro",
277
- category: "proof",
278
- aliases: ["verdict", "go"],
279
- runner: () => require("./runners/runShip").runShip,
247
+ category: "enforcement",
248
+ runner: () => require("./runners/runIntent").runIntent,
280
249
  examples: [
281
- { command: "vibecheck ship", description: "Get shipping verdict" },
282
- { command: "vibecheck ship --strict", description: "Fail on warnings" },
283
- { command: "vibecheck ship --badge", description: "Generate status badge" },
250
+ { command: "vibecheck intent set -s \"fix login bug\"", description: "Set intent" },
251
+ { command: "vibecheck intent show", description: "Show current intent" },
252
+ { command: "vibecheck intent clear", description: "Clear intent" },
284
253
  ],
285
- related: ["scan", "prove", "fix"],
254
+ related: ["approve", "shield", "ship"],
286
255
  },
287
256
 
288
- fix: {
289
- description: "AI-powered auto-fix for findings",
290
- longDescription: "Generate AI prompts to fix detected issues. Use --apply to let AI make changes directly.",
257
+ approve: {
258
+ description: "Review and approve session changes",
259
+ longDescription: "Review AI changes made during a vibe session (OBSERVE mode).",
291
260
  tier: "pro",
292
- category: "proof",
293
- aliases: ["f", "repair"],
294
- runner: () => require("./runners/runFix").runFix,
261
+ category: "enforcement",
262
+ runner: () => require("./runners/runApprove").runApprove,
295
263
  examples: [
296
- { command: "vibecheck fix", description: "Generate fix missions" },
297
- { command: "vibecheck fix --apply", description: "Apply AI fixes" },
298
- { command: "vibecheck fix --loop", description: "Fix loop until clean" },
264
+ { command: "vibecheck approve", description: "Interactive review" },
265
+ { command: "vibecheck approve -y", description: "Auto-approve" },
266
+ { command: "vibecheck approve --reject", description: "Reject pending changes" },
299
267
  ],
300
- related: ["scan", "ship"],
268
+ related: ["intent", "shield"],
301
269
  },
302
270
 
303
- prove: {
304
- description: "Full proof loop with runtime verification",
305
- longDescription: "Complete verification cycle with runtime testing and evidence generation.",
271
+ shield: {
272
+ description: "Agent Firewall - intercept, validate, and enforce AI actions",
273
+ longDescription: "Unified AI enforcement layer. Subcommands: status, enforce, observe, lock, unlock, verify, check, install.",
306
274
  tier: "pro",
307
- category: "proof",
308
- aliases: ["p", "verify"],
309
- runner: () => require("./runners/runProve").runProve,
275
+ category: "enforcement",
276
+ runner: () => require("./runners/runShield").runShield,
310
277
  examples: [
311
- { command: "vibecheck prove", description: "Run full proof loop" },
312
- { command: "vibecheck prove --url http://localhost:3000", description: "With runtime testing" },
313
- { command: "vibecheck prove --bundle", description: "Generate evidence pack" },
278
+ { command: "vibecheck shield status", description: "Show firewall status" },
279
+ { command: "vibecheck shield enforce", description: "Enable enforcement mode" },
280
+ { command: "vibecheck shield observe", description: "Enable observe-only mode" },
281
+ { command: "vibecheck shield verify --claims", description: "Verify AI claims" },
282
+ { command: "vibecheck shield check", description: "v2 enforcement check" },
283
+ { command: "vibecheck shield install", description: "Install IDE hooks" },
314
284
  ],
315
- related: ["ship", "reality"],
285
+ related: ["forge", "ship", "fix", "intent"],
286
+ },
287
+
288
+ launch: {
289
+ description: "Pre-release validation wizard - last 10 minutes before release",
290
+ longDescription: "Comprehensive pre-release checklist that validates build, environment, routes, auth, integrations, and security. One command to ensure you're ready to ship.",
291
+ tier: "pro",
292
+ category: "automation",
293
+ runner: () => require("./runners/runLaunch").runLaunch,
294
+ examples: [
295
+ { command: "vibecheck launch", description: "Interactive pre-release wizard" },
296
+ { command: "vibecheck launch --ci", description: "CI mode (non-interactive)" },
297
+ { command: "vibecheck launch --ci --json", description: "CI mode with JSON output" },
298
+ { command: "vibecheck launch --strict", description: "Treat warnings as blockers" },
299
+ { command: "vibecheck launch --only build,env,security", description: "Run specific phases" },
300
+ { command: "vibecheck launch --bundle", description: "Auto-generate shareable bundle" },
301
+ ],
302
+ related: ["ship", "audit", "shield", "packs"],
316
303
  },
317
304
 
318
305
  reality: {
@@ -320,98 +307,120 @@ const COMMANDS = {
320
307
  longDescription: "Verify your app's runtime behavior with Playwright-powered browser testing.",
321
308
  tier: "pro",
322
309
  category: "proof",
323
- aliases: ["browser", "e2e"],
324
310
  runner: () => require("./runners/runReality").runReality,
325
311
  examples: [
326
312
  { command: "vibecheck reality --url http://localhost:3000", description: "Test localhost" },
327
313
  { command: "vibecheck reality --auth email:pass", description: "With authentication" },
328
- { command: "vibecheck reality --agent", description: "AI agent testing" },
329
314
  ],
330
315
  related: ["prove", "ship"],
331
316
  },
332
317
 
333
- gate: {
334
- description: "CI/CD enforcement - fail builds on issues",
335
- longDescription: "Enforce quality gates in your CI/CD pipeline.",
318
+ prove: {
319
+ description: "Full proof loop with runtime verification",
320
+ longDescription: "Complete verification cycle: forge audit → reality → ship → fix loop.",
336
321
  tier: "pro",
337
- category: "automation",
338
- aliases: ["ci", "enforce"],
339
- runner: () => require("./runners/runGuard").runGate,
322
+ category: "proof",
323
+ runner: () => require("./runners/runProve").runProve,
340
324
  examples: [
341
- { command: "vibecheck gate", description: "Run CI gate check" },
342
- { command: "vibecheck gate --strict", description: "Strict mode" },
325
+ { command: "vibecheck prove", description: "Run full proof loop" },
326
+ { command: "vibecheck prove --url http://localhost:3000", description: "With runtime testing" },
343
327
  ],
344
- related: ["ship", "scan"],
328
+ related: ["ship", "reality"],
345
329
  },
346
330
 
347
- guard: {
348
- description: "AI guardrails - prompt firewall & hallucination checking",
349
- longDescription: "Validate AI-generated code and prompts. Detects prompt injection and verifies claims.",
331
+ ship: {
332
+ description: "Verdict engine - SHIP / WARN / BLOCK",
333
+ longDescription: "The final word on whether your code is ready to ship.",
350
334
  tier: "pro",
351
- category: "truth",
352
- aliases: ["ai-guard", "firewall", "validate"],
353
- runner: () => require("./runners/runGuard").runGuard,
335
+ category: "proof",
336
+ runner: () => require("./runners/runShip").runShip,
354
337
  examples: [
355
- { command: "vibecheck guard", description: "Run all guardrail checks" },
356
- { command: "vibecheck guard --claims", description: "Verify AI claims" },
338
+ { command: "vibecheck ship", description: "Get shipping verdict" },
339
+ { command: "vibecheck ship --strict", description: "Fail on warnings" },
357
340
  ],
358
- related: ["context", "fix"],
341
+ related: ["audit", "prove", "fix", "seal"],
359
342
  },
360
343
 
361
- mcp: {
362
- description: "Start MCP server for AI IDEs",
363
- longDescription: "Launch an MCP server for AI IDE integration.",
344
+ seal: {
345
+ description: "Generate ship badge and attestation",
346
+ longDescription: "Generate a ship status badge (SVG) and cryptographic attestation.",
364
347
  tier: "pro",
365
- category: "automation",
366
- aliases: [],
367
- runner: () => require("./runners/runMcp").runMcp,
348
+ category: "output",
349
+ runner: () => require("./runners/runShip").runSeal,
368
350
  examples: [
369
- { command: "vibecheck mcp", description: "Start MCP server" },
370
- { command: "vibecheck mcp --port 3099", description: "Custom port" },
351
+ { command: "vibecheck seal", description: "Generate status badge" },
352
+ { command: "vibecheck seal --format svg", description: "SVG badge" },
353
+ { command: "vibecheck seal --attest", description: "Include attestation" },
371
354
  ],
372
- related: ["context"],
355
+ related: ["ship", "packs"],
373
356
  },
374
357
 
375
- checkpoint: {
376
- description: "Compare baseline vs current, hallucination scoring",
377
- longDescription: "Track changes between scan runs. Detects new issues, resolved issues, and regressions.",
358
+ fix: {
359
+ description: "Mission-based auto-fix with safety gates (V2)",
360
+ longDescription: "Fix Missions V2 - 'Missions, not chaos'. Transform findings into small, reversible fix missions with pre-flight/post-flight safety gates, checkpoint-based rollback, and plan-only mode for trust building.",
378
361
  tier: "pro",
379
- category: "analysis",
380
- aliases: ["cp", "compare", "diff"],
381
- runner: () => require("./runners/runCheckpoint").runCheckpoint,
362
+ category: "proof",
363
+ runner: () => require("./runners/runFix").runFix,
382
364
  examples: [
383
- { command: "vibecheck checkpoint", description: "Compare against baseline" },
384
- { command: "vibecheck checkpoint --set", description: "Save new baseline" },
365
+ { command: "vibecheck fix", description: "Plan missions (no changes)" },
366
+ { command: "vibecheck fix --plan-only", description: "Full mission briefings with safety gates" },
367
+ { command: "vibecheck fix --prompt-only", description: "Generate LLM prompts only" },
368
+ { command: "vibecheck fix --apply", description: "Apply AI fixes with checkpoints" },
369
+ { command: "vibecheck fix --autopilot --apply", description: "Loop until SHIP or stuck" },
370
+ { command: "vibecheck fix --mission M_xxx", description: "Run specific mission" },
371
+ { command: "vibecheck fix --rollback M_xxx", description: "Rollback mission by ID" },
372
+ { command: "vibecheck fix --force", description: "Override safety gates" },
373
+ { command: "vibecheck fix --min-confidence 0.7", description: "Set confidence threshold" },
374
+ { command: "vibecheck fix --max-blast 5", description: "Limit blast radius" },
375
+ { command: "vibecheck fix --list-checkpoints", description: "List available checkpoints" },
385
376
  ],
386
- related: ["scan", "fix"],
377
+ related: ["audit", "ship", "checkpoint"],
387
378
  },
388
379
 
389
- approve: {
390
- description: "Authority verdicts - PROCEED/STOP/DEFER with proofs",
391
- longDescription: "Execute authorities to get structured verdicts with proofs.",
392
- tier: "pro",
393
- category: "authority",
394
- aliases: ["auth-verdict", "authority"],
395
- runner: () => require("./runners/runApprove").runApprove,
380
+ checkpoint: {
381
+ description: "⏱️ Time machine - snapshot & restore",
382
+ longDescription: "Checkpoint is the time machine. Create snapshots before risky actions, restore reliably. Auto-integrates with fix/polish/shield for fearless experimentation.",
383
+ tier: "free",
384
+ category: "proof",
385
+ runner: () => require("./runners/runCheckpoint").runCheckpoint,
396
386
  examples: [
397
- { command: "vibecheck approve safe-consolidation", description: "Run authority" },
398
- { command: "vibecheck approve --list", description: "List authorities" },
387
+ { command: "vibecheck checkpoint create 'Before refactor'", description: "Manual checkpoint" },
388
+ { command: "vibecheck checkpoint create --tag pre-fix", description: "Tagged checkpoint" },
389
+ { command: "vibecheck checkpoint list", description: "List all checkpoints" },
390
+ { command: "vibecheck checkpoint restore latest", description: "Restore most recent" },
391
+ { command: "vibecheck checkpoint restore pre-fix", description: "Restore by tag" },
392
+ { command: "vibecheck checkpoint restore latest --dry-run", description: "Preview restore" },
393
+ { command: "vibecheck checkpoint diff latest", description: "See changes since" },
394
+ { command: "vibecheck checkpoint prune --keep 5", description: "Keep 5 most recent" },
395
+ { command: "vibecheck checkpoint status", description: "Storage status" },
399
396
  ],
400
- related: ["classify", "ship"],
397
+ related: ["fix", "polish", "shield"],
401
398
  },
402
399
 
403
400
  polish: {
404
401
  description: "Production polish - final cleanup before deploy",
405
402
  longDescription: "Final production readiness checks and cleanup.",
406
403
  tier: "pro",
407
- category: "proof",
408
- aliases: ["prod", "final"],
404
+ category: "quality",
409
405
  runner: () => require("./runners/runPolish").runPolish,
410
406
  examples: [
411
407
  { command: "vibecheck polish", description: "Run polish checks" },
412
408
  ],
413
409
  related: ["ship", "prove"],
414
410
  },
411
+
412
+ mcp: {
413
+ description: "Start MCP server for AI IDEs",
414
+ longDescription: "Launch an MCP server for AI IDE integration.",
415
+ tier: "pro",
416
+ category: "automation",
417
+ runner: () => require("./runners/runMcp").runMcp,
418
+ examples: [
419
+ { command: "vibecheck mcp", description: "Start MCP server" },
420
+ { command: "vibecheck mcp --port 3099", description: "Custom port" },
421
+ ],
422
+ related: ["forge", "shield"],
423
+ },
415
424
  };
416
425
 
417
426
  // Validate that only allowed commands are defined
@@ -441,34 +450,12 @@ function getProCommands() {
441
450
  .map(([name]) => name);
442
451
  }
443
452
 
444
- // ─────────────────────────────────────────────────────────────
445
- // BUILD DERIVED DATA STRUCTURES
446
- // ─────────────────────────────────────────────────────────────
447
-
448
- // Build alias map: { alias -> command }
449
- const ALIAS_MAP = {};
450
- for (const [cmdName, cmd] of Object.entries(COMMANDS)) {
451
- if (cmd.aliases) {
452
- for (const alias of cmd.aliases) {
453
- ALIAS_MAP[alias] = cmdName;
454
- }
455
- }
456
- }
457
-
458
- // All command names including aliases
459
- const ALL_COMMANDS = new Set([
460
- ...Object.keys(COMMANDS),
461
- ...Object.keys(ALIAS_MAP),
462
- ]);
463
-
464
453
  // ─────────────────────────────────────────────────────────────
465
454
  // GETTERS
466
455
  // ─────────────────────────────────────────────────────────────
467
456
 
468
457
  function getRunner(cmd, opts = {}) {
469
- // Resolve alias to canonical command
470
- const canonicalCmd = ALIAS_MAP[cmd] || cmd;
471
- const def = COMMANDS[canonicalCmd];
458
+ const def = COMMANDS[cmd];
472
459
 
473
460
  if (!def) {
474
461
  return null;
@@ -482,29 +469,109 @@ function getRunner(cmd, opts = {}) {
482
469
  return def.runner();
483
470
  } catch (e) {
484
471
  if (opts.red && opts.reset) {
485
- console.error(`${opts.red}${opts.errorSymbol || '×'} Failed to load runner for ${cmd}: ${e.message}${opts.reset}`);
472
+ console.error(`${opts.red}× Failed to load runner for ${cmd}: ${e.message}${opts.reset}`);
486
473
  }
487
474
  return null;
488
475
  }
489
476
  }
490
477
 
491
478
  function getCommand(name) {
492
- // Check direct name
493
- if (COMMANDS[name]) return COMMANDS[name];
494
-
495
- // Check alias map
496
- const canonical = ALIAS_MAP[name];
497
- if (canonical && COMMANDS[canonical]) {
498
- return { ...COMMANDS[canonical], _resolvedFrom: name, _canonicalName: canonical };
499
- }
500
-
501
- return null;
479
+ return COMMANDS[name] || null;
502
480
  }
503
481
 
504
- function resolveCommand(name) {
505
- return ALIAS_MAP[name] || name;
482
+ function isValidCommand(name) {
483
+ return name in COMMANDS;
506
484
  }
507
485
 
486
+ function listCommands() {
487
+ return Object.keys(COMMANDS);
488
+ }
489
+
490
+ // ─────────────────────────────────────────────────────────────
491
+ // ALIAS MAP - Backwards compatibility for CLI
492
+ // ─────────────────────────────────────────────────────────────
493
+ // Note: The new registry uses canonical names only, but ALIAS_MAP
494
+ // is kept for backwards compatibility with vibecheck.js
495
+ const ALIAS_MAP = {
496
+ // Legacy aliases → canonical commands
497
+ "init": "link",
498
+ "setup": "link",
499
+ "configure": "link",
500
+ "quickstart": "kickoff",
501
+ "qs": "kickoff",
502
+ "start": "kickoff",
503
+ "onboard": "kickoff",
504
+ "health": "doctor",
505
+ "diag": "doctor",
506
+ "w": "watch",
507
+ "dev": "watch",
508
+ "scan": "audit",
509
+ "s": "audit",
510
+ "check": "audit",
511
+ "context": "forge",
512
+ "rules": "forge",
513
+ "ai-rules": "forge",
514
+ "mdc": "forge",
515
+ "ctx": "forge",
516
+ "brain": "forge",
517
+ "truthpack": "forge",
518
+ "login": "auth",
519
+ "logout": "auth",
520
+ "whoami": "auth",
521
+ "allowlist": "safelist",
522
+ "al": "safelist",
523
+ "suppress": "safelist",
524
+ "report": "packs",
525
+ "html": "packs",
526
+ "artifact": "packs",
527
+ "artifacts": "packs",
528
+ "evidence-pack": "packs",
529
+ "bundle": "packs",
530
+ "permissions-pack": "packs",
531
+ "proof-graph": "packs",
532
+ "gate": "launch",
533
+ "ci-gate": "launch",
534
+ "enforce": "launch",
535
+ "preflight": "launch",
536
+ "prelaunch": "launch",
537
+ "guard": "shield",
538
+ "ai-guard": "shield",
539
+ "firewall": "shield",
540
+ "validate": "shield",
541
+ "f": "fix",
542
+ "repair": "fix",
543
+ "missions": "fix",
544
+ "cp": "checkpoint",
545
+ "snap": "checkpoint",
546
+ "snapshot": "checkpoint",
547
+ "timemachine": "checkpoint",
548
+ "rollback": "checkpoint",
549
+ "p": "prove",
550
+ "verify": "prove",
551
+ "browser": "reality",
552
+ "e2e": "reality",
553
+ "cp": "checkpoint",
554
+ "compare": "checkpoint",
555
+ "diff": "checkpoint",
556
+ "prod": "polish",
557
+ "final": "polish",
558
+ "badge": "seal",
559
+ "attest": "seal",
560
+ // Auth aliases - top-level shortcuts
561
+ "login": "auth",
562
+ "logout": "auth",
563
+ "whoami": "auth",
564
+ "me": "auth",
565
+ "signin": "auth",
566
+ "signout": "auth",
567
+ };
568
+
569
+ // All command names including aliases
570
+ const ALL_COMMANDS = new Set([
571
+ ...Object.keys(COMMANDS),
572
+ ...Object.keys(ALIAS_MAP),
573
+ ]);
574
+
508
575
  // ─────────────────────────────────────────────────────────────
509
576
  // EXPORTS
510
577
  // ─────────────────────────────────────────────────────────────
@@ -524,8 +591,8 @@ module.exports = {
524
591
  // Getters
525
592
  getRunner,
526
593
  getCommand,
527
- resolveCommand,
528
- listCommands: () => Object.keys(COMMANDS),
594
+ isValidCommand,
595
+ listCommands,
529
596
 
530
597
  getCommandsByTier: (tier) =>
531
598
  Object.entries(COMMANDS)