@vibe-agent-toolkit/cli 0.2.0-rc.5 → 0.2.0-rc.7

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 (220) hide show
  1. package/README.md +4 -4
  2. package/dist/bin.js +41 -158
  3. package/dist/bin.js.map +1 -1
  4. package/dist/command-loaders.d.ts +2 -2
  5. package/dist/command-loaders.d.ts.map +1 -1
  6. package/dist/command-loaders.js +4 -2
  7. package/dist/command-loaders.js.map +1 -1
  8. package/dist/commands/ard/emit.d.ts +104 -0
  9. package/dist/commands/ard/emit.d.ts.map +1 -0
  10. package/dist/commands/ard/emit.js +223 -0
  11. package/dist/commands/ard/emit.js.map +1 -0
  12. package/dist/commands/ard/index.d.ts +12 -0
  13. package/dist/commands/ard/index.d.ts.map +1 -0
  14. package/dist/commands/ard/index.js +79 -0
  15. package/dist/commands/ard/index.js.map +1 -0
  16. package/dist/commands/ard/surfaces.d.ts +56 -0
  17. package/dist/commands/ard/surfaces.d.ts.map +1 -0
  18. package/dist/commands/ard/surfaces.js +150 -0
  19. package/dist/commands/ard/surfaces.js.map +1 -0
  20. package/dist/commands/audit.d.ts +75 -8
  21. package/dist/commands/audit.d.ts.map +1 -1
  22. package/dist/commands/audit.js +726 -127
  23. package/dist/commands/audit.js.map +1 -1
  24. package/dist/commands/claude/budget.d.ts +13 -0
  25. package/dist/commands/claude/budget.d.ts.map +1 -1
  26. package/dist/commands/claude/budget.js +80 -28
  27. package/dist/commands/claude/budget.js.map +1 -1
  28. package/dist/commands/claude/claude-config.d.ts.map +1 -1
  29. package/dist/commands/claude/claude-config.js +6 -0
  30. package/dist/commands/claude/claude-config.js.map +1 -1
  31. package/dist/commands/claude/context.js +1 -1
  32. package/dist/commands/claude/context.js.map +1 -1
  33. package/dist/commands/claude/marketplace/validate.d.ts +55 -22
  34. package/dist/commands/claude/marketplace/validate.d.ts.map +1 -1
  35. package/dist/commands/claude/marketplace/validate.js +380 -75
  36. package/dist/commands/claude/marketplace/validate.js.map +1 -1
  37. package/dist/commands/claude/org/helpers.d.ts +59 -1
  38. package/dist/commands/claude/org/helpers.d.ts.map +1 -1
  39. package/dist/commands/claude/org/helpers.js +58 -7
  40. package/dist/commands/claude/org/helpers.js.map +1 -1
  41. package/dist/commands/claude/org/index.d.ts.map +1 -1
  42. package/dist/commands/claude/org/index.js +24 -16
  43. package/dist/commands/claude/org/index.js.map +1 -1
  44. package/dist/commands/claude/org/skills.d.ts +509 -0
  45. package/dist/commands/claude/org/skills.d.ts.map +1 -1
  46. package/dist/commands/claude/org/skills.js +1364 -94
  47. package/dist/commands/claude/org/skills.js.map +1 -1
  48. package/dist/commands/claude/org/users.d.ts.map +1 -1
  49. package/dist/commands/claude/org/users.js +3 -1
  50. package/dist/commands/claude/org/users.js.map +1 -1
  51. package/dist/commands/claude/org/workspaces.d.ts.map +1 -1
  52. package/dist/commands/claude/org/workspaces.js +5 -2
  53. package/dist/commands/claude/org/workspaces.js.map +1 -1
  54. package/dist/commands/claude/plugin/build.d.ts +8 -0
  55. package/dist/commands/claude/plugin/build.d.ts.map +1 -1
  56. package/dist/commands/claude/plugin/build.js +16 -2
  57. package/dist/commands/claude/plugin/build.js.map +1 -1
  58. package/dist/commands/claude/plugin/tree-copy.d.ts +72 -0
  59. package/dist/commands/claude/plugin/tree-copy.d.ts.map +1 -1
  60. package/dist/commands/claude/plugin/tree-copy.js +215 -10
  61. package/dist/commands/claude/plugin/tree-copy.js.map +1 -1
  62. package/dist/commands/corpus/index.d.ts.map +1 -1
  63. package/dist/commands/corpus/index.js +3 -0
  64. package/dist/commands/corpus/index.js.map +1 -1
  65. package/dist/commands/corpus/report.d.ts +0 -1
  66. package/dist/commands/corpus/report.d.ts.map +1 -1
  67. package/dist/commands/corpus/report.js +0 -1
  68. package/dist/commands/corpus/report.js.map +1 -1
  69. package/dist/commands/corpus/runner.d.ts +58 -1
  70. package/dist/commands/corpus/runner.d.ts.map +1 -1
  71. package/dist/commands/corpus/runner.js +90 -15
  72. package/dist/commands/corpus/runner.js.map +1 -1
  73. package/dist/commands/corpus/scan.d.ts.map +1 -1
  74. package/dist/commands/corpus/scan.js +0 -1
  75. package/dist/commands/corpus/scan.js.map +1 -1
  76. package/dist/commands/doctor.d.ts +14 -0
  77. package/dist/commands/doctor.d.ts.map +1 -1
  78. package/dist/commands/doctor.js +96 -18
  79. package/dist/commands/doctor.js.map +1 -1
  80. package/dist/commands/okf/index.d.ts +11 -0
  81. package/dist/commands/okf/index.d.ts.map +1 -0
  82. package/dist/commands/okf/index.js +102 -0
  83. package/dist/commands/okf/index.js.map +1 -0
  84. package/dist/commands/okf/validate.d.ts +82 -0
  85. package/dist/commands/okf/validate.d.ts.map +1 -0
  86. package/dist/commands/okf/validate.js +157 -0
  87. package/dist/commands/okf/validate.js.map +1 -0
  88. package/dist/commands/phase-utils.d.ts +19 -3
  89. package/dist/commands/phase-utils.d.ts.map +1 -1
  90. package/dist/commands/phase-utils.js +26 -5
  91. package/dist/commands/phase-utils.js.map +1 -1
  92. package/dist/commands/rag/index-command.d.ts +27 -2
  93. package/dist/commands/rag/index-command.d.ts.map +1 -1
  94. package/dist/commands/rag/index-command.js +44 -7
  95. package/dist/commands/rag/index-command.js.map +1 -1
  96. package/dist/commands/rag/index.d.ts.map +1 -1
  97. package/dist/commands/rag/index.js +2 -0
  98. package/dist/commands/rag/index.js.map +1 -1
  99. package/dist/commands/resources/check-progress.d.ts +3 -0
  100. package/dist/commands/resources/check-progress.d.ts.map +1 -1
  101. package/dist/commands/resources/check-progress.js +6 -0
  102. package/dist/commands/resources/check-progress.js.map +1 -1
  103. package/dist/commands/resources/check.d.ts +33 -4
  104. package/dist/commands/resources/check.d.ts.map +1 -1
  105. package/dist/commands/resources/check.js +131 -44
  106. package/dist/commands/resources/check.js.map +1 -1
  107. package/dist/commands/resources/index.d.ts.map +1 -1
  108. package/dist/commands/resources/index.js +41 -9
  109. package/dist/commands/resources/index.js.map +1 -1
  110. package/dist/commands/resources/query.d.ts +18 -1
  111. package/dist/commands/resources/query.d.ts.map +1 -1
  112. package/dist/commands/resources/query.js +29 -4
  113. package/dist/commands/resources/query.js.map +1 -1
  114. package/dist/commands/resources/validate.d.ts +29 -0
  115. package/dist/commands/resources/validate.d.ts.map +1 -1
  116. package/dist/commands/resources/validate.js +116 -13
  117. package/dist/commands/resources/validate.js.map +1 -1
  118. package/dist/commands/skill/review-checklist.d.ts.map +1 -1
  119. package/dist/commands/skill/review-checklist.js +35 -0
  120. package/dist/commands/skill/review-checklist.js.map +1 -1
  121. package/dist/commands/skill/review.d.ts.map +1 -1
  122. package/dist/commands/skill/review.js +9 -2
  123. package/dist/commands/skill/review.js.map +1 -1
  124. package/dist/commands/skill/test/configure.d.ts +37 -0
  125. package/dist/commands/skill/test/configure.d.ts.map +1 -1
  126. package/dist/commands/skill/test/configure.js +57 -12
  127. package/dist/commands/skill/test/configure.js.map +1 -1
  128. package/dist/commands/skill/test/run.d.ts.map +1 -1
  129. package/dist/commands/skill/test/run.js +21 -6
  130. package/dist/commands/skill/test/run.js.map +1 -1
  131. package/dist/commands/skills/build.d.ts.map +1 -1
  132. package/dist/commands/skills/build.js +16 -3
  133. package/dist/commands/skills/build.js.map +1 -1
  134. package/dist/commands/skills/list.d.ts +2 -1
  135. package/dist/commands/skills/list.d.ts.map +1 -1
  136. package/dist/commands/skills/list.js +31 -9
  137. package/dist/commands/skills/list.js.map +1 -1
  138. package/dist/commands/skills/skill-discovery.d.ts +40 -1
  139. package/dist/commands/skills/skill-discovery.d.ts.map +1 -1
  140. package/dist/commands/skills/skill-discovery.js +32 -3
  141. package/dist/commands/skills/skill-discovery.js.map +1 -1
  142. package/dist/commands/skills/validate-command.d.ts.map +1 -1
  143. package/dist/commands/skills/validate-command.js +11 -3
  144. package/dist/commands/skills/validate-command.js.map +1 -1
  145. package/dist/commands/skills/validate.d.ts +66 -7
  146. package/dist/commands/skills/validate.d.ts.map +1 -1
  147. package/dist/commands/skills/validate.js +133 -29
  148. package/dist/commands/skills/validate.js.map +1 -1
  149. package/dist/commands/verify.d.ts +94 -3
  150. package/dist/commands/verify.d.ts.map +1 -1
  151. package/dist/commands/verify.js +192 -45
  152. package/dist/commands/verify.js.map +1 -1
  153. package/dist/skill-resolution/packaging-config.d.ts +49 -5
  154. package/dist/skill-resolution/packaging-config.d.ts.map +1 -1
  155. package/dist/skill-resolution/packaging-config.js +59 -19
  156. package/dist/skill-resolution/packaging-config.js.map +1 -1
  157. package/dist/skill-resolution/resolve-skill-reference.d.ts.map +1 -1
  158. package/dist/skill-resolution/resolve-skill-reference.js +6 -3
  159. package/dist/skill-resolution/resolve-skill-reference.js.map +1 -1
  160. package/dist/utils/command-error.d.ts +31 -0
  161. package/dist/utils/command-error.d.ts.map +1 -1
  162. package/dist/utils/command-error.js +45 -0
  163. package/dist/utils/command-error.js.map +1 -1
  164. package/dist/utils/config-loader.d.ts.map +1 -1
  165. package/dist/utils/config-loader.js +22 -6
  166. package/dist/utils/config-loader.js.map +1 -1
  167. package/dist/utils/edge-lens-evaluation.d.ts +83 -0
  168. package/dist/utils/edge-lens-evaluation.d.ts.map +1 -0
  169. package/dist/utils/edge-lens-evaluation.js +110 -0
  170. package/dist/utils/edge-lens-evaluation.js.map +1 -0
  171. package/dist/utils/optional-backend.d.ts +5 -4
  172. package/dist/utils/optional-backend.d.ts.map +1 -1
  173. package/dist/utils/optional-backend.js +5 -4
  174. package/dist/utils/optional-backend.js.map +1 -1
  175. package/dist/utils/project-root-policy.d.ts +20 -0
  176. package/dist/utils/project-root-policy.d.ts.map +1 -1
  177. package/dist/utils/project-root-policy.js +32 -0
  178. package/dist/utils/project-root-policy.js.map +1 -1
  179. package/dist/utils/projection-query.d.ts +41 -4
  180. package/dist/utils/projection-query.d.ts.map +1 -1
  181. package/dist/utils/projection-query.js +44 -10
  182. package/dist/utils/projection-query.js.map +1 -1
  183. package/dist/utils/projection-store.d.ts +41 -15
  184. package/dist/utils/projection-store.d.ts.map +1 -1
  185. package/dist/utils/projection-store.js +65 -18
  186. package/dist/utils/projection-store.js.map +1 -1
  187. package/dist/utils/repeatable-option.d.ts +37 -0
  188. package/dist/utils/repeatable-option.d.ts.map +1 -0
  189. package/dist/utils/repeatable-option.js +39 -0
  190. package/dist/utils/repeatable-option.js.map +1 -0
  191. package/dist/utils/resource-loader.d.ts +4 -3
  192. package/dist/utils/resource-loader.d.ts.map +1 -1
  193. package/dist/utils/resource-loader.js +61 -30
  194. package/dist/utils/resource-loader.js.map +1 -1
  195. package/dist/utils/root-argv.d.ts +53 -0
  196. package/dist/utils/root-argv.d.ts.map +1 -0
  197. package/dist/utils/root-argv.js +215 -0
  198. package/dist/utils/root-argv.js.map +1 -0
  199. package/dist/utils/run-integrity.d.ts +95 -0
  200. package/dist/utils/run-integrity.d.ts.map +1 -0
  201. package/dist/utils/run-integrity.js +102 -0
  202. package/dist/utils/run-integrity.js.map +1 -0
  203. package/dist/utils/sqlite-experimental-warning.d.ts +69 -0
  204. package/dist/utils/sqlite-experimental-warning.d.ts.map +1 -0
  205. package/dist/utils/sqlite-experimental-warning.js +144 -0
  206. package/dist/utils/sqlite-experimental-warning.js.map +1 -0
  207. package/dist/utils/user-context-scanner.d.ts +8 -0
  208. package/dist/utils/user-context-scanner.d.ts.map +1 -1
  209. package/dist/utils/user-context-scanner.js +4 -0
  210. package/dist/utils/user-context-scanner.js.map +1 -1
  211. package/dist/utils/validate-help-files.d.ts.map +1 -1
  212. package/dist/utils/validate-help-files.js +9 -2
  213. package/dist/utils/validate-help-files.js.map +1 -1
  214. package/docs/audit.md +120 -7
  215. package/docs/doctor.md +6 -6
  216. package/docs/index.md +1 -1
  217. package/docs/rag.md +3 -1
  218. package/docs/resources.md +5 -1
  219. package/docs/skills.md +47 -62
  220. package/package.json +18 -18
