@vibe-agent-toolkit/cli 0.2.0-rc.11 → 0.2.0-rc.12

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 (755) hide show
  1. package/README.md +3 -3
  2. package/dist/bin/supervise-cli.d.ts +45 -0
  3. package/dist/bin/supervise-cli.d.ts.map +1 -0
  4. package/dist/bin/supervise-cli.js +83 -0
  5. package/dist/bin/supervise-cli.js.map +1 -0
  6. package/dist/bin/vat +95 -43
  7. package/dist/bin/vat.d.ts +15 -4
  8. package/dist/bin/vat.d.ts.map +1 -1
  9. package/dist/bin/vat.js +95 -43
  10. package/dist/bin/vat.js.map +1 -1
  11. package/dist/bin.js +21 -29
  12. package/dist/bin.js.map +1 -1
  13. package/dist/command-tree.d.ts +45 -0
  14. package/dist/command-tree.d.ts.map +1 -0
  15. package/dist/command-tree.js +60 -0
  16. package/dist/command-tree.js.map +1 -0
  17. package/dist/commands/agent/build-schema.d.ts +100 -0
  18. package/dist/commands/agent/build-schema.d.ts.map +1 -0
  19. package/dist/commands/agent/build-schema.js +32 -0
  20. package/dist/commands/agent/build-schema.js.map +1 -0
  21. package/dist/commands/agent/build.d.ts +1 -0
  22. package/dist/commands/agent/build.d.ts.map +1 -1
  23. package/dist/commands/agent/build.js +63 -33
  24. package/dist/commands/agent/build.js.map +1 -1
  25. package/dist/commands/agent/import-schema.d.ts +75 -0
  26. package/dist/commands/agent/import-schema.d.ts.map +1 -0
  27. package/dist/commands/agent/import-schema.js +25 -0
  28. package/dist/commands/agent/import-schema.js.map +1 -0
  29. package/dist/commands/agent/import.d.ts.map +1 -1
  30. package/dist/commands/agent/import.js +33 -27
  31. package/dist/commands/agent/import.js.map +1 -1
  32. package/dist/commands/agent/index.d.ts.map +1 -1
  33. package/dist/commands/agent/index.js +132 -37
  34. package/dist/commands/agent/index.js.map +1 -1
  35. package/dist/commands/agent/install-path.d.ts.map +1 -1
  36. package/dist/commands/agent/install-path.js +2 -1
  37. package/dist/commands/agent/install-path.js.map +1 -1
  38. package/dist/commands/agent/install-schema.d.ts +89 -0
  39. package/dist/commands/agent/install-schema.d.ts.map +1 -0
  40. package/dist/commands/agent/install-schema.js +29 -0
  41. package/dist/commands/agent/install-schema.js.map +1 -0
  42. package/dist/commands/agent/install.d.ts +7 -1
  43. package/dist/commands/agent/install.d.ts.map +1 -1
  44. package/dist/commands/agent/install.js +78 -108
  45. package/dist/commands/agent/install.js.map +1 -1
  46. package/dist/commands/agent/installed-schema.d.ts +140 -0
  47. package/dist/commands/agent/installed-schema.d.ts.map +1 -0
  48. package/dist/commands/agent/installed-schema.js +36 -0
  49. package/dist/commands/agent/installed-schema.js.map +1 -0
  50. package/dist/commands/agent/installed.d.ts +1 -1
  51. package/dist/commands/agent/installed.d.ts.map +1 -1
  52. package/dist/commands/agent/installed.js +104 -75
  53. package/dist/commands/agent/installed.js.map +1 -1
  54. package/dist/commands/agent/list-schema.d.ts +128 -0
  55. package/dist/commands/agent/list-schema.d.ts.map +1 -0
  56. package/dist/commands/agent/list-schema.js +34 -0
  57. package/dist/commands/agent/list-schema.js.map +1 -0
  58. package/dist/commands/agent/list.d.ts +4 -3
  59. package/dist/commands/agent/list.d.ts.map +1 -1
  60. package/dist/commands/agent/list.js +50 -37
  61. package/dist/commands/agent/list.js.map +1 -1
  62. package/dist/commands/agent/run.d.ts +3 -0
  63. package/dist/commands/agent/run.d.ts.map +1 -1
  64. package/dist/commands/agent/run.js +8 -3
  65. package/dist/commands/agent/run.js.map +1 -1
  66. package/dist/commands/agent/uninstall-schema.d.ts +89 -0
  67. package/dist/commands/agent/uninstall-schema.d.ts.map +1 -0
  68. package/dist/commands/agent/uninstall-schema.js +29 -0
  69. package/dist/commands/agent/uninstall-schema.js.map +1 -0
  70. package/dist/commands/agent/uninstall.d.ts +5 -1
  71. package/dist/commands/agent/uninstall.d.ts.map +1 -1
  72. package/dist/commands/agent/uninstall.js +50 -38
  73. package/dist/commands/agent/uninstall.js.map +1 -1
  74. package/dist/commands/agent/validate-schema.d.ts +129 -0
  75. package/dist/commands/agent/validate-schema.d.ts.map +1 -0
  76. package/dist/commands/agent/validate-schema.js +35 -0
  77. package/dist/commands/agent/validate-schema.js.map +1 -0
  78. package/dist/commands/agent/validate.d.ts +6 -0
  79. package/dist/commands/agent/validate.d.ts.map +1 -1
  80. package/dist/commands/agent/validate.js +64 -36
  81. package/dist/commands/agent/validate.js.map +1 -1
  82. package/dist/commands/ard/emit-schema.d.ts +108 -0
  83. package/dist/commands/ard/emit-schema.d.ts.map +1 -0
  84. package/dist/commands/ard/emit-schema.js +37 -0
  85. package/dist/commands/ard/emit-schema.js.map +1 -0
  86. package/dist/commands/ard/emit.d.ts +21 -65
  87. package/dist/commands/ard/emit.d.ts.map +1 -1
  88. package/dist/commands/ard/emit.js +68 -74
  89. package/dist/commands/ard/emit.js.map +1 -1
  90. package/dist/commands/ard/index.d.ts.map +1 -1
  91. package/dist/commands/ard/index.js +14 -11
  92. package/dist/commands/ard/index.js.map +1 -1
  93. package/dist/commands/audit/compat-lane-findings.d.ts +65 -0
  94. package/dist/commands/audit/compat-lane-findings.d.ts.map +1 -0
  95. package/dist/commands/audit/compat-lane-findings.js +72 -0
  96. package/dist/commands/audit/compat-lane-findings.js.map +1 -0
  97. package/dist/commands/audit/distributed-tree.d.ts +2 -2
  98. package/dist/commands/audit/distributed-tree.d.ts.map +1 -1
  99. package/dist/commands/audit/distributed-tree.js +23 -12
  100. package/dist/commands/audit/distributed-tree.js.map +1 -1
  101. package/dist/commands/audit/git-url-clone.d.ts +15 -7
  102. package/dist/commands/audit/git-url-clone.d.ts.map +1 -1
  103. package/dist/commands/audit/git-url-clone.js +85 -42
  104. package/dist/commands/audit/git-url-clone.js.map +1 -1
  105. package/dist/commands/audit/hierarchical-output.d.ts +28 -4
  106. package/dist/commands/audit/hierarchical-output.d.ts.map +1 -1
  107. package/dist/commands/audit/hierarchical-output.js +44 -27
  108. package/dist/commands/audit/hierarchical-output.js.map +1 -1
  109. package/dist/commands/audit/scan-population.d.ts.map +1 -1
  110. package/dist/commands/audit/scan-population.js +2 -1
  111. package/dist/commands/audit/scan-population.js.map +1 -1
  112. package/dist/commands/audit-schema.d.ts +1247 -0
  113. package/dist/commands/audit-schema.d.ts.map +1 -0
  114. package/dist/commands/audit-schema.js +139 -0
  115. package/dist/commands/audit-schema.js.map +1 -0
  116. package/dist/commands/audit-settings-schema.d.ts +417 -0
  117. package/dist/commands/audit-settings-schema.d.ts.map +1 -0
  118. package/dist/commands/audit-settings-schema.js +77 -0
  119. package/dist/commands/audit-settings-schema.js.map +1 -0
  120. package/dist/commands/audit-settings.d.ts +28 -9
  121. package/dist/commands/audit-settings.d.ts.map +1 -1
  122. package/dist/commands/audit-settings.js +215 -151
  123. package/dist/commands/audit-settings.js.map +1 -1
  124. package/dist/commands/audit.d.ts +72 -33
  125. package/dist/commands/audit.d.ts.map +1 -1
  126. package/dist/commands/audit.js +405 -411
  127. package/dist/commands/audit.js.map +1 -1
  128. package/dist/commands/build.d.ts +61 -4
  129. package/dist/commands/build.d.ts.map +1 -1
  130. package/dist/commands/build.js +176 -190
  131. package/dist/commands/build.js.map +1 -1
  132. package/dist/commands/cache/clear-schema.d.ts +111 -0
  133. package/dist/commands/cache/clear-schema.d.ts.map +1 -0
  134. package/dist/commands/cache/clear-schema.js +37 -0
  135. package/dist/commands/cache/clear-schema.js.map +1 -0
  136. package/dist/commands/cache/clear.d.ts +28 -26
  137. package/dist/commands/cache/clear.d.ts.map +1 -1
  138. package/dist/commands/cache/clear.js +108 -103
  139. package/dist/commands/cache/clear.js.map +1 -1
  140. package/dist/commands/cache/index.d.ts.map +1 -1
  141. package/dist/commands/cache/index.js +13 -7
  142. package/dist/commands/cache/index.js.map +1 -1
  143. package/dist/commands/claude/claude-config.d.ts +23 -6
  144. package/dist/commands/claude/claude-config.d.ts.map +1 -1
  145. package/dist/commands/claude/claude-config.js +29 -15
  146. package/dist/commands/claude/claude-config.js.map +1 -1
  147. package/dist/commands/claude/context.d.ts +55 -2
  148. package/dist/commands/claude/context.d.ts.map +1 -1
  149. package/dist/commands/claude/context.js +74 -50
  150. package/dist/commands/claude/context.js.map +1 -1
  151. package/dist/commands/claude/marketplace/changelog-utils.js +2 -2
  152. package/dist/commands/claude/marketplace/changelog-utils.js.map +1 -1
  153. package/dist/commands/claude/marketplace/git-publish.d.ts +14 -1
  154. package/dist/commands/claude/marketplace/git-publish.d.ts.map +1 -1
  155. package/dist/commands/claude/marketplace/git-publish.js +135 -68
  156. package/dist/commands/claude/marketplace/git-publish.js.map +1 -1
  157. package/dist/commands/claude/marketplace/license-utils.d.ts +3 -5
  158. package/dist/commands/claude/marketplace/license-utils.d.ts.map +1 -1
  159. package/dist/commands/claude/marketplace/license-utils.js +16 -7
  160. package/dist/commands/claude/marketplace/license-utils.js.map +1 -1
  161. package/dist/commands/claude/marketplace/publish-schema.d.ts +137 -0
  162. package/dist/commands/claude/marketplace/publish-schema.d.ts.map +1 -0
  163. package/dist/commands/claude/marketplace/publish-schema.js +32 -0
  164. package/dist/commands/claude/marketplace/publish-schema.js.map +1 -0
  165. package/dist/commands/claude/marketplace/publish-tree.d.ts +6 -0
  166. package/dist/commands/claude/marketplace/publish-tree.d.ts.map +1 -1
  167. package/dist/commands/claude/marketplace/publish-tree.js +75 -17
  168. package/dist/commands/claude/marketplace/publish-tree.js.map +1 -1
  169. package/dist/commands/claude/marketplace/publish.d.ts +27 -0
  170. package/dist/commands/claude/marketplace/publish.d.ts.map +1 -1
  171. package/dist/commands/claude/marketplace/publish.js +84 -50
  172. package/dist/commands/claude/marketplace/publish.js.map +1 -1
  173. package/dist/commands/claude/marketplace/validate-schema.d.ts +362 -0
  174. package/dist/commands/claude/marketplace/validate-schema.d.ts.map +1 -0
  175. package/dist/commands/claude/marketplace/validate-schema.js +67 -0
  176. package/dist/commands/claude/marketplace/validate-schema.js.map +1 -0
  177. package/dist/commands/claude/marketplace/validate.d.ts +40 -53
  178. package/dist/commands/claude/marketplace/validate.d.ts.map +1 -1
  179. package/dist/commands/claude/marketplace/validate.js +358 -214
  180. package/dist/commands/claude/marketplace/validate.js.map +1 -1
  181. package/dist/commands/claude/org/api-keys.d.ts +3 -0
  182. package/dist/commands/claude/org/api-keys.d.ts.map +1 -1
  183. package/dist/commands/claude/org/api-keys.js +4 -5
  184. package/dist/commands/claude/org/api-keys.js.map +1 -1
  185. package/dist/commands/claude/org/code-analytics.js +1 -1
  186. package/dist/commands/claude/org/code-analytics.js.map +1 -1
  187. package/dist/commands/claude/org/cost.d.ts.map +1 -1
  188. package/dist/commands/claude/org/cost.js +11 -33
  189. package/dist/commands/claude/org/cost.js.map +1 -1
  190. package/dist/commands/claude/org/helpers.d.ts +40 -27
  191. package/dist/commands/claude/org/helpers.d.ts.map +1 -1
  192. package/dist/commands/claude/org/helpers.js +61 -66
  193. package/dist/commands/claude/org/helpers.js.map +1 -1
  194. package/dist/commands/claude/org/index.d.ts.map +1 -1
  195. package/dist/commands/claude/org/index.js +10 -4
  196. package/dist/commands/claude/org/index.js.map +1 -1
  197. package/dist/commands/claude/org/info.d.ts.map +1 -1
  198. package/dist/commands/claude/org/info.js +2 -3
  199. package/dist/commands/claude/org/info.js.map +1 -1
  200. package/dist/commands/claude/org/invites.d.ts +3 -0
  201. package/dist/commands/claude/org/invites.d.ts.map +1 -1
  202. package/dist/commands/claude/org/invites.js +5 -7
  203. package/dist/commands/claude/org/invites.js.map +1 -1
  204. package/dist/commands/claude/org/skills.d.ts +76 -21
  205. package/dist/commands/claude/org/skills.d.ts.map +1 -1
  206. package/dist/commands/claude/org/skills.js +273 -246
  207. package/dist/commands/claude/org/skills.js.map +1 -1
  208. package/dist/commands/claude/org/stubs-schema.d.ts +56 -0
  209. package/dist/commands/claude/org/stubs-schema.d.ts.map +1 -0
  210. package/dist/commands/claude/org/stubs-schema.js +23 -0
  211. package/dist/commands/claude/org/stubs-schema.js.map +1 -0
  212. package/dist/commands/claude/org/stubs.d.ts +8 -3
  213. package/dist/commands/claude/org/stubs.d.ts.map +1 -1
  214. package/dist/commands/claude/org/stubs.js +9 -9
  215. package/dist/commands/claude/org/stubs.js.map +1 -1
  216. package/dist/commands/claude/org/usage.d.ts.map +1 -1
  217. package/dist/commands/claude/org/usage.js +1 -2
  218. package/dist/commands/claude/org/usage.js.map +1 -1
  219. package/dist/commands/claude/org/users.d.ts +3 -0
  220. package/dist/commands/claude/org/users.d.ts.map +1 -1
  221. package/dist/commands/claude/org/users.js +6 -8
  222. package/dist/commands/claude/org/users.js.map +1 -1
  223. package/dist/commands/claude/org/workspaces.d.ts +3 -0
  224. package/dist/commands/claude/org/workspaces.d.ts.map +1 -1
  225. package/dist/commands/claude/org/workspaces.js +10 -15
  226. package/dist/commands/claude/org/workspaces.js.map +1 -1
  227. package/dist/commands/claude/plugin/build-schema.d.ts +642 -0
  228. package/dist/commands/claude/plugin/build-schema.d.ts.map +1 -0
  229. package/dist/commands/claude/plugin/build-schema.js +51 -0
  230. package/dist/commands/claude/plugin/build-schema.js.map +1 -0
  231. package/dist/commands/claude/plugin/build.d.ts +220 -45
  232. package/dist/commands/claude/plugin/build.d.ts.map +1 -1
  233. package/dist/commands/claude/plugin/build.js +466 -249
  234. package/dist/commands/claude/plugin/build.js.map +1 -1
  235. package/dist/commands/claude/plugin/helpers.d.ts +186 -24
  236. package/dist/commands/claude/plugin/helpers.d.ts.map +1 -1
  237. package/dist/commands/claude/plugin/helpers.js +110 -68
  238. package/dist/commands/claude/plugin/helpers.js.map +1 -1
  239. package/dist/commands/claude/plugin/install-schema.d.ts +144 -0
  240. package/dist/commands/claude/plugin/install-schema.d.ts.map +1 -0
  241. package/dist/commands/claude/plugin/install-schema.js +36 -0
  242. package/dist/commands/claude/plugin/install-schema.js.map +1 -0
  243. package/dist/commands/claude/plugin/install.d.ts +191 -11
  244. package/dist/commands/claude/plugin/install.d.ts.map +1 -1
  245. package/dist/commands/claude/plugin/install.js +688 -628
  246. package/dist/commands/claude/plugin/install.js.map +1 -1
  247. package/dist/commands/claude/plugin/kept-findings.d.ts +19 -0
  248. package/dist/commands/claude/plugin/kept-findings.d.ts.map +1 -0
  249. package/dist/commands/claude/plugin/kept-findings.js +24 -0
  250. package/dist/commands/claude/plugin/kept-findings.js.map +1 -0
  251. package/dist/commands/claude/plugin/list-schema.d.ts +223 -0
  252. package/dist/commands/claude/plugin/list-schema.d.ts.map +1 -0
  253. package/dist/commands/claude/plugin/list-schema.js +34 -0
  254. package/dist/commands/claude/plugin/list-schema.js.map +1 -0
  255. package/dist/commands/claude/plugin/list.d.ts +18 -0
  256. package/dist/commands/claude/plugin/list.d.ts.map +1 -1
  257. package/dist/commands/claude/plugin/list.js +53 -45
  258. package/dist/commands/claude/plugin/list.js.map +1 -1
  259. package/dist/commands/claude/plugin/npm-pack.d.ts +15 -0
  260. package/dist/commands/claude/plugin/npm-pack.d.ts.map +1 -0
  261. package/dist/commands/claude/plugin/npm-pack.js +39 -0
  262. package/dist/commands/claude/plugin/npm-pack.js.map +1 -0
  263. package/dist/commands/claude/plugin/plugin-changelog.d.ts +5 -1
  264. package/dist/commands/claude/plugin/plugin-changelog.d.ts.map +1 -1
  265. package/dist/commands/claude/plugin/plugin-changelog.js +9 -5
  266. package/dist/commands/claude/plugin/plugin-changelog.js.map +1 -1
  267. package/dist/commands/claude/plugin/plugin-files.d.ts +21 -2
  268. package/dist/commands/claude/plugin/plugin-files.d.ts.map +1 -1
  269. package/dist/commands/claude/plugin/plugin-files.js +65 -32
  270. package/dist/commands/claude/plugin/plugin-files.js.map +1 -1
  271. package/dist/commands/claude/plugin/plugin-validators.d.ts +13 -0
  272. package/dist/commands/claude/plugin/plugin-validators.d.ts.map +1 -1
  273. package/dist/commands/claude/plugin/plugin-validators.js +64 -16
  274. package/dist/commands/claude/plugin/plugin-validators.js.map +1 -1
  275. package/dist/commands/claude/plugin/tree-copy.d.ts.map +1 -1
  276. package/dist/commands/claude/plugin/tree-copy.js +63 -37
  277. package/dist/commands/claude/plugin/tree-copy.js.map +1 -1
  278. package/dist/commands/claude/plugin/uninstall-schema.d.ts +112 -0
  279. package/dist/commands/claude/plugin/uninstall-schema.d.ts.map +1 -0
  280. package/dist/commands/claude/plugin/uninstall-schema.js +28 -0
  281. package/dist/commands/claude/plugin/uninstall-schema.js.map +1 -0
  282. package/dist/commands/claude/plugin/uninstall.d.ts +57 -0
  283. package/dist/commands/claude/plugin/uninstall.d.ts.map +1 -1
  284. package/dist/commands/claude/plugin/uninstall.js +176 -64
  285. package/dist/commands/claude/plugin/uninstall.js.map +1 -1
  286. package/dist/commands/consistency-check.d.ts.map +1 -1
  287. package/dist/commands/consistency-check.js +8 -6
  288. package/dist/commands/consistency-check.js.map +1 -1
  289. package/dist/commands/corpus/index.d.ts.map +1 -1
  290. package/dist/commands/corpus/index.js +26 -10
  291. package/dist/commands/corpus/index.js.map +1 -1
  292. package/dist/commands/corpus/report.d.ts +34 -16
  293. package/dist/commands/corpus/report.d.ts.map +1 -1
  294. package/dist/commands/corpus/report.js +36 -18
  295. package/dist/commands/corpus/report.js.map +1 -1
  296. package/dist/commands/corpus/runner.d.ts +25 -20
  297. package/dist/commands/corpus/runner.d.ts.map +1 -1
  298. package/dist/commands/corpus/runner.js +123 -67
  299. package/dist/commands/corpus/runner.js.map +1 -1
  300. package/dist/commands/corpus/scan-schema.d.ts +127 -0
  301. package/dist/commands/corpus/scan-schema.d.ts.map +1 -0
  302. package/dist/commands/corpus/scan-schema.js +31 -0
  303. package/dist/commands/corpus/scan-schema.js.map +1 -0
  304. package/dist/commands/corpus/scan.d.ts +31 -0
  305. package/dist/commands/corpus/scan.d.ts.map +1 -1
  306. package/dist/commands/corpus/scan.js +124 -50
  307. package/dist/commands/corpus/scan.js.map +1 -1
  308. package/dist/commands/corpus/seed.d.ts +11 -8
  309. package/dist/commands/corpus/seed.d.ts.map +1 -1
  310. package/dist/commands/corpus/seed.js +29 -11
  311. package/dist/commands/corpus/seed.js.map +1 -1
  312. package/dist/commands/doctor-render.d.ts +52 -0
  313. package/dist/commands/doctor-render.d.ts.map +1 -0
  314. package/dist/commands/doctor-render.js +110 -0
  315. package/dist/commands/doctor-render.js.map +1 -0
  316. package/dist/commands/doctor-schema.d.ts +191 -0
  317. package/dist/commands/doctor-schema.d.ts.map +1 -0
  318. package/dist/commands/doctor-schema.js +44 -0
  319. package/dist/commands/doctor-schema.js.map +1 -0
  320. package/dist/commands/doctor.d.ts +7 -62
  321. package/dist/commands/doctor.d.ts.map +1 -1
  322. package/dist/commands/doctor.js +126 -165
  323. package/dist/commands/doctor.js.map +1 -1
  324. package/dist/commands/inventory-schema.d.ts +7297 -0
  325. package/dist/commands/inventory-schema.d.ts.map +1 -0
  326. package/dist/commands/inventory-schema.js +28 -0
  327. package/dist/commands/inventory-schema.js.map +1 -0
  328. package/dist/commands/inventory.d.ts +1 -1
  329. package/dist/commands/inventory.d.ts.map +1 -1
  330. package/dist/commands/inventory.js +89 -41
  331. package/dist/commands/inventory.js.map +1 -1
  332. package/dist/commands/mcp/index.d.ts.map +1 -1
  333. package/dist/commands/mcp/index.js +15 -0
  334. package/dist/commands/mcp/index.js.map +1 -1
  335. package/dist/commands/mcp/list-collections-schema.d.ts +101 -0
  336. package/dist/commands/mcp/list-collections-schema.d.ts.map +1 -0
  337. package/dist/commands/mcp/list-collections-schema.js +22 -0
  338. package/dist/commands/mcp/list-collections-schema.js.map +1 -0
  339. package/dist/commands/mcp/list-collections.d.ts +1 -1
  340. package/dist/commands/mcp/list-collections.d.ts.map +1 -1
  341. package/dist/commands/mcp/list-collections.js +19 -17
  342. package/dist/commands/mcp/list-collections.js.map +1 -1
  343. package/dist/commands/mcp/serve.d.ts +5 -0
  344. package/dist/commands/mcp/serve.d.ts.map +1 -1
  345. package/dist/commands/mcp/serve.js +29 -15
  346. package/dist/commands/mcp/serve.js.map +1 -1
  347. package/dist/commands/okf/index.d.ts.map +1 -1
  348. package/dist/commands/okf/index.js +6 -5
  349. package/dist/commands/okf/index.js.map +1 -1
  350. package/dist/commands/okf/validate-schema.d.ts +171 -0
  351. package/dist/commands/okf/validate-schema.d.ts.map +1 -0
  352. package/dist/commands/okf/validate-schema.js +44 -0
  353. package/dist/commands/okf/validate-schema.js.map +1 -0
  354. package/dist/commands/okf/validate.d.ts +16 -149
  355. package/dist/commands/okf/validate.d.ts.map +1 -1
  356. package/dist/commands/okf/validate.js +64 -62
  357. package/dist/commands/okf/validate.js.map +1 -1
  358. package/dist/commands/orchestrator-schema.d.ts +419 -0
  359. package/dist/commands/orchestrator-schema.d.ts.map +1 -0
  360. package/dist/commands/orchestrator-schema.js +91 -0
  361. package/dist/commands/orchestrator-schema.js.map +1 -0
  362. package/dist/commands/phase-utils.d.ts +188 -220
  363. package/dist/commands/phase-utils.d.ts.map +1 -1
  364. package/dist/commands/phase-utils.js +210 -258
  365. package/dist/commands/phase-utils.js.map +1 -1
  366. package/dist/commands/positional-args.d.ts +13 -11
  367. package/dist/commands/positional-args.d.ts.map +1 -1
  368. package/dist/commands/positional-args.js +16 -15
  369. package/dist/commands/positional-args.js.map +1 -1
  370. package/dist/commands/rag/admin-schema.d.ts +152 -0
  371. package/dist/commands/rag/admin-schema.d.ts.map +1 -0
  372. package/dist/commands/rag/admin-schema.js +31 -0
  373. package/dist/commands/rag/admin-schema.js.map +1 -0
  374. package/dist/commands/rag/clear-command.d.ts.map +1 -1
  375. package/dist/commands/rag/clear-command.js +30 -15
  376. package/dist/commands/rag/clear-command.js.map +1 -1
  377. package/dist/commands/rag/command-helpers.d.ts +31 -7
  378. package/dist/commands/rag/command-helpers.d.ts.map +1 -1
  379. package/dist/commands/rag/command-helpers.js +41 -21
  380. package/dist/commands/rag/command-helpers.js.map +1 -1
  381. package/dist/commands/rag/index-command.d.ts +37 -48
  382. package/dist/commands/rag/index-command.d.ts.map +1 -1
  383. package/dist/commands/rag/index-command.js +80 -65
  384. package/dist/commands/rag/index-command.js.map +1 -1
  385. package/dist/commands/rag/index-schema.d.ts +107 -0
  386. package/dist/commands/rag/index-schema.d.ts.map +1 -0
  387. package/dist/commands/rag/index-schema.js +34 -0
  388. package/dist/commands/rag/index-schema.js.map +1 -0
  389. package/dist/commands/rag/index.d.ts.map +1 -1
  390. package/dist/commands/rag/index.js +88 -41
  391. package/dist/commands/rag/index.js.map +1 -1
  392. package/dist/commands/rag/query-command.d.ts +18 -4
  393. package/dist/commands/rag/query-command.d.ts.map +1 -1
  394. package/dist/commands/rag/query-command.js +42 -27
  395. package/dist/commands/rag/query-command.js.map +1 -1
  396. package/dist/commands/rag/query-schema.d.ts +363 -0
  397. package/dist/commands/rag/query-schema.d.ts.map +1 -0
  398. package/dist/commands/rag/query-schema.js +59 -0
  399. package/dist/commands/rag/query-schema.js.map +1 -0
  400. package/dist/commands/rag/stats-command.d.ts.map +1 -1
  401. package/dist/commands/rag/stats-command.js +19 -18
  402. package/dist/commands/rag/stats-command.js.map +1 -1
  403. package/dist/commands/resources/check-progress.d.ts +64 -11
  404. package/dist/commands/resources/check-progress.d.ts.map +1 -1
  405. package/dist/commands/resources/check-progress.js +77 -4
  406. package/dist/commands/resources/check-progress.js.map +1 -1
  407. package/dist/commands/resources/check-schema.d.ts +335 -0
  408. package/dist/commands/resources/check-schema.d.ts.map +1 -0
  409. package/dist/commands/resources/check-schema.js +104 -0
  410. package/dist/commands/resources/check-schema.js.map +1 -0
  411. package/dist/commands/resources/check-supervisor.d.ts +315 -71
  412. package/dist/commands/resources/check-supervisor.d.ts.map +1 -1
  413. package/dist/commands/resources/check-supervisor.js +493 -107
  414. package/dist/commands/resources/check-supervisor.js.map +1 -1
  415. package/dist/commands/resources/check.d.ts +56 -249
  416. package/dist/commands/resources/check.d.ts.map +1 -1
  417. package/dist/commands/resources/check.js +416 -276
  418. package/dist/commands/resources/check.js.map +1 -1
  419. package/dist/commands/resources/index.d.ts.map +1 -1
  420. package/dist/commands/resources/index.js +165 -91
  421. package/dist/commands/resources/index.js.map +1 -1
  422. package/dist/commands/resources/query-schema.d.ts +188 -0
  423. package/dist/commands/resources/query-schema.d.ts.map +1 -0
  424. package/dist/commands/resources/query-schema.js +48 -0
  425. package/dist/commands/resources/query-schema.js.map +1 -0
  426. package/dist/commands/resources/query.d.ts +17 -12
  427. package/dist/commands/resources/query.d.ts.map +1 -1
  428. package/dist/commands/resources/query.js +60 -48
  429. package/dist/commands/resources/query.js.map +1 -1
  430. package/dist/commands/resources/scan-schema.d.ts +195 -0
  431. package/dist/commands/resources/scan-schema.d.ts.map +1 -0
  432. package/dist/commands/resources/scan-schema.js +53 -0
  433. package/dist/commands/resources/scan-schema.js.map +1 -0
  434. package/dist/commands/resources/scan.d.ts +26 -3
  435. package/dist/commands/resources/scan.d.ts.map +1 -1
  436. package/dist/commands/resources/scan.js +51 -53
  437. package/dist/commands/resources/scan.js.map +1 -1
  438. package/dist/commands/resources/validate-schema.d.ts +326 -0
  439. package/dist/commands/resources/validate-schema.d.ts.map +1 -0
  440. package/dist/commands/resources/validate-schema.js +60 -0
  441. package/dist/commands/resources/validate-schema.js.map +1 -0
  442. package/dist/commands/resources/validate.d.ts +45 -169
  443. package/dist/commands/resources/validate.d.ts.map +1 -1
  444. package/dist/commands/resources/validate.js +221 -485
  445. package/dist/commands/resources/validate.js.map +1 -1
  446. package/dist/commands/skill/review-checklist.d.ts.map +1 -1
  447. package/dist/commands/skill/review-checklist.js +0 -1
  448. package/dist/commands/skill/review-checklist.js.map +1 -1
  449. package/dist/commands/skill/review-schema.d.ts +278 -0
  450. package/dist/commands/skill/review-schema.d.ts.map +1 -0
  451. package/dist/commands/skill/review-schema.js +46 -0
  452. package/dist/commands/skill/review-schema.js.map +1 -0
  453. package/dist/commands/skill/review.d.ts +8 -234
  454. package/dist/commands/skill/review.d.ts.map +1 -1
  455. package/dist/commands/skill/review.js +54 -78
  456. package/dist/commands/skill/review.js.map +1 -1
  457. package/dist/commands/skill/test/auth-flags.d.ts +3 -0
  458. package/dist/commands/skill/test/auth-flags.d.ts.map +1 -1
  459. package/dist/commands/skill/test/auth-flags.js +6 -2
  460. package/dist/commands/skill/test/auth-flags.js.map +1 -1
  461. package/dist/commands/skill/test/configure-schema.d.ts +67 -0
  462. package/dist/commands/skill/test/configure-schema.d.ts.map +1 -0
  463. package/dist/commands/skill/test/configure-schema.js +27 -0
  464. package/dist/commands/skill/test/configure-schema.js.map +1 -0
  465. package/dist/commands/skill/test/configure.d.ts +12 -5
  466. package/dist/commands/skill/test/configure.d.ts.map +1 -1
  467. package/dist/commands/skill/test/configure.js +101 -31
  468. package/dist/commands/skill/test/configure.js.map +1 -1
  469. package/dist/commands/skill/test/run-schema.d.ts +107 -0
  470. package/dist/commands/skill/test/run-schema.d.ts.map +1 -0
  471. package/dist/commands/skill/test/run-schema.js +36 -0
  472. package/dist/commands/skill/test/run-schema.js.map +1 -0
  473. package/dist/commands/skill/test/run.d.ts +3 -2
  474. package/dist/commands/skill/test/run.d.ts.map +1 -1
  475. package/dist/commands/skill/test/run.js +316 -155
  476. package/dist/commands/skill/test/run.js.map +1 -1
  477. package/dist/commands/skills/build-schema.d.ts +199 -0
  478. package/dist/commands/skills/build-schema.d.ts.map +1 -0
  479. package/dist/commands/skills/build-schema.js +55 -0
  480. package/dist/commands/skills/build-schema.js.map +1 -0
  481. package/dist/commands/skills/build.d.ts +95 -298
  482. package/dist/commands/skills/build.d.ts.map +1 -1
  483. package/dist/commands/skills/build.js +415 -818
  484. package/dist/commands/skills/build.js.map +1 -1
  485. package/dist/commands/skills/command-helpers.d.ts +5 -11
  486. package/dist/commands/skills/command-helpers.d.ts.map +1 -1
  487. package/dist/commands/skills/command-helpers.js +7 -17
  488. package/dist/commands/skills/command-helpers.js.map +1 -1
  489. package/dist/commands/skills/index.js +12 -6
  490. package/dist/commands/skills/index.js.map +1 -1
  491. package/dist/commands/skills/install-schema.d.ts +153 -0
  492. package/dist/commands/skills/install-schema.d.ts.map +1 -0
  493. package/dist/commands/skills/install-schema.js +44 -0
  494. package/dist/commands/skills/install-schema.js.map +1 -0
  495. package/dist/commands/skills/install.d.ts +76 -8
  496. package/dist/commands/skills/install.d.ts.map +1 -1
  497. package/dist/commands/skills/install.js +230 -194
  498. package/dist/commands/skills/install.js.map +1 -1
  499. package/dist/commands/skills/list-schema.d.ts +145 -0
  500. package/dist/commands/skills/list-schema.d.ts.map +1 -0
  501. package/dist/commands/skills/list-schema.js +37 -0
  502. package/dist/commands/skills/list-schema.js.map +1 -0
  503. package/dist/commands/skills/list.d.ts +39 -8
  504. package/dist/commands/skills/list.d.ts.map +1 -1
  505. package/dist/commands/skills/list.js +110 -122
  506. package/dist/commands/skills/list.js.map +1 -1
  507. package/dist/commands/skills/package-schema.d.ts +98 -0
  508. package/dist/commands/skills/package-schema.d.ts.map +1 -0
  509. package/dist/commands/skills/package-schema.js +32 -0
  510. package/dist/commands/skills/package-schema.js.map +1 -0
  511. package/dist/commands/skills/package.d.ts +85 -14
  512. package/dist/commands/skills/package.d.ts.map +1 -1
  513. package/dist/commands/skills/package.js +288 -207
  514. package/dist/commands/skills/package.js.map +1 -1
  515. package/dist/commands/skills/scope-guard.d.ts +27 -20
  516. package/dist/commands/skills/scope-guard.d.ts.map +1 -1
  517. package/dist/commands/skills/scope-guard.js +43 -32
  518. package/dist/commands/skills/scope-guard.js.map +1 -1
  519. package/dist/commands/skills/skill-discovery.d.ts +1 -1
  520. package/dist/commands/skills/skill-discovery.d.ts.map +1 -1
  521. package/dist/commands/skills/skill-discovery.js +40 -19
  522. package/dist/commands/skills/skill-discovery.js.map +1 -1
  523. package/dist/commands/skills/source-resolvers.d.ts +58 -8
  524. package/dist/commands/skills/source-resolvers.d.ts.map +1 -1
  525. package/dist/commands/skills/source-resolvers.js +113 -38
  526. package/dist/commands/skills/source-resolvers.js.map +1 -1
  527. package/dist/commands/skills/validate-command.d.ts.map +1 -1
  528. package/dist/commands/skills/validate-command.js +31 -51
  529. package/dist/commands/skills/validate-command.js.map +1 -1
  530. package/dist/commands/skills/validate-schema.d.ts +199 -0
  531. package/dist/commands/skills/validate-schema.d.ts.map +1 -0
  532. package/dist/commands/skills/validate-schema.js +44 -0
  533. package/dist/commands/skills/validate-schema.js.map +1 -0
  534. package/dist/commands/skills/validate.d.ts +100 -136
  535. package/dist/commands/skills/validate.d.ts.map +1 -1
  536. package/dist/commands/skills/validate.js +257 -343
  537. package/dist/commands/skills/validate.js.map +1 -1
  538. package/dist/commands/validate.d.ts +17 -5
  539. package/dist/commands/validate.d.ts.map +1 -1
  540. package/dist/commands/validate.js +139 -94
  541. package/dist/commands/validate.js.map +1 -1
  542. package/dist/commands/verify.d.ts +121 -110
  543. package/dist/commands/verify.d.ts.map +1 -1
  544. package/dist/commands/verify.js +230 -294
  545. package/dist/commands/verify.js.map +1 -1
  546. package/dist/index.d.ts +1 -1
  547. package/dist/index.d.ts.map +1 -1
  548. package/dist/index.js +1 -1
  549. package/dist/index.js.map +1 -1
  550. package/dist/report-schemas.d.ts +12398 -35
  551. package/dist/report-schemas.d.ts.map +1 -1
  552. package/dist/report-schemas.js +624 -66
  553. package/dist/report-schemas.js.map +1 -1
  554. package/dist/skill-resolution/packaging-config.js +2 -2
  555. package/dist/skill-resolution/packaging-config.js.map +1 -1
  556. package/dist/skill-resolution/resolve-skill-reference.d.ts.map +1 -1
  557. package/dist/skill-resolution/resolve-skill-reference.js +20 -13
  558. package/dist/skill-resolution/resolve-skill-reference.js.map +1 -1
  559. package/dist/utils/agent-discovery.d.ts +34 -1
  560. package/dist/utils/agent-discovery.d.ts.map +1 -1
  561. package/dist/utils/agent-discovery.js +80 -38
  562. package/dist/utils/agent-discovery.js.map +1 -1
  563. package/dist/utils/claude-context-lens.d.ts +13 -6
  564. package/dist/utils/claude-context-lens.d.ts.map +1 -1
  565. package/dist/utils/claude-context-lens.js +11 -12
  566. package/dist/utils/claude-context-lens.js.map +1 -1
  567. package/dist/utils/command-error-codes.d.ts +12 -0
  568. package/dist/utils/command-error-codes.d.ts.map +1 -0
  569. package/dist/utils/command-error-codes.js +12 -0
  570. package/dist/utils/command-error-codes.js.map +1 -0
  571. package/dist/utils/command-refusal.d.ts +58 -0
  572. package/dist/utils/command-refusal.d.ts.map +1 -0
  573. package/dist/utils/command-refusal.js +170 -0
  574. package/dist/utils/command-refusal.js.map +1 -0
  575. package/dist/utils/commander-ending.d.ts +40 -0
  576. package/dist/utils/commander-ending.d.ts.map +1 -0
  577. package/dist/utils/commander-ending.js +42 -0
  578. package/dist/utils/commander-ending.js.map +1 -0
  579. package/dist/utils/config-loader.d.ts +13 -8
  580. package/dist/utils/config-loader.d.ts.map +1 -1
  581. package/dist/utils/config-loader.js +84 -45
  582. package/dist/utils/config-loader.js.map +1 -1
  583. package/dist/utils/corpus-target.d.ts +1 -1
  584. package/dist/utils/corpus-target.d.ts.map +1 -1
  585. package/dist/utils/corpus-target.js +6 -4
  586. package/dist/utils/corpus-target.js.map +1 -1
  587. package/dist/utils/debug-diagnostics.d.ts +18 -0
  588. package/dist/utils/debug-diagnostics.d.ts.map +1 -0
  589. package/dist/utils/debug-diagnostics.js +23 -0
  590. package/dist/utils/debug-diagnostics.js.map +1 -0
  591. package/dist/utils/document-writer.d.ts +191 -0
  592. package/dist/utils/document-writer.d.ts.map +1 -0
  593. package/dist/utils/document-writer.js +319 -0
  594. package/dist/utils/document-writer.js.map +1 -0
  595. package/dist/utils/help-loader.d.ts +2 -2
  596. package/dist/utils/help-loader.js +2 -2
  597. package/dist/utils/install-plan.d.ts +99 -0
  598. package/dist/utils/install-plan.d.ts.map +1 -0
  599. package/dist/utils/install-plan.js +146 -0
  600. package/dist/utils/install-plan.js.map +1 -0
  601. package/dist/utils/issue-anchor.d.ts +1 -1
  602. package/dist/utils/issue-anchor.d.ts.map +1 -1
  603. package/dist/utils/issue-anchor.js.map +1 -1
  604. package/dist/utils/issue-rendering.d.ts +8 -3
  605. package/dist/utils/issue-rendering.d.ts.map +1 -1
  606. package/dist/utils/issue-rendering.js +4 -0
  607. package/dist/utils/issue-rendering.js.map +1 -1
  608. package/dist/utils/lens-population.d.ts +20 -0
  609. package/dist/utils/lens-population.d.ts.map +1 -0
  610. package/dist/utils/lens-population.js +15 -0
  611. package/dist/utils/lens-population.js.map +1 -0
  612. package/dist/utils/marketplace-io.d.ts +63 -0
  613. package/dist/utils/marketplace-io.d.ts.map +1 -0
  614. package/dist/utils/marketplace-io.js +63 -0
  615. package/dist/utils/marketplace-io.js.map +1 -0
  616. package/dist/utils/operator-notices.d.ts +97 -0
  617. package/dist/utils/operator-notices.d.ts.map +1 -0
  618. package/dist/utils/operator-notices.js +115 -0
  619. package/dist/utils/operator-notices.js.map +1 -0
  620. package/dist/utils/optional-backend.d.ts +18 -15
  621. package/dist/utils/optional-backend.d.ts.map +1 -1
  622. package/dist/utils/optional-backend.js +22 -33
  623. package/dist/utils/optional-backend.js.map +1 -1
  624. package/dist/utils/output.d.ts +5 -43
  625. package/dist/utils/output.d.ts.map +1 -1
  626. package/dist/utils/output.js +8 -63
  627. package/dist/utils/output.js.map +1 -1
  628. package/dist/utils/package-json.d.ts +3 -4
  629. package/dist/utils/package-json.d.ts.map +1 -1
  630. package/dist/utils/package-json.js +8 -8
  631. package/dist/utils/package-json.js.map +1 -1
  632. package/dist/utils/population-wiring.d.ts +31 -38
  633. package/dist/utils/population-wiring.d.ts.map +1 -1
  634. package/dist/utils/population-wiring.js +38 -32
  635. package/dist/utils/population-wiring.js.map +1 -1
  636. package/dist/utils/project-root-policy.d.ts +74 -1
  637. package/dist/utils/project-root-policy.d.ts.map +1 -1
  638. package/dist/utils/project-root-policy.js +146 -8
  639. package/dist/utils/project-root-policy.js.map +1 -1
  640. package/dist/utils/projection-lenses.d.ts +25 -7
  641. package/dist/utils/projection-lenses.d.ts.map +1 -1
  642. package/dist/utils/projection-lenses.js +20 -6
  643. package/dist/utils/projection-lenses.js.map +1 -1
  644. package/dist/utils/projection-query.d.ts +17 -10
  645. package/dist/utils/projection-query.d.ts.map +1 -1
  646. package/dist/utils/projection-query.js +47 -28
  647. package/dist/utils/projection-query.js.map +1 -1
  648. package/dist/utils/projection-store.d.ts +2 -2
  649. package/dist/utils/projection-store.d.ts.map +1 -1
  650. package/dist/utils/projection-store.js +74 -45
  651. package/dist/utils/projection-store.js.map +1 -1
  652. package/dist/utils/rag-database.d.ts +61 -0
  653. package/dist/utils/rag-database.d.ts.map +1 -0
  654. package/dist/utils/rag-database.js +178 -0
  655. package/dist/utils/rag-database.js.map +1 -0
  656. package/dist/utils/relation-limits.d.ts +7 -2
  657. package/dist/utils/relation-limits.d.ts.map +1 -1
  658. package/dist/utils/relation-limits.js +6 -1
  659. package/dist/utils/relation-limits.js.map +1 -1
  660. package/dist/utils/relativize-paths.d.ts +23 -0
  661. package/dist/utils/relativize-paths.d.ts.map +1 -1
  662. package/dist/utils/relativize-paths.js +32 -1
  663. package/dist/utils/relativize-paths.js.map +1 -1
  664. package/dist/utils/resource-loader.d.ts +76 -32
  665. package/dist/utils/resource-loader.d.ts.map +1 -1
  666. package/dist/utils/resource-loader.js +132 -66
  667. package/dist/utils/resource-loader.js.map +1 -1
  668. package/dist/utils/run-integrity.d.ts +64 -31
  669. package/dist/utils/run-integrity.d.ts.map +1 -1
  670. package/dist/utils/run-integrity.js +76 -35
  671. package/dist/utils/run-integrity.js.map +1 -1
  672. package/dist/utils/scope-locations.d.ts +7 -5
  673. package/dist/utils/scope-locations.d.ts.map +1 -1
  674. package/dist/utils/scope-locations.js +37 -12
  675. package/dist/utils/scope-locations.js.map +1 -1
  676. package/dist/utils/staging-dir.d.ts +7 -0
  677. package/dist/utils/staging-dir.d.ts.map +1 -0
  678. package/dist/utils/staging-dir.js +12 -0
  679. package/dist/utils/staging-dir.js.map +1 -0
  680. package/dist/utils/url-redact.d.ts +9 -0
  681. package/dist/utils/url-redact.d.ts.map +1 -1
  682. package/dist/utils/url-redact.js +13 -0
  683. package/dist/utils/url-redact.js.map +1 -1
  684. package/dist/utils/user-context-scanner.d.ts +3 -2
  685. package/dist/utils/user-context-scanner.d.ts.map +1 -1
  686. package/dist/utils/user-context-scanner.js +24 -4
  687. package/dist/utils/user-context-scanner.js.map +1 -1
  688. package/dist/utils/validate-help-files.d.ts.map +1 -1
  689. package/dist/utils/validate-help-files.js +8 -14
  690. package/dist/utils/validate-help-files.js.map +1 -1
  691. package/dist/utils/vat-bin-path.d.ts.map +1 -1
  692. package/dist/utils/vat-bin-path.js +3 -3
  693. package/dist/utils/vat-bin-path.js.map +1 -1
  694. package/dist/utils/verdict-helpers.d.ts.map +1 -1
  695. package/dist/utils/verdict-helpers.js +5 -5
  696. package/dist/utils/verdict-helpers.js.map +1 -1
  697. package/docs/agent.md +347 -2
  698. package/docs/audit.md +312 -89
  699. package/docs/doctor.md +65 -19
  700. package/docs/index.md +571 -20
  701. package/docs/mcp.md +64 -12
  702. package/docs/rag.md +176 -48
  703. package/docs/resources.md +257 -71
  704. package/docs/skill-test.md +148 -19
  705. package/docs/skills.md +459 -174
  706. package/package.json +16 -19
  707. package/schemas/agent-build.json +268 -0
  708. package/schemas/agent-import.json +252 -0
  709. package/schemas/agent-install.json +260 -0
  710. package/schemas/agent-installed.json +287 -0
  711. package/schemas/agent-list.json +279 -0
  712. package/schemas/agent-uninstall.json +260 -0
  713. package/schemas/agent-validate.json +279 -0
  714. package/schemas/ard-emit.json +224 -106
  715. package/schemas/audit-settings.json +472 -0
  716. package/schemas/audit.json +635 -0
  717. package/schemas/cache-clear.json +273 -0
  718. package/schemas/claude-marketplace-publish.json +286 -0
  719. package/schemas/claude-marketplace-validate.json +352 -0
  720. package/schemas/claude-org-not-implemented.json +239 -0
  721. package/schemas/claude-plugin-build.json +446 -0
  722. package/schemas/claude-plugin-install.json +291 -0
  723. package/schemas/claude-plugin-list.json +326 -0
  724. package/schemas/claude-plugin-uninstall.json +272 -0
  725. package/schemas/corpus-audit.json +635 -0
  726. package/schemas/corpus-scan.json +293 -0
  727. package/schemas/doctor.json +299 -0
  728. package/schemas/inventory.json +982 -0
  729. package/schemas/mcp-list-collections.json +268 -0
  730. package/schemas/okf-validate.json +224 -106
  731. package/schemas/orchestrator.json +299 -0
  732. package/schemas/rag-clear.json +253 -0
  733. package/schemas/rag-index.json +273 -0
  734. package/schemas/rag-query.json +365 -0
  735. package/schemas/rag-stats.json +269 -0
  736. package/schemas/resources-check.json +242 -108
  737. package/schemas/resources-query.json +333 -0
  738. package/schemas/resources-scan.json +321 -0
  739. package/schemas/resources-validate.json +332 -0
  740. package/schemas/skill-review.json +224 -106
  741. package/schemas/skill-test-configure.json +256 -0
  742. package/schemas/skill-test-run.json +296 -0
  743. package/schemas/skills-build.json +325 -0
  744. package/schemas/skills-install.json +287 -0
  745. package/schemas/skills-list.json +283 -0
  746. package/schemas/skills-package.json +270 -0
  747. package/schemas/skills-validate.json +285 -0
  748. package/dist/commands/skills/shared.d.ts +0 -29
  749. package/dist/commands/skills/shared.d.ts.map +0 -1
  750. package/dist/commands/skills/shared.js +0 -33
  751. package/dist/commands/skills/shared.js.map +0 -1
  752. package/dist/utils/command-error.d.ts +0 -194
  753. package/dist/utils/command-error.d.ts.map +0 -1
  754. package/dist/utils/command-error.js +0 -237
  755. package/dist/utils/command-error.js.map +0 -1
