@vibe-agent-toolkit/cli 0.2.0-rc.10 → 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 +94 -40
  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 +94 -40
  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 +31 -63
  87. package/dist/commands/ard/emit.d.ts.map +1 -1
  88. package/dist/commands/ard/emit.js +124 -68
  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 +17 -10
  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 +415 -397
  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 +87 -2
  148. package/dist/commands/claude/context.d.ts.map +1 -1
  149. package/dist/commands/claude/context.js +116 -57
  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 +13 -10
  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 -145
  355. package/dist/commands/okf/validate.d.ts.map +1 -1
  356. package/dist/commands/okf/validate.js +63 -52
  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 +79 -13
  404. package/dist/commands/resources/check-progress.d.ts.map +1 -1
  405. package/dist/commands/resources/check-progress.js +112 -11
  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 +329 -71
  412. package/dist/commands/resources/check-supervisor.d.ts.map +1 -1
  413. package/dist/commands/resources/check-supervisor.js +507 -107
  414. package/dist/commands/resources/check-supervisor.js.map +1 -1
  415. package/dist/commands/resources/check.d.ts +88 -254
  416. package/dist/commands/resources/check.d.ts.map +1 -1
  417. package/dist/commands/resources/check.js +537 -310
  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 +189 -103
  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 +18 -13
  427. package/dist/commands/resources/query.d.ts.map +1 -1
  428. package/dist/commands/resources/query.js +61 -49
  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 -77
  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 -28
  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 +44 -5
  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 +18 -11
  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 +78 -32
  665. package/dist/utils/resource-loader.d.ts.map +1 -1
  666. package/dist/utils/resource-loader.js +134 -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 +17 -20
  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 +228 -107
  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 +280 -118
  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 -189
  753. package/dist/utils/command-error.d.ts.map +0 -1
  754. package/dist/utils/command-error.js +0 -230
  755. package/dist/utils/command-error.js.map +0 -1
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/commands/ard/index.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,OAAO,EAAU,MAAM,WAAW,CAAC;AAI5C,OAAO,EACL,cAAc,EACd,kBAAkB,EAClB,UAAU,EACV,qBAAqB,EACrB,kBAAkB,EAClB,KAAK,aAAa,GACnB,MAAM,WAAW,CAAC;AACnB,OAAO,EAAE,kBAAkB,EAAE,KAAK,oBAAoB,EAAE,KAAK,iBAAiB,EAAE,MAAM,eAAe,CAAC;AAEtG,yCAAyC;AACzC,wBAAgB,gBAAgB,IAAI,OAAO,CAgF1C"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/commands/ard/index.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,OAAO,EAAU,MAAM,WAAW,CAAC;AAI5C,OAAO,EACL,cAAc,EACd,kBAAkB,EAClB,UAAU,EACV,qBAAqB,EACrB,kBAAkB,EAClB,KAAK,aAAa,GACnB,MAAM,WAAW,CAAC;AACnB,OAAO,EAAE,kBAAkB,EAAE,KAAK,oBAAoB,EAAE,KAAK,iBAAiB,EAAE,MAAM,eAAe,CAAC;AAEtG,yCAAyC;AACzC,wBAAgB,gBAAgB,IAAI,OAAO,CAuF1C"}
@@ -61,16 +61,23 @@ Requirements:
61
61
  \`data\` and emission fails.
62
62
 
63
63
  Exit Codes:
64
- 0 - Manifest written — INCLUDING one that advertises nothing. An empty
65
- \`entries\` list is a legal ARD document, and skipped surfaces are reported
66
- on stderr at this exit code. Gate on \`--format json\` (the report
67
- envelope: \`examined\`, \`findings\`, \`summary\`, \`data.entryCount\`,
68
- \`data.skippedCount\`; schema: packages/cli/schemas/ard-emit.json), or
69
- make both conditions fail with \`--strict\`
70
- 1 - No \`ard:\` block in the config, or a surface could not be derived. Under
71
- \`--strict\`, also an empty manifest or a skipped surface
72
- 2 - System error (no project root, no config file, invalid config, unexpected
73
- internal failure)
64
+ 0 - Manifest written over at least one configured surface. Skipped surfaces
65
+ are reported on stderr at this exit code. Gate on \`--format json\` (the
66
+ report envelope: \`examined\`, \`findings\`, \`summary\`, \`gate\`,
67
+ \`data.entryCount\`, \`data.skippedCount\`; schema:
68
+ packages/cli/schemas/ard-emit.json), or make skips fail with \`--strict\`
69
+ 1 - No \`ard:\` block, or a surface that could not be derived — each an
70
+ error-severity finding about the PROJECT (ARD_NOT_CONFIGURED,
71
+ ARD_DERIVATION_FAILED), with \`data.outputPath\` null as nothing was
72
+ written. An \`ard:\` block that reaches no surface at all examined
73
+ nothing, and is refused (RESOURCE_CHECK_BROKEN). Under \`--strict\`, also
74
+ an empty manifest or a skipped surface (ARD_STRICT_REFUSED). The code is
75
+ derived from the published report, never chosen beside it
76
+ 2 - The command could not do its job; \`error.code\` says which: USAGE_INVALID
77
+ (no such project root), CONFIG_INVALID (no config file, or one that does
78
+ not parse), INPUT_UNREADABLE (a config the OS will not read),
79
+ RUN_INCOMPLETE (the OS refused the --output write), INTERNAL_ERROR (a
80
+ VAT defect)
74
81
 
75
82
  Example:
76
83
  $ vat ard emit --format json --strict
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/commands/ard/index.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,OAAO,EAAE,MAAM,EAAE,MAAM,WAAW,CAAC;AAE5C,OAAO,EAAE,cAAc,EAAE,kBAAkB,EAAE,MAAM,WAAW,CAAC;AAE/D,OAAO,EACL,cAAc,EACd,kBAAkB,EAClB,UAAU,EACV,qBAAqB,EACrB,kBAAkB,GAEnB,MAAM,WAAW,CAAC;AACnB,OAAO,EAAE,kBAAkB,EAAqD,MAAM,eAAe,CAAC;AAEtG,yCAAyC;AACzC,MAAM,UAAU,gBAAgB;IAC9B,MAAM,GAAG,GAAG,IAAI,OAAO,CAAC,KAAK,CAAC,CAAC;IAE/B,GAAG,CAAC,WAAW,CAAC,oEAAoE,CAAC,CAAC,WAAW,CAC/F,OAAO,EACP;;;;;;;CAOH,CACE,CAAC;IAEF,GAAG;SACA,OAAO,CAAC,MAAM,CAAC;SACf,WAAW,CAAC,6CAA6C,CAAC;SAC1D,MAAM,CAAC,qBAAqB,EAAE,yBAAyB,kBAAkB,GAAG,CAAC;SAC7E,MAAM,CAAC,sBAAsB,EAAE,qDAAqD,CAAC;SACrF,SAAS;IACR,sEAAsE;IACtE,sEAAsE;IACtE,2DAA2D;IAC3D,IAAI,MAAM,CAAC,mBAAmB,EAAE,uCAAuC,CAAC;SACrE,OAAO,CAAC,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;SACzB,OAAO,CAAC,MAAM,CAAC,CACnB;SACA,MAAM,CACL,UAAU,EACV,kFAAkF,CACnF;SACA,MAAM,CAAC,SAAS,EAAE,2BAA2B,CAAC;SAC9C,MAAM,CAAC,cAAc,CAAC;SACtB,WAAW,CACV,OAAO,EACP;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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;IAEJ,OAAO,GAAG,CAAC;AACb,CAAC"}
@@ -0,0 +1,65 @@
1
+ /**
2
+ * What the `--compat` and `--settings` lanes of `vat audit` found, as findings.
3
+ *
4
+ * The lanes publish their answers as blocks on the plugin's row (`data.files[].compatibility`,
5
+ * `.settings`). A block is not a finding: a plugin whose skill the org policy blocks was
6
+ * `status: ok`, `findings: []`, `summary: {0, 0, 0}` beside a stderr line saying a conflict was
7
+ * found — the human channel and the document disagreeing about one run. Each thing a lane found,
8
+ * and each thing it could not look at, is therefore ALSO a finding on the plugin's own result, so
9
+ * the envelope's status, the row's status and the file counts are derived from it like any other.
10
+ *
11
+ * Pure: it reads the rendered blocks and decides nothing about severity at run time.
12
+ */
13
+ import type { ValidationIssue } from '@vibe-agent-toolkit/schema';
14
+ /** A path a lane never examined, as the document renders it: root-relative, with the reason. */
15
+ interface UncheckedPath {
16
+ readonly path: string;
17
+ readonly reason: string;
18
+ }
19
+ /** As much of the two rendered blocks as a finding is derived from. */
20
+ export interface CompatLaneAnswer {
21
+ /** The analyzer's block: its unchecked paths, or the reason it could not run for the plugin at all. */
22
+ readonly compatibility: {
23
+ readonly analyzed: false;
24
+ readonly reason: string;
25
+ } | {
26
+ readonly unchecked: readonly UncheckedPath[];
27
+ };
28
+ /** The settings block, present iff the run asked for `--settings`. */
29
+ readonly settings?: {
30
+ readonly compatible: boolean;
31
+ readonly conflicts: ReadonlyArray<{
32
+ readonly detail: string;
33
+ readonly settingsFile: string;
34
+ readonly settingsLevel: string;
35
+ }>;
36
+ readonly unchecked?: readonly UncheckedPath[];
37
+ };
38
+ }
39
+ /** A finding the document already carries: as much of it as the dedupe reads. */
40
+ export interface FiledFinding {
41
+ readonly code: string;
42
+ readonly location: string;
43
+ }
44
+ /**
45
+ * The findings one plugin's lane answers amount to:
46
+ *
47
+ * - `SETTINGS_POLICY_CONFLICT` for each settings conflict — a tool, a hook, an MCP server or a
48
+ * model the plugin declares and the effective settings block — on the plugin;
49
+ * - `COMPAT_NOT_CHECKED` when the analyzer could not run for the plugin at all, on the plugin;
50
+ * - `COMPAT_NOT_CHECKED` for each path a lane could not examine, at that path — unless the
51
+ * document already carries that path's refusal ({@link SAME_REFUSAL_CODES}), or this call has
52
+ * just filed the plugin itself as not checked: one refused path is one finding, however many
53
+ * lanes met it.
54
+ *
55
+ * Each is a `warning`: the lanes are advisory, as `COMPAT_TARGET_INCOMPATIBLE` and the sibling
56
+ * verb's `SETTINGS_RULE_SHADOWED` are, so they move the status and the counts and never the exit code.
57
+ *
58
+ * @param pluginLocation - The plugin's own row path, root-relative (`.` for the scan root)
59
+ * @param answer - The two blocks as the document renders them
60
+ * @param filed - Every finding the document already carries, each with the location it is published at
61
+ * @returns The lanes' findings for this plugin, conflicts first
62
+ */
63
+ export declare function compatLaneIssues(pluginLocation: string, answer: CompatLaneAnswer, filed: readonly FiledFinding[]): ValidationIssue[];
64
+ export {};
65
+ //# sourceMappingURL=compat-lane-findings.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"compat-lane-findings.d.ts","sourceRoot":"","sources":["../../../src/commands/audit/compat-lane-findings.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAEH,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,4BAA4B,CAAC;AAElE,gGAAgG;AAChG,UAAU,aAAa;IACrB,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;CACzB;AAED,uEAAuE;AACvE,MAAM,WAAW,gBAAgB;IAC/B,uGAAuG;IACvG,QAAQ,CAAC,aAAa,EAAE;QAAE,QAAQ,CAAC,QAAQ,EAAE,KAAK,CAAC;QAAC,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAA;KAAE,GAAG;QAAE,QAAQ,CAAC,SAAS,EAAE,SAAS,aAAa,EAAE,CAAA;KAAE,CAAC;IACjI,sEAAsE;IACtE,QAAQ,CAAC,QAAQ,CAAC,EAAE;QAClB,QAAQ,CAAC,UAAU,EAAE,OAAO,CAAC;QAC7B,QAAQ,CAAC,SAAS,EAAE,aAAa,CAAC;YAAE,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;YAAC,QAAQ,CAAC,YAAY,EAAE,MAAM,CAAC;YAAC,QAAQ,CAAC,aAAa,EAAE,MAAM,CAAA;SAAE,CAAC,CAAC;QAC9H,QAAQ,CAAC,SAAS,CAAC,EAAE,SAAS,aAAa,EAAE,CAAC;KAC/C,CAAC;CACH;AAED,iFAAiF;AACjF,MAAM,WAAW,YAAY;IAC3B,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;CAC3B;AAyBD;;;;;;;;;;;;;;;;;;GAkBG;AACH,wBAAgB,gBAAgB,CAAC,cAAc,EAAE,MAAM,EAAE,MAAM,EAAE,gBAAgB,EAAE,KAAK,EAAE,SAAS,YAAY,EAAE,GAAG,eAAe,EAAE,CAiBpI"}
@@ -0,0 +1,72 @@
1
+ /**
2
+ * What the `--compat` and `--settings` lanes of `vat audit` found, as findings.
3
+ *
4
+ * The lanes publish their answers as blocks on the plugin's row (`data.files[].compatibility`,
5
+ * `.settings`). A block is not a finding: a plugin whose skill the org policy blocks was
6
+ * `status: ok`, `findings: []`, `summary: {0, 0, 0}` beside a stderr line saying a conflict was
7
+ * found — the human channel and the document disagreeing about one run. Each thing a lane found,
8
+ * and each thing it could not look at, is therefore ALSO a finding on the plugin's own result, so
9
+ * the envelope's status, the row's status and the file counts are derived from it like any other.
10
+ *
11
+ * Pure: it reads the rendered blocks and decides nothing about severity at run time.
12
+ */
13
+ /**
14
+ * The codes that already SAY "this path was not read": the scan's own refusal of it, the
15
+ * validator's refusal of its frontmatter (the settings check lists that same file as unchecked),
16
+ * and this lane's own finding for another plugin that holds the path. Only a finding of one of
17
+ * these at a path makes a `COMPAT_NOT_CHECKED` there a repeat — an unrelated finding that happens
18
+ * to sit at the same location says nothing about whether the lanes read it.
19
+ */
20
+ const SAME_REFUSAL_CODES = new Set(['SCAN_PATH_UNREADABLE', 'SKILL_MISSING_FRONTMATTER', 'COMPAT_NOT_CHECKED']);
21
+ const NOT_CHECKED_FIX = 'Make the path readable and well-formed, then re-run; until then the compatibility and settings answers for this plugin do not cover it.';
22
+ function notChecked(location, message) {
23
+ return { code: 'COMPAT_NOT_CHECKED', severity: 'warning', message, location, fix: NOT_CHECKED_FIX };
24
+ }
25
+ /** Every path either lane could not examine, each once, with the first reason given for it. */
26
+ function uncheckedPaths(answer) {
27
+ const byPath = new Map();
28
+ const all = ['unchecked' in answer.compatibility ? answer.compatibility.unchecked : [], answer.settings?.unchecked ?? []].flat();
29
+ for (const unchecked of all)
30
+ if (!byPath.has(unchecked.path))
31
+ byPath.set(unchecked.path, unchecked);
32
+ return [...byPath.values()];
33
+ }
34
+ /**
35
+ * The findings one plugin's lane answers amount to:
36
+ *
37
+ * - `SETTINGS_POLICY_CONFLICT` for each settings conflict — a tool, a hook, an MCP server or a
38
+ * model the plugin declares and the effective settings block — on the plugin;
39
+ * - `COMPAT_NOT_CHECKED` when the analyzer could not run for the plugin at all, on the plugin;
40
+ * - `COMPAT_NOT_CHECKED` for each path a lane could not examine, at that path — unless the
41
+ * document already carries that path's refusal ({@link SAME_REFUSAL_CODES}), or this call has
42
+ * just filed the plugin itself as not checked: one refused path is one finding, however many
43
+ * lanes met it.
44
+ *
45
+ * Each is a `warning`: the lanes are advisory, as `COMPAT_TARGET_INCOMPATIBLE` and the sibling
46
+ * verb's `SETTINGS_RULE_SHADOWED` are, so they move the status and the counts and never the exit code.
47
+ *
48
+ * @param pluginLocation - The plugin's own row path, root-relative (`.` for the scan root)
49
+ * @param answer - The two blocks as the document renders them
50
+ * @param filed - Every finding the document already carries, each with the location it is published at
51
+ * @returns The lanes' findings for this plugin, conflicts first
52
+ */
53
+ export function compatLaneIssues(pluginLocation, answer, filed) {
54
+ const refused = new Set(filed.filter((finding) => SAME_REFUSAL_CODES.has(finding.code)).map((finding) => finding.location));
55
+ const issues = (answer.settings?.conflicts ?? []).map((conflict) => ({
56
+ code: 'SETTINGS_POLICY_CONFLICT',
57
+ severity: 'warning',
58
+ message: `${conflict.detail} — ${conflict.settingsFile} (${conflict.settingsLevel} settings).`,
59
+ location: pluginLocation,
60
+ fix: 'Remove what the policy blocks from the plugin, or change the settings rule the message names.',
61
+ }));
62
+ if ('analyzed' in answer.compatibility) {
63
+ issues.push(notChecked(pluginLocation, `The compatibility analysis could not run for this plugin, so the run has no compatibility answer for it: ${answer.compatibility.reason}`));
64
+ refused.add(pluginLocation);
65
+ }
66
+ for (const { path, reason } of uncheckedPaths(answer)) {
67
+ if (!refused.has(path))
68
+ issues.push(notChecked(path, `The compatibility and settings checks could not examine this path, so their answers for the plugin do not cover it: ${reason}`));
69
+ }
70
+ return issues;
71
+ }
72
+ //# sourceMappingURL=compat-lane-findings.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"compat-lane-findings.js","sourceRoot":"","sources":["../../../src/commands/audit/compat-lane-findings.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AA4BH;;;;;;GAMG;AACH,MAAM,kBAAkB,GAAwB,IAAI,GAAG,CAAC,CAAC,sBAAsB,EAAE,2BAA2B,EAAE,oBAAoB,CAAC,CAAC,CAAC;AAErI,MAAM,eAAe,GAAG,yIAAyI,CAAC;AAElK,SAAS,UAAU,CAAC,QAAgB,EAAE,OAAe;IACnD,OAAO,EAAE,IAAI,EAAE,oBAAoB,EAAE,QAAQ,EAAE,SAAS,EAAE,OAAO,EAAE,QAAQ,EAAE,GAAG,EAAE,eAAe,EAAE,CAAC;AACtG,CAAC;AAED,+FAA+F;AAC/F,SAAS,cAAc,CAAC,MAAwB;IAC9C,MAAM,MAAM,GAAG,IAAI,GAAG,EAAyB,CAAC;IAChD,MAAM,GAAG,GAAG,CAAC,WAAW,IAAI,MAAM,CAAC,aAAa,CAAC,CAAC,CAAC,MAAM,CAAC,aAAa,CAAC,SAAS,CAAC,CAAC,C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AAG,CAAC,cAAc,CAAC,CAAC;IAC9B,CAAC;IACD,KAAK,MAAM,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,cAAc,CAAC,MAAM,CAAC,EAAE,CAAC;QACtD,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,CAAC;YAAE,MAAM,CAAC,IAAI,CAAC,UAAU,CAAC,IAAI,EAAE,uHAAuH,MAAM,EAAE,CAAC,CAAC,CAAC;IACzL,CAAC;IACD,OAAO,MAAM,CAAC;AAChB,CAAC"}
@@ -188,7 +188,7 @@ export declare function isWithin(root: string, absolutePath: string): boolean;
188
188
  * Classify the tree holding `skillMdPath`. See this module's header for the
189
189
  * reasoning behind each clause and the order they are applied in.
190
190
  */
191
- export declare function classifyScannedSkillTree(skillMdPath: string): Promise<SkillTreeProvenance>;
191
+ export declare function classifyScannedSkillTree(skillMdPath: string, within: string): Promise<SkillTreeProvenance>;
192
192
  /**
193
193
  * Will a crawl rooted at this SKILL.md's directory actually report the WHOLE
194
194
  * subtree beneath it — nested skills included?
@@ -203,7 +203,7 @@ export declare function classifyScannedSkillTree(skillMdPath: string): Promise<S
203
203
  * skill, and a scan rooted above `<claudeDir>/skills` reaches an install root
204
204
  * from outside one.
205
205
  */
206
- export declare function crawlOwnsSubtree(skillMdPath: string): Promise<boolean>;
206
+ export declare function crawlOwnsSubtree(skillMdPath: string, within: string): Promise<boolean>;
207
207
  /**
208
208
  * The agent-instruction files present in a skill's own directory, when that
209
209
  * directory is a distributed tree. Empty otherwise — including when the caller
@@ -1 +1 @@
1
- {"version":3,"file":"distributed-tree.d.ts","sourceRoot":"","sources":["../../../src/commands/audit/distributed-tree.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA0FG;AAGH,OAAO,EAAsB,KAAK,gBAAgB,EAAE,MAAM,wCAAwC,CAAC;AACnG,O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CAAC;AACnG,OAAO,EAAE,KAAK,eAAe,EAAE,MAAM,4BAA4B,CAAC;AAOlE,OAAO,EAEL,UAAU,EACX,MAAM,+BAA+B,CAAC;AAKvC;;;;;;GAMG;AACH,wBAAsB,qBAAqB,CAAC,OAAO,EAAE,MAAM,GAAG,OAAO,CAAC,UAAU,CAAC,CAShF;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAuDG;AACH,eAAO,MAAM,wBAAwB,EAAE,gBAmBtC,CAAC;AAcF,iEAAiE;AACjE,wBAAgB,oBAAoB,IAAI,IAAI,CAG3C;AAED;;;;;;;;;;GAUG;AACH,MAAM,MAAM,mBAAmB,GAAG,aAAa,GAAG,aAAa,GAAG,eAAe,CAAC;AAsClF;;;;;;;;;;;GAWG;AACH,wBAAgB,QAAQ,CAAC,IAAI,EAAE,MAAM,EAAE,YAAY,EAAE,MAAM,GAAG,OAAO,CAIpE;AAmBD;;;GAGG;AACH,wBAAsB,wBAAwB,CAAC,WAAW,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,GAAG,OAAO,CAAC,mBAAmB,CAAC,CAShH;AA0BD;;;;;;;;;;;;;GAaG;AACH,wBAAsB,gBAAgB,CAAC,WAAW,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,GAAG,OAAO,CAAC,OAAO,CAAC,CAE5F;AA+BD;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,wBAAsB,uBAAuB,CAC3C,SAAS,EAAE,MAAM,EACjB,YAAY,EAAE,MAAM,EACpB,SAAS,EAAE,OAAO,GACjB,OAAO,CAAC,eAAe,EAAE,CAAC,CAuB5B"}
@@ -168,10 +168,16 @@ export async function getOrCreateGitTracker(gitRoot) {
168
168
  * {@link resetGitTrackerCache} itself between phases, exactly as this module's
169
169
  * own tests do in `beforeEach`.
170
170
  */
171
- export const gitTrackerForProjectRoot = async (projectRoot) => {
172
- const gitRoot = gitFindRoot(projectRoot);
171
+ export const gitTrackerForProjectRoot = (projectRoot) => {
172
+ let gitRoot;
173
+ try {
174
+ gitRoot = gitFindRoot(projectRoot);
175
+ }
176
+ catch (error) {
177
+ return Promise.reject(error);
178
+ }
173
179
  if (gitRoot === null) {
174
- return undefined;
180
+ return Promise.resolve(undefined);
175
181
  }
176
182
  // No catch, deliberately. "Not a repository" and "git did not answer" are
177
183
  // both absorbed INSIDE `GitTracker.initialize()` (a null listing, a tracker
@@ -226,9 +232,12 @@ const REPO_SOURCE = 'repo-source';
226
232
  * Canonicalising the SKILL.md before deriving the git root is what keeps the
227
233
  * second fix honest — the tracker's own keys are built from the root it is given,
228
234
  * so a canonical lookup against a non-canonical root would miss every time.
235
+ *
236
+ * @param within - The tree `filePath` was crawled in (the audit's scan root), whose links are read
237
+ * before the kernel follows them; `filePath` itself when it is the operator's own path
229
238
  */
230
- function canonicalPath(filePath) {
231
- return toForwardSlash(normalizePath(safePath.resolve(filePath)));
239
+ function canonicalPath(filePath, within) {
240
+ return toForwardSlash(normalizePath(safePath.resolve(filePath), within));
232
241
  }
233
242
  /**
234
243
  * True when `absolutePath` is `root` or lies beneath it.
@@ -258,14 +267,16 @@ function isUnderClaudeInstallRoot(canonicalAbsolutePath) {
258
267
  const { pluginsDir, skillsDir, marketplacesDir } = getClaudeUserPaths();
259
268
  // marketplacesDir is nested under pluginsDir; listed anyway so the set reads as
260
269
  // the three install destinations rather than as an accident of layout.
261
- return [pluginsDir, skillsDir, marketplacesDir].some((dir) => isWithin(canonicalPath(dir), canonicalAbsolutePath));
270
+ return [pluginsDir, skillsDir, marketplacesDir].some((dir) =>
271
+ // An install root is the operator's own configuration (`CLAUDE_CONFIG_DIR`/`HOME`), never a crawled entry.
272
+ isWithin(canonicalPath(dir, dir), canonicalAbsolutePath));
262
273
  }
263
274
  /**
264
275
  * Classify the tree holding `skillMdPath`. See this module's header for the
265
276
  * reasoning behind each clause and the order they are applied in.
266
277
  */
267
- export async function classifyScannedSkillTree(skillMdPath) {
268
- const absolute = canonicalPath(skillMdPath);
278
+ export async function classifyScannedSkillTree(skillMdPath, within) {
279
+ const absolute = canonicalPath(skillMdPath, within);
269
280
  const memoized = provenanceCache.get(absolute);
270
281
  if (memoized !== undefined) {
271
282
  return memoized;
@@ -309,8 +320,8 @@ async function classifyUncached(absolute) {
309
320
  * skill, and a scan rooted above `<claudeDir>/skills` reaches an install root
310
321
  * from outside one.
311
322
  */
312
- export async function crawlOwnsSubtree(skillMdPath) {
313
- return (await classifyScannedSkillTree(skillMdPath)) !== REPO_SOURCE;
323
+ export async function crawlOwnsSubtree(skillMdPath, within) {
324
+ return (await classifyScannedSkillTree(skillMdPath, within)) !== REPO_SOURCE;
314
325
  }
315
326
  /**
316
327
  * The tree's own directory, spelled as a location a reader can act on.
@@ -365,11 +376,11 @@ function treeLocation(treeRoot, locationRoot) {
365
376
  export async function distributedTreeFindings(skillPath, locationRoot, crawlTree) {
366
377
  if (!crawlTree)
367
378
  return [];
368
- const provenance = await classifyScannedSkillTree(skillPath);
379
+ const provenance = await classifyScannedSkillTree(skillPath, locationRoot);
369
380
  if (provenance === REPO_SOURCE)
370
381
  return [];
371
382
  const treeRoot = safePath.resolve(skillPath, '..');
372
- const present = detectPackagedAgentInstructionFiles(treeRoot, locationRoot, []);
383
+ const present = detectPackagedAgentInstructionFiles(treeRoot, locationRoot, [], []);
373
384
  if (provenance === 'distributed')
374
385
  return present;
375
386
  // Provenance is unknown. Report the unknown, not the files: calling them
@@ -1 +1 @@
1
- {"version":3,"file":"distributed-tree.js","sourceRoot":"","sources":["../../../src/commands/audit/distributed-tree.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA0FG;AAEH,OAAO,EAAE,mCAAmC,EAAE,gBAAgB,EAAE,MAAM,kCAAkC,CAAC;AACzG,OAAO,EAAE,kBAAkB,EAAyB,MAAM,wCAAwC,CAAC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;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,MAAM,CAAC,KAAK,UAAU,uBAAuB,CAC3C,SAAiB,EACjB,YAAoB,EACpB,SAAkB;IAElB,IAAI,CAAC,SAAS;QAAE,OAAO,EAAE,CAAC;IAC1B,MAAM,UAAU,GAAG,MAAM,wBAAwB,CAAC,SAAS,EAAE,YAAY,CAAC,CAAC;IAC3E,IAAI,UAAU,KAAK,WAAW;QAAE,OAAO,EAAE,CAAC;IAE1C,MAAM,QAAQ,GAAG,QAAQ,CAAC,OAAO,CAAC,SAAS,EAAE,IAAI,CAAC,CAAC;IACnD,MAAM,OAAO,GAAG,mCAAmC,CAAC,QAAQ,EAAE,YAAY,EAAE,EAAE,EAAE,EAAE,CAAC,CAAC;IACpF,IAAI,UAAU,KAAK,aAAa;QAAE,OAAO,OAAO,CAAC;IAEjD,yEAAyE;IACzE,gFAAgF;IAChF,iFAAiF;IACjF,+EAA+E;IAC/E,8EAA8E;IAC9E,2EAA2E;IAC3E,IAAI,OAAO,CAAC,MAAM,KAAK,CAAC;QAAE,OAAO,EAAE,CAAC;IACpC,MAAM,QAAQ,GAAG,YAAY,CAAC,QAAQ,EAAE,YAAY,CAAC,CAAC;IACtD,OAAO;QACL,gBAAgB,CAAC,+BAA+B,EAAE;YAChD,QAAQ;YACR,MAAM,EAAE,GAAG,QAAQ,KAAK,OAAO,CAAC,MAAM,iDAAiD;SACxF,CAAC;KACH,CAAC;AACJ,CAAC"}
@@ -2,12 +2,13 @@
2
2
  * Shallow-clone-and-cleanup helper for `vat audit <git-url>`.
3
3
  *
4
4
  * Pipeline:
5
- * 1. mkdtempSync('vat-audit-')
6
- * 2. install SIGINT handler that removes the tempdir
5
+ * 1. makeStagingDir('vat-audit-')
6
+ * 2. guard every terminating signal: dispose of the tempdir, then die of it — held until the
7
+ * tempdir's one disposal (step 6, or the signal's own) has settled
7
8
  * 3. git clone --depth 1 --single-branch [--branch <ref>]
8
9
  * 4. git rev-parse HEAD → resolved commit SHA
9
10
  * 5. yield (tempdir, targetDir, provenance) to caller
10
- * 6. cleanup in finally — always rm tempdir unless `keepTempForDebug`
11
+ * 6. dispose of the tempdir, success or failure, unless `keepTempForDebug`
11
12
  */
12
13
  import { type ParsedGitUrl } from '@vibe-agent-toolkit/utils/git';
13
14
  import type { Provenance } from './provenance.js';
@@ -24,9 +25,16 @@ export interface CloneOptions {
24
25
  keepTempForDebug: boolean;
25
26
  }
26
27
  /**
27
- * Run `body` against a freshly shallow-cloned repo. Always cleans up the
28
- * tempdir unless `options.keepTempForDebug` is true. Re-raises any error
29
- * from the clone or from `body`.
28
+ * Run `body` against a freshly shallow-cloned repo, then dispose of the clone (unless
29
+ * `options.keepTempForDebug`). `body` must not end the process itself: a caller that exits
30
+ * does so once this has settled.
31
+ *
32
+ * A failure of the clone or of `body` is rethrown unchanged, a clone that will not go recorded
33
+ * beside it (`suppressedFaultsOf`). Once `body` succeeded, a clone the OS would not remove is
34
+ * returned as `leftover` beside its value — the work is done, so it is never the refusal.
30
35
  */
31
- export declare function withClonedRepo<T>(parsed: ParsedGitUrl, options: CloneOptions, body: (ctx: CloneAndAuditContext) => Promise<T>): Promise<T>;
36
+ export declare function withClonedRepo<T>(parsed: ParsedGitUrl, options: CloneOptions, body: (ctx: CloneAndAuditContext) => Promise<T>): Promise<{
37
+ readonly value: T;
38
+ readonly leftover: unknown;
39
+ }>;
32
40
  //# sourceMappingURL=git-url-clone.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"git-url-clone.d.ts","sourceRoot":"","sources":["../../../src/commands/audit/git-url-clone.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAMH,OAAO,EAAE,KAAK,YAAY,EAAE,MAAM,+BAA+B,CAAC;AAElE,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAElD,MAAM,WAAW,oBAAoB;IACnC,OAAO,EAAE,MAAM,CAAC;IAChB,SAAS,EAAE,MAAM,CAAC;IAClB,UAAU,EAAE,UAAU,CAAC;CACxB;AAED,MAAM,WAAW,YAAY;IAC3B;;;OAGG;IACH,gBAAgB,EAAE,OAAO,CAAC;CAC3B;AAED;;;;GAIG;AACH,wBAAsB,cAAc,CAAC,CAAC,EACpC,MAAM,EAAE,YAAY,EACpB,OAAO,EAAE,YAAY,EACrB,IAAI,EAAE,CAAC,GAAG,EAAE,oBAAoB,KAAK,OAAO,CAAC,CAAC,CAAC,GAC9C,OAAO,CAAC,CAAC,CAAC,CAgDZ"}
1
+ {"version":3,"file":"git-url-clone.d.ts","sourceRoot":"","sources":["../../../src/commands/audit/git-url-clone.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAOH,OAAO,EAAE,KAAK,YAAY,EAAE,MAAM,+BAA+B,CAAC;AAMlE,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAElD,MAAM,WAAW,oBAAoB;IACnC,OAAO,EAAE,MAAM,CAAC;IAChB,SAAS,EAAE,MAAM,CAAC;IAClB,UAAU,EAAE,UAAU,CAAC;CACxB;AAED,MAAM,WAAW,YAAY;IAC3B;;;OAGG;IACH,gBAAgB,EAAE,OAAO,CAAC;CAC3B;AAkCD;;;;;;;;GAQG;AACH,wBAAsB,cAAc,CAAC,CAAC,EACpC,MAAM,EAAE,YAAY,EACpB,OAAO,EAAE,YAAY,EACrB,IAAI,EAAE,CAAC,GAAG,EAAE,oBAAoB,KAAK,OAAO,CAAC,CAAC,CAAC,GAC9C,OAAO,CAAC;IAAE,QAAQ,CAAC,KAAK,EAAE,CAAC,CAAC;IAAC,QAAQ,CAAC,QAAQ,EAAE,OAAO,CAAA;CAAE,CAAC,CAoD5D"}
@@ -2,57 +2,99 @@
2
2
  * Shallow-clone-and-cleanup helper for `vat audit <git-url>`.
3
3
  *
4
4
  * Pipeline:
5
- * 1. mkdtempSync('vat-audit-')
6
- * 2. install SIGINT handler that removes the tempdir
5
+ * 1. makeStagingDir('vat-audit-')
6
+ * 2. guard every terminating signal: dispose of the tempdir, then die of it — held until the
7
+ * tempdir's one disposal (step 6, or the signal's own) has settled
7
8
  * 3. git clone --depth 1 --single-branch [--branch <ref>]
8
9
  * 4. git rev-parse HEAD → resolved commit SHA
9
10
  * 5. yield (tempdir, targetDir, provenance) to caller
10
- * 6. cleanup in finally — always rm tempdir unless `keepTempForDebug`
11
+ * 6. dispose of the tempdir, success or failure, unless `keepTempForDebug`
11
12
  */
12
- import { mkdtempSync, rmSync } from 'node:fs';
13
13
  import { cloneGitSource } from '@vibe-agent-toolkit/agent-skills';
14
- import { normalizedTmpdir, safePath } from '@vibe-agent-toolkit/utils';
14
+ import { ExitCode } from '@vibe-agent-toolkit/schema';
15
+ import { disposeTempDir, disposeTempDirAfterFailure } from '@vibe-agent-toolkit/utils';
16
+ import { handleTerminatingSignals } from '@vibe-agent-toolkit/utils/process';
17
+ import { CommandRefusalError, errorMessageOf, refusalCodeOf } from '../../utils/command-refusal.js';
18
+ import { makeStagingDir } from '../../utils/staging-dir.js';
15
19
  /**
16
- * Run `body` against a freshly shallow-cloned repo. Always cleans up the
17
- * tempdir unless `options.keepTempForDebug` is true. Re-raises any error
18
- * from the clone or from `body`.
20
+ * Clone the source, or refuse. A subpath the clone does not hold, or one that
21
+ * escapes it, arrives coded (`GIT_SUBPATH_INVALID`) and keeps its own refusal —
22
+ * `USAGE_INVALID`, the argument's mistake. Anything else the clone step throws
23
+ * (a clone that fails, a ref it does not have) means the source the operator
24
+ * named could not be read: `INPUT_UNREADABLE`. Only the clone step is coded; a
25
+ * failure inside the audit that follows is the audit's own.
26
+ */
27
+ function cloneSource(parsed, tempdir) {
28
+ try {
29
+ return cloneGitSource(parsed, tempdir);
30
+ }
31
+ catch (error) {
32
+ if (refusalCodeOf(error) !== 'INTERNAL_ERROR')
33
+ throw error;
34
+ throw new CommandRefusalError('INPUT_UNREADABLE', errorMessageOf(error), { cause: error });
35
+ }
36
+ }
37
+ /**
38
+ * Dispose of the clone's tempdir once the work on it is DONE — or, under `keepTempForDebug`,
39
+ * keep it and say where.
40
+ *
41
+ * @returns `undefined`, or the leftover: the classified fault naming a tempdir the OS would not
42
+ * remove, for the caller to publish as a warning beside the work it finished
43
+ */
44
+ async function disposeClone(tempdir, options) {
45
+ if (options.keepTempForDebug) {
46
+ process.stderr.write(`[vat: debug — temp dir preserved: ${tempdir}]\n`);
47
+ return undefined;
48
+ }
49
+ return await disposeTempDir(tempdir);
50
+ }
51
+ /**
52
+ * Run `body` against a freshly shallow-cloned repo, then dispose of the clone (unless
53
+ * `options.keepTempForDebug`). `body` must not end the process itself: a caller that exits
54
+ * does so once this has settled.
55
+ *
56
+ * A failure of the clone or of `body` is rethrown unchanged, a clone that will not go recorded
57
+ * beside it (`suppressedFaultsOf`). Once `body` succeeded, a clone the OS would not remove is
58
+ * returned as `leftover` beside its value — the work is done, so it is never the refusal.
19
59
  */
20
60
  export async function withClonedRepo(parsed, options, body) {
21
- const tempdir = mkdtempSync(safePath.join(normalizedTmpdir(), 'vat-audit-'));
22
- const sigintListener = () => {
61
+ // Through the one classified creation: a temp directory the OS will not make is the environment's fault.
62
+ const tempdir = await makeStagingDir('vat-audit-');
63
+ // ONE disposal, whoever starts it: the work's own end (after success or failure) or a signal. It
64
+ // settles on what it left behind, whichever path started it, so the signal path can name it. The
65
+ // guard is held until that disposal has SETTLED — a Ctrl-C that also kills `git` fails the clone
66
+ // step, and a guard released before the failure path's disposal let the pending signal kill the
67
+ // process half-way through it, the clone left behind.
68
+ let disposal;
69
+ const dispose = (start) => (disposal ??= start());
70
+ // Interrupted: dispose of the clone first, then die of the signal. No report follows a signal, so a
71
+ // clone that will not go is named on stderr. A repeat (a terminal Ctrl-C under the `vat` wrapper
72
+ // arrives twice) is swallowed — see `handleTerminatingSignals`.
73
+ const signalGuard = handleTerminatingSignals({
74
+ fallbackExitCode: ExitCode.ERROR,
75
+ cleanup: () => dispose(() => disposeClone(tempdir, options)).then((leftover) => {
76
+ if (leftover !== undefined)
77
+ process.stderr.write(`[vat: interrupted — temp dir left behind: ${errorMessageOf(leftover)}]\n`);
78
+ },
79
+ // A rejection is a refusal to dispose at all (nothing was touched): say that, not "left behind".
80
+ (error_) => {
81
+ process.stderr.write(`[vat: interrupted — temp dir not disposed of: ${errorMessageOf(error_)}]\n`);
82
+ }),
83
+ });
84
+ // The work's own disposal, then the guard's release — released even when the disposal REJECTS
85
+ // (a refusal to dispose at all), so a guard never outlives the work it guarded.
86
+ const disposeThenRelease = async (start) => {
23
87
  try {
24
- rmSync(tempdir, { recursive: true, force: true });
88
+ return await dispose(start);
25
89
  }
26
90
  finally {
27
- process.removeListener('SIGINT', sigintListener);
28
- process.kill(process.pid, 'SIGINT');
91
+ // A signal that arrived meanwhile ends the process once this same disposal has settled.
92
+ await signalGuard.releaseOrAwaitEnding();
29
93
  }
30
94
  };
31
- process.on('SIGINT', sigintListener);
32
- // The audit pipeline calls `process.exit()` on completion
33
- // (`handleAuditResults` in audit.ts), which would skip any `finally`
34
- // block here. Register an `'exit'` listener so cleanup runs even when
35
- // the process is ending — this is Node's documented escape hatch for
36
- // "always run this sync cleanup". We still keep the `finally` below so
37
- // thrown errors and the non-exit path behave the same.
38
- let cleaned = false;
39
- const cleanup = () => {
40
- if (cleaned)
41
- return;
42
- cleaned = true;
43
- if (options.keepTempForDebug) {
44
- process.stderr.write(`[vat: debug — temp dir preserved: ${tempdir}]\n`);
45
- }
46
- else {
47
- rmSync(tempdir, { recursive: true, force: true });
48
- }
49
- };
50
- const exitListener = () => {
51
- cleanup();
52
- };
53
- process.on('exit', exitListener);
95
+ let value;
54
96
  try {
55
- const { ref, commit, targetDir } = cloneGitSource(parsed, tempdir);
97
+ const { ref, commit, targetDir } = cloneSource(parsed, tempdir);
56
98
  const { subpath } = parsed;
57
99
  const provenance = {
58
100
  url: parsed.cloneUrl,
@@ -60,12 +102,13 @@ export async function withClonedRepo(parsed, options, body) {
60
102
  commit,
61
103
  ...(subpath ? { subpath } : {}),
62
104
  };
63
- return await body({ tempdir, targetDir, provenance });
105
+ value = await body({ tempdir, targetDir, provenance });
64
106
  }
65
- finally {
66
- process.removeListener('SIGINT', sigintListener);
67
- process.removeListener('exit', exitListener);
68
- cleanup();
107
+ catch (error) {
108
+ await disposeThenRelease(() => (options.keepTempForDebug ? disposeClone(tempdir, options) : disposeTempDirAfterFailure(tempdir, error)));
109
+ throw error;
69
110
  }
111
+ const leftover = await disposeThenRelease(() => disposeClone(tempdir, options));
112
+ return { value, leftover };
70
113
  }
71
114
  //# sourceMappingURL=git-url-clone.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"git-url-clone.js","sourceRoot":"","sources":["../../../src/commands/audit/git-url-clone.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,OAAO,EAAE,WAAW,EAAE,MAAM,EAAE,MAAM,SAAS,CAAC;AAE9C,OAAO,EAAE,cAAc,EAAE,MAAM,kCAAkC,CAAC;AAClE,OAAO,EAAE,gBAAgB,EAAE,QAAQ,EAAE,MAAM,2BAA2B,CAAC;AAmBvE;;;;GAIG;AACH,MAAM,CAAC,KAAK,UAAU,cAAc,CAClC,MAAoB,EACpB,OAAqB,EACrB,IAA+C;IAE/C,MAAM,OAAO,GAAG,WAAW,CAAC,QAAQ,CAAC,IAAI,CAAC,gBAAgB,EAAE,EAAE,YAAY,CAAC,CAAC,CAAC;IAC7E,MAAM,cAAc,GAAG,GAAS,EAAE;QAChC,IAAI,CAAC;YACH,MAAM,CAAC,OAAO,EAAE,EAAE,SAAS,EAAE,IAAI,EAAE,KAAK,EAAE,IAAI,EAAE,CAAC,CAAC;QACpD,CAAC;gBAAS,CAAC;YACT,OAAO,CAAC,cAAc,CAAC,QAAQ,EAAE,cAAc,CAAC,CAAC;YACjD,OAAO,CAAC,IAAI,CAAC,OAAO,CAAC,GAAG,EAAE,QAAQ,CAAC,CAAC;QACtC,CAAC;IACH,CAAC,CAAC;IACF,OAAO,CAAC,EAAE,CAAC,QAAQ,EAAE,cAAc,CAAC,CAAC;IAErC,0DAA0D;IAC1D,qEA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C,MAAM,EAAE,OAAO,CAAC,CAAC;QAChE,MAAM,EAAE,OAAO,EAAE,GAAG,MAAM,CAAC;QAC3B,MAAM,UAAU,GAAe;YAC7B,GAAG,EAAE,MAAM,CAAC,QAAQ;YACpB,GAAG;YACH,MAAM;YACN,GAAG,CAAC,OAAO,CAAC,CAAC,CAAC,EAAE,OAAO,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;SAChC,CAAC;QACF,KAAK,GAAG,MAAM,IAAI,CAAC,EAAE,OAAO,EAAE,SAAS,EAAE,UAAU,EAAE,CAAC,CAAC;IACzD,CAAC;IAAC,OAAO,KAAK,EAAE,CAAC;QACf,MAAM,kBAAkB,CAAC,GAAG,EAAE,CAAC,CAAC,OAAO,CAAC,gBAAgB,CAAC,CAAC,CAAC,YAAY,CAAC,OAAO,EAAE,OAAO,CAAC,CAAC,CAAC,CAAC,0BAA0B,CAAC,OAAO,EAAE,KAAK,CAAC,CAAC,CAAC,CAAC;QACzI,MAAM,KAAK,CAAC;IACd,CAAC;IACD,MAAM,QAAQ,GAAG,MAAM,kBAAkB,CAAC,GAAG,EAAE,CAAC,YAAY,CAAC,OAAO,EAAE,OAAO,CAAC,CAAC,CAAC;IAChF,OAAO,EAAE,KAAK,EAAE,QAAQ,EAAE,CAAC;AAC7B,CAAC"}
@@ -1,5 +1,5 @@
1
- import type { ValidationResult } from '@vibe-agent-toolkit/agent-skills';
2
- import { type ValidationIssue } from '@vibe-agent-toolkit/schema';
1
+ import { type ValidationResult } from '@vibe-agent-toolkit/agent-skills';
2
+ import { type SeverityCounts } from '@vibe-agent-toolkit/schema';
3
3
  export interface HierarchicalOutput {
4
4
  marketplaces: MarketplaceGroup[];
5
5
  cachedPlugins: PluginGroup[];
@@ -15,14 +15,38 @@ export interface PluginGroup {
15
15
  skills: SkillEntry[];
16
16
  }
17
17
  export type CacheStatus = 'stale' | 'orphaned' | 'fresh';
18
+ /**
19
+ * One skill in the `--user` view. Its findings are the report envelope's (each
20
+ * `location` names the file); the entry carries their distribution, the same
21
+ * `status` + `summary` pair every `files[]` row carries.
22
+ */
18
23
  export interface SkillEntry {
19
24
  name: string;
20
25
  /** Path relative to the run root stated once at the top of the report. */
21
26
  path: string;
22
- status: 'success' | 'warning' | 'error';
23
- issues: ValidationIssue[];
27
+ /** Literal: `findings` iff the skill carries any finding. */
28
+ status: 'ok' | 'findings';
29
+ summary: SeverityCounts;
24
30
  cacheStatus?: CacheStatus;
25
31
  }
32
+ /**
33
+ * Add misconfiguration issues to standalone skills in wrong locations
34
+ *
35
+ * Detects standalone SKILL.md files in ~/.claude/plugins/ that won't be recognized
36
+ * by Claude Code. These should be either moved to ~/.claude/skills/ or properly
37
+ * configured as plugins with .claude-plugin/plugin.json.
38
+ *
39
+ * Applied to the `--user` run's RESULTS, before the report is built, so the
40
+ * finding reaches the envelope's `findings` and `summary` and the `files[]` row
41
+ * as well as the hierarchy. It used to be added inside the hierarchy only: an
42
+ * error-severity finding the header never counted and the exit code never saw.
43
+ *
44
+ * @param results - Validation results to check — every result of the run, so a
45
+ * skill-claude-plugin's own plugin result is among them
46
+ * @param locationRoot - Run root the emitted `location` is expressed relative to
47
+ * @returns Results with misconfiguration issues added
48
+ */
49
+ export declare function addMisconfigurationIssues(results: ValidationResult[], locationRoot: string): ValidationResult[];
26
50
  /**
27
51
  * Build hierarchical output structure from validation results.
28
52
  *
@@ -1 +1 @@
1
- {"version":3,"file":"hierarchical-output.d.ts","sourceRoot":"","sources":["../../../src/commands/audit/hierarchical-output.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,kCAAkC,CAAC;AACzE,OAAO,EAGL,KAAK,eAAe,EACrB,MAAM,4BAA4B,CAAC;AAGpC,MAAM,WAAW,kBAAkB;IACjC,YAAY,EAAE,gBAAgB,EAAE,CAAC;IACjC,aAAa,EAAE,WAAW,EAAE,CAAC;IAC7B,iBAAiB,EAAE,WAAW,EAAE,CAAC;IACjC,gBAAgB,EAAE,UAAU,EAAE,CAAC;CAChC;AAED,MAAM,WAAW,gBAAgB;IAC/B,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,WAAW,EAAE,CAAC;CACxB;AAED,MAAM,WAAW,WAAW;IAC1B,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,UAAU,EAAE,CAAC;CACtB;AAED,MAAM,MAAM,WAAW,GAAG,OAAO,GAAG,UAAU,GAAG,OAAO,CAAC;AAEzD,MAAM,WAAW,UAAU;IACzB,IAAI,EAAE,MAAM,CAAC;IACb,0EAA0E;IAC1E,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,SAAS,GAAG,SAAS,GAAG,OAAO,CAAC;IACxC,MAAM,EAAE,eAAe,EAAE,CAAC;IAC1B,WAAW,CAAC,EAAE,WAAW,CAAC;CAC3B;AAqaD;;;;;;;;;;;;;;;;;;GAkBG;AACH,wBAAgB,uBAAuB,CACrC,OAAO,EAAE,gBAAgB,EAAE,EAC3B,OAAO,EAAE,OAAO,EAChB,YAAY,EAAE,MAAM,GACnB,kBAAkB,CAyCpB"}
1
+ {"version":3,"file":"hierarchical-output.d.ts","sourceRoot":"","sources":["../../../src/commands/audit/hierarchical-output.ts"],"names":[],"mappings":"AAEA,OAAO,EAAkB,KAAK,gBAAgB,EAAE,MAAM,kCAAkC,CAAC;AACzF,OAAO,EAAmB,KAAK,cAAc,EAAwB,MAAM,4BAA4B,CAAC;AAGxG,MAAM,WAAW,kBAAkB;IACjC,YAAY,EAAE,gBAAgB,EAAE,CAAC;IACjC,aAAa,EAAE,WAAW,EAAE,CAAC;IAC7B,iBAAiB,EAAE,WAAW,EAAE,CAAC;IACjC,gBAAgB,EAAE,UAAU,EAAE,CAAC;CAChC;AAED,MAAM,WAAW,gBAAgB;IAC/B,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,WAAW,EAAE,CAAC;CACxB;AAED,MAAM,WAAW,WAAW;IAC1B,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,UAAU,EAAE,CAAC;CACtB;AAED,MAAM,MAAM,WAAW,GAAG,OAAO,GAAG,UAAU,GAAG,OAAO,CAAC;AAEzD;;;;GAIG;AACH,MAAM,WAAW,UAAU;IACzB,IAAI,EAAE,MAAM,CAAC;IACb,0EAA0E;IAC1E,IAAI,EAAE,MAAM,CAAC;IACb,6DAA6D;IAC7D,MAAM,EAAE,IAAI,GAAG,UAAU,CAAC;IAC1B,OAAO,EAAE,cAAc,CAAC;IACxB,WAAW,CAAC,EAAE,WAAW,CAAC;CAC3B;AAuYD;;;;;;;;;;;;;;;;GAgBG;AACH,wBAAgB,yBAAyB,CAAC,OAAO,EAAE,gBAAgB,EAAE,EAAE,YAAY,EAAE,MAAM,GAAG,gBAAgB,EAAE,CAuB/G;AAED;;;;;;;;;;;;;;;;;;GAkBG;AACH,wBAAgB,uBAAuB,CACrC,OAAO,EAAE,gBAAgB,EAAE,EAC3B,OAAO,EAAE,OAAO,EAChB,YAAY,EAAE,MAAM,GACnB,kBAAkB,CAuCpB"}