@iowarp/clio-coder 0.5.1 → 0.5.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 (263) hide show
  1. package/.claude-plugin/marketplace.json +4 -4
  2. package/CHANGELOG.md +24 -0
  3. package/CONTRIBUTING.md +9 -0
  4. package/README.md +3 -3
  5. package/ROADMAP.md +30 -5
  6. package/dist/{acp-X3N7JDGS.js → acp-F6PGOFZ4.js} +2 -2
  7. package/dist/{agents-UYGSMAWR.js → agents-ZHP4R6EX.js} +22 -21
  8. package/dist/assets/codewiki.json +1 -1
  9. package/dist/{auth-CEDCO6O6.js → auth-N75U2H3Z.js} +4 -4
  10. package/dist/{chunk-DGMY2DWE.js → chunk-23UIXH6Z.js} +3 -3
  11. package/dist/{chunk-QTYRMBW6.js → chunk-36XVK5P5.js} +5 -5
  12. package/dist/{chunk-BIQLF3NZ.js → chunk-3DZ4LPLS.js} +6 -6
  13. package/dist/{chunk-7VNLPEUG.js → chunk-3GSPCWFX.js} +12 -12
  14. package/dist/{chunk-CRHPCPZP.js → chunk-4KC4CHKJ.js} +2 -2
  15. package/dist/{chunk-M5FPIZQW.js → chunk-4WJBWKMI.js} +2 -2
  16. package/dist/{chunk-KBUTSJSR.js → chunk-4XBYHXGK.js} +2 -2
  17. package/dist/{chunk-6W75D37F.js → chunk-53P775GE.js} +6 -3
  18. package/dist/{chunk-XZWSP67B.js → chunk-5APYAXCB.js} +2 -2
  19. package/dist/{chunk-A7G7OUND.js → chunk-67HPYNTJ.js} +2 -2
  20. package/dist/{chunk-5JQR5B4D.js → chunk-6KV4KCQZ.js} +4 -4
  21. package/dist/{chunk-V4XJWDHR.js → chunk-6UKFRTXI.js} +2 -1
  22. package/dist/{chunk-NDPF2N2L.js → chunk-7DW7CJW2.js} +2 -2
  23. package/dist/{chunk-5KQEUIWM.js → chunk-7LUEQODV.js} +4 -4
  24. package/dist/{chunk-LNOXCGN2.js → chunk-7UFDIOBT.js} +3 -3
  25. package/dist/{chunk-DXSETN72.js → chunk-7WUGNN43.js} +2 -2
  26. package/dist/{chunk-GW2KVAVI.js → chunk-AA3GRZWS.js} +2 -2
  27. package/dist/{chunk-6B76U65H.js → chunk-ADO3OQIC.js} +3 -3
  28. package/dist/{chunk-UX2L5CUD.js → chunk-AI36V3ON.js} +3 -3
  29. package/dist/{chunk-B7GY6QER.js → chunk-B26OUMJW.js} +2 -2
  30. package/dist/{chunk-LAR7DX5E.js → chunk-B5TASTCK.js} +153 -62
  31. package/dist/{chunk-TGWZXJ7L.js → chunk-BEMQK5Q7.js} +92 -84
  32. package/dist/{chunk-RNDCROSG.js → chunk-CNXU7TR2.js} +3 -3
  33. package/dist/{chunk-AKQ3N3L4.js → chunk-CVMUXT64.js} +35 -66
  34. package/dist/{chunk-733ZBT5P.js → chunk-E74MJF6G.js} +4 -4
  35. package/dist/{chunk-T2MDZES3.js → chunk-EBMTBE76.js} +3 -3
  36. package/dist/{chunk-OZ76TLGU.js → chunk-EEITU7S6.js} +2 -2
  37. package/dist/{chunk-7KI4ZSEB.js → chunk-ELDJWJKM.js} +97 -14
  38. package/dist/{chunk-GCQFN7YI.js → chunk-EMYEQLWO.js} +2 -2
  39. package/dist/{chunk-7FHSA7VB.js → chunk-EQPFEDFV.js} +222 -127
  40. package/dist/{chunk-TDGYTWM6.js → chunk-F4I3H56H.js} +2 -2
  41. package/dist/chunk-F6KCJO3U.js +523 -0
  42. package/dist/{chunk-FGSQHUCK.js → chunk-F6VKWTTY.js} +5 -5
  43. package/dist/{chunk-UJD5MPP6.js → chunk-FLNXQQ5B.js} +2 -2
  44. package/dist/{chunk-GGEEG7CD.js → chunk-FOSRJ2VZ.js} +4 -4
  45. package/dist/{chunk-ZARZ4POR.js → chunk-G5ZDQQE3.js} +3 -3
  46. package/dist/{chunk-QM7HFPQQ.js → chunk-G62JBPXN.js} +7 -7
  47. package/dist/{chunk-ZJPORZTC.js → chunk-GIAI7A2K.js} +2 -2
  48. package/dist/chunk-GPTR6OTU.js +2551 -0
  49. package/dist/{chunk-EZD2BXGP.js → chunk-GUFQPTQK.js} +2 -2
  50. package/dist/{chunk-OPD7GL6F.js → chunk-H6FQVNZC.js} +8 -7
  51. package/dist/chunk-H7REJ7L5.js +80 -0
  52. package/dist/{chunk-EYTLV3W3.js → chunk-HTWTORF7.js} +2 -2
  53. package/dist/{chunk-DF6PI6GN.js → chunk-I6UKQPGS.js} +3 -3
  54. package/dist/{chunk-ISHUS7HC.js → chunk-JRW236JT.js} +3 -3
  55. package/dist/{chunk-DE2LU267.js → chunk-KKAJGT3B.js} +3 -2
  56. package/dist/{chunk-OV62D6KO.js → chunk-KQMYL5GR.js} +3 -3
  57. package/dist/{chunk-WAISUJNQ.js → chunk-KWMFC7FN.js} +3 -3
  58. package/dist/{chunk-4D7QM7S5.js → chunk-LXYHCCIZ.js} +9 -9
  59. package/dist/{chunk-NFSK2VNU.js → chunk-LZMTVVN4.js} +2 -2
  60. package/dist/{chunk-ZNTGRDFA.js → chunk-M5PMRZSR.js} +123 -37
  61. package/dist/chunk-MMZMM6SW.js +131 -0
  62. package/dist/{chunk-FFYTC2KQ.js → chunk-MNABNEBX.js} +2 -2
  63. package/dist/{chunk-XMDBTYCH.js → chunk-N3CWOGVF.js} +3 -3
  64. package/dist/{chunk-VYRQHORQ.js → chunk-NMQSO6Z6.js} +4 -3
  65. package/dist/{chunk-4SYHGVDE.js → chunk-OQNCLZI4.js} +4 -4
  66. package/dist/{chunk-EG4ARXPC.js → chunk-OX6QTA4N.js} +3 -3
  67. package/dist/{chunk-P4GNZPXO.js → chunk-OYUS3UZP.js} +2 -2
  68. package/dist/{chunk-VWKR2NN5.js → chunk-PF36KOGI.js} +290 -111
  69. package/dist/{chunk-LFYA3HYH.js → chunk-PIU6BXXW.js} +2 -2
  70. package/dist/{chunk-EKV4UBCM.js → chunk-PZBQUJ2F.js} +2 -2
  71. package/dist/{chunk-7RET77VB.js → chunk-Q2HKY32Y.js} +2 -2
  72. package/dist/{chunk-VMTCZ2GR.js → chunk-Q4RMNWMZ.js} +4 -4
  73. package/dist/chunk-Q6FRR3AQ.js +48 -0
  74. package/dist/{chunk-6RJMYYIE.js → chunk-QJSIAJBY.js} +3 -3
  75. package/dist/{chunk-DOUISWEE.js → chunk-QOJ4ERMU.js} +5 -5
  76. package/dist/{chunk-IFPDAD7R.js → chunk-RWSRKXLT.js} +3 -3
  77. package/dist/{chunk-T33IYTZM.js → chunk-SAASVMIY.js} +3 -3
  78. package/dist/{chunk-2DTIWSAW.js → chunk-SEQDH6JC.js} +3 -3
  79. package/dist/{chunk-BRCOSE7O.js → chunk-SZUO5BSE.js} +2 -2
  80. package/dist/{chunk-HOEDA42N.js → chunk-T7HZ7KJF.js} +2 -2
  81. package/dist/{chunk-UCINIRHW.js → chunk-TPCZXWLT.js} +3 -3
  82. package/dist/{chunk-ZUKUCZYZ.js → chunk-TQ2KTH4A.js} +2 -2
  83. package/dist/{chunk-4WOOTKFD.js → chunk-U3FETNQB.js} +341 -20
  84. package/dist/{chunk-5B3RTYAK.js → chunk-UGDSB4AN.js} +2 -2
  85. package/dist/{chunk-VKHLUZNO.js → chunk-UZ7YBL43.js} +3 -3
  86. package/dist/{chunk-OXWRE2QJ.js → chunk-VKMSEO7Y.js} +4 -4
  87. package/dist/{chunk-FBXTHPNZ.js → chunk-VLX5VZ35.js} +5 -5
  88. package/dist/{chunk-KIAUZGKF.js → chunk-WAGBMMNX.js} +5 -5
  89. package/dist/{chunk-BFOSV5EZ.js → chunk-WX2YCH7F.js} +2 -2
  90. package/dist/{chunk-SAL2SBP4.js → chunk-XBIGUILU.js} +25 -10
  91. package/dist/{chunk-XOH3SD7H.js → chunk-XKYBFRWR.js} +5 -5
  92. package/dist/{chunk-U5QU5ZOD.js → chunk-XYPWFSU5.js} +3 -3
  93. package/dist/{chunk-YBUECLAF.js → chunk-YEJQDODA.js} +2 -2
  94. package/dist/{chunk-YQ6XEFVK.js → chunk-Z74OGONW.js} +39 -7
  95. package/dist/{chunk-I4ELN5BX.js → chunk-ZTNOEJRI.js} +2 -2
  96. package/dist/cli/index.js +25 -25
  97. package/dist/{clio-Z3JTEL2I.js → clio-4IKFE25F.js} +2 -2
  98. package/dist/{clio-context-tools-GR4OHFSO.js → clio-context-tools-OHJXYX4R.js} +25 -23
  99. package/dist/{code-nav-4X3OI6DK.js → code-nav-XPM3MY5I.js} +7 -7
  100. package/dist/{config-QYIRZHI7.js → config-343YS25T.js} +42 -40
  101. package/dist/{config-graph-TS3SGGQW.js → config-graph-WI263KDX.js} +42 -40
  102. package/dist/{configure-OX7KVJTQ.js → configure-GZDG4HER.js} +21 -21
  103. package/dist/{context-2BNF6HTP.js → context-4OFO7N7Y.js} +12 -12
  104. package/dist/{context-GTMUGAR4.js → context-JLK2RLOG.js} +41 -39
  105. package/dist/{context-NNLBES2Y.js → context-O6DIWCF6.js} +23 -21
  106. package/dist/{context-clear-FVJQBBL7.js → context-clear-MR7KOGQI.js} +41 -39
  107. package/dist/{context-working-set-MOE72SD6.js → context-working-set-YZAD3KWO.js} +14 -13
  108. package/dist/{data-tool-JJPBGMQJ.js → data-tool-EKD7DFHG.js} +7 -7
  109. package/dist/{detail-QZM3QAAU.js → detail-YZPHFEVJ.js} +42 -40
  110. package/dist/{dispatch-runner-2KSQO5FU.js → dispatch-runner-VKVXVTWJ.js} +43 -41
  111. package/dist/{doctor-2U6YR5NH.js → doctor-53AVQXAO.js} +16 -15
  112. package/dist/{doctor-deep-2EJQSHIZ.js → doctor-deep-BLRB2NCG.js} +5 -5
  113. package/dist/{eval-ZKK77JWZ.js → eval-P3BQSLQE.js} +21 -20
  114. package/dist/{evidence-POSEQW4Q.js → evidence-6LLI6SZH.js} +43 -41
  115. package/dist/{evidence-FMP7KZZ2.js → evidence-HTN3JLUO.js} +41 -39
  116. package/dist/{evidence-PJTOE7JA.js → evidence-NJRE3R5H.js} +41 -39
  117. package/dist/{evolve-JT6PAMZE.js → evolve-WWZHJVJP.js} +41 -39
  118. package/dist/{fleet-4XR2ZEOF.js → fleet-GGZ4BVJE.js} +63 -61
  119. package/dist/{fleet-6JJKNIMV.js → fleet-QG3IIWWM.js} +43 -41
  120. package/dist/{fleet-commands-L6WFT7KZ.js → fleet-commands-J2ZIKISQ.js} +7 -7
  121. package/dist/{fleet-decisions-BTQMWU5A.js → fleet-decisions-Y2Q7375Q.js} +8 -8
  122. package/dist/{fleet-graph-553DZ67Q.js → fleet-graph-TCBCCCBP.js} +11 -11
  123. package/dist/{fleet-inspect-SWJMFVDP.js → fleet-inspect-KOLKBC56.js} +43 -41
  124. package/dist/{fleet-preflight-KSIHWQAU.js → fleet-preflight-44UNCC4Y.js} +26 -24
  125. package/dist/{fleet-validate-7NLAE26R.js → fleet-validate-K2FXRZVA.js} +13 -13
  126. package/dist/{fleet-verify-QM6XU2KL.js → fleet-verify-AS444WDW.js} +41 -39
  127. package/dist/{fleet-view-RLKFHFCM.js → fleet-view-X4JU4J6O.js} +42 -40
  128. package/dist/gui/ops-worker.js +9 -9
  129. package/dist/gui/reads-worker.js +9 -8
  130. package/dist/{init-VBUPHABR.js → init-VSOWFHVL.js} +53 -51
  131. package/dist/{interactive-JCVBPVYT.js → interactive-JRCBENLZ.js} +154 -92
  132. package/dist/{interop-J7UOBOSF.js → interop-JR6BCY7R.js} +10 -10
  133. package/dist/{inventory-54G7FSVY.js → inventory-3JUGLVJI.js} +42 -40
  134. package/dist/{library-ROZAMUIL.js → library-7BOH3Y7N.js} +15 -15
  135. package/dist/{library-B3UPGY4V.js → library-7PFONXUI.js} +9 -9
  136. package/dist/{library-MXQA5DLT.js → library-TUYZMFIA.js} +7 -7
  137. package/dist/{library-import-2LTWOVBD.js → library-import-TJVXKLDK.js} +10 -10
  138. package/dist/{library-inventory-LJ3XHLWO.js → library-inventory-MD3AYTP4.js} +9 -9
  139. package/dist/{library-validation-DARHHUNW.js → library-validation-ZDLITEA3.js} +7 -7
  140. package/dist/{memory-5BPQSSOP.js → memory-Q2YVOKK5.js} +41 -39
  141. package/dist/{models-R6HILX6X.js → models-M7BOCW7F.js} +17 -16
  142. package/dist/{monitor-HVRKSFEQ.js → monitor-2HD3MC67.js} +46 -44
  143. package/dist/{orchestrator-OR7V4YWK.js → orchestrator-OUW3ZN6Y.js} +1890 -222
  144. package/dist/{panes-A743ONZ5.js → panes-TTPPSYCL.js} +3 -3
  145. package/dist/{preload-KLXFOX2F.js → preload-A47C2NUF.js} +41 -39
  146. package/dist/{providers-CMETPZNS.js → providers-T43W7EL4.js} +4 -4
  147. package/dist/{resources-FY6XYFN2.js → resources-TP6X2V6W.js} +20 -11
  148. package/dist/{run-UIDRUYAY.js → run-LDSBPMCS.js} +60 -58
  149. package/dist/{share-CAFMMQLM.js → share-URHKKMHR.js} +9 -9
  150. package/dist/{skills-ERKQUC7L.js → skills-E477MOOO.js} +13 -11
  151. package/dist/{skills-eval-JDAXOPWC.js → skills-eval-AIBR2L7H.js} +582 -92
  152. package/dist/{skills-inventory-TVUYJDVN.js → skills-inventory-HLMKY3R5.js} +13 -11
  153. package/dist/{slash-commands-MNKQ5QP3.js → slash-commands-LIIZKA5Y.js} +26 -24
  154. package/dist/{startup-background-PJMWTKVO.js → startup-background-JR2KDK6R.js} +42 -40
  155. package/dist/{steer-KKYXJSH4.js → steer-D7RTAPCM.js} +3 -3
  156. package/dist/{system-IVVZRKGI.js → system-X2P5N4IY.js} +14 -13
  157. package/dist/{targets-RFRUMCQ5.js → targets-VFFAKUFM.js} +25 -24
  158. package/dist/{tasks-6L2JJRC5.js → tasks-ERAWZA22.js} +6 -6
  159. package/dist/{trace-LA5MVR4Y.js → trace-MA5BT7XY.js} +3 -3
  160. package/dist/{usage-LA33SG3R.js → usage-WYFY2L6M.js} +49 -47
  161. package/dist/{verifiers-ECA5GIHL.js → verifiers-TYIW2XKF.js} +7 -7
  162. package/dist/{verify-R6QQCCEB.js → verify-242UFYTP.js} +6 -6
  163. package/dist/{web-fetch-PVZNMBOB.js → web-fetch-LRAGYU6Y.js} +3 -3
  164. package/dist/{wiki-generate-HL73TICA.js → wiki-generate-OFKOX2T6.js} +52 -50
  165. package/dist/worker/entry.js +30 -28
  166. package/docs/architecture/context-engine.md +2 -0
  167. package/docs/guide/context-continuity.md +49 -0
  168. package/docs/guide/proactive-memory.md +3 -0
  169. package/library/registry.yaml +292 -32
  170. package/library/skills/README.md +27 -2
  171. package/library/skills/context/context-handoff/SKILL.md +10 -4
  172. package/library/skills/meta/clio-coder-dev/SKILL.md +92 -88
  173. package/library/skills/meta/clio-coder-dev/evals.md +51 -46
  174. package/library/skills/meta/clio-coder-dev/plugin.json +2 -2
  175. package/library/skills/meta/clio-coder-dev/references/change-map.md +49 -0
  176. package/library/skills/meta/clio-coder-test/SKILL.md +89 -142
  177. package/library/skills/meta/clio-coder-test/evals.md +58 -62
  178. package/library/skills/meta/clio-coder-test/plugin.json +2 -2
  179. package/library/skills/meta/clio-coder-test/references/harness.md +3 -3
  180. package/library/skills/meta/clio-coder-test/references/lifecycle-validation.md +30 -0
  181. package/library/skills/meta/clio-coder-test/references/test-map.md +60 -89
  182. package/library/skills/registry.yaml +5 -5
  183. package/library/skills/skill-marketplace.json +12 -14
  184. package/package.json +1 -1
  185. package/src/cli/skills-eval.ts +1064 -54
  186. package/src/core/clio-repo.ts +3 -0
  187. package/src/core/tool-names.ts +1 -0
  188. package/src/domains/context/budget/inspection.ts +9 -0
  189. package/src/domains/context/budget/live-view.ts +418 -0
  190. package/src/domains/context/budget/pressure.ts +393 -0
  191. package/src/domains/context/budget/request-fit.ts +15 -0
  192. package/src/domains/evidence/build.ts +24 -0
  193. package/src/domains/memory/commit-state.ts +160 -0
  194. package/src/domains/memory/operations.ts +18 -10
  195. package/src/domains/memory/prompt-cache.ts +95 -0
  196. package/src/domains/memory/prompt-section.ts +50 -7
  197. package/src/domains/memory/relevance.ts +93 -0
  198. package/src/domains/memory/restoration.ts +78 -0
  199. package/src/domains/memory/store.ts +39 -1
  200. package/src/domains/middleware/memory-intervention.ts +116 -24
  201. package/src/domains/prompts/compiler.ts +1 -1
  202. package/src/domains/prompts/extension.ts +38 -1
  203. package/src/domains/resources/index.ts +11 -0
  204. package/src/domains/resources/skills/catalog-view.ts +571 -0
  205. package/src/domains/resources/skills/lexical-match.ts +136 -0
  206. package/src/domains/resources/skills/loader.ts +38 -0
  207. package/src/domains/resources/skills/promotion.ts +1 -55
  208. package/src/domains/resources/skills/provenance-pin.ts +50 -20
  209. package/src/domains/safety/action-classifier.ts +1 -0
  210. package/src/domains/session/compaction/branch-summary.ts +4 -1
  211. package/src/domains/session/compaction/compact.ts +18 -2
  212. package/src/domains/session/compaction/cut-point.ts +20 -1
  213. package/src/domains/session/compaction/tokens.ts +48 -3
  214. package/src/domains/session/context-accounting.ts +8 -1
  215. package/src/domains/session/continuity/carry.ts +59 -0
  216. package/src/domains/session/continuity/contract.ts +592 -0
  217. package/src/domains/session/continuity/evidence.ts +290 -0
  218. package/src/domains/session/continuity/fold.ts +1075 -0
  219. package/src/domains/session/continuity/note.ts +79 -0
  220. package/src/domains/session/continuity/operator-request.ts +104 -0
  221. package/src/domains/session/continuity/persistence.ts +408 -0
  222. package/src/domains/session/continuity/ports.ts +231 -0
  223. package/src/domains/session/continuity/projection.ts +538 -0
  224. package/src/domains/session/continuity/validate.ts +352 -0
  225. package/src/domains/session/entries.ts +50 -3
  226. package/src/domains/session/index.ts +48 -0
  227. package/src/domains/session/migrations/index.ts +7 -3
  228. package/src/domains/session/tree/fork.ts +15 -1
  229. package/src/engine/agent.ts +133 -9
  230. package/src/engine/session.ts +13 -6
  231. package/src/entry/orchestrator.ts +114 -31
  232. package/src/interactive/chat-loop.ts +216 -60
  233. package/src/interactive/chat-renderer.ts +99 -8
  234. package/src/interactive/context-overlay.ts +24 -3
  235. package/src/interactive/continuity-controller.ts +526 -0
  236. package/src/interactive/footer/dashboard.ts +12 -1
  237. package/src/interactive/footer/pages.ts +15 -7
  238. package/src/interactive/footer/widgets.ts +32 -7
  239. package/src/interactive/interactive-application.ts +2 -0
  240. package/src/interactive/interactive-slash-runtime.ts +43 -6
  241. package/src/interactive/model-session-replay.ts +130 -3
  242. package/src/interactive/output-reserve.ts +35 -0
  243. package/src/interactive/overlay-session-lifecycle.ts +18 -11
  244. package/src/interactive/session-transcript.ts +2 -1
  245. package/src/interactive/slash-commands.ts +20 -1
  246. package/src/interactive/turn-context.ts +685 -62
  247. package/src/interactive/turn-middleware.ts +39 -6
  248. package/src/interactive/turn-persistence.ts +15 -2
  249. package/src/interactive/turn-runtime.ts +48 -5
  250. package/src/tools/agent-tools.ts +3 -1
  251. package/src/tools/bootstrap.ts +6 -0
  252. package/src/tools/builtin-tool-catalog.ts +9 -0
  253. package/src/tools/context/index.ts +148 -113
  254. package/src/tools/context/surface.ts +11 -7
  255. package/src/tools/core-bootstrap.ts +4 -0
  256. package/src/tools/observation.ts +8 -2
  257. package/src/tools/policy.ts +3 -0
  258. package/src/tools/self-compact.ts +31 -0
  259. package/src/tools/surface.ts +1 -0
  260. package/src/tools/tasks.ts +1 -1
  261. package/dist/chunk-3OODBJ45.js +0 -1325
  262. package/dist/chunk-CTFPFW3H.js +0 -44
  263. package/dist/chunk-I4Y4WKZR.js +0 -386
