@bitseek/claw 1.3.1 → 1.3.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 (164) hide show
  1. package/dist/{accounts-BTexwKe8.js → accounts-CX1yOBOk.js} +1 -1
  2. package/dist/{accounts-ubG6irXZ.js → accounts-CaiECgq3.js} +16 -16
  3. package/dist/{accounts-CFz9Jc5d.js → accounts-DZqwa5NK.js} +1 -1
  4. package/dist/{active-listener-Hd9sOu9T.js → active-listener-neKWQsOO.js} +1 -1
  5. package/dist/{agent-scope-C6hps0r3.js → agent-scope-CTbRzU1C.js} +4 -4
  6. package/dist/{api-key-rotation-WzOC5dTW.js → api-key-rotation-BTSy5kZN.js} +2 -2
  7. package/dist/{audio-preflight-BWOdDA2n.js → audio-preflight-DZWb0ozj.js} +39 -39
  8. package/dist/{audio-transcription-runner-DaoqvWoi.js → audio-transcription-runner-2dp0SxL3.js} +11 -11
  9. package/dist/{bindings-CsIiIjqN.js → bindings-Daa-Etag.js} +2 -2
  10. package/dist/build-info.json +3 -3
  11. package/dist/bundled/boot-md/handler.js +65 -65
  12. package/dist/bundled/bootstrap-extra-files/handler.js +7 -7
  13. package/dist/bundled/command-logger/handler.js +2 -2
  14. package/dist/bundled/session-memory/handler.js +65 -65
  15. package/dist/canvas-host/a2ui/.bundle.hash +1 -1
  16. package/dist/{plugin-sdk/channel-activity-DAEbma-o.js → channel-activity-Btz1t5_1.js} +3 -3
  17. package/dist/{chrome-CjTE-vWv.js → chrome-DX1blHAJ.js} +18 -18
  18. package/dist/{chunk-DtYb6TYl.js → chunk-DEkdXze6.js} +1 -1
  19. package/dist/{commands-registry-NIsv9Z4R.js → commands-registry-BQkQRhEo.js} +5 -5
  20. package/dist/control-ui/assets/{index-DeYOAwUj.js → index-DIyxgivc.js} +420 -417
  21. package/dist/control-ui/assets/index-DIyxgivc.js.map +1 -0
  22. package/dist/control-ui/assets/index-EvU5ZebS.css +1 -0
  23. package/dist/control-ui/index.html +2 -2
  24. package/dist/{deliver-xY3h9X6N.js → deliver-C82Egs0W.js} +22 -22
  25. package/dist/{diagnostic-BO1GQJJf.js → diagnostic-DpOlXoSr.js} +2 -2
  26. package/dist/{dock-Cr9V9V1V.js → dock-DWqb4ufG.js} +6 -6
  27. package/dist/{env-DNMZEG57.js → env-Bn6pmvjK.js} +2 -2
  28. package/dist/{errors-DEkWxItM.js → errors-azBrKJmF.js} +1 -1
  29. package/dist/{fetch--iXu7oa7.js → fetch-B82CeaHJ.js} +5 -5
  30. package/dist/{fetch-guard-CNvY0vzQ.js → fetch-guard-CCLWHwu7.js} +2 -2
  31. package/dist/{frontmatter-DIRc-IR1.js → frontmatter-5U1LYLH9.js} +2 -2
  32. package/dist/{fs-safe-D8x_nIIA.js → fs-safe-BDR6eQAw.js} +4 -4
  33. package/dist/{github-copilot-token-DLGN-8YS.js → github-copilot-token-CPjAmbfr.js} +7 -7
  34. package/dist/{image-DCyaYY2d.js → image-BQ1JgwZu.js} +6 -6
  35. package/dist/{image-ops-DCpyia_K.js → image-ops-jvmQoiyw.js} +1 -1
  36. package/dist/{internal-hooks-yQe6H47q.js → internal-hooks-oLQ2m8YT.js} +1 -1
  37. package/dist/{ir-BZUjdf-6.js → ir-BODD8g-I.js} +6 -6
  38. package/dist/llm-slug-generator.js +65 -65
  39. package/dist/{plugin-sdk/logger-Cr-x0vMf.js → logger-DelEB7MK.js} +1 -1
  40. package/dist/{login-CgEHUE7h.js → login-Cm2zDfEU.js} +6 -6
  41. package/dist/{login-qr-DUJfhbUe.js → login-qr-iS1jPDpP.js} +13 -13
  42. package/dist/{manager-BNuB9clC.js → manager-DdzkWOvc.js} +15 -15
  43. package/dist/{markdown-tables-BHONoo6S.js → markdown-tables-pfs_NCNh.js} +1 -1
  44. package/dist/{plugin-sdk/message-channel-CvNq-esz.js → message-channel-POuk6EOq.js} +1 -1
  45. package/dist/{model-selection-D_Si2Ict.js → model-selection-DfZMxaX3.js} +44 -44
  46. package/dist/{outbound-DOVV_R6m.js → outbound-4q4mbU-Z.js} +7 -7
  47. package/dist/{outbound-attachment-C7sJLSnv.js → outbound-attachment-CBCp1oVQ.js} +2 -2
  48. package/dist/{path-alias-guards-CKjKIhQ3.js → path-alias-guards-DfQIjfhB.js} +1 -1
  49. package/dist/{paths-Cpu0XgUj.js → paths-BZO1jkK2.js} +3 -3
  50. package/dist/{paths-aGRLvQx9.js → paths-DKuX7-1L.js} +5 -5
  51. package/dist/{pi-embedded-BgVoy_Nm.js → pi-embedded-BhZNT6T-.js} +178 -178
  52. package/dist/{pi-embedded-helpers-CMTVhLjq.js → pi-embedded-helpers-CuwhW4u9.js} +29 -29
  53. package/dist/{pi-model-discovery-DCIw1y1c.js → pi-model-discovery-COjkql-U.js} +7 -7
  54. package/dist/plugin-sdk/{accounts-COLYAAOx.js → accounts-4WE2wtsW.js} +1 -1
  55. package/dist/plugin-sdk/{accounts-BZrkOo6-.js → accounts-AbI8uETR.js} +1 -1
  56. package/dist/plugin-sdk/{accounts-D_pT5EjF.js → accounts-BYcizTXn.js} +3 -3
  57. package/dist/plugin-sdk/{active-listener-DxBXcWm_.js → active-listener-pnqLAUOh.js} +1 -1
  58. package/dist/plugin-sdk/{agent-scope-DT5pxpJB.js → agent-scope-_j3fIYCK.js} +3 -3
  59. package/dist/plugin-sdk/{api-key-rotation-Dl6Ad7Nj.js → api-key-rotation-CYI51U_M.js} +2 -2
  60. package/dist/plugin-sdk/{audio-preflight-CkPj4OVY.js → audio-preflight-BTRRjPew.js} +33 -33
  61. package/dist/plugin-sdk/{audio-transcription-runner-BBn9jEMg.js → audio-transcription-runner-DFZS7uCO.js} +10 -10
  62. package/dist/plugin-sdk/{bindings-BSfhEjKN.js → bindings-CxxzC7gn.js} +2 -2
  63. package/dist/{channel-activity-D81g48kD.js → plugin-sdk/channel-activity-B3yZ-f-m.js} +3 -3
  64. package/dist/plugin-sdk/{channel-web-BaFUnG0F.js → channel-web-C521hZcX.js} +23 -23
  65. package/dist/plugin-sdk/{chrome-Dn0G4NoF.js → chrome-oPevdeh5.js} +7 -7
  66. package/dist/plugin-sdk/{chunk-cvtXztAT.js → chunk-BPyPeheZ.js} +1 -1
  67. package/dist/plugin-sdk/{command-format-BOJz3y1v.js → command-format-DvyMEXQo.js} +1 -1
  68. package/dist/plugin-sdk/{commands-registry-CZWv_JwZ.js → commands-registry-Dk8re8Lz.js} +5 -5
  69. package/dist/plugin-sdk/{config-DAwOhnVF.js → config-D7I2_X4P.js} +10 -10
  70. package/dist/plugin-sdk/{deliver-PdH-MCq8.js → deliver-NrIHn0__.js} +11 -11
  71. package/dist/plugin-sdk/{diagnostic-BZvj-qNu.js → diagnostic-DL3k_wRi.js} +2 -2
  72. package/dist/plugin-sdk/{dock-BdR3OYZn.js → dock-CjdkiLH7.js} +6 -6
  73. package/dist/plugin-sdk/{errors-jusxdu7M.js → errors-DFTN4h2I.js} +1 -1
  74. package/dist/plugin-sdk/{fetch-guard-Dary6WwJ.js → fetch-guard-BivEyA4v.js} +2 -2
  75. package/dist/plugin-sdk/{fs-safe-DMCE0ej9.js → fs-safe-B256n7Ff.js} +3 -3
  76. package/dist/plugin-sdk/{image-B3A2l2ep.js → image-CkPzr3XN.js} +6 -6
  77. package/dist/plugin-sdk/{image-ops-DulHE5Qc.js → image-ops-C9GXWF3o.js} +1 -1
  78. package/dist/plugin-sdk/index.js +64 -64
  79. package/dist/plugin-sdk/{ir-BFXiJrsN.js → ir-BIm-jvIK.js} +6 -6
  80. package/dist/plugin-sdk/{local-roots-DssN60r6.js → local-roots-2AOXGUXW.js} +4 -4
  81. package/dist/{logger-BlH5MJiV.js → plugin-sdk/logger-CNhs9eKJ.js} +1 -1
  82. package/dist/plugin-sdk/{login-D0ul3-6C.js → login-BcLiF9tC.js} +6 -6
  83. package/dist/plugin-sdk/{login-qr-XWKTFBuI.js → login-qr-GyPUodKJ.js} +9 -9
  84. package/dist/plugin-sdk/{manager-DGx_cF54.js → manager-DYLqNUb4.js} +10 -10
  85. package/dist/plugin-sdk/{markdown-tables-CsQpDNU5.js → markdown-tables-D9mmqMKi.js} +1 -1
  86. package/dist/{message-channel-Dl8dSs0T.js → plugin-sdk/message-channel-_CEZcqxE.js} +1 -1
  87. package/dist/plugin-sdk/{outbound-D29FHlQl.js → outbound-DdTsUaXa.js} +7 -7
  88. package/dist/plugin-sdk/{outbound-attachment-DRHrZUOx.js → outbound-attachment--hkuIDR1.js} +2 -2
  89. package/dist/plugin-sdk/{path-alias-guards-DpKV1B5p.js → path-alias-guards-BqUCBfUg.js} +1 -1
  90. package/dist/plugin-sdk/{pi-embedded-helpers-CKEUWckk.js → pi-embedded-helpers-CTfvZz83.js} +17 -17
  91. package/dist/plugin-sdk/{pi-model-discovery-BPeQq9XM.js → pi-model-discovery-CK3Ih_kq.js} +1 -1
  92. package/dist/plugin-sdk/{plugins-DF_dKXTR.js → plugins-BpHAMNJ1.js} +6 -6
  93. package/dist/plugin-sdk/{proxy-BfmEDoun.js → proxy-BJdRZOnJ.js} +1 -1
  94. package/dist/plugin-sdk/{proxy-fetch-BpHIgvBk.js → proxy-fetch-jmbopGcm.js} +1 -1
  95. package/dist/plugin-sdk/{pw-ai-BmmXDjtm.js → pw-ai-D0Kx7w1D.js} +13 -13
  96. package/dist/plugin-sdk/{qmd-manager-3hQbqkm5.js → qmd-manager-BDcutPp9.js} +8 -8
  97. package/dist/plugin-sdk/{query-expansion-BOGLUWB7.js → query-expansion-C_X8SyEA.js} +2 -2
  98. package/dist/{redact-ScShueoF.js → plugin-sdk/redact-DH8u23pF.js} +1 -1
  99. package/dist/plugin-sdk/{registry-Cv-oHUj1.js → registry-HF8_S7QO.js} +2 -2
  100. package/dist/plugin-sdk/{replies-CddwWBTJ.js → replies-DbjvV4gf.js} +3 -3
  101. package/dist/plugin-sdk/{reply-BCRC0yeW.js → reply-Czob6ZQ0.js} +93 -93
  102. package/dist/plugin-sdk/{reply-prefix-DXthVxCx.js → reply-prefix-KODsMNJ-.js} +1 -1
  103. package/dist/plugin-sdk/{resolve-outbound-target-D3Y4F2Le.js → resolve-outbound-target-BPT4aNiD.js} +2 -2
  104. package/dist/plugin-sdk/{resolve-route-DuwYYn4a.js → resolve-route-De2B5QY_.js} +4 -4
  105. package/dist/plugin-sdk/{retry-BMcrIz7L.js → retry-pZ8iKytf.js} +1 -1
  106. package/dist/plugin-sdk/{send-D0AaWnIj.js → send-1uW-uqPf.js} +7 -7
  107. package/dist/plugin-sdk/{send-C5USYGq7.js → send-BoNw1Bki.js} +8 -8
  108. package/dist/plugin-sdk/{send-B0ztz6QC.js → send-C-Rd2stz.js} +6 -6
  109. package/dist/plugin-sdk/{send-DJzwu8kk.js → send-CZIN8SDx.js} +15 -15
  110. package/dist/plugin-sdk/{send-DEyQJTzd.js → send-wCqsQs_s.js} +10 -10
  111. package/dist/plugin-sdk/{session-meta-ChWvKVWj.js → session-meta-7J-uHiM_.js} +1 -1
  112. package/dist/plugin-sdk/{session-BA7tVDpV.js → session-ooYcB82T.js} +5 -5
  113. package/dist/plugin-sdk/{sessions-BXps6YzJ.js → sessions-lAIo5l8W.js} +6 -6
  114. package/dist/plugin-sdk/{skill-commands-B20uUsji.js → skill-commands-D1Q6hGS4.js} +5 -5
  115. package/dist/plugin-sdk/{skills-DXOTei42.js → skills-BWSDv2F_.js} +8 -8
  116. package/dist/plugin-sdk/{ssrf-Doxv9M7Q.js → ssrf-JKDwTi8i.js} +1 -1
  117. package/dist/plugin-sdk/{store-BZbE1V-C.js → store-BMeqzQAf.js} +2 -2
  118. package/dist/plugin-sdk/{subsystem-CM1s2lDT.js → subsystem-B0V8LFBA.js} +2 -2
  119. package/dist/plugin-sdk/{tables-BhH8EIqU.js → tables-DCSeBGBz.js} +1 -1
  120. package/dist/{target-errors-B9Jzop3d.js → plugin-sdk/target-errors-0u6pegQv.js} +2 -2
  121. package/dist/{tokens-B9EDT4jv.js → plugin-sdk/tokens-DF2_VTJy.js} +1 -1
  122. package/dist/{tool-images-ffdfBx0b.js → plugin-sdk/tool-images-BbsgbHMZ.js} +2 -2
  123. package/dist/plugin-sdk/{tool-loop-detection-CygMSQUK.js → tool-loop-detection-JkCpGrfk.js} +2 -2
  124. package/dist/plugin-sdk/{utils-BcL6KGZf.js → utils-BfVxx6bk.js} +1 -1
  125. package/dist/plugin-sdk/web-D_qaocWb.js +72 -0
  126. package/dist/plugin-sdk/{whatsapp-actions-CRean1yN.js → whatsapp-actions-tVcrGNQc.js} +25 -25
  127. package/dist/{plugins-CJoaoIHc.js → plugins-D63QYxW6.js} +11 -11
  128. package/dist/{proxy-env-BnDt8j9F.js → proxy-env-vYAjKL5q.js} +1 -1
  129. package/dist/{proxy-fetch-xlbVQYN_.js → proxy-fetch-AvkSvetA.js} +1 -1
  130. package/dist/{proxy-DfJJLvch.js → proxy-jINniQBi.js} +1 -1
  131. package/dist/{pw-ai-DGwA7iCM.js → pw-ai-BLNiRUPI.js} +17 -17
  132. package/dist/{qmd-manager-CeN3N992.js → qmd-manager-BBKfRzj-.js} +11 -11
  133. package/dist/{query-expansion-CGnW4Mk_.js → query-expansion-2BrixCA2.js} +5 -5
  134. package/dist/{plugin-sdk/redact-BOuKZWXa.js → redact-uUggP88O.js} +1 -1
  135. package/dist/{registry-CJCkqTms.js → registry-C2GEGa2t.js} +3 -3
  136. package/dist/{replies-BFYGUEKu.js → replies-yAf6dFeT.js} +3 -3
  137. package/dist/{reply-prefix-DK1i6bCJ.js → reply-prefix-9mzt89Cf.js} +1 -1
  138. package/dist/{resolve-route-C5hVstLo.js → resolve-route-BNElrVxR.js} +4 -4
  139. package/dist/{retry-DTeP7C3h.js → retry-Ayb7e4XG.js} +1 -1
  140. package/dist/{send-B4pSMBHk.js → send-Bclgg0Ur.js} +8 -8
  141. package/dist/{send-BqKSZyIb.js → send-Bjaa69Cy.js} +27 -27
  142. package/dist/{send-V3fEVmLq.js → send-Cp0yQi_p.js} +10 -10
  143. package/dist/{send-XAO1mk64.js → send-DQ7hIAIK.js} +7 -7
  144. package/dist/{send-CN0f1Yst.js → send-DYY51FOR.js} +6 -6
  145. package/dist/{session-xKPVUYQP.js → session-TVb8hgJP.js} +9 -9
  146. package/dist/{session-meta-Cqv55kSk.js → session-meta-CyQWVUk4.js} +2 -2
  147. package/dist/{sessions-CA_BydGA.js → sessions-3jroJwu7.js} +31 -31
  148. package/dist/{skill-commands-CZFmIM-s.js → skill-commands-CSr9_48V.js} +9 -9
  149. package/dist/{skills-DMmr25nW.js → skills-B82IjVxn.js} +22 -22
  150. package/dist/{store-C8KgeMt2.js → store-DhC72KqW.js} +2 -2
  151. package/dist/{subsystem-BRjuJbbM.js → subsystem-CAatx5oo.js} +14 -14
  152. package/dist/{tables-BKnPZssn.js → tables-Bfh_TnCf.js} +1 -1
  153. package/dist/{plugin-sdk/target-errors-QZay02Cv.js → target-errors-CGYXYvSZ.js} +2 -2
  154. package/dist/{plugin-sdk/tokens-DIE-Bf72.js → tokens-BvzZdrVJ.js} +1 -1
  155. package/dist/{plugin-sdk/tool-images-heXfaJdb.js → tool-images-CqsWnc1k.js} +2 -2
  156. package/dist/{tool-loop-detection-CLoYKYIq.js → tool-loop-detection-C4V990MS.js} +3 -3
  157. package/dist/{utils-BFZnl-5N.js → utils-Bo1RFF0l.js} +6 -6
  158. package/dist/{web-C1PpWeXj.js → web-DQzzt8wj.js} +69 -69
  159. package/dist/{whatsapp-actions-CHt12z-f.js → whatsapp-actions-DXjy9m41.js} +28 -28
  160. package/dist/{workspace-D6mrCnXi.js → workspace-CswOYN9T.js} +21 -21
  161. package/package.json +1 -1
  162. package/dist/control-ui/assets/index-Ck63PFX9.css +0 -1
  163. package/dist/control-ui/assets/index-DeYOAwUj.js.map +0 -1
  164. package/dist/plugin-sdk/web-BDHHRoXS.js +0 -72
