@qwen-code/qwen-code 0.19.5 → 0.19.6-nightly.20260705.015ee4248

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 (264) hide show
  1. package/bundled/dataviz/SKILL.md +50 -0
  2. package/bundled/dataviz/references/anti-patterns.md +12 -0
  3. package/bundled/dataviz/references/choosing-a-form.md +16 -0
  4. package/bundled/dataviz/references/palette.md +57 -0
  5. package/bundled/dataviz/scripts/validate_palette.js +328 -0
  6. package/bundled/loop/SKILL.md +1 -1
  7. package/bundled/qc-helper/docs/configuration/settings.md +14 -8
  8. package/bundled/qc-helper/docs/features/headless.md +2 -2
  9. package/bundled/qc-helper/docs/features/scheduled-tasks.md +4 -2
  10. package/bundled/qc-helper/docs/reference/keyboard-shortcuts.md +1 -1
  11. package/bundled/review/DESIGN.md +23 -0
  12. package/bundled/review/SKILL.md +65 -8
  13. package/chunks/{MaxSizedBox-5JV77KRA.js → MaxSizedBox-PRXTXIGC.js} +31 -30
  14. package/chunks/{StandaloneSessionPicker-MGUGB6PH.js → StandaloneSessionPicker-PV7BSC5D.js} +42 -41
  15. package/chunks/{acpAgent-4F36XM3X.js → acpAgent-F34HNAM3.js} +939 -424
  16. package/chunks/{agent-IWBUZI6A.js → agent-XSQDKLST.js} +26 -25
  17. package/chunks/{agent-headless-JUTICAYO.js → agent-headless-B63XCKWX.js} +26 -25
  18. package/chunks/{anthropicContentGenerator-WL3LJOUB.js → anthropicContentGenerator-INXXI4PW.js} +7 -7
  19. package/chunks/{artifact-tool-W76WC2JX.js → artifact-tool-H2TNPNP5.js} +16 -3
  20. package/chunks/{askUserQuestion-J3P6TH3V.js → askUserQuestion-MKL5ZTMC.js} +2 -2
  21. package/chunks/{bridge-DHZHQ4UV.js → bridge-NCZDJBRF.js} +34 -32
  22. package/chunks/{channel-worker-supervisor-EVPAYNZ5.js → channel-worker-supervisor-JUYQ5Z4R.js} +5 -5
  23. package/chunks/{chunk-AVQDCKNF.js → chunk-22MNNNXE.js} +4 -0
  24. package/chunks/chunk-3RW4AZJV.js +5063 -0
  25. package/chunks/chunk-3VJ7MT3N.js +111 -0
  26. package/chunks/{chunk-JKGCBO3O.js → chunk-3VRMGS3A.js} +4 -4
  27. package/chunks/{chunk-TN6RT6EJ.js → chunk-3WOJO5EJ.js} +16 -4
  28. package/chunks/{chunk-G7OQ3RFJ.js → chunk-42XGFRJS.js} +3 -3
  29. package/chunks/{chunk-MOUXUCXQ.js → chunk-4KJ2BPIT.js} +1 -1
  30. package/chunks/{chunk-PPFWEV7G.js → chunk-4RQIB5UZ.js} +62 -62
  31. package/chunks/{chunk-JJ6B3ZD3.js → chunk-544UZQBD.js} +3 -3
  32. package/chunks/{chunk-B236XPGF.js → chunk-5UDYETKK.js} +1 -1
  33. package/chunks/{chunk-7DMQRPC7.js → chunk-6BEOH4KK.js} +1 -1
  34. package/chunks/{chunk-CXBG27SF.js → chunk-6IAWPIQ6.js} +3 -2
  35. package/chunks/{chunk-MDBNFHIO.js → chunk-6MDY7FX3.js} +5 -5
  36. package/chunks/{chunk-RM3PGSGL.js → chunk-6SHO7WFF.js} +15 -2
  37. package/chunks/{chunk-YCU7QV7Q.js → chunk-73WGF3NW.js} +34 -1
  38. package/chunks/{chunk-T42ACHFI.js → chunk-7LTB54MK.js} +1 -1
  39. package/chunks/{chunk-SJVPSHXU.js → chunk-7U6J224Z.js} +132 -25
  40. package/chunks/{chunk-CSPSJU5R.js → chunk-7WLJPMWU.js} +17 -17
  41. package/chunks/{chunk-R6RI2HIC.js → chunk-ACD5DFUY.js} +41 -14
  42. package/chunks/{chunk-EWALXUAD.js → chunk-AGHU5VRK.js} +8 -0
  43. package/chunks/{chunk-GLPV75ES.js → chunk-AHNJGLFV.js} +2 -2
  44. package/chunks/{chunk-DRS2HTNT.js → chunk-AOAFX4PL.js} +5 -5
  45. package/chunks/{chunk-QHYITL6P.js → chunk-CK7IUFOB.js} +63 -22
  46. package/chunks/{chunk-RSBQS6M4.js → chunk-CODWJXQA.js} +1 -1
  47. package/chunks/{chunk-LWGLBVWA.js → chunk-CSOTA7KX.js} +1 -1
  48. package/chunks/{chunk-UJT42DB6.js → chunk-DFH4T5IQ.js} +6 -6
  49. package/chunks/{chunk-DX3TKXNT.js → chunk-DJACOX4C.js} +2 -2
  50. package/chunks/{chunk-KKQWC6WS.js → chunk-DNV4FSN5.js} +1 -1
  51. package/chunks/{chunk-YPCPZSZB.js → chunk-DT3B47QP.js} +1 -1
  52. package/chunks/{chunk-NIOPRZNN.js → chunk-E7KNELIZ.js} +1 -1
  53. package/chunks/{chunk-DG573EOO.js → chunk-FEJ2FZ3U.js} +1 -1
  54. package/chunks/{chunk-M5ITDKSM.js → chunk-FHGQFG2K.js} +1 -1
  55. package/chunks/{chunk-HISPEX42.js → chunk-FSXFNDTI.js} +7 -7
  56. package/chunks/{chunk-LHMZCIKL.js → chunk-FUW7YGJU.js} +3 -1
  57. package/chunks/{chunk-Y4UQT3PM.js → chunk-FV5SBNNC.js} +1 -1
  58. package/chunks/{chunk-YTFBURQD.js → chunk-GB6HDZIK.js} +10 -2
  59. package/chunks/{chunk-D5KISTLW.js → chunk-H6EMK6QK.js} +1 -1
  60. package/chunks/{chunk-2Z43HUXT.js → chunk-HLKG6CZN.js} +3 -2
  61. package/chunks/{chunk-VXGPYF7U.js → chunk-IFEWJXFS.js} +1 -1
  62. package/chunks/{chunk-TENOUWY2.js → chunk-IJRL2S3D.js} +3 -3
  63. package/chunks/{chunk-OQHLUA2Y.js → chunk-IL6ZEDZ2.js} +4 -4
  64. package/chunks/{chunk-2CAII5HD.js → chunk-J7XUJALJ.js} +1 -1
  65. package/chunks/chunk-JFFOH2XO.js +2472 -0
  66. package/chunks/{chunk-NNEJEBCF.js → chunk-K3FZXSTO.js} +95 -107
  67. package/chunks/{chunk-NDY7OENU.js → chunk-KB4ICCA5.js} +3 -3
  68. package/chunks/{chunk-MNOXKSM2.js → chunk-LFFF2SPV.js} +3 -3
  69. package/chunks/{chunk-J3ERRYYI.js → chunk-LTMDKOZC.js} +2 -2
  70. package/chunks/{chunk-R3UWLLRQ.js → chunk-M7AGQP5D.js} +1 -1
  71. package/chunks/{chunk-CBJE2PLG.js → chunk-MLB5AB2I.js} +4 -4
  72. package/chunks/{chunk-YHTNWGRR.js → chunk-MZ7BABX3.js} +1 -1
  73. package/chunks/{chunk-SJBIFVD2.js → chunk-NFE3DQ4R.js} +7 -3
  74. package/chunks/{chunk-BC4R5C5R.js → chunk-NLD2WKE3.js} +55 -12
  75. package/chunks/{chunk-ALX6BUYW.js → chunk-NUGPZXAZ.js} +35 -1
  76. package/chunks/{chunk-NSSVORTQ.js → chunk-NYKWPUAE.js} +17 -13
  77. package/chunks/{chunk-K4I4STSL.js → chunk-OGEJMKN5.js} +2 -2
  78. package/chunks/{chunk-HTWHAN44.js → chunk-PC4ZXHU2.js} +1 -1
  79. package/chunks/{chunk-2YH27UNF.js → chunk-QLBBV7C6.js} +1 -1
  80. package/chunks/chunk-QT7XKZT7.js +293 -0
  81. package/chunks/{chunk-NPQWQYU6.js → chunk-QYNNN7BK.js} +1 -1
  82. package/chunks/chunk-R4N3OALZ.js +5631 -0
  83. package/chunks/{chunk-G4M7FPNY.js → chunk-RB5GAQR6.js} +2 -2
  84. package/chunks/{chunk-SBMHB6N5.js → chunk-RPHMD5UC.js} +15 -15
  85. package/chunks/{chunk-CHY5C5T4.js → chunk-SJ2CTIYH.js} +185 -88
  86. package/chunks/chunk-SLQXGMYY.js +949 -0
  87. package/chunks/{chunk-BZHLWC6T.js → chunk-SUAKHHK7.js} +2 -2
  88. package/chunks/{chunk-IMAMNLY6.js → chunk-SWV4CVYG.js} +158 -3
  89. package/chunks/{chunk-XKSCTXPK.js → chunk-TDGF35EN.js} +4 -3
  90. package/chunks/{chunk-TOAUDIS7.js → chunk-TLWA7TPR.js} +6 -2
  91. package/chunks/{chunk-WALEWZ44.js → chunk-UVHL5TCO.js} +1 -1
  92. package/chunks/{chunk-ZISMVA6U.js → chunk-VDMM5LVR.js} +1566 -37
  93. package/chunks/{chunk-BPFJQGY7.js → chunk-VEB3NYSO.js} +164 -5
  94. package/chunks/{chunk-L7OJ3ZO3.js → chunk-VZ7HY3YU.js} +1 -1
  95. package/chunks/{chunk-6KPZJJ6U.js → chunk-W4I6PLEG.js} +131 -38
  96. package/chunks/{chunk-QOMAHFYI.js → chunk-W7EEOR7D.js} +3 -3
  97. package/chunks/{chunk-6QVQZAW6.js → chunk-WKP5QZOP.js} +1 -1
  98. package/chunks/{chunk-YXK4GPYO.js → chunk-WMPVYQ4P.js} +30 -1
  99. package/chunks/{chunk-DM4E337C.js → chunk-WNTS5A2R.js} +5 -5
  100. package/chunks/{chunk-6QTCOQX7.js → chunk-WOG7QWIT.js} +3086 -2635
  101. package/chunks/{chunk-UY2TCIZS.js → chunk-X265R5C6.js} +3 -3
  102. package/chunks/{chunk-LKWAVAB5.js → chunk-X2XNQQJI.js} +2 -2
  103. package/chunks/{chunk-MTNTVOJR.js → chunk-X3YGAX7V.js} +6 -3
  104. package/chunks/{chunk-EROWZQN7.js → chunk-XD3OLPII.js} +6 -6
  105. package/chunks/{chunk-RNGAT2Y2.js → chunk-YYL6HROQ.js} +1 -1
  106. package/chunks/{chunk-XKZXGIRM.js → chunk-YZ2LNTHO.js} +2 -2
  107. package/chunks/{chunk-Z7XNVNPM.js → chunk-YZ5ANQMR.js} +3 -3
  108. package/chunks/{chunk-4MCC4XHH.js → chunk-Z7EYROOJ.js} +3568 -5508
  109. package/chunks/{chunk-5B2WNM6V.js → chunk-ZI4MGBB5.js} +1 -1
  110. package/chunks/{chunk-WZ724G6K.js → chunk-ZPGE42V7.js} +6 -6
  111. package/chunks/{computer-use-ON3JQUHW.js → computer-use-5I2UHVNY.js} +26 -25
  112. package/chunks/{contextCommand-OGCG7W6N.js → contextCommand-3NWY7AJG.js} +28 -27
  113. package/chunks/{cron-create-6YTCOX6P.js → cron-create-O6ZHD3JN.js} +22 -7
  114. package/chunks/{cron-delete-E3NIFSUK.js → cron-delete-BFD5B2XX.js} +4 -4
  115. package/chunks/{cron-list-Q64MNQNE.js → cron-list-KI6FV4KN.js} +4 -4
  116. package/chunks/{daemon-EEB2RYOL.js → daemon-DRUMLVFP.js} +140 -0
  117. package/chunks/daemon-status-provider-A2DK3ZTO.js +74 -0
  118. package/chunks/{dist-AP5V4WYU.js → dist-AAO65DPC.js} +2 -2
  119. package/chunks/{dist-X4ZDE726.js → dist-ABQ7VWRR.js} +3 -3
  120. package/chunks/{dist-SNXOUPYS.js → dist-AW5ZYMUI.js} +2 -2
  121. package/chunks/{dist-Z57Q4YF5.js → dist-DN6M6TJ5.js} +525 -95
  122. package/chunks/{dist-IZP2VV4C.js → dist-JPSVN367.js} +2 -2
  123. package/chunks/{earlyInputCapture-DAFHSGVW.js → earlyInputCapture-5TMSSPQ5.js} +27 -26
  124. package/chunks/{edit-3QFNCSZH.js → edit-V4ITLSUD.js} +27 -26
  125. package/chunks/{en-M4EBUBNU.js → en-AXARKOWO.js} +2 -0
  126. package/chunks/{enter-worktree-62EQQMLD.js → enter-worktree-7ULPRMTJ.js} +26 -25
  127. package/chunks/{enterPlanMode-VUQSE4EG.js → enterPlanMode-YSHMLHJZ.js} +26 -25
  128. package/chunks/{errors-PW75PZXE.js → errors-TCUTD7NF.js} +28 -27
  129. package/chunks/{exit-worktree-VVNH7OVY.js → exit-worktree-JZDCKR6A.js} +26 -25
  130. package/chunks/{exitPlanMode-RUYRCYZW.js → exitPlanMode-GOQBN6SG.js} +26 -25
  131. package/chunks/{fast-path-TFRJRTTR.js → fast-path-F2HGAKO2.js} +3 -3
  132. package/chunks/{fast-path-settings-UQLRFDQP.js → fast-path-settings-RCRXH2JG.js} +2 -2
  133. package/chunks/{gemini-XW7ZDUVR.js → gemini-3M7ECKNW.js} +86 -80
  134. package/chunks/{geminiContentGenerator-MZDVHVZH.js → geminiContentGenerator-5EG3QEJM.js} +4 -4
  135. package/chunks/{glob-WAY2PUWA.js → glob-2DBDTLR4.js} +54 -29
  136. package/chunks/{grep-W6CBKSYC.js → grep-R27DLGWT.js} +26 -25
  137. package/chunks/{initializer-HK2XE6P2.js → initializer-OXB6BJZU.js} +32 -31
  138. package/chunks/{keychain-token-storage-GPAKRDKQ.js → keychain-token-storage-UJV5XP4Z.js} +2 -2
  139. package/chunks/{list-RVLIIKKL.js → list-HLCOEOSF.js} +33 -32
  140. package/chunks/{loadedSettingsAdapter-C63OUYZC.js → loadedSettingsAdapter-JHTVH3YO.js} +31 -30
  141. package/chunks/{loop-wakeup-G2EHBRGR.js → loop-wakeup-CUVIY2JY.js} +5 -5
  142. package/chunks/{ls-IDHUVSAG.js → ls-L654WOAT.js} +4 -4
  143. package/chunks/{lsp-FSRYXGFT.js → lsp-M35KE54Y.js} +2 -2
  144. package/chunks/mcp-2JWEFAIN.js +67 -0
  145. package/chunks/{monitor-FOG36ABM.js → monitor-5QKFZFDX.js} +26 -25
  146. package/chunks/nonInteractiveCli-W5W5PIHI.js +112 -0
  147. package/chunks/{notebook-edit-GC6NXRCX.js → notebook-edit-XAFBWORI.js} +27 -26
  148. package/chunks/{openaiContentGenerator-EXR3ZL3Z.js → openaiContentGenerator-NULJROYV.js} +13 -12
  149. package/chunks/{pidfile-FNZM2DDH.js → pidfile-3LT7PZSW.js} +27 -26
  150. package/chunks/{qwenContentGenerator-A7B6J4U7.js → qwenContentGenerator-KLSURVNH.js} +28 -27
  151. package/chunks/{qwenOAuth2-LWLA6MQG.js → qwenOAuth2-ZV7YLMND.js} +5 -5
  152. package/chunks/{read-file-6JL4ULMY.js → read-file-HDAM3RHJ.js} +8 -8
  153. package/chunks/{read-mcp-resource-PIJF24RO.js → read-mcp-resource-CNQHBSJM.js} +2 -2
  154. package/chunks/record-artifact-PP3LKHTS.js +343 -0
  155. package/chunks/{ripGrep-DIUGLJE5.js → ripGrep-W36NLR7M.js} +26 -25
  156. package/chunks/{run-qwen-serve-CME3AKM4.js → run-qwen-serve-IMI2CQB5.js} +72 -28
  157. package/chunks/{scheduler-L7F6GDDT.js → scheduler-I5NKE5UJ.js} +26 -25
  158. package/chunks/{send-message-33PYFMCT.js → send-message-OA6MV4EU.js} +3 -3
  159. package/chunks/{serve-SRCBOJGP.js → serve-JMHMOYBO.js} +33 -32
  160. package/chunks/{server-QSQ45QFR.js → server-QIYIN34N.js} +1358 -492
  161. package/chunks/{session-5DG6NXHZ.js → session-BLL6HB35.js} +68 -65
  162. package/chunks/{settings-3EEQI4MN.js → settings-ABECXCTY.js} +30 -29
  163. package/chunks/{shell-B7FNYF5S.js → shell-A2TQI3U4.js} +26 -25
  164. package/chunks/{skill-AAOGHD5O.js → skill-4GTWZZWR.js} +10 -10
  165. package/chunks/{spawnChannel-3CBN3ZLK.js → spawnChannel-DFUVGP53.js} +30 -29
  166. package/chunks/{src-T5A7P7FS.js → src-ZORBMUM7.js} +77 -43
  167. package/chunks/{startInteractiveUI-2FGEQ6AS.js → startInteractiveUI-FH5MVXUE.js} +449 -175
  168. package/chunks/{syntheticOutput-YOSWIHDJ.js → syntheticOutput-F7LSDCAR.js} +3 -3
  169. package/chunks/{task-create-NHS2NGB3.js → task-create-RPFZNB4B.js} +7 -7
  170. package/chunks/{task-list-5UIB564R.js → task-list-TGGJX7EA.js} +5 -5
  171. package/chunks/{task-stop-HGXZ2VZ3.js → task-stop-W7NGTMYQ.js} +2 -2
  172. package/chunks/{task-update-IYYWUILG.js → task-update-5WUG5MVQ.js} +7 -7
  173. package/chunks/{team-create-KDF6W6PV.js → team-create-F76QOR6H.js} +26 -25
  174. package/chunks/{team-delete-FEKJCU4P.js → team-delete-UHQQ2QQX.js} +5 -5
  175. package/chunks/{team-plan-approval-PSFKQX7M.js → team-plan-approval-OKM7YZC2.js} +26 -25
  176. package/chunks/{theme-manager-5XOA2AO7.js → theme-manager-6R7EVWHW.js} +27 -26
  177. package/chunks/{todoWrite-TKMVZ2HT.js → todoWrite-C4ZAMSR3.js} +4 -4
  178. package/chunks/{tool-search-LFRILZXC.js → tool-search-UWXDKI7D.js} +9 -9
  179. package/chunks/{trustedFolders-7HQY6T6X.js → trustedFolders-DHASVVUP.js} +27 -26
  180. package/chunks/{validateNonInterActiveAuth-UC27B7BA.js → validateNonInterActiveAuth-56J7MOOP.js} +62 -59
  181. package/chunks/version-NE2I4PBN.js +10 -0
  182. package/chunks/{web-fetch-J4PIW36Q.js → web-fetch-UYGMOHW4.js} +5 -5
  183. package/chunks/{workflow-KUTESS6L.js → workflow-HGF3URV3.js} +35 -27
  184. package/chunks/{workspace-providers-status-LJT5AQDS.js → workspace-providers-status-KXB2OZFQ.js} +33 -32
  185. package/chunks/{workspace-service-YOBYVDXH.js → workspace-service-NSTI55BC.js} +39 -38
  186. package/chunks/workspace-skills-status-X5S6JGQZ.js +69 -0
  187. package/chunks/{write-file-FJYBZUHP.js → write-file-HVKT5VTX.js} +27 -26
  188. package/chunks/yargs-B64EYTCF.js +10 -0
  189. package/chunks/{zh-SLZNSSZB.js → zh-RS3HZHFH.js} +2 -0
  190. package/chunks/{zh-TW-P53C2SL5.js → zh-TW-L5GRQ4S4.js} +2 -0
  191. package/cli-entry.js +81 -8
  192. package/cli.js +348 -55
  193. package/locales/en.js +2 -0
  194. package/locales/zh-TW.js +2 -0
  195. package/locales/zh.js +2 -0
  196. package/node_modules/@qwen-code/audio-capture/package.json +1 -1
  197. package/node_modules/@qwen-code/audio-capture/prebuilds/darwin-arm64/@qwen-code+audio-capture.node +0 -0
  198. package/node_modules/@qwen-code/audio-capture/prebuilds/darwin-x64/@qwen-code+audio-capture.node +0 -0
  199. package/node_modules/@qwen-code/audio-capture/prebuilds/win32-x64/@qwen-code+audio-capture.node +0 -0
  200. package/package.json +3 -3
  201. package/web-shell/assets/{arc-D_rAuMDd.js → arc-Csx4m4N0.js} +1 -1
  202. package/web-shell/assets/{architectureDiagram-3BPJPVTR-DUCzbHVo.js → architectureDiagram-3BPJPVTR-BEa0vCM7.js} +1 -1
  203. package/web-shell/assets/{blockDiagram-GPEHLZMM-BEEBt1LL.js → blockDiagram-GPEHLZMM-BPzbKnn3.js} +1 -1
  204. package/web-shell/assets/{c4Diagram-AAUBKEIU-5ZJ_DeFL.js → c4Diagram-AAUBKEIU-B8YO71yP.js} +1 -1
  205. package/web-shell/assets/channel-QU1XUuVe.js +1 -0
  206. package/web-shell/assets/{chunk-2J33WTMH-Cfw7EiLn.js → chunk-2J33WTMH-32XhwSHt.js} +1 -1
  207. package/web-shell/assets/{chunk-4BX2VUAB-FGuZNCZY.js → chunk-4BX2VUAB-Bmoyo6PS.js} +1 -1
  208. package/web-shell/assets/{chunk-55IACEB6-CaBwYPBF.js → chunk-55IACEB6-TwH6PFhs.js} +1 -1
  209. package/web-shell/assets/{chunk-727SXJPM-BlR04OFz.js → chunk-727SXJPM-RI_IVUtZ.js} +1 -1
  210. package/web-shell/assets/{chunk-AQP2D5EJ-D3_mYJH5.js → chunk-AQP2D5EJ-DH6GIAZD.js} +1 -1
  211. package/web-shell/assets/{chunk-FMBD7UC4-7D4q4SbB.js → chunk-FMBD7UC4-DeD3k3D5.js} +1 -1
  212. package/web-shell/assets/{chunk-ND2GUHAM-BjX_Iwmr.js → chunk-ND2GUHAM-BLPb8nv3.js} +1 -1
  213. package/web-shell/assets/{chunk-QZHKN3VN-C3Hz_ZQh.js → chunk-QZHKN3VN-PZpyglW1.js} +1 -1
  214. package/web-shell/assets/classDiagram-4FO5ZUOK-fv1EWO-L.js +1 -0
  215. package/web-shell/assets/classDiagram-v2-Q7XG4LA2-fv1EWO-L.js +1 -0
  216. package/web-shell/assets/{cose-bilkent-S5V4N54A-Ax4UycaT.js → cose-bilkent-S5V4N54A-Jsd0yKfz.js} +1 -1
  217. package/web-shell/assets/{dagre-BM42HDAG-C6hmPtGt.js → dagre-BM42HDAG-B-zADciZ.js} +1 -1
  218. package/web-shell/assets/{diagram-2AECGRRQ-tXZnxjmw.js → diagram-2AECGRRQ-Cn6GDxoo.js} +1 -1
  219. package/web-shell/assets/{diagram-5GNKFQAL-99dwIzQG.js → diagram-5GNKFQAL-udLgyJxO.js} +1 -1
  220. package/web-shell/assets/{diagram-KO2AKTUF-Bqhn0-2s.js → diagram-KO2AKTUF-EcLpfzy3.js} +1 -1
  221. package/web-shell/assets/{diagram-LMA3HP47-DzThVSvo.js → diagram-LMA3HP47-D-YFbYsJ.js} +1 -1
  222. package/web-shell/assets/{diagram-OG6HWLK6-DPE8vjln.js → diagram-OG6HWLK6-C8oRUATa.js} +1 -1
  223. package/web-shell/assets/{erDiagram-TEJ5UH35-KzUKgQCV.js → erDiagram-TEJ5UH35-DPH5nStc.js} +1 -1
  224. package/web-shell/assets/{flowDiagram-I6XJVG4X-DBN-DXw5.js → flowDiagram-I6XJVG4X-CSOTwkAt.js} +1 -1
  225. package/web-shell/assets/{ganttDiagram-6RSMTGT7-DuBsP9u8.js → ganttDiagram-6RSMTGT7-D0L988t0.js} +1 -1
  226. package/web-shell/assets/{gitGraphDiagram-PVQCEYII-BjWHMyKR.js → gitGraphDiagram-PVQCEYII-B9Oo7gxS.js} +1 -1
  227. package/web-shell/assets/index-BYZZL5N7.css +5 -0
  228. package/web-shell/assets/index-C_oTyz0s.js +753 -0
  229. package/web-shell/assets/{infoDiagram-5YYISTIA-BVux0vP6.js → infoDiagram-5YYISTIA-Ddj4YN2P.js} +1 -1
  230. package/web-shell/assets/{ishikawaDiagram-YF4QCWOH-2qzw7f--.js → ishikawaDiagram-YF4QCWOH-CBjafcl7.js} +1 -1
  231. package/web-shell/assets/{journeyDiagram-JHISSGLW-Dnl65sxL.js → journeyDiagram-JHISSGLW-Bn3XD99u.js} +1 -1
  232. package/web-shell/assets/{kanban-definition-UN3LZRKU-BElSQYtY.js → kanban-definition-UN3LZRKU-D7PBPJmE.js} +1 -1
  233. package/web-shell/assets/{linear-BjoycSSY.js → linear-Bmfo22rZ.js} +1 -1
  234. package/web-shell/assets/{mermaid.core-xe6bvMRz.js → mermaid.core-xRkAI-EI.js} +5 -5
  235. package/web-shell/assets/{mindmap-definition-RKZ34NQL-D8DQgI4U.js → mindmap-definition-RKZ34NQL-B30zRinm.js} +1 -1
  236. package/web-shell/assets/{pieDiagram-4H26LBE5-Dwh7Gp7c.js → pieDiagram-4H26LBE5-DblnKR9Z.js} +1 -1
  237. package/web-shell/assets/{quadrantDiagram-W4KKPZXB-BXKNBln2.js → quadrantDiagram-W4KKPZXB-COkHFKjF.js} +1 -1
  238. package/web-shell/assets/{requirementDiagram-4Y6WPE33-BzaC3cIA.js → requirementDiagram-4Y6WPE33-DDU3MMyn.js} +1 -1
  239. package/web-shell/assets/{sankeyDiagram-5OEKKPKP-DP2t7eZk.js → sankeyDiagram-5OEKKPKP-Dt4lqEYv.js} +1 -1
  240. package/web-shell/assets/{sequenceDiagram-3UESZ5HK-XlFiWEYv.js → sequenceDiagram-3UESZ5HK-BRzby5gN.js} +1 -1
  241. package/web-shell/assets/{stateDiagram-AJRCARHV-CupgUMJO.js → stateDiagram-AJRCARHV-CylzByc3.js} +1 -1
  242. package/web-shell/assets/stateDiagram-v2-BHNVJYJU-BKWZIKkM.js +1 -0
  243. package/web-shell/assets/{timeline-definition-PNZ67QCA-DstuGywa.js → timeline-definition-PNZ67QCA-BSzaNx6w.js} +1 -1
  244. package/web-shell/assets/{vennDiagram-CIIHVFJN-CnbNp6zu.js → vennDiagram-CIIHVFJN-BbzeKzCo.js} +1 -1
  245. package/web-shell/assets/{wardley-L42UT6IY-DnvoHq6R.js → wardley-L42UT6IY-BRJwCgE_.js} +1 -1
  246. package/web-shell/assets/{wardleyDiagram-YWT4CUSO-Cz0xHEWB.js → wardleyDiagram-YWT4CUSO-BmAs0mJ-.js} +1 -1
  247. package/web-shell/assets/{xychartDiagram-2RQKCTM6-p36gfo88.js → xychartDiagram-2RQKCTM6-DqywSqVW.js} +1 -1
  248. package/web-shell/index.html +2 -2
  249. package/bundled/loop/SKILL.test.ts +0 -119
  250. package/bundled/loop/autonomous-loop.test.ts +0 -59
  251. package/bundled/loop/loop-task-file.test.ts +0 -1064
  252. package/bundled/loop/loop-tick-resolver.test.ts +0 -906
  253. package/chunks/chunk-EJ7BN3EN.js +0 -11396
  254. package/chunks/chunk-L7QPM2YD.js +0 -481
  255. package/chunks/daemon-status-provider-P72STMLB.js +0 -72
  256. package/chunks/nonInteractiveCli-6BYQSJTB.js +0 -109
  257. package/chunks/workspace-skills-status-ONEPXJV6.js +0 -62
  258. package/web-shell/assets/channel-B5ynH0q8.js +0 -1
  259. package/web-shell/assets/classDiagram-4FO5ZUOK-CK3ibywp.js +0 -1
  260. package/web-shell/assets/classDiagram-v2-Q7XG4LA2-CK3ibywp.js +0 -1
  261. package/web-shell/assets/index-9qfvU0_r.css +0 -5
  262. package/web-shell/assets/index-CWzDaQT5.js +0 -717
  263. package/web-shell/assets/stateDiagram-v2-BHNVJYJU-By3E4QwN.js +0 -1
  264. package/chunks/{chunk-UFC57OYT.js → chunk-VRDMOSQS.js} +54 -54
