@termix-it/cryptoclaw 1.1.9 → 1.1.11
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.
- package/dist/{accounts-7nNRr4R3.js → accounts-4l7ba973.js} +1 -1
- package/dist/{accounts-CKpnUMZd.js → accounts-CAjupeYV.js} +16 -16
- package/dist/{accounts-BIr_ieyH.js → accounts-k5nTdi32.js} +1 -1
- package/dist/{active-listener-ClXqZUsD.js → active-listener-D9FARjMd.js} +1 -1
- package/dist/{api-key-rotation-CUJC6xSi.js → api-key-rotation-C-Q6XdUW.js} +2 -2
- package/dist/{audio-preflight--MDRrrlB.js → audio-preflight-C7kt2vOu.js} +33 -33
- package/dist/{audio-transcription-runner-CgLX4N3r.js → audio-transcription-runner-CawngPvE.js} +12 -12
- package/dist/{audit-membership-runtime-Ch2lLD_u.js → audit-membership-runtime-C6dnIaXJ.js} +5 -5
- package/dist/build-info.json +3 -3
- package/dist/bundled/boot-md/handler.js +52 -52
- package/dist/bundled/bootstrap-extra-files/handler.js +7 -7
- package/dist/bundled/command-logger/handler.js +2 -2
- package/dist/bundled/session-memory/handler.js +52 -52
- package/dist/bundled/soul-evil/handler.js +5 -5
- package/dist/canvas-host/a2ui/.bundle.hash +1 -1
- package/dist/{channel-account-context-Crd0PQwN.js → channel-account-context-BAivtK8t.js} +1 -1
- package/dist/{channel-account-context-DPRR3rFq.js → channel-account-context-DptVE7IR.js} +1 -1
- package/dist/{channel-activity-32lmgAZH.js → channel-activity-Hho38eZq.js} +3 -3
- package/dist/{chrome-CtEQV_6p.js → chrome-palWvTtp.js} +18 -18
- package/dist/{command-registry-CBfNNhgy.js → command-registry-BEFHpoCL.js} +5 -5
- package/dist/{commands-registry-FnGtnvb0.js → commands-registry-A3LstXeY.js} +4 -4
- package/dist/{completion-cli-FP9HAEQ3.js → completion-cli-BxbU_lYn.js} +2 -2
- package/dist/{completion-cli-Bai3pUlw.js → completion-cli-rNt-qwSw.js} +1 -1
- package/dist/{deliver-32OxViWG.js → deliver-JkYjt9Qz.js} +20 -20
- package/dist/deliver-runtime-BvTbrDXE.js +37 -0
- package/dist/deps-send-discord.runtime-1mqY0Pn3.js +27 -0
- package/dist/deps-send-imessage.runtime-NAKUx6Vy.js +26 -0
- package/dist/deps-send-signal.runtime-CHqnnRXO.js +25 -0
- package/dist/deps-send-slack.runtime-CbGlCNTX.js +23 -0
- package/dist/deps-send-telegram.runtime-CgApeKta.js +28 -0
- package/dist/deps-send-whatsapp.runtime-CAPjqcnc.js +61 -0
- package/dist/{diagnostic-UO82MQjo.js → diagnostic-BGtFj4tU.js} +2 -2
- package/dist/{doctor-completion-CCNHTpp9.js → doctor-completion--S9fsNQo.js} +1 -1
- package/dist/{doctor-completion-BQBZQyQq.js → doctor-completion-BAJbdzsD.js} +1 -1
- package/dist/entry.js +2 -2
- package/dist/{errors-BwBpGOBV.js → errors-C1YF712P.js} +1 -1
- package/dist/{fetch-DozurFmr.js → fetch-_iocPLV2.js} +5 -5
- package/dist/{fetch-guard-XtFb6zM7.js → fetch-guard-CiQUuV0r.js} +2 -2
- package/dist/{frontmatter-Cy6ESb-O.js → frontmatter-Dn68lQ_o.js} +5 -5
- package/dist/{fs-safe-YxZ8RAEw.js → fs-safe-BLpOReWZ.js} +4 -4
- package/dist/{gateway-cli-CyeZq5AC.js → gateway-cli-HRo8JRRd.js} +5 -5
- package/dist/{gateway-cli-DLWVlNsd.js → gateway-cli-LhABh8fD.js} +5 -5
- package/dist/{github-copilot-token-D7knylDF.js → github-copilot-token-DDa7O18e.js} +7 -7
- package/dist/{image-B2LPzwKF.js → image-BlRI3dXw.js} +6 -6
- package/dist/{image-ops-gm8VfGiD.js → image-ops-D7mq-4y1.js} +2 -2
- package/dist/image-runtime-Cp3I725X.js +30 -0
- package/dist/index.js +1 -1
- package/dist/{ir-B7IR3m4T.js → ir-Dpg87zYv.js} +7 -7
- package/dist/{legacy-names-TrN6kryB.js → legacy-names-BAiRv0I2.js} +1 -1
- package/dist/llm-slug-generator.js +52 -52
- package/dist/{logger-CV2IWsAW.js → logger-C53B395N.js} +1 -1
- package/dist/{login-C6CkDgLi.js → login-CHsCISh4.js} +5 -5
- package/dist/{login-qr-WEr1WQvg.js → login-qr-BEW3jIOt.js} +11 -11
- package/dist/{manager-BWh3BVp1.js → manager-Dfrejf6z.js} +13 -13
- package/dist/manager-runtime-DacMHR37.js +19 -0
- package/dist/{model-selection-BiqOlgFe.js → model-selection-e9hodq0l.js} +48 -48
- package/dist/{onboard-BCnqRDky.js → onboard-BgQUk8KO.js} +2 -2
- package/dist/{onboard-CQ-YoTSl.js → onboard-CukHmJnb.js} +2 -2
- package/dist/{onboard-config-DWnlWcjI.js → onboard-config-C06y4K2b.js} +1 -1
- package/dist/{onboard-config-oUKoFfFB.js → onboard-config-DzpTyHer.js} +1 -1
- package/dist/{onboarding-DR-2kdRy.js → onboarding-BjkMcLV3.js} +2 -2
- package/dist/{onboarding-BY3YZMkn.js → onboarding-Dl2vyZrH.js} +2 -2
- package/dist/{onboarding.finalize-B_gI9SXJ.js → onboarding.finalize-D5Wmhsa1.js} +4 -4
- package/dist/{onboarding.finalize-CEgugO0l.js → onboarding.finalize-DPeb5UKU.js} +3 -3
- package/dist/{outbound-DSVwKSv4.js → outbound-BZqL8UdJ.js} +6 -6
- package/dist/{outbound-attachment-CcY_Rg0-.js → outbound-attachment-wzHGF-Is.js} +2 -2
- package/dist/{path-alias-guards-Gzq1eAOo.js → path-alias-guards-It4BBRdm.js} +1 -1
- package/dist/{paths-Cvc9EM8Y.js → paths-C6TxBCvO.js} +5 -5
- package/dist/{paths-BWg7M5Yy.js → paths-CZ0nrg7g.js} +3 -3
- package/dist/{pi-embedded-DkdNpxSe.js → pi-embedded-BNcbv6lg.js} +161 -161
- package/dist/{pi-embedded-helpers-B_qa7ikD.js → pi-embedded-helpers-CE9KKP1Q.js} +52 -52
- package/dist/{pi-model-discovery-FwBV8Q5J.js → pi-model-discovery-32EFg27L.js} +7 -7
- package/dist/pi-model-discovery-runtime-C8SNNnEN.js +12 -0
- package/dist/{pi-tools.before-tool-call.runtime-2r6sdUt5.js → pi-tools.before-tool-call.runtime-BfjlGXIc.js} +10 -10
- package/dist/plugin-sdk/signal.js +2 -2
- package/dist/plugin-sdk/slack.js +2 -2
- package/dist/{plugins-Burzc1_i.js → plugins-rc2l4VJe.js} +10 -10
- package/dist/{program-Rna_eew4.js → program-IR_GbPYL.js} +2 -2
- package/dist/{program-context-BfnHzkXT.js → program-context-CqbW3Ozx.js} +7 -7
- package/dist/{prompt-select-styled-1nWCPZKF.js → prompt-select-styled-4VXtaC_Y.js} +3 -3
- package/dist/{prompt-select-styled-BDi5UBUn.js → prompt-select-styled-CDVjf5nV.js} +3 -3
- package/dist/{proxy-env-C05eD8Tt.js → proxy-env-C2sbN0UU.js} +1 -1
- package/dist/{proxy-fetch-C_2Ejh5T.js → proxy-fetch-CVSmQMZt.js} +1 -1
- package/dist/{pw-ai-BbxaV2Cy.js → pw-ai-CWE0qzH7.js} +15 -15
- package/dist/{qmd-manager-JjGGwn8R.js → qmd-manager-DMSLC2iu.js} +11 -11
- package/dist/{query-expansion-DkXzaUOH.js → query-expansion-MI1dZ5Nj.js} +6 -6
- package/dist/{redact-C-aJRv5O.js → redact-BXURioma.js} +1 -1
- package/dist/{register.maintenance-BoigTo1u.js → register.maintenance-CxSE7-Kl.js} +6 -6
- package/dist/{register.maintenance-RJM2wCjj.js → register.maintenance-DwOfJhoP.js} +7 -7
- package/dist/{register.onboard--1jxOBJy.js → register.onboard-CvYvmVAO.js} +2 -2
- package/dist/{register.onboard-BtBM_7Qe.js → register.onboard-D336Th_C.js} +2 -2
- package/dist/{register.setup-B_O283DR.js → register.setup-B43LcoaE.js} +2 -2
- package/dist/{register.setup-o2PFpqW-.js → register.setup-DaJKzoTH.js} +2 -2
- package/dist/{register.status-health-sessions-CVjLnoAQ.js → register.status-health-sessions-BteqJ3fo.js} +3 -3
- package/dist/{register.status-health-sessions-ByZDjDZf.js → register.status-health-sessions-DYYi2rkn.js} +3 -3
- package/dist/{register.subclis-Cm8zQPce.js → register.subclis-Cjl06Zry.js} +3 -3
- package/dist/{run-main-Bcwtj17t.js → run-main-DM79Bp3w.js} +4 -4
- package/dist/{run-with-concurrency-CYTs7gPY.js → run-with-concurrency-C5E9gJhP.js} +4 -4
- package/dist/runtime-whatsapp-login.runtime-BhVxslsH.js +14 -0
- package/dist/runtime-whatsapp-outbound.runtime-CFivqxoq.js +23 -0
- package/dist/{send-DDKqu28r.js → send-BWySsurX.js} +7 -7
- package/dist/{send-ChW15YPB.js → send-BlTVCcYd.js} +27 -27
- package/dist/{send-Cj0LCSvd.js → send-C87tIqIn.js} +7 -7
- package/dist/{send-q-l5fncb.js → send-Cpja8Q1N.js} +5 -5
- package/dist/{send-hOoCA9jX.js → send-OP60RbsK.js} +6 -6
- package/dist/{session-BzKpA5X4.js → session-DmXsj3JD.js} +8 -8
- package/dist/{skill-commands-CIcvUo1A.js → skill-commands-DEsgUSH3.js} +9 -9
- package/dist/{skills-DU6_fNPx.js → skills-OklkZyI1.js} +22 -22
- package/dist/slash-commands.runtime-gtQnheWz.js +17 -0
- package/dist/slash-dispatch.runtime-w1y_0I6t.js +57 -0
- package/dist/slash-skill-commands.runtime-CA_oN4df.js +21 -0
- package/dist/{status-CKWYXIIT.js → status-B-T9Cvvn.js} +2 -2
- package/dist/{status-CZ9ThIxK.js → status-XxtmLZrL.js} +2 -2
- package/dist/{status.update-CoOEUoUN.js → status.update-CY3ejLFL.js} +1 -1
- package/dist/{status.update-CO_hSO5b.js → status.update-mgzBYrgy.js} +1 -1
- package/dist/{store-DcxsUE2f.js → store-BNhebBGr.js} +2 -2
- package/dist/subagent-registry-runtime-HYpWtFUu.js +57 -0
- package/dist/{subsystem-CEiApUN8.js → subsystem-W834z9Wa.js} +16 -16
- package/dist/{tables-DTb5mzup.js → tables-XtcH-BaF.js} +1 -1
- package/dist/{target-errors-jNfnUab4.js → target-errors-CNzteBWz.js} +2 -2
- package/dist/{thinking-BJkp7vCP.js → thinking-X8yYhVf1.js} +6 -6
- package/dist/{tokens-tz04P2cO.js → tokens-DxcVnNVJ.js} +1 -1
- package/dist/{tool-images-DRyUUf-X.js → tool-images-B-4ixjYn.js} +2 -2
- package/dist/{update-cli-C1DALvzD.js → update-cli-CNBvXpVS.js} +8 -8
- package/dist/{update-cli-BDOF9xoT.js → update-cli-PgA0bnyk.js} +7 -7
- package/dist/{update-runner-C7Ixr_Ti.js → update-runner-BACLkDvl.js} +3 -3
- package/dist/{update-runner-Bw1MljLh.js → update-runner-D7HCCtTd.js} +3 -3
- package/dist/{utils-BFS4zK3g.js → utils-D2oM4XHm.js} +7 -7
- package/dist/{web-fbVaDaVW.js → web-B8rFiLYw.js} +56 -56
- package/dist/{whatsapp-actions-CMHMrQzp.js → whatsapp-actions-BPIXiPAR.js} +22 -22
- package/dist/{workspace-D6GL2anS.js → workspace-ZgWjBCAm.js} +21 -21
- package/package.json +1 -1
- package/dist/deliver-runtime-DGYhS7K1.js +0 -37
- package/dist/deps-send-discord.runtime-BJmezHoH.js +0 -27
- package/dist/deps-send-imessage.runtime-Dsq-J7FK.js +0 -26
- package/dist/deps-send-signal.runtime-2kRNCAkm.js +0 -25
- package/dist/deps-send-slack.runtime-DoM54spr.js +0 -23
- package/dist/deps-send-telegram.runtime-DGtmyBk2.js +0 -28
- package/dist/deps-send-whatsapp.runtime-B_ZiouDf.js +0 -61
- package/dist/image-runtime-BL3D208M.js +0 -30
- package/dist/manager-runtime-CJHBIXOb.js +0 -19
- package/dist/pi-model-discovery-runtime-BozG-CtU.js +0 -12
- package/dist/runtime-whatsapp-login.runtime-BU92rhCA.js +0 -14
- package/dist/runtime-whatsapp-outbound.runtime-DZy-sAPP.js +0 -23
- package/dist/slash-commands.runtime-CXJJf0jq.js +0 -17
- package/dist/slash-dispatch.runtime-CnDWfnhw.js +0 -57
- package/dist/slash-skill-commands.runtime-NPMuDGFx.js +0 -21
- package/dist/subagent-registry-runtime-R6EArAuY.js +0 -57
|
@@ -1,72 +1,72 @@
|
|
|
1
|
-
import { _ as toAgentModelListLike, a as resolveAgentDir, c as resolveAgentWorkspaceDir, d as resolveRunModelFallbacksOverride, f as resolveSessionAgentId, g as resolveAgentModelPrimaryValue, h as resolveAgentModelFallbackValues, i as resolveAgentConfig, l as resolveDefaultAgentId, n as hasConfiguredModelFallbacks, p as resolveSessionAgentIds, r as listAgentIds, s as resolveAgentSkillsFilter, t as runTasksWithConcurrency, u as resolveEffectiveModelFallbacks } from "./run-with-concurrency-
|
|
2
|
-
import { a as resolveGatewayPort, c as resolveStateDir, d as resolveRequiredHomeDir, l as expandHomePrefix, n as STATE_DIR, r as resolveConfigPath } from "./paths-
|
|
3
|
-
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-
|
|
1
|
+
import { _ as toAgentModelListLike, a as resolveAgentDir, c as resolveAgentWorkspaceDir, d as resolveRunModelFallbacksOverride, f as resolveSessionAgentId, g as resolveAgentModelPrimaryValue, h as resolveAgentModelFallbackValues, i as resolveAgentConfig, l as resolveDefaultAgentId, n as hasConfiguredModelFallbacks, p as resolveSessionAgentIds, r as listAgentIds, s as resolveAgentSkillsFilter, t as runTasksWithConcurrency, u as resolveEffectiveModelFallbacks } from "./run-with-concurrency-C5E9gJhP.js";
|
|
2
|
+
import { a as resolveGatewayPort, c as resolveStateDir, d as resolveRequiredHomeDir, l as expandHomePrefix, n as STATE_DIR, r as resolveConfigPath } from "./paths-C6TxBCvO.js";
|
|
3
|
+
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-W834z9Wa.js";
|
|
4
4
|
import { C as parseAgentSessionKey, S as isSubagentSessionKey, _ as isBlockedObjectKey, b as isAcpSessionKey, c as normalizeAgentId, d as resolveThreadSessionKeys, f as sanitizeAgentId, g as normalizeOptionalAccountId, h as normalizeAccountId$2, i as buildAgentPeerSessionKey, l as normalizeMainKey, m as DEFAULT_ACCOUNT_ID, n as DEFAULT_MAIN_KEY, o as classifySessionKeyShape, p as scopedHeartbeatWakeOptions, r as buildAgentMainSessionKey, s as isValidAgentId, t as DEFAULT_AGENT_ID, u as resolveAgentIdFromSessionKey, v as deriveSessionChatType, w as resolveThreadParentSessionKey, x as isCronSessionKey, y as getSubagentDepth } from "./session-key-DgdmD4k7.js";
|
|
5
|
-
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-
|
|
6
|
-
import { A as normalizeWindowsPathForComparison, _ as runExec, a as DEFAULT_IDENTITY_FILENAME, b as openBoundaryFile, f as loadWorkspaceBootstrapFiles, g as runCommandWithTimeout, l as ensureAgentWorkspace, m as resolveOpenClawPackageRoot, n as DEFAULT_AGENT_WORKSPACE_DIR, r as DEFAULT_BOOTSTRAP_FILENAME, u as filterBootstrapFilesForSession, v as spawnWithFallback, x as openBoundaryFileSync } from "./workspace-
|
|
7
|
-
import { i as logWarn, n as logError, r as logInfo, t as logDebug } from "./logger-
|
|
8
|
-
import { $ as resolveConfigSnapshotHash, $n as listProfilesForProvider, $t as normalizePluginHttpPath, A as getCustomProviderApiKey, An as unwrapKnownShellMultiplexerInvocation, At as isSupportedLocalAvatarExtension, B as markAuthProfileFailure, Bn as resolveSlackStreamingMode, C as OLLAMA_NATIVE_BASE_URL, Cn as matchAllowlist, D as buildStreamErrorAssistantMessage, Dn as isDispatchWrapperExecutable, Dt as isAvatarDataUrl, E as buildAssistantMessageWithZeroUsage, En as extractShellWrapperInlineCommand, Et as AVATAR_MAX_BYTES, Fn as applyMergePatch, Ft as safeStatSync, G as describeUnknownError$1, Gn as resolveAgentMaxConcurrent, Gt as normalizeChannelId$1, H as resolveProfilesUnavailableReason, Ht as getChatChannelMeta, I as resolveAuthProfileOrder, In as isSafeExecutableValue, It as applyTestPluginDefaults, J as parseDotPath, Jn as resolveShellEnvFallbackTimeoutMs, Jt as getActivePluginRegistryKey, K as isNonEmptyString, Kn as VERSION, Kt as normalizeChatChannelId, L as clearExpiredCooldowns, Ln as mapStreamingModeToSlackLegacyDraftStreamMode, Lt as normalizePluginsConfig, M as resolveApiKeyForProvider, Mn as SAFE_BIN_PROFILES, Mt as loadPluginManifestRegistry, N as resolveEnvApiKey, Nn as normalizeSafeBinProfileFixtures, Nt as discoverOpenClawPlugins, O as buildUsageWithNoCost, On as isShellWrapperExecutable, Ot as isAvatarHttpUrl, P as resolveModelAuthMode, Pn as resolveSafeBinProfiles, Pt as isPathInside, Qn as dedupeProfileIds, Qt as createPluginRegistry, R as getSoonestCooldownExpiry, Rn as resolveDiscordPreviewStreamMode, Rt as resolveEffectiveEnableState, S as retryAsync, Sn as DEFAULT_SAFE_BINS, T as buildAssistantMessage, Tn as resolveCommandResolutionFromArgv, U as resolveApiKeyForProfile, Ut as listChatChannels, V as markAuthProfileUsed, Vt as CHAT_CHANNEL_ORDER, W as resolveSecretRefValues, Wn as DEFAULT_SUBAGENT_MAX_SPAWN_DEPTH, Wt as normalizeAnyChannelId, X as loadConfig, Xn as isTruthyEnvValue, Xt as requireActivePluginRegistry, Yn as isDangerousHostEnvVarName, Z as readConfigFileSnapshot, Zn as resolveOwnerDisplaySetting, Zt as setActivePluginRegistry, _n as validateSafeBinArgv, _r as splitTrailingAuthProfile, a as isCliProvider, an as getConfigOverrides, bn as isWindowsPlatform, br as DEFAULT_PROVIDER, c as normalizeProviderId, cn as unsetConfigOverride, cr as formatCliCommand, ct as resolveIMessageAttachmentRoots, d as resolveDefaultModelForAgent, dn as setConfigValueAtPath, dt as parseNonNegativeByteSize, en as clearPluginCommands, er as markAuthProfileGood, et as writeConfigFile, f as resolveModelRefFromString, fn as unsetConfigValueAtPath, fr as normalizeSecretInput, ft as secretRefKey, gn as normalizeTrustedSafeBinDirs, gr as resolveSecretInputRef, h as resolveThinkingDefault, hn as listWritableExplicitTrustedSafeBinDirs, hr as normalizeResolvedSecretInputString, i as findNormalizedProviderValue, in as matchPluginCommand, ir as withFileLock, it as resolveTelegramCustomCommands, j as requireApiKey, jn as splitShellArgs, jt as validateJsonSchemaValue, k as getApiKeyForModel, kn as unwrapKnownDispatchWrapperInvocation, kt as isPathWithinRoot, ln as getConfigValueAtPath, lr as resolveCliName, lt as resolveIMessageRemoteAttachmentRoots, m as resolveSubagentSpawnModelSelection, mn as isTrustedSafeBinPath, mr as hasConfiguredSecretInput, n as buildConfiguredAllowlistKeys, nn as getPluginCommandSpecs, nr as resolveAuthStorePathForDisplay, nt as TELEGRAM_COMMAND_NAME_PATTERN, o as modelKey, on as resetConfigOverrides, ot as isInboundPathAllowed, p as resolveReasoningDefault, pn as getTrustedSafeBinDirs, pr as coerceSecretRef, q as isRecord$2, qn as getShellPathFromLoginShell, qt as getActivePluginRegistry, r as buildModelAliasIndex, rn as listPluginCommands, rr as resolveOpenClawAgentDir, rt as normalizeTelegramCommandName, s as normalizeModelRef$2, sn as setConfigOverride, t as buildAllowedModelSet, tn as executePluginCommand, tr as ensureAuthProfileStore, tt as validateConfigObjectWithPlugins, u as resolveConfiguredModelRef, un as parseConfigPath, ur as resolveAuthProfileDisplayLabel, ut as normalizeScpRemoteHost, vn as analyzeShellCommand, vr as DEFAULT_CONTEXT_TOKENS, w as createOllamaStreamFn, wn as resolveAllowlistCandidatePath, x as resolveRetryConfig, xn as splitCommandChain, yn as buildEnforcedShellCommand, yr as DEFAULT_MODEL, z as isProfileInCooldown, zn as resolveSlackNativeStreaming, zt as resolveMemorySlotDecision } from "./model-selection-
|
|
9
|
-
import { a as saveJsonFile, i as loadJsonFile } from "./github-copilot-token-
|
|
10
|
-
import { c as parseBooleanValue$1, n as MANIFEST_KEY, r as createInternalHookEvent, s as triggerInternalHook } from "./legacy-names-
|
|
5
|
+
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-D2oM4XHm.js";
|
|
6
|
+
import { A as normalizeWindowsPathForComparison, _ as runExec, a as DEFAULT_IDENTITY_FILENAME, b as openBoundaryFile, f as loadWorkspaceBootstrapFiles, g as runCommandWithTimeout, l as ensureAgentWorkspace, m as resolveOpenClawPackageRoot, n as DEFAULT_AGENT_WORKSPACE_DIR, r as DEFAULT_BOOTSTRAP_FILENAME, u as filterBootstrapFilesForSession, v as spawnWithFallback, x as openBoundaryFileSync } from "./workspace-ZgWjBCAm.js";
|
|
7
|
+
import { i as logWarn, n as logError, r as logInfo, t as logDebug } from "./logger-C53B395N.js";
|
|
8
|
+
import { $ as resolveConfigSnapshotHash, $n as listProfilesForProvider, $t as normalizePluginHttpPath, A as getCustomProviderApiKey, An as unwrapKnownShellMultiplexerInvocation, At as isSupportedLocalAvatarExtension, B as markAuthProfileFailure, Bn as resolveSlackStreamingMode, C as OLLAMA_NATIVE_BASE_URL, Cn as matchAllowlist, D as buildStreamErrorAssistantMessage, Dn as isDispatchWrapperExecutable, Dt as isAvatarDataUrl, E as buildAssistantMessageWithZeroUsage, En as extractShellWrapperInlineCommand, Et as AVATAR_MAX_BYTES, Fn as applyMergePatch, Ft as safeStatSync, G as describeUnknownError$1, Gn as resolveAgentMaxConcurrent, Gt as normalizeChannelId$1, H as resolveProfilesUnavailableReason, Ht as getChatChannelMeta, I as resolveAuthProfileOrder, In as isSafeExecutableValue, It as applyTestPluginDefaults, J as parseDotPath, Jn as resolveShellEnvFallbackTimeoutMs, Jt as getActivePluginRegistryKey, K as isNonEmptyString, Kn as VERSION, Kt as normalizeChatChannelId, L as clearExpiredCooldowns, Ln as mapStreamingModeToSlackLegacyDraftStreamMode, Lt as normalizePluginsConfig, M as resolveApiKeyForProvider, Mn as SAFE_BIN_PROFILES, Mt as loadPluginManifestRegistry, N as resolveEnvApiKey, Nn as normalizeSafeBinProfileFixtures, Nt as discoverOpenClawPlugins, O as buildUsageWithNoCost, On as isShellWrapperExecutable, Ot as isAvatarHttpUrl, P as resolveModelAuthMode, Pn as resolveSafeBinProfiles, Pt as isPathInside, Qn as dedupeProfileIds, Qt as createPluginRegistry, R as getSoonestCooldownExpiry, Rn as resolveDiscordPreviewStreamMode, Rt as resolveEffectiveEnableState, S as retryAsync, Sn as DEFAULT_SAFE_BINS, T as buildAssistantMessage, Tn as resolveCommandResolutionFromArgv, U as resolveApiKeyForProfile, Ut as listChatChannels, V as markAuthProfileUsed, Vt as CHAT_CHANNEL_ORDER, W as resolveSecretRefValues, Wn as DEFAULT_SUBAGENT_MAX_SPAWN_DEPTH, Wt as normalizeAnyChannelId, X as loadConfig, Xn as isTruthyEnvValue, Xt as requireActivePluginRegistry, Yn as isDangerousHostEnvVarName, Z as readConfigFileSnapshot, Zn as resolveOwnerDisplaySetting, Zt as setActivePluginRegistry, _n as validateSafeBinArgv, _r as splitTrailingAuthProfile, a as isCliProvider, an as getConfigOverrides, bn as isWindowsPlatform, br as DEFAULT_PROVIDER, c as normalizeProviderId, cn as unsetConfigOverride, cr as formatCliCommand, ct as resolveIMessageAttachmentRoots, d as resolveDefaultModelForAgent, dn as setConfigValueAtPath, dt as parseNonNegativeByteSize, en as clearPluginCommands, er as markAuthProfileGood, et as writeConfigFile, f as resolveModelRefFromString, fn as unsetConfigValueAtPath, fr as normalizeSecretInput, ft as secretRefKey, gn as normalizeTrustedSafeBinDirs, gr as resolveSecretInputRef, h as resolveThinkingDefault, hn as listWritableExplicitTrustedSafeBinDirs, hr as normalizeResolvedSecretInputString, i as findNormalizedProviderValue, in as matchPluginCommand, ir as withFileLock, it as resolveTelegramCustomCommands, j as requireApiKey, jn as splitShellArgs, jt as validateJsonSchemaValue, k as getApiKeyForModel, kn as unwrapKnownDispatchWrapperInvocation, kt as isPathWithinRoot, ln as getConfigValueAtPath, lr as resolveCliName, lt as resolveIMessageRemoteAttachmentRoots, m as resolveSubagentSpawnModelSelection, mn as isTrustedSafeBinPath, mr as hasConfiguredSecretInput, n as buildConfiguredAllowlistKeys, nn as getPluginCommandSpecs, nr as resolveAuthStorePathForDisplay, nt as TELEGRAM_COMMAND_NAME_PATTERN, o as modelKey, on as resetConfigOverrides, ot as isInboundPathAllowed, p as resolveReasoningDefault, pn as getTrustedSafeBinDirs, pr as coerceSecretRef, q as isRecord$2, qn as getShellPathFromLoginShell, qt as getActivePluginRegistry, r as buildModelAliasIndex, rn as listPluginCommands, rr as resolveOpenClawAgentDir, rt as normalizeTelegramCommandName, s as normalizeModelRef$2, sn as setConfigOverride, t as buildAllowedModelSet, tn as executePluginCommand, tr as ensureAuthProfileStore, tt as validateConfigObjectWithPlugins, u as resolveConfiguredModelRef, un as parseConfigPath, ur as resolveAuthProfileDisplayLabel, ut as normalizeScpRemoteHost, vn as analyzeShellCommand, vr as DEFAULT_CONTEXT_TOKENS, w as createOllamaStreamFn, wn as resolveAllowlistCandidatePath, x as resolveRetryConfig, xn as splitCommandChain, yn as buildEnforcedShellCommand, yr as DEFAULT_MODEL, z as isProfileInCooldown, zn as resolveSlackNativeStreaming, zt as resolveMemorySlotDecision } from "./model-selection-e9hodq0l.js";
|
|
9
|
+
import { a as saveJsonFile, i as loadJsonFile } from "./github-copilot-token-DDa7O18e.js";
|
|
10
|
+
import { c as parseBooleanValue$1, n as MANIFEST_KEY, r as createInternalHookEvent, s as triggerInternalHook } from "./legacy-names-BAiRv0I2.js";
|
|
11
11
|
import { t as parseDurationMs } from "./parse-duration-D8SaZ9Wv.js";
|
|
12
|
-
import { _ as normalizeAtHashSlug, a as normalizeReasoningLevel, b as normalizeStringEntriesLower, c as normalizeVerboseLevel, d as getChannelDock, f as listChannelDocks, g as resolveChannelGroupToolsPolicy, h as resolveChannelGroupRequireMention, i as normalizeElevatedLevel, l as resolveResponseUsageMode, m as resolveChannelGroupPolicy, n as formatXHighModelHint, o as normalizeThinkLevel, p as normalizeSignalMessagingTarget, s as normalizeUsageDisplay, t as formatThinkingLevels, u as supportsXHighThinking, v as normalizeHyphenSlug, y as normalizeStringEntries } from "./thinking-
|
|
13
|
-
import { a as stripSilentToken, i as isSilentReplyText, n as SILENT_REPLY_TOKEN, r as isSilentReplyPrefixText, t as HEARTBEAT_TOKEN } from "./tokens-
|
|
14
|
-
import { _ as normalizeChatType, a as normalizeWhatsAppTarget, b as resolveDiscordAccount, c as listTelegramAccountIds, d as buildChannelAccountBindings, f as listBindings, g as resolveSlackBotToken, h as resolveSlackAppToken, i as isWhatsAppGroupJid, l as resolveTelegramAccount, m as resolveSlackReplyToMode, n as listChannelPlugins, o as createTelegramActionGate, p as resolveSlackAccount, r as normalizeChannelId$2, s as listEnabledTelegramAccounts, t as getChannelPlugin, u as resolveTelegramToken, v as createDiscordActionGate, x as normalizeDiscordToken, y as listEnabledDiscordAccounts } from "./plugins-
|
|
15
|
-
import { a as logWebSelfId, h as resolveAccountEntry, i as getWebAuthAgeMs, m as webAuthExists, n as resolveWhatsAppAccount, o as logoutWeb, t as hasAnyWhatsAppAuth, u as readWebSelfId } from "./accounts-
|
|
16
|
-
import { a as resolveSlackWebClientOptions, c as buildSlackBlocksFallbackText, i as createSlackWebClient, l as parseSlackTarget, n as markdownToSlackMrkdwnChunks, o as parseSlackBlocksInput, r as normalizeSlackOutboundText, s as validateSlackBlocksArray, t as sendMessageSlack, u as resolveSlackChannelId } from "./send-
|
|
17
|
-
import { $ as stripUndefinedFields, A as unpinMessageDiscord, At as resolveChannelEntryMatchWithFallback, B as listScheduledEventsDiscord, C as editMessageDiscord, Ct as resolveDiscordSystemLocation, D as pinMessageDiscord, Dt as applyChannelMatchMeta, E as listThreadsDiscord, Et as fetchDiscord, 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 buildChannelKeyCandidates, P as fetchChannelInfoDiscord, Q as sendDiscordText, R as kickMemberDiscord, S as deleteMessageDiscord, St as formatDiscordUserTag, T as listPinsDiscord, Tt as DiscordApiError, U as listGuildEmojisDiscord, V as removeRoleDiscord, W as uploadEmojiDiscord, X as removeChannelPermissionDiscord, Y as moveChannelDiscord, Z as setChannelPermissionDiscord, _ as sendStickerDiscord, _t as resolveDiscordOwnerAllowFrom, a as sendDiscordComponentMessage, at as parseDiscordTarget, b as formatMention, bt as shouldEmitDiscordReactionNotification, c as parseDiscordComponentCustomId, ct as listDiscordDirectoryPeersLive, d as parseDiscordModalCustomIdForCarbon, dt as normalizeDiscordSlug, et as fetchChannelPermissionsDiscord, f as readDiscordComponentSpec, ft as resolveDiscordAllowListMatch, g as sendPollDiscord, gt as resolveDiscordOwnerAccess, h as sendMessageDiscord, ht as resolveDiscordMemberAccessState, i as removeReactionDiscord, it as createDiscordRestClient, j as addRoleDiscord, k as searchMessagesDiscord, kt as normalizeChannelSlug, l as parseDiscordComponentCustomIdForCarbon, lt as isDiscordGroupAllowedByPolicy, m as resolveDiscordModalEntry, mt as resolveDiscordGuildEntry, n as reactMessageDiscord, nt as chunkDiscordTextWithMode, o as createDiscordFormModal, ot as resolveDiscordChannelId, p as resolveDiscordComponentEntry, pt as resolveDiscordChannelConfigWithFallback, q as deleteChannelDiscord, r as removeOwnReactionsDiscord, rt as createDiscordClient, s as formatDiscordComponentEventText, st as listDiscordDirectoryGroupsLive, t as fetchReactionsDiscord, tt as hasAnyGuildPermissionDiscord, u as parseDiscordModalCustomId, ut as normalizeDiscordAllowList, v as sendVoiceMessageDiscord, vt as resolveDiscordShouldRequireMention, w as fetchMessageDiscord, wt as resolveTimestampMs, x as createThreadDiscord, xt as formatDiscordReactionEmoji, y as sendWebhookMessageDiscord, yt as resolveGroupDmAllow, z as listGuildChannelsDiscord } from "./send-
|
|
12
|
+
import { _ as normalizeAtHashSlug, a as normalizeReasoningLevel, b as normalizeStringEntriesLower, c as normalizeVerboseLevel, d as getChannelDock, f as listChannelDocks, g as resolveChannelGroupToolsPolicy, h as resolveChannelGroupRequireMention, i as normalizeElevatedLevel, l as resolveResponseUsageMode, m as resolveChannelGroupPolicy, n as formatXHighModelHint, o as normalizeThinkLevel, p as normalizeSignalMessagingTarget, s as normalizeUsageDisplay, t as formatThinkingLevels, u as supportsXHighThinking, v as normalizeHyphenSlug, y as normalizeStringEntries } from "./thinking-X8yYhVf1.js";
|
|
13
|
+
import { a as stripSilentToken, i as isSilentReplyText, n as SILENT_REPLY_TOKEN, r as isSilentReplyPrefixText, t as HEARTBEAT_TOKEN } from "./tokens-DxcVnNVJ.js";
|
|
14
|
+
import { _ as normalizeChatType, a as normalizeWhatsAppTarget, b as resolveDiscordAccount, c as listTelegramAccountIds, d as buildChannelAccountBindings, f as listBindings, g as resolveSlackBotToken, h as resolveSlackAppToken, i as isWhatsAppGroupJid, l as resolveTelegramAccount, m as resolveSlackReplyToMode, n as listChannelPlugins, o as createTelegramActionGate, p as resolveSlackAccount, r as normalizeChannelId$2, s as listEnabledTelegramAccounts, t as getChannelPlugin, u as resolveTelegramToken, v as createDiscordActionGate, x as normalizeDiscordToken, y as listEnabledDiscordAccounts } from "./plugins-rc2l4VJe.js";
|
|
15
|
+
import { a as logWebSelfId, h as resolveAccountEntry, i as getWebAuthAgeMs, m as webAuthExists, n as resolveWhatsAppAccount, o as logoutWeb, t as hasAnyWhatsAppAuth, u as readWebSelfId } from "./accounts-CAjupeYV.js";
|
|
16
|
+
import { a as resolveSlackWebClientOptions, c as buildSlackBlocksFallbackText, i as createSlackWebClient, l as parseSlackTarget, n as markdownToSlackMrkdwnChunks, o as parseSlackBlocksInput, r as normalizeSlackOutboundText, s as validateSlackBlocksArray, t as sendMessageSlack, u as resolveSlackChannelId } from "./send-OP60RbsK.js";
|
|
17
|
+
import { $ as stripUndefinedFields, A as unpinMessageDiscord, At as resolveChannelEntryMatchWithFallback, B as listScheduledEventsDiscord, C as editMessageDiscord, Ct as resolveDiscordSystemLocation, D as pinMessageDiscord, Dt as applyChannelMatchMeta, E as listThreadsDiscord, Et as fetchDiscord, 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 buildChannelKeyCandidates, P as fetchChannelInfoDiscord, Q as sendDiscordText, R as kickMemberDiscord, S as deleteMessageDiscord, St as formatDiscordUserTag, T as listPinsDiscord, Tt as DiscordApiError, U as listGuildEmojisDiscord, V as removeRoleDiscord, W as uploadEmojiDiscord, X as removeChannelPermissionDiscord, Y as moveChannelDiscord, Z as setChannelPermissionDiscord, _ as sendStickerDiscord, _t as resolveDiscordOwnerAllowFrom, a as sendDiscordComponentMessage, at as parseDiscordTarget, b as formatMention, bt as shouldEmitDiscordReactionNotification, c as parseDiscordComponentCustomId, ct as listDiscordDirectoryPeersLive, d as parseDiscordModalCustomIdForCarbon, dt as normalizeDiscordSlug, et as fetchChannelPermissionsDiscord, f as readDiscordComponentSpec, ft as resolveDiscordAllowListMatch, g as sendPollDiscord, gt as resolveDiscordOwnerAccess, h as sendMessageDiscord, ht as resolveDiscordMemberAccessState, i as removeReactionDiscord, it as createDiscordRestClient, j as addRoleDiscord, k as searchMessagesDiscord, kt as normalizeChannelSlug, l as parseDiscordComponentCustomIdForCarbon, lt as isDiscordGroupAllowedByPolicy, m as resolveDiscordModalEntry, mt as resolveDiscordGuildEntry, n as reactMessageDiscord, nt as chunkDiscordTextWithMode, o as createDiscordFormModal, ot as resolveDiscordChannelId, p as resolveDiscordComponentEntry, pt as resolveDiscordChannelConfigWithFallback, q as deleteChannelDiscord, r as removeOwnReactionsDiscord, rt as createDiscordClient, s as formatDiscordComponentEventText, st as listDiscordDirectoryGroupsLive, t as fetchReactionsDiscord, tt as hasAnyGuildPermissionDiscord, u as parseDiscordModalCustomId, ut as normalizeDiscordAllowList, v as sendVoiceMessageDiscord, vt as resolveDiscordShouldRequireMention, w as fetchMessageDiscord, wt as resolveTimestampMs, x as createThreadDiscord, xt as formatDiscordReactionEmoji, y as sendWebhookMessageDiscord, yt as resolveGroupDmAllow, z as listGuildChannelsDiscord } from "./send-BWySsurX.js";
|
|
18
18
|
import { n as generateSecureUuid, t as generateSecureToken } from "./secure-random-xpZo1jCG.js";
|
|
19
|
-
import { C as createReplyToModeFilterForChannel, D as normalizeTargetForProvider, E as normalizeChannelTargetInput, O as getGlobalHookRunner, S as shouldSuppressReasoningPayload, T as buildTargetResolverSignature, _ as applyReplyThreading, a as normalizeReplyPayloadsForDelivery, b as isRenderablePayload, c as splitMediaFromOutput, d as toInternalMessageReceivedContext, f as toInternalMessageTranscribedContext, g as applyReplyTagsToPayload, h as fireAndForgetHook, i as normalizeOutboundPayloadsForJson, k as initializeGlobalHookRunner, l as deriveInboundMessageHookContext, m as toPluginMessageReceivedEvent, n as formatOutboundPayloadLog, o as throwIfAborted, p as toPluginMessageContext, r as normalizeOutboundPayloads, s as parseReplyDirectives, t as deliverOutboundPayloads, u as toInternalMessagePreprocessedContext, v as filterMessagingToolDuplicates, w as resolveReplyToMode, x as shouldSuppressMessagingToolReplies, y as filterMessagingToolMediaDuplicates } from "./deliver-
|
|
20
|
-
import { a as logMessageQueued, c as logWebhookError, d as startDiagnosticHeartbeat, f as stopDiagnosticHeartbeat, h as isDiagnosticsEnabled, i as logMessageProcessed, l as logWebhookProcessed, m as emitDiagnosticEvent, n as logLaneDequeue, o as logSessionStateChange, p as getDiagnosticSessionState, r as logLaneEnqueue, t as diag, u as logWebhookReceived } from "./diagnostic-
|
|
21
|
-
import { n as resolveSignalAccount, t as listEnabledSignalAccounts } from "./accounts-
|
|
19
|
+
import { C as createReplyToModeFilterForChannel, D as normalizeTargetForProvider, E as normalizeChannelTargetInput, O as getGlobalHookRunner, S as shouldSuppressReasoningPayload, T as buildTargetResolverSignature, _ as applyReplyThreading, a as normalizeReplyPayloadsForDelivery, b as isRenderablePayload, c as splitMediaFromOutput, d as toInternalMessageReceivedContext, f as toInternalMessageTranscribedContext, g as applyReplyTagsToPayload, h as fireAndForgetHook, i as normalizeOutboundPayloadsForJson, k as initializeGlobalHookRunner, l as deriveInboundMessageHookContext, m as toPluginMessageReceivedEvent, n as formatOutboundPayloadLog, o as throwIfAborted, p as toPluginMessageContext, r as normalizeOutboundPayloads, s as parseReplyDirectives, t as deliverOutboundPayloads, u as toInternalMessagePreprocessedContext, v as filterMessagingToolDuplicates, w as resolveReplyToMode, x as shouldSuppressMessagingToolReplies, y as filterMessagingToolMediaDuplicates } from "./deliver-JkYjt9Qz.js";
|
|
20
|
+
import { a as logMessageQueued, c as logWebhookError, d as startDiagnosticHeartbeat, f as stopDiagnosticHeartbeat, h as isDiagnosticsEnabled, i as logMessageProcessed, l as logWebhookProcessed, m as emitDiagnosticEvent, n as logLaneDequeue, o as logSessionStateChange, p as getDiagnosticSessionState, r as logLaneEnqueue, t as diag, u as logWebhookReceived } from "./diagnostic-BGtFj4tU.js";
|
|
21
|
+
import { n as resolveSignalAccount, t as listEnabledSignalAccounts } from "./accounts-4l7ba973.js";
|
|
22
22
|
import { i as resolveTelegramTargetChatType, r as parseTelegramTarget } from "./targets-yNvvUZit.js";
|
|
23
|
-
import { A as mediaKindFromMime, C as imageMimeFromFormat, E as kindFromMime, O as MAX_IMAGE_BYTES, T as isGifMedia, _ as GATEWAY_CLIENT_IDS, b as detectMime, c as INTERNAL_MESSAGE_CHANNEL, d as isInternalMessageChannel, f as isMarkdownCapableMessageChannel, g as resolveMessageChannel, h as resolveGatewayMessageChannel, i as getImageMetadata, l as isDeliverableMessageChannel, m as normalizeMessageChannel, p as listDeliverableMessageChannels, s as resizeToJpeg, u as isGatewayMessageChannel, v as GATEWAY_CLIENT_MODES, w as isAudioFileName, x as extensionForMime, y as GATEWAY_CLIENT_NAMES } from "./image-ops-
|
|
24
|
-
import { $ as removeChannelAllowFromStoreEntry, A as expandTextLinks, B as resolveTelegramThreadSpec, C as buildSenderName, D as buildTelegramThreadParams, E as buildTelegramParentPeer, F as resolveTelegramForumThreadId, G as firstDefined$1, H as normalizeAllowFrom$2, I as resolveTelegramGroupAllowFromContext, J as resolveGroupAllowFromSources, K as isSenderIdAllowed, L as resolveTelegramMediaPlaceholder, M as hasBotMention, N as normalizeForwardedContext, O as buildTypingThreadParams, P as resolveTelegramDirectPeerId, Q as readChannelAllowFromStore, R as resolveTelegramReplyId, S as buildSenderLabel, T as buildTelegramGroupPeerId, U as normalizeDmAllowFromWithStore$1, V as isSenderAllowed$1, W as resolveSenderAllowMatch$1, X as toLocationContext, Y as formatLocationText, Z as addChannelAllowFromStoreEntry, _ as splitTelegramCaption, a as reactMessageTelegram, at as isVoiceCompatibleAudio, b as resolveCronStorePath, c as sendStickerTelegram, d as isRecoverableTelegramNetworkError, et as upsertChannelPairingRequest, f as markdownToTelegramChunks, g as resolveTelegramFetch, h as wrapFileReferencesInHtml, i as editMessageTelegram, it as listPairingChannels, j as extractTelegramLocation, k as describeReplyTarget, l as resolveTelegramVoiceSend, m as renderTelegramHtmlText, n as createForumTopicTelegram, nt as writeJsonFileAtomically, o as sendMessageTelegram, p as markdownToTelegramHtml, q as mergeDmAllowFromSources, r as deleteMessageTelegram, rt as getPairingAdapter, s as sendPollTelegram, t as buildInlineKeyboard, tt as readJsonFileWithFallback, u as wasSentByBot, v as withTelegramApiErrorLogging, w as buildTelegramGroupFrom, x as buildGroupLabel, y as loadCronStore, z as resolveTelegramStreamMode } from "./send-
|
|
25
|
-
import { n as discoverModels, t as discoverAuthStorage } from "./pi-model-discovery-
|
|
26
|
-
import { $ as deliveryContextKey, $t as matchesAnyGlobPattern, A as isTransientHttpError, At as resolveGroupSessionKey, B as parseSessionThreadInfo, Bt as resolveGatewayCredentialsFromConfig, C as isCompactionFailureError, Ct as setSessionRuntimeModel, D as isLikelyContextOverflowError, Dt as resolveMainSessionKey, E as isFailoverErrorMessage, Et as resolveExplicitAgentSessionKey, F as isTimeoutErrorMessage, Ft as resolveBrowserConfig, G as readSessionUpdatedAt, Gt as collectExplicitAllowlist, Ht as resolveSandboxConfigForAgent, I as ensureSandboxWorkspaceForSession, It as resolveProfile, J as updateSessionStore, Jt as stripPluginOnlyAllowlist, K as recordSessionMetaFromInbound, Kt as expandPolicyWithPluginGroups, L as resolveSandboxContext, Lt as getBridgeAuthForPort, M as parseImageSizeError, Mt as resolveSessionLockMaxHoldFromTimeout, N as sanitizeUserFacingText, Nt as createBrowserRouteContext, O as isRateLimitAssistantError, Ot as deriveSessionMetaPatch, P as isAuthPermanentErrorMessage, Pt as registerBrowserRoutes, Q as deliveryContextFromSession, Qt as compileGlobPatterns, R as resolveSandboxRuntimeStatus, Rt as ensureBrowserControlAuth, S as isCloudCodeAssistFormatError, St as resolveFreshSessionTotalTokens, T as isFailoverAssistantError, U as resolveAndPersistSessionFile, Ut as applyOwnerOnlyToolPolicy, V as appendAssistantMessageToSessionTranscript, Vt as trimToUndefined$1, W as loadSessionStore, Wt as buildPluginToolGroups, X as isCacheEnabled, Xt as normalizeToolName, Y as updateSessionStoreEntry, Yt as expandToolGroups, Z as resolveCacheTtlMs$1, Zt as resolveToolProfilePolicy, _ as formatBillingErrorMessage, _t as resolveSessionResetPolicy, a as isMessagingToolDuplicateNormalized, an as sanitizeGoogleTurnOrdering, at as capArrayByJsonBytes, b as isAuthAssistantError, bt as DEFAULT_RESET_TRIGGERS, c as extractToolCallsFromAssistant, ct as parseInlineDirectives$1, d as downgradeOpenAIFunctionCallReasoningPairs, dt as hasInterSessionUserProvenance, en as buildBootstrapContextFiles, et as mergeDeliveryContext, f as downgradeOpenAIReasoningBlocks, ft as normalizeInputProvenance, g as formatAssistantErrorText, gt as resolveChannelResetConfig, h as classifyFailoverReason, ht as evaluateSessionFreshness, in as resolveBootstrapTotalMaxChars, it as archiveSessionTranscripts, j as parseImageDimensionError, jt as acquireSessionWriteLock, k as isRawApiErrorPayload, kt as resolveConversationLabel, l as extractToolResultId, lt as INPUT_PROVENANCE_KIND_VALUES, m as BILLING_ERROR_USER_MESSAGE, mt as resolveSessionKey, n as validateGeminiTurns, nn as resolveBootstrapMaxChars, nt as normalizeSessionDeliveryFields, o as normalizeTextForComparison, ot as countToolResults, p as isGoogleModelApi, pt as jsonUtf8Bytes, q as updateLastRoute, qt as mergeAlsoAllowPolicy, r as pickFallbackThinkingLevel, rn as resolveBootstrapPromptTruncationWarningMode, rt as normalizeAccountId$3, s as sanitizeSessionMessagesImages, st as extractToolCallNames, t as validateAnthropicTurns, tn as ensureSessionHeader, tt as normalizeDeliveryContext, u as sanitizeToolCallIdsForCloudCodeAssist, ut as applyInputProvenanceToUserMessage, v as formatRawAssistantErrorForUi, vt as resolveSessionResetType, w as isContextOverflowError, wt as canonicalizeMainSessionAlias, x as isBillingAssistantError, xt as mergeSessionEntry, y as getApiErrorPayloadFingerprint, yt as resolveThreadFlag, z as extractDeliveryInfo, zt as resolveBrowserControlAuth } from "./pi-embedded-helpers-
|
|
27
|
-
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-
|
|
28
|
-
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-
|
|
29
|
-
import { t as PATH_ALIAS_POLICIES } from "./path-alias-guards-
|
|
30
|
-
import { i as testRegexWithBoundedInput, r as compileSafeRegex, t as redactSensitiveText } from "./redact-
|
|
31
|
-
import { i as formatUncaughtError, o as readErrorName, r as formatErrorMessage } from "./errors-
|
|
32
|
-
import { a as readFileWithinRoot, c as writeFileWithinRoot, i as openFileWithinRoot, n as copyFileWithinRoot, r as createRootScopedReadFile, t as SafeOpenError } from "./fs-safe-
|
|
33
|
-
import { a as isBlockedHostnameOrIp, c as normalizeHostname, n as SsrFBlockedError } from "./proxy-env-
|
|
34
|
-
import { i as saveMediaBuffer, r as getMediaDir, t as MEDIA_MAX_BYTES } from "./store-
|
|
23
|
+
import { A as mediaKindFromMime, C as imageMimeFromFormat, E as kindFromMime, O as MAX_IMAGE_BYTES, T as isGifMedia, _ as GATEWAY_CLIENT_IDS, b as detectMime, c as INTERNAL_MESSAGE_CHANNEL, d as isInternalMessageChannel, f as isMarkdownCapableMessageChannel, g as resolveMessageChannel, h as resolveGatewayMessageChannel, i as getImageMetadata, l as isDeliverableMessageChannel, m as normalizeMessageChannel, p as listDeliverableMessageChannels, s as resizeToJpeg, u as isGatewayMessageChannel, v as GATEWAY_CLIENT_MODES, w as isAudioFileName, x as extensionForMime, y as GATEWAY_CLIENT_NAMES } from "./image-ops-D7mq-4y1.js";
|
|
24
|
+
import { $ as removeChannelAllowFromStoreEntry, A as expandTextLinks, B as resolveTelegramThreadSpec, C as buildSenderName, D as buildTelegramThreadParams, E as buildTelegramParentPeer, F as resolveTelegramForumThreadId, G as firstDefined$1, H as normalizeAllowFrom$2, I as resolveTelegramGroupAllowFromContext, J as resolveGroupAllowFromSources, K as isSenderIdAllowed, L as resolveTelegramMediaPlaceholder, M as hasBotMention, N as normalizeForwardedContext, O as buildTypingThreadParams, P as resolveTelegramDirectPeerId, Q as readChannelAllowFromStore, R as resolveTelegramReplyId, S as buildSenderLabel, T as buildTelegramGroupPeerId, U as normalizeDmAllowFromWithStore$1, V as isSenderAllowed$1, W as resolveSenderAllowMatch$1, X as toLocationContext, Y as formatLocationText, Z as addChannelAllowFromStoreEntry, _ as splitTelegramCaption, a as reactMessageTelegram, at as isVoiceCompatibleAudio, b as resolveCronStorePath, c as sendStickerTelegram, d as isRecoverableTelegramNetworkError, et as upsertChannelPairingRequest, f as markdownToTelegramChunks, g as resolveTelegramFetch, h as wrapFileReferencesInHtml, i as editMessageTelegram, it as listPairingChannels, j as extractTelegramLocation, k as describeReplyTarget, l as resolveTelegramVoiceSend, m as renderTelegramHtmlText, n as createForumTopicTelegram, nt as writeJsonFileAtomically, o as sendMessageTelegram, p as markdownToTelegramHtml, q as mergeDmAllowFromSources, r as deleteMessageTelegram, rt as getPairingAdapter, s as sendPollTelegram, t as buildInlineKeyboard, tt as readJsonFileWithFallback, u as wasSentByBot, v as withTelegramApiErrorLogging, w as buildTelegramGroupFrom, x as buildGroupLabel, y as loadCronStore, z as resolveTelegramStreamMode } from "./send-BlTVCcYd.js";
|
|
25
|
+
import { n as discoverModels, t as discoverAuthStorage } from "./pi-model-discovery-32EFg27L.js";
|
|
26
|
+
import { $ as deliveryContextKey, $t as matchesAnyGlobPattern, A as isTransientHttpError, At as resolveGroupSessionKey, B as parseSessionThreadInfo, Bt as resolveGatewayCredentialsFromConfig, C as isCompactionFailureError, Ct as setSessionRuntimeModel, D as isLikelyContextOverflowError, Dt as resolveMainSessionKey, E as isFailoverErrorMessage, Et as resolveExplicitAgentSessionKey, F as isTimeoutErrorMessage, Ft as resolveBrowserConfig, G as readSessionUpdatedAt, Gt as collectExplicitAllowlist, Ht as resolveSandboxConfigForAgent, I as ensureSandboxWorkspaceForSession, It as resolveProfile, J as updateSessionStore, Jt as stripPluginOnlyAllowlist, K as recordSessionMetaFromInbound, Kt as expandPolicyWithPluginGroups, L as resolveSandboxContext, Lt as getBridgeAuthForPort, M as parseImageSizeError, Mt as resolveSessionLockMaxHoldFromTimeout, N as sanitizeUserFacingText, Nt as createBrowserRouteContext, O as isRateLimitAssistantError, Ot as deriveSessionMetaPatch, P as isAuthPermanentErrorMessage, Pt as registerBrowserRoutes, Q as deliveryContextFromSession, Qt as compileGlobPatterns, R as resolveSandboxRuntimeStatus, Rt as ensureBrowserControlAuth, S as isCloudCodeAssistFormatError, St as resolveFreshSessionTotalTokens, T as isFailoverAssistantError, U as resolveAndPersistSessionFile, Ut as applyOwnerOnlyToolPolicy, V as appendAssistantMessageToSessionTranscript, Vt as trimToUndefined$1, W as loadSessionStore, Wt as buildPluginToolGroups, X as isCacheEnabled, Xt as normalizeToolName, Y as updateSessionStoreEntry, Yt as expandToolGroups, Z as resolveCacheTtlMs$1, Zt as resolveToolProfilePolicy, _ as formatBillingErrorMessage, _t as resolveSessionResetPolicy, a as isMessagingToolDuplicateNormalized, an as sanitizeGoogleTurnOrdering, at as capArrayByJsonBytes, b as isAuthAssistantError, bt as DEFAULT_RESET_TRIGGERS, c as extractToolCallsFromAssistant, ct as parseInlineDirectives$1, d as downgradeOpenAIFunctionCallReasoningPairs, dt as hasInterSessionUserProvenance, en as buildBootstrapContextFiles, et as mergeDeliveryContext, f as downgradeOpenAIReasoningBlocks, ft as normalizeInputProvenance, g as formatAssistantErrorText, gt as resolveChannelResetConfig, h as classifyFailoverReason, ht as evaluateSessionFreshness, in as resolveBootstrapTotalMaxChars, it as archiveSessionTranscripts, j as parseImageDimensionError, jt as acquireSessionWriteLock, k as isRawApiErrorPayload, kt as resolveConversationLabel, l as extractToolResultId, lt as INPUT_PROVENANCE_KIND_VALUES, m as BILLING_ERROR_USER_MESSAGE, mt as resolveSessionKey, n as validateGeminiTurns, nn as resolveBootstrapMaxChars, nt as normalizeSessionDeliveryFields, o as normalizeTextForComparison, ot as countToolResults, p as isGoogleModelApi, pt as jsonUtf8Bytes, q as updateLastRoute, qt as mergeAlsoAllowPolicy, r as pickFallbackThinkingLevel, rn as resolveBootstrapPromptTruncationWarningMode, rt as normalizeAccountId$3, s as sanitizeSessionMessagesImages, st as extractToolCallNames, t as validateAnthropicTurns, tn as ensureSessionHeader, tt as normalizeDeliveryContext, u as sanitizeToolCallIdsForCloudCodeAssist, ut as applyInputProvenanceToUserMessage, v as formatRawAssistantErrorForUi, vt as resolveSessionResetType, w as isContextOverflowError, wt as canonicalizeMainSessionAlias, x as isBillingAssistantError, xt as mergeSessionEntry, y as getApiErrorPayloadFingerprint, yt as resolveThreadFlag, z as extractDeliveryInfo, zt as resolveBrowserControlAuth } from "./pi-embedded-helpers-CE9KKP1Q.js";
|
|
27
|
+
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-palWvTtp.js";
|
|
28
|
+
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-OklkZyI1.js";
|
|
29
|
+
import { t as PATH_ALIAS_POLICIES } from "./path-alias-guards-It4BBRdm.js";
|
|
30
|
+
import { i as testRegexWithBoundedInput, r as compileSafeRegex, t as redactSensitiveText } from "./redact-BXURioma.js";
|
|
31
|
+
import { i as formatUncaughtError, o as readErrorName, r as formatErrorMessage } from "./errors-C1YF712P.js";
|
|
32
|
+
import { a as readFileWithinRoot, c as writeFileWithinRoot, i as openFileWithinRoot, n as copyFileWithinRoot, r as createRootScopedReadFile, t as SafeOpenError } from "./fs-safe-BLpOReWZ.js";
|
|
33
|
+
import { a as isBlockedHostnameOrIp, c as normalizeHostname, n as SsrFBlockedError } from "./proxy-env-C2sbN0UU.js";
|
|
34
|
+
import { i as saveMediaBuffer, r as getMediaDir, t as MEDIA_MAX_BYTES } from "./store-BNhebBGr.js";
|
|
35
35
|
import { n as readJsonFile, r as writeJsonAtomic, t as createAsyncLock } from "./json-files-D2dc4Wmw.js";
|
|
36
|
-
import { t as resolveIMessageAccount } from "./accounts-
|
|
37
|
-
import { i as resolveSessionTranscriptPath, n as resolveSessionFilePath, o as resolveSessionTranscriptsDirForAgent, r as resolveSessionFilePathOptions, s as resolveStorePath, t as resolveDefaultSessionStorePath } from "./paths-
|
|
36
|
+
import { t as resolveIMessageAccount } from "./accounts-k5nTdi32.js";
|
|
37
|
+
import { i as resolveSessionTranscriptPath, n as resolveSessionFilePath, o as resolveSessionTranscriptsDirForAgent, r as resolveSessionFilePathOptions, s as resolveStorePath, t as resolveDefaultSessionStorePath } from "./paths-CZ0nrg7g.js";
|
|
38
38
|
import { n as onSessionTranscriptUpdate, t as emitSessionTranscriptUpdate } from "./transcript-events-Db-3GZzv.js";
|
|
39
|
-
import { a as canonicalizeBase64, i as resolveImageSanitizationLimits, n as sanitizeImageBlocks, o as estimateBase64DecodedBytes, r as sanitizeToolResultImages } from "./tool-images-
|
|
39
|
+
import { a as canonicalizeBase64, i as resolveImageSanitizationLimits, n as sanitizeImageBlocks, o as estimateBase64DecodedBytes, r as sanitizeToolResultImages } from "./tool-images-B-4ixjYn.js";
|
|
40
40
|
import { i as withNormalizedTimestamp, n as resolveUserTimeFormat, r as resolveUserTimezone, t as formatUserTime } from "./date-time-Ce6oKo3v.js";
|
|
41
|
-
import { C as minimaxUnderstandImage, S as extractTextFromChatContent, _ as formatToolSummary, a as resolveProviderVisionModelFromConfig, b as findCodeRegions, c as extractThinkingFromTaggedStream, d as inferToolMetaFromArgs, f as isAssistantMessage, g as stripThinkingTagsFromText, h as stripMinimaxToolCallXml, i as decodeDataUrl, l as extractThinkingFromTaggedText, m as stripDowngradedToolCallText, n as coerceImageAssistantText, o as extractAssistantText$1, p as promoteThinkingTagsToBlocks, r as coerceImageModelConfig, s as extractAssistantThinking, u as formatReasoningMessage, v as resolveToolDisplay, w as ensureOpenClawModelsJson, x as isInsideCode, y as stripReasoningTagsFromText } from "./image-
|
|
42
|
-
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-
|
|
43
|
-
import { a as getDefaultMediaLocalRoots, i as getAgentScopedMediaLocalRoots, n as fetchRemoteMedia, r as readResponseWithLimit, t as MediaFetchError } from "./fetch-
|
|
41
|
+
import { C as minimaxUnderstandImage, S as extractTextFromChatContent, _ as formatToolSummary, a as resolveProviderVisionModelFromConfig, b as findCodeRegions, c as extractThinkingFromTaggedStream, d as inferToolMetaFromArgs, f as isAssistantMessage, g as stripThinkingTagsFromText, h as stripMinimaxToolCallXml, i as decodeDataUrl, l as extractThinkingFromTaggedText, m as stripDowngradedToolCallText, n as coerceImageAssistantText, o as extractAssistantText$1, p as promoteThinkingTagsToBlocks, r as coerceImageModelConfig, s as extractAssistantThinking, u as formatReasoningMessage, v as resolveToolDisplay, w as ensureOpenClawModelsJson, x as isInsideCode, y as stripReasoningTagsFromText } from "./image-BlRI3dXw.js";
|
|
42
|
+
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-CawngPvE.js";
|
|
43
|
+
import { a as getDefaultMediaLocalRoots, i as getAgentScopedMediaLocalRoots, n as fetchRemoteMedia, r as readResponseWithLimit, t as MediaFetchError } from "./fetch-_iocPLV2.js";
|
|
44
44
|
import { n as fetchWithTimeout, t as bindAbortRelay } from "./fetch-timeout-CSrVj6X7.js";
|
|
45
|
-
import { n as withStrictGuardedFetchMode, r as withTrustedEnvProxyGuardedFetchMode, t as fetchWithSsrFGuard } from "./fetch-guard-
|
|
46
|
-
import { t as makeProxyFetch } from "./proxy-fetch-
|
|
47
|
-
import { _ as isSafeFenceBreak, a as loadWebMedia, c as chunkByNewline, d as chunkMarkdownTextWithMode, f as chunkText, g as findFenceSpanAt, h as resolveTextChunkLimit, i as getDefaultLocalRoots, m as resolveChunkMode, o as loadWebMediaRaw, p as chunkTextWithMode, s as resolveMarkdownTableMode, u as chunkMarkdownText, v as parseFenceSpans } from "./ir-
|
|
48
|
-
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-
|
|
49
|
-
import { _ as isRestartEnabled, a as listChatCommandsForConfig, c as maybeResolveTextAlias, d as resolveCommandArgChoices, f as resolveCommandArgMenu, g as isNativeCommandsExplicitlyDisabled, h as isCommandFlagEnabled, i as listChatCommands, l as normalizeCommandBody, m as shouldHandleTextCommands, n as findCommandByNativeName, o as listNativeCommandSpecs, p as serializeCommandArgs, r as isCommandEnabled, s as listNativeCommandSpecsForConfig, t as buildCommandTextFromArgs, u as parseCommandArgs, v as resolveNativeCommandsEnabled, y as resolveNativeSkillsEnabled } from "./commands-registry-
|
|
50
|
-
import { a as getRemoteSkillEligibility, c as pruneExpiredPending, i as resolveSkillCommandInvocation, l as resolvePairingPaths, n as listSkillCommandsForAgents, o as ensureSkillsWatcher, r as listSkillCommandsForWorkspace, s as getSkillsSnapshotVersion, t as listReservedChatSlashCommandNames } from "./skill-commands-
|
|
45
|
+
import { n as withStrictGuardedFetchMode, r as withTrustedEnvProxyGuardedFetchMode, t as fetchWithSsrFGuard } from "./fetch-guard-CiQUuV0r.js";
|
|
46
|
+
import { t as makeProxyFetch } from "./proxy-fetch-CVSmQMZt.js";
|
|
47
|
+
import { _ as isSafeFenceBreak, a as loadWebMedia, c as chunkByNewline, d as chunkMarkdownTextWithMode, f as chunkText, g as findFenceSpanAt, h as resolveTextChunkLimit, i as getDefaultLocalRoots, m as resolveChunkMode, o as loadWebMediaRaw, p as chunkTextWithMode, s as resolveMarkdownTableMode, u as chunkMarkdownText, v as parseFenceSpans } from "./ir-Dpg87zYv.js";
|
|
48
|
+
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-CNzteBWz.js";
|
|
49
|
+
import { _ as isRestartEnabled, a as listChatCommandsForConfig, c as maybeResolveTextAlias, d as resolveCommandArgChoices, f as resolveCommandArgMenu, g as isNativeCommandsExplicitlyDisabled, h as isCommandFlagEnabled, i as listChatCommands, l as normalizeCommandBody, m as shouldHandleTextCommands, n as findCommandByNativeName, o as listNativeCommandSpecs, p as serializeCommandArgs, r as isCommandEnabled, s as listNativeCommandSpecsForConfig, t as buildCommandTextFromArgs, u as parseCommandArgs, v as resolveNativeCommandsEnabled, y as resolveNativeSkillsEnabled } from "./commands-registry-A3LstXeY.js";
|
|
50
|
+
import { a as getRemoteSkillEligibility, c as pruneExpiredPending, i as resolveSkillCommandInvocation, l as resolvePairingPaths, n as listSkillCommandsForAgents, o as ensureSkillsWatcher, r as listSkillCommandsForWorkspace, s as getSkillsSnapshotVersion, t as listReservedChatSlashCommandNames } from "./skill-commands-DEsgUSH3.js";
|
|
51
51
|
import { n as wrapFetchWithAbortSignal, t as resolveFetch } from "./fetch-CTN5ATFT.js";
|
|
52
52
|
import { n as recordCommandPoll, r as resetCommandPollCount } from "./command-poll-backoff-WKa7J8FO.js";
|
|
53
|
-
import { n as recordChannelActivity, r as createDiscordRetryRunner, t as getChannelActivity } from "./channel-activity-
|
|
53
|
+
import { n as recordChannelActivity, r as createDiscordRetryRunner, t as getChannelActivity } from "./channel-activity-Hho38eZq.js";
|
|
54
54
|
import { t as buildOutboundMediaLoadOptions } from "./load-options-BXqJ6gxm.js";
|
|
55
55
|
import { n as normalizePollInput } from "./polls-CVGKOEN8.js";
|
|
56
|
-
import { t as convertMarkdownTables } from "./tables-
|
|
57
|
-
import { a as signalCheck, i as resolveSignalRpcContext, n as sendReadReceiptSignal, o as signalRpcRequest, r as sendTypingSignal, s as streamSignalEvents, t as sendMessageSignal } from "./send-
|
|
58
|
-
import { a as isAllowedIMessageSender, i as formatIMessageChatTarget, n as createIMessageRpcClient, o as normalizeIMessageHandle, r as DEFAULT_IMESSAGE_PROBE_TIMEOUT_MS, s as parseIMessageTarget, t as sendMessageIMessage } from "./send-
|
|
59
|
-
import { i as redactIdentifier, t as getActiveWebListener } from "./active-listener-
|
|
60
|
-
import { n as resolveMemorySearchConfig } from "./manager-
|
|
61
|
-
import { f as listMemoryFiles, p as normalizeExtraMemoryPaths } from "./query-expansion-
|
|
56
|
+
import { t as convertMarkdownTables } from "./tables-XtcH-BaF.js";
|
|
57
|
+
import { a as signalCheck, i as resolveSignalRpcContext, n as sendReadReceiptSignal, o as signalRpcRequest, r as sendTypingSignal, s as streamSignalEvents, t as sendMessageSignal } from "./send-Cpja8Q1N.js";
|
|
58
|
+
import { a as isAllowedIMessageSender, i as formatIMessageChatTarget, n as createIMessageRpcClient, o as normalizeIMessageHandle, r as DEFAULT_IMESSAGE_PROBE_TIMEOUT_MS, s as parseIMessageTarget, t as sendMessageIMessage } from "./send-C87tIqIn.js";
|
|
59
|
+
import { i as redactIdentifier, t as getActiveWebListener } from "./active-listener-D9FARjMd.js";
|
|
60
|
+
import { n as resolveMemorySearchConfig } from "./manager-Dfrejf6z.js";
|
|
61
|
+
import { f as listMemoryFiles, p as normalizeExtraMemoryPaths } from "./query-expansion-MI1dZ5Nj.js";
|
|
62
62
|
import { createRequire } from "node:module";
|
|
63
|
-
import * as fs$
|
|
63
|
+
import * as fs$1 from "node:fs/promises";
|
|
64
64
|
import fs from "node:fs/promises";
|
|
65
65
|
import os, { homedir } from "node:os";
|
|
66
66
|
import * as path$1 from "node:path";
|
|
67
67
|
import path, { isAbsolute } from "node:path";
|
|
68
|
-
import
|
|
69
|
-
import
|
|
68
|
+
import syncFs, { existsSync, mkdirSync, mkdtempSync, promises, readFileSync, renameSync, rmSync, statSync, unlinkSync, writeFileSync } from "node:fs";
|
|
69
|
+
import JSON5 from "json5";
|
|
70
70
|
import { inspect, isDeepStrictEqual, promisify } from "node:util";
|
|
71
71
|
import { execFile, spawn, spawnSync } from "node:child_process";
|
|
72
72
|
import { fileURLToPath } from "node:url";
|
|
@@ -3172,7 +3172,7 @@ async function resolveOpenClawDocsPath(params) {
|
|
|
3172
3172
|
const workspaceDir = params.workspaceDir?.trim();
|
|
3173
3173
|
if (workspaceDir) {
|
|
3174
3174
|
const workspaceDocs = path.join(workspaceDir, "docs");
|
|
3175
|
-
if (
|
|
3175
|
+
if (syncFs.existsSync(workspaceDocs)) return workspaceDocs;
|
|
3176
3176
|
}
|
|
3177
3177
|
const packageRoot = await resolveOpenClawPackageRoot({
|
|
3178
3178
|
cwd: params.cwd,
|
|
@@ -3181,7 +3181,7 @@ async function resolveOpenClawDocsPath(params) {
|
|
|
3181
3181
|
});
|
|
3182
3182
|
if (!packageRoot) return null;
|
|
3183
3183
|
const packageDocs = path.join(packageRoot, "docs");
|
|
3184
|
-
return
|
|
3184
|
+
return syncFs.existsSync(packageDocs) ? packageDocs : null;
|
|
3185
3185
|
}
|
|
3186
3186
|
|
|
3187
3187
|
//#endregion
|
|
@@ -6298,7 +6298,7 @@ function resolveDefaultIdentityPath() {
|
|
|
6298
6298
|
return path.join(resolveStateDir(), "identity", "device.json");
|
|
6299
6299
|
}
|
|
6300
6300
|
function ensureDir$2(filePath) {
|
|
6301
|
-
|
|
6301
|
+
syncFs.mkdirSync(path.dirname(filePath), { recursive: true });
|
|
6302
6302
|
}
|
|
6303
6303
|
const ED25519_SPKI_PREFIX = Buffer.from("302a300506032b6570032100", "hex");
|
|
6304
6304
|
function base64UrlEncode(buf) {
|
|
@@ -6334,8 +6334,8 @@ function generateIdentity() {
|
|
|
6334
6334
|
}
|
|
6335
6335
|
function loadOrCreateDeviceIdentity(filePath = resolveDefaultIdentityPath()) {
|
|
6336
6336
|
try {
|
|
6337
|
-
if (
|
|
6338
|
-
const raw =
|
|
6337
|
+
if (syncFs.existsSync(filePath)) {
|
|
6338
|
+
const raw = syncFs.readFileSync(filePath, "utf8");
|
|
6339
6339
|
const parsed = JSON.parse(raw);
|
|
6340
6340
|
if (parsed?.version === 1 && typeof parsed.deviceId === "string" && typeof parsed.publicKeyPem === "string" && typeof parsed.privateKeyPem === "string") {
|
|
6341
6341
|
const derivedId = fingerprintPublicKey(parsed.publicKeyPem);
|
|
@@ -6344,9 +6344,9 @@ function loadOrCreateDeviceIdentity(filePath = resolveDefaultIdentityPath()) {
|
|
|
6344
6344
|
...parsed,
|
|
6345
6345
|
deviceId: derivedId
|
|
6346
6346
|
};
|
|
6347
|
-
|
|
6347
|
+
syncFs.writeFileSync(filePath, `${JSON.stringify(updated, null, 2)}\n`, { mode: 384 });
|
|
6348
6348
|
try {
|
|
6349
|
-
|
|
6349
|
+
syncFs.chmodSync(filePath, 384);
|
|
6350
6350
|
} catch {}
|
|
6351
6351
|
return {
|
|
6352
6352
|
deviceId: derivedId,
|
|
@@ -6371,9 +6371,9 @@ function loadOrCreateDeviceIdentity(filePath = resolveDefaultIdentityPath()) {
|
|
|
6371
6371
|
privateKeyPem: identity.privateKeyPem,
|
|
6372
6372
|
createdAtMs: Date.now()
|
|
6373
6373
|
};
|
|
6374
|
-
|
|
6374
|
+
syncFs.writeFileSync(filePath, `${JSON.stringify(stored, null, 2)}\n`, { mode: 384 });
|
|
6375
6375
|
try {
|
|
6376
|
-
|
|
6376
|
+
syncFs.chmodSync(filePath, 384);
|
|
6377
6377
|
} catch {}
|
|
6378
6378
|
return identity;
|
|
6379
6379
|
}
|
|
@@ -6565,8 +6565,8 @@ function resolveDeviceAuthPath(env = process.env) {
|
|
|
6565
6565
|
}
|
|
6566
6566
|
function readStore(filePath) {
|
|
6567
6567
|
try {
|
|
6568
|
-
if (!
|
|
6569
|
-
const raw =
|
|
6568
|
+
if (!syncFs.existsSync(filePath)) return null;
|
|
6569
|
+
const raw = syncFs.readFileSync(filePath, "utf8");
|
|
6570
6570
|
const parsed = JSON.parse(raw);
|
|
6571
6571
|
if (parsed?.version !== 1 || typeof parsed.deviceId !== "string") return null;
|
|
6572
6572
|
if (!parsed.tokens || typeof parsed.tokens !== "object") return null;
|
|
@@ -6576,10 +6576,10 @@ function readStore(filePath) {
|
|
|
6576
6576
|
}
|
|
6577
6577
|
}
|
|
6578
6578
|
function writeStore(filePath, store) {
|
|
6579
|
-
|
|
6580
|
-
|
|
6579
|
+
syncFs.mkdirSync(path.dirname(filePath), { recursive: true });
|
|
6580
|
+
syncFs.writeFileSync(filePath, `${JSON.stringify(store, null, 2)}\n`, { mode: 384 });
|
|
6581
6581
|
try {
|
|
6582
|
-
|
|
6582
|
+
syncFs.chmodSync(filePath, 384);
|
|
6583
6583
|
} catch {}
|
|
6584
6584
|
}
|
|
6585
6585
|
function loadDeviceAuthToken(params) {
|
|
@@ -9760,7 +9760,7 @@ function normalizeReplyPayload(payload, opts = {}) {
|
|
|
9760
9760
|
*/
|
|
9761
9761
|
let deliverRuntimePromise$2 = null;
|
|
9762
9762
|
function loadDeliverRuntime$2() {
|
|
9763
|
-
deliverRuntimePromise$2 ??= import("./deliver-runtime-
|
|
9763
|
+
deliverRuntimePromise$2 ??= import("./deliver-runtime-BvTbrDXE.js");
|
|
9764
9764
|
return deliverRuntimePromise$2;
|
|
9765
9765
|
}
|
|
9766
9766
|
/**
|
|
@@ -10448,8 +10448,8 @@ function normalizeSessionKey(value) {
|
|
|
10448
10448
|
}
|
|
10449
10449
|
function readSessionStore(storePath) {
|
|
10450
10450
|
try {
|
|
10451
|
-
const raw =
|
|
10452
|
-
const parsed =
|
|
10451
|
+
const raw = syncFs.readFileSync(storePath, "utf-8");
|
|
10452
|
+
const parsed = JSON5.parse(raw);
|
|
10453
10453
|
if (parsed && typeof parsed === "object" && !Array.isArray(parsed)) return parsed;
|
|
10454
10454
|
} catch {}
|
|
10455
10455
|
return {};
|
|
@@ -11048,7 +11048,7 @@ const DEFAULT_SUBAGENT_ANNOUNCE_TIMEOUT_MS = 6e4;
|
|
|
11048
11048
|
const MAX_TIMER_SAFE_TIMEOUT_MS = 2147e6;
|
|
11049
11049
|
let subagentRegistryRuntimePromise = null;
|
|
11050
11050
|
function loadSubagentRegistryRuntime() {
|
|
11051
|
-
subagentRegistryRuntimePromise ??= import("./subagent-registry-runtime-
|
|
11051
|
+
subagentRegistryRuntimePromise ??= import("./subagent-registry-runtime-HYpWtFUu.js");
|
|
11052
11052
|
return subagentRegistryRuntimePromise;
|
|
11053
11053
|
}
|
|
11054
11054
|
const DIRECT_ANNOUNCE_TRANSIENT_RETRY_DELAYS_MS = FAST_TEST_MODE ? [
|
|
@@ -14402,7 +14402,7 @@ async function runWithConcurrency(tasks, limit) {
|
|
|
14402
14402
|
//#region src/media-understanding/echo-transcript.ts
|
|
14403
14403
|
let deliverRuntimePromise$1 = null;
|
|
14404
14404
|
function loadDeliverRuntime$1() {
|
|
14405
|
-
deliverRuntimePromise$1 ??= import("./deliver-runtime-
|
|
14405
|
+
deliverRuntimePromise$1 ??= import("./deliver-runtime-BvTbrDXE.js");
|
|
14406
14406
|
return deliverRuntimePromise$1;
|
|
14407
14407
|
}
|
|
14408
14408
|
const DEFAULT_ECHO_TRANSCRIPT_FORMAT = "📝 \"{transcript}\"";
|
|
@@ -18051,7 +18051,7 @@ function mergeLegacyAgent(current, legacy) {
|
|
|
18051
18051
|
}
|
|
18052
18052
|
function ensureDir$1(filePath) {
|
|
18053
18053
|
const dir = path.dirname(filePath);
|
|
18054
|
-
|
|
18054
|
+
syncFs.mkdirSync(dir, { recursive: true });
|
|
18055
18055
|
}
|
|
18056
18056
|
function coerceAllowlistEntries(allowlist) {
|
|
18057
18057
|
if (!Array.isArray(allowlist) || allowlist.length === 0) return Array.isArray(allowlist) ? allowlist : void 0;
|
|
@@ -18121,11 +18121,11 @@ function generateToken() {
|
|
|
18121
18121
|
function loadExecApprovals() {
|
|
18122
18122
|
const filePath = resolveExecApprovalsPath();
|
|
18123
18123
|
try {
|
|
18124
|
-
if (!
|
|
18124
|
+
if (!syncFs.existsSync(filePath)) return normalizeExecApprovals({
|
|
18125
18125
|
version: 1,
|
|
18126
18126
|
agents: {}
|
|
18127
18127
|
});
|
|
18128
|
-
const raw =
|
|
18128
|
+
const raw = syncFs.readFileSync(filePath, "utf8");
|
|
18129
18129
|
const parsed = JSON.parse(raw);
|
|
18130
18130
|
if (parsed?.version !== 1) return normalizeExecApprovals({
|
|
18131
18131
|
version: 1,
|
|
@@ -18142,9 +18142,9 @@ function loadExecApprovals() {
|
|
|
18142
18142
|
function saveExecApprovals(file) {
|
|
18143
18143
|
const filePath = resolveExecApprovalsPath();
|
|
18144
18144
|
ensureDir$1(filePath);
|
|
18145
|
-
|
|
18145
|
+
syncFs.writeFileSync(filePath, `${JSON.stringify(file, null, 2)}\n`, { mode: 384 });
|
|
18146
18146
|
try {
|
|
18147
|
-
|
|
18147
|
+
syncFs.chmodSync(filePath, 384);
|
|
18148
18148
|
} catch {}
|
|
18149
18149
|
}
|
|
18150
18150
|
function ensureExecApprovals() {
|
|
@@ -18641,18 +18641,18 @@ function drainSystemEventEntries(sessionKey) {
|
|
|
18641
18641
|
function resolvePowerShellPath() {
|
|
18642
18642
|
const programFiles = process.env.ProgramFiles || process.env.PROGRAMFILES || "C:\\Program Files";
|
|
18643
18643
|
const pwsh7 = path.join(programFiles, "PowerShell", "7", "pwsh.exe");
|
|
18644
|
-
if (
|
|
18644
|
+
if (syncFs.existsSync(pwsh7)) return pwsh7;
|
|
18645
18645
|
const programW6432 = process.env.ProgramW6432;
|
|
18646
18646
|
if (programW6432 && programW6432 !== programFiles) {
|
|
18647
18647
|
const pwsh7Alt = path.join(programW6432, "PowerShell", "7", "pwsh.exe");
|
|
18648
|
-
if (
|
|
18648
|
+
if (syncFs.existsSync(pwsh7Alt)) return pwsh7Alt;
|
|
18649
18649
|
}
|
|
18650
18650
|
const pwshInPath = resolveShellFromPath("pwsh");
|
|
18651
18651
|
if (pwshInPath) return pwshInPath;
|
|
18652
18652
|
const systemRoot = process.env.SystemRoot || process.env.WINDIR;
|
|
18653
18653
|
if (systemRoot) {
|
|
18654
18654
|
const candidate = path.join(systemRoot, "System32", "WindowsPowerShell", "v1.0", "powershell.exe");
|
|
18655
|
-
if (
|
|
18655
|
+
if (syncFs.existsSync(candidate)) return candidate;
|
|
18656
18656
|
}
|
|
18657
18657
|
return "powershell.exe";
|
|
18658
18658
|
}
|
|
@@ -18690,7 +18690,7 @@ function resolveShellFromPath(name) {
|
|
|
18690
18690
|
for (const entry of entries) {
|
|
18691
18691
|
const candidate = path.join(entry, name);
|
|
18692
18692
|
try {
|
|
18693
|
-
|
|
18693
|
+
syncFs.accessSync(candidate, syncFs.constants.X_OK);
|
|
18694
18694
|
return candidate;
|
|
18695
18695
|
} catch {}
|
|
18696
18696
|
}
|
|
@@ -22165,7 +22165,7 @@ function ensureContextWindowCacheLoaded() {
|
|
|
22165
22165
|
await ensureOpenClawModelsJson(cfg);
|
|
22166
22166
|
} catch {}
|
|
22167
22167
|
try {
|
|
22168
|
-
const { discoverAuthStorage, discoverModels } = await import("./pi-model-discovery-
|
|
22168
|
+
const { discoverAuthStorage, discoverModels } = await import("./pi-model-discovery-32EFg27L.js").then((n) => n.r);
|
|
22169
22169
|
const agentDir = resolveOpenClawAgentDir();
|
|
22170
22170
|
const modelRegistry = discoverModels(discoverAuthStorage(agentDir), agentDir);
|
|
22171
22171
|
applyDiscoveredContextWindows({
|
|
@@ -22321,7 +22321,7 @@ function walkUpFrom(startDir, opts, resolveAtDir) {
|
|
|
22321
22321
|
function hasGitMarker(repoRoot) {
|
|
22322
22322
|
const gitPath = path.join(repoRoot, ".git");
|
|
22323
22323
|
try {
|
|
22324
|
-
const stat =
|
|
22324
|
+
const stat = syncFs.statSync(gitPath);
|
|
22325
22325
|
return stat.isDirectory() || stat.isFile();
|
|
22326
22326
|
} catch {
|
|
22327
22327
|
return false;
|
|
@@ -22333,10 +22333,10 @@ function findGitRoot(startDir, opts = {}) {
|
|
|
22333
22333
|
function resolveGitDirFromMarker(repoRoot) {
|
|
22334
22334
|
const gitPath = path.join(repoRoot, ".git");
|
|
22335
22335
|
try {
|
|
22336
|
-
const stat =
|
|
22336
|
+
const stat = syncFs.statSync(gitPath);
|
|
22337
22337
|
if (stat.isDirectory()) return gitPath;
|
|
22338
22338
|
if (!stat.isFile()) return null;
|
|
22339
|
-
const match =
|
|
22339
|
+
const match = syncFs.readFileSync(gitPath, "utf-8").match(/gitdir:\s*(.+)/i);
|
|
22340
22340
|
if (!match?.[1]) return null;
|
|
22341
22341
|
return path.resolve(repoRoot, match[1].trim());
|
|
22342
22342
|
} catch {
|
|
@@ -22403,7 +22403,7 @@ const resolveCommitHash = (options = {}) => {
|
|
|
22403
22403
|
cachedCommit = null;
|
|
22404
22404
|
return cachedCommit;
|
|
22405
22405
|
}
|
|
22406
|
-
const head =
|
|
22406
|
+
const head = syncFs.readFileSync(headPath, "utf-8").trim();
|
|
22407
22407
|
if (!head) {
|
|
22408
22408
|
cachedCommit = null;
|
|
22409
22409
|
return cachedCommit;
|
|
@@ -22411,7 +22411,7 @@ const resolveCommitHash = (options = {}) => {
|
|
|
22411
22411
|
if (head.startsWith("ref:")) {
|
|
22412
22412
|
const ref = head.replace(/^ref:\s*/i, "").trim();
|
|
22413
22413
|
const refPath = path.resolve(path.dirname(headPath), ref);
|
|
22414
|
-
cachedCommit = formatCommit(
|
|
22414
|
+
cachedCommit = formatCommit(syncFs.readFileSync(refPath, "utf-8").trim());
|
|
22415
22415
|
return cachedCommit;
|
|
22416
22416
|
}
|
|
22417
22417
|
cachedCommit = formatCommit(head);
|
|
@@ -22671,17 +22671,17 @@ const readUsageFromSessionLog = (sessionId, sessionEntry, agentId, sessionKey, s
|
|
|
22671
22671
|
} catch {
|
|
22672
22672
|
return;
|
|
22673
22673
|
}
|
|
22674
|
-
if (!
|
|
22674
|
+
if (!syncFs.existsSync(logPath)) return;
|
|
22675
22675
|
try {
|
|
22676
22676
|
const TAIL_BYTES = 8192;
|
|
22677
|
-
const stat =
|
|
22677
|
+
const stat = syncFs.statSync(logPath);
|
|
22678
22678
|
const offset = Math.max(0, stat.size - TAIL_BYTES);
|
|
22679
22679
|
const buf = Buffer.alloc(Math.min(TAIL_BYTES, stat.size));
|
|
22680
|
-
const fd =
|
|
22680
|
+
const fd = syncFs.openSync(logPath, "r");
|
|
22681
22681
|
try {
|
|
22682
|
-
|
|
22682
|
+
syncFs.readSync(fd, buf, 0, buf.length, offset);
|
|
22683
22683
|
} finally {
|
|
22684
|
-
|
|
22684
|
+
syncFs.closeSync(fd);
|
|
22685
22685
|
}
|
|
22686
22686
|
const tail = buf.toString("utf-8");
|
|
22687
22687
|
const lines = (offset > 0 ? tail.slice(tail.indexOf("\n") + 1) : tail).split(/\n+/);
|
|
@@ -24189,7 +24189,7 @@ function resolveRepoRoot(params) {
|
|
|
24189
24189
|
const configured = params.config?.agents?.defaults?.repoRoot?.trim();
|
|
24190
24190
|
if (configured) try {
|
|
24191
24191
|
const resolved = path.resolve(configured);
|
|
24192
|
-
if (
|
|
24192
|
+
if (syncFs.statSync(resolved).isDirectory()) return resolved;
|
|
24193
24193
|
} catch {}
|
|
24194
24194
|
const candidates = [params.workspaceDir, params.cwd].map((value) => value?.trim()).filter(Boolean);
|
|
24195
24195
|
const seen = /* @__PURE__ */ new Set();
|
|
@@ -24984,7 +24984,7 @@ async function buildContextReply(params) {
|
|
|
24984
24984
|
//#region src/auto-reply/reply/commands-export-session.ts
|
|
24985
24985
|
const EXPORT_HTML_DIR = path.join(path.dirname(fileURLToPath(import.meta.url)), "export-html");
|
|
24986
24986
|
function loadTemplate(fileName) {
|
|
24987
|
-
return
|
|
24987
|
+
return syncFs.readFileSync(path.join(EXPORT_HTML_DIR, fileName), "utf-8");
|
|
24988
24988
|
}
|
|
24989
24989
|
function generateHtml(sessionData) {
|
|
24990
24990
|
const template = loadTemplate("template.html");
|
|
@@ -25058,7 +25058,7 @@ async function buildExportSessionReply(params) {
|
|
|
25058
25058
|
} catch (err) {
|
|
25059
25059
|
return { text: `❌ Failed to resolve session file: ${err instanceof Error ? err.message : String(err)}` };
|
|
25060
25060
|
}
|
|
25061
|
-
if (!
|
|
25061
|
+
if (!syncFs.existsSync(sessionFile)) return { text: `❌ Session file not found: ${sessionFile}` };
|
|
25062
25062
|
const sessionManager = SessionManager.open(sessionFile);
|
|
25063
25063
|
const entries = sessionManager.getEntries();
|
|
25064
25064
|
const header = sessionManager.getHeader();
|
|
@@ -25079,8 +25079,8 @@ async function buildExportSessionReply(params) {
|
|
|
25079
25079
|
const defaultFileName = `openclaw-session-${entry.sessionId.slice(0, 8)}-${timestamp}.html`;
|
|
25080
25080
|
const outputPath = args.outputPath ? path.resolve(args.outputPath.startsWith("~") ? args.outputPath.replace("~", process.env.HOME ?? "") : args.outputPath) : path.join(params.workspaceDir, defaultFileName);
|
|
25081
25081
|
const outputDir = path.dirname(outputPath);
|
|
25082
|
-
if (!
|
|
25083
|
-
|
|
25082
|
+
if (!syncFs.existsSync(outputDir)) syncFs.mkdirSync(outputDir, { recursive: true });
|
|
25083
|
+
syncFs.writeFileSync(outputPath, html, "utf-8");
|
|
25084
25084
|
const relativePath = path.relative(params.workspaceDir, outputPath);
|
|
25085
25085
|
return { text: [
|
|
25086
25086
|
"✅ Session exported!",
|
|
@@ -25227,8 +25227,8 @@ function resolveZaiApiKey() {
|
|
|
25227
25227
|
}
|
|
25228
25228
|
try {
|
|
25229
25229
|
const authPath = path.join(resolveRequiredHomeDir(process.env, os.homedir), ".pi", "agent", "auth.json");
|
|
25230
|
-
if (!
|
|
25231
|
-
const data = JSON.parse(
|
|
25230
|
+
if (!syncFs.existsSync(authPath)) return;
|
|
25231
|
+
const data = JSON.parse(syncFs.readFileSync(authPath, "utf-8"));
|
|
25232
25232
|
return data["z-ai"]?.access || data.zai?.access;
|
|
25233
25233
|
} catch {
|
|
25234
25234
|
return;
|
|
@@ -27047,7 +27047,7 @@ function shouldPersistAnyBindingState() {
|
|
|
27047
27047
|
}
|
|
27048
27048
|
function shouldPersistBindingMutations() {
|
|
27049
27049
|
if (shouldPersistAnyBindingState()) return true;
|
|
27050
|
-
return
|
|
27050
|
+
return syncFs.existsSync(resolveThreadBindingsPath());
|
|
27051
27051
|
}
|
|
27052
27052
|
function saveBindingsToDisk(params = {}) {
|
|
27053
27053
|
if (!params.force && !shouldPersistAnyBindingState()) return;
|
|
@@ -28449,7 +28449,7 @@ const applyCostTotal = (totals, costTotal) => {
|
|
|
28449
28449
|
totals.totalCost += costTotal;
|
|
28450
28450
|
};
|
|
28451
28451
|
async function* readJsonlRecords(filePath) {
|
|
28452
|
-
const fileStream =
|
|
28452
|
+
const fileStream = syncFs.createReadStream(filePath, { encoding: "utf-8" });
|
|
28453
28453
|
const rl = readline.createInterface({
|
|
28454
28454
|
input: fileStream,
|
|
28455
28455
|
crlfDelay: Infinity
|
|
@@ -28521,10 +28521,10 @@ async function loadCostUsageSummary(params) {
|
|
|
28521
28521
|
const dailyMap = /* @__PURE__ */ new Map();
|
|
28522
28522
|
const totals = emptyTotals();
|
|
28523
28523
|
const sessionsDir = resolveSessionTranscriptsDirForAgent(params?.agentId);
|
|
28524
|
-
const entries = await
|
|
28524
|
+
const entries = await syncFs.promises.readdir(sessionsDir, { withFileTypes: true }).catch(() => []);
|
|
28525
28525
|
const files = (await Promise.all(entries.filter((entry) => entry.isFile() && entry.name.endsWith(".jsonl")).map(async (entry) => {
|
|
28526
28526
|
const filePath = path.join(sessionsDir, entry.name);
|
|
28527
|
-
const stats = await
|
|
28527
|
+
const stats = await syncFs.promises.stat(filePath).catch(() => null);
|
|
28528
28528
|
if (!stats) return null;
|
|
28529
28529
|
if (stats.mtimeMs < sinceTime) return null;
|
|
28530
28530
|
return filePath;
|
|
@@ -28557,7 +28557,7 @@ async function loadCostUsageSummary(params) {
|
|
|
28557
28557
|
}
|
|
28558
28558
|
async function loadSessionCostSummary(params) {
|
|
28559
28559
|
const sessionFile = params.sessionFile ?? (params.sessionId ? resolveSessionFilePath(params.sessionId, params.sessionEntry, { agentId: params.agentId }) : void 0);
|
|
28560
|
-
if (!sessionFile || !
|
|
28560
|
+
if (!sessionFile || !syncFs.existsSync(sessionFile)) return null;
|
|
28561
28561
|
const totals = emptyTotals();
|
|
28562
28562
|
let firstActivity;
|
|
28563
28563
|
let lastActivity;
|
|
@@ -31080,7 +31080,7 @@ async function createModelSelectionState(params) {
|
|
|
31080
31080
|
}
|
|
31081
31081
|
}
|
|
31082
31082
|
if (sessionEntry && sessionStore && sessionKey && sessionEntry.authProfileOverride) {
|
|
31083
|
-
const { ensureAuthProfileStore } = await import("./model-selection-
|
|
31083
|
+
const { ensureAuthProfileStore } = await import("./model-selection-e9hodq0l.js").then((n) => n.F);
|
|
31084
31084
|
const profile = ensureAuthProfileStore(void 0, { allowKeychainPrompt: false }).profiles[sessionEntry.authProfileOverride];
|
|
31085
31085
|
const providerKey = normalizeProviderId(provider);
|
|
31086
31086
|
if (!profile || normalizeProviderId(profile.provider) !== providerKey) await clearSessionAuthProfileOverride({
|
|
@@ -34741,7 +34741,7 @@ function asBoolean(value) {
|
|
|
34741
34741
|
}
|
|
34742
34742
|
function resolveTempPathParts(opts) {
|
|
34743
34743
|
const tmpDir = opts.tmpDir ?? resolvePreferredOpenClawTmpDir();
|
|
34744
|
-
if (!opts.tmpDir)
|
|
34744
|
+
if (!opts.tmpDir) syncFs.mkdirSync(tmpDir, {
|
|
34745
34745
|
recursive: true,
|
|
34746
34746
|
mode: 448
|
|
34747
34747
|
});
|
|
@@ -34827,7 +34827,7 @@ async function writeUrlToFile(filePath, url, opts) {
|
|
|
34827
34827
|
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}`);
|
|
34828
34828
|
const body = res.body;
|
|
34829
34829
|
if (!body) throw new Error(`failed to download ${url}: empty response body`);
|
|
34830
|
-
const fileHandle = await fs$
|
|
34830
|
+
const fileHandle = await fs$1.open(filePath, "w");
|
|
34831
34831
|
let thrown;
|
|
34832
34832
|
try {
|
|
34833
34833
|
const reader = body.getReader();
|
|
@@ -34845,7 +34845,7 @@ async function writeUrlToFile(filePath, url, opts) {
|
|
|
34845
34845
|
await fileHandle.close();
|
|
34846
34846
|
}
|
|
34847
34847
|
if (thrown) {
|
|
34848
|
-
await fs$
|
|
34848
|
+
await fs$1.unlink(filePath).catch(() => {});
|
|
34849
34849
|
throw thrown;
|
|
34850
34850
|
}
|
|
34851
34851
|
} finally {
|
|
@@ -34858,7 +34858,7 @@ async function writeUrlToFile(filePath, url, opts) {
|
|
|
34858
34858
|
}
|
|
34859
34859
|
async function writeBase64ToFile(filePath, base64) {
|
|
34860
34860
|
const buf = Buffer.from(base64, "base64");
|
|
34861
|
-
await fs$
|
|
34861
|
+
await fs$1.writeFile(filePath, buf);
|
|
34862
34862
|
return {
|
|
34863
34863
|
path: filePath,
|
|
34864
34864
|
bytes: buf.length
|
|
@@ -37902,9 +37902,9 @@ function loadExternalCatalogEntries(options) {
|
|
|
37902
37902
|
const entries = [];
|
|
37903
37903
|
for (const rawPath of paths) {
|
|
37904
37904
|
const resolved = resolveUserPath(rawPath);
|
|
37905
|
-
if (!
|
|
37905
|
+
if (!syncFs.existsSync(resolved)) continue;
|
|
37906
37906
|
try {
|
|
37907
|
-
const payload = JSON.parse(
|
|
37907
|
+
const payload = JSON.parse(syncFs.readFileSync(resolved, "utf-8"));
|
|
37908
37908
|
entries.push(...parseCatalogEntries(payload));
|
|
37909
37909
|
} catch {}
|
|
37910
37910
|
}
|
|
@@ -42021,7 +42021,7 @@ function listExistingAgentIdsFromDisk() {
|
|
|
42021
42021
|
const root = resolveStateDir();
|
|
42022
42022
|
const agentsDir = path.join(root, "agents");
|
|
42023
42023
|
try {
|
|
42024
|
-
return
|
|
42024
|
+
return syncFs.readdirSync(agentsDir, { withFileTypes: true }).filter((entry) => entry.isDirectory()).map((entry) => normalizeAgentId(entry.name)).filter(Boolean);
|
|
42025
42025
|
} catch {
|
|
42026
42026
|
return [];
|
|
42027
42027
|
}
|
|
@@ -48094,7 +48094,7 @@ async function runAgentTurnWithFallback(params) {
|
|
|
48094
48094
|
if (corruptedSessionId) {
|
|
48095
48095
|
const transcriptPath = resolveSessionTranscriptPath(corruptedSessionId);
|
|
48096
48096
|
try {
|
|
48097
|
-
|
|
48097
|
+
syncFs.unlinkSync(transcriptPath);
|
|
48098
48098
|
} catch {}
|
|
48099
48099
|
}
|
|
48100
48100
|
delete params.activeSessionStore[sessionKey];
|
|
@@ -48914,7 +48914,7 @@ async function readSessionLogSnapshot(params) {
|
|
|
48914
48914
|
if (!logPath) return {};
|
|
48915
48915
|
const snapshot = {};
|
|
48916
48916
|
if (params.includeByteSize) try {
|
|
48917
|
-
const stat = await
|
|
48917
|
+
const stat = await syncFs.promises.stat(logPath);
|
|
48918
48918
|
const size = Math.floor(stat.size);
|
|
48919
48919
|
snapshot.byteSize = Number.isFinite(size) && size >= 0 ? size : void 0;
|
|
48920
48920
|
} catch {
|
|
@@ -48928,7 +48928,7 @@ async function readSessionLogSnapshot(params) {
|
|
|
48928
48928
|
return snapshot;
|
|
48929
48929
|
}
|
|
48930
48930
|
async function readLastNonzeroUsageFromSessionLog(logPath) {
|
|
48931
|
-
const handle = await
|
|
48931
|
+
const handle = await syncFs.promises.open(logPath, "r");
|
|
48932
48932
|
try {
|
|
48933
48933
|
let position = (await handle.stat()).size;
|
|
48934
48934
|
let leadingPartial = "";
|
|
@@ -49625,9 +49625,9 @@ async function readPostCompactionContext(workspaceDir, cfg, nowMs) {
|
|
|
49625
49625
|
if (!opened.ok) return null;
|
|
49626
49626
|
const sections = extractSections((() => {
|
|
49627
49627
|
try {
|
|
49628
|
-
return
|
|
49628
|
+
return syncFs.readFileSync(opened.fd, "utf-8");
|
|
49629
49629
|
} finally {
|
|
49630
|
-
|
|
49630
|
+
syncFs.closeSync(opened.fd);
|
|
49631
49631
|
}
|
|
49632
49632
|
})(), ["Session Startup", "Red Lines"]);
|
|
49633
49633
|
if (sections.length === 0) return null;
|
|
@@ -49849,7 +49849,7 @@ async function runReplyAgent(params) {
|
|
|
49849
49849
|
if (resolved) transcriptCandidates.add(resolved);
|
|
49850
49850
|
transcriptCandidates.add(resolveSessionTranscriptPath(prevSessionId, agentId));
|
|
49851
49851
|
for (const candidate of transcriptCandidates) try {
|
|
49852
|
-
|
|
49852
|
+
syncFs.unlinkSync(candidate);
|
|
49853
49853
|
} catch {}
|
|
49854
49854
|
}
|
|
49855
49855
|
return true;
|
|
@@ -50795,7 +50795,7 @@ const warnedContexts = /* @__PURE__ */ new Map();
|
|
|
50795
50795
|
const log$10 = createSubsystemLogger("session-maintenance-warning");
|
|
50796
50796
|
let deliverRuntimePromise = null;
|
|
50797
50797
|
function loadDeliverRuntime() {
|
|
50798
|
-
deliverRuntimePromise ??= import("./deliver-runtime-
|
|
50798
|
+
deliverRuntimePromise ??= import("./deliver-runtime-BvTbrDXE.js");
|
|
50799
50799
|
return deliverRuntimePromise;
|
|
50800
50800
|
}
|
|
50801
50801
|
function shouldSendWarning() {
|
|
@@ -50962,7 +50962,7 @@ function forkSessionFromParent(params) {
|
|
|
50962
50962
|
agentId: params.agentId,
|
|
50963
50963
|
sessionsDir: params.sessionsDir
|
|
50964
50964
|
});
|
|
50965
|
-
if (!parentSessionFile || !
|
|
50965
|
+
if (!parentSessionFile || !syncFs.existsSync(parentSessionFile)) return null;
|
|
50966
50966
|
try {
|
|
50967
50967
|
const manager = SessionManager.open(parentSessionFile);
|
|
50968
50968
|
const leafId = manager.getLeafId();
|
|
@@ -50986,7 +50986,7 @@ function forkSessionFromParent(params) {
|
|
|
50986
50986
|
cwd: manager.getCwd(),
|
|
50987
50987
|
parentSession: parentSessionFile
|
|
50988
50988
|
};
|
|
50989
|
-
|
|
50989
|
+
syncFs.writeFileSync(sessionFile, `${JSON.stringify(header)}\n`, "utf-8");
|
|
50990
50990
|
return {
|
|
50991
50991
|
sessionId,
|
|
50992
50992
|
sessionFile
|
|
@@ -55752,7 +55752,7 @@ const VISION_PROVIDERS = [
|
|
|
55752
55752
|
];
|
|
55753
55753
|
let imageRuntimePromise = null;
|
|
55754
55754
|
function loadImageRuntime() {
|
|
55755
|
-
imageRuntimePromise ??= import("./image-runtime-
|
|
55755
|
+
imageRuntimePromise ??= import("./image-runtime-Cp3I725X.js");
|
|
55756
55756
|
return imageRuntimePromise;
|
|
55757
55757
|
}
|
|
55758
55758
|
/**
|
|
@@ -57745,7 +57745,7 @@ async function resolveDiscordPreflightAudioMentionContext(params) {
|
|
|
57745
57745
|
const needsPreflightTranscription = !params.isDirectMessage && params.shouldRequireMention && hasAudioAttachment && !hasTypedText && params.mentionRegexes.length > 0;
|
|
57746
57746
|
let transcript;
|
|
57747
57747
|
if (needsPreflightTranscription) try {
|
|
57748
|
-
const { transcribeFirstAudio } = await import("./audio-preflight
|
|
57748
|
+
const { transcribeFirstAudio } = await import("./audio-preflight-C7kt2vOu.js");
|
|
57749
57749
|
const audioUrls = audioAttachments.map((att) => att.url).filter((url) => typeof url === "string" && url.length > 0);
|
|
57750
57750
|
if (audioUrls.length > 0) transcript = await transcribeFirstAudio({
|
|
57751
57751
|
ctx: {
|
|
@@ -59305,7 +59305,7 @@ function identityHasValues(identity) {
|
|
|
59305
59305
|
}
|
|
59306
59306
|
function loadIdentityFromFile(identityPath) {
|
|
59307
59307
|
try {
|
|
59308
|
-
const parsed = parseIdentityMarkdown(
|
|
59308
|
+
const parsed = parseIdentityMarkdown(syncFs.readFileSync(identityPath, "utf-8"));
|
|
59309
59309
|
if (!identityHasValues(parsed)) return null;
|
|
59310
59310
|
return parsed;
|
|
59311
59311
|
} catch {
|
|
@@ -59329,7 +59329,7 @@ function resolveAvatarSource(cfg, agentId) {
|
|
|
59329
59329
|
}
|
|
59330
59330
|
function resolveExistingPath(value) {
|
|
59331
59331
|
try {
|
|
59332
|
-
return
|
|
59332
|
+
return syncFs.realpathSync(value);
|
|
59333
59333
|
} catch {
|
|
59334
59334
|
return path.resolve(value);
|
|
59335
59335
|
}
|
|
@@ -59347,7 +59347,7 @@ function resolveLocalAvatarPath(params) {
|
|
|
59347
59347
|
reason: "unsupported_extension"
|
|
59348
59348
|
};
|
|
59349
59349
|
try {
|
|
59350
|
-
const stat =
|
|
59350
|
+
const stat = syncFs.statSync(realPath);
|
|
59351
59351
|
if (!stat.isFile()) return {
|
|
59352
59352
|
ok: false,
|
|
59353
59353
|
reason: "missing"
|
|
@@ -65005,27 +65005,27 @@ let slackSenderRuntimePromise = null;
|
|
|
65005
65005
|
let signalSenderRuntimePromise = null;
|
|
65006
65006
|
let imessageSenderRuntimePromise = null;
|
|
65007
65007
|
function loadWhatsAppSenderRuntime() {
|
|
65008
|
-
whatsappSenderRuntimePromise ??= import("./deps-send-whatsapp.runtime-
|
|
65008
|
+
whatsappSenderRuntimePromise ??= import("./deps-send-whatsapp.runtime-CAPjqcnc.js");
|
|
65009
65009
|
return whatsappSenderRuntimePromise;
|
|
65010
65010
|
}
|
|
65011
65011
|
function loadTelegramSenderRuntime() {
|
|
65012
|
-
telegramSenderRuntimePromise ??= import("./deps-send-telegram.runtime-
|
|
65012
|
+
telegramSenderRuntimePromise ??= import("./deps-send-telegram.runtime-CgApeKta.js");
|
|
65013
65013
|
return telegramSenderRuntimePromise;
|
|
65014
65014
|
}
|
|
65015
65015
|
function loadDiscordSenderRuntime() {
|
|
65016
|
-
discordSenderRuntimePromise ??= import("./deps-send-discord.runtime-
|
|
65016
|
+
discordSenderRuntimePromise ??= import("./deps-send-discord.runtime-1mqY0Pn3.js");
|
|
65017
65017
|
return discordSenderRuntimePromise;
|
|
65018
65018
|
}
|
|
65019
65019
|
function loadSlackSenderRuntime() {
|
|
65020
|
-
slackSenderRuntimePromise ??= import("./deps-send-slack.runtime-
|
|
65020
|
+
slackSenderRuntimePromise ??= import("./deps-send-slack.runtime-CbGlCNTX.js");
|
|
65021
65021
|
return slackSenderRuntimePromise;
|
|
65022
65022
|
}
|
|
65023
65023
|
function loadSignalSenderRuntime() {
|
|
65024
|
-
signalSenderRuntimePromise ??= import("./deps-send-signal.runtime-
|
|
65024
|
+
signalSenderRuntimePromise ??= import("./deps-send-signal.runtime-CHqnnRXO.js");
|
|
65025
65025
|
return signalSenderRuntimePromise;
|
|
65026
65026
|
}
|
|
65027
65027
|
function loadIMessageSenderRuntime() {
|
|
65028
|
-
imessageSenderRuntimePromise ??= import("./deps-send-imessage.runtime-
|
|
65028
|
+
imessageSenderRuntimePromise ??= import("./deps-send-imessage.runtime-NAKUx6Vy.js");
|
|
65029
65029
|
return imessageSenderRuntimePromise;
|
|
65030
65030
|
}
|
|
65031
65031
|
function createDefaultDeps() {
|
|
@@ -71132,7 +71132,7 @@ async function monitorIMessageProvider(opts = {}) {
|
|
|
71132
71132
|
function readFileIfExists(filePath) {
|
|
71133
71133
|
if (!filePath) return;
|
|
71134
71134
|
try {
|
|
71135
|
-
return
|
|
71135
|
+
return syncFs.readFileSync(filePath, "utf-8").trim();
|
|
71136
71136
|
} catch {
|
|
71137
71137
|
return;
|
|
71138
71138
|
}
|
|
@@ -71762,7 +71762,7 @@ async function downloadLineMedia(messageId, channelAccessToken, maxBytes = 10 *
|
|
|
71762
71762
|
prefix: "line-media",
|
|
71763
71763
|
extension: getExtensionForContentType(contentType)
|
|
71764
71764
|
});
|
|
71765
|
-
await
|
|
71765
|
+
await syncFs.promises.writeFile(filePath, buffer);
|
|
71766
71766
|
logVerbose(`line: downloaded media ${messageId} to ${filePath} (${buffer.length} bytes)`);
|
|
71767
71767
|
return {
|
|
71768
71768
|
path: filePath,
|
|
@@ -77766,15 +77766,15 @@ let slashCommandsRuntimePromise = null;
|
|
|
77766
77766
|
let slashDispatchRuntimePromise = null;
|
|
77767
77767
|
let slashSkillCommandsRuntimePromise = null;
|
|
77768
77768
|
function loadSlashCommandsRuntime() {
|
|
77769
|
-
slashCommandsRuntimePromise ??= import("./slash-commands.runtime-
|
|
77769
|
+
slashCommandsRuntimePromise ??= import("./slash-commands.runtime-gtQnheWz.js");
|
|
77770
77770
|
return slashCommandsRuntimePromise;
|
|
77771
77771
|
}
|
|
77772
77772
|
function loadSlashDispatchRuntime() {
|
|
77773
|
-
slashDispatchRuntimePromise ??= import("./slash-dispatch.runtime-
|
|
77773
|
+
slashDispatchRuntimePromise ??= import("./slash-dispatch.runtime-w1y_0I6t.js");
|
|
77774
77774
|
return slashDispatchRuntimePromise;
|
|
77775
77775
|
}
|
|
77776
77776
|
function loadSlashSkillCommandsRuntime() {
|
|
77777
|
-
slashSkillCommandsRuntimePromise ??= import("./slash-skill-commands.runtime-
|
|
77777
|
+
slashSkillCommandsRuntimePromise ??= import("./slash-skill-commands.runtime-CA_oN4df.js");
|
|
77778
77778
|
return slashSkillCommandsRuntimePromise;
|
|
77779
77779
|
}
|
|
77780
77780
|
const slackExternalArgMenuStore = createSlackExternalArgMenuStore();
|
|
@@ -78764,7 +78764,7 @@ function collectTelegramUnmentionedGroupIds(groups) {
|
|
|
78764
78764
|
}
|
|
78765
78765
|
let auditMembershipRuntimePromise = null;
|
|
78766
78766
|
function loadAuditMembershipRuntime() {
|
|
78767
|
-
auditMembershipRuntimePromise ??= import("./audit-membership-runtime-
|
|
78767
|
+
auditMembershipRuntimePromise ??= import("./audit-membership-runtime-C6dnIaXJ.js");
|
|
78768
78768
|
return auditMembershipRuntimePromise;
|
|
78769
78769
|
}
|
|
78770
78770
|
async function auditTelegramGroupMembership(params) {
|
|
@@ -81139,7 +81139,7 @@ const buildTelegramMessageContext = async ({ primaryCtx, allMedia, replyMedia =
|
|
|
81139
81139
|
const disableAudioPreflight = firstDefined$1(topicConfig?.disableAudioPreflight, groupConfig?.disableAudioPreflight) === true;
|
|
81140
81140
|
let preflightTranscript;
|
|
81141
81141
|
if (isGroup && requireMention && hasAudio && !hasUserText && mentionRegexes.length > 0 && !disableAudioPreflight) try {
|
|
81142
|
-
const { transcribeFirstAudio } = await import("./audio-preflight
|
|
81142
|
+
const { transcribeFirstAudio } = await import("./audio-preflight-C7kt2vOu.js");
|
|
81143
81143
|
preflightTranscript = await transcribeFirstAudio({
|
|
81144
81144
|
ctx: {
|
|
81145
81145
|
MediaPaths: allMedia.length > 0 ? allMedia.map((m) => m.path) : void 0,
|
|
@@ -83952,7 +83952,7 @@ function createWhatsAppLoginTool() {
|
|
|
83952
83952
|
force: Type.Optional(Type.Boolean())
|
|
83953
83953
|
}),
|
|
83954
83954
|
execute: async (_toolCallId, args) => {
|
|
83955
|
-
const { startWebLoginWithQr, waitForWebLogin } = await import("./login-qr-
|
|
83955
|
+
const { startWebLoginWithQr, waitForWebLogin } = await import("./login-qr-BEW3jIOt.js");
|
|
83956
83956
|
if ((args?.action ?? "start") === "wait") {
|
|
83957
83957
|
const result = await waitForWebLogin({ timeoutMs: typeof args.timeoutMs === "number" ? args.timeoutMs : void 0 });
|
|
83958
83958
|
return {
|
|
@@ -84027,23 +84027,23 @@ let webOutboundPromise = null;
|
|
|
84027
84027
|
let webLoginPromise = null;
|
|
84028
84028
|
let whatsappActionsPromise = null;
|
|
84029
84029
|
function loadWebOutbound() {
|
|
84030
|
-
webOutboundPromise ??= import("./runtime-whatsapp-outbound.runtime-
|
|
84030
|
+
webOutboundPromise ??= import("./runtime-whatsapp-outbound.runtime-CFivqxoq.js");
|
|
84031
84031
|
return webOutboundPromise;
|
|
84032
84032
|
}
|
|
84033
84033
|
function loadWebLogin() {
|
|
84034
|
-
webLoginPromise ??= import("./runtime-whatsapp-login.runtime-
|
|
84034
|
+
webLoginPromise ??= import("./runtime-whatsapp-login.runtime-BhVxslsH.js");
|
|
84035
84035
|
return webLoginPromise;
|
|
84036
84036
|
}
|
|
84037
84037
|
function loadWebLoginQr() {
|
|
84038
|
-
webLoginQrPromise ??= import("./login-qr-
|
|
84038
|
+
webLoginQrPromise ??= import("./login-qr-BEW3jIOt.js");
|
|
84039
84039
|
return webLoginQrPromise;
|
|
84040
84040
|
}
|
|
84041
84041
|
function loadWebChannel() {
|
|
84042
|
-
webChannelPromise ??= import("./web-
|
|
84042
|
+
webChannelPromise ??= import("./web-B8rFiLYw.js");
|
|
84043
84043
|
return webChannelPromise;
|
|
84044
84044
|
}
|
|
84045
84045
|
function loadWhatsAppActions() {
|
|
84046
|
-
whatsappActionsPromise ??= import("./whatsapp-actions-
|
|
84046
|
+
whatsappActionsPromise ??= import("./whatsapp-actions-BPIXiPAR.js");
|
|
84047
84047
|
return whatsappActionsPromise;
|
|
84048
84048
|
}
|
|
84049
84049
|
function createRuntimeWhatsApp() {
|
|
@@ -84484,7 +84484,7 @@ const log$6 = createSubsystemLogger("memory");
|
|
|
84484
84484
|
const QMD_MANAGER_CACHE = /* @__PURE__ */ new Map();
|
|
84485
84485
|
let managerRuntimePromise = null;
|
|
84486
84486
|
function loadManagerRuntime() {
|
|
84487
|
-
managerRuntimePromise ??= import("./manager-runtime-
|
|
84487
|
+
managerRuntimePromise ??= import("./manager-runtime-DacMHR37.js");
|
|
84488
84488
|
return managerRuntimePromise;
|
|
84489
84489
|
}
|
|
84490
84490
|
async function getMemorySearchManager(params) {
|
|
@@ -84498,7 +84498,7 @@ async function getMemorySearchManager(params) {
|
|
|
84498
84498
|
if (cached) return { manager: cached };
|
|
84499
84499
|
}
|
|
84500
84500
|
try {
|
|
84501
|
-
const { QmdMemoryManager } = await import("./qmd-manager-
|
|
84501
|
+
const { QmdMemoryManager } = await import("./qmd-manager-DMSLC2iu.js");
|
|
84502
84502
|
const primary = await QmdMemoryManager.create({
|
|
84503
84503
|
cfg: params.cfg,
|
|
84504
84504
|
agentId: params.agentId,
|
|
@@ -85072,7 +85072,7 @@ async function withMemoryManagerForAgent(params) {
|
|
|
85072
85072
|
}
|
|
85073
85073
|
async function checkReadableFile(pathname) {
|
|
85074
85074
|
try {
|
|
85075
|
-
await fs.access(pathname,
|
|
85075
|
+
await fs.access(pathname, syncFs.constants.R_OK);
|
|
85076
85076
|
return { exists: true };
|
|
85077
85077
|
} catch (err) {
|
|
85078
85078
|
const code = err.code;
|
|
@@ -85131,7 +85131,7 @@ async function scanMemoryFiles(workspaceDir, extraPaths = []) {
|
|
|
85131
85131
|
}
|
|
85132
85132
|
let dirReadable = null;
|
|
85133
85133
|
try {
|
|
85134
|
-
await fs.access(memoryDir,
|
|
85134
|
+
await fs.access(memoryDir, syncFs.constants.R_OK);
|
|
85135
85135
|
dirReadable = true;
|
|
85136
85136
|
} catch (err) {
|
|
85137
85137
|
const code = err.code;
|
|
@@ -85580,7 +85580,7 @@ const resolvePluginSdkAliasFile = (params) => {
|
|
|
85580
85580
|
const srcCandidate = path.join(cursor, "src", "plugin-sdk", params.srcFile);
|
|
85581
85581
|
const distCandidate = path.join(cursor, "dist", "plugin-sdk", params.distFile);
|
|
85582
85582
|
const orderedCandidates = isDistRuntime ? [distCandidate, srcCandidate] : isTest ? [distCandidate, srcCandidate] : [distCandidate];
|
|
85583
|
-
for (const candidate of orderedCandidates) if (
|
|
85583
|
+
for (const candidate of orderedCandidates) if (syncFs.existsSync(candidate)) return candidate;
|
|
85584
85584
|
const parent = path.dirname(cursor);
|
|
85585
85585
|
if (parent === cursor) break;
|
|
85586
85586
|
cursor = parent;
|
|
@@ -86012,7 +86012,7 @@ function loadOpenClawPlugins(options = {}) {
|
|
|
86012
86012
|
continue;
|
|
86013
86013
|
}
|
|
86014
86014
|
const safeSource = opened.path;
|
|
86015
|
-
|
|
86015
|
+
syncFs.closeSync(opened.fd);
|
|
86016
86016
|
let mod = null;
|
|
86017
86017
|
try {
|
|
86018
86018
|
mod = getJiti()(safeSource);
|
|
@@ -86130,7 +86130,7 @@ function loadOpenClawPlugins(options = {}) {
|
|
|
86130
86130
|
}
|
|
86131
86131
|
function safeRealpathOrResolve(value) {
|
|
86132
86132
|
try {
|
|
86133
|
-
return
|
|
86133
|
+
return syncFs.realpathSync(value);
|
|
86134
86134
|
} catch {
|
|
86135
86135
|
return path.resolve(value);
|
|
86136
86136
|
}
|
|
@@ -86569,9 +86569,9 @@ function resolvePatchFileOps(options) {
|
|
|
86569
86569
|
});
|
|
86570
86570
|
assertBoundaryRead(opened, filePath);
|
|
86571
86571
|
try {
|
|
86572
|
-
return
|
|
86572
|
+
return syncFs.readFileSync(opened.fd, "utf8");
|
|
86573
86573
|
} finally {
|
|
86574
|
-
|
|
86574
|
+
syncFs.closeSync(opened.fd);
|
|
86575
86575
|
}
|
|
86576
86576
|
},
|
|
86577
86577
|
writeFile: async (filePath, content) => {
|
|
@@ -86850,7 +86850,7 @@ const LOOP_WARNING_BUCKET_SIZE = 10;
|
|
|
86850
86850
|
const MAX_LOOP_WARNING_KEYS = 256;
|
|
86851
86851
|
let beforeToolCallRuntimePromise = null;
|
|
86852
86852
|
function loadBeforeToolCallRuntime() {
|
|
86853
|
-
beforeToolCallRuntimePromise ??= import("./pi-tools.before-tool-call.runtime-
|
|
86853
|
+
beforeToolCallRuntimePromise ??= import("./pi-tools.before-tool-call.runtime-BfjlGXIc.js");
|
|
86854
86854
|
return beforeToolCallRuntimePromise;
|
|
86855
86855
|
}
|
|
86856
86856
|
function buildAdjustedParamsKey(params) {
|
|
@@ -89532,9 +89532,9 @@ async function readWorkspaceContextForSummary() {
|
|
|
89532
89532
|
if (!opened.ok) return "";
|
|
89533
89533
|
const sections = extractSections((() => {
|
|
89534
89534
|
try {
|
|
89535
|
-
return
|
|
89535
|
+
return syncFs.readFileSync(opened.fd, "utf-8");
|
|
89536
89536
|
} finally {
|
|
89537
|
-
|
|
89537
|
+
syncFs.closeSync(opened.fd);
|
|
89538
89538
|
}
|
|
89539
89539
|
})(), ["Session Startup", "Red Lines"]);
|
|
89540
89540
|
if (sections.length === 0) return "";
|
|
@@ -90903,7 +90903,7 @@ async function compactEmbeddedPiSessionDirect(params) {
|
|
|
90903
90903
|
if (!apiKeyInfo.apiKey) {
|
|
90904
90904
|
if (apiKeyInfo.mode !== "aws-sdk") throw new Error(`No API key resolved for provider "${model.provider}" (auth mode: ${apiKeyInfo.mode}).`);
|
|
90905
90905
|
} else if (model.provider === "github-copilot") {
|
|
90906
|
-
const { resolveCopilotApiToken } = await import("./github-copilot-token-
|
|
90906
|
+
const { resolveCopilotApiToken } = await import("./github-copilot-token-DDa7O18e.js").then((n) => n.n);
|
|
90907
90907
|
const copilotToken = await resolveCopilotApiToken({ githubToken: apiKeyInfo.apiKey });
|
|
90908
90908
|
authStorage.setRuntimeApiKey(model.provider, copilotToken.token);
|
|
90909
90909
|
} else authStorage.setRuntimeApiKey(model.provider, apiKeyInfo.apiKey);
|
|
@@ -93131,11 +93131,11 @@ function appendRawStream(payload) {
|
|
|
93131
93131
|
if (!rawStreamReady) {
|
|
93132
93132
|
rawStreamReady = true;
|
|
93133
93133
|
try {
|
|
93134
|
-
|
|
93134
|
+
syncFs.mkdirSync(path.dirname(RAW_STREAM_PATH), { recursive: true });
|
|
93135
93135
|
} catch {}
|
|
93136
93136
|
}
|
|
93137
93137
|
try {
|
|
93138
|
-
|
|
93138
|
+
syncFs.promises.appendFile(RAW_STREAM_PATH, `${JSON.stringify(payload)}\n`);
|
|
93139
93139
|
} catch {}
|
|
93140
93140
|
}
|
|
93141
93141
|
|
|
@@ -96640,7 +96640,7 @@ async function runEmbeddedPiAgent(params) {
|
|
|
96640
96640
|
await copilotTokenState.refreshInFlight;
|
|
96641
96641
|
return;
|
|
96642
96642
|
}
|
|
96643
|
-
const { resolveCopilotApiToken } = await import("./github-copilot-token-
|
|
96643
|
+
const { resolveCopilotApiToken } = await import("./github-copilot-token-DDa7O18e.js").then((n) => n.n);
|
|
96644
96644
|
copilotTokenState.refreshInFlight = (async () => {
|
|
96645
96645
|
const githubToken = copilotTokenState.githubToken.trim();
|
|
96646
96646
|
if (!githubToken) throw new Error("Copilot refresh requires a GitHub token.");
|
|
@@ -96732,7 +96732,7 @@ async function runEmbeddedPiAgent(params) {
|
|
|
96732
96732
|
return;
|
|
96733
96733
|
}
|
|
96734
96734
|
if (model.provider === "github-copilot") {
|
|
96735
|
-
const { resolveCopilotApiToken } = await import("./github-copilot-token-
|
|
96735
|
+
const { resolveCopilotApiToken } = await import("./github-copilot-token-DDa7O18e.js").then((n) => n.n);
|
|
96736
96736
|
const copilotToken = await resolveCopilotApiToken({ githubToken: apiKeyInfo.apiKey });
|
|
96737
96737
|
authStorage.setRuntimeApiKey(model.provider, copilotToken.token);
|
|
96738
96738
|
if (copilotTokenState) {
|