@@ -1,90 +1,90 @@
1
1
  import { t as __exportAll } from "./rolldown-runtime-Cbj13DAv.js";
2
- import { c as resolveDefaultAgentId, d as resolveSessionAgentId, f as resolveSessionAgentIds, g as toAgentModelListLike, h as resolveAgentModelPrimaryValue, i as resolveAgentDir, l as resolveEffectiveModelFallbacks, m as resolveAgentModelFallbackValues, n as listAgentIds, o as resolveAgentSkillsFilter, r as resolveAgentConfig, s as resolveAgentWorkspaceDir, t as hasConfiguredModelFallbacks, u as resolveRunModelFallbacksOverride } from "./agent-scope-C6hps0r3.js";
3
- import { a as resolveGatewayPort, c as resolveStateDir, d as resolveRequiredHomeDir, l as expandHomePrefix, n as STATE_DIR, p as resolveCliName, r as resolveConfigPath } from "./paths-aGRLvQx9.js";
4
- import { C as normalizeLogLevel, E as consumeRootOptionToken, T as FLAG_TERMINATOR, _ as isRich, a as clearActiveProgressLine, c as danger, f as setVerbose, g as colorize, h as warn, i as defaultRuntime, o as registerActiveProgressLine, p as shouldLogVerbose, r as createNonExitingRuntime, s as unregisterActiveProgressLine, t as createSubsystemLogger, u as logVerbose, v as theme, w as resolvePreferredOpenClawTmpDir, y as getChildLogger } from "./subsystem-BRjuJbbM.js";
2
+ import { c as resolveDefaultAgentId, d as resolveSessionAgentId, f as resolveSessionAgentIds, g as toAgentModelListLike, h as resolveAgentModelPrimaryValue, i as resolveAgentDir, l as resolveEffectiveModelFallbacks, m as resolveAgentModelFallbackValues, n as listAgentIds, o as resolveAgentSkillsFilter, r as resolveAgentConfig, s as resolveAgentWorkspaceDir, t as hasConfiguredModelFallbacks, u as resolveRunModelFallbacksOverride } from "./agent-scope-CTbRzU1C.js";
3
+ import { a as resolveGatewayPort, c as resolveStateDir, d as resolveRequiredHomeDir, l as expandHomePrefix, n as STATE_DIR, p as resolveCliName, r as resolveConfigPath } from "./paths-DKuX7-1L.js";
4
+ import { C as normalizeLogLevel, E as consumeRootOptionToken, T as FLAG_TERMINATOR, _ as isRich, a as clearActiveProgressLine, c as danger, f as setVerbose, g as colorize, h as warn, i as defaultRuntime, o as registerActiveProgressLine, p as shouldLogVerbose, r as createNonExitingRuntime, s as unregisterActiveProgressLine, t as createSubsystemLogger, u as logVerbose, v as theme, w as resolvePreferredOpenClawTmpDir, y as getChildLogger } from "./subsystem-CAatx5oo.js";
5
5
  import { C as resolveThreadParentSessionKey, S as parseAgentSessionKey, _ as deriveSessionChatType, b as isCronSessionKey, c as normalizeAgentId, d as resolveThreadSessionKeys, f as sanitizeAgentId, g as isBlockedObjectKey, h as normalizeOptionalAccountId, l as normalizeMainKey, m as normalizeAccountId$2, o as classifySessionKeyShape, p as DEFAULT_ACCOUNT_ID, r as buildAgentMainSessionKey, s as isValidAgentId, t as DEFAULT_AGENT_ID, u as resolveAgentIdFromSessionKey, v as getSubagentDepth, x as isSubagentSessionKey, y as isAcpSessionKey } from "./session-key-a6av96Fj.js";
6
- import { C as isPlainObject, S as truncateUtf16Safe, _ as shortenHomeInString, a as ensureDir$3, b as sliceUtf16Safe, c as isRecord$1, d as normalizeE164, h as resolveUserPath, o as escapeRegExp, r as clampInt, s as formatTerminalLink, t as CONFIG_DIR, v as shortenHomePath, y as sleep$1 } from "./utils-BFZnl-5N.js";
7
- import { C as openBoundaryFileSync, M as normalizeWindowsPathForComparison, S as openBoundaryFile, a as DEFAULT_IDENTITY_FILENAME, b as spawnWithFallback, f as loadWorkspaceBootstrapFiles, g as resolveOpenClawPackageRoot, l as ensureAgentWorkspace, m as resolveWorkspaceAttachmentsRoot, n as DEFAULT_AGENT_WORKSPACE_DIR, r as DEFAULT_BOOTSTRAP_FILENAME, u as filterBootstrapFilesForSession, v as runCommandWithTimeout, y as runExec } from "./workspace-D6mrCnXi.js";
8
- import { i as logWarn, n as logError, r as logInfo, t as logDebug } from "./logger-BlH5MJiV.js";
9
- import { $t as extractShellWrapperInlineCommand, A as resolveApiKeyForProvider, An as withFileLock, At as resolveEffectiveEnableState, B as resolveApiKeyForProfile, Bn as DEFAULT_PROVIDER, Bt as getTrustedSafeBinDirs, C as buildAssistantMessage, Cn as resolveOwnerDisplaySetting, Ct as validateJsonSchemaValue, D as getApiKeyForModel, Dn as ensureAuthProfileStore, Dt as safeStatSync, E as buildUsageWithNoCost, En as markAuthProfileGood, Et as isPathInside, F as getSoonestCooldownExpiry, Ft as unsetConfigOverride, G as resolveConfigSnapshotHash, Gt as analyzeShellCommand, H as loadConfig, Ht as listWritableExplicitTrustedSafeBinDirs, I as isProfileInCooldown, In as normalizeSecretInput, It as getConfigValueAtPath, J as TELEGRAM_COMMAND_NAME_PATTERN, Jt as splitCommandChain, K as writeConfigFile, Kt as buildEnforcedShellCommand, L as markAuthProfileFailure, Ln as splitTrailingAuthProfile, Lt as parseConfigPath, M as resolveModelAuthMode, Mt as getConfigOverrides, Nt as resetConfigOverrides, O as getCustomProviderApiKey, On as resolveAuthStorePathForDisplay, Ot as applyTestPluginDefaults, P as resolveAuthProfileOrder, Pn as resolveAuthProfileDisplayLabel, Pt as setConfigOverride, Q as isInboundPathAllowed, Qt as resolveCommandResolutionFromArgv, R as markAuthProfileUsed, Rn as DEFAULT_CONTEXT_TOKENS, Rt as setConfigValueAtPath, S as createOllamaStreamFn, Sn as isDangerousHostEnvVarName, St as isSupportedLocalAvatarExtension, T as buildStreamErrorAssistantMessage, Tn as listProfilesForProvider, Tt as discoverOpenClawPlugins, U as readConfigFileSnapshot, Ut as normalizeTrustedSafeBinDirs, Vt as isTrustedSafeBinPath, Wt as validateSafeBinArgv, X as resolveTelegramCustomCommands, Xt as matchAllowlist, Y as normalizeTelegramCommandName, Yt as DEFAULT_SAFE_BINS, Zt as resolveAllowlistCandidatePath, _n as DEFAULT_SUBAGENT_MAX_SPAWN_DEPTH, a as isCliProvider, an as SAFE_BIN_PROFILES, at as parseDurationMs, bn as getShellPathFromLoginShell, bt as isAvatarHttpUrl, c as normalizeProviderId, cn as applyMergePatch, d as resolveDefaultModelForAgent, dn as resolveDiscordPreviewStreamMode, en as isDispatchWrapperExecutable, et as resolveIMessageAttachmentRoots, f as resolveModelRefFromString, fn as resolveSlackNativeStreaming, h as resolveThinkingDefault, i as findNormalizedProviderValue, in as splitShellArgs, j as resolveEnvApiKey, jt as resolveMemorySlotDecision, k as requireApiKey, kn as resolveOpenClawAgentDir, kt as normalizePluginsConfig, ln as isSafeExecutableValue, m as resolveSubagentSpawnModelSelection, n as buildConfiguredAllowlistKeys, nn as unwrapKnownDispatchWrapperInvocation, nt as normalizeScpRemoteHost, o as modelKey, on as normalizeSafeBinProfileFixtures, p as resolveReasoningDefault, pn as resolveSlackStreamingMode, q as validateConfigObjectWithPlugins, qt as isWindowsPlatform, r as buildModelAliasIndex, rn as unwrapKnownShellMultiplexerInvocation, rt as parseNonNegativeByteSize, s as normalizeModelRef$2, sn as resolveSafeBinProfiles, t as buildAllowedModelSet, tn as isShellWrapperExecutable, tt as resolveIMessageRemoteAttachmentRoots, u as resolveConfiguredModelRef, un as mapStreamingModeToSlackLegacyDraftStreamMode, vn as resolveAgentMaxConcurrent, vt as AVATAR_MAX_BYTES, w as buildAssistantMessageWithZeroUsage, wn as dedupeProfileIds, wt as loadPluginManifestRegistry, x as OLLAMA_NATIVE_BASE_URL, xn as resolveShellEnvFallbackTimeoutMs, xt as isPathWithinRoot, yn as VERSION, yt as isAvatarDataUrl, z as resolveProfilesUnavailableReason, zn as DEFAULT_MODEL, zt as unsetConfigValueAtPath } from "./model-selection-D_Si2Ict.js";
10
- import { a as saveJsonFile, i as loadJsonFile } from "./github-copilot-token-DLGN-8YS.js";
11
- import { n as formatCliCommand, t as isTruthyEnvValue } from "./env-DNMZEG57.js";
6
+ import { C as isPlainObject, S as truncateUtf16Safe, _ as shortenHomeInString, a as ensureDir$3, b as sliceUtf16Safe, c as isRecord$1, d as normalizeE164, h as resolveUserPath, o as escapeRegExp, r as clampInt, s as formatTerminalLink, t as CONFIG_DIR, v as shortenHomePath, y as sleep$1 } from "./utils-Bo1RFF0l.js";
7
+ import { C as openBoundaryFileSync, M as normalizeWindowsPathForComparison, S as openBoundaryFile, a as DEFAULT_IDENTITY_FILENAME, b as spawnWithFallback, f as loadWorkspaceBootstrapFiles, g as resolveOpenClawPackageRoot, l as ensureAgentWorkspace, m as resolveWorkspaceAttachmentsRoot, n as DEFAULT_AGENT_WORKSPACE_DIR, r as DEFAULT_BOOTSTRAP_FILENAME, u as filterBootstrapFilesForSession, v as runCommandWithTimeout, y as runExec } from "./workspace-CswOYN9T.js";
8
+ import { i as logWarn, n as logError, r as logInfo, t as logDebug } from "./logger-DelEB7MK.js";
9
+ import { $t as extractShellWrapperInlineCommand, A as resolveApiKeyForProvider, An as withFileLock, At as resolveEffectiveEnableState, B as resolveApiKeyForProfile, Bn as DEFAULT_PROVIDER, Bt as getTrustedSafeBinDirs, C as buildAssistantMessage, Cn as resolveOwnerDisplaySetting, Ct as validateJsonSchemaValue, D as getApiKeyForModel, Dn as ensureAuthProfileStore, Dt as safeStatSync, E as buildUsageWithNoCost, En as markAuthProfileGood, Et as isPathInside, F as getSoonestCooldownExpiry, Ft as unsetConfigOverride, G as resolveConfigSnapshotHash, Gt as analyzeShellCommand, H as loadConfig, Ht as listWritableExplicitTrustedSafeBinDirs, I as isProfileInCooldown, In as normalizeSecretInput, It as getConfigValueAtPath, J as TELEGRAM_COMMAND_NAME_PATTERN, Jt as splitCommandChain, K as writeConfigFile, Kt as buildEnforcedShellCommand, L as markAuthProfileFailure, Ln as splitTrailingAuthProfile, Lt as parseConfigPath, M as resolveModelAuthMode, Mt as getConfigOverrides, Nt as resetConfigOverrides, O as getCustomProviderApiKey, On as resolveAuthStorePathForDisplay, Ot as applyTestPluginDefaults, P as resolveAuthProfileOrder, Pn as resolveAuthProfileDisplayLabel, Pt as setConfigOverride, Q as isInboundPathAllowed, Qt as resolveCommandResolutionFromArgv, R as markAuthProfileUsed, Rn as DEFAULT_CONTEXT_TOKENS, Rt as setConfigValueAtPath, S as createOllamaStreamFn, Sn as isDangerousHostEnvVarName, St as isSupportedLocalAvatarExtension, T as buildStreamErrorAssistantMessage, Tn as listProfilesForProvider, Tt as discoverOpenClawPlugins, U as readConfigFileSnapshot, Ut as normalizeTrustedSafeBinDirs, Vt as isTrustedSafeBinPath, Wt as validateSafeBinArgv, X as resolveTelegramCustomCommands, Xt as matchAllowlist, Y as normalizeTelegramCommandName, Yt as DEFAULT_SAFE_BINS, Zt as resolveAllowlistCandidatePath, _n as DEFAULT_SUBAGENT_MAX_SPAWN_DEPTH, a as isCliProvider, an as SAFE_BIN_PROFILES, at as parseDurationMs, bn as getShellPathFromLoginShell, bt as isAvatarHttpUrl, c as normalizeProviderId, cn as applyMergePatch, d as resolveDefaultModelForAgent, dn as resolveDiscordPreviewStreamMode, en as isDispatchWrapperExecutable, et as resolveIMessageAttachmentRoots, f as resolveModelRefFromString, fn as resolveSlackNativeStreaming, h as resolveThinkingDefault, i as findNormalizedProviderValue, in as splitShellArgs, j as resolveEnvApiKey, jt as resolveMemorySlotDecision, k as requireApiKey, kn as resolveOpenClawAgentDir, kt as normalizePluginsConfig, ln as isSafeExecutableValue, m as resolveSubagentSpawnModelSelection, n as buildConfiguredAllowlistKeys, nn as unwrapKnownDispatchWrapperInvocation, nt as normalizeScpRemoteHost, o as modelKey, on as normalizeSafeBinProfileFixtures, p as resolveReasoningDefault, pn as resolveSlackStreamingMode, q as validateConfigObjectWithPlugins, qt as isWindowsPlatform, r as buildModelAliasIndex, rn as unwrapKnownShellMultiplexerInvocation, rt as parseNonNegativeByteSize, s as normalizeModelRef$2, sn as resolveSafeBinProfiles, t as buildAllowedModelSet, tn as isShellWrapperExecutable, tt as resolveIMessageRemoteAttachmentRoots, u as resolveConfiguredModelRef, un as mapStreamingModeToSlackLegacyDraftStreamMode, vn as resolveAgentMaxConcurrent, vt as AVATAR_MAX_BYTES, w as buildAssistantMessageWithZeroUsage, wn as dedupeProfileIds, wt as loadPluginManifestRegistry, x as OLLAMA_NATIVE_BASE_URL, xn as resolveShellEnvFallbackTimeoutMs, xt as isPathWithinRoot, yn as VERSION, yt as isAvatarDataUrl, z as resolveProfilesUnavailableReason, zn as DEFAULT_MODEL, zt as unsetConfigValueAtPath } from "./model-selection-DfZMxaX3.js";
10
+ import { a as saveJsonFile, i as loadJsonFile } from "./github-copilot-token-CPjAmbfr.js";
11
+ import { n as formatCliCommand, t as isTruthyEnvValue } from "./env-Bn6pmvjK.js";
12
12
  import { t as parseBooleanValue$1 } from "./boolean-mcn6kL0s.js";