@@ -4,7 +4,7 @@
4
4
  * Discovers skills from config yaml skills.include/exclude, validates each
5
5
  * using validateSkillForPackaging with merged packaging config.
6
6
  */
7
- import { validateSkillForPackaging, } from '@vibe-agent-toolkit/agent-skills';
7
+ import { conventionalSuiteProbe, validateSkillForPackaging, } from '@vibe-agent-toolkit/agent-skills';
8
8
  import { ResourceRegistry, } from '@vibe-agent-toolkit/resources';
9
9
  import { allowUnusedIssues, calculateValidationStatus, countBySeverity, createAllowUsageLedger, } from '@vibe-agent-toolkit/schema';
10
10
  import { findProjectRoot, safePath } from '@vibe-agent-toolkit/utils';
@@ -16,6 +16,7 @@ import { formatDurationSecs } from '../../utils/duration.js';
16
16
  import { formatIssueLines, formatRunIssueLines, formatSeverityBreakdown, issuesToRenderAtVerbosity, summarizeFindings, sumSeverityCounts, } from '../../utils/issue-rendering.js';
17
17
  import { requireProjectRoot } from '../../utils/project-root-policy.js';
18
18
  import { RESOURCES_CRAWL_ENV, RESOURCES_CRAWL_PROJECTION, withResourcePopulationSource, } from '../../utils/resource-loader.js';
