@oscharko-dev/keiko 1.0.4 → 1.1.0

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 (929) hide show
  1. package/README.md +11 -1
  2. package/dist/ui/csp-hashes.json +6 -6
  3. package/dist/ui/static/404.html +1 -1
  4. package/dist/ui/static/__next.__PAGE__.txt +16 -14
  5. package/dist/ui/static/__next._full.txt +21 -20
  6. package/dist/ui/static/__next._tree.txt +2 -2
  7. package/dist/ui/static/_next/static/chunks/000t9p2ysi3dv.css +1 -0
  8. package/dist/ui/static/_next/static/chunks/01_gc9m97_vw5.js +1 -0
  9. package/dist/ui/static/_next/static/chunks/02p2_qr2a9511.js +1 -0
  10. package/dist/ui/static/_next/static/chunks/02ug3u_si269z.js +1 -0
  11. package/dist/ui/static/_next/static/chunks/03deeo56ud39g.js +1 -0
  12. package/dist/ui/static/_next/static/chunks/0_8kv51rrhcg-.js +1 -0
  13. package/dist/ui/static/_next/static/chunks/0ahpt93l7-z9f.js +1 -0
  14. package/dist/ui/static/_next/static/chunks/0bbv42deftomm.js +1 -0
  15. package/dist/ui/static/_next/static/chunks/0c3w2ubla6ek6.js +1 -0
  16. package/dist/ui/static/_next/static/chunks/0e6em7dg4gr6q.js +1 -0
  17. package/dist/ui/static/_next/static/chunks/0gnizm29lk3ll.js +1 -0
  18. package/dist/ui/static/_next/static/chunks/0m0w3hleoejwg.js +1 -0
  19. package/dist/ui/static/_next/static/chunks/{2nubqp1hwandv.js → 0ojvvjnsf38bk.js} +1 -1
  20. package/dist/ui/static/_next/static/chunks/0we68cbpsgepq.css +1 -0
  21. package/dist/ui/static/_next/static/chunks/0xqxs7rppw_o5.css +5 -0
  22. package/dist/ui/static/_next/static/chunks/0z5be09yla9lp.js +1 -0
  23. package/dist/ui/static/_next/static/chunks/14aztwc0_78th.js +1 -0
  24. package/dist/ui/static/_next/static/chunks/18-rkk8vbltb8.js +1 -0
  25. package/dist/ui/static/_next/static/chunks/187yy--dlljjz.js +1 -0
  26. package/dist/ui/static/_next/static/chunks/1ep9f2fjv7oh7.js +1 -0
  27. package/dist/ui/static/_next/static/chunks/1hk335vrug1rc.js +1 -0
  28. package/dist/ui/static/_next/static/chunks/1kacubgk0y2ki.js +1 -0
  29. package/dist/ui/static/_next/static/chunks/1kxhf3ld28pzk.js +1 -0
  30. package/dist/ui/static/_next/static/chunks/1lb8ju8qa0d9m.js +1 -0
  31. package/dist/ui/static/_next/static/chunks/1lrj3d157kay1.js +5 -0
  32. package/dist/ui/static/_next/static/chunks/1mcajwmbse068.js +7 -0
  33. package/dist/ui/static/_next/static/chunks/{2l9r80s3qje3v.js → 1piodmepoegnw.js} +1 -1
  34. package/dist/ui/static/_next/static/chunks/1qsl7dx87n-af.js +1 -0
  35. package/dist/ui/static/_next/static/chunks/{0vywz1p6au4ri.js → 1uetvnnpa5z22.js} +1 -1
  36. package/dist/ui/static/_next/static/chunks/1uulmf99vtuyt.js +1 -0
  37. package/dist/ui/static/_next/static/chunks/202kx3p8axlmr.js +1 -0
  38. package/dist/ui/static/_next/static/chunks/{0hn7lj400e79p.js → 2179tism08tgt.js} +1 -1
  39. package/dist/ui/static/_next/static/chunks/21t1klb1thn76.js +1 -0
  40. package/dist/ui/static/_next/static/chunks/29nzymeooaepv.js +1 -0
  41. package/dist/ui/static/_next/static/chunks/2_o61-akoq549.js +1 -0
  42. package/dist/ui/static/_next/static/chunks/{064diuwddstj6.js → 2cn33khz2ae-h.js} +1 -1
  43. package/dist/ui/static/_next/static/chunks/{0b3klia_y6i3z.js → 2dbr8ufwv1hwn.js} +1 -1
  44. package/dist/ui/static/_next/static/chunks/2dpxapmdvqlh1.js +1 -0
  45. package/dist/ui/static/_next/static/chunks/2e4prtd3wmn0a.js +1 -0
  46. package/dist/ui/static/_next/static/chunks/2h_zvmb272ozs.js +1 -0
  47. package/dist/ui/static/_next/static/chunks/{3qtph5seqciux.css → 2l0gyhe4jpu23.css} +5 -5
  48. package/dist/ui/static/_next/static/chunks/2l9ens2l3tayx.js +1 -0
  49. package/dist/ui/static/_next/static/chunks/2oxvgl3qb19wf.js +1 -0
  50. package/dist/ui/static/_next/static/chunks/2s9-91g2jic6u.js +1 -0
  51. package/dist/ui/static/_next/static/chunks/2uoxlx30y60nf.js +1 -0
  52. package/dist/ui/static/_next/static/chunks/2vhgpp_064_st.js +1 -0
  53. package/dist/ui/static/_next/static/chunks/2xpud5k1hwfvf.js +1 -0
  54. package/dist/ui/static/_next/static/chunks/2ywqac8g8us1n.css +1 -0
  55. package/dist/ui/static/_next/static/chunks/3-htoy7v6gx51.js +1 -0
  56. package/dist/ui/static/_next/static/chunks/3-l-8qt163_y6.js +1 -0
  57. package/dist/ui/static/_next/static/chunks/3_rof9w-g14_v.js +3 -0
  58. package/dist/ui/static/_next/static/chunks/3aqtjd-a1ygis.js +1 -0
  59. package/dist/ui/static/_next/static/chunks/3d-10944zk2o9.js +1 -0
  60. package/dist/ui/static/_next/static/chunks/3f6svr_pokw6j.js +1 -0
  61. package/dist/ui/static/_next/static/chunks/3ibevys2o09xx.js +1 -0
  62. package/dist/ui/static/_next/static/chunks/3iv5llh4xg-7v.js +1 -0
  63. package/dist/ui/static/_next/static/chunks/3ly6-f_52vfie.js +1 -0
  64. package/dist/ui/static/_next/static/chunks/3pm8eiwwesd47.js +1 -0
  65. package/dist/ui/static/_next/static/chunks/3tr04kks52pjw.js +1 -0
  66. package/dist/ui/static/_next/static/chunks/3wwyidrm300kk.js +1 -0
  67. package/dist/ui/static/_next/static/chunks/3xw9gh9d5ngza.js +1 -0
  68. package/dist/ui/static/_next/static/chunks/3zbk4r-6rxn7j.css +2 -0
  69. package/dist/ui/static/_next/static/chunks/42y02tbxkub8f.js +1 -0
  70. package/dist/ui/static/_not-found/__next._full.txt +20 -18
  71. package/dist/ui/static/_not-found/__next._not-found.__PAGE__.txt +13 -11
  72. package/dist/ui/static/_not-found/__next._tree.txt +1 -1
  73. package/dist/ui/static/_not-found.html +1 -1
  74. package/dist/ui/static/_not-found.txt +20 -18
  75. package/dist/ui/static/atlassian-connectors/__next._full.txt +22 -20
  76. package/dist/ui/static/atlassian-connectors/__next._tree.txt +1 -1
  77. package/dist/ui/static/atlassian-connectors/__next.atlassian-connectors.__PAGE__.txt +15 -13
  78. package/dist/ui/static/atlassian-connectors.html +1 -1
  79. package/dist/ui/static/atlassian-connectors.txt +22 -20
  80. package/dist/ui/static/index.html +1 -1
  81. package/dist/ui/static/index.txt +21 -20
  82. package/dist/ui/static/launch/__next._full.txt +25 -23
  83. package/dist/ui/static/launch/__next._tree.txt +2 -2
  84. package/dist/ui/static/launch/__next.launch.__PAGE__.txt +16 -14
  85. package/dist/ui/static/launch.html +1 -1
  86. package/dist/ui/static/launch.txt +25 -23
  87. package/dist/ui/static/local-knowledge/__next._full.txt +25 -23
  88. package/dist/ui/static/local-knowledge/__next._tree.txt +2 -2
  89. package/dist/ui/static/local-knowledge/__next.local-knowledge.__PAGE__.txt +16 -14
  90. package/dist/ui/static/local-knowledge/capsule/__next._full.txt +23 -21
  91. package/dist/ui/static/local-knowledge/capsule/__next._tree.txt +1 -1
  92. package/dist/ui/static/local-knowledge/capsule/__next.local-knowledge.capsule.__PAGE__.txt +15 -13
  93. package/dist/ui/static/local-knowledge/capsule.html +1 -1
  94. package/dist/ui/static/local-knowledge/capsule.txt +23 -21
  95. package/dist/ui/static/local-knowledge.html +1 -1
  96. package/dist/ui/static/local-knowledge.txt +25 -23
  97. package/node_modules/@oscharko-dev/keiko-cli/dist/activity-log-line-reader.d.ts +30 -0
  98. package/node_modules/@oscharko-dev/keiko-cli/dist/activity-log-line-reader.d.ts.map +1 -0
  99. package/node_modules/@oscharko-dev/keiko-cli/dist/activity-log-line-reader.js +114 -0
  100. package/node_modules/@oscharko-dev/keiko-cli/dist/audit.d.ts.map +1 -1
  101. package/node_modules/@oscharko-dev/keiko-cli/dist/audit.js +108 -39
  102. package/node_modules/@oscharko-dev/keiko-cli/dist/cli-activity-log.d.ts +3 -0
  103. package/node_modules/@oscharko-dev/keiko-cli/dist/cli-activity-log.d.ts.map +1 -0
  104. package/node_modules/@oscharko-dev/keiko-cli/dist/cli-activity-log.js +14 -0
  105. package/node_modules/@oscharko-dev/keiko-cli/dist/cli-control-state.d.ts +1 -1
  106. package/node_modules/@oscharko-dev/keiko-cli/dist/cli-control-state.d.ts.map +1 -1
  107. package/node_modules/@oscharko-dev/keiko-cli/dist/cli-control-state.js +7 -4
  108. package/node_modules/@oscharko-dev/keiko-cli/dist/cli-model-resolution.d.ts.map +1 -1
  109. package/node_modules/@oscharko-dev/keiko-cli/dist/cli-model-resolution.js +3 -1
  110. package/node_modules/@oscharko-dev/keiko-cli/dist/evaluate.d.ts.map +1 -1
  111. package/node_modules/@oscharko-dev/keiko-cli/dist/evaluate.js +4 -2
  112. package/node_modules/@oscharko-dev/keiko-cli/dist/install-layout.d.ts +60 -7
  113. package/node_modules/@oscharko-dev/keiko-cli/dist/install-layout.d.ts.map +1 -1
  114. package/node_modules/@oscharko-dev/keiko-cli/dist/install-layout.js +32 -10
  115. package/node_modules/@oscharko-dev/keiko-cli/dist/launcher-state.js +1 -1
  116. package/node_modules/@oscharko-dev/keiko-cli/dist/lifecycle.d.ts.map +1 -1
  117. package/node_modules/@oscharko-dev/keiko-cli/dist/lifecycle.js +82 -103
  118. package/node_modules/@oscharko-dev/keiko-cli/dist/memory.d.ts.map +1 -1
  119. package/node_modules/@oscharko-dev/keiko-cli/dist/memory.js +14 -7
  120. package/node_modules/@oscharko-dev/keiko-cli/dist/portable-launch-notifier.d.ts.map +1 -1
  121. package/node_modules/@oscharko-dev/keiko-cli/dist/portable-launch-notifier.js +30 -7
  122. package/node_modules/@oscharko-dev/keiko-cli/dist/process-activity-log.d.ts +197 -0
  123. package/node_modules/@oscharko-dev/keiko-cli/dist/process-activity-log.d.ts.map +1 -0
  124. package/node_modules/@oscharko-dev/keiko-cli/dist/process-activity-log.js +147 -0
  125. package/node_modules/@oscharko-dev/keiko-cli/dist/process-guards.d.ts +3 -2
  126. package/node_modules/@oscharko-dev/keiko-cli/dist/process-guards.d.ts.map +1 -1
  127. package/node_modules/@oscharko-dev/keiko-cli/dist/process-guards.js +49 -36
  128. package/node_modules/@oscharko-dev/keiko-cli/dist/prompt-enhancer.d.ts.map +1 -1
  129. package/node_modules/@oscharko-dev/keiko-cli/dist/prompt-enhancer.js +9 -7
  130. package/node_modules/@oscharko-dev/keiko-cli/dist/repair.d.ts.map +1 -1
  131. package/node_modules/@oscharko-dev/keiko-cli/dist/repair.js +8 -3
  132. package/node_modules/@oscharko-dev/keiko-cli/dist/run.d.ts.map +1 -1
  133. package/node_modules/@oscharko-dev/keiko-cli/dist/run.js +3 -1
  134. package/node_modules/@oscharko-dev/keiko-cli/dist/runner.d.ts.map +1 -1
  135. package/node_modules/@oscharko-dev/keiko-cli/dist/runner.js +58 -18
  136. package/node_modules/@oscharko-dev/keiko-cli/dist/security-log.d.ts.map +1 -1
  137. package/node_modules/@oscharko-dev/keiko-cli/dist/security-log.js +126 -57
  138. package/node_modules/@oscharko-dev/keiko-cli/dist/state-paths.d.ts +1 -1
  139. package/node_modules/@oscharko-dev/keiko-cli/dist/state-paths.d.ts.map +1 -1
  140. package/node_modules/@oscharko-dev/keiko-cli/dist/state-paths.js +29 -6
  141. package/node_modules/@oscharko-dev/keiko-cli/dist/support-analyze-sufficiency.d.ts +52 -0
  142. package/node_modules/@oscharko-dev/keiko-cli/dist/support-analyze-sufficiency.d.ts.map +1 -0
  143. package/node_modules/@oscharko-dev/keiko-cli/dist/support-analyze-sufficiency.js +249 -0
  144. package/node_modules/@oscharko-dev/keiko-cli/dist/support-analyze.d.ts +85 -0
  145. package/node_modules/@oscharko-dev/keiko-cli/dist/support-analyze.d.ts.map +1 -1
  146. package/node_modules/@oscharko-dev/keiko-cli/dist/support-analyze.js +498 -56
  147. package/node_modules/@oscharko-dev/keiko-cli/dist/support-export.d.ts +12 -8
  148. package/node_modules/@oscharko-dev/keiko-cli/dist/support-export.d.ts.map +1 -1
  149. package/node_modules/@oscharko-dev/keiko-cli/dist/support-export.js +147 -99
  150. package/node_modules/@oscharko-dev/keiko-cli/dist/support-incident.d.ts +50 -0
  151. package/node_modules/@oscharko-dev/keiko-cli/dist/support-incident.d.ts.map +1 -0
  152. package/node_modules/@oscharko-dev/keiko-cli/dist/support-incident.js +317 -0
  153. package/node_modules/@oscharko-dev/keiko-cli/dist/support-query-cli.d.ts +80 -0
  154. package/node_modules/@oscharko-dev/keiko-cli/dist/support-query-cli.d.ts.map +1 -0
  155. package/node_modules/@oscharko-dev/keiko-cli/dist/support-query-cli.js +462 -0
  156. package/node_modules/@oscharko-dev/keiko-cli/dist/support-query-evidence.d.ts +480 -0
  157. package/node_modules/@oscharko-dev/keiko-cli/dist/support-query-evidence.d.ts.map +1 -0
  158. package/node_modules/@oscharko-dev/keiko-cli/dist/support-query-evidence.js +191 -0
  159. package/node_modules/@oscharko-dev/keiko-cli/dist/support-query.d.ts +169 -0
  160. package/node_modules/@oscharko-dev/keiko-cli/dist/support-query.d.ts.map +1 -0
  161. package/node_modules/@oscharko-dev/keiko-cli/dist/support-query.js +709 -0
  162. package/node_modules/@oscharko-dev/keiko-cli/dist/support-segment-manifest-names.d.ts +6 -0
  163. package/node_modules/@oscharko-dev/keiko-cli/dist/support-segment-manifest-names.d.ts.map +1 -0
  164. package/node_modules/@oscharko-dev/keiko-cli/dist/support-segment-manifest-names.js +27 -0
  165. package/node_modules/@oscharko-dev/keiko-cli/dist/support-segment-manifest.d.ts +164 -0
  166. package/node_modules/@oscharko-dev/keiko-cli/dist/support-segment-manifest.d.ts.map +1 -0
  167. package/node_modules/@oscharko-dev/keiko-cli/dist/support-segment-manifest.js +688 -0
  168. package/node_modules/@oscharko-dev/keiko-cli/dist/support-segment-scan.d.ts +78 -0
  169. package/node_modules/@oscharko-dev/keiko-cli/dist/support-segment-scan.d.ts.map +1 -0
  170. package/node_modules/@oscharko-dev/keiko-cli/dist/support-segment-scan.js +252 -0
  171. package/node_modules/@oscharko-dev/keiko-cli/dist/support-selective-export.d.ts +43 -0
  172. package/node_modules/@oscharko-dev/keiko-cli/dist/support-selective-export.d.ts.map +1 -0
  173. package/node_modules/@oscharko-dev/keiko-cli/dist/support-selective-export.js +115 -0
  174. package/node_modules/@oscharko-dev/keiko-cli/dist/support-tool-catalog.d.ts.map +1 -1
  175. package/node_modules/@oscharko-dev/keiko-cli/dist/support-tool-catalog.js +118 -4
  176. package/node_modules/@oscharko-dev/keiko-cli/dist/support.d.ts +21 -2
  177. package/node_modules/@oscharko-dev/keiko-cli/dist/support.d.ts.map +1 -1
  178. package/node_modules/@oscharko-dev/keiko-cli/dist/support.js +885 -177
  179. package/node_modules/@oscharko-dev/keiko-cli/dist/ui-process-stop.d.ts.map +1 -1
  180. package/node_modules/@oscharko-dev/keiko-cli/dist/ui-process-stop.js +95 -24
  181. package/node_modules/@oscharko-dev/keiko-cli/dist/ui.d.ts +13 -4
  182. package/node_modules/@oscharko-dev/keiko-cli/dist/ui.d.ts.map +1 -1
  183. package/node_modules/@oscharko-dev/keiko-cli/dist/ui.js +364 -109
  184. package/node_modules/@oscharko-dev/keiko-cli/dist/uninstall.d.ts.map +1 -1
  185. package/node_modules/@oscharko-dev/keiko-cli/dist/uninstall.js +123 -51
  186. package/node_modules/@oscharko-dev/keiko-cli/package.json +14 -14
  187. package/node_modules/@oscharko-dev/keiko-connectors/dist/version.d.ts +1 -1
  188. package/node_modules/@oscharko-dev/keiko-connectors/dist/version.js +1 -1
  189. package/node_modules/@oscharko-dev/keiko-connectors/package.json +3 -3
  190. package/node_modules/@oscharko-dev/keiko-contracts/dist/activity-log-failure-class-contracts.d.ts +6322 -0
  191. package/node_modules/@oscharko-dev/keiko-contracts/dist/activity-log-failure-class-contracts.d.ts.map +1 -0
  192. package/node_modules/@oscharko-dev/keiko-contracts/dist/activity-log-failure-class-contracts.js +8278 -0
  193. package/node_modules/@oscharko-dev/keiko-contracts/dist/activity-log-files.d.ts +54 -0
  194. package/node_modules/@oscharko-dev/keiko-contracts/dist/activity-log-files.d.ts.map +1 -0
  195. package/node_modules/@oscharko-dev/keiko-contracts/dist/activity-log-files.js +215 -0
  196. package/node_modules/@oscharko-dev/keiko-contracts/dist/activity-log-loss.d.ts +16 -0
  197. package/node_modules/@oscharko-dev/keiko-contracts/dist/activity-log-loss.d.ts.map +1 -0
  198. package/node_modules/@oscharko-dev/keiko-contracts/dist/activity-log-loss.js +82 -0
  199. package/node_modules/@oscharko-dev/keiko-contracts/dist/activity-log-registry.generated.d.ts +50926 -0
  200. package/node_modules/@oscharko-dev/keiko-contracts/dist/activity-log-registry.generated.d.ts.map +1 -0
  201. package/node_modules/@oscharko-dev/keiko-contracts/dist/activity-log-registry.generated.js +60264 -0
  202. package/node_modules/@oscharko-dev/keiko-contracts/dist/bff-wire.d.ts +19 -0
  203. package/node_modules/@oscharko-dev/keiko-contracts/dist/bff-wire.d.ts.map +1 -1
  204. package/node_modules/@oscharko-dev/keiko-contracts/dist/code-task-acceptance.d.ts +2 -2
  205. package/node_modules/@oscharko-dev/keiko-contracts/dist/code-task-acceptance.d.ts.map +1 -1
  206. package/node_modules/@oscharko-dev/keiko-contracts/dist/code-task-acceptance.js +1 -2
  207. package/node_modules/@oscharko-dev/keiko-contracts/dist/coding-workbench-runtime-api.d.ts +5 -0
  208. package/node_modules/@oscharko-dev/keiko-contracts/dist/coding-workbench-runtime-api.d.ts.map +1 -1
  209. package/node_modules/@oscharko-dev/keiko-contracts/dist/coding-workbench-runtime-api.js +15 -0
  210. package/node_modules/@oscharko-dev/keiko-contracts/dist/diagnostics.d.ts +145 -1
  211. package/node_modules/@oscharko-dev/keiko-contracts/dist/diagnostics.d.ts.map +1 -1
  212. package/node_modules/@oscharko-dev/keiko-contracts/dist/diagnostics.js +532 -6
  213. package/node_modules/@oscharko-dev/keiko-contracts/dist/gateway.d.ts +1 -1
  214. package/node_modules/@oscharko-dev/keiko-contracts/dist/gateway.d.ts.map +1 -1
  215. package/node_modules/@oscharko-dev/keiko-contracts/dist/gateway.js +1 -0
  216. package/node_modules/@oscharko-dev/keiko-contracts/dist/governed-tool-catalog.d.ts +1 -1
  217. package/node_modules/@oscharko-dev/keiko-contracts/dist/governed-tool-catalog.d.ts.map +1 -1
  218. package/node_modules/@oscharko-dev/keiko-contracts/dist/index.d.ts +1 -1
  219. package/node_modules/@oscharko-dev/keiko-contracts/dist/index.d.ts.map +1 -1
  220. package/node_modules/@oscharko-dev/keiko-contracts/dist/observability.d.ts +235 -0
  221. package/node_modules/@oscharko-dev/keiko-contracts/dist/observability.d.ts.map +1 -1
  222. package/node_modules/@oscharko-dev/keiko-contracts/dist/observability.js +743 -0
  223. package/node_modules/@oscharko-dev/keiko-contracts/dist/support-incident.d.ts +216 -0
  224. package/node_modules/@oscharko-dev/keiko-contracts/dist/support-incident.d.ts.map +1 -0
  225. package/node_modules/@oscharko-dev/keiko-contracts/dist/support-incident.js +403 -0
  226. package/node_modules/@oscharko-dev/keiko-contracts/dist/verification.d.ts +3 -0
  227. package/node_modules/@oscharko-dev/keiko-contracts/dist/verification.d.ts.map +1 -1
  228. package/node_modules/@oscharko-dev/keiko-contracts/dist/verification.js +18 -1
  229. package/node_modules/@oscharko-dev/keiko-contracts/dist/version.d.ts +2 -2
  230. package/node_modules/@oscharko-dev/keiko-contracts/dist/version.js +2 -2
  231. package/node_modules/@oscharko-dev/keiko-contracts/package.json +1 -1
  232. package/node_modules/@oscharko-dev/keiko-evaluations/dist/model-provider.d.ts +2 -1
  233. package/node_modules/@oscharko-dev/keiko-evaluations/dist/model-provider.d.ts.map +1 -1
  234. package/node_modules/@oscharko-dev/keiko-evaluations/dist/model-provider.js +1 -1
  235. package/node_modules/@oscharko-dev/keiko-evaluations/dist/runner.d.ts +2 -1
  236. package/node_modules/@oscharko-dev/keiko-evaluations/dist/runner.d.ts.map +1 -1
  237. package/node_modules/@oscharko-dev/keiko-evaluations/dist/runner.js +2 -1
  238. package/node_modules/@oscharko-dev/keiko-evaluations/package.json +9 -9
  239. package/node_modules/@oscharko-dev/keiko-evidence/dist/version.d.ts +1 -1
  240. package/node_modules/@oscharko-dev/keiko-evidence/dist/version.js +1 -1
  241. package/node_modules/@oscharko-dev/keiko-evidence/package.json +4 -4
  242. package/node_modules/@oscharko-dev/keiko-git/dist/types.d.ts +20 -0
  243. package/node_modules/@oscharko-dev/keiko-git/dist/types.d.ts.map +1 -1
  244. package/node_modules/@oscharko-dev/keiko-git/dist/version.d.ts +1 -1
  245. package/node_modules/@oscharko-dev/keiko-git/dist/version.js +1 -1
  246. package/node_modules/@oscharko-dev/keiko-git/package.json +1 -1
  247. package/node_modules/@oscharko-dev/keiko-harness/dist/version.d.ts +1 -1
  248. package/node_modules/@oscharko-dev/keiko-harness/dist/version.js +1 -1
  249. package/node_modules/@oscharko-dev/keiko-harness/package.json +7 -7
  250. package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/indexing/embedding-activity-log.d.ts +68 -0
  251. package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/indexing/embedding-activity-log.d.ts.map +1 -0
  252. package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/indexing/embedding-activity-log.js +532 -0
  253. package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/indexing/embedding-batcher.d.ts.map +1 -1
  254. package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/indexing/embedding-batcher.js +93 -76
  255. package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/indexing/orchestrator-activity-log.d.ts +120 -0
  256. package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/indexing/orchestrator-activity-log.d.ts.map +1 -0
  257. package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/indexing/orchestrator-activity-log.js +686 -0
  258. package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/indexing/orchestrator.d.ts.map +1 -1
  259. package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/indexing/orchestrator.js +150 -207
  260. package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/indexing/preflight-activity-log.d.ts +36 -0
  261. package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/indexing/preflight-activity-log.d.ts.map +1 -0
  262. package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/indexing/preflight-activity-log.js +264 -0
  263. package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/indexing/types.d.ts.map +1 -1
  264. package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/knowledge-log.d.ts +1 -0
  265. package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/knowledge-log.d.ts.map +1 -1
  266. package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/knowledge-log.js +44 -12
  267. package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/repository-pod.d.ts.map +1 -1
  268. package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/repository-pod.js +30 -13
  269. package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/retrieval/local-vector-index-port.d.ts.map +1 -1
  270. package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/retrieval/local-vector-index-port.js +25 -6
  271. package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/retrieval/usearch-ann-index.d.ts.map +1 -1
  272. package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/retrieval/usearch-ann-index.js +46 -10
  273. package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/store-content-encryption.d.ts.map +1 -1
  274. package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/store-content-encryption.js +71 -20
  275. package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/store.d.ts.map +1 -1
  276. package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/store.js +54 -17
  277. package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/version.d.ts +1 -1
  278. package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/version.js +1 -1
  279. package/node_modules/@oscharko-dev/keiko-local-knowledge/package.json +5 -5
  280. package/node_modules/@oscharko-dev/keiko-memory-capture/dist/version.d.ts +1 -1
  281. package/node_modules/@oscharko-dev/keiko-memory-capture/dist/version.js +1 -1
  282. package/node_modules/@oscharko-dev/keiko-memory-capture/package.json +3 -3
  283. package/node_modules/@oscharko-dev/keiko-memory-consolidation/dist/consolidate.d.ts.map +1 -1
  284. package/node_modules/@oscharko-dev/keiko-memory-consolidation/dist/consolidate.js +24 -5
  285. package/node_modules/@oscharko-dev/keiko-memory-consolidation/dist/log-port.d.ts.map +1 -1
  286. package/node_modules/@oscharko-dev/keiko-memory-consolidation/dist/log-port.js +35 -12
  287. package/node_modules/@oscharko-dev/keiko-memory-consolidation/dist/version.d.ts +1 -1
  288. package/node_modules/@oscharko-dev/keiko-memory-consolidation/dist/version.js +1 -1
  289. package/node_modules/@oscharko-dev/keiko-memory-consolidation/package.json +3 -3
  290. package/node_modules/@oscharko-dev/keiko-memory-governance/dist/version.d.ts +1 -1
  291. package/node_modules/@oscharko-dev/keiko-memory-governance/dist/version.js +1 -1
  292. package/node_modules/@oscharko-dev/keiko-memory-governance/package.json +3 -3
  293. package/node_modules/@oscharko-dev/keiko-memory-retrieval/dist/version.d.ts +1 -1
  294. package/node_modules/@oscharko-dev/keiko-memory-retrieval/dist/version.js +1 -1
  295. package/node_modules/@oscharko-dev/keiko-memory-retrieval/package.json +3 -3
  296. package/node_modules/@oscharko-dev/keiko-memory-vault/dist/db.d.ts.map +1 -1
  297. package/node_modules/@oscharko-dev/keiko-memory-vault/dist/db.js +25 -7
  298. package/node_modules/@oscharko-dev/keiko-memory-vault/dist/migrate-encrypt.d.ts +4 -2
  299. package/node_modules/@oscharko-dev/keiko-memory-vault/dist/migrate-encrypt.d.ts.map +1 -1
  300. package/node_modules/@oscharko-dev/keiko-memory-vault/dist/migrate-encrypt.js +37 -12
  301. package/node_modules/@oscharko-dev/keiko-memory-vault/dist/schema.d.ts.map +1 -1
  302. package/node_modules/@oscharko-dev/keiko-memory-vault/dist/schema.js +34 -10
  303. package/node_modules/@oscharko-dev/keiko-memory-vault/dist/vault-log.d.ts +3 -2
  304. package/node_modules/@oscharko-dev/keiko-memory-vault/dist/vault-log.d.ts.map +1 -1
  305. package/node_modules/@oscharko-dev/keiko-memory-vault/dist/vault-log.js +35 -12
  306. package/node_modules/@oscharko-dev/keiko-memory-vault/dist/vault.d.ts.map +1 -1
  307. package/node_modules/@oscharko-dev/keiko-memory-vault/dist/vault.js +24 -6
  308. package/node_modules/@oscharko-dev/keiko-memory-vault/dist/version.d.ts +1 -1
  309. package/node_modules/@oscharko-dev/keiko-memory-vault/dist/version.js +1 -1
  310. package/node_modules/@oscharko-dev/keiko-memory-vault/package.json +3 -3
  311. package/node_modules/@oscharko-dev/keiko-model-gateway/dist/gateway.d.ts.map +1 -1
  312. package/node_modules/@oscharko-dev/keiko-model-gateway/dist/gateway.js +408 -40
  313. package/node_modules/@oscharko-dev/keiko-model-gateway/dist/http.d.ts.map +1 -1
  314. package/node_modules/@oscharko-dev/keiko-model-gateway/dist/http.js +237 -61
  315. package/node_modules/@oscharko-dev/keiko-model-gateway/dist/observability.d.ts +5 -0
  316. package/node_modules/@oscharko-dev/keiko-model-gateway/dist/observability.d.ts.map +1 -1
  317. package/node_modules/@oscharko-dev/keiko-model-gateway/dist/observability.js +72 -12
  318. package/node_modules/@oscharko-dev/keiko-model-gateway/dist/openai-adapter.d.ts.map +1 -1
  319. package/node_modules/@oscharko-dev/keiko-model-gateway/dist/openai-adapter.js +75 -17
  320. package/node_modules/@oscharko-dev/keiko-model-gateway/dist/openai-embedding-adapter.d.ts.map +1 -1
  321. package/node_modules/@oscharko-dev/keiko-model-gateway/dist/openai-embedding-adapter.js +404 -116
  322. package/node_modules/@oscharko-dev/keiko-model-gateway/dist/prDescription/generate.d.ts.map +1 -1
  323. package/node_modules/@oscharko-dev/keiko-model-gateway/dist/prDescription/generate.js +313 -92
  324. package/node_modules/@oscharko-dev/keiko-model-gateway/dist/resilience.d.ts +2 -3
  325. package/node_modules/@oscharko-dev/keiko-model-gateway/dist/resilience.d.ts.map +1 -1
  326. package/node_modules/@oscharko-dev/keiko-model-gateway/dist/resilience.js +260 -54
  327. package/node_modules/@oscharko-dev/keiko-model-gateway/dist/speech-to-text-adapter.d.ts.map +1 -1
  328. package/node_modules/@oscharko-dev/keiko-model-gateway/dist/speech-to-text-adapter.js +31 -11
  329. package/node_modules/@oscharko-dev/keiko-model-gateway/dist/text-to-speech-adapter.d.ts.map +1 -1
  330. package/node_modules/@oscharko-dev/keiko-model-gateway/dist/text-to-speech-adapter.js +147 -21
  331. package/node_modules/@oscharko-dev/keiko-model-gateway/dist/toolCatalogBridge.d.ts.map +1 -1
  332. package/node_modules/@oscharko-dev/keiko-model-gateway/dist/toolCatalogBridge.js +190 -44
  333. package/node_modules/@oscharko-dev/keiko-model-gateway/dist/version.d.ts +1 -1
  334. package/node_modules/@oscharko-dev/keiko-model-gateway/dist/version.js +1 -1
  335. package/node_modules/@oscharko-dev/keiko-model-gateway/package.json +4 -4
  336. package/node_modules/@oscharko-dev/keiko-quality-intelligence/package.json +3 -3
  337. package/node_modules/@oscharko-dev/keiko-sandbox/package.json +2 -2
  338. package/node_modules/@oscharko-dev/keiko-sdk/package.json +9 -9
  339. package/node_modules/@oscharko-dev/keiko-security/dist/fs-atomic-rename.d.ts.map +1 -1
  340. package/node_modules/@oscharko-dev/keiko-security/dist/fs-atomic-rename.js +39 -14
  341. package/node_modules/@oscharko-dev/keiko-security/dist/fs-hardening.d.ts +107 -0
  342. package/node_modules/@oscharko-dev/keiko-security/dist/fs-hardening.d.ts.map +1 -1
  343. package/node_modules/@oscharko-dev/keiko-security/dist/fs-hardening.js +1998 -1
  344. package/node_modules/@oscharko-dev/keiko-security/dist/index.d.ts +2 -1
  345. package/node_modules/@oscharko-dev/keiko-security/dist/index.d.ts.map +1 -1
  346. package/node_modules/@oscharko-dev/keiko-security/dist/index.js +1 -3
  347. package/node_modules/@oscharko-dev/keiko-security/dist/log-port.d.ts.map +1 -1
  348. package/node_modules/@oscharko-dev/keiko-security/dist/log-port.js +36 -13
  349. package/node_modules/@oscharko-dev/keiko-security/dist/macos-keychain.d.ts.map +1 -1
  350. package/node_modules/@oscharko-dev/keiko-security/dist/macos-keychain.js +31 -15
  351. package/node_modules/@oscharko-dev/keiko-security/dist/portable-tree-attestation.d.ts +2 -1
  352. package/node_modules/@oscharko-dev/keiko-security/dist/portable-tree-attestation.d.ts.map +1 -1
  353. package/node_modules/@oscharko-dev/keiko-security/dist/portable-tree-attestation.js +46 -15
  354. package/node_modules/@oscharko-dev/keiko-security/dist/safe-artifact-directory-mutation-protocol.d.ts +23 -0
  355. package/node_modules/@oscharko-dev/keiko-security/dist/safe-artifact-directory-mutation-protocol.d.ts.map +1 -0
  356. package/node_modules/@oscharko-dev/keiko-security/dist/safe-artifact-directory-mutation-protocol.js +11 -0
  357. package/node_modules/@oscharko-dev/keiko-security/dist/safe-artifact-directory-mutation-runtime.d.ts +9 -0
  358. package/node_modules/@oscharko-dev/keiko-security/dist/safe-artifact-directory-mutation-runtime.d.ts.map +1 -0
  359. package/node_modules/@oscharko-dev/keiko-security/dist/safe-artifact-directory-mutation-runtime.js +115 -0
  360. package/node_modules/@oscharko-dev/keiko-security/dist/safe-artifact-directory-mutation.d.ts +2 -0
  361. package/node_modules/@oscharko-dev/keiko-security/dist/safe-artifact-directory-mutation.d.ts.map +1 -0
  362. package/node_modules/@oscharko-dev/keiko-security/dist/safe-artifact-directory-mutation.js +50 -0
  363. package/node_modules/@oscharko-dev/keiko-security/dist/secret-vault.d.ts.map +1 -1
  364. package/node_modules/@oscharko-dev/keiko-security/dist/secret-vault.js +260 -50
  365. package/node_modules/@oscharko-dev/keiko-security/dist/version.d.ts +1 -1
  366. package/node_modules/@oscharko-dev/keiko-security/dist/version.js +1 -1
  367. package/node_modules/@oscharko-dev/keiko-security/dist/windows-local-volume.d.ts.map +1 -1
  368. package/node_modules/@oscharko-dev/keiko-security/dist/windows-local-volume.js +32 -7
  369. package/node_modules/@oscharko-dev/keiko-security/dist/windows-shortcuts.d.ts.map +1 -1
  370. package/node_modules/@oscharko-dev/keiko-security/dist/windows-shortcuts.js +38 -14
  371. package/node_modules/@oscharko-dev/keiko-security/package.json +2 -2
  372. package/node_modules/@oscharko-dev/keiko-server/dist/atlassian/credentialRoutes.d.ts.map +1 -1
  373. package/node_modules/@oscharko-dev/keiko-server/dist/atlassian/credentialRoutes.js +47 -5
  374. package/node_modules/@oscharko-dev/keiko-server/dist/bounded-request-body.d.ts.map +1 -1
  375. package/node_modules/@oscharko-dev/keiko-server/dist/bounded-request-body.js +160 -37
  376. package/node_modules/@oscharko-dev/keiko-server/dist/chat-activity.d.ts +48 -0
  377. package/node_modules/@oscharko-dev/keiko-server/dist/chat-activity.d.ts.map +1 -0
  378. package/node_modules/@oscharko-dev/keiko-server/dist/chat-activity.js +336 -0
  379. package/node_modules/@oscharko-dev/keiko-server/dist/chat-compaction-model-summary.d.ts.map +1 -1
  380. package/node_modules/@oscharko-dev/keiko-server/dist/chat-compaction-model-summary.js +28 -10
  381. package/node_modules/@oscharko-dev/keiko-server/dist/chat-handlers.d.ts +5 -5
  382. package/node_modules/@oscharko-dev/keiko-server/dist/chat-handlers.d.ts.map +1 -1
  383. package/node_modules/@oscharko-dev/keiko-server/dist/chat-handlers.js +49 -66
  384. package/node_modules/@oscharko-dev/keiko-server/dist/chat-stream-handlers.d.ts.map +1 -1
  385. package/node_modules/@oscharko-dev/keiko-server/dist/chat-stream-handlers.js +5 -1
  386. package/node_modules/@oscharko-dev/keiko-server/dist/client-diagnostics-routes.d.ts +9 -1
  387. package/node_modules/@oscharko-dev/keiko-server/dist/client-diagnostics-routes.d.ts.map +1 -1
  388. package/node_modules/@oscharko-dev/keiko-server/dist/client-diagnostics-routes.js +1202 -50
  389. package/node_modules/@oscharko-dev/keiko-server/dist/coding-app-session/codingAppSessionRoutes.d.ts.map +1 -1
  390. package/node_modules/@oscharko-dev/keiko-server/dist/coding-app-session/codingAppSessionRoutes.js +98 -35
  391. package/node_modules/@oscharko-dev/keiko-server/dist/coding-context/activity-log.d.ts +22 -0
  392. package/node_modules/@oscharko-dev/keiko-server/dist/coding-context/activity-log.d.ts.map +1 -0
  393. package/node_modules/@oscharko-dev/keiko-server/dist/coding-context/activity-log.js +83 -0
  394. package/node_modules/@oscharko-dev/keiko-server/dist/coding-context/codeContextConnector.d.ts.map +1 -1
  395. package/node_modules/@oscharko-dev/keiko-server/dist/coding-context/codeContextConnector.js +10 -15
  396. package/node_modules/@oscharko-dev/keiko-server/dist/coding-context/codingRuntimeIssueIntake.d.ts.map +1 -1
  397. package/node_modules/@oscharko-dev/keiko-server/dist/coding-context/codingRuntimeIssueIntake.js +45 -23
  398. package/node_modules/@oscharko-dev/keiko-server/dist/coding-context/githubAuthorizationRoutes.d.ts.map +1 -1
  399. package/node_modules/@oscharko-dev/keiko-server/dist/coding-context/githubAuthorizationRoutes.js +21 -6
  400. package/node_modules/@oscharko-dev/keiko-server/dist/coding-context/githubCodeContextPort.d.ts.map +1 -1
  401. package/node_modules/@oscharko-dev/keiko-server/dist/coding-context/githubCodeContextPort.js +90 -12
  402. package/node_modules/@oscharko-dev/keiko-server/dist/coding-context/githubIssueReaderAuthorization.d.ts.map +1 -1
  403. package/node_modules/@oscharko-dev/keiko-server/dist/coding-context/githubIssueReaderAuthorization.js +85 -27
  404. package/node_modules/@oscharko-dev/keiko-server/dist/coding-context/githubIssueResolution.d.ts +2 -0
  405. package/node_modules/@oscharko-dev/keiko-server/dist/coding-context/githubIssueResolution.d.ts.map +1 -1
  406. package/node_modules/@oscharko-dev/keiko-server/dist/coding-context/githubIssueResolution.js +118 -14
  407. package/node_modules/@oscharko-dev/keiko-server/dist/coding-context/issuePreviewRoutes.d.ts.map +1 -1
  408. package/node_modules/@oscharko-dev/keiko-server/dist/coding-context/issuePreviewRoutes.js +53 -9
  409. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingHistoryRoutes.d.ts +7 -0
  410. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingHistoryRoutes.d.ts.map +1 -0
  411. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingHistoryRoutes.js +78 -0
  412. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingRepositorySearchHandler.d.ts.map +1 -1
  413. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingRepositorySearchHandler.js +126 -27
  414. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingRuntimeActivityOperations.d.ts +857 -0
  415. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingRuntimeActivityOperations.d.ts.map +1 -0
  416. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingRuntimeActivityOperations.js +411 -0
  417. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingRuntimeCiRepairBudgetStore.d.ts.map +1 -1
  418. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingRuntimeCiRepairBudgetStore.js +49 -44
  419. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingRuntimeCiRepairBudgetTypes.d.ts +2 -0
  420. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingRuntimeCiRepairBudgetTypes.d.ts.map +1 -1
  421. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingRuntimeCiRepairBudgetTypes.js +17 -0
  422. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingRuntimeCiRepairController.d.ts +9 -1
  423. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingRuntimeCiRepairController.d.ts.map +1 -1
  424. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingRuntimeCiRepairController.js +38 -20
  425. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingRuntimeControlPlane.d.ts +2 -0
  426. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingRuntimeControlPlane.d.ts.map +1 -1
  427. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingRuntimeControlPlane.js +4 -0
  428. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingRuntimeHistory.d.ts +40 -0
  429. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingRuntimeHistory.d.ts.map +1 -0
  430. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingRuntimeHistory.js +372 -0
  431. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingRuntimeIssueIntake.d.ts +2 -0
  432. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingRuntimeIssueIntake.d.ts.map +1 -1
  433. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingRuntimeIssueIntake.js +104 -20
  434. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingRuntimeManager.d.ts.map +1 -1
  435. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingRuntimeManager.js +0 -1
  436. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingRuntimeOperationCoordinator.d.ts.map +1 -1
  437. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingRuntimeOperationCoordinator.js +183 -27
  438. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingRuntimeOrchestrator.d.ts +12 -3
  439. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingRuntimeOrchestrator.d.ts.map +1 -1
  440. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingRuntimeOrchestrator.js +963 -223
  441. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingRuntimeOrchestratorTypes.d.ts +3 -0
  442. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingRuntimeOrchestratorTypes.d.ts.map +1 -1
  443. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingRuntimeRoutes.d.ts.map +1 -1
  444. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingRuntimeRoutes.js +123 -14
  445. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingRuntimeSnapshotStore.d.ts +2 -0
  446. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingRuntimeSnapshotStore.d.ts.map +1 -1
  447. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingRuntimeSnapshotStore.js +33 -16
  448. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingRuntimeVerifiedCommitAuthorityStore.d.ts.map +1 -1
  449. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingRuntimeVerifiedCommitAuthorityStore.js +23 -9
  450. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingSafeActivityProjection.d.ts +1 -1
  451. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingSafeActivityProjection.d.ts.map +1 -1
  452. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingSafeActivityProjection.js +66 -19
  453. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingToolAuthorityPort.d.ts.map +1 -1
  454. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingToolAuthorityPort.js +46 -5
  455. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingToolFacade.d.ts.map +1 -1
  456. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingToolFacade.js +13 -1
  457. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingToolGovernedDelegate.d.ts.map +1 -1
  458. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingToolGovernedDelegate.js +6 -5
  459. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingToolIpc.d.ts +8 -2
  460. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingToolIpc.d.ts.map +1 -1
  461. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingToolReadEditPorts.d.ts.map +1 -1
  462. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingToolReadEditPorts.js +130 -31
  463. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/devLanePortableCodingRuntime.js +3 -3
  464. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/devLaneRuntimeProcessBackend.d.ts +1 -1
  465. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/devLaneRuntimeProcessBackend.d.ts.map +1 -1
  466. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/devLaneRuntimeProcessBackend.js +54 -47
  467. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/nativeRuntimeProcessBackend.d.ts +1 -1
  468. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/nativeRuntimeProcessBackend.d.ts.map +1 -1
  469. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/nativeRuntimeProcessBackend.js +13 -16
  470. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/opencodeLaunchProfile.d.ts +5 -2
  471. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/opencodeLaunchProfile.d.ts.map +1 -1
  472. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/opencodeLaunchProfile.js +56 -4
  473. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/opencodeProtocolSurface.d.ts +4 -1
  474. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/opencodeProtocolSurface.d.ts.map +1 -1
  475. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/opencodeProtocolSurface.js +24 -4
  476. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/opencodeRuntimeAdapter.d.ts +10 -1
  477. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/opencodeRuntimeAdapter.d.ts.map +1 -1
  478. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/opencodeRuntimeAdapter.js +244 -61
  479. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/opencodeRuntimeComposition.d.ts +2 -1
  480. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/opencodeRuntimeComposition.d.ts.map +1 -1
  481. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/opencodeRuntimeComposition.js +268 -368
  482. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/opencodeToolSchemas.d.ts +5 -13
  483. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/opencodeToolSchemas.d.ts.map +1 -1
  484. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/opencodeToolSchemas.js +15 -44
  485. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/opencodeV2ApprovalRequests.d.ts +16 -0
  486. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/opencodeV2ApprovalRequests.d.ts.map +1 -0
  487. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/opencodeV2ApprovalRequests.js +86 -0
  488. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/opencodeV2History.d.ts +22 -0
  489. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/opencodeV2History.d.ts.map +1 -0
  490. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/opencodeV2History.js +438 -0
  491. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/opencodeV2HttpClient.d.ts +30 -0
  492. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/opencodeV2HttpClient.d.ts.map +1 -0
  493. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/opencodeV2HttpClient.js +251 -0
  494. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/opencodeV2Questions.d.ts +7 -0
  495. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/opencodeV2Questions.d.ts.map +1 -0
  496. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/opencodeV2Questions.js +125 -0
  497. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/productionAuxiliaryPorts.d.ts.map +1 -1
  498. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/productionAuxiliaryPorts.js +42 -14
  499. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/productionCiRepairRuntime.d.ts.map +1 -1
  500. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/productionCiRepairRuntime.js +65 -36
  501. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/productionCodingRuntimePorts.d.ts.map +1 -1
  502. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/productionCodingRuntimePorts.js +109 -21
  503. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/productionCodingRuntimeQuestionPort.d.ts.map +1 -1
  504. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/productionCodingRuntimeQuestionPort.js +3 -6
  505. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/productionCodingRuntimeResolver.d.ts +1 -1
  506. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/productionCodingRuntimeResolver.d.ts.map +1 -1
  507. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/productionCodingRuntimeResolver.js +18 -8
  508. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/productionDraftDeliveryDependencies.d.ts.map +1 -1
  509. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/productionDraftDeliveryDependencies.js +160 -46
  510. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/productionManagedWorktreeTools.d.ts.map +1 -1
  511. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/productionManagedWorktreeTools.js +423 -106
  512. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/productionOpenCodeActivation.d.ts +2 -0
  513. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/productionOpenCodeActivation.d.ts.map +1 -1
  514. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/productionOpenCodeActivation.js +100 -18
  515. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/productionOpenCodeBackend.d.ts +6 -1
  516. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/productionOpenCodeBackend.d.ts.map +1 -1
  517. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/productionOpenCodeBackend.js +43 -16
  518. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/productionRuntimeGitPreparation.d.ts.map +1 -1
  519. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/productionRuntimeGitPreparation.js +51 -7
  520. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/productionVerifiedCommitDependencies.d.ts.map +1 -1
  521. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/productionVerifiedCommitDependencies.js +32 -9
  522. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/readOnlyChildOrchestrator.d.ts +1 -1
  523. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/readOnlyChildOrchestrator.d.ts.map +1 -1
  524. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/readOnlyChildOrchestrator.js +155 -22
  525. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/runtimeAuthorityService.d.ts +1 -1
  526. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/runtimeAuthorityService.d.ts.map +1 -1
  527. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/runtimeAuthorityService.js +300 -61
  528. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/windowsPortableAuthenticode.d.ts.map +1 -1
  529. package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/windowsPortableAuthenticode.js +30 -11
  530. package/node_modules/@oscharko-dev/keiko-server/dist/coding-sidecar-gateway.d.ts.map +1 -1
  531. package/node_modules/@oscharko-dev/keiko-server/dist/coding-sidecar-gateway.js +240 -61
  532. package/node_modules/@oscharko-dev/keiko-server/dist/coding-sidecar-tool-facade.d.ts.map +1 -1
  533. package/node_modules/@oscharko-dev/keiko-server/dist/coding-sidecar-tool-facade.js +45 -8
  534. package/node_modules/@oscharko-dev/keiko-server/dist/deps-activity.d.ts +40 -0
  535. package/node_modules/@oscharko-dev/keiko-server/dist/deps-activity.d.ts.map +1 -0
  536. package/node_modules/@oscharko-dev/keiko-server/dist/deps-activity.js +207 -0
  537. package/node_modules/@oscharko-dev/keiko-server/dist/deps.d.ts +7 -1
  538. package/node_modules/@oscharko-dev/keiko-server/dist/deps.d.ts.map +1 -1
  539. package/node_modules/@oscharko-dev/keiko-server/dist/deps.js +69 -58
  540. package/node_modules/@oscharko-dev/keiko-server/dist/diagnostics-log.d.ts +1 -1
  541. package/node_modules/@oscharko-dev/keiko-server/dist/diagnostics-log.d.ts.map +1 -1
  542. package/node_modules/@oscharko-dev/keiko-server/dist/diagnostics-log.js +194 -26
  543. package/node_modules/@oscharko-dev/keiko-server/dist/editor/agentProducerRoute.d.ts.map +1 -1
  544. package/node_modules/@oscharko-dev/keiko-server/dist/editor/agentProducerRoute.js +113 -17
  545. package/node_modules/@oscharko-dev/keiko-server/dist/editor/agentRoutes.d.ts.map +1 -1
  546. package/node_modules/@oscharko-dev/keiko-server/dist/editor/agentRoutes.js +7 -1
  547. package/node_modules/@oscharko-dev/keiko-server/dist/editor/dap/debugLaunchPlan.d.ts.map +1 -1
  548. package/node_modules/@oscharko-dev/keiko-server/dist/editor/dap/debugLaunchPlan.js +35 -11
  549. package/node_modules/@oscharko-dev/keiko-server/dist/editor/localHistory/localHistoryCapture.d.ts +1 -1
  550. package/node_modules/@oscharko-dev/keiko-server/dist/editor/localHistory/localHistoryCapture.d.ts.map +1 -1
  551. package/node_modules/@oscharko-dev/keiko-server/dist/editor/localHistory/localHistoryCapture.js +56 -15
  552. package/node_modules/@oscharko-dev/keiko-server/dist/editor/lsp/lspNodeAdapter.d.ts.map +1 -1
  553. package/node_modules/@oscharko-dev/keiko-server/dist/editor/lsp/lspNodeAdapter.js +201 -37
  554. package/node_modules/@oscharko-dev/keiko-server/dist/editor/lsp/lspProcessManager.d.ts.map +1 -1
  555. package/node_modules/@oscharko-dev/keiko-server/dist/editor/lsp/lspProcessManager.js +51 -11
  556. package/node_modules/@oscharko-dev/keiko-server/dist/editor/lsp/providers/javaProvider.d.ts.map +1 -1
  557. package/node_modules/@oscharko-dev/keiko-server/dist/editor/lsp/providers/javaProvider.js +78 -11
  558. package/node_modules/@oscharko-dev/keiko-server/dist/editor/verificationExecution.d.ts +4 -1
  559. package/node_modules/@oscharko-dev/keiko-server/dist/editor/verificationExecution.d.ts.map +1 -1
  560. package/node_modules/@oscharko-dev/keiko-server/dist/editor/verificationExecution.js +55 -0
  561. package/node_modules/@oscharko-dev/keiko-server/dist/editor/verificationRunner.d.ts.map +1 -1
  562. package/node_modules/@oscharko-dev/keiko-server/dist/editor/verificationRunner.js +211 -65
  563. package/node_modules/@oscharko-dev/keiko-server/dist/editor/watch/workspaceWatchRoutes.d.ts.map +1 -1
  564. package/node_modules/@oscharko-dev/keiko-server/dist/editor/watch/workspaceWatchRoutes.js +33 -6
  565. package/node_modules/@oscharko-dev/keiko-server/dist/evidence-retention-log.d.ts.map +1 -1
  566. package/node_modules/@oscharko-dev/keiko-server/dist/evidence-retention-log.js +36 -6
  567. package/node_modules/@oscharko-dev/keiko-server/dist/gateway-instance-cache.d.ts.map +1 -1
  568. package/node_modules/@oscharko-dev/keiko-server/dist/gateway-instance-cache.js +97 -22
  569. package/node_modules/@oscharko-dev/keiko-server/dist/gateway-readiness.d.ts +5 -3
  570. package/node_modules/@oscharko-dev/keiko-server/dist/gateway-readiness.d.ts.map +1 -1
  571. package/node_modules/@oscharko-dev/keiko-server/dist/gateway-readiness.js +220 -39
  572. package/node_modules/@oscharko-dev/keiko-server/dist/gateway-setup.d.ts.map +1 -1
  573. package/node_modules/@oscharko-dev/keiko-server/dist/gateway-setup.js +283 -68
  574. package/node_modules/@oscharko-dev/keiko-server/dist/gateway-spend-budget.d.ts.map +1 -1
  575. package/node_modules/@oscharko-dev/keiko-server/dist/gateway-spend-budget.js +138 -45
  576. package/node_modules/@oscharko-dev/keiko-server/dist/gitChangeChatContext.d.ts.map +1 -1
  577. package/node_modules/@oscharko-dev/keiko-server/dist/gitChangeChatContext.js +97 -13
  578. package/node_modules/@oscharko-dev/keiko-server/dist/gitChangeRoutes.d.ts +5 -0
  579. package/node_modules/@oscharko-dev/keiko-server/dist/gitChangeRoutes.d.ts.map +1 -1
  580. package/node_modules/@oscharko-dev/keiko-server/dist/gitChangeRoutes.js +146 -30
  581. package/node_modules/@oscharko-dev/keiko-server/dist/gitChangeSnapshotReader.d.ts.map +1 -1
  582. package/node_modules/@oscharko-dev/keiko-server/dist/gitChangeSnapshotReader.js +13 -1
  583. package/node_modules/@oscharko-dev/keiko-server/dist/gitChangeSnapshotRegistry.d.ts.map +1 -1
  584. package/node_modules/@oscharko-dev/keiko-server/dist/gitChangeSnapshotRegistry.js +122 -32
  585. package/node_modules/@oscharko-dev/keiko-server/dist/gitChangeSnapshotService.d.ts.map +1 -1
  586. package/node_modules/@oscharko-dev/keiko-server/dist/gitChangeSnapshotService.js +140 -24
  587. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/approvalEvents.d.ts +6 -2
  588. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/approvalEvents.d.ts.map +1 -1
  589. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/approvalEvents.js +192 -8
  590. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/ciObservationService.d.ts.map +1 -1
  591. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/ciObservationService.js +154 -26
  592. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/commitRoutes.d.ts +2 -2
  593. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/commitRoutes.d.ts.map +1 -1
  594. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/commitRoutes.js +100 -46
  595. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/draftDeliveryChecks.d.ts +21 -0
  596. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/draftDeliveryChecks.d.ts.map +1 -1
  597. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/draftDeliveryChecks.js +108 -13
  598. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/draftDeliveryChecksRefresh.d.ts.map +1 -1
  599. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/draftDeliveryChecksRefresh.js +23 -20
  600. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/draftDeliveryFacts.d.ts.map +1 -1
  601. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/draftDeliveryFacts.js +93 -18
  602. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/draftDeliveryLedger.d.ts +28 -0
  603. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/draftDeliveryLedger.d.ts.map +1 -1
  604. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/draftDeliveryLedger.js +123 -33
  605. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/draftDeliveryService.d.ts.map +1 -1
  606. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/draftDeliveryService.js +33 -33
  607. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/draftDeliveryTemplate.d.ts.map +1 -1
  608. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/draftDeliveryTemplate.js +97 -24
  609. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/draftRelatedIssuesActivity.d.ts +150 -0
  610. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/draftRelatedIssuesActivity.d.ts.map +1 -0
  611. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/draftRelatedIssuesActivity.js +64 -0
  612. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/execution.d.ts +226 -1
  613. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/execution.d.ts.map +1 -1
  614. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/execution.js +344 -70
  615. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/journeyObservationService.d.ts +25 -0
  616. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/journeyObservationService.d.ts.map +1 -1
  617. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/journeyObservationService.js +159 -26
  618. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/journeyRoutes.d.ts.map +1 -1
  619. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/journeyRoutes.js +238 -59
  620. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/localMutationRoutes.d.ts.map +1 -1
  621. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/localMutationRoutes.js +2 -9
  622. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/mergeExecution.d.ts.map +1 -1
  623. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/mergeExecution.js +79 -13
  624. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/prDescriptionPreparation.d.ts.map +1 -1
  625. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/prDescriptionPreparation.js +6 -2
  626. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/prDescriptionProjection.d.ts.map +1 -1
  627. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/prDescriptionProjection.js +133 -16
  628. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/prDescriptionReceiptStore.d.ts.map +1 -1
  629. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/prDescriptionReceiptStore.js +73 -19
  630. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/prDescriptionRoutes.d.ts.map +1 -1
  631. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/prDescriptionRoutes.js +147 -50
  632. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/prDescriptionService.d.ts.map +1 -1
  633. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/prDescriptionService.js +4 -3
  634. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/prDescriptionTypes.d.ts +12 -4
  635. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/prDescriptionTypes.d.ts.map +1 -1
  636. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/prMarkReadyExecution.d.ts +1 -1
  637. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/prMarkReadyExecution.d.ts.map +1 -1
  638. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/prMarkReadyExecution.js +138 -42
  639. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/repositoryInitializationRoutes.d.ts.map +1 -1
  640. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/repositoryInitializationRoutes.js +51 -7
  641. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/requestPreparation.d.ts +4 -0
  642. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/requestPreparation.d.ts.map +1 -1
  643. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/requestPreparation.js +145 -26
  644. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/runtimeGitRead.d.ts.map +1 -1
  645. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/runtimeGitRead.js +43 -13
  646. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/runtimeGitService.d.ts.map +1 -1
  647. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/runtimeGitService.js +122 -11
  648. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/syncRoutes.d.ts.map +1 -1
  649. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/syncRoutes.js +4 -15
  650. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/verifiedCommitService.d.ts.map +1 -1
  651. package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/verifiedCommitService.js +194 -11
  652. package/node_modules/@oscharko-dev/keiko-server/dist/gitProcessActivity.d.ts +5 -2
  653. package/node_modules/@oscharko-dev/keiko-server/dist/gitProcessActivity.d.ts.map +1 -1
  654. package/node_modules/@oscharko-dev/keiko-server/dist/gitProcessActivity.js +157 -31
  655. package/node_modules/@oscharko-dev/keiko-server/dist/grounded-orchestrator.d.ts.map +1 -1
  656. package/node_modules/@oscharko-dev/keiko-server/dist/grounded-orchestrator.js +514 -74
  657. package/node_modules/@oscharko-dev/keiko-server/dist/grounded-qa.d.ts.map +1 -1
  658. package/node_modules/@oscharko-dev/keiko-server/dist/grounded-qa.js +7 -2
  659. package/node_modules/@oscharko-dev/keiko-server/dist/grounded-rerank-facade.d.ts.map +1 -1
  660. package/node_modules/@oscharko-dev/keiko-server/dist/grounded-rerank-facade.js +84 -20
  661. package/node_modules/@oscharko-dev/keiko-server/dist/harness-context-compactor.d.ts.map +1 -1
  662. package/node_modules/@oscharko-dev/keiko-server/dist/harness-context-compactor.js +30 -9
  663. package/node_modules/@oscharko-dev/keiko-server/dist/index.d.ts +7 -0
  664. package/node_modules/@oscharko-dev/keiko-server/dist/index.d.ts.map +1 -1
  665. package/node_modules/@oscharko-dev/keiko-server/dist/index.js +20 -0
  666. package/node_modules/@oscharko-dev/keiko-server/dist/local-knowledge-handlers.d.ts.map +1 -1
  667. package/node_modules/@oscharko-dev/keiko-server/dist/local-knowledge-handlers.js +287 -68
  668. package/node_modules/@oscharko-dev/keiko-server/dist/memory-embedding.d.ts.map +1 -1
  669. package/node_modules/@oscharko-dev/keiko-server/dist/memory-embedding.js +219 -65
  670. package/node_modules/@oscharko-dev/keiko-server/dist/native-file-dialog/route.d.ts.map +1 -1
  671. package/node_modules/@oscharko-dev/keiko-server/dist/native-file-dialog/route.js +30 -10
  672. package/node_modules/@oscharko-dev/keiko-server/dist/observability/activity-log-loss-summary.d.ts +233 -0
  673. package/node_modules/@oscharko-dev/keiko-server/dist/observability/activity-log-loss-summary.d.ts.map +1 -0
  674. package/node_modules/@oscharko-dev/keiko-server/dist/observability/activity-log-loss-summary.js +124 -0
  675. package/node_modules/@oscharko-dev/keiko-server/dist/observability/activity-log-persistence.d.ts +8 -0
  676. package/node_modules/@oscharko-dev/keiko-server/dist/observability/activity-log-persistence.d.ts.map +1 -0
  677. package/node_modules/@oscharko-dev/keiko-server/dist/observability/activity-log-persistence.js +25 -0
  678. package/node_modules/@oscharko-dev/keiko-server/dist/observability/activity-log-readiness.d.ts +34 -0
  679. package/node_modules/@oscharko-dev/keiko-server/dist/observability/activity-log-readiness.d.ts.map +1 -0
  680. package/node_modules/@oscharko-dev/keiko-server/dist/observability/activity-log-readiness.js +301 -0
  681. package/node_modules/@oscharko-dev/keiko-server/dist/observability/activity-log-store.d.ts +215 -0
  682. package/node_modules/@oscharko-dev/keiko-server/dist/observability/activity-log-store.d.ts.map +1 -0
  683. package/node_modules/@oscharko-dev/keiko-server/dist/observability/activity-log-store.js +755 -0
  684. package/node_modules/@oscharko-dev/keiko-server/dist/observability/index.d.ts +4 -0
  685. package/node_modules/@oscharko-dev/keiko-server/dist/observability/index.d.ts.map +1 -1
  686. package/node_modules/@oscharko-dev/keiko-server/dist/observability/index.js +6 -2
  687. package/node_modules/@oscharko-dev/keiko-server/dist/observability/log-redaction.d.ts.map +1 -1
  688. package/node_modules/@oscharko-dev/keiko-server/dist/observability/log-redaction.js +25 -14
  689. package/node_modules/@oscharko-dev/keiko-server/dist/observability/model-id-evidence.d.ts +17 -0
  690. package/node_modules/@oscharko-dev/keiko-server/dist/observability/model-id-evidence.d.ts.map +1 -0
  691. package/node_modules/@oscharko-dev/keiko-server/dist/observability/model-id-evidence.js +35 -0
  692. package/node_modules/@oscharko-dev/keiko-server/dist/observability/runtime-state-dir.d.ts +6 -0
  693. package/node_modules/@oscharko-dev/keiko-server/dist/observability/runtime-state-dir.d.ts.map +1 -0
  694. package/node_modules/@oscharko-dev/keiko-server/dist/observability/runtime-state-dir.js +23 -0
  695. package/node_modules/@oscharko-dev/keiko-server/dist/observability/server-log.d.ts +106 -6
  696. package/node_modules/@oscharko-dev/keiko-server/dist/observability/server-log.d.ts.map +1 -1
  697. package/node_modules/@oscharko-dev/keiko-server/dist/observability/server-log.js +2504 -481
  698. package/node_modules/@oscharko-dev/keiko-server/dist/observability/server-logger.d.ts +38 -2
  699. package/node_modules/@oscharko-dev/keiko-server/dist/observability/server-logger.d.ts.map +1 -1
  700. package/node_modules/@oscharko-dev/keiko-server/dist/observability/server-logger.js +187 -39
  701. package/node_modules/@oscharko-dev/keiko-server/dist/observability/support-incident-store.d.ts +44 -0
  702. package/node_modules/@oscharko-dev/keiko-server/dist/observability/support-incident-store.d.ts.map +1 -0
  703. package/node_modules/@oscharko-dev/keiko-server/dist/observability/support-incident-store.js +255 -0
  704. package/node_modules/@oscharko-dev/keiko-server/dist/observability/support-incident.d.ts +107 -0
  705. package/node_modules/@oscharko-dev/keiko-server/dist/observability/support-incident.d.ts.map +1 -0
  706. package/node_modules/@oscharko-dev/keiko-server/dist/observability/support-incident.js +1052 -0
  707. package/node_modules/@oscharko-dev/keiko-server/dist/process-log-sink.d.ts.map +1 -1
  708. package/node_modules/@oscharko-dev/keiko-server/dist/process-log-sink.js +66 -17
  709. package/node_modules/@oscharko-dev/keiko-server/dist/qualityIntelligence/capsuleAdapter.d.ts +3 -2
  710. package/node_modules/@oscharko-dev/keiko-server/dist/qualityIntelligence/capsuleAdapter.d.ts.map +1 -1
  711. package/node_modules/@oscharko-dev/keiko-server/dist/qualityIntelligence/capsuleAdapter.js +35 -5
  712. package/node_modules/@oscharko-dev/keiko-server/dist/qualityIntelligence/figmaSnapshotRoutes.d.ts.map +1 -1
  713. package/node_modules/@oscharko-dev/keiko-server/dist/qualityIntelligence/figmaSnapshotRoutes.js +3 -1
  714. package/node_modules/@oscharko-dev/keiko-server/dist/qualityIntelligence/handoffRoutes.d.ts.map +1 -1
  715. package/node_modules/@oscharko-dev/keiko-server/dist/qualityIntelligence/handoffRoutes.js +7 -6
  716. package/node_modules/@oscharko-dev/keiko-server/dist/qualityIntelligence/reCheckRoutes.d.ts.map +1 -1
  717. package/node_modules/@oscharko-dev/keiko-server/dist/qualityIntelligence/reCheckRoutes.js +7 -2
  718. package/node_modules/@oscharko-dev/keiko-server/dist/qualityIntelligence/runRoutes.d.ts.map +1 -1
  719. package/node_modules/@oscharko-dev/keiko-server/dist/qualityIntelligence/runRoutes.js +7 -2
  720. package/node_modules/@oscharko-dev/keiko-server/dist/reference-id.d.ts +16 -0
  721. package/node_modules/@oscharko-dev/keiko-server/dist/reference-id.d.ts.map +1 -0
  722. package/node_modules/@oscharko-dev/keiko-server/dist/reference-id.js +90 -0
  723. package/node_modules/@oscharko-dev/keiko-server/dist/routes.d.ts.map +1 -1
  724. package/node_modules/@oscharko-dev/keiko-server/dist/routes.js +12 -7
  725. package/node_modules/@oscharko-dev/keiko-server/dist/run-engine.d.ts.map +1 -1
  726. package/node_modules/@oscharko-dev/keiko-server/dist/run-engine.js +3 -3
  727. package/node_modules/@oscharko-dev/keiko-server/dist/run-handlers.d.ts.map +1 -1
  728. package/node_modules/@oscharko-dev/keiko-server/dist/run-handlers.js +33 -9
  729. package/node_modules/@oscharko-dev/keiko-server/dist/server.d.ts.map +1 -1
  730. package/node_modules/@oscharko-dev/keiko-server/dist/server.js +50 -10
  731. package/node_modules/@oscharko-dev/keiko-server/dist/sse-write.d.ts.map +1 -1
  732. package/node_modules/@oscharko-dev/keiko-server/dist/sse-write.js +37 -9
  733. package/node_modules/@oscharko-dev/keiko-server/dist/store/chats.d.ts.map +1 -1
  734. package/node_modules/@oscharko-dev/keiko-server/dist/store/chats.js +3 -2
  735. package/node_modules/@oscharko-dev/keiko-server/dist/store/codingHistory.d.ts +36 -0
  736. package/node_modules/@oscharko-dev/keiko-server/dist/store/codingHistory.d.ts.map +1 -0
  737. package/node_modules/@oscharko-dev/keiko-server/dist/store/codingHistory.js +191 -0
  738. package/node_modules/@oscharko-dev/keiko-server/dist/store/codingHistoryIsolation.d.ts +5 -0
  739. package/node_modules/@oscharko-dev/keiko-server/dist/store/codingHistoryIsolation.d.ts.map +1 -0
  740. package/node_modules/@oscharko-dev/keiko-server/dist/store/codingHistoryIsolation.js +44 -0
  741. package/node_modules/@oscharko-dev/keiko-server/dist/store/db.d.ts +1 -1
  742. package/node_modules/@oscharko-dev/keiko-server/dist/store/db.d.ts.map +1 -1
  743. package/node_modules/@oscharko-dev/keiko-server/dist/store/db.js +61 -37
  744. package/node_modules/@oscharko-dev/keiko-server/dist/store/journeyOutcomeMigration.d.ts.map +1 -1
  745. package/node_modules/@oscharko-dev/keiko-server/dist/store/journeyOutcomeMigration.js +26 -5
  746. package/node_modules/@oscharko-dev/keiko-server/dist/store/legacySchemaTestFixture.d.ts.map +1 -1
  747. package/node_modules/@oscharko-dev/keiko-server/dist/store/legacySchemaTestFixture.js +9 -1
  748. package/node_modules/@oscharko-dev/keiko-server/dist/store/schema.d.ts +1 -1
  749. package/node_modules/@oscharko-dev/keiko-server/dist/store/schema.d.ts.map +1 -1
  750. package/node_modules/@oscharko-dev/keiko-server/dist/store/schema.js +31 -1
  751. package/node_modules/@oscharko-dev/keiko-server/dist/store/transaction.d.ts +4 -0
  752. package/node_modules/@oscharko-dev/keiko-server/dist/store/transaction.d.ts.map +1 -0
  753. package/node_modules/@oscharko-dev/keiko-server/dist/store/transaction.js +19 -0
  754. package/node_modules/@oscharko-dev/keiko-server/dist/store/types.d.ts +6 -1
  755. package/node_modules/@oscharko-dev/keiko-server/dist/store/types.d.ts.map +1 -1
  756. package/node_modules/@oscharko-dev/keiko-server/dist/store-handlers.d.ts.map +1 -1
  757. package/node_modules/@oscharko-dev/keiko-server/dist/store-handlers.js +34 -8
  758. package/node_modules/@oscharko-dev/keiko-server/dist/task-workspace/activity-log.d.ts.map +1 -1
  759. package/node_modules/@oscharko-dev/keiko-server/dist/task-workspace/activity-log.js +212 -13
  760. package/node_modules/@oscharko-dev/keiko-server/dist/task-workspace/workspace-root-access.d.ts.map +1 -1
  761. package/node_modules/@oscharko-dev/keiko-server/dist/task-workspace/workspace-root-access.js +31 -28
  762. package/node_modules/@oscharko-dev/keiko-server/dist/terminal-routes.d.ts.map +1 -1
  763. package/node_modules/@oscharko-dev/keiko-server/dist/terminal-routes.js +6 -10
  764. package/node_modules/@oscharko-dev/keiko-server/dist/tool-catalog/catalogToolBinder.d.ts.map +1 -1
  765. package/node_modules/@oscharko-dev/keiko-server/dist/tool-catalog/catalogToolBinder.js +18 -9
  766. package/node_modules/@oscharko-dev/keiko-server/dist/tool-catalog/catalogToolFacadeBridge.d.ts.map +1 -1
  767. package/node_modules/@oscharko-dev/keiko-server/dist/tool-catalog/catalogToolFacadeBridge.js +41 -5
  768. package/node_modules/@oscharko-dev/keiko-server/dist/tool-catalog/catalogToolLifecycle.d.ts.map +1 -1
  769. package/node_modules/@oscharko-dev/keiko-server/dist/tool-catalog/catalogToolLifecycle.js +401 -17
  770. package/node_modules/@oscharko-dev/keiko-server/dist/tool-catalog/catalogToolSettlement.d.ts.map +1 -1
  771. package/node_modules/@oscharko-dev/keiko-server/dist/tool-catalog/catalogToolSettlement.js +1 -2
  772. package/node_modules/@oscharko-dev/keiko-server/dist/update-candidate-authority.d.ts +1 -1
  773. package/node_modules/@oscharko-dev/keiko-server/dist/update-candidate-authority.d.ts.map +1 -1
  774. package/node_modules/@oscharko-dev/keiko-server/dist/update-candidate-authority.js +170 -39
  775. package/node_modules/@oscharko-dev/keiko-server/dist/update-legacy-audit-import.d.ts.map +1 -1
  776. package/node_modules/@oscharko-dev/keiko-server/dist/update-legacy-audit-import.js +94 -66
  777. package/node_modules/@oscharko-dev/keiko-server/dist/update-local-state.d.ts +1 -1
  778. package/node_modules/@oscharko-dev/keiko-server/dist/update-local-state.d.ts.map +1 -1
  779. package/node_modules/@oscharko-dev/keiko-server/dist/update-local-state.js +70 -20
  780. package/node_modules/@oscharko-dev/keiko-server/dist/update-portable-normal-startup.d.ts.map +1 -1
  781. package/node_modules/@oscharko-dev/keiko-server/dist/update-portable-normal-startup.js +87 -13
  782. package/node_modules/@oscharko-dev/keiko-server/dist/update-portable-sidecar-verification.d.ts +2 -2
  783. package/node_modules/@oscharko-dev/keiko-server/dist/update-portable-sidecar-verification.d.ts.map +1 -1
  784. package/node_modules/@oscharko-dev/keiko-server/dist/update-portable-sidecar-verification.js +7 -7
  785. package/node_modules/@oscharko-dev/keiko-server/dist/update-portable-staging.d.ts.map +1 -1
  786. package/node_modules/@oscharko-dev/keiko-server/dist/update-portable-staging.js +4 -4
  787. package/node_modules/@oscharko-dev/keiko-server/dist/update-preflight-activity.d.ts +16 -0
  788. package/node_modules/@oscharko-dev/keiko-server/dist/update-preflight-activity.d.ts.map +1 -0
  789. package/node_modules/@oscharko-dev/keiko-server/dist/update-preflight-activity.js +182 -0
  790. package/node_modules/@oscharko-dev/keiko-server/dist/update-preflight-portable-assets.d.ts +1 -1
  791. package/node_modules/@oscharko-dev/keiko-server/dist/update-preflight-portable-assets.d.ts.map +1 -1
  792. package/node_modules/@oscharko-dev/keiko-server/dist/update-preflight-portable-assets.js +5 -15
  793. package/node_modules/@oscharko-dev/keiko-server/dist/update-preflight-portable-evidence.d.ts +1 -1
  794. package/node_modules/@oscharko-dev/keiko-server/dist/update-preflight-portable-evidence.d.ts.map +1 -1
  795. package/node_modules/@oscharko-dev/keiko-server/dist/update-preflight-portable-evidence.js +21 -47
  796. package/node_modules/@oscharko-dev/keiko-server/dist/update-preflight-routes.d.ts +5 -5
  797. package/node_modules/@oscharko-dev/keiko-server/dist/update-preflight-routes.d.ts.map +1 -1
  798. package/node_modules/@oscharko-dev/keiko-server/dist/update-preflight-routes.js +21 -15
  799. package/node_modules/@oscharko-dev/keiko-server/dist/update-runtime-activity.d.ts +39 -0
  800. package/node_modules/@oscharko-dev/keiko-server/dist/update-runtime-activity.d.ts.map +1 -0
  801. package/node_modules/@oscharko-dev/keiko-server/dist/update-runtime-activity.js +266 -0
  802. package/node_modules/@oscharko-dev/keiko-server/dist/update-session.d.ts.map +1 -1
  803. package/node_modules/@oscharko-dev/keiko-server/dist/update-session.js +138 -20
  804. package/node_modules/@oscharko-dev/keiko-server/dist/voice-handlers.d.ts.map +1 -1
  805. package/node_modules/@oscharko-dev/keiko-server/dist/voice-handlers.js +5 -0
  806. package/node_modules/@oscharko-dev/keiko-server/dist/voice-live-dictation.d.ts.map +1 -1
  807. package/node_modules/@oscharko-dev/keiko-server/dist/voice-live-dictation.js +41 -11
  808. package/node_modules/@oscharko-dev/keiko-server/dist/voice-realtime.d.ts.map +1 -1
  809. package/node_modules/@oscharko-dev/keiko-server/dist/voice-realtime.js +70 -17
  810. package/node_modules/@oscharko-dev/keiko-server/dist/workspace-root-denial-log.d.ts +11 -1
  811. package/node_modules/@oscharko-dev/keiko-server/dist/workspace-root-denial-log.d.ts.map +1 -1
  812. package/node_modules/@oscharko-dev/keiko-server/dist/workspace-root-denial-log.js +81 -26
  813. package/node_modules/@oscharko-dev/keiko-server/dist/workspace-script-trust.d.ts +2 -2
  814. package/node_modules/@oscharko-dev/keiko-server/dist/workspace-script-trust.d.ts.map +1 -1
  815. package/node_modules/@oscharko-dev/keiko-server/dist/workspace-script-trust.js +135 -37
  816. package/node_modules/@oscharko-dev/keiko-server/package.json +22 -22
  817. package/node_modules/@oscharko-dev/keiko-tool-catalog/dist/dialect.d.ts.map +1 -1
  818. package/node_modules/@oscharko-dev/keiko-tool-catalog/dist/dialect.js +4 -6
  819. package/node_modules/@oscharko-dev/keiko-tool-catalog/dist/opencode.d.ts +2 -2
  820. package/node_modules/@oscharko-dev/keiko-tool-catalog/dist/opencode.d.ts.map +1 -1
  821. package/node_modules/@oscharko-dev/keiko-tool-catalog/dist/opencode.js +30 -70
  822. package/node_modules/@oscharko-dev/keiko-tool-catalog/dist/profile.d.ts.map +1 -1
  823. package/node_modules/@oscharko-dev/keiko-tool-catalog/dist/profile.js +1 -1
  824. package/node_modules/@oscharko-dev/keiko-tool-catalog/package.json +3 -3
  825. package/node_modules/@oscharko-dev/keiko-tools/dist/version.d.ts +1 -1
  826. package/node_modules/@oscharko-dev/keiko-tools/dist/version.js +1 -1
  827. package/node_modules/@oscharko-dev/keiko-tools/package.json +7 -7
  828. package/node_modules/@oscharko-dev/keiko-verification/dist/dependencies.d.ts +7 -3
  829. package/node_modules/@oscharko-dev/keiko-verification/dist/dependencies.d.ts.map +1 -1
  830. package/node_modules/@oscharko-dev/keiko-verification/dist/dependencies.js +192 -14
  831. package/node_modules/@oscharko-dev/keiko-verification/dist/orchestrator.d.ts +2 -0
  832. package/node_modules/@oscharko-dev/keiko-verification/dist/orchestrator.d.ts.map +1 -1
  833. package/node_modules/@oscharko-dev/keiko-verification/dist/orchestrator.js +6 -2
  834. package/node_modules/@oscharko-dev/keiko-verification/package.json +5 -5
  835. package/node_modules/@oscharko-dev/keiko-workflows/package.json +10 -10
  836. package/node_modules/@oscharko-dev/keiko-workspace/dist/version.d.ts +1 -1
  837. package/node_modules/@oscharko-dev/keiko-workspace/dist/version.js +1 -1
  838. package/node_modules/@oscharko-dev/keiko-workspace/package.json +3 -3
  839. package/package.json +32 -28
  840. package/release-impact.catalog.json +126 -0
  841. package/scripts/lib/local-state-audit.mjs +94 -0
  842. package/vendor/oscharko-dev-keiko-cli-1.1.0.tgz +0 -0
  843. package/vendor/{oscharko-dev-keiko-connectors-1.0.4.tgz → oscharko-dev-keiko-connectors-1.1.0.tgz} +0 -0
  844. package/vendor/oscharko-dev-keiko-contracts-1.1.0.tgz +0 -0
  845. package/vendor/oscharko-dev-keiko-evaluations-1.1.0.tgz +0 -0
  846. package/vendor/{oscharko-dev-keiko-evidence-1.0.4.tgz → oscharko-dev-keiko-evidence-1.1.0.tgz} +0 -0
  847. package/vendor/oscharko-dev-keiko-git-1.1.0.tgz +0 -0
  848. package/vendor/{oscharko-dev-keiko-harness-1.0.4.tgz → oscharko-dev-keiko-harness-1.1.0.tgz} +0 -0
  849. package/vendor/oscharko-dev-keiko-local-knowledge-1.1.0.tgz +0 -0
  850. package/vendor/{oscharko-dev-keiko-memory-capture-1.0.4.tgz → oscharko-dev-keiko-memory-capture-1.1.0.tgz} +0 -0
  851. package/vendor/oscharko-dev-keiko-memory-consolidation-1.1.0.tgz +0 -0
  852. package/vendor/{oscharko-dev-keiko-memory-governance-1.0.4.tgz → oscharko-dev-keiko-memory-governance-1.1.0.tgz} +0 -0
  853. package/vendor/{oscharko-dev-keiko-memory-retrieval-1.0.4.tgz → oscharko-dev-keiko-memory-retrieval-1.1.0.tgz} +0 -0
  854. package/vendor/oscharko-dev-keiko-memory-vault-1.1.0.tgz +0 -0
  855. package/vendor/oscharko-dev-keiko-model-gateway-1.1.0.tgz +0 -0
  856. package/vendor/{oscharko-dev-keiko-quality-intelligence-1.0.4.tgz → oscharko-dev-keiko-quality-intelligence-1.1.0.tgz} +0 -0
  857. package/vendor/oscharko-dev-keiko-sandbox-1.1.0.tgz +0 -0
  858. package/vendor/{oscharko-dev-keiko-sdk-1.0.4.tgz → oscharko-dev-keiko-sdk-1.1.0.tgz} +0 -0
  859. package/vendor/oscharko-dev-keiko-security-1.1.0.tgz +0 -0
  860. package/vendor/oscharko-dev-keiko-server-1.1.0.tgz +0 -0
  861. package/vendor/oscharko-dev-keiko-tool-catalog-1.1.0.tgz +0 -0
  862. package/vendor/{oscharko-dev-keiko-tools-1.0.4.tgz → oscharko-dev-keiko-tools-1.1.0.tgz} +0 -0
  863. package/vendor/oscharko-dev-keiko-verification-1.1.0.tgz +0 -0
  864. package/vendor/{oscharko-dev-keiko-workflows-1.0.4.tgz → oscharko-dev-keiko-workflows-1.1.0.tgz} +0 -0
  865. package/vendor/{oscharko-dev-keiko-workspace-1.0.4.tgz → oscharko-dev-keiko-workspace-1.1.0.tgz} +0 -0
  866. package/dist/ui/static/_next/static/chunks/0-tss9mlvjuz4.js +0 -1
  867. package/dist/ui/static/_next/static/chunks/04lb-38e89aw8.js +0 -1
  868. package/dist/ui/static/_next/static/chunks/04t-d0js_hvfr.js +0 -1
  869. package/dist/ui/static/_next/static/chunks/086jxcgou7s_5.js +0 -1
  870. package/dist/ui/static/_next/static/chunks/08pxrik1lm06d.js +0 -5
  871. package/dist/ui/static/_next/static/chunks/093r62_9c_psx.js +0 -1
  872. package/dist/ui/static/_next/static/chunks/0_u5vd-_66bpj.js +0 -1
  873. package/dist/ui/static/_next/static/chunks/0gsb-naamu9g1.js +0 -1
  874. package/dist/ui/static/_next/static/chunks/0ix9hk8cnb0as.js +0 -1
  875. package/dist/ui/static/_next/static/chunks/0n9uef9g17pxd.js +0 -1
  876. package/dist/ui/static/_next/static/chunks/0o131urxtkbxj.js +0 -1
  877. package/dist/ui/static/_next/static/chunks/0pac-465ukeam.js +0 -1
  878. package/dist/ui/static/_next/static/chunks/0qzzopo8q0m1e.js +0 -1
  879. package/dist/ui/static/_next/static/chunks/0vvfq-eocx502.js +0 -1
  880. package/dist/ui/static/_next/static/chunks/15wh9-75zvro2.js +0 -1
  881. package/dist/ui/static/_next/static/chunks/160x2go4zkjhx.js +0 -1
  882. package/dist/ui/static/_next/static/chunks/17yrtbw7mk5py.css +0 -2
  883. package/dist/ui/static/_next/static/chunks/1kgbe4la7mty5.js +0 -1
  884. package/dist/ui/static/_next/static/chunks/1peg9ve597086.js +0 -1
  885. package/dist/ui/static/_next/static/chunks/1q6j3gd8d86-v.css +0 -2
  886. package/dist/ui/static/_next/static/chunks/1t_6hc_5pxuqd.js +0 -1
  887. package/dist/ui/static/_next/static/chunks/1v4mpk8t6w8_7.js +0 -1
  888. package/dist/ui/static/_next/static/chunks/1yj6x688jjk-a.js +0 -1
  889. package/dist/ui/static/_next/static/chunks/21djhsnzx069x.js +0 -1
  890. package/dist/ui/static/_next/static/chunks/23e-psiwdsaxk.js +0 -1
  891. package/dist/ui/static/_next/static/chunks/289h3-vke8o67.js +0 -1
  892. package/dist/ui/static/_next/static/chunks/2dxo0g3208ag1.js +0 -1
  893. package/dist/ui/static/_next/static/chunks/2jadbwshuwe_n.js +0 -1
  894. package/dist/ui/static/_next/static/chunks/2u9u5i8o6vd-w.js +0 -1
  895. package/dist/ui/static/_next/static/chunks/2vj6gqk9lh7yv.js +0 -1
  896. package/dist/ui/static/_next/static/chunks/3-k1y9vbxcms8.js +0 -3
  897. package/dist/ui/static/_next/static/chunks/3137i2nt475lq.js +0 -1
  898. package/dist/ui/static/_next/static/chunks/3_jzs5uvplshk.js +0 -1
  899. package/dist/ui/static/_next/static/chunks/3d-jscai6hb55.js +0 -1
  900. package/dist/ui/static/_next/static/chunks/3dkw81rui6ry8.js +0 -1
  901. package/dist/ui/static/_next/static/chunks/3f3ici8rsavir.js +0 -1
  902. package/dist/ui/static/_next/static/chunks/3f_-h2lm9ml4b.js +0 -1
  903. package/dist/ui/static/_next/static/chunks/3frfm_q9cqdtg.js +0 -1
  904. package/dist/ui/static/_next/static/chunks/3irz7sn3e2ix3.js +0 -1
  905. package/dist/ui/static/_next/static/chunks/3j1p83q4cv4cv.js +0 -1
  906. package/dist/ui/static/_next/static/chunks/3kgmrssgqwg_h.js +0 -1
  907. package/dist/ui/static/_next/static/chunks/3lc67g1jowxt_.js +0 -1
  908. package/dist/ui/static/_next/static/chunks/3pgmij812w0aa.css +0 -1
  909. package/dist/ui/static/_next/static/chunks/3q3ds5x5j4w7j.js +0 -1
  910. package/dist/ui/static/_next/static/chunks/3r2v5s5l7jkoj.js +0 -1
  911. package/dist/ui/static/_next/static/chunks/3w9c58yrtr4oj.js +0 -1
  912. package/dist/ui/static/_next/static/chunks/3wxm1wke5887n.js +0 -7
  913. package/dist/ui/static/_next/static/chunks/3ymz8bp4uzhhh.js +0 -1
  914. package/vendor/oscharko-dev-keiko-cli-1.0.4.tgz +0 -0
  915. package/vendor/oscharko-dev-keiko-contracts-1.0.4.tgz +0 -0
  916. package/vendor/oscharko-dev-keiko-evaluations-1.0.4.tgz +0 -0
  917. package/vendor/oscharko-dev-keiko-git-1.0.4.tgz +0 -0
  918. package/vendor/oscharko-dev-keiko-local-knowledge-1.0.4.tgz +0 -0
  919. package/vendor/oscharko-dev-keiko-memory-consolidation-1.0.4.tgz +0 -0
  920. package/vendor/oscharko-dev-keiko-memory-vault-1.0.4.tgz +0 -0
  921. package/vendor/oscharko-dev-keiko-model-gateway-1.0.4.tgz +0 -0
  922. package/vendor/oscharko-dev-keiko-sandbox-1.0.4.tgz +0 -0
  923. package/vendor/oscharko-dev-keiko-security-1.0.4.tgz +0 -0
  924. package/vendor/oscharko-dev-keiko-server-1.0.4.tgz +0 -0
  925. package/vendor/oscharko-dev-keiko-tool-catalog-1.0.4.tgz +0 -0
  926. package/vendor/oscharko-dev-keiko-verification-1.0.4.tgz +0 -0
  927. /package/dist/ui/static/_next/static/{t7N9H4GMepHS6cfU2Wj24 → pnaCuBv6v6k-xKyv71Bct}/_buildManifest.js +0 -0
  928. /package/dist/ui/static/_next/static/{t7N9H4GMepHS6cfU2Wj24 → pnaCuBv6v6k-xKyv71Bct}/_clientMiddlewareManifest.js +0 -0
  929. /package/dist/ui/static/_next/static/{t7N9H4GMepHS6cfU2Wj24 → pnaCuBv6v6k-xKyv71Bct}/_ssgManifest.js +0 -0