13
- import { a as triggerInternalHook, t as createInternalHookEvent } from "./internal-hooks-yQe6H47q.js";
14
- import { _ as getPluginCommandSpecs, a as normalizeAnyChannelId, c as getActivePluginRegistry, d as requireActivePluginRegistry, f as setActivePluginRegistry, g as executePluginCommand, h as clearPluginCommands, i as listChatChannels, l as getActivePluginRegistryKey, m as normalizePluginHttpPath, n as CHAT_CHANNEL_ORDER, o as normalizeChannelId$1, p as createPluginRegistry, r as getChatChannelMeta, s as normalizeChatChannelId, v as listPluginCommands, y as matchPluginCommand } from "./registry-CJCkqTms.js";
13
+ import { a as triggerInternalHook, t as createInternalHookEvent } from "./internal-hooks-oLQ2m8YT.js";
14
+ import { _ as getPluginCommandSpecs, a as normalizeAnyChannelId, c as getActivePluginRegistry, d as requireActivePluginRegistry, f as setActivePluginRegistry, g as executePluginCommand, h as clearPluginCommands, i as listChatChannels, l as getActivePluginRegistryKey, m as normalizePluginHttpPath, n as CHAT_CHANNEL_ORDER, o as normalizeChannelId$1, p as createPluginRegistry, r as getChatChannelMeta, s as normalizeChatChannelId, v as listPluginCommands, y as matchPluginCommand } from "./registry-C2GEGa2t.js";
15
15
  import { n as MANIFEST_KEY } from "./legacy-names-CaxS8pq2.js";
16
- import { a as resolveChannelGroupRequireMention, c as normalizeHyphenSlug, i as resolveChannelGroupPolicy, l as normalizeStringEntries, n as listChannelDocks, o as resolveChannelGroupToolsPolicy, r as normalizeSignalMessagingTarget, s as normalizeAtHashSlug, t as getChannelDock, u as normalizeStringEntriesLower } from "./dock-Cr9V9V1V.js";
16
+ import { a as resolveChannelGroupRequireMention, c as normalizeHyphenSlug, i as resolveChannelGroupPolicy, l as normalizeStringEntries, n as listChannelDocks, o as resolveChannelGroupToolsPolicy, r as normalizeSignalMessagingTarget, s as normalizeAtHashSlug, t as getChannelDock, u as normalizeStringEntriesLower } from "./dock-DWqb4ufG.js";
17
17
  import { t as runTasksWithConcurrency } from "./run-with-concurrency-NY-gTuzr.js";
18
- import { a as stripSilentToken, i as isSilentReplyText, n as SILENT_REPLY_TOKEN, r as isSilentReplyPrefixText, t as HEARTBEAT_TOKEN } from "./tokens-B9EDT4jv.js";
19
- import { _ as resolveDiscordAccount, a as normalizeWhatsAppTarget, c as listTelegramAccountIds, d as resolveSlackAccount, f as resolveSlackReplyToMode, g as listEnabledDiscordAccounts, h as createDiscordActionGate, i as isWhatsAppGroupJid, l as resolveTelegramAccount, m as resolveSlackBotToken, n as listChannelPlugins, o as createTelegramActionGate, p as resolveSlackAppToken, r as normalizeChannelId$2, s as listEnabledTelegramAccounts, t as getChannelPlugin, u as resolveTelegramToken, v as normalizeDiscordToken } from "./plugins-CJoaoIHc.js";
20
- import { a as logWebSelfId, i as getWebAuthAgeMs, m as webAuthExists, n as resolveWhatsAppAccount, o as logoutWeb, t as hasAnyWhatsAppAuth, u as readWebSelfId } from "./accounts-ubG6irXZ.js";
18
+ import { a as stripSilentToken, i as isSilentReplyText, n as SILENT_REPLY_TOKEN, r as isSilentReplyPrefixText, t as HEARTBEAT_TOKEN } from "./tokens-BvzZdrVJ.js";
19
+ import { _ as resolveDiscordAccount, a as normalizeWhatsAppTarget, c as listTelegramAccountIds, d as resolveSlackAccount, f as resolveSlackReplyToMode, g as listEnabledDiscordAccounts, h as createDiscordActionGate, i as isWhatsAppGroupJid, l as resolveTelegramAccount, m as resolveSlackBotToken, n as listChannelPlugins, o as createTelegramActionGate, p as resolveSlackAppToken, r as normalizeChannelId$2, s as listEnabledTelegramAccounts, t as getChannelPlugin, u as resolveTelegramToken, v as normalizeDiscordToken } from "./plugins-D63QYxW6.js";
20
+ import { a as logWebSelfId, i as getWebAuthAgeMs, m as webAuthExists, n as resolveWhatsAppAccount, o as logoutWeb, t as hasAnyWhatsAppAuth, u as readWebSelfId } from "./accounts-CaiECgq3.js";
21
21
  import { t as resolveAccountEntry } from "./account-lookup-JrULBwdR.js";
22
22
  import { t as normalizeChatType } from "./chat-type-DKb2TlGZ.js";
23
- import { t as buildChannelAccountBindings } from "./bindings-CsIiIjqN.js";
24
- import { a as createSlackWebClient, c as validateSlackBlocksArray, d as resolveSlackChannelId, i as normalizeSlackOutboundText, l as buildSlackBlocksFallbackText, o as resolveSlackWebClientOptions, s as parseSlackBlocksInput, t as sendMessageSlack, u as parseSlackTarget } from "./send-B4pSMBHk.js";
25
- import { $ as fetchChannelPermissionsDiscord, A as unpinMessageDiscord, B as listScheduledEventsDiscord, C as editMessageDiscord, Ct as resolveTimestampMs, D as pinMessageDiscord, Dt as normalizeChannelSlug, E as listThreadsDiscord, Et as buildChannelKeyCandidates, F as fetchMemberInfoDiscord, G as uploadStickerDiscord, H as timeoutMemberDiscord, I as fetchRoleInfoDiscord, J as editChannelDiscord, K as createChannelDiscord, L as fetchVoiceStatusDiscord, M as banMemberDiscord, N as createScheduledEventDiscord, O as readMessagesDiscord, Ot as resolveChannelEntryMatchWithFallback, P as fetchChannelInfoDiscord, Q as stripUndefinedFields, R as kickMemberDiscord, S as deleteMessageDiscord, St as resolveDiscordSystemLocation, T as listPinsDiscord, Tt as applyChannelMatchMeta, U as listGuildEmojisDiscord, V as removeRoleDiscord, W as uploadEmojiDiscord, X as removeChannelPermissionDiscord, Y as moveChannelDiscord, Z as setChannelPermissionDiscord, _ as sendPollDiscord, _t as resolveDiscordShouldRequireMention, a as removeReactionDiscord, at as resolveDiscordChannelId, b as sendWebhookMessageDiscord, bt as formatDiscordReactionEmoji, c as formatDiscordComponentEventText, ct as isDiscordGroupAllowedByPolicy, d as parseDiscordModalCustomId, dt as resolveDiscordAllowListMatch, et as hasAnyGuildPermissionDiscord, f as parseDiscordModalCustomIdForCarbon, ft as resolveDiscordChannelConfigWithFallback, g as sendMessageDiscord, gt as resolveDiscordOwnerAllowFrom, h as resolveDiscordModalEntry, ht as resolveDiscordOwnerAccess, i as removeOwnReactionsDiscord, it as parseDiscordTarget, j as addRoleDiscord, k as searchMessagesDiscord, l as parseDiscordComponentCustomId, lt as normalizeDiscordAllowList, m as resolveDiscordComponentEntry, mt as resolveDiscordMemberAccessState, n as fetchReactionsDiscord, nt as createDiscordClient, o as sendDiscordComponentMessage, ot as listDiscordDirectoryGroupsLive, p as readDiscordComponentSpec, pt as resolveDiscordGuildEntry, q as deleteChannelDiscord, r as reactMessageDiscord, rt as createDiscordRestClient, s as createDiscordFormModal, st as listDiscordDirectoryPeersLive, tt as chunkDiscordTextWithMode, u as parseDiscordComponentCustomIdForCarbon, ut as normalizeDiscordSlug, v as sendStickerDiscord, vt as resolveGroupDmAllow, w as fetchMessageDiscord, wt as fetchDiscord, x as createThreadDiscord, xt as formatDiscordUserTag, y as sendVoiceMessageDiscord, yt as shouldEmitDiscordReactionNotification, z as listGuildChannelsDiscord } from "./send-V3fEVmLq.js";
23
+ import { t as buildChannelAccountBindings } from "./bindings-Daa-Etag.js";
24
+ import { a as createSlackWebClient, c as validateSlackBlocksArray, d as resolveSlackChannelId, i as normalizeSlackOutboundText, l as buildSlackBlocksFallbackText, o as resolveSlackWebClientOptions, s as parseSlackBlocksInput, t as sendMessageSlack, u as parseSlackTarget } from "./send-Bclgg0Ur.js";
25
+ import { $ as fetchChannelPermissionsDiscord, A as unpinMessageDiscord, B as listScheduledEventsDiscord, C as editMessageDiscord, Ct as resolveTimestampMs, D as pinMessageDiscord, Dt as normalizeChannelSlug, E as listThreadsDiscord, Et as buildChannelKeyCandidates, F as fetchMemberInfoDiscord, G as uploadStickerDiscord, H as timeoutMemberDiscord, I as fetchRoleInfoDiscord, J as editChannelDiscord, K as createChannelDiscord, L as fetchVoiceStatusDiscord, M as banMemberDiscord, N as createScheduledEventDiscord, O as readMessagesDiscord, Ot as resolveChannelEntryMatchWithFallback, P as fetchChannelInfoDiscord, Q as stripUndefinedFields, R as kickMemberDiscord, S as deleteMessageDiscord, St as resolveDiscordSystemLocation, T as listPinsDiscord, Tt as applyChannelMatchMeta, U as listGuildEmojisDiscord, V as removeRoleDiscord, W as uploadEmojiDiscord, X as removeChannelPermissionDiscord, Y as moveChannelDiscord, Z as setChannelPermissionDiscord, _ as sendPollDiscord, _t as resolveDiscordShouldRequireMention, a as removeReactionDiscord, at as resolveDiscordChannelId, b as sendWebhookMessageDiscord, bt as formatDiscordReactionEmoji, c as formatDiscordComponentEventText, ct as isDiscordGroupAllowedByPolicy, d as parseDiscordModalCustomId, dt as resolveDiscordAllowListMatch, et as hasAnyGuildPermissionDiscord, f as parseDiscordModalCustomIdForCarbon, ft as resolveDiscordChannelConfigWithFallback, g as sendMessageDiscord, gt as resolveDiscordOwnerAllowFrom, h as resolveDiscordModalEntry, ht as resolveDiscordOwnerAccess, i as removeOwnReactionsDiscord, it as parseDiscordTarget, j as addRoleDiscord, k as searchMessagesDiscord, l as parseDiscordComponentCustomId, lt as normalizeDiscordAllowList, m as resolveDiscordComponentEntry, mt as resolveDiscordMemberAccessState, n as fetchReactionsDiscord, nt as createDiscordClient, o as sendDiscordComponentMessage, ot as listDiscordDirectoryGroupsLive, p as readDiscordComponentSpec, pt as resolveDiscordGuildEntry, q as deleteChannelDiscord, r as reactMessageDiscord, rt as createDiscordRestClient, s as createDiscordFormModal, st as listDiscordDirectoryPeersLive, tt as chunkDiscordTextWithMode, u as parseDiscordComponentCustomIdForCarbon, ut as normalizeDiscordSlug, v as sendStickerDiscord, vt as resolveGroupDmAllow, w as fetchMessageDiscord, wt as fetchDiscord, x as createThreadDiscord, xt as formatDiscordUserTag, y as sendVoiceMessageDiscord, yt as shouldEmitDiscordReactionNotification, z as listGuildChannelsDiscord } from "./send-Cp0yQi_p.js";
26
26
  import { n as generateSecureUuid, t as generateSecureToken } from "./secure-random-CY3Mg7Dp.js";
27
- import { A as initializeGlobalHookRunner, C as shouldSuppressReasoningPayload, D as normalizeChannelTargetInput, E as buildTargetResolverSignature, O as normalizeTargetForProvider, S as shouldSuppressMessagingToolReplies, T as resolveReplyToMode, _ as applyReplyTagsToPayload, a as normalizeOutboundPayloadsForJson, b as filterMessagingToolMediaDuplicates, c as parseReplyDirectives, d as toInternalMessagePreprocessedContext, f as toInternalMessageReceivedContext, g as fireAndForgetHook, h as toPluginMessageReceivedEvent, i as normalizeOutboundPayloads, k as getGlobalHookRunner, l as splitMediaFromOutput, m as toPluginMessageContext, o as normalizeReplyPayloadsForDelivery, p as toInternalMessageTranscribedContext, r as formatOutboundPayloadLog, s as throwIfAborted, t as deliverOutboundPayloads, u as deriveInboundMessageHookContext, v as applyReplyThreading, w as createReplyToModeFilterForChannel, x as isRenderablePayload, y as filterMessagingToolDuplicates } from "./deliver-xY3h9X6N.js";
28
- 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-BO1GQJJf.js";
27
+ import { A as initializeGlobalHookRunner, C as shouldSuppressReasoningPayload, D as normalizeChannelTargetInput, E as buildTargetResolverSignature, O as normalizeTargetForProvider, S as shouldSuppressMessagingToolReplies, T as resolveReplyToMode, _ as applyReplyTagsToPayload, a as normalizeOutboundPayloadsForJson, b as filterMessagingToolMediaDuplicates, c as parseReplyDirectives, d as toInternalMessagePreprocessedContext, f as toInternalMessageReceivedContext, g as fireAndForgetHook, h as toPluginMessageReceivedEvent, i as normalizeOutboundPayloads, k as getGlobalHookRunner, l as splitMediaFromOutput, m as toPluginMessageContext, o as normalizeReplyPayloadsForDelivery, p as toInternalMessageTranscribedContext, r as formatOutboundPayloadLog, s as throwIfAborted, t as deliverOutboundPayloads, u as deriveInboundMessageHookContext, v as applyReplyThreading, w as createReplyToModeFilterForChannel, x as isRenderablePayload, y as filterMessagingToolDuplicates } from "./deliver-C82Egs0W.js";
28
+ 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-DpOlXoSr.js";
29
29
  import { r as getDiagnosticSessionState } from "./diagnostic-session-state-DBPrVBk3.js";