19
+ import { nothingCheckedFinding } from '../../utils/run-integrity.js';
19
20
  import { collectDeclaredEvalSuites, mergeSkillPackagingConfig } from '../../utils/skill-packaging-config.js';
20
21
  import { renderSkillQualityFooter } from '../../utils/skill-quality-footer.js';
21
22
  import { applyConfigVerdicts } from '../../utils/verdict-helpers.js';
@@ -32,6 +33,62 @@ import { discoverSkillsFromConfig } from './skill-discovery.js';
32
33
  function batchIssues(results) {
33
34
  return results.flatMap((r) => r.allErrors);
34
35
  }
36
+ /**
37
+ * The run-level findings, with the run-integrity refusal derived in front of
38
+ * them when the run validated no skill.
39
+ *
40
+ * 🚨 **Zero skills validated is an ERROR, not a clean run.** `skills.include`
41
+ * globs that discover nothing — a typo, a renamed directory, an `exclude` that
42
+ * swallows every match — used to take an early return that printed one info
43
+ * line and published NO document at exit 0, and `vat validate` folded that into
44
+ * `status: success`: the gate the docs name as THE gate, green forever on a
45
+ * config that checked nothing. `vat verify` refused the identical config in its
46
+ * `packaged-content` phase and its message sent the operator to this command,
47
+ * which then said nothing.
48
+ *
49
+ * 🔑 The ONE seam both channels read. {@link buildValidateSummary} (the
50
+ * document) and {@link formatValidationReportLines} (stderr) both derive their
51
+ * issue set here, so "denominator zero, status clean" is unrepresentable on
52
+ * either channel rather than merely unwritten, and the exit code — derived from
53
+ * the document's own counts — agrees with both by construction. Through the
54
+ * shared mechanism in `run-integrity.ts`: one non-overridable
55
+ * `RESOURCE_CHECK_BROKEN` at `error`.
56
+ *
57
+ * Only the empty GLOB is refused. A config with no `skills:` block at all is a
58
+ * choice — the project declares no skills — and both orchestrators already skip
59
+ * this phase on that config; the phase declines it the same way (no document,
60
+ * exit 0) rather than inventing a refusal for a gate nobody declared.
61
+ *
62
+ * @param results - One result per skill the run validated: the denominator
63
+ * @param runIssues - The run's own findings so far (`ALLOW_UNUSED`), so an
64
+ * existing run-integrity report is not duplicated
65
+ * @param patterns - The discovery globs, named in the refusal so the operator
66
+ * sees what matched nothing
67
+ * @returns The run-level issues the document and the stderr report publish
68
+ */
69
+ export function withRunIntegrity(results, runIssues, patterns) {
70
+ return [
71
+ ...nothingCheckedFinding(results.length, runIssues, () => nothingDiscoveredMessage(patterns)),
72
+ ...runIssues,
73
+ ];
74
+ }
75
+ /** The globs as an operator wrote them, back-quoted and comma-separated. */
76
+ function quoteGlobs(globs) {
77
+ return globs.map((glob) => `\`${glob}\``).join(', ');
78
+ }
79
+ /** What did not run, and what the operator can do — invariant 5 of `run-integrity.ts`. */
80
+ function nothingDiscoveredMessage(patterns) {
81
+ const include = quoteGlobs(patterns.include);
82
+ const exclude = patterns.exclude === undefined || patterns.exclude.length === 0
83
+ ? ''
84
+ : ` after \`skills.exclude\` (${quoteGlobs(patterns.exclude)})`;
85
+ return 'vat skills validate validated 0 skills, so this run is not a verdict: nothing was checked,'
86
+ + ' and the document reads the same as a run over clean skills. The `skills.include` globs in'
87
+ + ` vibe-agent-toolkit.config.yaml (${include}) matched no SKILL.md${exclude} — usually a typo`
88
+ + ' in the glob, a renamed directory, or an exclude that swallows every match. Fix the patterns'
89
+ + ' so they discover the skills this project ships, or remove the `skills:` block if it ships'
90
+ + ' none.';
91
+ }
35
92
  /**
36
93
  * One skill's VERBOSE YAML entry: the whole result plus the per-severity counts
37
94
  * its two-valued `status` cannot express.
@@ -114,12 +171,18 @@ function toSummaryYamlResult(result) {
114
171
  * zeros: `issueCounts` and `runIssueCounts` keep their complete
115
172
  * `{errors, warnings, info}` shape in both modes, because they are the
116
173
  * reconciliation identity rather than something a reader scans.
174
+ *
175
+ * A run over ZERO skills is refused here, not passed — see
176
+ * {@link withRunIntegrity}, which is why the discovery `patterns` are a
177
+ * parameter of a document builder: the refusal names the globs that matched
178
+ * nothing, and the builder is where the refusal is derived.
117
179
  */