@@ -3,17 +3,20 @@
3
3
  // existing, hardened pieces into one redacted `.jsonl` bundle: the in-process `AuditResult`
4
4
  // `keiko audit local-state --json` already produces, the evidence-index count from
5
5
  // `listEvidence`, and a verbatim copy of `<state-dir>/logs/server*.log`. `analyze` groups a
6
- // bundle's (or a raw server.log's) lines by correlationId into reconstructed timelines.
6
+ // bundle's (or a raw Activity Log file's) lines by correlationId into reconstructed timelines.
7
7
  //
8
8
  // This file owns argv parsing, stdout/stderr, environment/state-dir resolution, and calling the
9
9
  // audit/evidence subsystems. The exporter's and analyzer's own logic — file discovery, size-budget
10
10
  // selection, manifest assembly, parsing, grouping, ordering, rendering — lives in
11
11
  // ./support-export.ts and ./support-analyze.ts, each independently unit-tested on data, not argv.
12
- import { existsSync, mkdirSync, readFileSync, writeFileSync } from "node:fs";
12
+ import { createHash, randomUUID } from "node:crypto";
13
+ import { closeSync, mkdirSync, openSync, writeFileSync } from "node:fs";
13
14
  import { homedir as defaultHomedir } from "node:os";
14
15
  import { basename, dirname, isAbsolute, join, resolve } from "node:path";
