@hostclubeos/miraos 0.0.1-beta → 0.0.5-beta

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 (417) hide show
  1. package/bundled/app-store-compliance/SKILL.md +58 -0
  2. package/bundled/bug-hunter/NOTICE +17 -0
  3. package/bundled/bug-hunter/SKILL.md +65 -0
  4. package/bundled/superpowers/NOTICE +11 -0
  5. package/bundled/superpowers/SKILL.md +43 -0
  6. package/bundled/superpowers/references/brainstorming/SKILL.md +316 -0
  7. package/bundled/superpowers/references/brainstorming/builder-check-prompt.md +23 -0
  8. package/bundled/superpowers/references/brainstorming/scripts/frame-template.html +213 -0
  9. package/bundled/superpowers/references/brainstorming/scripts/helper.js +167 -0
  10. package/bundled/superpowers/references/brainstorming/scripts/server.cjs +723 -0
  11. package/bundled/superpowers/references/brainstorming/scripts/start-server.sh +216 -0
  12. package/bundled/superpowers/references/brainstorming/scripts/stop-server.sh +120 -0
  13. package/bundled/superpowers/references/brainstorming/visual-companion.md +299 -0
  14. package/bundled/superpowers/references/diagnosing-superpowers/SKILL.md +120 -0
  15. package/bundled/superpowers/references/diagnosing-superpowers/prompts/analyst-common.md +38 -0
  16. package/bundled/superpowers/references/diagnosing-superpowers/prompts/cost-and-time.md +28 -0
  17. package/bundled/superpowers/references/diagnosing-superpowers/prompts/plan-adherence.md +29 -0
  18. package/bundled/superpowers/references/diagnosing-superpowers/prompts/quality-evidence.md +26 -0
  19. package/bundled/superpowers/references/diagnosing-superpowers/prompts/repeated-work.md +30 -0
  20. package/bundled/superpowers/references/diagnosing-superpowers/prompts/request-conflicts.md +20 -0
  21. package/bundled/superpowers/references/diagnosing-superpowers/prompts/scrub-audit.md +33 -0
  22. package/bundled/superpowers/references/diagnosing-superpowers/prompts/scrub.md +29 -0
  23. package/bundled/superpowers/references/diagnosing-superpowers/prompts/similar-session.md +38 -0
  24. package/bundled/superpowers/references/diagnosing-superpowers/prompts/skill-timeline.md +30 -0
  25. package/bundled/superpowers/references/diagnosing-superpowers/prompts/stumbles.md +28 -0
  26. package/bundled/superpowers/references/diagnosing-superpowers/references/context-safety.md +22 -0
  27. package/bundled/superpowers/references/diagnosing-superpowers/references/github-issues.md +47 -0
  28. package/bundled/superpowers/references/diagnosing-superpowers/references/redaction-policy.md +34 -0
  29. package/bundled/superpowers/references/diagnosing-superpowers/references/session-discovery.md +31 -0
  30. package/bundled/superpowers/references/diagnosing-superpowers/templates/bundle-README.md +77 -0
  31. package/bundled/superpowers/references/diagnosing-superpowers/templates/case.md +64 -0
  32. package/bundled/superpowers/references/diagnosing-superpowers/templates/issue.md +70 -0
  33. package/bundled/superpowers/references/diagnosing-superpowers/templates/report.md +82 -0
  34. package/bundled/superpowers/references/dispatching-parallel-agents/SKILL.md +167 -0
  35. package/bundled/superpowers/references/executing-plans/SKILL.md +323 -0
  36. package/bundled/superpowers/references/executing-plans/scripts/task-done +55 -0
  37. package/bundled/superpowers/references/executing-plans/scripts/task-start +32 -0
  38. package/bundled/superpowers/references/finishing-a-development-branch/SKILL.md +225 -0
  39. package/bundled/superpowers/references/receiving-code-review/SKILL.md +205 -0
  40. package/bundled/superpowers/references/requesting-code-review/SKILL.md +95 -0
  41. package/bundled/superpowers/references/requesting-code-review/code-reviewer.md +198 -0
  42. package/bundled/superpowers/references/subagent-driven-development/SKILL.md +339 -0
  43. package/bundled/superpowers/references/subagent-driven-development/implementer-prompt.md +154 -0
  44. package/bundled/superpowers/references/subagent-driven-development/re-review-prompt.md +116 -0
  45. package/bundled/superpowers/references/subagent-driven-development/references/batching.md +11 -0
  46. package/bundled/superpowers/references/subagent-driven-development/references/cannot-verify.md +10 -0
  47. package/bundled/superpowers/references/subagent-driven-development/references/final-review.md +49 -0
  48. package/bundled/superpowers/references/subagent-driven-development/references/fix-loop.md +77 -0
  49. package/bundled/superpowers/references/subagent-driven-development/references/handling-reports.md +15 -0
  50. package/bundled/superpowers/references/subagent-driven-development/references/preflight.md +26 -0
  51. package/bundled/superpowers/references/subagent-driven-development/references/resuming.md +12 -0
  52. package/bundled/superpowers/references/subagent-driven-development/scripts/review-package +64 -0
  53. package/bundled/superpowers/references/subagent-driven-development/scripts/sdd-repo +54 -0
  54. package/bundled/superpowers/references/subagent-driven-development/scripts/sdd-workspace +110 -0
  55. package/bundled/superpowers/references/subagent-driven-development/scripts/task-brief +108 -0
  56. package/bundled/superpowers/references/subagent-driven-development/task-reviewer-prompt.md +209 -0
  57. package/bundled/superpowers/references/systematic-debugging/SKILL.md +283 -0
  58. package/bundled/superpowers/references/systematic-debugging/condition-based-waiting-example.ts +159 -0
  59. package/bundled/superpowers/references/systematic-debugging/condition-based-waiting.md +115 -0
  60. package/bundled/superpowers/references/systematic-debugging/defense-in-depth.md +122 -0
  61. package/bundled/superpowers/references/systematic-debugging/find-polluter.sh +72 -0
  62. package/bundled/superpowers/references/systematic-debugging/root-cause-tracing.md +169 -0
  63. package/bundled/superpowers/references/test-driven-development/SKILL.md +330 -0
  64. package/bundled/superpowers/references/test-driven-development/writing-good-tests.md +198 -0
  65. package/bundled/superpowers/references/using-git-worktrees/SKILL.md +167 -0
  66. package/bundled/superpowers/references/using-superpowers/SKILL.md +65 -0
  67. package/bundled/superpowers/references/using-superpowers/references/antigravity-tools.md +23 -0
  68. package/bundled/superpowers/references/using-superpowers/references/claude-code-tools.md +29 -0
  69. package/bundled/superpowers/references/using-superpowers/references/codex-tools.md +108 -0
  70. package/bundled/superpowers/references/using-superpowers/references/gemini-tools.md +63 -0
  71. package/bundled/superpowers/references/using-superpowers/references/hermes-tools.md +56 -0
  72. package/bundled/superpowers/references/using-superpowers/references/muse-tools.md +35 -0
  73. package/bundled/superpowers/references/using-superpowers/references/pi-tools.md +16 -0
  74. package/bundled/superpowers/references/verification-before-completion/SKILL.md +120 -0
  75. package/bundled/superpowers/references/writing-plans/SKILL.md +204 -0
  76. package/bundled/superpowers/references/writing-skills/SKILL.md +399 -0
  77. package/bundled/superpowers/references/writing-skills/references/CLAUDE_MD_TESTING.md +189 -0
  78. package/bundled/superpowers/references/writing-skills/references/anthropic-best-practices.md +1150 -0
  79. package/bundled/superpowers/references/writing-skills/references/bulletproofing.md +80 -0
  80. package/bundled/superpowers/references/writing-skills/references/discovery.md +201 -0
  81. package/bundled/superpowers/references/writing-skills/references/flowcharts.md +37 -0
  82. package/bundled/superpowers/references/writing-skills/references/graphviz-conventions.dot +172 -0
  83. package/bundled/superpowers/references/writing-skills/references/persuasion-principles.md +187 -0
  84. package/bundled/superpowers/references/writing-skills/references/testing-skills-with-subagents.md +384 -0
  85. package/bundled/superpowers/references/writing-skills/render-graphs.js +169 -0
  86. package/bundled/swarm/SKILL.md +47 -0
  87. package/chunks/{MaxSizedBox-4XZJGJCR.js → MaxSizedBox-CBUPHLMW.js} +1 -1
  88. package/chunks/{StandaloneSessionPicker-YUWFI6WT.js → StandaloneSessionPicker-EXZJQKTK.js} +1 -1
  89. package/chunks/{acp-subagent-executor-7BGJRBWA.js → acp-subagent-executor-BMIXP52W.js} +1 -1
  90. package/chunks/{acpAgent-DO3DYSKS.js → acpAgent-UHWDA3W7.js} +3 -3
  91. package/chunks/{advisor-ZMSGPCRF.js → advisor-5RUG3VFZ.js} +1 -1
  92. package/chunks/{agent-ZMZLTEBG.js → agent-SGQ7AEZI.js} +1 -1
  93. package/chunks/{agent-headless-5COOZKMA.js → agent-headless-ZGCZ2DA7.js} +1 -1
  94. package/chunks/{agent-host-client-L2ROWXVT.js → agent-host-client-HY5GPSHM.js} +1 -1
  95. package/chunks/{agent-host-connections-A4UGANXV.js → agent-host-connections-KGTBS37X.js} +1 -1
  96. package/chunks/{autofix-pr-N3M7IGHT.js → autofix-pr-E62FC67X.js} +1 -1
  97. package/chunks/{autofix-pr-VWZPABZQ.js → autofix-pr-TRI4NMYI.js} +1 -1
  98. package/chunks/{batch-RTO7FWGG.js → batch-OUC6FGCQ.js} +1 -1
  99. package/chunks/{bridge-ZZ2GF4DM.js → bridge-FLEIBB5V.js} +1 -1
  100. package/chunks/{bwrap-execution-6NIUP47A.js → bwrap-execution-VLHJWP4O.js} +1 -1
  101. package/chunks/{channel-settings-store-Y5HXLPQF.js → channel-settings-store-QG6HREVH.js} +1 -1
  102. package/chunks/{chunk-FXFSZ7QF.js → chunk-23543L6E.js} +1 -1
  103. package/chunks/{chunk-NM5TUAPJ.js → chunk-2GVKPBW5.js} +1 -1
  104. package/chunks/{chunk-DPKN7TSL.js → chunk-2QYFSBJY.js} +1 -1
  105. package/chunks/{chunk-NMB6IBA7.js → chunk-2TDRP3IX.js} +1 -1
  106. package/chunks/{chunk-ZE5YXIAJ.js → chunk-2VW4HXVF.js} +1 -1
  107. package/chunks/{chunk-FQXNP7EE.js → chunk-2ZWVSKPK.js} +1 -1
  108. package/chunks/{chunk-SBFKWNC3.js → chunk-3GJ56V2J.js} +1 -1
  109. package/chunks/{chunk-7JU5ZJJ7.js → chunk-3KFLO5W3.js} +1 -1
  110. package/chunks/{chunk-P4ZCOMZS.js → chunk-3MBYQYPC.js} +1 -1
  111. package/chunks/{chunk-FHGGT7VE.js → chunk-4346FNTB.js} +1 -1
  112. package/chunks/{chunk-IKQHFQ74.js → chunk-4GNHXVJZ.js} +1 -1
  113. package/chunks/{chunk-2FD2BYUZ.js → chunk-4IVYVCCU.js} +3 -3
  114. package/chunks/{chunk-ZEIWENJU.js → chunk-4KIFAVR2.js} +1 -1
  115. package/chunks/{chunk-YSWDQYJU.js → chunk-4MGTY3CJ.js} +1 -1
  116. package/chunks/{chunk-3LS3HVJA.js → chunk-4WYKHP7Q.js} +1 -1
  117. package/chunks/{chunk-MWGGXT4P.js → chunk-56PVVXUG.js} +1 -1
  118. package/chunks/{chunk-J4KLD52D.js → chunk-62DMHXLL.js} +1 -1
  119. package/chunks/{chunk-TALEJQWF.js → chunk-66DZADDA.js} +1 -1
  120. package/chunks/{chunk-GOEBFMO2.js → chunk-6RDYPRV6.js} +1 -1
  121. package/chunks/{chunk-5HNCGRMZ.js → chunk-724YPZRX.js} +1 -1
  122. package/chunks/{chunk-HA6K73R7.js → chunk-744QTJR2.js} +2 -2
  123. package/chunks/{chunk-SCQWVHLA.js → chunk-7F5IYTVE.js} +1 -1
  124. package/chunks/{chunk-TDM5PKRC.js → chunk-7VP4KALB.js} +1 -1
  125. package/chunks/{chunk-QWOBTVIO.js → chunk-7W5DOBKY.js} +1 -1
  126. package/chunks/{chunk-UL5A63VS.js → chunk-AE6E2YKY.js} +1 -1
  127. package/chunks/{chunk-J2DA7XAM.js → chunk-AIAYQAPA.js} +1 -1
  128. package/chunks/{chunk-3XFUS57Z.js → chunk-AIGBQN6R.js} +1 -1
  129. package/chunks/{chunk-BVYNPYGP.js → chunk-AJ75BPTA.js} +6 -1
  130. package/chunks/{chunk-LEZ3AZJI.js → chunk-ATVRF62A.js} +1 -1
  131. package/chunks/{chunk-DW4HTZVZ.js → chunk-BX3KM7OK.js} +1 -1
  132. package/chunks/{chunk-4UVQYN33.js → chunk-CUY6CVSL.js} +1 -1
  133. package/chunks/{chunk-RRXNG7AI.js → chunk-D3QZNIFB.js} +6 -6
  134. package/chunks/{chunk-5PZ4EFXH.js → chunk-D3YOXHQF.js} +1 -1
  135. package/chunks/{chunk-L66KXTVG.js → chunk-DABLVQXV.js} +1 -1
  136. package/chunks/{chunk-6AA5DYMC.js → chunk-DMM5LJWL.js} +2 -2
  137. package/chunks/{chunk-TWCQNRBQ.js → chunk-DNYXZVBT.js} +1 -1
  138. package/chunks/{chunk-HCIFQTQ4.js → chunk-E6LRCLLE.js} +2 -2
  139. package/chunks/{chunk-L44CUCID.js → chunk-EF3HUB7S.js} +1 -1
  140. package/chunks/{chunk-WQEJL3HN.js → chunk-EW3EVEYN.js} +1 -1
  141. package/chunks/{chunk-RMATGKAM.js → chunk-FC7SJIAS.js} +1 -1
  142. package/chunks/{chunk-4NQCOITC.js → chunk-FK5L2WVV.js} +1 -1
  143. package/chunks/{chunk-EMRZ722U.js → chunk-FRADUGRC.js} +1 -1
  144. package/chunks/{chunk-T2O3JMRH.js → chunk-FS67DOZQ.js} +1 -1
  145. package/chunks/{chunk-27MEJGPT.js → chunk-FXANOHXI.js} +5 -5
  146. package/chunks/{chunk-VCLKQDTV.js → chunk-GLQWA4W2.js} +1 -1
  147. package/chunks/{chunk-STPD3MIX.js → chunk-GOZ5FAUV.js} +1 -1
  148. package/chunks/{chunk-POX6TDCX.js → chunk-GTQULDIL.js} +1 -1
  149. package/chunks/{chunk-SR6MFJYO.js → chunk-GY4ID3EB.js} +1 -1
  150. package/chunks/{chunk-IJDGB3GP.js → chunk-H65ZVST6.js} +1 -1
  151. package/chunks/{chunk-6MWOHNU7.js → chunk-HASJX2YS.js} +1 -1
  152. package/chunks/{chunk-TJVI2L24.js → chunk-HSN5QUS7.js} +1 -1
  153. package/chunks/{chunk-7A42KF7G.js → chunk-HZ4L4MDM.js} +1 -1
  154. package/chunks/{chunk-WXVU3W2Q.js → chunk-IC42HQCH.js} +1 -1
  155. package/chunks/{chunk-NSA4ZO4V.js → chunk-IF3SWUYT.js} +1 -1
  156. package/chunks/{chunk-AGVUBA2V.js → chunk-J773THNP.js} +1 -1
  157. package/chunks/{chunk-ETYFIFMT.js → chunk-JDHMSERR.js} +1 -1
  158. package/chunks/{chunk-GNJTCOX3.js → chunk-JIQVUYBI.js} +1 -1
  159. package/chunks/{chunk-F5LMCQ2K.js → chunk-JJDF5FHA.js} +1 -1
  160. package/chunks/{chunk-TSI3G7JM.js → chunk-JQOLNQQN.js} +1 -1
  161. package/chunks/{chunk-ERUWCPGL.js → chunk-JQYPRANX.js} +1 -1
  162. package/chunks/{chunk-IW5GJAOR.js → chunk-K7KY7FIB.js} +1 -1
  163. package/chunks/{chunk-P2CUOX2Q.js → chunk-K7VOBDFT.js} +1 -1
  164. package/chunks/{chunk-SNGI5OD7.js → chunk-KK6SQPYG.js} +1 -1
  165. package/chunks/{chunk-HVAOQB42.js → chunk-KNW2OD46.js} +1 -1
  166. package/chunks/{chunk-GQSVGUOU.js → chunk-KP77CL5U.js} +1 -1
  167. package/chunks/{chunk-G6EIN5FW.js → chunk-KYK53GFP.js} +1 -1
  168. package/chunks/{chunk-432LPP2J.js → chunk-MQWKOOSR.js} +1 -1
  169. package/chunks/{chunk-XMIUDKGO.js → chunk-MUS4ADP7.js} +2 -2
  170. package/chunks/{chunk-IVHSWYWP.js → chunk-MYS5NQXO.js} +1 -1
  171. package/chunks/{chunk-FCOVJQX7.js → chunk-N4RIISOE.js} +1 -1
  172. package/chunks/{chunk-FCB7X7TI.js → chunk-NCBA52SB.js} +1 -1
  173. package/chunks/{chunk-GNV3UOVR.js → chunk-NGH27AWP.js} +1 -1
  174. package/chunks/{chunk-YM7CPT6W.js → chunk-NKWATWMD.js} +2 -2
  175. package/chunks/{chunk-R4HUU27E.js → chunk-NVD63O5H.js} +1 -1
  176. package/chunks/{chunk-WNT3ND65.js → chunk-NYM67KKZ.js} +2 -2
  177. package/chunks/{chunk-F6MHDBMX.js → chunk-O6Z3KO6R.js} +1 -1
  178. package/chunks/{chunk-RPMW55YH.js → chunk-OV2J3OED.js} +1 -1
  179. package/chunks/{chunk-RGOWOT3Z.js → chunk-P42MFWO2.js} +1 -1
  180. package/chunks/{chunk-XREDCQA5.js → chunk-P5543CFV.js} +1 -1
  181. package/chunks/{chunk-RHFRL6CB.js → chunk-PFECH6U6.js} +1 -1
  182. package/chunks/{chunk-3SQ76U4F.js → chunk-PFKTTUGS.js} +6 -6
  183. package/chunks/{chunk-XU5D2FKZ.js → chunk-PGKFDR73.js} +1 -1
  184. package/chunks/{chunk-LTUKVA3O.js → chunk-PQOQONLN.js} +1 -1
  185. package/chunks/{chunk-E7PL6EYK.js → chunk-PVHBBTAU.js} +1 -1
  186. package/chunks/{chunk-SKLO2WHR.js → chunk-PXBJPUGN.js} +1 -1
  187. package/chunks/{chunk-BCY6VYWQ.js → chunk-QEIX42MZ.js} +1 -1
  188. package/chunks/{chunk-MEUP65FI.js → chunk-QTCO5I4C.js} +1 -1
  189. package/chunks/{chunk-3KM4JL4Y.js → chunk-RBA3TP7L.js} +1 -1
  190. package/chunks/{chunk-R3H2AN4X.js → chunk-RKFNQQNA.js} +1 -1
  191. package/chunks/{chunk-RBYRJBQV.js → chunk-RNPVWQ3V.js} +1 -1
  192. package/chunks/{chunk-G7KBHT53.js → chunk-RRMTSVGU.js} +1 -1
  193. package/chunks/{chunk-W5YMSMZG.js → chunk-RWFOQXPU.js} +1 -1
  194. package/chunks/{chunk-R32F7IAM.js → chunk-SCHCTQCG.js} +1 -1
  195. package/chunks/{chunk-MC47YWMG.js → chunk-SHKSVOTG.js} +1 -1
  196. package/chunks/{chunk-YPG2SMZS.js → chunk-SK3QOQR4.js} +1 -1
  197. package/chunks/{chunk-5SFSOCHV.js → chunk-T3A53XMM.js} +1 -1
  198. package/chunks/{chunk-3SCCBDDE.js → chunk-T5PDEAU5.js} +1 -1
  199. package/chunks/{chunk-PIHZPQYO.js → chunk-T5XGTSQU.js} +1 -1
  200. package/chunks/{chunk-J4SZAKAX.js → chunk-TFITRCIC.js} +1 -1
  201. package/chunks/{chunk-THO23XWK.js → chunk-TLZM3DMY.js} +1 -1
  202. package/chunks/{chunk-Y6PDX4C4.js → chunk-TU5QHOJC.js} +1 -1
  203. package/chunks/{chunk-FFE5LIA6.js → chunk-TWJ4XBED.js} +1 -1
  204. package/chunks/{chunk-K6I2EP3G.js → chunk-UNJYVYTC.js} +1 -1
  205. package/chunks/{chunk-KSWZ6FTA.js → chunk-UOYXBAN7.js} +1 -1
  206. package/chunks/{chunk-GGXMABF2.js → chunk-USR2Y7B3.js} +1 -1
  207. package/chunks/{chunk-6O6IED5M.js → chunk-UWMLSAQY.js} +1 -1
  208. package/chunks/{chunk-OGPOUNG7.js → chunk-V5Z6OEKJ.js} +1 -1
  209. package/chunks/{chunk-MWMYT4PK.js → chunk-VBJV7T47.js} +1 -1
  210. package/chunks/{chunk-BAHNLZJQ.js → chunk-VF2UWWI2.js} +1 -1
  211. package/chunks/{chunk-MVF4MYTY.js → chunk-VJUTDS6C.js} +1 -1
  212. package/chunks/{chunk-A42T2FGM.js → chunk-W2ZVZ6LS.js} +1 -1
  213. package/chunks/{chunk-V6ZOOFZ3.js → chunk-W6IOHGWW.js} +1 -1
  214. package/chunks/{chunk-I5FHTXDB.js → chunk-WC72OWF2.js} +2 -2
  215. package/chunks/{chunk-XW5ZOTPK.js → chunk-WJLHLFIR.js} +1 -1
  216. package/chunks/{chunk-T4P4FF3I.js → chunk-WZTO3EYG.js} +1 -1
  217. package/chunks/{chunk-IUUWYEF5.js → chunk-XZNF4YNN.js} +1 -1
  218. package/chunks/{chunk-N7OJZ7AS.js → chunk-YN6WXB6B.js} +1 -1
  219. package/chunks/{chunk-PJUXHD2F.js → chunk-YVN32EUM.js} +1 -1
  220. package/chunks/{chunk-B7XMOQLO.js → chunk-Z4JY3HGO.js} +1 -1
  221. package/chunks/{chunk-AIIV662S.js → chunk-ZOWMHZWO.js} +1 -1
  222. package/chunks/{codex-subagent-executor-AR4Q5IHV.js → codex-subagent-executor-UCDGQFTR.js} +1 -1
  223. package/chunks/{config-utils-5S5PZQ5S.js → config-utils-Z6F4DVLG.js} +1 -1
  224. package/chunks/{contextCommand-YEZP3P4L.js → contextCommand-HMVZT56Y.js} +1 -1
  225. package/chunks/{core-runtime-LISS3YR4.js → core-runtime-AV7CJXOL.js} +1 -1
  226. package/chunks/{create-sub-session-FCB4YENT.js → create-sub-session-NNKVHZKT.js} +1 -1
  227. package/chunks/{cron-create-E2PZGYSL.js → cron-create-HWZDFVPA.js} +1 -1
  228. package/chunks/{daemon-git-worktree-guard-23KFZWC5.js → daemon-git-worktree-guard-Q3C45X7T.js} +1 -1
  229. package/chunks/{daemon-status-provider-KU7B5BBQ.js → daemon-status-provider-F6KB2LNG.js} +1 -1
  230. package/chunks/{daemon-trust-policy-FL3DDA6T.js → daemon-trust-policy-6D4KJANB.js} +1 -1
  231. package/chunks/{daemon-trust-policy-monitor-FCCK3YHW.js → daemon-trust-policy-monitor-BZ46W4IA.js} +1 -1
  232. package/chunks/{deferred-core-runtime-BCJU6YQI.js → deferred-core-runtime-YC5XIWEI.js} +1 -1
  233. package/chunks/{display-image-ZHNLZCK7.js → display-image-LAGHQ4RY.js} +1 -1
  234. package/chunks/{edit-SXQ5HK4W.js → edit-LOWDEKPX.js} +1 -1
  235. package/chunks/{enterPlanMode-NX6SOALP.js → enterPlanMode-NGSATDRH.js} +1 -1
  236. package/chunks/{environment-GFCR2C43.js → environment-CVIB5DW4.js} +1 -1
  237. package/chunks/{errors-WZJPHSEP.js → errors-USKSVZFO.js} +1 -1
  238. package/chunks/{execute-sandbox-VZ4OKFCC.js → execute-sandbox-KNRRYQ52.js} +1 -1
  239. package/chunks/{execution-sandbox-config-XQNSHI7G.js → execution-sandbox-config-XBW3PXDA.js} +1 -1
  240. package/chunks/{execution-tool-XPHUDQJ4.js → execution-tool-QSJLRU5N.js} +1 -1
  241. package/chunks/{execution-worker-6RXFIQH4.js → execution-worker-TQEIC4AJ.js} +1 -1
  242. package/chunks/{exitPlanMode-LP3D7M5M.js → exitPlanMode-AW2HOTIK.js} +1 -1
  243. package/chunks/{fast-path-2D5QZRQW.js → fast-path-DWPD5EGQ.js} +1 -1
  244. package/chunks/{glob-JFH2DTI7.js → glob-7U6FQSWZ.js} +1 -1
  245. package/chunks/{goal-tools-UL3O364Y.js → goal-tools-5ZB6GPCJ.js} +1 -1
  246. package/chunks/{handleAutoUpdate-MYD2LZXQ.js → handleAutoUpdate-MLUFTWFP.js} +1 -1
  247. package/chunks/{i18n-LDINZEX3.js → i18n-QAPQLOC3.js} +1 -1
  248. package/chunks/{initializer-LLXI4EVO.js → initializer-B27IZ7K4.js} +1 -1
  249. package/chunks/{installationInfo-4FS5ROEO.js → installationInfo-SAMHABWV.js} +1 -1
  250. package/chunks/{interactive-mod-session-UFB2CURW.js → interactive-mod-session-7LQ5CYUR.js} +1 -1
  251. package/chunks/{landlock-execution-3T5Y3SFY.js → landlock-execution-2BJ56FDV.js} +1 -1
  252. package/chunks/{list-45PFXWOV.js → list-TDMJQDQO.js} +1 -1
  253. package/chunks/{llm-VIFUT34L.js → llm-RBI7KXDE.js} +4 -4
  254. package/chunks/{loadedSettingsAdapter-3MNB7PHB.js → loadedSettingsAdapter-ZQK5KMEW.js} +1 -1
  255. package/chunks/{local-TBDN3BOU.js → local-HSG47CNJ.js} +1 -1
  256. package/chunks/{local-execution-environment-PNRU2WTJ.js → local-execution-environment-WJVCE26F.js} +1 -1
  257. package/chunks/{loggingContentGenerator-JA22TIC4.js → loggingContentGenerator-ALSG42YA.js} +1 -1
  258. package/chunks/{loop-wakeup-BXKFVB7H.js → loop-wakeup-LFU4LDJM.js} +1 -1
  259. package/chunks/{manage-memory-BMKA64KG.js → manage-memory-FBL6CHX2.js} +1 -1
  260. package/chunks/{managed-execution-engine-PVXRANOE.js → managed-execution-engine-FX7FDAWW.js} +1 -1
  261. package/chunks/{managed-local-serve-H5BEBXVR.js → managed-local-serve-YE4JDFNP.js} +1 -1
  262. package/chunks/{managed-npm-update-JGC5W6SL.js → managed-npm-update-2MKV7UOI.js} +1 -1
  263. package/chunks/{managed-runtime-attestation-worker-KCUQIRVR.js → managed-runtime-attestation-worker-DBAHM5MN.js} +1 -1
  264. package/chunks/{managed-runtime-bootstrap-HCN3NINM.js → managed-runtime-bootstrap-SHEXUEZN.js} +1 -1
  265. package/chunks/{managed-runtime-session-worker-G4TB3S5M.js → managed-runtime-session-worker-YN4KML7A.js} +1 -1
  266. package/chunks/{managed-runtime-ssh-worker-4WSWY2MH.js → managed-runtime-ssh-worker-BZNJV7IB.js} +1 -1
  267. package/chunks/{managed-session-authority-H5USCQ6W.js → managed-session-authority-MFEINLXC.js} +1 -1
  268. package/chunks/{mcp-WXNSQID6.js → mcp-TS5PX5FY.js} +1 -1
  269. package/chunks/{memory-E5SQH3NJ.js → memory-JTDN5AEA.js} +1 -1
  270. package/chunks/{model-call-collection-PULBNXXQ.js → model-call-collection-TNBMD3YL.js} +1 -1
  271. package/chunks/{model-configuration-SJEIOQGZ.js → model-configuration-6KTQQTMO.js} +1 -1
  272. package/chunks/{modelConfigUtils-WJ27GPGB.js → modelConfigUtils-LCZZ3EQU.js} +1 -1
  273. package/chunks/{monitor-N25QQU7J.js → monitor-KCCNIKLE.js} +1 -1
  274. package/chunks/{nonInteractiveCli-E6RLP7AG.js → nonInteractiveCli-BXHX6EIU.js} +1 -1
  275. package/chunks/{nonInteractiveToolExecutor-Z5JBEIAW.js → nonInteractiveToolExecutor-R5CTTWKD.js} +1 -1
  276. package/chunks/{notebook-edit-WVLO2EUN.js → notebook-edit-KIWE2XOA.js} +1 -1
  277. package/chunks/{omni-RKVYBBQI.js → omni-IFTMWBMU.js} +1 -1
  278. package/chunks/{openaiContentGenerator-2G2XB3DF.js → openaiContentGenerator-XP3VPU6C.js} +1 -1
  279. package/chunks/{openaiResponsesContentGenerator-344BTMHF.js → openaiResponsesContentGenerator-ZJ6C22EA.js} +1 -1
  280. package/chunks/{pidfile-KS6QFQIJ.js → pidfile-42P24JIA.js} +1 -1
  281. package/chunks/{processUtils-U45GFMXN.js → processUtils-I2XOO5U2.js} +1 -1
  282. package/chunks/{prompt-terminal-ledger-HAK6RGOC.js → prompt-terminal-ledger-7EW46VQ4.js} +1 -1
  283. package/chunks/{reactive-degrade-S7C6GXHH.js → reactive-degrade-O4JO7MOX.js} +1 -1
  284. package/chunks/{read-file-RG5ZNNCH.js → read-file-VGC4O7F2.js} +1 -1
  285. package/chunks/{record-source-6J47E2DW.js → record-source-VX26ZO6I.js} +1 -1
  286. package/chunks/{request-shutdown-SCU5TN5V.js → request-shutdown-P7227UEF.js} +1 -1
  287. package/chunks/{resumeHistoryUtils-CDDEU4RO.js → resumeHistoryUtils-QMVIHQRW.js} +1 -1
  288. package/chunks/{review-H6FLIVJV.js → review-PC4IDLCG.js} +1 -1
  289. package/chunks/{ripGrep-XEDOYGPA.js → ripGrep-JY4PZABK.js} +1 -1
  290. package/chunks/{run-qwen-serve-ODBFOM6H.js → run-qwen-serve-XRWVWOZK.js} +1 -1
  291. package/chunks/{runtime-SCINDTK2.js → runtime-OL7B72CH.js} +1 -1
  292. package/chunks/{runtime-shell-policy-77EFLSNG.js → runtime-shell-policy-TXAWAOBK.js} +1 -1
  293. package/chunks/{sandboxConfig-WE7GXTES.js → sandboxConfig-EJTMWZHD.js} +1 -1
  294. package/chunks/{scheduled-tasks-4HL6GKQ4.js → scheduled-tasks-XQSZWZXG.js} +1 -1
  295. package/chunks/{scheduler-ETHKOB4B.js → scheduler-3TIRZEVB.js} +1 -1
  296. package/chunks/{search-memory-R4O5AIEV.js → search-memory-P5KOTUVV.js} +1 -1
  297. package/chunks/{send-message-SBQSBXDW.js → send-message-KFSKFXLX.js} +1 -1
  298. package/chunks/{serve-TRAGNNK6.js → serve-JCUT4WK7.js} +1 -1
  299. package/chunks/{server-BXVHT3XW.js → server-HMTRZJF7.js} +3 -3
  300. package/chunks/{session-A6NV4RLU.js → session-RGLZU6KY.js} +1 -1
  301. package/chunks/{session-attachments-root-WU56VFQN.js → session-attachments-root-O3YQ7HWD.js} +1 -1
  302. package/chunks/{session-execution-engine-selector-MG2ZDK25.js → session-execution-engine-selector-LZBHS3UO.js} +1 -1
  303. package/chunks/{session-pr-refresh-HQOHASVU.js → session-pr-refresh-L5Z5WCXS.js} +1 -1
  304. package/chunks/{sessionService-XBFZRVW6.js → sessionService-MMPZUN5X.js} +1 -1
  305. package/chunks/{settings-HDG72SDU.js → settings-7PYHXPN4.js} +1 -1
  306. package/chunks/{shell-VNVPTXQO.js → shell-E6QLKRVU.js} +1 -1
  307. package/chunks/{skill-4VDNIMOV.js → skill-55IZUUM5.js} +1 -1
  308. package/chunks/{skill-settings-VKC2ATCK.js → skill-settings-A2M5BPH7.js} +1 -1
  309. package/chunks/{spawnChannel-RB5Q6Z4U.js → spawnChannel-KWU26CB7.js} +1 -1
  310. package/chunks/{standalone-update-QDH63IIS.js → standalone-update-32WYZ3BJ.js} +1 -1
  311. package/chunks/{start-opentui-ui-VULNQJ3L.js → start-opentui-ui-YNTPK7LX.js} +2 -2
  312. package/chunks/{startInteractiveUI-XZATGHLR.js → startInteractiveUI-MWA2VYTJ.js} +2 -2
  313. package/chunks/{task-create-ODLLJ5EF.js → task-create-67YBESBR.js} +1 -1
  314. package/chunks/{task-update-ZNWF5QPF.js → task-update-DLBXOE5R.js} +1 -1
  315. package/chunks/{team-create-CUJXJ2ZS.js → team-create-ARICYIQB.js} +1 -1
  316. package/chunks/{team-plan-approval-36LS5SZD.js → team-plan-approval-JPRE6Q3R.js} +1 -1
  317. package/chunks/{terminal-image-renderer-FYGH5GYJ.js → terminal-image-renderer-HVIZ2VNE.js} +1 -1
  318. package/chunks/{theme-manager-AMNU6BMN.js → theme-manager-UEPLIBUP.js} +1 -1
  319. package/chunks/{tool-call-E635LKSC.js → tool-call-EFJKXI3Z.js} +1 -1
  320. package/chunks/{tool-result-media-USCQTGHC.js → tool-result-media-LMIYNXSD.js} +1 -1
  321. package/chunks/{tool-search-FNTAT2ZW.js → tool-search-D7HQTRQG.js} +1 -1
  322. package/chunks/{total-session-admission-6P5YNVII.js → total-session-admission-67QMR44O.js} +1 -1
  323. package/chunks/{trustedFolders-7SPIYZSS.js → trustedFolders-HARYVS3F.js} +1 -1
  324. package/chunks/{update-relaunch-ZYID7ZKA.js → update-relaunch-NVNPOK5J.js} +1 -1
  325. package/chunks/{updateCheck-A3JUVWQV.js → updateCheck-7NMXUCTN.js} +1 -1
  326. package/chunks/{upload-config-DT3IQPC7.js → upload-config-W2SICJ32.js} +1 -1
  327. package/chunks/{useAutoAcceptIndicator-OS64SJOW.js → useAutoAcceptIndicator-ELMIP4TJ.js} +1 -1
  328. package/chunks/{validateNonInterActiveAuth-SJLXPGT4.js → validateNonInterActiveAuth-3433WFLE.js} +1 -1
  329. package/chunks/{version-CD2O2AJ7.js → version-XCFKTEY3.js} +1 -1
  330. package/chunks/{web-fetch-CQZMLBDV.js → web-fetch-537RS6IX.js} +1 -1
  331. package/chunks/{web-search-47YZU3PO.js → web-search-O27MYFSW.js} +1 -1
  332. package/chunks/{workflow-ROHRWGL5.js → workflow-6QF4RMYM.js} +1 -1
  333. package/chunks/{workflow-ancestor-trust-YSFNC6J5.js → workflow-ancestor-trust-CABLU3VV.js} +1 -1
  334. package/chunks/{workspace-agents-P4T5564B.js → workspace-agents-5WP3PY7W.js} +1 -1
  335. package/chunks/{workspace-providers-status-GZOJR5XX.js → workspace-providers-status-7G2EJJEO.js} +1 -1
  336. package/chunks/{workspace-recovery-worker-C4KTT7J5.js → workspace-recovery-worker-ICCIDEWU.js} +1 -1
  337. package/chunks/{workspace-registration-store-2WDVL42M.js → workspace-registration-store-WHXMNQQQ.js} +1 -1
  338. package/chunks/{workspace-registry-2V2LYFXO.js → workspace-registry-NXBODLYH.js} +1 -1
  339. package/chunks/{workspace-runtime-coordinator-7OH4M6FV.js → workspace-runtime-coordinator-CJXS273B.js} +1 -1
  340. package/chunks/{workspace-service-353F3S2A.js → workspace-service-HUDE2RXN.js} +1 -1
  341. package/chunks/{workspace-skills-status-A5FRCJJF.js → workspace-skills-status-FJC6U62F.js} +1 -1
  342. package/chunks/{workspace-trust-reconciler-N4AKVBD4.js → workspace-trust-reconciler-ZIQ3A5ZB.js} +1 -1
  343. package/chunks/{write-file-XOIVQYGC.js → write-file-652YGG7I.js} +1 -1
  344. package/chunks/{zoom-image-ACTDUJ4C.js → zoom-image-YEH4O74G.js} +1 -1
  345. package/cli.js +2 -2
  346. package/execution-worker.js +1 -1
  347. package/export-transcript-document.js +1 -1
  348. package/package.json +2 -2
  349. package/web-shell/assets/{PierreFilePreview-DR46bTX6.js → PierreFilePreview-DEhWK46v.js} +1 -1
  350. package/web-shell/assets/{SpreadsheetPreview-zgxr-aKy.js → SpreadsheetPreview-C-GgIuPX.js} +1 -1
  351. package/web-shell/assets/{WorkspaceFileBrowser-BEoibHvP.js → WorkspaceFileBrowser-64vDYikf.js} +1 -1
  352. package/web-shell/assets/{abnfDiagram-VCTEODGH-Cba-rfLM.js → abnfDiagram-VCTEODGH-C2WWURam.js} +1 -1
  353. package/web-shell/assets/{agents-route-DexLhLcH.js → agents-route-j5ba59xn.js} +1 -1
  354. package/web-shell/assets/{arc-BLxikpdy.js → arc-Bkr_-GVn.js} +1 -1
  355. package/web-shell/assets/{architectureDiagram-5GKGNRK7-BMaIAoGQ.js → architectureDiagram-5GKGNRK7-D_v_wDDW.js} +1 -1
  356. package/web-shell/assets/{blockDiagram-NRAW4CY4-CGSbuIDn.js → blockDiagram-NRAW4CY4-Csxc3YNo.js} +1 -1
  357. package/web-shell/assets/{c4Diagram-UCG6FXSJ-DVwZ8MO2.js → c4Diagram-UCG6FXSJ-PXryoJCB.js} +1 -1
  358. package/web-shell/assets/channel-6Pj4KPAs.js +1 -0
  359. package/web-shell/assets/{chunk-2Q5K7J3B-BzKDWtZ3.js → chunk-2Q5K7J3B-DwK5UBHI.js} +1 -1
  360. package/web-shell/assets/{chunk-5VM5RSS4-C8SFBHFV.js → chunk-5VM5RSS4-BC1hvD6_.js} +1 -1
  361. package/web-shell/assets/{chunk-F27PBJKO-D8brpDvU.js → chunk-F27PBJKO-iFe0IxfJ.js} +1 -1
  362. package/web-shell/assets/{chunk-G27WJ6UU-Cilx_eO_.js → chunk-G27WJ6UU-ROSuKRxI.js} +1 -1
  363. package/web-shell/assets/{chunk-JWPE2WC7-CeplW23S.js → chunk-JWPE2WC7-CYHS6PxA.js} +1 -1
  364. package/web-shell/assets/{chunk-LCL6LL3I-BUO5XSSe.js → chunk-LCL6LL3I-D5bFMqCy.js} +1 -1
  365. package/web-shell/assets/{chunk-POPQ4Y6H-DPo869nv.js → chunk-POPQ4Y6H-BJh77MGv.js} +1 -1
  366. package/web-shell/assets/{chunk-SVP7TREG-DhfIj0Jt.js → chunk-SVP7TREG-Cs81aYft.js} +1 -1
  367. package/web-shell/assets/{chunk-XXDRQBXY-B72Tsbdi.js → chunk-XXDRQBXY-DqDbN44E.js} +1 -1
  368. package/web-shell/assets/classDiagram-DTDB5LWJ-BaTUuuB8.js +1 -0
  369. package/web-shell/assets/classDiagram-v2-JRS7N3AN-BaTUuuB8.js +1 -0
  370. package/web-shell/assets/{cose-bilkent-JH36ORCC-8EANR5K4.js → cose-bilkent-JH36ORCC-DhjrwADJ.js} +1 -1
  371. package/web-shell/assets/{cynefin-OW5HDTMX-Cj3uoFr9.js → cynefin-OW5HDTMX-Dh7t-_3M.js} +1 -1
  372. package/web-shell/assets/{cynefinDiagram-5FMLGOSQ-CHwRYcv9.js → cynefinDiagram-5FMLGOSQ-5J4kto0C.js} +1 -1
  373. package/web-shell/assets/{dagre-3AP2YEHR-B50MDk4E.js → dagre-3AP2YEHR-28AdbIcl.js} +1 -1
  374. package/web-shell/assets/{diagram-S7CK7UJ4-Fbk8W4Ks.js → diagram-S7CK7UJ4-DmksuoIf.js} +1 -1
  375. package/web-shell/assets/{diagram-UQ7AKVKN-CNeEtpni.js → diagram-UQ7AKVKN-DUjgQ8Fg.js} +1 -1
  376. package/web-shell/assets/{diagram-VSXAHHWV-CYXiWI4p.js → diagram-VSXAHHWV-DUe_FpG-.js} +1 -1
  377. package/web-shell/assets/{diagram-VX7I27RA-CF7R7hGA.js → diagram-VX7I27RA-CJJ70teK.js} +1 -1
  378. package/web-shell/assets/{diagram-Z3DM3KII-DZzHpEub.js → diagram-Z3DM3KII-BgABlJO4.js} +1 -1
  379. package/web-shell/assets/{docx-preview-CjpeB47y.js → docx-preview-BMBWboRx.js} +1 -1
  380. package/web-shell/assets/{ebnfDiagram-PWID7BFC-CtH0z2j9.js → ebnfDiagram-PWID7BFC-B3nK_Lh7.js} +1 -1
  381. package/web-shell/assets/{erDiagram-SSCWMZ5O-D51BQ445.js → erDiagram-SSCWMZ5O-DCTdCWlu.js} +1 -1
  382. package/web-shell/assets/{flowDiagram-A5DVABFB-B1-3lJwP.js → flowDiagram-A5DVABFB-CPxk2UUl.js} +1 -1
  383. package/web-shell/assets/{ganttDiagram-EL5Y4UJY-iMw3jNW5.js → ganttDiagram-EL5Y4UJY-WZzMAKht.js} +1 -1
  384. package/web-shell/assets/{gitGraphDiagram-WWUBYQGX-D_KI4JVS.js → gitGraphDiagram-WWUBYQGX-DKcO5ugU.js} +1 -1
  385. package/web-shell/assets/{index-D1oIEFvH.js → index-CkRLMu1y.js} +6 -6
  386. package/web-shell/assets/{index-iouf3mnZ.js → index-Dbm3-Fps.js} +1 -1
  387. package/web-shell/assets/{infoDiagram-RXCK75RN-CwG9MQQq.js → infoDiagram-RXCK75RN-CJX5DzdL.js} +1 -1
  388. package/web-shell/assets/{ishikawaDiagram-5VMMS53U-C99w6R-O.js → ishikawaDiagram-5VMMS53U-fF0Id5B6.js} +1 -1
  389. package/web-shell/assets/{journeyDiagram-EYS64GPL--T5XVhJh.js → journeyDiagram-EYS64GPL-BOAezBVe.js} +1 -1
  390. package/web-shell/assets/{kanban-definition-3QL26DDD-Cs-rGYgZ.js → kanban-definition-3QL26DDD-DdNBof9J.js} +1 -1
  391. package/web-shell/assets/{layout-BHU2s0xS.js → layout-CXX3l5w0.js} +1 -1
  392. package/web-shell/assets/{linear-DbLtsa7_.js → linear-Dnaccp-S.js} +1 -1
  393. package/web-shell/assets/{mermaid.core-CTBkTEXb.js → mermaid.core-BzdC3B6T.js} +6 -6
  394. package/web-shell/assets/{mindmap-definition-FBJOCRG2-RWLGqkYd.js → mindmap-definition-FBJOCRG2-D-gMUzLw.js} +1 -1
  395. package/web-shell/assets/{pegDiagram-XKGWAZYB-DIQRWxNr.js → pegDiagram-XKGWAZYB-B9n1WVZq.js} +1 -1
  396. package/web-shell/assets/{pieDiagram-E7YTZNPT-Dg9VHqU0.js → pieDiagram-E7YTZNPT-ok49U0zT.js} +1 -1
  397. package/web-shell/assets/{quadrantDiagram-AXDQQJYC-BFeuB7Iq.js → quadrantDiagram-AXDQQJYC-DJKha-v3.js} +1 -1
  398. package/web-shell/assets/{railroadDiagram-O6MQD6OU-DbO9AYto.js → railroadDiagram-O6MQD6OU-DjL4pl7y.js} +1 -1
  399. package/web-shell/assets/{requirementDiagram-EFPCY7ZU-ClpOYbUE.js → requirementDiagram-EFPCY7ZU-BpmmRw3A.js} +1 -1
  400. package/web-shell/assets/{sankeyDiagram-P5KCCOFB-CaHmNc0O.js → sankeyDiagram-P5KCCOFB-KpteHB8X.js} +1 -1
  401. package/web-shell/assets/{sequenceDiagram-WJ2MYXX4-4r32bqWv.js → sequenceDiagram-WJ2MYXX4-COMghCpA.js} +1 -1
  402. package/web-shell/assets/{sizeCapture-X5ZJPWSS-CGXqc7rW.js → sizeCapture-X5ZJPWSS-5fEwJD-n.js} +1 -1
  403. package/web-shell/assets/{stateDiagram-HBIQ2CUA-DuAO60my.js → stateDiagram-HBIQ2CUA-CnC7oXvs.js} +1 -1
  404. package/web-shell/assets/stateDiagram-v2-4QOOHH4V-V_cfZFBL.js +1 -0
  405. package/web-shell/assets/{swimlanes-XN3QIQJK-DUQMHZRn.js → swimlanes-XN3QIQJK-bVlhZdve.js} +1 -1
  406. package/web-shell/assets/swimlanesDiagram-VK2B7HYN-25wVg0WL.js +8 -0
  407. package/web-shell/assets/{timeline-definition-24CTP7MA-DNCSPOxv.js → timeline-definition-24CTP7MA-CBvYgMu5.js} +1 -1
  408. package/web-shell/assets/{vennDiagram-4TSXK5OY-Bxh1Z0T6.js → vennDiagram-4TSXK5OY-CUTYvV1j.js} +1 -1
  409. package/web-shell/assets/{wardleyDiagram-VM6X3IG4-D6fuN1bA.js → wardleyDiagram-VM6X3IG4-Djl4gxCB.js} +1 -1
  410. package/web-shell/assets/{xychartDiagram-S5SC5T6Z-DkwTa8kZ.js → xychartDiagram-S5SC5T6Z-BcJZtI2X.js} +1 -1
  411. package/web-shell/index.html +1 -1
  412. package/web-shell/sw.js +1 -1
  413. package/web-shell/assets/channel-CvkbH6SO.js +0 -1
  414. package/web-shell/assets/classDiagram-DTDB5LWJ-DuyseBqE.js +0 -1
  415. package/web-shell/assets/classDiagram-v2-JRS7N3AN-DuyseBqE.js +0 -1
  416. package/web-shell/assets/stateDiagram-v2-4QOOHH4V-BjIYif-p.js +0 -1
  417. package/web-shell/assets/swimlanesDiagram-VK2B7HYN-DZB3DqrF.js +0 -8