@@ -6,7 +6,7 @@ import {
6
6
  } from "./chunk-GO6LNQXT.js";
7
7
  import {
8
8
  ToolNames
9
- } from "./chunk-MTNTVOJR.js";
9
+ } from "./chunk-X3YGAX7V.js";
10
10
  import {
11
11
  init_esbuild_shims
12
12
  } from "./chunk-A4BMJM77.js";
@@ -14,13 +14,137 @@ import {
14
14
  __name
15
15
  } from "./chunk-J2S4EL5Y.js";
16
16
 
17
- // packages/core/src/agents/runtime/agent-context.ts
17
+ // packages/core/src/subagents/types.ts
18
+ init_esbuild_shims();
19
+ var BUBBLE_APPROVAL_MODE = "bubble";
20
+ var SubagentError = class extends Error {
21
+ constructor(message, code, subagentName) {
22
+ super(message);
23
+ this.code = code;
24
+ this.subagentName = subagentName;
25
+ this.name = "SubagentError";
26
+ }
27
+ static {
28
+ __name(this, "SubagentError");
29
+ }
30
+ };
31
+ var SubagentErrorCode = {
32
+ NOT_FOUND: "NOT_FOUND",
33
+ ALREADY_EXISTS: "ALREADY_EXISTS",
34
+ INVALID_CONFIG: "INVALID_CONFIG",
35
+ INVALID_NAME: "INVALID_NAME",
36
+ FILE_ERROR: "FILE_ERROR",
37
+ VALIDATION_ERROR: "VALIDATION_ERROR",
38
+ TOOL_NOT_FOUND: "TOOL_NOT_FOUND"
39
+ };
40
+
41
+ // packages/core/src/tools/agent/fork-subagent.ts
18
42
  init_esbuild_shims();