16
+ import { activityLogEvent, defineActivityLogOperation, ACTIVITY_LOG_CATALOG_DIGEST, ACTIVITY_LOG_DIRECTORY_NAME, ACTIVITY_LOG_REGISTRY_VERSION, ACTIVITY_LOG_SCHEMA_DIGEST, DIAGNOSTIC_SUFFICIENCY_REASONS, DIAGNOSTIC_SUFFICIENCY_STATUSES, parseActivityLogFileName, } from "@oscharko-dev/keiko-contracts/runtime/observability";
15
17
  import { KEIKO_PRODUCT_VERSION } from "@oscharko-dev/keiko-contracts/runtime/version";
16
18
  import { emitSecurityLogEvent, securityErrorKind } from "@oscharko-dev/keiko-security";
19
+ import { acknowledgeSafeArtifactFileSet, isSafeArtifactClass, isSafeArtifactFailureKind, openSafeArtifactFile, publishSafeArtifactFileSet, recoverSafeArtifactFileSet, safeArtifactPublicationSlot, } from "@oscharko-dev/keiko-security/fs-hardening";
17
20
  import { AuditLoadError, auditLocalStateResult } from "./audit.js";
18
21
  // KEIKO-0655: shared argv-parsing helper replaces the byte-identical flagValue copy this file held.
