@humain/humain-code 0.8.2 → 0.8.4

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 (946) hide show
  1. package/CHANGELOG.md +152 -0
  2. package/dist/bundle/agent-monitor.js +1 -1
  3. package/dist/bundle/chunks/anthropic-messages-42CGJCSR.js +82 -0
  4. package/dist/bundle/chunks/ask-VH7GNX75.js +97 -0
  5. package/dist/bundle/chunks/azure-openai-responses-DOKKMBUN.js +15 -0
  6. package/dist/bundle/chunks/bedrock-converse-stream.js +200 -179
  7. package/dist/bundle/chunks/bowser-UX7KDMIY.js +92 -0
  8. package/dist/bundle/chunks/{chunk-46C6D7UC.js → chunk-2CYGUEQO.js} +1 -1
  9. package/dist/bundle/chunks/chunk-3RXT35Y3.js +3 -0
  10. package/dist/bundle/chunks/chunk-4BNDLR6C.js +177 -0
  11. package/dist/bundle/chunks/{chunk-MPRAQ6ZI.js → chunk-4LGBXPUD.js} +1 -1
  12. package/dist/bundle/chunks/chunk-4SL6URR3.js +90 -0
  13. package/dist/bundle/chunks/{chunk-PJXBU6CR.js → chunk-52642TYH.js} +394 -204
  14. package/dist/bundle/chunks/{chunk-LSRXA7OS.js → chunk-5C5K4EVJ.js} +3 -3
  15. package/dist/bundle/chunks/{chunk-2JNJJ6SZ.js → chunk-5KUCY54O.js} +3 -3
  16. package/dist/bundle/chunks/{chunk-4TDNOR36.js → chunk-625QJSFJ.js} +1 -1
  17. package/dist/bundle/chunks/chunk-73YX5XGR.js +2461 -0
  18. package/dist/bundle/chunks/chunk-7DIRHF4H.js +17 -0
  19. package/dist/bundle/chunks/{chunk-QJB5YI3I.js → chunk-7PAXKU7M.js} +1 -1
  20. package/dist/bundle/chunks/{chunk-R2KD2HFT.js → chunk-7YB3HRRN.js} +83 -196
  21. package/dist/bundle/chunks/{chunk-DCXHRP6C.js → chunk-A2UZYK23.js} +13 -13
  22. package/dist/bundle/chunks/chunk-A5ZMBTTM.js +12 -0
  23. package/dist/bundle/chunks/{chunk-JKX5EGOT.js → chunk-AER66CNP.js} +13 -13
  24. package/dist/bundle/chunks/chunk-ARTF7ZMQ.js +5 -0
  25. package/dist/bundle/chunks/chunk-B3FT6L6S.js +131 -0
  26. package/dist/bundle/chunks/chunk-BIC5BSNX.js +13 -0
  27. package/dist/bundle/chunks/{chunk-JSHKS7VH.js → chunk-BNZZJ4LO.js} +1 -1
  28. package/dist/bundle/chunks/{chunk-4MKATHT2.js → chunk-CG43CMFH.js} +1 -1
  29. package/dist/bundle/chunks/{chunk-EFY2QPVP.js → chunk-CIAXW64K.js} +16 -16
  30. package/dist/bundle/chunks/{chunk-VFLVWPLZ.js → chunk-CKFLQGJN.js} +20 -16
  31. package/dist/bundle/chunks/chunk-D4UCXXDP.js +115 -0
  32. package/dist/bundle/chunks/{chunk-HQMUDHC3.js → chunk-D6ZWWDW5.js} +6 -5
  33. package/dist/bundle/chunks/{chunk-U4EAJPMO.js → chunk-EVDQRT3I.js} +252 -371
  34. package/dist/bundle/chunks/{chunk-FJIISX5W.js → chunk-F74XLJPC.js} +195 -192
  35. package/dist/bundle/chunks/chunk-FDRBTGFJ.js +4 -0
  36. package/dist/bundle/chunks/{chunk-E4VUW4RI.js → chunk-FLWO3H5J.js} +12 -12
  37. package/dist/bundle/chunks/{chunk-KLSRGGOH.js → chunk-G2PFPQX7.js} +2 -2
  38. package/dist/bundle/chunks/chunk-GMPJWLZS.js +57 -0
  39. package/dist/bundle/chunks/{chunk-M5TVWJ5T.js → chunk-H35P7ROY.js} +462 -441
  40. package/dist/bundle/chunks/chunk-HCHCYBNK.js +2 -0
  41. package/dist/bundle/chunks/{chunk-7WE77IE3.js → chunk-HRNYDRL7.js} +1 -1
  42. package/dist/bundle/chunks/chunk-HWFAAGYK.js +23 -0
  43. package/dist/bundle/chunks/{chunk-G2QMON4O.js → chunk-HWXQCJDP.js} +408 -392
  44. package/dist/bundle/chunks/{chunk-PVNXN2TC.js → chunk-II5C7G67.js} +1 -1
  45. package/dist/bundle/chunks/{chunk-F2H47FRF.js → chunk-IMRZP5SC.js} +182 -137
  46. package/dist/bundle/chunks/{chunk-H2B3WLIM.js → chunk-J5YFXMTM.js} +4 -4
  47. package/dist/bundle/chunks/chunk-J64VNQ6D.js +13 -0
  48. package/dist/bundle/chunks/{chunk-65FLSKDA.js → chunk-K5EFEIFP.js} +5 -4
  49. package/dist/bundle/chunks/{chunk-KI7CHPWC.js → chunk-KJ3QRSSY.js} +46 -43
  50. package/dist/bundle/chunks/{cli-6DJO467D.js → chunk-KSEO2LRK.js} +12 -10
  51. package/dist/bundle/chunks/{chunk-HHWVVNGG.js → chunk-MA2WCMSN.js} +2 -2
  52. package/dist/bundle/chunks/{chunk-L4J7SMJB.js → chunk-MAEKQSFU.js} +1 -1
  53. package/dist/bundle/chunks/chunk-MHQNLTZR.js +8 -0
  54. package/dist/bundle/chunks/chunk-MLOUZAVZ.js +122 -0
  55. package/dist/bundle/chunks/chunk-MQYR4Q6X.js +5 -0
  56. package/dist/bundle/chunks/chunk-MXF3KYLZ.js +4 -0
  57. package/dist/bundle/chunks/{chunk-GY663MNP.js → chunk-MZRTVX7F.js} +1 -1
  58. package/dist/bundle/chunks/chunk-MZYHSWHX.js +59 -0
  59. package/dist/bundle/chunks/{chunk-6HTHDVJC.js → chunk-NPVRWPGX.js} +1 -1
  60. package/dist/bundle/chunks/{chunk-BRSLXHED.js → chunk-O44A4E4K.js} +1 -1
  61. package/dist/bundle/chunks/{chunk-T2ZGMEMV.js → chunk-OADQOW67.js} +175 -260
  62. package/dist/bundle/chunks/chunk-OTVHRZ67.js +17 -0
  63. package/dist/bundle/chunks/{chunk-J4GII2EE.js → chunk-P7SLTLSZ.js} +51 -46
  64. package/dist/bundle/chunks/{chunk-7OZNMWAJ.js → chunk-PPGSQZZF.js} +1 -1
  65. package/dist/bundle/chunks/chunk-PYX6ZCC7.js +29 -0
  66. package/dist/bundle/chunks/chunk-PZ7NYBHJ.js +8 -0
  67. package/dist/bundle/chunks/{chunk-VCMXBP5S.js → chunk-QESIDBMW.js} +1 -7
  68. package/dist/bundle/chunks/chunk-QUWVILLB.js +3 -0
  69. package/dist/bundle/chunks/chunk-QZWUXGY7.js +99 -0
  70. package/dist/bundle/chunks/{chunk-MIAXMK5F.js → chunk-QZXLTW7V.js} +8 -7
  71. package/dist/bundle/chunks/chunk-RP6MWUAP.js +4 -0
  72. package/dist/bundle/chunks/chunk-S2US54IU.js +37 -0
  73. package/dist/bundle/chunks/{chunk-H7UPU2SH.js → chunk-SOE25WIS.js} +1218 -1239
  74. package/dist/bundle/chunks/{chunk-JSZBTGI6.js → chunk-SZZ5PNP6.js} +2 -2
  75. package/dist/bundle/chunks/chunk-T5WECB2D.js +7 -0
  76. package/dist/bundle/chunks/{chunk-2NVGOSBN.js → chunk-T7F2TEIS.js} +37 -13
  77. package/dist/bundle/chunks/{chunk-ZSWU5KKA.js → chunk-UOSJTMCL.js} +7 -3
  78. package/dist/bundle/chunks/{chunk-6P6MMQUH.js → chunk-UTRUALFN.js} +3 -3
  79. package/dist/bundle/chunks/{chunk-PWFM6AQQ.js → chunk-V2HTCZRF.js} +70 -67
  80. package/dist/bundle/chunks/{chunk-JX6YIPNK.js → chunk-WCKS2DPT.js} +1 -1
  81. package/dist/bundle/chunks/chunk-XGOJCV6Z.js +2 -0
  82. package/dist/bundle/chunks/chunk-XGSJX23G.js +1151 -0
  83. package/dist/bundle/chunks/{chunk-7WETECIB.js → chunk-Z7BWHPJ2.js} +1 -1
  84. package/dist/bundle/chunks/chunk-ZFFDBTG3.js +17 -0
  85. package/dist/bundle/chunks/cli-NJLV3XDZ.js +3 -0
  86. package/dist/bundle/chunks/{cloudflare-workers-ai-system-one-JEZVYITT.js → cloudflare-workers-ai-system-one-ZAZW4M4B.js} +1 -1
  87. package/dist/bundle/chunks/{compat-ELBUCH6U.js → compat-7UJJAO4E.js} +12 -12
  88. package/dist/bundle/chunks/{curator-server-QB4GITGS.js → curator-server-MW645JI3.js} +2 -2
  89. package/dist/bundle/chunks/{dist-NERIS6SW.js → dist-7PCCEUQF.js} +2 -2
  90. package/dist/bundle/chunks/{dist-QSYDYE3Y.js → dist-I53JI67E.js} +9 -9
  91. package/dist/bundle/chunks/{dist-35STTNYA.js → dist-NI2PTSLH.js} +1 -1
  92. package/dist/bundle/chunks/{dist-CBODG4CA.js → dist-VXQT3DQY.js} +6 -6
  93. package/dist/bundle/chunks/{dist-cjs-EROMDUKS.js → dist-cjs-4JQA6W3S.js} +31 -31
  94. package/dist/bundle/chunks/doctor-KJVAYG3F.js +83 -0
  95. package/dist/bundle/chunks/{easter-egg-3d-VZC5WOYV.js → easter-egg-3d-Z24JLXD4.js} +1 -1
  96. package/dist/bundle/chunks/entry-3EL6GOWK.js +2 -0
  97. package/dist/bundle/chunks/{entry-SRYLSS5P.js → entry-4IMREZBD.js} +80 -79
  98. package/dist/bundle/chunks/{execute-6MEJJF2T.js → execute-C4BZQRPQ.js} +23 -22
  99. package/dist/bundle/chunks/{extract-L373D6O7.js → extract-XVQCIS7D.js} +5 -5
  100. package/dist/bundle/chunks/{flow-implementer-3P3BHQ7E.js → flow-implementer-GE2ARQKR.js} +5 -5
  101. package/dist/bundle/chunks/github-copilot.js +57 -56
  102. package/dist/bundle/chunks/google-generative-ai-P2P45MYP.js +22 -0
  103. package/dist/bundle/chunks/google-vertex-SHY4IS5F.js +26 -0
  104. package/dist/bundle/chunks/{host-WOLZCWQQ.js → host-YESS2VAB.js} +1 -1
  105. package/dist/bundle/chunks/{index.bundle-HONF3PUD.js → index.bundle-TZT64KLH.js} +102 -89
  106. package/dist/bundle/chunks/{inprocess-3PDJKE5F.js → inprocess-MGMVI6HN.js} +6 -6
  107. package/dist/bundle/chunks/interactive-mode-HHWOE4FD.js +5 -0
  108. package/dist/bundle/chunks/{llama-cpp-classify-KYZT532X.js → llama-cpp-classify-RSRH4KV2.js} +5 -5
  109. package/dist/bundle/chunks/mistral-conversations-YTMJKHHI.js +42 -0
  110. package/dist/bundle/chunks/{node-N7TPBUJB.js → node-FF6QQQLH.js} +1 -1
  111. package/dist/bundle/chunks/openai-codex-responses-NUCJOJSZ.js +97 -0
  112. package/dist/bundle/chunks/openai-completions-E5NRJUHA.js +91 -0
  113. package/dist/bundle/chunks/{openai-decisions-JMSDGR7K.js → openai-decisions-342J5ZYG.js} +1 -1
  114. package/dist/bundle/chunks/openai-responses-BN5Z4HFI.js +26 -0
  115. package/dist/bundle/chunks/openrouter-images-7RNG3JVF.js +12 -0
  116. package/dist/bundle/chunks/{pdfjs-FE3L72A6.js → pdfjs-LSTLRXQW.js} +1415 -1416
  117. package/dist/bundle/chunks/pi-messages-2L7FV5OK.js +22 -0
  118. package/dist/bundle/chunks/questionnaire-session-XEVAK7JS.js +123 -0
  119. package/dist/bundle/chunks/runtime-2FSZRUG5.js +2 -0
  120. package/dist/bundle/chunks/session-picker-666KJIVM.js +4 -0
  121. package/dist/bundle/chunks/startup-ui-INEVSNGK.js +3 -0
  122. package/dist/bundle/chunks/{trace-command-VM7FBWPE.js → trace-command-BCVMZ5ZD.js} +4 -4
  123. package/dist/bundle/chunks/typesafe-system-one-UJUNSZG4.js +3 -0
  124. package/dist/bundle/chunks/{undici-WVNE45GY.js → undici-7IGAYA4S.js} +1 -1
  125. package/dist/bundle/chunks/virtual-modules-UXSSFNV5.js +29 -0
  126. package/dist/bundle/cli-runtime.js +5 -5
  127. package/dist/bundle/flow/package.json +3 -3
  128. package/dist/bundle/index.js +13 -13
  129. package/dist/bundle/orchestrate/package.json +1 -1
  130. package/dist/bundle/rpc-entry.js +5 -4
  131. package/dist/cli/agent-dir-arg.d.ts +12 -0
  132. package/dist/cli/agent-dir-arg.d.ts.map +1 -0
  133. package/dist/cli/agent-dir-arg.js +15 -0
  134. package/dist/cli/agent-dir-arg.js.map +1 -0
  135. package/dist/cli/args.d.ts +9 -0
  136. package/dist/cli/args.d.ts.map +1 -1
  137. package/dist/cli/args.js +19 -5
  138. package/dist/cli/args.js.map +1 -1
  139. package/dist/cli/auth-check.d.ts +1 -1
  140. package/dist/cli/auth-check.d.ts.map +1 -1
  141. package/dist/cli/auth-check.js +4 -2
  142. package/dist/cli/auth-check.js.map +1 -1
  143. package/dist/cli/doctor-config.d.ts +14 -0
  144. package/dist/cli/doctor-config.d.ts.map +1 -0
  145. package/dist/cli/doctor-config.js +92 -0
  146. package/dist/cli/doctor-config.js.map +1 -0
  147. package/dist/cli/doctor-system.d.ts +12 -0
  148. package/dist/cli/doctor-system.d.ts.map +1 -0
  149. package/dist/cli/doctor-system.js +109 -0
  150. package/dist/cli/doctor-system.js.map +1 -0
  151. package/dist/cli/doctor.d.ts +11 -0
  152. package/dist/cli/doctor.d.ts.map +1 -0
  153. package/dist/cli/doctor.js +323 -0
  154. package/dist/cli/doctor.js.map +1 -0
  155. package/dist/cli/doctor.lazy.d.ts +3 -0
  156. package/dist/cli/doctor.lazy.d.ts.map +1 -0
  157. package/dist/cli/doctor.lazy.js +3 -0
  158. package/dist/cli/doctor.lazy.js.map +1 -0
  159. package/dist/cli/list-models.d.ts.map +1 -1
  160. package/dist/cli/list-models.js +0 -4
  161. package/dist/cli/list-models.js.map +1 -1
  162. package/dist/cli/project-trust.d.ts.map +1 -1
  163. package/dist/cli/project-trust.js +6 -6
  164. package/dist/cli/project-trust.js.map +1 -1
  165. package/dist/cli/startup-ui.d.ts +3 -2
  166. package/dist/cli/startup-ui.d.ts.map +1 -1
  167. package/dist/cli/startup-ui.js +23 -10
  168. package/dist/cli/startup-ui.js.map +1 -1
  169. package/dist/config.d.ts +5 -1
  170. package/dist/config.d.ts.map +1 -1
  171. package/dist/config.js +13 -3
  172. package/dist/config.js.map +1 -1
  173. package/dist/coordination/adapter/delivery.d.ts +27 -0
  174. package/dist/coordination/adapter/delivery.d.ts.map +1 -1
  175. package/dist/coordination/adapter/delivery.js +164 -4
  176. package/dist/coordination/adapter/delivery.js.map +1 -1
  177. package/dist/coordination/adapter/index.d.ts.map +1 -1
  178. package/dist/coordination/adapter/index.js +31 -5
  179. package/dist/coordination/adapter/index.js.map +1 -1
  180. package/dist/coordination/adapter/presence.d.ts +5 -0
  181. package/dist/coordination/adapter/presence.d.ts.map +1 -1
  182. package/dist/coordination/adapter/presence.js +25 -3
  183. package/dist/coordination/adapter/presence.js.map +1 -1
  184. package/dist/coordination/adapter/question-routing.d.ts +7 -0
  185. package/dist/coordination/adapter/question-routing.d.ts.map +1 -0
  186. package/dist/coordination/adapter/question-routing.js +40 -0
  187. package/dist/coordination/adapter/question-routing.js.map +1 -0
  188. package/dist/coordination/adapter/receipts.d.ts +7 -0
  189. package/dist/coordination/adapter/receipts.d.ts.map +1 -1
  190. package/dist/coordination/adapter/receipts.js +25 -2
  191. package/dist/coordination/adapter/receipts.js.map +1 -1
  192. package/dist/coordination/adapter/tool.d.ts +19 -3
  193. package/dist/coordination/adapter/tool.d.ts.map +1 -1
  194. package/dist/coordination/adapter/tool.js +93 -19
  195. package/dist/coordination/adapter/tool.js.map +1 -1
  196. package/dist/coordination/broker/broker.d.ts +3 -3
  197. package/dist/coordination/broker/broker.d.ts.map +1 -1
  198. package/dist/coordination/broker/broker.js +15 -7
  199. package/dist/coordination/broker/broker.js.map +1 -1
  200. package/dist/coordination/client/client.d.ts +2 -2
  201. package/dist/coordination/client/client.d.ts.map +1 -1
  202. package/dist/coordination/client/client.js +4 -0
  203. package/dist/coordination/client/client.js.map +1 -1
  204. package/dist/coordination/transport/protocol.d.ts.map +1 -1
  205. package/dist/coordination/transport/protocol.js +23 -0
  206. package/dist/coordination/transport/protocol.js.map +1 -1
  207. package/dist/coordination/transport/types.d.ts +11 -1
  208. package/dist/coordination/transport/types.d.ts.map +1 -1
  209. package/dist/coordination/transport/types.js.map +1 -1
  210. package/dist/core/acceptance-command.d.ts +6 -3
  211. package/dist/core/acceptance-command.d.ts.map +1 -1
  212. package/dist/core/acceptance-command.js +43 -12
  213. package/dist/core/acceptance-command.js.map +1 -1
  214. package/dist/core/acceptance-ledger.d.ts +2 -0
  215. package/dist/core/acceptance-ledger.d.ts.map +1 -1
  216. package/dist/core/acceptance-ledger.js +14 -3
  217. package/dist/core/acceptance-ledger.js.map +1 -1
  218. package/dist/core/agent-session-runtime.d.ts +11 -4
  219. package/dist/core/agent-session-runtime.d.ts.map +1 -1
  220. package/dist/core/agent-session-runtime.js +13 -4
  221. package/dist/core/agent-session-runtime.js.map +1 -1
  222. package/dist/core/agent-session-services.d.ts.map +1 -1
  223. package/dist/core/agent-session-services.js +6 -0
  224. package/dist/core/agent-session-services.js.map +1 -1
  225. package/dist/core/agent-session.d.ts +19 -1
  226. package/dist/core/agent-session.d.ts.map +1 -1
  227. package/dist/core/agent-session.js +131 -36
  228. package/dist/core/agent-session.js.map +1 -1
  229. package/dist/core/auth-storage.d.ts.map +1 -1
  230. package/dist/core/auth-storage.js +7 -1
  231. package/dist/core/auth-storage.js.map +1 -1
  232. package/dist/core/bash-executor.d.ts +3 -1
  233. package/dist/core/bash-executor.d.ts.map +1 -1
  234. package/dist/core/bash-executor.js +18 -8
  235. package/dist/core/bash-executor.js.map +1 -1
  236. package/dist/core/compaction/branch-summarization.d.ts +2 -2
  237. package/dist/core/compaction/branch-summarization.d.ts.map +1 -1
  238. package/dist/core/compaction/branch-summarization.js +9 -15
  239. package/dist/core/compaction/branch-summarization.js.map +1 -1
  240. package/dist/core/compaction/compaction.d.ts.map +1 -1
  241. package/dist/core/compaction/compaction.js +3 -0
  242. package/dist/core/compaction/compaction.js.map +1 -1
  243. package/dist/core/export-html/index.d.ts.map +1 -1
  244. package/dist/core/export-html/index.js +12 -10
  245. package/dist/core/export-html/index.js.map +1 -1
  246. package/dist/core/export-html/template.js +23 -1
  247. package/dist/core/extensions/runner.d.ts.map +1 -1
  248. package/dist/core/extensions/runner.js +13 -2
  249. package/dist/core/extensions/runner.js.map +1 -1
  250. package/dist/core/extensions/types.d.ts +9 -1
  251. package/dist/core/extensions/types.d.ts.map +1 -1
  252. package/dist/core/extensions/types.js.map +1 -1
  253. package/dist/core/footer-data-provider.d.ts.map +1 -1
  254. package/dist/core/footer-data-provider.js +2 -4
  255. package/dist/core/footer-data-provider.js.map +1 -1
  256. package/dist/core/http-dispatcher.d.ts +5 -2
  257. package/dist/core/http-dispatcher.d.ts.map +1 -1
  258. package/dist/core/http-dispatcher.js +6 -3
  259. package/dist/core/http-dispatcher.js.map +1 -1
  260. package/dist/core/keybindings.d.ts +20 -0
  261. package/dist/core/keybindings.d.ts.map +1 -1
  262. package/dist/core/keybindings.js +4 -1
  263. package/dist/core/keybindings.js.map +1 -1
  264. package/dist/core/mcp-servers.d.ts +29 -0
  265. package/dist/core/mcp-servers.d.ts.map +1 -1
  266. package/dist/core/mcp-servers.js +63 -17
  267. package/dist/core/mcp-servers.js.map +1 -1
  268. package/dist/core/messages.d.ts +4 -0
  269. package/dist/core/messages.d.ts.map +1 -1
  270. package/dist/core/messages.js +10 -2
  271. package/dist/core/messages.js.map +1 -1
  272. package/dist/core/model-config.d.ts +36 -0
  273. package/dist/core/model-config.d.ts.map +1 -1
  274. package/dist/core/model-resolver.js +1 -1
  275. package/dist/core/model-resolver.js.map +1 -1
  276. package/dist/core/model-runtime.d.ts.map +1 -1
  277. package/dist/core/model-runtime.js +20 -10
  278. package/dist/core/model-runtime.js.map +1 -1
  279. package/dist/core/nested-tool-calls.d.ts +6 -5
  280. package/dist/core/nested-tool-calls.d.ts.map +1 -1
  281. package/dist/core/nested-tool-calls.js +1 -3
  282. package/dist/core/nested-tool-calls.js.map +1 -1
  283. package/dist/core/oauth-account-pool.d.ts +14 -0
  284. package/dist/core/oauth-account-pool.d.ts.map +1 -1
  285. package/dist/core/oauth-account-pool.js +166 -14
  286. package/dist/core/oauth-account-pool.js.map +1 -1
  287. package/dist/core/os-secret-store.js +1 -1
  288. package/dist/core/os-secret-store.js.map +1 -1
  289. package/dist/core/package-manager.d.ts +3 -1
  290. package/dist/core/package-manager.d.ts.map +1 -1
  291. package/dist/core/package-manager.js +25 -4
  292. package/dist/core/package-manager.js.map +1 -1
  293. package/dist/core/pi-ai-schemas.d.ts +4 -0
  294. package/dist/core/pi-ai-schemas.d.ts.map +1 -1
  295. package/dist/core/project-trust.d.ts.map +1 -1
  296. package/dist/core/project-trust.js +1 -1
  297. package/dist/core/project-trust.js.map +1 -1
  298. package/dist/core/provider-composer.d.ts +1 -0
  299. package/dist/core/provider-composer.d.ts.map +1 -1
  300. package/dist/core/provider-composer.js +1 -0
  301. package/dist/core/provider-composer.js.map +1 -1
  302. package/dist/core/resolve-config-value.d.ts +4 -0
  303. package/dist/core/resolve-config-value.d.ts.map +1 -1
  304. package/dist/core/resolve-config-value.js +14 -3
  305. package/dist/core/resolve-config-value.js.map +1 -1
  306. package/dist/core/resource-loader.d.ts.map +1 -1
  307. package/dist/core/resource-loader.js +40 -2
  308. package/dist/core/resource-loader.js.map +1 -1
  309. package/dist/core/run-outcome.d.ts +1 -1
  310. package/dist/core/run-outcome.d.ts.map +1 -1
  311. package/dist/core/run-outcome.js +2 -2
  312. package/dist/core/run-outcome.js.map +1 -1
  313. package/dist/core/run-preflight.d.ts.map +1 -1
  314. package/dist/core/run-preflight.js +15 -8
  315. package/dist/core/run-preflight.js.map +1 -1
  316. package/dist/core/runtime-credentials.d.ts.map +1 -1
  317. package/dist/core/runtime-credentials.js +11 -7
  318. package/dist/core/runtime-credentials.js.map +1 -1
  319. package/dist/core/sdk.d.ts.map +1 -1
  320. package/dist/core/sdk.js +8 -4
  321. package/dist/core/sdk.js.map +1 -1
  322. package/dist/core/session-manager.d.ts +22 -1
  323. package/dist/core/session-manager.d.ts.map +1 -1
  324. package/dist/core/session-manager.js +227 -37
  325. package/dist/core/session-manager.js.map +1 -1
  326. package/dist/core/settings-defaults.d.ts +10 -1
  327. package/dist/core/settings-defaults.d.ts.map +1 -1
  328. package/dist/core/settings-defaults.js +7 -1
  329. package/dist/core/settings-defaults.js.map +1 -1
  330. package/dist/core/settings-manager.d.ts +14 -4
  331. package/dist/core/settings-manager.d.ts.map +1 -1
  332. package/dist/core/settings-manager.js +48 -15
  333. package/dist/core/settings-manager.js.map +1 -1
  334. package/dist/core/settings-schema.d.ts +20 -2
  335. package/dist/core/settings-schema.d.ts.map +1 -1
  336. package/dist/core/settings-schema.js +27 -4
  337. package/dist/core/settings-schema.js.map +1 -1
  338. package/dist/core/slash-commands.d.ts.map +1 -1
  339. package/dist/core/slash-commands.js +2 -0
  340. package/dist/core/slash-commands.js.map +1 -1
  341. package/dist/core/tools/bash-jobs.js +2 -2
  342. package/dist/core/tools/bash-jobs.js.map +1 -1
  343. package/dist/core/tools/bash.d.ts +3 -0
  344. package/dist/core/tools/bash.d.ts.map +1 -1
  345. package/dist/core/tools/bash.js +78 -46
  346. package/dist/core/tools/bash.js.map +1 -1
  347. package/dist/core/tools/edit-diff.d.ts +7 -1
  348. package/dist/core/tools/edit-diff.d.ts.map +1 -1
  349. package/dist/core/tools/edit-diff.js +139 -75
  350. package/dist/core/tools/edit-diff.js.map +1 -1
  351. package/dist/core/tools/edit.d.ts.map +1 -1
  352. package/dist/core/tools/edit.js +4 -1
  353. package/dist/core/tools/edit.js.map +1 -1
  354. package/dist/core/tools/output-accumulator.d.ts +21 -6
  355. package/dist/core/tools/output-accumulator.d.ts.map +1 -1
  356. package/dist/core/tools/output-accumulator.js +90 -76
  357. package/dist/core/tools/output-accumulator.js.map +1 -1
  358. package/dist/core/tools/render-utils.d.ts +7 -2
  359. package/dist/core/tools/render-utils.d.ts.map +1 -1
  360. package/dist/core/tools/render-utils.js +14 -1
  361. package/dist/core/tools/render-utils.js.map +1 -1
  362. package/dist/core/tools/renderers/bash.d.ts.map +1 -1
  363. package/dist/core/tools/renderers/bash.js +9 -3
  364. package/dist/core/tools/renderers/bash.js.map +1 -1
  365. package/dist/core/tools/truncate.d.ts +1 -1
  366. package/dist/core/tools/truncate.d.ts.map +1 -1
  367. package/dist/core/tools/truncate.js +16 -7
  368. package/dist/core/tools/truncate.js.map +1 -1
  369. package/dist/core/tools/write.d.ts.map +1 -1
  370. package/dist/core/tools/write.js +2 -0
  371. package/dist/core/tools/write.js.map +1 -1
  372. package/dist/core/trust-manager.d.ts +2 -0
  373. package/dist/core/trust-manager.d.ts.map +1 -1
  374. package/dist/core/trust-manager.js +5 -4
  375. package/dist/core/trust-manager.js.map +1 -1
  376. package/dist/core/usage-totals.d.ts.map +1 -1
  377. package/dist/core/usage-totals.js +3 -0
  378. package/dist/core/usage-totals.js.map +1 -1
  379. package/dist/extensions/codemode/execute.d.ts.map +1 -1
  380. package/dist/extensions/codemode/execute.js +64 -20
  381. package/dist/extensions/codemode/execute.js.map +1 -1
  382. package/dist/extensions/codemode/renderer.d.ts.map +1 -1
  383. package/dist/extensions/codemode/renderer.js +8 -3
  384. package/dist/extensions/codemode/renderer.js.map +1 -1
  385. package/dist/extensions/codemode/tool.d.ts +5 -0
  386. package/dist/extensions/codemode/tool.d.ts.map +1 -1
  387. package/dist/extensions/codemode/tool.js.map +1 -1
  388. package/dist/extensions/llama/client.d.ts.map +1 -1
  389. package/dist/extensions/llama/client.js +3 -13
  390. package/dist/extensions/llama/client.js.map +1 -1
  391. package/dist/extensions/llama/ui.d.ts.map +1 -1
  392. package/dist/extensions/llama/ui.js +2 -1
  393. package/dist/extensions/llama/ui.js.map +1 -1
  394. package/dist/extensions/mcp/cli.d.ts +7 -0
  395. package/dist/extensions/mcp/cli.d.ts.map +1 -1
  396. package/dist/extensions/mcp/cli.js +35 -8
  397. package/dist/extensions/mcp/cli.js.map +1 -1
  398. package/dist/extensions/mcp/config.d.ts +33 -0
  399. package/dist/extensions/mcp/config.d.ts.map +1 -1
  400. package/dist/extensions/mcp/config.js +11 -2
  401. package/dist/extensions/mcp/config.js.map +1 -1
  402. package/dist/extensions/mcp/index.d.ts +8 -0
  403. package/dist/extensions/mcp/index.d.ts.map +1 -1
  404. package/dist/extensions/mcp/index.js +16 -0
  405. package/dist/extensions/mcp/index.js.map +1 -1
  406. package/dist/extensions/mcp/resources.d.ts +1 -1
  407. package/dist/extensions/mcp/resources.d.ts.map +1 -1
  408. package/dist/extensions/mcp/resources.js +4 -3
  409. package/dist/extensions/mcp/resources.js.map +1 -1
  410. package/dist/extensions/mcp/runtime.d.ts +1 -1
  411. package/dist/extensions/mcp/runtime.d.ts.map +1 -1
  412. package/dist/extensions/mcp/runtime.js +15 -14
  413. package/dist/extensions/mcp/runtime.js.map +1 -1
  414. package/dist/extensions/mcp/tools.d.ts +1 -24
  415. package/dist/extensions/mcp/tools.d.ts.map +1 -1
  416. package/dist/extensions/mcp/tools.js +10 -163
  417. package/dist/extensions/mcp/tools.js.map +1 -1
  418. package/dist/humain/ask-user-question/index.d.ts +4 -0
  419. package/dist/humain/ask-user-question/index.d.ts.map +1 -0
  420. package/dist/humain/ask-user-question/index.js +18 -0
  421. package/dist/humain/ask-user-question/index.js.map +1 -0
  422. package/dist/humain/ask-user-question/vendor/ask/answer-channel.d.ts +38 -0
  423. package/dist/humain/ask-user-question/vendor/ask/answer-channel.d.ts.map +1 -0
  424. package/dist/humain/ask-user-question/vendor/ask/answer-channel.js +97 -0
  425. package/dist/humain/ask-user-question/vendor/ask/answer-channel.js.map +1 -0
  426. package/dist/humain/ask-user-question/vendor/ask/ask-user-question.d.ts +41 -0
  427. package/dist/humain/ask-user-question/vendor/ask/ask-user-question.d.ts.map +1 -0
  428. package/dist/humain/ask-user-question/vendor/ask/ask-user-question.js +441 -0
  429. package/dist/humain/ask-user-question/vendor/ask/ask-user-question.js.map +1 -0
  430. package/dist/humain/ask-user-question/vendor/ask/config.d.ts +39 -0
  431. package/dist/humain/ask-user-question/vendor/ask/config.d.ts.map +1 -0
  432. package/dist/humain/ask-user-question/vendor/ask/config.js +95 -0
  433. package/dist/humain/ask-user-question/vendor/ask/config.js.map +1 -0
  434. package/dist/humain/ask-user-question/vendor/ask/events.d.ts +132 -0
  435. package/dist/humain/ask-user-question/vendor/ask/events.d.ts.map +1 -0
  436. package/dist/humain/ask-user-question/vendor/ask/events.js +50 -0
  437. package/dist/humain/ask-user-question/vendor/ask/events.js.map +1 -0
  438. package/dist/humain/ask-user-question/vendor/ask/index.d.ts +5 -0
  439. package/dist/humain/ask-user-question/vendor/ask/index.d.ts.map +1 -0
  440. package/dist/humain/ask-user-question/vendor/ask/index.js +15 -0
  441. package/dist/humain/ask-user-question/vendor/ask/index.js.map +1 -0
  442. package/dist/humain/ask-user-question/vendor/ask/presentation.d.ts +81 -0
  443. package/dist/humain/ask-user-question/vendor/ask/presentation.d.ts.map +1 -0
  444. package/dist/humain/ask-user-question/vendor/ask/presentation.js +105 -0
  445. package/dist/humain/ask-user-question/vendor/ask/presentation.js.map +1 -0
  446. package/dist/humain/ask-user-question/vendor/ask/reconcile.d.ts +28 -0
  447. package/dist/humain/ask-user-question/vendor/ask/reconcile.d.ts.map +1 -0
  448. package/dist/humain/ask-user-question/vendor/ask/reconcile.js +45 -0
  449. package/dist/humain/ask-user-question/vendor/ask/reconcile.js.map +1 -0
  450. package/dist/humain/ask-user-question/vendor/ask/rpc-fallback.d.ts +41 -0
  451. package/dist/humain/ask-user-question/vendor/ask/rpc-fallback.d.ts.map +1 -0
  452. package/dist/humain/ask-user-question/vendor/ask/rpc-fallback.js +166 -0
  453. package/dist/humain/ask-user-question/vendor/ask/rpc-fallback.js.map +1 -0
  454. package/dist/humain/ask-user-question/vendor/ask/state/build-questionnaire.d.ts +46 -0
  455. package/dist/humain/ask-user-question/vendor/ask/state/build-questionnaire.d.ts.map +1 -0
  456. package/dist/humain/ask-user-question/vendor/ask/state/build-questionnaire.js +247 -0
  457. package/dist/humain/ask-user-question/vendor/ask/state/build-questionnaire.js.map +1 -0
  458. package/dist/humain/ask-user-question/vendor/ask/state/external-editor.d.ts +11 -0
  459. package/dist/humain/ask-user-question/vendor/ask/state/external-editor.d.ts.map +1 -0
  460. package/dist/humain/ask-user-question/vendor/ask/state/external-editor.js +56 -0
  461. package/dist/humain/ask-user-question/vendor/ask/state/external-editor.js.map +1 -0
  462. package/dist/humain/ask-user-question/vendor/ask/state/i18n-bridge.d.ts +6 -0
  463. package/dist/humain/ask-user-question/vendor/ask/state/i18n-bridge.d.ts.map +1 -0
  464. package/dist/humain/ask-user-question/vendor/ask/state/i18n-bridge.js +10 -0
  465. package/dist/humain/ask-user-question/vendor/ask/state/i18n-bridge.js.map +1 -0
  466. package/dist/humain/ask-user-question/vendor/ask/state/key-router.d.ts +57 -0
  467. package/dist/humain/ask-user-question/vendor/ask/state/key-router.d.ts.map +1 -0
  468. package/dist/humain/ask-user-question/vendor/ask/state/key-router.js +357 -0
  469. package/dist/humain/ask-user-question/vendor/ask/state/key-router.js.map +1 -0
  470. package/dist/humain/ask-user-question/vendor/ask/state/questionnaire-session.d.ts +112 -0
  471. package/dist/humain/ask-user-question/vendor/ask/state/questionnaire-session.d.ts.map +1 -0
  472. package/dist/humain/ask-user-question/vendor/ask/state/questionnaire-session.js +240 -0
  473. package/dist/humain/ask-user-question/vendor/ask/state/questionnaire-session.js.map +1 -0
  474. package/dist/humain/ask-user-question/vendor/ask/state/row-intent.d.ts +87 -0
  475. package/dist/humain/ask-user-question/vendor/ask/state/row-intent.d.ts.map +1 -0
  476. package/dist/humain/ask-user-question/vendor/ask/state/row-intent.js +79 -0
  477. package/dist/humain/ask-user-question/vendor/ask/state/row-intent.js.map +1 -0
  478. package/dist/humain/ask-user-question/vendor/ask/state/selectors/contract.d.ts +22 -0
  479. package/dist/humain/ask-user-question/vendor/ask/state/selectors/contract.d.ts.map +1 -0
  480. package/dist/humain/ask-user-question/vendor/ask/state/selectors/contract.js +2 -0
  481. package/dist/humain/ask-user-question/vendor/ask/state/selectors/contract.js.map +1 -0
  482. package/dist/humain/ask-user-question/vendor/ask/state/selectors/derivations.d.ts +27 -0
  483. package/dist/humain/ask-user-question/vendor/ask/state/selectors/derivations.d.ts.map +1 -0
  484. package/dist/humain/ask-user-question/vendor/ask/state/selectors/derivations.js +48 -0
  485. package/dist/humain/ask-user-question/vendor/ask/state/selectors/derivations.js.map +1 -0
  486. package/dist/humain/ask-user-question/vendor/ask/state/selectors/focus.d.ts +13 -0
  487. package/dist/humain/ask-user-question/vendor/ask/state/selectors/focus.d.ts.map +1 -0
  488. package/dist/humain/ask-user-question/vendor/ask/state/selectors/focus.js +15 -0
  489. package/dist/humain/ask-user-question/vendor/ask/state/selectors/focus.js.map +1 -0
  490. package/dist/humain/ask-user-question/vendor/ask/state/selectors/projections.d.ts +14 -0
  491. package/dist/humain/ask-user-question/vendor/ask/state/selectors/projections.d.ts.map +1 -0
  492. package/dist/humain/ask-user-question/vendor/ask/state/selectors/projections.js +96 -0
  493. package/dist/humain/ask-user-question/vendor/ask/state/selectors/projections.js.map +1 -0
  494. package/dist/humain/ask-user-question/vendor/ask/state/state-reducer.d.ts +58 -0
  495. package/dist/humain/ask-user-question/vendor/ask/state/state-reducer.d.ts.map +1 -0
  496. package/dist/humain/ask-user-question/vendor/ask/state/state-reducer.js +310 -0
  497. package/dist/humain/ask-user-question/vendor/ask/state/state-reducer.js.map +1 -0
  498. package/dist/humain/ask-user-question/vendor/ask/state/state.d.ts +68 -0
  499. package/dist/humain/ask-user-question/vendor/ask/state/state.d.ts.map +1 -0
  500. package/dist/humain/ask-user-question/vendor/ask/state/state.js +2 -0
  501. package/dist/humain/ask-user-question/vendor/ask/state/state.js.map +1 -0
  502. package/dist/humain/ask-user-question/vendor/ask/tool/external-answer.d.ts +24 -0
  503. package/dist/humain/ask-user-question/vendor/ask/tool/external-answer.d.ts.map +1 -0
  504. package/dist/humain/ask-user-question/vendor/ask/tool/external-answer.js +114 -0
  505. package/dist/humain/ask-user-question/vendor/ask/tool/external-answer.js.map +1 -0
  506. package/dist/humain/ask-user-question/vendor/ask/tool/format-answer.d.ts +18 -0
  507. package/dist/humain/ask-user-question/vendor/ask/tool/format-answer.d.ts.map +1 -0
  508. package/dist/humain/ask-user-question/vendor/ask/tool/format-answer.js +29 -0
  509. package/dist/humain/ask-user-question/vendor/ask/tool/format-answer.js.map +1 -0
  510. package/dist/humain/ask-user-question/vendor/ask/tool/normalize-params.d.ts +41 -0
  511. package/dist/humain/ask-user-question/vendor/ask/tool/normalize-params.d.ts.map +1 -0
  512. package/dist/humain/ask-user-question/vendor/ask/tool/normalize-params.js +99 -0
  513. package/dist/humain/ask-user-question/vendor/ask/tool/normalize-params.js.map +1 -0
  514. package/dist/humain/ask-user-question/vendor/ask/tool/response-envelope.d.ts +37 -0
  515. package/dist/humain/ask-user-question/vendor/ask/tool/response-envelope.d.ts.map +1 -0
  516. package/dist/humain/ask-user-question/vendor/ask/tool/response-envelope.js +70 -0
  517. package/dist/humain/ask-user-question/vendor/ask/tool/response-envelope.js.map +1 -0
  518. package/dist/humain/ask-user-question/vendor/ask/tool/types.d.ts +129 -0
  519. package/dist/humain/ask-user-question/vendor/ask/tool/types.d.ts.map +1 -0
  520. package/dist/humain/ask-user-question/vendor/ask/tool/types.js +76 -0
  521. package/dist/humain/ask-user-question/vendor/ask/tool/types.js.map +1 -0
  522. package/dist/humain/ask-user-question/vendor/ask/tool/validate-questionnaire.d.ts +21 -0
  523. package/dist/humain/ask-user-question/vendor/ask/tool/validate-questionnaire.d.ts.map +1 -0
  524. package/dist/humain/ask-user-question/vendor/ask/tool/validate-questionnaire.js +49 -0
  525. package/dist/humain/ask-user-question/vendor/ask/tool/validate-questionnaire.js.map +1 -0
  526. package/dist/humain/ask-user-question/vendor/ask/view/component-binding.d.ts +23 -0
  527. package/dist/humain/ask-user-question/vendor/ask/view/component-binding.d.ts.map +1 -0
  528. package/dist/humain/ask-user-question/vendor/ask/view/component-binding.js +16 -0
  529. package/dist/humain/ask-user-question/vendor/ask/view/component-binding.js.map +1 -0
  530. package/dist/humain/ask-user-question/vendor/ask/view/components/inline-input.d.ts +21 -0
  531. package/dist/humain/ask-user-question/vendor/ask/view/components/inline-input.d.ts.map +1 -0
  532. package/dist/humain/ask-user-question/vendor/ask/view/components/inline-input.js +49 -0
  533. package/dist/humain/ask-user-question/vendor/ask/view/components/inline-input.js.map +1 -0
  534. package/dist/humain/ask-user-question/vendor/ask/view/components/multi-select-view.d.ts +43 -0
  535. package/dist/humain/ask-user-question/vendor/ask/view/components/multi-select-view.d.ts.map +1 -0
  536. package/dist/humain/ask-user-question/vendor/ask/view/components/multi-select-view.js +130 -0
  537. package/dist/humain/ask-user-question/vendor/ask/view/components/multi-select-view.js.map +1 -0
  538. package/dist/humain/ask-user-question/vendor/ask/view/components/option-list-view.d.ts +45 -0
  539. package/dist/humain/ask-user-question/vendor/ask/view/components/option-list-view.d.ts.map +1 -0
  540. package/dist/humain/ask-user-question/vendor/ask/view/components/option-list-view.js +39 -0
  541. package/dist/humain/ask-user-question/vendor/ask/view/components/option-list-view.js.map +1 -0
  542. package/dist/humain/ask-user-question/vendor/ask/view/components/preview/markdown-content-cache.d.ts +36 -0
  543. package/dist/humain/ask-user-question/vendor/ask/view/components/preview/markdown-content-cache.d.ts.map +1 -0
  544. package/dist/humain/ask-user-question/vendor/ask/view/components/preview/markdown-content-cache.js +72 -0
  545. package/dist/humain/ask-user-question/vendor/ask/view/components/preview/markdown-content-cache.js.map +1 -0
  546. package/dist/humain/ask-user-question/vendor/ask/view/components/preview/preview-block-renderer.d.ts +61 -0
  547. package/dist/humain/ask-user-question/vendor/ask/view/components/preview/preview-block-renderer.d.ts.map +1 -0
  548. package/dist/humain/ask-user-question/vendor/ask/view/components/preview/preview-block-renderer.js +108 -0
  549. package/dist/humain/ask-user-question/vendor/ask/view/components/preview/preview-block-renderer.js.map +1 -0
  550. package/dist/humain/ask-user-question/vendor/ask/view/components/preview/preview-box-renderer.d.ts +39 -0
  551. package/dist/humain/ask-user-question/vendor/ask/view/components/preview/preview-box-renderer.d.ts.map +1 -0
  552. package/dist/humain/ask-user-question/vendor/ask/view/components/preview/preview-box-renderer.js +76 -0
  553. package/dist/humain/ask-user-question/vendor/ask/view/components/preview/preview-box-renderer.js.map +1 -0
  554. package/dist/humain/ask-user-question/vendor/ask/view/components/preview/preview-layout-decider.d.ts +123 -0
  555. package/dist/humain/ask-user-question/vendor/ask/view/components/preview/preview-layout-decider.d.ts.map +1 -0
  556. package/dist/humain/ask-user-question/vendor/ask/view/components/preview/preview-layout-decider.js +180 -0
  557. package/dist/humain/ask-user-question/vendor/ask/view/components/preview/preview-layout-decider.js.map +1 -0
  558. package/dist/humain/ask-user-question/vendor/ask/view/components/preview/preview-pane.d.ts +108 -0
  559. package/dist/humain/ask-user-question/vendor/ask/view/components/preview/preview-pane.d.ts.map +1 -0
  560. package/dist/humain/ask-user-question/vendor/ask/view/components/preview/preview-pane.js +235 -0
  561. package/dist/humain/ask-user-question/vendor/ask/view/components/preview/preview-pane.js.map +1 -0
  562. package/dist/humain/ask-user-question/vendor/ask/view/components/submit-picker.d.ts +37 -0
  563. package/dist/humain/ask-user-question/vendor/ask/view/components/submit-picker.d.ts.map +1 -0
  564. package/dist/humain/ask-user-question/vendor/ask/view/components/submit-picker.js +47 -0
  565. package/dist/humain/ask-user-question/vendor/ask/view/components/submit-picker.js.map +1 -0
  566. package/dist/humain/ask-user-question/vendor/ask/view/components/tab-bar.d.ts +31 -0
  567. package/dist/humain/ask-user-question/vendor/ask/view/components/tab-bar.d.ts.map +1 -0
  568. package/dist/humain/ask-user-question/vendor/ask/view/components/tab-bar.js +35 -0
  569. package/dist/humain/ask-user-question/vendor/ask/view/components/tab-bar.js.map +1 -0
  570. package/dist/humain/ask-user-question/vendor/ask/view/components/wrapping-select.d.ts +124 -0
  571. package/dist/humain/ask-user-question/vendor/ask/view/components/wrapping-select.d.ts.map +1 -0
  572. package/dist/humain/ask-user-question/vendor/ask/view/components/wrapping-select.js +205 -0
  573. package/dist/humain/ask-user-question/vendor/ask/view/components/wrapping-select.js.map +1 -0
  574. package/dist/humain/ask-user-question/vendor/ask/view/dialog-builder.d.ts +83 -0
  575. package/dist/humain/ask-user-question/vendor/ask/view/dialog-builder.d.ts.map +1 -0
  576. package/dist/humain/ask-user-question/vendor/ask/view/dialog-builder.js +186 -0
  577. package/dist/humain/ask-user-question/vendor/ask/view/dialog-builder.js.map +1 -0
  578. package/dist/humain/ask-user-question/vendor/ask/view/dialog-copy.d.ts +47 -0
  579. package/dist/humain/ask-user-question/vendor/ask/view/dialog-copy.d.ts.map +1 -0
  580. package/dist/humain/ask-user-question/vendor/ask/view/dialog-copy.js +48 -0
  581. package/dist/humain/ask-user-question/vendor/ask/view/dialog-copy.js.map +1 -0
  582. package/dist/humain/ask-user-question/vendor/ask/view/props-adapter.d.ts +58 -0
  583. package/dist/humain/ask-user-question/vendor/ask/view/props-adapter.d.ts.map +1 -0
  584. package/dist/humain/ask-user-question/vendor/ask/view/props-adapter.js +84 -0
  585. package/dist/humain/ask-user-question/vendor/ask/view/props-adapter.js.map +1 -0
  586. package/dist/humain/ask-user-question/vendor/ask/view/scroll-window.d.ts +20 -0
  587. package/dist/humain/ask-user-question/vendor/ask/view/scroll-window.d.ts.map +1 -0
  588. package/dist/humain/ask-user-question/vendor/ask/view/scroll-window.js +55 -0
  589. package/dist/humain/ask-user-question/vendor/ask/view/scroll-window.js.map +1 -0
  590. package/dist/humain/ask-user-question/vendor/ask/view/stateful-view.d.ts +23 -0
  591. package/dist/humain/ask-user-question/vendor/ask/view/stateful-view.d.ts.map +1 -0
  592. package/dist/humain/ask-user-question/vendor/ask/view/stateful-view.js +2 -0
  593. package/dist/humain/ask-user-question/vendor/ask/view/stateful-view.js.map +1 -0
  594. package/dist/humain/ask-user-question/vendor/ask/view/tab-components.d.ts +15 -0
  595. package/dist/humain/ask-user-question/vendor/ask/view/tab-components.d.ts.map +1 -0
  596. package/dist/humain/ask-user-question/vendor/ask/view/tab-components.js +2 -0
  597. package/dist/humain/ask-user-question/vendor/ask/view/tab-components.js.map +1 -0
  598. package/dist/humain/ask-user-question/vendor/ask/view/tab-content-strategy.d.ts +98 -0
  599. package/dist/humain/ask-user-question/vendor/ask/view/tab-content-strategy.d.ts.map +1 -0
  600. package/dist/humain/ask-user-question/vendor/ask/view/tab-content-strategy.js +248 -0
  601. package/dist/humain/ask-user-question/vendor/ask/view/tab-content-strategy.js.map +1 -0
  602. package/dist/humain/ask-user-question/vendor/ask/view/transcript.d.ts +23 -0
  603. package/dist/humain/ask-user-question/vendor/ask/view/transcript.d.ts.map +1 -0
  604. package/dist/humain/ask-user-question/vendor/ask/view/transcript.js +131 -0
  605. package/dist/humain/ask-user-question/vendor/ask/view/transcript.js.map +1 -0
  606. package/dist/humain/ask-user-question/vendor/config/config.d.ts +132 -0
  607. package/dist/humain/ask-user-question/vendor/config/config.d.ts.map +1 -0
  608. package/dist/humain/ask-user-question/vendor/config/config.js +286 -0
  609. package/dist/humain/ask-user-question/vendor/config/config.js.map +1 -0
  610. package/dist/humain/ask-user-question/vendor/config/index.d.ts +2 -0
  611. package/dist/humain/ask-user-question/vendor/config/index.d.ts.map +1 -0
  612. package/dist/humain/ask-user-question/vendor/config/index.js +2 -0
  613. package/dist/humain/ask-user-question/vendor/config/index.js.map +1 -0
  614. package/dist/humain/ask-user-question/vendor/i18n/i18n.d.ts +64 -0
  615. package/dist/humain/ask-user-question/vendor/i18n/i18n.d.ts.map +1 -0
  616. package/dist/humain/ask-user-question/vendor/i18n/i18n.js +185 -0
  617. package/dist/humain/ask-user-question/vendor/i18n/i18n.js.map +1 -0
  618. package/dist/humain/ask-user-question/vendor/i18n/loader.d.ts +44 -0
  619. package/dist/humain/ask-user-question/vendor/i18n/loader.d.ts.map +1 -0
  620. package/dist/humain/ask-user-question/vendor/i18n/loader.js +55 -0
  621. package/dist/humain/ask-user-question/vendor/i18n/loader.js.map +1 -0
  622. package/dist/humain/bedrock-provider/vendor/index.bundle.mjs +26 -16
  623. package/dist/humain/brand-logo.d.ts +2 -0
  624. package/dist/humain/brand-logo.d.ts.map +1 -1
  625. package/dist/humain/brand-logo.js +4 -0
  626. package/dist/humain/brand-logo.js.map +1 -1
  627. package/dist/humain/bundled-extension-names.d.ts +1 -0
  628. package/dist/humain/bundled-extension-names.d.ts.map +1 -1
  629. package/dist/humain/bundled-extension-names.js +1 -0
  630. package/dist/humain/bundled-extension-names.js.map +1 -1
  631. package/dist/humain/checklist/footer-progress.d.ts +7 -0
  632. package/dist/humain/checklist/footer-progress.d.ts.map +1 -0
  633. package/dist/humain/checklist/footer-progress.js +15 -0
  634. package/dist/humain/checklist/footer-progress.js.map +1 -0
  635. package/dist/humain/checklist/glyphs.d.ts +7 -0
  636. package/dist/humain/checklist/glyphs.d.ts.map +1 -0
  637. package/dist/humain/checklist/glyphs.js +8 -0
  638. package/dist/humain/checklist/glyphs.js.map +1 -0
  639. package/dist/humain/checklist/index.d.ts +6 -0
  640. package/dist/humain/checklist/index.d.ts.map +1 -0
  641. package/dist/humain/checklist/index.js +37 -0
  642. package/dist/humain/checklist/index.js.map +1 -0
  643. package/dist/humain/checklist/progress.d.ts +37 -0
  644. package/dist/humain/checklist/progress.d.ts.map +1 -0
  645. package/dist/humain/checklist/progress.js +234 -0
  646. package/dist/humain/checklist/progress.js.map +1 -0
  647. package/dist/humain/checklist/projector.d.ts +53 -0
  648. package/dist/humain/checklist/projector.d.ts.map +1 -0
  649. package/dist/humain/checklist/projector.js +198 -0
  650. package/dist/humain/checklist/projector.js.map +1 -0
  651. package/dist/humain/checklist/sidebar.d.ts +18 -0
  652. package/dist/humain/checklist/sidebar.d.ts.map +1 -0
  653. package/dist/humain/checklist/sidebar.js +38 -0
  654. package/dist/humain/checklist/sidebar.js.map +1 -0
  655. package/dist/humain/checklist/status-segment.d.ts +19 -0
  656. package/dist/humain/checklist/status-segment.d.ts.map +1 -0
  657. package/dist/humain/checklist/status-segment.js +59 -0
  658. package/dist/humain/checklist/status-segment.js.map +1 -0
  659. package/dist/humain/checklist/vendor/add-task-dialog.d.ts +54 -0
  660. package/dist/humain/checklist/vendor/add-task-dialog.d.ts.map +1 -0
  661. package/dist/humain/checklist/vendor/add-task-dialog.js +238 -0
  662. package/dist/humain/checklist/vendor/add-task-dialog.js.map +1 -0
  663. package/dist/humain/checklist/vendor/commands.d.ts +38 -0
  664. package/dist/humain/checklist/vendor/commands.d.ts.map +1 -0
  665. package/dist/humain/checklist/vendor/commands.js +193 -0
  666. package/dist/humain/checklist/vendor/commands.js.map +1 -0
  667. package/dist/humain/checklist/vendor/index.d.ts +3 -0
  668. package/dist/humain/checklist/vendor/index.d.ts.map +1 -0
  669. package/dist/humain/checklist/vendor/index.js +276 -0
  670. package/dist/humain/checklist/vendor/index.js.map +1 -0
  671. package/dist/humain/checklist/vendor/render.d.ts +97 -0
  672. package/dist/humain/checklist/vendor/render.d.ts.map +1 -0
  673. package/dist/humain/checklist/vendor/render.js +354 -0
  674. package/dist/humain/checklist/vendor/render.js.map +1 -0
  675. package/dist/humain/checklist/vendor/settings.d.ts +11 -0
  676. package/dist/humain/checklist/vendor/settings.d.ts.map +1 -0
  677. package/dist/humain/checklist/vendor/settings.js +8 -0
  678. package/dist/humain/checklist/vendor/settings.js.map +1 -0
  679. package/dist/humain/checklist/vendor/store.d.ts +120 -0
  680. package/dist/humain/checklist/vendor/store.d.ts.map +1 -0
  681. package/dist/humain/checklist/vendor/store.js +990 -0
  682. package/dist/humain/checklist/vendor/store.js.map +1 -0
  683. package/dist/humain/checklist/vendor/tools.d.ts +21 -0
  684. package/dist/humain/checklist/vendor/tools.d.ts.map +1 -0
  685. package/dist/humain/checklist/vendor/tools.js +162 -0
  686. package/dist/humain/checklist/vendor/tools.js.map +1 -0
  687. package/dist/humain/checklist/vendor/types.d.ts +188 -0
  688. package/dist/humain/checklist/vendor/types.d.ts.map +1 -0
  689. package/dist/humain/checklist/vendor/types.js +32 -0
  690. package/dist/humain/checklist/vendor/types.js.map +1 -0
  691. package/dist/humain/gateway/catalog.d.ts +1 -0
  692. package/dist/humain/gateway/catalog.d.ts.map +1 -1
  693. package/dist/humain/gateway/catalog.js +1 -0
  694. package/dist/humain/gateway/catalog.js.map +1 -1
  695. package/dist/humain/gateway/client.d.ts +1 -0
  696. package/dist/humain/gateway/client.d.ts.map +1 -1
  697. package/dist/humain/gateway/client.js +8 -1
  698. package/dist/humain/gateway/client.js.map +1 -1
  699. package/dist/humain/gateway/http.d.ts.map +1 -1
  700. package/dist/humain/gateway/http.js +11 -3
  701. package/dist/humain/gateway/http.js.map +1 -1
  702. package/dist/humain/gateway/images.d.ts +3 -0
  703. package/dist/humain/gateway/images.d.ts.map +1 -0
  704. package/dist/humain/gateway/images.js +73 -0
  705. package/dist/humain/gateway/images.js.map +1 -0
  706. package/dist/humain/gateway/provider.js +1 -1
  707. package/dist/humain/gateway/provider.js.map +1 -1
  708. package/dist/humain/hcode/account-store.d.ts.map +1 -1
  709. package/dist/humain/hcode/account-store.js +3 -1
  710. package/dist/humain/hcode/account-store.js.map +1 -1
  711. package/dist/humain/hcode/account.d.ts.map +1 -1
  712. package/dist/humain/hcode/account.js +23 -13
  713. package/dist/humain/hcode/account.js.map +1 -1
  714. package/dist/humain/hcode/images.d.ts.map +1 -1
  715. package/dist/humain/hcode/images.js +19 -13
  716. package/dist/humain/hcode/images.js.map +1 -1
  717. package/dist/humain/hcode/login-failure.d.ts +1 -0
  718. package/dist/humain/hcode/login-failure.d.ts.map +1 -1
  719. package/dist/humain/hcode/login-failure.js +1 -0
  720. package/dist/humain/hcode/login-failure.js.map +1 -1
  721. package/dist/humain/hcode/provider.d.ts.map +1 -1
  722. package/dist/humain/hcode/provider.js +2 -1
  723. package/dist/humain/hcode/provider.js.map +1 -1
  724. package/dist/humain/hcode/run-credential.d.ts +1 -0
  725. package/dist/humain/hcode/run-credential.d.ts.map +1 -1
  726. package/dist/humain/hcode/run-credential.js +12 -4
  727. package/dist/humain/hcode/run-credential.js.map +1 -1
  728. package/dist/humain/index.d.ts.map +1 -1
  729. package/dist/humain/index.js +4 -0
  730. package/dist/humain/index.js.map +1 -1
  731. package/dist/humain/node-provider.d.ts.map +1 -1
  732. package/dist/humain/node-provider.js +37 -8
  733. package/dist/humain/node-provider.js.map +1 -1
  734. package/dist/main.d.ts +1 -1
  735. package/dist/main.d.ts.map +1 -1
  736. package/dist/main.js +38 -26
  737. package/dist/main.js.map +1 -1
  738. package/dist/modes/interactive/chat-viewport.js +1 -1
  739. package/dist/modes/interactive/chat-viewport.js.map +1 -1
  740. package/dist/modes/interactive/components/bash-execution.d.ts +2 -1
  741. package/dist/modes/interactive/components/bash-execution.d.ts.map +1 -1
  742. package/dist/modes/interactive/components/bash-execution.js +7 -4
  743. package/dist/modes/interactive/components/bash-execution.js.map +1 -1
  744. package/dist/modes/interactive/components/config-selector.js +1 -1
  745. package/dist/modes/interactive/components/config-selector.js.map +1 -1
  746. package/dist/modes/interactive/components/custom-editor.d.ts +2 -0
  747. package/dist/modes/interactive/components/custom-editor.d.ts.map +1 -1
  748. package/dist/modes/interactive/components/custom-editor.js +20 -1
  749. package/dist/modes/interactive/components/custom-editor.js.map +1 -1
  750. package/dist/modes/interactive/components/extension-editor.d.ts +1 -1
  751. package/dist/modes/interactive/components/extension-editor.js +2 -2
  752. package/dist/modes/interactive/components/extension-editor.js.map +1 -1
  753. package/dist/modes/interactive/components/footer.d.ts +7 -0
  754. package/dist/modes/interactive/components/footer.d.ts.map +1 -1
  755. package/dist/modes/interactive/components/footer.js +74 -1
  756. package/dist/modes/interactive/components/footer.js.map +1 -1
  757. package/dist/modes/interactive/components/mermaid.d.ts.map +1 -1
  758. package/dist/modes/interactive/components/mermaid.js +11 -4
  759. package/dist/modes/interactive/components/mermaid.js.map +1 -1
  760. package/dist/modes/interactive/components/model-selector.d.ts +2 -0
  761. package/dist/modes/interactive/components/model-selector.d.ts.map +1 -1
  762. package/dist/modes/interactive/components/model-selector.js +56 -8
  763. package/dist/modes/interactive/components/model-selector.js.map +1 -1
  764. package/dist/modes/interactive/components/oauth-selector.d.ts +13 -1
  765. package/dist/modes/interactive/components/oauth-selector.d.ts.map +1 -1
  766. package/dist/modes/interactive/components/oauth-selector.js +10 -9
  767. package/dist/modes/interactive/components/oauth-selector.js.map +1 -1
  768. package/dist/modes/interactive/components/session-selector.js +3 -3
  769. package/dist/modes/interactive/components/session-selector.js.map +1 -1
  770. package/dist/modes/interactive/components/settings-selector.d.ts +4 -3
  771. package/dist/modes/interactive/components/settings-selector.d.ts.map +1 -1
  772. package/dist/modes/interactive/components/settings-selector.js +83 -37
  773. package/dist/modes/interactive/components/settings-selector.js.map +1 -1
  774. package/dist/modes/interactive/components/settings-submenu.d.ts.map +1 -1
  775. package/dist/modes/interactive/components/settings-submenu.js +3 -3
  776. package/dist/modes/interactive/components/settings-submenu.js.map +1 -1
  777. package/dist/modes/interactive/components/status-indicator.d.ts +18 -7
  778. package/dist/modes/interactive/components/status-indicator.d.ts.map +1 -1
  779. package/dist/modes/interactive/components/status-indicator.js +70 -24
  780. package/dist/modes/interactive/components/status-indicator.js.map +1 -1
  781. package/dist/modes/interactive/components/status-line.d.ts +16 -0
  782. package/dist/modes/interactive/components/status-line.d.ts.map +1 -0
  783. package/dist/modes/interactive/components/status-line.js +51 -0
  784. package/dist/modes/interactive/components/status-line.js.map +1 -0
  785. package/dist/modes/interactive/components/tool-execution.d.ts +5 -0
  786. package/dist/modes/interactive/components/tool-execution.d.ts.map +1 -1
  787. package/dist/modes/interactive/components/tool-execution.js +8 -1
  788. package/dist/modes/interactive/components/tool-execution.js.map +1 -1
  789. package/dist/modes/interactive/components/visual-truncate.d.ts.map +1 -1
  790. package/dist/modes/interactive/components/visual-truncate.js +11 -3
  791. package/dist/modes/interactive/components/visual-truncate.js.map +1 -1
  792. package/dist/modes/interactive/external-editor.d.ts.map +1 -1
  793. package/dist/modes/interactive/external-editor.js +13 -3
  794. package/dist/modes/interactive/external-editor.js.map +1 -1
  795. package/dist/modes/interactive/interactive-mode.d.ts +17 -1
  796. package/dist/modes/interactive/interactive-mode.d.ts.map +1 -1
  797. package/dist/modes/interactive/interactive-mode.js +232 -108
  798. package/dist/modes/interactive/interactive-mode.js.map +1 -1
  799. package/dist/modes/interactive/program-status-reporter.d.ts +2 -0
  800. package/dist/modes/interactive/program-status-reporter.d.ts.map +1 -1
  801. package/dist/modes/interactive/program-status-reporter.js +4 -0
  802. package/dist/modes/interactive/program-status-reporter.js.map +1 -1
  803. package/dist/modes/interactive/session-share.d.ts.map +1 -1
  804. package/dist/modes/interactive/session-share.js +9 -1
  805. package/dist/modes/interactive/session-share.js.map +1 -1
  806. package/dist/modes/print-mode.d.ts.map +1 -1
  807. package/dist/modes/print-mode.js +34 -7
  808. package/dist/modes/print-mode.js.map +1 -1
  809. package/dist/modes/rpc/jsonl.js +6 -5
  810. package/dist/modes/rpc/jsonl.js.map +1 -1
  811. package/dist/modes/rpc/rpc-client.d.ts +2 -0
  812. package/dist/modes/rpc/rpc-client.d.ts.map +1 -1
  813. package/dist/modes/rpc/rpc-client.js +9 -2
  814. package/dist/modes/rpc/rpc-client.js.map +1 -1
  815. package/dist/modes/rpc/rpc-mode.d.ts +2 -1
  816. package/dist/modes/rpc/rpc-mode.d.ts.map +1 -1
  817. package/dist/modes/rpc/rpc-mode.js +113 -13
  818. package/dist/modes/rpc/rpc-mode.js.map +1 -1
  819. package/dist/modes/rpc/rpc-types.d.ts +22 -1
  820. package/dist/modes/rpc/rpc-types.d.ts.map +1 -1
  821. package/dist/modes/rpc/rpc-types.js.map +1 -1
  822. package/dist/modes/uncaught-errors.d.ts +20 -0
  823. package/dist/modes/uncaught-errors.d.ts.map +1 -0
  824. package/dist/modes/uncaught-errors.js +56 -0
  825. package/dist/modes/uncaught-errors.js.map +1 -0
  826. package/dist/package-manager-cli.d.ts.map +1 -1
  827. package/dist/package-manager-cli.js +10 -1
  828. package/dist/package-manager-cli.js.map +1 -1
  829. package/dist/utils/clipboard-image.js +1 -1
  830. package/dist/utils/clipboard-image.js.map +1 -1
  831. package/dist/utils/clipboard.js +2 -2
  832. package/dist/utils/clipboard.js.map +1 -1
  833. package/dist/utils/image-process.d.ts +5 -0
  834. package/dist/utils/image-process.d.ts.map +1 -1
  835. package/dist/utils/image-process.js +22 -4
  836. package/dist/utils/image-process.js.map +1 -1
  837. package/dist/utils/output-files.d.ts +44 -7
  838. package/dist/utils/output-files.d.ts.map +1 -1
  839. package/dist/utils/output-files.js +206 -12
  840. package/dist/utils/output-files.js.map +1 -1
  841. package/dist/utils/piped-stdin.d.ts +21 -0
  842. package/dist/utils/piped-stdin.d.ts.map +1 -0
  843. package/dist/utils/piped-stdin.js +60 -0
  844. package/dist/utils/piped-stdin.js.map +1 -0
  845. package/dist/utils/shell.d.ts +5 -2
  846. package/dist/utils/shell.d.ts.map +1 -1
  847. package/dist/utils/shell.js +77 -8
  848. package/dist/utils/shell.js.map +1 -1
  849. package/dist/utils/syntax-highlight.d.ts +33 -2
  850. package/dist/utils/syntax-highlight.d.ts.map +1 -1
  851. package/dist/utils/syntax-highlight.js +77 -10
  852. package/dist/utils/syntax-highlight.js.map +1 -1
  853. package/dist/utils/tools-manager.d.ts +1 -0
  854. package/dist/utils/tools-manager.d.ts.map +1 -1
  855. package/dist/utils/tools-manager.js +9 -8
  856. package/dist/utils/tools-manager.js.map +1 -1
  857. package/dist/utils/wsl.d.ts +8 -2
  858. package/dist/utils/wsl.d.ts.map +1 -1
  859. package/dist/utils/wsl.js +12 -3
  860. package/dist/utils/wsl.js.map +1 -1
  861. package/docs/cli.md +45 -3
  862. package/docs/codemode.md +7 -3
  863. package/docs/compaction.md +1 -1
  864. package/docs/coordination.md +16 -4
  865. package/docs/development.md +6 -0
  866. package/docs/environment-variables.md +5 -3
  867. package/docs/extensions.md +19 -5
  868. package/docs/keybindings.md +2 -0
  869. package/docs/llama-cpp.md +2 -2
  870. package/docs/message-types.md +1 -0
  871. package/docs/models-configuration.md +14 -3
  872. package/docs/models.md +29 -7
  873. package/docs/providers.md +25 -3
  874. package/docs/rpc-commands.md +25 -2
  875. package/docs/rpc.md +20 -0
  876. package/docs/run-preflight.md +2 -2
  877. package/docs/session-format.md +9 -0
  878. package/docs/settings.md +35 -5
  879. package/docs/shell-aliases.md +1 -1
  880. package/docs/slash-commands.md +3 -1
  881. package/docs/terminal-setup.md +25 -0
  882. package/docs/windows.md +2 -1
  883. package/examples/extensions/custom-provider-anthropic/package-lock.json +4 -4
  884. package/examples/extensions/custom-provider-anthropic/package.json +1 -1
  885. package/examples/rpc-extension-ui.ts +8 -7
  886. package/npm-shrinkwrap.json +209 -180
  887. package/package.json +26 -20
  888. package/schemas/keybindings.schema.json +12 -0
  889. package/schemas/models.schema.json +20 -7
  890. package/schemas/settings.schema.json +43 -5
  891. package/src/coordination/UPSTREAM.md +27 -1
  892. package/src/coordination/upstream.json +3 -3
  893. package/src/humain/ask-user-question/UPSTREAM.md +31 -0
  894. package/src/humain/ask-user-question/upstream.json +258 -0
  895. package/src/humain/ask-user-question/vendor/ask/LICENSE +21 -0
  896. package/src/humain/ask-user-question/vendor/ask/locales/de.json +38 -0
  897. package/src/humain/ask-user-question/vendor/ask/locales/en.json +41 -0
  898. package/src/humain/ask-user-question/vendor/ask/locales/es.json +38 -0
  899. package/src/humain/ask-user-question/vendor/ask/locales/fr.json +38 -0
  900. package/src/humain/ask-user-question/vendor/ask/locales/pt-BR.json +38 -0
  901. package/src/humain/ask-user-question/vendor/ask/locales/pt.json +38 -0
  902. package/src/humain/ask-user-question/vendor/ask/locales/ru.json +38 -0
  903. package/src/humain/ask-user-question/vendor/ask/locales/uk.json +38 -0
  904. package/src/humain/ask-user-question/vendor/ask/locales/zh.json +40 -0
  905. package/src/humain/ask-user-question/vendor/config/LICENSE +21 -0
  906. package/src/humain/ask-user-question/vendor/i18n/LICENSE +21 -0
  907. package/src/humain/caveman/UPSTREAM.md +44 -11
  908. package/src/humain/caveman/upstream.json +3 -3
  909. package/src/humain/caveman/vendor/NOTICE +4 -0
  910. package/dist/bundle/chunks/anthropic-messages-XFCDMGD6.js +0 -77
  911. package/dist/bundle/chunks/azure-openai-responses-F4KQM3NK.js +0 -15
  912. package/dist/bundle/chunks/bowser-DXKSTXFQ.js +0 -89
  913. package/dist/bundle/chunks/chunk-3E37CJCE.js +0 -34
  914. package/dist/bundle/chunks/chunk-3HVHETMU.js +0 -18
  915. package/dist/bundle/chunks/chunk-3PJ7NPWN.js +0 -80
  916. package/dist/bundle/chunks/chunk-6JTCRCNF.js +0 -74
  917. package/dist/bundle/chunks/chunk-F77J5EQZ.js +0 -3
  918. package/dist/bundle/chunks/chunk-GPLWWO5Q.js +0 -121
  919. package/dist/bundle/chunks/chunk-GV5OVRKK.js +0 -4
  920. package/dist/bundle/chunks/chunk-JBSWWCT5.js +0 -12
  921. package/dist/bundle/chunks/chunk-JQBZUFH7.js +0 -3580
  922. package/dist/bundle/chunks/chunk-JWOPWHVH.js +0 -51
  923. package/dist/bundle/chunks/chunk-KRBELWQH.js +0 -7
  924. package/dist/bundle/chunks/chunk-PFBAIRCY.js +0 -56
  925. package/dist/bundle/chunks/chunk-Q5RKNQ2T.js +0 -73
  926. package/dist/bundle/chunks/chunk-QFDZEUFU.js +0 -12
  927. package/dist/bundle/chunks/chunk-SKCJ25SX.js +0 -24
  928. package/dist/bundle/chunks/chunk-UEW6TUSP.js +0 -36
  929. package/dist/bundle/chunks/chunk-UZOIHLNU.js +0 -23
  930. package/dist/bundle/chunks/chunk-YSWDFV2L.js +0 -11
  931. package/dist/bundle/chunks/chunk-YZMQXAJM.js +0 -8
  932. package/dist/bundle/chunks/entry-2GZ3PTWQ.js +0 -2
  933. package/dist/bundle/chunks/google-generative-ai-WIASMWS3.js +0 -22
  934. package/dist/bundle/chunks/google-vertex-WSPHRZIZ.js +0 -25
  935. package/dist/bundle/chunks/interactive-mode-SDUO5OLD.js +0 -5
  936. package/dist/bundle/chunks/mistral-conversations-7JYDDRUT.js +0 -43
  937. package/dist/bundle/chunks/openai-codex-responses-7PAML4NF.js +0 -102
  938. package/dist/bundle/chunks/openai-completions-UJDAIGTK.js +0 -87
  939. package/dist/bundle/chunks/openai-responses-2WNCE6AY.js +0 -26
  940. package/dist/bundle/chunks/openrouter-images-V3UCCO6X.js +0 -8
  941. package/dist/bundle/chunks/pi-messages-TQ7LJUNQ.js +0 -28
  942. package/dist/bundle/chunks/runtime-H7LYNKCZ.js +0 -2
  943. package/dist/bundle/chunks/session-picker-EYKCMFQR.js +0 -4
  944. package/dist/bundle/chunks/startup-ui-7ODOR34R.js +0 -3
  945. package/dist/bundle/chunks/typesafe-system-one-YP7GGN4C.js +0 -3
  946. package/dist/bundle/chunks/virtual-modules-IU5KWB2C.js +0 -28
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/core/export-html/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,EAAE,YAAY,EAAE,aAAa,EAAE,MAAM,IAAI,CAAC;AAC7D,OAAO,EAAE,QAAQ,EAAE,IAAI,EAAE,MAAM,MAAM,CAAC;AACtC,OAAO,EAAE,WAAW,EAAE,oBAAoB,EAAE,MAAM,iBAAiB,CAAC;AACpE,OAAO,EAAE,sBAAsB,EAAE,oBAAoB,EAAE,MAAM,wCAAwC,CAAC;AACtG,OAAO,EAAE,aAAa,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAC;AAGlE,OAAO,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AAiCvD,yFAAyF;AACzF,SAAS,UAAU,CAAC,KAAa;IAChC,MAAM,QAAQ,GAAG,KAAK,CAAC,KAAK,CAAC,qDAAqD,CAAC,CAAC;IACpF,IAAI,QAAQ,EAAE,CAAC;QACd,OAAO;YACN,CAAC,EAAE,MAAM,CAAC,QAAQ,CAAC,QAAQ,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC;YACnC,CAAC,EAAE,MAAM,CAAC,QAAQ,CAAC,QAAQ,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC;YACnC,CAAC,EAAE,MAAM,CAAC,QAAQ,CAAC,QAAQ,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC;SACnC,CAAC;IACH,CAAC;IACD,MAAM,QAAQ,GAAG,KAAK,CAAC,KAAK,CAAC,iDAAiD,CAAC,CAAC;IAChF,IAAI,QAAQ,EAAE,CAAC;QACd,OAAO;YACN,CAAC,EAAE,MAAM,CAAC,QAAQ,CAAC,QAAQ,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC;YACnC,CAAC,EAAE,MAAM,CAAC,QAAQ,CAAC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ync } from \"fs\";\nimport { basename, join } from \"path\";\nimport { APP_COMMAND, getExportTemplateDir } from \"../../config.ts\";\nimport { getResolvedThemeColors, getThemeExportColors } from \"../../modes/interactive/theme/theme.ts\";\nimport { normalizePath, resolvePath } from \"../../utils/paths.ts\";\nimport type { ToolDefinition } from \"../extensions/types.ts\";\nimport type { SessionEntry } from \"../session-manager.ts\";\nimport { SessionManager } from \"../session-manager.ts\";\n\n/**\n * Interface for rendering custom tools to HTML.\n * Used by agent-session to pre-render extension tool output.\n */\nexport interface ToolHtmlRenderer {\n\t/** Render a tool call to HTML. Returns undefined if tool has no custom renderer. */\n\trenderCall(toolCallId: string, toolName: string, args: unknown): string | undefined;\n\t/** Render a tool result to HTML. Returns collapsed/expanded or undefined if tool has no custom renderer. */\n\trenderResult(\n\t\ttoolCallId: string,\n\t\ttoolName: string,\n\t\tresult: Array<{ type: string; text?: string; data?: string; mimeType?: string }>,\n\t\tdetails: unknown,\n\t\tisError: boolean,\n\t): { collapsed?: string; expanded?: string } | undefined;\n}\n\n/** Pre-rendered HTML for a custom tool call and result */\ninterface RenderedToolHtml {\n\tcallHtml?: string;\n\tresultHtmlCollapsed?: string;\n\tresultHtmlExpanded?: string;\n}\n\nexport interface ExportOptions {\n\toutputPath?: string;\n\tthemeName?: string;\n\t/** Optional tool renderer for custom tools */\n\ttoolRenderer?: ToolHtmlRenderer;\n}\n\n/** Parse a color string to RGB values. Supports hex (#RRGGBB) and rgb(r,g,b) formats. */\nfunction parseColor(color: string): { r: number; g: number; b: number } | undefined {\n\tconst hexMatch = color.match(/^#([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/);\n\tif (hexMatch) {\n\t\treturn {\n\t\t\tr: Number.parseInt(hexMatch[1], 16),\n\t\t\tg: Number.parseInt(hexMatch[2], 16),\n\t\t\tb: Number.parseInt(hexMatch[3], 16),\n\t\t};\n\t}\n\tconst rgbMatch = color.match(/^rgb\\s*\\(\\s*(\\d+)\\s*,\\s*(\\d+)\\s*,\\s*(\\d+)\\s*\\)$/);\n\tif (rgbMatch) {\n\t\treturn {\n\t\t\tr: Number.parseInt(rgbMatch[1], 10),\n\t\t\tg: Number.parseInt(rgbMatch[2], 10),\n\t\t\tb: Number.parseInt(rgbMatch[3], 10),\n\t\t};\n\t}\n\treturn undefined;\n}\n\n/** Calculate relative luminance of a color (0-1, higher = lighter). */\nfunction getLuminance(r: number, g: number, b: number): number {\n\tconst toLinear = (c: number) => {\n\t\tconst s = c / 255;\n\t\treturn s <= 0.03928 ? s / 12.92 : ((s + 0.055) / 1.055) ** 2.4;\n\t};\n\treturn 0.2126 * toLinear(r) + 0.7152 * toLinear(g) + 0.0722 * toLinear(b);\n}\n\n/** Adjust color brightness. Factor > 1 lightens, < 1 darkens. */\nfunction adjustBrightness(color: string, factor: number): string {\n\tconst parsed = parseColor(color);\n\tif (!parsed) return color;\n\tconst adjust = (c: number) => Math.min(255, Math.max(0, Math.round(c * factor)));\n\treturn `rgb(${adjust(parsed.r)}, ${adjust(parsed.g)}, ${adjust(parsed.b)})`;\n}\n\n/** Derive export background colors from a base color (e.g., userMessageBg). */\nfunction deriveExportColors(baseColor: string): { pageBg: string; cardBg: string; infoBg: string } {\n\tconst parsed = parseColor(baseColor);\n\tif (!parsed) {\n\t\treturn {\n\t\t\tpageBg: \"rgb(24, 24, 30)\",\n\t\t\tcardBg: \"rgb(30, 30, 36)\",\n\t\t\tinfoBg: \"rgb(60, 55, 40)\",\n\t\t};\n\t}\n\n\tconst luminance = getLuminance(parsed.r, parsed.g, parsed.b);\n\tconst isLight = luminance > 0.5;\n\n\tif (isLight) {\n\t\treturn {\n\t\t\tpageBg: adjustBrightness(baseColor, 0.96),\n\t\t\tcardBg: baseColor,\n\t\t\tinfoBg: `rgb(${Math.min(255, parsed.r + 10)}, ${Math.min(255, parsed.g + 5)}, ${Math.max(0, parsed.b - 20)})`,\n\t\t};\n\t}\n\treturn {\n\t\tpageBg: adjustBrightness(baseColor, 0.7),\n\t\tcardBg: adjustBrightness(baseColor, 0.85),\n\t\tinfoBg: `rgb(${Math.min(255, parsed.r + 20)}, ${Math.min(255, parsed.g + 15)}, ${parsed.b})`,\n\t};\n}\n\n/**\n * Generate CSS custom property declarations from theme colors.\n */\nfunction generateThemeVars(themeName?: string): string {\n\tconst colors = getResolvedThemeColors(themeName);\n\tconst lines: string[] = [];\n\tfor (const [key, value] of Object.entries(colors)) {\n\t\tlines.push(`--${key}: ${value};`);\n\t}\n\n\t// Use explicit theme export colors if available, otherwise derive from userMessageBg\n\tconst themeExport = getThemeExportColors(themeName);\n\tconst userMessageBg = colors.userMessageBg || \"#343541\";\n\tconst derivedColors = deriveExportColors(userMessageBg);\n\n\tlines.push(`--exportPageBg: ${themeExport.pageBg ?? derivedColors.pageBg};`);\n\tlines.push(`--exportCardBg: ${themeExport.cardBg ?? derivedColors.cardBg};`);\n\tlines.push(`--exportInfoBg: ${themeExport.infoBg ?? derivedColors.infoBg};`);\n\n\treturn lines.join(\"\\n \");\n}\n\ninterface SessionData {\n\theader: ReturnType<SessionManager[\"getHeader\"]>;\n\tentries: ReturnType<SessionManager[\"getEntries\"]>;\n\tleafId: string | null;\n\tsystemPrompt?: string;\n\ttools?: Array<Pick<ToolDefinition, \"name\" | \"description\" | \"parameters\">>;\n\t/** Pre-rendered HTML for custom tool calls/results, keyed by tool call ID */\n\trenderedTools?: Record<string, RenderedToolHtml>;\n}\n\n/**\n * Core HTML generation logic shared by both export functions.\n */\nfunction generateHtml(sessionData: SessionData, themeName?: string): string {\n\tconst templateDir = getExportTemplateDir();\n\tconst template = readFileSync(join(templateDir, \"template.html\"), \"utf-8\");\n\tconst templateCss = readFileSync(join(templateDir, \"template.css\"), \"utf-8\");\n\tconst templateJs = readFileSync(join(templateDir, \"template.js\"), \"utf-8\");\n\tconst markedJs = readFileSync(join(templateDir, \"vendor\", \"marked.min.js\"), \"utf-8\");\n\tconst markedCjkFriendlyJs = readFileSync(join(templateDir, \"vendor\", \"marked-cjk-friendly.min.js\"), \"utf-8\");\n\tconst hljsJs = readFileSync(join(templateDir, \"vendor\", \"highlight.min.js\"), \"utf-8\");\n\n\tconst themeVars = generateThemeVars(themeName);\n\tconst colors = getResolvedThemeColors(themeName);\n\tconst themeExport = getThemeExportColors(themeName);\n\tconst derivedExportColors = deriveExportColors(colors.userMessageBg || \"#343541\");\n\tconst bodyBg = themeExport.pageBg ?? derivedExportColors.pageBg;\n\tconst containerBg = themeExport.cardBg ?? derivedExportColors.cardBg;\n\tconst infoBg = themeExport.infoBg ?? derivedExportColors.infoBg;\n\n\t// Base64 encode session data to avoid escaping issues\n\tconst sessionDataBase64 = Buffer.from(JSON.stringify(sessionData)).toString(\"base64\");\n\n\t// Build the CSS with theme variables injected\n\tconst css = templateCss\n\t\t.replace(\"{{THEME_VARS}}\", themeVars)\n\t\t.replace(\"{{BODY_BG}}\", bodyBg)\n\t\t.replace(\"{{CONTAINER_BG}}\", containerBg)\n\t\t.replace(\"{{INFO_BG}}\", infoBg);\n\n\treturn template\n\t\t.replace(\"{{CSS}}\", css)\n\t\t.replace(\"{{JS}}\", templateJs)\n\t\t.replace(\"{{SESSION_DATA}}\", sessionDataBase64)\n\t\t.replace(\"{{MARKED_JS}}\", markedJs)\n\t\t.replace(\"{{MARKED_CJK_FRIENDLY_JS}}\", markedCjkFriendlyJs)\n\t\t.replace(\"{{HIGHLIGHT_JS}}\", hljsJs);\n}\n\n/** Tools rendered directly by the HTML template (not pre-rendered via TUI→ANSI→HTML pipeline) */\nconst TEMPLATE_RENDERED_TOOLS = new Set([\"bash\", \"read\", \"write\", \"edit\", \"ls\"]);\n\n/**\n * Pre-render custom tools to HTML using their TUI renderers.\n */\nfunction preRenderCustomTools(\n\tentries: SessionEntry[],\n\ttoolRenderer: ToolHtmlRenderer,\n): Record<string, RenderedToolHtml> {\n\tconst renderedTools: Record<string, RenderedToolHtml> = {};\n\n\tfor (const entry of entries) {\n\t\tif (entry.type !== \"message\") continue;\n\t\tconst msg = entry.message;\n\n\t\t// Find tool calls in assistant messages\n\t\tif (msg.role === \"assistant\" && Array.isArray(msg.content)) {\n\t\t\tfor (const block of msg.content) {\n\t\t\t\tif (block.type === \"toolCall\" && !TEMPLATE_RENDERED_TOOLS.has(block.name)) {\n\t\t\t\t\tconst callHtml = toolRenderer.renderCall(block.id, block.name, block.arguments);\n\t\t\t\t\tif (callHtml) {\n\t\t\t\t\t\trenderedTools[block.id] = { callHtml };\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t// Find tool results\n\t\tif (msg.role === \"toolResult\" && msg.toolCallId) {\n\t\t\tconst toolName = msg.toolName || \"\";\n\t\t\t// Only render if we have a pre-rendered call OR it's not template-rendered\n\t\t\tconst existing = renderedTools[msg.toolCallId];\n\t\t\tif (existing || !TEMPLATE_RENDERED_TOOLS.has(toolName)) {\n\t\t\t\tconst rendered = toolRenderer.renderResult(\n\t\t\t\t\tmsg.toolCallId,\n\t\t\t\t\ttoolName,\n\t\t\t\t\tmsg.content,\n\t\t\t\t\tmsg.details,\n\t\t\t\t\tmsg.isError || false,\n\t\t\t\t);\n\t\t\t\tif (rendered) {\n\t\t\t\t\trenderedTools[msg.toolCallId] = {\n\t\t\t\t\t\t...existing,\n\t\t\t\t\t\tresultHtmlCollapsed: rendered.collapsed,\n\t\t\t\t\t\tresultHtmlExpanded: rendered.expanded,\n\t\t\t\t\t};\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn renderedTools;\n}\n\n/**\n * Export session to HTML using SessionManager and AgentState.\n * Used by TUI's /export command.\n */\nexport async function exportSessionToHtml(\n\tsm: SessionManager,\n\tstate?: AgentState,\n\toptions?: ExportOptions | string,\n): Promise<string> {\n\tconst opts: ExportOptions = typeof options === \"string\" ? { outputPath: options } : options || {};\n\n\tconst sessionFile = sm.getSessionFile();\n\tif (!sessionFile) {\n\t\tthrow new Error(\"Cannot export in-memory session to HTML\");\n\t}\n\tif (!existsSync(sessionFile)) {\n\t\tthrow new Error(\"Nothing to export yet - start a conversation first\");\n\t}\n\n\tconst entries = sm.getEntries();\n\n\t// Pre-render custom tools if a tool renderer is provided\n\tlet renderedTools: Record<string, RenderedToolHtml> | undefined;\n\tif (opts.toolRenderer) {\n\t\trenderedTools = preRenderCustomTools(entries, opts.toolRenderer);\n\t\t// Only include if we actually rendered something\n\t\tif (Object.keys(renderedTools).length === 0) {\n\t\t\trenderedTools = undefined;\n\t\t}\n\t}\n\n\tconst sessionData: SessionData = {\n\t\theader: sm.getHeader(),\n\t\tentries,\n\t\tleafId: sm.getLeafId(),\n\t\tsystemPrompt: state?.systemPrompt,\n\t\ttools: state?.tools?.map((t) => ({ name: t.name, description: t.description, parameters: t.parameters })),\n\t\trenderedTools,\n\t};\n\n\tconst html = generateHtml(sessionData, opts.themeName);\n\n\tlet outputPath = opts.outputPath ? normalizePath(opts.outputPath) : undefined;\n\tif (!outputPath) {\n\t\tconst sessionBasename = basename(sessionFile, \".jsonl\");\n\t\toutputPath = `${APP_COMMAND}-session-${sessionBasename}.html`;\n\t}\n\n\twriteFileSync(outputPath, html, \"utf8\");\n\treturn outputPath;\n}\n\n/**\n * Export session file to HTML (standalone, without AgentState).\n * Used by CLI for exporting arbitrary session files.\n */\nexport async function exportFromFile(inputPath: string, options?: ExportOptions | string): Promise<string> {\n\tconst opts: ExportOptions = typeof options === \"string\" ? { outputPath: options } : options || {};\n\tconst resolvedInputPath = resolvePath(inputPath);\n\n\tif (!existsSync(resolvedInputPath)) {\n\t\tthrow new Error(`File not found: ${resolvedInputPath}`);\n\t}\n\n\tconst sm = SessionManager.open(resolvedInputPath);\n\n\tconst sessionData: SessionData = {\n\t\theader: sm.getHeader(),\n\t\tentries: sm.getEntries(),\n\t\tleafId: sm.getLeafId(),\n\t\tsystemPrompt: undefined,\n\t\ttools: undefined,\n\t};\n\n\tconst html = generateHtml(sessionData, opts.themeName);\n\n\tlet outputPath = opts.outputPath ? normalizePath(opts.outputPath) : undefined;\n\tif (!outputPath) {\n\t\tconst inputBasename = basename(resolvedInputPath, \".jsonl\");\n\t\toutputPath = `${APP_COMMAND}-session-${inputBasename}.html`;\n\t}\n\n\twriteFileSync(outputPath, html, \"utf8\");\n\treturn outputPath;\n}\n"]}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/core/export-html/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,EAAE,YAAY,EAAE,aAAa,EAAE,MAAM,IAAI,CAAC;AAC7D,OAAO,EAAE,QAAQ,EAAE,IAAI,EAAE,MAAM,MAAM,CAAC;AACtC,OAAO,EAAE,WAAW,EAAE,oBAAoB,EAAE,MAAM,iBAAiB,CAAC;AACpE,OAAO,EAAE,sBAAsB,EAAE,oBAAoB,EAAE,MAAM,wCAAwC,CAAC;AACtG,OAAO,EAAE,aAAa,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAC;AAGlE,OAAO,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AAiCvD,yFAAyF;AACzF,SAAS,UAAU,CAAC,KAAa;IAChC,MAAM,QAAQ,GAAG,KAAK,CAAC,KAAK,CAAC,qDAAqD,CAAC,CAAC;IACpF,IAAI,QAAQ,EAAE,CAAC;QACd,OAAO;YACN,CAAC,EAAE,MAAM,CAAC,QAAQ,CAAC,QAAQ,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC;YACnC,CAAC,EAAE,MAAM,CAAC,QAAQ,CAAC,QAAQ,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC;YACnC,CAAC,EAAE,MAAM,CAAC,QAAQ,CAAC,QAAQ,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC;SACnC,CAAC;IACH,CAAC;IACD,MAAM,QAAQ,GAAG,KAAK,CAAC,KAAK,CAAC,iDAAiD,CAAC,CAAC;IAChF,IAAI,QAAQ,EAAE,CAAC;QACd,OAAO;YACN,CAAC,EAAE,MAAM,CAAC,QAAQ,CAAC,QAAQ,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC;YACnC,CA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CAAC,CAAC;QAC5D,UAAU,GAAG,GAAG,WAAW,YAAY,aAAa,OAAO,CAAC;IAC7D,CAAC;IAED,aAAa,CAAC,UAAU,EAAE,IAAI,EAAE,MAAM,CAAC,CAAC;IACxC,OAAO,UAAU,CAAC;AACnB,CAAC","sourcesContent":["import type { AgentState } from \"@earendil-works/pi-agent-core\";\nimport { existsSync, readFileSync, writeFileSync } from \"fs\";\nimport { basename, join } from \"path\";\nimport { APP_COMMAND, getExportTemplateDir } from \"../../config.ts\";\nimport { getResolvedThemeColors, getThemeExportColors } from \"../../modes/interactive/theme/theme.ts\";\nimport { normalizePath, resolvePath } from \"../../utils/paths.ts\";\nimport type { ToolDefinition } from \"../extensions/types.ts\";\nimport type { SessionEntry } from \"../session-manager.ts\";\nimport { SessionManager } from \"../session-manager.ts\";\n\n/**\n * Interface for rendering custom tools to HTML.\n * Used by agent-session to pre-render extension tool output.\n */\nexport interface ToolHtmlRenderer {\n\t/** Render a tool call to HTML. Returns undefined if tool has no custom renderer. */\n\trenderCall(toolCallId: string, toolName: string, args: unknown): string | undefined;\n\t/** Render a tool result to HTML. Returns collapsed/expanded or undefined if tool has no custom renderer. */\n\trenderResult(\n\t\ttoolCallId: string,\n\t\ttoolName: string,\n\t\tresult: Array<{ type: string; text?: string; data?: string; mimeType?: string }>,\n\t\tdetails: unknown,\n\t\tisError: boolean,\n\t): { collapsed?: string; expanded?: string } | undefined;\n}\n\n/** Pre-rendered HTML for a custom tool call and result */\ninterface RenderedToolHtml {\n\tcallHtml?: string;\n\tresultHtmlCollapsed?: string;\n\tresultHtmlExpanded?: string;\n}\n\nexport interface ExportOptions {\n\toutputPath?: string;\n\tthemeName?: string;\n\t/** Optional tool renderer for custom tools */\n\ttoolRenderer?: ToolHtmlRenderer;\n}\n\n/** Parse a color string to RGB values. Supports hex (#RRGGBB) and rgb(r,g,b) formats. */\nfunction parseColor(color: string): { r: number; g: number; b: number } | undefined {\n\tconst hexMatch = color.match(/^#([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/);\n\tif (hexMatch) {\n\t\treturn {\n\t\t\tr: Number.parseInt(hexMatch[1], 16),\n\t\t\tg: Number.parseInt(hexMatch[2], 16),\n\t\t\tb: Number.parseInt(hexMatch[3], 16),\n\t\t};\n\t}\n\tconst rgbMatch = color.match(/^rgb\\s*\\(\\s*(\\d+)\\s*,\\s*(\\d+)\\s*,\\s*(\\d+)\\s*\\)$/);\n\tif (rgbMatch) {\n\t\treturn {\n\t\t\tr: Number.parseInt(rgbMatch[1], 10),\n\t\t\tg: Number.parseInt(rgbMatch[2], 10),\n\t\t\tb: Number.parseInt(rgbMatch[3], 10),\n\t\t};\n\t}\n\treturn undefined;\n}\n\n/** Calculate relative luminance of a color (0-1, higher = lighter). */\nfunction getLuminance(r: number, g: number, b: number): number {\n\tconst toLinear = (c: number) => {\n\t\tconst s = c / 255;\n\t\treturn s <= 0.03928 ? s / 12.92 : ((s + 0.055) / 1.055) ** 2.4;\n\t};\n\treturn 0.2126 * toLinear(r) + 0.7152 * toLinear(g) + 0.0722 * toLinear(b);\n}\n\n/** Adjust color brightness. Factor > 1 lightens, < 1 darkens. */\nfunction adjustBrightness(color: string, factor: number): string {\n\tconst parsed = parseColor(color);\n\tif (!parsed) return color;\n\tconst adjust = (c: number) => Math.min(255, Math.max(0, Math.round(c * factor)));\n\treturn `rgb(${adjust(parsed.r)}, ${adjust(parsed.g)}, ${adjust(parsed.b)})`;\n}\n\n/** Derive export background colors from a base color (e.g., userMessageBg). */\nfunction deriveExportColors(baseColor: string): { pageBg: string; cardBg: string; infoBg: string } {\n\tconst parsed = parseColor(baseColor);\n\tif (!parsed) {\n\t\treturn {\n\t\t\tpageBg: \"rgb(24, 24, 30)\",\n\t\t\tcardBg: \"rgb(30, 30, 36)\",\n\t\t\tinfoBg: \"rgb(60, 55, 40)\",\n\t\t};\n\t}\n\n\tconst luminance = getLuminance(parsed.r, parsed.g, parsed.b);\n\tconst isLight = luminance > 0.5;\n\n\tif (isLight) {\n\t\treturn {\n\t\t\tpageBg: adjustBrightness(baseColor, 0.96),\n\t\t\tcardBg: baseColor,\n\t\t\tinfoBg: `rgb(${Math.min(255, parsed.r + 10)}, ${Math.min(255, parsed.g + 5)}, ${Math.max(0, parsed.b - 20)})`,\n\t\t};\n\t}\n\treturn {\n\t\tpageBg: adjustBrightness(baseColor, 0.7),\n\t\tcardBg: adjustBrightness(baseColor, 0.85),\n\t\tinfoBg: `rgb(${Math.min(255, parsed.r + 20)}, ${Math.min(255, parsed.g + 15)}, ${parsed.b})`,\n\t};\n}\n\n/**\n * Generate CSS custom property declarations from theme colors.\n */\nfunction generateThemeVars(themeName?: string): string {\n\tconst colors = getResolvedThemeColors(themeName);\n\tconst lines: string[] = [];\n\tfor (const [key, value] of Object.entries(colors)) {\n\t\tlines.push(`--${key}: ${value};`);\n\t}\n\n\t// Use explicit theme export colors if available, otherwise derive from userMessageBg\n\tconst themeExport = getThemeExportColors(themeName);\n\tconst userMessageBg = colors.userMessageBg || \"#343541\";\n\tconst derivedColors = deriveExportColors(userMessageBg);\n\n\tlines.push(`--exportPageBg: ${themeExport.pageBg ?? derivedColors.pageBg};`);\n\tlines.push(`--exportCardBg: ${themeExport.cardBg ?? derivedColors.cardBg};`);\n\tlines.push(`--exportInfoBg: ${themeExport.infoBg ?? derivedColors.infoBg};`);\n\n\treturn lines.join(\"\\n \");\n}\n\ninterface SessionData {\n\theader: ReturnType<SessionManager[\"getHeader\"]>;\n\tentries: ReturnType<SessionManager[\"getEntries\"]>;\n\tleafId: string | null;\n\tsystemPrompt?: string;\n\ttools?: Array<Pick<ToolDefinition, \"name\" | \"description\" | \"parameters\">>;\n\t/** Pre-rendered HTML for custom tool calls/results, keyed by tool call ID */\n\trenderedTools?: Record<string, RenderedToolHtml>;\n}\n\n/**\n * Core HTML generation logic shared by both export functions.\n */\nfunction generateHtml(sessionData: SessionData, themeName?: string): string {\n\tconst templateDir = getExportTemplateDir();\n\tconst template = readFileSync(join(templateDir, \"template.html\"), \"utf-8\");\n\tconst templateCss = readFileSync(join(templateDir, \"template.css\"), \"utf-8\");\n\tconst templateJs = readFileSync(join(templateDir, \"template.js\"), \"utf-8\");\n\tconst markedJs = readFileSync(join(templateDir, \"vendor\", \"marked.min.js\"), \"utf-8\");\n\tconst markedCjkFriendlyJs = readFileSync(join(templateDir, \"vendor\", \"marked-cjk-friendly.min.js\"), \"utf-8\");\n\tconst hljsJs = readFileSync(join(templateDir, \"vendor\", \"highlight.min.js\"), \"utf-8\");\n\n\tconst themeVars = generateThemeVars(themeName);\n\tconst colors = getResolvedThemeColors(themeName);\n\tconst themeExport = getThemeExportColors(themeName);\n\tconst derivedExportColors = deriveExportColors(colors.userMessageBg || \"#343541\");\n\tconst bodyBg = themeExport.pageBg ?? derivedExportColors.pageBg;\n\tconst containerBg = themeExport.cardBg ?? derivedExportColors.cardBg;\n\tconst infoBg = themeExport.infoBg ?? derivedExportColors.infoBg;\n\n\t// Base64 encode session data to avoid escaping issues\n\tconst sessionDataBase64 = Buffer.from(JSON.stringify(sessionData)).toString(\"base64\");\n\n\t// Every value is passed through a function: a replacement string expands \"$$\" and \"$&\", which the\n\t// viewer script (\"$${totalCost...}\") and highlight.js contain, so they would be inserted changed.\n\n\t// Build the CSS with theme variables injected\n\tconst css = templateCss\n\t\t.replace(\"{{THEME_VARS}}\", () => themeVars)\n\t\t.replace(\"{{BODY_BG}}\", () => bodyBg)\n\t\t.replace(\"{{CONTAINER_BG}}\", () => containerBg)\n\t\t.replace(\"{{INFO_BG}}\", () => infoBg);\n\n\treturn template\n\t\t.replace(\"{{CSS}}\", () => css)\n\t\t.replace(\"{{JS}}\", () => templateJs)\n\t\t.replace(\"{{SESSION_DATA}}\", () => sessionDataBase64)\n\t\t.replace(\"{{MARKED_JS}}\", () => markedJs)\n\t\t.replace(\"{{MARKED_CJK_FRIENDLY_JS}}\", () => markedCjkFriendlyJs)\n\t\t.replace(\"{{HIGHLIGHT_JS}}\", () => hljsJs);\n}\n\n/** Tools rendered directly by the HTML template (not pre-rendered via TUI→ANSI→HTML pipeline) */\nconst TEMPLATE_RENDERED_TOOLS = new Set([\"bash\", \"read\", \"write\", \"edit\", \"ls\"]);\n\n/**\n * Pre-render custom tools to HTML using their TUI renderers.\n */\nfunction preRenderCustomTools(\n\tentries: SessionEntry[],\n\ttoolRenderer: ToolHtmlRenderer,\n): Record<string, RenderedToolHtml> {\n\tconst renderedTools: Record<string, RenderedToolHtml> = {};\n\n\tfor (const entry of entries) {\n\t\tif (entry.type !== \"message\") continue;\n\t\tconst msg = entry.message;\n\n\t\t// Find tool calls in assistant messages\n\t\tif (msg.role === \"assistant\" && Array.isArray(msg.content)) {\n\t\t\tfor (const block of msg.content) {\n\t\t\t\tif (block.type === \"toolCall\" && !TEMPLATE_RENDERED_TOOLS.has(block.name)) {\n\t\t\t\t\tconst callHtml = toolRenderer.renderCall(block.id, block.name, block.arguments);\n\t\t\t\t\tif (callHtml) {\n\t\t\t\t\t\trenderedTools[block.id] = { callHtml };\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t// Find tool results\n\t\tif (msg.role === \"toolResult\" && msg.toolCallId) {\n\t\t\tconst toolName = msg.toolName || \"\";\n\t\t\t// Only render if we have a pre-rendered call OR it's not template-rendered\n\t\t\tconst existing = renderedTools[msg.toolCallId];\n\t\t\tif (existing || !TEMPLATE_RENDERED_TOOLS.has(toolName)) {\n\t\t\t\tconst rendered = toolRenderer.renderResult(\n\t\t\t\t\tmsg.toolCallId,\n\t\t\t\t\ttoolName,\n\t\t\t\t\tmsg.content,\n\t\t\t\t\tmsg.details,\n\t\t\t\t\tmsg.isError || false,\n\t\t\t\t);\n\t\t\t\tif (rendered) {\n\t\t\t\t\trenderedTools[msg.toolCallId] = {\n\t\t\t\t\t\t...existing,\n\t\t\t\t\t\tresultHtmlCollapsed: rendered.collapsed,\n\t\t\t\t\t\tresultHtmlExpanded: rendered.expanded,\n\t\t\t\t\t};\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn renderedTools;\n}\n\n/**\n * Export session to HTML using SessionManager and AgentState.\n * Used by TUI's /export command.\n */\nexport async function exportSessionToHtml(\n\tsm: SessionManager,\n\tstate?: AgentState,\n\toptions?: ExportOptions | string,\n): Promise<string> {\n\tconst opts: ExportOptions = typeof options === \"string\" ? { outputPath: options } : options || {};\n\n\tconst sessionFile = sm.getSessionFile();\n\tif (!sessionFile) {\n\t\tthrow new Error(\"Cannot export in-memory session to HTML\");\n\t}\n\tif (!existsSync(sessionFile)) {\n\t\tthrow new Error(\"Nothing to export yet - start a conversation first\");\n\t}\n\n\tconst entries = sm.getEntries();\n\n\t// Pre-render custom tools if a tool renderer is provided\n\tlet renderedTools: Record<string, RenderedToolHtml> | undefined;\n\tif (opts.toolRenderer) {\n\t\trenderedTools = preRenderCustomTools(entries, opts.toolRenderer);\n\t\t// Only include if we actually rendered something\n\t\tif (Object.keys(renderedTools).length === 0) {\n\t\t\trenderedTools = undefined;\n\t\t}\n\t}\n\n\tconst sessionData: SessionData = {\n\t\theader: sm.getHeader(),\n\t\tentries,\n\t\tleafId: sm.getLeafId(),\n\t\tsystemPrompt: state?.systemPrompt,\n\t\ttools: state?.tools?.map((t) => ({ name: t.name, description: t.description, parameters: t.parameters })),\n\t\trenderedTools,\n\t};\n\n\tconst html = generateHtml(sessionData, opts.themeName);\n\n\tlet outputPath = opts.outputPath ? normalizePath(opts.outputPath) : undefined;\n\tif (!outputPath) {\n\t\tconst sessionBasename = basename(sessionFile, \".jsonl\");\n\t\toutputPath = `${APP_COMMAND}-session-${sessionBasename}.html`;\n\t}\n\n\twriteFileSync(outputPath, html, \"utf8\");\n\treturn outputPath;\n}\n\n/**\n * Export session file to HTML (standalone, without AgentState).\n * Used by CLI for exporting arbitrary session files.\n */\nexport async function exportFromFile(inputPath: string, options?: ExportOptions | string): Promise<string> {\n\tconst opts: ExportOptions = typeof options === \"string\" ? { outputPath: options } : options || {};\n\tconst resolvedInputPath = resolvePath(inputPath);\n\n\tif (!existsSync(resolvedInputPath)) {\n\t\tthrow new Error(`File not found: ${resolvedInputPath}`);\n\t}\n\n\tconst sm = SessionManager.open(resolvedInputPath);\n\n\tconst sessionData: SessionData = {\n\t\theader: sm.getHeader(),\n\t\tentries: sm.getEntries(),\n\t\tleafId: sm.getLeafId(),\n\t\tsystemPrompt: undefined,\n\t\ttools: undefined,\n\t};\n\n\tconst html = generateHtml(sessionData, opts.themeName);\n\n\tlet outputPath = opts.outputPath ? normalizePath(opts.outputPath) : undefined;\n\tif (!outputPath) {\n\t\tconst inputBasename = basename(resolvedInputPath, \".jsonl\");\n\t\toutputPath = `${APP_COMMAND}-session-${inputBasename}.html`;\n\t}\n\n\twriteFileSync(outputPath, html, \"utf8\");\n\treturn outputPath;\n}\n"]}
@@ -38,6 +38,26 @@
38
38
  byId.set(entry.id, entry);