118
- export function buildValidateSummary(results, duration, verbose, runIssues) {
180
+ export function buildValidateSummary(results, duration, verbose, runIssues, patterns) {
119
181
  const skillIssues = batchIssues(results);
120
- const runIssueCounts = countBySeverity(runIssues);
182
+ const published = withRunIntegrity(results, runIssues, patterns);
183
+ const runIssueCounts = countBySeverity(published);
121
184
  return {
122
- status: calculateValidationStatus([...skillIssues, ...runIssues]),
185
+ status: calculateValidationStatus([...skillIssues, ...published]),
123
186
  issueCounts: sumSeverityCounts([countBySeverity(skillIssues), runIssueCounts]),
124
187
  runIssueCounts,
125
188
  // `skillsValidated` stays the true denominator even though the default
@@ -139,7 +202,7 @@ export function buildValidateSummary(results, duration, verbose, runIssues) {
139
202
  results: verbose
140
203
  ? results.map((r) => toVerboseYamlResult(r))
141
204
  : results.filter((r) => hasFindings(r)).map((r) => toSummaryYamlResult(r)),
142
- runIssues: [...runIssues],
205
+ runIssues: published,
143
206
  durationSecs: formatDurationSecs(duration),
144
207
  };
145
208
  }
@@ -261,9 +324,14 @@ function reportBanner(status, counts) {
261
324
  * Run-level findings and the banner are printed in full either way — there are
262
325
  * ~14 of the former, and they belong to the project config rather than to any
263
326
  * asset, so there is no row for them to collapse into.
327
+ *
328
+ * Reads the same seam as the document builder ({@link withRunIntegrity}), so a
329
+ * run over zero skills prints the refusal here too rather than a green banner
330
+ * over a document that says `error`.
264
331
  */
265
- export function formatValidationReportLines(results, runIssues, verbose) {
266
- const issues = [...batchIssues(results), ...runIssues];
332
+ export function formatValidationReportLines(results, runIssues, verbose, patterns) {
333
+ const published = withRunIntegrity(results, runIssues, patterns);
334
+ const issues = [...batchIssues(results), ...published];
267
335
  const counts = countBySeverity(issues);
268
336
  const status = calculateValidationStatus(issues);
269
337
  const lines = [reportBanner(status, counts)];
@@ -272,7 +340,7 @@ export function formatValidationReportLines(results, runIssues, verbose) {
272
340
  continue;
273
341
  lines.push(...skillReportLines(result, verbose));
274
342
  }
275
- const runLines = formatRunIssueLines(runIssues);
343
+ const runLines = formatRunIssueLines(published);
276
344
  if (runLines.length > 0) {
277
345
  lines.push(...runLines, '');
278
346
  }
@@ -281,7 +349,7 @@ export function formatValidationReportLines(results, runIssues, verbose) {
281
349
  /**
282
350
  * Output validation report to stdout (YAML) and stderr (human-readable)
283
351
  */
284
- function reportValidationToStderr(results, logger, verbose, runIssues) {
352
+ function reportValidationToStderr(results, logger, verbose, runIssues, patterns) {
285
353
  // Collect all emitted codes across skills (both errors and warnings) to drive the footer
286
354
  const emittedCodes = new Set();
287
355
  for (const r of results) {
@@ -289,11 +357,11 @@ function reportValidationToStderr(results, logger, verbose, runIssues) {
289
357
  emittedCodes.add(issue.code);
290
358
  }
291
359
  }
292
- for (const issue of runIssues) {
360
+ for (const issue of withRunIntegrity(results, runIssues, patterns)) {
293
361
  emittedCodes.add(issue.code);
294
362
  }
295
363
  const hasSkillFindings = results.some((r) => calculateValidationStatus(r.allErrors) !== 'success');
296
- for (const line of formatValidationReportLines(results, runIssues, verbose)) {
364
+ for (const line of formatValidationReportLines(results, runIssues, verbose, patterns)) {
297
365
  logger.info(line);
298
366
  }
299
367
  renderSkillQualityFooter(logger, hasSkillFindings, emittedCodes);
@@ -346,6 +414,9 @@ export async function buildSkillsValidateRegistry(projectRoot, options = {}) {
346
414
  const registry = await ResourceRegistry.fromCrawl({
347
415
  baseDir: projectRoot,
348
416
  include: ['**/*.md'],
417
+ // `vat skills validate` acts on this registry as the whole population: a
418
+ // directory it cannot list refuses the run by name, exit 2.
419
+ unreadable: 'refuse',
349
420
  ...(populationSource !== undefined && { populationSource }),
350
421
  }, config === undefined ? undefined : { config });
351
422
  registry.resolveLinks();
@@ -357,11 +428,28 @@ export async function buildSharedValidationContext(skills, projectSkills, config
357
428
  // package and matched per skill, so only the batch can say an entry matched
358
429
  // nothing. Always present, so no early return can drop it.
359
430
  const allowLedger = createAllowUsageLedger();
431
+ // The RUN's conventional-suite probe, and it belongs beside the ledger rather
432
+ // than with the two optimizations below: resolving a skill's test input probes
433
+ // `<skill-root>/evals/evals.json` for the subject AND for every entry in
434
+ // `projectSkills`, so a probe minted per skill asks S questions per skill and
435
+ // S² per run about the same S paths. Measured with the lab on a 103-skill
436
+ // adopter: 10,815 probes over 103 distinct paths, half the command's entire
437
+ // filesystem traffic; with the run's probe threaded, ~103.
438
+ //
439
+ // Created here, once, and handed to every skill in the batch — that is the
440
+ // whole contract of `SkillValidationSharedContext.suiteProbe`, whose fallback
441
+ // (`?? conventionalSuiteProbe()`) treats an omitting caller as claiming ITS
442
+ // call is the whole run. This lane loops, so omitting it made that claim
443
+ // falsely and silently.
444
+ //
445
+ // NOT module-scoped: the answer is a filesystem snapshot, and a cache
446
+ // outliving the run keeps answering for a tree that has since changed.
447
+ const suiteProbe = conventionalSuiteProbe();
360
448
  // Likewise not an optimization: the test-input rule is project-wide, so this
361
449
  // lane must model a bundle that excludes EVERY declared suite, not just the
362
450
  // subject's. Present even for an empty batch, so no early return can drop it.
363
451
  if (skills.length === 0) {
364
- return { allowLedger, projectSkills };
452
+ return { allowLedger, projectSkills, suiteProbe, unreadable: 'refuse' };
365
453
  }
366
454
  const projectRoots = new Set();
367
455
  const gitRoots = new Set();
@@ -379,7 +467,7 @@ export async function buildSharedValidationContext(skills, projectSkills, config
379
467
  gitRoots.add(safePath.resolve(gitRoot));
380
468
  }
381
469
  }
382
- const context = { allowLedger, projectSkills };
470
+ const context = { allowLedger, projectSkills, suiteProbe, unreadable: 'refuse' };
383
471
  // One tracker per repo; when the batch spans repos, skip rather than spawn
384
472
  // multiple `git ls-files`.
385
473
  //
@@ -441,10 +529,20 @@ export async function buildSharedValidationContext(skills, projectSkills, config
441
529
  * Validate every configured skill and hand back the document and exit code,
442
530
  * printing the document nowhere.
443
531
  *
444
- * The phase entry point for `vat validate` and `vat verify`. The two early
445
- * returns publish NO document — an unconfigured or empty run prints nothing on
446
- * stdout and exits 0, exactly as the child process did, and
447
- * `phaseResultFromOutcome` records that as `success` with no `report`.
532
+ * The phase entry point for `vat validate` and `vat verify`. The one early
533
+ * return publishes NO document: a config with no `skills:` block prints one
534
+ * info line, exits 0, and `phaseResultFromOutcome` records that as `success`
535
+ * with no `report` — both orchestrators skip the phase on that config anyway,
536
+ * because declaring no skills is a choice.
537
+ *
538
+ * A `skills:` block whose globs discover nothing is NOT a second early return.
539
+ * It used to be — one info line, no document, exit 0 — and that made `vat
540
+ * validate` green forever on a typo'd glob. It now runs through the same
541
+ * builder as a populated batch, which refuses a zero denominator (see
542
+ * {@link withRunIntegrity}): a document with one `RESOURCE_CHECK_BROKEN` at
543
+ * `error`, `status: error`, exit 1. Exit 1 and not 2, deliberately: the run
544
+ * completed and the gate FAILED, which is the class an operator's CI already
545
+ * handles; 2 is for a run that could not answer at all.
448
546
  */
449
547
  export async function runSkillsValidatePhase(pathArg, options) {
450
548
  const { logger, cwd, startTime } = setupCommandContext(pathArg, options.debug);
@@ -460,12 +558,14 @@ export async function runSkillsValidatePhase(pathArg, options) {
460
558
  logger.info('No skills section in config yaml — nothing to validate');
461
559
  return { document: undefined, exitCode: 0 };
462
560
  }
463
- // Discover skills from config yaml (relative to cwd where config lives)
464
- const discovered = await discoverSkillsFromConfig(config.skills, cwd);
465
- if (discovered.length === 0) {
466
- logger.info('ℹ️ No skills found matching config yaml skills.include patterns');
467
- return { document: undefined, exitCode: 0 };
468
- }
561
+ // Discover skills from config yaml (relative to cwd where config lives).
562
+ // `'refuse'`: one fewer skill at exit 0 is the drop this command must not
563
+ // make. The throw lands in the catch below → `reportCommandError`, exit 2.
564
+ const discovered = await discoverSkillsFromConfig(config.skills, cwd, 'refuse');
565
+ // No early return on `discovered.length === 0` — see the function comment.
566
+ // The empty batch flows through every step below unchanged: the shared
567
+ // context is built for zero skills (its ledger and probe exist regardless),
568
+ // the loop runs zero times, and the builder refuses the zero denominator.
469
569
  // Merge packaging config for each skill.
470
570
  const { defaults, config: perSkillConfig } = config.skills;
471
571
  const validatableSkills = discovered.map(skill => ({
@@ -504,11 +604,13 @@ export async function runSkillsValidatePhase(pathArg, options) {
504
604
  : allowUnusedIssues(sharedContext.allowLedger);
505
605
  const duration = Date.now() - startTime;
506
606
  const verbose = options.verbose === true;
507
- const document = buildValidateSummary(results, duration, verbose, runIssues);
508
- reportValidationToStderr(results, logger, verbose, runIssues);
509
- const hasErrors = results.some(r => r.status === 'error')
510
- || runIssues.some(i => i.severity === 'error');
511
- return { document, exitCode: hasErrors ? 1 : 0 };
607
+ const document = buildValidateSummary(results, duration, verbose, runIssues, config.skills);
608
+ reportValidationToStderr(results, logger, verbose, runIssues, config.skills);
609
+ // The exit code is read off the DOCUMENT, not recomputed beside it, so the
610
+ // two cannot disagree: whatever the builder refused, the process refuses.
611
+ // `issueCounts.errors` counts an active error on any skill and every
612
+ // run-level error alike — including the zero-denominator refusal.
613
+ return { document, exitCode: document.issueCounts.errors > 0 ? 1 : 0 };
512
614
  }
513
615
  catch (error) {
514
616
  return {
@@ -522,8 +624,10 @@ export async function runSkillsValidatePhase(pathArg, options) {
522
624
  * Skills validate command implementation
523
625
  */
524
626
  export async function validateCommand(pathArg, options) {
627
+ // `undefined`: this command offers no `--format`, so its failure envelope is
628
+ // YAML like its report.
525
629
  finishCommand(await runSkillsValidatePhase(pathArg, options), (document) => {
526
630
  writeYamlSummary(document);
527
- });
631
+ }, undefined);
528
632
  }
529
633
  //# sourceMappingURL=validate.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"validate.js","sourceRoot":"","sources":["../../../src/commands/skills/validate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zC,MAAM,QAAQ,GAAG,oBAAoB,CAAC,OAAO,EAAE,QAAQ,EAAE,OAAO,EAAE,SAAS,EAAE,MAAM,CAAC,MAAM,CAAC,CAAC;QAC5F,wBAAwB,CAAC,OAAO,EAAE,MAAM,EAAE,OAAO,EAAE,SAAS,EAAE,MAAM,CAAC,MAAM,CAAC,CAAC;QAE7E,2EAA2E;QAC3E,0EAA0E;QAC1E,qEAAqE;QACrE,kEAAkE;QAClE,OAAO,EAAE,QAAQ,EAAE,QAAQ,EAAE,QAAQ,CAAC,WAAW,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC;IACzE,CAAC;IAAC,OAAO,KAAK,EAAE,CAAC;QACf,OAAO;YACL,QAAQ,EAAE,kBAAkB,CAAC,KAAK,EAAE,MAAM,EAAE,SAAS,EAAE,gBAAgB,CAAC;YACxE,QAAQ,EAAE,CAAC;YACX,MAAM,EAAE,IAAI;SACb,CAAC;IACJ,CAAC;AACH,CAAC;AAED;;GAEG;AACH,MAAM,CAAC,KAAK,UAAU,eAAe,CACnC,OAA2B,EAC3B,OAAqC;IAErC,6EAA6E;IAC7E,wBAAwB;IACxB,aAAa,CAAC,MAAM,sBAAsB,CAAC,OAAO,EAAE,OAAO,CAAC,EAAE,CAAC,QAAQ,EAAE,EAAE;QACzE,gBAAgB,CAAC,QAAmD,CAAC,CAAC;IACxE,CAAC,EAAE,SAAS,CAAC,CAAC;AAChB,CAAC"}
@@ -15,10 +15,11 @@
15
15
  * Both sets are config-gated, and both are announced on startup.
16
16
  */
17
17
  import type { ProjectConfig } from '@vibe-agent-toolkit/resources';
18
- import { type ValidationIssue } from '@vibe-agent-toolkit/schema';
18
+ import { type SeverityCounts, type ValidationIssue } from '@vibe-agent-toolkit/schema';
19
19
  import { Command } from 'commander';
20
+ import type { createLogger } from '../utils/logger.js';
20
21
  import { type ConsistencyIssueSeverity } from './consistency-check.js';
21
- import { type PhaseSelection } from './phase-utils.js';
22
+ import { type PhaseResult, type PhaseSelection } from './phase-utils.js';
22
23
  import type { DiscoveredSkill } from './skills/command-helpers.js';
23
24
  export interface VerifyCommandOptions {
24
25
  /** Retired; declared only so {@link rejectRetiredOnly} can explain the removal. */
@@ -82,10 +83,32 @@ export declare function checkFilesConfigDests(cwd: string, discovered: readonly
82
83
  *
83
84
  * Locations anchor at `cwd`, the run's stated root, so a reader can open them.
84
85
  *
86
+ * Returns the count of bundles crawled beside the findings, because the phase
87
+ * that publishes them needs the denominator: zero findings over zero bundles is
88
+ * not a pass — see {@link buildPackagedContentPhase}.
89
+ *
85
90
  * @param discovered - The skills this run discovered from `skills.include`. See
86
91
  * {@link collectBuiltSkillOutputs} for why it is required rather than optional.
87
92
  */
88
- export declare function checkPackagedAgentInstructionFiles(cwd: string, discovered: readonly DiscoveredSkill[]): ValidationIssue[];
93
+ export declare function checkPackagedAgentInstructionFiles(cwd: string, discovered: readonly DiscoveredSkill[]): PackagedContentCrawl;
94
+ /**
95
+ * What the packaged-content crawl found, over how many bundles, and how many
96
+ * it should have found.
97
+ *
98
+ * `bundlesInspected` can exceed `bundlesExpected`: a bundle sitting in `dist/`
99
+ * for a `skills.config` key discovery no longer reaches is inspected (it is
100
+ * distributed output) but not expected (nothing in this run builds it). It can
101
+ * fall short of it only by the bundles named in `bundlesMissing`.
102
+ */
103
+ export interface PackagedContentCrawl {
104
+ /** Built bundles that EXIST on disk and were crawled — the phase's denominator. */
105
+ bundlesInspected: number;
106
+ /** Bundles `vat build` produces for this run's discovered skills — what the denominator should be. */
107
+ bundlesExpected: number;
108
+ /** Expected bundles absent from disk, as `cwd`-relative paths. Non-empty means the phase is not a verdict. */
109
+ bundlesMissing: string[];
110
+ issues: ValidationIssue[];
111
+ }
89
112
  /**
90
113
  * Decide which verification phases to run.
91
114
  *
@@ -140,5 +163,73 @@ interface PublishedIssue {
140
163
  * and stderr is not the document a CI consumer parses.
141
164
  */
142
165
  export declare function toPublishedIssue(issue: ValidationIssue): PublishedIssue;
166
+ /**
167
+ * A phase result that carries its own findings into the archived YAML.
168
+ *
169
+ * Extends {@link PhaseResult} rather than widening it: only verify's own phases
170
+ * hold findings — a delegated phase's findings belong to (and are printed by)
171
+ * the command it delegates to, inside the report nested under `report`.
172
+ */
173
+ interface FindingsPhaseResult extends PhaseResult {
174
+ issueCounts: SeverityCounts;
175
+ issues: PublishedIssue[];
176
+ }
177
+ /**
178
+ * The `packaged-content` phase's result: its findings, the count they are
179
+ * over, and the count they should have been over — see {@link PackagedContentCrawl}.
180
+ */
181
+ export interface PackagedContentPhaseResult extends FindingsPhaseResult {
182
+ bundlesInspected: number;
183
+ bundlesExpected: number;
184
+ bundlesMissing: string[];
185
+ }
186
+ /**
187
+ * Build the `packaged-content` phase result from what the crawl found.
188
+ *
189
+ * 🚨 **Zero bundles is an ERROR, not a clean phase — and so is a MISSING one.**
190
+ * The phase is pushed unconditionally whenever `skills:` exists and it feeds the
191
+ * real exit code; `discoverSkillsFromConfig` returning `[]` on a typo'd glob —
192
+ * or `dist/` not having been built at all, or built somewhere else — gave the
193
+ * crawl nothing to walk, and nothing walked was zero findings was `success`,
194
+ * with no count in the document to say the phase had looked at nothing. `vat
195
+ * verify` exists to check the BUILT tree; a run that found none of it is not a
196
+ * verdict on it. Nor is a run that found half of it: with `bundlesInspected` as
197
+ * the only denominator, two discovered skills and one deleted bundle published
198
+ * `success` beside `bundlesInspected: 1`. The crawl now also carries what it
199
+ * should have found, and the document publishes both counts.
200
+ *
201
+ * Derived here, in the one function that produces this phase's document, and
202
+ * not in the command body, so no path through the orchestrator can publish
203
+ * `status: success` beside `bundlesInspected: 0` or beside a non-empty
204
+ * `bundlesMissing`. Through the shared mechanism in `run-integrity.ts`: one
205
+ * non-overridable `RESOURCE_CHECK_BROKEN` at `error`, which
206
+ * {@link exitCodeForPhases} then turns into exit 1. ONE, not two, when both
207
+ * apply: the missing-bundle refusal is derived first because it names paths,
208
+ * and {@link nothingCheckedFinding} stands down behind an existing
209
+ * run-integrity finding.
210
+ *
211
+ * Pure, and exported so the refusal is pinned without a project on disk.
212
+ */
213
+ export declare function buildPackagedContentPhase(crawl: PackagedContentCrawl): PackagedContentPhaseResult;
214
+ /**
215
+ * Run the `packaged-content` phase: crawl, derive the phase document, and
216
+ * report THAT document's issues on stderr.
217
+ *
218
+ * 🚨 **The stderr report used to be gated on the crawl, one line before the
219
+ * refusal was derived.** `if (crawl.issues.length > 0) report(crawl.issues)`
220
+ * ran ahead of {@link buildPackagedContentPhase}, which is where the
221
+ * zero-bundle refusal is added — so on an unbuilt project the crawl found
222
+ * nothing, nothing was logged, the skills phase's `✅ All validations passed`
223
+ * stayed the last line on stderr, and the process exited 1 on a refusal that
224
+ * existed only in the YAML. Reporting from the phase result makes what stderr
225
+ * says and what the exit code is computed from one list, which is
226
+ * `run-integrity.ts` invariant 6.
227
+ *
228
+ * The round trip through `asValidationIssues` is deliberate rather than
229
+ * reporting the crawl's list plus a second derivation of the refusal: the
230
+ * document is the artifact of record, and stderr should render exactly what it
231
+ * carries, not a parallel computation that can drift from it.
232
+ */
233
+ export declare function runPackagedContentPhase(projectRoot: string, discoveredSkills: readonly DiscoveredSkill[], logger: ReturnType<typeof createLogger>): PackagedContentPhaseResult;
143
234
  export {};
144
235
  //# sourceMappingURL=verify.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"verify.d.ts","sourceRoot":"","sources":["../../src/commands/verify.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AAWH,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,+BAA+B,CAAC;AACnE,OAAO,EAIL,KAAK,eAAe,EACrB,MAAM,4BAA4B,CAAC;AAEpC,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAYpC,OAAO,EAGL,KAAK,wBAAwB,EAC9B,MAAM,wBAAwB,CAAC;AAChC,OAAO,EAWL,KAAK,cAAc,EAEpB,MAAM,kBAAkB,CAAC;AAG1B,OAAO,KAAK,EAAE,e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