@cleocode/cleo 2026.10.9 → 2026.10.10-canary.2

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 (174) hide show
  1. package/dist/cli/{adapter-GDM2AKLR.js → adapter-CPTD34FK.js} +3 -3
  2. package/dist/cli/{add-KB753M5X.js → add-LWLCUIKC.js} +3 -3
  3. package/dist/cli/{add-batch-E75D6YTI.js → add-batch-HD4O65I4.js} +3 -3
  4. package/dist/cli/{admin-YSKKVF3L.js → admin-AMAV2TN4.js} +3 -3
  5. package/dist/cli/{admin-2QQCZIW7.js → admin-C4IBLF66.js} +3 -3
  6. package/dist/cli/{adr-UMPRIZIB.js → adr-GHNX5QWM.js} +3 -3
  7. package/dist/cli/{analyze-R4TV7YQ2.js → analyze-X2EIOKF5.js} +3 -3
  8. package/dist/cli/{archive-QZHTAEPV.js → archive-BEIKUZOO.js} +3 -3
  9. package/dist/cli/{archive-stats-GA4ZUWKG.js → archive-stats-5DWII4ZZ.js} +3 -3
  10. package/dist/cli/{attention-O55SETPZ.js → attention-VHCNHELF.js} +3 -3
  11. package/dist/cli/{backup-TTDK7IOM.js → backup-ZJIWPO4V.js} +3 -3
  12. package/dist/cli/{blockers-EKLFYTJO.js → blockers-36T27MZS.js} +3 -3
  13. package/dist/cli/{briefing-5XRHHLAA.js → briefing-VX57TOFZ.js} +3 -3
  14. package/dist/cli/{cancel-ZVN2BAGV.js → cancel-XNFMTQEB.js} +3 -3
  15. package/dist/cli/{check-YI6QVOBW.js → check-T36DIBMA.js} +3 -3
  16. package/dist/cli/{check-52ZTN67R.js → check-T3YTCTLP.js} +2 -2
  17. package/dist/cli/{chunk-LLDYX63U.js → chunk-DX6TRZV7.js} +17 -2
  18. package/dist/cli/{chunk-YI5O7YZO.js → chunk-KKR5BMKV.js} +11 -11
  19. package/dist/cli/{chunk-CVU2C3ZF.js → chunk-NM7WUNBY.js} +2 -2
  20. package/dist/cli/{chunk-J6GFQY5V.js → chunk-SXN3DUMZ.js} +2 -2
  21. package/dist/cli/{chunk-EW2CKNNZ.js → chunk-UUPWMOQA.js} +2 -1
  22. package/dist/cli/{claim-KCDK32SF.js → claim-523YCZTL.js} +3 -3
  23. package/dist/cli/{cli-MWR6QNIQ.js → cli-HGC4OT64.js} +3 -3
  24. package/dist/cli/{complete-M7Y4ZEWB.js → complete-ZLCRSOC5.js} +4 -4
  25. package/dist/cli/{complexity-K27YZWBY.js → complexity-23V5DOSY.js} +3 -3
  26. package/dist/cli/{compliance-WBUBA773.js → compliance-6RYR24JG.js} +3 -3
  27. package/dist/cli/{conduit-RL6V2M76.js → conduit-KRI5H7DO.js} +3 -3
  28. package/dist/cli/{config-O5FUB6R5.js → config-SHDHTQKL.js} +3 -3
  29. package/dist/cli/{consensus-GGREGZHH.js → consensus-NQWKVYTQ.js} +3 -3
  30. package/dist/cli/{context-D5JSCOCF.js → context-JO52QETY.js} +3 -3
  31. package/dist/cli/{contribution-UMPLZPRR.js → contribution-PZWQJLAS.js} +3 -3
  32. package/dist/cli/{current-IEXUTK7F.js → current-ZVRJMT25.js} +3 -3
  33. package/dist/cli/{daemon-HDYMZL3Z.js → daemon-LZDGTNOY.js} +3 -3
  34. package/dist/cli/{dash-B6CRGPBL.js → dash-NEJ7XJAG.js} +3 -3
  35. package/dist/cli/{decompose-APS4UY5B.js → decompose-2AYL2QU6.js} +3 -3
  36. package/dist/cli/{decomposition-HEHFZHPO.js → decomposition-VXRGWQ2Q.js} +3 -3
  37. package/dist/cli/{delete-7AFONFBH.js → delete-KOQ72TIM.js} +3 -3
  38. package/dist/cli/{deps-DZFAUNGC.js → deps-L2W6VER7.js} +3 -3
  39. package/dist/cli/{detect-X3ONN7BF.js → detect-O24G4N5S.js} +3 -3
  40. package/dist/cli/{diagnostics-BOQN5BBE.js → diagnostics-44ARSOPB.js} +3 -3
  41. package/dist/cli/{docs-5VHYBX3P.js → docs-3CGAL626.js} +16 -4
  42. package/dist/cli/{docs-DMYQCRZF.js → docs-7QSB4NT2.js} +132 -82
  43. package/dist/cli/{doctor-ZSTYV4FJ.js → doctor-YAKOPWUS.js} +4 -4
  44. package/dist/cli/{doctor-tool-locks-W22MYJHN.js → doctor-tool-locks-QCBTDZPG.js} +2 -2
  45. package/dist/cli/{done-OJNI3I7X.js → done-ULOLHME6.js} +4 -4
  46. package/dist/cli/{export-LH5UJTJ7.js → export-AKF7XM44.js} +3 -3
  47. package/dist/cli/{export-tasks-NONTLPDO.js → export-tasks-GO3KXECZ.js} +3 -3
  48. package/dist/cli/{find-PMC7RICN.js → find-M4WXW6QC.js} +3 -3
  49. package/dist/cli/{focus-B6UAE22J.js → focus-A7YZ4AFX.js} +3 -3
  50. package/dist/cli/{grade-K4QVKECD.js → grade-MQHQBHT2.js} +3 -3
  51. package/dist/cli/{graph-ACUZZ6UP.js → graph-YSLZO4ZT.js} +3 -3
  52. package/dist/cli/{history-OYXAFZLB.js → history-OJ52PK7W.js} +3 -3
  53. package/dist/cli/{import-OWNNBXHE.js → import-P4J5KVMP.js} +3 -3
  54. package/dist/cli/{import-tasks-ALKVWV7O.js → import-tasks-K42DVQT6.js} +3 -3
  55. package/dist/cli/index.js +102 -102
  56. package/dist/cli/{inject-CJIGOTU2.js → inject-SMJVGCU4.js} +3 -3
  57. package/dist/cli/{intelligence-PIYYLELR.js → intelligence-W6A7YKPA.js} +3 -3
  58. package/dist/cli/{issue-SKZ3VYSU.js → issue-3F6EHEVP.js} +3 -3
  59. package/dist/cli/{labels-3UWR5CZ2.js → labels-BLYMQLSB.js} +3 -3
  60. package/dist/cli/{lifecycle-QJYPQVQX.js → lifecycle-DVULHH7L.js} +3 -3
  61. package/dist/cli/{list-S3D56SWR.js → list-I4MH7DZG.js} +3 -3
  62. package/dist/cli/{llm-XLI6DWAT.js → llm-HRAGPYFT.js} +3 -3
  63. package/dist/cli/{log-27LATD6P.js → log-7NA4ULZG.js} +3 -3
  64. package/dist/cli/{manifest-RGP3GUSZ.js → manifest-ASEXWCV5.js} +3 -3
  65. package/dist/cli/{map-4U4O2FRD.js → map-SB5VOUWI.js} +3 -3
  66. package/dist/cli/{memory-SZX5CXYU.js → memory-434MP4JR.js} +2 -2
  67. package/dist/cli/{memory-A46L6VUK.js → memory-VZV3YV3D.js} +3 -3
  68. package/dist/cli/{migrate-claude-mem-XJSLS4OP.js → migrate-claude-mem-4DEGUYEP.js} +3 -3
  69. package/dist/cli/{next-T5FYLKHJ.js → next-3VMGBBP3.js} +3 -3
  70. package/dist/cli/{nexus-I2CGSEXT.js → nexus-GJJ2J7RY.js} +2 -2
  71. package/dist/cli/{nexus-LN7IOBHA.js → nexus-L6YXCZW7.js} +3 -3
  72. package/dist/cli/{ops-SS2ETL37.js → ops-ZH36T3WV.js} +3 -3
  73. package/dist/cli/{orchestrate-MTWEN2N4.js → orchestrate-DMH5NKDD.js} +2 -2
  74. package/dist/cli/{orchestrate-WM7A3NMZ.js → orchestrate-U54IOTZN.js} +3 -3
  75. package/dist/cli/{phase-OWQYB2PT.js → phase-OPMHFKAT.js} +3 -3
  76. package/dist/cli/{pipeline-WTCTZJXY.js → pipeline-YCKZZPLM.js} +2 -2
  77. package/dist/cli/{pivot-WSXRRP4T.js → pivot-SBT5QNJU.js} +3 -3
  78. package/dist/cli/{plan-I7PIDCJO.js → plan-WP2KX2WL.js} +3 -3
  79. package/dist/cli/{playbook-V3PPWDX7.js → playbook-RTD55GF2.js} +3 -3
  80. package/dist/cli/{promote-VVIZYWTO.js → promote-KIHCKOHF.js} +3 -3
  81. package/dist/cli/{provenance-IJDOBC6P.js → provenance-V3NQN22W.js} +3 -3
  82. package/dist/cli/{provider-EO5GE5HH.js → provider-SP2SM6O7.js} +3 -3
  83. package/dist/cli/{reason-6QLPUQOW.js → reason-PID3Z7CJ.js} +3 -3
  84. package/dist/cli/{reconcile-FKMX3AC4.js → reconcile-V3MXVCGK.js} +3 -3
  85. package/dist/cli/{relates-LLAMIT46.js → relates-BPR7MQZO.js} +3 -3
  86. package/dist/cli/{release-SSPADPVW.js → release-3UCVO5F3.js} +3 -3
  87. package/dist/cli/{reorder-76DK3VKZ.js → reorder-KVEMP7YJ.js} +3 -3
  88. package/dist/cli/{reparent-5IWOPJHH.js → reparent-5P3XVZVZ.js} +3 -3
  89. package/dist/cli/{req-26OBW454.js → req-WJXG3VMF.js} +3 -3
  90. package/dist/cli/{research-R53WZQ7Q.js → research-7FZVWKBI.js} +3 -3
  91. package/dist/cli/{restore-6BRSPY6U.js → restore-R62D7EAK.js} +3 -3
  92. package/dist/cli/{roadmap-2TR2JIB7.js → roadmap-C7QRRWU6.js} +3 -3
  93. package/dist/cli/{safestop-VJGPDCGC.js → safestop-VFWRTRNN.js} +3 -3
  94. package/dist/cli/{saga-WXVQZVYW.js → saga-4SWWIV5R.js} +3 -3
  95. package/dist/cli/{selfimprove-5KCF356T.js → selfimprove-PMO4G6M7.js} +2 -2
  96. package/dist/cli/{selfimprove-TLFS7LGK.js → selfimprove-WD7TE2PE.js} +3 -3
  97. package/dist/cli/{sequence-GS36BKUA.js → sequence-QBZ5TKFY.js} +3 -3
  98. package/dist/cli/{service-XI7U5HY4.js → service-QW7E2Z4T.js} +3 -3
  99. package/dist/cli/{session-G2KJOPAP.js → session-7RPQWXUU.js} +3 -3
  100. package/dist/cli/{session-A2P65BNC.js → session-ZVQGWRWO.js} +2 -2
  101. package/dist/cli/{show-J2IF6U4J.js → show-MOWMYKST.js} +3 -3
  102. package/dist/cli/{skills-IPJJZMB7.js → skills-UB2AFNKR.js} +3 -3
  103. package/dist/cli/{snapshot-ZMAYKGMZ.js → snapshot-27IKABDN.js} +3 -3
  104. package/dist/cli/{start-SREEO3QL.js → start-MHHLCFLH.js} +3 -3
  105. package/dist/cli/{stats-DPW6K24D.js → stats-ENTZCGLB.js} +3 -3
  106. package/dist/cli/{sticky-MS4WJ253.js → sticky-P5S6PZW7.js} +3 -3
  107. package/dist/cli/{stop-PDDDU3VP.js → stop-ONKFXIA7.js} +3 -3
  108. package/dist/cli/{sync-MUWOGGOG.js → sync-FJ54PLK5.js} +3 -3
  109. package/dist/cli/{tasks-KHNOCRHV.js → tasks-FH7HRNJV.js} +3 -3
  110. package/dist/cli/{tasks-QHI734UM.js → tasks-MH5VB26S.js} +2 -2
  111. package/dist/cli/{testing-P4KPPGDB.js → testing-LU4WHYU5.js} +3 -3
  112. package/dist/cli/{token-5GFAWYKG.js → token-TCRWHVEV.js} +3 -3
  113. package/dist/cli/{update-44W5NBWH.js → update-OAVS4KKP.js} +3 -3
  114. package/dist/cli/update-check-entry.js +1 -1
  115. package/dist/cli/{update-notice-6SQ6WPQG.js → update-notice-YTDDHJ76.js} +2 -2
  116. package/dist/cli/{verify-GHM23K5B.js → verify-KTSVQOJ2.js} +3 -3
  117. package/dist/cli/{worktree-7WJNLGTP.js → worktree-BRPQ7YEP.js} +3 -3
  118. package/package.json +17 -14
  119. package/studio-dist/client/_app/immutable/chunks/BilLvzh2.js +1 -0
  120. package/studio-dist/client/_app/immutable/chunks/{yeMtPcjs.js → BzLw5Azy.js} +1 -1
  121. package/studio-dist/client/_app/immutable/chunks/{B_Cm0K23.js → CtthiLMf.js} +1 -1
  122. package/studio-dist/client/_app/immutable/chunks/{htIkBo3h.js → ZILf3J30.js} +1 -1
  123. package/studio-dist/client/_app/immutable/entry/{app.D_QHaJ3z.js → app.BBlLk234.js} +2 -2
  124. package/studio-dist/client/_app/immutable/entry/start.CIau6KWf.js +1 -0
  125. package/studio-dist/client/_app/immutable/nodes/{0.BVtAKyoD.js → 0.XDr79loy.js} +1 -1
  126. package/studio-dist/client/_app/immutable/nodes/{1.x9_HsgB7.js → 1.BIDw-yxW.js} +1 -1
  127. package/studio-dist/client/_app/immutable/nodes/{15.glZ43ttx.js → 15.CdYN6-h6.js} +1 -1
  128. package/studio-dist/client/_app/immutable/nodes/{16.SxXcT51y.js → 16.CCdiIukX.js} +1 -1
  129. package/studio-dist/client/_app/immutable/nodes/{17.D96OPsSW.js → 17.DHkN7-R6.js} +1 -1
  130. package/studio-dist/client/_app/immutable/nodes/{18.GfqYk8Uu.js → 18.jfQddC_d.js} +1 -1
  131. package/studio-dist/client/_app/immutable/nodes/{20.B20_ZVFX.js → 20.qspbGvdo.js} +1 -1
  132. package/studio-dist/client/_app/immutable/nodes/{24.DJCSnDKG.js → 24.CqtFKd8e.js} +1 -1
  133. package/studio-dist/client/_app/immutable/nodes/25.D2joWmC2.js +39 -0
  134. package/studio-dist/client/_app/immutable/nodes/{26.D4oX5ton.js → 26.aCZqFGVF.js} +1 -1
  135. package/studio-dist/client/_app/immutable/nodes/{3.DRXAzDuy.js → 3.9B_eO7cp.js} +1 -1
  136. package/studio-dist/client/_app/version.json +1 -1
  137. package/studio-dist/server/chunks/{0-fXXl4eGQ.js → 0-fIumNNL0.js} +3 -3
  138. package/studio-dist/server/chunks/1-Bn0b72l_.js +9 -0
  139. package/studio-dist/server/chunks/{15-CeLGpJvD.js → 15-DvdOaFcu.js} +3 -3
  140. package/studio-dist/server/chunks/{16-4MHW1-6T.js → 16-D4_PDChB.js} +3 -3
  141. package/studio-dist/server/chunks/{17-CHSE_reZ.js → 17-DqFEROhE.js} +3 -3
  142. package/studio-dist/server/chunks/{18-CPdyOX1J.js → 18-CRuy4dru.js} +3 -3
  143. package/studio-dist/server/chunks/{20-BUik9a2i.js → 20-CwVR5tQj.js} +3 -3
  144. package/studio-dist/server/chunks/{24-DL9CUKkc.js → 24-supshJdQ.js} +3 -3
  145. package/studio-dist/server/chunks/{25-DY9iOuEC.js → 25-BWNoEZLf.js} +8 -4
  146. package/studio-dist/server/chunks/{26-DYALaCse.js → 26-Bh5F9FNj.js} +3 -3
  147. package/studio-dist/server/chunks/{3-yKa40-Hr.js → 3-ChA--E3D.js} +3 -3
  148. package/studio-dist/server/chunks/{_layout.svelte-DsAVcyEj.js → _layout.svelte-Cho_nF2v.js} +4 -4
  149. package/studio-dist/server/chunks/{_page.svelte-CbxJdxQC.js → _page.svelte-BW3p3zYk.js} +3 -3
  150. package/studio-dist/server/chunks/{_page.svelte-CjCDXXbC.js → _page.svelte-Be-gzIo2.js} +3 -3
  151. package/studio-dist/server/chunks/{_page.svelte-CcmiRQ4j.js → _page.svelte-BegmGE3Q.js} +3 -3
  152. package/studio-dist/server/chunks/{_page.svelte-OCrVFGoZ.js → _page.svelte-CFlt65NR.js} +4 -4
  153. package/studio-dist/server/chunks/{_page.svelte-COf241FA.js → _page.svelte-CM1R_Cba.js} +6 -6
  154. package/studio-dist/server/chunks/{_page.svelte-Cf6G1gTh.js → _page.svelte-CU4necvH.js} +3 -3
  155. package/studio-dist/server/chunks/{_page.svelte-BsXQOOQU.js → _page.svelte-DHjQag3Y.js} +3 -3
  156. package/studio-dist/server/chunks/{_page.svelte-DTA6Lm_w.js → _page.svelte-DTavcbCx.js} +3 -3
  157. package/studio-dist/server/chunks/{_page.svelte-B-YCLhOS.js → _page.svelte-DWxlxvhk.js} +3 -3
  158. package/studio-dist/server/chunks/{_server.ts-BRr1plRB.js → _server.ts-4BRxl0b5.js} +2 -2
  159. package/studio-dist/server/chunks/{_server.ts-CVUVmk-_.js → _server.ts-7SxVYTCA.js} +3 -3
  160. package/studio-dist/server/chunks/{_server.ts-BcsGXBPF.js → _server.ts-B3AyKiRE.js} +3 -3
  161. package/studio-dist/server/chunks/{_server.ts-CiYJJ0tA.js → _server.ts-BghBG7n7.js} +3 -3
  162. package/studio-dist/server/chunks/{_server.ts-DuQtMtgL.js → _server.ts-ClQAnYoJ.js} +3 -3
  163. package/studio-dist/server/chunks/{client-BztYKJP1.js → client-DBog4VWR.js} +2 -2
  164. package/studio-dist/server/chunks/{error.svelte-D_iuwUHJ.js → error.svelte-AU-DaYrr.js} +3 -3
  165. package/studio-dist/server/chunks/{http-DGCHyZuV.js → http-1glX9355.js} +2 -2
  166. package/studio-dist/server/chunks/{internal-BZdEYjCu.js → internal-BlCMnnlC.js} +2 -2
  167. package/studio-dist/server/chunks/{operations-registry-DmjBRBua.js → operations-registry-cFp6nJCy.js} +31 -1
  168. package/studio-dist/server/chunks/{stores-D3P-ih8A.js → stores-Cg3JdVLa.js} +2 -2
  169. package/studio-dist/server/index.js +1 -1
  170. package/studio-dist/server/manifest.js +17 -17
  171. package/studio-dist/client/_app/immutable/chunks/X4B6m7ok.js +0 -1
  172. package/studio-dist/client/_app/immutable/entry/start.N9rktVuA.js +0 -1
  173. package/studio-dist/client/_app/immutable/nodes/25.BPu5r2zq.js +0 -39
  174. package/studio-dist/server/chunks/1-C3f4PLaZ.js +0 -9