@@ -2,20 +2,31 @@ import { createRequire as __clioCreateRequire } from "node:module"; const requir
2
2
  import {
3
3
  expandPromptTemplateInput,
4
4
  loadPromptTemplates
5
- } from "./chunk-UX2L5CUD.js";
5
+ } from "./chunk-AI36V3ON.js";
6
6
  import {
7
7
  expandSkillInvocationInput,
8
8
  loadSkills,
9
9
  parsePendingSkillRequests
10
- } from "./chunk-LAR7DX5E.js";
10
+ } from "./chunk-B5TASTCK.js";
11
11
  import {
12
12
  frontmatterRegion,
13
13
  normalizedSkillHash,
14
14
  stripProvenanceLines
15
15
  } from "./chunk-DNCE23JJ.js";
16
+ import {
17
+ lexicalMatches,
18
+ normalize
19
+ } from "./chunk-H7REJ7L5.js";
16
20
  import {
17
21
  expandConfigPath
18
22
  } from "./chunk-VNBICSS2.js";
23
+ import {
24
+ SKILL_INSTALL_OFFER_OPTION_NEVER,
25
+ SKILL_INSTALL_OFFER_OPTION_NOT_NOW,
26
+ SKILL_INSTALL_OFFER_OPTION_PROJECT,
27
+ SKILL_INSTALL_OFFER_OPTION_USER,
28
+ SKILL_SUGGESTION_ANCHOR
29
+ } from "./chunk-MMZMM6SW.js";
19
30
  import {
20
31
  require_dist
21
32
  } from "./chunk-B5GGDIHT.js";