19
43
  import { AsyncLocalStorage } from "node:async_hooks";
20
- var storage = new AsyncLocalStorage();
21
- function runWithAgentContext(agentId, fn) {
44
+ var FORK_SUBAGENT_TYPE = "fork";
45
+ function isForkSubagentEnabled(config) {
46
+ return config.isInteractive();
47
+ }
48
+ __name(isForkSubagentEnabled, "isForkSubagentEnabled");
49
+ var FORK_BOILERPLATE_TAG = "fork-boilerplate";
50
+ var FORK_DIRECTIVE_PREFIX = "Directive: ";
51
+ var FORK_AGENT = {
52
+ name: FORK_SUBAGENT_TYPE,
53
+ description: 'Fork yourself \u2014 inherits your full conversation context. Selected explicitly via `subagent_type: "fork"` (only in interactive sessions). Runs detached in the background; you are notified when it completes.',
54
+ tools: ["*"],
55
+ systemPrompt: "You are a forked worker process. Follow the directive in the conversation history. Execute tasks directly using available tools. Do not spawn sub-agents.",
56
+ // `bubble` surfaces this fork's permission prompts to the parent's Background-
57
+ // tasks UI; a detached fork has no inline UI, so 'default' would auto-deny them.
58
+ approvalMode: BUBBLE_APPROVAL_MODE,
59
+ level: "session"
60
+ };
61
+ var FORK_DEFAULT_MAX_TURNS = 200;
62
+ var forkExecutionStorage = new AsyncLocalStorage();
63
+ function runInForkContext(fn) {
64
+ return forkExecutionStorage.run({ marker: true }, fn);
65
+ }
66
+ __name(runInForkContext, "runInForkContext");
67
+ function isInForkExecution() {
68
+ return forkExecutionStorage.getStore() !== void 0;
69
+ }
70
+ __name(isInForkExecution, "isInForkExecution");
71
+ var FORK_PLACEHOLDER_RESULT = "Fork started \u2014 processing in background";
72
+ function buildFunctionResponseParts(assistantMessage, placeholderOutput) {
73
+ return (assistantMessage.parts?.filter((part) => part.functionCall) ?? []).map((part) => ({
74
+ functionResponse: {
75
+ id: part.functionCall.id,
76
+ name: part.functionCall.name,
77
+ response: { output: placeholderOutput }
78
+ }
79
+ }));
80
+ }
81
+ __name(buildFunctionResponseParts, "buildFunctionResponseParts");
82
+ function buildForkedMessages(directive, assistantMessage) {
83
+ const toolUseParts = assistantMessage.parts?.filter((part) => part.functionCall) || [];
84
+ if (toolUseParts.length === 0) {
85
+ return [];
86
+ }
87
+ const fullAssistantMessage = {
88
+ role: assistantMessage.role,
89
+ parts: [...assistantMessage.parts || []]
90
+ };
91
+ const toolResultParts = buildFunctionResponseParts(
92
+ assistantMessage,
93
+ FORK_PLACEHOLDER_RESULT
94
+ );
95
+ const toolResultMessage = {
96
+ role: "user",
97
+ parts: [
98
+ ...toolResultParts,
99
+ {
100
+ text: buildChildMessage(directive)
101
+ }
102
+ ]
103
+ };
104
+ return [fullAssistantMessage, toolResultMessage];
105
+ }
106
+ __name(buildForkedMessages, "buildForkedMessages");
107
+ function buildWorktreeNotice(parentCwd, worktreeCwd) {
108
+ return `You are operating in an isolated git worktree at ${worktreeCwd}. The parent agent is in ${parentCwd}. Same repository, same relative file layout, separate working copy. All your file edits, writes, and shell commands MUST target paths under ${worktreeCwd}. When the inherited context references a path under ${parentCwd}, translate it to the corresponding path under ${worktreeCwd} before acting on it. Re-read any file you intend to edit (the parent may have modified it after the snapshot in your context). Your changes stay in this worktree and do not affect the parent's working tree.`;
109
+ }
110
+ __name(buildWorktreeNotice, "buildWorktreeNotice");
111
+ function buildChildMessage(directive) {
112
+ return `<${FORK_BOILERPLATE_TAG}>
113
+ STOP. READ THIS FIRST.
114
+
115
+ You are a forked worker process. You are NOT the main agent.
116
+
117
+ RULES (non-negotiable):
118
+ 1. You ARE the fork. Do NOT spawn sub-agents; execute directly.
119
+ 2. Do NOT converse, ask questions, or suggest next steps
120
+ 3. Do NOT editorialize or add meta-commentary
121
+ 4. USE your tools directly: Bash, Read, Write, etc.
122
+ 5. If you modify files, commit your changes before reporting. Include the commit hash in your report.
123
+ 6. Do NOT emit text between tool calls. Use tools silently, then report once at the end.
124
+ 7. Stay strictly within your directive's scope. If you discover related systems outside your scope, mention them in one sentence at most \u2014 other workers cover those areas.
125
+ 8. Keep your report under 500 words unless the directive specifies otherwise. Be factual and concise.
126
+ 9. Your response MUST begin with "Scope:". No preamble, no thinking-out-loud.
127
+ 10. REPORT structured facts, then stop
128
+
129
+ Output format (plain text labels, not markdown headers):
130
+ Scope: <echo back your assigned scope in one sentence>
131
+ Result: <the answer or key findings, limited to the scope above>
132
+ Key files: <relevant file paths \u2014 include for research tasks>
133
+ Files changed: <list with commit hash \u2014 include only if you modified files>
134
+ Issues: <list \u2014 include only if there are issues to flag>
135
+ </${FORK_BOILERPLATE_TAG}>
136
+
137
+ ${FORK_DIRECTIVE_PREFIX}${directive}`;
138
+ }
139
+ __name(buildChildMessage, "buildChildMessage");
140
+
141
+ // packages/core/src/agents/runtime/agent-context.ts
142
+ init_esbuild_shims();
143
+ import { AsyncLocalStorage as AsyncLocalStorage2 } from "node:async_hooks";
144
+ var storage = new AsyncLocalStorage2();
145
+ function runWithAgentContext(agentId, fn, depthOverride) {
22
146
  const current = storage.getStore() ?? {};
23
- const depth = (current.depth ?? -1) + 1;
147
+ const depth = depthOverride ?? (current.depth ?? -1) + 1;
24
148
  return storage.run({ ...current, agentId, depth }, fn);
25
149
  }
26
150
  __name(runWithAgentContext, "runWithAgentContext");
@@ -41,6 +165,25 @@ function getRuntimeContentGenerator() {
41
165
  return storage.getStore()?.runtimeView;
42
166
  }
43
167
  __name(getRuntimeContentGenerator, "getRuntimeContentGenerator");
168
+ function isTopLevelSession() {
169
+ return getCurrentAgentId() === null;
170
+ }
171
+ __name(isTopLevelSession, "isTopLevelSession");
172
+ function childLaunchDepth() {
173
+ return getCurrentAgentId() !== null ? getCurrentAgentDepth() + 1 : 0;
174
+ }
175
+ __name(childLaunchDepth, "childLaunchDepth");
176
+ function canSpawnNestedAgent(maxDepth) {
177
+ return childLaunchDepth() + 1 <= maxDepth;
178
+ }
179
+ __name(canSpawnNestedAgent, "canSpawnNestedAgent");
180
+ function spawnBlockReason(maxDepth) {
181
+ if (!canSpawnNestedAgent(maxDepth)) return "depth";
182
+ if (isTeammate()) return "teammate";
183
+ if (isInForkExecution()) return "fork";
184
+ return null;
185
+ }
186
+ __name(spawnBlockReason, "spawnBlockReason");
44
187
 
45
188
  // packages/core/src/config/approval-mode.ts
46
189
  init_esbuild_shims();
@@ -161,11 +304,27 @@ function buildSubagentPlanToolBlockedResult(toolName, logTag, logger) {
161
304
  __name(buildSubagentPlanToolBlockedResult, "buildSubagentPlanToolBlockedResult");
162
305
 
163
306
  export {
307
+ BUBBLE_APPROVAL_MODE,
308
+ SubagentError,
309
+ SubagentErrorCode,
310
+ FORK_SUBAGENT_TYPE,
311
+ isForkSubagentEnabled,
312
+ FORK_AGENT,
313
+ FORK_DEFAULT_MAX_TURNS,
314
+ runInForkContext,
315
+ FORK_PLACEHOLDER_RESULT,
316
+ buildFunctionResponseParts,
317
+ buildForkedMessages,
318
+ buildWorktreeNotice,
319
+ buildChildMessage,
164
320
  runWithAgentContext,
165
321
  runWithRuntimeContentGenerator,
166
322
  getCurrentAgentId,
167
323
  getCurrentAgentDepth,
168
324
  getRuntimeContentGenerator,
325
+ isTopLevelSession,
326
+ childLaunchDepth,
327
+ spawnBlockReason,
169
328
  ApprovalMode,
170
329
  APPROVAL_MODES,
171
330
  SUBAGENT_PLAN_LIFECYCLE_TOOLS,
@@ -5,7 +5,7 @@ import {
5
5
  } from "./chunk-OFEVLU4C.js";
6
6
  import {
7
7
  SchemaValidator
8
- } from "./chunk-MTNTVOJR.js";
8
+ } from "./chunk-X3YGAX7V.js";
9
9
  import {
10
10
  init_esbuild_shims
11
11
  } from "./chunk-A4BMJM77.js";
@@ -3,33 +3,34 @@
3
3
  import {
4
4
  handleAtCommand,
5
5
  resolveAtCommandQuery
6
- } from "./chunk-SJVPSHXU.js";
6
+ } from "./chunk-7U6J224Z.js";
7
7
  import {
8
8
  isAtCommand,
9
9
  isBtwCommand,
10
10
  isSlashCommand,
11
11
  normalizePartList,
12
12
  recordGoalStatusItem
13
- } from "./chunk-4MCC4XHH.js";
13
+ } from "./chunk-Z7EYROOJ.js";
14
14
  import {
15
15
  SHELL_COMMAND_NAME,
16
+ fitPendingSlice,
16
17
  useSessionStats
17
- } from "./chunk-IMAMNLY6.js";
18
+ } from "./chunk-SWV4CVYG.js";
18
19
  import {
19
20
  require_react
20
21
  } from "./chunk-KYMBIKIW.js";