@@ -1,6 +1,6 @@
1
1
  // Force strict mode and setup for ESM
2
2
  "use strict";
3
- import{validateSessionSourceInput}from"./chunk-G5PYYZMM.js";import{isSubagentLikeExecutionContext}from"./chunk-GNJTCOX3.js";import{BaseDeclarativeTool,BaseToolInvocation}from"./chunk-D6CEQ2GY.js";import{ToolDisplayNames,ToolNames}from"./chunk-SBZFGYYS.js";import{init_esbuild_shims}from"./chunk-VKDAXTCZ.js";import{__name}from"./chunk-KBWJGX7I.js";init_esbuild_shims();var RecordSourceInvocation=class extends BaseToolInvocation{constructor(params,config){super(params);this.config=config}static{__name(this,"RecordSourceInvocation")}getDescription(){return`Add reference: ${this.params.title}`}async execute(){try{if(isSubagentLikeExecutionContext()){throw new Error("Only the top-level session can register sources")}const service=this.config.getSessionSourceService();if(!service)throw new Error("Session source service unavailable");if(this.params.locator.type==="attachment")throw new Error("The tool accepts only workspace files and URLs");const{source}=await service.upsert(this.params);const message=`Reference added: ${source.id}`;return{llmContent:message,returnDisplay:message}}catch(error){const message=error instanceof Error?error.message:"Source registration failed";return{llmContent:message,returnDisplay:message,error:{message,type:"execution_failed"}}}}};var RecordSourceTool=class _RecordSourceTool extends BaseDeclarativeTool{constructor(config){super(_RecordSourceTool.Name,ToolDisplayNames.RECORD_SOURCE,"Adds a file or HTTP(S) link to this session reference list. Registration stores metadata only: it does not read or send resource contents, and does not prove the assistant used the reference. Use record_artifact for newly produced deliverables.","other",{type:"object",additionalProperties:false,required:["title","locator"],properties:{title:{type:"string",maxLength:200},description:{type:"string",maxLength:1e3},locator:{oneOf:[{type:"object",additionalProperties:false,required:["type","workspacePath"],properties:{type:{type:"string",const:"workspace_file"},workspacePath:{type:"string",maxLength:500}}},{type:"object",additionalProperties:false,required:["type","url"],properties:{type:{type:"string",const:"url"},url:{type:"string",maxLength:2048}}}]}}},true,false,true,false,"source reference file link");this.config=config}static{__name(this,"RecordSourceTool")}static Name=ToolNames.RECORD_SOURCE;validateToolParamValues(params){try{const input=validateSessionSourceInput(params);return input.locator.type==="attachment"?"The tool accepts only workspace files and URLs":null}catch(error){return error instanceof Error?error.message:"Invalid source"}}createInvocation(params){return new RecordSourceInvocation(params,this.config)}};export{RecordSourceTool};
3
+ import{validateSessionSourceInput}from"./chunk-G5PYYZMM.js";import{isSubagentLikeExecutionContext}from"./chunk-JIQVUYBI.js";import{BaseDeclarativeTool,BaseToolInvocation}from"./chunk-D6CEQ2GY.js";import{ToolDisplayNames,ToolNames}from"./chunk-SBZFGYYS.js";import{init_esbuild_shims}from"./chunk-VKDAXTCZ.js";import{__name}from"./chunk-KBWJGX7I.js";init_esbuild_shims();var RecordSourceInvocation=class extends BaseToolInvocation{constructor(params,config){super(params);this.config=config}static{__name(this,"RecordSourceInvocation")}getDescription(){return`Add reference: ${this.params.title}`}async execute(){try{if(isSubagentLikeExecutionContext()){throw new Error("Only the top-level session can register sources")}const service=this.config.getSessionSourceService();if(!service)throw new Error("Session source service unavailable");if(this.params.locator.type==="attachment")throw new Error("The tool accepts only workspace files and URLs");const{source}=await service.upsert(this.params);const message=`Reference added: ${source.id}`;return{llmContent:message,returnDisplay:message}}catch(error){const message=error instanceof Error?error.message:"Source registration failed";return{llmContent:message,returnDisplay:message,error:{message,type:"execution_failed"}}}}};var RecordSourceTool=class _RecordSourceTool extends BaseDeclarativeTool{constructor(config){super(_RecordSourceTool.Name,ToolDisplayNames.RECORD_SOURCE,"Adds a file or HTTP(S) link to this session reference list. Registration stores metadata only: it does not read or send resource contents, and does not prove the assistant used the reference. Use record_artifact for newly produced deliverables.","other",{type:"object",additionalProperties:false,required:["title","locator"],properties:{title:{type:"string",maxLength:200},description:{type:"string",maxLength:1e3},locator:{oneOf:[{type:"object",additionalProperties:false,required:["type","workspacePath"],properties:{type:{type:"string",const:"workspace_file"},workspacePath:{type:"string",maxLength:500}}},{type:"object",additionalProperties:false,required:["type","url"],properties:{type:{type:"string",const:"url"},url:{type:"string",maxLength:2048}}}]}}},true,false,true,false,"source reference file link");this.config=config}static{__name(this,"RecordSourceTool")}static Name=ToolNames.RECORD_SOURCE;validateToolParamValues(params){try{const input=validateSessionSourceInput(params);return input.locator.type==="attachment"?"The tool accepts only workspace files and URLs":null}catch(error){return error instanceof Error?error.message:"Invalid source"}}createInvocation(params){return new RecordSourceInvocation(params,this.config)}};export{RecordSourceTool};
4
4
  /**
5
5
  * @license
6
6
  * Copyright 2026 Qwen Team
@@ -1,6 +1,6 @@
1
1
  // Force strict mode and setup for ESM
2
2
  "use strict";
3
- import{LoadedSettings,getNestedProperty,getPersistScopeForModelSelection}from"./chunk-FXFSZ7QF.js";import{getHomeEnvFallbackVars}from"./chunk-3KM4JL4Y.js";import{writeWithBackupSync}from"./chunk-T4P4FF3I.js";import{preserveModelProviderPlaceholders}from"./chunk-P4ZCOMZS.js";import{resolveEnvVarsInObject}from"./chunk-HW7ZRPZU.js";import{init_esbuild_shims}from"./chunk-VKDAXTCZ.js";import{__name}from"./chunk-KBWJGX7I.js";init_esbuild_shims();import*as fs from"node:fs";function findRawModelProviderEntries(settings,providerId){return["System",...settings.isTrusted?["Workspace"]:[],"User","SystemDefaults"].map(source=>settings.forScope(source).originalSettings.modelProviders).find(providers=>providers&&Object.hasOwn(providers,providerId))?.[providerId]}__name(findRawModelProviderEntries,"findRawModelProviderEntries");function getRawModelProviders(settings){return Object.fromEntries(Object.keys(settings.merged.modelProviders??{}).map(providerId=>[providerId,findRawModelProviderEntries(settings,providerId)??[]]))}__name(getRawModelProviders,"getRawModelProviders");function createLoadedSettingsAdapter(settings,scope){const persistScope=scope??getPersistScopeForModelSelection(settings);const settingsFile=settings.forScope(persistScope);let fileSnapshot;let settingsSnapshot=null;let originalSnapshot=null;return{getValue(key){return getNestedProperty(settings.merged,key)},setValue(key,value){for(const part of key.split(".")){if(part==="__proto__"||part==="constructor"||part==="prototype"){throw new Error(`Refusing to write settings key with reserved segment: ${key}`)}}const provider=key.startsWith("modelProviders.")&&key.split(".").length===2?key.slice("modelProviders.".length):void 0;if(!provider||!Array.isArray(value)){settings.setValue(persistScope,key,value);return}const sourceFor=__name(providerId=>findRawModelProviderEntries(settings,providerId),"sourceFor");const ownsBucket=Object.hasOwn(settingsFile.settings.modelProviders??{},provider);const previous=ownsBucket?settingsFile.settings.modelProviders?.[provider]:settings.merged.modelProviders?.[provider];const raw=ownsBucket?settingsFile.originalSettings.modelProviders?.[provider]:sourceFor(provider);const resolvedProviders=provider==="openai"?settings.merged.modelProviders??{}:{[provider]:previous??[]};const rawProviders=provider==="openai"?Object.fromEntries(Object.keys(resolvedProviders).map(id=>[id,sourceFor(id)??[]])):{[provider]:raw??[]};const persisted=preserveModelProviderPlaceholders(value,provider,resolvedProviders,rawProviders,settings.merged.providerProtocol);settings.setValue(persistScope,key,persisted);settingsFile.settings.modelProviders=resolveEnvVarsInObject(settingsFile.originalSettings.modelProviders,getHomeEnvFallbackVars());settings.recomputeMerged()},getModelProviders(){return settings.merged.modelProviders??{}},getModelProvidersForWrite(){const ownProviders=settingsFile.settings.modelProviders??{};const writeView=persistScope==="User"?new LoadedSettings(settings.system,settings.systemDefaults,settings.user,{...settings.workspace,settings:{},originalSettings:{}},false,new Set).merged:settings.merged;return{modelProviders:ownProviders,providerProtocol:writeView.providerProtocol,shadowedProviders:Object.keys(ownProviders).filter(providerId=>["System",...settings.isTrusted?["Workspace"]:[],"User","SystemDefaults"].find(scope2=>Object.hasOwn(settings.forScope(scope2).originalSettings.modelProviders??{},providerId))!==persistScope)}},persist(){},backup(){const contents=fs.existsSync(settingsFile.path)?fs.readFileSync(settingsFile.path,"utf8"):null;settingsSnapshot=structuredClone(settingsFile.settings);originalSnapshot=structuredClone(settingsFile.originalSettings);fileSnapshot=contents},restore(){if(fileSnapshot===void 0)return;try{if(fileSnapshot===null){fs.rmSync(settingsFile.path,{force:true})}else{writeWithBackupSync(settingsFile.path,fileSnapshot)}}finally{if(settingsSnapshot!==null){settingsFile.settings=settingsSnapshot}if(originalSnapshot!==null){settingsFile.originalSettings=originalSnapshot}settings.recomputeMerged()}},cleanupBackup(){fileSnapshot=void 0;settingsSnapshot=null;originalSnapshot=null}}}__name(createLoadedSettingsAdapter,"createLoadedSettingsAdapter");export{findRawModelProviderEntries,getRawModelProviders,createLoadedSettingsAdapter};
3
+ import{LoadedSettings,getNestedProperty,getPersistScopeForModelSelection}from"./chunk-23543L6E.js";import{getHomeEnvFallbackVars}from"./chunk-RBA3TP7L.js";import{writeWithBackupSync}from"./chunk-WZTO3EYG.js";import{preserveModelProviderPlaceholders}from"./chunk-3MBYQYPC.js";import{resolveEnvVarsInObject}from"./chunk-HW7ZRPZU.js";import{init_esbuild_shims}from"./chunk-VKDAXTCZ.js";import{__name}from"./chunk-KBWJGX7I.js";init_esbuild_shims();import*as fs from"node:fs";function findRawModelProviderEntries(settings,providerId){return["System",...settings.isTrusted?["Workspace"]:[],"User","SystemDefaults"].map(source=>settings.forScope(source).originalSettings.modelProviders).find(providers=>providers&&Object.hasOwn(providers,providerId))?.[providerId]}__name(findRawModelProviderEntries,"findRawModelProviderEntries");function getRawModelProviders(settings){return Object.fromEntries(Object.keys(settings.merged.modelProviders??{}).map(providerId=>[providerId,findRawModelProviderEntries(settings,providerId)??[]]))}__name(getRawModelProviders,"getRawModelProviders");function createLoadedSettingsAdapter(settings,scope){const persistScope=scope??getPersistScopeForModelSelection(settings);const settingsFile=settings.forScope(persistScope);let fileSnapshot;let settingsSnapshot=null;let originalSnapshot=null;return{getValue(key){return getNestedProperty(settings.merged,key)},setValue(key,value){for(const part of key.split(".")){if(part==="__proto__"||part==="constructor"||part==="prototype"){throw new Error(`Refusing to write settings key with reserved segment: ${key}`)}}const provider=key.startsWith("modelProviders.")&&key.split(".").length===2?key.slice("modelProviders.".length):void 0;if(!provider||!Array.isArray(value)){settings.setValue(persistScope,key,value);return}const sourceFor=__name(providerId=>findRawModelProviderEntries(settings,providerId),"sourceFor");const ownsBucket=Object.hasOwn(settingsFile.settings.modelProviders??{},provider);const previous=ownsBucket?settingsFile.settings.modelProviders?.[provider]:settings.merged.modelProviders?.[provider];const raw=ownsBucket?settingsFile.originalSettings.modelProviders?.[provider]:sourceFor(provider);const resolvedProviders=provider==="openai"?settings.merged.modelProviders??{}:{[provider]:previous??[]};const rawProviders=provider==="openai"?Object.fromEntries(Object.keys(resolvedProviders).map(id=>[id,sourceFor(id)??[]])):{[provider]:raw??[]};const persisted=preserveModelProviderPlaceholders(value,provider,resolvedProviders,rawProviders,settings.merged.providerProtocol);settings.setValue(persistScope,key,persisted);settingsFile.settings.modelProviders=resolveEnvVarsInObject(settingsFile.originalSettings.modelProviders,getHomeEnvFallbackVars());settings.recomputeMerged()},getModelProviders(){return settings.merged.modelProviders??{}},getModelProvidersForWrite(){const ownProviders=settingsFile.settings.modelProviders??{};const writeView=persistScope==="User"?new LoadedSettings(settings.system,settings.systemDefaults,settings.user,{...settings.workspace,settings:{},originalSettings:{}},false,new Set).merged:settings.merged;return{modelProviders:ownProviders,providerProtocol:writeView.providerProtocol,shadowedProviders:Object.keys(ownProviders).filter(providerId=>["System",...settings.isTrusted?["Workspace"]:[],"User","SystemDefaults"].find(scope2=>Object.hasOwn(settings.forScope(scope2).originalSettings.modelProviders??{},providerId))!==persistScope)}},persist(){},backup(){const contents=fs.existsSync(settingsFile.path)?fs.readFileSync(settingsFile.path,"utf8"):null;settingsSnapshot=structuredClone(settingsFile.settings);originalSnapshot=structuredClone(settingsFile.originalSettings);fileSnapshot=contents},restore(){if(fileSnapshot===void 0)return;try{if(fileSnapshot===null){fs.rmSync(settingsFile.path,{force:true})}else{writeWithBackupSync(settingsFile.path,fileSnapshot)}}finally{if(settingsSnapshot!==null){settingsFile.settings=settingsSnapshot}if(originalSnapshot!==null){settingsFile.originalSettings=originalSnapshot}settings.recomputeMerged()}},cleanupBackup(){fileSnapshot=void 0;settingsSnapshot=null;originalSnapshot=null}}}__name(createLoadedSettingsAdapter,"createLoadedSettingsAdapter");export{findRawModelProviderEntries,getRawModelProviders,createLoadedSettingsAdapter};
4
4
  /**
5
5
  * @license
6
6
  * Copyright 2025 Qwen Team
@@ -1,6 +1,6 @@
1
1
  // Force strict mode and setup for ESM
2
2
  "use strict";
3
- import{registerCleanup}from"./chunk-RHFRL6CB.js";import{init_esbuild_shims}from"./chunk-VKDAXTCZ.js";import{__name}from"./chunk-KBWJGX7I.js";init_esbuild_shims();import*as fs from"node:fs";import*as os from"node:os";import*as path from"node:path";var MAX_PROFILES=5;var RATE_LIMIT_MS=3e4;var MIN_FREE_BYTES_AFTER_WRITE=256*1024*1024;var DEFAULT_SAMPLING_INTERVAL_US=1e3;var ESTIMATED_PROFILE_BYTES=10*1024*1024;var state="idle";var session=null;var initialized=false;var signalHandlerRegistered=false;var lastWriteByDir=new Map;function initCpuProfiler(){if(initialized)return;initialized=true;registerSignalHandler();registerCleanup(async()=>{if(state==="recording"){const result=await stopCpuProfile();if(result.ok){process.stderr.write(`[cpu-profiler] Profile written: ${result.filePath}
3
+ import{registerCleanup}from"./chunk-PFECH6U6.js";import{init_esbuild_shims}from"./chunk-VKDAXTCZ.js";import{__name}from"./chunk-KBWJGX7I.js";init_esbuild_shims();import*as fs from"node:fs";import*as os from"node:os";import*as path from"node:path";var MAX_PROFILES=5;var RATE_LIMIT_MS=3e4;var MIN_FREE_BYTES_AFTER_WRITE=256*1024*1024;var DEFAULT_SAMPLING_INTERVAL_US=1e3;var ESTIMATED_PROFILE_BYTES=10*1024*1024;var state="idle";var session=null;var initialized=false;var signalHandlerRegistered=false;var lastWriteByDir=new Map;function initCpuProfiler(){if(initialized)return;initialized=true;registerSignalHandler();registerCleanup(async()=>{if(state==="recording"){const result=await stopCpuProfile();if(result.ok){process.stderr.write(`[cpu-profiler] Profile written: ${result.filePath}
4
4
  `)}}});const enabled=process.env["QWEN_CODE_CPU_PROFILE"]==="1";if(!enabled)return;void startCpuProfile().then(result=>{if(!result.ok){process.stderr.write(`[cpu-profiler] Failed to start: ${result.error}
5
5
  `)}})}__name(initCpuProfiler,"initCpuProfiler");async function startCpuProfile(opts){if(state!=="idle"){return{ok:false,error:state==="recording"?"CPU profiling is already in progress.":"CPU profiler is currently stopping. Please wait a moment and try again."}}state="recording";try{const inspectorSession=await getOrCreateSession();await inspectorSession.post("Profiler.enable");await inspectorSession.post("Profiler.setSamplingInterval",{interval:opts?.samplingInterval??DEFAULT_SAMPLING_INTERVAL_US});await inspectorSession.post("Profiler.start");return{ok:true}}catch(error){state="idle";disconnectSession();return{ok:false,error:formatError(error)}}}__name(startCpuProfile,"startCpuProfile");async function stopCpuProfile(options){if(state!=="recording"){return{ok:false,error:state==="idle"?"CPU profiler is not recording.":"CPU profiler is already stopping."}}const outputDir=options?.outputDir??defaultOutputDir();const now=options?.now??new Date;const rateLimitMs=options?.rateLimitMs??RATE_LIMIT_MS;const maxProfiles=options?.maxProfiles??MAX_PROFILES;try{enforceRateLimit(outputDir,now,rateLimitMs)}catch(error){state="idle";if(session){session.post("Profiler.stop").catch(()=>{});session.post("Profiler.disable").catch(()=>{})}disconnectSession();return{ok:false,error:formatError(error)}}state="stopping";try{if(!session){throw new Error("Inspector session lost unexpectedly during Profiler.stop; the profile data could not be retrieved.")}const result=await session.post("Profiler.stop");if(!result.profile){throw new Error("V8 Profiler.stop returned an empty profile; recording may have been interrupted.")}await session.post("Profiler.disable");fs.mkdirSync(outputDir,{recursive:true,mode:448});try{fs.chmodSync(outputDir,448)}catch{}checkDiskSpace(outputDir);const filePath=path.join(outputDir,`qwen-code-cpu-${process.pid}-${formatTimestamp(now)}.cpuprofile`);try{fs.writeFileSync(filePath,JSON.stringify(result.profile),{mode:384})}catch(writeError){try{fs.rmSync(filePath,{force:true})}catch{}throw writeError}recordWrite(outputDir,now);cleanupOldProfiles(outputDir,maxProfiles);state="idle";return{ok:true,filePath}}catch(error){state="idle";disconnectSession();return{ok:false,error:formatError(error)}}}__name(stopCpuProfile,"stopCpuProfile");function isCpuProfileRecording(){return state==="recording"}__name(isCpuProfileRecording,"isCpuProfileRecording");function registerSignalHandler(){if(signalHandlerRegistered)return;if(process.platform==="win32")return;signalHandlerRegistered=true;process.on("SIGUSR1",handleSigusr1)}__name(registerSignalHandler,"registerSignalHandler");function defaultOutputDir(){return path.join(os.homedir(),".qwen","cpu-profiles")}__name(defaultOutputDir,"defaultOutputDir");function formatTimestamp(now){return now.toISOString().replace(/[:.]/g,"-")}__name(formatTimestamp,"formatTimestamp");function formatError(error){return error instanceof Error?error.message:String(error)}__name(formatError,"formatError");var sessionFactory=null;async function getOrCreateSession(){if(session)return session;if(sessionFactory){session=await sessionFactory();return session}const inspectorModule=await import("node:inspector/promises");const newSession=new inspectorModule.Session;newSession.connect();session=newSession;return session}__name(getOrCreateSession,"getOrCreateSession");function disconnectSession(){if(session){try{session.disconnect()}catch{}session=null}}__name(disconnectSession,"disconnectSession");function handleSigusr1(){if(state==="idle"){void startCpuProfile().then(result=>{if(result.ok){process.stderr.write(`[cpu-profiler] Recording started (PID ${process.pid}). Send SIGUSR1 again to stop.
6
6
  `)}else{process.stderr.write(`[cpu-profiler] Failed to start: ${result.error}
@@ -1,6 +1,6 @@
1
1
  // Force strict mode and setup for ESM
2
2
  "use strict";
3
- import{OUTPUT_LANGUAGE_TABLE}from"./chunk-3SQ76U4F.js";import{init_esbuild_shims}from"./chunk-VKDAXTCZ.js";import{__name}from"./chunk-KBWJGX7I.js";init_esbuild_shims();var STRICT_PARITY_CODES=new Set(["zh","zh-TW"]);var SUPPORTED_LANGUAGES=OUTPUT_LANGUAGE_TABLE.map(entry=>({...entry,...STRICT_PARITY_CODES.has(entry.code)?{strictParity:true}:{}}));function normalizeLanguageCandidate(input){return input.trim().replace(/_/g,"-").toLowerCase()}__name(normalizeLanguageCandidate,"normalizeLanguageCandidate");function matchesLocaleToken(candidate,token){return candidate===token||candidate.startsWith(`${token}-`)||candidate.startsWith(`${token}.`)||candidate.startsWith(`${token}@`)}__name(matchesLocaleToken,"matchesLocaleToken");function getMatchedLocaleTokenLength(candidate,language){const code=language.code.toLowerCase();const id=language.id.toLowerCase();if(matchesLocaleToken(candidate,id)){return id.length}if(matchesLocaleToken(candidate,code)){return code.length}return void 0}__name(getMatchedLocaleTokenLength,"getMatchedLocaleTokenLength");function resolveSupportedLanguage(input){const normalized=normalizeLanguageCandidate(input);if(!normalized){return void 0}let bestMatch;for(const language of SUPPORTED_LANGUAGES){if(normalized===language.fullName.toLowerCase()||language.nativeName&&normalized===language.nativeName.toLowerCase()){return language.code}const tokenLength=getMatchedLocaleTokenLength(normalized,language);if(tokenLength!==void 0&&(!bestMatch||tokenLength>bestMatch.tokenLength)){bestMatch={code:language.code,tokenLength}}}return bestMatch?.code}__name(resolveSupportedLanguage,"resolveSupportedLanguage");function getLanguageNameFromLocale(locale){const resolved=resolveSupportedLanguage(locale);const lang=resolved?SUPPORTED_LANGUAGES.find(language=>language.code===resolved):void 0;return lang?.fullName||"English"}__name(getLanguageNameFromLocale,"getLanguageNameFromLocale");function getLanguageSettingsOptions(){return[{value:"auto",label:"Auto (detect from system)"},...SUPPORTED_LANGUAGES.map(l=>({value:l.code,label:l.nativeName?`${l.nativeName} (${l.fullName})`:`${l.fullName} (${l.id})`}))]}__name(getLanguageSettingsOptions,"getLanguageSettingsOptions");function getSupportedLanguageIds(separator="|"){return SUPPORTED_LANGUAGES.map(l=>l.id).join(separator)}__name(getSupportedLanguageIds,"getSupportedLanguageIds");export{SUPPORTED_LANGUAGES,resolveSupportedLanguage,getLanguageNameFromLocale,getLanguageSettingsOptions,getSupportedLanguageIds};
3
+ import{OUTPUT_LANGUAGE_TABLE}from"./chunk-PFKTTUGS.js";import{init_esbuild_shims}from"./chunk-VKDAXTCZ.js";import{__name}from"./chunk-KBWJGX7I.js";init_esbuild_shims();var STRICT_PARITY_CODES=new Set(["zh","zh-TW"]);var SUPPORTED_LANGUAGES=OUTPUT_LANGUAGE_TABLE.map(entry=>({...entry,...STRICT_PARITY_CODES.has(entry.code)?{strictParity:true}:{}}));function normalizeLanguageCandidate(input){return input.trim().replace(/_/g,"-").toLowerCase()}__name(normalizeLanguageCandidate,"normalizeLanguageCandidate");function matchesLocaleToken(candidate,token){return candidate===token||candidate.startsWith(`${token}-`)||candidate.startsWith(`${token}.`)||candidate.startsWith(`${token}@`)}__name(matchesLocaleToken,"matchesLocaleToken");function getMatchedLocaleTokenLength(candidate,language){const code=language.code.toLowerCase();const id=language.id.toLowerCase();if(matchesLocaleToken(candidate,id)){return id.length}if(matchesLocaleToken(candidate,code)){return code.length}return void 0}__name(getMatchedLocaleTokenLength,"getMatchedLocaleTokenLength");function resolveSupportedLanguage(input){const normalized=normalizeLanguageCandidate(input);if(!normalized){return void 0}let bestMatch;for(const language of SUPPORTED_LANGUAGES){if(normalized===language.fullName.toLowerCase()||language.nativeName&&normalized===language.nativeName.toLowerCase()){return language.code}const tokenLength=getMatchedLocaleTokenLength(normalized,language);if(tokenLength!==void 0&&(!bestMatch||tokenLength>bestMatch.tokenLength)){bestMatch={code:language.code,tokenLength}}}return bestMatch?.code}__name(resolveSupportedLanguage,"resolveSupportedLanguage");function getLanguageNameFromLocale(locale){const resolved=resolveSupportedLanguage(locale);const lang=resolved?SUPPORTED_LANGUAGES.find(language=>language.code===resolved):void 0;return lang?.fullName||"English"}__name(getLanguageNameFromLocale,"getLanguageNameFromLocale");function getLanguageSettingsOptions(){return[{value:"auto",label:"Auto (detect from system)"},...SUPPORTED_LANGUAGES.map(l=>({value:l.code,label:l.nativeName?`${l.nativeName} (${l.fullName})`:`${l.fullName} (${l.id})`}))]}__name(getLanguageSettingsOptions,"getLanguageSettingsOptions");function getSupportedLanguageIds(separator="|"){return SUPPORTED_LANGUAGES.map(l=>l.id).join(separator)}__name(getSupportedLanguageIds,"getSupportedLanguageIds");export{SUPPORTED_LANGUAGES,resolveSupportedLanguage,getLanguageNameFromLocale,getLanguageSettingsOptions,getSupportedLanguageIds};
4
4
  /**
5
5
  * @license
6
6
  * Copyright 2025 Qwen team
@@ -1,6 +1,6 @@
1
1
  // Force strict mode and setup for ESM
2
2
  "use strict";
3
- import{captureRuntimeFileVersion,writeRuntimeFile}from"./chunk-RMATGKAM.js";import{checkTeamMemorySecrets,checkWorkspaceTeamMemorySecrets}from"./chunk-VFFTE2PS.js";import{buildWorkspaceArtifactCandidate,formatRecordArtifactReminder}from"./chunk-54CHQYA3.js";import{CommitAttributionService,FileEncoding,checkPriorRead,createPatchSmart,detectLineEnding,ensureCrlfLineEndings,getDiffStat,needsUtf8Bom}from"./chunk-3SQ76U4F.js";import{backgroundFixHolding}from"./chunk-B5ZFH363.js";import{getCurrentAgentId}from"./chunk-GQSVGUOU.js";import{FileOperationEvent,ReadFileTool,getLanguageFromFilePath,logFileOperation}from"./chunk-MJEL7DIE.js";import{isAnyAutoMemPath,isTeamAutoMemPath}from"./chunk-CQGP2BAW.js";import{fileExists,getSpecificMimeType}from"./chunk-6JHMYZNS.js";import{safeLiteralReplace}from"./chunk-DBRQGEEI.js";import{BaseDeclarativeTool,StructuredToolError}from"./chunk-D6CEQ2GY.js";import{ToolDisplayNames,ToolNames}from"./chunk-SBZFGYYS.js";import{createDebugLogger}from"./chunk-46KPDLFH.js";import{makeRelative,shortenPath,unescapePath}from"./chunk-2ZK2FGZQ.js";import{getErrorMessage,isNodeError}from"./chunk-E7MYPQGV.js";import{init_esbuild_shims}from"./chunk-VKDAXTCZ.js";import{__name}from"./chunk-KBWJGX7I.js";init_esbuild_shims();import*as fs from"node:fs";import*as path from"node:path";init_esbuild_shims();var UNICODE_EQUIVALENT_MAP={"\u2010":"-","\u2011":"-","\u2012":"-","\u2013":"-","\u2014":"-","\u2015":"-","\u2212":"-","\u2018":"'","\u2019":"'","\u201A":"'","\u201B":"'","\u201C":'"',"\u201D":'"',"\u201E":'"',"\u201F":'"',"\xA0":" ","\u2002":" ","\u2003":" ","\u2004":" ","\u2005":" ","\u2006":" ","\u2007":" ","\u2008":" ","\u2009":" ","\u200A":" ","\u202F":" ","\u205F":" ","\u3000":" "};function normalizeBasicCharacters(text){if(text===""){return text}let normalized="";for(const char of text){normalized+=UNICODE_EQUIVALENT_MAP[char]??char}return normalized}__name(normalizeBasicCharacters,"normalizeBasicCharacters");var LINE_COMPARISON_PASSES=[value=>value,value=>value.trimEnd()];function normalizeLineForComparison(value){return normalizeBasicCharacters(value).trimEnd()}__name(normalizeLineForComparison,"normalizeLineForComparison");function seekSequenceWithTransform(lines,pattern,transform){if(pattern.length===0){return 0}if(pattern.length>lines.length){return null}outer:for(let i=0;i<=lines.length-pattern.length;i++){for(let p=0;p<pattern.length;p++){if(transform(lines[i+p])!==transform(pattern[p])){continue outer}}return i}return null}__name(seekSequenceWithTransform,"seekSequenceWithTransform");function buildLineIndex(text){const lines=text.split("\n");const offsets=new Array(lines.length+1);let cursor=0;for(let i=0;i<lines.length;i++){offsets[i]=cursor;cursor+=lines[i].length;if(i<lines.length-1){cursor+=1}}offsets[lines.length]=text.length;return{lines,offsets}}__name(buildLineIndex,"buildLineIndex");function sliceFromLines(text,offsets,lines,startLine,lineCount,includeTrailingNewline){if(lineCount===0){return includeTrailingNewline?"\n":""}const startIndex=offsets[startLine]??0;const lastLineIndex=startLine+lineCount-1;const lastLineStart=offsets[lastLineIndex]??0;let endIndex=lastLineStart+(lines[lastLineIndex]?.length??0);if(includeTrailingNewline){const nextLineStart=offsets[startLine+lineCount];if(nextLineStart!==void 0){endIndex=nextLineStart}else if(text.endsWith("\n")){endIndex=text.length}}return text.slice(startIndex,endIndex)}__name(sliceFromLines,"sliceFromLines");function findLineBasedMatch(haystack,needle){const{lines,offsets}=buildLineIndex(haystack);const patternLines=needle.split("\n");const endsWithNewline=needle.endsWith("\n");if(patternLines.length===0){return null}const attemptMatch=__name(candidate=>{for(const pass of LINE_COMPARISON_PASSES){const idx=seekSequenceWithTransform(lines,candidate,pass);if(idx!==null){return idx}}return seekSequenceWithTransform(lines,candidate,normalizeLineForComparison)},"attemptMatch");let matchIndex=attemptMatch(patternLines);if(matchIndex!==null){return{slice:sliceFromLines(haystack,offsets,lines,matchIndex,patternLines.length-(endsWithNewline?1:0),endsWithNewline),removedTrailingFinalEmptyLine:false,lineBasedMatch:true}}if(patternLines.at(-1)===""){const trimmedPattern=patternLines.slice(0,-1);if(trimmedPattern.length===0){return null}matchIndex=attemptMatch(trimmedPattern);if(matchIndex!==null){return{slice:sliceFromLines(haystack,offsets,lines,matchIndex,trimmedPattern.length,false),removedTrailingFinalEmptyLine:true,lineBasedMatch:true}}}return null}__name(findLineBasedMatch,"findLineBasedMatch");function findMatchedSlice(haystack,needle){if(needle===""){return null}const literalIndex=haystack.indexOf(needle);if(literalIndex!==-1){return{slice:haystack.slice(literalIndex,literalIndex+needle.length),removedTrailingFinalEmptyLine:false}}const normalizedHaystack=normalizeBasicCharacters(haystack);const normalizedNeedleChars=normalizeBasicCharacters(needle);const normalizedIndex=normalizedHaystack.indexOf(normalizedNeedleChars);if(normalizedIndex!==-1){return{slice:haystack.slice(normalizedIndex,normalizedIndex+needle.length),removedTrailingFinalEmptyLine:false}}return findLineBasedMatch(haystack,needle)}__name(findMatchedSlice,"findMatchedSlice");function removeTrailingNewline(text){if(text.endsWith("\r\n")){return text.slice(0,-2)}if(text.endsWith("\n")||text.endsWith("\r")){return text.slice(0,-1)}return text}__name(removeTrailingNewline,"removeTrailingNewline");function adjustNewStringForTrailingLine(newString,removedTrailingLine){return removedTrailingLine?removeTrailingNewline(newString):newString}__name(adjustNewStringForTrailingLine,"adjustNewStringForTrailingLine");var UNICODE_ESCAPE_PATTERN=/\\\\|\\u[0-9a-fA-F]{4}/g;var MAX_UNICODE_RECOVERY_CODE_UNITS=256;function decodeUnicodeEscapes(text){const decoded=text.replace(UNICODE_ESCAPE_PATTERN,escape=>{if(escape.length===2)return escape;const code=parseInt(escape.slice(2),16);return code>=128?String.fromCharCode(code):escape});return/[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?<![\uD800-\uDBFF])[\uDC00-\uDFFF]/.test(decoded)?null:decoded}__name(decodeUnicodeEscapes,"decodeUnicodeEscapes");function splitsEscapeSequence(text,offset){if(text[offset-1]==="\\"&&/[\\'"/bfnrtv0]/.test(text[offset]??"")){return true}for(let start=Math.max(0,offset-5);start<offset;start++){if(text[start]==="\\"&&/^\\u[0-9a-fA-F]{4}$/.test(text.slice(start,start+6))){return true}}return false}__name(splitsEscapeSequence,"splitsEscapeSequence");function findUnicodeEscapeMatch(fileContent,oldString,newString){const decoded=decodeUnicodeEscapes(oldString);if(decoded===null||decoded.length>MAX_UNICODE_RECOVERY_CODE_UNITS||!/[\u0080-\uffff]/.test(decoded)){return null}if(decoded===oldString&&!fileContent.includes("\\u"))return null;const pattern=decoded.split("").map(char=>{const literal=char.replace(/[.*+?^${}()|[\]\\]/g,"\\$&");if(char.charCodeAt(0)<128)return literal;const hex=char.charCodeAt(0).toString(16).padStart(4,"0").replace(/[a-f]/g,digit=>`[${digit}${digit.toUpperCase()}]`);return`(?:${literal}|(?<!\\\\)\\\\u${hex})`}).join("");let canonical;let literalSearchStart=0;const trailingBackslash=/(?:^|[^\\])(?:\\\\)*\\$/.test(newString);for(const match of fileContent.matchAll(new RegExp(pattern,"g"))){const end=match.index+match[0].length;if(splitsEscapeSequence(fileContent,match.index)||splitsEscapeSequence(fileContent,end)||trailingBackslash&&fileContent[end]==="\\"){return null}if(canonical!==void 0&&canonical!==match[0])return null;canonical=match[0];if(fileContent.indexOf(canonical,literalSearchStart)!==match.index){return null}literalSearchStart=match.index+canonical.length}if(canonical===void 0)return null;if(fileContent.indexOf(canonical,literalSearchStart)!==-1)return null;const escapes=Array.from(canonical.matchAll(UNICODE_ESCAPE_PATTERN),match=>match[0]).filter(escape=>escape.length===6&&parseInt(escape.slice(2),16)>=128);if(escapes.length===0){return{oldString:canonical,newString:decodeUnicodeEscapes(newString)??newString}}if(/[\u0080-\uffff]/.test(canonical))return null;if(/(?:^|[^\\])(?:\\\\)*\\[\u0080-\uffff]/.test(newString))return null;const byChar=new Map(escapes.map(escape=>[String.fromCharCode(parseInt(escape.slice(2),16)),escape]));const digits=escapes.join("").replace(/\\u/g,"");const uppercase=(digits.match(/[A-F]/g)?.length??0)>(digits.match(/[a-f]/g)?.length??0);return{oldString:canonical,newString:newString.split("").map(char=>{if(char.charCodeAt(0)<128)return char;const hex=char.charCodeAt(0).toString(16).padStart(4,"0");return byChar.get(char)??"\\u"+(uppercase?hex.toUpperCase():hex)}).join("")}}__name(findUnicodeEscapeMatch,"findUnicodeEscapeMatch");function normalizeEditStrings(fileContent,oldString,newString){if(fileContent===null||oldString===""){return{oldString,newString}}const canonicalOriginal=findMatchedSlice(fileContent,oldString);if(canonicalOriginal!==null){return{oldString:canonicalOriginal.slice,newString:adjustNewStringForTrailingLine(newString,canonicalOriginal.removedTrailingFinalEmptyLine),...canonicalOriginal.lineBasedMatch?{lineBasedMatch:true}:{}}}return findUnicodeEscapeMatch(fileContent,oldString,newString)??{oldString,newString}}__name(normalizeEditStrings,"normalizeEditStrings");function maybeAugmentOldStringForDeletion(fileContent,oldString,newString,lineBasedMatch=false){if(fileContent===null||oldString===""||newString!==""||oldString.endsWith("\n")){return oldString}const candidate=`${oldString}
3
+ import{captureRuntimeFileVersion,writeRuntimeFile}from"./chunk-FC7SJIAS.js";import{checkTeamMemorySecrets,checkWorkspaceTeamMemorySecrets}from"./chunk-VFFTE2PS.js";import{buildWorkspaceArtifactCandidate,formatRecordArtifactReminder}from"./chunk-54CHQYA3.js";import{CommitAttributionService,FileEncoding,checkPriorRead,createPatchSmart,detectLineEnding,ensureCrlfLineEndings,getDiffStat,needsUtf8Bom}from"./chunk-PFKTTUGS.js";import{backgroundFixHolding}from"./chunk-B5ZFH363.js";import{getCurrentAgentId}from"./chunk-KP77CL5U.js";import{FileOperationEvent,ReadFileTool,getLanguageFromFilePath,logFileOperation}from"./chunk-MJEL7DIE.js";import{isAnyAutoMemPath,isTeamAutoMemPath}from"./chunk-CQGP2BAW.js";import{fileExists,getSpecificMimeType}from"./chunk-6JHMYZNS.js";import{safeLiteralReplace}from"./chunk-DBRQGEEI.js";import{BaseDeclarativeTool,StructuredToolError}from"./chunk-D6CEQ2GY.js";import{ToolDisplayNames,ToolNames}from"./chunk-SBZFGYYS.js";import{createDebugLogger}from"./chunk-46KPDLFH.js";import{makeRelative,shortenPath,unescapePath}from"./chunk-2ZK2FGZQ.js";import{getErrorMessage,isNodeError}from"./chunk-E7MYPQGV.js";import{init_esbuild_shims}from"./chunk-VKDAXTCZ.js";import{__name}from"./chunk-KBWJGX7I.js";init_esbuild_shims();import*as fs from"node:fs";import*as path from"node:path";init_esbuild_shims();var UNICODE_EQUIVALENT_MAP={"\u2010":"-","\u2011":"-","\u2012":"-","\u2013":"-","\u2014":"-","\u2015":"-","\u2212":"-","\u2018":"'","\u2019":"'","\u201A":"'","\u201B":"'","\u201C":'"',"\u201D":'"',"\u201E":'"',"\u201F":'"',"\xA0":" ","\u2002":" ","\u2003":" ","\u2004":" ","\u2005":" ","\u2006":" ","\u2007":" ","\u2008":" ","\u2009":" ","\u200A":" ","\u202F":" ","\u205F":" ","\u3000":" "};function normalizeBasicCharacters(text){if(text===""){return text}let normalized="";for(const char of text){normalized+=UNICODE_EQUIVALENT_MAP[char]??char}return normalized}__name(normalizeBasicCharacters,"normalizeBasicCharacters");var LINE_COMPARISON_PASSES=[value=>value,value=>value.trimEnd()];function normalizeLineForComparison(value){return normalizeBasicCharacters(value).trimEnd()}__name(normalizeLineForComparison,"normalizeLineForComparison");function seekSequenceWithTransform(lines,pattern,transform){if(pattern.length===0){return 0}if(pattern.length>lines.length){return null}outer:for(let i=0;i<=lines.length-pattern.length;i++){for(let p=0;p<pattern.length;p++){if(transform(lines[i+p])!==transform(pattern[p])){continue outer}}return i}return null}__name(seekSequenceWithTransform,"seekSequenceWithTransform");function buildLineIndex(text){const lines=text.split("\n");const offsets=new Array(lines.length+1);let cursor=0;for(let i=0;i<lines.length;i++){offsets[i]=cursor;cursor+=lines[i].length;if(i<lines.length-1){cursor+=1}}offsets[lines.length]=text.length;return{lines,offsets}}__name(buildLineIndex,"buildLineIndex");function sliceFromLines(text,offsets,lines,startLine,lineCount,includeTrailingNewline){if(lineCount===0){return includeTrailingNewline?"\n":""}const startIndex=offsets[startLine]??0;const lastLineIndex=startLine+lineCount-1;const lastLineStart=offsets[lastLineIndex]??0;let endIndex=lastLineStart+(lines[lastLineIndex]?.length??0);if(includeTrailingNewline){const nextLineStart=offsets[startLine+lineCount];if(nextLineStart!==void 0){endIndex=nextLineStart}else if(text.endsWith("\n")){endIndex=text.length}}return text.slice(startIndex,endIndex)}__name(sliceFromLines,"sliceFromLines");function findLineBasedMatch(haystack,needle){const{lines,offsets}=buildLineIndex(haystack);const patternLines=needle.split("\n");const endsWithNewline=needle.endsWith("\n");if(patternLines.length===0){return null}const attemptMatch=__name(candidate=>{for(const pass of LINE_COMPARISON_PASSES){const idx=seekSequenceWithTransform(lines,candidate,pass);if(idx!==null){return idx}}return seekSequenceWithTransform(lines,candidate,normalizeLineForComparison)},"attemptMatch");let matchIndex=attemptMatch(patternLines);if(matchIndex!==null){return{slice:sliceFromLines(haystack,offsets,lines,matchIndex,patternLines.length-(endsWithNewline?1:0),endsWithNewline),removedTrailingFinalEmptyLine:false,lineBasedMatch:true}}if(patternLines.at(-1)===""){const trimmedPattern=patternLines.slice(0,-1);if(trimmedPattern.length===0){return null}matchIndex=attemptMatch(trimmedPattern);if(matchIndex!==null){return{slice:sliceFromLines(haystack,offsets,lines,matchIndex,trimmedPattern.length,false),removedTrailingFinalEmptyLine:true,lineBasedMatch:true}}}return null}__name(findLineBasedMatch,"findLineBasedMatch");function findMatchedSlice(haystack,needle){if(needle===""){return null}const literalIndex=haystack.indexOf(needle);if(literalIndex!==-1){return{slice:haystack.slice(literalIndex,literalIndex+needle.length),removedTrailingFinalEmptyLine:false}}const normalizedHaystack=normalizeBasicCharacters(haystack);const normalizedNeedleChars=normalizeBasicCharacters(needle);const normalizedIndex=normalizedHaystack.indexOf(normalizedNeedleChars);if(normalizedIndex!==-1){return{slice:haystack.slice(normalizedIndex,normalizedIndex+needle.length),removedTrailingFinalEmptyLine:false}}return findLineBasedMatch(haystack,needle)}__name(findMatchedSlice,"findMatchedSlice");function removeTrailingNewline(text){if(text.endsWith("\r\n")){return text.slice(0,-2)}if(text.endsWith("\n")||text.endsWith("\r")){return text.slice(0,-1)}return text}__name(removeTrailingNewline,"removeTrailingNewline");function adjustNewStringForTrailingLine(newString,removedTrailingLine){return removedTrailingLine?removeTrailingNewline(newString):newString}__name(adjustNewStringForTrailingLine,"adjustNewStringForTrailingLine");var UNICODE_ESCAPE_PATTERN=/\\\\|\\u[0-9a-fA-F]{4}/g;var MAX_UNICODE_RECOVERY_CODE_UNITS=256;function decodeUnicodeEscapes(text){const decoded=text.replace(UNICODE_ESCAPE_PATTERN,escape=>{if(escape.length===2)return escape;const code=parseInt(escape.slice(2),16);return code>=128?String.fromCharCode(code):escape});return/[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?<![\uD800-\uDBFF])[\uDC00-\uDFFF]/.test(decoded)?null:decoded}__name(decodeUnicodeEscapes,"decodeUnicodeEscapes");function splitsEscapeSequence(text,offset){if(text[offset-1]==="\\"&&/[\\'"/bfnrtv0]/.test(text[offset]??"")){return true}for(let start=Math.max(0,offset-5);start<offset;start++){if(text[start]==="\\"&&/^\\u[0-9a-fA-F]{4}$/.test(text.slice(start,start+6))){return true}}return false}__name(splitsEscapeSequence,"splitsEscapeSequence");function findUnicodeEscapeMatch(fileContent,oldString,newString){const decoded=decodeUnicodeEscapes(oldString);if(decoded===null||decoded.length>MAX_UNICODE_RECOVERY_CODE_UNITS||!/[\u0080-\uffff]/.test(decoded)){return null}if(decoded===oldString&&!fileContent.includes("\\u"))return null;const pattern=decoded.split("").map(char=>{const literal=char.replace(/[.*+?^${}()|[\]\\]/g,"\\$&");if(char.charCodeAt(0)<128)return literal;const hex=char.charCodeAt(0).toString(16).padStart(4,"0").replace(/[a-f]/g,digit=>`[${digit}${digit.toUpperCase()}]`);return`(?:${literal}|(?<!\\\\)\\\\u${hex})`}).join("");let canonical;let literalSearchStart=0;const trailingBackslash=/(?:^|[^\\])(?:\\\\)*\\$/.test(newString);for(const match of fileContent.matchAll(new RegExp(pattern,"g"))){const end=match.index+match[0].length;if(splitsEscapeSequence(fileContent,match.index)||splitsEscapeSequence(fileContent,end)||trailingBackslash&&fileContent[end]==="\\"){return null}if(canonical!==void 0&&canonical!==match[0])return null;canonical=match[0];if(fileContent.indexOf(canonical,literalSearchStart)!==match.index){return null}literalSearchStart=match.index+canonical.length}if(canonical===void 0)return null;if(fileContent.indexOf(canonical,literalSearchStart)!==-1)return null;const escapes=Array.from(canonical.matchAll(UNICODE_ESCAPE_PATTERN),match=>match[0]).filter(escape=>escape.length===6&&parseInt(escape.slice(2),16)>=128);if(escapes.length===0){return{oldString:canonical,newString:decodeUnicodeEscapes(newString)??newString}}if(/[\u0080-\uffff]/.test(canonical))return null;if(/(?:^|[^\\])(?:\\\\)*\\[\u0080-\uffff]/.test(newString))return null;const byChar=new Map(escapes.map(escape=>[String.fromCharCode(parseInt(escape.slice(2),16)),escape]));const digits=escapes.join("").replace(/\\u/g,"");const uppercase=(digits.match(/[A-F]/g)?.length??0)>(digits.match(/[a-f]/g)?.length??0);return{oldString:canonical,newString:newString.split("").map(char=>{if(char.charCodeAt(0)<128)return char;const hex=char.charCodeAt(0).toString(16).padStart(4,"0");return byChar.get(char)??"\\u"+(uppercase?hex.toUpperCase():hex)}).join("")}}__name(findUnicodeEscapeMatch,"findUnicodeEscapeMatch");function normalizeEditStrings(fileContent,oldString,newString){if(fileContent===null||oldString===""){return{oldString,newString}}const canonicalOriginal=findMatchedSlice(fileContent,oldString);if(canonicalOriginal!==null){return{oldString:canonicalOriginal.slice,newString:adjustNewStringForTrailingLine(newString,canonicalOriginal.removedTrailingFinalEmptyLine),...canonicalOriginal.lineBasedMatch?{lineBasedMatch:true}:{}}}return findUnicodeEscapeMatch(fileContent,oldString,newString)??{oldString,newString}}__name(normalizeEditStrings,"normalizeEditStrings");function maybeAugmentOldStringForDeletion(fileContent,oldString,newString,lineBasedMatch=false){if(fileContent===null||oldString===""||newString!==""||oldString.endsWith("\n")){return oldString}const candidate=`${oldString}
4
4
  `;const hasCandidate=lineBasedMatch?findLineBasedMatchOffsets(fileContent,candidate).length>0:fileContent.includes(candidate);return hasCandidate?candidate:oldString}__name(maybeAugmentOldStringForDeletion,"maybeAugmentOldStringForDeletion");function countOccurrences(source,substr){if(substr===""){return 0}let count=0;let index=source.indexOf(substr);while(index!==-1){count++;index=source.indexOf(substr,index+substr.length)}return count}__name(countOccurrences,"countOccurrences");function findLineBasedMatchOffsets(source,substr){const offsets=[];if(substr===""){return offsets}let index=source.indexOf(substr);while(index!==-1){const end=index+substr.length;const startsLine=index===0||source[index-1]==="\n";const endsLine=substr.endsWith("\n")||end===source.length||source[end]==="\n";if(startsLine&&endsLine){offsets.push(index);index=source.indexOf(substr,end)}else{index=source.indexOf(substr,index+1)}}return offsets}__name(findLineBasedMatchOffsets,"findLineBasedMatchOffsets");var SNIPPET_CONTEXT_LINES=4;var SNIPPET_MAX_LINES=1e3;function extractEditSnippet(oldContent,newContent){const newLines=newContent.split("\n");const totalLines=newLines.length;if(oldContent===null){return{startLine:1,endLine:totalLines,totalLines,content:newContent}}if(oldContent===newContent||!newContent){return null}const oldLines=oldContent.split("\n");let firstDiffLine=0;const minLength=Math.min(oldLines.length,newLines.length);while(firstDiffLine<minLength){if(oldLines[firstDiffLine]!==newLines[firstDiffLine]){break}firstDiffLine++}let oldEndIndex=oldLines.length-1;let newEndIndex=newLines.length-1;while(oldEndIndex>=firstDiffLine&&newEndIndex>=firstDiffLine){if(oldLines[oldEndIndex]!==newLines[newEndIndex]){break}oldEndIndex--;newEndIndex--}const changeStart=firstDiffLine+1;const changeEnd=newEndIndex+1;if(changeEnd-changeStart>SNIPPET_MAX_LINES){return null}const snippetStart=Math.max(1,changeStart-SNIPPET_CONTEXT_LINES);const snippetEnd=Math.min(totalLines,changeEnd+SNIPPET_CONTEXT_LINES);const snippetLines=newLines.slice(snippetStart-1,snippetEnd);return{startLine:snippetStart,endLine:snippetEnd,totalLines,content:snippetLines.join("\n")}}__name(extractEditSnippet,"extractEditSnippet");var debugLogger=createDebugLogger("EDIT_PRIOR_READ");function applyReplacement(currentContent,oldString,newString,isNewFile,matchOffsets){if(isNewFile){return newString}if(currentContent===null){return oldString===""?newString:""}if(oldString===""&&!isNewFile){return currentContent}if(matchOffsets!==void 0){const pieces=[];let cursor=0;for(const offset of matchOffsets){pieces.push(currentContent.slice(cursor,offset),newString);cursor=offset+oldString.length}pieces.push(currentContent.slice(cursor));return pieces.join("")}return safeLiteralReplace(currentContent,oldString,newString)}__name(applyReplacement,"applyReplacement");var EditToolInvocation=class{constructor(config,params){this.config=config;this.params=params}static{__name(this,"EditToolInvocation")}toolLocations(){return[{path:this.params.file_path}]}async calculateEdit(params,original,signal){const observation=original??await this.config.getFileSystemService().textFileIo?.inspect(params.file_path,signal);const sandboxFileVersion=captureRuntimeFileVersion(this.config,params.file_path);const replaceAll=params.replace_all??false;let currentContent=null;let fileExists2=observation?observation.kind==="file":await fileExists(params.file_path);let isNewFile=false;let finalNewString=params.new_string;let finalOldString=params.old_string;let occurrences=0;let error=void 0;let useBOM=false;let detectedEncoding="utf-8";let detectedLineEnding="lf";if(!this.config.getFileReadCacheDisabled()){const decision=await checkPriorRead(this.config.getFileReadCache(),params.file_path,"editing");if(!decision.ok){return{currentContent:null,newContent:"",occurrences:0,error:{display:decision.displayMessage,raw:decision.rawMessage,type:decision.type},isNewFile:false,encoding:"utf-8",bom:false,lineEnding:"lf"}}}if(fileExists2){try{const fileInfo=observation?.kind==="file"?observation.response:await this.config.getFileSystemService().readTextFile({path:params.file_path});if(fileInfo._meta?.bom!==void 0){useBOM=fileInfo._meta.bom}else{useBOM=fileInfo.content.length>0&&fileInfo.content.codePointAt(0)===65279}detectedEncoding=fileInfo._meta?.encoding||"utf-8";detectedLineEnding=detectLineEnding(fileInfo.content);currentContent=fileInfo.content.replace(/\r\n/g,"\n");fileExists2=true}catch(err){if(!isNodeError(err)||err.code!=="ENOENT"){throw err}fileExists2=false}}if(fileExists2&&!this.config.getFileReadCacheDisabled()){const postDecision=await checkPriorRead(this.config.getFileReadCache(),params.file_path,"editing",{expectExisting:true});if(!postDecision.ok){debugLogger.warn("post-read TOCTOU rejection",{path:params.file_path,reason:postDecision.type});return{currentContent:null,newContent:"",occurrences:0,error:{display:postDecision.displayMessage,raw:postDecision.rawMessage,type:postDecision.type},isNewFile:false,encoding:"utf-8",bom:false,lineEnding:"lf"}}}const normalizedStrings=normalizeEditStrings(currentContent,finalOldString,finalNewString);finalOldString=normalizedStrings.oldString;finalNewString=normalizedStrings.newString;let matchOffsets;if(finalOldString===""&&!fileExists2){isNewFile=true}else if(!fileExists2){error={display:`File not found. Cannot apply edit. Use an empty old_string to create a new file.`,raw:`File not found: ${params.file_path}`,type:"file_not_found"}}else if(currentContent!==null){finalOldString=maybeAugmentOldStringForDeletion(currentContent,finalOldString,finalNewString,normalizedStrings.lineBasedMatch);if(normalizedStrings.lineBasedMatch){matchOffsets=findLineBasedMatchOffsets(currentContent,finalOldString)}occurrences=matchOffsets?.length??countOccurrences(currentContent,finalOldString);if(params.old_string===""){error={display:`Failed to edit. Attempted to create a file that already exists.`,raw:`File already exists, cannot create: ${params.file_path}`,type:"attempt_to_create_existing_file"}}else if(occurrences===0){error={display:`Failed to edit, could not find the string to replace.`,raw:`Failed to edit, 0 occurrences found for old_string in ${params.file_path}. No edits made. The exact text in old_string was not found. Ensure you're not escaping content incorrectly and check whitespace, indentation, and context. Use ${ReadFileTool.Name} tool to verify.`,type:"edit_no_occurrence_found"}}else if(!replaceAll&&occurrences>1){error={display:`Failed to edit because the text matches multiple locations. Provide more context or set replace_all to true.`,raw:`Failed to edit. Found ${occurrences} occurrences for old_string in ${params.file_path} but replace_all was not enabled.`,type:"edit_expected_occurrence_mismatch"}}else if(finalOldString===finalNewString){error={display:`No changes to apply. The old_string and new_string are identical.`,raw:`No changes to apply. The old_string and new_string are identical in file: ${params.file_path}`,type:"edit_no_change"}}}else{error={display:`Failed to read content of file.`,raw:`Failed to read content of existing file: ${params.file_path}`,type:"read_content_failure"}}const newContent=!error?applyReplacement(currentContent,finalOldString,finalNewString,isNewFile,matchOffsets):currentContent??"";if(!error&&fileExists2&&currentContent===newContent){error={display:"No changes to apply. The new content is identical to the current content.",raw:`No changes to apply. The new content is identical to the current content in file: ${params.file_path}`,type:"edit_no_change"}}if(!error){const teamMemoryError=(this.config.getFileSystemService().textFileIo?checkWorkspaceTeamMemorySecrets:checkTeamMemorySecrets)(params.file_path,newContent,this.config.getProjectRoot());if(teamMemoryError){const preExisting=currentContent!==null&&(this.config.getFileSystemService().textFileIo?checkWorkspaceTeamMemorySecrets:checkTeamMemorySecrets)(params.file_path,currentContent,this.config.getProjectRoot())!==null;const message=preExisting?`${teamMemoryError} Note: the secret already exists in the current file content, so removing it from your edit alone is not enough \u2014 delete the committed secret from the file.`:teamMemoryError;error={display:message,raw:message,type:"invalid_tool_params"}}}return{currentContent,newContent,sandboxFileVersion,occurrences,error,isNewFile,bom:useBOM,encoding:detectedEncoding,lineEnding:detectedLineEnding}}requiresUserInteraction(){return backgroundFixHolding(this.params.file_path,getCurrentAgentId())!==void 0}async getDefaultPermission(){if(this.config.getFileSystemService().textFileIo)return"ask";const projectRoot=this.config.getProjectRoot();const filePath=path.resolve(this.params.file_path);if(isTeamAutoMemPath(filePath,projectRoot)){return"ask"}if(isAnyAutoMemPath(filePath,projectRoot)){return"allow"}return"ask"}async getConfirmationDetails(abortSignal){let editData;try{editData=await this.calculateEdit(this.params,void 0,abortSignal)}catch(error){if(abortSignal.aborted){throw error}const errorMsg=isNodeError(error)&&error.code==="EISDIR"?`Target is a directory, not a file: ${this.params.file_path} (${error.code})`:getErrorMessage(error);throw new Error(`Error preparing edit: ${errorMsg}`)}if(editData.error){throw new StructuredToolError(editData.error.raw,editData.error.type)}const fileName=path.basename(this.params.file_path);const fileDiff=createPatchSmart(fileName,editData.currentContent??"",editData.newContent,"Current","Proposed");const confirmationDetails={type:"edit",title:`Confirm Edit: ${shortenPath(makeRelative(this.params.file_path,this.config.getTargetDir()))}`,fileName,filePath:this.params.file_path,fileDiff,originalContent:editData.currentContent,newContent:editData.newContent,onConfirm:__name(async outcome=>{if(outcome==="proceed_always"){this.config.setApprovalMode("auto-edit")}},"onConfirm")};return confirmationDetails}getDescription(){const relativePath=makeRelative(this.params.file_path,this.config.getTargetDir());if(this.params.old_string===""){return`Create ${shortenPath(relativePath)}`}if(this.params.old_string===this.params.new_string){return`No file changes to ${shortenPath(relativePath)}`}return shortenPath(relativePath)}async execute(signal){try{const io=this.config.getFileSystemService().textFileIo;return io?await io.withMutation(this.params.file_path,signal,mutation=>this.executeObserved(signal,mutation)):await this.executeObserved(signal)}catch(error){if(signal.aborted)throw error;return this.writeFailure(error)}}async executeObserved(signal,mutation){let editData;try{editData=await this.calculateEdit(this.params,mutation?.original,signal)}catch(error){if(signal.aborted){throw error}const errorMsg=getErrorMessage(error);return{llmContent:`Error preparing edit: ${errorMsg}`,returnDisplay:`Error preparing edit: ${errorMsg}`,error:{message:errorMsg,type:"edit_preparation_failure"}}}if(editData.error){return{llmContent:editData.error.raw,returnDisplay:`Error: ${editData.error.display}`,error:{message:editData.error.raw,type:editData.error.type}}}try{try{await this.config.getFileHistoryService().trackEdit(this.params.file_path)}catch{}if(!this.config.getFileReadCacheDisabled()){const writeDecision=await checkPriorRead(this.config.getFileReadCache(),this.params.file_path,"editing",{expectExisting:!editData.isNewFile});if(!writeDecision.ok){debugLogger.warn("pre-write TOCTOU rejection",{path:this.params.file_path,reason:writeDecision.type});return{llmContent:writeDecision.rawMessage,returnDisplay:`Error: ${writeDecision.displayMessage}`,error:{message:writeDecision.rawMessage,type:writeDecision.type}}}}if(!mutation&&!this.config.getShellExecutionSandbox?.()){this.ensureParentDirectoriesExist(this.params.file_path)}let committedStats;const write=__name(async params=>{if(mutation)committedStats=await mutation.write(params);else await writeRuntimeFile(this.config,params,editData.sandboxFileVersion,signal)},"write");if(editData.isNewFile){const userEncoding=this.config.getDefaultFileEncoding();let useBOM=false;if(userEncoding===FileEncoding.UTF8_BOM){useBOM=true}else if(userEncoding===void 0){useBOM=needsUtf8Bom(this.params.file_path)}await write({path:this.params.file_path,content:editData.newContent,toolWriteOrigin:"edit",_meta:{bom:useBOM}})}else{await write({path:this.params.file_path,content:editData.newContent,toolWriteOrigin:"edit",_meta:{bom:editData.bom,encoding:editData.encoding,lineEnding:editData.lineEnding}})}if(!mutation&&!this.params.modified_by_user){CommitAttributionService.getInstance().recordEdit(this.params.file_path,editData.currentContent,editData.newContent)}let postWriteSizeBytes;try{if(mutation&&!committedStats)throw new Error("Scoped file write returned no committed stats.");const postWriteStats=mutation?committedStats:fs.statSync(this.params.file_path);postWriteSizeBytes=postWriteStats.size;this.config.getFileReadCache().recordWrite(this.params.file_path,postWriteStats)}catch(error){if(mutation)throw error}const fileName=path.basename(this.params.file_path);const originallyProposedContent=this.params.ai_proposed_content||editData.newContent;const diffStat=getDiffStat(fileName,editData.currentContent??"",originallyProposedContent,editData.newContent);const fileDiff=createPatchSmart(fileName,editData.currentContent??"",editData.newContent,"Current","Proposed");const displayResult={fileDiff,fileName,filePath:this.params.file_path,originalContent:editData.currentContent,newContent:editData.newContent,diffStat};const mimetype=getSpecificMimeType(this.params.file_path);const programmingLanguage=getLanguageFromFilePath(this.params.file_path);const extension=path.extname(this.params.file_path);const operation=editData.isNewFile?"create":"update";logFileOperation(this.config,new FileOperationEvent(EditTool.Name,operation,editData.newContent.split("\n").length,mimetype,extension,programmingLanguage));const llmSuccessMessageParts=[editData.isNewFile?`Created new file: ${this.params.file_path} with provided content.`:`The file: ${this.params.file_path} has been updated.`];const artifact=buildWorkspaceArtifactCandidate(this.config,this.params.file_path,{recordAsArtifact:this.params.record_as_artifact,sizeBytes:postWriteSizeBytes});if(artifact&&!artifact.updateOnly){llmSuccessMessageParts.push(formatRecordArtifactReminder(artifact.workspacePath))}const snippetResult=extractEditSnippet(editData.currentContent,editData.newContent);if(snippetResult){const snippetText=`Showing lines ${snippetResult.startLine}-${snippetResult.endLine} of ${snippetResult.totalLines} from the edited file:
5
5
 
6
6
  ---
@@ -1,6 +1,6 @@
1
1
  // Force strict mode and setup for ESM
2
2
  "use strict";
3
- import{loadSettings}from"./chunk-FXFSZ7QF.js";import{t}from"./chunk-4NQCOITC.js";import{loadEnvironment}from"./chunk-3KM4JL4Y.js";import{collectProviderModelsForProtocol}from"./chunk-MWGGXT4P.js";import{resolveModelSelectionAuthType}from"./chunk-BVYNPYGP.js";import{init_esbuild_shims}from"./chunk-VKDAXTCZ.js";import{__name}from"./chunk-KBWJGX7I.js";init_esbuild_shims();var DEFAULT_ENV_KEYS={["openai"]:"OPENAI_API_KEY",["openai-responses"]:"OPENAI_API_KEY"};function findModelConfig(modelProviders,providerProtocol,authType,modelId,baseUrl){if(!modelProviders||!modelId){return void 0}const models=collectProviderModelsForProtocol(modelProviders,providerProtocol,authType);if(models.length===0){return void 0}if(baseUrl){return models.find(m=>m.id===modelId&&m.baseUrl===baseUrl)??models.find(m=>m.id===modelId)}return models.find(m=>m.id===modelId)}__name(findModelConfig,"findModelConfig");function resolveSelectedModel(settings,config){const modelsConfig=config?.getModelsConfig();if(modelsConfig){return{modelId:modelsConfig.getModel(),baseUrl:modelsConfig.getGenerationConfig()?.baseUrl}}return{modelId:settings.model?.name,baseUrl:settings.model?.baseUrl}}__name(resolveSelectedModel,"resolveSelectedModel");function hasEnvValue(settings,envKey){if(!envKey){return false}if(process.env[envKey]){return true}const settingsEnv=settings.env;const settingsEnvValue=settingsEnv?.[envKey];return typeof settingsEnvValue==="string"&&settingsEnvValue.trim().length>0}__name(hasEnvValue,"hasEnvValue");function hasApiKeyForAuth(authType,settings,config){const modelProviders=settings.modelProviders;const{modelId,baseUrl}=resolveSelectedModel(settings,config);const modelAuthType=!config&&(authType==="openai"||authType==="openai-responses")?resolveModelSelectionAuthType(authType,modelId,modelProviders,settings.providerProtocol,baseUrl):authType;const modelConfig=findModelConfig(modelProviders,settings.providerProtocol,modelAuthType,modelId,baseUrl);const resolvedApiKey=config?.getModelsConfig().getGenerationConfig()?.apiKey;if(resolvedApiKey){return{hasKey:true,checkedEnvKey:modelConfig?.envKey??DEFAULT_ENV_KEYS[authType],isExplicitEnvKey:!!modelConfig?.envKey}}if(modelConfig?.envKey){const hasKey=hasEnvValue(settings,modelConfig.envKey);return{hasKey,checkedEnvKey:modelConfig.envKey,isExplicitEnvKey:true}}const defaultEnvKey=DEFAULT_ENV_KEYS[authType];if(defaultEnvKey){const hasKey=hasEnvValue(settings,defaultEnvKey);if(hasKey){return{hasKey,checkedEnvKey:defaultEnvKey,isExplicitEnvKey:false}}}if(settings.security?.auth?.apiKey){return{hasKey:true,checkedEnvKey:defaultEnvKey||void 0,isExplicitEnvKey:false}}return{hasKey:false,checkedEnvKey:defaultEnvKey,isExplicitEnvKey:false}}__name(hasApiKeyForAuth,"hasApiKeyForAuth");function validateAuthMethod(authMethod,config){const settings=loadSettings(process.cwd(),false);loadEnvironment(settings.merged);if(authMethod==="openai"||authMethod==="openai-responses"){const{hasKey,checkedEnvKey,isExplicitEnvKey}=hasApiKeyForAuth(authMethod,settings.merged,config);if(!hasKey){const envKeyHint=checkedEnvKey?`'${checkedEnvKey}'`:"'OPENAI_API_KEY'";if(isExplicitEnvKey){return t("Missing API key for OpenAI-compatible auth. Set the {{envKeyHint}} environment variable.",{envKeyHint})}return t("Missing API key for OpenAI-compatible auth. Set settings.security.auth.apiKey, or set the {{envKeyHint}} environment variable.",{envKeyHint})}return null}return t("Invalid auth method selected.")}__name(validateAuthMethod,"validateAuthMethod");export{validateAuthMethod};
3
+ import{loadSettings}from"./chunk-23543L6E.js";import{t}from"./chunk-FK5L2WVV.js";import{loadEnvironment}from"./chunk-RBA3TP7L.js";import{collectProviderModelsForProtocol}from"./chunk-56PVVXUG.js";import{resolveModelSelectionAuthType}from"./chunk-AJ75BPTA.js";import{init_esbuild_shims}from"./chunk-VKDAXTCZ.js";import{__name}from"./chunk-KBWJGX7I.js";init_esbuild_shims();var DEFAULT_ENV_KEYS={["openai"]:"OPENAI_API_KEY",["openai-responses"]:"OPENAI_API_KEY"};function findModelConfig(modelProviders,providerProtocol,authType,modelId,baseUrl){if(!modelProviders||!modelId){return void 0}const models=collectProviderModelsForProtocol(modelProviders,providerProtocol,authType);if(models.length===0){return void 0}if(baseUrl){return models.find(m=>m.id===modelId&&m.baseUrl===baseUrl)??models.find(m=>m.id===modelId)}return models.find(m=>m.id===modelId)}__name(findModelConfig,"findModelConfig");function resolveSelectedModel(settings,config){const modelsConfig=config?.getModelsConfig();if(modelsConfig){return{modelId:modelsConfig.getModel(),baseUrl:modelsConfig.getGenerationConfig()?.baseUrl}}return{modelId:settings.model?.name,baseUrl:settings.model?.baseUrl}}__name(resolveSelectedModel,"resolveSelectedModel");function hasEnvValue(settings,envKey){if(!envKey){return false}if(process.env[envKey]){return true}const settingsEnv=settings.env;const settingsEnvValue=settingsEnv?.[envKey];return typeof settingsEnvValue==="string"&&settingsEnvValue.trim().length>0}__name(hasEnvValue,"hasEnvValue");function hasApiKeyForAuth(authType,settings,config){const modelProviders=settings.modelProviders;const{modelId,baseUrl}=resolveSelectedModel(settings,config);const modelAuthType=!config&&(authType==="openai"||authType==="openai-responses")?resolveModelSelectionAuthType(authType,modelId,modelProviders,settings.providerProtocol,baseUrl):authType;const modelConfig=findModelConfig(modelProviders,settings.providerProtocol,modelAuthType,modelId,baseUrl);const resolvedApiKey=config?.getModelsConfig().getGenerationConfig()?.apiKey;if(resolvedApiKey){return{hasKey:true,checkedEnvKey:modelConfig?.envKey??DEFAULT_ENV_KEYS[authType],isExplicitEnvKey:!!modelConfig?.envKey}}if(modelConfig?.envKey){const hasKey=hasEnvValue(settings,modelConfig.envKey);return{hasKey,checkedEnvKey:modelConfig.envKey,isExplicitEnvKey:true}}const defaultEnvKey=DEFAULT_ENV_KEYS[authType];if(defaultEnvKey){const hasKey=hasEnvValue(settings,defaultEnvKey);if(hasKey){return{hasKey,checkedEnvKey:defaultEnvKey,isExplicitEnvKey:false}}}if(settings.security?.auth?.apiKey){return{hasKey:true,checkedEnvKey:defaultEnvKey||void 0,isExplicitEnvKey:false}}return{hasKey:false,checkedEnvKey:defaultEnvKey,isExplicitEnvKey:false}}__name(hasApiKeyForAuth,"hasApiKeyForAuth");function validateAuthMethod(authMethod,config){const settings=loadSettings(process.cwd(),false);loadEnvironment(settings.merged);if(authMethod==="openai"||authMethod==="openai-responses"){const{hasKey,checkedEnvKey,isExplicitEnvKey}=hasApiKeyForAuth(authMethod,settings.merged,config);if(!hasKey){const envKeyHint=checkedEnvKey?`'${checkedEnvKey}'`:"'OPENAI_API_KEY'";if(isExplicitEnvKey){return t("Missing API key for OpenAI-compatible auth. Set the {{envKeyHint}} environment variable.",{envKeyHint})}return t("Missing API key for OpenAI-compatible auth. Set settings.security.auth.apiKey, or set the {{envKeyHint}} environment variable.",{envKeyHint})}return null}return t("Invalid auth method selected.")}__name(validateAuthMethod,"validateAuthMethod");export{validateAuthMethod};
4
4
  /**
5
5
  * @license
6
6
  * Copyright 2025 Qwen Team