@@ -7,22 +7,27 @@
7
7
  * - LICENSE file must exist (error)
8
8
  * - README.md should exist (warning)
9
9
  * - CHANGELOG.md should exist (warning)
10
+ *
11
+ * Publishes the `Report<T>` envelope (`validate-schema.ts`): every finding flat
12
+ * with its `location` relative to `data.root`, one `data.plugins` row per
13
+ * declared local plugin walked.
10
14
  */
11
- import { existsSync, readdirSync, statSync } from 'node:fs';
12
- import { validateMarketplace, validateSkill, } from '@vibe-agent-toolkit/agent-skills';
15
+ import { readdirSync } from 'node:fs';
16
+ import { materializeIssue, validateMarketplace, validateSkill, } from '@vibe-agent-toolkit/agent-skills';
13
17
  import { validatePlugin } from '@vibe-agent-toolkit/claude-marketplace';
14
- import { calculateValidationStatus, countBySeverity, } from '@vibe-agent-toolkit/schema';
15
- import { direntKindFollowingSync, findProjectRoot, isPathAbsentError, issueLocation, isVatError, normalizePath, PathEscapesRootError, relativeEscapesRoot, safePath, toForwardSlash, toForwardSlashAnyPlatform } from '@vibe-agent-toolkit/utils';
18
+ import { buildReport, summarizeIssues, toFindings, } from '@vibe-agent-toolkit/schema';
19
+ import { direntKindFollowingSync, everywhere, findProjectRoot, followedKindSync, forEachInOrder, fsFaultOf, isLinkChainRefusedError, isPathAbsentError, issueLocation, isVatError, mapInOrder, normalizePath, PathEscapesRootError, pathPresent, relativeEscapesRoot, safePath, toForwardSlash, toForwardSlashAnyPlatform } from '@vibe-agent-toolkit/utils';
16
20
  import { Command } from 'commander';