@@ -130,6 +141,306 @@ var ResourcesManifest = {
130
141
  // src/domains/resources/prompts/substitute.ts
131
142
  init_esm_shims();
132
143
 
144
+ // src/domains/resources/skills/catalog-view.ts
145
+ init_esm_shims();
146
+ var LISTING_HEADER = "Available skills.";
147
+ var SESSION_NOTE = "These skills were explicitly supplied for this session. Preserve their source; session availability does not mean Clio installed or copied them.";
148
+ var INTEROP_NOTE = "Other-agent skill folders are discovery-only. Explicitly import into Clio before use; the trust-imports setting does not install or activate loose files.";
149
+ var MARKETPLACE_HEADER = "Marketplace (additional skills available to install; /skill <name> offers to install):";
150
+ var SESSION_HEADER = "Explicitly supplied session skills (not installed packages):";
151
+ var EMPTY_WITH_MARKETPLACE = "No skills are available in Clio and no additional marketplace skills were found.";
152
+ var EMPTY_WITHOUT_MARKETPLACE = "No skills are available in Clio.";
153
+ var DRIFT_MARKER = " [drifted]";
154
+ var MAX_LIMIT = 200;
155
+ var MAX_QUERY_ECHO = 48;
156
+ var MAX_NAME_ECHO = 64;
157
+ var MAX_DRIFT_NAMES = 6;
158
+ function byteLength(text) {
159
+ return Buffer.byteLength(text, "utf8");
160
+ }
161
+ function boundText(text, maxCodePoints) {
162
+ const points = [...text];
163
+ if (points.length <= maxCodePoints) return text;
164
+ return `${points.slice(0, maxCodePoints - 1).join("")}\u2026`;
165
+ }
166
+ function boundQuery(query) {
167
+ return boundText(query.replace(/\s+/g, " ").trim(), MAX_QUERY_ECHO);
168
+ }
169
+ function boundName(name) {
170
+ return boundText(name, MAX_NAME_ECHO);
171
+ }
172
+ function activationProtocolLine(modelActivation) {
173
+ return modelActivation ? `If one skill above matches the current task, load it now with context(scope="skills", name="<name>") and continue in the same turn; at this autonomy level you activate installed skills yourself and do not wait for the operator. Marketplace additions still require operator approval. If none match, do not mention skills.` : `If one skill above matches the current task, begin your reply with the line \`${SKILL_SUGGESTION_ANCHOR}\` (a comma-separated sequence, in order, when several compose), then continue the task in the same turn without it; only the operator can run it. If none match, do not mention skills.`;
174
+ }
175
+ function marketplaceOfferClause() {
176
+ return `When no installed skill serves the task but a marketplace skill above genuinely does, you may instead ask the operator with ask_user (mode=single_question, header "Install skill") whether to install it, offering exactly: "${SKILL_INSTALL_OFFER_OPTION_PROJECT}", "${SKILL_INSTALL_OFFER_OPTION_USER}", "${SKILL_INSTALL_OFFER_OPTION_NOT_NOW}", "${SKILL_INSTALL_OFFER_OPTION_NEVER}". The harness handles those exact offer options. An explicit operator request or approval also authorizes the documented library install CLI. After installation, refresh the inventory; distinguish installed from ready and report /library reload when required.`;
177
+ }
178
+ function driftNotice(names) {
179
+ if (names.length === 0) return "";
180
+ const shown = names.slice(0, MAX_DRIFT_NAMES).map(boundName);
181
+ const omitted = names.length - shown.length;
182
+ const list = omitted > 0 ? `${shown.join(", ")} and ${omitted} more` : shown.join(", ");
183
+ const subject = names.length === 1 ? `${list} no longer matches` : `${list} no longer match`;
184
+ return `Marked [drifted]: ${subject} the content hash recorded for it; the skill still loads unchanged, and /library shows the installed copy.`;
185
+ }
186
+ function readySkills(skills) {
187
+ return skills.filter((skill) => skill.source === "clio-coder" || skill.source === "plugin");
188
+ }
189
+ function sessionSkills(skills) {
190
+ return skills.filter((skill) => skill.source !== "clio-coder" && skill.source !== "plugin");
191
+ }
192
+ function haystackForSkill(skill) {
193
+ const triggers = skill.metadata.triggers;
194
+ const triggerText = Array.isArray(triggers) ? triggers.filter((entry) => typeof entry === "string").join(" ") : "";
195
+ return `${skill.name.replace(/-/g, " ")} ${skill.description} ${triggerText}`;
196
+ }
197
+ function haystackForMarketplace(entry) {
198
+ return `${entry.name.replace(/-/g, " ")} ${entry.description} ${entry.category ?? ""} ${(entry.triggers ?? []).join(" ")}`;
199
+ }
200
+ function haystackForPackage(record) {
201
+ return `${record.name.replace(/-/g, " ")} ${record.names.join(" ").replace(/-/g, " ")}`;
202
+ }
203
+ function buildRows(input) {
204
+ const drifted = input.drifted ?? /* @__PURE__ */ new Set();
205
+ const rows = [];
206
+ for (const skill of readySkills(input.skills)) {
207
+ const isDrifted = drifted.has(skill.name);
208
+ rows.push({
209
+ kind: "ready",
210
+ name: skill.name,
211
+ key: `ready:${skill.filePath}`,
212
+ drifted: isDrifted,
213
+ line: `- ${skill.name}${isDrifted ? DRIFT_MARKER : ""} (source: ${skill.source}; scope: ${skill.scope}): ${skill.description}`,
214
+ haystack: haystackForSkill(skill)
215
+ });
216
+ }
217
+ for (const skill of sessionSkills(input.skills)) {
218
+ rows.push({
219
+ kind: "session",
220
+ name: skill.name,
221
+ key: `session:${skill.filePath}`,
222
+ drifted: false,
223
+ line: `- ${skill.name} (source: ${skill.source}; scope: ${skill.scope}; file: ${skill.filePath}): ${skill.description}`,
224
+ haystack: haystackForSkill(skill)
225
+ });
226
+ }
227
+ for (const record of input.packages) {
228
+ rows.push({
229
+ kind: "package",
230
+ name: record.name,
231
+ key: `package:${record.scope}:${record.path}`,
232
+ drifted: false,
233
+ line: `- ${record.name} (scope: ${record.scope}; origin: ${record.origin === "catalog" ? "marketplace catalog" : record.origin}; state: ${record.state}; path: ${record.path})`,
234
+ haystack: haystackForPackage(record)
235
+ });
236
+ }
237
+ for (const entry of input.marketplace) {
238
+ const category = entry.category ? ` [${entry.category}]` : "";
239
+ rows.push({
240
+ kind: "marketplace",
241
+ name: entry.name,
242
+ key: `marketplace:${entry.sourceUrl}`,
243
+ drifted: false,
244
+ line: `- ${entry.name}${category}: ${entry.description}`,
245
+ haystack: haystackForMarketplace(entry)
246
+ });
247
+ }
248
+ return rows;
249
+ }
250
+ function selectRows(rows, query) {
251
+ const strict = rows.filter((row) => lexicalMatches(query, row.haystack, "all"));
252
+ if (strict.length > 0) return { rows: strict, mode: "all" };
253
+ return { rows: rows.filter((row) => lexicalMatches(query, row.haystack, "any")), mode: "any" };
254
+ }
255
+ function renderSections(rows, input, drift) {
256
+ const ready = rows.filter((row) => row.kind === "ready");
257
+ const session = rows.filter((row) => row.kind === "session");
258
+ const packages = rows.filter((row) => row.kind === "package");
259
+ const marketplace = rows.filter((row) => row.kind === "marketplace");
260
+ const lines = [LISTING_HEADER, ""];
261
+ lines.push(`Ready skills in Clio (${ready.length}):`);
262
+ if (ready.length === 0) lines.push("- none");
263
+ for (const row of ready) lines.push(row.line);
264
+ if (session.length > 0) {
265
+ lines.push("", SESSION_HEADER);
266
+ for (const row of session) lines.push(row.line);
267
+ lines.push(SESSION_NOTE);
268
+ }
269
+ if (packages.length > 0) {
270
+ lines.push("", `Installed packages providing skills (${packages.length}):`);
271
+ for (const row of packages) lines.push(row.line);
272
+ }
273
+ lines.push("", INTEROP_NOTE);
274
+ if (marketplace.length > 0) {
275
+ lines.push("", MARKETPLACE_HEADER);
276
+ for (const row of marketplace) lines.push(row.line);
277
+ }
278
+ if (drift.length > 0) lines.push("", drift);
279
+ lines.push("", activationProtocolLine(input.modelActivation));
280
+ if (marketplace.length > 0) lines.push(marketplaceOfferClause());
281
+ return lines.join("\n");
282
+ }
283
+ function clampLimit(limit, fallback) {
284
+ if (limit === void 0 || !Number.isFinite(limit)) return fallback;
285
+ return Math.max(1, Math.min(MAX_LIMIT, Math.floor(limit)));
286
+ }
287
+ function clampOffset(offset) {
288
+ if (offset === void 0 || !Number.isFinite(offset) || offset <= 0) return 0;
289
+ return Math.floor(offset);
290
+ }
291
+ function buildSkillCatalogView(input) {
292
+ const rawQuery = (input.query ?? "").trim();
293
+ const query = normalize(rawQuery).length > 0 ? rawQuery : "";
294
+ const emptyTerms = rawQuery.length > 0 && query.length === 0;
295
+ const filtered = query.length > 0;
296
+ const all = buildRows(input);
297
+ if (all.length === 0 && !filtered) {
298
+ return {
299
+ text: input.marketplaceOffered ? EMPTY_WITH_MARKETPLACE : EMPTY_WITHOUT_MARKETPLACE,
300
+ rows: [],
301
+ total: 0,
302
+ shown: 0,
303
+ nextOffset: void 0,
304
+ filtered: false,
305
+ matchMode: null,
306
+ budgetLimited: false,
307
+ driftedNames: []
308
+ };
309
+ }
310
+ const selected = filtered ? selectRows(all, query) : { rows: [...all], mode: null };
311
+ const matching = selected.rows;
312
+ const total = matching.length;
313
+ const offset = clampOffset(input.offset);
314
+ const limit = clampLimit(input.limit, total);
315
+ const window = matching.slice(offset, offset + limit);
316
+ const driftedNames = matching.filter((row) => row.drifted).map((row) => row.name);
317
+ const context = {
318
+ input,
319
+ drift: driftNotice(driftedNames),
320
+ filtered,
321
+ emptyTerms,
322
+ query,
323
+ matchMode: selected.mode,
324
+ total,
325
+ offset,
326
+ catalogTotal: all.length,
327
+ window
328
+ };
329
+ const whole = renderCandidate(context, window.length, false);
330
+ if (byteLength(whole) <= input.capBytes) {
331
+ return finishView(context, window, whole, false);
332
+ }
333
+ let low = 1;
334
+ let high = window.length - 1;
335
+ let best = -1;
336
+ let bestText = "";
337
+ while (low <= high) {
338
+ const mid = low + high >> 1;
339
+ const text = renderCandidate(context, mid, true);
340
+ if (byteLength(text) <= input.capBytes) {
341
+ best = mid;
342
+ bestText = text;
343
+ low = mid + 1;
344
+ } else {
345
+ high = mid - 1;
346
+ }
347
+ }
348
+ if (best >= 1) return finishView(context, window.slice(0, best), bestText, true);
349
+ const blocked = renderCandidate(context, 0, true);
350
+ if (byteLength(blocked) <= input.capBytes) {
351
+ return finishView(context, [], blocked, true);
352
+ }
353
+ return {
354
+ text: compactFallback(context),
355
+ rows: [],
356
+ total,
357
+ shown: 0,
358
+ nextOffset: void 0,
359
+ filtered,
360
+ matchMode: selected.mode,
361
+ budgetLimited: true,
362
+ driftedNames
363
+ };
364
+ }
365
+ function continuation(context, shown) {
366
+ const consumed = context.offset + shown;
367
+ if (consumed >= context.total) return { nextOffset: void 0, blocked: false };
368
+ if (shown === 0) return { nextOffset: context.offset + 1, blocked: true };
369
+ return { nextOffset: consumed, blocked: false };
370
+ }
371
+ function renderCandidate(context, shown, cut) {
372
+ const page = context.window.slice(0, shown);
373
+ const body = renderSections(page, context.input, context.drift);
374
+ const { nextOffset, blocked } = continuation(context, shown);
375
+ const note = pageNote({
376
+ filtered: context.filtered,
377
+ emptyTerms: context.emptyTerms,
378
+ query: context.query,
379
+ matchMode: context.matchMode,
380
+ total: context.total,
381
+ shown,
382
+ nextOffset,
383
+ budgetLimited: cut,
384
+ blockedRow: blocked ? context.window[0] ?? null : null,
385
+ catalogTotal: context.catalogTotal
386
+ });
387
+ return note.length > 0 ? `${body}
388
+ ${note}` : body;
389
+ }
390
+ function finishView(context, page, text, budgetLimited) {
391
+ const { nextOffset } = continuation(context, page.length);
392
+ return {
393
+ text,
394
+ rows: page.map((row) => ({ ...row })),
395
+ total: context.total,
396
+ shown: page.length,
397
+ nextOffset,
398
+ filtered: context.filtered,
399
+ matchMode: context.matchMode,
400
+ budgetLimited,
401
+ driftedNames: context.window.filter((row) => row.drifted).map((row) => row.name)
402
+ };
403
+ }
404
+ function compactFallback(context) {
405
+ const scope = context.filtered ? `${context.total} matching` : `${context.total}`;
406
+ return `Available skills: ${scope}. This call's budget cannot carry the listing; narrow it with context(scope="skills", query="<terms>") or raise the budget in a fresh turn.`;
407
+ }
408
+ function pageNote(input) {
409
+ const clauses = [];
410
+ if (input.emptyTerms) {
411
+ clauses.push("The query carried no searchable terms, so the full list is shown.");
412
+ }
413
+ if (input.filtered) {
414
+ const broadened = input.matchMode === "any" ? ", matched on any query word after no row matched them all" : "";
415
+ clauses.push(
416
+ input.total === 0 ? `No skill matches "${boundQuery(input.query)}"; ${input.catalogTotal} are available unfiltered, so drop query to list them.` : `Filtered by "${boundQuery(input.query)}"${broadened}: ${input.total} of ${input.catalogTotal} rows match.`
417
+ );
418
+ }
419
+ if (input.shown < input.total) {
420
+ clauses.push(
421
+ input.budgetLimited ? `Showing ${input.shown} of ${input.total} matching rows; the rest did not fit this call's budget.` : `Showing ${input.shown} of ${input.total} matching rows.`
422
+ );
423
+ }
424
+ if (input.blockedRow !== null) {
425
+ clauses.push(
426
+ `"${boundName(input.blockedRow.name)}" is too large to carry in this call's budget and was stepped over; open it directly with context(scope="skills", name="${boundName(input.blockedRow.name)}").`
427
+ );
428
+ }
429
+ if (input.nextOffset !== void 0) {
430
+ clauses.push(
431
+ input.filtered ? (
432
+ // Offsets index the FILTERED result set. A continuation that dropped
433
+ // the query would apply this cursor to the unfiltered catalog, which
434
+ // repeats rows and skips matches.
435
+ `Continue with the same query at offset=${input.nextOffset}; the offset indexes the filtered rows, so dropping query changes which rows it selects.`
436
+ ) : `Continue with context(scope="skills", offset=${input.nextOffset}) for the remainder.`
437
+ );
438
+ } else if (input.shown < input.total) {
439
+ clauses.push("The remainder cannot be carried this turn; narrow with query or continue in a follow-up turn.");
440
+ }
441
+ return clauses.join(" ");
442
+ }
443
+
133
444
  // src/domains/resources/skills/evals.ts
134
445
  init_esm_shims();
135
446
  var SCENARIO_HEADING = /^##\s+([A-Z])(\d+)\s*[-:–—]\s*(.+?)\s*$/;
@@ -590,26 +901,34 @@ function loadSkillPinManifest(manifestPath) {
590
901
  return entries;
591
902
  }
592
903
  function checkSkillDrift(skill, cwd) {
593
- const actual = skill.normalizedHash.toLowerCase();
904
+ return checkSkillDriftBatch([skill], cwd).get(skill.name) ?? null;
905
+ }
906
+ function checkSkillDriftBatch(skills, cwd) {
907
+ const reports = /* @__PURE__ */ new Map();
908
+ if (skills.length === 0) return reports;
594
909
  const manifestPath = resolveSkillPinManifestPath(cwd);
595
910
  const manifest = manifestPath === null ? null : loadSkillPinManifest(manifestPath);
596
- const pinned = manifest?.get(skill.name);
597
- if (pinned !== void 0) {
598
- return {
599
- verdict: pinned.sha256 === actual ? "match" : "mismatch",
600
- authority: "pinned-manifest",
601
- expected: pinned.sha256
602
- };
603
- }
604
- const recorded = skill.provenance?.installedHash?.trim().toLowerCase();
605
- if (recorded !== void 0 && /^[0-9a-f]{64}$/.test(recorded)) {
606
- return {
607
- verdict: recorded === actual ? "match" : "mismatch",
608
- authority: "install-record",
609
- expected: recorded
610
- };
911
+ for (const skill of skills) {
912
+ const actual = skill.normalizedHash.toLowerCase();
913
+ const pinned = manifest?.get(skill.name);
914
+ if (pinned !== void 0) {
915
+ reports.set(skill.name, {
916
+ verdict: pinned.sha256 === actual ? "match" : "mismatch",
917
+ authority: "pinned-manifest",
918
+ expected: pinned.sha256
919
+ });
920
+ continue;
921
+ }
922
+ const recorded = skill.provenance?.installedHash?.trim().toLowerCase();
923
+ if (recorded !== void 0 && /^[0-9a-f]{64}$/.test(recorded)) {
924
+ reports.set(skill.name, {
925
+ verdict: recorded === actual ? "match" : "mismatch",
926
+ authority: "install-record",
927
+ expected: recorded
928
+ });
929
+ }
611
930
  }
612
- return null;
931
+ return reports;
613
932
  }
614
933
 
615
934
  // src/domains/resources/index.ts
@@ -627,11 +946,13 @@ function createResourcesDomainModule(options = {}) {
627
946
  export {
628
947
  createResourcesLoader,
629
948
  ResourcesManifest,
949
+ buildSkillCatalogView,
630
950
  parseSkillEvals,
631
951
  parseSkillSourceSpec,
632
952
  updateSkills,
633
953
  checkSkillDrift,
954
+ checkSkillDriftBatch,
634
955
  ResourcesDomainModule,
635
956
  createResourcesDomainModule
636
957
  };
637
- //# sourceMappingURL=chunk-4WOOTKFD.js.map
958
+ //# sourceMappingURL=chunk-U3FETNQB.js.map
@@ -2,7 +2,7 @@ import { createRequire as __clioCreateRequire } from "node:module"; const requir
2
2
  import {
3
3
  gateDecisionsDirectory,
4
4
  verifyGateDecisionArtifact
5
- } from "./chunk-OV62D6KO.js";
5
+ } from "./chunk-KQMYL5GR.js";
6
6
  import {
7
7
  clioStateDir
8
8
  } from "./chunk-CTTI7G3T.js";
@@ -120,4 +120,4 @@ export {
120
120
  GATE_TOPOLOGY_MAX_SUBJECTS,
121
121
  gateTopology
122
122
  };
123
- //# sourceMappingURL=chunk-5B3RTYAK.js.map
123
+ //# sourceMappingURL=chunk-UGDSB4AN.js.map
@@ -4,10 +4,10 @@ import {
4
4
  isRouteDecisionAgentSelection,
5
5
  isRoutingIntent,
6
6
  parseWorkerContextProvenance
7
- } from "./chunk-T33IYTZM.js";
7
+ } from "./chunk-SAASVMIY.js";
8
8
  import {
9
9
  isExecutionRole
10
- } from "./chunk-BRCOSE7O.js";
10
+ } from "./chunk-SZUO5BSE.js";
11
11
  import {
12
12
  init_esm_shims
13
13
  } from "./chunk-ECBHH7LU.js";