21
22
  import {
22
23
  themeManager
23
- } from "./chunk-HTWHAN44.js";
24
+ } from "./chunk-PC4ZXHU2.js";
24
25
  import {
25
26
  formatMemoryUsage
26
27
  } from "./chunk-KHDZHZMH.js";
27
28
  import {
28
29
  isInlineModelOverrideAllowed
29
- } from "./chunk-K4I4STSL.js";
30
+ } from "./chunk-OGEJMKN5.js";
30
31
  import {
31
32
  t
32
- } from "./chunk-DM4E337C.js";
33
+ } from "./chunk-WNTS5A2R.js";
33
34
  import {
34
35
  AutonomousLoopTickResolver,
35
36
  CoreToolScheduler,
@@ -51,7 +52,7 @@ import {
51
52
  setActiveGoal,
52
53
  shouldRunVisionBridge,
53
54
  splitImageParts
54
- } from "./chunk-6QTCOQX7.js";
55
+ } from "./chunk-WOG7QWIT.js";
55
56
  import {
56
57
  ApiCancelEvent,
57
58
  ConversationFinishedEvent,
@@ -61,17 +62,17 @@ import {
61
62
  logConversationFinishedEvent,
62
63
  logUserPrompt,
63
64
  logUserRetry
64
- } from "./chunk-CHY5C5T4.js";
65
+ } from "./chunk-SJ2CTIYH.js";
65
66
  import {
66
67
  isAnyAutoMemPath
67
- } from "./chunk-MOUXUCXQ.js";
68
+ } from "./chunk-4KJ2BPIT.js";
68
69
  import {
69
70
  ToolNames
70
- } from "./chunk-MTNTVOJR.js";
71
+ } from "./chunk-X3YGAX7V.js";
71
72
  import {
72
73
  getUnsupportedImageFormatWarning,
73
74
  isSupportedImageMimeType
74
- } from "./chunk-YTFBURQD.js";
75
+ } from "./chunk-GB6HDZIK.js";
75
76
  import {
76
77
  FinishReason
77
78
  } from "./chunk-55ZMG67I.js";