17
- import { formatDuration, reportCommandError } from '../../../utils/command-error.js';
21
+ import { refusalCodeOf } from '../../../utils/command-refusal.js';
18
22
  import { loadConfig } from '../../../utils/config-loader.js';
19
- import { summarizeFindings } from '../../../utils/issue-rendering.js';
23
+ import { endWithReport, NOTHING_FINISHED, publishedReport, refusalReport } from '../../../utils/document-writer.js';
20
24
  import { resolveIssueSeverity } from '../../../utils/issue-severity.js';
21
25
  import { createLogger } from '../../../utils/logger.js';
22
- import { writeYamlOutput } from '../../../utils/output.js';
23
- import { relativizePathEntries } from '../../../utils/relativize-paths.js';
24
- import { runIntegrityFinding } from '../../../utils/run-integrity.js';
25
- import { finishCommand } from '../../phase-utils.js';
26
+ import { assertReadableDirectoryArgument } from '../../../utils/project-root-policy.js';
27
+ import { relativizePath } from '../../../utils/relativize-paths.js';
28
+ import { RUN_INTEGRITY_CODE, runIntegrityFinding, warnRunIntegrity } from '../../../utils/run-integrity.js';
29
+ /** `vat claude marketplace validate` offers no `--strict`: warnings never fail it. */
30
+ const GATE = { strict: false };
26
31
  /**
27
32
  * Check for required/recommended files in the marketplace root.
28
33
  */