@@ -983,4 +983,4 @@ export {
983
983
  adaptGroundedEvidenceValidationStatus,
984
984
  adaptFinishContractCompletionStatus
985
985
  };
986
- //# sourceMappingURL=chunk-VKHLUZNO.js.map
986
+ //# sourceMappingURL=chunk-UZ7YBL43.js.map
@@ -1,13 +1,13 @@
1
1
  import { createRequire as __clioCreateRequire } from "node:module"; const require = __clioCreateRequire(import.meta.url);
2
2
  import {
3
3
  inspectEvidence
4
- } from "./chunk-7FHSA7VB.js";
4
+ } from "./chunk-EQPFEDFV.js";
5
5
  import {
6
6
  trustVerdict
7
- } from "./chunk-OZ76TLGU.js";
7
+ } from "./chunk-EEITU7S6.js";
8
8
  import {
9
9
  TRUST_STATUS_AXES
10
- } from "./chunk-VKHLUZNO.js";
10
+ } from "./chunk-UZ7YBL43.js";
11
11
  import {
12
12
  clioDataDir
13
13
  } from "./chunk-CTTI7G3T.js";
@@ -43,4 +43,4 @@ export {
43
43
  EVIDENCE_DETAIL_MAX_RUNS,
44
44
  evidenceDetailSnapshot
45
45
  };
