openclaw-cortex 3.0.1 → 3.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (185) hide show
  1. package/dist/{accounts-B3MIBUxY.js → accounts-6btx_LVr.js} +14 -14
  2. package/dist/{accounts-X5YWm9b7.js → accounts-BOYxuJ9C.js} +1 -1
  3. package/dist/{accounts-Doecg-Pe.js → accounts-Cg6z7lKw.js} +1 -1
  4. package/dist/{active-listener-DI-5r3l7.js → active-listener-BhL5jMd9.js} +1 -1
  5. package/dist/{agent-scope-DgSbJ6PA.js → agent-scope-BLYwrEEA.js} +3 -3
  6. package/dist/{audio-preflight-CketII1D.js → audio-preflight-CJMYPxgz.js} +4 -4
  7. package/dist/{audio-preflight-EwgV_X7F.js → audio-preflight-DrLN-6C1.js} +30 -30
  8. package/dist/{bindings-ZzFXeSUF.js → bindings-DWtXcdc8.js} +2 -2
  9. package/dist/build-info.json +3 -3
  10. package/dist/bundled/boot-md/handler.js +53 -53
  11. package/dist/bundled/bootstrap-extra-files/handler.js +5 -5
  12. package/dist/bundled/command-logger/handler.js +1 -1
  13. package/dist/bundled/session-memory/handler.js +53 -53
  14. package/dist/canvas-host/a2ui/.bundle.hash +1 -1
  15. package/dist/{channel-activity-By7mU0Ld.js → channel-activity-LT3oBvO7.js} +1 -1
  16. package/dist/{chrome-BwkFC1Kp.js → chrome-DBmAGMTR.js} +20 -20
  17. package/dist/{chrome-7PNldBIY.js → chrome-jiKls1lm.js} +7 -7
  18. package/dist/{chunk-DoTNWpve.js → chunk-TRVny4T1.js} +1 -1
  19. package/dist/{command-format--87BbJbN.js → command-format-D1Crrvey.js} +1 -1
  20. package/dist/{command-registry-CKl3i1dn.js → command-registry-B3oActxS.js} +4 -4
  21. package/dist/{commands-registry-C1TEcrP2.js → commands-registry-B6FYKIxi.js} +3 -3
  22. package/dist/{plugin-sdk/common-CJo4CK5_.js → common-y9ALHdVZ.js} +2 -2
  23. package/dist/{completion-cli-D9M167hh.js → completion-cli-C_J-jd9D.js} +1 -1
  24. package/dist/{completion-cli-DWbOrNO2.js → completion-cli-FIejYbDL.js} +2 -2
  25. package/dist/{config-DnorUs_i.js → config-qfEsodS7.js} +12 -12
  26. package/dist/control-ui/_app/immutable/chunks/Bf6c0cUg.js +1 -0
  27. package/dist/control-ui/_app/immutable/entry/{app.gjdkTR50.js → app.BwCsQnur.js} +2 -2
  28. package/dist/control-ui/_app/immutable/entry/start.Br3cjxv0.js +1 -0
  29. package/dist/control-ui/_app/immutable/nodes/{0.DZBLEJTo.js → 0.Dx9jJZSo.js} +1 -1
  30. package/dist/control-ui/_app/immutable/nodes/{1.El_L1H2f.js → 1.BL0sXqCf.js} +1 -1
  31. package/dist/control-ui/_app/immutable/nodes/{14.ApTZ29I1.js → 14.CDt16nEp.js} +1 -1
  32. package/dist/control-ui/_app/version.json +1 -1
  33. package/dist/control-ui/index.html +6 -6
  34. package/dist/{deliver-CFSxoz2_.js → deliver-DXKF_Nu0.js} +1 -1
  35. package/dist/{deliver-DotE8uPe.js → deliver-miQ_b14_.js} +20 -20
  36. package/dist/{diagnostic-D8zLma7p.js → diagnostic-CoT2YQH4.js} +1 -1
  37. package/dist/{doctor-completion-B18Bypvd.js → doctor-completion-D7sHoVar.js} +1 -1
  38. package/dist/{doctor-completion-C45zyyLh.js → doctor-completion-sHbqqiJx.js} +1 -1
  39. package/dist/entry.js +1 -1
  40. package/dist/extensionAPI.js +6 -6
  41. package/dist/{frontmatter-D07uaEbx.js → frontmatter-BT4H5SZG.js} +2 -2
  42. package/dist/{fs-safe-DD7nl1O-.js → fs-safe-B8-WkEXM.js} +1 -1
  43. package/dist/{gateway-cli-C9P1VKyA.js → gateway-cli-Ch6gZFPT.js} +6 -6
  44. package/dist/{gateway-cli-Cy10TRa_.js → gateway-cli-DZ4LS2Gw.js} +6 -6
  45. package/dist/{gemini-auth-prEOLMZr.js → gemini-auth-B32PFjFy.js} +1 -1
  46. package/dist/{github-copilot-token-Bu5FPDAY.js → github-copilot-token-BQ98eazZ.js} +7 -7
  47. package/dist/{image-D-wXbQEl.js → image-Bnzq6Ut_.js} +4 -4
  48. package/dist/{image-DafeVSso.js → image-DChVqMFC.js} +1 -1
  49. package/dist/index.js +1 -1
  50. package/dist/{ir-D4AIeS28.js → ir-CRTCIHIG.js} +4 -4
  51. package/dist/llm-slug-generator.js +53 -53
  52. package/dist/{local-roots-B9HIz81e.js → local-roots-tMzVEQD2.js} +5 -5
  53. package/dist/{login-CHBdSags.js → login-DGwFcNWz.js} +7 -7
  54. package/dist/{login-qr-Ch834jRc.js → login-qr-IWLbGrDP.js} +12 -12
  55. package/dist/{manager-B8MDZuUH.js → manager-KxfmY55A.js} +13 -13
  56. package/dist/{manifest-registry-CpMEl7vN.js → manifest-registry-Dovhiqzt.js} +19 -19
  57. package/dist/{markdown-tables-1wSxjPR8.js → markdown-tables-DO9qAEKa.js} +1 -1
  58. package/dist/{message-channel-CW_Jr8qx.js → message-channel-BDlvrUZF.js} +1 -1
  59. package/dist/{model-auth-BlsavKKY.js → model-auth-Dm1uOof6.js} +9 -9
  60. package/dist/{normalize-DsdAOxp0.js → normalize-D5KCCgTX.js} +9 -9
  61. package/dist/{onboard-BO-10joL.js → onboard-C4csnV8K.js} +1 -1
  62. package/dist/{onboard-CoGGGg5K.js → onboard-PLazjdti.js} +1 -1
  63. package/dist/{onboarding-CiOMo5_c.js → onboarding-B_8tUxFm.js} +1 -1
  64. package/dist/{onboarding-EMqX1DQj.js → onboarding-IlBStOWQ.js} +1 -1
  65. package/dist/{onboarding.finalize-BkqY37UR.js → onboarding.finalize-CUfEwc_X.js} +4 -4
  66. package/dist/{onboarding.finalize-D-8iuvnX.js → onboarding.finalize-CscOXfzt.js} +3 -3
  67. package/dist/{outbound-BI27cc0j.js → outbound-CthSjSDV.js} +7 -7
  68. package/dist/{outbound-attachment-Ba6Ea-zP.js → outbound-attachment-BChLBLPg.js} +2 -2
  69. package/dist/{paths-CkkDESQ2.js → paths-CyR9Pa1R.js} +5 -5
  70. package/dist/{paths-B4zRLe0K.js → paths-gnW-md4M.js} +1 -1
  71. package/dist/{pi-auth-json-gQa8k4FW.js → pi-auth-json-mTixxeol.js} +8 -8
  72. package/dist/{pi-embedded-DzV18Sl5.js → pi-embedded-D0HD9Cfc.js} +158 -158
  73. package/dist/{pi-embedded-Ig1YOX5t.js → pi-embedded-DPsT4Vb4.js} +16 -16
  74. package/dist/{pi-embedded-helpers-C-3FQnQz.js → pi-embedded-helpers--8pQ_5Ix.js} +4 -4
  75. package/dist/{pi-embedded-helpers-B4V6-8TA.js → pi-embedded-helpers-f1wpGfIT.js} +52 -52
  76. package/dist/plugin-sdk/{accounts-vV5Gfd26.js → accounts-CRs7kbLB.js} +1 -1
  77. package/dist/plugin-sdk/{accounts-iN-dbgw4.js → accounts-b1Cok6r_.js} +3 -3
  78. package/dist/plugin-sdk/{accounts-LxMkgia0.js → accounts-uAqOguyH.js} +1 -1
  79. package/dist/plugin-sdk/{active-listener-Bh0LXjEI.js → active-listener-BdVTYHTN.js} +1 -1
  80. package/dist/plugin-sdk/{agent-scope-BS_vck4W.js → agent-scope-OWMdRegz.js} +2 -2
  81. package/dist/plugin-sdk/{api-key-rotation-LkecAWT_.js → api-key-rotation-DedcgBOR.js} +1 -1
  82. package/dist/plugin-sdk/{audio-preflight-Bs1SkEb1.js → audio-preflight-EYVIo5wC.js} +25 -25
  83. package/dist/plugin-sdk/{bindings-CTCkMENc.js → bindings-LROfNV1W.js} +2 -2
  84. package/dist/plugin-sdk/{channel-activity-PV3vhwo2.js → channel-activity-DHI8R5Xg.js} +1 -1
  85. package/dist/plugin-sdk/{channel-web-C1Hsjdgf.js → channel-web-CGp1_ZH4.js} +22 -22
  86. package/dist/plugin-sdk/{chrome-cWvSiZw3.js → chrome-BS8LYp6z.js} +3 -3
  87. package/dist/plugin-sdk/{chunk-CyOBR4uk.js → chunk-C9J4kyVw.js} +1 -1
  88. package/dist/plugin-sdk/{command-format-C5kdEGEu.js → command-format-BTciq6Gg.js} +1 -1
  89. package/dist/plugin-sdk/{commands-registry-Bvksrm0n.js → commands-registry-pHxVP_Zd.js} +3 -3
  90. package/dist/{common-B7QyEEac.js → plugin-sdk/common-CCPGi5xr.js} +2 -2
  91. package/dist/plugin-sdk/{config-B8Nc1zrG.js → config-DemNgb7Z.js} +9 -9
  92. package/dist/plugin-sdk/{deliver-Dut_1pt2.js → deliver-BCvqh6o3.js} +10 -10
  93. package/dist/plugin-sdk/{diagnostic-DFXnVf2I.js → diagnostic-oBxO5N68.js} +1 -1
  94. package/dist/plugin-sdk/{fs-safe-CdpuSWry.js → fs-safe-CGcLaY9D.js} +1 -1
  95. package/dist/plugin-sdk/{image-B3tSrFDE.js → image-BHSeZfna.js} +4 -4
  96. package/dist/plugin-sdk/index.js +52 -52
  97. package/dist/plugin-sdk/{ir-05vuco_v.js → ir-JSGKj1e6.js} +4 -4
  98. package/dist/plugin-sdk/{local-roots-DlmKIABh.js → local-roots-jpNoUngc.js} +3 -3
  99. package/dist/plugin-sdk/{login-_t6d0RBi.js → login-Ckh0Yz4j.js} +7 -7
  100. package/dist/plugin-sdk/{login-qr-Czq6nBnB.js → login-qr-DRY27T-V.js} +9 -9
  101. package/dist/plugin-sdk/{manager-DEOMAxd_.js → manager-B9XMF8DU.js} +8 -8
  102. package/dist/plugin-sdk/{manifest-registry-BgkX6ON4.js → manifest-registry-Lzj-fZNH.js} +1 -1
  103. package/dist/plugin-sdk/{markdown-tables-FF81O4MP.js → markdown-tables-CgnPuqk-.js} +1 -1
  104. package/dist/plugin-sdk/{message-channel-DxNExIdv.js → message-channel-C3OrO29D.js} +1 -1
  105. package/dist/plugin-sdk/{model-selection-Bj-E4zbc.js → model-selection-BQiSfqzh.js} +4 -4
  106. package/dist/plugin-sdk/{normalize-DWmWs1Oq.js → normalize-raRH8X3d.js} +4 -4
  107. package/dist/plugin-sdk/{outbound-D2-05wUl.js → outbound-CtRrsxZT.js} +7 -7
  108. package/dist/plugin-sdk/{outbound-attachment-DmbQx_Vk.js → outbound-attachment-BD9q-xgD.js} +2 -2
  109. package/dist/plugin-sdk/{pi-auth-json-D-qvsSpX.js → pi-auth-json-BlIDGSl5.js} +5 -5
  110. package/dist/plugin-sdk/{pi-embedded-helpers-C1u6XyK5.js → pi-embedded-helpers-0qu1zxwF.js} +17 -17
  111. package/dist/plugin-sdk/{plugins-0PB0IWJL.js → plugins-BJciHbYr.js} +3 -3
  112. package/dist/plugin-sdk/{pw-ai-BIyeKPJF.js → pw-ai-DkUDisr8.js} +8 -8
  113. package/dist/plugin-sdk/{qmd-manager-DeQxerRp.js → qmd-manager-kPD4Wyie.js} +4 -4
  114. package/dist/plugin-sdk/{registry-BECEtj9n.js → registry-C8pj8ctW.js} +2 -2
  115. package/dist/plugin-sdk/{replies-DnGHvUeV.js → replies-0BFlZXJ5.js} +3 -3
  116. package/dist/plugin-sdk/{reply-Due6Dl-a.js → reply-BUzGHOJ7.js} +78 -78
  117. package/dist/plugin-sdk/{reply-prefix-UgReuQSG.js → reply-prefix-YUOHz1rF.js} +1 -1
  118. package/dist/plugin-sdk/{resolve-route-BaFHJbum.js → resolve-route-DudlMKs4.js} +3 -3
  119. package/dist/plugin-sdk/{retry-Bkj1k1me.js → retry-B8Oq5mgi.js} +1 -1
  120. package/dist/plugin-sdk/{runner-Bq1wBell.js → runner-BkD3LLSl.js} +9 -9
  121. package/dist/plugin-sdk/{send-MrY4gJ_w.js → send-9i1KJYhJ.js} +7 -7
  122. package/dist/plugin-sdk/{send-D4HKCCvV.js → send-A_uouj00.js} +7 -7
  123. package/dist/plugin-sdk/{send-By-dm-fT.js → send-CpfmIaxP.js} +11 -11
  124. package/dist/plugin-sdk/{send-NUKqMNZh.js → send-DREpPboJ.js} +6 -6
  125. package/dist/plugin-sdk/{send-M99nJHP9.js → send-Di1hHvf2.js} +11 -11
  126. package/dist/plugin-sdk/{session-DGLRioDC.js → session-CpS-Mhnp.js} +4 -4
  127. package/dist/plugin-sdk/{skill-commands-Cw-IRPUz.js → skill-commands-CTB7AZXn.js} +5 -5
  128. package/dist/plugin-sdk/{skills-D0-IpJne.js → skills-BCD1hFBZ.js} +7 -7
  129. package/dist/plugin-sdk/{sqlite-DtIiUWZr.js → sqlite-Yn48izJ_.js} +1 -1
  130. package/dist/plugin-sdk/{store-BcTI1iBS.js → store-BJRhX9Bi.js} +2 -2
  131. package/dist/plugin-sdk/{subsystem-Ck27y_6W.js → subsystem-BfLMZ8kW.js} +1 -1
  132. package/dist/plugin-sdk/{tables-B6ajREI6.js → tables-D5aPNTF6.js} +1 -1
  133. package/dist/plugin-sdk/{thinking-D81fexfE.js → thinking-BACprzA0.js} +5 -5
  134. package/dist/plugin-sdk/{tokens-B6GWdF_0.js → tokens-D1LxPszt.js} +1 -1
  135. package/dist/plugin-sdk/{tool-loop-detection-CbPwu1_R.js → tool-loop-detection-CYSptBsl.js} +2 -2
  136. package/dist/plugin-sdk/web-DNugKZLo.js +65 -0
  137. package/dist/plugin-sdk/{whatsapp-actions-B8IYO5sc.js → whatsapp-actions-CGuheX42.js} +20 -20
  138. package/dist/{plugins-CLJ0iOl0.js → plugins-CJYXNO4s.js} +1 -1
  139. package/dist/{program-DWc2vj5U.js → program-BEOFzhHf.js} +2 -2
  140. package/dist/{program-context-g9Bf7H9y.js → program-context-CTRcW6qt.js} +6 -6
  141. package/dist/{prompt-select-styled-Dq1G221I.js → prompt-select-styled-DEl1ViOW.js} +1 -1
  142. package/dist/{prompt-select-styled-dUrAqGxZ.js → prompt-select-styled-DxHHs9eu.js} +1 -1
  143. package/dist/{pw-ai-Db7y7La-.js → pw-ai-BJE3mkCf.js} +11 -11
  144. package/dist/{pw-ai-CNp2t_EO.js → pw-ai-D6PxL0UG.js} +1 -1
  145. package/dist/{qmd-manager-3KfZrilm.js → qmd-manager-4-VYqNeC.js} +7 -7
  146. package/dist/{register.maintenance-BQlKe9JQ.js → register.maintenance-BdAIyY7s.js} +4 -4
  147. package/dist/{register.maintenance-BXCIyC2q.js → register.maintenance-jNMy6C-i.js} +5 -5
  148. package/dist/{register.onboard-XjRFAaX-.js → register.onboard-C_oZreTK.js} +2 -2
  149. package/dist/{register.onboard-BjMshgZ4.js → register.onboard-DlDtwyfd.js} +2 -2
  150. package/dist/{register.setup-D9k8Eyg7.js → register.setup-Ba6S39kI.js} +2 -2
  151. package/dist/{register.setup-C3aOJ-9J.js → register.setup-WBFMBTcP.js} +2 -2
  152. package/dist/{register.subclis-DpCWe0ca.js → register.subclis-DtUGzYVz.js} +3 -3
  153. package/dist/{registry-CXBAJGac.js → registry-BmY4gNy6.js} +17 -17
  154. package/dist/{replies-C3QP8Fs6.js → replies-BJH3pQXJ.js} +3 -3
  155. package/dist/{reply-prefix-DhPco1Lk.js → reply-prefix-BaCBHwi7.js} +1 -1
  156. package/dist/{resolve-route-BQouUsWd.js → resolve-route-ClURVRZM.js} +4 -4
  157. package/dist/{retry-BwVcNQB0.js → retry-BxB_D6Pn.js} +1 -1
  158. package/dist/{run-main-BRe5c6iW.js → run-main-B6uubEb8.js} +3 -3
  159. package/dist/{runner-cxIcSp2C.js → runner-BmfMAciA.js} +9 -9
  160. package/dist/{runner-BN1T_Ne4.js → runner-CRUcM4a1.js} +1 -1
  161. package/dist/{send-DNUVC_tJ.js → send-B6BrpfcR.js} +7 -7
  162. package/dist/{send-ByKJYHWg.js → send-BNdapfcg.js} +19 -19
  163. package/dist/{send-CPUILfmc.js → send-C1F31aYA.js} +6 -6
  164. package/dist/{send-3ea6pkzH.js → send-D6tzL2Tv.js} +10 -10
  165. package/dist/{send-2sCLgOVr.js → send-DvBDdcQr.js} +6 -6
  166. package/dist/{session-C0_85REJ.js → session-BH5NTora.js} +8 -8
  167. package/dist/{skill-commands-IxgOIsIT.js → skill-commands-DVss6_wi.js} +9 -9
  168. package/dist/{skills-CwAZv64I.js → skills-Ci_2Mah4.js} +21 -21
  169. package/dist/{sqlite-BY19hYgD.js → sqlite-DJh2xLr6.js} +4 -4
  170. package/dist/{store-CDqpQLub.js → store-Be0QxLPZ.js} +2 -2
  171. package/dist/{subsystem-BFaeHXzD.js → subsystem-B5g771Td.js} +1 -1
  172. package/dist/{tables-z72GfOJY.js → tables-xDr7OSBa.js} +1 -1
  173. package/dist/{thinking-BzWAkN2b.js → thinking-wiChP3LK.js} +5 -5
  174. package/dist/{tokens-CC-Nd7t2.js → tokens-BRx7o_ZS.js} +1 -1
  175. package/dist/{tool-loop-detection-DDnbw1kC.js → tool-loop-detection-BjQsVGUc.js} +3 -3
  176. package/dist/{update-cli-Cnm99-Cj.js → update-cli-COyyIt37.js} +5 -5
  177. package/dist/{update-cli-3URF877J.js → update-cli-WAMVsPit.js} +4 -4
  178. package/dist/{web-CXDGlE3A.js → web-C0-NYLoG.js} +57 -57
  179. package/dist/{web-ComVBhjb.js → web-QGqe0Uj4.js} +6 -6
  180. package/dist/{whatsapp-actions-CLGSXEPl.js → whatsapp-actions-CgowK4CW.js} +23 -23
  181. package/dist/{workspace-CGgFZdqw.js → workspace-D9IzNnST.js} +6 -6
  182. package/package.json +1 -1
  183. package/dist/control-ui/_app/immutable/chunks/CB9985Nn.js +0 -1
  184. package/dist/control-ui/_app/immutable/entry/start.B5atPhn7.js +0 -1
  185. package/dist/plugin-sdk/web-BfmMxgKj.js +0 -65