30
- import { n as resolveSignalAccount, t as listEnabledSignalAccounts } from "./accounts-BTexwKe8.js";
31
- import { $ as readChannelAllowFromStore, A as describeReplyTarget, B as resolveTelegramStreamMode, C as buildSenderLabel, D as buildTelegramParentPeer, E as buildTelegramGroupPeerId, F as resolveTelegramDirectPeerId, G as resolveSenderAllowMatch$1, H as isSenderAllowed$1, I as resolveTelegramForumThreadId, J as mergeDmAllowFromSources, K as firstDefined$1, L as resolveTelegramGroupAllowFromContext, M as extractTelegramLocation, N as hasBotMention, O as buildTelegramThreadParams, P as normalizeForwardedContext, Q as addChannelAllowFromStoreEntry, R as resolveTelegramMediaPlaceholder, S as buildGroupLabel, T as buildTelegramGroupFrom, U as normalizeAllowFrom$2, V as resolveTelegramThreadSpec, W as normalizeDmAllowFromWithStore$1, X as formatLocationText, Y as resolveGroupAllowFromSources, Z as toLocationContext, _ as resolveTelegramFetch, a as reactMessageTelegram, at as listPairingChannels, b as loadCronStore, c as sendStickerTelegram, ct as resolveTelegramTargetChatType, d as wasSentByBot, et as removeChannelAllowFromStoreEntry, f as isRecoverableTelegramNetworkError, g as wrapFileReferencesInHtml, h as renderTelegramHtmlText, i as editMessageTelegram, it as getPairingAdapter, j as expandTextLinks, k as buildTypingThreadParams, m as markdownToTelegramHtml, n as createForumTopicTelegram, nt as readJsonFileWithFallback, o as sendMessageTelegram, ot as isVoiceCompatibleAudio, p as markdownToTelegramChunks, q as isSenderIdAllowed, r as deleteMessageTelegram, rt as writeJsonFileAtomically, s as sendPollTelegram, st as parseTelegramTarget, t as buildInlineKeyboard, tt as upsertChannelPairingRequest, u as resolveTelegramVoiceSend, v as splitTelegramCaption, w as buildSenderName, x as resolveCronStorePath, y as withTelegramApiErrorLogging, z as resolveTelegramReplyId } from "./send-BqKSZyIb.js";
32
- import { c as detectMime, d as imageMimeFromFormat, f as isAudioFileName, g as MAX_IMAGE_BYTES, i as getImageMetadata, l as extensionForMime, m as kindFromMime, p as isGifMedia, s as resizeToJpeg, v as mediaKindFromMime } from "./image-ops-DCpyia_K.js";
33
- import { n as discoverModels, t as discoverAuthStorage } from "./pi-model-discovery-DCIw1y1c.js";
34
- 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-Dl8dSs0T.js";
35
- import { $ as mergeAlsoAllowPolicy, A as isRawApiErrorPayload, B as registerBrowserRoutes, C as isCloudCodeAssistFormatError, D as isFailoverErrorMessage, E as isFailoverAssistantError, F as sanitizeUserFacingText, G as resolveBrowserControlAuth, H as resolveProfile, I as ensureSandboxWorkspaceForSession, J as resolveSandboxConfigForAgent, K as resolveGatewayCredentialsFromConfig, L as resolveSandboxContext, M as isTransientHttpError, N as parseImageDimensionError, O as isLikelyContextOverflowError, P as parseImageSizeError, Q as expandPolicyWithPluginGroups, R as resolveSandboxRuntimeStatus, S as isBillingAssistantError, T as isContextOverflowError, U as getBridgeAuthForPort, V as resolveBrowserConfig, W as ensureBrowserControlAuth, X as buildPluginToolGroups, Y as applyOwnerOnlyToolPolicy, Z as collectExplicitAllowlist, _ as formatBillingErrorMessage, a as isMessagingToolDuplicateNormalized, at as matchesAnyGlobPattern, b as isAuthAssistantError, c as extractToolCallsFromAssistant, ct as resolveBootstrapMaxChars, d as downgradeOpenAIFunctionCallReasoningPairs, et as stripPluginOnlyAllowlist, f as downgradeOpenAIReasoningBlocks, g as formatAssistantErrorText, h as classifyFailoverReason, it as compileGlobPatterns, j as isTimeoutErrorMessage, k as isRateLimitAssistantError, l as extractToolResultId, lt as resolveBootstrapTotalMaxChars, m as BILLING_ERROR_USER_MESSAGE, n as validateGeminiTurns, nt as normalizeToolName, o as normalizeTextForComparison, ot as buildBootstrapContextFiles, p as isGoogleModelApi, q as trimToUndefined$1, r as pickFallbackThinkingLevel, rt as resolveToolProfilePolicy, s as sanitizeSessionMessagesImages, st as ensureSessionHeader, t as validateAnthropicTurns, tt as expandToolGroups, u as sanitizeToolCallIdsForCloudCodeAssist, ut as sanitizeGoogleTurnOrdering, v as formatRawAssistantErrorForUi, w as isCompactionFailureError, x as isAuthPermanentErrorMessage, y as getApiErrorPayloadFingerprint, z as createBrowserRouteContext } from "./pi-embedded-helpers-CMTVhLjq.js";
36
- import { A as rawDataToString, B as isSecureWebSocketUrl, C as ensureChromeExtensionRelayServer, N as DEFAULT_UPLOAD_DIR, P as resolveExistingPathsWithinRoot, U as DEFAULT_AI_SNAPSHOT_MAX_CHARS, s as resolveLsofCommandSync, z as isLoopbackHost } from "./chrome-CjTE-vWv.js";
37
- 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-DMmr25nW.js";
38
- import { t as PATH_ALIAS_POLICIES } from "./path-alias-guards-CKjKIhQ3.js";
39
- import { i as testRegexWithBoundedInput, r as compileSafeRegex, t as redactSensitiveText } from "./redact-ScShueoF.js";
40
- import { i as formatUncaughtError, o as readErrorName, r as formatErrorMessage } from "./errors-DEkWxItM.js";
41
- import { a as readFileWithinRoot, c as writeFileWithinRoot, i as openFileWithinRoot, n as copyFileWithinRoot, r as createRootScopedReadFile, t as SafeOpenError } from "./fs-safe-D8x_nIIA.js";
42
- import { a as isBlockedHostnameOrIp, c as normalizeHostname, n as SsrFBlockedError } from "./proxy-env-BnDt8j9F.js";
43
- import { i as saveMediaBuffer, r as getMediaDir, t as MEDIA_MAX_BYTES } from "./store-C8KgeMt2.js";
30
+ import { n as resolveSignalAccount, t as listEnabledSignalAccounts } from "./accounts-CX1yOBOk.js";
31
+ import { $ as readChannelAllowFromStore, A as describeReplyTarget, B as resolveTelegramStreamMode, C as buildSenderLabel, D as buildTelegramParentPeer, E as buildTelegramGroupPeerId, F as resolveTelegramDirectPeerId, G as resolveSenderAllowMatch$1, H as isSenderAllowed$1, I as resolveTelegramForumThreadId, J as mergeDmAllowFromSources, K as firstDefined$1, L as resolveTelegramGroupAllowFromContext, M as extractTelegramLocation, N as hasBotMention, O as buildTelegramThreadParams, P as normalizeForwardedContext, Q as addChannelAllowFromStoreEntry, R as resolveTelegramMediaPlaceholder, S as buildGroupLabel, T as buildTelegramGroupFrom, U as normalizeAllowFrom$2, V as resolveTelegramThreadSpec, W as normalizeDmAllowFromWithStore$1, X as formatLocationText, Y as resolveGroupAllowFromSources, Z as toLocationContext, _ as resolveTelegramFetch, a as reactMessageTelegram, at as listPairingChannels, b as loadCronStore, c as sendStickerTelegram, ct as resolveTelegramTargetChatType, d as wasSentByBot, et as removeChannelAllowFromStoreEntry, f as isRecoverableTelegramNetworkError, g as wrapFileReferencesInHtml, h as renderTelegramHtmlText, i as editMessageTelegram, it as getPairingAdapter, j as expandTextLinks, k as buildTypingThreadParams, m as markdownToTelegramHtml, n as createForumTopicTelegram, nt as readJsonFileWithFallback, o as sendMessageTelegram, ot as isVoiceCompatibleAudio, p as markdownToTelegramChunks, q as isSenderIdAllowed, r as deleteMessageTelegram, rt as writeJsonFileAtomically, s as sendPollTelegram, st as parseTelegramTarget, t as buildInlineKeyboard, tt as upsertChannelPairingRequest, u as resolveTelegramVoiceSend, v as splitTelegramCaption, w as buildSenderName, x as resolveCronStorePath, y as withTelegramApiErrorLogging, z as resolveTelegramReplyId } from "./send-Bjaa69Cy.js";
32
+ import { c as detectMime, d as imageMimeFromFormat, f as isAudioFileName, g as MAX_IMAGE_BYTES, i as getImageMetadata, l as extensionForMime, m as kindFromMime, p as isGifMedia, s as resizeToJpeg, v as mediaKindFromMime } from "./image-ops-jvmQoiyw.js";
33
+ import { n as discoverModels, t as discoverAuthStorage } from "./pi-model-discovery-COjkql-U.js";
34
+ 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-POuk6EOq.js";
35
+ import { $ as mergeAlsoAllowPolicy, A as isRawApiErrorPayload, B as registerBrowserRoutes, C as isCloudCodeAssistFormatError, D as isFailoverErrorMessage, E as isFailoverAssistantError, F as sanitizeUserFacingText, G as resolveBrowserControlAuth, H as resolveProfile, I as ensureSandboxWorkspaceForSession, J as resolveSandboxConfigForAgent, K as resolveGatewayCredentialsFromConfig, L as resolveSandboxContext, M as isTransientHttpError, N as parseImageDimensionError, O as isLikelyContextOverflowError, P as parseImageSizeError, Q as expandPolicyWithPluginGroups, R as resolveSandboxRuntimeStatus, S as isBillingAssistantError, T as isContextOverflowError, U as getBridgeAuthForPort, V as resolveBrowserConfig, W as ensureBrowserControlAuth, X as buildPluginToolGroups, Y as applyOwnerOnlyToolPolicy, Z as collectExplicitAllowlist, _ as formatBillingErrorMessage, a as isMessagingToolDuplicateNormalized, at as matchesAnyGlobPattern, b as isAuthAssistantError, c as extractToolCallsFromAssistant, ct as resolveBootstrapMaxChars, d as downgradeOpenAIFunctionCallReasoningPairs, et as stripPluginOnlyAllowlist, f as downgradeOpenAIReasoningBlocks, g as formatAssistantErrorText, h as classifyFailoverReason, it as compileGlobPatterns, j as isTimeoutErrorMessage, k as isRateLimitAssistantError, l as extractToolResultId, lt as resolveBootstrapTotalMaxChars, m as BILLING_ERROR_USER_MESSAGE, n as validateGeminiTurns, nt as normalizeToolName, o as normalizeTextForComparison, ot as buildBootstrapContextFiles, p as isGoogleModelApi, q as trimToUndefined$1, r as pickFallbackThinkingLevel, rt as resolveToolProfilePolicy, s as sanitizeSessionMessagesImages, st as ensureSessionHeader, t as validateAnthropicTurns, tt as expandToolGroups, u as sanitizeToolCallIdsForCloudCodeAssist, ut as sanitizeGoogleTurnOrdering, v as formatRawAssistantErrorForUi, w as isCompactionFailureError, x as isAuthPermanentErrorMessage, y as getApiErrorPayloadFingerprint, z as createBrowserRouteContext } from "./pi-embedded-helpers-CuwhW4u9.js";
36
+ import { A as rawDataToString, B as isSecureWebSocketUrl, C as ensureChromeExtensionRelayServer, N as DEFAULT_UPLOAD_DIR, P as resolveExistingPathsWithinRoot, U as DEFAULT_AI_SNAPSHOT_MAX_CHARS, s as resolveLsofCommandSync, z as isLoopbackHost } from "./chrome-DX1blHAJ.js";
37
+ 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-B82IjVxn.js";
38
+ import { t as PATH_ALIAS_POLICIES } from "./path-alias-guards-DfQIjfhB.js";
39
+ import { i as testRegexWithBoundedInput, r as compileSafeRegex, t as redactSensitiveText } from "./redact-uUggP88O.js";
40
+ import { i as formatUncaughtError, o as readErrorName, r as formatErrorMessage } from "./errors-azBrKJmF.js";
41
+ import { a as readFileWithinRoot, c as writeFileWithinRoot, i as openFileWithinRoot, n as copyFileWithinRoot, r as createRootScopedReadFile, t as SafeOpenError } from "./fs-safe-BDR6eQAw.js";
42
+ import { a as isBlockedHostnameOrIp, c as normalizeHostname, n as SsrFBlockedError } from "./proxy-env-vYAjKL5q.js";
43
+ import { i as saveMediaBuffer, r as getMediaDir, t as MEDIA_MAX_BYTES } from "./store-DhC72KqW.js";
44
44
  import { n as readJsonFile, r as writeJsonAtomic, t as createAsyncLock } from "./json-files-JTS4WE3P.js";
45
- import { A as resolveSessionKey, B as canonicalizeMainSessionAlias, C as extractToolCallNames, D as hasInterSessionUserProvenance, E as applyInputProvenanceToUserMessage, F as resolveThreadFlag, G as resolveGroupSessionKey, H as resolveExplicitAgentSessionKey, I as DEFAULT_RESET_TRIGGERS, K as acquireSessionWriteLock, L as mergeSessionEntry, M as resolveChannelResetConfig, N as resolveSessionResetPolicy, O as normalizeInputProvenance, P as resolveSessionResetType, R as resolveFreshSessionTotalTokens, S as countToolResults, T as INPUT_PROVENANCE_KIND_VALUES, U as resolveMainSessionKey, W as deriveSessionMetaPatch, _ as normalizeDeliveryContext, a as resolveAndPersistSessionFile, b as archiveSessionTranscripts, c as recordSessionMetaFromInbound, d as updateSessionStoreEntry, f as isCacheEnabled, g as mergeDeliveryContext, h as deliveryContextKey, j as evaluateSessionFreshness, k as jsonUtf8Bytes, l as updateLastRoute, m as deliveryContextFromSession, n as parseSessionThreadInfo, o as loadSessionStore, p as resolveCacheTtlMs$1, q as resolveSessionLockMaxHoldFromTimeout, r as appendAssistantMessageToSessionTranscript, s as readSessionUpdatedAt, t as extractDeliveryInfo, u as updateSessionStore, v as normalizeSessionDeliveryFields, w as parseInlineDirectives$1, x as capArrayByJsonBytes, y as normalizeAccountId$3, z as setSessionRuntimeModel } from "./sessions-CA_BydGA.js";
45
+ import { A as resolveSessionKey, B as canonicalizeMainSessionAlias, C as extractToolCallNames, D as hasInterSessionUserProvenance, E as applyInputProvenanceToUserMessage, F as resolveThreadFlag, G as resolveGroupSessionKey, H as resolveExplicitAgentSessionKey, I as DEFAULT_RESET_TRIGGERS, K as acquireSessionWriteLock, L as mergeSessionEntry, M as resolveChannelResetConfig, N as resolveSessionResetPolicy, O as normalizeInputProvenance, P as resolveSessionResetType, R as resolveFreshSessionTotalTokens, S as countToolResults, T as INPUT_PROVENANCE_KIND_VALUES, U as resolveMainSessionKey, W as deriveSessionMetaPatch, _ as normalizeDeliveryContext, a as resolveAndPersistSessionFile, b as archiveSessionTranscripts, c as recordSessionMetaFromInbound, d as updateSessionStoreEntry, f as isCacheEnabled, g as mergeDeliveryContext, h as deliveryContextKey, j as evaluateSessionFreshness, k as jsonUtf8Bytes, l as updateLastRoute, m as deliveryContextFromSession, n as parseSessionThreadInfo, o as loadSessionStore, p as resolveCacheTtlMs$1, q as resolveSessionLockMaxHoldFromTimeout, r as appendAssistantMessageToSessionTranscript, s as readSessionUpdatedAt, t as extractDeliveryInfo, u as updateSessionStore, v as normalizeSessionDeliveryFields, w as parseInlineDirectives$1, x as capArrayByJsonBytes, y as normalizeAccountId$3, z as setSessionRuntimeModel } from "./sessions-3jroJwu7.js";
46
46
  import { n as resolveConversationLabel } from "./conversation-label-CEQUZyFY.js";
47
- import { t as resolveIMessageAccount } from "./accounts-CFz9Jc5d.js";
48
- import { i as resolveSessionTranscriptPath, n as resolveSessionFilePath, o as resolveSessionTranscriptsDirForAgent, r as resolveSessionFilePathOptions, s as resolveStorePath, t as resolveDefaultSessionStorePath } from "./paths-Cpu0XgUj.js";
47
+ import { t as resolveIMessageAccount } from "./accounts-DZqwa5NK.js";
48
+ import { i as resolveSessionTranscriptPath, n as resolveSessionFilePath, o as resolveSessionTranscriptsDirForAgent, r as resolveSessionFilePathOptions, s as resolveStorePath, t as resolveDefaultSessionStorePath } from "./paths-BZO1jkK2.js";
49
49
  import { n as onSessionTranscriptUpdate, t as emitSessionTranscriptUpdate } from "./transcript-events-Cso7-m1w.js";
50
- import { a as canonicalizeBase64, i as resolveImageSanitizationLimits, n as sanitizeImageBlocks, o as estimateBase64DecodedBytes, r as sanitizeToolResultImages } from "./tool-images-ffdfBx0b.js";
50
+ import { a as canonicalizeBase64, i as resolveImageSanitizationLimits, n as sanitizeImageBlocks, o as estimateBase64DecodedBytes, r as sanitizeToolResultImages } from "./tool-images-CqsWnc1k.js";
51
51
  import { a as normalizeReasoningLevel, c as normalizeVerboseLevel, i as normalizeElevatedLevel, l as resolveResponseUsageMode, n as formatXHighModelHint, o as normalizeThinkLevel, s as normalizeUsageDisplay, t as formatThinkingLevels, u as supportsXHighThinking } from "./thinking-FnAYAFD8.js";