46
- //# sourceMappingURL=chunk-OXWRE2QJ.js.map
46
+ //# sourceMappingURL=chunk-VKMSEO7Y.js.map
@@ -19,7 +19,7 @@ import {
19
19
  } from "./chunk-TKDRT2DF.js";
20
20
  import {
21
21
  loadSkills
22
- } from "./chunk-LAR7DX5E.js";
22
+ } from "./chunk-B5TASTCK.js";
23
23
  import {
24
24
  credentialsPresent
25
25
  } from "./chunk-DVTBERFY.js";
@@ -30,10 +30,10 @@ import {
30
30
  } from "./chunk-Z4GLJ6J4.js";
31
31
  import {
32
32
  isSessionEntry
33
- } from "./chunk-I4Y4WKZR.js";
33
+ } from "./chunk-F6KCJO3U.js";
34
34
  import {
35
35
  readSessionFileEntries
36
- } from "./chunk-EKV4UBCM.js";
36
+ } from "./chunk-PZBQUJ2F.js";
37
37
  import {
38
38
  interopAgentKind
39
39
  } from "./chunk-5EQO5NWP.js";
@@ -360,7 +360,7 @@ async function runDoctorFleetChecks(projectRoot = process.cwd(), options = {}) {
360
360
  }
361
361
  const nodes = settings.fleet?.nodes ?? [];