@@ -1,75 +1,75 @@
1
1
  import { t as __exportAll } from "./rolldown-runtime-Cbj13DAv.js";
2
- import { c as expandHomePrefix, i as resolveGatewayPort, n as resolveConfigPath, s as resolveStateDir, t as STATE_DIR, u as resolveRequiredHomeDir } from "./paths-CkkDESQ2.js";
2
+ import { c as expandHomePrefix, i as resolveGatewayPort, n as resolveConfigPath, s as resolveStateDir, t as STATE_DIR, u as resolveRequiredHomeDir } from "./paths-CyR9Pa1R.js";
3
3
  import { _ as isSubagentSessionKey, c as normalizeAccountId$3, d as resolveAgentIdFromSessionKey, f as resolveThreadSessionKeys, g as isCronSessionKey, h as isAcpSessionKey, i as buildAgentMainSessionKey, l as normalizeAgentId, m as getSubagentDepth, n as DEFAULT_AGENT_ID, p as sanitizeAgentId, s as classifySessionKeyShape, t as DEFAULT_ACCOUNT_ID$1, u as normalizeMainKey, v as parseAgentSessionKey, y as resolveThreadParentSessionKey } from "./session-key-CgcjHuX_.js";
4
- import { $ as warn, B as sleep$1, D as escapeRegExp, E as ensureDir$3, G as danger, I as resolveUserPath, J as logVerbose, M as normalizeE164, O as formatTerminalLink, R as shortenHomeInString, S as CONFIG_DIR, U as truncateUtf16Safe, V as sliceUtf16Safe, W as isPlainObject, X as setVerbose, Z as shouldLogVerbose, _ as matchPluginCommand, a as normalizeAnyChannelId, d as createPluginRegistry, dt as resolvePreferredOpenClawTmpDir, et as colorize, f as normalizePluginHttpPath, g as listPluginCommands, h as getPluginCommandSpecs, k as isRecord$1, l as requireActivePluginRegistry, lt as normalizeLogLevel, m as executePluginCommand, n as CHAT_CHANNEL_ORDER, nt as theme, o as normalizeChannelId, p as clearPluginCommands, r as DEFAULT_CHAT_CHANNEL, rt as getChildLogger, tt as isRich, u as setActivePluginRegistry, v as createInternalHookEvent, w as clampInt, x as triggerInternalHook, z as shortenHomePath } from "./registry-CXBAJGac.js";
5
- import { a as resolveAgentModelPrimary, c as resolveDefaultAgentId, d as resolveSessionAgentIds, i as resolveAgentModelFallbacksOverride, l as resolveEffectiveModelFallbacks, n as resolveAgentConfig, o as resolveAgentSkillsFilter, r as resolveAgentDir, s as resolveAgentWorkspaceDir, t as listAgentIds, u as resolveSessionAgentId } from "./agent-scope-DgSbJ6PA.js";
6
- import { a as registerActiveProgressLine, i as clearActiveProgressLine, n as createNonExitingRuntime, o as unregisterActiveProgressLine, r as defaultRuntime, t as createSubsystemLogger } from "./subsystem-BFaeHXzD.js";
7
- import { S as logWarn, _ as runExec, b as logError, f as loadWorkspaceBootstrapFiles, g as runCommandWithTimeout, l as ensureAgentWorkspace, m as resolveOpenClawPackageRoot, n as DEFAULT_AGENT_WORKSPACE_DIR, r as DEFAULT_BOOTSTRAP_FILENAME, u as filterBootstrapFilesForSession, v as spawnWithFallback, x as logInfo, y as logDebug } from "./workspace-CGgFZdqw.js";
8
- import { n as SILENT_REPLY_TOKEN, r as isSilentReplyText, t as HEARTBEAT_TOKEN } from "./tokens-CC-Nd7t2.js";
9
- import { a as listTelegramAccountIds, c as resolveSlackAccount, d as resolveSlackBotToken, f as createDiscordActionGate, h as normalizeDiscordToken, i as listEnabledTelegramAccounts, m as resolveDiscordAccount, n as normalizeWhatsAppTarget, o as resolveTelegramAccount, p as listEnabledDiscordAccounts, r as createTelegramActionGate, s as resolveTelegramToken, t as isWhatsAppGroupJid, u as resolveSlackAppToken } from "./normalize-DsdAOxp0.js";
10
- import { a as logoutWeb, i as logWebSelfId, l as readWebSelfId, p as webAuthExists, r as getWebAuthAgeMs, t as resolveWhatsAppAccount } from "./accounts-B3MIBUxY.js";
4
+ import { $ as warn, B as sleep$1, D as escapeRegExp, E as ensureDir$3, G as danger, I as resolveUserPath, J as logVerbose, M as normalizeE164, O as formatTerminalLink, R as shortenHomeInString, S as CONFIG_DIR, U as truncateUtf16Safe, V as sliceUtf16Safe, W as isPlainObject, X as setVerbose, Z as shouldLogVerbose, _ as matchPluginCommand, a as normalizeAnyChannelId, d as createPluginRegistry, dt as resolvePreferredOpenClawTmpDir, et as colorize, f as normalizePluginHttpPath, g as listPluginCommands, h as getPluginCommandSpecs, k as isRecord$1, l as requireActivePluginRegistry, lt as normalizeLogLevel, m as executePluginCommand, n as CHAT_CHANNEL_ORDER, nt as theme, o as normalizeChannelId, p as clearPluginCommands, r as DEFAULT_CHAT_CHANNEL, rt as getChildLogger, tt as isRich, u as setActivePluginRegistry, v as createInternalHookEvent, w as clampInt, x as triggerInternalHook, z as shortenHomePath } from "./registry-BmY4gNy6.js";
5
+ import { a as resolveAgentModelPrimary, c as resolveDefaultAgentId, d as resolveSessionAgentIds, i as resolveAgentModelFallbacksOverride, l as resolveEffectiveModelFallbacks, n as resolveAgentConfig, o as resolveAgentSkillsFilter, r as resolveAgentDir, s as resolveAgentWorkspaceDir, t as listAgentIds, u as resolveSessionAgentId } from "./agent-scope-BLYwrEEA.js";
6
+ import { a as registerActiveProgressLine, i as clearActiveProgressLine, n as createNonExitingRuntime, o as unregisterActiveProgressLine, r as defaultRuntime, t as createSubsystemLogger } from "./subsystem-B5g771Td.js";
7
+ import { S as logWarn, _ as runExec, b as logError, f as loadWorkspaceBootstrapFiles, g as runCommandWithTimeout, l as ensureAgentWorkspace, m as resolveOpenClawPackageRoot, n as DEFAULT_AGENT_WORKSPACE_DIR, r as DEFAULT_BOOTSTRAP_FILENAME, u as filterBootstrapFilesForSession, v as spawnWithFallback, x as logInfo, y as logDebug } from "./workspace-D9IzNnST.js";
8
+ import { n as SILENT_REPLY_TOKEN, r as isSilentReplyText, t as HEARTBEAT_TOKEN } from "./tokens-BRx7o_ZS.js";
9
+ import { a as listTelegramAccountIds, c as resolveSlackAccount, d as resolveSlackBotToken, f as createDiscordActionGate, h as normalizeDiscordToken, i as listEnabledTelegramAccounts, m as resolveDiscordAccount, n as normalizeWhatsAppTarget, o as resolveTelegramAccount, p as listEnabledDiscordAccounts, r as createTelegramActionGate, s as resolveTelegramToken, t as isWhatsAppGroupJid, u as resolveSlackAppToken } from "./normalize-D5KCCgTX.js";
10
+ import { a as logoutWeb, i as logWebSelfId, l as readWebSelfId, p as webAuthExists, r as getWebAuthAgeMs, t as resolveWhatsAppAccount } from "./accounts-6btx_LVr.js";
11
11
  import { t as normalizeChatType } from "./chat-type-C_KiWNAH.js";
12
12
  import { t as parseBooleanValue$1 } from "./boolean-B8-BqKGQ.js";