39
39
  }
40
40
 
41
+ // Parent links that form a cycle (a damaged session) would keep every walk below going. The link that closes a
42
+ // cycle is cut as the session manager cuts it: walking up from the last entry first, the entry whose parent is
43
+ // already on the walk becomes a root. Only this page's parsed copy of the data is changed.
44
+ const cycleDone = new Set();
45
+ for (let i = entries.length - 1; i >= 0; i--) {
46
+ const onPath = new Set();
47
+ let current = byId.get(entries[i].id);
48
+ let last;
49
+ while (current && !cycleDone.has(current.id)) {
50
+ if (onPath.has(current.id)) {
51
+ last.parentId = null;
52
+ break;
53
+ }
54
+ onPath.add(current.id);
55
+ last = current;
56
+ current = current.parentId ? byId.get(current.parentId) : undefined;
57
+ }
58
+ for (const id of onPath) cycleDone.add(id);
59
+ }
60
+
41
61
  // Tool call lookup (toolCallId -> {name, arguments})
42
62
  const toolCallMap = new Map();
43
63
  for (const entry of entries) {
@@ -83,8 +103,10 @@
83
103
  });
84
104
  }
85
105
 
86
- // Build parent-child relationships
106
+ // Build parent-child relationships. A repeated ID is placed once, from the entry byId holds: its other
107
+ // occurrences would add links the cycle cut above does not see.
87
108
  for (const entry of entries) {
109
+ if (byId.get(entry.id) !== entry) continue;
88
110
  const node = nodeMap.get(entry.id);
89
111
  if (entry.parentId === null || entry.parentId === undefined || entry.parentId === entry.id) {
90
112
  roots.push(node);
@@ -1 +1 @@
1
- {"version":3,"file":"runner.d.ts","sourceRoot":"","sources":["../../../src/core/extensions/runner.ts"],"names":[],"mappings":"AACA;;GAEG;AAEH,OAAO,KAAK,EAAE,YAAY,EAAa,MAAM,+BAA+B,CAAC;AAC7E,OAAO,EAEN,KAAK,YAAY,EAEjB,KAAK,QAAQ,EACb,KAAK,eAAe,EACpB,MAAM,uBAAuB,CAAC;AAC/B,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,wBAAwB,CAAC;AAEpD,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,oBAAoB,CAAC;AAC7D,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,mBAAmB,CAAC;AAC5D,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAC;AAC3D,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAC;AAE1D,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,qBAAqB,CAAC;AAC/D,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AAC5D,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,wBAAwB,CAAC;AAC9D,OAAO,EACN,KAAK,wBAAwB,EAE7B,KAAK,kCAAkC,EAEvC,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EAAgC,KAAK,0BAA0B,EAAE,MAAM,+BAA+B,CAAC;AAC9G,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,sBAAsB,CAAC;AACnE,OAAO,KAAK,EACX,sBAAsB,EACtB,2BAA2B,EAC3B,qBAAqB,EACrB,2BAA2B,EAC3B,yBAAyB,EACzB,0BAA0B,EAC1B,0BAA0B,EAC1B,sBAAsB,EAEtB,yBAAyB,EAGzB,YAAY,EAGZ,sBAAsB,EACtB,aAAa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) {
73
73
  (resultRecord.exitCode === undefined || typeof resultRecord.exitCode === "number") &&
74
74
  typeof resultRecord.cancelled === "boolean" &&
75
75
  typeof resultRecord.truncated === "boolean" &&
76
- (resultRecord.fullOutputPath === undefined || typeof resultRecord.fullOutputPath === "string"));
76
+ (resultRecord.fullOutputPath === undefined || typeof resultRecord.fullOutputPath === "string") &&
77
+ (resultRecord.fullOutputError === undefined || typeof resultRecord.fullOutputError === "string"));
77
78
  }