362
362
  if (nodes.length === 0) return [];
363
- const { recordFleetPreflight, runFleetNodePreflight } = await import("./fleet-preflight-KSIHWQAU.js");
363
+ const { recordFleetPreflight, runFleetNodePreflight } = await import("./fleet-preflight-44UNCC4Y.js");
364
364
  const targets = (settings.targets ?? []).map((target) => ({
365
365
  id: target.id,
366
366
  runtimeId: target.runtime,
@@ -579,4 +579,4 @@ export {
579
579
  runDoctorRuntimeChecks,
580
580
  runDoctorModelChecks
581
581
  };
582
- //# sourceMappingURL=chunk-FBXTHPNZ.js.map
582
+ //# sourceMappingURL=chunk-VLX5VZ35.js.map
@@ -7,20 +7,20 @@ import {
7
7
  import {
8
8
  openLedger,
9
9
  readFleetRun
10
- } from "./chunk-7FHSA7VB.js";
10
+ } from "./chunk-EQPFEDFV.js";
11
11
  import {
12
12
  WRITE_BOUNDARY_VIOLATION_REASON
13
- } from "./chunk-DXSETN72.js";
13
+ } from "./chunk-7WUGNN43.js";
14
14
  import {
15
15
  formatTrustSummaryLine
16
- } from "./chunk-OZ76TLGU.js";
16
+ } from "./chunk-EEITU7S6.js";
17
17
  import {
18
18
  readRunEventJournal,
19
19
  runEventJournalPath
20
20
  } from "./chunk-UQIVHSE4.js";
21
21
  import {
22
22
  inspectRunReceiptTrustStatus
23
- } from "./chunk-VKHLUZNO.js";
23
+ } from "./chunk-UZ7YBL43.js";
24
24
  import {
25
25
  sanitizeCallTargetText
26
26
  } from "./chunk-XNIZBOFV.js";