13
- import { n as resolveCliName, r as isTruthyEnvValue, t as formatCliCommand } from "./command-format--87BbJbN.js";
14
- import { a as resolveSlackWebClientOptions, c as buildSlackBlocksFallbackText, i as createSlackWebClient, l as parseSlackTarget, o as parseSlackBlocksInput, s as validateSlackBlocksArray, t as sendMessageSlack, u as resolveSlackChannelId } from "./send-CPUILfmc.js";
15
- import { n as listChannelPlugins, r as normalizeChannelId$1, t as getChannelPlugin } from "./plugins-CLJ0iOl0.js";
16
- import { $ as hasAnyGuildPermissionDiscord, A as addRoleDiscord, B as removeRoleDiscord, C as fetchMessageDiscord, Ct as applyChannelMatchMeta, D as readMessagesDiscord, E as pinMessageDiscord, Et as resolveChannelEntryMatchWithFallback, F as fetchRoleInfoDiscord, G as createChannelDiscord, H as listGuildEmojisDiscord, I as fetchVoiceStatusDiscord, J as moveChannelDiscord, K as deleteChannelDiscord, L as kickMemberDiscord, M as createScheduledEventDiscord, N as fetchChannelInfoDiscord, O as searchMessagesDiscord, P as fetchMemberInfoDiscord, Q as fetchChannelPermissionsDiscord, R as listGuildChannelsDiscord, S as editMessageDiscord, St as fetchDiscord, T as listThreadsDiscord, Tt as normalizeChannelSlug, U as uploadEmojiDiscord, V as timeoutMemberDiscord, W as uploadStickerDiscord, X as setChannelPermissionDiscord, Y as removeChannelPermissionDiscord, Z as stripUndefinedFields, _ as sendPollDiscord, _t as shouldEmitDiscordReactionNotification, a as removeReactionDiscord, at as listDiscordDirectoryPeersLive, b as createThreadDiscord, bt as resolveDiscordSystemLocation, c as formatDiscordComponentEventText, ct as normalizeDiscordAllowList, d as parseDiscordModalCustomId, dt as resolveDiscordChannelConfigWithFallback, et as createDiscordClient, f as parseDiscordModalCustomIdForCarbon, ft as resolveDiscordGuildEntry, g as sendMessageDiscord, gt as resolveGroupDmAllow, h as resolveDiscordModalEntry, ht as resolveDiscordShouldRequireMention, i as removeOwnReactionsDiscord, it as listDiscordDirectoryGroupsLive, j as banMemberDiscord, k as unpinMessageDiscord, l as parseDiscordComponentCustomId, lt as normalizeDiscordSlug, m as resolveDiscordComponentEntry, mt as resolveDiscordOwnerAllowFrom, n as fetchReactionsDiscord, nt as parseDiscordTarget, o as sendDiscordComponentMessage, ot as allowListMatches$1, p as readDiscordComponentSpec, pt as resolveDiscordMemberAccessState, q as editChannelDiscord, r as reactMessageDiscord, rt as resolveDiscordChannelId, s as createDiscordFormModal, st as isDiscordGroupAllowedByPolicy, tt as chunkDiscordTextWithMode, u as parseDiscordComponentCustomIdForCarbon, ut as resolveDiscordAllowListMatch, v as sendStickerDiscord, vt as formatDiscordReactionEmoji, w as listPinsDiscord, wt as buildChannelKeyCandidates, x as deleteMessageDiscord, xt as resolveTimestampMs, y as sendVoiceMessageDiscord, yt as formatDiscordUserTag, z as listScheduledEventsDiscord } from "./send-3ea6pkzH.js";
17
- import { C as getGlobalHookRunner, S as parseInlineDirectives$1, _ as normalizeTargetForProvider, a as normalizeOutboundPayloadsForJson, b as MEDIA_TOKEN_RE, c as applyReplyThreading, d as isRenderablePayload, f as shouldSuppressMessagingToolReplies, g as normalizeChannelTargetInput, h as buildTargetResolverSignature, i as normalizeOutboundPayloads, l as filterMessagingToolDuplicates, m as resolveReplyToMode, o as normalizeReplyPayloadsForDelivery, p as createReplyToModeFilterForChannel, r as formatOutboundPayloadLog, s as applyReplyTagsToPayload, t as deliverOutboundPayloads, u as filterMessagingToolMediaDuplicates, v as throwIfAborted, w as initializeGlobalHookRunner, x as splitMediaFromOutput, y as parseReplyDirectives } from "./deliver-DotE8uPe.js";
18
- import { a as logMessageProcessed, c as logWebhookError, d as startDiagnosticHeartbeat, f as stopDiagnosticHeartbeat, i as logLaneEnqueue, l as logWebhookProcessed, m as isDiagnosticsEnabled, o as logMessageQueued, p as emitDiagnosticEvent, r as logLaneDequeue, s as logSessionStateChange, t as diag, u as logWebhookReceived } from "./diagnostic-D8zLma7p.js";
13
+ import { n as resolveCliName, r as isTruthyEnvValue, t as formatCliCommand } from "./command-format-D1Crrvey.js";
14
+ import { a as resolveSlackWebClientOptions, c as buildSlackBlocksFallbackText, i as createSlackWebClient, l as parseSlackTarget, o as parseSlackBlocksInput, s as validateSlackBlocksArray, t as sendMessageSlack, u as resolveSlackChannelId } from "./send-C1F31aYA.js";
15
+ import { n as listChannelPlugins, r as normalizeChannelId$1, t as getChannelPlugin } from "./plugins-CJYXNO4s.js";
16
+ import { $ as hasAnyGuildPermissionDiscord, A as addRoleDiscord, B as removeRoleDiscord, C as fetchMessageDiscord, Ct as applyChannelMatchMeta, D as readMessagesDiscord, E as pinMessageDiscord, Et as resolveChannelEntryMatchWithFallback, F as fetchRoleInfoDiscord, G as createChannelDiscord, H as listGuildEmojisDiscord, I as fetchVoiceStatusDiscord, J as moveChannelDiscord, K as deleteChannelDiscord, L as kickMemberDiscord, M as createScheduledEventDiscord, N as fetchChannelInfoDiscord, O as searchMessagesDiscord, P as fetchMemberInfoDiscord, Q as fetchChannelPermissionsDiscord, R as listGuildChannelsDiscord, S as editMessageDiscord, St as fetchDiscord, T as listThreadsDiscord, Tt as normalizeChannelSlug, U as uploadEmojiDiscord, V as timeoutMemberDiscord, W as uploadStickerDiscord, X as setChannelPermissionDiscord, Y as removeChannelPermissionDiscord, Z as stripUndefinedFields, _ as sendPollDiscord, _t as shouldEmitDiscordReactionNotification, a as removeReactionDiscord, at as listDiscordDirectoryPeersLive, b as createThreadDiscord, bt as resolveDiscordSystemLocation, c as formatDiscordComponentEventText, ct as normalizeDiscordAllowList, d as parseDiscordModalCustomId, dt as resolveDiscordChannelConfigWithFallback, et as createDiscordClient, f as parseDiscordModalCustomIdForCarbon, ft as resolveDiscordGuildEntry, g as sendMessageDiscord, gt as resolveGroupDmAllow, h as resolveDiscordModalEntry, ht as resolveDiscordShouldRequireMention, i as removeOwnReactionsDiscord, it as listDiscordDirectoryGroupsLive, j as banMemberDiscord, k as unpinMessageDiscord, l as parseDiscordComponentCustomId, lt as normalizeDiscordSlug, m as resolveDiscordComponentEntry, mt as resolveDiscordOwnerAllowFrom, n as fetchReactionsDiscord, nt as parseDiscordTarget, o as sendDiscordComponentMessage, ot as allowListMatches$1, p as readDiscordComponentSpec, pt as resolveDiscordMemberAccessState, q as editChannelDiscord, r as reactMessageDiscord, rt as resolveDiscordChannelId, s as createDiscordFormModal, st as isDiscordGroupAllowedByPolicy, tt as chunkDiscordTextWithMode, u as parseDiscordComponentCustomIdForCarbon, ut as resolveDiscordAllowListMatch, v as sendStickerDiscord, vt as formatDiscordReactionEmoji, w as listPinsDiscord, wt as buildChannelKeyCandidates, x as deleteMessageDiscord, xt as resolveTimestampMs, y as sendVoiceMessageDiscord, yt as formatDiscordUserTag, z as listScheduledEventsDiscord } from "./send-D6tzL2Tv.js";
17
+ import { C as getGlobalHookRunner, S as parseInlineDirectives$1, _ as normalizeTargetForProvider, a as normalizeOutboundPayloadsForJson, b as MEDIA_TOKEN_RE, c as applyReplyThreading, d as isRenderablePayload, f as shouldSuppressMessagingToolReplies, g as normalizeChannelTargetInput, h as buildTargetResolverSignature, i as normalizeOutboundPayloads, l as filterMessagingToolDuplicates, m as resolveReplyToMode, o as normalizeReplyPayloadsForDelivery, p as createReplyToModeFilterForChannel, r as formatOutboundPayloadLog, s as applyReplyTagsToPayload, t as deliverOutboundPayloads, u as filterMessagingToolMediaDuplicates, v as throwIfAborted, w as initializeGlobalHookRunner, x as splitMediaFromOutput, y as parseReplyDirectives } from "./deliver-miQ_b14_.js";
18
+ import { a as logMessageProcessed, c as logWebhookError, d as startDiagnosticHeartbeat, f as stopDiagnosticHeartbeat, i as logLaneEnqueue, l as logWebhookProcessed, m as isDiagnosticsEnabled, o as logMessageQueued, p as emitDiagnosticEvent, r as logLaneDequeue, s as logSessionStateChange, t as diag, u as logWebhookReceived } from "./diagnostic-CoT2YQH4.js";
19
19
  import { r as getDiagnosticSessionState } from "./diagnostic-session-state-DmrztgHU.js";
20
- import { n as resolveSignalAccount, t as listEnabledSignalAccounts } from "./accounts-Doecg-Pe.js";
21
- import { $ as isVoiceCompatibleAudio, A as extractTelegramLocation, B as normalizeAllowFromWithStore$1, C as buildTelegramGroupFrom, D as buildTypingThreadParams, E as buildTelegramThreadParams, F as resolveTelegramMediaPlaceholder, G as formatLocationText, H as firstDefined$1, I as resolveTelegramReplyId, J as readChannelAllowFromStore, K as toLocationContext, L as resolveTelegramStreamMode, M as normalizeForwardedContext, N as resolveTelegramForumThreadId, O as describeReplyTarget, P as resolveTelegramGroupAllowFromContext, Q as listPairingChannels, R as resolveTelegramThreadSpec, S as buildSenderName, T as buildTelegramParentPeer, U as isSenderIdAllowed, V as resolveSenderAllowMatch, W as mergeAllowFromSources, X as upsertChannelPairingRequest, Y as removeChannelAllowFromStoreEntry, Z as getPairingAdapter, _ as resolveTelegramFetch, a as reactMessageTelegram, b as buildGroupLabel, c as sendStickerTelegram, d as wasSentByBot, et as parseTelegramTarget, f as isRecoverableTelegramNetworkError, g as wrapFileReferencesInHtml, h as renderTelegramHtmlText, i as editMessageTelegram, j as hasBotMention, k as expandTextLinks, m as markdownToTelegramHtml, n as createForumTopicTelegram, o as sendMessageTelegram, p as markdownToTelegramChunks, q as addChannelAllowFromStoreEntry, r as deleteMessageTelegram, s as sendPollTelegram, t as buildInlineKeyboard, tt as resolveTelegramTargetChatType, u as resolveTelegramVoiceSend, v as splitTelegramCaption, w as buildTelegramGroupPeerId, x as buildSenderLabel, y as withTelegramApiErrorLogging, z as isSenderAllowed$1 } from "./send-ByKJYHWg.js";
22
- import { d as detectMime, f as extensionForMime, g as isGifMedia, h as isAudioFileName, m as imageMimeFromFormat, s as getImageMetadata, u as resizeToJpeg, x as mediaKindFromMime, y as MAX_IMAGE_BYTES } from "./fs-safe-DD7nl1O-.js";
23
- import { A as normalizeProviderId, C as buildAllowedModelSet, D as isCliProvider, E as findNormalizedProviderValue, F as resolveSubagentSpawnModelSelection, G as DEFAULT_MODEL, H as OLLAMA_NATIVE_BASE_URL, I as resolveThinkingDefault, J as normalizeSecretInput, K as DEFAULT_PROVIDER, M as resolveConfiguredModelRef, N as resolveDefaultModelForAgent, O as modelKey, P as resolveModelRefFromString, T as buildModelAliasIndex, U as createOllamaStreamFn, W as DEFAULT_CONTEXT_TOKENS, Y as getShellPathFromLoginShell, Z as resolveShellEnvFallbackTimeoutMs, _ as ensureAuthProfileStore, a as resolveEnvApiKey, b as withFileLock, c as resolveAuthProfileOrder, d as markAuthProfileFailure, f as markAuthProfileUsed, g as markAuthProfileGood, h as listProfilesForProvider, i as resolveApiKeyForProvider, k as normalizeModelRef$2, l as getSoonestCooldownExpiry, m as dedupeProfileIds, n as getCustomProviderApiKey, o as resolveModelAuthMode, p as resolveApiKeyForProfile, q as resolveAuthProfileDisplayLabel, r as requireApiKey, t as getApiKeyForModel, u as isProfileInCooldown, v as resolveAuthStorePathForDisplay, w as buildConfiguredAllowlistKeys, y as resolveOpenClawAgentDir } from "./model-auth-BlsavKKY.js";
24
- import { a as saveJsonFile, i as loadJsonFile } from "./github-copilot-token-Bu5FPDAY.js";
20
+ import { n as resolveSignalAccount, t as listEnabledSignalAccounts } from "./accounts-Cg6z7lKw.js";
21
+ import { $ as isVoiceCompatibleAudio, A as extractTelegramLocation, B as normalizeAllowFromWithStore$1, C as buildTelegramGroupFrom, D as buildTypingThreadParams, E as buildTelegramThreadParams, F as resolveTelegramMediaPlaceholder, G as formatLocationText, H as firstDefined$1, I as resolveTelegramReplyId, J as readChannelAllowFromStore, K as toLocationContext, L as resolveTelegramStreamMode, M as normalizeForwardedContext, N as resolveTelegramForumThreadId, O as describeReplyTarget, P as resolveTelegramGroupAllowFromContext, Q as listPairingChannels, R as resolveTelegramThreadSpec, S as buildSenderName, T as buildTelegramParentPeer, U as isSenderIdAllowed, V as resolveSenderAllowMatch, W as mergeAllowFromSources, X as upsertChannelPairingRequest, Y as removeChannelAllowFromStoreEntry, Z as getPairingAdapter, _ as resolveTelegramFetch, a as reactMessageTelegram, b as buildGroupLabel, c as sendStickerTelegram, d as wasSentByBot, et as parseTelegramTarget, f as isRecoverableTelegramNetworkError, g as wrapFileReferencesInHtml, h as renderTelegramHtmlText, i as editMessageTelegram, j as hasBotMention, k as expandTextLinks, m as markdownToTelegramHtml, n as createForumTopicTelegram, o as sendMessageTelegram, p as markdownToTelegramChunks, q as addChannelAllowFromStoreEntry, r as deleteMessageTelegram, s as sendPollTelegram, t as buildInlineKeyboard, tt as resolveTelegramTargetChatType, u as resolveTelegramVoiceSend, v as splitTelegramCaption, w as buildTelegramGroupPeerId, x as buildSenderLabel, y as withTelegramApiErrorLogging, z as isSenderAllowed$1 } from "./send-BNdapfcg.js";
22
+ import { d as detectMime, f as extensionForMime, g as isGifMedia, h as isAudioFileName, m as imageMimeFromFormat, s as getImageMetadata, u as resizeToJpeg, x as mediaKindFromMime, y as MAX_IMAGE_BYTES } from "./fs-safe-B8-WkEXM.js";
23
+ import { A as normalizeProviderId, C as buildAllowedModelSet, D as isCliProvider, E as findNormalizedProviderValue, F as resolveSubagentSpawnModelSelection, G as DEFAULT_MODEL, H as OLLAMA_NATIVE_BASE_URL, I as resolveThinkingDefault, J as normalizeSecretInput, K as DEFAULT_PROVIDER, M as resolveConfiguredModelRef, N as resolveDefaultModelForAgent, O as modelKey, P as resolveModelRefFromString, T as buildModelAliasIndex, U as createOllamaStreamFn, W as DEFAULT_CONTEXT_TOKENS, Y as getShellPathFromLoginShell, Z as resolveShellEnvFallbackTimeoutMs, _ as ensureAuthProfileStore, a as resolveEnvApiKey, b as withFileLock, c as resolveAuthProfileOrder, d as markAuthProfileFailure, f as markAuthProfileUsed, g as markAuthProfileGood, h as listProfilesForProvider, i as resolveApiKeyForProvider, k as normalizeModelRef$2, l as getSoonestCooldownExpiry, m as dedupeProfileIds, n as getCustomProviderApiKey, o as resolveModelAuthMode, p as resolveApiKeyForProfile, q as resolveAuthProfileDisplayLabel, r as requireApiKey, t as getApiKeyForModel, u as isProfileInCooldown, v as resolveAuthStorePathForDisplay, w as buildConfiguredAllowlistKeys, y as resolveOpenClawAgentDir } from "./model-auth-Dm1uOof6.js";
24
+ import { a as saveJsonFile, i as loadJsonFile } from "./github-copilot-token-BQ98eazZ.js";
25
25
  import { n as discoverModels, t as discoverAuthStorage } from "./pi-model-discovery-C-yOXpma.js";