@@ -34,7 +39,8 @@ function checkMarketplaceFiles(marketplacePath) {
34
39
  { file: 'CHANGELOG.md', code: 'MARKETPLACE_MISSING_CHANGELOG', severity: 'warning', verb: 'recommended for tracking changes' },
35
40
  ];
36
41
  for (const check of fileChecks) {
37
- if (!existsSync(safePath.join(marketplacePath, check.file))) {
42
+ // A probe the OS refuses is the marketplace's source fault, never "missing".
43
+ if (!pathPresent(safePath.join(marketplacePath, check.file), { follow: marketplacePath }, everywhere('source'), 'probe')) {
38
44
  issues.push({
39
45
  severity: check.severity,
40
46
  code: check.code,
@@ -71,6 +77,8 @@ class WalkBoundary {
71
77
  marketplacePath;
72
78
  realRoot;
73
79
  refused = [];
80
+ /** Root-relative paths inside a validated plugin the OS would not let the walk read. */
81
+ unread = [];
74
82
  constructor(marketplacePath, realRoot) {
75
83
  this.marketplacePath = marketplacePath;
76
84
  this.realRoot = realRoot;
@@ -81,12 +89,41 @@ class WalkBoundary {
81
89
  * beneath it is visited either, because nothing beneath it was read.
82
90
  */
83
91
  contains(abs) {
84
- const real = toForwardSlash(normalizePath(abs));
85
- if (!relativeEscapesRoot(safePath.relative(this.realRoot, real)))
92
+ if (this.resolvesInside(abs))
86
93
  return true;
87
94
  this.refused.push(issueLocation(abs, this.marketplacePath));
88
95
  return false;
89
96
  }
97
+ /**
98
+ * Whether `abs`'s real path — its links read beneath the root first — sits under the root. A
99
+ * chain through a network or device path leaves the root by definition, and is never handed to
100
+ * the kernel: it is outside.
101
+ */
102
+ resolvesInside(abs) {
103
+ try {
104
+ return !relativeEscapesRoot(safePath.relative(this.realRoot, toForwardSlash(normalizePath(abs, this.marketplacePath))));
105
+ }
106
+ catch (error) {
107
+ if (!isLinkChainRefusedError(error))
108
+ throw error;
109
+ return false;
110
+ }
111
+ }
112
+ /**
113
+ * Record `abs` as a path the OS refused to let the walk read, and return its
114
+ * `SCAN_PATH_UNREADABLE` warning. The record, not the warning, is what the
115
+ * builder turns into the run-integrity refusal: a severity override may
116
+ * silence the warning, never the fact that nothing behind the path was read.
117
+ * Anything that is not a filesystem refusal is a defect and is rethrown.
118
+ */
119
+ unreadable(abs, error) {
120
+ const fault = fsFaultOf(error);
121
+ if (fault === undefined)
122
+ throw error;
123
+ const location = issueLocation(abs, this.marketplacePath);
124
+ this.unread.push(location);
125
+ return materializeIssue('SCAN_PATH_UNREADABLE', { location, detail: `${location}: read refused with ${fault.errno}` });
126
+ }
90
127
  }
91
128
  /**
92
129
  * Validate all SKILL.md files within a plugin's skills/ directory.
@@ -100,23 +137,52 @@ class WalkBoundary {
100
137
  */
101
138
  async function validatePluginSkills(pluginDir, marketplacePath, boundary, validation) {
102
139
  const skillsDir = safePath.join(pluginDir, 'skills');
103
- if (!existsSync(skillsDir) || !boundary.contains(skillsDir))
140
+ // Containment first: it reads the chain, so a link out (a network one included) is refused by
141
+ // name before anything follows it; an absent `skills/` is inside and then not present.
142
+ if (!boundary.contains(skillsDir))
104
143
  return [];
105
- const issues = [];
106
- const skillEntries = readdirSync(skillsDir, { withFileTypes: true });
107
- for (const skillEntry of skillEntries) {
108
- const skillDir = safePath.join(skillsDir, skillEntry.name);
109
- if (!isDirectory(skillDir) || !boundary.contains(skillDir))
110
- continue;
111
- const skillMdPath = safePath.join(skillDir, 'SKILL.md');
112
- if (!existsSync(skillMdPath) || !boundary.contains(skillMdPath))
113
- continue;
144
+ let skillEntries;
145
+ try {
146
+ if (!pathPresent(skillsDir, { follow: marketplacePath }, everywhere('source'), 'probe'))
147
+ return [];
148
+ skillEntries = readdirSync(skillsDir, { withFileTypes: true });
149
+ }
150
+ catch (error) {
151
+ return resolveIssueSeverity([boundary.unreadable(skillsDir, error)], validation);
152
+ }
153
+ // In order: `boundary` records refused and unread paths in the order the run names them.
154
+ const perSkill = await mapInOrder(skillEntries, (skillEntry) => validateOneSkill(safePath.join(skillsDir, skillEntry.name), marketplacePath, boundary, validation));
155
+ return perSkill.flat();
156
+ }
157
+ /**
158
+ * Validate one entry of a plugin's `skills/`: nothing when it is not a skill
159
+ * directory holding a SKILL.md under the root. A skill the OS will not let the
160
+ * run stat or read is one this gate did not check — named through `boundary`
161
+ * and refused by the builder, never a crash (it was INTERNAL_ERROR, exit 2).
162
+ */
163
+ async function validateOneSkill(skillDir, marketplacePath, boundary, validation) {
164
+ const refusedAt = (path, error) => resolveIssueSeverity([boundary.unreadable(path, error)], validation);
165
+ // Containment before every followed probe: `contains` reads the chain and refuses a link out
166
+ // (a network one included) by name, so the probe after it only ever follows a chain in the root.
167
+ try {
168
+ if (!boundary.contains(skillDir) || !isDirectory(skillDir, marketplacePath))
169
+ return [];
170
+ }
171
+ catch (error) {
172
+ return refusedAt(skillDir, error);
173
+ }
174
+ const skillMdPath = safePath.join(skillDir, 'SKILL.md');
175
+ try {
176
+ if (!boundary.contains(skillMdPath) || !pathPresent(skillMdPath, { follow: marketplacePath }, everywhere('source'), 'probe'))
177
+ return [];
114
178
  // Severity only (no `allow`), resolved here so a default-`ignore` code can still be raised.
115
179
  const severity = validation?.severity === undefined ? {} : { severity: validation.severity };
116
- const skillResult = await validateSkill({ skillPath: skillMdPath, rootDir: skillDir, locationRoot: marketplacePath, validation: severity });
117
- issues.push(...skillResult.issues);
180
+ const skillResult = await validateSkill({ skillPath: skillMdPath, rootDir: skillDir, locationRoot: marketplacePath, validation: severity, side: 'source' });
181
+ return skillResult.issues;
182
+ }
183
+ catch (error) {
184
+ return refusedAt(skillMdPath, error);
118
185
  }
119
- return issues;
120
186
  }
121
187
  /**
122
188
  * Whether `dir` is a directory. `false` for a file and for nothing — both are
@@ -125,9 +191,9 @@ async function validatePluginSkills(pluginDir, marketplacePath, boundary, valida
125
191
  * resolve, sending the reader to create a directory that is there. The refusal
126
192
  * propagates and the command refuses the run by errno, like every other verb.
127
193
  */
128
- function isDirectory(dir) {
194
+ function isDirectory(dir, within) {
129
195
  try {
130
- return statSync(dir).isDirectory();
196
+ return followedKindSync(dir, within) === 'directory';
131
197
  }
132
198
  catch (error) {
133
199
  if (isPathAbsentError(error))
@@ -181,9 +247,19 @@ function containedPluginDir(marketplacePath, realRoot, source) {
181
247
  throw error;
182
248
  return undefined;
183
249
  }
184
- if (!isDirectory(lexical))
250
+ let real;
251
+ try {
252
+ if (!isDirectory(lexical, marketplacePath))
253
+ return undefined;
254
+ real = toForwardSlash(normalizePath(lexical, marketplacePath));
255
+ }
256
+ catch (error) {
257
+ // A source whose link chain names a network or device path leaves the root by definition: it
258
+ // names nothing this command may enter, and the builder refuses the run by name from its absence.
259
+ if (!isLinkChainRefusedError(error))
260
+ throw error;
185
261
  return undefined;
186
- const real = toForwardSlash(normalizePath(lexical));
262
+ }
187
263
  return relativeEscapesRoot(safePath.relative(realRoot, real)) ? undefined : { lexical, real };
188
264
  }
189
265
  /**
@@ -215,11 +291,10 @@ function containedPluginDir(marketplacePath, realRoot, source) {
215
291
  * `validation` is the governing project's severity map (see
216
292
  * {@link resolveProjectValidationConfig}). It is applied to each plugin result
217
293
  * HERE rather than to the flat list at the end because the emitted document
218
- * publishes both: `issues` and `plugins[].issues` are two views of the same
219
- * findings, plus `plugins[].status`. Resolving once, at the producer, is what
220
- * keeps them from disagreeing — a suppressed warning still listed under
221
- * `plugins[]`, or a plugin `status: warning` above an issue list that no longer
222
- * contains a warning.
294
+ * publishes both: the envelope's `findings` and each `data.plugins[]` row's
295
+ * `status` + `summary` tally the same findings. Resolving once, at the
296
+ * producer, is what keeps them from disagreeing — a row counting a warning
297
+ * the envelope suppressed, or a row `findings` over nothing published.
223
298
  */
224
299
  async function validateDeclaredPlugins(marketplacePath, declared, validation) {
225
300
  const pluginResults = [];
@@ -227,34 +302,38 @@ async function validateDeclaredPlugins(marketplacePath, declared, validation) {
227
302
  // Keyed by REAL path: one directory is validated once however many entries
228
303
  // name it, and the same key is what `undeclaredPluginDirs` compares against.
229
304
  const validatedByDir = new Map();
230
- const realRoot = toForwardSlash(normalizePath(marketplacePath));
305
+ // The marketplace root is the operator's own argument: its own `within`.
306
+ const realRoot = toForwardSlash(normalizePath(marketplacePath, marketplacePath));
231
307
  const boundary = new WalkBoundary(marketplacePath, realRoot);
232
- for (const entry of declared) {
308
+ // In order: `validatedByDir` dedupes a directory two entries name, which a
309
+ // concurrent first visit would validate twice.
310
+ await forEachInOrder(declared, async (entry) => {
233
311
  // A source that names nothing inside the root — nothing at all, a file,
234
312
  // an absolute path, a `..` climb, a symlink out — is simply absent from the
235
313
  // results, and the builder refuses the run by name from that absence.
236
314
  const dir = containedPluginDir(marketplacePath, realRoot, entry.source);
237
315
  if (dir === undefined)
238
- continue;
316
+ return;
239
317
  // Two entries, one directory: the directory's findings were collected
240
318
  // twice and COUNTED twice (`PLUGIN_MISSING_AUTHOR: 2` for one file). Each
241
319
  // entry still gets its row — the manifest declared two — but the file is
242
320
  // inspected once and its findings enter `issues` once.
243
321
  const seen = validatedByDir.get(dir.real);
244
322
  if (seen !== undefined) {
245
- pluginResults.push({ ...entry, result: seen });
246
- continue;
323
+ pluginResults.push({ ...entry, ...seen });
324
+ return;
247
325
  }
248
- const result = await validateContainedPlugin(dir.lexical, marketplacePath, boundary, validation);
249
- validatedByDir.set(dir.real, result);
250
- pluginResults.push({ ...entry, result });
251
- issues.push(...result.issues);
326
+ const contained = await validateContainedPlugin(dir.lexical, marketplacePath, boundary, validation);
327
+ validatedByDir.set(dir.real, contained);
328
+ pluginResults.push({ ...entry, ...contained });
329
+ issues.push(...contained.result.issues);
252
330
  issues.push(...await validatePluginSkills(dir.lexical, marketplacePath, boundary, validation));
253
- }
331
+ });
254
332
  return {
255
333
  pluginResults,
256
334
  undeclared: undeclaredPluginDirs(marketplacePath, new Set(validatedByDir.keys())),
257
335
  refused: boundary.refused,
336
+ unread: boundary.unread,
258
337
  issues,
259
338
  };
260
339
  }
@@ -263,21 +342,26 @@ async function validateDeclaredPlugins(marketplacePath, declared, validation) {
263
342
  * of the root, in which case the manifest is refused by name and the plugin's
264
343
  * row says so instead of carrying findings about a file the run did not read.
265
344
  *
266
- * The row keeps `status: 'error'` with no issues: the error is the refusal
267
- * the builder publishes once for the run, and a `success` row for a plugin
268
- * whose manifest was never opened would be the reassuring lie this whole
269
- * boundary exists to refuse.
345
+ * The row is published with `manifestRead: false` and nothing counted: the
346
+ * error is the refusal the builder publishes once for the run, and a bare
347
+ * `ok` row for a plugin whose manifest was never opened would be the
348
+ * reassuring lie this whole boundary exists to refuse — `manifestRead` is
349
+ * what tells the two apart. A manifest the OS will not read is the same
350
+ * claim: the row is `manifestRead: false` and the builder names it in that refusal.
270
351
  */
271
352
  async function validateContainedPlugin(pluginDir, marketplacePath, boundary, validation) {
272
353
  const manifestPath = safePath.join(pluginDir, '.claude-plugin', 'plugin.json');
273
- if (existsSync(manifestPath) && !boundary.contains(manifestPath)) {
354
+ // No presence probe: `contains` reads the chain, and an absent (or dangling) manifest is inside.
355
+ if (!boundary.contains(manifestPath)) {
274
356
  return {
275
- path: pluginDir,
276
- type: 'claude-plugin',
277
- status: 'error',
278
- summary: `Plugin manifest not read: ${issueLocation(manifestPath, marketplacePath)} resolves outside the marketplace root`,
279
- issues: [],
280
- issueCounts: countBySeverity([]),
357
+ manifestRead: false,
358
+ result: {
359
+ path: pluginDir,
360
+ type: 'claude-plugin',
361
+ ...summarizeIssues([]),
362
+ description: `Plugin manifest not read: ${issueLocation(manifestPath, marketplacePath)} resolves outside the marketplace root`,
363
+ issues: [],
364
+ },
281
365
  };
282
366
  }
283
367
  // `locationRoot` is not optional here even though the parameter is: omitted,
@@ -286,12 +370,19 @@ async function validateContainedPlugin(pluginDir, marketplacePath, boundary, val
286
370
  // and skill findings beside them — and every plugin's manifest collapses to
287
371
  // the same `.claude-plugin/plugin.json`.
288
372
  const rawResult = await validatePlugin(pluginDir, { strict: true, locationRoot: marketplacePath });
373
+ // A manifest the OS refused is a `SCAN_PATH_UNREADABLE` WARNING from the
374
+ // validator — right for `vat audit`, a pass for this gate. Read off the RAW
375
+ // issues, so a severity override cannot turn "not read" back into "read".
376
+ const manifestLocation = issueLocation(manifestPath, marketplacePath);
377
+ const manifestRead = !rawResult.issues.some((issue) => issue.code === 'SCAN_PATH_UNREADABLE' && issue.location === manifestLocation);
289
378
  const pluginIssues = resolveIssueSeverity(rawResult.issues, validation);
290
379
  return {
291
- ...rawResult,
292
- issues: pluginIssues,
293
- status: calculateValidationStatus(pluginIssues),
294
- issueCounts: countBySeverity(pluginIssues),
380
+ manifestRead,
381
+ result: {
382
+ ...rawResult,
383
+ issues: pluginIssues,
384
+ ...summarizeIssues(pluginIssues),
385
+ },
295
386
  };
296
387
  }
297
388
  /**
@@ -304,15 +395,35 @@ async function validateContainedPlugin(pluginDir, marketplacePath, boundary, val
304
395
  */
305
396
  function undeclaredPluginDirs(marketplacePath, validatedDirs) {
306
397
  const pluginsDir = safePath.join(marketplacePath, 'plugins');
307
- if (!existsSync(pluginsDir))
398
+ if (!pathPresent(pluginsDir, { follow: marketplacePath }, everywhere('source'), 'probe'))
308
399
  return [];
309
400
  return readdirSync(pluginsDir, { withFileTypes: true })
310
401
  // Followed: a plugin directory that is a link is a plugin the marketplace
311
402
  // ships, and `validatedDirs` is real paths for exactly that reason.
312
- .filter((entry) => direntKindFollowingSync(pluginsDir, entry) === 'directory')
313
- .map((entry) => safePath.join(pluginsDir, entry.name))
314
- .filter((dir) => !validatedDirs.has(toForwardSlash(normalizePath(dir))))
315
- .map((dir) => issueLocation(dir, marketplacePath));
403
+ .flatMap((entry) => {
404
+ const dir = safePath.join(pluginsDir, entry.name);
405
+ const real = undeclaredCandidateIdentity(pluginsDir, entry, marketplacePath);
406
+ return real === undefined || validatedDirs.has(real) ? [] : [issueLocation(dir, marketplacePath)];
407
+ });
408
+ }
409
+ /**
410
+ * The real path of a `plugins/` entry that resolves to a directory, or `undefined` when it does
411
+ * not. An entry whose link chain names a network or device path is never followed: no declared
412
+ * source can resolve to it (the source lane refuses the same chain), so it is listed by its own
413
+ * spelling — named, never silently dropped.
414
+ */
415
+ function undeclaredCandidateIdentity(pluginsDir, entry, within) {
416
+ const dir = safePath.join(pluginsDir, entry.name);
417
+ try {
418
+ if (direntKindFollowingSync(pluginsDir, entry, within) !== 'directory')
419
+ return undefined;
420
+ return toForwardSlash(normalizePath(dir, within));
421
+ }
422
+ catch (error) {
423
+ if (!isLinkChainRefusedError(error))
424
+ throw error;
425
+ return dir;
426
+ }
316
427
  }
317
428
  /**
318
429
  * The `validation` config governing findings about `marketplacePath`.
@@ -352,7 +463,7 @@ function resolveProjectValidationConfig(marketplacePath, logger) {
352
463
  if (projectRoot === null)
353
464
  return undefined;
354
465
  try {
355
- return loadConfig(projectRoot)?.skills?.defaults?.validation;
466
+ return loadConfig(projectRoot, 'source')?.skills?.defaults?.validation;
356
467
  }
357
468
  catch (error) {
358
469
  logger.error(`Warning: could not read ${projectRoot} config for validation.severity overrides — ` +
@@ -378,8 +489,8 @@ function resolveProjectValidationConfig(marketplacePath, logger) {
378
489
  *
379
490
  * Severity resolution is likewise INSIDE this function rather than a step the
380
491
  * command adds after it. Its absence is the whole defect this addressed, and a
381
- * command-body step is one a caller can forget: with it here, the flat `issues`
382
- * list and `plugins[].issues` derive from a single resolved set, and the
492
+ * command-body step is one a caller can forget: with it here, the envelope's
493
+ * `findings` and the `data.plugins[]` tallies derive from a single resolved set, and the
383
494
  * smallest testable entry point is the one that includes the filter. The run's
384
495
  * `status` — and with it the exit code — is derived one step later, in
385
496
  * {@link buildMarketplaceValidateReport}, from the issues the document actually
@@ -402,70 +513,53 @@ export async function collectMarketplaceFindings(marketplacePath, logger) {
402
513
  // These issues are deliberately NOT severity-resolved: an override governs
403
514
  // findings ABOUT a marketplace that could be read, not the failure to read
404
515
  // one. Resolving them would let `MARKETPLACE_MISSING_MANIFEST: ignore` empty
405
- // the list and report `status: success` beside a summary saying the manifest
406
- // is missing — a run that never happened claiming it passed.
407
- if (marketplaceResult.status === 'error') {
516
+ // the list and report `status: ok` beside a manifest that is missing — a run that never happened claiming it passed.
517
+ if (marketplaceResult.summary.errors > 0) {
408
518
  return {
409
519
  marketplaceResult,
410
520
  pluginResults: [],
411
521
  undeclared: [],
412
522
  refused: [],
523
+ unread: [],
413
524
  issues: [...marketplaceResult.issues],
414
525
  };
415
526
  }
416
527
  const validation = resolveProjectValidationConfig(marketplacePath, logger);
417
528
  const fileIssues = checkMarketplaceFiles(marketplacePath);
418
- const { pluginResults, undeclared, refused, issues: pluginIssues } = await validateDeclaredPlugins(marketplacePath, marketplaceResult.metadata?.localPluginSources ?? [], validation);
529
+ const { pluginResults, undeclared, refused, unread, issues: pluginIssues } = await validateDeclaredPlugins(marketplacePath, marketplaceResult.metadata?.localPluginSources ?? [], validation);
419
530
  const issues = [
420
531
  ...resolveIssueSeverity(marketplaceResult.issues, validation),
421
532
  ...resolveIssueSeverity(fileIssues, validation),
422
533
  ...pluginIssues,
423
534
  ];
424
- return { marketplaceResult, pluginResults, undeclared, refused, issues };
535
+ return { marketplaceResult, pluginResults, undeclared, refused, unread, issues };
425
536
  }
426
537
  /**
427
- * Group key for findings that carry no `location` at all.
428
- *
429
- * A symbol rather than a sentinel string, and it is deliberately NOT published
430
- * as one: every `location` in this document must satisfy the anchor contract —
431
- * `join(root, location)` names a real file — so a row keyed `(no location)`
432
- * would be a path that resolves to nothing, which is the coordinate lie `root`
433
- * exists to prevent. The row is published with `unlocated: true` and no
434
- * `location` instead. Dropping such findings was the other option and is the
435
- * worse one: grouping by `location` is exactly the operation that silently
436
- * loses them, and a shorter summary is the reassuring failure.
437
- */
438
- const UNLOCATED = Symbol('unlocated');
439
- /**
440
- * Collapse a flat finding list onto one counts-only row per `location`.
441
- *
442
- * `location` is this command's per-asset unit: `plugins/alpha/.claude-plugin/
443
- * plugin.json`, `plugins/beta/skills/x/SKILL.md`. Rows come out in first-seen
444
- * order, and a location with no findings has no row — there is nothing to
445
- * filter here, because a location only exists in this listing by having emitted
446
- * something.
538
+ * The plugin entries the run examined: every REMOTE entry — the manifest's
539
+ * schema is its whole validation, and it passed — plus every declared local
540
+ * plugin the walk reached. A local entry whose source did not resolve is not
541
+ * counted; the builder's run-integrity finding names it.
447
542
  *
448
- * Every value is passed through un-rebased: `location` is already relative to
449
- * the report's stated `root`, and `relative()` is not idempotent (see
450
- * {@link MarketplaceValidateReportInput.root}).
543
+ * Remote entries count because an all-remote marketplace is a real verdict
544
+ * about a manifest whose every entry validated, not a run over nothing.
451
545
  */
452
- export function summarizeIssuesByLocation(issues) {
453
- const byLocation = new Map();
454
- for (const issue of issues) {
455
- const key = issue.location ?? UNLOCATED;
456
- const existing = byLocation.get(key);
457
- if (existing) {
458
- existing.push(issue);
459
- }
460
- else {
461
- byLocation.set(key, [issue]);
462
- }
463
- }
464
- return [...byLocation.entries()].map(([key, locationIssues]) => {
465
- const { codes, ...counts } = summarizeFindings(locationIssues);
466
- const anchor = typeof key === 'string' ? { location: key } : { unlocated: true };
467
- return { ...anchor, ...counts, codes };
468
- });
546
+ function pluginEntriesExamined(marketplace, pluginResults) {
547
+ const declared = marketplace?.pluginEntries ?? 0;
548
+ const local = marketplace?.localPluginSources?.length ?? 0;
549
+ return declared - local + pluginResults.length;
550
+ }
551
+ /** The manifest's facts the document publishes, or `null` when it did not validate. */
552
+ function marketplaceData(marketplace) {
553
+ if (marketplace === undefined)
554
+ return null;
555
+ const { name, description, version, pluginEntries, localPluginSources } = marketplace;
556
+ return {
557
+ ...(name === undefined ? {} : { name }),
558
+ ...(description === undefined ? {} : { description }),
559
+ ...(version === undefined ? {} : { version }),
560
+ ...(pluginEntries === undefined ? {} : { pluginEntries }),
561
+ ...(localPluginSources === undefined ? {} : { localPluginSources }),
562
+ };
469
563
  }
470
564
  /**
471
565
  * Build the report `vat claude marketplace validate` publishes on stdout.
@@ -475,57 +569,50 @@ export function summarizeIssuesByLocation(issues) {
475
569
  * builder serves both exits (manifest-missing bail and full run) so the
476
570
  * document has a single shape either way.
477
571
  *
572
+ * `status` and `summary` are derived by `buildReport` from the findings — the
573
+ * run-integrity refusal below included — so the status, the counts and the
574
+ * exit code cannot disagree. A plugin row's `summary` is the tally of the
575
+ * findings its own validator published; every finding itself is on the
576
+ * envelope, once.
577
+ *
478
578
  * Being pure is also the limit of what it can guarantee: it re-bases `path`,
479
579
  * and passes `issues` through verbatim. The single-coordinate-system property
480
580
  * is therefore only as true as its inputs — see `root` above — and is enforced
481
581
  * against a real marketplace in `payload-path-coordinates.test.ts`, not here.
482
582
  */
483
583
  export function buildMarketplaceValidateReport(input) {
484
- const { root, marketplace, pluginResults, undeclared, refused, bailSummary, duration, verbose } = input;
485
- const issues = [
486
- ...unfinishedRunFinding(marketplace, pluginResults, refused),
584
+ const { root, marketplace, pluginResults, undeclared, refused } = input;
585
+ const unread = [...unreadManifests(pluginResults, refused, root), ...input.unread];
586
+ const findings = toFindings([
587
+ ...unfinishedRunFinding(marketplace, pluginResults, refused, unread),
487
588
  ...input.issues,
488
- ];
489
- const issueCounts = countBySeverity(issues);
490
- const plugins = pluginResults.map(({ name, source, result }) => ({
589
+ ]);
590
+ const plugins = pluginResults.map(({ name, source, result, manifestRead }) => ({
491
591
  name,
492
592
  source,
493
- path: result.path,
494
- status: result.status,
495
- metadata: result.metadata,
496
- issues: result.issues,
593
+ path: relativizePath(result.path, root),
594
+ manifestRead,
595
+ ...summarizeIssues(toFindings(result.issues)),
497
596
  }));
498
- return {
499
- // Derived from the issues THIS document publishes — the refusal above
500
- // included — so the status, the counts and the listing cannot disagree, and
501
- // the exit code the command takes from it cannot either.
502
- status: calculateValidationStatus(issues),
503
- // Stated once, and the only absolute path in the document.
504
- root,
505
- ...(marketplace ? { marketplace } : {}),
506
- // The numerator. Beside `marketplace.localPluginSources` it says whether
507
- // every declared source resolved; without it "three local plugins, all
508
- // clean" and "three local plugins, none looked at" are the same document.
509
- pluginsValidated: pluginResults.length,
510
- plugins: relativizePathEntries(plugins, root),
511
- // Named, not graded — see `validateDeclaredPlugins`. Always present, so an
512
- // empty list is a statement that `plugins/` was looked at.
513
- undeclared: [...undeclared],
514
- // Paths the walk would not open (real path outside the root) — see
515
- // `WalkBoundary`. Always present: an empty list says every path the run
516
- // read was under `root`, which is the containment claim the help text makes.
517
- refused: [...refused],
518
- // One row per inspected asset by default; the flat per-issue list under
519
- // `--verbose`. Either way every `location` stays relative to `root` above.
520
- issues: verbose === true ? issues : summarizeIssuesByLocation(issues),
521
- // Counts ride beside the status: `status` names only the worst ACTIONABLE
522
- // severity, so an info-only run is `success` and the info would otherwise
523
- // be unreported.
524
- issueCounts,
525
- summary: bailSummary
526
- ?? `${issueCounts.errors} error(s), ${issueCounts.warnings} warning(s), ${issueCounts.info} info`,
527
- duration,
528
- };
597
+ return buildReport({
598
+ examined: pluginEntriesExamined(marketplace, pluginResults),
599
+ findings,
600
+ data: {
601
+ // Stated once, and the only absolute path in the document.
602
+ root,
603
+ marketplace: marketplaceData(marketplace),
604
+ plugins,
605
+ // Named, not graded — see `validateDeclaredPlugins`. Always present, so an
606
+ // empty list is a statement that `plugins/` was looked at.
607
+ undeclared: [...undeclared],
608
+ // Paths the walk would not open (real path outside the root) — see
609
+ // `WalkBoundary`. Always present: an empty list says every path the run
610
+ // read was under `root`, which is the containment claim the help text makes.
611
+ refused: [...refused],
612
+ },
613
+ gate: GATE,
614
+ durationMs: input.durationMs,
615
+ });
529
616
  }
530
617
  /**
531
618
  * The refusal for a run in which a declared local source did not resolve.
@@ -570,10 +657,10 @@ export function buildMarketplaceValidateReport(input) {
570
657
  * @param refused - Root-relative paths the walk would not open
571
658
  * @returns The one finding, or nothing
572
659
  */
573
- function unfinishedRunFinding(marketplace, validated, refused) {
660
+ function unfinishedRunFinding(marketplace, validated, refused, unread) {
574
661
  const declared = marketplace?.localPluginSources ?? [];
575
662
  const unresolved = declared.filter((entry) => !validated.some((v) => v.name === entry.name && v.source === entry.source));
576
- if (unresolved.length === 0 && refused.length === 0)
663
+ if (unresolved.length === 0 && refused.length === 0 && unread.length === 0)
577
664
  return [];
578
665
  const parts = [];
579
666
  if (unresolved.length > 0) {
@@ -596,17 +683,46 @@ function unfinishedRunFinding(marketplace, validated, refused) {
596
683
  + ' they hold — this command never leaves the directory it was pointed at. Replace each link'
597
684
  + ' with the files it points at, or move its target under the marketplace root.');
598
685
  }
686
+ if (unread.length > 0) {
687
+ const named = unread.map((path) => `\`${path}\``).join(', ');
688
+ parts.push(`The operating system refused to let this run read ${unread.length} path(s) inside a validated plugin: ${named}`
689
+ + ' (the SCAN_PATH_UNREADABLE finding beside each names the errno). Nothing behind them was'
690
+ + ' checked — a plugin.json\'s manifest checks, a skill\'s SKILL.md checks — so this document is'
691
+ + ' not a verdict about them. Make each path readable — check its permissions and ownership — and re-run.');
692
+ }
599
693
  return [runIntegrityFinding(parts.join(' '))];
600
694
  }
601
695
  /**
602
- * Validate a marketplace and hand back its document and exit code, printing
603
- * nothing on stdout.
696
+ * The root-relative manifest of every plugin row whose manifest was not read
697
+ * for a reason OTHER than a link out of the root — those are already named in
698
+ * `refused`. Derived from the document's own rows, like the rest of the refusal.
699
+ */
700
+ function unreadManifests(pluginResults, refused, root) {
701
+ const manifests = pluginResults
702
+ .filter((row) => !row.manifestRead)
703
+ .map((row) => toForwardSlash(safePath.join(relativizePath(row.result.path, root), '.claude-plugin', 'plugin.json')))
704
+ .filter((manifest) => !refused.includes(manifest));
705
+ return [...new Set(manifests)];
706
+ }
707
+ /** The human half, on stderr: every error in full, and the rest under `--verbose`. */
708
+ function logFindings(report, verbose, logger) {
709
+ for (const finding of report.findings) {
710
+ if (!verbose && finding.severity !== 'error' && finding.code !== RUN_INTEGRITY_CODE)
711
+ continue;
712
+ const anchor = finding.location === undefined ? '' : `${finding.location}: `;
713
+ logger.error(` ${anchor}${finding.severity}: ${finding.message} [${finding.code}]`);
714
+ }
715
+ const { errors, warnings, info } = report.summary;
716
+ logger.info(`${errors} error(s), ${warnings} warning(s), ${info} info`);
717
+ }
718
+ /**
719
+ * Validate a marketplace and hand back its report, printing nothing on stdout.
604
720
  *
605
721
  * The phase entry point for `vat verify`, which runs this once per configured
606
- * marketplace IN ITS OWN PROCESS. Progress and findings still go to stderr as
607
- * they always did; only the decision of where the document lands moves to the
608
- * caller — stdout for a command-line run, `phases[].report` for an orchestrated
609
- * one.
722
+ * marketplace, and the command's own. The report is the one BEFORE the
723
+ * writer's run-integrity pass: inside an orchestrator, `runPhase` applies the same
724
+ * pass to this phase's report, by the declaration this verb gives its own writer. A refusal is the envelope's error
725
+ * branch, its message already on stderr.
610
726
  */
611
727
  export async function runMarketplaceValidatePhase(targetPath, options) {
612
728
  const logger = createLogger(options.debug ? { debug: true } : {});
@@ -614,39 +730,54 @@ export async function runMarketplaceValidatePhase(targetPath, options) {
614
730
  try {
615
731
  const marketplacePath = safePath.resolve(targetPath ?? '.');
616
732
  logger.info(`Validating marketplace: ${marketplacePath}`);
617
- const { marketplaceResult, pluginResults, undeclared, refused, issues } = await collectMarketplaceFindings(marketplacePath, logger);
618
- // A bailed run reports WHY it stopped; a completed run reports what it
619
- // found. Both emit through the one builder, so the document has a single
620
- // shape either way.
621
- const bailed = marketplaceResult.status === 'error';
622
- const document = buildMarketplaceValidateReport({
733
+ const { marketplaceResult, pluginResults, undeclared, refused, unread, issues } = await collectMarketplaceFindings(marketplacePath, logger);
734
+ const report = buildMarketplaceValidateReport({
623
735
  root: marketplacePath,
624
736
  marketplace: marketplaceResult.metadata,
625
737
  pluginResults,
626
738
  undeclared,
627
739
  refused,
740
+ unread,
628
741
  issues,
629
- ...(bailed ? { bailSummary: marketplaceResult.summary } : {}),
630
- duration: formatDuration(Date.now() - startTime),
631
- verbose: options.verbose === true,
742
+ durationMs: Date.now() - startTime,
632
743
  });
633
- // From the DOCUMENT, so the exit code and the published status are one
634
- // derivation — the run-integrity refusal lands in the builder, and an exit
635
- // code computed upstream of it would answer 0 over `status: error`.
636
- return { document, exitCode: document.status === 'error' ? 1 : 0 };
744
+ logFindings(report, options.verbose === true, logger);
745
+ return { report };
637
746
  }
638
747
  catch (error) {
639
- return {
640
- document: reportCommandError(error, logger, startTime, 'MarketplaceValidate'),
641
- exitCode: 2,
642
- failed: true,
643
- };
748
+ return { report: refusedReport(error) };
644
749
  }
645
750
  }
751
+ /** The error branch for a run that could not do its job — classified by code, never by message. */
752
+ function refusedReport(error) {
753
+ return refusalReport(refusalCodeOf(error), error, GATE, NOTHING_FINISHED);
754
+ }
755
+ /**
756
+ * The command lane: the operator's `[path]` is judged before anything runs.
757
+ *
758
+ * A path naming nothing is the invocation's mistake (`USAGE_INVALID`); one the
759
+ * OS will not list is the input's (`INPUT_UNREADABLE`). Neither is a finding
760
+ * about a marketplace. Only the TYPED argument is judged: `vat verify` hands
761
+ * the phase a path it computed (`dist/.claude/plugins/marketplaces/<name>`),
762
+ * where an absent directory is an unbuilt marketplace — a finding about the
763
+ * project (`MARKETPLACE_MISSING_MANIFEST`), not an invocation mistake.
764
+ */
646
765
  async function marketplaceValidateCommand(targetPath, options) {
647
- // `undefined`: this command offers no `--format`, so its failure envelope is
648
- // YAML like its report.
649
- finishCommand(await runMarketplaceValidatePhase(targetPath, options), writeYamlOutput, undefined);
766
+ let report;
767
+ try {
768
+ const marketplacePath = assertReadableDirectoryArgument(targetPath ?? '.');
769
+ ({ report } = await runMarketplaceValidatePhase(marketplacePath, options));
770
+ }
771
+ catch (error) {
772
+ // Only the argument check throws here: the phase returns its own refusals.
773
+ report = refusedReport(error);
774
+ }
775
+ const published = publishedReport('claude marketplace validate', report);
776
+ // The writer's own zero-examined refusal, warned in the lane that publishes it.
777
+ if (published !== report)
778
+ warnRunIntegrity(published);
779
+ // This command offers no `--format`: its document is YAML.
780
+ endWithReport('claude marketplace validate', published, 'yaml');
650
781
  }
651
782
  export function createMarketplaceValidateCommand() {
652
783
  const command = new Command('validate');
@@ -654,7 +785,7 @@ export function createMarketplaceValidateCommand() {
654
785
  .description('Validate a marketplace directory for publishing')
655
786
  .argument('[path]', 'Path to marketplace directory (default: current directory)')
656
787
  .option('-d, --debug', 'Enable debug logging')
657
- .option('-v, --verbose', 'Show all scanned resources, including those without issues')
788
+ .option('-v, --verbose', 'Print every finding in full on stderr, not only the errors')
658
789
  .action(marketplaceValidateCommand)
659
790
  .addHelpText('after', `
660
791
  Description:
@@ -663,40 +794,53 @@ Description:
663
794
 
664
795
  Plugin versions are required (error, not warning) in strict marketplace validation.
665
796
 
666
- Output (YAML on stdout):
667
- root: the marketplace directory — every location below is relative to it
668
- status, issueCounts, summary, duration, marketplace, plugins
669
- pluginsValidated: how many of the manifest's relative-path sources
670
- (marketplace.localPluginSources) resolved to a directory and were
671
- validated — each plugins[] row names the entry it satisfies. A
672
- declared source that does not resolve is reported as
673
- RESOURCE_CHECK_BROKEN at error (exit 1), naming it, rather than as
674
- a pass — a plugin the manifest ships and this run never saw is not
675
- a verdict. A source is never followed outside the root: an absolute
676
- path or a ".." segment fails the manifest schema, and a symlink that
677
- points out is refused like an unresolved source. Co-located
678
- marketplaces (source: "./") are validated at the root. An
679
- all-remote marketplace has nothing local and stays green.
680
- undeclared: directories under plugins/ that no manifest entry names.
797
+ Output (YAML on stdout — the report envelope):
798
+ status: ok | findings | error. findings means at least one finding was
799
+ published; error means the run did not finish (error.code says why).
800
+ examined: the plugin entries validated — every remote entry of
801
+ marketplace.json plus each declared local plugin the walk reached.
802
+ summary: the findings by severity.
803
+ findings[]: every finding, flat — {code, severity, message, location, …};
804
+ location is relative to data.root.
805
+ data.root: the marketplace directory — every path in the document is
806
+ relative to it.
807
+ data.marketplace: the manifest's name, version, pluginEntries and
808
+ localPluginSources; null when the manifest is missing or invalid.
809
+ data.plugins[]: one row per declared local plugin walked — {name, source,
810
+ path, manifestRead, status, summary}. A declared source that does
811
+ not resolve is reported as RESOURCE_CHECK_BROKEN at error (exit 1),
812
+ naming it, rather than as a pass — a plugin the manifest ships and
813
+ this run never saw is not a verdict. A source is never followed
814
+ outside the root: an absolute path or a ".." segment fails the
815
+ manifest schema, and a symlink that points out is refused like an
816
+ unresolved source. Co-located marketplaces (source: "./") are
817
+ validated at the root. An all-remote marketplace has nothing local
818
+ to walk; its entries still count as examined.
819
+ data.undeclared: directories under plugins/ that no manifest entry names.
681
820
  Listed only — they cannot be installed, so they are neither
682
821
  validated nor a failure.
683
- refused: paths inside a validated plugin this run would not open because
684
- they resolve outside the root (a skills/ dir, skill dir, SKILL.md
685
- or plugin.json that is a symlink pointing out). Containment is by
686
- real path at every depth, not only at the declared source; each is
687
- named here and in the RESOURCE_CHECK_BROKEN finding (exit 1).
688
-
689
- issues: one row per inspected location, carrying only that location's counts
690
- ({location, errors?, warnings?, info?, codes}). A zero bucket is
691
- omitted, and a location with no findings has no row.
822
+ data.refused: paths inside a validated plugin this run would not open
823
+ because they resolve outside the root (a skills/ dir, skill dir,
824
+ SKILL.md or plugin.json that is a symlink pointing out). Containment
825
+ is by real path at every depth, not only at the declared source;
826
+ each is named here and in the RESOURCE_CHECK_BROKEN finding (exit 1).
827
+ A plugin.json the OS will not read is the same: its row is
828
+ manifestRead: false and the RESOURCE_CHECK_BROKEN finding names it
829
+ (exit 1) beside the SCAN_PATH_UNREADABLE warning — never a pass. So
830
+ is a plugin's skills/ directory the OS will not list, or a skill
831
+ directory or SKILL.md it will not stat or read: named in that
832
+ finding (exit 1), each beside its SCAN_PATH_UNREADABLE warning.
692
833
 
693
- --verbose replaces those rows with the flat per-issue list (message, fix and
694
- all). That form is for '> file' then grep, not for reading.
834
+ stderr prints every error in full; --verbose adds every warning and info.
835
+ The document is the same either way.
695
836
 
696
- Exit Codes:
697
- 0 - All validations passed (warnings allowed)
698
- 1 - Validation errors found
699
- 2 - System error (directory not found, etc.)
837
+ Exit Codes (derived from the document):
838
+ 0 - status ok, or findings with no error-severity finding
839
+ 1 - status findings with at least one error-severity finding (including a
840
+ marketplace declaring no plugin entry: nothing was examined)
841
+ 2 - status error: the run did not finish — USAGE_INVALID for a path that
842
+ does not exist or is not a directory, INPUT_UNREADABLE for one the OS
843
+ will not list
700
844
 
701
845
  Example:
702
846
  $ vat claude marketplace validate . # Validate current directory