52
- import { C as extractTextFromChatContent, S as isInsideCode, T as ensureOpenClawModelsJson, _ as stripThinkingTagsFromText, a as decodeDataUrl, b as stripReasoningTagsFromText, c as extractAssistantThinking, d as formatReasoningMessage, f as inferToolMetaFromArgs, g as stripMinimaxToolCallXml, h as stripDowngradedToolCallText, i as coerceImageModelConfig, l as extractThinkingFromTaggedStream, m as promoteThinkingTagsToBlocks, o as resolveProviderVisionModelFromConfig, p as isAssistantMessage, r as coerceImageAssistantText, s as extractAssistantText$1, u as extractThinkingFromTaggedText, v as formatToolSummary, w as minimaxUnderstandImage, x as findCodeRegions, y as resolveToolDisplay } from "./image-DCyaYY2d.js";
53
- import { _ as resolveAttachmentKind, a as resolveAutoImageModel, b as modelSupportsVision, c as applyTemplate, d as normalizeMediaUnderstandingChatType, f as resolveMediaUnderstandingScope, h as registerUnhandledRejectionHandler, i as normalizeMediaAttachments, l as resolveConcurrency, m as buildRandomTempFilePath, n as buildProviderRegistry, o as resolveMediaAttachmentLocalRoots, p as CLI_OUTPUT_MAX_BUFFER, r as createMediaAttachmentCache, s as runCapability, t as runAudioTranscription, u as resolveTimeoutMs$2, v as findModelInCatalog, y as loadModelCatalog } from "./audio-transcription-runner-DaoqvWoi.js";
54
- import { a as getDefaultMediaLocalRoots, i as getAgentScopedMediaLocalRoots, n as fetchRemoteMedia, r as readResponseWithLimit, t as MediaFetchError } from "./fetch--iXu7oa7.js";
52
+ import { C as extractTextFromChatContent, S as isInsideCode, T as ensureOpenClawModelsJson, _ as stripThinkingTagsFromText, a as decodeDataUrl, b as stripReasoningTagsFromText, c as extractAssistantThinking, d as formatReasoningMessage, f as inferToolMetaFromArgs, g as stripMinimaxToolCallXml, h as stripDowngradedToolCallText, i as coerceImageModelConfig, l as extractThinkingFromTaggedStream, m as promoteThinkingTagsToBlocks, o as resolveProviderVisionModelFromConfig, p as isAssistantMessage, r as coerceImageAssistantText, s as extractAssistantText$1, u as extractThinkingFromTaggedText, v as formatToolSummary, w as minimaxUnderstandImage, x as findCodeRegions, y as resolveToolDisplay } from "./image-BQ1JgwZu.js";
53
+ import { _ as resolveAttachmentKind, a as resolveAutoImageModel, b as modelSupportsVision, c as applyTemplate, d as normalizeMediaUnderstandingChatType, f as resolveMediaUnderstandingScope, h as registerUnhandledRejectionHandler, i as normalizeMediaAttachments, l as resolveConcurrency, m as buildRandomTempFilePath, n as buildProviderRegistry, o as resolveMediaAttachmentLocalRoots, p as CLI_OUTPUT_MAX_BUFFER, r as createMediaAttachmentCache, s as runCapability, t as runAudioTranscription, u as resolveTimeoutMs$2, v as findModelInCatalog, y as loadModelCatalog } from "./audio-transcription-runner-2dp0SxL3.js";
54
+ import { a as getDefaultMediaLocalRoots, i as getAgentScopedMediaLocalRoots, n as fetchRemoteMedia, r as readResponseWithLimit, t as MediaFetchError } from "./fetch-B82CeaHJ.js";
55
55
  import { n as fetchWithTimeout, t as bindAbortRelay } from "./fetch-timeout-CYFFedEH.js";
56
- import { n as withStrictGuardedFetchMode, r as withTrustedEnvProxyGuardedFetchMode, t as fetchWithSsrFGuard } from "./fetch-guard-CNvY0vzQ.js";
57
- import { t as makeProxyFetch } from "./proxy-fetch-xlbVQYN_.js";
58
- import { a as resolveAgentIdentity, i as resolveAckReaction, o as resolveEffectiveMessagesConfig, r as resolveResponsePrefixTemplate, s as resolveHumanDelayConfig, t as createReplyPrefixOptions } from "./reply-prefix-DK1i6bCJ.js";
59
- 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-DtYb6TYl.js";
60
- import { n as resolveMarkdownTableMode } from "./markdown-tables-BHONoo6S.js";
61
- import { a as loadWebMedia, i as getDefaultLocalRoots, o as loadWebMediaRaw } from "./ir-BZUjdf-6.js";
62
- import { a as ToolInputError, c as imageResultFromFile, d as readNumberParam, f as readReactionParams, h as readStringParam, l as jsonResult, m as readStringOrNumberParam, n as missingTargetError, o as createActionGate, p as readStringArrayParam, r as unknownTargetError, s as imageResult, t as ambiguousTargetError, u as parseAvailableTags } from "./target-errors-B9Jzop3d.js";
63
- import { _ as isNativeCommandsExplicitlyDisabled, a as listChatCommands, b as resolveNativeSkillsEnabled, c as listNativeCommandSpecsForConfig, d as parseCommandArgs, f as resolveCommandArgChoices, g as isCommandFlagEnabled, h as shouldHandleTextCommands, i as isCommandEnabled, l as maybeResolveTextAlias, m as serializeCommandArgs, o as listChatCommandsForConfig, p as resolveCommandArgMenu, r as findCommandByNativeName, s as listNativeCommandSpecs, t as buildCommandTextFromArgs, u as normalizeCommandBody, v as isRestartEnabled, y as resolveNativeCommandsEnabled } from "./commands-registry-NIsv9Z4R.js";
64
- import { c as getSkillsSnapshotVersion, i as resolveSkillCommandInvocation, l as pruneExpiredPending, n as listSkillCommandsForAgents, o as getRemoteSkillEligibility, r as listSkillCommandsForWorkspace, s as ensureSkillsWatcher, t as listReservedChatSlashCommandNames, u as resolvePairingPaths } from "./skill-commands-CZFmIM-s.js";
56
+ import { n as withStrictGuardedFetchMode, r as withTrustedEnvProxyGuardedFetchMode, t as fetchWithSsrFGuard } from "./fetch-guard-CCLWHwu7.js";
57
+ import { t as makeProxyFetch } from "./proxy-fetch-AvkSvetA.js";
58
+ import { a as resolveAgentIdentity, i as resolveAckReaction, o as resolveEffectiveMessagesConfig, r as resolveResponsePrefixTemplate, s as resolveHumanDelayConfig, t as createReplyPrefixOptions } from "./reply-prefix-9mzt89Cf.js";
59
+ 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-DEkdXze6.js";
60
+ import { n as resolveMarkdownTableMode } from "./markdown-tables-pfs_NCNh.js";
61
+ import { a as loadWebMedia, i as getDefaultLocalRoots, o as loadWebMediaRaw } from "./ir-BODD8g-I.js";
62
+ import { a as ToolInputError, c as imageResultFromFile, d as readNumberParam, f as readReactionParams, h as readStringParam, l as jsonResult, m as readStringOrNumberParam, n as missingTargetError, o as createActionGate, p as readStringArrayParam, r as unknownTargetError, s as imageResult, t as ambiguousTargetError, u as parseAvailableTags } from "./target-errors-CGYXYvSZ.js";
63
+ import { _ as isNativeCommandsExplicitlyDisabled, a as listChatCommands, b as resolveNativeSkillsEnabled, c as listNativeCommandSpecsForConfig, d as parseCommandArgs, f as resolveCommandArgChoices, g as isCommandFlagEnabled, h as shouldHandleTextCommands, i as isCommandEnabled, l as maybeResolveTextAlias, m as serializeCommandArgs, o as listChatCommandsForConfig, p as resolveCommandArgMenu, r as findCommandByNativeName, s as listNativeCommandSpecs, t as buildCommandTextFromArgs, u as normalizeCommandBody, v as isRestartEnabled, y as resolveNativeCommandsEnabled } from "./commands-registry-BQkQRhEo.js";
64
+ import { c as getSkillsSnapshotVersion, i as resolveSkillCommandInvocation, l as pruneExpiredPending, n as listSkillCommandsForAgents, o as getRemoteSkillEligibility, r as listSkillCommandsForWorkspace, s as ensureSkillsWatcher, t as listReservedChatSlashCommandNames, u as resolvePairingPaths } from "./skill-commands-CSr9_48V.js";
65
65
  import { r as normalizeInboundTextNewlines, t as finalizeInboundContext } from "./inbound-context-D4jdbLFJ.js";
66
66
  import { n as wrapFetchWithAbortSignal, t as resolveFetch } from "./fetch-CIXnD4u2.js";
67
- import { n as retryAsync } from "./retry-DTeP7C3h.js";
67
+ import { n as retryAsync } from "./retry-Ayb7e4XG.js";
68
68
  import { n as recordCommandPoll, r as resetCommandPollCount } from "./command-poll-backoff-DYqTwyb3.js";
69
- import { n as recordChannelActivity, r as createDiscordRetryRunner, t as getChannelActivity } from "./channel-activity-D81g48kD.js";
69
+ import { n as recordChannelActivity, r as createDiscordRetryRunner, t as getChannelActivity } from "./channel-activity-Btz1t5_1.js";
70
70
  import { t as buildOutboundMediaLoadOptions } from "./load-options-xFTRYZAO.js";
71
71
  import { n as normalizePollInput } from "./polls-an_kOejR.js";
72
- import { t as convertMarkdownTables } from "./tables-BKnPZssn.js";
73
- import { a as resolveSignalRpcContext, c as streamSignalEvents, n as sendReadReceiptSignal, o as signalCheck, r as sendTypingSignal, s as signalRpcRequest, t as sendMessageSignal } from "./send-CN0f1Yst.js";
74
- 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-XAO1mk64.js";
75
- import { n as resolveAgentRoute, t as buildAgentSessionKey } from "./resolve-route-C5hVstLo.js";
76
- import { i as redactIdentifier, t as getActiveWebListener } from "./active-listener-Hd9sOu9T.js";
77
- import { a as createReplyReferencePlanner, i as resolveSlackThreadTs, n as deliverReplies$3, t as createSlackReplyDeliveryPlan } from "./replies-BFYGUEKu.js";
78
- import { t as recordInboundSessionMetaSafe } from "./session-meta-Cqv55kSk.js";
79
- import { n as resolveMemorySearchConfig } from "./manager-BNuB9clC.js";
80
- import { f as listMemoryFiles, p as normalizeExtraMemoryPaths } from "./query-expansion-CGnW4Mk_.js";
72
+ import { t as convertMarkdownTables } from "./tables-Bfh_TnCf.js";
73
+ import { a as resolveSignalRpcContext, c as streamSignalEvents, n as sendReadReceiptSignal, o as signalCheck, r as sendTypingSignal, s as signalRpcRequest, t as sendMessageSignal } from "./send-DYY51FOR.js";
74
+ 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-DQ7hIAIK.js";
75
+ import { n as resolveAgentRoute, t as buildAgentSessionKey } from "./resolve-route-BNElrVxR.js";
76
+ import { i as redactIdentifier, t as getActiveWebListener } from "./active-listener-neKWQsOO.js";
77
+ import { a as createReplyReferencePlanner, i as resolveSlackThreadTs, n as deliverReplies$3, t as createSlackReplyDeliveryPlan } from "./replies-yAf6dFeT.js";
78
+ import { t as recordInboundSessionMetaSafe } from "./session-meta-CyQWVUk4.js";
79
+ import { n as resolveMemorySearchConfig } from "./manager-DdzkWOvc.js";
80
+ import { f as listMemoryFiles, p as normalizeExtraMemoryPaths } from "./query-expansion-2BrixCA2.js";
81
81
  import { createRequire } from "node:module";
82
- import * as fs$1 from "node:fs/promises";
82
+ import * as fs$2 from "node:fs/promises";
83
83
  import fs from "node:fs/promises";
84
84
  import os, { homedir } from "node:os";
85
85
  import * as path$1 from "node:path";
86
86
  import path, { isAbsolute } from "node:path";
87
- import syncFs, { existsSync, mkdirSync, mkdtempSync, promises, readFileSync, renameSync, rmSync, statSync, unlinkSync, writeFileSync } from "node:fs";
87
+ import fs$1, { existsSync, mkdirSync, mkdtempSync, promises, readFileSync, renameSync, rmSync, statSync, unlinkSync, writeFileSync } from "node:fs";
88
88
  import JSON5 from "json5";
89
89
  import { inspect, promisify } from "node:util";
90
90
  import { execFile, execFileSync, spawn, spawnSync } from "node:child_process";