26
- import { a as isMarkdownCapableMessageChannel, c as resolveGatewayMessageChannel, d as GATEWAY_CLIENT_MODES, f as GATEWAY_CLIENT_NAMES, i as isInternalMessageChannel, l as resolveMessageChannel, n as isDeliverableMessageChannel, o as listDeliverableMessageChannels, r as isGatewayMessageChannel, s as normalizeMessageChannel, t as INTERNAL_MESSAGE_CHANNEL, u as GATEWAY_CLIENT_IDS } from "./message-channel-CW_Jr8qx.js";
27
- import { $ as normalizeAccountId$4, A as isTransientHttpError, At as getBridgeAuthForPort, B as loadSessionStore, Bt as normalizeToolName, C as isContextOverflowError, Ct as resolveSessionLockMaxHoldFromTimeout, D as isRateLimitAssistantError, Dt as resolveProfile, E as isLikelyContextOverflowError, Et as resolveBrowserConfig, F as resolveSandboxContext, Ft as buildPluginToolGroups, G as updateSessionStoreEntry, Gt as buildBootstrapContextFiles, H as recordSessionMetaFromInbound, Ht as stripPluginOnlyAllowlist, I as resolveSandboxRuntimeStatus, It as collectExplicitAllowlist, J as deliveryContextFromSession, Jt as resolveBootstrapTotalMaxChars, K as isCacheEnabled, Kt as ensureSessionHeader, L as extractDeliveryInfo, Lt as expandPolicyWithPluginGroups, M as parseImageSizeError, Mt as resolveBrowserControlAuth, N as sanitizeUserFacingText, Nt as resolveSandboxConfigForAgent, O as isRawApiErrorPayload, Ot as DEFAULT_UPLOAD_DIR, P as ensureSandboxWorkspaceForSession, Pt as applyOwnerOnlyToolPolicy, Q as normalizeSessionDeliveryFields, R as appendAssistantMessageToSessionTranscript, Rt as expandToolGroups, S as isCompactionFailureError, St as acquireSessionWriteLock, T as isFailoverErrorMessage, Tt as registerBrowserRoutes, U as updateLastRoute, Ut as compileGlobPatterns, V as readSessionUpdatedAt, Vt as resolveToolProfilePolicy, W as updateSessionStore, Wt as matchesAnyGlobPattern, X as mergeDeliveryContext, Y as deliveryContextKey, Yt as sanitizeGoogleTurnOrdering, Z as normalizeDeliveryContext, _ as formatRawAssistantErrorForUi, a as isMessagingToolDuplicateNormalized, at as applyInputProvenanceToUserMessage, b as isBillingAssistantError, bt as deriveSessionMetaPatch, c as extractToolCallsFromAssistant, ct as resolveSessionKey, d as isAntigravityClaude, dt as resolveSessionResetPolicy, et as archiveSessionTranscripts, f as isGoogleModelApi, ft as resolveSessionResetType, g as formatBillingErrorMessage, gt as canonicalizeMainSessionAlias, h as formatAssistantErrorText, ht as resolveFreshSessionTotalTokens, it as INPUT_PROVENANCE_KIND_VALUES, j as parseImageDimensionError, jt as ensureBrowserControlAuth, k as isTimeoutErrorMessage, kt as resolveExistingPathsWithinRoot, l as extractToolResultId, lt as evaluateSessionFreshness, m as classifyFailoverReason, mt as DEFAULT_RESET_TRIGGERS, n as validateGeminiTurns, nt as countToolResults, o as normalizeTextForComparison, ot as hasInterSessionUserProvenance, p as BILLING_ERROR_USER_MESSAGE, pt as resolveThreadFlag, q as resolveCacheTtlMs$1, qt as resolveBootstrapMaxChars, r as pickFallbackThinkingLevel, rt as extractToolCallNames, s as sanitizeSessionMessagesImages, st as normalizeInputProvenance, t as validateAnthropicTurns, tt as capArrayByJsonBytes, u as downgradeOpenAIReasoningBlocks, ut as resolveChannelResetConfig, v as getApiErrorPayloadFingerprint, vt as resolveExplicitAgentSessionKey, w as isFailoverAssistantError, wt as createBrowserRouteContext, x as isCloudCodeAssistFormatError, xt as resolveGroupSessionKey, y as isAuthAssistantError, yt as resolveMainSessionKey, zt as mergeAlsoAllowPolicy } from "./pi-embedded-helpers-B4V6-8TA.js";
28
- import { C as getConfigValueAtPath, D as isSafeExecutableValue, E as unsetConfigValueAtPath, O as resolveAgentMaxConcurrent, S as unsetConfigOverride, T as setConfigValueAtPath, _ as parseDurationMs, a as writeConfigFile, b as resetConfigOverrides, c as TELEGRAM_COMMAND_NAME_PATTERN, f as isInboundPathAllowed, g as normalizeScpRemoteHost, h as resolveIMessageRemoteAttachmentRoots, i as resolveConfigSnapshotHash, k as VERSION, l as normalizeTelegramCommandName, m as resolveIMessageAttachmentRoots, n as loadConfig, o as validateConfigObjectWithPlugins, r as readConfigFileSnapshot, u as resolveTelegramCustomCommands, v as validateJsonSchemaValue, w as parseConfigPath, x as setConfigOverride, y as getConfigOverrides } from "./config-DnorUs_i.js";
29
- import { a as applyTestPluginDefaults, c as resolveMemorySlotDecision, i as safeStatSync, n as discoverOpenClawPlugins, o as normalizePluginsConfig, r as isPathInside, s as resolveEnableState, t as loadPluginManifestRegistry, u as isPathInsideWithRealpath } from "./manifest-registry-CpMEl7vN.js";
30
- import { a as parseAvailableTags, c as readStringArrayParam, h as resolveImageSanitizationLimits, i as jsonResult, l as readStringOrNumberParam, m as sanitizeToolResultImages, n as imageResult, o as readNumberParam, p as sanitizeImageBlocks, r as imageResultFromFile, s as readReactionParams, t as createActionGate, u as readStringParam } from "./common-B7QyEEac.js";
31
- import { C as rawDataToString, O as DEFAULT_AI_SNAPSHOT_MAX_CHARS, T as isSecureWebSocketUrl, x as ensureChromeExtensionRelayServer } from "./chrome-BwkFC1Kp.js";
32
- import { c as assertSandboxPath, d as resolveSandboxedMediaSource, f as applySkillEnvOverrides, i as resolveSkillsPromptForRun, l as resolveSandboxInputPath, n as buildWorkspaceSkillSnapshot, p as applySkillEnvOverridesFromSnapshot, r as loadWorkspaceSkillEntries, s as assertMediaNotDataUrl } from "./skills-CwAZv64I.js";
26
+ import { a as isMarkdownCapableMessageChannel, c as resolveGatewayMessageChannel, d as GATEWAY_CLIENT_MODES, f as GATEWAY_CLIENT_NAMES, i as isInternalMessageChannel, l as resolveMessageChannel, n as isDeliverableMessageChannel, o as listDeliverableMessageChannels, r as isGatewayMessageChannel, s as normalizeMessageChannel, t as INTERNAL_MESSAGE_CHANNEL, u as GATEWAY_CLIENT_IDS } from "./message-channel-BDlvrUZF.js";
27
+ import { $ as normalizeAccountId$4, A as isTransientHttpError, At as getBridgeAuthForPort, B as loadSessionStore, Bt as normalizeToolName, C as isContextOverflowError, Ct as resolveSessionLockMaxHoldFromTimeout, D as isRateLimitAssistantError, Dt as resolveProfile, E as isLikelyContextOverflowError, Et as resolveBrowserConfig, F as resolveSandboxContext, Ft as buildPluginToolGroups, G as updateSessionStoreEntry, Gt as buildBootstrapContextFiles, H as recordSessionMetaFromInbound, Ht as stripPluginOnlyAllowlist, I as resolveSandboxRuntimeStatus, It as collectExplicitAllowlist, J as deliveryContextFromSession, Jt as resolveBootstrapTotalMaxChars, K as isCacheEnabled, Kt as ensureSessionHeader, L as extractDeliveryInfo, Lt as expandPolicyWithPluginGroups, M as parseImageSizeError, Mt as resolveBrowserControlAuth, N as sanitizeUserFacingText, Nt as resolveSandboxConfigForAgent, O as isRawApiErrorPayload, Ot as DEFAULT_UPLOAD_DIR, P as ensureSandboxWorkspaceForSession, Pt as applyOwnerOnlyToolPolicy, Q as normalizeSessionDeliveryFields, R as appendAssistantMessageToSessionTranscript, Rt as expandToolGroups, S as isCompactionFailureError, St as acquireSessionWriteLock, T as isFailoverErrorMessage, Tt as registerBrowserRoutes, U as updateLastRoute, Ut as compileGlobPatterns, V as readSessionUpdatedAt, Vt as resolveToolProfilePolicy, W as updateSessionStore, Wt as matchesAnyGlobPattern, X as mergeDeliveryContext, Y as deliveryContextKey, Yt as sanitizeGoogleTurnOrdering, Z as normalizeDeliveryContext, _ as formatRawAssistantErrorForUi, a as isMessagingToolDuplicateNormalized, at as applyInputProvenanceToUserMessage, b as isBillingAssistantError, bt as deriveSessionMetaPatch, c as extractToolCallsFromAssistant, ct as resolveSessionKey, d as isAntigravityClaude, dt as resolveSessionResetPolicy, et as archiveSessionTranscripts, f as isGoogleModelApi, ft as resolveSessionResetType, g as formatBillingErrorMessage, gt as canonicalizeMainSessionAlias, h as formatAssistantErrorText, ht as resolveFreshSessionTotalTokens, it as INPUT_PROVENANCE_KIND_VALUES, j as parseImageDimensionError, jt as ensureBrowserControlAuth, k as isTimeoutErrorMessage, kt as resolveExistingPathsWithinRoot, l as extractToolResultId, lt as evaluateSessionFreshness, m as classifyFailoverReason, mt as DEFAULT_RESET_TRIGGERS, n as validateGeminiTurns, nt as countToolResults, o as normalizeTextForComparison, ot as hasInterSessionUserProvenance, p as BILLING_ERROR_USER_MESSAGE, pt as resolveThreadFlag, q as resolveCacheTtlMs$1, qt as resolveBootstrapMaxChars, r as pickFallbackThinkingLevel, rt as extractToolCallNames, s as sanitizeSessionMessagesImages, st as normalizeInputProvenance, t as validateAnthropicTurns, tt as capArrayByJsonBytes, u as downgradeOpenAIReasoningBlocks, ut as resolveChannelResetConfig, v as getApiErrorPayloadFingerprint, vt as resolveExplicitAgentSessionKey, w as isFailoverAssistantError, wt as createBrowserRouteContext, x as isCloudCodeAssistFormatError, xt as resolveGroupSessionKey, y as isAuthAssistantError, yt as resolveMainSessionKey, zt as mergeAlsoAllowPolicy } from "./pi-embedded-helpers-f1wpGfIT.js";
28
+ import { C as getConfigValueAtPath, D as isSafeExecutableValue, E as unsetConfigValueAtPath, O as resolveAgentMaxConcurrent, S as unsetConfigOverride, T as setConfigValueAtPath, _ as parseDurationMs, a as writeConfigFile, b as resetConfigOverrides, c as TELEGRAM_COMMAND_NAME_PATTERN, f as isInboundPathAllowed, g as normalizeScpRemoteHost, h as resolveIMessageRemoteAttachmentRoots, i as resolveConfigSnapshotHash, k as VERSION, l as normalizeTelegramCommandName, m as resolveIMessageAttachmentRoots, n as loadConfig, o as validateConfigObjectWithPlugins, r as readConfigFileSnapshot, u as resolveTelegramCustomCommands, v as validateJsonSchemaValue, w as parseConfigPath, x as setConfigOverride, y as getConfigOverrides } from "./config-qfEsodS7.js";
29
+ import { a as applyTestPluginDefaults, c as resolveMemorySlotDecision, i as safeStatSync, n as discoverOpenClawPlugins, o as normalizePluginsConfig, r as isPathInside, s as resolveEnableState, t as loadPluginManifestRegistry, u as isPathInsideWithRealpath } from "./manifest-registry-Dovhiqzt.js";
30
+ import { a as parseAvailableTags, c as readStringArrayParam, h as resolveImageSanitizationLimits, i as jsonResult, l as readStringOrNumberParam, m as sanitizeToolResultImages, n as imageResult, o as readNumberParam, p as sanitizeImageBlocks, r as imageResultFromFile, s as readReactionParams, t as createActionGate, u as readStringParam } from "./common-y9ALHdVZ.js";
31
+ import { C as rawDataToString, O as DEFAULT_AI_SNAPSHOT_MAX_CHARS, T as isSecureWebSocketUrl, x as ensureChromeExtensionRelayServer } from "./chrome-DBmAGMTR.js";
32
+ import { c as assertSandboxPath, d as resolveSandboxedMediaSource, f as applySkillEnvOverrides, i as resolveSkillsPromptForRun, l as resolveSandboxInputPath, n as buildWorkspaceSkillSnapshot, p as applySkillEnvOverridesFromSnapshot, r as loadWorkspaceSkillEntries, s as assertMediaNotDataUrl } from "./skills-Ci_2Mah4.js";
33
33
  import { n as formatErrorMessage, r as formatUncaughtError } from "./errors-3KjSwJLH.js";
34
34
  import { i as isBlockedHostnameOrIp, o as normalizeHostname, t as SsrFBlockedError } from "./ssrf-B8OrDkCk.js";
35
- import { n as getMediaDir, r as saveMediaBuffer } from "./store-CDqpQLub.js";
36
- import { _ as normalizeAtHashSlug, a as normalizeReasoningLevel, b as normalizeStringEntriesLower, c as normalizeVerboseLevel, d as getChannelDock, f as listChannelDocks, g as resolveChannelGroupToolsPolicy, h as resolveChannelGroupRequireMention, i as normalizeElevatedLevel, l as resolveResponseUsageMode, m as resolveChannelGroupPolicy, n as formatXHighModelHint, o as normalizeThinkLevel, p as normalizeSignalMessagingTarget, s as normalizeUsageDisplay, t as formatThinkingLevels, u as supportsXHighThinking, v as normalizeHyphenSlug, y as normalizeStringEntries } from "./thinking-BzWAkN2b.js";
35
+ import { n as getMediaDir, r as saveMediaBuffer } from "./store-Be0QxLPZ.js";
36
+ import { _ as normalizeAtHashSlug, a as normalizeReasoningLevel, b as normalizeStringEntriesLower, c as normalizeVerboseLevel, d as getChannelDock, f as listChannelDocks, g as resolveChannelGroupToolsPolicy, h as resolveChannelGroupRequireMention, i as normalizeElevatedLevel, l as resolveResponseUsageMode, m as resolveChannelGroupPolicy, n as formatXHighModelHint, o as normalizeThinkLevel, p as normalizeSignalMessagingTarget, s as normalizeUsageDisplay, t as formatThinkingLevels, u as supportsXHighThinking, v as normalizeHyphenSlug, y as normalizeStringEntries } from "./thinking-wiChP3LK.js";
37
37
  import { n as resolveConversationLabel } from "./conversation-label-BeLJTciU.js";
38
- import { t as resolveIMessageAccount } from "./accounts-X5YWm9b7.js";
39
- import { i as resolveSessionTranscriptPath, n as resolveSessionFilePath, o as resolveSessionTranscriptsDirForAgent, r as resolveSessionFilePathOptions, s as resolveStorePath, t as resolveDefaultSessionStorePath } from "./paths-B4zRLe0K.js";
38
+ import { t as resolveIMessageAccount } from "./accounts-BOYxuJ9C.js";
39
+ import { i as resolveSessionTranscriptPath, n as resolveSessionFilePath, o as resolveSessionTranscriptsDirForAgent, r as resolveSessionFilePathOptions, s as resolveStorePath, t as resolveDefaultSessionStorePath } from "./paths-gnW-md4M.js";
40
40
  import { t as emitSessionTranscriptUpdate } from "./transcript-events-CZ8CG4ht.js";