78
79
  /**
79
80
  * Helper function to emit session_shutdown event to extensions.
@@ -391,7 +392,17 @@ export class ExtensionRunner {
391
392
  confirm: (title, message, opts) => this.withUIPrompt("confirm", title, () => ui.confirm(title, message, opts)),
392
393
  input: (title, placeholder, opts) => this.withUIPrompt("input", title, () => ui.input(title, placeholder, opts)),
393
394
  editor: (title, prefill) => this.withUIPrompt("editor", title, () => ui.editor(title, prefill)),
394
- custom: (factory, options) => this.withUIPrompt("custom", undefined, () => ui.custom(factory, options)),
395
+ custom: (factory, options) => {
396
+ if (options?.overlay) {
397
+ const overlayOptions = typeof options.overlayOptions === "function" ? options.overlayOptions() : options.overlayOptions;
398
+ // Passive overlays live alongside dialogs and must not hold their prompt depth open.
399
+ const resolvedOptions = { ...options, overlayOptions };
400
+ if (overlayOptions?.nonCapturing)
401
+ return ui.custom(factory, resolvedOptions);
402
+ return this.withUIPrompt("custom", undefined, () => ui.custom(factory, resolvedOptions));
403
+ }
404
+ return this.withUIPrompt("custom", undefined, () => ui.custom(factory, options));
405
+ },
395
406
  };
396
407
  }
397
408
  withUIPrompt(kind, title, run) {