@@ -3302,7 +3302,7 @@ async function resolveOpenClawDocsPath(params) {
3302
3302
  const workspaceDir = params.workspaceDir?.trim();
3303
3303
  if (workspaceDir) {
3304
3304
  const workspaceDocs = path.join(workspaceDir, "docs");
3305
- if (syncFs.existsSync(workspaceDocs)) return workspaceDocs;
3305
+ if (fs$1.existsSync(workspaceDocs)) return workspaceDocs;
3306
3306
  }
3307
3307
  const packageRoot = await resolveOpenClawPackageRoot({
3308
3308
  cwd: params.cwd,
@@ -3311,7 +3311,7 @@ async function resolveOpenClawDocsPath(params) {
3311
3311
  });
3312
3312
  if (!packageRoot) return null;
3313
3313
  const packageDocs = path.join(packageRoot, "docs");
3314
- return syncFs.existsSync(packageDocs) ? packageDocs : null;
3314
+ return fs$1.existsSync(packageDocs) ? packageDocs : null;
3315
3315
  }
3316
3316
 
3317
3317
  //#endregion
@@ -6362,7 +6362,7 @@ function resolveDefaultIdentityPath() {
6362
6362
  return path.join(resolveStateDir(), "identity", "device.json");
6363
6363
  }
6364
6364
  function ensureDir$2(filePath) {
6365
- syncFs.mkdirSync(path.dirname(filePath), { recursive: true });
6365
+ fs$1.mkdirSync(path.dirname(filePath), { recursive: true });
6366
6366
  }
6367
6367
  const ED25519_SPKI_PREFIX = Buffer.from("302a300506032b6570032100", "hex");
6368
6368
  function base64UrlEncode(buf) {
@@ -6398,8 +6398,8 @@ function generateIdentity() {
6398
6398
  }
6399
6399
  function loadOrCreateDeviceIdentity(filePath = resolveDefaultIdentityPath()) {
6400
6400
  try {
6401
- if (syncFs.existsSync(filePath)) {
6402
- const raw = syncFs.readFileSync(filePath, "utf8");
6401
+ if (fs$1.existsSync(filePath)) {
6402
+ const raw = fs$1.readFileSync(filePath, "utf8");
6403
6403
  const parsed = JSON.parse(raw);
6404
6404
  if (parsed?.version === 1 && typeof parsed.deviceId === "string" && typeof parsed.publicKeyPem === "string" && typeof parsed.privateKeyPem === "string") {
6405
6405
  const derivedId = fingerprintPublicKey(parsed.publicKeyPem);
@@ -6408,9 +6408,9 @@ function loadOrCreateDeviceIdentity(filePath = resolveDefaultIdentityPath()) {
6408
6408
  ...parsed,
6409
6409
  deviceId: derivedId
6410
6410
  };
6411
- syncFs.writeFileSync(filePath, `${JSON.stringify(updated, null, 2)}\n`, { mode: 384 });
6411
+ fs$1.writeFileSync(filePath, `${JSON.stringify(updated, null, 2)}\n`, { mode: 384 });
6412
6412
  try {
6413
- syncFs.chmodSync(filePath, 384);
6413
+ fs$1.chmodSync(filePath, 384);
6414
6414
  } catch {}
6415
6415
  return {
6416
6416
  deviceId: derivedId,
@@ -6435,9 +6435,9 @@ function loadOrCreateDeviceIdentity(filePath = resolveDefaultIdentityPath()) {
6435
6435
  privateKeyPem: identity.privateKeyPem,
6436
6436
  createdAtMs: Date.now()
6437
6437
  };
6438
- syncFs.writeFileSync(filePath, `${JSON.stringify(stored, null, 2)}\n`, { mode: 384 });
6438
+ fs$1.writeFileSync(filePath, `${JSON.stringify(stored, null, 2)}\n`, { mode: 384 });
6439
6439
  try {
6440
- syncFs.chmodSync(filePath, 384);
6440
+ fs$1.chmodSync(filePath, 384);
6441
6441
  } catch {}
6442
6442
  return identity;
6443
6443
  }
@@ -6629,8 +6629,8 @@ function resolveDeviceAuthPath(env = process.env) {
6629
6629
  }
6630
6630
  function readStore(filePath) {
6631
6631
  try {
6632
- if (!syncFs.existsSync(filePath)) return null;
6633
- const raw = syncFs.readFileSync(filePath, "utf8");
6632
+ if (!fs$1.existsSync(filePath)) return null;
6633
+ const raw = fs$1.readFileSync(filePath, "utf8");
6634
6634
  const parsed = JSON.parse(raw);
6635
6635
  if (parsed?.version !== 1 || typeof parsed.deviceId !== "string") return null;
6636
6636
  if (!parsed.tokens || typeof parsed.tokens !== "object") return null;
@@ -6640,10 +6640,10 @@ function readStore(filePath) {
6640
6640
  }
6641
6641
  }
6642
6642
  function writeStore(filePath, store) {
6643
- syncFs.mkdirSync(path.dirname(filePath), { recursive: true });
6644
- syncFs.writeFileSync(filePath, `${JSON.stringify(store, null, 2)}\n`, { mode: 384 });
6643
+ fs$1.mkdirSync(path.dirname(filePath), { recursive: true });
6644
+ fs$1.writeFileSync(filePath, `${JSON.stringify(store, null, 2)}\n`, { mode: 384 });
6645
6645
  try {
6646
- syncFs.chmodSync(filePath, 384);
6646
+ fs$1.chmodSync(filePath, 384);
6647
6647
  } catch {}
6648
6648
  }
6649
6649
  function loadDeviceAuthToken(params) {
@@ -9683,7 +9683,7 @@ async function routeReply(params) {
9683
9683
  const resolvedReplyToId = replyToId ?? (channelId === "slack" && threadId != null && threadId !== "" ? String(threadId) : void 0);
9684
9684
  const resolvedThreadId = channelId === "slack" ? null : threadId ?? null;
9685
9685
  try {
9686
- const { deliverOutboundPayloads } = await import("./deliver-xY3h9X6N.js").then((n) => n.n);
9686
+ const { deliverOutboundPayloads } = await import("./deliver-C82Egs0W.js").then((n) => n.n);
9687
9687
  const outboundSession = buildOutboundSessionContext({
9688
9688
  cfg,
9689
9689
  agentId: resolvedAgentId,
@@ -10327,7 +10327,7 @@ function normalizeSessionKey(value) {
10327
10327
  }
10328
10328
  function readSessionStore(storePath) {
10329
10329
  try {
10330
- const raw = syncFs.readFileSync(storePath, "utf-8");
10330
+ const raw = fs$1.readFileSync(storePath, "utf-8");
10331
10331
  const parsed = JSON5.parse(raw);
10332
10332
  if (parsed && typeof parsed === "object" && !Array.isArray(parsed)) return parsed;
10333
10333
  } catch {}
@@ -14241,7 +14241,7 @@ async function sendTranscriptEcho(params) {
14241
14241
  }
14242
14242
  const text = formatEchoTranscript(transcript, params.format ?? DEFAULT_ECHO_TRANSCRIPT_FORMAT);
14243
14243
  try {
14244
- const { deliverOutboundPayloads } = await import("./deliver-xY3h9X6N.js").then((n) => n.n);
14244
+ const { deliverOutboundPayloads } = await import("./deliver-C82Egs0W.js").then((n) => n.n);
14245
14245
  await deliverOutboundPayloads({
14246
14246
  cfg,
14247
14247
  channel: normalizedChannel,
@@ -17856,7 +17856,7 @@ function mergeLegacyAgent(current, legacy) {
17856
17856
  }
17857
17857
  function ensureDir$1(filePath) {
17858
17858
  const dir = path.dirname(filePath);
17859
- syncFs.mkdirSync(dir, { recursive: true });
17859
+ fs$1.mkdirSync(dir, { recursive: true });
17860
17860
  }
17861
17861
  function coerceAllowlistEntries(allowlist) {
17862
17862
  if (!Array.isArray(allowlist) || allowlist.length === 0) return Array.isArray(allowlist) ? allowlist : void 0;
@@ -17926,11 +17926,11 @@ function generateToken() {
17926
17926
  function loadExecApprovals() {
17927
17927
  const filePath = resolveExecApprovalsPath();
17928
17928
  try {
17929
- if (!syncFs.existsSync(filePath)) return normalizeExecApprovals({
17929
+ if (!fs$1.existsSync(filePath)) return normalizeExecApprovals({
17930
17930
  version: 1,
17931
17931
  agents: {}
17932
17932
  });
17933
- const raw = syncFs.readFileSync(filePath, "utf8");
17933
+ const raw = fs$1.readFileSync(filePath, "utf8");
17934
17934
  const parsed = JSON.parse(raw);
17935
17935
  if (parsed?.version !== 1) return normalizeExecApprovals({
17936
17936
  version: 1,
@@ -17947,9 +17947,9 @@ function loadExecApprovals() {
17947
17947
  function saveExecApprovals(file) {
17948
17948
  const filePath = resolveExecApprovalsPath();
17949
17949
  ensureDir$1(filePath);
17950
- syncFs.writeFileSync(filePath, `${JSON.stringify(file, null, 2)}\n`, { mode: 384 });
17950
+ fs$1.writeFileSync(filePath, `${JSON.stringify(file, null, 2)}\n`, { mode: 384 });
17951
17951
  try {
17952
- syncFs.chmodSync(filePath, 384);
17952
+ fs$1.chmodSync(filePath, 384);
17953
17953
  } catch {}
17954
17954
  }
17955
17955
  function ensureExecApprovals() {
@@ -18446,18 +18446,18 @@ function drainSystemEventEntries(sessionKey) {
18446
18446
  function resolvePowerShellPath() {
18447
18447
  const programFiles = process.env.ProgramFiles || process.env.PROGRAMFILES || "C:\\Program Files";
18448
18448
  const pwsh7 = path.join(programFiles, "PowerShell", "7", "pwsh.exe");
18449
- if (syncFs.existsSync(pwsh7)) return pwsh7;
18449
+ if (fs$1.existsSync(pwsh7)) return pwsh7;
18450
18450
  const programW6432 = process.env.ProgramW6432;
18451
18451
  if (programW6432 && programW6432 !== programFiles) {
18452
18452
  const pwsh7Alt = path.join(programW6432, "PowerShell", "7", "pwsh.exe");
18453
- if (syncFs.existsSync(pwsh7Alt)) return pwsh7Alt;
18453
+ if (fs$1.existsSync(pwsh7Alt)) return pwsh7Alt;
18454
18454
  }
18455
18455
  const pwshInPath = resolveShellFromPath("pwsh");
18456
18456
  if (pwshInPath) return pwshInPath;
18457
18457
  const systemRoot = process.env.SystemRoot || process.env.WINDIR;
18458
18458
  if (systemRoot) {
18459
18459
  const candidate = path.join(systemRoot, "System32", "WindowsPowerShell", "v1.0", "powershell.exe");
18460
- if (syncFs.existsSync(candidate)) return candidate;
18460
+ if (fs$1.existsSync(candidate)) return candidate;
18461
18461
  }
18462
18462
  return "powershell.exe";
18463
18463
  }
@@ -18495,7 +18495,7 @@ function resolveShellFromPath(name) {
18495
18495
  for (const entry of entries) {
18496
18496
  const candidate = path.join(entry, name);
18497
18497
  try {
18498
- syncFs.accessSync(candidate, syncFs.constants.X_OK);
18498
+ fs$1.accessSync(candidate, fs$1.constants.X_OK);
18499
18499
  return candidate;
18500
18500
  } catch {}
18501
18501
  }
@@ -21969,7 +21969,7 @@ function ensureContextWindowCacheLoaded() {
21969
21969
  await ensureOpenClawModelsJson(cfg);
21970
21970
  } catch {}
21971
21971
  try {
21972
- const { discoverAuthStorage, discoverModels } = await import("./pi-model-discovery-DCIw1y1c.js").then((n) => n.r);
21972
+ const { discoverAuthStorage, discoverModels } = await import("./pi-model-discovery-COjkql-U.js").then((n) => n.r);
21973
21973
  const agentDir = resolveOpenClawAgentDir();
21974
21974
  const modelRegistry = discoverModels(discoverAuthStorage(agentDir), agentDir);
21975
21975
  applyDiscoveredContextWindows({
@@ -22131,7 +22131,7 @@ function walkUpFrom(startDir, opts, resolveAtDir) {
22131
22131
  function hasGitMarker(repoRoot) {
22132
22132
  const gitPath = path.join(repoRoot, ".git");
22133
22133
  try {
22134
- const stat = syncFs.statSync(gitPath);
22134
+ const stat = fs$1.statSync(gitPath);
22135
22135
  return stat.isDirectory() || stat.isFile();
22136
22136
  } catch {
22137
22137
  return false;
@@ -22143,10 +22143,10 @@ function findGitRoot(startDir, opts = {}) {
22143
22143
  function resolveGitDirFromMarker(repoRoot) {
22144
22144
  const gitPath = path.join(repoRoot, ".git");
22145
22145
  try {
22146
- const stat = syncFs.statSync(gitPath);
22146
+ const stat = fs$1.statSync(gitPath);
22147
22147
  if (stat.isDirectory()) return gitPath;
22148
22148
  if (!stat.isFile()) return null;
22149
- const match = syncFs.readFileSync(gitPath, "utf-8").match(/gitdir:\s*(.+)/i);
22149
+ const match = fs$1.readFileSync(gitPath, "utf-8").match(/gitdir:\s*(.+)/i);
22150
22150
  if (!match?.[1]) return null;
22151
22151
  return path.resolve(repoRoot, match[1].trim());
22152
22152
  } catch {
@@ -22213,7 +22213,7 @@ const resolveCommitHash = (options = {}) => {
22213
22213
  cachedCommit = null;
22214
22214
  return cachedCommit;
22215
22215
  }
22216
- const head = syncFs.readFileSync(headPath, "utf-8").trim();
22216
+ const head = fs$1.readFileSync(headPath, "utf-8").trim();
22217
22217
  if (!head) {
22218
22218
  cachedCommit = null;
22219
22219
  return cachedCommit;
@@ -22221,7 +22221,7 @@ const resolveCommitHash = (options = {}) => {
22221
22221
  if (head.startsWith("ref:")) {
22222
22222
  const ref = head.replace(/^ref:\s*/i, "").trim();
22223
22223
  const refPath = path.resolve(path.dirname(headPath), ref);
22224
- cachedCommit = formatCommit(syncFs.readFileSync(refPath, "utf-8").trim());
22224
+ cachedCommit = formatCommit(fs$1.readFileSync(refPath, "utf-8").trim());
22225
22225
  return cachedCommit;
22226
22226
  }
22227
22227
  cachedCommit = formatCommit(head);
@@ -22481,17 +22481,17 @@ const readUsageFromSessionLog = (sessionId, sessionEntry, agentId, sessionKey, s
22481
22481
  } catch {
22482
22482
  return;
22483
22483
  }
22484
- if (!syncFs.existsSync(logPath)) return;
22484
+ if (!fs$1.existsSync(logPath)) return;
22485
22485
  try {
22486
22486
  const TAIL_BYTES = 8192;
22487
- const stat = syncFs.statSync(logPath);
22487
+ const stat = fs$1.statSync(logPath);
22488
22488
  const offset = Math.max(0, stat.size - TAIL_BYTES);
22489
22489
  const buf = Buffer.alloc(Math.min(TAIL_BYTES, stat.size));
22490
- const fd = syncFs.openSync(logPath, "r");
22490
+ const fd = fs$1.openSync(logPath, "r");
22491
22491
  try {
22492
- syncFs.readSync(fd, buf, 0, buf.length, offset);
22492
+ fs$1.readSync(fd, buf, 0, buf.length, offset);
22493
22493
  } finally {
22494
- syncFs.closeSync(fd);
22494
+ fs$1.closeSync(fd);
22495
22495
  }
22496
22496
  const tail = buf.toString("utf-8");
22497
22497
  const lines = (offset > 0 ? tail.slice(tail.indexOf("\n") + 1) : tail).split(/\n+/);
@@ -23846,7 +23846,7 @@ function resolveRepoRoot(params) {
23846
23846
  const configured = params.config?.agents?.defaults?.repoRoot?.trim();
23847
23847
  if (configured) try {
23848
23848
  const resolved = path.resolve(configured);
23849
- if (syncFs.statSync(resolved).isDirectory()) return resolved;
23849
+ if (fs$1.statSync(resolved).isDirectory()) return resolved;
23850
23850
  } catch {}
23851
23851
  const candidates = [params.workspaceDir, params.cwd].map((value) => value?.trim()).filter(Boolean);
23852
23852
  const seen = /* @__PURE__ */ new Set();
@@ -24614,7 +24614,7 @@ async function buildContextReply(params) {
24614
24614
  //#region src/auto-reply/reply/commands-export-session.ts
24615
24615
  const EXPORT_HTML_DIR = path.join(path.dirname(fileURLToPath(import.meta.url)), "export-html");
24616
24616
  function loadTemplate(fileName) {
24617
- return syncFs.readFileSync(path.join(EXPORT_HTML_DIR, fileName), "utf-8");
24617
+ return fs$1.readFileSync(path.join(EXPORT_HTML_DIR, fileName), "utf-8");
24618
24618
  }
24619
24619
  function generateHtml(sessionData) {
24620
24620
  const template = loadTemplate("template.html");
@@ -24688,7 +24688,7 @@ async function buildExportSessionReply(params) {
24688
24688
  } catch (err) {
24689
24689
  return { text: `❌ Failed to resolve session file: ${err instanceof Error ? err.message : String(err)}` };
24690
24690
  }
24691
- if (!syncFs.existsSync(sessionFile)) return { text: `❌ Session file not found: ${sessionFile}` };
24691
+ if (!fs$1.existsSync(sessionFile)) return { text: `❌ Session file not found: ${sessionFile}` };
24692
24692
  const sessionManager = SessionManager.open(sessionFile);
24693
24693
  const entries = sessionManager.getEntries();
24694
24694
  const header = sessionManager.getHeader();
@@ -24709,8 +24709,8 @@ async function buildExportSessionReply(params) {
24709
24709
  const defaultFileName = `openclaw-session-${entry.sessionId.slice(0, 8)}-${timestamp}.html`;
24710
24710
  const outputPath = args.outputPath ? path.resolve(args.outputPath.startsWith("~") ? args.outputPath.replace("~", process.env.HOME ?? "") : args.outputPath) : path.join(params.workspaceDir, defaultFileName);
24711
24711
  const outputDir = path.dirname(outputPath);
24712
- if (!syncFs.existsSync(outputDir)) syncFs.mkdirSync(outputDir, { recursive: true });
24713
- syncFs.writeFileSync(outputPath, html, "utf-8");
24712
+ if (!fs$1.existsSync(outputDir)) fs$1.mkdirSync(outputDir, { recursive: true });
24713
+ fs$1.writeFileSync(outputPath, html, "utf-8");
24714
24714
  const relativePath = path.relative(params.workspaceDir, outputPath);
24715
24715
  return { text: [
24716
24716
  "✅ Session exported!",
@@ -24885,8 +24885,8 @@ function resolveZaiApiKey() {
24885
24885
  }
24886
24886
  try {
24887
24887
  const authPath = path.join(resolveRequiredHomeDir(process.env, os.homedir), ".pi", "agent", "auth.json");
24888
- if (!syncFs.existsSync(authPath)) return;
24889
- const data = JSON.parse(syncFs.readFileSync(authPath, "utf-8"));
24888
+ if (!fs$1.existsSync(authPath)) return;
24889
+ const data = JSON.parse(fs$1.readFileSync(authPath, "utf-8"));
24890
24890
  return data["z-ai"]?.access || data.zai?.access;
24891
24891
  } catch {
24892
24892
  return;
@@ -26705,7 +26705,7 @@ function shouldPersistAnyBindingState() {
26705
26705
  }
26706
26706
  function shouldPersistBindingMutations() {
26707
26707
  if (shouldPersistAnyBindingState()) return true;
26708
- return syncFs.existsSync(resolveThreadBindingsPath());
26708
+ return fs$1.existsSync(resolveThreadBindingsPath());
26709
26709
  }
26710
26710
  function saveBindingsToDisk(params = {}) {
26711
26711
  if (!params.force && !shouldPersistAnyBindingState()) return;
@@ -27969,7 +27969,7 @@ const applyCostTotal = (totals, costTotal) => {
27969
27969
  totals.totalCost += costTotal;
27970
27970
  };
27971
27971
  async function* readJsonlRecords(filePath) {
27972
- const fileStream = syncFs.createReadStream(filePath, { encoding: "utf-8" });
27972
+ const fileStream = fs$1.createReadStream(filePath, { encoding: "utf-8" });
27973
27973
  const rl = readline.createInterface({
27974
27974
  input: fileStream,
27975
27975
  crlfDelay: Infinity
@@ -28041,10 +28041,10 @@ async function loadCostUsageSummary(params) {
28041
28041
  const dailyMap = /* @__PURE__ */ new Map();
28042
28042
  const totals = emptyTotals();
28043
28043
  const sessionsDir = resolveSessionTranscriptsDirForAgent(params?.agentId);
28044
- const entries = await syncFs.promises.readdir(sessionsDir, { withFileTypes: true }).catch(() => []);
28044
+ const entries = await fs$1.promises.readdir(sessionsDir, { withFileTypes: true }).catch(() => []);
28045
28045
  const files = (await Promise.all(entries.filter((entry) => entry.isFile() && entry.name.endsWith(".jsonl")).map(async (entry) => {
28046
28046
  const filePath = path.join(sessionsDir, entry.name);
28047
- const stats = await syncFs.promises.stat(filePath).catch(() => null);
28047
+ const stats = await fs$1.promises.stat(filePath).catch(() => null);
28048
28048
  if (!stats) return null;
28049
28049
  if (stats.mtimeMs < sinceTime) return null;
28050
28050
  return filePath;
@@ -28077,7 +28077,7 @@ async function loadCostUsageSummary(params) {
28077
28077
  }
28078
28078
  async function loadSessionCostSummary(params) {
28079
28079
  const sessionFile = params.sessionFile ?? (params.sessionId ? resolveSessionFilePath(params.sessionId, params.sessionEntry, { agentId: params.agentId }) : void 0);
28080
- if (!sessionFile || !syncFs.existsSync(sessionFile)) return null;
28080
+ if (!sessionFile || !fs$1.existsSync(sessionFile)) return null;
28081
28081
  const totals = emptyTotals();
28082
28082
  let firstActivity;
28083
28083
  let lastActivity;
@@ -30573,7 +30573,7 @@ async function createModelSelectionState(params) {
30573
30573
  }
30574
30574
  }
30575
30575
  if (sessionEntry && sessionStore && sessionKey && sessionEntry.authProfileOverride) {
30576
- const { ensureAuthProfileStore } = await import("./model-selection-D_Si2Ict.js").then((n) => n.N);
30576
+ const { ensureAuthProfileStore } = await import("./model-selection-DfZMxaX3.js").then((n) => n.N);
30577
30577
  const profile = ensureAuthProfileStore(void 0, { allowKeychainPrompt: false }).profiles[sessionEntry.authProfileOverride];
30578
30578
  const providerKey = normalizeProviderId(provider);
30579
30579
  if (!profile || normalizeProviderId(profile.provider) !== providerKey) await clearSessionAuthProfileOverride({
@@ -34234,7 +34234,7 @@ function asBoolean(value) {
34234
34234
  }
34235
34235
  function resolveTempPathParts(opts) {
34236
34236
  const tmpDir = opts.tmpDir ?? resolvePreferredOpenClawTmpDir();
34237
- if (!opts.tmpDir) syncFs.mkdirSync(tmpDir, {
34237
+ if (!opts.tmpDir) fs$1.mkdirSync(tmpDir, {
34238
34238
  recursive: true,
34239
34239
  mode: 448
34240
34240
  });
@@ -34320,7 +34320,7 @@ async function writeUrlToFile(filePath, url, opts) {
34320
34320
  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}`);
34321
34321
  const body = res.body;
34322
34322
  if (!body) throw new Error(`failed to download ${url}: empty response body`);
34323
- const fileHandle = await fs$1.open(filePath, "w");
34323
+ const fileHandle = await fs$2.open(filePath, "w");
34324
34324
  let thrown;
34325
34325
  try {
34326
34326
  const reader = body.getReader();
@@ -34338,7 +34338,7 @@ async function writeUrlToFile(filePath, url, opts) {
34338
34338
  await fileHandle.close();
34339
34339
  }
34340
34340
  if (thrown) {
34341
- await fs$1.unlink(filePath).catch(() => {});
34341
+ await fs$2.unlink(filePath).catch(() => {});
34342
34342
  throw thrown;
34343
34343
  }
34344
34344
  } finally {
@@ -34351,7 +34351,7 @@ async function writeUrlToFile(filePath, url, opts) {
34351
34351
  }
34352
34352
  async function writeBase64ToFile(filePath, base64) {
34353
34353
  const buf = Buffer.from(base64, "base64");
34354
- await fs$1.writeFile(filePath, buf);
34354
+ await fs$2.writeFile(filePath, buf);
34355
34355
  return {
34356
34356
  path: filePath,
34357
34357
  bytes: buf.length
@@ -37396,9 +37396,9 @@ function loadExternalCatalogEntries(options) {
37396
37396
  const entries = [];
37397
37397
  for (const rawPath of paths) {
37398
37398
  const resolved = resolveUserPath(rawPath);
37399
- if (!syncFs.existsSync(resolved)) continue;
37399
+ if (!fs$1.existsSync(resolved)) continue;
37400
37400
  try {
37401
- const payload = JSON.parse(syncFs.readFileSync(resolved, "utf-8"));
37401
+ const payload = JSON.parse(fs$1.readFileSync(resolved, "utf-8"));
37402
37402
  entries.push(...parseCatalogEntries(payload));
37403
37403
  } catch {}
37404
37404
  }
@@ -41112,7 +41112,7 @@ function listExistingAgentIdsFromDisk() {
41112
41112
  const root = resolveStateDir();
41113
41113
  const agentsDir = path.join(root, "agents");
41114
41114
  try {
41115
- return syncFs.readdirSync(agentsDir, { withFileTypes: true }).filter((entry) => entry.isDirectory()).map((entry) => normalizeAgentId(entry.name)).filter(Boolean);
41115
+ return fs$1.readdirSync(agentsDir, { withFileTypes: true }).filter((entry) => entry.isDirectory()).map((entry) => normalizeAgentId(entry.name)).filter(Boolean);
41116
41116
  } catch {
41117
41117
  return [];
41118
41118
  }
@@ -47037,7 +47037,7 @@ async function runAgentTurnWithFallback(params) {
47037
47037
  if (corruptedSessionId) {
47038
47038
  const transcriptPath = resolveSessionTranscriptPath(corruptedSessionId);
47039
47039
  try {
47040
- syncFs.unlinkSync(transcriptPath);
47040
+ fs$1.unlinkSync(transcriptPath);
47041
47041
  } catch {}
47042
47042
  }
47043
47043
  delete params.activeSessionStore[sessionKey];
@@ -47838,7 +47838,7 @@ async function readSessionLogSnapshot(params) {
47838
47838
  if (!logPath) return {};
47839
47839
  const snapshot = {};
47840
47840
  if (params.includeByteSize) try {
47841
- const stat = await syncFs.promises.stat(logPath);
47841
+ const stat = await fs$1.promises.stat(logPath);
47842
47842
  const size = Math.floor(stat.size);
47843
47843
  snapshot.byteSize = Number.isFinite(size) && size >= 0 ? size : void 0;
47844
47844
  } catch {
@@ -47852,7 +47852,7 @@ async function readSessionLogSnapshot(params) {
47852
47852
  return snapshot;
47853
47853
  }
47854
47854
  async function readLastNonzeroUsageFromSessionLog(logPath) {
47855
- const handle = await syncFs.promises.open(logPath, "r");
47855
+ const handle = await fs$1.promises.open(logPath, "r");
47856
47856
  try {
47857
47857
  let position = (await handle.stat()).size;
47858
47858
  let leadingPartial = "";
@@ -48523,9 +48523,9 @@ async function readPostCompactionContext(workspaceDir) {
48523
48523
  if (!opened.ok) return null;
48524
48524
  const sections = extractSections((() => {
48525
48525
  try {
48526
- return syncFs.readFileSync(opened.fd, "utf-8");
48526
+ return fs$1.readFileSync(opened.fd, "utf-8");
48527
48527
  } finally {
48528
- syncFs.closeSync(opened.fd);
48528
+ fs$1.closeSync(opened.fd);
48529
48529
  }
48530
48530
  })(), ["Session Startup", "Red Lines"]);
48531
48531
  if (sections.length === 0) return null;
@@ -48740,7 +48740,7 @@ async function runReplyAgent(params) {
48740
48740
  if (resolved) transcriptCandidates.add(resolved);
48741
48741
  transcriptCandidates.add(resolveSessionTranscriptPath(prevSessionId, agentId));
48742
48742
  for (const candidate of transcriptCandidates) try {
48743
- syncFs.unlinkSync(candidate);
48743
+ fs$1.unlinkSync(candidate);
48744
48744
  } catch {}
48745
48745
  }
48746
48746
  return true;
@@ -49731,7 +49731,7 @@ async function deliverSessionMaintenanceWarning(params) {
49731
49731
  return;
49732
49732
  }
49733
49733
  try {
49734
- const { deliverOutboundPayloads } = await import("./deliver-xY3h9X6N.js").then((n) => n.n);
49734
+ const { deliverOutboundPayloads } = await import("./deliver-C82Egs0W.js").then((n) => n.n);
49735
49735
  const outboundSession = buildOutboundSessionContext({
49736
49736
  cfg: params.cfg,
49737
49737
  sessionKey: params.sessionKey
@@ -49869,7 +49869,7 @@ function forkSessionFromParent(params) {
49869
49869
  agentId: params.agentId,
49870
49870
  sessionsDir: params.sessionsDir
49871
49871
  });
49872
- if (!parentSessionFile || !syncFs.existsSync(parentSessionFile)) return null;
49872
+ if (!parentSessionFile || !fs$1.existsSync(parentSessionFile)) return null;
49873
49873
  try {
49874
49874
  const manager = SessionManager.open(parentSessionFile);
49875
49875
  const leafId = manager.getLeafId();
@@ -49893,7 +49893,7 @@ function forkSessionFromParent(params) {
49893
49893
  cwd: manager.getCwd(),
49894
49894
  parentSession: parentSessionFile
49895
49895
  };
49896
- syncFs.writeFileSync(sessionFile, `${JSON.stringify(header)}\n`, "utf-8");
49896
+ fs$1.writeFileSync(sessionFile, `${JSON.stringify(header)}\n`, "utf-8");
49897
49897
  return {
49898
49898
  sessionId,
49899
49899
  sessionFile
@@ -54673,7 +54673,7 @@ async function describeStickerImage(params) {
54673
54673
  logVerbose(`telegram: describing sticker with ${provider}/${model}`);
54674
54674
  try {
54675
54675
  const buffer = await fs.readFile(imagePath);
54676
- const { describeImageWithModel } = await import("./image-DCyaYY2d.js").then((n) => n.n);
54676
+ const { describeImageWithModel } = await import("./image-BQ1JgwZu.js").then((n) => n.n);
54677
54677
  return (await describeImageWithModel({
54678
54678
  buffer,
54679
54679
  fileName: "sticker.webp",
@@ -56427,7 +56427,7 @@ async function resolveDiscordPreflightAudioMentionContext(params) {
56427
56427
  const needsPreflightTranscription = !params.isDirectMessage && params.shouldRequireMention && hasAudioAttachment && !hasTypedText && params.mentionRegexes.length > 0;
56428
56428
  let transcript;
56429
56429
  if (needsPreflightTranscription) try {
56430
- const { transcribeFirstAudio } = await import("./audio-preflight-BWOdDA2n.js");
56430
+ const { transcribeFirstAudio } = await import("./audio-preflight-DZWb0ozj.js");
56431
56431
  const audioUrls = audioAttachments.map((att) => att.url).filter((url) => typeof url === "string" && url.length > 0);
56432
56432
  if (audioUrls.length > 0) transcript = await transcribeFirstAudio({
56433
56433
  ctx: {
@@ -57882,7 +57882,7 @@ function identityHasValues(identity) {
57882
57882
  }
57883
57883
  function loadIdentityFromFile(identityPath) {
57884
57884
  try {
57885
- const parsed = parseIdentityMarkdown(syncFs.readFileSync(identityPath, "utf-8"));
57885
+ const parsed = parseIdentityMarkdown(fs$1.readFileSync(identityPath, "utf-8"));
57886
57886
  if (!identityHasValues(parsed)) return null;
57887
57887
  return parsed;
57888
57888
  } catch {
@@ -57906,7 +57906,7 @@ function resolveAvatarSource(cfg, agentId) {
57906
57906
  }
57907
57907
  function resolveExistingPath(value) {
57908
57908
  try {
57909
- return syncFs.realpathSync(value);
57909
+ return fs$1.realpathSync(value);
57910
57910
  } catch {
57911
57911
  return path.resolve(value);
57912
57912
  }
@@ -57924,7 +57924,7 @@ function resolveLocalAvatarPath(params) {
57924
57924
  reason: "unsupported_extension"
57925
57925
  };
57926
57926
  try {
57927
- const stat = syncFs.statSync(realPath);
57927
+ const stat = fs$1.statSync(realPath);
57928
57928
  if (!stat.isFile()) return {
57929
57929
  ok: false,
57930
57930
  reason: "missing"
@@ -60969,27 +60969,27 @@ function createOutboundSendDepsFromCliSource(deps) {
60969
60969
  function createDefaultDeps() {
60970
60970
  return {
60971
60971
  sendMessageWhatsApp: async (...args) => {
60972
- const { sendMessageWhatsApp } = await import("./web-C1PpWeXj.js");
60972
+ const { sendMessageWhatsApp } = await import("./web-DQzzt8wj.js");
60973
60973
  return await sendMessageWhatsApp(...args);
60974
60974
  },
60975
60975
  sendMessageTelegram: async (...args) => {
60976
- const { sendMessageTelegram } = await import("./send-BqKSZyIb.js").then((n) => n.l);
60976
+ const { sendMessageTelegram } = await import("./send-Bjaa69Cy.js").then((n) => n.l);
60977
60977
  return await sendMessageTelegram(...args);
60978
60978
  },
60979
60979
  sendMessageDiscord: async (...args) => {
60980
- const { sendMessageDiscord } = await import("./send-V3fEVmLq.js").then((n) => n.t);
60980
+ const { sendMessageDiscord } = await import("./send-Cp0yQi_p.js").then((n) => n.t);
60981
60981
  return await sendMessageDiscord(...args);
60982
60982
  },
60983
60983
  sendMessageSlack: async (...args) => {
60984
- const { sendMessageSlack } = await import("./send-B4pSMBHk.js").then((n) => n.n);
60984
+ const { sendMessageSlack } = await import("./send-Bclgg0Ur.js").then((n) => n.n);
60985
60985
  return await sendMessageSlack(...args);
60986
60986
  },
60987
60987
  sendMessageSignal: async (...args) => {
60988
- const { sendMessageSignal } = await import("./send-CN0f1Yst.js").then((n) => n.i);
60988
+ const { sendMessageSignal } = await import("./send-DYY51FOR.js").then((n) => n.i);
60989
60989
  return await sendMessageSignal(...args);
60990
60990
  },
60991
60991
  sendMessageIMessage: async (...args) => {
60992
- const { sendMessageIMessage } = await import("./send-XAO1mk64.js").then((n) => n.n);
60992
+ const { sendMessageIMessage } = await import("./send-DQ7hIAIK.js").then((n) => n.n);
60993
60993
  return await sendMessageIMessage(...args);
60994
60994
  }
60995
60995
  };
@@ -66795,7 +66795,7 @@ async function monitorIMessageProvider(opts = {}) {
66795
66795
  function readFileIfExists(filePath) {
66796
66796
  if (!filePath) return;
66797
66797
  try {
66798
- return syncFs.readFileSync(filePath, "utf-8").trim();
66798
+ return fs$1.readFileSync(filePath, "utf-8").trim();
66799
66799
  } catch {
66800
66800
  return;
66801
66801
  }
@@ -67409,7 +67409,7 @@ async function downloadLineMedia(messageId, channelAccessToken, maxBytes = 10 *
67409
67409
  prefix: "line-media",
67410
67410
  extension: getExtensionForContentType(contentType)
67411
67411
  });
67412
- await syncFs.promises.writeFile(filePath, buffer);
67412
+ await fs$1.promises.writeFile(filePath, buffer);
67413
67413
  logVerbose(`line: downloaded media ${messageId} to ${filePath} (${buffer.length} bytes)`);
67414
67414
  return {
67415
67415
  path: filePath,
@@ -73082,7 +73082,7 @@ function readSlackExternalArgMenuToken(raw) {
73082
73082
  }
73083
73083
  let commandsRegistry;
73084
73084
  async function getCommandsRegistry() {
73085
- if (!commandsRegistry) commandsRegistry = await import("./commands-registry-NIsv9Z4R.js").then((n) => n.n);
73085
+ if (!commandsRegistry) commandsRegistry = await import("./commands-registry-BQkQRhEo.js").then((n) => n.n);
73086
73086
  return commandsRegistry;
73087
73087
  }
73088
73088
  function encodeSlackCommandArgValue(parts) {
@@ -73412,14 +73412,14 @@ async function registerSlackMonitorSlashCommands(params) {
73412
73412
  const channelName = channelInfo?.name;
73413
73413
  const roomLabel = channelName ? `#${channelName}` : `#${command.channel_id}`;
73414
73414
  const [{ resolveAgentRoute }, { finalizeInboundContext }, { dispatchReplyWithDispatcher }] = await Promise.all([
73415
- import("./resolve-route-C5hVstLo.js").then((n) => n.r),
73415
+ import("./resolve-route-BNElrVxR.js").then((n) => n.r),
73416
73416
  import("./inbound-context-D4jdbLFJ.js").then((n) => n.n),
73417
73417
  Promise.resolve().then(() => provider_dispatcher_exports)
73418
73418
  ]);
73419
73419
  const [{ resolveConversationLabel }, { createReplyPrefixOptions }, { recordInboundSessionMetaSafe }] = await Promise.all([
73420
73420
  import("./conversation-label-CEQUZyFY.js").then((n) => n.t),
73421
- import("./reply-prefix-DK1i6bCJ.js").then((n) => n.n),
73422
- import("./session-meta-Cqv55kSk.js").then((n) => n.n)
73421
+ import("./reply-prefix-9mzt89Cf.js").then((n) => n.n),
73422
+ import("./session-meta-CyQWVUk4.js").then((n) => n.n)
73423
73423
  ]);
73424
73424
  const route = resolveAgentRoute({
73425
73425
  cfg,
@@ -73484,9 +73484,9 @@ async function registerSlackMonitorSlashCommands(params) {
73484
73484
  });
73485
73485
  const deliverSlashPayloads = async (replies) => {
73486
73486
  const [{ deliverSlackSlashReplies }, { resolveChunkMode }, { resolveMarkdownTableMode }] = await Promise.all([
73487
- import("./replies-BFYGUEKu.js").then((n) => n.r),
73488
- import("./chunk-DtYb6TYl.js").then((n) => n.s),
73489
- import("./markdown-tables-BHONoo6S.js").then((n) => n.t)
73487
+ import("./replies-yAf6dFeT.js").then((n) => n.r),
73488
+ import("./chunk-DEkdXze6.js").then((n) => n.s),
73489
+ import("./markdown-tables-pfs_NCNh.js").then((n) => n.t)
73490
73490
  ]);
73491
73491
  await deliverSlackSlashReplies({
73492
73492
  replies,
@@ -73539,7 +73539,7 @@ async function registerSlackMonitorSlashCommands(params) {
73539
73539
  let nativeCommands = [];
73540
73540
  if (nativeEnabled) {
73541
73541
  reg = await getCommandsRegistry();
73542
- const skillCommands = nativeSkillsEnabled ? (await import("./skill-commands-CZFmIM-s.js").then((n) => n.a)).listSkillCommandsForAgents({ cfg }) : [];
73542
+ const skillCommands = nativeSkillsEnabled ? (await import("./skill-commands-CSr9_48V.js").then((n) => n.a)).listSkillCommandsForAgents({ cfg }) : [];
73543
73543
  nativeCommands = reg.listNativeCommandSpecsForConfig(cfg, {
73544
73544
  skillCommands,
73545
73545
  provider: "slack"
@@ -74125,7 +74125,7 @@ async function auditTelegramGroupMembership(params) {
74125
74125
  groups: [],
74126
74126
  elapsedMs: Date.now() - started
74127
74127
  };
74128
- const fetcher = params.proxyUrl ? (await import("./proxy-DfJJLvch.js").then((n) => n.t)).makeProxyFetch(params.proxyUrl) : fetch;
74128
+ const fetcher = params.proxyUrl ? (await import("./proxy-jINniQBi.js").then((n) => n.t)).makeProxyFetch(params.proxyUrl) : fetch;
74129
74129
  const { fetchWithTimeout } = await import("./fetch-timeout-CYFFedEH.js").then((n) => n.r);
74130
74130
  const base = `${TELEGRAM_API_BASE$1}/bot${token}`;
74131
74131
  const groups = [];
@@ -76448,7 +76448,7 @@ const buildTelegramMessageContext = async ({ primaryCtx, allMedia, replyMedia =
76448
76448
  const disableAudioPreflight = firstDefined$1(topicConfig?.disableAudioPreflight, groupConfig?.disableAudioPreflight) === true;
76449
76449
  let preflightTranscript;
76450
76450
  if (isGroup && requireMention && hasAudio && !hasUserText && mentionRegexes.length > 0 && !disableAudioPreflight) try {
76451
- const { transcribeFirstAudio } = await import("./audio-preflight-BWOdDA2n.js");
76451
+ const { transcribeFirstAudio } = await import("./audio-preflight-DZWb0ozj.js");
76452
76452
  preflightTranscript = await transcribeFirstAudio({
76453
76453
  ctx: {
76454
76454
  MediaPaths: allMedia.length > 0 ? allMedia.map((m) => m.path) : void 0,
@@ -79146,7 +79146,7 @@ function createWhatsAppLoginTool() {
79146
79146
  force: Type.Optional(Type.Boolean())
79147
79147
  }),
79148
79148
  execute: async (_toolCallId, args) => {
79149
- const { startWebLoginWithQr, waitForWebLogin } = await import("./login-qr-DUJfhbUe.js");
79149
+ const { startWebLoginWithQr, waitForWebLogin } = await import("./login-qr-iS1jPDpP.js");
79150
79150
  if ((args?.action ?? "start") === "wait") {
79151
79151
  const result = await waitForWebLogin({ timeoutMs: typeof args.timeoutMs === "number" ? args.timeoutMs : void 0 });
79152
79152
  return {
@@ -79221,23 +79221,23 @@ let webLoginQrPromise = null;
79221
79221
  let webChannelPromise = null;
79222
79222
  let whatsappActionsPromise = null;
79223
79223
  function loadWebOutbound() {
79224
- webOutboundPromise ??= import("./outbound-DOVV_R6m.js").then((n) => n.t);
79224
+ webOutboundPromise ??= import("./outbound-4q4mbU-Z.js").then((n) => n.t);
79225
79225
  return webOutboundPromise;
79226
79226
  }
79227
79227
  function loadWebLogin() {
79228
- webLoginPromise ??= import("./login-CgEHUE7h.js").then((n) => n.n);
79228
+ webLoginPromise ??= import("./login-Cm2zDfEU.js").then((n) => n.n);
79229
79229
  return webLoginPromise;
79230
79230
  }
79231
79231
  function loadWebLoginQr() {
79232
- webLoginQrPromise ??= import("./login-qr-DUJfhbUe.js");
79232
+ webLoginQrPromise ??= import("./login-qr-iS1jPDpP.js");
79233
79233
  return webLoginQrPromise;
79234
79234
  }
79235
79235
  function loadWebChannel() {
79236
- webChannelPromise ??= import("./web-C1PpWeXj.js");
79236
+ webChannelPromise ??= import("./web-DQzzt8wj.js");
79237
79237
  return webChannelPromise;
79238
79238
  }
79239
79239
  function loadWhatsAppActions() {
79240
- whatsappActionsPromise ??= import("./whatsapp-actions-CHt12z-f.js");
79240
+ whatsappActionsPromise ??= import("./whatsapp-actions-DXjy9m41.js");
79241
79241
  return whatsappActionsPromise;
79242
79242
  }
79243
79243
  function createRuntimeWhatsApp() {
@@ -79687,7 +79687,7 @@ async function getMemorySearchManager(params) {
79687
79687
  if (cached) return { manager: cached };
79688
79688
  }
79689
79689
  try {
79690
- const { QmdMemoryManager } = await import("./qmd-manager-CeN3N992.js");
79690
+ const { QmdMemoryManager } = await import("./qmd-manager-BBKfRzj-.js");
79691
79691
  const primary = await QmdMemoryManager.create({
79692
79692
  cfg: params.cfg,
79693
79693
  agentId: params.agentId,
@@ -79699,7 +79699,7 @@ async function getMemorySearchManager(params) {
79699
79699
  const wrapper = new FallbackMemoryManager({
79700
79700
  primary,
79701
79701
  fallbackFactory: async () => {
79702
- const { MemoryIndexManager } = await import("./manager-BNuB9clC.js").then((n) => n.t);
79702
+ const { MemoryIndexManager } = await import("./manager-DdzkWOvc.js").then((n) => n.t);
79703
79703
  return await MemoryIndexManager.get(params);
79704
79704
  }
79705
79705
  }, () => {
@@ -79714,7 +79714,7 @@ async function getMemorySearchManager(params) {
79714
79714
  }
79715
79715
  }
79716
79716
  try {
79717
- const { MemoryIndexManager } = await import("./manager-BNuB9clC.js").then((n) => n.t);
79717
+ const { MemoryIndexManager } = await import("./manager-DdzkWOvc.js").then((n) => n.t);
79718
79718
  return { manager: await MemoryIndexManager.get(params) };
79719
79719
  } catch (err) {
79720
79720
  return {
@@ -80241,7 +80241,7 @@ async function withMemoryManagerForAgent(params) {
80241
80241
  }
80242
80242
  async function checkReadableFile(pathname) {
80243
80243
  try {
80244
- await fs.access(pathname, syncFs.constants.R_OK);
80244
+ await fs.access(pathname, fs$1.constants.R_OK);
80245
80245
  return { exists: true };
80246
80246
  } catch (err) {
80247
80247
  const code = err.code;
@@ -80300,7 +80300,7 @@ async function scanMemoryFiles(workspaceDir, extraPaths = []) {
80300
80300
  }
80301
80301
  let dirReadable = null;
80302
80302
  try {
80303
- await fs.access(memoryDir, syncFs.constants.R_OK);
80303
+ await fs.access(memoryDir, fs$1.constants.R_OK);
80304
80304
  dirReadable = true;
80305
80305
  } catch (err) {
80306
80306
  const code = err.code;
@@ -80746,7 +80746,7 @@ const resolvePluginSdkAliasFile = (params) => {
80746
80746
  const srcCandidate = path.join(cursor, "src", "plugin-sdk", params.srcFile);
80747
80747
  const distCandidate = path.join(cursor, "dist", "plugin-sdk", params.distFile);
80748
80748
  const orderedCandidates = isDistRuntime ? [distCandidate, srcCandidate] : isTest ? [distCandidate, srcCandidate] : [distCandidate];
80749
- for (const candidate of orderedCandidates) if (syncFs.existsSync(candidate)) return candidate;
80749
+ for (const candidate of orderedCandidates) if (fs$1.existsSync(candidate)) return candidate;
80750
80750
  const parent = path.dirname(cursor);
80751
80751
  if (parent === cursor) break;
80752
80752
  cursor = parent;
@@ -81083,7 +81083,7 @@ function loadOpenClawPlugins(options = {}) {
81083
81083
  continue;
81084
81084
  }
81085
81085
  const safeSource = opened.path;
81086
- syncFs.closeSync(opened.fd);
81086
+ fs$1.closeSync(opened.fd);
81087
81087
  let mod = null;
81088
81088
  try {
81089
81089
  mod = getJiti()(safeSource);
@@ -81201,7 +81201,7 @@ function loadOpenClawPlugins(options = {}) {
81201
81201
  }
81202
81202
  function safeRealpathOrResolve(value) {
81203
81203
  try {
81204
- return syncFs.realpathSync(value);
81204
+ return fs$1.realpathSync(value);
81205
81205
  } catch {
81206
81206
  return path.resolve(value);
81207
81207
  }
@@ -81640,9 +81640,9 @@ function resolvePatchFileOps(options) {
81640
81640
  });
81641
81641
  assertBoundaryRead(opened, filePath);
81642
81642
  try {
81643
- return syncFs.readFileSync(opened.fd, "utf8");
81643
+ return fs$1.readFileSync(opened.fd, "utf8");
81644
81644
  } finally {
81645
- syncFs.closeSync(opened.fd);
81645
+ fs$1.closeSync(opened.fd);
81646
81646
  }
81647
81647
  },
81648
81648
  writeFile: async (filePath, content) => {
@@ -81938,7 +81938,7 @@ async function recordLoopOutcome(args) {
81938
81938
  if (!args.ctx?.sessionKey) return;
81939
81939
  try {
81940
81940
  const { getDiagnosticSessionState } = await import("./diagnostic-session-state-DBPrVBk3.js").then((n) => n.n);
81941
- const { recordToolCallOutcome } = await import("./tool-loop-detection-CLoYKYIq.js");
81941
+ const { recordToolCallOutcome } = await import("./tool-loop-detection-C4V990MS.js");
81942
81942
  recordToolCallOutcome(getDiagnosticSessionState({
81943
81943
  sessionKey: args.ctx.sessionKey,
81944
81944
  sessionId: args.ctx?.agentId
@@ -81959,8 +81959,8 @@ async function runBeforeToolCallHook(args) {
81959
81959
  const params = args.params;
81960
81960
  if (args.ctx?.sessionKey) {
81961
81961
  const { getDiagnosticSessionState } = await import("./diagnostic-session-state-DBPrVBk3.js").then((n) => n.n);
81962
- const { logToolLoopAction } = await import("./diagnostic-BO1GQJJf.js").then((n) => n.n);
81963
- const { detectToolCallLoop, recordToolCall } = await import("./tool-loop-detection-CLoYKYIq.js");
81962
+ const { logToolLoopAction } = await import("./diagnostic-DpOlXoSr.js").then((n) => n.n);
81963
+ const { detectToolCallLoop, recordToolCall } = await import("./tool-loop-detection-C4V990MS.js");
81964
81964
  const sessionState = getDiagnosticSessionState({
81965
81965
  sessionKey: args.ctx.sessionKey,
81966
81966
  sessionId: args.ctx?.agentId
@@ -84445,9 +84445,9 @@ async function readWorkspaceContextForSummary() {
84445
84445
  if (!opened.ok) return "";
84446
84446
  const sections = extractSections((() => {
84447
84447
  try {
84448
- return syncFs.readFileSync(opened.fd, "utf-8");
84448
+ return fs$1.readFileSync(opened.fd, "utf-8");
84449
84449
  } finally {
84450
- syncFs.closeSync(opened.fd);
84450
+ fs$1.closeSync(opened.fd);
84451
84451
  }
84452
84452
  })(), ["Session Startup", "Red Lines"]);
84453
84453
  if (sections.length === 0) return "";
@@ -85794,7 +85794,7 @@ async function compactEmbeddedPiSessionDirect(params) {
85794
85794
  if (!apiKeyInfo.apiKey) {
85795
85795
  if (apiKeyInfo.mode !== "aws-sdk") throw new Error(`No API key resolved for provider "${model.provider}" (auth mode: ${apiKeyInfo.mode}).`);
85796
85796
  } else if (model.provider === "github-copilot") {
85797
- const { resolveCopilotApiToken } = await import("./github-copilot-token-DLGN-8YS.js").then((n) => n.n);
85797
+ const { resolveCopilotApiToken } = await import("./github-copilot-token-CPjAmbfr.js").then((n) => n.n);
85798
85798
  const copilotToken = await resolveCopilotApiToken({ githubToken: apiKeyInfo.apiKey });
85799
85799
  authStorage.setRuntimeApiKey(model.provider, copilotToken.token);
85800
85800
  } else authStorage.setRuntimeApiKey(model.provider, apiKeyInfo.apiKey);
@@ -88047,11 +88047,11 @@ function appendRawStream(payload) {
88047
88047
  if (!rawStreamReady) {
88048
88048
  rawStreamReady = true;
88049
88049
  try {
88050
- syncFs.mkdirSync(path.dirname(RAW_STREAM_PATH), { recursive: true });
88050
+ fs$1.mkdirSync(path.dirname(RAW_STREAM_PATH), { recursive: true });
88051
88051
  } catch {}
88052
88052
  }
88053
88053
  try {
88054
- syncFs.promises.appendFile(RAW_STREAM_PATH, `${JSON.stringify(payload)}\n`);
88054
+ fs$1.promises.appendFile(RAW_STREAM_PATH, `${JSON.stringify(payload)}\n`);
88055
88055
  } catch {}
88056
88056
  }
88057
88057
 
@@ -91561,7 +91561,7 @@ async function runEmbeddedPiAgent(params) {
91561
91561
  await copilotTokenState.refreshInFlight;
91562
91562
  return;
91563
91563
  }
91564
- const { resolveCopilotApiToken } = await import("./github-copilot-token-DLGN-8YS.js").then((n) => n.n);
91564
+ const { resolveCopilotApiToken } = await import("./github-copilot-token-CPjAmbfr.js").then((n) => n.n);
91565
91565
  copilotTokenState.refreshInFlight = (async () => {
91566
91566
  const githubToken = copilotTokenState.githubToken.trim();
91567
91567
  if (!githubToken) throw new Error("Copilot refresh requires a GitHub token.");
@@ -91653,7 +91653,7 @@ async function runEmbeddedPiAgent(params) {
91653
91653
  return;
91654
91654
  }
91655
91655
  if (model.provider === "github-copilot") {
91656
- const { resolveCopilotApiToken } = await import("./github-copilot-token-DLGN-8YS.js").then((n) => n.n);
91656
+ const { resolveCopilotApiToken } = await import("./github-copilot-token-CPjAmbfr.js").then((n) => n.n);
91657
91657
  const copilotToken = await resolveCopilotApiToken({ githubToken: apiKeyInfo.apiKey });
91658
91658
  authStorage.setRuntimeApiKey(model.provider, copilotToken.token);
91659
91659
  if (copilotTokenState) {