41
- import { S as ensureOpenClawModelsJson, _ as stripMinimaxToolCallXml, a as decodeDataUrl, b as stripReasoningTagsFromText, c as extractAssistantText$1, d as extractThinkingFromTaggedText, f as formatReasoningMessage, g as stripDowngradedToolCallText, h as promoteThinkingTagsToBlocks, i as coerceImageModelConfig, l as extractAssistantThinking, m as isAssistantMessage, o as resolveProviderVisionModelFromConfig, p as inferToolMetaFromArgs, r as coerceImageAssistantText, s as minimaxUnderstandImage, u as extractThinkingFromTaggedStream, v as stripThinkingTagsFromText, x as extractTextFromChatContent, y as resolveToolDisplay } from "./image-D-wXbQEl.js";
42
- import { a as resolveEffectiveMessagesConfig, i as resolveAckReaction, o as resolveHumanDelayConfig, r as resolveResponsePrefixTemplate, t as createReplyPrefixOptions } from "./reply-prefix-DhPco1Lk.js";
43
- import { n as resolveMemorySearchConfig } from "./manager-B8MDZuUH.js";
44
- import { d as listMemoryFiles, f as normalizeExtraMemoryPaths, g as runTasksWithConcurrency } from "./sqlite-BY19hYgD.js";
45
- import { n as retryAsync } from "./retry-BwVcNQB0.js";
46
- import { a as chunkText, c as resolveChunkMode, d as isSafeFenceBreak, f as parseFenceSpans, i as chunkMarkdownTextWithMode, l as resolveTextChunkLimit, o as chunkTextWithMode, r as chunkMarkdownText, t as chunkByNewline, u as findFenceSpanAt } from "./chunk-DoTNWpve.js";
47
- import { n as resolveMarkdownTableMode } from "./markdown-tables-1wSxjPR8.js";
41
+ import { S as ensureOpenClawModelsJson, _ as stripMinimaxToolCallXml, a as decodeDataUrl, b as stripReasoningTagsFromText, c as extractAssistantText$1, d as extractThinkingFromTaggedText, f as formatReasoningMessage, g as stripDowngradedToolCallText, h as promoteThinkingTagsToBlocks, i as coerceImageModelConfig, l as extractAssistantThinking, m as isAssistantMessage, o as resolveProviderVisionModelFromConfig, p as inferToolMetaFromArgs, r as coerceImageAssistantText, s as minimaxUnderstandImage, u as extractThinkingFromTaggedStream, v as stripThinkingTagsFromText, x as extractTextFromChatContent, y as resolveToolDisplay } from "./image-Bnzq6Ut_.js";
42
+ import { a as resolveEffectiveMessagesConfig, i as resolveAckReaction, o as resolveHumanDelayConfig, r as resolveResponsePrefixTemplate, t as createReplyPrefixOptions } from "./reply-prefix-BaCBHwi7.js";
43
+ import { n as resolveMemorySearchConfig } from "./manager-KxfmY55A.js";
44
+ import { d as listMemoryFiles, f as normalizeExtraMemoryPaths, g as runTasksWithConcurrency } from "./sqlite-DJh2xLr6.js";
45
+ import { n as retryAsync } from "./retry-BxB_D6Pn.js";
46
+ import { a as chunkText, c as resolveChunkMode, d as isSafeFenceBreak, f as parseFenceSpans, i as chunkMarkdownTextWithMode, l as resolveTextChunkLimit, o as chunkTextWithMode, r as chunkMarkdownText, t as chunkByNewline, u as findFenceSpanAt } from "./chunk-TRVny4T1.js";
47
+ import { n as resolveMarkdownTableMode } from "./markdown-tables-DO9qAEKa.js";
48
48
  import { n as fetchWithTimeout, t as bindAbortRelay } from "./fetch-timeout-DL3f_O53.js";
49
- import { a as readResponseWithLimit, i as fetchRemoteMedia, n as getDefaultMediaLocalRoots, o as fetchWithSsrFGuard, t as getAgentScopedMediaLocalRoots } from "./local-roots-B9HIz81e.js";
50
- import { a as loadWebMedia, i as getDefaultLocalRoots } from "./ir-D4AIeS28.js";
51
- import { a as listChatCommandsForConfig, c as normalizeCommandBody, d as resolveCommandArgMenu, f as serializeCommandArgs, i as listChatCommands, l as parseCommandArgs, o as listNativeCommandSpecs, p as shouldHandleTextCommands, r as findCommandByNativeName, s as listNativeCommandSpecsForConfig, t as buildCommandTextFromArgs, u as resolveCommandArgChoices } from "./commands-registry-C1TEcrP2.js";
52
- import { c as getSkillsSnapshotVersion, d as createAsyncLock, f as readJsonFile, i as resolveSkillCommandInvocation, l as pruneExpiredPending, n as listSkillCommandsForAgents, o as getRemoteSkillEligibility, p as writeJsonAtomic, r as listSkillCommandsForWorkspace, s as ensureSkillsWatcher, t as listReservedChatSlashCommandNames, u as resolvePairingPaths } from "./skill-commands-IxgOIsIT.js";
49
+ import { a as readResponseWithLimit, i as fetchRemoteMedia, n as getDefaultMediaLocalRoots, o as fetchWithSsrFGuard, t as getAgentScopedMediaLocalRoots } from "./local-roots-tMzVEQD2.js";
50
+ import { a as loadWebMedia, i as getDefaultLocalRoots } from "./ir-CRTCIHIG.js";
51
+ import { a as listChatCommandsForConfig, c as normalizeCommandBody, d as resolveCommandArgMenu, f as serializeCommandArgs, i as listChatCommands, l as parseCommandArgs, o as listNativeCommandSpecs, p as shouldHandleTextCommands, r as findCommandByNativeName, s as listNativeCommandSpecsForConfig, t as buildCommandTextFromArgs, u as resolveCommandArgChoices } from "./commands-registry-B6FYKIxi.js";
52
+ import { c as getSkillsSnapshotVersion, d as createAsyncLock, f as readJsonFile, i as resolveSkillCommandInvocation, l as pruneExpiredPending, n as listSkillCommandsForAgents, o as getRemoteSkillEligibility, p as writeJsonAtomic, r as listSkillCommandsForWorkspace, s as ensureSkillsWatcher, t as listReservedChatSlashCommandNames, u as resolvePairingPaths } from "./skill-commands-DVss6_wi.js";
53
53
  import { r as normalizeInboundTextNewlines, t as finalizeInboundContext } from "./inbound-context-CzKsDFGL.js";
54
- import { _ as resolveMediaUnderstandingScope, a as resolveMediaAttachmentLocalRoots, c as loadModelCatalog, d as resolveAttachmentKind, f as buildRandomTempFilePath, g as normalizeMediaUnderstandingChatType, h as resolveTimeoutMs$1, i as resolveAutoImageModel, l as modelSupportsVision, m as resolveConcurrency, n as createMediaAttachmentCache, o as runCapability, p as registerUnhandledRejectionHandler, r as normalizeMediaAttachments, s as findModelInCatalog, t as buildProviderRegistry, v as CLI_OUTPUT_MAX_BUFFER, y as applyTemplate } from "./runner-cxIcSp2C.js";
54
+ import { _ as resolveMediaUnderstandingScope, a as resolveMediaAttachmentLocalRoots, c as loadModelCatalog, d as resolveAttachmentKind, f as buildRandomTempFilePath, g as normalizeMediaUnderstandingChatType, h as resolveTimeoutMs$1, i as resolveAutoImageModel, l as modelSupportsVision, m as resolveConcurrency, n as createMediaAttachmentCache, o as runCapability, p as registerUnhandledRejectionHandler, r as normalizeMediaAttachments, s as findModelInCatalog, t as buildProviderRegistry, v as CLI_OUTPUT_MAX_BUFFER, y as applyTemplate } from "./runner-BmfMAciA.js";
55
55
  import { n as wrapFetchWithAbortSignal, t as resolveFetch } from "./fetch-DtI0mtzx.js";
56
56
  import { n as recordCommandPoll, r as resetCommandPollCount } from "./command-poll-backoff-Bup9wS1y.js";
57
57
  import { n as normalizePollInput } from "./polls-BX3wB_EC.js";
58
- import { a as resolveSignalRpcContext, c as streamSignalEvents, n as sendReadReceiptSignal, o as signalCheck, r as sendTypingSignal, s as signalRpcRequest, t as sendMessageSignal } from "./send-2sCLgOVr.js";
59
- import { a as formatIMessageChatTarget, c as parseIMessageTarget, i as DEFAULT_IMESSAGE_PROBE_TIMEOUT_MS, o as isAllowedIMessageSender, r as createIMessageRpcClient, s as normalizeIMessageHandle, t as sendMessageIMessage } from "./send-DNUVC_tJ.js";
60
- import { n as resolveAgentRoute, t as buildAgentSessionKey } from "./resolve-route-BQouUsWd.js";
61
- import { n as recordChannelActivity, r as createDiscordRetryRunner, t as getChannelActivity } from "./channel-activity-By7mU0Ld.js";
62
- import { t as convertMarkdownTables } from "./tables-z72GfOJY.js";
58
+ import { a as resolveSignalRpcContext, c as streamSignalEvents, n as sendReadReceiptSignal, o as signalCheck, r as sendTypingSignal, s as signalRpcRequest, t as sendMessageSignal } from "./send-DvBDdcQr.js";
59
+ import { a as formatIMessageChatTarget, c as parseIMessageTarget, i as DEFAULT_IMESSAGE_PROBE_TIMEOUT_MS, o as isAllowedIMessageSender, r as createIMessageRpcClient, s as normalizeIMessageHandle, t as sendMessageIMessage } from "./send-B6BrpfcR.js";
60
+ import { n as resolveAgentRoute, t as buildAgentSessionKey } from "./resolve-route-ClURVRZM.js";
61
+ import { n as recordChannelActivity, r as createDiscordRetryRunner, t as getChannelActivity } from "./channel-activity-LT3oBvO7.js";
62
+ import { t as convertMarkdownTables } from "./tables-xDr7OSBa.js";
63
63
  import { t as makeProxyFetch } from "./proxy-CBJ1upuz.js";
64
- import { a as createReplyReferencePlanner, i as resolveSlackThreadTs, n as deliverReplies$3, t as createSlackReplyDeliveryPlan } from "./replies-C3QP8Fs6.js";
65
- import { t as getActiveWebListener } from "./active-listener-DI-5r3l7.js";
64
+ import { a as createReplyReferencePlanner, i as resolveSlackThreadTs, n as deliverReplies$3, t as createSlackReplyDeliveryPlan } from "./replies-BJH3pQXJ.js";
65
+ import { t as getActiveWebListener } from "./active-listener-BhL5jMd9.js";
66
66
  import { createRequire } from "node:module";
67
- import * as fs$1 from "node:fs/promises";
67
+ import * as fs$2 from "node:fs/promises";
68
68
  import fs from "node:fs/promises";
69
69
  import os, { homedir } from "node:os";
70
70
  import * as path$1 from "node:path";
71
71
  import path from "node:path";
72
- import fsSync, { existsSync, mkdirSync, mkdtempSync, readFileSync, renameSync, rmSync, statSync, unlinkSync, writeFileSync } from "node:fs";
72
+ import fs$1, { existsSync, mkdirSync, mkdtempSync, readFileSync, renameSync, rmSync, statSync, unlinkSync, writeFileSync } from "node:fs";
73
73
  import JSON5 from "json5";
74
74
  import { execFile, execFileSync, spawn, spawnSync } from "node:child_process";
75
75
  import { inspect, promisify } from "node:util";
@@ -81,7 +81,7 @@ import { EdgeTTS } from "node-edge-tts";
81
81
  import AjvPkg from "ajv";
82
82
  import { createServer } from "node:http";
83
83
  import { ProxyAgent, fetch as fetch$1 } from "undici";
84
- import WebSocket$1, { WebSocket } from "ws";
84
+ import WebSocket, { WebSocket as WebSocket$1 } from "ws";
85
85
  import { Buffer as Buffer$1 } from "node:buffer";
86
86
  import { createJiti } from "jiti";
87
87
  import { Type } from "@sinclair/typebox";