@@ -80,7 +81,7 @@ import {
80
81
  createDebugLogger,
81
82
  getErrorMessage,
82
83
  isNodeError
83
- } from "./chunk-AVQDCKNF.js";
84
+ } from "./chunk-22MNNNXE.js";
84
85
  import {
85
86
  init_esbuild_shims
86
87
  } from "./chunk-A4BMJM77.js";
@@ -417,39 +418,61 @@ ${finalOutput}`;
417
418
 
418
419
  // packages/cli/src/ui/utils/markdownUtilities.ts
419
420
  init_esbuild_shims();
421
+ var findNextFence = /* @__PURE__ */ __name((content, from) => {
422
+ const backtick = content.indexOf("```", from);
423
+ const tilde = content.indexOf("~~~", from);
424
+ if (backtick === -1 && tilde === -1) return null;
425
+ let index;
426
+ let char;
427
+ if (tilde === -1 || backtick !== -1 && backtick < tilde) {
428
+ index = backtick;
429
+ char = "`";
430
+ } else {
431
+ index = tilde;
432
+ char = "~";
433
+ }
434
+ let length = 0;
435
+ while (content[index + length] === char) length++;
436
+ return { index, char, length };
437
+ }, "findNextFence");
420
438
  var isIndexInsideCodeBlock = /* @__PURE__ */ __name((content, indexToTest) => {
421
- let fenceCount = 0;
439
+ let openChar = "";
440
+ let openLen = 0;
422
441
  let searchPos = 0;
423
442
  while (searchPos < content.length) {
424
- const nextFence = content.indexOf("```", searchPos);
425
- if (nextFence === -1 || nextFence >= indexToTest) {
426
- break;
443
+ const fence = findNextFence(content, searchPos);
444
+ if (!fence || fence.index >= indexToTest) break;
445
+ if (openChar === "") {
446
+ openChar = fence.char;
447
+ openLen = fence.length;
448
+ } else if (fence.char === openChar && fence.length >= openLen) {
449
+ openChar = "";
450
+ openLen = 0;
427
451
  }
428
- fenceCount++;
429
- searchPos = nextFence + 3;
452
+ searchPos = fence.index + fence.length;
430
453
  }
431
- return fenceCount % 2 === 1;
454
+ return openChar !== "";
432
455
  }, "isIndexInsideCodeBlock");
433
456
  var findEnclosingCodeBlockStart = /* @__PURE__ */ __name((content, index) => {
434
- if (!isIndexInsideCodeBlock(content, index)) {
435
- return -1;
436
- }
437
- let currentSearchPos = 0;
438
- while (currentSearchPos < index) {
439
- const blockStartIndex = content.indexOf("```", currentSearchPos);
440
- if (blockStartIndex === -1 || blockStartIndex >= index) {
441
- break;
442
- }
443
- const blockEndIndex = content.indexOf("```", blockStartIndex + 3);
444
- if (blockStartIndex < index) {
445
- if (blockEndIndex === -1 || index < blockEndIndex + 3) {
446
- return blockStartIndex;
447
- }
457
+ let openChar = "";
458
+ let openLen = 0;
459
+ let openIndex = -1;
460
+ let searchPos = 0;
461
+ while (searchPos < content.length) {
462
+ const fence = findNextFence(content, searchPos);
463
+ if (!fence || fence.index >= index) break;
464
+ if (openChar === "") {
465
+ openChar = fence.char;
466
+ openLen = fence.length;
467
+ openIndex = fence.index;
468
+ } else if (fence.char === openChar && fence.length >= openLen) {
469
+ openChar = "";
470
+ openLen = 0;
471
+ openIndex = -1;
448
472
  }
449
- if (blockEndIndex === -1) break;
450
- currentSearchPos = blockEndIndex + 3;
473
+ searchPos = fence.index + fence.length;
451
474
  }
452
- return -1;
475
+ return openChar !== "" ? openIndex : -1;
453
476
  }, "findEnclosingCodeBlockStart");
454
477
  var findLastSafeSplitPoint = /* @__PURE__ */ __name((content, idealMaxLength) => {
455
478
  const hasLengthCap = idealMaxLength !== void 0;
@@ -899,6 +922,8 @@ var EDIT_TOOL_NAMES = /* @__PURE__ */ new Set([
899
922
  ]);
900
923
  var STREAM_UPDATE_THROTTLE_MS = 60;
901
924
  var STREAM_PENDING_ITEM_MAX_CHARS = 16384;
925
+ var STREAM_PENDING_COMMIT_RESERVE_ROWS = 5;
926
+ var STREAM_PENDING_COMPOSER_RESERVE_ROWS = 12;
902
927
  var LOADING_THOUGHT_DESCRIPTION_MAX_CHARS = 4096;
903
928
  function showCitations(settings) {
904
929
  const enabled = settings?.merged?.ui?.showCitations;
@@ -915,7 +940,19 @@ function clampLoadingThoughtDescription(description) {
915
940
  return description.slice(0, LOADING_THOUGHT_DESCRIPTION_MAX_CHARS);
916
941
  }
917
942
  __name(clampLoadingThoughtDescription, "clampLoadingThoughtDescription");
918
- var useGeminiStream = /* @__PURE__ */ __name((geminiClient, history, addItem, config, isConfigInitialized, settings, onDebugMessage, handleSlashCommand, shellModeActive, getPreferredEditor, onAuthError, performMemoryRefresh, modelSwitchedFromQuotaError, setModelSwitchedFromQuotaError, onEditorClose, onCancelSubmit, setShellInputFocused, terminalWidth, terminalHeight, midTurnDrainRef, logger) => {
943
+ function charIndexAfterLine(text, keptLines) {
944
+ if (keptLines <= 0) return -1;
945
+ let count = 0;
946
+ for (let i = 0; i < text.length; i++) {
947
+ if (text[i] === "\n") {
948
+ count++;
949
+ if (count === keptLines) return i + 1;
950
+ }
951
+ }
952
+ return -1;
953
+ }
954
+ __name(charIndexAfterLine, "charIndexAfterLine");
955
+ var useGeminiStream = /* @__PURE__ */ __name((geminiClient, history, addItem, config, isConfigInitialized, settings, onDebugMessage, handleSlashCommand, shellModeActive, getPreferredEditor, onAuthError, performMemoryRefresh, modelSwitchedFromQuotaError, setModelSwitchedFromQuotaError, onEditorClose, onCancelSubmit, setShellInputFocused, terminalWidth, terminalHeight, midTurnDrainRef, logger, availableTerminalHeightRef, terminalWidthRef) => {
919
956
  const [initError, setInitError] = (0, import_react5.useState)(null);
920
957
  const abortControllerRef = (0, import_react5.useRef)(null);
921
958
  const flushBufferedStreamEventsRef = (0, import_react5.useRef)(/* @__PURE__ */ new Set());
@@ -1411,6 +1448,54 @@ var useGeminiStream = /* @__PURE__ */ __name((geminiClient, history, addItem, co
1411
1448
  nextPendingType = "gemini_content";
1412
1449
  newGeminiMessageBuffer = afterText;
1413
1450
  }
1451
+ const viewportRows = (availableTerminalHeightRef?.current ?? 0) > 0 ? availableTerminalHeightRef.current : Math.max(4, terminalHeight - STREAM_PENDING_COMPOSER_RESERVE_ROWS);
1452
+ const commitWidth = (terminalWidthRef?.current ?? 0) > 0 ? terminalWidthRef.current : terminalWidth;
1453
+ const commitRowBudget = Math.max(
1454
+ 4,
1455
+ viewportRows - STREAM_PENDING_COMMIT_RESERVE_ROWS
1456
+ );
1457
+ const tableClampRows = Math.max(2, viewportRows - 3);
1458
+ while (true) {
1459
+ const bufferLines = newGeminiMessageBuffer.split("\n");
1460
+ const { keptLines, clipped } = fitPendingSlice(
1461
+ bufferLines,
1462
+ commitWidth,
1463
+ commitRowBudget,
1464
+ tableClampRows
1465
+ );
1466
+ if (!clipped) break;
1467
+ let boundaryLine = -1;
1468
+ for (let k = Math.min(keptLines, bufferLines.length) - 1; k >= 0; k--) {
1469
+ if (bufferLines[k].trim() === "") {
1470
+ boundaryLine = k;
1471
+ break;
1472
+ }
1473
+ }
1474
+ if (boundaryLine < 0) break;
1475
+ const target = charIndexAfterLine(
1476
+ newGeminiMessageBuffer,
1477
+ boundaryLine + 1
1478
+ );
1479
+ if (target <= 0) break;
1480
+ const splitPoint = findLastSafeSplitPoint(
1481
+ newGeminiMessageBuffer,
1482
+ target
1483
+ );
1484
+ if (splitPoint <= 0 || splitPoint >= newGeminiMessageBuffer.length) {
1485
+ break;
1486
+ }
1487
+ const beforeText = newGeminiMessageBuffer.substring(0, splitPoint);
1488
+ const afterText = newGeminiMessageBuffer.substring(splitPoint);
1489
+ commitItem(
1490
+ {
1491
+ type: nextPendingType,
1492
+ text: beforeText
1493
+ },
1494
+ userMessageTimestamp
1495
+ );
1496
+ nextPendingType = "gemini_content";
1497
+ newGeminiMessageBuffer = afterText;
1498
+ }
1414
1499
  setPendingHistoryItem((item) => {
1415
1500
  const base = {
1416
1501
  type: nextPendingType,
@@ -1423,7 +1508,15 @@ var useGeminiStream = /* @__PURE__ */ __name((geminiClient, history, addItem, co
1423
1508
  });
1424
1509
  return newGeminiMessageBuffer;
1425
1510
  },
1426
- [commitItem, pendingHistoryItemRef, setPendingHistoryItem]
1511
+ [
1512
+ commitItem,
1513
+ pendingHistoryItemRef,
1514
+ setPendingHistoryItem,
1515
+ terminalWidth,
1516
+ terminalHeight,
1517
+ availableTerminalHeightRef,
1518
+ terminalWidthRef
1519
+ ]
1427
1520
  );
1428
1521
  const mergeThought = (0, import_react5.useCallback)(
1429
1522
  (incoming) => {
@@ -3,17 +3,17 @@
3
3
  import {
4
4
  getInboxesDir,
5
5
  require_proper_lockfile
6
- } from "./chunk-LKWAVAB5.js";
6
+ } from "./chunk-X2XNQQJI.js";
7
7
  import {
8
8
  Mutex
9
9
  } from "./chunk-OMX7CUOE.js";
10
10
  import {
11
11
  atomicWriteJSON
12
- } from "./chunk-T42ACHFI.js";
12
+ } from "./chunk-7LTB54MK.js";
13
13
  import {
14
14
  createDebugLogger,
15
15
  isNodeError
16
- } from "./chunk-AVQDCKNF.js";
16
+ } from "./chunk-22MNNNXE.js";
17
17
  import {
18
18
  init_esbuild_shims
19
19
  } from "./chunk-A4BMJM77.js";
@@ -2,7 +2,7 @@
2
2
  "use strict";
3
3
  import {
4
4
  parseRule
5
- } from "./chunk-6QTCOQX7.js";
5
+ } from "./chunk-WOG7QWIT.js";
6
6
  import {
7
7
  init_esbuild_shims
8
8
  } from "./chunk-A4BMJM77.js";
@@ -2,7 +2,7 @@
2
2
  "use strict";
3
3
  import {
4
4
  createDebugLogger
5
- } from "./chunk-AVQDCKNF.js";
5
+ } from "./chunk-22MNNNXE.js";
6
6
  import {
7
7
  init_esbuild_shims
8
8
  } from "./chunk-A4BMJM77.js";
@@ -73,6 +73,27 @@ function getHookKey(hook) {
73
73
  }
74
74
  }
75
75
  __name(getHookKey, "getHookKey");
76
+ function isToolArtifactLike(value) {
77
+ if (typeof value !== "object" || value === null) {
78
+ return false;
79
+ }
80
+ const artifact = value;
81
+ return typeof artifact["title"] === "string" && isOptionalString(artifact, "kind") && isOptionalString(artifact, "storage") && isOptionalString(artifact, "description") && isOptionalString(artifact, "workspacePath") && isOptionalString(artifact, "managedId") && isOptionalString(artifact, "url") && isOptionalString(artifact, "mimeType") && (artifact["sizeBytes"] === void 0 || typeof artifact["sizeBytes"] === "number" && Number.isSafeInteger(artifact["sizeBytes"]) && artifact["sizeBytes"] >= 0) && (artifact["metadata"] === void 0 || isToolArtifactMetadataLike(artifact["metadata"]));
82
+ }
83
+ __name(isToolArtifactLike, "isToolArtifactLike");
84
+ function isToolArtifactMetadataLike(value) {
85
+ if (typeof value !== "object" || value === null || Array.isArray(value)) {
86
+ return false;
87
+ }
88
+ return Object.values(value).every(
89
+ (item) => item === null || typeof item === "string" || typeof item === "boolean" || typeof item === "number" && Number.isFinite(item)
90
+ );
91
+ }
92
+ __name(isToolArtifactMetadataLike, "isToolArtifactMetadataLike");
93
+ function isOptionalString(value, key) {
94
+ return value[key] === void 0 || typeof value[key] === "string";
95
+ }
96
+ __name(isOptionalString, "isOptionalString");
76
97
  var MAX_USER_PROMPT_EXPANSION_ADDITIONAL_CONTEXT_LENGTH = 1e4;
77
98
  function sanitizeUserPromptExpansionAdditionalContext(raw) {
78
99
  return raw.replace(/&/g, "&amp;").replace(/</g, "&lt;").replace(/>/g, "&gt;").slice(0, MAX_USER_PROMPT_EXPANSION_ADDITIONAL_CONTEXT_LENGTH).replace(/&(?:a(?:mp?)?|lt?|gt?)?$/, "");
@@ -157,6 +178,13 @@ var DefaultHookOutput = class {
157
178
  }
158
179
  return void 0;
159
180
  }
181
+ getArtifacts() {
182
+ const artifacts = this.hookSpecificOutput?.["artifacts"];
183
+ if (!Array.isArray(artifacts)) {
184
+ return [];
185
+ }
186
+ return artifacts.filter(isToolArtifactLike);
187
+ }
160
188
  /**
161
189
  * Check if execution should be blocked and return error info
162
190
  */
@@ -434,6 +462,7 @@ export {
434
462
  HOOKS_CONFIG_FIELDS,
435
463
  HookType,
436
464
  getHookKey,
465
+ isToolArtifactLike,
437
466
  MAX_USER_PROMPT_EXPANSION_ADDITIONAL_CONTEXT_LENGTH,
438
467
  sanitizeUserPromptExpansionAdditionalContext,
439
468
  createHookOutput,
@@ -5,10 +5,10 @@ import {
5
5
  } from "./chunk-Y6Z2O3WR.js";
6
6
  import {
7
7
  resolveBundleDir
8
- } from "./chunk-6QTCOQX7.js";
8
+ } from "./chunk-WOG7QWIT.js";
9
9
  import {
10
10
  Storage
11
- } from "./chunk-AVQDCKNF.js";
11
+ } from "./chunk-22MNNNXE.js";
12
12
  import {
13
13
  init_esbuild_shims
14
14
  } from "./chunk-A4BMJM77.js";
@@ -160,13 +160,13 @@ init_esbuild_shims();
160
160
  var globImport_locales_js = __glob({
161
161
  "./locales/ca.js": () => import("./ca-HCMB2I54.js"),
162
162
  "./locales/de.js": () => import("./de-PLLFDERI.js"),
163
- "./locales/en.js": () => import("./en-M4EBUBNU.js"),
163
+ "./locales/en.js": () => import("./en-AXARKOWO.js"),
164
164
  "./locales/fr.js": () => import("./fr-MBMNQSQ6.js"),
165
165
  "./locales/ja.js": () => import("./ja-HFV5QCHR.js"),
166
166
  "./locales/pt.js": () => import("./pt-2THT3YHA.js"),
167
167
  "./locales/ru.js": () => import("./ru-Z67YJHBG.js"),
168
- "./locales/zh-TW.js": () => import("./zh-TW-P53C2SL5.js"),
169
- "./locales/zh.js": () => import("./zh-SLZNSSZB.js")
168
+ "./locales/zh-TW.js": () => import("./zh-TW-L5GRQ4S4.js"),
169
+ "./locales/zh.js": () => import("./zh-RS3HZHFH.js")
170
170
  });
171
171
 
172
172
  // packages/cli/src/i18n/index.ts