19
22
  import { flagValue } from "./cli-arg-parsing.js";
@@ -27,45 +30,67 @@ import { installLayoutOverrideEvidence, writeInstallLayoutOverrideEvidenceWithFa
27
30
  import { loadEvidence, loadServer, loadToolLifecycle } from "./lazy-modules.js";
28
31
  import { createCliSecurityLogSink } from "./security-log.js";
29
32
  import { inspectStateRoot, resolveStateDir } from "./state-paths.js";
30
- import { analyzeLogText, buildReproductionSeed, findTimeline, hasIssueToPrJourneyOps, renderGatewayReplayScriptFixture, renderHumanAllTimelines, renderHumanClusters, renderHumanReproductionSeed, renderHumanTimeline, } from "./support-analyze.js";
31
- import { buildConfigSnapshotSection, buildEvidenceManifestSection, buildSupportBundleManifest, buildUiLogSection, bundleSha256Hex, bundleText, DEFAULT_MAX_BUNDLE_BYTES, describeErrorKind, discoverServerLogFiles, readKeptFiles, selectLogFilesWithinBudget, serializeBundleLines, sha256SidecarPath, UI_LOG_FILE_NAME, UI_LOG_SECTION, } from "./support-export.js";
33
+ import { ACTIVITY_LOG_EVIDENCE_INTEGRITY, analyzeLogLines, buildReproductionSeedFromAnalysis, findTimeline, hasIssueToPrJourneyOps, renderGatewayReplayScriptFixture, renderHumanAllTimelines, renderHumanClusters, renderHumanReproductionSeed, renderHumanTimeline, timelineSufficiency, } from "./support-analyze.js";
34
+ import { ActivityLogReadError, readActivityLogFileLines } from "./activity-log-line-reader.js";
35
+ import { runSupportIncidentCli } from "./support-incident.js";
36
+ import { parseSupportManifestArgs, parseSupportQueryArgs, runSupportManifestCli, runSupportQueryCli, SUPPORT_QUERY_USAGE, } from "./support-query-cli.js";
37
+ import { collectSelectedLogContent, parseSupportExportSelector, } from "./support-selective-export.js";
38
+ import { buildConfigSnapshotSection, buildEvidenceManifestSection, buildSupportBundleManifest, bundleSha256Hex, bundleText, DEFAULT_MAX_BUNDLE_BYTES, describeErrorKind, discoverServerLogFiles, readKeptFiles, selectLogFilesWithinBudget, serializeBundleLines, sha256SidecarPath, UI_LOG_SECTION, } from "./support-export.js";
32
39
  const USAGE = `Usage:
33
40
  keiko support export [--out PATH] [--state-dir PATH] [--max-bytes N]
34
- [--include-ui-log --i-understand-this-is-unredacted]
35
41
  [--include-evidence RUNID[,RUNID...]]
42
+ [--incident ID | --correlation-id ID | --defect-fingerprint SHA256]
36
43
  keiko support analyze FILE [--correlation-id ID] [--json] [--clusters]
37
44
  [--seed] [--emit-fixture PATH]
45
+ keiko support incident list|show|preview|report|dismiss [ID] [--state-dir PATH] [--json]
46
+ keiko support query ... and keiko support manifest rebuild|verify (keiko support query --help)
38
47
 
39
48
  export writes a redacted .jsonl support bundle: a manifest line (local-state audit summary,
40
49
  evidence-index count, exactly which log files were copied, and a redacted schema/integrity
41
50
  fingerprint for each of the ui, local-knowledge, and memory-vault stores found under --state-dir),
42
51
  an always-present config-snapshot section (Keiko's own resolved KEIKO_* runtime configuration,
43
- redacted), then every line of <state-dir>/logs/server*.log, copied byte-for-byte. A store that has
52
+ redacted), then every line of the Activity Log under <state-dir>/logs/ (its sealed and active
53
+ segments plus any legacy server*.log files, oldest first), copied byte-for-byte. A store that has
44
54
  never been used from this state dir, or that cannot be opened (corrupt, or a vault key the
45
55
  operator has not supplied), is named in the manifest's storesUnavailable instead of failing the
46
56
  export. Default --out is ./keiko-support-<timestamp>.jsonl (colons replaced with '-'); default
47
57
  --max-bytes is 50MB — the oldest log files are dropped first when the cap would be exceeded, and
48
- always named in the manifest's truncatedLogFiles. The current log file is never dropped; if it
58
+ always named in the manifest's truncatedLogFiles. The newest log file is never dropped; if it
49
59
  alone still exceeds the cap, only its tail is exported instead, named in the manifest's
50
- currentFileTailTruncated. A <output>.sha256 sidecar carries a SHA-256 digest of the bundle's bytes.
60
+ currentFileTailTruncated. sourceLogFileLines records each copied file's line count and whether it
61
+ ended in a torn line, so analyze reports such a tail as truncated rather than corrupt.
62
+ With --incident, --correlation-id or --defect-fingerprint the report is selective: it carries only
63
+ that selection's registered causal closure plus a narrow process context, copied verbatim, and the
64
+ manifest's selection member states its versioned diagnostic sufficiency. A selection that does not
65
+ fit --max-bytes or cannot be found is never cut: nothing is written and the command exits 1.
66
+ A <output>.sha256 sidecar carries a SHA-256 digest of the bundle's bytes.
67
+ Publication exclusively creates the report and sidecar and never replaces an existing destination.
68
+ If a process stops mid-publication, rerun the same explicit --out command; for the default output,
69
+ rerun from the same working directory. Keiko recovers the durable prior bytes before taking a new
70
+ clock or log snapshot, or fails closed when the bounded recovery slot conflicts.
51
71
 
52
- <state-dir>/ui.log (the UI/BFF process's raw, unredacted stdout+stderr) is excluded by default and
53
- always named in the manifest's sectionsExcluded — attaching it requires BOTH --include-ui-log AND
54
- --i-understand-this-is-unredacted; either flag alone still excludes it. --include-evidence attaches
55
- the FULL EvidenceStore manifest for each listed runId (beyond the index-only summary above) for
56
- deep replay; a runId that does not exist under --state-dir contributes no section.
72
+ A legacy <state-dir>/ui.log (raw UI process output written by earlier versions) is never read into
73
+ a report and is always named in the manifest's sectionsExcluded; every diagnostic the UI process
74
+ produces is an Activity Log line. --include-evidence attaches the FULL EvidenceStore manifest for
75
+ each listed runId (beyond the index-only summary above) for deep replay; a runId that does not
76
+ exist under --state-dir contributes no section. After a successful export the command reports the
77
+ state directory's diagnostic readiness (ready, degraded or unavailable, with closed reasons).
57
78
 
58
- analyze reads FILE (a support bundle or a raw server.log — auto-detected), groups its lines by
59
- correlationId, and prints one reconstructed timeline per id. Each process lifetime is ordered by
60
- seq; lifetimes are ordered by the position of their first line in the file, because the log
61
- envelope promises no order across processes. The default and per-correlation reports identify the
62
- resolved input file, an inferable raw-log state directory, newest valid event and instance, and
63
- whether the raw log is current and apparently active. A raw log more than five minutes behind the
64
- analysis clock is reported as stale; bundles are historical artifacts and are never presented as
65
- live processes.
79
+ analyze reads FILE (a support bundle or one raw Activity Log file — auto-detected), groups its
80
+ lines by correlationId, and prints one reconstructed timeline per id.
81
+ Each process lifetime is ordered by seq; lifetimes are ordered by the position of their first line
82
+ in the file, because the log envelope promises no order across processes. The default and
83
+ per-correlation reports identify the resolved input file, an inferable raw-log state directory,
84
+ newest valid event and instance, and whether the raw log is current and apparently active. A raw
85
+ log more than five minutes behind the analysis clock is reported as stale; bundles are historical
86
+ artifacts and are never presented as live processes.
66
87
  --correlation-id narrows to a single id; --json emits the machine-readable form. --clusters prints
67
88
  a whole-file view of every parsed line grouped by (category, op, errorKind), independent of
68
- --correlation-id: a count and up to 5 sample correlation ids per group. --seed (requires
89
+ --correlation-id: a count and up to 5 sample correlation ids per group. --clusters --json is a
90
+ deprecated, unversioned bare array kept byte-compatible for existing readers; it prints a one-line
91
+ stderr deprecation notice on every use naming its versioned replacement, the clusters member of
92
+ plain --json (kind keiko.support.analyze, schemaVersion 1), which carries the same data inside a
93
+ versioned envelope. --seed (requires
69
94
  --correlation-id) prints a ReproductionSeed — a gatewayScript/httpRequest/storeFingerprint/
70
95
  indexingJob/issueToPrJourney/stackFrames/causeChain reconstruction for that one correlationId, plus
71
96
  a warnings field naming exactly what could not be reconstructed and why. --emit-fixture PATH (requires
@@ -73,7 +98,31 @@ a warnings field naming exactly what could not be reconstructed and why. --emit-
73
98
  from that seed's gatewayScript, to PATH — refusing to overwrite an existing file and creating
74
99
  parent directories as needed. --seed and --emit-fixture may be combined in one invocation.
75
100
  `;
76
- function emitSupportInstallLayoutRefusal(context, errorKind, reason) {
101
+ const CLI_SUPPORT_EXPORT_FAILED_OPERATION = defineActivityLogOperation({
102
+ contractKind: "activity-log-operation",
103
+ schemaVersion: 1,
104
+ op: "cli.support.export.failed",
105
+ category: "diagnostic",
106
+ owner: "keiko-cli",
107
+ emitter: "support.emitSupportInstallLayoutRefusal",
108
+ fields: {
109
+ reason: {
110
+ type: "string",
111
+ dataClass: "closed-enum",
112
+ required: true,
113
+ values: ["unsafe-state-root", "activity-log-unavailable", "state-root-validation-failed"],
114
+ },
115
+ targetSha256: { type: "string", dataClass: "digest", required: true, maxLength: 64 },
116
+ failureKind: { type: "string", dataClass: "error-kind", required: true, maxLength: 64 },
117
+ },
118
+ causal: "correlation",
119
+ lifecycle: "failure",
120
+ analyzerProjection: "failure-cluster",
121
+ failureClasses: ["cli-support-export"],
122
+ proofIds: ["cli.support.export.failed.install-layout-refusal"],
123
+ releaseImpact: "patch",
124
+ });
125
+ function emitSupportInstallLayoutRefusal(context, failureKind, reason) {
77
126
  try {
78
127
  if (cliControlStateConflictsWithTarget(context.controlStateDir, context.stateDir))
79
128
  return;
@@ -82,16 +131,18 @@ function emitSupportInstallLayoutRefusal(context, errorKind, reason) {
82
131
  return;
83
132
  }
84
133
  const sink = createCliSecurityLogSink(context.controlStateDir, context.factory, context.correlationId);
85
- emitSecurityLogEvent(sink, {
134
+ emitSecurityLogEvent(sink, activityLogEvent(CLI_SUPPORT_EXPORT_FAILED_OPERATION, {
86
135
  level: "error",
87
- category: "diagnostic",
88
- op: "cli.support.export.failed",
89
- errorKind,
90
- extra: { reason, targetSha256: cliTargetIdentitySha256(context.stateDir) },
91
- });
136
+ correlationId: context.correlationId,
137
+ errorKind: reason === "unsafe-state-root" ? "unsafe-target" : "unavailable",
138
+ }, {
139
+ reason,
140
+ targetSha256: cliTargetIdentitySha256(context.stateDir),
141
+ failureKind,
142
+ }));
92
143
  }
93
- function refuseSupportInstallLayout(context, errorKind, reason) {
94
- emitSupportInstallLayoutRefusal(context, errorKind, reason);
144
+ function refuseSupportInstallLayout(context, failureKind, reason) {
145
+ emitSupportInstallLayoutRefusal(context, failureKind, reason);
95
146
  return "refused";
96
147
  }
97
148
  function writeSupportInstallLayoutEvidence(stateDir, env, deps) {
@@ -130,7 +181,12 @@ function prepareSupportInstallLayoutEvidence(stateDir, env, deps, io) {
130
181
  return false;
131
182
  }
132
183
  const SUPPORT_LOG_STALE_AFTER_MS = 5 * 60_000;
133
- const SERVER_LOG_FILE_PATTERN = /^server(?:-\d{4}-\d{2}-\d{2})?\.log$/;
184
+ // The flags that once attached the raw `ui.log` (#3532). They are refused explicitly rather than
185
+ // ignored, so an operator who still passes them learns that no report can carry raw UI output.
186
+ const RETIRED_UI_LOG_FLAGS = [
187
+ "--include-ui-log",
188
+ "--i-understand-this-is-unredacted",
189
+ ];
134
190
  function parsePositiveInteger(value) {
135
191
  if (!/^\d+$/.test(value))
136
192
  return undefined;
@@ -148,9 +204,22 @@ function parseIncludeEvidenceIds(raw) {
148
204
  .map((id) => id.trim())
149
205
  .filter((id) => id.length > 0);
150
206
  }
151
- function parseExportArgs(args) {
207
+ // The answers that need no flag parsing: help, and the refusal of a retired ui.log flag.
208
+ function exportArgsEarlyResult(args) {
152
209
  if (args.includes("--help") || args.includes("-h"))
153
210
  return { kind: "help" };
211
+ if (!RETIRED_UI_LOG_FLAGS.some((flag) => args.includes(flag)))
212
+ return undefined;
213
+ return {
214
+ kind: "usage",
215
+ message: "keiko support export: --include-ui-log is no longer supported; raw UI output is never " +
216
+ `part of a support report. Every UI diagnostic is in the Activity Log.\n${USAGE}`,
217
+ };
218
+ }
219
+ function parseExportArgs(args) {
220
+ const early = exportArgsEarlyResult(args);
221
+ if (early !== undefined)
222
+ return early;
154
223
  const out = flagValue(args, "--out");
155
224
  const stateDir = flagValue(args, "--state-dir");
156
225
  const maxBytesRaw = flagValue(args, "--max-bytes");
@@ -168,15 +237,18 @@ function parseExportArgs(args) {
168
237
  message: `keiko support export: --max-bytes must be a positive integer.\n${USAGE}`,
169
238
  };
170
239
  }
240
+ const selection = parseSupportExportSelector(args);
241
+ if (selection.kind === "usage") {
242
+ return { kind: "usage", message: `keiko support export: ${selection.message}\n${USAGE}` };
243
+ }
171
244
  return {
172
245
  kind: "ok",
173
246
  value: {
174
247
  out,
175
248
  stateDir,
176
249
  maxBytes,
177
- includeUiLog: args.includes("--include-ui-log"),
178
- iUnderstandUnredacted: args.includes("--i-understand-this-is-unredacted"),
179
250
  includeEvidenceRunIds: parseIncludeEvidenceIds(includeEvidenceRaw),
251
+ selector: selection.selector,
180
252
  },
181
253
  };
182
254
  }
@@ -237,6 +309,23 @@ export function parseSupportArgs(args) {
237
309
  const parsed = parseAnalyzeArgs(rest);
238
310
  return parsed.kind === "ok" ? { kind: "analyze", value: parsed.value } : parsed;
239
311
  }
312
+ if (subcommand === "incident")
313
+ return { kind: "incident", args: rest };
314
+ return parseQuerySubcommand(subcommand, rest);
315
+ }
316
+ function parseQuerySubcommand(subcommand, rest) {
317
+ if (subcommand === "query") {
318
+ const parsed = parseSupportQueryArgs(rest);
319
+ if (parsed.kind === "help")
320
+ return { kind: "query-help" };
321
+ return parsed.kind === "ok" ? { kind: "query", value: parsed.value } : parsed;
322
+ }
323
+ if (subcommand === "manifest") {
324
+ const parsed = parseSupportManifestArgs(rest);
325
+ if (parsed.kind === "help")
326
+ return { kind: "query-help" };
327
+ return parsed.kind === "ok" ? { kind: "manifest", value: parsed.value } : parsed;
328
+ }
240
329
  return { kind: "usage", message: `keiko support: unknown subcommand: ${subcommand}\n${USAGE}` };
241
330
  }
242
331
  function resolveStateDirSource(env, stateDirArg) {
@@ -246,10 +335,17 @@ function resolveStateDirSource(env, stateDirArg) {
246
335
  function defaultOutFileName(generatedAt) {
247
336
  return `keiko-support-${generatedAt.toISOString().replaceAll(":", "-")}.jsonl`;
248
337
  }
249
- function resolveOutPath(cwd, outArg, generatedAt) {
338
+ export function resolveOutPath(cwd, outArg, generatedAt) {
250
339
  const value = outArg ?? defaultOutFileName(generatedAt);
251
340
  return isAbsolute(value) ? value : resolve(cwd, value);
252
341
  }
342
+ // Nothing but the Activity Log store may create files in its directory: a report written there could
343
+ // take a segment's name, and retention owns every closed-grammar name in it.
344
+ function supportDestinationCollidesWithActivityLog(cwd, stateDir, outArg) {
345
+ if (outArg === undefined)
346
+ return false;
347
+ return dirname(resolve(cwd, outArg)) === resolve(stateDir, ACTIVITY_LOG_DIRECTORY_NAME);
348
+ }
253
349
  // Never throws: a missing or unreadable evidence directory means zero evidence to report, never a
254
350
  // failed export (the manifest field is a count, not a listing, so there is nothing sensitive to
255
351
  // lose by reporting zero).
@@ -282,11 +378,12 @@ function resolveExportInstallMode(server) {
282
378
  }
283
379
  }
284
380
  // Discovers, budget-selects, and reads the state dir's server*.log files in one pass, tolerating
285
- // the sink's own rotation/retention pruning at both boundaries it can race
286
- // (support-export.ts's `discoverServerLogFiles`, between `readdirSync` and `statSync`, and
381
+ // concurrent removal of the current file or a compatible legacy archive at both boundaries
382
+ // (support-export.ts's `discoverServerLogFiles`, between `readdirSync` and the verified open, and
287
383
  // `readKeptFiles`, between selection and the actual read): `sourceLogFiles` names only the files
288
- // that actually contributed content; `skippedLogFiles` names every file that vanished at either
289
- // boundary, by name only, never by its absolute path. `budgetExceeded` and
384
+ // that actually contributed content; `skippedLogFiles` names every file that vanished or was
385
+ // refused (a link or non-regular entry) at either boundary, by name only, never by its absolute
386
+ // path. `budgetExceeded` and
290
387
  // `currentFileTailTruncated` come from `readKeptFiles`, not `selection`: only the read step knows
291
388
  // whether a tail read of the current file actually managed to keep a complete line, which is what
292
389
  // decides whether the size budget was, in the end, honoured.
@@ -300,34 +397,433 @@ function collectLogContent(logsDir, maxBytes) {
300
397
  .filter((name) => !readSkipped.has(name));
301
398
  return {
302
399
  contentLines: read.contentLines,
400
+ terminalFragment: read.terminalFragment,
303
401
  sourceLogFiles,
402
+ sourceLogFileLines: read.sourceLogFileLines,
304
403
  truncatedLogFiles: selection.truncatedLogFiles,
305
404
  currentFileTailTruncated: read.currentFileTailTruncated,
306
405
  budgetExceeded: read.budgetExceeded,
307
406
  skippedLogFiles: [...discovery.skippedLogFiles, ...read.skippedLogFiles],
308
407
  };
309
408
  }
310
- // Content-free, same discipline as readAnalyzeSource: an fs error's message can quote the path it
311
- // was writing (AGENTS.md §7). Reports `describeErrorKind`'s result — the fs error's own `code`
312
- // (ENOENT/EACCES/EROFS) when it has one, since a Node fs error is always a plain `Error` and
313
- // `error.constructor.name` is therefore always just `"Error"`, telling an operator nothing the
314
- // generic prefix didn't already say. Returns undefined on success, an exit code on failure.
315
- // Also writes the `<output>.sha256` sidecar (design doc §6.2's closing addendum): a cheap
316
- // integrity story for an artifact that crosses a customer-machine-to-agent trust boundary, computed
317
- // over the EXACT bytes just written to `outPath`. A failure writing either file reports the same
318
- // content-free outcome and writes neither half — a bundle without its sidecar, or a sidecar for
319
- // bytes that were never actually persisted, are both worse than refusing the export.
320
- function writeBundleOrExitCode(outPath, contents, io) {
409
+ function safeArtifactFailureRecord(error) {
410
+ if (typeof error !== "object" || error === null)
411
+ return undefined;
412
+ const artifactClass = Reflect.get(error, "artifactClass");
413
+ const kind = Reflect.get(error, "kind");
414
+ if (!isSafeArtifactClass(artifactClass) || !isSafeArtifactFailureKind(kind))
415
+ return undefined;
416
+ return { artifactClass, kind };
417
+ }
418
+ export function supportPublicationErrorKind(error) {
419
+ try {
420
+ return safeArtifactFailureRecord(error)?.kind ?? "unknown";
421
+ }
422
+ catch {
423
+ return "unknown";
424
+ }
425
+ }
426
+ function supportPublicationFailure(error) {
427
+ try {
428
+ const failure = safeArtifactFailureRecord(error);
429
+ if (failure !== undefined) {
430
+ const failedArtifactClass = failure.artifactClass === "integrity-artifact" || failure.artifactClass === "manifest"
431
+ ? failure.artifactClass
432
+ : "support-report";
433
+ return { errorKind: failure.kind, failedArtifactClass };
434
+ }
435
+ }
436
+ catch {
437
+ return { errorKind: "unknown", failedArtifactClass: "support-report" };
438
+ }
439
+ return { errorKind: "unknown", failedArtifactClass: "support-report" };
440
+ }
441
+ export function supportPublicationContext(cwd, outArg) {
442
+ const explicitPath = outArg === undefined ? undefined : resolve(cwd, outArg);
443
+ const root = explicitPath === undefined ? resolve(cwd) : dirname(explicitPath);
444
+ const namespace = explicitPath === undefined ? "support-export/default" : "support-export/explicit";
445
+ return { root, slot: safeArtifactPublicationSlot(namespace, explicitPath ?? root) };
446
+ }
447
+ function publishSupportBundle(outPath, contents, io, context, recoveryState) {
448
+ const reportSha256 = bundleSha256Hex(contents);
449
+ try {
450
+ const result = publishSafeArtifactFileSet([
451
+ { path: outPath, contents, artifactClass: "support-report" },
452
+ {
453
+ path: sha256SidecarPath(outPath),
454
+ contents: `${reportSha256}\n`,
455
+ artifactClass: "integrity-artifact",
456
+ },
457
+ ], {
458
+ commitPath: outPath,
459
+ publicationSlot: context.slot,
460
+ trustedRoot: context.root,
461
+ });
462
+ return {
463
+ status: "published",
464
+ result,
465
+ reportBytes: Buffer.byteLength(contents),
466
+ reportSha256,
467
+ recoveryState,
468
+ };
469
+ }
470
+ catch (error) {
471
+ const failure = supportPublicationFailure(error);
472
+ const { errorKind } = failure;
473
+ io.err(`keiko support export: could not write the bundle: ${errorKind}\n`);
474
+ return { status: "failed", ...failure, recoveryState };
475
+ }
476
+ }
477
+ function recoverSupportBundle(context, io) {
478
+ try {
479
+ const result = recoverSafeArtifactFileSet({
480
+ publicationSlot: context.slot,
481
+ trustedRoot: context.root,
482
+ });
483
+ if (result.status === "rolled-back") {
484
+ return { status: "rolled-back", recoveryState: "rolled-back" };
485
+ }
486
+ if (result.status !== "recovered")
487
+ return { status: "none" };
488
+ return {
489
+ status: "recovered",
490
+ result,
491
+ reportBytes: result.commitByteCount,
492
+ reportSha256: result.commitSha256,
493
+ recoveryState: "recovered",
494
+ };
495
+ }
496
+ catch (error) {
497
+ const failure = supportPublicationFailure(error);
498
+ const { errorKind } = failure;
499
+ io.err(`keiko support export: could not recover the prior publication: ${errorKind}\n`);
500
+ return { status: "failed", ...failure, recoveryState: "conflict" };
501
+ }
502
+ }
503
+ function acknowledgeSupportPublication(context, io) {
321
504
  try {
322
- writeFileSync(outPath, contents, "utf8");
323
- writeFileSync(sha256SidecarPath(outPath), `${bundleSha256Hex(contents)}\n`, "utf8");
505
+ acknowledgeSafeArtifactFileSet({
506
+ publicationSlot: context.slot,
507
+ trustedRoot: context.root,
508
+ });
324
509
  return undefined;
325
510
  }
326
511
  catch (error) {
327
- io.err(`keiko support export: could not write the bundle: ${describeErrorKind(error)}\n`);
328
- return 1;
512
+ const errorKind = supportPublicationErrorKind(error);
513
+ io.err(`keiko support export: could not acknowledge publication: ${errorKind}\n`);
514
+ return errorKind;
515
+ }
516
+ }
517
+ const SUPPORT_EXPORT_PUBLICATION_OPERATION = defineActivityLogOperation({
518
+ contractKind: "activity-log-operation",
519
+ schemaVersion: 1,
520
+ op: "support.export.publication",
521
+ category: "diagnostic",
522
+ owner: "keiko-cli",
523
+ emitter: "support.emitSupportPublicationEvidence",
524
+ fields: {
525
+ publicationArtifactClass: {
526
+ type: "string",
527
+ dataClass: "closed-enum",
528
+ required: true,
529
+ values: ["support-report"],
530
+ },
531
+ artifactCount: { type: "integer", dataClass: "count", required: true },
532
+ visibleArtifactCount: { type: "integer", dataClass: "count", required: false },
533
+ persistenceStatus: {
534
+ type: "string",
535
+ dataClass: "closed-enum",
536
+ required: true,
537
+ values: ["published", "recovered", "rolled-back", "acknowledgement-failed", "failed"],
538
+ },
539
+ publicationPersistenceStatus: {
540
+ type: "string",
541
+ dataClass: "closed-enum",
542
+ required: true,
543
+ values: ["published", "recovered", "rolled-back", "acknowledgement-failed", "failed"],
544
+ },
545
+ completeness: { type: "string", dataClass: "completeness-state", required: true },
546
+ publicationCompleteness: {
547
+ type: "string",
548
+ dataClass: "completeness-state",
549
+ required: true,
550
+ },
551
+ loss: { type: "string", dataClass: "loss-state", required: true },
552
+ publicationLoss: { type: "string", dataClass: "loss-state", required: true },
553
+ recoveryState: {
554
+ type: "string",
555
+ dataClass: "closed-enum",
556
+ required: true,
557
+ values: ["none", "rolled-back", "recovered", "conflict"],
558
+ },
559
+ publicationStatus: {
560
+ type: "string",
561
+ dataClass: "closed-enum",
562
+ required: false,
563
+ values: ["published", "recovered"],
564
+ },
565
+ permissionAssurance: {
566
+ type: "string",
567
+ dataClass: "closed-enum",
568
+ required: false,
569
+ values: ["verified-private", "platform-inherited"],
570
+ },
571
+ durabilityAssurance: {
572
+ type: "string",
573
+ dataClass: "closed-enum",
574
+ required: false,
575
+ values: ["verified", "directory-sync-unavailable"],
576
+ },
577
+ reportBytes: { type: "integer", dataClass: "count", required: false },
578
+ reportSha256: {
579
+ type: "string",
580
+ dataClass: "digest",
581
+ required: false,
582
+ maxLength: 64,
583
+ },
584
+ receiptState: {
585
+ type: "string",
586
+ dataClass: "closed-enum",
587
+ required: true,
588
+ values: ["consumed", "acknowledgement-uncertain", "unknown"],
589
+ },
590
+ failedArtifactClass: {
591
+ type: "string",
592
+ dataClass: "closed-enum",
593
+ required: false,
594
+ values: ["support-report", "integrity-artifact", "manifest"],
595
+ },
596
+ failureKind: {
597
+ type: "string",
598
+ dataClass: "closed-enum",
599
+ required: false,
600
+ values: [
601
+ "invalid-publication",
602
+ "close-failed",
603
+ "durability-failed",
604
+ "open-failed",
605
+ "permission-failed",
606
+ "permission-unsafe",
607
+ "publish-failed",
608
+ "publish-unsupported",
609
+ "read-failed",
610
+ "recovery-conflict",
611
+ "replace-failed",
612
+ "target-exists",
613
+ "target-mutated",
614
+ "unsafe-ancestor",
615
+ "unsafe-target",
616
+ "write-failed",
617
+ "unknown",
618
+ ],
619
+ },
620
+ },
621
+ causal: "correlation",
622
+ lifecycle: "end",
623
+ analyzerProjection: "capability",
624
+ failureClasses: ["support-publication", "support-publication-acknowledgement"],
625
+ proofIds: [
626
+ "support.export.publication.publication-evidence",
627
+ "support.export.publication.commit-last",
628
+ ],
629
+ releaseImpact: "patch",
630
+ });
631
+ const SUPPORT_ANALYZE_CLASSIFICATION_OPERATION = defineActivityLogOperation({
632
+ contractKind: "activity-log-operation",
633
+ schemaVersion: 1,
634
+ op: "support.analyze.classified",
635
+ category: "diagnostic",
636
+ owner: "keiko-cli",
637
+ emitter: "support.emitSupportAnalysisEvidence",
638
+ fields: {
639
+ sourceKind: {
640
+ type: "string",
641
+ dataClass: "closed-enum",
642
+ required: true,
643
+ values: ["bundle", "raw-log"],
644
+ },
645
+ evidenceClassification: {
646
+ type: "string",
647
+ dataClass: "closed-enum",
648
+ required: true,
649
+ values: ["supported", "legacy", "unsupported", "corrupt", "truncated", "incomplete"],
650
+ },
651
+ supportedLineCount: { type: "integer", dataClass: "count", required: true },
652
+ legacyLineCount: { type: "integer", dataClass: "count", required: true },
653
+ unsupportedLineCount: { type: "integer", dataClass: "count", required: true },
654
+ corruptLineCount: { type: "integer", dataClass: "count", required: true },
655
+ truncatedLineCount: { type: "integer", dataClass: "count", required: true },
656
+ incompleteLineCount: { type: "integer", dataClass: "count", required: true },
657
+ sequenceAnomalyCount: { type: "integer", dataClass: "count", required: true },
658
+ malformedLineCount: { type: "integer", dataClass: "count", required: true },
659
+ // #3532: the per-failure-class sufficiency projection of the analyzed artifact.
660
+ sufficiency: {
661
+ type: "string",
662
+ dataClass: "closed-enum",
663
+ required: true,
664
+ values: [...DIAGNOSTIC_SUFFICIENCY_STATUSES],
665
+ },
666
+ sufficiencyReasons: {
667
+ type: "string-array",
668
+ dataClass: "closed-enum",
669
+ required: false,
670
+ maxItems: 17,
671
+ values: [...DIAGNOSTIC_SUFFICIENCY_REASONS],
672
+ },
673
+ completeClassCount: { type: "integer", dataClass: "count", required: true },
674
+ degradedClassCount: { type: "integer", dataClass: "count", required: true },
675
+ insufficientClassCount: { type: "integer", dataClass: "count", required: true },
676
+ completeness: { type: "string", dataClass: "completeness-state", required: true },
677
+ loss: { type: "string", dataClass: "loss-state", required: true },
678
+ },
679
+ causal: "correlation",
680
+ lifecycle: "end",
681
+ analyzerProjection: "capability",
682
+ failureClasses: ["support-analysis"],
683
+ proofIds: ["support.analyze.classified.classification-evidence"],
684
+ releaseImpact: "patch",
685
+ });
686
+ function completedPublicationEvidenceFields(publication, persistenceStatus, receiptState) {
687
+ return {
688
+ publicationArtifactClass: "support-report",
689
+ artifactCount: 2,
690
+ visibleArtifactCount: 2,
691
+ persistenceStatus,
692
+ publicationPersistenceStatus: persistenceStatus,
693
+ completeness: "complete",
694
+ publicationCompleteness: "complete",
695
+ loss: "none",
696
+ publicationLoss: "none",
697
+ recoveryState: publication.recoveryState,
698
+ publicationStatus: publication.result.status,
699
+ permissionAssurance: publication.result.permissionAssurance,
700
+ durabilityAssurance: publication.result.durabilityAssurance,
701
+ reportBytes: publication.reportBytes,
702
+ reportSha256: publication.reportSha256,
703
+ receiptState,
704
+ };
705
+ }
706
+ function failedPublicationEvidenceFields(outcome) {
707
+ return {
708
+ publicationArtifactClass: "support-report",
709
+ artifactCount: 2,
710
+ persistenceStatus: "failed",
711
+ publicationPersistenceStatus: "failed",
712
+ completeness: "unknown",
713
+ publicationCompleteness: "unknown",
714
+ loss: "publication-unavailable",
715
+ publicationLoss: "publication-unavailable",
716
+ recoveryState: outcome.recoveryState,
717
+ receiptState: "unknown",
718
+ failedArtifactClass: outcome.failedArtifactClass,
719
+ failureKind: outcome.errorKind,
720
+ };
721
+ }
722
+ function supportPublicationActivityErrorKind(failure) {
723
+ switch (failure) {
724
+ case "invalid-publication":
725
+ return "validation-failed";
726
+ case "permission-failed":
727
+ return "permission-denied";
728
+ case "permission-unsafe":
729
+ case "unsafe-ancestor":
730
+ return "unsafe-target";
731
+ case "publish-failed":
732
+ case "replace-failed":
733
+ return "write-failed";
734
+ case "recovery-conflict":
735
+ return "conflict";
736
+ case "close-failed":
737
+ return "durability-failed";
738
+ default:
739
+ return failure;
740
+ }
741
+ }
742
+ function emitSupportPublicationEvidence(server, stateDir, correlationId, outcome) {
743
+ const activityLog = server.createFileServerLogSink(stateDir);
744
+ try {
745
+ if (outcome.status === "rolled-back") {
746
+ writeRolledBackRecovery(activityLog, correlationId, outcome);
747
+ return;
748
+ }
749
+ if (outcome.status === "acknowledgement-failed") {
750
+ writeAcknowledgementFailure(activityLog, correlationId, outcome);
751
+ return;
752
+ }
753
+ if (outcome.status !== "failed") {
754
+ writeCompletedPublication(activityLog, correlationId, outcome);
755
+ return;
756
+ }
757
+ writeFailedPublication(activityLog, correlationId, outcome);
758
+ }
759
+ finally {
760
+ activityLog.close?.();
761
+ }
762
+ }
763
+ function emitSupportAnalysisEvidence(server, stateDir, result) {
764
+ const activityLog = server.createFileServerLogSink(stateDir);
765
+ try {
766
+ activityLog.write(activityLogEvent(SUPPORT_ANALYZE_CLASSIFICATION_OPERATION, { correlationId: randomUUID() }, {
767
+ sourceKind: result.sourceKind,
768
+ evidenceClassification: result.evidence.classification,
769
+ supportedLineCount: result.evidence.supportedLineCount,
770
+ legacyLineCount: result.evidence.legacyLineCount,
771
+ unsupportedLineCount: result.evidence.unsupportedLineCount,
772
+ corruptLineCount: result.evidence.corruptLineCount,
773
+ truncatedLineCount: result.evidence.truncatedLineCount,
774
+ incompleteLineCount: result.evidence.incompleteLineCount,
775
+ sequenceAnomalyCount: result.evidence.sequenceAnomalies.length,
776
+ malformedLineCount: result.malformedLineCount,
777
+ sufficiency: result.sufficiency.status,
778
+ ...(result.sufficiency.reasons.length === 0
779
+ ? {}
780
+ : { sufficiencyReasons: result.sufficiency.reasons }),
781
+ completeClassCount: result.sufficiency.coverage.completeClassCount,
782
+ degradedClassCount: result.sufficiency.coverage.degradedClassCount,
783
+ insufficientClassCount: result.sufficiency.coverage.insufficientClassCount,
784
+ ...ACTIVITY_LOG_EVIDENCE_INTEGRITY[result.evidence.classification],
785
+ }));
786
+ }
787
+ finally {
788
+ activityLog.close?.();
329
789
  }
330
790
  }
791
+ function writeRolledBackRecovery(activityLog, correlationId, outcome) {
792
+ activityLog.write(activityLogEvent(SUPPORT_EXPORT_PUBLICATION_OPERATION, { correlationId }, {
793
+ publicationArtifactClass: "support-report",
794
+ artifactCount: 2,
795
+ visibleArtifactCount: 0,
796
+ persistenceStatus: "rolled-back",
797
+ publicationPersistenceStatus: "rolled-back",
798
+ completeness: "complete",
799
+ publicationCompleteness: "complete",
800
+ loss: "none",
801
+ publicationLoss: "none",
802
+ recoveryState: outcome.recoveryState,
803
+ receiptState: "consumed",
804
+ }));
805
+ }
806
+ function writeAcknowledgementFailure(activityLog, correlationId, outcome) {
807
+ activityLog.write(activityLogEvent(SUPPORT_EXPORT_PUBLICATION_OPERATION, {
808
+ level: "error",
809
+ correlationId,
810
+ errorKind: supportPublicationActivityErrorKind(outcome.errorKind),
811
+ }, {
812
+ ...completedPublicationEvidenceFields(outcome.publication, "acknowledgement-failed", "acknowledgement-uncertain"),
813
+ failedArtifactClass: "manifest",
814
+ failureKind: outcome.errorKind,
815
+ }));
816
+ }
817
+ function writeCompletedPublication(activityLog, correlationId, outcome) {
818
+ activityLog.write(activityLogEvent(SUPPORT_EXPORT_PUBLICATION_OPERATION, { correlationId }, completedPublicationEvidenceFields(outcome, outcome.status, "consumed")));
819
+ }
820
+ function writeFailedPublication(activityLog, correlationId, outcome) {
821
+ activityLog.write(activityLogEvent(SUPPORT_EXPORT_PUBLICATION_OPERATION, {
822
+ level: "error",
823
+ correlationId,
824
+ errorKind: supportPublicationActivityErrorKind(outcome.errorKind),
825
+ }, failedPublicationEvidenceFields(outcome)));
826
+ }
331
827
  // Finding 1 (minor): store fingerprint collection runs a synchronous full-DB `quick_check` plus
332
828
  // a row count per table for each store, which can take a while against a large local-knowledge
333
829
  // index with nothing printed while it runs. This progress line keeps a slow run from looking
@@ -335,17 +831,16 @@ function writeBundleOrExitCode(outPath, contents, io) {
335
831
  function reportStoreFingerprintProgress(io) {
336
832
  io.err("keiko support export: computing store fingerprints (may take a while on a large local-knowledge index)...\n");
337
833
  }
834
+ // Body-free like every other failure line in this file: an auditor error's text can quote the
835
+ // state tree it was reading, so only the closed `AuditLoadError` reason or the error's kind is
836
+ // printed, never its message.
338
837
  function reportAuditFailure(error, io) {
339
- if (error instanceof AuditLoadError) {
340
- io.err(`keiko support export: local-state audit could not produce a result (${error.reason}); ` +
341
- "refusing to write a bundle without an audit summary.\n");
342
- return 1;
343
- }
344
- if (error instanceof Error) {
345
- io.err(`keiko support export: ${error.message}\n`);
346
- return 1;
347
- }
348
- throw error;
838
+ if (!(error instanceof Error))
839
+ throw error;
840
+ const reason = error instanceof AuditLoadError ? error.reason : describeErrorKind(error);
841
+ io.err(`keiko support export: local-state audit could not produce a result (${reason}); ` +
842
+ "refusing to write a bundle without an audit summary.\n");
843
+ return 1;
349
844
  }
350
845
  function processProvenance(server, generatedAt, stateDirSource) {
351
846
  return {
@@ -362,29 +857,13 @@ function processProvenance(server, generatedAt, stateDirSource) {
362
857
  function logContentManifestFields(logContent) {
363
858
  return {
364
859
  sourceLogFiles: logContent.sourceLogFiles,
860
+ sourceLogFileLines: logContent.sourceLogFileLines,
365
861
  truncatedLogFiles: logContent.truncatedLogFiles,
366
862
  currentFileTailTruncated: logContent.currentFileTailTruncated,
367
863
  budgetExceeded: logContent.budgetExceeded,
368
864
  skippedLogFiles: logContent.skippedLogFiles,
369
865
  };
370
866
  }
371
- // A missing or unreadable ui.log (no `keiko start` has ever run against this state dir, or a
372
- // permission error) means there is nothing to attach — never a failed export.
373
- function readUiLogContentOrUndefined(stateDir) {
374
- try {
375
- return readFileSync(join(stateDir, UI_LOG_FILE_NAME), "utf8");
376
- }
377
- catch {
378
- return undefined;
379
- }
380
- }
381
- function resolveUiLogInclusion(stateDir, args) {
382
- const consented = args.includeUiLog && args.iUnderstandUnredacted;
383
- const content = consented ? readUiLogContentOrUndefined(stateDir) : undefined;
384
- return content === undefined
385
- ? { section: undefined, excluded: true }
386
- : { section: buildUiLogSection(content), excluded: false };
387
- }
388
867
  // A `KEIKO_`-prefixed env name is collected with the prefix fused on, so `redactLogFields`'s
389
868
  // field-NAME denylist (an exact match on the WHOLE normalized name, `log-redaction.ts`) can never
390
869
  // fire on it: normalization turns `KEIKO_DEFAULT_API_KEY` into `keikodefaultapikey`, which does
@@ -392,31 +871,31 @@ function resolveUiLogInclusion(stateDir, args) {
392
871
  // heuristics alone is not enough either — they do not catch, for example, a hex-only secret (no
393
872
  // uppercase character, so the high-entropy check never fires) or any other operator-chosen
394
873
  // credential shape they were never designed to enumerate. This is therefore a second, independent
395
- // gate at the COLLECTION layer: a credential-shaped segment anywhere in the name (split on `_`)
396
- // refuses the field outright, before its value is ever read into the snapshot at all.
397
- const CREDENTIAL_NAME_SEGMENTS = new Set([
874
+ // gate at the COLLECTION layer: a credential word (optionally plural) ENDING any `_`-separated
875
+ // segment refuses the field outright, before its value is ever read into the snapshot at all —
876
+ // whether the word stands alone (`KEIKO_API_KEY`) or is fused onto a qualifier
877
+ // (`KEIKO_CLIENTSECRET`, `KEIKO_APITOKEN`). The segment end, not any substring, is deliberate:
878
+ // `KEIKO_LOCAL_KNOWLEDGE_TOKENIZER` names a tokenizer mode, not a token.
879
+ const CREDENTIAL_NAME_WORDS = [
398
880
  "key",
399
- "keys",
400
- "apikey",
401
- "apikeys",
402
881
  "secret",
403
- "secrets",
404
882
  "token",
405
- "tokens",
406
883
  "credential",
407
- "credentials",
408
884
  "password",
409
885
  "passwd",
410
886
  "pwd",
411
887
  "auth",
412
888
  "cert",
413
889
  "certificate",
414
- ]);
890
+ ];
891
+ function isCredentialNameSegment(segment) {
892
+ return CREDENTIAL_NAME_WORDS.some((word) => segment.endsWith(word) || segment.endsWith(`${word}s`));
893
+ }
415
894
  function isCredentialShapedEnvName(key) {
416
895
  return key
417
896
  .toLowerCase()
418
897
  .split("_")
419
- .some((segment) => CREDENTIAL_NAME_SEGMENTS.has(segment));
898
+ .some((segment) => isCredentialNameSegment(segment));
420
899
  }
421
900
  // "The resolved runtime configuration" scoped to what this CLI itself resolves from the
422
901
  // environment — its own `KEIKO_*` vocabulary (KEIKO_STATE_DIR, KEIKO_CONFIG_FILE,
@@ -461,67 +940,164 @@ async function resolveIncludedEvidenceSections(evidenceDir, runIds, deps) {
461
940
  }
462
941
  }
463
942
  // Assembles every Wave 6 `$section` record in the bundle's fixed order: config-snapshot (always),
464
- // then each requested evidence-manifest, then ui-log last (when its gate passed) — content
465
- // verbatim, so it sits closest to the raw log lines that follow it.
466
- function assembleWave6Sections(env, server, uiLog, evidenceSections) {
467
- const configSnapshot = resolveConfigSnapshotSection(env, server);
468
- return uiLog.section === undefined
469
- ? [configSnapshot, ...evidenceSections]
470
- : [configSnapshot, ...evidenceSections, uiLog.section];
943
+ // then each requested evidence-manifest. No section ever carries raw UI output (#3532).
944
+ function assembleWave6Sections(env, server, evidenceSections) {
945
+ return [resolveConfigSnapshotSection(env, server), ...evidenceSections];
471
946
  }
472
- async function runSupportExport(args, io, env, deps) {
473
- const cwd = deps.cwd ?? process.cwd();
474
- const now = deps.now ?? (() => new Date());
475
- const stateDir = resolveStateDir(cwd, env, args.stateDir);
476
- if (!prepareSupportInstallLayoutEvidence(stateDir, env, deps, io))
947
+ async function recordRolledBackRecovery(recovery, stateDir) {
948
+ emitSupportPublicationEvidence(await loadServer(), stateDir, randomUUID(), recovery);
949
+ }
950
+ async function recoveredSupportExportExitCode(recovery, stateDir, io, context) {
951
+ const server = await loadServer();
952
+ if (recovery.status === "failed") {
953
+ emitSupportPublicationEvidence(server, stateDir, randomUUID(), recovery);
477
954
  return 1;
478
- const logContent = collectLogContent(join(stateDir, "logs"), args.maxBytes ?? DEFAULT_MAX_BUNDLE_BYTES);
479
- const evidenceDir = env.KEIKO_EVIDENCE_DIR ?? join(stateDir, "evidence");
480
- const evidenceIndexCount = await resolveEvidenceIndexCount(evidenceDir, deps);
481
- // Not a hot path (`support analyze` never reaches this function), so loading the server module
482
- // graph here is not the GEN-PERF-CLI-001 cost `ui.ts` guards against on every command dispatch.
955
+ }
956
+ return completeSupportPublication(recovery, server, stateDir, io, context, `Recovered support report at ${recovery.result.commitPath}\n`);
957
+ }
958
+ // Success is claimed only once the receipt is acknowledged: an unacknowledged publication exits 1
959
+ // without a success line, and the next run recovers and announces the same durable report.
960
+ function completeSupportPublication(publication, server, stateDir, io, context, successLine) {
961
+ const correlationId = randomUUID();
962
+ const errorKind = acknowledgeSupportPublication(context, io);
963
+ if (errorKind === undefined) {
964
+ io.out(successLine);
965
+ emitSupportPublicationEvidence(server, stateDir, correlationId, publication);
966
+ return 0;
967
+ }
968
+ emitSupportPublicationEvidence(server, stateDir, correlationId, {
969
+ status: "acknowledgement-failed",
970
+ errorKind,
971
+ publication,
972
+ });
973
+ return 1;
974
+ }
975
+ function publishedSupportExportExitCode(publication, server, stateDir, lineCount, outPath, io, context) {
976
+ if (publication.status === "failed") {
977
+ emitSupportPublicationEvidence(server, stateDir, randomUUID(), publication);
978
+ return 1;
979
+ }
980
+ return completeSupportPublication(publication, server, stateDir, io, context, `Wrote ${String(lineCount)} lines to ${outPath}\n`);
981
+ }
982
+ // The whole log (oldest files dropped first to fit --max-bytes), or, with a selector, only the
983
+ // selection's causal closure, which is never cut to fit (#3531).
984
+ async function collectExportLogContent(args, stateDir, io, server) {
985
+ const maxBytes = args.maxBytes ?? DEFAULT_MAX_BUNDLE_BYTES;
986
+ if (args.selector === undefined)
987
+ return collectLogContent(join(stateDir, "logs"), maxBytes);
988
+ return collectSelectedLogContent(args.selector, stateDir, maxBytes, io, server);
989
+ }
990
+ async function collectFreshSupportData(args, io, env, deps, context) {
483
991
  const server = await loadServer();
992
+ const logContent = await collectExportLogContent(args, context.stateDir, io, server);
993
+ if (typeof logContent === "number")
994
+ return logContent;
995
+ const evidenceDir = env.KEIKO_EVIDENCE_DIR ?? join(context.stateDir, "evidence");
996
+ const evidenceIndexCount = await resolveEvidenceIndexCount(evidenceDir, deps);
997
+ try {
998
+ const activityLog = server.createFileServerLogSink(context.stateDir);
999
+ activityLog.close?.();
1000
+ }
1001
+ catch (error) {
1002
+ io.err(`keiko support export: Activity Log unavailable: ${supportPublicationErrorKind(error)}\n`);
1003
+ return 1;
1004
+ }
484
1005
  let auditSummary;
485
1006
  try {
486
- auditSummary = await auditLocalStateResult(stateDir, env, deps.auditDeps ?? {});
1007
+ auditSummary = await auditLocalStateResult(context.stateDir, env, deps.auditDeps ?? {});
487
1008
  }
488
1009
  catch (error) {
489
1010
  return reportAuditFailure(error, io);
490
1011
  }
491
- // Deferred until after the audit's own fail-closed check: opening three real stores is real
492
- // I/O, wasted if the export is about to be refused anyway.
493
1012
  reportStoreFingerprintProgress(io);
494
- const storeFingerprintCollection = await server.collectStoreFingerprints({ stateDir, env });
495
- const uiLog = resolveUiLogInclusion(stateDir, args);
1013
+ const stores = await server.collectStoreFingerprints({ stateDir: context.stateDir, env });
496
1014
  const evidenceSections = await resolveIncludedEvidenceSections(evidenceDir, args.includeEvidenceRunIds, deps);
497
- const generatedAtDate = now();
498
- const manifest = buildSupportBundleManifest({
499
- ...processProvenance(server, generatedAtDate, resolveStateDirSource(env, args.stateDir)),
500
- ...logContentManifestFields(logContent),
501
- auditSummary,
1015
+ return {
1016
+ logContent,
502
1017
  evidenceIndexCount,
503
- storeFingerprints: storeFingerprintCollection.fingerprints,
504
- storesUnavailable: storeFingerprintCollection.unavailable,
505
- sectionsExcluded: uiLog.excluded ? [UI_LOG_SECTION] : [],
1018
+ server,
1019
+ auditSummary,
1020
+ stores,
1021
+ evidenceSections,
1022
+ generatedAtDate: context.now(),
1023
+ };
1024
+ }
1025
+ async function publishFreshSupportExport(args, io, env, deps, context) {
1026
+ const data = await collectFreshSupportData(args, io, env, deps, context);
1027
+ if (typeof data === "number")
1028
+ return data;
1029
+ const baseManifest = buildSupportBundleManifest({
1030
+ ...processProvenance(data.server, data.generatedAtDate, context.stateDirSource),
1031
+ ...logContentManifestFields(data.logContent),
1032
+ auditSummary: data.auditSummary,
1033
+ evidenceIndexCount: data.evidenceIndexCount,
1034
+ storeFingerprints: data.stores.fingerprints,
1035
+ storesUnavailable: data.stores.unavailable,
1036
+ // A legacy raw `ui.log` is never read into a report; the manifest keeps naming it as excluded.
1037
+ sectionsExcluded: [UI_LOG_SECTION],
506
1038
  });
507
- const sections = assembleWave6Sections(env, server, uiLog, evidenceSections);
508
- const lines = serializeBundleLines(manifest, sections, logContent.contentLines);
509
- const outPath = resolveOutPath(cwd, args.out, generatedAtDate);
510
- const failureCode = writeBundleOrExitCode(outPath, bundleText(lines), io);
511
- if (failureCode !== undefined)
512
- return failureCode;
513
- io.out(`Wrote ${String(lines.length)} lines to ${outPath}\n`);
514
- return 0;
1039
+ const selection = data.logContent.selection;
1040
+ const manifest = selection === undefined ? baseManifest : { ...baseManifest, selection };
1041
+ const sections = assembleWave6Sections(env, data.server, data.evidenceSections);
1042
+ const lines = serializeBundleLines(manifest, sections, data.logContent.contentLines);
1043
+ const outPath = resolveOutPath(context.cwd, args.out, data.generatedAtDate);
1044
+ const publication = publishSupportBundle(outPath, bundleText(lines, data.logContent.terminalFragment), io, context.publication, context.recoveryState);
1045
+ return publishedSupportExportExitCode(publication, data.server, context.stateDir, lines.length, outPath, io, context.publication);
1046
+ }
1047
+ async function runSupportExport(args, io, env, deps) {
1048
+ const cwd = deps.cwd ?? process.cwd();
1049
+ const now = deps.now ?? (() => new Date());
1050
+ const stateDir = resolveStateDir(cwd, env, args.stateDir);
1051
+ if (!prepareSupportInstallLayoutEvidence(stateDir, env, deps, io))
1052
+ return 1;
1053
+ const stateDirSource = resolveStateDirSource(env, args.stateDir);
1054
+ if (supportDestinationCollidesWithActivityLog(cwd, stateDir, args.out)) {
1055
+ io.err("keiko support export: destination collides with the Activity Log\n");
1056
+ return 1;
1057
+ }
1058
+ const publicationContext = supportPublicationContext(cwd, args.out);
1059
+ const recovery = recoverSupportBundle(publicationContext, io);
1060
+ if (recovery.status === "recovered" || recovery.status === "failed") {
1061
+ return recoveredSupportExportExitCode(recovery, stateDir, io, publicationContext);
1062
+ }
1063
+ if (recovery.status === "rolled-back")
1064
+ await recordRolledBackRecovery(recovery, stateDir);
1065
+ const exitCode = await publishFreshSupportExport(args, io, env, deps, {
1066
+ cwd,
1067
+ now,
1068
+ stateDir,
1069
+ stateDirSource,
1070
+ publication: publicationContext,
1071
+ recoveryState: recovery.status,
1072
+ });
1073
+ if (exitCode === 0)
1074
+ await reportSupportReadiness(stateDir, env, io);
1075
+ return exitCode;
1076
+ }
1077
+ // `keiko support export` also states the exported directory's diagnostic readiness (#3532). The
1078
+ // self-check persists its own `activity-log.readiness` line after the export, so the report it just
1079
+ // wrote stays exactly the evidence that existed when it was taken. This command inspects a state
1080
+ // directory it does not serve, so its own logger's wiring is not part of that directory's answer.
1081
+ async function reportSupportReadiness(stateDir, env, io) {
1082
+ const snapshot = (await loadServer()).checkActivityLogReadiness({
1083
+ stateDir,
1084
+ env,
1085
+ scope: "directory",
1086
+ });
1087
+ const reasons = snapshot.reasons.length === 0 ? "" : ` (${snapshot.reasons.join(", ")})`;
1088
+ io.out(`Diagnostic evidence: ${snapshot.readiness}${reasons}.\n`);
515
1089
  }
516
1090
  function reportMissingCorrelationId(correlationId, io) {
517
1091
  io.err(`keiko support analyze: no lines found for correlation id: ${correlationId}\n`);
518
1092
  return 1;
519
1093
  }
1094
+ // A raw Activity Log file sits directly in `<state-dir>/logs/` under the closed grammar (a segment or
1095
+ // a legacy server*.log); anything else gives no state directory to infer.
520
1096
  function inferAnalyzedStateDir(filePath, sourceKind) {
521
1097
  const logDirectory = dirname(filePath);
522
1098
  return sourceKind === "raw-log" &&
523
- basename(logDirectory) === "logs" &&
524
- SERVER_LOG_FILE_PATTERN.test(basename(filePath))
1099
+ basename(logDirectory) === ACTIVITY_LOG_DIRECTORY_NAME &&
1100
+ parseActivityLogFileName(basename(filePath)) !== undefined
525
1101
  ? dirname(logDirectory)
526
1102
  : undefined;
527
1103
  }
@@ -629,9 +1205,32 @@ function renderAnalysisContext(context) {
629
1205
  ];
630
1206
  return `${lines.join("\n")}\n\n`;
631
1207
  }
632
- function emitSingleTimeline(timeline, malformedLineCount, context, json, io) {
1208
+ // The versioned machine forms of `analyze --json` (#3531). Each names itself and its version ahead of
1209
+ // the fields the unversioned output already had, which stay unchanged, so an earlier reader (such as
1210
+ // `keiko investigate --from-timeline`) keeps working.
1211
+ const SUPPORT_ANALYZE_KIND = "keiko.support.analyze";
1212
+ const SUPPORT_ANALYZE_TIMELINE_KIND = "keiko.support.analyze-timeline";
1213
+ const SUPPORT_ANALYZE_SCHEMA_VERSION = 1;
1214
+ function analyzeProvenance() {
1215
+ return {
1216
+ productVersion: KEIKO_PRODUCT_VERSION,
1217
+ registryVersion: ACTIVITY_LOG_REGISTRY_VERSION,
1218
+ schemaDigest: ACTIVITY_LOG_SCHEMA_DIGEST,
1219
+ catalogDigest: ACTIVITY_LOG_CATALOG_DIGEST,
1220
+ };
1221
+ }
1222
+ function emitSingleTimeline(timeline, result, context, json, io) {
633
1223
  if (json) {
634
- io.out(`${JSON.stringify({ ...timeline, malformedLineCount, analysisContext: context })}\n`);
1224
+ const payload = {
1225
+ kind: SUPPORT_ANALYZE_TIMELINE_KIND,
1226
+ schemaVersion: SUPPORT_ANALYZE_SCHEMA_VERSION,
1227
+ provenance: analyzeProvenance(),
1228
+ ...timeline,
1229
+ malformedLineCount: result.malformedLineCount,
1230
+ sufficiency: timelineSufficiency(result, timeline),
1231
+ analysisContext: context,
1232
+ };
1233
+ io.out(`${JSON.stringify(payload)}\n`);
635
1234
  }
636
1235
  else {
637
1236
  io.out(`${renderAnalysisContext(context)}${renderHumanTimeline(timeline)}`);
@@ -639,8 +1238,13 @@ function emitSingleTimeline(timeline, malformedLineCount, context, json, io) {
639
1238
  return 0;
640
1239
  }
641
1240
  function emitAllTimelines(result, json, io) {
1241
+ const payload = {
1242
+ kind: SUPPORT_ANALYZE_KIND,
1243
+ schemaVersion: SUPPORT_ANALYZE_SCHEMA_VERSION,
1244
+ provenance: analyzeProvenance(),
1245
+ };
642
1246
  io.out(json
643
- ? `${JSON.stringify(result)}\n`
1247
+ ? `${JSON.stringify({ ...payload, ...result })}\n`
644
1248
  : `${renderAnalysisContext(result.analysisContext)}${renderHumanAllTimelines(result)}`);
645
1249
  return 0;
646
1250
  }
@@ -648,22 +1252,63 @@ function emitAllTimelines(result, json, io) {
648
1252
  // of --correlation-id (support-analyze.ts's `renderHumanClusters` docstring reserves it for
649
1253
  // exactly this flag). Emits the bare `OpCluster[]` under --json, never nested inside a larger
650
1254
  // envelope, since this is deliberately a focused report, not a slice of the default output.
1255
+ //
1256
+ // That bare array predates the versioned machine profiles (#3531) and stays byte-compatible: no
1257
+ // reader of it breaks. But it is itself unversioned, with no stated compatibility or deprecation
1258
+ // path (#3531 Update Impact) — and `keiko support analyze --json`'s own `clusters` member (kind
1259
+ // `keiko.support.analyze`, schemaVersion 1) now carries exactly the same `OpCluster[]` data inside
1260
+ // a versioned envelope. `--clusters --json` is therefore the explicit deprecation path itself: keep
1261
+ // the array exactly as it was, and name the versioned replacement on stderr every time it is used.
651
1262
  function emitClusters(clusters, json, io) {
1263
+ if (json) {
1264
+ io.err("keiko support analyze: --clusters --json is a deprecated, unversioned bare array; use " +
1265
+ `the clusters member of keiko support analyze --json (${SUPPORT_ANALYZE_KIND} v` +
1266
+ `${String(SUPPORT_ANALYZE_SCHEMA_VERSION)}) instead.\n`);
1267
+ }
652
1268
  io.out(json ? `${JSON.stringify(clusters)}\n` : renderHumanClusters(clusters));
653
1269
  return 0;
654
1270
  }
655
- // Single return statement by design (sonarjs/function-return-type): both arms assign the same
656
- // declared `string | number` union before one trailing return, rather than returning from inside
657
- // each branch, so the function's return shape reads as one type instead of two.
658
- function readAnalyzeSource(filePath, io) {
1271
+ // Records what a reproduction seed states about its source while the analysis streams it (#3531):
1272
+ // the SHA-256 of the artifact's exact bytes, its line count, and its first line (a bundle's
1273
+ // manifest line). Digest and analysis come from the same pass, so they describe one snapshot.
1274
+ class SeedSourceObserver {
1275
+ hash = createHash("sha256");
1276
+ lineCount = 0;
1277
+ firstLine;
1278
+ observeChunk = (chunk) => {
1279
+ this.hash.update(chunk);
1280
+ };
1281
+ *observeLines(lines) {
1282
+ for (const line of lines) {
1283
+ if (this.lineCount === 0)
1284
+ this.firstLine = line.text;
1285
+ this.lineCount += 1;
1286
+ yield line;
1287
+ }
1288
+ }
1289
+ source() {
1290
+ return {
1291
+ lineCount: this.lineCount,
1292
+ sha256: this.hash.digest("hex"),
1293
+ firstLine: this.firstLine,
1294
+ };
1295
+ }
1296
+ }
1297
+ // Streams FILE through the bounded line reader (#3531) instead of loading it whole. A failure to
1298
+ // open or read it is reported content-free: the closed cause kind, never an fs message, which can
1299
+ // quote the path (AGENTS.md §7). Any other error propagates.
1300
+ function streamAnalyzeSource(filePath, options, io, observer) {
659
1301
  let result;
660
1302
  try {
661
- result = readFileSync(filePath, "utf8");
1303
+ const lines = readActivityLogFileLines(() => openSync(filePath, "r"), {
1304
+ onChunk: observer?.observeChunk,
1305
+ });
1306
+ result = analyzeLogLines(observer === undefined ? lines : observer.observeLines(lines), options);
662
1307
  }
663
1308
  catch (error) {
664
- // Content-free: an fs error's message can quote the path it was reading (AGENTS.md §7).
665
- const kind = error instanceof Error ? error.constructor.name : "Error";
666
- io.err(`keiko support analyze: could not read ${filePath} — ${kind}\n`);
1309
+ if (!(error instanceof ActivityLogReadError))
1310
+ throw error;
1311
+ io.err(`keiko support analyze: could not read ${filePath} — ${error.causeKind}\n`);
667
1312
  result = 1;
668
1313
  }
669
1314
  return result;
@@ -671,23 +1316,35 @@ function readAnalyzeSource(filePath, io) {
671
1316
  function resolveFixturePath(cwd, path) {
672
1317
  return isAbsolute(path) ? path : resolve(cwd, path);
673
1318
  }
674
- // Fail-closed (disclosed gap #1's fix): never overwrites an existing file — a fixture is meant to
675
- // be hand-edited after generation, and silently clobbering that would destroy real work — and
676
- // creates the parent directory so `--emit-fixture some/new/dir/fixture.ts` does not require the
677
- // operator to `mkdir -p` first. Content-free error reporting, same discipline as
678
- // `writeBundleOrExitCode`: an fs error's message can quote the path it was writing.
1319
+ // Fail-closed (disclosed gap #1's fix): never overwrites or follows an existing entry — a fixture
1320
+ // is meant to be hand-edited after generation, and silently clobbering that would destroy real
1321
+ // work. The one file is created exclusively in place through the shared hardened primitive, with
1322
+ // the trust root a user-chosen `--out` report uses (the destination's own directory): a live or
1323
+ // dangling symlink, hard link, or FIFO at PATH is refused as an existing target, nothing is ever
1324
+ // created at a link's target, and no staging or recovery files are left beside it. The parent
1325
+ // directory is created first so `--emit-fixture some/new/dir/fixture.ts` does not require the
1326
+ // operator to `mkdir -p`. Content-free error reporting: only the closed failure kind is printed.
679
1327
  function writeFixtureOrExitCode(path, contents, io) {
680
- if (existsSync(path)) {
681
- io.err(`keiko support analyze: refusing to overwrite existing file: ${path}\n`);
682
- return 1;
683
- }
684
1328
  try {
685
1329
  mkdirSync(dirname(path), { recursive: true });
686
- writeFileSync(path, contents, "utf8");
1330
+ const descriptor = openSafeArtifactFile(path, {
1331
+ artifactClass: "replay-fixture",
1332
+ mode: "exclusive-create",
1333
+ trustedRoot: dirname(path),
1334
+ });
1335
+ try {
1336
+ writeFileSync(descriptor, contents, "utf8");
1337
+ }
1338
+ finally {
1339
+ closeSync(descriptor);
1340
+ }
687
1341
  return undefined;
688
1342
  }
689
1343
  catch (error) {
690
- io.err(`keiko support analyze: could not write fixture: ${describeErrorKind(error)}\n`);
1344
+ const kind = describeErrorKind(error);
1345
+ io.err(kind === "target-exists"
1346
+ ? `keiko support analyze: refusing to overwrite existing file: ${path}\n`
1347
+ : `keiko support analyze: could not write fixture: ${kind}\n`);
691
1348
  return 1;
692
1349
  }
693
1350
  }
@@ -731,7 +1388,8 @@ function emitSeedResult(seed, fixturePath, json, io) {
731
1388
  // `--seed` / `--emit-fixture` (both require --correlation-id, enforced by `parseAnalyzeArgs`):
732
1389
  // builds one `ReproductionSeed`, optionally writes the fixture derived from its `gatewayScript`,
733
1390
  // then reports according to which of the two flags were actually requested.
734
- function runSeedAndFixture(text, args, cwd, io, options) {
1391
+ function runSeedAndFixture(analysis, source, context) {
1392
+ const { args, cwd, io, options } = context;
735
1393
  const correlationId = args.correlationId;
736
1394
  if (correlationId === undefined) {
737
1395
  // Unreachable in practice: parseAnalyzeArgs rejects --seed/--emit-fixture without
@@ -740,7 +1398,7 @@ function runSeedAndFixture(text, args, cwd, io, options) {
740
1398
  io.err(`keiko support analyze: --seed/--emit-fixture require --correlation-id.\n${USAGE}`);
741
1399
  return 2;
742
1400
  }
743
- const seed = buildReproductionSeed(text, correlationId, new Date(), options);
1401
+ const seed = buildReproductionSeedFromAnalysis(analysis, source, correlationId, new Date(), options);
744
1402
  if (seed === undefined)
745
1403
  return reportMissingCorrelationId(correlationId, io);
746
1404
  const fixtureOutcome = emitFixtureIfRequested(seed, args.emitFixture, correlationId, cwd, io);
@@ -778,28 +1436,66 @@ async function loadToolAnalysisOptions(result, io) {
778
1436
  return {};
779
1437
  }
780
1438
  }
781
- async function runSupportAnalyze(args, io, deps) {
1439
+ async function persistSupportAnalysisEvidence(result, cwd, env, io) {
1440
+ // Analysis input is immutable evidence. Persist the operator action to the CLI's local Activity
1441
+ // Log instead of appending to a raw input file, which may itself end in the crash fragment being
1442
+ // diagnosed.
1443
+ const stateDir = resolveStateDir(cwd, env);
1444
+ try {
1445
+ const server = await loadServer();
1446
+ emitSupportAnalysisEvidence(server, stateDir, result);
1447
+ return true;
1448
+ }
1449
+ catch (error) {
1450
+ io.err(`keiko support analyze: Activity Log unavailable: ${supportPublicationErrorKind(error)}\n`);
1451
+ return false;
1452
+ }
1453
+ }
1454
+ async function emitAnalyzedSupportResult(result, context) {
1455
+ if (!(await persistSupportAnalysisEvidence(result, context.cwd, context.env, context.io)))
1456
+ return 1;
1457
+ if (context.args.clusters)
1458
+ return emitClusters(result.clusters, context.args.json, context.io);
1459
+ if (context.args.seed || context.args.emitFixture !== undefined) {
1460
+ // The seed states its source's digest and line count, so it streams the artifact once more
1461
+ // and records both from the same pass as its analysis (#3531).
1462
+ const observer = new SeedSourceObserver();
1463
+ const analysis = streamAnalyzeSource(context.filePath, context.options, context.io, observer);
1464
+ if (typeof analysis === "number")
1465
+ return analysis;
1466
+ return runSeedAndFixture(analysis, observer.source(), context);
1467
+ }
1468
+ const report = buildAnalysisReport(result, context.filePath, context.deps);
1469
+ if (context.args.correlationId === undefined) {
1470
+ return emitAllTimelines(report, context.args.json, context.io);
1471
+ }
1472
+ const timeline = findTimeline(result, context.args.correlationId);
1473
+ if (timeline === undefined) {
1474
+ return reportMissingCorrelationId(context.args.correlationId, context.io);
1475
+ }
1476
+ return emitSingleTimeline(timeline, result, report.analysisContext, context.args.json, context.io);
1477
+ }
1478
+ async function runSupportAnalyze(args, io, env, deps) {
782
1479
  const cwd = deps.cwd ?? process.cwd();
783
1480
  const filePath = isAbsolute(args.file) ? args.file : resolve(cwd, args.file);
784
- const text = readAnalyzeSource(filePath, io);
785
- if (typeof text === "number")
786
- return text;
787
- const basic = analyzeLogText(text);
1481
+ const basic = streamAnalyzeSource(filePath, {}, io);
1482
+ if (typeof basic === "number")
1483
+ return basic;
788
1484
  const options = await loadToolAnalysisOptions(basic, io);
789
- const result = options.toolLifecycleValidator === undefined ? basic : analyzeLogText(text, options);
790
- if (args.clusters)
791
- return emitClusters(result.clusters, args.json, io);
792
- if (args.seed || args.emitFixture !== undefined) {
793
- return runSeedAndFixture(text, args, cwd, io, options);
794
- }
795
- const report = buildAnalysisReport(result, filePath, deps);
796
- if (args.correlationId === undefined) {
797
- return emitAllTimelines(report, args.json, io);
798
- }
799
- const timeline = findTimeline(result, args.correlationId);
800
- if (timeline === undefined)
801
- return reportMissingCorrelationId(args.correlationId, io);
802
- return emitSingleTimeline(timeline, result.malformedLineCount, report.analysisContext, args.json, io);
1485
+ const result = options.toolLifecycleValidator === undefined
1486
+ ? basic
1487
+ : streamAnalyzeSource(filePath, options, io);
1488
+ if (typeof result === "number")
1489
+ return result;
1490
+ return emitAnalyzedSupportResult(result, {
1491
+ args,
1492
+ cwd,
1493
+ filePath,
1494
+ io,
1495
+ env,
1496
+ deps,
1497
+ options,
1498
+ });
803
1499
  }
804
1500
  export async function runSupportCli(args, io, env = {}, deps = {}) {
805
1501
  const parsed = parseSupportArgs(args);
@@ -814,5 +1510,17 @@ export async function runSupportCli(args, io, env = {}, deps = {}) {
814
1510
  if (parsed.kind === "export") {
815
1511
  return runSupportExport(parsed.value, io, env, deps);
816
1512
  }
817
- return runSupportAnalyze(parsed.value, io, deps);
1513
+ if (parsed.kind === "incident") {
1514
+ return runSupportIncidentCli(parsed.args, io, env, { cwd: deps.cwd });
1515
+ }
1516
+ if (parsed.kind === "query-help") {
1517
+ io.out(SUPPORT_QUERY_USAGE);
1518
+ return 0;
1519
+ }
1520
+ if (parsed.kind === "query")
1521
+ return runSupportQueryCli(parsed.value, io, env, { cwd: deps.cwd });
1522
+ if (parsed.kind === "manifest") {
1523
+ return runSupportManifestCli(parsed.value, io, env, { cwd: deps.cwd });
1524
+ }
1525
+ return runSupportAnalyze(parsed.value, io, env, deps);
818
1526
  }