@@ -3144,7 +3144,7 @@ async function resolveOpenClawDocsPath(params) {
3144
3144
  const workspaceDir = params.workspaceDir?.trim();
3145
3145
  if (workspaceDir) {
3146
3146
  const workspaceDocs = path.join(workspaceDir, "docs");
3147
- if (fsSync.existsSync(workspaceDocs)) return workspaceDocs;
3147
+ if (fs$1.existsSync(workspaceDocs)) return workspaceDocs;
3148
3148
  }
3149
3149
  const packageRoot = await resolveOpenClawPackageRoot({
3150
3150
  cwd: params.cwd,
@@ -3153,7 +3153,7 @@ async function resolveOpenClawDocsPath(params) {
3153
3153
  });
3154
3154
  if (!packageRoot) return null;
3155
3155
  const packageDocs = path.join(packageRoot, "docs");
3156
- return fsSync.existsSync(packageDocs) ? packageDocs : null;
3156
+ return fs$1.existsSync(packageDocs) ? packageDocs : null;
3157
3157
  }
3158
3158
 
3159
3159
  //#endregion
@@ -3462,7 +3462,7 @@ async function getMemorySearchManager(params) {
3462
3462
  if (cached) return { manager: cached };
3463
3463
  }
3464
3464
  try {
3465
- const { QmdMemoryManager } = await import("./qmd-manager-3KfZrilm.js");
3465
+ const { QmdMemoryManager } = await import("./qmd-manager-4-VYqNeC.js");
3466
3466
  const primary = await QmdMemoryManager.create({
3467
3467
  cfg: params.cfg,
3468
3468
  agentId: params.agentId,
@@ -3474,7 +3474,7 @@ async function getMemorySearchManager(params) {
3474
3474
  const wrapper = new FallbackMemoryManager({
3475
3475
  primary,
3476
3476
  fallbackFactory: async () => {
3477
- const { MemoryIndexManager } = await import("./manager-B8MDZuUH.js").then((n) => n.t);
3477
+ const { MemoryIndexManager } = await import("./manager-KxfmY55A.js").then((n) => n.t);
3478
3478
  return await MemoryIndexManager.get(params);
3479
3479
  }
3480
3480
  }, () => QMD_MANAGER_CACHE.delete(cacheKey));
@@ -3487,7 +3487,7 @@ async function getMemorySearchManager(params) {
3487
3487
  }
3488
3488
  }
3489
3489
  try {
3490
- const { MemoryIndexManager } = await import("./manager-B8MDZuUH.js").then((n) => n.t);
3490
+ const { MemoryIndexManager } = await import("./manager-KxfmY55A.js").then((n) => n.t);
3491
3491
  return { manager: await MemoryIndexManager.get(params) };
3492
3492
  } catch (err) {
3493
3493
  return {
@@ -4175,7 +4175,7 @@ function resolveDefaultIdentityPath() {
4175
4175
  return path.join(resolveStateDir(), "identity", "device.json");
4176
4176
  }
4177
4177
  function ensureDir$2(filePath) {
4178
- fsSync.mkdirSync(path.dirname(filePath), { recursive: true });
4178
+ fs$1.mkdirSync(path.dirname(filePath), { recursive: true });
4179
4179
  }
4180
4180
  const ED25519_SPKI_PREFIX = Buffer.from("302a300506032b6570032100", "hex");
4181
4181
  function base64UrlEncode(buf) {
@@ -4211,8 +4211,8 @@ function generateIdentity() {
4211
4211
  }
4212
4212
  function loadOrCreateDeviceIdentity(filePath = resolveDefaultIdentityPath()) {
4213
4213
  try {
4214
- if (fsSync.existsSync(filePath)) {
4215
- const raw = fsSync.readFileSync(filePath, "utf8");
4214
+ if (fs$1.existsSync(filePath)) {
4215
+ const raw = fs$1.readFileSync(filePath, "utf8");
4216
4216
  const parsed = JSON.parse(raw);
4217
4217
  if (parsed?.version === 1 && typeof parsed.deviceId === "string" && typeof parsed.publicKeyPem === "string" && typeof parsed.privateKeyPem === "string") {
4218
4218
  const derivedId = fingerprintPublicKey(parsed.publicKeyPem);
@@ -4221,9 +4221,9 @@ function loadOrCreateDeviceIdentity(filePath = resolveDefaultIdentityPath()) {
4221
4221
  ...parsed,
4222
4222
  deviceId: derivedId
4223
4223
  };
4224
- fsSync.writeFileSync(filePath, `${JSON.stringify(updated, null, 2)}\n`, { mode: 384 });
4224
+ fs$1.writeFileSync(filePath, `${JSON.stringify(updated, null, 2)}\n`, { mode: 384 });
4225
4225
  try {
4226
- fsSync.chmodSync(filePath, 384);
4226
+ fs$1.chmodSync(filePath, 384);
4227
4227
  } catch {}
4228
4228
  return {
4229
4229
  deviceId: derivedId,
@@ -4248,9 +4248,9 @@ function loadOrCreateDeviceIdentity(filePath = resolveDefaultIdentityPath()) {
4248
4248
  privateKeyPem: identity.privateKeyPem,
4249
4249
  createdAtMs: Date.now()
4250
4250
  };
4251
- fsSync.writeFileSync(filePath, `${JSON.stringify(stored, null, 2)}\n`, { mode: 384 });
4251
+ fs$1.writeFileSync(filePath, `${JSON.stringify(stored, null, 2)}\n`, { mode: 384 });
4252
4252
  try {
4253
- fsSync.chmodSync(filePath, 384);
4253
+ fs$1.chmodSync(filePath, 384);
4254
4254
  } catch {}
4255
4255
  return identity;
4256
4256
  }
@@ -4400,8 +4400,8 @@ function resolveDeviceAuthPath(env = process.env) {
4400
4400
  }
4401
4401
  function readStore(filePath) {
4402
4402
  try {
4403
- if (!fsSync.existsSync(filePath)) return null;
4404
- const raw = fsSync.readFileSync(filePath, "utf8");
4403
+ if (!fs$1.existsSync(filePath)) return null;
4404
+ const raw = fs$1.readFileSync(filePath, "utf8");
4405
4405
  const parsed = JSON.parse(raw);
4406
4406
  if (parsed?.version !== 1 || typeof parsed.deviceId !== "string") return null;
4407
4407
  if (!parsed.tokens || typeof parsed.tokens !== "object") return null;
@@ -4411,10 +4411,10 @@ function readStore(filePath) {
4411
4411
  }
4412
4412
  }
4413
4413
  function writeStore(filePath, store) {
4414
- fsSync.mkdirSync(path.dirname(filePath), { recursive: true });
4415
- fsSync.writeFileSync(filePath, `${JSON.stringify(store, null, 2)}\n`, { mode: 384 });
4414
+ fs$1.mkdirSync(path.dirname(filePath), { recursive: true });
4415
+ fs$1.writeFileSync(filePath, `${JSON.stringify(store, null, 2)}\n`, { mode: 384 });
4416
4416
  try {
4417
- fsSync.chmodSync(filePath, 384);
4417
+ fs$1.chmodSync(filePath, 384);
4418
4418
  } catch {}
4419
4419
  }
4420
4420
  function loadDeviceAuthToken(params) {
@@ -5714,7 +5714,7 @@ var GatewayClient = class {
5714
5714
  if (fingerprint !== expected) return /* @__PURE__ */ new Error("gateway tls fingerprint mismatch");
5715
5715
  });
5716
5716
  }
5717
- this.ws = new WebSocket(url, wsOptions);
5717
+ this.ws = new WebSocket$1(url, wsOptions);
5718
5718
  this.ws.on("open", () => {
5719
5719
  if (url.startsWith("wss://") && this.opts.tlsFingerprint) {
5720
5720
  const tlsError = this.validateTlsFingerprint();
@@ -5933,7 +5933,7 @@ var GatewayClient = class {
5933
5933
  return null;
5934
5934
  }
5935
5935
  async request(method, params, opts) {
5936
- if (!this.ws || this.ws.readyState !== WebSocket.OPEN) throw new Error("gateway not connected");
5936
+ if (!this.ws || this.ws.readyState !== WebSocket$1.OPEN) throw new Error("gateway not connected");
5937
5937
  const id = randomUUID();
5938
5938
  const frame = {
5939
5939
  type: "req",
@@ -7197,7 +7197,7 @@ async function routeReply(params) {
7197
7197
  const resolvedReplyToId = replyToId ?? (channelId === "slack" && threadId != null && threadId !== "" ? String(threadId) : void 0);
7198
7198
  const resolvedThreadId = channelId === "slack" ? null : threadId ?? null;
7199
7199
  try {
7200
- const { deliverOutboundPayloads } = await import("./deliver-DotE8uPe.js").then((n) => n.n);
7200
+ const { deliverOutboundPayloads } = await import("./deliver-miQ_b14_.js").then((n) => n.n);
7201
7201
  return {
7202
7202
  ok: true,
7203
7203
  messageId: (await deliverOutboundPayloads({
@@ -7429,7 +7429,7 @@ function normalizeSessionKey(value) {
7429
7429
  }
7430
7430
  function readSessionStore(storePath) {
7431
7431
  try {
7432
- const raw = fsSync.readFileSync(storePath, "utf-8");
7432
+ const raw = fs$1.readFileSync(storePath, "utf-8");
7433
7433
  const parsed = JSON5.parse(raw);
7434
7434
  if (parsed && typeof parsed === "object" && !Array.isArray(parsed)) return parsed;
7435
7435
  } catch {}
@@ -12036,7 +12036,7 @@ async function createModelSelectionState(params) {
12036
12036
  }
12037
12037
  }
12038
12038
  if (sessionEntry && sessionStore && sessionKey && sessionEntry.authProfileOverride) {
12039
- const { ensureAuthProfileStore } = await import("./model-auth-BlsavKKY.js").then((n) => n.s);
12039
+ const { ensureAuthProfileStore } = await import("./model-auth-Dm1uOof6.js").then((n) => n.s);
12040
12040
  const profile = ensureAuthProfileStore(void 0, { allowKeychainPrompt: false }).profiles[sessionEntry.authProfileOverride];
12041
12041
  const providerKey = normalizeProviderId(provider);
12042
12042
  if (!profile || normalizeProviderId(profile.provider) !== providerKey) await clearSessionAuthProfileOverride({
@@ -14389,8 +14389,8 @@ const DEFAULT_SAFE_BINS = [
14389
14389
  ];
14390
14390
  function isExecutableFile(filePath) {
14391
14391
  try {
14392
- if (!fsSync.statSync(filePath).isFile()) return false;
14393
- if (process.platform !== "win32") fsSync.accessSync(filePath, fsSync.constants.X_OK);
14392
+ if (!fs$1.statSync(filePath).isFile()) return false;
14393
+ if (process.platform !== "win32") fs$1.accessSync(filePath, fs$1.constants.X_OK);
14394
14394
  return true;
14395
14395
  } catch {
14396
14396
  return false;
@@ -14428,7 +14428,7 @@ function normalizeMatchTarget(value) {
14428
14428
  }
14429
14429
  function tryRealpath(value) {
14430
14430
  try {
14431
- return fsSync.realpathSync(value);
14431
+ return fs$1.realpathSync(value);
14432
14432
  } catch {
14433
14433
  return null;
14434
14434
  }
@@ -15628,7 +15628,7 @@ function mergeLegacyAgent(current, legacy) {
15628
15628
  }
15629
15629
  function ensureDir$1(filePath) {
15630
15630
  const dir = path.dirname(filePath);
15631
- fsSync.mkdirSync(dir, { recursive: true });
15631
+ fs$1.mkdirSync(dir, { recursive: true });
15632
15632
  }
15633
15633
  function coerceAllowlistEntries(allowlist) {
15634
15634
  if (!Array.isArray(allowlist) || allowlist.length === 0) return Array.isArray(allowlist) ? allowlist : void 0;
@@ -15698,11 +15698,11 @@ function generateToken() {
15698
15698
  function loadExecApprovals() {
15699
15699
  const filePath = resolveExecApprovalsPath();
15700
15700
  try {
15701
- if (!fsSync.existsSync(filePath)) return normalizeExecApprovals({
15701
+ if (!fs$1.existsSync(filePath)) return normalizeExecApprovals({
15702
15702
  version: 1,
15703
15703
  agents: {}
15704
15704
  });
15705
- const raw = fsSync.readFileSync(filePath, "utf8");
15705
+ const raw = fs$1.readFileSync(filePath, "utf8");
15706
15706
  const parsed = JSON.parse(raw);
15707
15707
  if (parsed?.version !== 1) return normalizeExecApprovals({
15708
15708
  version: 1,
@@ -15719,9 +15719,9 @@ function loadExecApprovals() {
15719
15719
  function saveExecApprovals(file) {
15720
15720
  const filePath = resolveExecApprovalsPath();
15721
15721
  ensureDir$1(filePath);
15722
- fsSync.writeFileSync(filePath, `${JSON.stringify(file, null, 2)}\n`, { mode: 384 });
15722
+ fs$1.writeFileSync(filePath, `${JSON.stringify(file, null, 2)}\n`, { mode: 384 });
15723
15723
  try {
15724
- fsSync.chmodSync(filePath, 384);
15724
+ fs$1.chmodSync(filePath, 384);
15725
15725
  } catch {}
15726
15726
  }
15727
15727
  function ensureExecApprovals() {
@@ -16042,7 +16042,7 @@ function resolvePowerShellPath() {
16042
16042
  const systemRoot = process.env.SystemRoot || process.env.WINDIR;
16043
16043
  if (systemRoot) {
16044
16044
  const candidate = path.join(systemRoot, "System32", "WindowsPowerShell", "v1.0", "powershell.exe");
16045
- if (fsSync.existsSync(candidate)) return candidate;
16045
+ if (fs$1.existsSync(candidate)) return candidate;
16046
16046
  }
16047
16047
  return "powershell.exe";
16048
16048
  }
@@ -16080,7 +16080,7 @@ function resolveShellFromPath(name) {
16080
16080
  for (const entry of entries) {
16081
16081
  const candidate = path.join(entry, name);
16082
16082
  try {
16083
- fsSync.accessSync(candidate, fsSync.constants.X_OK);
16083
+ fs$1.accessSync(candidate, fs$1.constants.X_OK);
16084
16084
  return candidate;
16085
16085
  } catch {}
16086
16086
  }
@@ -19206,7 +19206,7 @@ function walkUpFrom(startDir, opts, resolveAtDir) {
19206
19206
  function hasGitMarker(repoRoot) {
19207
19207
  const gitPath = path.join(repoRoot, ".git");
19208
19208
  try {
19209
- const stat = fsSync.statSync(gitPath);
19209
+ const stat = fs$1.statSync(gitPath);
19210
19210
  return stat.isDirectory() || stat.isFile();
19211
19211
  } catch {
19212
19212
  return false;
@@ -19218,10 +19218,10 @@ function findGitRoot(startDir, opts = {}) {
19218
19218
  function resolveGitDirFromMarker(repoRoot) {
19219
19219
  const gitPath = path.join(repoRoot, ".git");
19220
19220
  try {
19221
- const stat = fsSync.statSync(gitPath);
19221
+ const stat = fs$1.statSync(gitPath);
19222
19222
  if (stat.isDirectory()) return gitPath;
19223
19223
  if (!stat.isFile()) return null;
19224
- const match = fsSync.readFileSync(gitPath, "utf-8").match(/gitdir:\s*(.+)/i);
19224
+ const match = fs$1.readFileSync(gitPath, "utf-8").match(/gitdir:\s*(.+)/i);
19225
19225
  if (!match?.[1]) return null;
19226
19226
  return path.resolve(repoRoot, match[1].trim());
19227
19227
  } catch {
@@ -19288,7 +19288,7 @@ const resolveCommitHash = (options = {}) => {
19288
19288
  cachedCommit = null;
19289
19289
  return cachedCommit;
19290
19290
  }
19291
- const head = fsSync.readFileSync(headPath, "utf-8").trim();
19291
+ const head = fs$1.readFileSync(headPath, "utf-8").trim();
19292
19292
  if (!head) {
19293
19293
  cachedCommit = null;
19294
19294
  return cachedCommit;
@@ -19296,7 +19296,7 @@ const resolveCommitHash = (options = {}) => {
19296
19296
  if (head.startsWith("ref:")) {
19297
19297
  const ref = head.replace(/^ref:\s*/i, "").trim();
19298
19298
  const refPath = path.resolve(path.dirname(headPath), ref);
19299
- cachedCommit = formatCommit(fsSync.readFileSync(refPath, "utf-8").trim());
19299
+ cachedCommit = formatCommit(fs$1.readFileSync(refPath, "utf-8").trim());
19300
19300
  return cachedCommit;
19301
19301
  }
19302
19302
  cachedCommit = formatCommit(head);
@@ -19490,9 +19490,9 @@ const readUsageFromSessionLog = (sessionId, sessionEntry, agentId, sessionKey, s
19490
19490
  } catch {
19491
19491
  return;
19492
19492
  }
19493
- if (!fsSync.existsSync(logPath)) return;
19493
+ if (!fs$1.existsSync(logPath)) return;
19494
19494
  try {
19495
- const lines = fsSync.readFileSync(logPath, "utf-8").split(/\n+/);
19495
+ const lines = fs$1.readFileSync(logPath, "utf-8").split(/\n+/);
19496
19496
  let input = 0;
19497
19497
  let output = 0;
19498
19498
  let promptTokens = 0;
@@ -20735,7 +20735,7 @@ function resolveRepoRoot(params) {
20735
20735
  const configured = params.config?.agents?.defaults?.repoRoot?.trim();
20736
20736
  if (configured) try {
20737
20737
  const resolved = path.resolve(configured);
20738
- if (fsSync.statSync(resolved).isDirectory()) return resolved;
20738
+ if (fs$1.statSync(resolved).isDirectory()) return resolved;
20739
20739
  } catch {}
20740
20740
  const candidates = [params.workspaceDir, params.cwd].map((value) => value?.trim()).filter(Boolean);
20741
20741
  const seen = /* @__PURE__ */ new Set();
@@ -21488,7 +21488,7 @@ async function buildContextReply(params) {
21488
21488
  //#region src/auto-reply/reply/commands-export-session.ts
21489
21489
  const EXPORT_HTML_DIR = path.join(path.dirname(fileURLToPath(import.meta.url)), "export-html");
21490
21490
  function loadTemplate(fileName) {
21491
- return fsSync.readFileSync(path.join(EXPORT_HTML_DIR, fileName), "utf-8");
21491
+ return fs$1.readFileSync(path.join(EXPORT_HTML_DIR, fileName), "utf-8");
21492
21492
  }
21493
21493
  function generateHtml(sessionData) {
21494
21494
  const template = loadTemplate("template.html");
@@ -21562,7 +21562,7 @@ async function buildExportSessionReply(params) {
21562
21562
  } catch (err) {
21563
21563
  return { text: `❌ Failed to resolve session file: ${err instanceof Error ? err.message : String(err)}` };
21564
21564
  }
21565
- if (!fsSync.existsSync(sessionFile)) return { text: `❌ Session file not found: ${sessionFile}` };
21565
+ if (!fs$1.existsSync(sessionFile)) return { text: `❌ Session file not found: ${sessionFile}` };
21566
21566
  const sessionManager = SessionManager.open(sessionFile);
21567
21567
  const entries = sessionManager.getEntries();
21568
21568
  const header = sessionManager.getHeader();
@@ -21583,8 +21583,8 @@ async function buildExportSessionReply(params) {
21583
21583
  const defaultFileName = `openclaw-session-${entry.sessionId.slice(0, 8)}-${timestamp}.html`;
21584
21584
  const outputPath = args.outputPath ? path.resolve(args.outputPath.startsWith("~") ? args.outputPath.replace("~", process.env.HOME ?? "") : args.outputPath) : path.join(params.workspaceDir, defaultFileName);
21585
21585
  const outputDir = path.dirname(outputPath);
21586
- if (!fsSync.existsSync(outputDir)) fsSync.mkdirSync(outputDir, { recursive: true });
21587
- fsSync.writeFileSync(outputPath, html, "utf-8");
21586
+ if (!fs$1.existsSync(outputDir)) fs$1.mkdirSync(outputDir, { recursive: true });
21587
+ fs$1.writeFileSync(outputPath, html, "utf-8");
21588
21588
  const relativePath = path.relative(params.workspaceDir, outputPath);
21589
21589
  return { text: [
21590
21590
  "✅ Session exported!",
@@ -21698,8 +21698,8 @@ function resolveZaiApiKey() {
21698
21698
  }
21699
21699
  try {
21700
21700
  const authPath = path.join(os.homedir(), ".pi", "agent", "auth.json");
21701
- if (!fsSync.existsSync(authPath)) return;
21702
- const data = JSON.parse(fsSync.readFileSync(authPath, "utf-8"));
21701
+ if (!fs$1.existsSync(authPath)) return;
21702
+ const data = JSON.parse(fs$1.readFileSync(authPath, "utf-8"));
21703
21703
  return data["z-ai"]?.access || data.zai?.access;
21704
21704
  } catch {
21705
21705
  return;
@@ -23478,7 +23478,7 @@ const applyCostTotal = (totals, costTotal) => {
23478
23478
  totals.totalCost += costTotal;
23479
23479
  };
23480
23480
  async function* readJsonlRecords(filePath) {
23481
- const fileStream = fsSync.createReadStream(filePath, { encoding: "utf-8" });
23481
+ const fileStream = fs$1.createReadStream(filePath, { encoding: "utf-8" });
23482
23482
  const rl = readline.createInterface({
23483
23483
  input: fileStream,
23484
23484
  crlfDelay: Infinity
@@ -23550,10 +23550,10 @@ async function loadCostUsageSummary(params) {
23550
23550
  const dailyMap = /* @__PURE__ */ new Map();
23551
23551
  const totals = emptyTotals();
23552
23552
  const sessionsDir = resolveSessionTranscriptsDirForAgent(params?.agentId);
23553
- const entries = await fsSync.promises.readdir(sessionsDir, { withFileTypes: true }).catch(() => []);
23553
+ const entries = await fs$1.promises.readdir(sessionsDir, { withFileTypes: true }).catch(() => []);
23554
23554
  const files = (await Promise.all(entries.filter((entry) => entry.isFile() && entry.name.endsWith(".jsonl")).map(async (entry) => {
23555
23555
  const filePath = path.join(sessionsDir, entry.name);
23556
- const stats = await fsSync.promises.stat(filePath).catch(() => null);
23556
+ const stats = await fs$1.promises.stat(filePath).catch(() => null);
23557
23557
  if (!stats) return null;
23558
23558
  if (stats.mtimeMs < sinceTime) return null;
23559
23559
  return filePath;
@@ -23586,7 +23586,7 @@ async function loadCostUsageSummary(params) {
23586
23586
  }
23587
23587
  async function loadSessionCostSummary(params) {
23588
23588
  const sessionFile = params.sessionFile ?? (params.sessionId ? resolveSessionFilePath(params.sessionId, params.sessionEntry, { agentId: params.agentId }) : void 0);
23589
- if (!sessionFile || !fsSync.existsSync(sessionFile)) return null;
23589
+ if (!sessionFile || !fs$1.existsSync(sessionFile)) return null;
23590
23590
  const totals = emptyTotals();
23591
23591
  let firstActivity;
23592
23592
  let lastActivity;
@@ -27349,7 +27349,7 @@ function asBoolean(value) {
27349
27349
  }
27350
27350
  function resolveTempPathParts(opts) {
27351
27351
  const tmpDir = opts.tmpDir ?? resolvePreferredOpenClawTmpDir();
27352
- if (!opts.tmpDir) fsSync.mkdirSync(tmpDir, {
27352
+ if (!opts.tmpDir) fs$1.mkdirSync(tmpDir, {
27353
27353
  recursive: true,
27354
27354
  mode: 448
27355
27355
  });
@@ -27415,7 +27415,7 @@ async function writeUrlToFile(filePath, url) {
27415
27415
  if (typeof contentLength === "number" && Number.isFinite(contentLength) && contentLength > MAX_CAMERA_URL_DOWNLOAD_BYTES) throw new Error(`writeUrlToFile: content-length ${contentLength} exceeds max ${MAX_CAMERA_URL_DOWNLOAD_BYTES}`);
27416
27416
  const body = res.body;
27417
27417
  if (!body) throw new Error(`failed to download ${url}: empty response body`);
27418
- const fileHandle = await fs$1.open(filePath, "w");
27418
+ const fileHandle = await fs$2.open(filePath, "w");
27419
27419
  let bytes = 0;
27420
27420
  let thrown;
27421
27421
  try {
@@ -27434,7 +27434,7 @@ async function writeUrlToFile(filePath, url) {
27434
27434
  await fileHandle.close();
27435
27435
  }
27436
27436
  if (thrown) {
27437
- await fs$1.unlink(filePath).catch(() => {});
27437
+ await fs$2.unlink(filePath).catch(() => {});
27438
27438
  throw thrown;
27439
27439
  }
27440
27440
  return {
@@ -27444,7 +27444,7 @@ async function writeUrlToFile(filePath, url) {
27444
27444
  }
27445
27445
  async function writeBase64ToFile(filePath, base64) {
27446
27446
  const buf = Buffer.from(base64, "base64");
27447
- await fs$1.writeFile(filePath, buf);
27447
+ await fs$2.writeFile(filePath, buf);
27448
27448
  return {
27449
27449
  path: filePath,
27450
27450
  bytes: buf.length
@@ -32833,7 +32833,7 @@ function listExistingAgentIdsFromDisk() {
32833
32833
  const root = resolveStateDir();
32834
32834
  const agentsDir = path.join(root, "agents");
32835
32835
  try {
32836
- return fsSync.readdirSync(agentsDir, { withFileTypes: true }).filter((entry) => entry.isDirectory()).map((entry) => normalizeAgentId(entry.name)).filter(Boolean);
32836
+ return fs$1.readdirSync(agentsDir, { withFileTypes: true }).filter((entry) => entry.isDirectory()).map((entry) => normalizeAgentId(entry.name)).filter(Boolean);
32837
32837
  } catch {
32838
32838
  return [];
32839
32839
  }
@@ -37912,7 +37912,7 @@ async function runAgentTurnWithFallback(params) {
37912
37912
  if (corruptedSessionId) {
37913
37913
  const transcriptPath = resolveSessionTranscriptPath(corruptedSessionId);
37914
37914
  try {
37915
- fsSync.unlinkSync(transcriptPath);
37915
+ fs$1.unlinkSync(transcriptPath);
37916
37916
  } catch {}
37917
37917
  }
37918
37918
  delete params.activeSessionStore[sessionKey];
@@ -38617,9 +38617,9 @@ function auditPostCompactionReads(readFilePaths, workspaceDir, requiredReads = D
38617
38617
  * Returns messages from the last N lines (default 100).
38618
38618
  */
38619
38619
  function readSessionMessages(sessionFile, maxLines = 100) {
38620
- if (!fsSync.existsSync(sessionFile)) return [];
38620
+ if (!fs$1.existsSync(sessionFile)) return [];
38621
38621
  try {
38622
- const recentLines = fsSync.readFileSync(sessionFile, "utf-8").trim().split("\n").slice(-maxLines);
38622
+ const recentLines = fs$1.readFileSync(sessionFile, "utf-8").trim().split("\n").slice(-maxLines);
38623
38623
  const messages = [];
38624
38624
  for (const line of recentLines) try {
38625
38625
  const entry = JSON.parse(line);
@@ -38660,8 +38660,8 @@ const MAX_CONTEXT_CHARS = 3e3;
38660
38660
  async function readPostCompactionContext(workspaceDir) {
38661
38661
  const agentsPath = path.join(workspaceDir, "AGENTS.md");
38662
38662
  try {
38663
- if (!fsSync.existsSync(agentsPath)) return null;
38664
- const sections = extractSections(await fsSync.promises.readFile(agentsPath, "utf-8"), ["Session Startup", "Red Lines"]);
38663
+ if (!fs$1.existsSync(agentsPath)) return null;
38664
+ const sections = extractSections(await fs$1.promises.readFile(agentsPath, "utf-8"), ["Session Startup", "Red Lines"]);
38665
38665
  if (sections.length === 0) return null;
38666
38666
  const combined = sections.join("\n\n");
38667
38667
  return "[Post-compaction context refresh]\n\nSession was just compacted. The conversation summary above is a hint, NOT a substitute for your startup sequence. Execute your Session Startup sequence now — read the required files before responding to the user.\n\nCritical rules from AGENTS.md:\n\n" + (combined.length > MAX_CONTEXT_CHARS ? combined.slice(0, MAX_CONTEXT_CHARS) + "\n...[truncated]..." : combined);
@@ -38865,7 +38865,7 @@ async function runReplyAgent(params) {
38865
38865
  if (resolved) transcriptCandidates.add(resolved);
38866
38866
  transcriptCandidates.add(resolveSessionTranscriptPath(prevSessionId, agentId));
38867
38867
  for (const candidate of transcriptCandidates) try {
38868
- fsSync.unlinkSync(candidate);
38868
+ fs$1.unlinkSync(candidate);
38869
38869
  } catch {}
38870
38870
  }
38871
38871
  return true;
@@ -39753,7 +39753,7 @@ async function deliverSessionMaintenanceWarning(params) {
39753
39753
  return;
39754
39754
  }
39755
39755
  try {
39756
- const { deliverOutboundPayloads } = await import("./deliver-DotE8uPe.js").then((n) => n.n);
39756
+ const { deliverOutboundPayloads } = await import("./deliver-miQ_b14_.js").then((n) => n.n);
39757
39757
  await deliverOutboundPayloads({
39758
39758
  cfg: params.cfg,
39759
39759
  channel,
@@ -39779,7 +39779,7 @@ function forkSessionFromParent(params) {
39779
39779
  agentId: params.agentId,
39780
39780
  sessionsDir: params.sessionsDir
39781
39781
  });
39782
- if (!parentSessionFile || !fsSync.existsSync(parentSessionFile)) return null;
39782
+ if (!parentSessionFile || !fs$1.existsSync(parentSessionFile)) return null;
39783
39783
  try {
39784
39784
  const manager = SessionManager.open(parentSessionFile);
39785
39785
  const leafId = manager.getLeafId();
@@ -39803,7 +39803,7 @@ function forkSessionFromParent(params) {
39803
39803
  cwd: manager.getCwd(),
39804
39804
  parentSession: parentSessionFile
39805
39805
  };
39806
- fsSync.writeFileSync(sessionFile, `${JSON.stringify(header)}\n`, "utf-8");
39806
+ fs$1.writeFileSync(sessionFile, `${JSON.stringify(header)}\n`, "utf-8");
39807
39807
  return {
39808
39808
  sessionId,
39809
39809
  sessionFile
@@ -43185,7 +43185,7 @@ async function describeStickerImage(params) {
43185
43185
  logVerbose(`telegram: describing sticker with ${provider}/${model}`);
43186
43186
  try {
43187
43187
  const buffer = await fs.readFile(imagePath);
43188
- const { describeImageWithModel } = await import("./image-D-wXbQEl.js").then((n) => n.n);
43188
+ const { describeImageWithModel } = await import("./image-Bnzq6Ut_.js").then((n) => n.n);
43189
43189
  return (await describeImageWithModel({
43190
43190
  buffer,
43191
43191
  fileName: "sticker.webp",
@@ -43608,7 +43608,7 @@ function createWhatsAppLoginTool() {
43608
43608
  force: Type.Optional(Type.Boolean())
43609
43609
  }),
43610
43610
  execute: async (_toolCallId, args) => {
43611
- const { startWebLoginWithQr, waitForWebLogin } = await import("./login-qr-Ch834jRc.js");
43611
+ const { startWebLoginWithQr, waitForWebLogin } = await import("./login-qr-IWLbGrDP.js");
43612
43612
  if ((args?.action ?? "start") === "wait") {
43613
43613
  const result = await waitForWebLogin({ timeoutMs: typeof args.timeoutMs === "number" ? args.timeoutMs : void 0 });
43614
43614
  return {
@@ -43890,7 +43890,7 @@ async function withMemoryManagerForAgent(params) {
43890
43890
  }
43891
43891
  async function checkReadableFile(pathname) {
43892
43892
  try {
43893
- await fs.access(pathname, fsSync.constants.R_OK);
43893
+ await fs.access(pathname, fs$1.constants.R_OK);
43894
43894
  return { exists: true };
43895
43895
  } catch (err) {
43896
43896
  const code = err.code;
@@ -43949,7 +43949,7 @@ async function scanMemoryFiles(workspaceDir, extraPaths = []) {
43949
43949
  }
43950
43950
  let dirReadable = null;
43951
43951
  try {
43952
- await fs.access(memoryDir, fsSync.constants.R_OK);
43952
+ await fs.access(memoryDir, fs$1.constants.R_OK);
43953
43953
  dirReadable = true;
43954
43954
  } catch (err) {
43955
43955
  const code = err.code;
@@ -45605,7 +45605,7 @@ async function preflightDiscordMessage(params) {
45605
45605
  let preflightTranscript;
45606
45606
  const hasAudioAttachment = message.attachments?.some((att) => att.contentType?.startsWith("audio/"));
45607
45607
  if (!isDirectMessage && shouldRequireMention && hasAudioAttachment && !baseText && mentionRegexes.length > 0) try {
45608
- const { transcribeFirstAudio } = await import("./audio-preflight-EwgV_X7F.js");
45608
+ const { transcribeFirstAudio } = await import("./audio-preflight-DrLN-6C1.js");
45609
45609
  const audioPaths = message.attachments?.filter((att) => att.contentType?.startsWith("audio/")).map((att) => att.url) ?? [];
45610
45610
  if (audioPaths.length > 0) preflightTranscript = await transcribeFirstAudio({
45611
45611
  ctx: {
@@ -47268,7 +47268,7 @@ function sanitizeRecentModels(models, limit) {
47268
47268
  }
47269
47269
  async function readJsonFileWithFallback(filePath, fallback) {
47270
47270
  try {
47271
- const raw = await fsSync.promises.readFile(filePath, "utf-8");
47271
+ const raw = await fs$1.promises.readFile(filePath, "utf-8");
47272
47272
  return {
47273
47273
  value: JSON.parse(raw),
47274
47274
  exists: true
@@ -47286,14 +47286,14 @@ async function readJsonFileWithFallback(filePath, fallback) {
47286
47286
  }
47287
47287
  async function writeJsonFileAtomically(filePath, value) {
47288
47288
  const dir = path.dirname(filePath);
47289
- await fsSync.promises.mkdir(dir, {
47289
+ await fs$1.promises.mkdir(dir, {
47290
47290
  recursive: true,
47291
47291
  mode: 448
47292
47292
  });
47293
47293
  const tmp = path.join(dir, `${path.basename(filePath)}.${crypto.randomUUID()}.tmp`);
47294
- await fsSync.promises.writeFile(tmp, `${JSON.stringify(value, null, 2)}\n`, "utf-8");
47295
- await fsSync.promises.chmod(tmp, 384);
47296
- await fsSync.promises.rename(tmp, filePath);
47294
+ await fs$1.promises.writeFile(tmp, `${JSON.stringify(value, null, 2)}\n`, "utf-8");
47295
+ await fs$1.promises.chmod(tmp, 384);
47296
+ await fs$1.promises.rename(tmp, filePath);
47297
47297
  }
47298
47298
  async function readPreferencesStore(filePath) {
47299
47299
  const { value } = await readJsonFileWithFallback(filePath, {
@@ -49736,27 +49736,27 @@ function isVoiceChannelType(type) {
49736
49736
  function createDefaultDeps() {
49737
49737
  return {
49738
49738
  sendMessageWhatsApp: async (...args) => {
49739
- const { sendMessageWhatsApp } = await import("./web-CXDGlE3A.js");
49739
+ const { sendMessageWhatsApp } = await import("./web-C0-NYLoG.js");
49740
49740
  return await sendMessageWhatsApp(...args);
49741
49741
  },
49742
49742
  sendMessageTelegram: async (...args) => {
49743
- const { sendMessageTelegram } = await import("./send-ByKJYHWg.js").then((n) => n.l);
49743
+ const { sendMessageTelegram } = await import("./send-BNdapfcg.js").then((n) => n.l);
49744
49744
  return await sendMessageTelegram(...args);
49745
49745
  },
49746
49746
  sendMessageDiscord: async (...args) => {
49747
- const { sendMessageDiscord } = await import("./send-3ea6pkzH.js").then((n) => n.t);
49747
+ const { sendMessageDiscord } = await import("./send-D6tzL2Tv.js").then((n) => n.t);
49748
49748
  return await sendMessageDiscord(...args);
49749
49749
  },
49750
49750
  sendMessageSlack: async (...args) => {
49751
- const { sendMessageSlack } = await import("./send-CPUILfmc.js").then((n) => n.n);
49751
+ const { sendMessageSlack } = await import("./send-C1F31aYA.js").then((n) => n.n);
49752
49752
  return await sendMessageSlack(...args);
49753
49753
  },
49754
49754
  sendMessageSignal: async (...args) => {
49755
- const { sendMessageSignal } = await import("./send-2sCLgOVr.js").then((n) => n.i);
49755
+ const { sendMessageSignal } = await import("./send-DvBDdcQr.js").then((n) => n.i);
49756
49756
  return await sendMessageSignal(...args);
49757
49757
  },
49758
49758
  sendMessageIMessage: async (...args) => {
49759
- const { sendMessageIMessage } = await import("./send-DNUVC_tJ.js").then((n) => n.n);
49759
+ const { sendMessageIMessage } = await import("./send-B6BrpfcR.js").then((n) => n.n);
49760
49760
  return await sendMessageIMessage(...args);
49761
49761
  }
49762
49762
  };
@@ -52632,7 +52632,7 @@ function createDiscordGatewayPlugin(params) {
52632
52632
  super(options);
52633
52633
  }
52634
52634
  createWebSocket(url) {
52635
- return new WebSocket$1(url, { agent });
52635
+ return new WebSocket(url, { agent });
52636
52636
  }
52637
52637
  }
52638
52638
  return new ProxyGatewayPlugin();
@@ -54154,7 +54154,7 @@ const DEFAULT_ACCOUNT_ID = "default";
54154
54154
  function readFileIfExists(filePath) {
54155
54155
  if (!filePath) return;
54156
54156
  try {
54157
- return fsSync.readFileSync(filePath, "utf-8").trim();
54157
+ return fs$1.readFileSync(filePath, "utf-8").trim();
54158
54158
  } catch {
54159
54159
  return;
54160
54160
  }
@@ -54717,7 +54717,7 @@ async function downloadLineMedia(messageId, channelAccessToken, maxBytes = 10 *
54717
54717
  prefix: "line-media",
54718
54718
  extension: getExtensionForContentType(contentType)
54719
54719
  });
54720
- await fsSync.promises.writeFile(filePath, buffer);
54720
+ await fs$1.promises.writeFile(filePath, buffer);
54721
54721
  logVerbose(`line: downloaded media ${messageId} to ${filePath} (${buffer.length} bytes)`);
54722
54722
  return {
54723
54723
  path: filePath,
@@ -59704,7 +59704,7 @@ function readSlackExternalArgMenuToken(raw) {
59704
59704
  }
59705
59705
  let commandsRegistry;
59706
59706
  async function getCommandsRegistry() {
59707
- if (!commandsRegistry) commandsRegistry = await import("./commands-registry-C1TEcrP2.js").then((n) => n.n);
59707
+ if (!commandsRegistry) commandsRegistry = await import("./commands-registry-B6FYKIxi.js").then((n) => n.n);
59708
59708
  return commandsRegistry;
59709
59709
  }
59710
59710
  function encodeSlackCommandArgValue(parts) {
@@ -60046,11 +60046,11 @@ async function registerSlackMonitorSlashCommands(params) {
60046
60046
  const channelName = channelInfo?.name;
60047
60047
  const roomLabel = channelName ? `#${channelName}` : `#${command.channel_id}`;
60048
60048
  const [{ resolveAgentRoute }, { finalizeInboundContext }, { dispatchReplyWithDispatcher }] = await Promise.all([
60049
- import("./resolve-route-BQouUsWd.js").then((n) => n.r),
60049
+ import("./resolve-route-ClURVRZM.js").then((n) => n.r),
60050
60050
  import("./inbound-context-CzKsDFGL.js").then((n) => n.n),
60051
60051
  Promise.resolve().then(() => provider_dispatcher_exports)
60052
60052
  ]);
60053
- const [{ resolveConversationLabel }, { createReplyPrefixOptions }] = await Promise.all([import("./conversation-label-BeLJTciU.js").then((n) => n.t), import("./reply-prefix-DhPco1Lk.js").then((n) => n.n)]);
60053
+ const [{ resolveConversationLabel }, { createReplyPrefixOptions }] = await Promise.all([import("./conversation-label-BeLJTciU.js").then((n) => n.t), import("./reply-prefix-BaCBHwi7.js").then((n) => n.n)]);
60054
60054
  const route = resolveAgentRoute({
60055
60055
  cfg,
60056
60056
  channel: "slack",
@@ -60107,9 +60107,9 @@ async function registerSlackMonitorSlashCommands(params) {
60107
60107
  });
60108
60108
  const deliverSlashPayloads = async (replies) => {
60109
60109
  const [{ deliverSlackSlashReplies }, { resolveChunkMode }, { resolveMarkdownTableMode }] = await Promise.all([
60110
- import("./replies-C3QP8Fs6.js").then((n) => n.r),
60111
- import("./chunk-DoTNWpve.js").then((n) => n.s),
60112
- import("./markdown-tables-1wSxjPR8.js").then((n) => n.t)
60110
+ import("./replies-BJH3pQXJ.js").then((n) => n.r),
60111
+ import("./chunk-TRVny4T1.js").then((n) => n.s),
60112
+ import("./markdown-tables-DO9qAEKa.js").then((n) => n.t)
60113
60113
  ]);
60114
60114
  await deliverSlackSlashReplies({
60115
60115
  replies,
@@ -60162,7 +60162,7 @@ async function registerSlackMonitorSlashCommands(params) {
60162
60162
  let nativeCommands = [];
60163
60163
  if (nativeEnabled) {
60164
60164
  reg = await getCommandsRegistry();
60165
- const skillCommands = nativeSkillsEnabled ? (await import("./skill-commands-IxgOIsIT.js").then((n) => n.a)).listSkillCommandsForAgents({ cfg }) : [];
60165
+ const skillCommands = nativeSkillsEnabled ? (await import("./skill-commands-DVss6_wi.js").then((n) => n.a)).listSkillCommandsForAgents({ cfg }) : [];
60166
60166
  nativeCommands = reg.listNativeCommandSpecsForConfig(cfg, {
60167
60167
  skillCommands,
60168
60168
  provider: "slack"
@@ -62380,7 +62380,7 @@ const buildTelegramMessageContext = async ({ primaryCtx, allMedia, storeAllowFro
62380
62380
  const hasAudio = allMedia.some((media) => media.contentType?.startsWith("audio/"));
62381
62381
  let preflightTranscript;
62382
62382
  if (isGroup && requireMention && hasAudio && !hasUserText && mentionRegexes.length > 0) try {
62383
- const { transcribeFirstAudio } = await import("./audio-preflight-EwgV_X7F.js");
62383
+ const { transcribeFirstAudio } = await import("./audio-preflight-DrLN-6C1.js");
62384
62384
  preflightTranscript = await transcribeFirstAudio({
62385
62385
  ctx: {
62386
62386
  MediaPaths: allMedia.length > 0 ? allMedia.map((m) => m.path) : void 0,
@@ -64546,23 +64546,23 @@ let webLoginQrPromise = null;
64546
64546
  let webChannelPromise = null;
64547
64547
  let whatsappActionsPromise = null;
64548
64548
  function loadWebOutbound() {
64549
- webOutboundPromise ??= import("./outbound-BI27cc0j.js").then((n) => n.t);
64549
+ webOutboundPromise ??= import("./outbound-CthSjSDV.js").then((n) => n.t);
64550
64550
  return webOutboundPromise;
64551
64551
  }
64552
64552
  function loadWebLogin() {
64553
- webLoginPromise ??= import("./login-CHBdSags.js").then((n) => n.n);
64553
+ webLoginPromise ??= import("./login-DGwFcNWz.js").then((n) => n.n);
64554
64554
  return webLoginPromise;
64555
64555
  }
64556
64556
  function loadWebLoginQr() {
64557
- webLoginQrPromise ??= import("./login-qr-Ch834jRc.js");
64557
+ webLoginQrPromise ??= import("./login-qr-IWLbGrDP.js");
64558
64558
  return webLoginQrPromise;
64559
64559
  }
64560
64560
  function loadWebChannel() {
64561
- webChannelPromise ??= import("./web-CXDGlE3A.js");
64561
+ webChannelPromise ??= import("./web-C0-NYLoG.js");
64562
64562
  return webChannelPromise;
64563
64563
  }
64564
64564
  function loadWhatsAppActions() {
64565
- whatsappActionsPromise ??= import("./whatsapp-actions-CLGSXEPl.js");
64565
+ whatsappActionsPromise ??= import("./whatsapp-actions-CgowK4CW.js");
64566
64566
  return whatsappActionsPromise;
64567
64567
  }
64568
64568
  function createPluginRuntime() {
@@ -64783,7 +64783,7 @@ const resolvePluginSdkAliasFile = (params) => {
64783
64783
  const srcCandidate = path.join(cursor, "src", "plugin-sdk", params.srcFile);
64784
64784
  const distCandidate = path.join(cursor, "dist", "plugin-sdk", params.distFile);
64785
64785
  const orderedCandidates = isTest ? [distCandidate, srcCandidate] : [distCandidate];
64786
- for (const candidate of orderedCandidates) if (fsSync.existsSync(candidate)) return candidate;
64786
+ for (const candidate of orderedCandidates) if (fs$1.existsSync(candidate)) return candidate;
64787
64787
  const parent = path.dirname(cursor);
64788
64788
  if (parent === cursor) break;
64789
64789
  cursor = parent;
@@ -65841,7 +65841,7 @@ async function recordLoopOutcome(args) {
65841
65841
  if (!args.ctx?.sessionKey) return;
65842
65842
  try {
65843
65843
  const { getDiagnosticSessionState } = await import("./diagnostic-session-state-DmrztgHU.js").then((n) => n.n);
65844
- const { recordToolCallOutcome } = await import("./tool-loop-detection-DDnbw1kC.js");
65844
+ const { recordToolCallOutcome } = await import("./tool-loop-detection-BjQsVGUc.js");
65845
65845
  recordToolCallOutcome(getDiagnosticSessionState({
65846
65846
  sessionKey: args.ctx.sessionKey,
65847
65847
  sessionId: args.ctx?.agentId
@@ -65862,8 +65862,8 @@ async function runBeforeToolCallHook(args) {
65862
65862
  const params = args.params;
65863
65863
  if (args.ctx?.sessionKey) {
65864
65864
  const { getDiagnosticSessionState } = await import("./diagnostic-session-state-DmrztgHU.js").then((n) => n.n);
65865
- const { logToolLoopAction } = await import("./diagnostic-D8zLma7p.js").then((n) => n.n);
65866
- const { detectToolCallLoop, recordToolCall } = await import("./tool-loop-detection-DDnbw1kC.js");
65865
+ const { logToolLoopAction } = await import("./diagnostic-CoT2YQH4.js").then((n) => n.n);
65866
+ const { detectToolCallLoop, recordToolCall } = await import("./tool-loop-detection-BjQsVGUc.js");
65867
65867
  const sessionState = getDiagnosticSessionState({
65868
65868
  sessionKey: args.ctx.sessionKey,
65869
65869
  sessionId: args.ctx?.agentId
@@ -68392,8 +68392,8 @@ async function readWorkspaceContextForSummary() {
68392
68392
  const workspaceDir = process.cwd();
68393
68393
  const agentsPath = path.join(workspaceDir, "AGENTS.md");
68394
68394
  try {
68395
- if (!fsSync.existsSync(agentsPath)) return "";
68396
- const sections = extractSections(await fsSync.promises.readFile(agentsPath, "utf-8"), ["Session Startup", "Red Lines"]);
68395
+ if (!fs$1.existsSync(agentsPath)) return "";
68396
+ const sections = extractSections(await fs$1.promises.readFile(agentsPath, "utf-8"), ["Session Startup", "Red Lines"]);
68397
68397
  if (sections.length === 0) return "";
68398
68398
  const combined = sections.join("\n\n");
68399
68399
  return `\n\n<workspace-critical-rules>\n${combined.length > MAX_SUMMARY_CONTEXT_CHARS ? combined.slice(0, MAX_SUMMARY_CONTEXT_CHARS) + "\n...[truncated]..." : combined}\n</workspace-critical-rules>`;
@@ -69722,7 +69722,7 @@ async function compactEmbeddedPiSessionDirect(params) {
69722
69722
  if (!apiKeyInfo.apiKey) {
69723
69723
  if (apiKeyInfo.mode !== "aws-sdk") throw new Error(`No API key resolved for provider "${model.provider}" (auth mode: ${apiKeyInfo.mode}).`);
69724
69724
  } else if (model.provider === "github-copilot") {
69725
- const { resolveCopilotApiToken } = await import("./github-copilot-token-Bu5FPDAY.js").then((n) => n.n);
69725
+ const { resolveCopilotApiToken } = await import("./github-copilot-token-BQ98eazZ.js").then((n) => n.n);
69726
69726
  const copilotToken = await resolveCopilotApiToken({ githubToken: apiKeyInfo.apiKey });
69727
69727
  authStorage.setRuntimeApiKey(model.provider, copilotToken.token);
69728
69728
  } else authStorage.setRuntimeApiKey(model.provider, apiKeyInfo.apiKey);
@@ -70940,11 +70940,11 @@ function appendRawStream(payload) {
70940
70940
  if (!rawStreamReady) {
70941
70941
  rawStreamReady = true;
70942
70942
  try {
70943
- fsSync.mkdirSync(path.dirname(RAW_STREAM_PATH), { recursive: true });
70943
+ fs$1.mkdirSync(path.dirname(RAW_STREAM_PATH), { recursive: true });
70944
70944
  } catch {}
70945
70945
  }
70946
70946
  try {
70947
- fsSync.promises.appendFile(RAW_STREAM_PATH, `${JSON.stringify(payload)}\n`);
70947
+ fs$1.promises.appendFile(RAW_STREAM_PATH, `${JSON.stringify(payload)}\n`);
70948
70948
  } catch {}
70949
70949
  }
70950
70950
 
@@ -74154,7 +74154,7 @@ async function runEmbeddedPiAgent(params) {
74154
74154
  return;
74155
74155
  }
74156
74156
  if (model.provider === "github-copilot") {
74157
- const { resolveCopilotApiToken } = await import("./github-copilot-token-Bu5FPDAY.js").then((n) => n.n);
74157
+ const { resolveCopilotApiToken } = await import("./github-copilot-token-BQ98eazZ.js").then((n) => n.n);
74158
74158
  const copilotToken = await resolveCopilotApiToken({ githubToken: apiKeyInfo.apiKey });
74159
74159
  authStorage.setRuntimeApiKey(model.provider, copilotToken.token);
74160
74160
  } else authStorage.setRuntimeApiKey(model.provider, apiKeyInfo.apiKey);