@@ -572,4 +572,4 @@ export {
572
572
  loadFleetRunViewModel,
573
573
  runFleetView
574
574
  };
575
- //# sourceMappingURL=chunk-KIAUZGKF.js.map
575
+ //# sourceMappingURL=chunk-WAGBMMNX.js.map
@@ -1,7 +1,7 @@
1
1
  import { createRequire as __clioCreateRequire } from "node:module"; const require = __clioCreateRequire(import.meta.url);
2
2
  import {
3
3
  estimateInputTokensFromContext
4
- } from "./chunk-EYTLV3W3.js";
4
+ } from "./chunk-HTWTORF7.js";
5
5
  import {
6
6
  normalizeContext,
7
7
  streamSimple
@@ -175,4 +175,4 @@ export {
175
175
  runPrewarmRound,
176
176
  recordStartupDiagnostic
177
177
  };
178
- //# sourceMappingURL=chunk-BFOSV5EZ.js.map
178
+ //# sourceMappingURL=chunk-WX2YCH7F.js.map
@@ -18,10 +18,10 @@ import {
18
18
  import {
19
19
  acceptanceFromTaskFlags,
20
20
  formatUserTaskHandoff
21
- } from "./chunk-ISHUS7HC.js";
21
+ } from "./chunk-JRW236JT.js";
22
22
  import {
23
23
  createWorkerProgressFold
24
- } from "./chunk-HOEDA42N.js";
24
+ } from "./chunk-T7HZ7KJF.js";
25
25
  import {
26
26
  SETTINGS_SECTIONS,
27
27
  resolveSettingsSection
@@ -31,31 +31,31 @@ import {
31
31
  WORKER_OUTPUT_MAX_BYTES,
32
32
  activeDecisionRefs,
33
33
  decisionRationale
34
- } from "./chunk-U5QU5ZOD.js";
34
+ } from "./chunk-XYPWFSU5.js";
35
35
  import {
36
36
  SKILL_SURFACE_CLEAR_ARG,
37
37
  parseSkillCommand
38
- } from "./chunk-LAR7DX5E.js";
38
+ } from "./chunk-B5TASTCK.js";
39
39
  import {
40
40
  isLibraryKind
41
41
  } from "./chunk-NVPXXW2H.js";