@@ -25,7 +25,7 @@ import {
25
25
  dispatchFromCli,
26
26
  dispatchRaw,
27
27
  handleRawError
28
- } from "./chunk-J6GFQY5V.js";
28
+ } from "./chunk-SXN3DUMZ.js";
29
29
  import "./chunk-6N6WGLXE.js";
30
30
  import {
31
31
  resolve
@@ -49,7 +49,7 @@ import {
49
49
  } from "./chunk-4RGSNUUP.js";
50
50
  import "./chunk-6JSJNYH2.js";
51
51
  import "./chunk-D7BAQNV2.js";
52
- import "./chunk-YI5O7YZO.js";
52
+ import "./chunk-KKR5BMKV.js";
53
53
 
54
54
  // packages/cleo/src/cli/commands/docs.ts
55
55
  import { appendFile, mkdir as mkdir3, readdir, readFile as readFile2, writeFile as writeFile2 } from "node:fs/promises";
@@ -57,7 +57,7 @@ import { dirname as dirname3, isAbsolute, join as join4, resolve as resolve3 } f
57
57
  import {
58
58
  DocKindConfigError,
59
59
  DocKindRegistry,
60
- ExitCode as ExitCode5
60
+ ExitCode as ExitCode6
61
61
  } from "@cleocode/contracts";
62
62
  import {
63
63
  detectStrayCleoDb,
@@ -278,9 +278,57 @@ var setAliasCommand = defineCommand({
278
278
  }
279
279
  });
280
280
 
281
+ // packages/cleo/src/cli/commands/docs/triage.ts
282
+ import { ExitCode as ExitCode4 } from "@cleocode/contracts/exit-codes.js";
283
+ function parseLimit(raw) {
284
+ if (raw === void 0) return void 0;
285
+ const parsed = Number.parseInt(raw, 10);
286
+ if (!Number.isFinite(parsed) || parsed <= 0) {
287
+ cliError("--limit must be a positive integer", ExitCode4.VALIDATION_ERROR, {
288
+ name: "E_VALIDATION"
289
+ });
290
+ process.exit(ExitCode4.VALIDATION_ERROR);
291
+ }
292
+ return parsed;
293
+ }
294
+ var triageCommand = defineCommand({
295
+ meta: {
296
+ name: "triage",
297
+ description: "Batch-triage docs through the docs.triage decision site: proposed keep/update/supersede/archive verdicts plus staleness scores. Dry report by default (no doc is ever mutated); --record persists each verdict as a proposed D#### decision for owner review (T13446)."
298
+ },
299
+ args: {
300
+ limit: {
301
+ type: "string",
302
+ description: "Maximum docs to scan, oldest first (default 25)"
303
+ },
304
+ status: {
305
+ type: "string",
306
+ description: "Lifecycle status to scan (default draft)"
307
+ },
308
+ record: {
309
+ type: "boolean",
310
+ description: "Persist every verdict as a typed D#### decision (confirmationState: proposed). Default: dry report, nothing written."
311
+ }
312
+ },
313
+ async run({ args }) {
314
+ const limit = parseLimit(typeof args.limit === "string" ? args.limit : void 0);
315
+ await dispatchFromCli(
316
+ "query",
317
+ "docs",
318
+ "triage",
319
+ {
320
+ ...limit !== void 0 ? { limit } : {},
321
+ ...typeof args.status === "string" ? { status: args.status } : {},
322
+ record: args.record === true
323
+ },
324
+ { command: "docs triage" }
325
+ );
326
+ }
327
+ });
328
+
281
329
  // packages/cleo/src/cli/commands/docs-viewer.ts
282
330
  import { spawn } from "node:child_process";
283
- import { ExitCode as ExitCode4 } from "@cleocode/contracts/exit-codes.js";
331
+ import { ExitCode as ExitCode5 } from "@cleocode/contracts/exit-codes.js";
284
332
 
285
333
  // packages/cleo/src/viewer/pidfile.ts
286
334
  import { mkdir, readFile, unlink, writeFile } from "node:fs/promises";
@@ -786,11 +834,11 @@ var serveCommand = defineCommand({
786
834
  const host = String(args.host);
787
835
  const noAutoPort = negatedFlag(args, "auto-port");
788
836
  if (!Number.isFinite(startPort) || startPort < 1 || startPort > 65535) {
789
- cliError(`invalid --port: ${args.port}`, ExitCode4.VALIDATION_ERROR, { name: "E_VALIDATION" });
837
+ cliError(`invalid --port: ${args.port}`, ExitCode5.VALIDATION_ERROR, { name: "E_VALIDATION" });
790
838
  return;
791
839
  }
792
840
  if (!Number.isFinite(endPort) || endPort < startPort) {
793
- cliError(`invalid --end-port: ${args["end-port"]}`, ExitCode4.VALIDATION_ERROR, {
841
+ cliError(`invalid --end-port: ${args["end-port"]}`, ExitCode5.VALIDATION_ERROR, {
794
842
  name: "E_VALIDATION"
795
843
  });
796
844
  return;
@@ -817,7 +865,7 @@ var serveCommand = defineCommand({
817
865
  } catch (err) {
818
866
  const e = err;
819
867
  if (e.code === "E_NO_PORT" || e.code === "EADDRINUSE") {
820
- cliError(e.message ?? `port ${startPort} unavailable`, ExitCode4.GENERAL_ERROR, {
868
+ cliError(e.message ?? `port ${startPort} unavailable`, ExitCode5.GENERAL_ERROR, {
821
869
  name: e.code === "E_NO_PORT" ? "E_NO_PORT" : "EADDRINUSE"
822
870
  });
823
871
  return;
@@ -871,14 +919,14 @@ var openCommand = defineCommand({
871
919
  status = await getViewerStatus();
872
920
  } catch (err) {
873
921
  const e = err;
874
- cliError(e.message ?? "failed to start docs viewer", ExitCode4.GENERAL_ERROR, {
922
+ cliError(e.message ?? "failed to start docs viewer", ExitCode5.GENERAL_ERROR, {
875
923
  name: "E_VIEWER_START_FAILED"
876
924
  });
877
925
  return;
878
926
  }
879
927
  }
880
928
  if (!status.running || status.pid === null || status.port === null || status.host === null) {
881
- cliError("timed out waiting for viewer to bind", ExitCode4.GENERAL_ERROR, {
929
+ cliError("timed out waiting for viewer to bind", ExitCode5.GENERAL_ERROR, {
882
930
  name: "E_VIEWER_TIMEOUT"
883
931
  });
884
932
  return;
@@ -1182,13 +1230,13 @@ var addCommand = defineCommand({
1182
1230
  assertKnownFlags(rawArgs, addCommand.args, "docs add");
1183
1231
  } catch (err) {
1184
1232
  if (err instanceof UnknownFlagError) {
1185
- cliError(err.message, ExitCode5.VALIDATION_ERROR, {
1233
+ cliError(err.message, ExitCode6.VALIDATION_ERROR, {
1186
1234
  name: err.code,
1187
1235
  fix: err.fix,
1188
1236
  alternatives: err.suggestions.map((s) => ({ action: s, command: s })),
1189
1237
  details: { flag: err.flag, knownFlags: err.knownFlags }
1190
1238
  });
1191
- process.exit(ExitCode5.VALIDATION_ERROR);
1239
+ process.exit(ExitCode6.VALIDATION_ERROR);
1192
1240
  }
1193
1241
  throw err;
1194
1242
  }
@@ -1272,7 +1320,7 @@ var addCommand = defineCommand({
1272
1320
  const scoreFixed = sim.score.toFixed(2);
1273
1321
  const hint = `Similar to '${sim.mostSimilarSlug}' (score ${scoreFixed}) \u2014 did you mean: cleo docs update ${sim.mostSimilarSlug}? Pass --allow-similar to bypass.`;
1274
1322
  if (mode === "block" && !allowSimilar) {
1275
- cliError(hint, ExitCode5.VALIDATION_ERROR, {
1323
+ cliError(hint, ExitCode6.VALIDATION_ERROR, {
1276
1324
  name: "E_SLUG_SIMILARITY",
1277
1325
  fix: `Use \`cleo docs update ${sim.mostSimilarSlug}\` if updating, or pass --allow-similar to add as a new doc.`,
1278
1326
  alternatives: [
@@ -1293,7 +1341,7 @@ var addCommand = defineCommand({
1293
1341
  kind: args.type
1294
1342
  }
1295
1343
  });
1296
- process.exit(ExitCode5.VALIDATION_ERROR);
1344
+ process.exit(ExitCode6.VALIDATION_ERROR);
1297
1345
  }
1298
1346
  humanInfo(hint);
1299
1347
  if (allowSimilar) {
@@ -1488,17 +1536,17 @@ var fetchCommand = defineCommand({
1488
1536
  const result = await model.fetchDecoded(ref);
1489
1537
  if (!result.ok) {
1490
1538
  if (result.reason === "not-found") {
1491
- cliError(`Doc not found: ${ref}`, ExitCode5.NOT_FOUND, {
1539
+ cliError(`Doc not found: ${ref}`, ExitCode6.NOT_FOUND, {
1492
1540
  name: "E_NOT_FOUND",
1493
1541
  fix: "List available docs with: cleo docs list"
1494
1542
  });
1495
1543
  } else {
1496
- cliError(`Content not retrievable: ${ref}`, ExitCode5.NOT_FOUND, {
1544
+ cliError(`Content not retrievable: ${ref}`, ExitCode6.NOT_FOUND, {
1497
1545
  name: "E_NOT_FOUND",
1498
1546
  fix: "The doc metadata exists but its blob may be missing. Try: cleo docs publish <slug>"
1499
1547
  });
1500
1548
  }
1501
- process.exit(ExitCode5.NOT_FOUND);
1549
+ process.exit(ExitCode6.NOT_FOUND);
1502
1550
  }
1503
1551
  process.stdout.write(result.content);
1504
1552
  if (!result.content.endsWith("\n")) {
@@ -1580,8 +1628,8 @@ var supersedeCommand = defineCommand({
1580
1628
  assertKnownFlags(rawArgs, supersedeCommandArgs, "docs supersede");
1581
1629
  } catch (err) {
1582
1630
  if (err instanceof UnknownFlagError) {
1583
- cliError(err.message, ExitCode5.VALIDATION_ERROR, { name: "E_VALIDATION" });
1584
- process.exit(ExitCode5.VALIDATION_ERROR);
1631
+ cliError(err.message, ExitCode6.VALIDATION_ERROR, { name: "E_VALIDATION" });
1632
+ process.exit(ExitCode6.VALIDATION_ERROR);
1585
1633
  }
1586
1634
  throw err;
1587
1635
  }
@@ -1697,10 +1745,10 @@ var exportCommand = defineCommand({
1697
1745
  }
1698
1746
  } catch (err) {
1699
1747
  const message = err instanceof Error ? err.message : String(err);
1700
- cliError(`docs export failed: ${message}`, ExitCode5.GENERAL_ERROR, {
1748
+ cliError(`docs export failed: ${message}`, ExitCode6.GENERAL_ERROR, {
1701
1749
  name: "E_DOCS_EXPORT_FAILED"
1702
1750
  });
1703
- process.exit(ExitCode5.GENERAL_ERROR);
1751
+ process.exit(ExitCode6.GENERAL_ERROR);
1704
1752
  }
1705
1753
  }
1706
1754
  });
@@ -1781,10 +1829,10 @@ var _llmOutputCommand = defineCommand({
1781
1829
  }
1782
1830
  } catch (err) {
1783
1831
  const message = err instanceof Error ? err.message : String(err);
1784
- cliError(`docs llm-output failed: ${message}`, ExitCode5.GENERAL_ERROR, {
1832
+ cliError(`docs llm-output failed: ${message}`, ExitCode6.GENERAL_ERROR, {
1785
1833
  name: "E_DOCS_LLM_OUTPUT_FAILED"
1786
1834
  });
1787
- process.exit(ExitCode5.GENERAL_ERROR);
1835
+ process.exit(ExitCode6.GENERAL_ERROR);
1788
1836
  }
1789
1837
  }
1790
1838
  });
@@ -1858,10 +1906,10 @@ var llmOutputCommand = defineCommand({
1858
1906
  }
1859
1907
  } catch (err) {
1860
1908
  const message = err instanceof Error ? err.message : String(err);
1861
- cliError(`docs llm-output failed: ${message}`, ExitCode5.GENERAL_ERROR, {
1909
+ cliError(`docs llm-output failed: ${message}`, ExitCode6.GENERAL_ERROR, {
1862
1910
  name: "E_DOCS_LLM_OUTPUT_FAILED"
1863
1911
  });
1864
- process.exit(ExitCode5.GENERAL_ERROR);
1912
+ process.exit(ExitCode6.GENERAL_ERROR);
1865
1913
  }
1866
1914
  }
1867
1915
  });
@@ -1905,10 +1953,10 @@ var searchCommand = defineCommand({
1905
1953
  cliOutput(result, { command: "docs search", operation: "docs.search" });
1906
1954
  } catch (err) {
1907
1955
  const message = err instanceof Error ? err.message : String(err);
1908
- cliError(`docs search failed: ${message}`, ExitCode5.GENERAL_ERROR, {
1956
+ cliError(`docs search failed: ${message}`, ExitCode6.GENERAL_ERROR, {
1909
1957
  name: "E_DOCS_SEARCH_FAILED"
1910
1958
  });
1911
- process.exit(ExitCode5.GENERAL_ERROR);
1959
+ process.exit(ExitCode6.GENERAL_ERROR);
1912
1960
  }
1913
1961
  }
1914
1962
  });
@@ -1944,23 +1992,23 @@ var findCommand = defineCommand({
1944
1992
  assertKnownFlags(rawArgs, findCommand.args, "docs find");
1945
1993
  } catch (err) {
1946
1994
  if (err instanceof UnknownFlagError) {
1947
- cliError(err.message, ExitCode5.VALIDATION_ERROR, {
1995
+ cliError(err.message, ExitCode6.VALIDATION_ERROR, {
1948
1996
  name: err.code,
1949
1997
  fix: err.fix,
1950
1998
  alternatives: err.suggestions.map((s) => ({ action: s, command: s })),
1951
1999
  details: { flag: err.flag, knownFlags: err.knownFlags }
1952
2000
  });
1953
- process.exit(ExitCode5.VALIDATION_ERROR);
2001
+ process.exit(ExitCode6.VALIDATION_ERROR);
1954
2002
  }
1955
2003
  throw err;
1956
2004
  }
1957
2005
  const similarSlug = typeof args.similar === "string" ? args.similar.trim() : "";
1958
2006
  if (similarSlug.length === 0) {
1959
- cliError("--similar <slug> is required", ExitCode5.VALIDATION_ERROR, {
2007
+ cliError("--similar <slug> is required", ExitCode6.VALIDATION_ERROR, {
1960
2008
  name: "E_VALIDATION",
1961
2009
  fix: "Example: `cleo docs find --similar adr-073-above-epic-naming --limit 5`."
1962
2010
  });
1963
- process.exit(ExitCode5.VALIDATION_ERROR);
2011
+ process.exit(ExitCode6.VALIDATION_ERROR);
1964
2012
  }
1965
2013
  let limit;
1966
2014
  if (typeof args.limit === "string") {
@@ -1968,12 +2016,12 @@ var findCommand = defineCommand({
1968
2016
  if (!Number.isFinite(parsed) || parsed <= 0) {
1969
2017
  cliError(
1970
2018
  `--limit must be a positive integer (got "${args.limit}")`,
1971
- ExitCode5.VALIDATION_ERROR,
2019
+ ExitCode6.VALIDATION_ERROR,
1972
2020
  {
1973
2021
  name: "E_VALIDATION"
1974
2022
  }
1975
2023
  );
1976
- process.exit(ExitCode5.VALIDATION_ERROR);
2024
+ process.exit(ExitCode6.VALIDATION_ERROR);
1977
2025
  }
1978
2026
  limit = parsed;
1979
2027
  }
@@ -1983,10 +2031,10 @@ var findCommand = defineCommand({
1983
2031
  if (!Number.isFinite(parsed) || parsed < 0 || parsed > 1) {
1984
2032
  cliError(
1985
2033
  `--threshold must be a number in [0, 1] (got "${args.threshold}")`,
1986
- ExitCode5.VALIDATION_ERROR,
2034
+ ExitCode6.VALIDATION_ERROR,
1987
2035
  { name: "E_VALIDATION" }
1988
2036
  );
1989
- process.exit(ExitCode5.VALIDATION_ERROR);
2037
+ process.exit(ExitCode6.VALIDATION_ERROR);
1990
2038
  }
1991
2039
  threshold = parsed;
1992
2040
  }
@@ -2002,8 +2050,8 @@ var findCommand = defineCommand({
2002
2050
  } catch (err) {
2003
2051
  const code = err instanceof Error && typeof err.code === "string" ? err.code : "E_DOCS_FIND_FAILED";
2004
2052
  const message = err instanceof Error ? err.message : String(err);
2005
- cliError(`docs find failed: ${message}`, ExitCode5.GENERAL_ERROR, { name: code });
2006
- process.exit(ExitCode5.GENERAL_ERROR);
2053
+ cliError(`docs find failed: ${message}`, ExitCode6.GENERAL_ERROR, { name: code });
2054
+ process.exit(ExitCode6.GENERAL_ERROR);
2007
2055
  }
2008
2056
  }
2009
2057
  });
@@ -2060,10 +2108,10 @@ var mergeCommand = defineCommand({
2060
2108
  cliOutput(result, { command: "docs merge", operation: "docs.merge" });
2061
2109
  } catch (err) {
2062
2110
  const message = err instanceof Error ? err.message : String(err);
2063
- cliError(`docs merge failed: ${message}`, ExitCode5.GENERAL_ERROR, {
2111
+ cliError(`docs merge failed: ${message}`, ExitCode6.GENERAL_ERROR, {
2064
2112
  name: "E_DOCS_MERGE_FAILED"
2065
2113
  });
2066
- process.exit(ExitCode5.GENERAL_ERROR);
2114
+ process.exit(ExitCode6.GENERAL_ERROR);
2067
2115
  }
2068
2116
  }
2069
2117
  });
@@ -2117,13 +2165,13 @@ var queryCommand = defineCommand({
2117
2165
  assertKnownFlags(rawArgs, queryCommand.args, "docs query");
2118
2166
  } catch (err) {
2119
2167
  if (err instanceof UnknownFlagError) {
2120
- cliError(err.message, ExitCode5.VALIDATION_ERROR, {
2168
+ cliError(err.message, ExitCode6.VALIDATION_ERROR, {
2121
2169
  name: err.code,
2122
2170
  fix: err.fix,
2123
2171
  alternatives: err.suggestions.map((s) => ({ action: s, command: s })),
2124
2172
  details: { flag: err.flag, knownFlags: err.knownFlags }
2125
2173
  });
2126
- process.exit(ExitCode5.VALIDATION_ERROR);
2174
+ process.exit(ExitCode6.VALIDATION_ERROR);
2127
2175
  }
2128
2176
  throw err;
2129
2177
  }
@@ -2140,24 +2188,24 @@ var queryCommand = defineCommand({
2140
2188
  if (modes.length === 0) {
2141
2189
  cliError(
2142
2190
  "docs query requires a query mode: pass a free-text <query>, --similar <slug>, or --for <id>",
2143
- ExitCode5.VALIDATION_ERROR,
2191
+ ExitCode6.VALIDATION_ERROR,
2144
2192
  {
2145
2193
  name: "E_VALIDATION",
2146
2194
  fix: 'Examples: cleo docs query "authentication flow" | cleo docs query --similar adr-073 | cleo docs query --for T123'
2147
2195
  }
2148
2196
  );
2149
- process.exit(ExitCode5.VALIDATION_ERROR);
2197
+ process.exit(ExitCode6.VALIDATION_ERROR);
2150
2198
  }
2151
2199
  if (modes.length > 1) {
2152
2200
  cliError(
2153
2201
  `docs query modes are mutually exclusive \u2014 got ${modes.join(", ")}. Choose one.`,
2154
- ExitCode5.VALIDATION_ERROR,
2202
+ ExitCode6.VALIDATION_ERROR,
2155
2203
  {
2156
2204
  name: "E_VALIDATION",
2157
2205
  fix: "Pass exactly one of: free-text <query>, --similar <slug>, or --for <id>"
2158
2206
  }
2159
2207
  );
2160
- process.exit(ExitCode5.VALIDATION_ERROR);
2208
+ process.exit(ExitCode6.VALIDATION_ERROR);
2161
2209
  }
2162
2210
  let limit;
2163
2211
  if (typeof args.limit === "string") {
@@ -2165,10 +2213,10 @@ var queryCommand = defineCommand({
2165
2213
  if (!Number.isFinite(parsed) || parsed <= 0) {
2166
2214
  cliError(
2167
2215
  `--limit must be a positive integer (got "${args.limit}")`,
2168
- ExitCode5.VALIDATION_ERROR,
2216
+ ExitCode6.VALIDATION_ERROR,
2169
2217
  { name: "E_VALIDATION" }
2170
2218
  );
2171
- process.exit(ExitCode5.VALIDATION_ERROR);
2219
+ process.exit(ExitCode6.VALIDATION_ERROR);
2172
2220
  }
2173
2221
  limit = parsed;
2174
2222
  }
@@ -2178,10 +2226,10 @@ var queryCommand = defineCommand({
2178
2226
  if (!Number.isFinite(parsed) || parsed < 0 || parsed > 1) {
2179
2227
  cliError(
2180
2228
  `--threshold must be a number in [0, 1] (got "${args.threshold}")`,
2181
- ExitCode5.VALIDATION_ERROR,
2229
+ ExitCode6.VALIDATION_ERROR,
2182
2230
  { name: "E_VALIDATION" }
2183
2231
  );
2184
- process.exit(ExitCode5.VALIDATION_ERROR);
2232
+ process.exit(ExitCode6.VALIDATION_ERROR);
2185
2233
  }
2186
2234
  threshold = parsed;
2187
2235
  }
@@ -2213,8 +2261,8 @@ var queryCommand = defineCommand({
2213
2261
  } catch (err) {
2214
2262
  const message = err instanceof Error ? err.message : String(err);
2215
2263
  const code = err instanceof Error && typeof err.code === "string" ? err.code : "E_DOCS_QUERY_FAILED";
2216
- cliError(`docs query failed: ${message}`, ExitCode5.GENERAL_ERROR, { name: code });
2217
- process.exit(ExitCode5.GENERAL_ERROR);
2264
+ cliError(`docs query failed: ${message}`, ExitCode6.GENERAL_ERROR, { name: code });
2265
+ process.exit(ExitCode6.GENERAL_ERROR);
2218
2266
  }
2219
2267
  }
2220
2268
  });
@@ -2247,10 +2295,10 @@ var rankCommand = defineCommand({
2247
2295
  cliOutput(result, { command: "docs rank", operation: "docs.rank" });
2248
2296
  } catch (err) {
2249
2297
  const message = err instanceof Error ? err.message : String(err);
2250
- cliError(`docs rank failed: ${message}`, ExitCode5.GENERAL_ERROR, {
2298
+ cliError(`docs rank failed: ${message}`, ExitCode6.GENERAL_ERROR, {
2251
2299
  name: "E_DOCS_RANK_FAILED"
2252
2300
  });
2253
- process.exit(ExitCode5.GENERAL_ERROR);
2301
+ process.exit(ExitCode6.GENERAL_ERROR);
2254
2302
  }
2255
2303
  }
2256
2304
  });
@@ -2312,13 +2360,13 @@ var updateCommand = defineCommand({
2312
2360
  assertKnownFlags(rawArgs, updateCommand.args, "docs update");
2313
2361
  } catch (err) {
2314
2362
  if (err instanceof UnknownFlagError) {
2315
- cliError(err.message, ExitCode5.VALIDATION_ERROR, {
2363
+ cliError(err.message, ExitCode6.VALIDATION_ERROR, {
2316
2364
  name: err.code,
2317
2365
  fix: err.fix,
2318
2366
  alternatives: err.suggestions.map((s) => ({ action: s, command: s })),
2319
2367
  details: { flag: err.flag, knownFlags: err.knownFlags }
2320
2368
  });
2321
- process.exit(ExitCode5.VALIDATION_ERROR);
2369
+ process.exit(ExitCode6.VALIDATION_ERROR);
2322
2370
  }
2323
2371
  throw err;
2324
2372
  }
@@ -2326,22 +2374,22 @@ var updateCommand = defineCommand({
2326
2374
  const filePath = typeof args.file === "string" ? args.file : void 0;
2327
2375
  const inlineContent = typeof args.content === "string" ? args.content : void 0;
2328
2376
  if (filePath !== void 0 && inlineContent !== void 0) {
2329
- cliError("--file and --content are mutually exclusive", ExitCode5.VALIDATION_ERROR, {
2377
+ cliError("--file and --content are mutually exclusive", ExitCode6.VALIDATION_ERROR, {
2330
2378
  name: "E_VALIDATION",
2331
2379
  fix: "Use `cleo docs update <slug> --file <path>` OR `--content <text>` (not both)."
2332
2380
  });
2333
- process.exit(ExitCode5.VALIDATION_ERROR);
2381
+ process.exit(ExitCode6.VALIDATION_ERROR);
2334
2382
  }
2335
2383
  if (filePath === void 0 && inlineContent === void 0 && typeof args.status !== "string") {
2336
2384
  cliError(
2337
2385
  "provide --file <path>, --content <text>, or --status <status> alone",
2338
- ExitCode5.VALIDATION_ERROR,
2386
+ ExitCode6.VALIDATION_ERROR,
2339
2387
  {
2340
2388
  name: "E_VALIDATION",
2341
2389
  fix: 'Example: `cleo docs update my-doc --file ./new.md`, `--content "..."`, or `cleo docs update my-doc --status accepted` to change only the lifecycle status.'
2342
2390
  }
2343
2391
  );
2344
- process.exit(ExitCode5.VALIDATION_ERROR);
2392
+ process.exit(ExitCode6.VALIDATION_ERROR);
2345
2393
  }
2346
2394
  let resolvedFile;
2347
2395
  if (filePath !== void 0) {
@@ -2396,10 +2444,10 @@ var versionsCommand = defineCommand({
2396
2444
  cliOutput(result, { command: "docs versions", operation: "docs.versions" });
2397
2445
  } catch (err) {
2398
2446
  const message = err instanceof Error ? err.message : String(err);
2399
- cliError(`docs versions failed: ${message}`, ExitCode5.GENERAL_ERROR, {
2447
+ cliError(`docs versions failed: ${message}`, ExitCode6.GENERAL_ERROR, {
2400
2448
  name: "E_DOCS_VERSIONS_FAILED"
2401
2449
  });
2402
- process.exit(ExitCode5.GENERAL_ERROR);
2450
+ process.exit(ExitCode6.GENERAL_ERROR);
2403
2451
  }
2404
2452
  }
2405
2453
  });
@@ -2484,10 +2532,10 @@ var publishCommand = defineCommand({
2484
2532
  if (!slugOrId) {
2485
2533
  cliError(
2486
2534
  "docs publish --target pr requires a slug-or-id argument",
2487
- ExitCode5.GENERAL_ERROR,
2535
+ ExitCode6.GENERAL_ERROR,
2488
2536
  { name: "E_MISSING_ARG" }
2489
2537
  );
2490
- process.exit(ExitCode5.GENERAL_ERROR);
2538
+ process.exit(ExitCode6.GENERAL_ERROR);
2491
2539
  }
2492
2540
  const result = await dispatchDocsRaw("mutate", "publish", {
2493
2541
  slugOrId,
@@ -2506,7 +2554,7 @@ var publishCommand = defineCommand({
2506
2554
  const e = result.error;
2507
2555
  cliError(
2508
2556
  e.message,
2509
- ExitCode5.GENERAL_ERROR,
2557
+ ExitCode6.GENERAL_ERROR,
2510
2558
  {
2511
2559
  name: e.codeName,
2512
2560
  ...e.fix ? { fix: e.fix } : {},
@@ -2515,15 +2563,15 @@ var publishCommand = defineCommand({
2515
2563
  },
2516
2564
  { operation: "docs.publish" }
2517
2565
  );
2518
- process.exit(ExitCode5.GENERAL_ERROR);
2566
+ process.exit(ExitCode6.GENERAL_ERROR);
2519
2567
  }
2520
2568
  if (!args.for || !args.to) {
2521
2569
  cliError(
2522
2570
  "docs publish --target file requires --for <ownerId> and --to <path>",
2523
- ExitCode5.GENERAL_ERROR,
2571
+ ExitCode6.GENERAL_ERROR,
2524
2572
  { name: "E_MISSING_ARG" }
2525
2573
  );
2526
- process.exit(ExitCode5.GENERAL_ERROR);
2574
+ process.exit(ExitCode6.GENERAL_ERROR);
2527
2575
  }
2528
2576
  try {
2529
2577
  const result = await dispatchDocsRaw("mutate", "publish", {
@@ -2535,10 +2583,10 @@ var publishCommand = defineCommand({
2535
2583
  cliOutput(result, { command: "docs publish", operation: "docs.publish" });
2536
2584
  } catch (err) {
2537
2585
  const message = err instanceof Error ? err.message : String(err);
2538
- cliError(`docs publish failed: ${message}`, ExitCode5.GENERAL_ERROR, {
2586
+ cliError(`docs publish failed: ${message}`, ExitCode6.GENERAL_ERROR, {
2539
2587
  name: "E_DOCS_PUBLISH_FAILED"
2540
2588
  });
2541
- process.exit(ExitCode5.GENERAL_ERROR);
2589
+ process.exit(ExitCode6.GENERAL_ERROR);
2542
2590
  }
2543
2591
  }
2544
2592
  });
@@ -2604,7 +2652,7 @@ var publishPrCommand = defineCommand({
2604
2652
  const e = result.error;
2605
2653
  cliError(
2606
2654
  e.message,
2607
- ExitCode5.GENERAL_ERROR,
2655
+ ExitCode6.GENERAL_ERROR,
2608
2656
  {
2609
2657
  name: e.codeName,
2610
2658
  ...e.fix ? { fix: e.fix } : {},
@@ -2613,7 +2661,7 @@ var publishPrCommand = defineCommand({
2613
2661
  },
2614
2662
  { operation: "docs.publish" }
2615
2663
  );
2616
- process.exit(ExitCode5.GENERAL_ERROR);
2664
+ process.exit(ExitCode6.GENERAL_ERROR);
2617
2665
  }
2618
2666
  });
2619
2667
  var checkCommand = defineCommand({
@@ -2755,10 +2803,10 @@ var syncCommand = defineCommand({
2755
2803
  if (!ownerId) {
2756
2804
  cliError(
2757
2805
  "--for <ownerId> is required when --from <path> is set",
2758
- ExitCode5.VALIDATION_ERROR,
2806
+ ExitCode6.VALIDATION_ERROR,
2759
2807
  { name: "E_VALIDATION" }
2760
2808
  );
2761
- process.exit(ExitCode5.VALIDATION_ERROR);
2809
+ process.exit(ExitCode6.VALIDATION_ERROR);
2762
2810
  }
2763
2811
  try {
2764
2812
  const result = await dispatchDocsRaw("mutate", "sync", {
@@ -2770,10 +2818,10 @@ var syncCommand = defineCommand({
2770
2818
  cliOutput(result, { command: "docs sync", operation: "docs.sync" });
2771
2819
  } catch (err) {
2772
2820
  const message = err instanceof Error ? err.message : String(err);
2773
- cliError(`docs sync failed: ${message}`, ExitCode5.GENERAL_ERROR, {
2821
+ cliError(`docs sync failed: ${message}`, ExitCode6.GENERAL_ERROR, {
2774
2822
  name: "E_DOCS_SYNC_FAILED"
2775
2823
  });
2776
- process.exit(ExitCode5.GENERAL_ERROR);
2824
+ process.exit(ExitCode6.GENERAL_ERROR);
2777
2825
  }
2778
2826
  return;
2779
2827
  }
@@ -2824,10 +2872,10 @@ var statusCommand = defineCommand({
2824
2872
  }
2825
2873
  } catch (err) {
2826
2874
  const message = err instanceof Error ? err.message : String(err);
2827
- cliError(`docs status failed: ${message}`, ExitCode5.GENERAL_ERROR, {
2875
+ cliError(`docs status failed: ${message}`, ExitCode6.GENERAL_ERROR, {
2828
2876
  name: "E_DOCS_STATUS_FAILED"
2829
2877
  });
2830
- process.exit(ExitCode5.GENERAL_ERROR);
2878
+ process.exit(ExitCode6.GENERAL_ERROR);
2831
2879
  }
2832
2880
  }
2833
2881
  });
@@ -2933,16 +2981,16 @@ var importCommand = defineCommand({
2933
2981
  cliOutput(result, { command: "docs import", operation: "docs.import" });
2934
2982
  } catch (err) {
2935
2983
  if (err instanceof CounterMismatchError) {
2936
- cliError(err.message, ExitCode5.GENERAL_ERROR, {
2984
+ cliError(err.message, ExitCode6.GENERAL_ERROR, {
2937
2985
  name: "E_COUNTER_MISMATCH"
2938
2986
  });
2939
- process.exit(ExitCode5.GENERAL_ERROR);
2987
+ process.exit(ExitCode6.GENERAL_ERROR);
2940
2988
  }
2941
2989
  const message = err instanceof Error ? err.message : String(err);
2942
- cliError(`docs import failed: ${message}`, ExitCode5.GENERAL_ERROR, {
2990
+ cliError(`docs import failed: ${message}`, ExitCode6.GENERAL_ERROR, {
2943
2991
  name: "E_DOCS_IMPORT_FAILED"
2944
2992
  });
2945
- process.exit(ExitCode5.GENERAL_ERROR);
2993
+ process.exit(ExitCode6.GENERAL_ERROR);
2946
2994
  }
2947
2995
  }
2948
2996
  });
@@ -3081,7 +3129,7 @@ var listTypesCommand = defineCommand({
3081
3129
  var docsCommand = defineCommand({
3082
3130
  meta: {
3083
3131
  name: "docs",
3084
- description: "Canonical six-verb docs path: add, update, fetch, list, remove, publish. Unified query: query (subsumes search/find/rank). LLM output: llm-output (replaces generate + export). Advanced: supersede, merge, graph, versions. Audit: audit (query the immutable docs audit trail). Legacy/migration: search, find, rank, sync, status, gap-check, import (use query for new work). Viewer: viewer (start/stop/open/status). Utilities: schema (list-types \u2192 schema)."
3132
+ description: "Canonical six-verb docs path: add, update, fetch, list, remove, publish. Unified query: query (subsumes search/find/rank). LLM output: llm-output (replaces generate + export). Advanced: supersede, merge, graph, versions. Audit: audit (query the immutable docs audit trail). Triage: triage (batch docs.triage verdicts \u2014 proposals only, --record persists D####) (T13446). Legacy/migration: search, find, rank, sync, status, gap-check, import (use query for new work). Viewer: viewer (start/stop/open/status). Utilities: schema (list-types \u2192 schema)."
3085
3133
  },
3086
3134
  subCommands: {
3087
3135
  // T11136 — Unified drift management (consolidates sync/status/gap-check)
@@ -3115,6 +3163,8 @@ var docsCommand = defineCommand({
3115
3163
  "publish-pr": publishPrCommand,
3116
3164
  // T11182 — unified docs audit trail
3117
3165
  audit: auditCommand,
3166
+ // T13446 — docs.triage batch triage (proposals only; --record persists D#### verdicts)
3167
+ triage: triageCommand,
3118
3168
  // Legacy/migration (use canonical verbs for new work)
3119
3169
  sync: syncCommand,
3120
3170
  status: statusCommand,
@@ -3136,4 +3186,4 @@ export {
3136
3186
  _llmOutputCommand,
3137
3187
  docsCommand
3138
3188
  };
3139
- //# sourceMappingURL=docs-DMYQCRZF.js.map
3189
+ //# sourceMappingURL=docs-7QSB4NT2.js.map
@@ -48,7 +48,7 @@ import {
48
48
  } from "./chunk-KZTPVED2.js";
49
49
  import {
50
50
  doctorToolLocksCommand
51
- } from "./chunk-LLDYX63U.js";
51
+ } from "./chunk-DX6TRZV7.js";
52
52
  import {
53
53
  doctorMemoryGuardCommand
54
54
  } from "./chunk-HXRXT3XU.js";
@@ -126,7 +126,7 @@ import {
126
126
  import {
127
127
  dispatchFromCli,
128
128
  dispatchRaw
129
- } from "./chunk-J6GFQY5V.js";
129
+ } from "./chunk-SXN3DUMZ.js";
130
130
  import "./chunk-6N6WGLXE.js";
131
131
  import "./chunk-4VASFLUW.js";
132
132
  import {
@@ -140,7 +140,7 @@ import {
140
140
  } from "./chunk-4RGSNUUP.js";
141
141
  import "./chunk-6JSJNYH2.js";
142
142
  import "./chunk-D7BAQNV2.js";
143
- import "./chunk-YI5O7YZO.js";
143
+ import "./chunk-KKR5BMKV.js";
144
144
 
145
145
  // packages/cleo/src/cli/commands/doctor.ts
146
146
  import { mkdirSync, writeFileSync } from "node:fs";
@@ -1276,4 +1276,4 @@ Dependency cycles: check skipped (${msg})`);
1276
1276
  export {
1277
1277
  doctorCommand
1278
1278
  };
1279
- //# sourceMappingURL=doctor-ZSTYV4FJ.js.map
1279
+ //# sourceMappingURL=doctor-YAKOPWUS.js.map
@@ -15,7 +15,7 @@
15
15
  })();
16
16
  import {
17
17
  doctorToolLocksCommand
18
- } from "./chunk-LLDYX63U.js";
18
+ } from "./chunk-DX6TRZV7.js";
19
19
  import "./chunk-C3B7C43W.js";
20
20
  import "./chunk-PKKZPOOP.js";
21
21
  import "./chunk-4RGSNUUP.js";
@@ -23,4 +23,4 @@ import "./chunk-6JSJNYH2.js";
23
23
  export {
24
24
  doctorToolLocksCommand
25
25
  };
26
- //# sourceMappingURL=doctor-tool-locks-W22MYJHN.js.map
26
+ //# sourceMappingURL=doctor-tool-locks-QCBTDZPG.js.map