42
42
  import {
43
43
  TOOL_PROFILE_NAMES,
44
44
  isToolProfileName
45
- } from "./chunk-XZWSP67B.js";
45
+ } from "./chunk-5APYAXCB.js";
46
46
  import {
47
47
  requestExecutionRole
48
- } from "./chunk-BRCOSE7O.js";
48
+ } from "./chunk-SZUO5BSE.js";
49
49
  import {
50
50
  truncateUtf8
51
51
  } from "./chunk-MYI32N4R.js";
52
52
  import {
53
53
  resolveModelReference
54
- } from "./chunk-EYTLV3W3.js";
54
+ } from "./chunk-HTWTORF7.js";
55
55
  import {
56
56
  parseCouncilReport,
57
57
  parseOracleResult
58
- } from "./chunk-LNOXCGN2.js";
58
+ } from "./chunk-7UFDIOBT.js";
59
59
  import {
60
60
  THINKING_LEVELS
61
61
  } from "./chunk-QZTTRSJE.js";
@@ -1890,9 +1890,10 @@ ${usage}` : usage);
1890
1890
  name: "context",
1891
1891
  description: "Context hub: window overlay plus compact, recall, init, refresh, and reset",
1892
1892
  group: "Inspect",
1893
- kinds: ["context-view", "compact", "context-recall", "init", "context-clear", "context-refresh"],
1893
+ kinds: ["context-view", "compact", "context-recover", "context-recall", "init", "context-clear", "context-refresh"],
1894
1894
  subcommandDescriptions: {
1895
1895
  compact: "Compact session context",
1896
+ recover: "Recover a paused handoff: ID reduce|deliver",
1896
1897
  recall: "Recall an evicted result",
1897
1898
  init: "Initialize project context",
1898
1899
  refresh: "Refresh project context",
@@ -1901,6 +1902,12 @@ ${usage}` : usage);
1901
1902
  args: {
1902
1903
  subcommands: {
1903
1904
  compact: { positionals: [...COMPACT_POSITIONALS] },
1905
+ recover: {
1906
+ positionals: [
1907
+ { name: "handoffId", required: true },
1908
+ { name: "action", required: true }
1909
+ ]
1910
+ },
1904
1911
  recall: { positionals: [...RECALL_POSITIONALS] },
1905
1912
  init: {
1906
1913
  flags: CONTEXT_INIT_FLAG_TABLE.flatMap(({ flag, aliases = [] }) => [flag, ...aliases].map((name) => ({ name })))
@@ -1914,6 +1921,10 @@ ${usage}` : usage);
1914
1921
  switch (parsed.subcommand) {
1915
1922
  case "compact":
1916
1923
  return { kind: "compact", instructions: parsed.rest };
1924
+ case "recover": {
1925
+ const [handoffId, action] = parsed.positionals;
1926
+ return handoffId && (action === "reduce" || action === "deliver") ? { kind: "context-recover", handoffId, action } : { kind: "usage-error", command: "context", reason: "Use /context recover <handoffId> <reduce|deliver>" };
1927
+ }
1917
1928
  case "recall":
1918
1929
  return { kind: "context-recall", ref: parsed.positionals[0] ?? "" };
1919
1930
  case "init": {
@@ -1940,6 +1951,10 @@ ${usage}` : usage);
1940
1951
  case "compact":
1941
1952
  ctx.runCompact(command.instructions);
1942
1953
  return;
1954
+ case "context-recover":
1955
+ if (ctx.runHandoffRecovery) ctx.runHandoffRecovery(command.handoffId, command.action);
1956
+ else ctx.notice("error", "native handoff recovery is unavailable");
1957
+ return;
1943
1958
  case "context-recall":
1944
1959
  if (ctx.runContextRecall) {
1945
1960
  ctx.runContextRecall(command.ref);
@@ -2793,4 +2808,4 @@ export {
2793
2808
  dispatchSlashCommand,
2794
2809
  commandReference
2795
2810
  };
2796
- //# sourceMappingURL=chunk-SAL2SBP4.js.map
2811
+ //# sourceMappingURL=chunk-XBIGUILU.js.map