silentlake 3.0.0
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/LICENSE +21 -0
- package/README.md +205 -0
- package/dist/APEv2Parser-BZv_dP9t.js +269 -0
- package/dist/APEv2Parser-CPzxFNBB.js +5 -0
- package/dist/AbstractID3Parser-mvDFcjYV.js +47 -0
- package/dist/AiffParser-BXQ9SRZk.js +145 -0
- package/dist/AsfParser-CmBDUlZE.js +631 -0
- package/dist/BasicParser-DhmXREDo.js +853 -0
- package/dist/DsdiffParser-CTKKGyZg.js +150 -0
- package/dist/DsfParser-Ds-YQe4Z.js +101 -0
- package/dist/FlacParser-B1XVPgXF.js +5 -0
- package/dist/FlacParser-DMPyL1y4.js +367 -0
- package/dist/ID3v1Parser-BICWWVDG.js +289 -0
- package/dist/ID3v2Parser-BmZHSUqs.js +650 -0
- package/dist/ID3v2Token-DeJf4tYQ.js +145 -0
- package/dist/MP4Parser-Cjf-Zs8T.js +1061 -0
- package/dist/MatroskaParser-DgBzBe8t.js +909 -0
- package/dist/MpegParser-D5swTpA1.js +744 -0
- package/dist/MusepackParser-D8EQXnpK.js +285 -0
- package/dist/OggParser-BcIYPHwP.js +390 -0
- package/dist/Util-D_zGsr97.js +170 -0
- package/dist/WavPackParser-hosU8gfo.js +166 -0
- package/dist/WaveParser-CA00FZrC.js +273 -0
- package/dist/abort-cutoff-CERmtgZI.js +56 -0
- package/dist/abort-cutoff.runtime-BuaoE5Si.js +61 -0
- package/dist/abort-signal-CsrBEr94.js +13 -0
- package/dist/account-helpers-D3c_eI7c.js +37 -0
- package/dist/account-helpers-ru3jdZSV.js +12 -0
- package/dist/account-id-DZnNZg8x.js +1 -0
- package/dist/account-id-ZCrgXl7Z.js +44 -0
- package/dist/account-lookup-nkoa-foB.js +10 -0
- package/dist/account-snapshot-fields-Cvq7803C.js +116 -0
- package/dist/account-summary-B5Xzvntm.js +36 -0
- package/dist/accounts-CYgFhv2o.js +105 -0
- package/dist/accounts-ChlyF7cx.js +112 -0
- package/dist/accounts-Fyrhtztr.js +212 -0
- package/dist/ack-reactions-CNVwfOBj.js +43 -0
- package/dist/acp-cli-BIcgXTaP.js +2033 -0
- package/dist/acp-runtime-BdLdT-QY.js +1 -0
- package/dist/actions.runtime-BBPvLwDK.js +236 -0
- package/dist/actions.runtime-MrkZQbUZ.js +217 -0
- package/dist/agent-CBOdzEvR.js +1 -0
- package/dist/agent-scope-BLhzf-o0.js +17 -0
- package/dist/agent-scope-DPP4Z_UU.js +193 -0
- package/dist/agents-DGJIvby1.js +323 -0
- package/dist/agents-DbUUarGq.js +855 -0
- package/dist/agents.config-C_lrnc9J.js +18 -0
- package/dist/agents.config-D1VqC78r.js +121 -0
- package/dist/allow-from-BPSBITdd.js +9 -0
- package/dist/allow-from-BwTLpvhp.js +20 -0
- package/dist/allow-from-C4iBpqFI.js +62 -0
- package/dist/allowlist-config-edit-CKbnMmwS.js +279 -0
- package/dist/allowlist-match-CYmPgg1K.js +63 -0
- package/dist/ansi-BEJF8NKS.js +54 -0
- package/dist/anthropic-vertex-provider-Dd5agCN9.js +60 -0
- package/dist/apply.runtime-BO_W7UsB.js +211 -0
- package/dist/apply.runtime-BeYLuuGy.js +370 -0
- package/dist/archive-Tr0wIUO-.js +532 -0
- package/dist/arg-split-Dtda0YDl.js +38 -0
- package/dist/artifacts-C_4LekPC.js +39 -0
- package/dist/audit-COaaGhfd.js +788 -0
- package/dist/audit-OWBlbPvC.js +54 -0
- package/dist/audit-channel.allow-from.runtime-B7BHNblL.js +17 -0
- package/dist/audit-channel.collect.runtime-BjAagjy5.js +521 -0
- package/dist/audit-channel.discord.runtime-BBY6S9lg.js +5 -0
- package/dist/audit-channel.telegram.runtime-SJnxOJH2.js +8 -0
- package/dist/audit-channel.zalouser.runtime-SGRWvHxT.js +5 -0
- package/dist/audit-extra.async-Brlm785b.js +817 -0
- package/dist/audit-fs-oDMUa5N_.js +375 -0
- package/dist/audit-membership-runtime-BV4yo8s2.js +261 -0
- package/dist/audit.deep.runtime-C4qycPyC.js +31 -0
- package/dist/audit.nondeep.runtime-BKadRetL.js +842 -0
- package/dist/audit.runtime-n3hTkevZ.js +74 -0
- package/dist/auth-O6LQFLHJ.js +416 -0
- package/dist/auth-choice-D-8Ti3vA.js +219 -0
- package/dist/auth-choice-DN87_4lW.js +610 -0
- package/dist/auth-choice-in4GYJhH.js +64 -0
- package/dist/auth-choice-legacy-Clyw2lVc.js +17 -0
- package/dist/auth-choice-options-Bu05kzZL.js +127 -0
- package/dist/auth-choice-prompt-BCN6pEXi.js +215 -0
- package/dist/auth-choice-prompt-CtrY5wqR.js +36 -0
- package/dist/auth-choice.apply-helpers-BibBSEl9.js +66 -0
- package/dist/auth-choice.plugin-providers.runtime-T3IBLR0k.js +219 -0
- package/dist/auth-health-BKOrx-5O.js +166 -0
- package/dist/auth-mode-policy-DywddkT-.js +18 -0
- package/dist/auth-profiles-CDiIWpd-.js +1047 -0
- package/dist/auth-profiles.runtime-SDKdG_z_.js +48 -0
- package/dist/avatar-policy-Ds9e6uHI.js +67 -0
- package/dist/backup-create-CwfGrmvZ.js +461 -0
- package/dist/banner-TF-M94dP.js +351 -0
- package/dist/base-session-key-Cf2rkwag.js +14 -0
- package/dist/bindings-BV4AtNSY.js +21 -0
- package/dist/bindings-kjwuC11Q.js +69 -0
- package/dist/bluebubbles-C1M3Geg0.js +87 -0
- package/dist/bluebubbles-CahJ717x.js +603 -0
- package/dist/bluebubbles-dEl4QpYz.js +37 -0
- package/dist/bonjour-discovery-C2oY96BG.js +376 -0
- package/dist/boolean-DKtCJu_W.js +29 -0
- package/dist/boolean-param-xAGXUSSN.js +13 -0
- package/dist/boundary-file-read-BP6VMpqH.js +106 -0
- package/dist/boundary-path-B3FFLYNx.js +557 -0
- package/dist/brave--q9r6diS.js +405 -0
- package/dist/brew-DSwWqzLd.js +44 -0
- package/dist/browser-cli-BLE-cZxz.js +1502 -0
- package/dist/build-info.json +5 -0
- package/dist/bundled/boot-md/HOOK.md +20 -0
- package/dist/bundled/boot-md/handler.js +381 -0
- package/dist/bundled/bootstrap-extra-files/HOOK.md +53 -0
- package/dist/bundled/bootstrap-extra-files/handler.js +56 -0
- package/dist/bundled/command-logger/HOOK.md +122 -0
- package/dist/bundled/command-logger/handler.js +62 -0
- package/dist/bundled/session-memory/HOOK.md +109 -0
- package/dist/bundled/session-memory/handler.js +401 -0
- package/dist/call-6gyz3vtP.js +44 -0
- package/dist/call-I0SGvyU7.js +639 -0
- package/dist/canvas-host/a2ui/.bundle.hash +1 -0
- package/dist/canvas-host/a2ui/a2ui.bundle.js +1 -0
- package/dist/canvas-host/a2ui/index.html +307 -0
- package/dist/catalog-BwAYUfL7.js +240 -0
- package/dist/channel-5NZHO7iU.js +4945 -0
- package/dist/channel-BJK4S8ZH.js +1006 -0
- package/dist/channel-CNodzoey.js +321 -0
- package/dist/channel-UyhyMj09.js +1077 -0
- package/dist/channel-account-context-DXI4NQFD.js +104 -0
- package/dist/channel-actions-DU2CR3xW.js +37 -0
- package/dist/channel-activity-B8aReQoE.js +35 -0
- package/dist/channel-config-3Uv6ve2_.js +115 -0
- package/dist/channel-config-helpers-ChUYvBB0.js +377 -0
- package/dist/channel-config-schema-DEVsCZpj.js +1 -0
- package/dist/channel-feedback-G6zh8efr.js +245 -0
- package/dist/channel-inbound-3L_8TOZ0.js +395 -0
- package/dist/channel-lifecycle-CpU1dRbh.js +354 -0
- package/dist/channel-options-DJaIP4Dv.js +38 -0
- package/dist/channel-pairing-rNA4qQPY.js +66 -0
- package/dist/channel-pb3INhpi.js +1284 -0
- package/dist/channel-plugin-common-BhTxCE5t.js +1 -0
- package/dist/channel-plugin-ids-CFeS3qir.js +26 -0
- package/dist/channel-plugin-resolution-BSK2VmVJ.js +112 -0
- package/dist/channel-policy-C4GKHvhz.js +1 -0
- package/dist/channel-reply-pipeline-CPTuaW8n.js +15 -0
- package/dist/channel-send-result-By8EpCPw.js +40 -0
- package/dist/channel-setup-BiFBGGLd.js +49 -0
- package/dist/channel-shared-B7nVL6s_.js +308 -0
- package/dist/channel-summary-BDcfGPTZ.js +137 -0
- package/dist/channel-summary-rf4JbM-W.js +41 -0
- package/dist/channel-targets-DfnKGXez.js +87 -0
- package/dist/channel-xTzNVpmF.js +1602 -0
- package/dist/channel.runtime-BgaUUB7d.js +268 -0
- package/dist/channel.runtime-C3f_klCw.js +324 -0
- package/dist/channel.runtime-CdJxCNlJ.js +512 -0
- package/dist/channel.runtime-CzzQWPgu.js +35 -0
- package/dist/channel.runtime-PVCKVe5x.js +288 -0
- package/dist/channel.runtime-jBXnZL1S.js +230 -0
- package/dist/channels-CRtKc7T_.js +1393 -0
- package/dist/channels-XmRcwHO_.js +408 -0
- package/dist/channels-cli-BgTInHdf.js +412 -0
- package/dist/channels-status-issues-C_U44M8Y.js +16 -0
- package/dist/chat-type-C-n03mQY.js +10 -0
- package/dist/clack-prompter-DuzDnaLi.js +112 -0
- package/dist/clawbot-cli-lS6Ntjly.js +218 -0
- package/dist/cli/daemon-cli.js +9 -0
- package/dist/cli-DBYk4h7a.js +254 -0
- package/dist/cli-name-Daok7A7-.js +25 -0
- package/dist/cli-runtime-aAVwbEYy.js +7 -0
- package/dist/cli-startup-metadata.json +26 -0
- package/dist/cli-utils-Np4NAAtt.js +39 -0
- package/dist/command-format-CjE6bLiz.js +21 -0
- package/dist/command-format-D7pz5AcU.js +2 -0
- package/dist/command-gating-BQXGSqc9.js +40 -0
- package/dist/command-options-5coRiipK.js +25 -0
- package/dist/command-poll-backoff-CpkSns-6.js +56 -0
- package/dist/command-poll-backoff.runtime-YT6EGcLN.js +7 -0
- package/dist/command-registry-BYuNrgu_.js +14 -0
- package/dist/command-registry-Dkr1-w1Q.js +242 -0
- package/dist/command-secret-gateway-u-EjduIr.js +211 -0
- package/dist/command-secret-targets-COcwhn-D.js +88 -0
- package/dist/command-secret-targets-CQJT3viO.js +3 -0
- package/dist/commands-Bb9xUwz9.js +42 -0
- package/dist/commands-core-CD6RD8UX.js +4923 -0
- package/dist/commands-core.runtime-DhRG5rok.js +232 -0
- package/dist/commands-registry-ChCep1KJ.js +295 -0
- package/dist/commands-registry.data-XyUTELK9.js +904 -0
- package/dist/commands-registry.runtime-m5WTxFtv.js +25 -0
- package/dist/commands-status.runtime-DZwdZgLZ.js +211 -0
- package/dist/commands.runtime-BbpkbBbI.js +232 -0
- package/dist/common-CUBlLRXB.js +457 -0
- package/dist/compact.runtime-DwG4Ix3B.js +216 -0
- package/dist/completion-cli-CYjSNenV.js +17 -0
- package/dist/completion-cli-CuQ2VNX5.js +445 -0
- package/dist/config-6sZwvXJD.js +88 -0
- package/dist/config-C-Ef7QhH.js +23 -0
- package/dist/config-DdDLrP_v.js +273 -0
- package/dist/config-Dgkla4O3.js +38 -0
- package/dist/config-cli-BV16bUmI.js +945 -0
- package/dist/config-guard-BcYEe-kl.js +126 -0
- package/dist/config-helpers-3u5wfLBu.js +117 -0
- package/dist/config-presence-BmUF_5K9.js +79 -0
- package/dist/config-regex-CvZFnWkO.js +39 -0
- package/dist/config-runtime-CstET7fq.js +142 -0
- package/dist/config-schema-5YkIW1xw.js +270 -0
- package/dist/config-schema-B1UGMwZ8.js +31 -0
- package/dist/config-schema-DzlnsY3D.js +33 -0
- package/dist/config-state-CE0CGjey.js +288 -0
- package/dist/config-validation-BEVsnUBu.js +272 -0
- package/dist/config-value-DgJrpclm.js +25 -0
- package/dist/configure-CRx5OThC.js +1126 -0
- package/dist/configure-D4Lh7bhs.js +344 -0
- package/dist/connection-auth-CB_IINnP.js +30 -0
- package/dist/constants-C_Scc680.js +71 -0
- package/dist/control-ui/apple-touch-icon.png +0 -0
- package/dist/control-ui/assets/index-BS0un8Wb.js +18 -0
- package/dist/control-ui/assets/index-DkMftoEy.css +1 -0
- package/dist/control-ui/favicon-32.png +0 -0
- package/dist/control-ui/favicon.ico +0 -0
- package/dist/control-ui/favicon.svg +22 -0
- package/dist/control-ui/index.html +17 -0
- package/dist/control-ui-assets-DjqeIg6A.js +232 -0
- package/dist/control-ui-shared-DP000Pxd.js +29 -0
- package/dist/conversation-runtime-zmG5YBsE.js +1458 -0
- package/dist/core-BV7ewUK4.js +187 -0
- package/dist/core-command-descriptors-CuKGKQIe.js +96 -0
- package/dist/credentials-BPwBlm1X.js +265 -0
- package/dist/cron-cli-CQlFbxlu.js +579 -0
- package/dist/daemon-cli-COhDevTB.js +354 -0
- package/dist/daemon-install-Ma4HdDtf.js +134 -0
- package/dist/daemon-install-plan.shared-cFfBUeV2.js +222 -0
- package/dist/daemon-runtime-CbClrCwc.js +12 -0
- package/dist/dangerous-config-flags-BJtLWIk7.js +15 -0
- package/dist/dangerous-name-matching-DZa_t0RM.js +44 -0
- package/dist/dangerous-tools-yGPDFTHh.js +27 -0
- package/dist/date-time-DCAyaBop.js +118 -0
- package/dist/dedupe-Cgnk5BbX.js +55 -0
- package/dist/defaults-CEdZhIIb.js +6 -0
- package/dist/delegate-DTiRmxH5.js +43 -0
- package/dist/deliver-BUIGBDbK.js +212 -0
- package/dist/deliver-runtime-BY7Zrac7.js +211 -0
- package/dist/delivery-queue-B19wDCjT.js +3 -0
- package/dist/delivery-queue-DrrqB4Hi.js +299 -0
- package/dist/device-auth-GEXe9vqR.js +15 -0
- package/dist/device-bootstrap-CwwokLEY.js +96 -0
- package/dist/device-bootstrap-Dbhe6oe8.js +1 -0
- package/dist/device-metadata-normalization-BDSQ_eA7.js +21 -0
- package/dist/device-pairing-CeI55dBv.js +560 -0
- package/dist/devices-cli-BXm0dkB2.js +366 -0
- package/dist/diagnostic-DBAi0Q5B.js +310 -0
- package/dist/diagnostic-events-ktCoG8Br.js +48 -0
- package/dist/diagnostics-QM3vI6rj.js +14 -0
- package/dist/diagnostics-XVyUA90d.js +33 -0
- package/dist/directive-handling.fast-lane-C7se5K_I.js +273 -0
- package/dist/directive-handling.impl-DMqj3m0-.js +638 -0
- package/dist/directive-handling.impl-aong_bNF.js +214 -0
- package/dist/directive-handling.levels-8vnMeuGX.js +2 -0
- package/dist/directive-handling.levels-CoruY1AA.js +13 -0
- package/dist/directive-handling.persist.runtime-ZWDdE5tG.js +170 -0
- package/dist/directive-handling.shared-B0RjHp7h.js +147 -0
- package/dist/directory-cli-I6eodbBS.js +437 -0
- package/dist/directory-config-helpers-CURJ8mj7.js +129 -0
- package/dist/directory-runtime-DhC8QkMq.js +19 -0
- package/dist/directory.static-B4VBitVO.js +44 -0
- package/dist/discord-Cu5CoXrA.js +214 -0
- package/dist/discord-core-5tkl-BzP.js +1 -0
- package/dist/discord-dOQ4uo2e.js +635 -0
- package/dist/dm-policy-shared-6bCJzHOS.js +188 -0
- package/dist/dns-cli-Dr0_Afcp.js +223 -0
- package/dist/docker-COe8Snwj.js +1254 -0
- package/dist/docs-cli-BkY5rqBi.js +176 -0
- package/dist/doctor-completion-CU7jR9vY.js +90 -0
- package/dist/doctor-config-preflight-Bj70HRt3.js +150 -0
- package/dist/doctor-config-preflight-C5h-tgtM.js +40 -0
- package/dist/doctor-state-migrations-CW1v5V4y.js +212 -0
- package/dist/doctor-state-migrations-ElD0NFmv.js +732 -0
- package/dist/entry-status-B2OWAf0s.js +172 -0
- package/dist/entry.js +219 -0
- package/dist/env-BP70DGuy.js +30 -0
- package/dist/env-overrides-JneV60sd.js +434 -0
- package/dist/env-overrides.runtime-DLrwions.js +18 -0
- package/dist/env-substitution-D6t_sLS_.js +136 -0
- package/dist/errors-BxyFnvP3.js +58 -0
- package/dist/exec-Dmex2w_d.js +310 -0
- package/dist/exec-approvals-BJhuySBz.js +386 -0
- package/dist/exec-approvals-allowlist-BboWC4n9.js +384 -0
- package/dist/exec-approvals-cli-rer7oVfh.js +427 -0
- package/dist/exec-safe-bin-runtime-policy-BL5_Z-KU.js +89 -0
- package/dist/exec-safety-CaaBy-Zw.js +24 -0
- package/dist/export-html/template.css +1060 -0
- package/dist/export-html/template.html +88 -0
- package/dist/export-html/template.js +1875 -0
- package/dist/extension-shared-5txN7IXK.js +74 -0
- package/dist/extensionAPI.js +218 -0
- package/dist/extensions/acpx/openclaw.plugin.json +120 -0
- package/dist/extensions/acpx/package.json +14 -0
- package/dist/extensions/acpx/skills/acp-router/SKILL.md +219 -0
- package/dist/extensions/amazon-bedrock/index.js +231 -0
- package/dist/extensions/amazon-bedrock/openclaw.plugin.json +11 -0
- package/dist/extensions/amazon-bedrock/package.json +12 -0
- package/dist/extensions/anthropic/index.js +330 -0
- package/dist/extensions/anthropic/openclaw.plugin.json +42 -0
- package/dist/extensions/anthropic/package.json +12 -0
- package/dist/extensions/bluebubbles/index.js +224 -0
- package/dist/extensions/bluebubbles/openclaw.plugin.json +11 -0
- package/dist/extensions/bluebubbles/package.json +51 -0
- package/dist/extensions/bluebubbles/setup-entry.js +289 -0
- package/dist/extensions/brave/index.js +23 -0
- package/dist/extensions/brave/openclaw.plugin.json +45 -0
- package/dist/extensions/brave/package.json +12 -0
- package/dist/extensions/byteplus/index.js +112 -0
- package/dist/extensions/byteplus/openclaw.plugin.json +32 -0
- package/dist/extensions/byteplus/package.json +12 -0
- package/dist/extensions/chutes/index.js +221 -0
- package/dist/extensions/chutes/openclaw.plugin.json +44 -0
- package/dist/extensions/chutes/package.json +12 -0
- package/dist/extensions/cloudflare-ai-gateway/index.js +218 -0
- package/dist/extensions/cloudflare-ai-gateway/openclaw.plugin.json +32 -0
- package/dist/extensions/cloudflare-ai-gateway/package.json +12 -0
- package/dist/extensions/copilot-proxy/index.js +125 -0
- package/dist/extensions/copilot-proxy/openclaw.plugin.json +23 -0
- package/dist/extensions/copilot-proxy/package.json +12 -0
- package/dist/extensions/device-pair/index.js +1040 -0
- package/dist/extensions/device-pair/openclaw.plugin.json +20 -0
- package/dist/extensions/diagnostics-otel/openclaw.plugin.json +8 -0
- package/dist/extensions/diagnostics-otel/package.json +27 -0
- package/dist/extensions/diffs/openclaw.plugin.json +216 -0
- package/dist/extensions/diffs/package.json +20 -0
- package/dist/extensions/diffs/skills/diffs/SKILL.md +22 -0
- package/dist/extensions/discord/index.js +215 -0
- package/dist/extensions/discord/openclaw.plugin.json +11 -0
- package/dist/extensions/discord/package.json +40 -0
- package/dist/extensions/discord/setup-entry.js +215 -0
- package/dist/extensions/elevenlabs/index.js +223 -0
- package/dist/extensions/elevenlabs/openclaw.plugin.json +8 -0
- package/dist/extensions/elevenlabs/package.json +12 -0
- package/dist/extensions/fal/index.js +112 -0
- package/dist/extensions/fal/openclaw.plugin.json +34 -0
- package/dist/extensions/fal/package.json +12 -0
- package/dist/extensions/feishu/index.js +227 -0
- package/dist/extensions/feishu/openclaw.plugin.json +14 -0
- package/dist/extensions/feishu/package.json +42 -0
- package/dist/extensions/feishu/setup-entry.js +112 -0
- package/dist/extensions/feishu/skills/feishu-doc/SKILL.md +211 -0
- package/dist/extensions/feishu/skills/feishu-doc/references/block-types.md +103 -0
- package/dist/extensions/feishu/skills/feishu-drive/SKILL.md +97 -0
- package/dist/extensions/feishu/skills/feishu-perm/SKILL.md +119 -0
- package/dist/extensions/feishu/skills/feishu-wiki/SKILL.md +111 -0
- package/dist/extensions/firecrawl/index.js +211 -0
- package/dist/extensions/firecrawl/openclaw.plugin.json +41 -0
- package/dist/extensions/firecrawl/package.json +12 -0
- package/dist/extensions/github-copilot/index.js +490 -0
- package/dist/extensions/github-copilot/openclaw.plugin.json +30 -0
- package/dist/extensions/github-copilot/package.json +12 -0
- package/dist/extensions/google/index.js +211 -0
- package/dist/extensions/google/openclaw.plugin.json +71 -0
- package/dist/extensions/google/package.json +12 -0
- package/dist/extensions/googlechat/openclaw.plugin.json +11 -0
- package/dist/extensions/googlechat/package.json +46 -0
- package/dist/extensions/huggingface/index.js +108 -0
- package/dist/extensions/huggingface/openclaw.plugin.json +33 -0
- package/dist/extensions/huggingface/package.json +12 -0
- package/dist/extensions/imessage/index.js +223 -0
- package/dist/extensions/imessage/openclaw.plugin.json +11 -0
- package/dist/extensions/imessage/package.json +26 -0
- package/dist/extensions/imessage/setup-entry.js +220 -0
- package/dist/extensions/irc/index.js +220 -0
- package/dist/extensions/irc/openclaw.plugin.json +11 -0
- package/dist/extensions/irc/package.json +25 -0
- package/dist/extensions/irc/setup-entry.js +222 -0
- package/dist/extensions/kilocode/index.js +282 -0
- package/dist/extensions/kilocode/openclaw.plugin.json +32 -0
- package/dist/extensions/kilocode/package.json +12 -0
- package/dist/extensions/kimi-coding/index.js +148 -0
- package/dist/extensions/kimi-coding/openclaw.plugin.json +37 -0
- package/dist/extensions/kimi-coding/package.json +12 -0
- package/dist/extensions/line/index.js +57 -0
- package/dist/extensions/line/openclaw.plugin.json +11 -0
- package/dist/extensions/line/package.json +39 -0
- package/dist/extensions/line/setup-entry.js +49 -0
- package/dist/extensions/llm-task/index.js +157 -0
- package/dist/extensions/llm-task/openclaw.plugin.json +33 -0
- package/dist/extensions/llm-task/package.json +16 -0
- package/dist/extensions/lobster/index.js +261 -0
- package/dist/extensions/lobster/openclaw.plugin.json +10 -0
- package/dist/extensions/lobster/package.json +17 -0
- package/dist/extensions/matrix/openclaw.plugin.json +11 -0
- package/dist/extensions/matrix/package.json +53 -0
- package/dist/extensions/mattermost/index.js +220 -0
- package/dist/extensions/mattermost/openclaw.plugin.json +11 -0
- package/dist/extensions/mattermost/package.json +41 -0
- package/dist/extensions/mattermost/setup-entry.js +222 -0
- package/dist/extensions/memory-core/index.js +36 -0
- package/dist/extensions/memory-core/openclaw.plugin.json +9 -0
- package/dist/extensions/memory-core/package.json +20 -0
- package/dist/extensions/memory-lancedb/openclaw.plugin.json +92 -0
- package/dist/extensions/memory-lancedb/package.json +24 -0
- package/dist/extensions/microsoft/index.js +223 -0
- package/dist/extensions/microsoft/openclaw.plugin.json +8 -0
- package/dist/extensions/microsoft/package.json +12 -0
- package/dist/extensions/minimax/index.js +437 -0
- package/dist/extensions/minimax/openclaw.plugin.json +71 -0
- package/dist/extensions/minimax/package.json +12 -0
- package/dist/extensions/mistral/index.js +149 -0
- package/dist/extensions/mistral/openclaw.plugin.json +31 -0
- package/dist/extensions/mistral/package.json +12 -0
- package/dist/extensions/modelstudio/index.js +144 -0
- package/dist/extensions/modelstudio/openclaw.plugin.json +46 -0
- package/dist/extensions/modelstudio/package.json +12 -0
- package/dist/extensions/moonshot/index.js +211 -0
- package/dist/extensions/moonshot/openclaw.plugin.json +78 -0
- package/dist/extensions/moonshot/package.json +12 -0
- package/dist/extensions/msteams/openclaw.plugin.json +11 -0
- package/dist/extensions/msteams/package.json +48 -0
- package/dist/extensions/nextcloud-talk/index.js +221 -0
- package/dist/extensions/nextcloud-talk/openclaw.plugin.json +11 -0
- package/dist/extensions/nextcloud-talk/package.json +48 -0
- package/dist/extensions/nextcloud-talk/setup-entry.js +223 -0
- package/dist/extensions/nostr/openclaw.plugin.json +11 -0
- package/dist/extensions/nostr/package.json +45 -0
- package/dist/extensions/nvidia/index.js +29 -0
- package/dist/extensions/nvidia/openclaw.plugin.json +16 -0
- package/dist/extensions/nvidia/package.json +12 -0
- package/dist/extensions/ollama/index.js +118 -0
- package/dist/extensions/ollama/openclaw.plugin.json +28 -0
- package/dist/extensions/ollama/package.json +12 -0
- package/dist/extensions/open-prose/index.js +10 -0
- package/dist/extensions/open-prose/openclaw.plugin.json +13 -0
- package/dist/extensions/open-prose/package.json +12 -0
- package/dist/extensions/open-prose/skills/prose/LICENSE +21 -0
- package/dist/extensions/open-prose/skills/prose/SKILL.md +323 -0
- package/dist/extensions/open-prose/skills/prose/alt-borges.md +141 -0
- package/dist/extensions/open-prose/skills/prose/alts/arabian-nights.md +229 -0
- package/dist/extensions/open-prose/skills/prose/alts/borges.md +360 -0
- package/dist/extensions/open-prose/skills/prose/alts/folk.md +322 -0
- package/dist/extensions/open-prose/skills/prose/alts/homer.md +217 -0
- package/dist/extensions/open-prose/skills/prose/alts/kafka.md +373 -0
- package/dist/extensions/open-prose/skills/prose/alts/shared-appendix.md +35 -0
- package/dist/extensions/open-prose/skills/prose/compiler.md +2971 -0
- package/dist/extensions/open-prose/skills/prose/examples/01-hello-world.prose +4 -0
- package/dist/extensions/open-prose/skills/prose/examples/02-research-and-summarize.prose +6 -0
- package/dist/extensions/open-prose/skills/prose/examples/03-code-review.prose +17 -0
- package/dist/extensions/open-prose/skills/prose/examples/04-write-and-refine.prose +14 -0
- package/dist/extensions/open-prose/skills/prose/examples/05-debug-issue.prose +20 -0
- package/dist/extensions/open-prose/skills/prose/examples/06-explain-codebase.prose +17 -0
- package/dist/extensions/open-prose/skills/prose/examples/07-refactor.prose +20 -0
- package/dist/extensions/open-prose/skills/prose/examples/08-blog-post.prose +20 -0
- package/dist/extensions/open-prose/skills/prose/examples/09-research-with-agents.prose +25 -0
- package/dist/extensions/open-prose/skills/prose/examples/10-code-review-agents.prose +32 -0
- package/dist/extensions/open-prose/skills/prose/examples/11-skills-and-imports.prose +27 -0
- package/dist/extensions/open-prose/skills/prose/examples/12-secure-agent-permissions.prose +43 -0
- package/dist/extensions/open-prose/skills/prose/examples/13-variables-and-context.prose +51 -0
- package/dist/extensions/open-prose/skills/prose/examples/14-composition-blocks.prose +48 -0
- package/dist/extensions/open-prose/skills/prose/examples/15-inline-sequences.prose +23 -0
- package/dist/extensions/open-prose/skills/prose/examples/16-parallel-reviews.prose +19 -0
- package/dist/extensions/open-prose/skills/prose/examples/17-parallel-research.prose +19 -0
- package/dist/extensions/open-prose/skills/prose/examples/18-mixed-parallel-sequential.prose +36 -0
- package/dist/extensions/open-prose/skills/prose/examples/19-advanced-parallel.prose +71 -0
- package/dist/extensions/open-prose/skills/prose/examples/20-fixed-loops.prose +20 -0
- package/dist/extensions/open-prose/skills/prose/examples/21-pipeline-operations.prose +35 -0
- package/dist/extensions/open-prose/skills/prose/examples/22-error-handling.prose +51 -0
- package/dist/extensions/open-prose/skills/prose/examples/23-retry-with-backoff.prose +63 -0
- package/dist/extensions/open-prose/skills/prose/examples/24-choice-blocks.prose +86 -0
- package/dist/extensions/open-prose/skills/prose/examples/25-conditionals.prose +114 -0
- package/dist/extensions/open-prose/skills/prose/examples/26-parameterized-blocks.prose +100 -0
- package/dist/extensions/open-prose/skills/prose/examples/27-string-interpolation.prose +105 -0
- package/dist/extensions/open-prose/skills/prose/examples/28-automated-pr-review.prose +37 -0
- package/dist/extensions/open-prose/skills/prose/examples/28-gas-town.prose +1572 -0
- package/dist/extensions/open-prose/skills/prose/examples/29-captains-chair.prose +218 -0
- package/dist/extensions/open-prose/skills/prose/examples/30-captains-chair-simple.prose +42 -0
- package/dist/extensions/open-prose/skills/prose/examples/31-captains-chair-with-memory.prose +145 -0
- package/dist/extensions/open-prose/skills/prose/examples/33-pr-review-autofix.prose +168 -0
- package/dist/extensions/open-prose/skills/prose/examples/34-content-pipeline.prose +204 -0
- package/dist/extensions/open-prose/skills/prose/examples/35-feature-factory.prose +296 -0
- package/dist/extensions/open-prose/skills/prose/examples/36-bug-hunter.prose +237 -0
- package/dist/extensions/open-prose/skills/prose/examples/37-the-forge.prose +1474 -0
- package/dist/extensions/open-prose/skills/prose/examples/38-skill-scan.prose +455 -0
- package/dist/extensions/open-prose/skills/prose/examples/39-architect-by-simulation.prose +277 -0
- package/dist/extensions/open-prose/skills/prose/examples/40-rlm-self-refine.prose +32 -0
- package/dist/extensions/open-prose/skills/prose/examples/41-rlm-divide-conquer.prose +38 -0
- package/dist/extensions/open-prose/skills/prose/examples/42-rlm-filter-recurse.prose +46 -0
- package/dist/extensions/open-prose/skills/prose/examples/43-rlm-pairwise.prose +50 -0
- package/dist/extensions/open-prose/skills/prose/examples/44-run-endpoint-ux-test.prose +261 -0
- package/dist/extensions/open-prose/skills/prose/examples/45-plugin-release.prose +159 -0
- package/dist/extensions/open-prose/skills/prose/examples/45-run-endpoint-ux-test-with-remediation.prose +637 -0
- package/dist/extensions/open-prose/skills/prose/examples/46-run-endpoint-ux-test-fast.prose +148 -0
- package/dist/extensions/open-prose/skills/prose/examples/46-workflow-crystallizer.prose +225 -0
- package/dist/extensions/open-prose/skills/prose/examples/47-language-self-improvement.prose +356 -0
- package/dist/extensions/open-prose/skills/prose/examples/48-habit-miner.prose +445 -0
- package/dist/extensions/open-prose/skills/prose/examples/49-prose-run-retrospective.prose +210 -0
- package/dist/extensions/open-prose/skills/prose/examples/README.md +391 -0
- package/dist/extensions/open-prose/skills/prose/examples/roadmap/README.md +22 -0
- package/dist/extensions/open-prose/skills/prose/examples/roadmap/iterative-refinement.prose +20 -0
- package/dist/extensions/open-prose/skills/prose/examples/roadmap/parallel-review.prose +18 -0
- package/dist/extensions/open-prose/skills/prose/examples/roadmap/simple-pipeline.prose +17 -0
- package/dist/extensions/open-prose/skills/prose/examples/roadmap/syntax/open-prose-syntax.prose +223 -0
- package/dist/extensions/open-prose/skills/prose/guidance/antipatterns.md +951 -0
- package/dist/extensions/open-prose/skills/prose/guidance/patterns.md +700 -0
- package/dist/extensions/open-prose/skills/prose/guidance/system-prompt.md +180 -0
- package/dist/extensions/open-prose/skills/prose/help.md +144 -0
- package/dist/extensions/open-prose/skills/prose/lib/README.md +108 -0
- package/dist/extensions/open-prose/skills/prose/lib/calibrator.prose +215 -0
- package/dist/extensions/open-prose/skills/prose/lib/cost-analyzer.prose +174 -0
- package/dist/extensions/open-prose/skills/prose/lib/error-forensics.prose +250 -0
- package/dist/extensions/open-prose/skills/prose/lib/inspector.prose +196 -0
- package/dist/extensions/open-prose/skills/prose/lib/profiler.prose +460 -0
- package/dist/extensions/open-prose/skills/prose/lib/program-improver.prose +275 -0
- package/dist/extensions/open-prose/skills/prose/lib/project-memory.prose +118 -0
- package/dist/extensions/open-prose/skills/prose/lib/user-memory.prose +93 -0
- package/dist/extensions/open-prose/skills/prose/lib/vm-improver.prose +243 -0
- package/dist/extensions/open-prose/skills/prose/primitives/session.md +593 -0
- package/dist/extensions/open-prose/skills/prose/prose.md +1237 -0
- package/dist/extensions/open-prose/skills/prose/state/filesystem.md +498 -0
- package/dist/extensions/open-prose/skills/prose/state/in-context.md +384 -0
- package/dist/extensions/open-prose/skills/prose/state/postgres.md +880 -0
- package/dist/extensions/open-prose/skills/prose/state/sqlite.md +531 -0
- package/dist/extensions/openai/index.js +677 -0
- package/dist/extensions/openai/openclaw.plugin.json +42 -0
- package/dist/extensions/openai/package.json +12 -0
- package/dist/extensions/opencode/index.js +116 -0
- package/dist/extensions/opencode/openclaw.plugin.json +32 -0
- package/dist/extensions/opencode/package.json +12 -0
- package/dist/extensions/opencode-go/index.js +114 -0
- package/dist/extensions/opencode-go/openclaw.plugin.json +32 -0
- package/dist/extensions/opencode-go/package.json +12 -0
- package/dist/extensions/openrouter/index.js +398 -0
- package/dist/extensions/openrouter/openclaw.plugin.json +31 -0
- package/dist/extensions/openrouter/package.json +12 -0
- package/dist/extensions/openshell/index.js +923 -0
- package/dist/extensions/openshell/openclaw.plugin.json +99 -0
- package/dist/extensions/openshell/package.json +12 -0
- package/dist/extensions/perplexity/index.js +23 -0
- package/dist/extensions/perplexity/openclaw.plugin.json +49 -0
- package/dist/extensions/perplexity/package.json +12 -0
- package/dist/extensions/phone-control/index.js +276 -0
- package/dist/extensions/phone-control/openclaw.plugin.json +10 -0
- package/dist/extensions/qianfan/index.js +114 -0
- package/dist/extensions/qianfan/openclaw.plugin.json +31 -0
- package/dist/extensions/qianfan/package.json +12 -0
- package/dist/extensions/qwen-portal-auth/index.js +350 -0
- package/dist/extensions/qwen-portal-auth/openclaw.plugin.json +29 -0
- package/dist/extensions/sglang/index.js +285 -0
- package/dist/extensions/sglang/openclaw.plugin.json +28 -0
- package/dist/extensions/sglang/package.json +12 -0
- package/dist/extensions/signal/index.js +218 -0
- package/dist/extensions/signal/openclaw.plugin.json +11 -0
- package/dist/extensions/signal/package.json +23 -0
- package/dist/extensions/signal/setup-entry.js +218 -0
- package/dist/extensions/slack/index.js +222 -0
- package/dist/extensions/slack/openclaw.plugin.json +11 -0
- package/dist/extensions/slack/package.json +30 -0
- package/dist/extensions/slack/setup-entry.js +220 -0
- package/dist/extensions/synology-chat/index.js +56 -0
- package/dist/extensions/synology-chat/openclaw.plugin.json +11 -0
- package/dist/extensions/synology-chat/package.json +29 -0
- package/dist/extensions/synology-chat/setup-entry.js +58 -0
- package/dist/extensions/synthetic/index.js +112 -0
- package/dist/extensions/synthetic/openclaw.plugin.json +31 -0
- package/dist/extensions/synthetic/package.json +12 -0
- package/dist/extensions/talk-voice/index.js +197 -0
- package/dist/extensions/talk-voice/openclaw.plugin.json +10 -0
- package/dist/extensions/tavily/index.js +211 -0
- package/dist/extensions/tavily/openclaw.plugin.json +44 -0
- package/dist/extensions/tavily/package.json +12 -0
- package/dist/extensions/tavily/skills/tavily/SKILL.md +94 -0
- package/dist/extensions/telegram/index.js +221 -0
- package/dist/extensions/telegram/openclaw.plugin.json +11 -0
- package/dist/extensions/telegram/package.json +31 -0
- package/dist/extensions/telegram/setup-entry.js +221 -0
- package/dist/extensions/thread-ownership/index.js +70 -0
- package/dist/extensions/thread-ownership/openclaw.plugin.json +30 -0
- package/dist/extensions/tlon/bundled-skills/@tloncorp/tlon-skill/README.md +143 -0
- package/dist/extensions/tlon/bundled-skills/@tloncorp/tlon-skill/SKILL.md +375 -0
- package/dist/extensions/tlon/bundled-skills/@tloncorp/tlon-skill/bin/tlon.js +96 -0
- package/dist/extensions/tlon/bundled-skills/@tloncorp/tlon-skill/package.json +40 -0
- package/dist/extensions/tlon/bundled-skills/@tloncorp/tlon-skill/references/hooks-examples/auto-react.hoon +24 -0
- package/dist/extensions/tlon/bundled-skills/@tloncorp/tlon-skill/references/hooks-examples/delete-old-posts.hoon +18 -0
- package/dist/extensions/tlon/bundled-skills/@tloncorp/tlon-skill/references/hooks-examples/word-filter.hoon +52 -0
- package/dist/extensions/tlon/bundled-skills/@tloncorp/tlon-skill/references/hooks.md +366 -0
- package/dist/extensions/tlon/bundled-skills/@tloncorp/tlon-skill/references/urbit-api.md +113 -0
- package/dist/extensions/tlon/bundled-skills/@tloncorp/tlon-skill/scripts/postinstall.js +74 -0
- package/dist/extensions/tlon/openclaw.plugin.json +14 -0
- package/dist/extensions/tlon/package.json +45 -0
- package/dist/extensions/together/index.js +113 -0
- package/dist/extensions/together/openclaw.plugin.json +31 -0
- package/dist/extensions/together/package.json +12 -0
- package/dist/extensions/twitch/openclaw.plugin.json +11 -0
- package/dist/extensions/twitch/package.json +27 -0
- package/dist/extensions/venice/index.js +132 -0
- package/dist/extensions/venice/openclaw.plugin.json +31 -0
- package/dist/extensions/venice/package.json +12 -0
- package/dist/extensions/vercel-ai-gateway/index.js +86 -0
- package/dist/extensions/vercel-ai-gateway/openclaw.plugin.json +31 -0
- package/dist/extensions/vercel-ai-gateway/package.json +12 -0
- package/dist/extensions/vllm/index.js +285 -0
- package/dist/extensions/vllm/openclaw.plugin.json +28 -0
- package/dist/extensions/vllm/package.json +12 -0
- package/dist/extensions/voice-call/index.js +5715 -0
- package/dist/extensions/voice-call/openclaw.plugin.json +648 -0
- package/dist/extensions/voice-call/package.json +31 -0
- package/dist/extensions/volcengine/index.js +112 -0
- package/dist/extensions/volcengine/openclaw.plugin.json +32 -0
- package/dist/extensions/volcengine/package.json +12 -0
- package/dist/extensions/whatsapp/openclaw.plugin.json +11 -0
- package/dist/extensions/whatsapp/package.json +44 -0
- package/dist/extensions/xai/index.js +211 -0
- package/dist/extensions/xai/openclaw.plugin.json +65 -0
- package/dist/extensions/xai/package.json +12 -0
- package/dist/extensions/xiaomi/index.js +115 -0
- package/dist/extensions/xiaomi/openclaw.plugin.json +31 -0
- package/dist/extensions/xiaomi/package.json +12 -0
- package/dist/extensions/zai/index.js +559 -0
- package/dist/extensions/zai/openclaw.plugin.json +88 -0
- package/dist/extensions/zai/package.json +12 -0
- package/dist/extensions/zalo/index.js +225 -0
- package/dist/extensions/zalo/openclaw.plugin.json +11 -0
- package/dist/extensions/zalo/package.json +48 -0
- package/dist/extensions/zalo/setup-entry.js +226 -0
- package/dist/extensions/zalouser/openclaw.plugin.json +11 -0
- package/dist/extensions/zalouser/package.json +49 -0
- package/dist/external-content-BUdUOqkv.js +238 -0
- package/dist/feishu-CiuVx86p.js +62821 -0
- package/dist/feishu-DKboNv0e.js +2664 -0
- package/dist/fetch-guard-DIyN1HW5.js +165 -0
- package/dist/fetch-timeout-C5xpMuGd.js +36 -0
- package/dist/file-identity-Cw0fQxYY.js +11 -0
- package/dist/file-lock-WbEmczmY.js +107 -0
- package/dist/filter-oMGaNOM1.js +20 -0
- package/dist/follow-redirects-BPQ_NgUo.js +9143 -0
- package/dist/format-DH8ysi7s.js +19 -0
- package/dist/format-datetime-BGS6tLDE.js +73 -0
- package/dist/format-duration-CO0BGWB0.js +57 -0
- package/dist/format-relative-C3nDxnXz.js +54 -0
- package/dist/frontmatter-S5vS-I4a.js +309 -0
- package/dist/fs-safe-D3qzH-ab.js +731 -0
- package/dist/gateway-cli-CPLQ73W9.js +28403 -0
- package/dist/gateway-install-token-CKAQVM8-.js +164 -0
- package/dist/gateway-rpc-BsgPg6MU.js +26 -0
- package/dist/gateway-runtime-B5HHmFvN.js +42 -0
- package/dist/gaxios-fetch-compat-KX6bsqFm.js +165 -0
- package/dist/gemini-auth-B5ljg7jr.js +29 -0
- package/dist/git-commit-BIdLubm5.js +2 -0
- package/dist/git-commit-OvUvjri2.js +177 -0
- package/dist/github-copilot-auth-BBn03354.js +104 -0
- package/dist/global-singleton-4KwY5RvX.js +13 -0
- package/dist/globals-41sdSaKv.js +38 -0
- package/dist/gmail-setup-utils-BX68dZla.js +419 -0
- package/dist/group-access-DJZrYPx1.js +113 -0
- package/dist/group-keys-BD_IYSMs.js +44 -0
- package/dist/group-policy-CWFxv3iB.js +201 -0
- package/dist/group-policy-warnings-Ddu6lBkh.js +175 -0
- package/dist/health-BW_d3hKj.js +573 -0
- package/dist/health-format-B5XfOTuJ.js +26 -0
- package/dist/health-o6N--_xj.js +59 -0
- package/dist/heartbeat-7aHh0m3d.js +169 -0
- package/dist/heartbeat-summary-Das49TYq.js +57 -0
- package/dist/help-Cr5cdpTF.js +81 -0
- package/dist/help-format-Dv45FpYu.js +15 -0
- package/dist/helpers-CLNycoI8.js +32 -0
- package/dist/helpers-DJ-5HEbE.js +24 -0
- package/dist/history-CHjo8B5W.js +102 -0
- package/dist/hook-runtime-BnNBi_q4.js +1 -0
- package/dist/hooks-cli-Bj8_UM2C.js +1102 -0
- package/dist/hooks-policy-BL6HDLUn.js +20 -0
- package/dist/hooks-status-gzNmo3li.js +78 -0
- package/dist/host-env-security-BogNN146.js +223 -0
- package/dist/http-body-CCiSfloA.js +237 -0
- package/dist/http-registry-WFFbLYRd.js +153 -0
- package/dist/identity-DovQV4zD.js +112 -0
- package/dist/identity-cyBYcoXS.js +84 -0
- package/dist/identity-file-EndG1nfc.js +60 -0
- package/dist/image-DWkjd9ze.js +211 -0
- package/dist/image-generation-CsblUROw.js +441 -0
- package/dist/image-ops-j01UkxEv.js +371 -0
- package/dist/imessage-Bb83msoJ.js +219 -0
- package/dist/imessage-CsiCgRcg.js +190 -0
- package/dist/imessage-CytlwbMq.js +1451 -0
- package/dist/imessage-core-CsYJuaRZ.js +1 -0
- package/dist/inbound-envelope-4P3IIJc3.js +61 -0
- package/dist/inbound-reply-dispatch-B6JDKPpf.js +72 -0
- package/dist/includes-7XyL3p1c.js +188 -0
- package/dist/includes-scan-y-rS6tTw.js +55 -0
- package/dist/index.js +57 -0
- package/dist/infra/warning-filter.js +2 -0
- package/dist/inspect-TkOiUCgp.js +279 -0
- package/dist/install-safe-path-Rwbw1XCZ.js +62 -0
- package/dist/installs-CShDWoiR.js +532 -0
- package/dist/interactive-F7iY0yED.js +8 -0
- package/dist/interactive-runtime-OweOj_Vv.js +90 -0
- package/dist/internal-hooks-0uipqzRY.js +156 -0
- package/dist/io-BYmuc7ha.js +35 -0
- package/dist/io-BjKpaXU3.js +7161 -0
- package/dist/ip-C8vmzVu0.js +203 -0
- package/dist/ipv4-CJCNv_K7.js +82 -0
- package/dist/irc-BSHd6-tL.js +12 -0
- package/dist/irc-CO-H7Npu.js +660 -0
- package/dist/is-main-YViS6wOn.js +27 -0
- package/dist/issue-format-CBEXVico.js +31 -0
- package/dist/issue-format-D3HehoKZ.js +4 -0
- package/dist/json-file-C2zjA0Gv.js +23 -0
- package/dist/json-files-WW-H_psG.js +60 -0
- package/dist/json-pointer-f9dEnBoR.js +43 -0
- package/dist/json-store-O1LwpnBH.js +37 -0
- package/dist/kb-cli-DMZs6PCu.js +65 -0
- package/dist/keyed-async-queue-CPUWV5Pm.js +32 -0
- package/dist/kill-tree-CbjXBw3z.js +149 -0
- package/dist/kilocode-shared-DS7_0IMs.js +29 -0
- package/dist/launchd-DowEtzjr.js +491 -0
- package/dist/lazy-runtime-BcXbyAaC.js +1 -0
- package/dist/lazy-runtime-bWkd2cs3.js +29 -0
- package/dist/legacy-names-CUNZ4vHN.js +7 -0
- package/dist/legacy-web-search-BgZjNG2h.js +222 -0
- package/dist/lib-CERS7N4b.js +503 -0
- package/dist/lib-PPICrHv1.js +1938 -0
- package/dist/library-DJriL3ed.js +211 -0
- package/dist/lifecycle-core-D08nRlzW.js +382 -0
- package/dist/line/accounts.js +10 -0
- package/dist/line/send.js +39 -0
- package/dist/line/template-messages.js +2 -0
- package/dist/line-BX_d0Jwk.js +688 -0
- package/dist/line-CJSvwApm.js +1 -0
- package/dist/line-core-BOIxkjgu.js +1 -0
- package/dist/links-CKahSp5K.js +13 -0
- package/dist/llm-slug-generator-X_rlkFDe.js +68 -0
- package/dist/llm-slug-generator.js +212 -0
- package/dist/llm-task-Dx8ymRFr.js +1 -0
- package/dist/local-roots-DAzCjWbC.js +34 -0
- package/dist/location-DefAH9WS.js +42 -0
- package/dist/logger-CoEtkjhn.js +550 -0
- package/dist/logger-Cqy7-Maj.js +70 -0
- package/dist/logging-Bz1qZDPg.js +16 -0
- package/dist/logging-CS185p8Q.js +13 -0
- package/dist/logging-CbTTfADU.js +1 -0
- package/dist/logging-CrGwCjML.js +36 -0
- package/dist/logs-cli-C3x0gsGh.js +261 -0
- package/dist/magic-string.es-DJPWMt-n.js +1011 -0
- package/dist/main-session-DKr0lBVk.js +36 -0
- package/dist/manager-BF-xRVUt.js +2005 -0
- package/dist/manager-DjPRm0yC.js +4226 -0
- package/dist/manager-runtime-DoKa4efG.js +59 -0
- package/dist/manager.runtime-CdPdh296.js +827 -0
- package/dist/manifest-registry-B90TyTWl.js +1350 -0
- package/dist/map-size-CMTQVKUV.js +15 -0
- package/dist/markdown-to-line-BWwaRx5F.js +640 -0
- package/dist/mask-api-key-CprzEe7l.js +10 -0
- package/dist/matrix-CMi2y980.js +228 -0
- package/dist/matrix-migration-snapshot-NMxdum7C.js +702 -0
- package/dist/mattermost-Cduscjlj.js +15 -0
- package/dist/mattermost-DO0BCfF3.js +1 -0
- package/dist/mcp-cli-D0PqoKGl.js +94 -0
- package/dist/mcp-config-BcFTambR.js +108 -0
- package/dist/media-limits-Cuvmmhop.js +14 -0
- package/dist/media-understanding-DptzemF7.js +48 -0
- package/dist/media-understanding.runtime-w4DWJMEQ.js +216 -0
- package/dist/memory-DBjQ0TPd.js +1 -0
- package/dist/memory-cli-D2AtVbYN.js +215 -0
- package/dist/memory-cli-DNq4q-b4.js +541 -0
- package/dist/memory-search-Das1tiuB.js +204 -0
- package/dist/memory-search-DxmSTjHq.js +18 -0
- package/dist/mention-gating-B_q-EHFx.js +25 -0
- package/dist/mentions-Bxys_va0.js +154 -0
- package/dist/message-channel-Cy-gN4K2.js +106 -0
- package/dist/message-hook-mappers-BBTV3JRQ.js +249 -0
- package/dist/method-scopes-ChbR5hu0.js +2650 -0
- package/dist/mime-C4vVTBso.js +150 -0
- package/dist/minimal-C5yUxtHy.js +2120 -0
- package/dist/model-auth-Blh0xL9g.js +309 -0
- package/dist/model-auth-env-CF9ts7Th.js +111 -0
- package/dist/model-catalog.runtime-Bq_DOgMs.js +211 -0
- package/dist/model-id-normalization-Y-MIsyK_.js +16 -0
- package/dist/model-input-BB2wSAHb.js +20 -0
- package/dist/model-overrides-sIzKU2wo.js +84 -0
- package/dist/model-param-b-DIFEhICm.js +15 -0
- package/dist/model-picker-CCcVTPVs.js +400 -0
- package/dist/model-picker-DbqaKTMq.js +215 -0
- package/dist/model-picker.runtime-CkLp1x9k.js +224 -0
- package/dist/model-selection-BTpJnslv.js +437 -0
- package/dist/model-selection-slZyRw2d.js +765 -0
- package/dist/model-suppression.runtime-DaobH5cQ.js +216 -0
- package/dist/models-BN_CtDV3.js +2536 -0
- package/dist/models-Dp5Lga_a.js +226 -0
- package/dist/models-cli-Cd_3pVLS.js +418 -0
- package/dist/models-config-jp2ZYjgH.js +211 -0
- package/dist/models-config.providers.discovery-BaIk1NKL.js +141 -0
- package/dist/models-config.runtime-CYpoeHa4.js +211 -0
- package/dist/monitor-Bbfus89A.js +3145 -0
- package/dist/monitor-D63iuNTd.js +3272 -0
- package/dist/monitor-DAPxJ4Fy.js +878 -0
- package/dist/monitor-DlFPue4X.js +223 -0
- package/dist/multimodal-DC43jYNv.js +75 -0
- package/dist/mutable-allowlist-detectors-C6EAzWYE.js +62 -0
- package/dist/net-DlJFp95v.js +270 -0
- package/dist/network-mode-DOgvmom4.js +17 -0
- package/dist/nextcloud-talk-4niIjhpY.js +12 -0
- package/dist/nextcloud-talk-CwnkUy8E.js +1 -0
- package/dist/node-cli-BQ0uYRRJ.js +2484 -0
- package/dist/node-command-policy-Bg2g6Xjp.js +192 -0
- package/dist/node-commands-B6W6Eo0b.js +11 -0
- package/dist/node-require-BgDD9bTi.js +14 -0
- package/dist/node-resolve-BunMro3f.js +69 -0
- package/dist/node-service-DEZvLQRW.js +65 -0
- package/dist/node-startup-env-Gz8ZQniA.js +50 -0
- package/dist/nodes-cli-Dvhiks4b.js +1330 -0
- package/dist/nodes-screen-DkGtEg3m.js +401 -0
- package/dist/normalize-secret-input-_PgpexOG.js +32 -0
- package/dist/note-dfjacCV8.js +109 -0
- package/dist/npm-pack-install-DFT7_ufP.js +574 -0
- package/dist/npm-resolution-O8ezGXjk.js +60 -0
- package/dist/oauth.runtime-Dn3J7wCH.js +318 -0
- package/dist/oauth.runtime-qCkidk8J.js +180 -0
- package/dist/oauth.runtime-y9sB_ut5.js +687 -0
- package/dist/ollama-defaults-asNuGW4_.js +4 -0
- package/dist/onboard-D9IU-7uw.js +48 -0
- package/dist/onboard-DQaHGPRm.js +25 -0
- package/dist/onboard-DXqBeqiM.js +589 -0
- package/dist/onboard-channels-CfZTqyJW.js +300 -0
- package/dist/onboard-channels-Cl8Z603m.js +1257 -0
- package/dist/onboard-config-DFKb-0sE.js +29 -0
- package/dist/onboard-config-DYykzJhx.js +2 -0
- package/dist/onboard-custom-BH3efE8p.js +216 -0
- package/dist/onboard-custom-z5zb42R-.js +644 -0
- package/dist/onboard-helpers-BN19CLP5.js +335 -0
- package/dist/onboard-helpers-Ddb9wkxO.js +54 -0
- package/dist/onboard-hooks-Hiw3_8VL.js +73 -0
- package/dist/onboard-remote-Bdqyy2tX.js +59 -0
- package/dist/onboard-remote-DZ1c3za2.js +182 -0
- package/dist/onboard-search-8Xnnh8SX.js +446 -0
- package/dist/onboard-skills-BTVz6kVV.js +69 -0
- package/dist/onboard-skills-BskXWJGU.js +133 -0
- package/dist/openai-codex-provider.runtime-BFsopDHI.js +2 -0
- package/dist/openai-defaults-B7FUywsh.js +10 -0
- package/dist/openclaw-exec-env-AcZ9we1N.js +14 -0
- package/dist/openclaw-root-TUHYdr9B.js +88 -0
- package/dist/openclaw-tools.runtime-BI4ZZ6Ie.js +211 -0
- package/dist/outbound-media-69yrWRDt.js +11 -0
- package/dist/outbound-runtime-ic_7ulJJ.js +1 -0
- package/dist/pairing-challenge-pdOQqb2j.js +48 -0
- package/dist/pairing-cli-DXxrNtvB.js +150 -0
- package/dist/pairing-labels-CNKCSmBK.js +7 -0
- package/dist/pairing-message-CBv2njJT.js +4 -0
- package/dist/pairing-store-C4lsd4pO.js +590 -0
- package/dist/pairing-token-gKj4SNFJ.js +55 -0
- package/dist/parse-duration-BBGYkY0S.js +41 -0
- package/dist/parse-finite-number-CP4MQF_w.js +30 -0
- package/dist/parse-log-line-CVh9zu3Q.js +43 -0
- package/dist/parse-port-COyt3COn.js +8 -0
- package/dist/path-alias-guards-ZTKqurNH.js +40 -0
- package/dist/path-env-CPkz6U0Y.js +87 -0
- package/dist/paths-CTjJI9l0.js +179 -0
- package/dist/paths-GHJ97ebE.js +268 -0
- package/dist/paths-nCHyK08H.js +56 -0
- package/dist/perplexity-kYSLNo8o.js +422 -0
- package/dist/persistent-dedupe-bjKjVI5u.js +116 -0
- package/dist/pi-embedded-CDH9LrEg.js +172586 -0
- package/dist/pi-model-discovery-CuX5CDyZ.js +125 -0
- package/dist/pi-model-discovery-runtime-DUWeqjUv.js +44 -0
- package/dist/pi-tools.before-tool-call.runtime-D9NV63QP.js +387 -0
- package/dist/platform-launcher-CqGy6UhP.js +83 -0
- package/dist/plugin-entry-CwuwM1jC.js +17 -0
- package/dist/plugin-install-CpMYi2tB.js +184 -0
- package/dist/plugin-install-aDvFMLBT.js +216 -0
- package/dist/plugin-install-plan-B_2cLkDP.js +49 -0
- package/dist/plugin-registry-C7Z7CkLP.js +213 -0
- package/dist/plugin-registry-C8bgJflP.js +51 -0
- package/dist/plugin-sdk/account-helpers.d.ts +1 -0
- package/dist/plugin-sdk/account-helpers.js +3 -0
- package/dist/plugin-sdk/account-id.d.ts +1 -0
- package/dist/plugin-sdk/account-id.js +2 -0
- package/dist/plugin-sdk/account-resolution.d.ts +1 -0
- package/dist/plugin-sdk/account-resolution.js +216 -0
- package/dist/plugin-sdk/acp-runtime.d.ts +1 -0
- package/dist/plugin-sdk/acp-runtime.js +46 -0
- package/dist/plugin-sdk/agent-runtime.d.ts +1 -0
- package/dist/plugin-sdk/agent-runtime.js +215 -0
- package/dist/plugin-sdk/allow-from.d.ts +1 -0
- package/dist/plugin-sdk/allow-from.js +17 -0
- package/dist/plugin-sdk/allowlist-config-edit.d.ts +1 -0
- package/dist/plugin-sdk/allowlist-config-edit.js +2 -0
- package/dist/plugin-sdk/bluebubbles.d.ts +1 -0
- package/dist/plugin-sdk/bluebubbles.js +232 -0
- package/dist/plugin-sdk/boolean-param.d.ts +1 -0
- package/dist/plugin-sdk/boolean-param.js +2 -0
- package/dist/plugin-sdk/channel-actions.d.ts +1 -0
- package/dist/plugin-sdk/channel-actions.js +16 -0
- package/dist/plugin-sdk/channel-config-helpers.d.ts +1 -0
- package/dist/plugin-sdk/channel-config-helpers.js +15 -0
- package/dist/plugin-sdk/channel-config-schema.d.ts +1 -0
- package/dist/plugin-sdk/channel-config-schema.js +5 -0
- package/dist/plugin-sdk/channel-contract.d.ts +1 -0
- package/dist/plugin-sdk/channel-contract.js +1 -0
- package/dist/plugin-sdk/channel-feedback.d.ts +1 -0
- package/dist/plugin-sdk/channel-feedback.js +4 -0
- package/dist/plugin-sdk/channel-inbound.d.ts +1 -0
- package/dist/plugin-sdk/channel-inbound.js +53 -0
- package/dist/plugin-sdk/channel-lifecycle.d.ts +1 -0
- package/dist/plugin-sdk/channel-lifecycle.js +2 -0
- package/dist/plugin-sdk/channel-pairing.d.ts +1 -0
- package/dist/plugin-sdk/channel-pairing.js +2 -0
- package/dist/plugin-sdk/channel-policy.d.ts +1 -0
- package/dist/plugin-sdk/channel-policy.js +19 -0
- package/dist/plugin-sdk/channel-reply-pipeline.d.ts +1 -0
- package/dist/plugin-sdk/channel-reply-pipeline.js +23 -0
- package/dist/plugin-sdk/channel-runtime.d.ts +1 -0
- package/dist/plugin-sdk/channel-runtime.js +33 -0
- package/dist/plugin-sdk/channel-send-result.d.ts +1 -0
- package/dist/plugin-sdk/channel-send-result.js +2 -0
- package/dist/plugin-sdk/channel-setup.d.ts +1 -0
- package/dist/plugin-sdk/channel-setup.js +24 -0
- package/dist/plugin-sdk/channel-targets.d.ts +1 -0
- package/dist/plugin-sdk/channel-targets.js +3 -0
- package/dist/plugin-sdk/cli-runtime.d.ts +1 -0
- package/dist/plugin-sdk/cli-runtime.js +5 -0
- package/dist/plugin-sdk/command-auth.d.ts +1 -0
- package/dist/plugin-sdk/command-auth.js +212 -0
- package/dist/plugin-sdk/compat.js +59 -0
- package/dist/plugin-sdk/config-runtime.d.ts +1 -0
- package/dist/plugin-sdk/config-runtime.js +51 -0
- package/dist/plugin-sdk/conversation-runtime.d.ts +1 -0
- package/dist/plugin-sdk/conversation-runtime.js +55 -0
- package/dist/plugin-sdk/core.d.ts +1 -0
- package/dist/plugin-sdk/core.js +40 -0
- package/dist/plugin-sdk/device-bootstrap.d.ts +1 -0
- package/dist/plugin-sdk/device-bootstrap.js +6 -0
- package/dist/plugin-sdk/diagnostics-otel.d.ts +1 -0
- package/dist/plugin-sdk/diagnostics-otel.js +7 -0
- package/dist/plugin-sdk/diffs.d.ts +1 -0
- package/dist/plugin-sdk/diffs.js +3 -0
- package/dist/plugin-sdk/directory-runtime.d.ts +1 -0
- package/dist/plugin-sdk/directory-runtime.js +5 -0
- package/dist/plugin-sdk/discord-core.d.ts +1 -0
- package/dist/plugin-sdk/discord-core.js +26 -0
- package/dist/plugin-sdk/discord.d.ts +1 -0
- package/dist/plugin-sdk/discord.js +219 -0
- package/dist/plugin-sdk/extension-shared.d.ts +1 -0
- package/dist/plugin-sdk/extension-shared.js +15 -0
- package/dist/plugin-sdk/extensions/anthropic-vertex/provider-catalog.d.ts +5 -0
- package/dist/plugin-sdk/extensions/bluebubbles/runtime-api.d.ts +1 -0
- package/dist/plugin-sdk/extensions/bluebubbles/src/group-policy.d.ts +14 -0
- package/dist/plugin-sdk/extensions/brave/index.d.ts +8 -0
- package/dist/plugin-sdk/extensions/brave/src/brave-web-search-provider.d.ts +42 -0
- package/dist/plugin-sdk/extensions/discord/api.d.ts +14 -0
- package/dist/plugin-sdk/extensions/discord/runtime-api.d.ts +17 -0
- package/dist/plugin-sdk/extensions/discord/session-key-api.d.ts +1 -0
- package/dist/plugin-sdk/extensions/discord/src/account-inspect.d.ts +17 -0
- package/dist/plugin-sdk/extensions/discord/src/accounts.d.ts +27 -0
- package/dist/plugin-sdk/extensions/discord/src/actions/handle-action.d.ts +3 -0
- package/dist/plugin-sdk/extensions/discord/src/actions/handle-action.guild-admin.d.ts +9 -0
- package/dist/plugin-sdk/extensions/discord/src/actions/runtime.d.ts +5 -0
- package/dist/plugin-sdk/extensions/discord/src/actions/runtime.guild.d.ts +24 -0
- package/dist/plugin-sdk/extensions/discord/src/actions/runtime.messaging.d.ts +32 -0
- package/dist/plugin-sdk/extensions/discord/src/actions/runtime.moderation-shared.d.ts +13 -0
- package/dist/plugin-sdk/extensions/discord/src/actions/runtime.moderation.d.ts +10 -0
- package/dist/plugin-sdk/extensions/discord/src/actions/runtime.presence.d.ts +3 -0
- package/dist/plugin-sdk/extensions/discord/src/actions/runtime.shared.d.ts +1 -0
- package/dist/plugin-sdk/extensions/discord/src/api.d.ts +11 -0
- package/dist/plugin-sdk/extensions/discord/src/audit.d.ts +29 -0
- package/dist/plugin-sdk/extensions/discord/src/channel-actions.d.ts +2 -0
- package/dist/plugin-sdk/extensions/discord/src/chunk.d.ts +20 -0
- package/dist/plugin-sdk/extensions/discord/src/client.d.ts +24 -0
- package/dist/plugin-sdk/extensions/discord/src/components-registry.d.ts +16 -0
- package/dist/plugin-sdk/extensions/discord/src/components.d.ts +204 -0
- package/dist/plugin-sdk/extensions/discord/src/directory-cache.d.ts +10 -0
- package/dist/plugin-sdk/extensions/discord/src/directory-config.d.ts +3 -0
- package/dist/plugin-sdk/extensions/discord/src/directory-live.d.ts +3 -0
- package/dist/plugin-sdk/extensions/discord/src/draft-chunking.d.ts +6 -0
- package/dist/plugin-sdk/extensions/discord/src/draft-stream.d.ts +21 -0
- package/dist/plugin-sdk/extensions/discord/src/gateway-logging.d.ts +8 -0
- package/dist/plugin-sdk/extensions/discord/src/group-policy.d.ts +4 -0
- package/dist/plugin-sdk/extensions/discord/src/guilds.d.ts +6 -0
- package/dist/plugin-sdk/extensions/discord/src/mentions.d.ts +8 -0
- package/dist/plugin-sdk/extensions/discord/src/message-tool-schema.d.ts +96 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/agent-components-helpers.d.ts +155 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/agent-components.d.ts +28 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/allow-list.d.ts +189 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/auto-presence.d.ts +59 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/commands.d.ts +2 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/dm-command-auth.d.ts +24 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/dm-command-decision.d.ts +14 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/exec-approvals.d.ts +55 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/format.d.ts +13 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/gateway-error-guard.d.ts +6 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/gateway-plugin.d.ts +8 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/gateway-registry.d.ts +9 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/inbound-context.d.ts +22 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/inbound-job.d.ts +13 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/inbound-worker.d.ts +15 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/listeners.d.ts +67 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/message-handler.d.ts +13 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/message-handler.preflight.d.ts +14 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/message-handler.preflight.types.d.ts +88 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/message-handler.process.d.ts +2 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/message-utils.d.ts +45 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/model-picker-preferences.d.ts +18 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/model-picker.d.ts +117 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/native-command-context.d.ts +68 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/native-command-ui.d.ts +97 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/native-command.d.ts +19 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/preflight-audio.d.ts +21 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/preflight-audio.runtime.d.ts +3 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/presence-cache.d.ts +9 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/presence.d.ts +5 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/provider.allowlist.d.ts +14 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/provider.d.ts +26 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/provider.lifecycle.d.ts +27 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/reply-context.d.ts +17 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/reply-delivery.d.ts +40 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/rest-fetch.d.ts +2 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/route-resolution.d.ts +40 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/sender-identity.d.ts +31 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/startup-status.d.ts +4 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/status.d.ts +17 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/system-events.d.ts +2 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/thread-bindings.config.d.ts +11 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/thread-bindings.d.ts +8 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/thread-bindings.discord-api.d.ts +41 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/thread-bindings.lifecycle.d.ts +60 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/thread-bindings.manager.d.ts +21 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/thread-bindings.messages.d.ts +1 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/thread-bindings.persona.d.ts +6 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/thread-bindings.state.d.ts +79 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/thread-bindings.types.d.ts +79 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/thread-session-close.d.ts +15 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/threading.d.ts +98 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/timeouts.d.ts +14 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor/typing.d.ts +5 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor.d.ts +10 -0
- package/dist/plugin-sdk/extensions/discord/src/monitor.gateway.d.ts +14 -0
- package/dist/plugin-sdk/extensions/discord/src/normalize.d.ts +14 -0
- package/dist/plugin-sdk/extensions/discord/src/outbound-adapter.d.ts +3 -0
- package/dist/plugin-sdk/extensions/discord/src/pluralkit.d.ts +26 -0
- package/dist/plugin-sdk/extensions/discord/src/probe.d.ts +37 -0
- package/dist/plugin-sdk/extensions/discord/src/resolve-allowlist-common.d.ts +11 -0
- package/dist/plugin-sdk/extensions/discord/src/resolve-channels.d.ts +15 -0
- package/dist/plugin-sdk/extensions/discord/src/resolve-users.d.ts +14 -0
- package/dist/plugin-sdk/extensions/discord/src/retry.d.ts +12 -0
- package/dist/plugin-sdk/extensions/discord/src/runtime-api.d.ts +11 -0
- package/dist/plugin-sdk/extensions/discord/src/send.channels.d.ts +17 -0
- package/dist/plugin-sdk/extensions/discord/src/send.components.d.ts +24 -0
- package/dist/plugin-sdk/extensions/discord/src/send.d.ts +11 -0
- package/dist/plugin-sdk/extensions/discord/src/send.emojis-stickers.d.ts +4 -0
- package/dist/plugin-sdk/extensions/discord/src/send.guild.d.ts +24 -0
- package/dist/plugin-sdk/extensions/discord/src/send.messages.d.ts +20 -0
- package/dist/plugin-sdk/extensions/discord/src/send.outbound.d.ts +61 -0
- package/dist/plugin-sdk/extensions/discord/src/send.permissions.d.ts +20 -0
- package/dist/plugin-sdk/extensions/discord/src/send.reactions.d.ts +15 -0
- package/dist/plugin-sdk/extensions/discord/src/send.shared.d.ts +86 -0
- package/dist/plugin-sdk/extensions/discord/src/send.types.d.ts +148 -0
- package/dist/plugin-sdk/extensions/discord/src/send.typing.d.ts +5 -0
- package/dist/plugin-sdk/extensions/discord/src/session-key-normalization.d.ts +7 -0
- package/dist/plugin-sdk/extensions/discord/src/shared-interactive.d.ts +3 -0
- package/dist/plugin-sdk/extensions/discord/src/status-issues.d.ts +2 -0
- package/dist/plugin-sdk/extensions/discord/src/targets.d.ts +18 -0
- package/dist/plugin-sdk/extensions/discord/src/token.d.ts +11 -0
- package/dist/plugin-sdk/extensions/discord/src/ui.d.ts +19 -0
- package/dist/plugin-sdk/extensions/discord/src/voice/command.d.ts +15 -0
- package/dist/plugin-sdk/extensions/discord/src/voice/manager.d.ts +60 -0
- package/dist/plugin-sdk/extensions/discord/src/voice/manager.runtime.d.ts +5 -0
- package/dist/plugin-sdk/extensions/discord/src/voice/sdk-runtime.d.ts +3 -0
- package/dist/plugin-sdk/extensions/discord/src/voice-message.d.ts +50 -0
- package/dist/plugin-sdk/extensions/discord/timeouts.d.ts +1 -0
- package/dist/plugin-sdk/extensions/feishu/api.d.ts +4 -0
- package/dist/plugin-sdk/extensions/feishu/runtime-api.d.ts +1 -0
- package/dist/plugin-sdk/extensions/feishu/setup-api.d.ts +2 -0
- package/dist/plugin-sdk/extensions/feishu/src/accounts.d.ts +48 -0
- package/dist/plugin-sdk/extensions/feishu/src/async.d.ts +12 -0
- package/dist/plugin-sdk/extensions/feishu/src/bot-content.d.ts +82 -0
- package/dist/plugin-sdk/extensions/feishu/src/bot-sender-name.d.ts +16 -0
- package/dist/plugin-sdk/extensions/feishu/src/bot.d.ts +70 -0
- package/dist/plugin-sdk/extensions/feishu/src/client.d.ts +47 -0
- package/dist/plugin-sdk/extensions/feishu/src/config-schema.d.ts +550 -0
- package/dist/plugin-sdk/extensions/feishu/src/conversation-id.d.ts +17 -0
- package/dist/plugin-sdk/extensions/feishu/src/dedup.d.ts +19 -0
- package/dist/plugin-sdk/extensions/feishu/src/dynamic-agent.d.ts +18 -0
- package/dist/plugin-sdk/extensions/feishu/src/external-keys.d.ts +1 -0
- package/dist/plugin-sdk/extensions/feishu/src/media.d.ts +118 -0
- package/dist/plugin-sdk/extensions/feishu/src/mention.d.ts +52 -0
- package/dist/plugin-sdk/extensions/feishu/src/policy.d.ts +28 -0
- package/dist/plugin-sdk/extensions/feishu/src/post.d.ts +11 -0
- package/dist/plugin-sdk/extensions/feishu/src/probe.d.ts +10 -0
- package/dist/plugin-sdk/extensions/feishu/src/reply-dispatcher.d.ts +35 -0
- package/dist/plugin-sdk/extensions/feishu/src/runtime.d.ts +3 -0
- package/dist/plugin-sdk/extensions/feishu/src/secret-input.d.ts +1 -0
- package/dist/plugin-sdk/extensions/feishu/src/send-result.d.ts +12 -0
- package/dist/plugin-sdk/extensions/feishu/src/send-target.d.ts +10 -0
- package/dist/plugin-sdk/extensions/feishu/src/send.d.ts +131 -0
- package/dist/plugin-sdk/extensions/feishu/src/setup-core.d.ts +3 -0
- package/dist/plugin-sdk/extensions/feishu/src/setup-surface.d.ts +3 -0
- package/dist/plugin-sdk/extensions/feishu/src/streaming-card.d.ts +55 -0
- package/dist/plugin-sdk/extensions/feishu/src/targets.d.ts +6 -0
- package/dist/plugin-sdk/extensions/feishu/src/thread-bindings.d.ts +42 -0
- package/dist/plugin-sdk/extensions/feishu/src/types.d.ts +84 -0
- package/dist/plugin-sdk/extensions/feishu/src/typing.d.ts +57 -0
- package/dist/plugin-sdk/extensions/firecrawl/index.d.ts +8 -0
- package/dist/plugin-sdk/extensions/firecrawl/src/config.d.ts +25 -0
- package/dist/plugin-sdk/extensions/firecrawl/src/firecrawl-client.d.ts +43 -0
- package/dist/plugin-sdk/extensions/firecrawl/src/firecrawl-scrape-tool.d.ts +17 -0
- package/dist/plugin-sdk/extensions/firecrawl/src/firecrawl-search-provider.d.ts +2 -0
- package/dist/plugin-sdk/extensions/firecrawl/src/firecrawl-search-tool.d.ts +15 -0
- package/dist/plugin-sdk/extensions/google/gemini-cli-provider.d.ts +2 -0
- package/dist/plugin-sdk/extensions/google/index.d.ts +8 -0
- package/dist/plugin-sdk/extensions/google/media-understanding-provider.d.ts +6 -0
- package/dist/plugin-sdk/extensions/google/oauth.credentials.d.ts +21 -0
- package/dist/plugin-sdk/extensions/google/oauth.d.ts +5 -0
- package/dist/plugin-sdk/extensions/google/oauth.flow.d.ts +20 -0
- package/dist/plugin-sdk/extensions/google/oauth.http.d.ts +1 -0
- package/dist/plugin-sdk/extensions/google/oauth.project.d.ts +4 -0
- package/dist/plugin-sdk/extensions/google/oauth.runtime.d.ts +1 -0
- package/dist/plugin-sdk/extensions/google/oauth.shared.d.ts +33 -0
- package/dist/plugin-sdk/extensions/google/oauth.token.d.ts +2 -0
- package/dist/plugin-sdk/extensions/google/provider-models.d.ts +6 -0
- package/dist/plugin-sdk/extensions/google/runtime-api.d.ts +1 -0
- package/dist/plugin-sdk/extensions/google/src/gemini-web-search-provider.d.ts +13 -0
- package/dist/plugin-sdk/extensions/huggingface/provider-catalog.d.ts +2 -0
- package/dist/plugin-sdk/extensions/imessage/api.d.ts +4 -0
- package/dist/plugin-sdk/extensions/imessage/runtime-api.d.ts +6 -0
- package/dist/plugin-sdk/extensions/imessage/src/accounts.d.ts +16 -0
- package/dist/plugin-sdk/extensions/imessage/src/client.d.ts +46 -0
- package/dist/plugin-sdk/extensions/imessage/src/constants.d.ts +2 -0
- package/dist/plugin-sdk/extensions/imessage/src/group-policy.d.ts +14 -0
- package/dist/plugin-sdk/extensions/imessage/src/monitor/abort-handler.d.ts +9 -0
- package/dist/plugin-sdk/extensions/imessage/src/monitor/deliver.d.ts +14 -0
- package/dist/plugin-sdk/extensions/imessage/src/monitor/echo-cache.d.ts +9 -0
- package/dist/plugin-sdk/extensions/imessage/src/monitor/inbound-processing.d.ts +98 -0
- package/dist/plugin-sdk/extensions/imessage/src/monitor/loop-rate-limiter.d.ts +14 -0
- package/dist/plugin-sdk/extensions/imessage/src/monitor/monitor-provider.d.ts +7 -0
- package/dist/plugin-sdk/extensions/imessage/src/monitor/parse-notification.d.ts +2 -0
- package/dist/plugin-sdk/extensions/imessage/src/monitor/reflection-guard.d.ts +14 -0
- package/dist/plugin-sdk/extensions/imessage/src/monitor/runtime.d.ts +4 -0
- package/dist/plugin-sdk/extensions/imessage/src/monitor/sanitize-outbound.d.ts +6 -0
- package/dist/plugin-sdk/extensions/imessage/src/monitor/self-chat-cache.d.ts +16 -0
- package/dist/plugin-sdk/extensions/imessage/src/monitor/types.d.ts +37 -0
- package/dist/plugin-sdk/extensions/imessage/src/monitor.d.ts +2 -0
- package/dist/plugin-sdk/extensions/imessage/src/probe.d.ts +17 -0
- package/dist/plugin-sdk/extensions/imessage/src/send.d.ts +34 -0
- package/dist/plugin-sdk/extensions/imessage/src/target-parsing-helpers.d.ts +85 -0
- package/dist/plugin-sdk/extensions/imessage/src/targets.d.ts +27 -0
- package/dist/plugin-sdk/extensions/irc/api.d.ts +2 -0
- package/dist/plugin-sdk/extensions/irc/src/accounts.d.ts +23 -0
- package/dist/plugin-sdk/extensions/irc/src/control-chars.d.ts +3 -0
- package/dist/plugin-sdk/extensions/irc/src/normalize.d.ts +18 -0
- package/dist/plugin-sdk/extensions/irc/src/runtime-api.d.ts +1 -0
- package/dist/plugin-sdk/extensions/irc/src/setup-core.d.ts +10 -0
- package/dist/plugin-sdk/extensions/irc/src/setup-surface.d.ts +4 -0
- package/dist/plugin-sdk/extensions/irc/src/types.d.ts +83 -0
- package/dist/plugin-sdk/extensions/kilocode/provider-catalog.d.ts +3 -0
- package/dist/plugin-sdk/extensions/kimi-coding/provider-catalog.d.ts +10 -0
- package/dist/plugin-sdk/extensions/matrix/helper-api.d.ts +3 -0
- package/dist/plugin-sdk/extensions/matrix/runtime-api.d.ts +7 -0
- package/dist/plugin-sdk/extensions/matrix/src/account-selection.d.ts +6 -0
- package/dist/plugin-sdk/extensions/matrix/src/auth-precedence.d.ts +11 -0
- package/dist/plugin-sdk/extensions/matrix/src/env-vars.d.ts +10 -0
- package/dist/plugin-sdk/extensions/matrix/src/matrix/thread-bindings-shared.d.ts +77 -0
- package/dist/plugin-sdk/extensions/matrix/src/storage-paths.d.ts +26 -0
- package/dist/plugin-sdk/extensions/matrix/thread-bindings-runtime.d.ts +1 -0
- package/dist/plugin-sdk/extensions/modelstudio/provider-catalog.d.ts +4 -0
- package/dist/plugin-sdk/extensions/moonshot/index.d.ts +8 -0
- package/dist/plugin-sdk/extensions/moonshot/media-understanding-provider.d.ts +4 -0
- package/dist/plugin-sdk/extensions/moonshot/onboard.d.ts +7 -0
- package/dist/plugin-sdk/extensions/moonshot/provider-catalog.d.ts +4 -0
- package/dist/plugin-sdk/extensions/moonshot/src/kimi-web-search-provider.d.ts +43 -0
- package/dist/plugin-sdk/extensions/nvidia/provider-catalog.d.ts +2 -0
- package/dist/plugin-sdk/extensions/perplexity/index.d.ts +8 -0
- package/dist/plugin-sdk/extensions/perplexity/src/perplexity-web-search-provider.d.ts +37 -0
- package/dist/plugin-sdk/extensions/qianfan/provider-catalog.d.ts +4 -0
- package/dist/plugin-sdk/extensions/signal/api.d.ts +8 -0
- package/dist/plugin-sdk/extensions/signal/src/accounts.d.ts +17 -0
- package/dist/plugin-sdk/extensions/signal/src/client.d.ts +32 -0
- package/dist/plugin-sdk/extensions/signal/src/daemon.d.ts +26 -0
- package/dist/plugin-sdk/extensions/signal/src/format.d.ts +17 -0
- package/dist/plugin-sdk/extensions/signal/src/identity.d.ts +25 -0
- package/dist/plugin-sdk/extensions/signal/src/message-actions.d.ts +2 -0
- package/dist/plugin-sdk/extensions/signal/src/monitor/access-policy.d.ts +40 -0
- package/dist/plugin-sdk/extensions/signal/src/monitor/event-handler.d.ts +5 -0
- package/dist/plugin-sdk/extensions/signal/src/monitor/event-handler.types.d.ts +126 -0
- package/dist/plugin-sdk/extensions/signal/src/monitor/mentions.d.ts +2 -0
- package/dist/plugin-sdk/extensions/signal/src/monitor.d.ts +27 -0
- package/dist/plugin-sdk/extensions/signal/src/probe.d.ts +7 -0
- package/dist/plugin-sdk/extensions/signal/src/reaction-level.d.ts +17 -0
- package/dist/plugin-sdk/extensions/signal/src/rpc-context.d.ts +9 -0
- package/dist/plugin-sdk/extensions/signal/src/runtime-api.d.ts +1 -0
- package/dist/plugin-sdk/extensions/signal/src/send-reactions.d.ts +34 -0
- package/dist/plugin-sdk/extensions/signal/src/send.d.ts +27 -0
- package/dist/plugin-sdk/extensions/signal/src/sse-reconnect.d.ts +13 -0
- package/dist/plugin-sdk/extensions/slack/api.d.ts +15 -0
- package/dist/plugin-sdk/extensions/slack/runtime-api.d.ts +5 -0
- package/dist/plugin-sdk/extensions/slack/src/account-inspect.d.ts +32 -0
- package/dist/plugin-sdk/extensions/slack/src/account-surface-fields.d.ts +14 -0
- package/dist/plugin-sdk/extensions/slack/src/accounts.d.ts +25 -0
- package/dist/plugin-sdk/extensions/slack/src/action-runtime.d.ts +38 -0
- package/dist/plugin-sdk/extensions/slack/src/actions.d.ts +74 -0
- package/dist/plugin-sdk/extensions/slack/src/blocks-fallback.d.ts +2 -0
- package/dist/plugin-sdk/extensions/slack/src/blocks-input.d.ts +3 -0
- package/dist/plugin-sdk/extensions/slack/src/blocks-render.d.ts +6 -0
- package/dist/plugin-sdk/extensions/slack/src/channel-migration.d.ts +20 -0
- package/dist/plugin-sdk/extensions/slack/src/client.d.ts +4 -0
- package/dist/plugin-sdk/extensions/slack/src/directory-config.d.ts +3 -0
- package/dist/plugin-sdk/extensions/slack/src/directory-live.d.ts +3 -0
- package/dist/plugin-sdk/extensions/slack/src/draft-stream.d.ts +25 -0
- package/dist/plugin-sdk/extensions/slack/src/format.d.ts +8 -0
- package/dist/plugin-sdk/extensions/slack/src/group-policy.d.ts +4 -0
- package/dist/plugin-sdk/extensions/slack/src/http/index.d.ts +1 -0
- package/dist/plugin-sdk/extensions/slack/src/http/registry.d.ts +12 -0
- package/dist/plugin-sdk/extensions/slack/src/index.d.ts +7 -0
- package/dist/plugin-sdk/extensions/slack/src/interactive-replies.d.ts +5 -0
- package/dist/plugin-sdk/extensions/slack/src/message-actions.d.ts +5 -0
- package/dist/plugin-sdk/extensions/slack/src/modal-metadata.d.ts +8 -0
- package/dist/plugin-sdk/extensions/slack/src/monitor/allow-list.d.ts +24 -0
- package/dist/plugin-sdk/extensions/slack/src/monitor/auth.d.ts +29 -0
- package/dist/plugin-sdk/extensions/slack/src/monitor/channel-config.d.ts +45 -0
- package/dist/plugin-sdk/extensions/slack/src/monitor/channel-type.d.ts +3 -0
- package/dist/plugin-sdk/extensions/slack/src/monitor/commands.d.ts +9 -0
- package/dist/plugin-sdk/extensions/slack/src/monitor/context.d.ts +107 -0
- package/dist/plugin-sdk/extensions/slack/src/monitor/dm-auth.d.ts +17 -0
- package/dist/plugin-sdk/extensions/slack/src/monitor/events/channels.d.ts +5 -0
- package/dist/plugin-sdk/extensions/slack/src/monitor/events/interactions.block-actions.d.ts +49 -0
- package/dist/plugin-sdk/extensions/slack/src/monitor/events/interactions.d.ts +4 -0
- package/dist/plugin-sdk/extensions/slack/src/monitor/events/interactions.modal.d.ts +68 -0
- package/dist/plugin-sdk/extensions/slack/src/monitor/events/members.d.ts +5 -0
- package/dist/plugin-sdk/extensions/slack/src/monitor/events/message-subtype-handlers.d.ts +13 -0
- package/dist/plugin-sdk/extensions/slack/src/monitor/events/messages.d.ts +6 -0
- package/dist/plugin-sdk/extensions/slack/src/monitor/events/pins.d.ts +5 -0
- package/dist/plugin-sdk/extensions/slack/src/monitor/events/reactions.d.ts +5 -0
- package/dist/plugin-sdk/extensions/slack/src/monitor/events/system-event-context.d.ts +12 -0
- package/dist/plugin-sdk/extensions/slack/src/monitor/events.d.ts +10 -0
- package/dist/plugin-sdk/extensions/slack/src/monitor/external-arg-menu-store.d.ts +18 -0
- package/dist/plugin-sdk/extensions/slack/src/monitor/media.d.ts +66 -0
- package/dist/plugin-sdk/extensions/slack/src/monitor/message-handler/dispatch.d.ts +12 -0
- package/dist/plugin-sdk/extensions/slack/src/monitor/message-handler/prepare-content.d.ts +14 -0
- package/dist/plugin-sdk/extensions/slack/src/monitor/message-handler/prepare-thread-context.d.ts +24 -0
- package/dist/plugin-sdk/extensions/slack/src/monitor/message-handler/prepare.d.ts +13 -0
- package/dist/plugin-sdk/extensions/slack/src/monitor/message-handler/types.d.ts +23 -0
- package/dist/plugin-sdk/extensions/slack/src/monitor/message-handler.d.ts +22 -0
- package/dist/plugin-sdk/extensions/slack/src/monitor/mrkdwn.d.ts +1 -0
- package/dist/plugin-sdk/extensions/slack/src/monitor/policy.d.ts +5 -0
- package/dist/plugin-sdk/extensions/slack/src/monitor/provider.d.ts +26 -0
- package/dist/plugin-sdk/extensions/slack/src/monitor/reconnect-policy.d.ts +25 -0
- package/dist/plugin-sdk/extensions/slack/src/monitor/replies.d.ts +56 -0
- package/dist/plugin-sdk/extensions/slack/src/monitor/room-context.d.ts +14 -0
- package/dist/plugin-sdk/extensions/slack/src/monitor/slash-commands.runtime.d.ts +11 -0
- package/dist/plugin-sdk/extensions/slack/src/monitor/slash-dispatch.runtime.d.ts +17 -0
- package/dist/plugin-sdk/extensions/slack/src/monitor/slash-skill-commands.runtime.d.ts +3 -0
- package/dist/plugin-sdk/extensions/slack/src/monitor/slash.d.ts +6 -0
- package/dist/plugin-sdk/extensions/slack/src/monitor/thread-resolution.d.ts +12 -0
- package/dist/plugin-sdk/extensions/slack/src/monitor/types.d.ts +113 -0
- package/dist/plugin-sdk/extensions/slack/src/monitor.d.ts +5 -0
- package/dist/plugin-sdk/extensions/slack/src/probe.d.ts +14 -0
- package/dist/plugin-sdk/extensions/slack/src/resolve-allowlist-common.d.ts +29 -0
- package/dist/plugin-sdk/extensions/slack/src/resolve-channels.d.ts +19 -0
- package/dist/plugin-sdk/extensions/slack/src/resolve-users.d.ts +26 -0
- package/dist/plugin-sdk/extensions/slack/src/runtime-api.d.ts +4 -0
- package/dist/plugin-sdk/extensions/slack/src/send.d.ts +24 -0
- package/dist/plugin-sdk/extensions/slack/src/sent-thread-cache.d.ts +3 -0
- package/dist/plugin-sdk/extensions/slack/src/stream-mode.d.ts +23 -0
- package/dist/plugin-sdk/extensions/slack/src/streaming.d.ts +72 -0
- package/dist/plugin-sdk/extensions/slack/src/targets.d.ts +7 -0
- package/dist/plugin-sdk/extensions/slack/src/threading-tool-context.d.ts +10 -0
- package/dist/plugin-sdk/extensions/slack/src/threading.d.ts +29 -0
- package/dist/plugin-sdk/extensions/slack/src/token.d.ts +4 -0
- package/dist/plugin-sdk/extensions/slack/src/truncate.d.ts +1 -0
- package/dist/plugin-sdk/extensions/slack/src/types.d.ts +58 -0
- package/dist/plugin-sdk/extensions/tavily/index.d.ts +8 -0
- package/dist/plugin-sdk/extensions/tavily/src/config.d.ts +14 -0
- package/dist/plugin-sdk/extensions/tavily/src/tavily-client.d.ts +29 -0
- package/dist/plugin-sdk/extensions/tavily/src/tavily-extract-tool.d.ts +14 -0
- package/dist/plugin-sdk/extensions/tavily/src/tavily-search-provider.d.ts +2 -0
- package/dist/plugin-sdk/extensions/tavily/src/tavily-search-tool.d.ts +17 -0
- package/dist/plugin-sdk/extensions/telegram/allow-from.d.ts +1 -0
- package/dist/plugin-sdk/extensions/telegram/api.d.ts +20 -0
- package/dist/plugin-sdk/extensions/telegram/runtime-api.d.ts +14 -0
- package/dist/plugin-sdk/extensions/telegram/src/account-inspect.d.ts +18 -0
- package/dist/plugin-sdk/extensions/telegram/src/accounts.d.ts +31 -0
- package/dist/plugin-sdk/extensions/telegram/src/action-runtime.d.ts +21 -0
- package/dist/plugin-sdk/extensions/telegram/src/allow-from.d.ts +2 -0
- package/dist/plugin-sdk/extensions/telegram/src/allowed-updates.d.ts +4 -0
- package/dist/plugin-sdk/extensions/telegram/src/api-fetch.d.ts +20 -0
- package/dist/plugin-sdk/extensions/telegram/src/api-logging.d.ts +11 -0
- package/dist/plugin-sdk/extensions/telegram/src/approval-buttons.d.ts +2 -0
- package/dist/plugin-sdk/extensions/telegram/src/audit-membership-runtime.d.ts +4 -0
- package/dist/plugin-sdk/extensions/telegram/src/audit.d.ts +33 -0
- package/dist/plugin-sdk/extensions/telegram/src/bot/delivery.d.ts +2 -0
- package/dist/plugin-sdk/extensions/telegram/src/bot/delivery.replies.d.ts +50 -0
- package/dist/plugin-sdk/extensions/telegram/src/bot/delivery.resolve-media.d.ts +8 -0
- package/dist/plugin-sdk/extensions/telegram/src/bot/delivery.send.d.ts +27 -0
- package/dist/plugin-sdk/extensions/telegram/src/bot/helpers.d.ts +147 -0
- package/dist/plugin-sdk/extensions/telegram/src/bot/reply-threading.d.ts +30 -0
- package/dist/plugin-sdk/extensions/telegram/src/bot/types.d.ts +28 -0
- package/dist/plugin-sdk/extensions/telegram/src/bot-access.d.ts +25 -0
- package/dist/plugin-sdk/extensions/telegram/src/bot-deps.d.ts +19 -0
- package/dist/plugin-sdk/extensions/telegram/src/bot-handlers.d.ts +1 -0
- package/dist/plugin-sdk/extensions/telegram/src/bot-handlers.media.d.ts +7 -0
- package/dist/plugin-sdk/extensions/telegram/src/bot-handlers.runtime.d.ts +2 -0
- package/dist/plugin-sdk/extensions/telegram/src/bot-message-context.body.d.ts +39 -0
- package/dist/plugin-sdk/extensions/telegram/src/bot-message-context.d.ts +34 -0
- package/dist/plugin-sdk/extensions/telegram/src/bot-message-context.session.d.ts +41 -0
- package/dist/plugin-sdk/extensions/telegram/src/bot-message-context.types.d.ts +56 -0
- package/dist/plugin-sdk/extensions/telegram/src/bot-message-dispatch.d.ts +31 -0
- package/dist/plugin-sdk/extensions/telegram/src/bot-message.d.ts +20 -0
- package/dist/plugin-sdk/extensions/telegram/src/bot-native-command-menu.d.ts +37 -0
- package/dist/plugin-sdk/extensions/telegram/src/bot-native-commands.d.ts +60 -0
- package/dist/plugin-sdk/extensions/telegram/src/bot-updates.d.ts +31 -0
- package/dist/plugin-sdk/extensions/telegram/src/bot.d.ts +39 -0
- package/dist/plugin-sdk/extensions/telegram/src/bot.runtime.d.ts +4 -0
- package/dist/plugin-sdk/extensions/telegram/src/button-types.d.ts +13 -0
- package/dist/plugin-sdk/extensions/telegram/src/caption.d.ts +5 -0
- package/dist/plugin-sdk/extensions/telegram/src/channel-actions.d.ts +6 -0
- package/dist/plugin-sdk/extensions/telegram/src/conversation-route.d.ts +24 -0
- package/dist/plugin-sdk/extensions/telegram/src/directory-config.d.ts +3 -0
- package/dist/plugin-sdk/extensions/telegram/src/dm-access.d.ts +20 -0
- package/dist/plugin-sdk/extensions/telegram/src/draft-stream.d.ts +48 -0
- package/dist/plugin-sdk/extensions/telegram/src/exec-approvals-handler.d.ts +34 -0
- package/dist/plugin-sdk/extensions/telegram/src/exec-approvals.d.ts +39 -0
- package/dist/plugin-sdk/extensions/telegram/src/fetch.d.ts +23 -0
- package/dist/plugin-sdk/extensions/telegram/src/format.d.ts +19 -0
- package/dist/plugin-sdk/extensions/telegram/src/forum-service-message.d.ts +9 -0
- package/dist/plugin-sdk/extensions/telegram/src/group-access.d.ts +54 -0
- package/dist/plugin-sdk/extensions/telegram/src/group-config-helpers.d.ts +8 -0
- package/dist/plugin-sdk/extensions/telegram/src/group-migration.d.ts +20 -0
- package/dist/plugin-sdk/extensions/telegram/src/group-policy.d.ts +4 -0
- package/dist/plugin-sdk/extensions/telegram/src/inline-buttons.d.ts +11 -0
- package/dist/plugin-sdk/extensions/telegram/src/lane-delivery-state.d.ts +12 -0
- package/dist/plugin-sdk/extensions/telegram/src/lane-delivery-text-deliverer.d.ts +55 -0
- package/dist/plugin-sdk/extensions/telegram/src/lane-delivery.d.ts +2 -0
- package/dist/plugin-sdk/extensions/telegram/src/media-understanding.runtime.d.ts +5 -0
- package/dist/plugin-sdk/extensions/telegram/src/message-tool-schema.d.ts +5 -0
- package/dist/plugin-sdk/extensions/telegram/src/model-buttons.d.ts +84 -0
- package/dist/plugin-sdk/extensions/telegram/src/monitor.d.ts +20 -0
- package/dist/plugin-sdk/extensions/telegram/src/network-config.d.ts +33 -0
- package/dist/plugin-sdk/extensions/telegram/src/network-errors.d.ts +25 -0
- package/dist/plugin-sdk/extensions/telegram/src/normalize.d.ts +2 -0
- package/dist/plugin-sdk/extensions/telegram/src/outbound-adapter.d.ts +14 -0
- package/dist/plugin-sdk/extensions/telegram/src/outbound-params.d.ts +2 -0
- package/dist/plugin-sdk/extensions/telegram/src/polling-session.d.ts +27 -0
- package/dist/plugin-sdk/extensions/telegram/src/probe.d.ts +25 -0
- package/dist/plugin-sdk/extensions/telegram/src/proxy.d.ts +1 -0
- package/dist/plugin-sdk/extensions/telegram/src/reaction-level.d.ts +11 -0
- package/dist/plugin-sdk/extensions/telegram/src/reasoning-lane-coordinator.d.ts +18 -0
- package/dist/plugin-sdk/extensions/telegram/src/send.d.ts +217 -0
- package/dist/plugin-sdk/extensions/telegram/src/sendchataction-401-backoff.d.ts +28 -0
- package/dist/plugin-sdk/extensions/telegram/src/sent-message-cache.d.ts +12 -0
- package/dist/plugin-sdk/extensions/telegram/src/sequential-key.d.ts +25 -0
- package/dist/plugin-sdk/extensions/telegram/src/status-issues.d.ts +2 -0
- package/dist/plugin-sdk/extensions/telegram/src/status-reaction-variants.d.ts +21 -0
- package/dist/plugin-sdk/extensions/telegram/src/sticker-cache.d.ts +46 -0
- package/dist/plugin-sdk/extensions/telegram/src/target-writeback.d.ts +7 -0
- package/dist/plugin-sdk/extensions/telegram/src/targets.d.ts +11 -0
- package/dist/plugin-sdk/extensions/telegram/src/thread-bindings.d.ts +58 -0
- package/dist/plugin-sdk/extensions/telegram/src/token.d.ts +13 -0
- package/dist/plugin-sdk/extensions/telegram/src/update-offset-store.d.ts +15 -0
- package/dist/plugin-sdk/extensions/telegram/src/voice.d.ts +16 -0
- package/dist/plugin-sdk/extensions/telegram/src/webhook.d.ts +21 -0
- package/dist/plugin-sdk/extensions/venice/provider-catalog.d.ts +2 -0
- package/dist/plugin-sdk/extensions/vercel-ai-gateway/provider-catalog.d.ts +2 -0
- package/dist/plugin-sdk/extensions/whatsapp/api.d.ts +7 -0
- package/dist/plugin-sdk/extensions/whatsapp/auth-presence.d.ts +1 -0
- package/dist/plugin-sdk/extensions/whatsapp/light-runtime-api.d.ts +4 -0
- package/dist/plugin-sdk/extensions/whatsapp/login-qr-api.d.ts +1 -0
- package/dist/plugin-sdk/extensions/whatsapp/runtime-api.d.ts +11 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/accounts.d.ts +42 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/action-runtime-target-auth.d.ts +10 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/action-runtime.d.ts +9 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/active-listener.d.ts +25 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/agent-tools-login.d.ts +2 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/auth-store.d.ts +26 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/auto-reply/constants.d.ts +1 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/auto-reply/deliver-reply.d.ts +19 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/auto-reply/heartbeat-runner.d.ts +20 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/auto-reply/loggers.d.ts +4 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/auto-reply/mentions.d.ts +19 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/auto-reply/monitor/ack-reaction.d.ts +13 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/auto-reply/monitor/broadcast.d.ts +16 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/auto-reply/monitor/commands.d.ts +2 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/auto-reply/monitor/echo.d.ts +17 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/auto-reply/monitor/group-activation.d.ts +9 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/auto-reply/monitor/group-gating.d.ts +33 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/auto-reply/monitor/group-members.d.ts +6 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/auto-reply/monitor/last-route.d.ts +15 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/auto-reply/monitor/message-line.d.ts +11 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/auto-reply/monitor/on-message.d.ts +24 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/auto-reply/monitor/peer.d.ts +2 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/auto-reply/monitor/process-message.d.ts +40 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/auto-reply/monitor.d.ts +5 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/auto-reply/session-snapshot.d.ts +17 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/auto-reply/types.d.ts +30 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/auto-reply/util.d.ts +2 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/auto-reply.d.ts +1 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/auto-reply.impl.d.ts +6 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/channel.runtime.d.ts +23 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/directory-config.d.ts +3 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/group-policy.d.ts +14 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/inbound/access-control.d.ts +36 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/inbound/dedupe.d.ts +2 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/inbound/extract.d.ts +13 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/inbound/media.d.ts +7 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/inbound/monitor.d.ts +30 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/inbound/send-api.d.ts +22 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/inbound/types.d.ts +42 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/inbound.d.ts +4 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/login-qr.d.ts +19 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/login.d.ts +3 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/media.d.ts +43 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/normalize.d.ts +1 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/qr-image.d.ts +4 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/reconnect.d.ts +12 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/runtime-api.d.ts +3 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/send.d.ts +27 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/session-errors.d.ts +2 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/session.d.ts +17 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/setup-core.d.ts +2 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/setup-surface.d.ts +2 -0
- package/dist/plugin-sdk/extensions/whatsapp/src/vcard.d.ts +6 -0
- package/dist/plugin-sdk/extensions/xai/index.d.ts +8 -0
- package/dist/plugin-sdk/extensions/xai/model-definitions.d.ts +17 -0
- package/dist/plugin-sdk/extensions/xai/onboard.d.ts +5 -0
- package/dist/plugin-sdk/extensions/xai/provider-catalog.d.ts +2 -0
- package/dist/plugin-sdk/extensions/xai/provider-models.d.ts +6 -0
- package/dist/plugin-sdk/extensions/xai/src/web-search-shared.d.ts +69 -0
- package/dist/plugin-sdk/extensions/xai/stream.d.ts +3 -0
- package/dist/plugin-sdk/extensions/xai/web-search.d.ts +10 -0
- package/dist/plugin-sdk/extensions/xiaomi/provider-catalog.d.ts +3 -0
- package/dist/plugin-sdk/extensions/zalo/api.d.ts +2 -0
- package/dist/plugin-sdk/extensions/zalo/runtime-api.d.ts +1 -0
- package/dist/plugin-sdk/extensions/zalo/src/accounts.d.ts +11 -0
- package/dist/plugin-sdk/extensions/zalo/src/runtime-api.d.ts +1 -0
- package/dist/plugin-sdk/extensions/zalo/src/secret-input.d.ts +1 -0
- package/dist/plugin-sdk/extensions/zalo/src/setup-core.d.ts +1 -0
- package/dist/plugin-sdk/extensions/zalo/src/setup-surface.d.ts +3 -0
- package/dist/plugin-sdk/extensions/zalo/src/token.d.ts +8 -0
- package/dist/plugin-sdk/extensions/zalo/src/types.d.ts +46 -0
- package/dist/plugin-sdk/feishu.d.ts +1 -0
- package/dist/plugin-sdk/feishu.js +101 -0
- package/dist/plugin-sdk/gateway-runtime.d.ts +1 -0
- package/dist/plugin-sdk/gateway-runtime.js +46 -0
- package/dist/plugin-sdk/googlechat.d.ts +1 -0
- package/dist/plugin-sdk/googlechat.js +93 -0
- package/dist/plugin-sdk/group-access.d.ts +1 -0
- package/dist/plugin-sdk/group-access.js +2 -0
- package/dist/plugin-sdk/hook-runtime.d.ts +1 -0
- package/dist/plugin-sdk/hook-runtime.js +12 -0
- package/dist/plugin-sdk/image-generation.d.ts +1 -0
- package/dist/plugin-sdk/image-generation.js +51 -0
- package/dist/plugin-sdk/imessage-core.d.ts +1 -0
- package/dist/plugin-sdk/imessage-core.js +214 -0
- package/dist/plugin-sdk/imessage.d.ts +1 -0
- package/dist/plugin-sdk/imessage.js +223 -0
- package/dist/plugin-sdk/index.d.ts +1 -0
- package/dist/plugin-sdk/index.js +55 -0
- package/dist/plugin-sdk/infra-runtime.d.ts +1 -0
- package/dist/plugin-sdk/infra-runtime.js +223 -0
- package/dist/plugin-sdk/interactive-runtime.d.ts +1 -0
- package/dist/plugin-sdk/interactive-runtime.js +3 -0
- package/dist/plugin-sdk/irc.d.ts +1 -0
- package/dist/plugin-sdk/irc.js +232 -0
- package/dist/plugin-sdk/json-store.d.ts +1 -0
- package/dist/plugin-sdk/json-store.js +9 -0
- package/dist/plugin-sdk/keyed-async-queue.d.ts +1 -0
- package/dist/plugin-sdk/keyed-async-queue.js +2 -0
- package/dist/plugin-sdk/lazy-runtime.d.ts +1 -0
- package/dist/plugin-sdk/lazy-runtime.js +2 -0
- package/dist/plugin-sdk/line-core.d.ts +1 -0
- package/dist/plugin-sdk/line-core.js +29 -0
- package/dist/plugin-sdk/line.d.ts +1 -0
- package/dist/plugin-sdk/line.js +22 -0
- package/dist/plugin-sdk/llm-task.d.ts +1 -0
- package/dist/plugin-sdk/llm-task.js +7 -0
- package/dist/plugin-sdk/matrix-runtime-heavy.d.ts +1 -0
- package/dist/plugin-sdk/matrix-runtime-heavy.js +223 -0
- package/dist/plugin-sdk/matrix-runtime-shared.d.ts +1 -0
- package/dist/plugin-sdk/matrix-runtime-shared.js +2 -0
- package/dist/plugin-sdk/matrix.d.ts +1 -0
- package/dist/plugin-sdk/matrix.js +84 -0
- package/dist/plugin-sdk/mattermost.d.ts +1 -0
- package/dist/plugin-sdk/mattermost.js +233 -0
- package/dist/plugin-sdk/media-runtime.d.ts +1 -0
- package/dist/plugin-sdk/media-runtime.js +212 -0
- package/dist/plugin-sdk/media-understanding-runtime.d.ts +1 -0
- package/dist/plugin-sdk/media-understanding-runtime.js +211 -0
- package/dist/plugin-sdk/media-understanding.d.ts +1 -0
- package/dist/plugin-sdk/media-understanding.js +15 -0
- package/dist/plugin-sdk/memory-core.d.ts +1 -0
- package/dist/plugin-sdk/memory-core.js +2 -0
- package/dist/plugin-sdk/memory-lancedb.d.ts +1 -0
- package/dist/plugin-sdk/memory-lancedb.js +2 -0
- package/dist/plugin-sdk/msteams.d.ts +1 -0
- package/dist/plugin-sdk/msteams.js +244 -0
- package/dist/plugin-sdk/nextcloud-talk.d.ts +1 -0
- package/dist/plugin-sdk/nextcloud-talk.js +231 -0
- package/dist/plugin-sdk/nostr.d.ts +1 -0
- package/dist/plugin-sdk/nostr.js +50 -0
- package/dist/plugin-sdk/ollama-setup.d.ts +1 -0
- package/dist/plugin-sdk/ollama-setup.js +33 -0
- package/dist/plugin-sdk/outbound-runtime.d.ts +1 -0
- package/dist/plugin-sdk/outbound-runtime.js +23 -0
- package/dist/plugin-sdk/plugin-entry.d.ts +1 -0
- package/dist/plugin-sdk/plugin-entry.js +3 -0
- package/dist/plugin-sdk/plugin-runtime.d.ts +1 -0
- package/dist/plugin-sdk/plugin-runtime.js +211 -0
- package/dist/plugin-sdk/process-runtime.d.ts +1 -0
- package/dist/plugin-sdk/process-runtime.js +12 -0
- package/dist/plugin-sdk/provider-auth-api-key.d.ts +1 -0
- package/dist/plugin-sdk/provider-auth-api-key.js +53 -0
- package/dist/plugin-sdk/provider-auth-login.d.ts +1 -0
- package/dist/plugin-sdk/provider-auth-login.js +2 -0
- package/dist/plugin-sdk/provider-auth.d.ts +1 -0
- package/dist/plugin-sdk/provider-auth.js +37 -0
- package/dist/plugin-sdk/provider-catalog.d.ts +1 -0
- package/dist/plugin-sdk/provider-catalog.js +2 -0
- package/dist/plugin-sdk/provider-env-vars.d.ts +1 -0
- package/dist/plugin-sdk/provider-env-vars.js +2 -0
- package/dist/plugin-sdk/provider-google.d.ts +1 -0
- package/dist/plugin-sdk/provider-google.js +3 -0
- package/dist/plugin-sdk/provider-models.d.ts +1 -0
- package/dist/plugin-sdk/provider-models.js +27 -0
- package/dist/plugin-sdk/provider-onboard.d.ts +1 -0
- package/dist/plugin-sdk/provider-onboard.js +20 -0
- package/dist/plugin-sdk/provider-setup.d.ts +1 -0
- package/dist/plugin-sdk/provider-setup.js +58 -0
- package/dist/plugin-sdk/provider-stream.d.ts +1 -0
- package/dist/plugin-sdk/provider-stream.js +211 -0
- package/dist/plugin-sdk/provider-usage.d.ts +1 -0
- package/dist/plugin-sdk/provider-usage.js +18 -0
- package/dist/plugin-sdk/provider-web-search.d.ts +1 -0
- package/dist/plugin-sdk/provider-web-search.js +23 -0
- package/dist/plugin-sdk/provider-zai-endpoint.d.ts +1 -0
- package/dist/plugin-sdk/provider-zai-endpoint.js +3 -0
- package/dist/plugin-sdk/reply-history.d.ts +1 -0
- package/dist/plugin-sdk/reply-history.js +23 -0
- package/dist/plugin-sdk/reply-payload.d.ts +1 -0
- package/dist/plugin-sdk/reply-payload.js +2 -0
- package/dist/plugin-sdk/reply-runtime.d.ts +1 -0
- package/dist/plugin-sdk/reply-runtime.js +211 -0
- package/dist/plugin-sdk/request-url.d.ts +1 -0
- package/dist/plugin-sdk/request-url.js +2 -0
- package/dist/plugin-sdk/root-alias.cjs +272 -0
- package/dist/plugin-sdk/routing.d.ts +1 -0
- package/dist/plugin-sdk/routing.js +25 -0
- package/dist/plugin-sdk/runtime-env.d.ts +1 -0
- package/dist/plugin-sdk/runtime-env.js +15 -0
- package/dist/plugin-sdk/runtime-store.d.ts +1 -0
- package/dist/plugin-sdk/runtime-store.js +2 -0
- package/dist/plugin-sdk/runtime.d.ts +1 -0
- package/dist/plugin-sdk/runtime.js +15 -0
- package/dist/plugin-sdk/sandbox.d.ts +1 -0
- package/dist/plugin-sdk/sandbox.js +66 -0
- package/dist/plugin-sdk/secret-input.d.ts +1 -0
- package/dist/plugin-sdk/secret-input.js +3 -0
- package/dist/plugin-sdk/security-runtime.d.ts +1 -0
- package/dist/plugin-sdk/security-runtime.js +18 -0
- package/dist/plugin-sdk/self-hosted-provider-setup.d.ts +1 -0
- package/dist/plugin-sdk/self-hosted-provider-setup.js +33 -0
- package/dist/plugin-sdk/setup-adapter-runtime.d.ts +1 -0
- package/dist/plugin-sdk/setup-adapter-runtime.js +2 -0
- package/dist/plugin-sdk/setup-runtime.d.ts +1 -0
- package/dist/plugin-sdk/setup-runtime.js +17 -0
- package/dist/plugin-sdk/setup-tools.d.ts +1 -0
- package/dist/plugin-sdk/setup-tools.js +21 -0
- package/dist/plugin-sdk/setup.d.ts +1 -0
- package/dist/plugin-sdk/setup.js +26 -0
- package/dist/plugin-sdk/signal.d.ts +1 -0
- package/dist/plugin-sdk/signal.js +220 -0
- package/dist/plugin-sdk/slack-core.d.ts +1 -0
- package/dist/plugin-sdk/slack-core.js +22 -0
- package/dist/plugin-sdk/slack.d.ts +1 -0
- package/dist/plugin-sdk/slack.js +223 -0
- package/dist/plugin-sdk/speech-runtime.d.ts +1 -0
- package/dist/plugin-sdk/speech-runtime.js +213 -0
- package/dist/plugin-sdk/speech.d.ts +1 -0
- package/dist/plugin-sdk/speech.js +212 -0
- package/dist/plugin-sdk/src/acp/control-plane/manager.core.d.ts +86 -0
- package/dist/plugin-sdk/src/acp/control-plane/manager.d.ts +7 -0
- package/dist/plugin-sdk/src/acp/control-plane/manager.identity-reconcile.d.ts +23 -0
- package/dist/plugin-sdk/src/acp/control-plane/manager.runtime-controls.d.ts +14 -0
- package/dist/plugin-sdk/src/acp/control-plane/manager.types.d.ts +109 -0
- package/dist/plugin-sdk/src/acp/control-plane/manager.utils.d.ts +21 -0
- package/dist/plugin-sdk/src/acp/control-plane/runtime-cache.d.ts +38 -0
- package/dist/plugin-sdk/src/acp/control-plane/runtime-options.d.ts +23 -0
- package/dist/plugin-sdk/src/acp/control-plane/session-actor-queue.d.ts +8 -0
- package/dist/plugin-sdk/src/acp/control-plane/spawn.d.ts +25 -0
- package/dist/plugin-sdk/src/acp/conversation-id.d.ts +15 -0
- package/dist/plugin-sdk/src/acp/persistent-bindings.lifecycle.d.ts +33 -0
- package/dist/plugin-sdk/src/acp/persistent-bindings.resolve.d.ts +18 -0
- package/dist/plugin-sdk/src/acp/persistent-bindings.types.d.ts +39 -0
- package/dist/plugin-sdk/src/acp/policy.d.ts +10 -0
- package/dist/plugin-sdk/src/acp/runtime/error-text.d.ts +7 -0
- package/dist/plugin-sdk/src/acp/runtime/errors.d.ts +20 -0
- package/dist/plugin-sdk/src/acp/runtime/registry.d.ts +18 -0
- package/dist/plugin-sdk/src/acp/runtime/session-identifiers.d.ts +17 -0
- package/dist/plugin-sdk/src/acp/runtime/session-identity.d.ts +24 -0
- package/dist/plugin-sdk/src/acp/runtime/session-meta.d.ts +31 -0
- package/dist/plugin-sdk/src/acp/runtime/types.d.ts +118 -0
- package/dist/plugin-sdk/src/agents/acp-spawn-parent-stream.d.ts +19 -0
- package/dist/plugin-sdk/src/agents/acp-spawn.d.ts +44 -0
- package/dist/plugin-sdk/src/agents/agent-command.d.ts +11 -0
- package/dist/plugin-sdk/src/agents/agent-paths.d.ts +2 -0
- package/dist/plugin-sdk/src/agents/agent-scope.d.ts +66 -0
- package/dist/plugin-sdk/src/agents/announce-idempotency.d.ts +11 -0
- package/dist/plugin-sdk/src/agents/anthropic-payload-log.d.ts +20 -0
- package/dist/plugin-sdk/src/agents/anthropic-vertex-provider.d.ts +9 -0
- package/dist/plugin-sdk/src/agents/anthropic-vertex-stream.d.ts +11 -0
- package/dist/plugin-sdk/src/agents/api-key-rotation.d.ts +22 -0
- package/dist/plugin-sdk/src/agents/apply-patch-update.d.ts +10 -0
- package/dist/plugin-sdk/src/agents/apply-patch.d.ts +35 -0
- package/dist/plugin-sdk/src/agents/auth-health.d.ts +40 -0
- package/dist/plugin-sdk/src/agents/auth-profiles/constants.d.ts +20 -0
- package/dist/plugin-sdk/src/agents/auth-profiles/credential-state.d.ts +11 -0
- package/dist/plugin-sdk/src/agents/auth-profiles/display.d.ts +7 -0
- package/dist/plugin-sdk/src/agents/auth-profiles/doctor.d.ts +8 -0
- package/dist/plugin-sdk/src/agents/auth-profiles/external-cli-sync.d.ts +12 -0
- package/dist/plugin-sdk/src/agents/auth-profiles/oauth.d.ts +14 -0
- package/dist/plugin-sdk/src/agents/auth-profiles/order.d.ts +21 -0
- package/dist/plugin-sdk/src/agents/auth-profiles/paths.d.ts +4 -0
- package/dist/plugin-sdk/src/agents/auth-profiles/profiles.d.ts +24 -0
- package/dist/plugin-sdk/src/agents/auth-profiles/repair.d.ts +14 -0
- package/dist/plugin-sdk/src/agents/auth-profiles/session-override.d.ts +18 -0
- package/dist/plugin-sdk/src/agents/auth-profiles/state-observation.d.ts +10 -0
- package/dist/plugin-sdk/src/agents/auth-profiles/store.d.ts +22 -0
- package/dist/plugin-sdk/src/agents/auth-profiles/types.d.ts +63 -0
- package/dist/plugin-sdk/src/agents/auth-profiles/upsert-with-lock.d.ts +6 -0
- package/dist/plugin-sdk/src/agents/auth-profiles/usage.d.ts +87 -0
- package/dist/plugin-sdk/src/agents/auth-profiles.d.ts +13 -0
- package/dist/plugin-sdk/src/agents/auth-profiles.runtime.d.ts +3 -0
- package/dist/plugin-sdk/src/agents/bash-process-registry.d.ts +70 -0
- package/dist/plugin-sdk/src/agents/bash-tools.d.ts +4 -0
- package/dist/plugin-sdk/src/agents/bash-tools.exec-approval-followup.d.ts +12 -0
- package/dist/plugin-sdk/src/agents/bash-tools.exec-approval-request.d.ts +70 -0
- package/dist/plugin-sdk/src/agents/bash-tools.exec-host-gateway.d.ts +35 -0
- package/dist/plugin-sdk/src/agents/bash-tools.exec-host-node.d.ts +26 -0
- package/dist/plugin-sdk/src/agents/bash-tools.exec-host-shared.d.ts +143 -0
- package/dist/plugin-sdk/src/agents/bash-tools.exec-runtime.d.ts +81 -0
- package/dist/plugin-sdk/src/agents/bash-tools.exec-types.d.ts +68 -0
- package/dist/plugin-sdk/src/agents/bash-tools.exec.d.ts +6 -0
- package/dist/plugin-sdk/src/agents/bash-tools.process.d.ts +7 -0
- package/dist/plugin-sdk/src/agents/bash-tools.shared.d.ts +56 -0
- package/dist/plugin-sdk/src/agents/bedrock-discovery.d.ts +9 -0
- package/dist/plugin-sdk/src/agents/bootstrap-budget.d.ts +87 -0
- package/dist/plugin-sdk/src/agents/bootstrap-cache.d.ts +11 -0
- package/dist/plugin-sdk/src/agents/bootstrap-files.d.ts +32 -0
- package/dist/plugin-sdk/src/agents/bootstrap-hooks.d.ts +10 -0
- package/dist/plugin-sdk/src/agents/btw.d.ts +24 -0
- package/dist/plugin-sdk/src/agents/byteplus-models.d.ts +79 -0
- package/dist/plugin-sdk/src/agents/cache-trace.d.ts +49 -0
- package/dist/plugin-sdk/src/agents/channel-tools.d.ts +43 -0
- package/dist/plugin-sdk/src/agents/chutes-models.d.ts +25 -0
- package/dist/plugin-sdk/src/agents/chutes-oauth.d.ts +46 -0
- package/dist/plugin-sdk/src/agents/cli-backends.d.ts +8 -0
- package/dist/plugin-sdk/src/agents/cli-credentials.d.ts +83 -0
- package/dist/plugin-sdk/src/agents/cli-runner/bundle-mcp.d.ts +14 -0
- package/dist/plugin-sdk/src/agents/cli-runner/helpers.d.ts +70 -0
- package/dist/plugin-sdk/src/agents/cli-runner/reliability.d.ts +11 -0
- package/dist/plugin-sdk/src/agents/cli-runner.d.ts +44 -0
- package/dist/plugin-sdk/src/agents/cli-session.d.ts +3 -0
- package/dist/plugin-sdk/src/agents/cli-watchdog-defaults.d.ts +11 -0
- package/dist/plugin-sdk/src/agents/cloudflare-ai-gateway.d.ts +22 -0
- package/dist/plugin-sdk/src/agents/command/delivery.d.ts +21 -0
- package/dist/plugin-sdk/src/agents/command/run-context.d.ts +2 -0
- package/dist/plugin-sdk/src/agents/command/session-store.d.ts +17 -0
- package/dist/plugin-sdk/src/agents/command/session.d.ts +33 -0
- package/dist/plugin-sdk/src/agents/command/types.d.ts +95 -0
- package/dist/plugin-sdk/src/agents/command-poll-backoff.d.ts +28 -0
- package/dist/plugin-sdk/src/agents/command-poll-backoff.runtime.d.ts +3 -0
- package/dist/plugin-sdk/src/agents/compaction-real-conversation.d.ts +4 -0
- package/dist/plugin-sdk/src/agents/compaction.d.ts +70 -0
- package/dist/plugin-sdk/src/agents/console-sanitize.d.ts +1 -0
- package/dist/plugin-sdk/src/agents/content-blocks.d.ts +1 -0
- package/dist/plugin-sdk/src/agents/context-cache.d.ts +2 -0
- package/dist/plugin-sdk/src/agents/context-window-guard.d.ts +24 -0
- package/dist/plugin-sdk/src/agents/context.d.ts +37 -0
- package/dist/plugin-sdk/src/agents/current-time.d.ts +17 -0
- package/dist/plugin-sdk/src/agents/custom-api-registry.d.ts +4 -0
- package/dist/plugin-sdk/src/agents/date-time.d.ts +13 -0
- package/dist/plugin-sdk/src/agents/defaults.d.ts +3 -0
- package/dist/plugin-sdk/src/agents/docs-path.d.ts +6 -0
- package/dist/plugin-sdk/src/agents/doubao-models.d.ts +100 -0
- package/dist/plugin-sdk/src/agents/embedded-pi-lsp.d.ts +13 -0
- package/dist/plugin-sdk/src/agents/embedded-pi-mcp.d.ts +10 -0
- package/dist/plugin-sdk/src/agents/failover-error.d.ts +33 -0
- package/dist/plugin-sdk/src/agents/fast-mode.d.ts +19 -0
- package/dist/plugin-sdk/src/agents/glob-pattern.d.ts +18 -0
- package/dist/plugin-sdk/src/agents/huggingface-models.d.ts +17 -0
- package/dist/plugin-sdk/src/agents/identity-avatar.d.ts +15 -0
- package/dist/plugin-sdk/src/agents/identity-file.d.ts +12 -0
- package/dist/plugin-sdk/src/agents/identity.d.ts +28 -0
- package/dist/plugin-sdk/src/agents/image-sanitization.d.ts +8 -0
- package/dist/plugin-sdk/src/agents/internal-events.d.ts +16 -0
- package/dist/plugin-sdk/src/agents/kilocode-models.d.ts +7 -0
- package/dist/plugin-sdk/src/agents/lanes.d.ts +4 -0
- package/dist/plugin-sdk/src/agents/live-auth-keys.d.ts +6 -0
- package/dist/plugin-sdk/src/agents/mcp-stdio.d.ts +16 -0
- package/dist/plugin-sdk/src/agents/memory-search.d.ts +79 -0
- package/dist/plugin-sdk/src/agents/minimax-vlm.d.ts +9 -0
- package/dist/plugin-sdk/src/agents/model-alias-lines.d.ts +2 -0
- package/dist/plugin-sdk/src/agents/model-auth-env-vars.d.ts +2 -0
- package/dist/plugin-sdk/src/agents/model-auth-env.d.ts +5 -0
- package/dist/plugin-sdk/src/agents/model-auth-label.d.ts +8 -0
- package/dist/plugin-sdk/src/agents/model-auth-markers.d.ts +20 -0
- package/dist/plugin-sdk/src/agents/model-auth.d.ts +51 -0
- package/dist/plugin-sdk/src/agents/model-catalog.d.ts +30 -0
- package/dist/plugin-sdk/src/agents/model-catalog.runtime.d.ts +1 -0
- package/dist/plugin-sdk/src/agents/model-compat.d.ts +20 -0
- package/dist/plugin-sdk/src/agents/model-fallback-observation.d.ts +22 -0
- package/dist/plugin-sdk/src/agents/model-fallback.d.ts +53 -0
- package/dist/plugin-sdk/src/agents/model-fallback.types.d.ts +13 -0
- package/dist/plugin-sdk/src/agents/model-id-normalization.d.ts +2 -0
- package/dist/plugin-sdk/src/agents/model-ref-profile.d.ts +4 -0
- package/dist/plugin-sdk/src/agents/model-selection.d.ts +125 -0
- package/dist/plugin-sdk/src/agents/model-suppression.d.ts +8 -0
- package/dist/plugin-sdk/src/agents/model-suppression.runtime.d.ts +3 -0
- package/dist/plugin-sdk/src/agents/model-tool-support.d.ts +3 -0
- package/dist/plugin-sdk/src/agents/models-config.d.ts +6 -0
- package/dist/plugin-sdk/src/agents/models-config.merge.d.ts +17 -0
- package/dist/plugin-sdk/src/agents/models-config.plan.d.ts +17 -0
- package/dist/plugin-sdk/src/agents/models-config.providers.d.ts +50 -0
- package/dist/plugin-sdk/src/agents/models-config.providers.discovery.d.ts +19 -0
- package/dist/plugin-sdk/src/agents/models-config.runtime.d.ts +1 -0
- package/dist/plugin-sdk/src/agents/ollama-defaults.d.ts +1 -0
- package/dist/plugin-sdk/src/agents/ollama-models.d.ts +48 -0
- package/dist/plugin-sdk/src/agents/ollama-stream.d.ts +58 -0
- package/dist/plugin-sdk/src/agents/openai-ws-connection.d.ts +323 -0
- package/dist/plugin-sdk/src/agents/openai-ws-stream.d.ts +70 -0
- package/dist/plugin-sdk/src/agents/openclaw-tools.d.ts +63 -0
- package/dist/plugin-sdk/src/agents/openclaw-tools.runtime.d.ts +1 -0
- package/dist/plugin-sdk/src/agents/opencode-zen-models.d.ts +46 -0
- package/dist/plugin-sdk/src/agents/owner-display.d.ts +19 -0
- package/dist/plugin-sdk/src/agents/path-policy.d.ts +10 -0
- package/dist/plugin-sdk/src/agents/payload-redaction.d.ts +5 -0
- package/dist/plugin-sdk/src/agents/pi-auth-credentials.d.ts +16 -0
- package/dist/plugin-sdk/src/agents/pi-bundle-lsp-runtime.d.ts +24 -0
- package/dist/plugin-sdk/src/agents/pi-bundle-mcp-tools.d.ts +12 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-block-chunker.d.ts +19 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-error-observation.d.ts +19 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-helpers/bootstrap.d.ts +33 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-helpers/errors.d.ts +45 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-helpers/failover-matches.d.ts +8 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-helpers/google.d.ts +3 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-helpers/images.d.ts +21 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-helpers/messaging-dedupe.d.ts +10 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-helpers/openai.d.ts +17 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-helpers/thinking.d.ts +5 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-helpers/turns.d.ts +21 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-helpers/types.d.ts +5 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-helpers.d.ts +11 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-messaging.d.ts +9 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-payloads.d.ts +9 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/abort.d.ts +6 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/anthropic-stream-wrappers.d.ts +16 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/cache-ttl.d.ts +9 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/compact.d.ts +75 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/compact.runtime.d.ts +3 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/compaction-runtime-context.d.ts +50 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/compaction-safety-timeout.d.ts +7 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/context-engine-maintenance.d.ts +25 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/extensions.d.ts +12 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/extra-params.d.ts +24 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/google-stream-wrappers.d.ts +8 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/google.d.ts +43 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/history.d.ts +18 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/lanes.d.ts +3 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/logger.d.ts +1 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/message-action-discovery-input.d.ts +24 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/model.d.ts +37 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/model.provider-normalization.d.ts +9 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/moonshot-stream-wrappers.d.ts +19 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/openai-stream-wrappers.d.ts +11 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/openrouter-model-capabilities.d.ts +53 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/proxy-stream-wrappers.d.ts +6 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/run/attempt.d.ts +69 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/run/compaction-retry-aggregate-timeout.d.ts +13 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/run/compaction-timeout.d.ts +29 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/run/failover-observation.d.ts +20 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/run/history-image-prune.d.ts +7 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/run/images.d.ts +83 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/run/params.d.ts +138 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/run/payloads.d.ts +43 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/run/types.d.ts +70 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/run.d.ts +3 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/runs.d.ts +51 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/sandbox-info.d.ts +4 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/session-manager-cache.d.ts +2 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/session-manager-init.d.ts +17 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/session-truncation.d.ts +38 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/skills-runtime.d.ts +10 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/stream-payload-utils.d.ts +2 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/system-prompt.d.ts +55 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/thinking.d.ts +17 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/tool-name-allowlist.d.ts +6 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/tool-result-char-estimator.d.ts +10 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/tool-result-context-guard.d.ts +9 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/tool-result-truncation.d.ts +84 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/tool-split.d.ts +11 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/transcript-rewrite.d.ts +22 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/types.d.ts +89 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/utils.d.ts +5 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/wait-for-idle-before-flush.d.ts +15 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner/zai-stream-wrappers.d.ts +7 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-runner.d.ts +12 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-subscribe.d.ts +34 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-subscribe.handlers.compaction.d.ts +8 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-subscribe.handlers.d.ts +2 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-subscribe.handlers.lifecycle.d.ts +4 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-subscribe.handlers.messages.d.ts +35 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-subscribe.handlers.tools.d.ts +18 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-subscribe.handlers.types.d.ts +154 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-subscribe.raw-stream.d.ts +1 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-subscribe.tools.d.ts +26 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-subscribe.types.d.ts +47 -0
- package/dist/plugin-sdk/src/agents/pi-embedded-utils.d.ts +41 -0
- package/dist/plugin-sdk/src/agents/pi-embedded.d.ts +2 -0
- package/dist/plugin-sdk/src/agents/pi-extensions/compaction-instructions.d.ts +25 -0
- package/dist/plugin-sdk/src/agents/pi-extensions/compaction-safeguard-runtime.d.ts +20 -0
- package/dist/plugin-sdk/src/agents/pi-extensions/compaction-safeguard.d.ts +75 -0
- package/dist/plugin-sdk/src/agents/pi-extensions/context-pruning/extension.d.ts +2 -0
- package/dist/plugin-sdk/src/agents/pi-extensions/context-pruning/pruner.d.ts +10 -0
- package/dist/plugin-sdk/src/agents/pi-extensions/context-pruning/runtime.d.ts +9 -0
- package/dist/plugin-sdk/src/agents/pi-extensions/context-pruning/settings.d.ts +44 -0
- package/dist/plugin-sdk/src/agents/pi-extensions/context-pruning/tools.d.ts +2 -0
- package/dist/plugin-sdk/src/agents/pi-extensions/context-pruning.d.ts +10 -0
- package/dist/plugin-sdk/src/agents/pi-extensions/session-manager-runtime-registry.d.ts +4 -0
- package/dist/plugin-sdk/src/agents/pi-model-discovery-runtime.d.ts +1 -0
- package/dist/plugin-sdk/src/agents/pi-model-discovery.d.ts +7 -0
- package/dist/plugin-sdk/src/agents/pi-project-settings.d.ts +31 -0
- package/dist/plugin-sdk/src/agents/pi-settings.d.ts +45 -0
- package/dist/plugin-sdk/src/agents/pi-tool-definition-adapter.d.ts +8 -0
- package/dist/plugin-sdk/src/agents/pi-tools.abort.d.ts +2 -0
- package/dist/plugin-sdk/src/agents/pi-tools.before-tool-call.d.ts +39 -0
- package/dist/plugin-sdk/src/agents/pi-tools.before-tool-call.runtime.d.ts +10 -0
- package/dist/plugin-sdk/src/agents/pi-tools.d.ts +106 -0
- package/dist/plugin-sdk/src/agents/pi-tools.host-edit.d.ts +8 -0
- package/dist/plugin-sdk/src/agents/pi-tools.params.d.ts +34 -0
- package/dist/plugin-sdk/src/agents/pi-tools.policy.d.ts +38 -0
- package/dist/plugin-sdk/src/agents/pi-tools.read.d.ts +43 -0
- package/dist/plugin-sdk/src/agents/pi-tools.schema.d.ts +12 -0
- package/dist/plugin-sdk/src/agents/pi-tools.types.d.ts +2 -0
- package/dist/plugin-sdk/src/agents/provider-attribution.d.ts +19 -0
- package/dist/plugin-sdk/src/agents/provider-capabilities.d.ts +42 -0
- package/dist/plugin-sdk/src/agents/provider-id.d.ts +5 -0
- package/dist/plugin-sdk/src/agents/pty-dsr.d.ts +5 -0
- package/dist/plugin-sdk/src/agents/pty-keys.d.ts +13 -0
- package/dist/plugin-sdk/src/agents/queued-file-writer.d.ts +5 -0
- package/dist/plugin-sdk/src/agents/runtime-plugins.d.ts +6 -0
- package/dist/plugin-sdk/src/agents/sandbox/backend.d.ts +84 -0
- package/dist/plugin-sdk/src/agents/sandbox/bind-spec.d.ts +7 -0
- package/dist/plugin-sdk/src/agents/sandbox/browser-bridges.d.ts +7 -0
- package/dist/plugin-sdk/src/agents/sandbox/browser.d.ts +12 -0
- package/dist/plugin-sdk/src/agents/sandbox/config-hash.d.ts +18 -0
- package/dist/plugin-sdk/src/agents/sandbox/config.d.ts +33 -0
- package/dist/plugin-sdk/src/agents/sandbox/constants.d.ts +21 -0
- package/dist/plugin-sdk/src/agents/sandbox/context.d.ts +20 -0
- package/dist/plugin-sdk/src/agents/sandbox/docker-backend.d.ts +12 -0
- package/dist/plugin-sdk/src/agents/sandbox/docker.d.ts +59 -0
- package/dist/plugin-sdk/src/agents/sandbox/fs-bridge-mutation-helper.d.ts +24 -0
- package/dist/plugin-sdk/src/agents/sandbox/fs-bridge-path-safety.d.ts +60 -0
- package/dist/plugin-sdk/src/agents/sandbox/fs-bridge-shell-command-plans.d.ts +11 -0
- package/dist/plugin-sdk/src/agents/sandbox/fs-bridge.d.ts +56 -0
- package/dist/plugin-sdk/src/agents/sandbox/fs-paths.d.ts +28 -0
- package/dist/plugin-sdk/src/agents/sandbox/hash.d.ts +1 -0
- package/dist/plugin-sdk/src/agents/sandbox/host-paths.d.ts +9 -0
- package/dist/plugin-sdk/src/agents/sandbox/manage.d.ts +13 -0
- package/dist/plugin-sdk/src/agents/sandbox/network-mode.d.ts +7 -0
- package/dist/plugin-sdk/src/agents/sandbox/novnc-auth.d.ts +24 -0
- package/dist/plugin-sdk/src/agents/sandbox/path-utils.d.ts +2 -0
- package/dist/plugin-sdk/src/agents/sandbox/prune.d.ts +2 -0
- package/dist/plugin-sdk/src/agents/sandbox/registry.d.ts +34 -0
- package/dist/plugin-sdk/src/agents/sandbox/remote-fs-bridge.d.ts +12 -0
- package/dist/plugin-sdk/src/agents/sandbox/runtime-status.d.ts +18 -0
- package/dist/plugin-sdk/src/agents/sandbox/sanitize-env-vars.d.ts +14 -0
- package/dist/plugin-sdk/src/agents/sandbox/shared.d.ts +4 -0
- package/dist/plugin-sdk/src/agents/sandbox/ssh-backend.d.ts +3 -0
- package/dist/plugin-sdk/src/agents/sandbox/ssh.d.ts +52 -0
- package/dist/plugin-sdk/src/agents/sandbox/tool-policy.d.ts +4 -0
- package/dist/plugin-sdk/src/agents/sandbox/types.d.ts +98 -0
- package/dist/plugin-sdk/src/agents/sandbox/types.docker.d.ts +4 -0
- package/dist/plugin-sdk/src/agents/sandbox/validate-sandbox-security.d.ts +68 -0
- package/dist/plugin-sdk/src/agents/sandbox/workspace-mounts.d.ts +8 -0
- package/dist/plugin-sdk/src/agents/sandbox/workspace.d.ts +1 -0
- package/dist/plugin-sdk/src/agents/sandbox-media-paths.d.ts +17 -0
- package/dist/plugin-sdk/src/agents/sandbox-paths.d.ts +24 -0
- package/dist/plugin-sdk/src/agents/sandbox-tool-policy.d.ts +8 -0
- package/dist/plugin-sdk/src/agents/sandbox.d.ts +15 -0
- package/dist/plugin-sdk/src/agents/sanitize-for-prompt.d.ts +21 -0
- package/dist/plugin-sdk/src/agents/schema/clean-for-gemini.d.ts +2 -0
- package/dist/plugin-sdk/src/agents/schema/clean-for-xai.d.ts +2 -0
- package/dist/plugin-sdk/src/agents/schema/typebox.d.ts +14 -0
- package/dist/plugin-sdk/src/agents/self-hosted-provider-defaults.d.ts +8 -0
- package/dist/plugin-sdk/src/agents/session-dirs.d.ts +3 -0
- package/dist/plugin-sdk/src/agents/session-file-repair.d.ts +11 -0
- package/dist/plugin-sdk/src/agents/session-slug.d.ts +1 -0
- package/dist/plugin-sdk/src/agents/session-tool-result-guard-wrapper.d.ts +19 -0
- package/dist/plugin-sdk/src/agents/session-tool-result-guard.d.ts +44 -0
- package/dist/plugin-sdk/src/agents/session-tool-result-state.d.ts +17 -0
- package/dist/plugin-sdk/src/agents/session-transcript-repair.d.ts +33 -0
- package/dist/plugin-sdk/src/agents/session-write-lock.d.ts +53 -0
- package/dist/plugin-sdk/src/agents/sglang-defaults.d.ts +4 -0
- package/dist/plugin-sdk/src/agents/shell-utils.d.ts +9 -0
- package/dist/plugin-sdk/src/agents/simple-completion-transport.d.ts +6 -0
- package/dist/plugin-sdk/src/agents/skills/bundled-dir.d.ts +7 -0
- package/dist/plugin-sdk/src/agents/skills/config.d.ts +13 -0
- package/dist/plugin-sdk/src/agents/skills/env-overrides.d.ts +12 -0
- package/dist/plugin-sdk/src/agents/skills/filter.d.ts +3 -0
- package/dist/plugin-sdk/src/agents/skills/frontmatter.d.ts +6 -0
- package/dist/plugin-sdk/src/agents/skills/plugin-skills.d.ts +5 -0
- package/dist/plugin-sdk/src/agents/skills/refresh.d.ts +19 -0
- package/dist/plugin-sdk/src/agents/skills/serialize.d.ts +1 -0
- package/dist/plugin-sdk/src/agents/skills/types.d.ts +87 -0
- package/dist/plugin-sdk/src/agents/skills/workspace.d.ts +51 -0
- package/dist/plugin-sdk/src/agents/skills.d.ts +7 -0
- package/dist/plugin-sdk/src/agents/spawned-context.d.ts +30 -0
- package/dist/plugin-sdk/src/agents/stable-stringify.d.ts +1 -0
- package/dist/plugin-sdk/src/agents/stream-message-shared.d.ts +35 -0
- package/dist/plugin-sdk/src/agents/subagent-announce-dispatch.d.ts +22 -0
- package/dist/plugin-sdk/src/agents/subagent-announce-queue.d.ts +29 -0
- package/dist/plugin-sdk/src/agents/subagent-announce.d.ts +48 -0
- package/dist/plugin-sdk/src/agents/subagent-attachments.d.ts +39 -0
- package/dist/plugin-sdk/src/agents/subagent-capabilities.d.ts +37 -0
- package/dist/plugin-sdk/src/agents/subagent-control.d.ts +176 -0
- package/dist/plugin-sdk/src/agents/subagent-depth.d.ts +11 -0
- package/dist/plugin-sdk/src/agents/subagent-lifecycle-events.d.ts +18 -0
- package/dist/plugin-sdk/src/agents/subagent-orphan-recovery.d.ts +41 -0
- package/dist/plugin-sdk/src/agents/subagent-registry-cleanup.d.ts +25 -0
- package/dist/plugin-sdk/src/agents/subagent-registry-completion.d.ts +15 -0
- package/dist/plugin-sdk/src/agents/subagent-registry-queries.d.ts +17 -0
- package/dist/plugin-sdk/src/agents/subagent-registry-runtime.d.ts +1 -0
- package/dist/plugin-sdk/src/agents/subagent-registry-state.d.ts +7 -0
- package/dist/plugin-sdk/src/agents/subagent-registry.d.ts +62 -0
- package/dist/plugin-sdk/src/agents/subagent-registry.store.d.ts +5 -0
- package/dist/plugin-sdk/src/agents/subagent-registry.types.d.ts +62 -0
- package/dist/plugin-sdk/src/agents/subagent-spawn.d.ts +71 -0
- package/dist/plugin-sdk/src/agents/synthetic-models.d.ts +160 -0
- package/dist/plugin-sdk/src/agents/system-prompt-params.d.ts +30 -0
- package/dist/plugin-sdk/src/agents/system-prompt-report.d.ts +22 -0
- package/dist/plugin-sdk/src/agents/system-prompt.d.ts +72 -0
- package/dist/plugin-sdk/src/agents/timeout.d.ts +8 -0
- package/dist/plugin-sdk/src/agents/together-models.d.ts +4 -0
- package/dist/plugin-sdk/src/agents/tool-call-id.d.ts +27 -0
- package/dist/plugin-sdk/src/agents/tool-catalog.d.ts +35 -0
- package/dist/plugin-sdk/src/agents/tool-display-common.d.ts +69 -0
- package/dist/plugin-sdk/src/agents/tool-display.d.ts +15 -0
- package/dist/plugin-sdk/src/agents/tool-fs-policy.d.ts +17 -0
- package/dist/plugin-sdk/src/agents/tool-images.d.ts +11 -0
- package/dist/plugin-sdk/src/agents/tool-loop-detection.d.ts +55 -0
- package/dist/plugin-sdk/src/agents/tool-mutation.d.ts +14 -0
- package/dist/plugin-sdk/src/agents/tool-policy-match.d.ts +3 -0
- package/dist/plugin-sdk/src/agents/tool-policy-pipeline.d.ts +27 -0
- package/dist/plugin-sdk/src/agents/tool-policy-shared.d.ts +11 -0
- package/dist/plugin-sdk/src/agents/tool-policy.d.ts +33 -0
- package/dist/plugin-sdk/src/agents/tool-summaries.d.ts +2 -0
- package/dist/plugin-sdk/src/agents/tools/agent-step.d.ts +15 -0
- package/dist/plugin-sdk/src/agents/tools/agents-list-tool.d.ts +6 -0
- package/dist/plugin-sdk/src/agents/tools/browser-tool.actions.d.ts +34 -0
- package/dist/plugin-sdk/src/agents/tools/browser-tool.d.ts +6 -0
- package/dist/plugin-sdk/src/agents/tools/browser-tool.schema.d.ts +75 -0
- package/dist/plugin-sdk/src/agents/tools/canvas-tool.d.ts +5 -0
- package/dist/plugin-sdk/src/agents/tools/common.d.ts +81 -0
- package/dist/plugin-sdk/src/agents/tools/cron-tool.d.ts +11 -0
- package/dist/plugin-sdk/src/agents/tools/gateway-tool.d.ts +6 -0
- package/dist/plugin-sdk/src/agents/tools/gateway.d.ts +15 -0
- package/dist/plugin-sdk/src/agents/tools/image-generate-tool.d.ts +19 -0
- package/dist/plugin-sdk/src/agents/tools/image-tool.d.ts +35 -0
- package/dist/plugin-sdk/src/agents/tools/image-tool.helpers.d.ts +19 -0
- package/dist/plugin-sdk/src/agents/tools/media-tool-shared.d.ts +47 -0
- package/dist/plugin-sdk/src/agents/tools/memory-tool.d.ts +10 -0
- package/dist/plugin-sdk/src/agents/tools/message-tool.d.ts +21 -0
- package/dist/plugin-sdk/src/agents/tools/model-config.helpers.d.ts +21 -0
- package/dist/plugin-sdk/src/agents/tools/nodes-tool.d.ts +13 -0
- package/dist/plugin-sdk/src/agents/tools/nodes-utils.d.ts +14 -0
- package/dist/plugin-sdk/src/agents/tools/pdf-native-providers.d.ts +24 -0
- package/dist/plugin-sdk/src/agents/tools/pdf-tool.d.ts +23 -0
- package/dist/plugin-sdk/src/agents/tools/pdf-tool.helpers.d.ts +27 -0
- package/dist/plugin-sdk/src/agents/tools/session-status-tool.d.ts +7 -0
- package/dist/plugin-sdk/src/agents/tools/sessions-access.d.ts +42 -0
- package/dist/plugin-sdk/src/agents/tools/sessions-announce-target.d.ts +5 -0
- package/dist/plugin-sdk/src/agents/tools/sessions-helpers.d.ts +73 -0
- package/dist/plugin-sdk/src/agents/tools/sessions-history-tool.d.ts +7 -0
- package/dist/plugin-sdk/src/agents/tools/sessions-list-tool.d.ts +7 -0
- package/dist/plugin-sdk/src/agents/tools/sessions-resolution.d.ts +79 -0
- package/dist/plugin-sdk/src/agents/tools/sessions-send-helpers.d.ts +34 -0
- package/dist/plugin-sdk/src/agents/tools/sessions-send-tool.a2a.d.ts +12 -0
- package/dist/plugin-sdk/src/agents/tools/sessions-send-tool.d.ts +9 -0
- package/dist/plugin-sdk/src/agents/tools/sessions-spawn-tool.d.ts +13 -0
- package/dist/plugin-sdk/src/agents/tools/sessions-yield-tool.d.ts +5 -0
- package/dist/plugin-sdk/src/agents/tools/subagents-tool.d.ts +4 -0
- package/dist/plugin-sdk/src/agents/tools/tool-runtime.helpers.d.ts +9 -0
- package/dist/plugin-sdk/src/agents/tools/tts-tool.d.ts +7 -0
- package/dist/plugin-sdk/src/agents/tools/web-fetch-utils.d.ts +25 -0
- package/dist/plugin-sdk/src/agents/tools/web-fetch-visibility.d.ts +2 -0
- package/dist/plugin-sdk/src/agents/tools/web-fetch.d.ts +39 -0
- package/dist/plugin-sdk/src/agents/tools/web-guarded-fetch.d.ts +16 -0
- package/dist/plugin-sdk/src/agents/tools/web-search-citation-redirect.d.ts +5 -0
- package/dist/plugin-sdk/src/agents/tools/web-search-provider-common.d.ts +41 -0
- package/dist/plugin-sdk/src/agents/tools/web-search-provider-config.d.ts +21 -0
- package/dist/plugin-sdk/src/agents/tools/web-search-provider-credentials.d.ts +5 -0
- package/dist/plugin-sdk/src/agents/tools/web-search.d.ts +13 -0
- package/dist/plugin-sdk/src/agents/tools/web-shared.d.ts +24 -0
- package/dist/plugin-sdk/src/agents/tools/web-tools.d.ts +2 -0
- package/dist/plugin-sdk/src/agents/trace-base.d.ts +10 -0
- package/dist/plugin-sdk/src/agents/transcript-policy.d.ts +24 -0
- package/dist/plugin-sdk/src/agents/usage.d.ts +65 -0
- package/dist/plugin-sdk/src/agents/venice-models.d.ts +369 -0
- package/dist/plugin-sdk/src/agents/vercel-ai-gateway.d.ts +15 -0
- package/dist/plugin-sdk/src/agents/vllm-defaults.d.ts +4 -0
- package/dist/plugin-sdk/src/agents/volc-models.shared.d.ts +62 -0
- package/dist/plugin-sdk/src/agents/workspace-dir.d.ts +2 -0
- package/dist/plugin-sdk/src/agents/workspace-dirs.d.ts +2 -0
- package/dist/plugin-sdk/src/agents/workspace-run.d.ts +18 -0
- package/dist/plugin-sdk/src/agents/workspace-templates.d.ts +6 -0
- package/dist/plugin-sdk/src/agents/workspace.d.ts +45 -0
- package/dist/plugin-sdk/src/auto-reply/chunk.d.ts +45 -0
- package/dist/plugin-sdk/src/auto-reply/command-auth.d.ts +17 -0
- package/dist/plugin-sdk/src/auto-reply/command-detection.d.ts +13 -0
- package/dist/plugin-sdk/src/auto-reply/commands-args.d.ts +3 -0
- package/dist/plugin-sdk/src/auto-reply/commands-registry.d.ts +54 -0
- package/dist/plugin-sdk/src/auto-reply/commands-registry.data.d.ts +3 -0
- package/dist/plugin-sdk/src/auto-reply/commands-registry.runtime.d.ts +1 -0
- package/dist/plugin-sdk/src/auto-reply/commands-registry.types.d.ts +67 -0
- package/dist/plugin-sdk/src/auto-reply/commands-text-routing.d.ts +3 -0
- package/dist/plugin-sdk/src/auto-reply/dispatch.d.ts +32 -0
- package/dist/plugin-sdk/src/auto-reply/envelope.d.ts +60 -0
- package/dist/plugin-sdk/src/auto-reply/fallback-state.d.ts +55 -0
- package/dist/plugin-sdk/src/auto-reply/group-activation.d.ts +6 -0
- package/dist/plugin-sdk/src/auto-reply/heartbeat-reply-payload.d.ts +2 -0
- package/dist/plugin-sdk/src/auto-reply/heartbeat.d.ts +26 -0
- package/dist/plugin-sdk/src/auto-reply/inbound-debounce.d.ts +18 -0
- package/dist/plugin-sdk/src/auto-reply/media-note.d.ts +2 -0
- package/dist/plugin-sdk/src/auto-reply/model-runtime.d.ts +17 -0
- package/dist/plugin-sdk/src/auto-reply/model.d.ts +8 -0
- package/dist/plugin-sdk/src/auto-reply/reply/abort-cutoff.d.ts +22 -0
- package/dist/plugin-sdk/src/auto-reply/reply/abort-cutoff.runtime.d.ts +7 -0
- package/dist/plugin-sdk/src/auto-reply/reply/abort-primitives.d.ts +7 -0
- package/dist/plugin-sdk/src/auto-reply/reply/abort.d.ts +26 -0
- package/dist/plugin-sdk/src/auto-reply/reply/acp-projector.d.ts +21 -0
- package/dist/plugin-sdk/src/auto-reply/reply/acp-reset-target.d.ts +12 -0
- package/dist/plugin-sdk/src/auto-reply/reply/acp-stream-settings.d.ts +24 -0
- package/dist/plugin-sdk/src/auto-reply/reply/agent-runner-execution.d.ts +59 -0
- package/dist/plugin-sdk/src/auto-reply/reply/agent-runner-helpers.d.ts +15 -0
- package/dist/plugin-sdk/src/auto-reply/reply/agent-runner-memory.d.ts +30 -0
- package/dist/plugin-sdk/src/auto-reply/reply/agent-runner-payloads.d.ts +28 -0
- package/dist/plugin-sdk/src/auto-reply/reply/agent-runner-reminder-guard.d.ts +13 -0
- package/dist/plugin-sdk/src/auto-reply/reply/agent-runner-utils.d.ts +214 -0
- package/dist/plugin-sdk/src/auto-reply/reply/agent-runner.d.ts +38 -0
- package/dist/plugin-sdk/src/auto-reply/reply/auto-topic-label-config.d.ts +14 -0
- package/dist/plugin-sdk/src/auto-reply/reply/auto-topic-label.d.ts +26 -0
- package/dist/plugin-sdk/src/auto-reply/reply/bash-command.d.ts +19 -0
- package/dist/plugin-sdk/src/auto-reply/reply/block-reply-coalescer.d.ts +15 -0
- package/dist/plugin-sdk/src/auto-reply/reply/block-reply-pipeline.d.ts +32 -0
- package/dist/plugin-sdk/src/auto-reply/reply/block-streaming.d.ts +38 -0
- package/dist/plugin-sdk/src/auto-reply/reply/body.d.ts +10 -0
- package/dist/plugin-sdk/src/auto-reply/reply/btw-command.d.ts +3 -0
- package/dist/plugin-sdk/src/auto-reply/reply/channel-context.d.ts +23 -0
- package/dist/plugin-sdk/src/auto-reply/reply/command-gates.d.ts +24 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-acp/context.d.ts +14 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-acp/diagnostics.d.ts +4 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-acp/install-hints.d.ts +3 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-acp/lifecycle.d.ts +5 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-acp/runtime-options.d.ts +9 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-acp/shared.d.ts +95 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-acp/targets.d.ts +12 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-acp.d.ts +2 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-allowlist.d.ts +2 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-approve.d.ts +2 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-bash.d.ts +2 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-btw.d.ts +2 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-compact.d.ts +2 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-config.d.ts +3 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-context-report.d.ts +3 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-context.d.ts +12 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-core.d.ts +13 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-core.runtime.d.ts +1 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-export-session.d.ts +3 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-info.d.ts +11 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-mcp.d.ts +2 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-models.d.ts +34 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-plugin.d.ts +13 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-plugins.d.ts +2 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-session-abort.d.ts +3 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-session-store.d.ts +13 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-session.d.ts +9 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-setunset-standard.d.ts +10 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-setunset.d.ts +34 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-slash-parse.d.ts +24 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-status.d.ts +27 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-status.runtime.d.ts +1 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-subagents/action-agents.d.ts +3 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-subagents/action-focus.d.ts +3 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-subagents/action-help.d.ts +2 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-subagents/action-info.d.ts +3 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-subagents/action-kill.d.ts +3 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-subagents/action-list.d.ts +3 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-subagents/action-log.d.ts +3 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-subagents/action-send.d.ts +3 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-subagents/action-spawn.d.ts +3 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-subagents/action-unfocus.d.ts +3 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-subagents/shared.d.ts +87 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-subagents.d.ts +4 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-system-prompt.d.ts +14 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-tts.d.ts +2 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands-types.d.ts +70 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands.d.ts +4 -0
- package/dist/plugin-sdk/src/auto-reply/reply/commands.runtime.d.ts +1 -0
- package/dist/plugin-sdk/src/auto-reply/reply/config-commands.d.ts +15 -0
- package/dist/plugin-sdk/src/auto-reply/reply/config-value.d.ts +4 -0
- package/dist/plugin-sdk/src/auto-reply/reply/config-write-authorization.d.ts +11 -0
- package/dist/plugin-sdk/src/auto-reply/reply/debug-commands.d.ts +16 -0
- package/dist/plugin-sdk/src/auto-reply/reply/directive-handling.auth-profile.d.ts +10 -0
- package/dist/plugin-sdk/src/auto-reply/reply/directive-handling.auth.d.ts +11 -0
- package/dist/plugin-sdk/src/auto-reply/reply/directive-handling.d.ts +7 -0
- package/dist/plugin-sdk/src/auto-reply/reply/directive-handling.defaults.d.ts +10 -0
- package/dist/plugin-sdk/src/auto-reply/reply/directive-handling.fast-lane.d.ts +7 -0
- package/dist/plugin-sdk/src/auto-reply/reply/directive-handling.impl.d.ts +3 -0
- package/dist/plugin-sdk/src/auto-reply/reply/directive-handling.levels.d.ts +26 -0
- package/dist/plugin-sdk/src/auto-reply/reply/directive-handling.model-picker.d.ts +13 -0
- package/dist/plugin-sdk/src/auto-reply/reply/directive-handling.model-selection.d.ts +23 -0
- package/dist/plugin-sdk/src/auto-reply/reply/directive-handling.model.d.ts +44 -0
- package/dist/plugin-sdk/src/auto-reply/reply/directive-handling.params.d.ts +52 -0
- package/dist/plugin-sdk/src/auto-reply/reply/directive-handling.parse.d.ts +65 -0
- package/dist/plugin-sdk/src/auto-reply/reply/directive-handling.persist.d.ts +29 -0
- package/dist/plugin-sdk/src/auto-reply/reply/directive-handling.persist.runtime.d.ts +1 -0
- package/dist/plugin-sdk/src/auto-reply/reply/directive-handling.queue-validation.d.ts +10 -0
- package/dist/plugin-sdk/src/auto-reply/reply/directive-handling.shared.d.ts +28 -0
- package/dist/plugin-sdk/src/auto-reply/reply/directive-parsing.d.ts +5 -0
- package/dist/plugin-sdk/src/auto-reply/reply/directives.d.ts +44 -0
- package/dist/plugin-sdk/src/auto-reply/reply/discord-parent-channel.d.ts +1 -0
- package/dist/plugin-sdk/src/auto-reply/reply/dispatch-acp-delivery.d.ts +29 -0
- package/dist/plugin-sdk/src/auto-reply/reply/dispatch-acp.d.ts +32 -0
- package/dist/plugin-sdk/src/auto-reply/reply/dispatch-from-config.d.ts +16 -0
- package/dist/plugin-sdk/src/auto-reply/reply/dispatcher-registry.d.ts +24 -0
- package/dist/plugin-sdk/src/auto-reply/reply/elevated-allowlist-matcher.d.ts +20 -0
- package/dist/plugin-sdk/src/auto-reply/reply/elevated-unavailable.d.ts +8 -0
- package/dist/plugin-sdk/src/auto-reply/reply/exec/directive.d.ts +20 -0
- package/dist/plugin-sdk/src/auto-reply/reply/exec.d.ts +1 -0
- package/dist/plugin-sdk/src/auto-reply/reply/followup-runner.d.ts +16 -0
- package/dist/plugin-sdk/src/auto-reply/reply/get-reply-directives-apply.d.ts +67 -0
- package/dist/plugin-sdk/src/auto-reply/reply/get-reply-directives-utils.d.ts +3 -0
- package/dist/plugin-sdk/src/auto-reply/reply/get-reply-directives.d.ts +93 -0
- package/dist/plugin-sdk/src/auto-reply/reply/get-reply-inline-actions.d.ts +62 -0
- package/dist/plugin-sdk/src/auto-reply/reply/get-reply-run.d.ts +69 -0
- package/dist/plugin-sdk/src/auto-reply/reply/get-reply.d.ts +7 -0
- package/dist/plugin-sdk/src/auto-reply/reply/groups.d.ts +26 -0
- package/dist/plugin-sdk/src/auto-reply/reply/history.d.ts +72 -0
- package/dist/plugin-sdk/src/auto-reply/reply/inbound-context.d.ts +8 -0
- package/dist/plugin-sdk/src/auto-reply/reply/inbound-dedupe.d.ts +8 -0
- package/dist/plugin-sdk/src/auto-reply/reply/inbound-meta.d.ts +4 -0
- package/dist/plugin-sdk/src/auto-reply/reply/inbound-text.d.ts +5 -0
- package/dist/plugin-sdk/src/auto-reply/reply/line-directives.d.ts +22 -0
- package/dist/plugin-sdk/src/auto-reply/reply/matrix-context.d.ts +13 -0
- package/dist/plugin-sdk/src/auto-reply/reply/mcp-commands.d.ts +15 -0
- package/dist/plugin-sdk/src/auto-reply/reply/memory-flush.d.ts +63 -0
- package/dist/plugin-sdk/src/auto-reply/reply/mentions.d.ts +19 -0
- package/dist/plugin-sdk/src/auto-reply/reply/message-preprocess-hooks.d.ts +7 -0
- package/dist/plugin-sdk/src/auto-reply/reply/model-selection.d.ts +67 -0
- package/dist/plugin-sdk/src/auto-reply/reply/normalize-reply.d.ts +14 -0
- package/dist/plugin-sdk/src/auto-reply/reply/origin-routing.d.ts +13 -0
- package/dist/plugin-sdk/src/auto-reply/reply/plugins-commands.d.ts +16 -0
- package/dist/plugin-sdk/src/auto-reply/reply/post-compaction-context.d.ts +15 -0
- package/dist/plugin-sdk/src/auto-reply/reply/provider-dispatcher.d.ts +19 -0
- package/dist/plugin-sdk/src/auto-reply/reply/queue/cleanup.d.ts +6 -0
- package/dist/plugin-sdk/src/auto-reply/reply/queue/directive.d.ts +15 -0
- package/dist/plugin-sdk/src/auto-reply/reply/queue/drain.d.ts +5 -0
- package/dist/plugin-sdk/src/auto-reply/reply/queue/enqueue.d.ts +4 -0
- package/dist/plugin-sdk/src/auto-reply/reply/queue/normalize.d.ts +3 -0
- package/dist/plugin-sdk/src/auto-reply/reply/queue/settings.d.ts +2 -0
- package/dist/plugin-sdk/src/auto-reply/reply/queue/state.d.ts +20 -0
- package/dist/plugin-sdk/src/auto-reply/reply/queue/types.d.ts +87 -0
- package/dist/plugin-sdk/src/auto-reply/reply/queue-policy.d.ts +8 -0
- package/dist/plugin-sdk/src/auto-reply/reply/queue.d.ts +8 -0
- package/dist/plugin-sdk/src/auto-reply/reply/reply-delivery.d.ts +28 -0
- package/dist/plugin-sdk/src/auto-reply/reply/reply-directives.d.ts +14 -0
- package/dist/plugin-sdk/src/auto-reply/reply/reply-dispatcher.d.ts +57 -0
- package/dist/plugin-sdk/src/auto-reply/reply/reply-elevated.d.ts +16 -0
- package/dist/plugin-sdk/src/auto-reply/reply/reply-inline-whitespace.d.ts +1 -0
- package/dist/plugin-sdk/src/auto-reply/reply/reply-inline.d.ts +8 -0
- package/dist/plugin-sdk/src/auto-reply/reply/reply-media-paths.d.ts +7 -0
- package/dist/plugin-sdk/src/auto-reply/reply/reply-payloads.d.ts +28 -0
- package/dist/plugin-sdk/src/auto-reply/reply/reply-reference.d.ts +20 -0
- package/dist/plugin-sdk/src/auto-reply/reply/reply-tags.d.ts +6 -0
- package/dist/plugin-sdk/src/auto-reply/reply/reply-threading.d.ts +9 -0
- package/dist/plugin-sdk/src/auto-reply/reply/response-prefix-template.d.ts +51 -0
- package/dist/plugin-sdk/src/auto-reply/reply/route-reply.d.ts +60 -0
- package/dist/plugin-sdk/src/auto-reply/reply/session-delivery.d.ts +30 -0
- package/dist/plugin-sdk/src/auto-reply/reply/session-fork.d.ts +11 -0
- package/dist/plugin-sdk/src/auto-reply/reply/session-fork.runtime.d.ts +9 -0
- package/dist/plugin-sdk/src/auto-reply/reply/session-hooks.d.ts +32 -0
- package/dist/plugin-sdk/src/auto-reply/reply/session-reset-model.d.ts +25 -0
- package/dist/plugin-sdk/src/auto-reply/reply/session-reset-prompt.d.ts +9 -0
- package/dist/plugin-sdk/src/auto-reply/reply/session-run-accounting.d.ts +12 -0
- package/dist/plugin-sdk/src/auto-reply/reply/session-updates.d.ts +35 -0
- package/dist/plugin-sdk/src/auto-reply/reply/session-usage.d.ts +23 -0
- package/dist/plugin-sdk/src/auto-reply/reply/session.d.ts +26 -0
- package/dist/plugin-sdk/src/auto-reply/reply/slack-directives.d.ts +3 -0
- package/dist/plugin-sdk/src/auto-reply/reply/stage-sandbox-media.d.ts +9 -0
- package/dist/plugin-sdk/src/auto-reply/reply/streaming-directives.d.ts +10 -0
- package/dist/plugin-sdk/src/auto-reply/reply/strip-inbound-meta.d.ts +31 -0
- package/dist/plugin-sdk/src/auto-reply/reply/subagents-utils.d.ts +27 -0
- package/dist/plugin-sdk/src/auto-reply/reply/telegram-context.d.ts +12 -0
- package/dist/plugin-sdk/src/auto-reply/reply/typing-mode.d.ts +30 -0
- package/dist/plugin-sdk/src/auto-reply/reply/typing-policy.d.ts +13 -0
- package/dist/plugin-sdk/src/auto-reply/reply/typing.d.ts +18 -0
- package/dist/plugin-sdk/src/auto-reply/reply/untrusted-context.d.ts +1 -0
- package/dist/plugin-sdk/src/auto-reply/reply.d.ts +6 -0
- package/dist/plugin-sdk/src/auto-reply/send-policy.d.ts +6 -0
- package/dist/plugin-sdk/src/auto-reply/skill-commands-base.d.ts +9 -0
- package/dist/plugin-sdk/src/auto-reply/skill-commands.d.ts +16 -0
- package/dist/plugin-sdk/src/auto-reply/skill-commands.runtime.d.ts +1 -0
- package/dist/plugin-sdk/src/auto-reply/status.d.ts +61 -0
- package/dist/plugin-sdk/src/auto-reply/templating.d.ts +190 -0
- package/dist/plugin-sdk/src/auto-reply/thinking.d.ts +13 -0
- package/dist/plugin-sdk/src/auto-reply/thinking.shared.d.ts +33 -0
- package/dist/plugin-sdk/src/auto-reply/tokens.d.ts +10 -0
- package/dist/plugin-sdk/src/auto-reply/tool-meta.d.ts +8 -0
- package/dist/plugin-sdk/src/auto-reply/types.d.ts +95 -0
- package/dist/plugin-sdk/src/bindings/records.d.ts +10 -0
- package/dist/plugin-sdk/src/browser/bridge-auth-registry.d.ts +8 -0
- package/dist/plugin-sdk/src/browser/bridge-server.d.ts +24 -0
- package/dist/plugin-sdk/src/browser/cdp-proxy-bypass.d.ts +31 -0
- package/dist/plugin-sdk/src/browser/cdp-timeouts.d.ts +26 -0
- package/dist/plugin-sdk/src/browser/cdp.d.ts +125 -0
- package/dist/plugin-sdk/src/browser/cdp.helpers.d.ts +29 -0
- package/dist/plugin-sdk/src/browser/chrome-mcp.d.ts +127 -0
- package/dist/plugin-sdk/src/browser/chrome-mcp.snapshot.d.ts +26 -0
- package/dist/plugin-sdk/src/browser/chrome.d.ts +21 -0
- package/dist/plugin-sdk/src/browser/chrome.executables.d.ts +15 -0
- package/dist/plugin-sdk/src/browser/chrome.profile-decoration.d.ts +10 -0
- package/dist/plugin-sdk/src/browser/client-actions-core.d.ts +159 -0
- package/dist/plugin-sdk/src/browser/client-actions-observe.d.ts +68 -0
- package/dist/plugin-sdk/src/browser/client-actions-state.d.ts +93 -0
- package/dist/plugin-sdk/src/browser/client-actions-types.d.ts +18 -0
- package/dist/plugin-sdk/src/browser/client-actions-url.d.ts +2 -0
- package/dist/plugin-sdk/src/browser/client-actions.d.ts +4 -0
- package/dist/plugin-sdk/src/browser/client-fetch.d.ts +21 -0
- package/dist/plugin-sdk/src/browser/client.d.ts +157 -0
- package/dist/plugin-sdk/src/browser/config.d.ts +46 -0
- package/dist/plugin-sdk/src/browser/constants.d.ts +8 -0
- package/dist/plugin-sdk/src/browser/control-auth.d.ts +13 -0
- package/dist/plugin-sdk/src/browser/control-service.d.ts +5 -0
- package/dist/plugin-sdk/src/browser/csrf.d.ts +8 -0
- package/dist/plugin-sdk/src/browser/errors.d.ts +35 -0
- package/dist/plugin-sdk/src/browser/form-fields.d.ts +8 -0
- package/dist/plugin-sdk/src/browser/http-auth.d.ts +5 -0
- package/dist/plugin-sdk/src/browser/navigation-guard.d.ts +30 -0
- package/dist/plugin-sdk/src/browser/output-atomic.d.ts +5 -0
- package/dist/plugin-sdk/src/browser/paths.d.ts +61 -0
- package/dist/plugin-sdk/src/browser/profile-capabilities.d.ts +30 -0
- package/dist/plugin-sdk/src/browser/profiles-service.d.ts +28 -0
- package/dist/plugin-sdk/src/browser/profiles.d.ts +30 -0
- package/dist/plugin-sdk/src/browser/proxy-files.d.ts +7 -0
- package/dist/plugin-sdk/src/browser/pw-ai-module.d.ts +6 -0
- package/dist/plugin-sdk/src/browser/pw-ai-state.d.ts +2 -0
- package/dist/plugin-sdk/src/browser/pw-ai.d.ts +2 -0
- package/dist/plugin-sdk/src/browser/pw-role-snapshot.d.ts +35 -0
- package/dist/plugin-sdk/src/browser/pw-session.d.ts +164 -0
- package/dist/plugin-sdk/src/browser/pw-session.page-cdp.d.ts +9 -0
- package/dist/plugin-sdk/src/browser/pw-tools-core.activity.d.ts +21 -0
- package/dist/plugin-sdk/src/browser/pw-tools-core.d.ts +8 -0
- package/dist/plugin-sdk/src/browser/pw-tools-core.downloads.d.ts +34 -0
- package/dist/plugin-sdk/src/browser/pw-tools-core.interactions.d.ts +135 -0
- package/dist/plugin-sdk/src/browser/pw-tools-core.responses.d.ts +13 -0
- package/dist/plugin-sdk/src/browser/pw-tools-core.shared.d.ts +10 -0
- package/dist/plugin-sdk/src/browser/pw-tools-core.snapshot.d.ts +66 -0
- package/dist/plugin-sdk/src/browser/pw-tools-core.state.d.ts +46 -0
- package/dist/plugin-sdk/src/browser/pw-tools-core.storage.d.ts +47 -0
- package/dist/plugin-sdk/src/browser/pw-tools-core.trace.d.ts +12 -0
- package/dist/plugin-sdk/src/browser/resolved-config-refresh.d.ts +12 -0
- package/dist/plugin-sdk/src/browser/routes/agent.act.d.ts +3 -0
- package/dist/plugin-sdk/src/browser/routes/agent.act.download.d.ts +3 -0
- package/dist/plugin-sdk/src/browser/routes/agent.act.hooks.d.ts +3 -0
- package/dist/plugin-sdk/src/browser/routes/agent.act.shared.d.ts +10 -0
- package/dist/plugin-sdk/src/browser/routes/agent.d.ts +3 -0
- package/dist/plugin-sdk/src/browser/routes/agent.debug.d.ts +3 -0
- package/dist/plugin-sdk/src/browser/routes/agent.shared.d.ts +37 -0
- package/dist/plugin-sdk/src/browser/routes/agent.snapshot.d.ts +12 -0
- package/dist/plugin-sdk/src/browser/routes/agent.snapshot.plan.d.ts +22 -0
- package/dist/plugin-sdk/src/browser/routes/agent.storage.d.ts +14 -0
- package/dist/plugin-sdk/src/browser/routes/basic.d.ts +3 -0
- package/dist/plugin-sdk/src/browser/routes/dispatcher.d.ts +16 -0
- package/dist/plugin-sdk/src/browser/routes/index.d.ts +3 -0
- package/dist/plugin-sdk/src/browser/routes/output-paths.d.ts +10 -0
- package/dist/plugin-sdk/src/browser/routes/path-output.d.ts +1 -0
- package/dist/plugin-sdk/src/browser/routes/tabs.d.ts +3 -0
- package/dist/plugin-sdk/src/browser/routes/types.d.ts +20 -0
- package/dist/plugin-sdk/src/browser/routes/utils.d.ts +15 -0
- package/dist/plugin-sdk/src/browser/runtime-lifecycle.d.ts +15 -0
- package/dist/plugin-sdk/src/browser/safe-filename.d.ts +1 -0
- package/dist/plugin-sdk/src/browser/screenshot.d.ts +9 -0
- package/dist/plugin-sdk/src/browser/server-context.availability.d.ts +19 -0
- package/dist/plugin-sdk/src/browser/server-context.constants.d.ts +7 -0
- package/dist/plugin-sdk/src/browser/server-context.d.ts +4 -0
- package/dist/plugin-sdk/src/browser/server-context.reset.d.ts +20 -0
- package/dist/plugin-sdk/src/browser/server-context.selection.d.ts +16 -0
- package/dist/plugin-sdk/src/browser/server-context.tab-ops.d.ts +13 -0
- package/dist/plugin-sdk/src/browser/server-context.types.d.ts +74 -0
- package/dist/plugin-sdk/src/browser/server-lifecycle.d.ts +10 -0
- package/dist/plugin-sdk/src/browser/server-middleware.d.ts +6 -0
- package/dist/plugin-sdk/src/browser/session-tab-registry.d.ts +30 -0
- package/dist/plugin-sdk/src/browser/snapshot-roles.d.ts +11 -0
- package/dist/plugin-sdk/src/browser/target-id.d.ts +11 -0
- package/dist/plugin-sdk/src/browser/trash.d.ts +1 -0
- package/dist/plugin-sdk/src/browser/url-pattern.d.ts +1 -0
- package/dist/plugin-sdk/src/bundled-web-search-registry.d.ts +10 -0
- package/dist/plugin-sdk/src/channel-web.d.ts +5 -0
- package/dist/plugin-sdk/src/channels/account-snapshot-fields.d.ts +10 -0
- package/dist/plugin-sdk/src/channels/account-summary.d.ts +28 -0
- package/dist/plugin-sdk/src/channels/ack-reactions.d.ts +29 -0
- package/dist/plugin-sdk/src/channels/allow-from.d.ts +16 -0
- package/dist/plugin-sdk/src/channels/allowlist-match.d.ts +42 -0
- package/dist/plugin-sdk/src/channels/allowlists/resolve-utils.d.ts +34 -0
- package/dist/plugin-sdk/src/channels/channel-config.d.ts +39 -0
- package/dist/plugin-sdk/src/channels/chat-type.d.ts +2 -0
- package/dist/plugin-sdk/src/channels/command-gating.d.ts +32 -0
- package/dist/plugin-sdk/src/channels/config-presence.d.ts +4 -0
- package/dist/plugin-sdk/src/channels/conversation-label.d.ts +2 -0
- package/dist/plugin-sdk/src/channels/draft-stream-controls.d.ts +54 -0
- package/dist/plugin-sdk/src/channels/draft-stream-loop.d.ts +13 -0
- package/dist/plugin-sdk/src/channels/ids.d.ts +3 -0
- package/dist/plugin-sdk/src/channels/inbound-debounce-policy.d.ts +18 -0
- package/dist/plugin-sdk/src/channels/location.d.ts +21 -0
- package/dist/plugin-sdk/src/channels/logging.d.ts +20 -0
- package/dist/plugin-sdk/src/channels/mention-gating.d.ts +27 -0
- package/dist/plugin-sdk/src/channels/model-overrides.d.ts +18 -0
- package/dist/plugin-sdk/src/channels/native-command-session-targets.d.ts +12 -0
- package/dist/plugin-sdk/src/channels/plugins/account-action-gate.d.ts +5 -0
- package/dist/plugin-sdk/src/channels/plugins/account-helpers.d.ts +8 -0
- package/dist/plugin-sdk/src/channels/plugins/acp-configured-binding-consumer.d.ts +2 -0
- package/dist/plugin-sdk/src/channels/plugins/acp-stateful-target-driver.d.ts +2 -0
- package/dist/plugin-sdk/src/channels/plugins/actions/reaction-message-id.d.ts +8 -0
- package/dist/plugin-sdk/src/channels/plugins/actions/shared.d.ts +7 -0
- package/dist/plugin-sdk/src/channels/plugins/allowlist-match.d.ts +2 -0
- package/dist/plugin-sdk/src/channels/plugins/binding-provider.d.ts +5 -0
- package/dist/plugin-sdk/src/channels/plugins/binding-registry.d.ts +6 -0
- package/dist/plugin-sdk/src/channels/plugins/binding-routing.d.ts +32 -0
- package/dist/plugin-sdk/src/channels/plugins/binding-targets.d.ts +33 -0
- package/dist/plugin-sdk/src/channels/plugins/binding-types.d.ts +40 -0
- package/dist/plugin-sdk/src/channels/plugins/bluebubbles-actions.d.ts +48 -0
- package/dist/plugin-sdk/src/channels/plugins/channel-config.d.ts +2 -0
- package/dist/plugin-sdk/src/channels/plugins/config-helpers.d.ts +25 -0
- package/dist/plugin-sdk/src/channels/plugins/config-schema.d.ts +20 -0
- package/dist/plugin-sdk/src/channels/plugins/config-writes.d.ts +56 -0
- package/dist/plugin-sdk/src/channels/plugins/configured-binding-builtins.d.ts +2 -0
- package/dist/plugin-sdk/src/channels/plugins/configured-binding-compiler.d.ts +11 -0
- package/dist/plugin-sdk/src/channels/plugins/configured-binding-consumers.d.ts +32 -0
- package/dist/plugin-sdk/src/channels/plugins/configured-binding-match.d.ts +23 -0
- package/dist/plugin-sdk/src/channels/plugins/configured-binding-registry.d.ts +28 -0
- package/dist/plugin-sdk/src/channels/plugins/configured-binding-session-lookup.d.ts +6 -0
- package/dist/plugin-sdk/src/channels/plugins/directory-adapters.d.ts +9 -0
- package/dist/plugin-sdk/src/channels/plugins/directory-config-helpers.d.ts +69 -0
- package/dist/plugin-sdk/src/channels/plugins/directory-types.d.ts +7 -0
- package/dist/plugin-sdk/src/channels/plugins/exec-approval-local.d.ts +8 -0
- package/dist/plugin-sdk/src/channels/plugins/group-policy-warnings.d.ts +126 -0
- package/dist/plugin-sdk/src/channels/plugins/helpers.d.ts +24 -0
- package/dist/plugin-sdk/src/channels/plugins/index.d.ts +4 -0
- package/dist/plugin-sdk/src/channels/plugins/media-limits.d.ts +9 -0
- package/dist/plugin-sdk/src/channels/plugins/media-payload.d.ts +15 -0
- package/dist/plugin-sdk/src/channels/plugins/message-action-discovery.d.ts +77 -0
- package/dist/plugin-sdk/src/channels/plugins/message-action-dispatch.d.ts +3 -0
- package/dist/plugin-sdk/src/channels/plugins/message-action-names.d.ts +2 -0
- package/dist/plugin-sdk/src/channels/plugins/message-capabilities.d.ts +2 -0
- package/dist/plugin-sdk/src/channels/plugins/normalize/imessage.d.ts +2 -0
- package/dist/plugin-sdk/src/channels/plugins/normalize/shared.d.ts +6 -0
- package/dist/plugin-sdk/src/channels/plugins/normalize/signal.d.ts +2 -0
- package/dist/plugin-sdk/src/channels/plugins/normalize/slack.d.ts +2 -0
- package/dist/plugin-sdk/src/channels/plugins/normalize/whatsapp.d.ts +3 -0
- package/dist/plugin-sdk/src/channels/plugins/outbound/direct-text-media.d.ts +39 -0
- package/dist/plugin-sdk/src/channels/plugins/outbound/interactive.d.ts +2 -0
- package/dist/plugin-sdk/src/channels/plugins/outbound/load.d.ts +2 -0
- package/dist/plugin-sdk/src/channels/plugins/pairing-adapters.d.ts +13 -0
- package/dist/plugin-sdk/src/channels/plugins/pairing-message.d.ts +1 -0
- package/dist/plugin-sdk/src/channels/plugins/pairing.d.ts +16 -0
- package/dist/plugin-sdk/src/channels/plugins/registry-loader.d.ts +5 -0
- package/dist/plugin-sdk/src/channels/plugins/registry.d.ts +4 -0
- package/dist/plugin-sdk/src/channels/plugins/runtime-forwarders.d.ts +26 -0
- package/dist/plugin-sdk/src/channels/plugins/setup-group-access-configure.d.ts +22 -0
- package/dist/plugin-sdk/src/channels/plugins/setup-group-access.d.ts +32 -0
- package/dist/plugin-sdk/src/channels/plugins/setup-helpers.d.ts +81 -0
- package/dist/plugin-sdk/src/channels/plugins/setup-wizard-binary.d.ts +34 -0
- package/dist/plugin-sdk/src/channels/plugins/setup-wizard-helpers.d.ts +441 -0
- package/dist/plugin-sdk/src/channels/plugins/setup-wizard-proxy.d.ts +48 -0
- package/dist/plugin-sdk/src/channels/plugins/setup-wizard-types.d.ts +107 -0
- package/dist/plugin-sdk/src/channels/plugins/setup-wizard.d.ts +267 -0
- package/dist/plugin-sdk/src/channels/plugins/stateful-target-builtins.d.ts +2 -0
- package/dist/plugin-sdk/src/channels/plugins/stateful-target-drivers.d.ts +54 -0
- package/dist/plugin-sdk/src/channels/plugins/status-issues/bluebubbles.d.ts +2 -0
- package/dist/plugin-sdk/src/channels/plugins/status-issues/shared.d.ts +29 -0
- package/dist/plugin-sdk/src/channels/plugins/target-parsing.d.ts +7 -0
- package/dist/plugin-sdk/src/channels/plugins/target-resolvers.d.ts +12 -0
- package/dist/plugin-sdk/src/channels/plugins/threading-helpers.d.ts +12 -0
- package/dist/plugin-sdk/src/channels/plugins/types.adapters.d.ts +557 -0
- package/dist/plugin-sdk/src/channels/plugins/types.core.d.ts +522 -0
- package/dist/plugin-sdk/src/channels/plugins/types.d.ts +8 -0
- package/dist/plugin-sdk/src/channels/plugins/types.plugin.d.ts +58 -0
- package/dist/plugin-sdk/src/channels/plugins/whatsapp-heartbeat.d.ts +11 -0
- package/dist/plugin-sdk/src/channels/plugins/whatsapp-shared.d.ts +21 -0
- package/dist/plugin-sdk/src/channels/read-only-account-inspect.d.ts +12 -0
- package/dist/plugin-sdk/src/channels/read-only-account-inspect.discord.runtime.d.ts +3 -0
- package/dist/plugin-sdk/src/channels/read-only-account-inspect.slack.runtime.d.ts +3 -0
- package/dist/plugin-sdk/src/channels/read-only-account-inspect.telegram.runtime.d.ts +3 -0
- package/dist/plugin-sdk/src/channels/registry.d.ts +15 -0
- package/dist/plugin-sdk/src/channels/reply-prefix.d.ts +25 -0
- package/dist/plugin-sdk/src/channels/run-state-machine.d.ts +19 -0
- package/dist/plugin-sdk/src/channels/sender-label.d.ts +9 -0
- package/dist/plugin-sdk/src/channels/session-envelope.d.ts +10 -0
- package/dist/plugin-sdk/src/channels/session-meta.d.ts +9 -0
- package/dist/plugin-sdk/src/channels/session.d.ts +26 -0
- package/dist/plugin-sdk/src/channels/status-reactions.d.ts +66 -0
- package/dist/plugin-sdk/src/channels/targets.d.ts +57 -0
- package/dist/plugin-sdk/src/channels/thread-binding-id.d.ts +4 -0
- package/dist/plugin-sdk/src/channels/thread-bindings-messages.d.ts +19 -0
- package/dist/plugin-sdk/src/channels/thread-bindings-policy.d.ts +68 -0
- package/dist/plugin-sdk/src/channels/transport/stall-watchdog.d.ts +20 -0
- package/dist/plugin-sdk/src/channels/typing-lifecycle.d.ts +12 -0
- package/dist/plugin-sdk/src/channels/typing-start-guard.d.ts +13 -0
- package/dist/plugin-sdk/src/channels/typing.d.ts +18 -0
- package/dist/plugin-sdk/src/cli/argv.d.ts +27 -0
- package/dist/plugin-sdk/src/cli/cli-name.d.ts +3 -0
- package/dist/plugin-sdk/src/cli/cli-utils.d.ts +19 -0
- package/dist/plugin-sdk/src/cli/command-format.d.ts +1 -0
- package/dist/plugin-sdk/src/cli/command-secret-gateway.d.ts +19 -0
- package/dist/plugin-sdk/src/cli/command-secret-targets.d.ts +16 -0
- package/dist/plugin-sdk/src/cli/deps.d.ts +11 -0
- package/dist/plugin-sdk/src/cli/help-format.d.ts +5 -0
- package/dist/plugin-sdk/src/cli/memory-cli.d.ts +12 -0
- package/dist/plugin-sdk/src/cli/message-secret-scope.d.ts +11 -0
- package/dist/plugin-sdk/src/cli/nodes-camera.d.ts +51 -0
- package/dist/plugin-sdk/src/cli/nodes-canvas.d.ts +10 -0
- package/dist/plugin-sdk/src/cli/nodes-media-utils.d.ts +13 -0
- package/dist/plugin-sdk/src/cli/nodes-run.d.ts +3 -0
- package/dist/plugin-sdk/src/cli/nodes-screen.d.ts +18 -0
- package/dist/plugin-sdk/src/cli/outbound-send-deps.d.ts +4 -0
- package/dist/plugin-sdk/src/cli/outbound-send-mapping.d.ts +13 -0
- package/dist/plugin-sdk/src/cli/parse-bytes.d.ts +4 -0
- package/dist/plugin-sdk/src/cli/parse-duration.d.ts +4 -0
- package/dist/plugin-sdk/src/cli/parse-timeout.d.ts +4 -0
- package/dist/plugin-sdk/src/cli/profile-utils.d.ts +2 -0
- package/dist/plugin-sdk/src/cli/progress.d.ts +24 -0
- package/dist/plugin-sdk/src/cli/prompt.d.ts +1 -0
- package/dist/plugin-sdk/src/cli/send-runtime/discord.d.ts +4 -0
- package/dist/plugin-sdk/src/cli/send-runtime/imessage.d.ts +4 -0
- package/dist/plugin-sdk/src/cli/send-runtime/signal.d.ts +4 -0
- package/dist/plugin-sdk/src/cli/send-runtime/slack.d.ts +4 -0
- package/dist/plugin-sdk/src/cli/send-runtime/telegram.d.ts +4 -0
- package/dist/plugin-sdk/src/cli/send-runtime/whatsapp.d.ts +4 -0
- package/dist/plugin-sdk/src/cli/wait.d.ts +1 -0
- package/dist/plugin-sdk/src/commands/backup-shared.d.ts +32 -0
- package/dist/plugin-sdk/src/commands/chutes-oauth.d.ts +21 -0
- package/dist/plugin-sdk/src/commands/cleanup-utils.d.ts +36 -0
- package/dist/plugin-sdk/src/commands/daemon-runtime.d.ts +8 -0
- package/dist/plugin-sdk/src/commands/health.d.ts +63 -0
- package/dist/plugin-sdk/src/commands/models/shared.d.ts +58 -0
- package/dist/plugin-sdk/src/commands/onboard-types.d.ts +92 -0
- package/dist/plugin-sdk/src/compat/legacy-names.d.ts +8 -0
- package/dist/plugin-sdk/src/config/agent-dirs.d.ts +14 -0
- package/dist/plugin-sdk/src/config/agent-limits.d.ts +6 -0
- package/dist/plugin-sdk/src/config/allowed-values.d.ts +7 -0
- package/dist/plugin-sdk/src/config/backup-rotation.d.ts +32 -0
- package/dist/plugin-sdk/src/config/bindings.d.ts +8 -0
- package/dist/plugin-sdk/src/config/byte-size.d.ts +6 -0
- package/dist/plugin-sdk/src/config/cache-utils.d.ts +10 -0
- package/dist/plugin-sdk/src/config/channel-capabilities.d.ts +6 -0
- package/dist/plugin-sdk/src/config/channel-configured.d.ts +2 -0
- package/dist/plugin-sdk/src/config/commands.d.ts +25 -0
- package/dist/plugin-sdk/src/config/config-paths.d.ts +10 -0
- package/dist/plugin-sdk/src/config/config.d.ts +6 -0
- package/dist/plugin-sdk/src/config/dangerous-name-matching.d.ts +12 -0
- package/dist/plugin-sdk/src/config/defaults.d.ts +18 -0
- package/dist/plugin-sdk/src/config/discord-preview-streaming.d.ts +27 -0
- package/dist/plugin-sdk/src/config/env-preserve.d.ts +10 -0
- package/dist/plugin-sdk/src/config/env-substitution.d.ts +45 -0
- package/dist/plugin-sdk/src/config/env-vars.d.ts +7 -0
- package/dist/plugin-sdk/src/config/gateway-control-ui-origins.d.ts +21 -0
- package/dist/plugin-sdk/src/config/group-policy.d.ts +49 -0
- package/dist/plugin-sdk/src/config/includes.d.ts +43 -0
- package/dist/plugin-sdk/src/config/io.d.ts +79 -0
- package/dist/plugin-sdk/src/config/issue-format.d.ts +14 -0
- package/dist/plugin-sdk/src/config/legacy-migrate.d.ts +5 -0
- package/dist/plugin-sdk/src/config/legacy-web-search.d.ts +8 -0
- package/dist/plugin-sdk/src/config/legacy.d.ts +6 -0
- package/dist/plugin-sdk/src/config/legacy.migrations.d.ts +1 -0
- package/dist/plugin-sdk/src/config/legacy.migrations.part-1.d.ts +2 -0
- package/dist/plugin-sdk/src/config/legacy.migrations.part-2.d.ts +2 -0
- package/dist/plugin-sdk/src/config/legacy.migrations.part-3.d.ts +2 -0
- package/dist/plugin-sdk/src/config/legacy.rules.d.ts +2 -0
- package/dist/plugin-sdk/src/config/legacy.shared.d.ts +20 -0
- package/dist/plugin-sdk/src/config/logging.d.ts +8 -0
- package/dist/plugin-sdk/src/config/markdown-tables.d.ts +8 -0
- package/dist/plugin-sdk/src/config/mcp-config.d.ts +33 -0
- package/dist/plugin-sdk/src/config/merge-patch.d.ts +5 -0
- package/dist/plugin-sdk/src/config/model-input.d.ts +9 -0
- package/dist/plugin-sdk/src/config/normalize-exec-safe-bin.d.ts +2 -0
- package/dist/plugin-sdk/src/config/normalize-paths.d.ts +8 -0
- package/dist/plugin-sdk/src/config/paths.d.ts +57 -0
- package/dist/plugin-sdk/src/config/plugin-auto-enable.d.ts +14 -0
- package/dist/plugin-sdk/src/config/plugins-allowlist.d.ts +2 -0
- package/dist/plugin-sdk/src/config/port-defaults.d.ts +13 -0
- package/dist/plugin-sdk/src/config/prototype-keys.d.ts +1 -0
- package/dist/plugin-sdk/src/config/runtime-group-policy.d.ts +56 -0
- package/dist/plugin-sdk/src/config/runtime-overrides.d.ts +15 -0
- package/dist/plugin-sdk/src/config/sessions/artifacts.d.ts +5 -0
- package/dist/plugin-sdk/src/config/sessions/delivery-info.d.ts +16 -0
- package/dist/plugin-sdk/src/config/sessions/disk-budget.d.ts +28 -0
- package/dist/plugin-sdk/src/config/sessions/explicit-session-key-normalization.d.ts +2 -0
- package/dist/plugin-sdk/src/config/sessions/group.d.ts +11 -0
- package/dist/plugin-sdk/src/config/sessions/main-session.d.ts +42 -0
- package/dist/plugin-sdk/src/config/sessions/main-session.runtime.d.ts +1 -0
- package/dist/plugin-sdk/src/config/sessions/metadata.d.ts +16 -0
- package/dist/plugin-sdk/src/config/sessions/paths.d.ts +23 -0
- package/dist/plugin-sdk/src/config/sessions/reset.d.ts +43 -0
- package/dist/plugin-sdk/src/config/sessions/session-file.d.ts +15 -0
- package/dist/plugin-sdk/src/config/sessions/session-key.d.ts +8 -0
- package/dist/plugin-sdk/src/config/sessions/store-cache.d.ts +19 -0
- package/dist/plugin-sdk/src/config/sessions/store-maintenance.d.ts +62 -0
- package/dist/plugin-sdk/src/config/sessions/store-migrations.d.ts +2 -0
- package/dist/plugin-sdk/src/config/sessions/store-summary.d.ts +6 -0
- package/dist/plugin-sdk/src/config/sessions/store.d.ts +91 -0
- package/dist/plugin-sdk/src/config/sessions/store.runtime.d.ts +1 -0
- package/dist/plugin-sdk/src/config/sessions/targets.d.ts +19 -0
- package/dist/plugin-sdk/src/config/sessions/transcript.d.ts +33 -0
- package/dist/plugin-sdk/src/config/sessions/types.d.ts +259 -0
- package/dist/plugin-sdk/src/config/sessions.d.ts +15 -0
- package/dist/plugin-sdk/src/config/talk.d.ts +18 -0
- package/dist/plugin-sdk/src/config/telegram-custom-commands.d.ts +24 -0
- package/dist/plugin-sdk/src/config/types.acp.d.ts +44 -0
- package/dist/plugin-sdk/src/config/types.agent-defaults.d.ts +354 -0
- package/dist/plugin-sdk/src/config/types.agents-shared.d.ts +33 -0
- package/dist/plugin-sdk/src/config/types.agents.d.ts +94 -0
- package/dist/plugin-sdk/src/config/types.approvals.d.ts +26 -0
- package/dist/plugin-sdk/src/config/types.auth.d.ts +28 -0
- package/dist/plugin-sdk/src/config/types.base.d.ts +216 -0
- package/dist/plugin-sdk/src/config/types.browser.d.ts +71 -0
- package/dist/plugin-sdk/src/config/types.channel-messaging-common.d.ts +46 -0
- package/dist/plugin-sdk/src/config/types.channels.d.ts +63 -0
- package/dist/plugin-sdk/src/config/types.cli.d.ts +12 -0
- package/dist/plugin-sdk/src/config/types.cron.d.ts +55 -0
- package/dist/plugin-sdk/src/config/types.d.ts +34 -0
- package/dist/plugin-sdk/src/config/types.discord.d.ts +345 -0
- package/dist/plugin-sdk/src/config/types.gateway.d.ts +416 -0
- package/dist/plugin-sdk/src/config/types.googlechat.d.ts +115 -0
- package/dist/plugin-sdk/src/config/types.hooks.d.ts +123 -0
- package/dist/plugin-sdk/src/config/types.imessage.d.ts +81 -0
- package/dist/plugin-sdk/src/config/types.installs.d.ts +14 -0
- package/dist/plugin-sdk/src/config/types.irc.d.ts +56 -0
- package/dist/plugin-sdk/src/config/types.mcp.d.ts +13 -0
- package/dist/plugin-sdk/src/config/types.memory.d.ts +59 -0
- package/dist/plugin-sdk/src/config/types.messages.d.ts +163 -0
- package/dist/plugin-sdk/src/config/types.models.d.ts +57 -0
- package/dist/plugin-sdk/src/config/types.msteams.d.ts +111 -0
- package/dist/plugin-sdk/src/config/types.node-host.d.ts +10 -0
- package/dist/plugin-sdk/src/config/types.openclaw.d.ts +141 -0
- package/dist/plugin-sdk/src/config/types.plugins.d.ts +46 -0
- package/dist/plugin-sdk/src/config/types.queue.d.ts +14 -0
- package/dist/plugin-sdk/src/config/types.sandbox.d.ts +122 -0
- package/dist/plugin-sdk/src/config/types.secrets.d.ts +90 -0
- package/dist/plugin-sdk/src/config/types.signal.d.ts +58 -0
- package/dist/plugin-sdk/src/config/types.skills.d.ts +42 -0
- package/dist/plugin-sdk/src/config/types.slack.d.ts +190 -0
- package/dist/plugin-sdk/src/config/types.telegram.d.ts +271 -0
- package/dist/plugin-sdk/src/config/types.tools.d.ts +567 -0
- package/dist/plugin-sdk/src/config/types.tts.d.ts +97 -0
- package/dist/plugin-sdk/src/config/types.whatsapp.d.ts +105 -0
- package/dist/plugin-sdk/src/config/validation.d.ts +35 -0
- package/dist/plugin-sdk/src/config/version.d.ts +8 -0
- package/dist/plugin-sdk/src/config/zod-schema.agent-defaults.d.ts +387 -0
- package/dist/plugin-sdk/src/config/zod-schema.agent-model.d.ts +5 -0
- package/dist/plugin-sdk/src/config/zod-schema.agent-runtime.d.ts +1571 -0
- package/dist/plugin-sdk/src/config/zod-schema.agents.d.ts +803 -0
- package/dist/plugin-sdk/src/config/zod-schema.allowdeny.d.ts +13 -0
- package/dist/plugin-sdk/src/config/zod-schema.approvals.d.ts +15 -0
- package/dist/plugin-sdk/src/config/zod-schema.channels.d.ts +9 -0
- package/dist/plugin-sdk/src/config/zod-schema.core.d.ts +979 -0
- package/dist/plugin-sdk/src/config/zod-schema.d.ts +5313 -0
- package/dist/plugin-sdk/src/config/zod-schema.hooks.d.ts +85 -0
- package/dist/plugin-sdk/src/config/zod-schema.installs.d.ts +34 -0
- package/dist/plugin-sdk/src/config/zod-schema.providers-core.d.ts +4992 -0
- package/dist/plugin-sdk/src/config/zod-schema.providers-whatsapp.d.ts +245 -0
- package/dist/plugin-sdk/src/config/zod-schema.providers.d.ts +2923 -0
- package/dist/plugin-sdk/src/config/zod-schema.secret-input-validation.d.ts +24 -0
- package/dist/plugin-sdk/src/config/zod-schema.sensitive.d.ts +2 -0
- package/dist/plugin-sdk/src/config/zod-schema.session.d.ts +277 -0
- package/dist/plugin-sdk/src/context-engine/delegate.d.ts +15 -0
- package/dist/plugin-sdk/src/context-engine/index.d.ts +6 -0
- package/dist/plugin-sdk/src/context-engine/init.d.ts +1 -0
- package/dist/plugin-sdk/src/context-engine/legacy.d.ts +50 -0
- package/dist/plugin-sdk/src/context-engine/registry.d.ts +47 -0
- package/dist/plugin-sdk/src/context-engine/types.d.ts +206 -0
- package/dist/plugin-sdk/src/cron/delivery.d.ts +32 -0
- package/dist/plugin-sdk/src/cron/isolated-agent/delivery-target.d.ts +26 -0
- package/dist/plugin-sdk/src/cron/legacy-delivery.d.ts +15 -0
- package/dist/plugin-sdk/src/cron/normalize.d.ts +13 -0
- package/dist/plugin-sdk/src/cron/parse.d.ts +1 -0
- package/dist/plugin-sdk/src/cron/payload-migration.d.ts +3 -0
- package/dist/plugin-sdk/src/cron/schedule.d.ts +6 -0
- package/dist/plugin-sdk/src/cron/service/initial-delivery.d.ts +3 -0
- package/dist/plugin-sdk/src/cron/service/jobs.d.ts +32 -0
- package/dist/plugin-sdk/src/cron/service/locked.d.ts +2 -0
- package/dist/plugin-sdk/src/cron/service/normalize.d.ts +18 -0
- package/dist/plugin-sdk/src/cron/service/ops.d.ts +84 -0
- package/dist/plugin-sdk/src/cron/service/state.d.ts +158 -0
- package/dist/plugin-sdk/src/cron/service/store.d.ts +11 -0
- package/dist/plugin-sdk/src/cron/service/timeout-policy.d.ts +13 -0
- package/dist/plugin-sdk/src/cron/service/timer.d.ts +45 -0
- package/dist/plugin-sdk/src/cron/service.d.ts +69 -0
- package/dist/plugin-sdk/src/cron/session-reaper.d.ts +35 -0
- package/dist/plugin-sdk/src/cron/stagger.d.ts +8 -0
- package/dist/plugin-sdk/src/cron/store-migration.d.ts +9 -0
- package/dist/plugin-sdk/src/cron/store.d.ts +10 -0
- package/dist/plugin-sdk/src/cron/types-shared.d.ts +17 -0
- package/dist/plugin-sdk/src/cron/types.d.ts +142 -0
- package/dist/plugin-sdk/src/cron/webhook-url.d.ts +1 -0
- package/dist/plugin-sdk/src/daemon/arg-split.d.ts +4 -0
- package/dist/plugin-sdk/src/daemon/cmd-argv.d.ts +3 -0
- package/dist/plugin-sdk/src/daemon/cmd-set.d.ts +7 -0
- package/dist/plugin-sdk/src/daemon/constants.d.ts +35 -0
- package/dist/plugin-sdk/src/daemon/runtime-binary.d.ts +2 -0
- package/dist/plugin-sdk/src/gateway/auth-mode-policy.d.ts +4 -0
- package/dist/plugin-sdk/src/gateway/auth-rate-limit.d.ts +67 -0
- package/dist/plugin-sdk/src/gateway/auth.d.ts +62 -0
- package/dist/plugin-sdk/src/gateway/call.d.ts +88 -0
- package/dist/plugin-sdk/src/gateway/channel-status-patches.d.ts +6 -0
- package/dist/plugin-sdk/src/gateway/chat-abort.d.ts +46 -0
- package/dist/plugin-sdk/src/gateway/chat-sanitize.d.ts +4 -0
- package/dist/plugin-sdk/src/gateway/client.d.ts +83 -0
- package/dist/plugin-sdk/src/gateway/connection-auth.d.ts +28 -0
- package/dist/plugin-sdk/src/gateway/credential-planner.d.ts +53 -0
- package/dist/plugin-sdk/src/gateway/credentials.d.ts +52 -0
- package/dist/plugin-sdk/src/gateway/device-auth.d.ts +18 -0
- package/dist/plugin-sdk/src/gateway/device-metadata-normalization.d.ts +2 -0
- package/dist/plugin-sdk/src/gateway/exec-approval-manager.d.ts +47 -0
- package/dist/plugin-sdk/src/gateway/method-scopes.d.ts +22 -0
- package/dist/plugin-sdk/src/gateway/model-pricing-cache.d.ts +32 -0
- package/dist/plugin-sdk/src/gateway/net.d.ts +88 -0
- package/dist/plugin-sdk/src/gateway/node-registry.d.ts +60 -0
- package/dist/plugin-sdk/src/gateway/operator-approvals-client.d.ts +6 -0
- package/dist/plugin-sdk/src/gateway/protocol/client-info.d.ts +58 -0
- package/dist/plugin-sdk/src/gateway/protocol/connect-error-details.d.ts +38 -0
- package/dist/plugin-sdk/src/gateway/protocol/index.d.ts +874 -0
- package/dist/plugin-sdk/src/gateway/protocol/schema/agent.d.ts +119 -0
- package/dist/plugin-sdk/src/gateway/protocol/schema/agents-models-skills.d.ts +206 -0
- package/dist/plugin-sdk/src/gateway/protocol/schema/channels.d.ts +229 -0
- package/dist/plugin-sdk/src/gateway/protocol/schema/config.d.ts +110 -0
- package/dist/plugin-sdk/src/gateway/protocol/schema/cron.d.ts +455 -0
- package/dist/plugin-sdk/src/gateway/protocol/schema/devices.d.ts +42 -0
- package/dist/plugin-sdk/src/gateway/protocol/schema/error-codes.d.ts +14 -0
- package/dist/plugin-sdk/src/gateway/protocol/schema/exec-approvals.d.ts +184 -0
- package/dist/plugin-sdk/src/gateway/protocol/schema/frames.d.ts +169 -0
- package/dist/plugin-sdk/src/gateway/protocol/schema/logs-chat.d.ts +53 -0
- package/dist/plugin-sdk/src/gateway/protocol/schema/nodes.d.ts +111 -0
- package/dist/plugin-sdk/src/gateway/protocol/schema/primitives.d.ts +40 -0
- package/dist/plugin-sdk/src/gateway/protocol/schema/protocol-schemas.d.ts +1601 -0
- package/dist/plugin-sdk/src/gateway/protocol/schema/push.d.ts +16 -0
- package/dist/plugin-sdk/src/gateway/protocol/schema/secrets.d.ts +23 -0
- package/dist/plugin-sdk/src/gateway/protocol/schema/sessions.d.ts +112 -0
- package/dist/plugin-sdk/src/gateway/protocol/schema/snapshot.d.ts +69 -0
- package/dist/plugin-sdk/src/gateway/protocol/schema/types.d.ts +137 -0
- package/dist/plugin-sdk/src/gateway/protocol/schema/wizard.d.ts +86 -0
- package/dist/plugin-sdk/src/gateway/protocol/schema.d.ts +18 -0
- package/dist/plugin-sdk/src/gateway/resolve-configured-secret-input-string.d.ts +33 -0
- package/dist/plugin-sdk/src/gateway/security-path.d.ts +20 -0
- package/dist/plugin-sdk/src/gateway/server/ws-types.d.ts +12 -0
- package/dist/plugin-sdk/src/gateway/server-broadcast.d.ts +17 -0
- package/dist/plugin-sdk/src/gateway/server-channels.d.ts +66 -0
- package/dist/plugin-sdk/src/gateway/server-constants.d.ts +11 -0
- package/dist/plugin-sdk/src/gateway/server-methods/types.d.ts +102 -0
- package/dist/plugin-sdk/src/gateway/server-shared.d.ts +7 -0
- package/dist/plugin-sdk/src/gateway/session-archive.fs.d.ts +20 -0
- package/dist/plugin-sdk/src/gateway/session-utils.d.ts +108 -0
- package/dist/plugin-sdk/src/gateway/session-utils.fs.d.ts +33 -0
- package/dist/plugin-sdk/src/gateway/session-utils.types.d.ts +76 -0
- package/dist/plugin-sdk/src/gateway/startup-auth.d.ts +20 -0
- package/dist/plugin-sdk/src/gateway/ws-log.d.ts +5 -0
- package/dist/plugin-sdk/src/gateway/ws-logging.d.ts +4 -0
- package/dist/plugin-sdk/src/globals.d.ts +11 -0
- package/dist/plugin-sdk/src/hooks/fire-and-forget.d.ts +1 -0
- package/dist/plugin-sdk/src/hooks/internal-hooks.d.ts +216 -0
- package/dist/plugin-sdk/src/hooks/message-hook-mappers.d.ts +76 -0
- package/dist/plugin-sdk/src/hooks/types.d.ts +62 -0
- package/dist/plugin-sdk/src/image-generation/provider-registry.d.ts +4 -0
- package/dist/plugin-sdk/src/image-generation/providers/fal.d.ts +2 -0
- package/dist/plugin-sdk/src/image-generation/providers/google.d.ts +2 -0
- package/dist/plugin-sdk/src/image-generation/providers/openai.d.ts +2 -0
- package/dist/plugin-sdk/src/image-generation/runtime.d.ts +27 -0
- package/dist/plugin-sdk/src/image-generation/types.d.ts +64 -0
- package/dist/plugin-sdk/src/infra/abort-signal.d.ts +1 -0
- package/dist/plugin-sdk/src/infra/agent-events.d.ts +24 -0
- package/dist/plugin-sdk/src/infra/archive-path.d.ts +12 -0
- package/dist/plugin-sdk/src/infra/archive-staging.d.ts +24 -0
- package/dist/plugin-sdk/src/infra/archive.d.ts +53 -0
- package/dist/plugin-sdk/src/infra/backoff.d.ts +8 -0
- package/dist/plugin-sdk/src/infra/backup-create.d.ts +29 -0
- package/dist/plugin-sdk/src/infra/binaries.d.ts +3 -0
- package/dist/plugin-sdk/src/infra/boundary-file-read.d.ts +34 -0
- package/dist/plugin-sdk/src/infra/boundary-path.d.ts +38 -0
- package/dist/plugin-sdk/src/infra/brew.d.ts +8 -0
- package/dist/plugin-sdk/src/infra/channel-activity.d.ts +18 -0
- package/dist/plugin-sdk/src/infra/channel-summary.d.ts +7 -0
- package/dist/plugin-sdk/src/infra/cli-root-options.d.ts +3 -0
- package/dist/plugin-sdk/src/infra/dedupe.d.ts +13 -0
- package/dist/plugin-sdk/src/infra/device-auth-store.d.ts +18 -0
- package/dist/plugin-sdk/src/infra/device-bootstrap.d.ts +41 -0
- package/dist/plugin-sdk/src/infra/device-identity.d.ts +11 -0
- package/dist/plugin-sdk/src/infra/device-pairing.d.ts +126 -0
- package/dist/plugin-sdk/src/infra/diagnostic-events.d.ts +140 -0
- package/dist/plugin-sdk/src/infra/diagnostic-flags.d.ts +4 -0
- package/dist/plugin-sdk/src/infra/dotenv.d.ts +3 -0
- package/dist/plugin-sdk/src/infra/env.d.ts +11 -0
- package/dist/plugin-sdk/src/infra/errors.d.ts +13 -0
- package/dist/plugin-sdk/src/infra/exec-allowlist-pattern.d.ts +1 -0
- package/dist/plugin-sdk/src/infra/exec-approval-command-display.d.ts +6 -0
- package/dist/plugin-sdk/src/infra/exec-approval-reply.d.ts +31 -0
- package/dist/plugin-sdk/src/infra/exec-approval-session-target.d.ts +16 -0
- package/dist/plugin-sdk/src/infra/exec-approval-surface.d.ts +20 -0
- package/dist/plugin-sdk/src/infra/exec-approvals-allowlist.d.ts +64 -0
- package/dist/plugin-sdk/src/infra/exec-approvals-analysis.d.ts +79 -0
- package/dist/plugin-sdk/src/infra/exec-approvals.d.ts +147 -0
- package/dist/plugin-sdk/src/infra/exec-command-resolution.d.ts +46 -0
- package/dist/plugin-sdk/src/infra/exec-obfuscation-detect.d.ts +12 -0
- package/dist/plugin-sdk/src/infra/exec-safe-bin-policy-profiles.d.ts +24 -0
- package/dist/plugin-sdk/src/infra/exec-safe-bin-policy-validator.d.ts +2 -0
- package/dist/plugin-sdk/src/infra/exec-safe-bin-policy.d.ts +2 -0
- package/dist/plugin-sdk/src/infra/exec-safe-bin-runtime-policy.d.ts +25 -0
- package/dist/plugin-sdk/src/infra/exec-safe-bin-trust.d.ts +23 -0
- package/dist/plugin-sdk/src/infra/exec-safety.d.ts +1 -0
- package/dist/plugin-sdk/src/infra/exec-wrapper-resolution.d.ts +48 -0
- package/dist/plugin-sdk/src/infra/executable-path.d.ts +6 -0
- package/dist/plugin-sdk/src/infra/fetch.d.ts +2 -0
- package/dist/plugin-sdk/src/infra/file-identity.d.ts +5 -0
- package/dist/plugin-sdk/src/infra/file-lock.d.ts +2 -0
- package/dist/plugin-sdk/src/infra/format-time/format-datetime.d.ts +35 -0
- package/dist/plugin-sdk/src/infra/format-time/format-duration.d.ts +23 -0
- package/dist/plugin-sdk/src/infra/format-time/format-relative.d.ts +39 -0
- package/dist/plugin-sdk/src/infra/fs-pinned-write-helper.d.ts +18 -0
- package/dist/plugin-sdk/src/infra/fs-safe.d.ts +87 -0
- package/dist/plugin-sdk/src/infra/gemini-auth.d.ts +16 -0
- package/dist/plugin-sdk/src/infra/git-commit.d.ts +14 -0
- package/dist/plugin-sdk/src/infra/git-root.d.ts +7 -0
- package/dist/plugin-sdk/src/infra/hardlink-guards.d.ts +6 -0
- package/dist/plugin-sdk/src/infra/heartbeat-events.d.ts +22 -0
- package/dist/plugin-sdk/src/infra/heartbeat-reason.d.ts +5 -0
- package/dist/plugin-sdk/src/infra/heartbeat-summary.d.ts +16 -0
- package/dist/plugin-sdk/src/infra/heartbeat-visibility.d.ts +17 -0
- package/dist/plugin-sdk/src/infra/heartbeat-wake.d.ts +33 -0
- package/dist/plugin-sdk/src/infra/home-dir.d.ts +17 -0
- package/dist/plugin-sdk/src/infra/host-env-security.d.ts +40 -0
- package/dist/plugin-sdk/src/infra/http-body.d.ts +46 -0
- package/dist/plugin-sdk/src/infra/json-file.d.ts +2 -0
- package/dist/plugin-sdk/src/infra/json-files.d.ts +12 -0
- package/dist/plugin-sdk/src/infra/json-utf8-bytes.d.ts +1 -0
- package/dist/plugin-sdk/src/infra/jsonl-socket.d.ts +6 -0
- package/dist/plugin-sdk/src/infra/machine-name.d.ts +1 -0
- package/dist/plugin-sdk/src/infra/map-size.d.ts +1 -0
- package/dist/plugin-sdk/src/infra/matrix-legacy-crypto.d.ts +41 -0
- package/dist/plugin-sdk/src/infra/matrix-legacy-state.d.ts +30 -0
- package/dist/plugin-sdk/src/infra/matrix-migration-config.d.ts +48 -0
- package/dist/plugin-sdk/src/infra/matrix-migration-snapshot.d.ts +25 -0
- package/dist/plugin-sdk/src/infra/matrix-plugin-helper.d.ts +29 -0
- package/dist/plugin-sdk/src/infra/net/fetch-guard.d.ts +37 -0
- package/dist/plugin-sdk/src/infra/net/hostname.d.ts +1 -0
- package/dist/plugin-sdk/src/infra/net/proxy-env.d.ts +10 -0
- package/dist/plugin-sdk/src/infra/net/proxy-fetch.d.ts +15 -0
- package/dist/plugin-sdk/src/infra/net/ssrf.d.ts +55 -0
- package/dist/plugin-sdk/src/infra/net/undici-global-dispatcher.d.ts +6 -0
- package/dist/plugin-sdk/src/infra/node-pairing.d.ts +53 -0
- package/dist/plugin-sdk/src/infra/node-shell.d.ts +1 -0
- package/dist/plugin-sdk/src/infra/npm-registry-spec.d.ts +19 -0
- package/dist/plugin-sdk/src/infra/openclaw-exec-env.d.ts +4 -0
- package/dist/plugin-sdk/src/infra/openclaw-root.d.ts +10 -0
- package/dist/plugin-sdk/src/infra/outbound/abort.d.ts +8 -0
- package/dist/plugin-sdk/src/infra/outbound/agent-delivery.d.ts +46 -0
- package/dist/plugin-sdk/src/infra/outbound/base-session-key.d.ts +9 -0
- package/dist/plugin-sdk/src/infra/outbound/bound-delivery-router.d.ts +16 -0
- package/dist/plugin-sdk/src/infra/outbound/channel-adapters.d.ts +14 -0
- package/dist/plugin-sdk/src/infra/outbound/channel-resolution.d.ts +8 -0
- package/dist/plugin-sdk/src/infra/outbound/channel-selection.d.ts +17 -0
- package/dist/plugin-sdk/src/infra/outbound/channel-target.d.ts +6 -0
- package/dist/plugin-sdk/src/infra/outbound/conversation-id.d.ts +4 -0
- package/dist/plugin-sdk/src/infra/outbound/deliver-runtime.d.ts +1 -0
- package/dist/plugin-sdk/src/infra/outbound/deliver.d.ts +49 -0
- package/dist/plugin-sdk/src/infra/outbound/delivery-queue.d.ts +89 -0
- package/dist/plugin-sdk/src/infra/outbound/directory-cache.d.ts +24 -0
- package/dist/plugin-sdk/src/infra/outbound/envelope.d.ts +16 -0
- package/dist/plugin-sdk/src/infra/outbound/format.d.ts +39 -0
- package/dist/plugin-sdk/src/infra/outbound/identity.d.ts +9 -0
- package/dist/plugin-sdk/src/infra/outbound/message-action-normalization.d.ts +6 -0
- package/dist/plugin-sdk/src/infra/outbound/message-action-params.d.ts +36 -0
- package/dist/plugin-sdk/src/infra/outbound/message-action-runner.d.ts +76 -0
- package/dist/plugin-sdk/src/infra/outbound/message-action-spec.d.ts +7 -0
- package/dist/plugin-sdk/src/infra/outbound/message.d.ts +84 -0
- package/dist/plugin-sdk/src/infra/outbound/mirror.d.ts +13 -0
- package/dist/plugin-sdk/src/infra/outbound/outbound-policy.d.ts +32 -0
- package/dist/plugin-sdk/src/infra/outbound/outbound-send-service.d.ts +65 -0
- package/dist/plugin-sdk/src/infra/outbound/outbound-session.d.ts +31 -0
- package/dist/plugin-sdk/src/infra/outbound/payloads.d.ts +23 -0
- package/dist/plugin-sdk/src/infra/outbound/sanitize-text.d.ts +23 -0
- package/dist/plugin-sdk/src/infra/outbound/send-deps.d.ts +30 -0
- package/dist/plugin-sdk/src/infra/outbound/session-binding-service.d.ts +90 -0
- package/dist/plugin-sdk/src/infra/outbound/session-context.d.ts +12 -0
- package/dist/plugin-sdk/src/infra/outbound/target-errors.d.ts +6 -0
- package/dist/plugin-sdk/src/infra/outbound/target-normalization.d.ts +4 -0
- package/dist/plugin-sdk/src/infra/outbound/target-resolver.d.ts +60 -0
- package/dist/plugin-sdk/src/infra/outbound/targets.d.ts +87 -0
- package/dist/plugin-sdk/src/infra/outbound/thread-id.d.ts +1 -0
- package/dist/plugin-sdk/src/infra/outbound/tool-payload.d.ts +2 -0
- package/dist/plugin-sdk/src/infra/pairing-files.d.ts +23 -0
- package/dist/plugin-sdk/src/infra/pairing-pending.d.ts +13 -0
- package/dist/plugin-sdk/src/infra/pairing-token.d.ts +3 -0
- package/dist/plugin-sdk/src/infra/parse-finite-number.d.ts +4 -0
- package/dist/plugin-sdk/src/infra/path-alias-guards.d.ts +18 -0
- package/dist/plugin-sdk/src/infra/path-guards.d.ts +6 -0
- package/dist/plugin-sdk/src/infra/path-prepend.d.ts +11 -0
- package/dist/plugin-sdk/src/infra/path-safety.d.ts +2 -0
- package/dist/plugin-sdk/src/infra/plain-object.d.ts +4 -0
- package/dist/plugin-sdk/src/infra/ports-format.d.ts +5 -0
- package/dist/plugin-sdk/src/infra/ports-inspect.d.ts +2 -0
- package/dist/plugin-sdk/src/infra/ports-lsof.d.ts +2 -0
- package/dist/plugin-sdk/src/infra/ports-probe.d.ts +5 -0
- package/dist/plugin-sdk/src/infra/ports-types.d.ts +18 -0
- package/dist/plugin-sdk/src/infra/ports.d.ts +14 -0
- package/dist/plugin-sdk/src/infra/prototype-keys.d.ts +1 -0
- package/dist/plugin-sdk/src/infra/provider-usage.auth.d.ts +14 -0
- package/dist/plugin-sdk/src/infra/provider-usage.d.ts +4 -0
- package/dist/plugin-sdk/src/infra/provider-usage.fetch.claude.d.ts +2 -0
- package/dist/plugin-sdk/src/infra/provider-usage.fetch.codex.d.ts +2 -0
- package/dist/plugin-sdk/src/infra/provider-usage.fetch.d.ts +5 -0
- package/dist/plugin-sdk/src/infra/provider-usage.fetch.gemini.d.ts +2 -0
- package/dist/plugin-sdk/src/infra/provider-usage.fetch.minimax.d.ts +2 -0
- package/dist/plugin-sdk/src/infra/provider-usage.fetch.shared.d.ts +12 -0
- package/dist/plugin-sdk/src/infra/provider-usage.fetch.zai.d.ts +2 -0
- package/dist/plugin-sdk/src/infra/provider-usage.format.d.ts +13 -0
- package/dist/plugin-sdk/src/infra/provider-usage.load.d.ts +16 -0
- package/dist/plugin-sdk/src/infra/provider-usage.shared.d.ts +9 -0
- package/dist/plugin-sdk/src/infra/provider-usage.types.d.ts +17 -0
- package/dist/plugin-sdk/src/infra/restart-sentinel.d.ts +50 -0
- package/dist/plugin-sdk/src/infra/restart-stale-pids.d.ts +22 -0
- package/dist/plugin-sdk/src/infra/restart.d.ts +72 -0
- package/dist/plugin-sdk/src/infra/retry-policy.d.ts +30 -0
- package/dist/plugin-sdk/src/infra/retry.d.ts +21 -0
- package/dist/plugin-sdk/src/infra/safe-open-sync.d.ts +25 -0
- package/dist/plugin-sdk/src/infra/scp-host.d.ts +4 -0
- package/dist/plugin-sdk/src/infra/secret-file.d.ts +18 -0
- package/dist/plugin-sdk/src/infra/secure-random.d.ts +2 -0
- package/dist/plugin-sdk/src/infra/session-cost-usage.d.ts +45 -0
- package/dist/plugin-sdk/src/infra/session-cost-usage.types.d.ts +141 -0
- package/dist/plugin-sdk/src/infra/session-maintenance-warning.d.ts +11 -0
- package/dist/plugin-sdk/src/infra/shell-env.d.ts +34 -0
- package/dist/plugin-sdk/src/infra/shell-inline-command.d.ts +8 -0
- package/dist/plugin-sdk/src/infra/skills-remote.d.ts +25 -0
- package/dist/plugin-sdk/src/infra/ssh-tunnel.d.ts +21 -0
- package/dist/plugin-sdk/src/infra/system-events.d.ts +18 -0
- package/dist/plugin-sdk/src/infra/system-message.d.ts +3 -0
- package/dist/plugin-sdk/src/infra/system-run-approval-binding.d.ts +49 -0
- package/dist/plugin-sdk/src/infra/system-run-approval-context.d.ts +45 -0
- package/dist/plugin-sdk/src/infra/system-run-command.d.ts +36 -0
- package/dist/plugin-sdk/src/infra/system-run-normalize.d.ts +2 -0
- package/dist/plugin-sdk/src/infra/tailnet.d.ts +8 -0
- package/dist/plugin-sdk/src/infra/tailscale.d.ts +34 -0
- package/dist/plugin-sdk/src/infra/tls/fingerprint.d.ts +1 -0
- package/dist/plugin-sdk/src/infra/tls/gateway.d.ts +16 -0
- package/dist/plugin-sdk/src/infra/tmp-openclaw-dir.d.ts +20 -0
- package/dist/plugin-sdk/src/infra/transport-ready.d.ts +16 -0
- package/dist/plugin-sdk/src/infra/unhandled-rejections.d.ts +15 -0
- package/dist/plugin-sdk/src/infra/warning-filter.d.ts +7 -0
- package/dist/plugin-sdk/src/infra/windows-task-restart.d.ts +2 -0
- package/dist/plugin-sdk/src/infra/ws.d.ts +2 -0
- package/dist/plugin-sdk/src/infra/wsl.d.ts +12 -0
- package/dist/plugin-sdk/src/interactive/payload.d.ts +53 -0
- package/dist/plugin-sdk/src/line/accounts.d.ts +10 -0
- package/dist/plugin-sdk/src/line/actions.d.ts +22 -0
- package/dist/plugin-sdk/src/line/auto-reply-delivery.d.ts +38 -0
- package/dist/plugin-sdk/src/line/bot-access.d.ts +17 -0
- package/dist/plugin-sdk/src/line/bot-handlers.d.ts +23 -0
- package/dist/plugin-sdk/src/line/bot-message-context.d.ts +129 -0
- package/dist/plugin-sdk/src/line/bot.d.ts +24 -0
- package/dist/plugin-sdk/src/line/channel-access-token.d.ts +4 -0
- package/dist/plugin-sdk/src/line/config-schema.d.ts +65 -0
- package/dist/plugin-sdk/src/line/download.d.ts +7 -0
- package/dist/plugin-sdk/src/line/flex-templates/basic-cards.d.ts +46 -0
- package/dist/plugin-sdk/src/line/flex-templates/common.d.ts +2 -0
- package/dist/plugin-sdk/src/line/flex-templates/media-control-cards.d.ts +73 -0
- package/dist/plugin-sdk/src/line/flex-templates/message.d.ts +6 -0
- package/dist/plugin-sdk/src/line/flex-templates/schedule-cards.d.ts +55 -0
- package/dist/plugin-sdk/src/line/flex-templates/types.d.ts +19 -0
- package/dist/plugin-sdk/src/line/flex-templates.d.ts +5 -0
- package/dist/plugin-sdk/src/line/group-keys.d.ts +17 -0
- package/dist/plugin-sdk/src/line/markdown-to-line.d.ts +72 -0
- package/dist/plugin-sdk/src/line/monitor.d.ts +28 -0
- package/dist/plugin-sdk/src/line/probe.d.ts +2 -0
- package/dist/plugin-sdk/src/line/reply-chunks.d.ts +24 -0
- package/dist/plugin-sdk/src/line/send.d.ts +93 -0
- package/dist/plugin-sdk/src/line/signature.d.ts +1 -0
- package/dist/plugin-sdk/src/line/template-messages.d.ts +100 -0
- package/dist/plugin-sdk/src/line/types.d.ts +115 -0
- package/dist/plugin-sdk/src/line/webhook-node.d.ts +15 -0
- package/dist/plugin-sdk/src/line/webhook-utils.d.ts +2 -0
- package/dist/plugin-sdk/src/line/webhook.d.ts +19 -0
- package/dist/plugin-sdk/src/link-understanding/apply.d.ts +10 -0
- package/dist/plugin-sdk/src/link-understanding/apply.runtime.d.ts +1 -0
- package/dist/plugin-sdk/src/link-understanding/defaults.d.ts +2 -0
- package/dist/plugin-sdk/src/link-understanding/detect.d.ts +3 -0
- package/dist/plugin-sdk/src/link-understanding/format.d.ts +4 -0
- package/dist/plugin-sdk/src/link-understanding/runner.d.ts +11 -0
- package/dist/plugin-sdk/src/logger.d.ts +6 -0
- package/dist/plugin-sdk/src/logging/config.d.ts +4 -0
- package/dist/plugin-sdk/src/logging/console.d.ts +23 -0
- package/dist/plugin-sdk/src/logging/diagnostic-session-state.d.ts +30 -0
- package/dist/plugin-sdk/src/logging/diagnostic.d.ts +67 -0
- package/dist/plugin-sdk/src/logging/env-log-level.d.ts +2 -0
- package/dist/plugin-sdk/src/logging/levels.d.ts +5 -0
- package/dist/plugin-sdk/src/logging/logger.d.ts +48 -0
- package/dist/plugin-sdk/src/logging/node-require.d.ts +1 -0
- package/dist/plugin-sdk/src/logging/redact-bounded.d.ts +8 -0
- package/dist/plugin-sdk/src/logging/redact-identifier.d.ts +4 -0
- package/dist/plugin-sdk/src/logging/redact.d.ts +9 -0
- package/dist/plugin-sdk/src/logging/state.d.ts +19 -0
- package/dist/plugin-sdk/src/logging/subsystem.d.ts +18 -0
- package/dist/plugin-sdk/src/logging/timestamps.d.ts +2 -0
- package/dist/plugin-sdk/src/logging.d.ts +10 -0
- package/dist/plugin-sdk/src/markdown/code-spans.d.ts +10 -0
- package/dist/plugin-sdk/src/markdown/fences.d.ts +10 -0
- package/dist/plugin-sdk/src/markdown/frontmatter.d.ts +2 -0
- package/dist/plugin-sdk/src/markdown/ir.d.ts +32 -0
- package/dist/plugin-sdk/src/markdown/render.d.ts +18 -0
- package/dist/plugin-sdk/src/markdown/tables.d.ts +2 -0
- package/dist/plugin-sdk/src/markdown/whatsapp.d.ts +14 -0
- package/dist/plugin-sdk/src/media/audio-tags.d.ts +10 -0
- package/dist/plugin-sdk/src/media/audio.d.ts +19 -0
- package/dist/plugin-sdk/src/media/base64.d.ts +6 -0
- package/dist/plugin-sdk/src/media/constants.d.ts +7 -0
- package/dist/plugin-sdk/src/media/fetch.d.ts +34 -0
- package/dist/plugin-sdk/src/media/ffmpeg-exec.d.ts +11 -0
- package/dist/plugin-sdk/src/media/ffmpeg-limits.d.ts +4 -0
- package/dist/plugin-sdk/src/media/file-context.d.ts +7 -0
- package/dist/plugin-sdk/src/media/image-ops.d.ts +41 -0
- package/dist/plugin-sdk/src/media/inbound-path-policy.d.ts +18 -0
- package/dist/plugin-sdk/src/media/input-files.d.ts +99 -0
- package/dist/plugin-sdk/src/media/load-options.d.ts +12 -0
- package/dist/plugin-sdk/src/media/local-roots.d.ts +3 -0
- package/dist/plugin-sdk/src/media/mime.d.ts +16 -0
- package/dist/plugin-sdk/src/media/outbound-attachment.d.ts +6 -0
- package/dist/plugin-sdk/src/media/parse.d.ts +8 -0
- package/dist/plugin-sdk/src/media/pdf-extract.d.ts +17 -0
- package/dist/plugin-sdk/src/media/png-encode.d.ts +8 -0
- package/dist/plugin-sdk/src/media/read-response-with-limit.d.ts +8 -0
- package/dist/plugin-sdk/src/media/sniff-mime-from-base64.d.ts +1 -0
- package/dist/plugin-sdk/src/media/store.d.ts +37 -0
- package/dist/plugin-sdk/src/media/temp-files.d.ts +1 -0
- package/dist/plugin-sdk/src/media/web-media.d.ts +43 -0
- package/dist/plugin-sdk/src/media-understanding/apply.d.ts +19 -0
- package/dist/plugin-sdk/src/media-understanding/apply.runtime.d.ts +1 -0
- package/dist/plugin-sdk/src/media-understanding/attachments.cache.d.ts +37 -0
- package/dist/plugin-sdk/src/media-understanding/attachments.d.ts +3 -0
- package/dist/plugin-sdk/src/media-understanding/attachments.normalize.d.ts +8 -0
- package/dist/plugin-sdk/src/media-understanding/attachments.select.d.ts +7 -0
- package/dist/plugin-sdk/src/media-understanding/audio-preflight.d.ts +16 -0
- package/dist/plugin-sdk/src/media-understanding/audio-transcription-runner.d.ts +16 -0
- package/dist/plugin-sdk/src/media-understanding/concurrency.d.ts +1 -0
- package/dist/plugin-sdk/src/media-understanding/defaults.d.ts +20 -0
- package/dist/plugin-sdk/src/media-understanding/echo-transcript.d.ts +13 -0
- package/dist/plugin-sdk/src/media-understanding/errors.d.ts +6 -0
- package/dist/plugin-sdk/src/media-understanding/format.d.ts +7 -0
- package/dist/plugin-sdk/src/media-understanding/fs.d.ts +1 -0
- package/dist/plugin-sdk/src/media-understanding/output-extract.d.ts +2 -0
- package/dist/plugin-sdk/src/media-understanding/providers/deepgram/audio.d.ts +4 -0
- package/dist/plugin-sdk/src/media-understanding/providers/deepgram/index.d.ts +2 -0
- package/dist/plugin-sdk/src/media-understanding/providers/groq/index.d.ts +2 -0
- package/dist/plugin-sdk/src/media-understanding/providers/image-runtime.d.ts +2 -0
- package/dist/plugin-sdk/src/media-understanding/providers/image.d.ts +3 -0
- package/dist/plugin-sdk/src/media-understanding/providers/index.d.ts +5 -0
- package/dist/plugin-sdk/src/media-understanding/providers/openai-compatible-audio.d.ts +7 -0
- package/dist/plugin-sdk/src/media-understanding/providers/shared.d.ts +28 -0
- package/dist/plugin-sdk/src/media-understanding/resolve.d.ts +44 -0
- package/dist/plugin-sdk/src/media-understanding/runner.d.ts +39 -0
- package/dist/plugin-sdk/src/media-understanding/runner.entries.d.ts +33 -0
- package/dist/plugin-sdk/src/media-understanding/runtime.d.ts +52 -0
- package/dist/plugin-sdk/src/media-understanding/scope.d.ts +9 -0
- package/dist/plugin-sdk/src/media-understanding/transcribe-audio.d.ts +1 -0
- package/dist/plugin-sdk/src/media-understanding/types.d.ts +115 -0
- package/dist/plugin-sdk/src/media-understanding/video.d.ts +2 -0
- package/dist/plugin-sdk/src/memory/backend-config.d.ts +55 -0
- package/dist/plugin-sdk/src/memory/batch-embedding-common.d.ts +9 -0
- package/dist/plugin-sdk/src/memory/batch-error-utils.d.ts +15 -0
- package/dist/plugin-sdk/src/memory/batch-gemini.d.ts +46 -0
- package/dist/plugin-sdk/src/memory/batch-http.d.ts +8 -0
- package/dist/plugin-sdk/src/memory/batch-openai.d.ts +19 -0
- package/dist/plugin-sdk/src/memory/batch-output.d.ts +23 -0
- package/dist/plugin-sdk/src/memory/batch-provider-common.d.ts +9 -0
- package/dist/plugin-sdk/src/memory/batch-runner.d.ts +38 -0
- package/dist/plugin-sdk/src/memory/batch-status.d.ts +27 -0
- package/dist/plugin-sdk/src/memory/batch-upload.d.ts +6 -0
- package/dist/plugin-sdk/src/memory/batch-utils.d.ts +11 -0
- package/dist/plugin-sdk/src/memory/batch-voyage.d.ts +20 -0
- package/dist/plugin-sdk/src/memory/embedding-chunk-limits.d.ts +3 -0
- package/dist/plugin-sdk/src/memory/embedding-input-limits.d.ts +4 -0
- package/dist/plugin-sdk/src/memory/embedding-inputs.d.ts +17 -0
- package/dist/plugin-sdk/src/memory/embedding-model-limits.d.ts +2 -0
- package/dist/plugin-sdk/src/memory/embedding-vectors.d.ts +1 -0
- package/dist/plugin-sdk/src/memory/embeddings-debug.d.ts +1 -0
- package/dist/plugin-sdk/src/memory/embeddings-gemini.d.ts +63 -0
- package/dist/plugin-sdk/src/memory/embeddings-mistral.d.ts +15 -0
- package/dist/plugin-sdk/src/memory/embeddings-model-normalize.d.ts +5 -0
- package/dist/plugin-sdk/src/memory/embeddings-ollama.d.ts +14 -0
- package/dist/plugin-sdk/src/memory/embeddings-openai.d.ts +15 -0
- package/dist/plugin-sdk/src/memory/embeddings-remote-client.d.ts +12 -0
- package/dist/plugin-sdk/src/memory/embeddings-remote-fetch.d.ts +8 -0
- package/dist/plugin-sdk/src/memory/embeddings-remote-provider.d.ts +21 -0
- package/dist/plugin-sdk/src/memory/embeddings-voyage.d.ts +15 -0
- package/dist/plugin-sdk/src/memory/embeddings.d.ts +58 -0
- package/dist/plugin-sdk/src/memory/fs-utils.d.ts +11 -0
- package/dist/plugin-sdk/src/memory/hybrid.d.ts +45 -0
- package/dist/plugin-sdk/src/memory/index.d.ts +3 -0
- package/dist/plugin-sdk/src/memory/internal.d.ts +51 -0
- package/dist/plugin-sdk/src/memory/manager-embedding-ops.d.ts +49 -0
- package/dist/plugin-sdk/src/memory/manager-runtime.d.ts +1 -0
- package/dist/plugin-sdk/src/memory/manager-search.d.ts +60 -0
- package/dist/plugin-sdk/src/memory/manager-sync-ops.d.ts +147 -0
- package/dist/plugin-sdk/src/memory/manager.d.ts +122 -0
- package/dist/plugin-sdk/src/memory/memory-schema.d.ts +11 -0
- package/dist/plugin-sdk/src/memory/mmr.d.ts +62 -0
- package/dist/plugin-sdk/src/memory/multimodal.d.ts +36 -0
- package/dist/plugin-sdk/src/memory/node-llama.d.ts +8 -0
- package/dist/plugin-sdk/src/memory/post-json.d.ts +10 -0
- package/dist/plugin-sdk/src/memory/prompt-section.d.ts +22 -0
- package/dist/plugin-sdk/src/memory/qmd-manager.d.ts +149 -0
- package/dist/plugin-sdk/src/memory/qmd-process.d.ts +24 -0
- package/dist/plugin-sdk/src/memory/qmd-query-parser.d.ts +9 -0
- package/dist/plugin-sdk/src/memory/qmd-scope.d.ts +4 -0
- package/dist/plugin-sdk/src/memory/query-expansion.d.ts +41 -0
- package/dist/plugin-sdk/src/memory/read-file.d.ts +21 -0
- package/dist/plugin-sdk/src/memory/remote-http.d.ts +9 -0
- package/dist/plugin-sdk/src/memory/search-manager.d.ts +12 -0
- package/dist/plugin-sdk/src/memory/secret-input.d.ts +5 -0
- package/dist/plugin-sdk/src/memory/session-files.d.ts +14 -0
- package/dist/plugin-sdk/src/memory/sqlite-vec.d.ts +9 -0
- package/dist/plugin-sdk/src/memory/sqlite.d.ts +1 -0
- package/dist/plugin-sdk/src/memory/temporal-decay.d.ts +25 -0
- package/dist/plugin-sdk/src/memory/types.d.ts +95 -0
- package/dist/plugin-sdk/src/node-host/with-timeout.d.ts +1 -0
- package/dist/plugin-sdk/src/pairing/pairing-challenge.d.ts +32 -0
- package/dist/plugin-sdk/src/pairing/pairing-labels.d.ts +2 -0
- package/dist/plugin-sdk/src/pairing/pairing-messages.d.ts +6 -0
- package/dist/plugin-sdk/src/pairing/pairing-store.d.ts +52 -0
- package/dist/plugin-sdk/src/param-key.d.ts +2 -0
- package/dist/plugin-sdk/src/plugin-sdk/account-helpers.d.ts +2 -0
- package/dist/plugin-sdk/src/plugin-sdk/account-id.d.ts +1 -0
- package/dist/plugin-sdk/src/plugin-sdk/account-resolution.d.ts +24 -0
- package/dist/plugin-sdk/src/plugin-sdk/acp-runtime.d.ts +7 -0
- package/dist/plugin-sdk/src/plugin-sdk/acpx.d.ts +8 -0
- package/dist/plugin-sdk/src/plugin-sdk/agent-media-payload.d.ts +13 -0
- package/dist/plugin-sdk/src/plugin-sdk/agent-runtime.d.ts +25 -0
- package/dist/plugin-sdk/src/plugin-sdk/allow-from.d.ts +58 -0
- package/dist/plugin-sdk/src/plugin-sdk/allowlist-config-edit.d.ts +99 -0
- package/dist/plugin-sdk/src/plugin-sdk/bluebubbles.d.ts +43 -0
- package/dist/plugin-sdk/src/plugin-sdk/boolean-param.d.ts +2 -0
- package/dist/plugin-sdk/src/plugin-sdk/channel-actions.d.ts +5 -0
- package/dist/plugin-sdk/src/plugin-sdk/channel-config-helpers.d.ts +147 -0
- package/dist/plugin-sdk/src/plugin-sdk/channel-config-schema.d.ts +4 -0
- package/dist/plugin-sdk/src/plugin-sdk/channel-contract.d.ts +1 -0
- package/dist/plugin-sdk/src/plugin-sdk/channel-feedback.d.ts +3 -0
- package/dist/plugin-sdk/src/plugin-sdk/channel-inbound.d.ts +11 -0
- package/dist/plugin-sdk/src/plugin-sdk/channel-lifecycle.d.ts +41 -0
- package/dist/plugin-sdk/src/plugin-sdk/channel-pairing.d.ts +21 -0
- package/dist/plugin-sdk/src/plugin-sdk/channel-plugin-common.d.ts +12 -0
- package/dist/plugin-sdk/src/plugin-sdk/channel-policy.d.ts +6 -0
- package/dist/plugin-sdk/src/plugin-sdk/channel-reply-pipeline.d.ts +16 -0
- package/dist/plugin-sdk/src/plugin-sdk/channel-runtime.d.ts +11 -0
- package/dist/plugin-sdk/src/plugin-sdk/channel-send-result.d.ts +39 -0
- package/dist/plugin-sdk/src/plugin-sdk/channel-setup.d.ts +18 -0
- package/dist/plugin-sdk/src/plugin-sdk/channel-targets.d.ts +3 -0
- package/dist/plugin-sdk/src/plugin-sdk/cli-runtime.d.ts +4 -0
- package/dist/plugin-sdk/src/plugin-sdk/command-auth.d.ts +62 -0
- package/dist/plugin-sdk/src/plugin-sdk/compat.d.ts +17 -0
- package/dist/plugin-sdk/src/plugin-sdk/config-paths.d.ts +7 -0
- package/dist/plugin-sdk/src/plugin-sdk/config-runtime.d.ts +18 -0
- package/dist/plugin-sdk/src/plugin-sdk/conversation-runtime.d.ts +18 -0
- package/dist/plugin-sdk/src/plugin-sdk/copilot-proxy.d.ts +2 -0
- package/dist/plugin-sdk/src/plugin-sdk/core.d.ts +142 -0
- package/dist/plugin-sdk/src/plugin-sdk/device-bootstrap.d.ts +2 -0
- package/dist/plugin-sdk/src/plugin-sdk/diagnostics-otel.d.ts +6 -0
- package/dist/plugin-sdk/src/plugin-sdk/diffs.d.ts +4 -0
- package/dist/plugin-sdk/src/plugin-sdk/directory-runtime.d.ts +8 -0
- package/dist/plugin-sdk/src/plugin-sdk/discord-core.d.ts +10 -0
- package/dist/plugin-sdk/src/plugin-sdk/discord-send.d.ts +31 -0
- package/dist/plugin-sdk/src/plugin-sdk/discord.d.ts +33 -0
- package/dist/plugin-sdk/src/plugin-sdk/entrypoints.d.ts +17 -0
- package/dist/plugin-sdk/src/plugin-sdk/extension-shared.d.ts +67 -0
- package/dist/plugin-sdk/src/plugin-sdk/feishu.d.ts +42 -0
- package/dist/plugin-sdk/src/plugin-sdk/fetch-auth.d.ts +14 -0
- package/dist/plugin-sdk/src/plugin-sdk/file-lock.d.ts +18 -0
- package/dist/plugin-sdk/src/plugin-sdk/gateway-runtime.d.ts +4 -0
- package/dist/plugin-sdk/src/plugin-sdk/google.d.ts +2 -0
- package/dist/plugin-sdk/src/plugin-sdk/googlechat.d.ts +45 -0
- package/dist/plugin-sdk/src/plugin-sdk/group-access.d.ts +57 -0
- package/dist/plugin-sdk/src/plugin-sdk/hook-runtime.d.ts +3 -0
- package/dist/plugin-sdk/src/plugin-sdk/image-generation-runtime.d.ts +1 -0
- package/dist/plugin-sdk/src/plugin-sdk/image-generation.d.ts +4 -0
- package/dist/plugin-sdk/src/plugin-sdk/imessage-core.d.ts +6 -0
- package/dist/plugin-sdk/src/plugin-sdk/imessage-targets.d.ts +1 -0
- package/dist/plugin-sdk/src/plugin-sdk/imessage.d.ts +14 -0
- package/dist/plugin-sdk/src/plugin-sdk/inbound-envelope.d.ts +97 -0
- package/dist/plugin-sdk/src/plugin-sdk/inbound-reply-dispatch.d.ts +73 -0
- package/dist/plugin-sdk/src/plugin-sdk/index.d.ts +25 -0
- package/dist/plugin-sdk/src/plugin-sdk/infra-runtime.d.ts +40 -0
- package/dist/plugin-sdk/src/plugin-sdk/interactive-runtime.d.ts +3 -0
- package/dist/plugin-sdk/src/plugin-sdk/irc.d.ts +37 -0
- package/dist/plugin-sdk/src/plugin-sdk/json-store.d.ts +12 -0
- package/dist/plugin-sdk/src/plugin-sdk/keyed-async-queue.d.ts +16 -0
- package/dist/plugin-sdk/src/plugin-sdk/lazy-runtime.d.ts +1 -0
- package/dist/plugin-sdk/src/plugin-sdk/line-core.d.ts +11 -0
- package/dist/plugin-sdk/src/plugin-sdk/line.d.ts +15 -0
- package/dist/plugin-sdk/src/plugin-sdk/llm-task.d.ts +4 -0
- package/dist/plugin-sdk/src/plugin-sdk/lobster.d.ts +3 -0
- package/dist/plugin-sdk/src/plugin-sdk/matrix-runtime-heavy.d.ts +4 -0
- package/dist/plugin-sdk/src/plugin-sdk/matrix-runtime-shared.d.ts +6 -0
- package/dist/plugin-sdk/src/plugin-sdk/matrix.d.ts +65 -0
- package/dist/plugin-sdk/src/plugin-sdk/mattermost.d.ts +49 -0
- package/dist/plugin-sdk/src/plugin-sdk/media-runtime.d.ts +22 -0
- package/dist/plugin-sdk/src/plugin-sdk/media-understanding-runtime.d.ts +1 -0
- package/dist/plugin-sdk/src/plugin-sdk/media-understanding.d.ts +4 -0
- package/dist/plugin-sdk/src/plugin-sdk/memory-core.d.ts +3 -0
- package/dist/plugin-sdk/src/plugin-sdk/memory-lancedb.d.ts +2 -0
- package/dist/plugin-sdk/src/plugin-sdk/msteams.d.ts +57 -0
- package/dist/plugin-sdk/src/plugin-sdk/nextcloud-talk.d.ts +41 -0
- package/dist/plugin-sdk/src/plugin-sdk/nostr.d.ts +17 -0
- package/dist/plugin-sdk/src/plugin-sdk/oauth-utils.d.ts +7 -0
- package/dist/plugin-sdk/src/plugin-sdk/ollama-setup.d.ts +3 -0
- package/dist/plugin-sdk/src/plugin-sdk/open-prose.d.ts +2 -0
- package/dist/plugin-sdk/src/plugin-sdk/optional-channel-setup.d.ts +11 -0
- package/dist/plugin-sdk/src/plugin-sdk/outbound-media.d.ts +6 -0
- package/dist/plugin-sdk/src/plugin-sdk/outbound-runtime.d.ts +3 -0
- package/dist/plugin-sdk/src/plugin-sdk/pairing-access.d.ts +19 -0
- package/dist/plugin-sdk/src/plugin-sdk/persistent-dedupe.d.ts +22 -0
- package/dist/plugin-sdk/src/plugin-sdk/phone-control.d.ts +2 -0
- package/dist/plugin-sdk/src/plugin-sdk/plugin-entry.d.ts +20 -0
- package/dist/plugin-sdk/src/plugin-sdk/plugin-runtime.d.ts +7 -0
- package/dist/plugin-sdk/src/plugin-sdk/process-runtime.d.ts +1 -0
- package/dist/plugin-sdk/src/plugin-sdk/provider-auth-api-key.d.ts +7 -0
- package/dist/plugin-sdk/src/plugin-sdk/provider-auth-login.d.ts +27 -0
- package/dist/plugin-sdk/src/plugin-sdk/provider-auth-login.runtime.d.ts +3 -0
- package/dist/plugin-sdk/src/plugin-sdk/provider-auth-result.d.ts +15 -0
- package/dist/plugin-sdk/src/plugin-sdk/provider-auth.d.ts +22 -0
- package/dist/plugin-sdk/src/plugin-sdk/provider-catalog.d.ts +2 -0
- package/dist/plugin-sdk/src/plugin-sdk/provider-env-vars.d.ts +1 -0
- package/dist/plugin-sdk/src/plugin-sdk/provider-google.d.ts +2 -0
- package/dist/plugin-sdk/src/plugin-sdk/provider-models.d.ts +31 -0
- package/dist/plugin-sdk/src/plugin-sdk/provider-onboard.d.ts +5 -0
- package/dist/plugin-sdk/src/plugin-sdk/provider-setup.d.ts +5 -0
- package/dist/plugin-sdk/src/plugin-sdk/provider-stream.d.ts +7 -0
- package/dist/plugin-sdk/src/plugin-sdk/provider-tools.d.ts +3 -0
- package/dist/plugin-sdk/src/plugin-sdk/provider-usage.d.ts +4 -0
- package/dist/plugin-sdk/src/plugin-sdk/provider-web-search.d.ts +18 -0
- package/dist/plugin-sdk/src/plugin-sdk/provider-zai-endpoint.d.ts +1 -0
- package/dist/plugin-sdk/src/plugin-sdk/reply-history.d.ts +3 -0
- package/dist/plugin-sdk/src/plugin-sdk/reply-payload.d.ts +164 -0
- package/dist/plugin-sdk/src/plugin-sdk/reply-runtime.d.ts +20 -0
- package/dist/plugin-sdk/src/plugin-sdk/request-url.d.ts +2 -0
- package/dist/plugin-sdk/src/plugin-sdk/resolution-notes.d.ts +5 -0
- package/dist/plugin-sdk/src/plugin-sdk/routing.d.ts +8 -0
- package/dist/plugin-sdk/src/plugin-sdk/run-command.d.ts +13 -0
- package/dist/plugin-sdk/src/plugin-sdk/runtime-env.d.ts +6 -0
- package/dist/plugin-sdk/src/plugin-sdk/runtime-store.d.ts +8 -0
- package/dist/plugin-sdk/src/plugin-sdk/runtime.d.ts +28 -0
- package/dist/plugin-sdk/src/plugin-sdk/sandbox.d.ts +5 -0
- package/dist/plugin-sdk/src/plugin-sdk/secret-input-runtime.d.ts +1 -0
- package/dist/plugin-sdk/src/plugin-sdk/secret-input-schema.d.ts +15 -0
- package/dist/plugin-sdk/src/plugin-sdk/secret-input.d.ts +31 -0
- package/dist/plugin-sdk/src/plugin-sdk/security-runtime.d.ts +4 -0
- package/dist/plugin-sdk/src/plugin-sdk/self-hosted-provider-setup.d.ts +3 -0
- package/dist/plugin-sdk/src/plugin-sdk/setup-adapter-runtime.d.ts +1 -0
- package/dist/plugin-sdk/src/plugin-sdk/setup-runtime.d.ts +9 -0
- package/dist/plugin-sdk/src/plugin-sdk/setup-tools.d.ts +4 -0
- package/dist/plugin-sdk/src/plugin-sdk/setup.d.ts +21 -0
- package/dist/plugin-sdk/src/plugin-sdk/signal-core.d.ts +8 -0
- package/dist/plugin-sdk/src/plugin-sdk/signal.d.ts +23 -0
- package/dist/plugin-sdk/src/plugin-sdk/slack-core.d.ts +6 -0
- package/dist/plugin-sdk/src/plugin-sdk/slack-targets.d.ts +1 -0
- package/dist/plugin-sdk/src/plugin-sdk/slack.d.ts +26 -0
- package/dist/plugin-sdk/src/plugin-sdk/speech-runtime.d.ts +1 -0
- package/dist/plugin-sdk/src/plugin-sdk/speech.d.ts +5 -0
- package/dist/plugin-sdk/src/plugin-sdk/ssrf-policy.d.ts +20 -0
- package/dist/plugin-sdk/src/plugin-sdk/ssrf-runtime.d.ts +2 -0
- package/dist/plugin-sdk/src/plugin-sdk/state-paths.d.ts +1 -0
- package/dist/plugin-sdk/src/plugin-sdk/status-helpers.d.ts +145 -0
- package/dist/plugin-sdk/src/plugin-sdk/talk-voice.d.ts +2 -0
- package/dist/plugin-sdk/src/plugin-sdk/telegram-core.d.ts +8 -0
- package/dist/plugin-sdk/src/plugin-sdk/telegram.d.ts +1 -0
- package/dist/plugin-sdk/src/plugin-sdk/temp-path.d.ts +14 -0
- package/dist/plugin-sdk/src/plugin-sdk/test-utils.d.ts +1 -0
- package/dist/plugin-sdk/src/plugin-sdk/testing.d.ts +26 -0
- package/dist/plugin-sdk/src/plugin-sdk/text-chunking.d.ts +2 -0
- package/dist/plugin-sdk/src/plugin-sdk/text-runtime.d.ts +22 -0
- package/dist/plugin-sdk/src/plugin-sdk/thread-bindings-runtime.d.ts +2 -0
- package/dist/plugin-sdk/src/plugin-sdk/thread-ownership.d.ts +3 -0
- package/dist/plugin-sdk/src/plugin-sdk/tlon.d.ts +21 -0
- package/dist/plugin-sdk/src/plugin-sdk/tool-send.d.ts +7 -0
- package/dist/plugin-sdk/src/plugin-sdk/twitch.d.ts +18 -0
- package/dist/plugin-sdk/src/plugin-sdk/voice-call.d.ts +9 -0
- package/dist/plugin-sdk/src/plugin-sdk/web-media.d.ts +1 -0
- package/dist/plugin-sdk/src/plugin-sdk/webhook-ingress.d.ts +4 -0
- package/dist/plugin-sdk/src/plugin-sdk/webhook-memory-guards.d.ts +52 -0
- package/dist/plugin-sdk/src/plugin-sdk/webhook-path.d.ts +8 -0
- package/dist/plugin-sdk/src/plugin-sdk/webhook-request-guards.d.ts +89 -0
- package/dist/plugin-sdk/src/plugin-sdk/webhook-targets.d.ts +97 -0
- package/dist/plugin-sdk/src/plugin-sdk/whatsapp-action-runtime.d.ts +1 -0
- package/dist/plugin-sdk/src/plugin-sdk/whatsapp-core.d.ts +10 -0
- package/dist/plugin-sdk/src/plugin-sdk/whatsapp-login-qr.d.ts +1 -0
- package/dist/plugin-sdk/src/plugin-sdk/whatsapp-shared.d.ts +6 -0
- package/dist/plugin-sdk/src/plugin-sdk/whatsapp.d.ts +31 -0
- package/dist/plugin-sdk/src/plugin-sdk/windows-spawn.d.ts +44 -0
- package/dist/plugin-sdk/src/plugin-sdk/zai.d.ts +1 -0
- package/dist/plugin-sdk/src/plugin-sdk/zalo.d.ts +46 -0
- package/dist/plugin-sdk/src/plugin-sdk/zalouser.d.ts +39 -0
- package/dist/plugin-sdk/src/plugins/bundle-commands.d.ts +12 -0
- package/dist/plugin-sdk/src/plugins/bundle-lsp.d.ts +27 -0
- package/dist/plugin-sdk/src/plugins/bundle-manifest.d.ts +32 -0
- package/dist/plugin-sdk/src/plugins/bundle-mcp.d.ts +30 -0
- package/dist/plugin-sdk/src/plugins/bundled-compat.d.ts +9 -0
- package/dist/plugin-sdk/src/plugins/bundled-dir.d.ts +1 -0
- package/dist/plugin-sdk/src/plugins/bundled-provider-auth-env-vars.d.ts +1 -0
- package/dist/plugin-sdk/src/plugins/bundled-provider-auth-env-vars.generated.d.ts +40 -0
- package/dist/plugin-sdk/src/plugins/bundled-web-search-ids.d.ts +2 -0
- package/dist/plugin-sdk/src/plugins/bundled-web-search.d.ts +10 -0
- package/dist/plugin-sdk/src/plugins/captured-registration.d.ts +14 -0
- package/dist/plugin-sdk/src/plugins/commands.d.ts +111 -0
- package/dist/plugin-sdk/src/plugins/config-schema.d.ts +2 -0
- package/dist/plugin-sdk/src/plugins/config-state.d.ts +53 -0
- package/dist/plugin-sdk/src/plugins/conversation-binding.d.ts +89 -0
- package/dist/plugin-sdk/src/plugins/discovery.d.ts +30 -0
- package/dist/plugin-sdk/src/plugins/enable.d.ts +7 -0
- package/dist/plugin-sdk/src/plugins/hook-runner-global.d.ts +37 -0
- package/dist/plugin-sdk/src/plugins/hooks.d.ts +70 -0
- package/dist/plugin-sdk/src/plugins/http-path.d.ts +1 -0
- package/dist/plugin-sdk/src/plugins/http-registry.d.ts +16 -0
- package/dist/plugin-sdk/src/plugins/http-route-overlap.d.ts +11 -0
- package/dist/plugin-sdk/src/plugins/interactive-dispatch-adapters.d.ts +44 -0
- package/dist/plugin-sdk/src/plugins/interactive.d.ts +60 -0
- package/dist/plugin-sdk/src/plugins/loader.d.ts +47 -0
- package/dist/plugin-sdk/src/plugins/logger.d.ts +9 -0
- package/dist/plugin-sdk/src/plugins/manifest-registry.d.ts +49 -0
- package/dist/plugin-sdk/src/plugins/manifest.d.ts +119 -0
- package/dist/plugin-sdk/src/plugins/path-safety.d.ts +5 -0
- package/dist/plugin-sdk/src/plugins/provider-api-key-auth.d.ts +24 -0
- package/dist/plugin-sdk/src/plugins/provider-api-key-auth.runtime.d.ts +11 -0
- package/dist/plugin-sdk/src/plugins/provider-auth-helpers.d.ts +25 -0
- package/dist/plugin-sdk/src/plugins/provider-auth-input.d.ts +49 -0
- package/dist/plugin-sdk/src/plugins/provider-auth-mode.d.ts +14 -0
- package/dist/plugin-sdk/src/plugins/provider-auth-ref.d.ts +32 -0
- package/dist/plugin-sdk/src/plugins/provider-auth-token.d.ts +9 -0
- package/dist/plugin-sdk/src/plugins/provider-auth-types.d.ts +1 -0
- package/dist/plugin-sdk/src/plugins/provider-catalog-metadata.d.ts +6 -0
- package/dist/plugin-sdk/src/plugins/provider-catalog.d.ts +24 -0
- package/dist/plugin-sdk/src/plugins/provider-discovery.d.ts +37 -0
- package/dist/plugin-sdk/src/plugins/provider-model-allowlist.d.ts +6 -0
- package/dist/plugin-sdk/src/plugins/provider-model-defaults.d.ts +19 -0
- package/dist/plugin-sdk/src/plugins/provider-model-definitions.d.ts +107 -0
- package/dist/plugin-sdk/src/plugins/provider-model-helpers.d.ts +8 -0
- package/dist/plugin-sdk/src/plugins/provider-model-primary.d.ts +12 -0
- package/dist/plugin-sdk/src/plugins/provider-oauth-flow.d.ts +20 -0
- package/dist/plugin-sdk/src/plugins/provider-ollama-setup.d.ts +32 -0
- package/dist/plugin-sdk/src/plugins/provider-onboarding-config.d.ts +62 -0
- package/dist/plugin-sdk/src/plugins/provider-openai-codex-oauth-tls.d.ts +22 -0
- package/dist/plugin-sdk/src/plugins/provider-openai-codex-oauth.d.ts +10 -0
- package/dist/plugin-sdk/src/plugins/provider-runtime.d.ts +154 -0
- package/dist/plugin-sdk/src/plugins/provider-runtime.runtime.d.ts +1 -0
- package/dist/plugin-sdk/src/plugins/provider-self-hosted-setup.d.ts +51 -0
- package/dist/plugin-sdk/src/plugins/provider-thinking.d.ts +9 -0
- package/dist/plugin-sdk/src/plugins/provider-validation.d.ts +7 -0
- package/dist/plugin-sdk/src/plugins/provider-vllm-setup.d.ts +21 -0
- package/dist/plugin-sdk/src/plugins/provider-zai-endpoint.d.ts +16 -0
- package/dist/plugin-sdk/src/plugins/providers.d.ts +40 -0
- package/dist/plugin-sdk/src/plugins/registry-empty.d.ts +2 -0
- package/dist/plugin-sdk/src/plugins/registry.d.ts +191 -0
- package/dist/plugin-sdk/src/plugins/roots.d.ts +18 -0
- package/dist/plugin-sdk/src/plugins/runtime/gateway-request-scope.d.ts +19 -0
- package/dist/plugin-sdk/src/plugins/runtime/index.d.ts +19 -0
- package/dist/plugin-sdk/src/plugins/runtime/native-deps.d.ts +8 -0
- package/dist/plugin-sdk/src/plugins/runtime/runtime-agent.d.ts +2 -0
- package/dist/plugin-sdk/src/plugins/runtime/runtime-channel.d.ts +2 -0
- package/dist/plugin-sdk/src/plugins/runtime/runtime-config.d.ts +2 -0
- package/dist/plugin-sdk/src/plugins/runtime/runtime-discord-ops.runtime.d.ts +25 -0
- package/dist/plugin-sdk/src/plugins/runtime/runtime-discord-typing.d.ts +15 -0
- package/dist/plugin-sdk/src/plugins/runtime/runtime-discord.d.ts +2 -0
- package/dist/plugin-sdk/src/plugins/runtime/runtime-events.d.ts +2 -0
- package/dist/plugin-sdk/src/plugins/runtime/runtime-imessage.d.ts +2 -0
- package/dist/plugin-sdk/src/plugins/runtime/runtime-logging.d.ts +2 -0
- package/dist/plugin-sdk/src/plugins/runtime/runtime-matrix-boundary.d.ts +4 -0
- package/dist/plugin-sdk/src/plugins/runtime/runtime-matrix.d.ts +2 -0
- package/dist/plugin-sdk/src/plugins/runtime/runtime-media.d.ts +2 -0
- package/dist/plugin-sdk/src/plugins/runtime/runtime-signal.d.ts +2 -0
- package/dist/plugin-sdk/src/plugins/runtime/runtime-slack-ops.runtime.d.ts +11 -0
- package/dist/plugin-sdk/src/plugins/runtime/runtime-slack.d.ts +2 -0
- package/dist/plugin-sdk/src/plugins/runtime/runtime-system.d.ts +2 -0
- package/dist/plugin-sdk/src/plugins/runtime/runtime-telegram-contract.d.ts +41 -0
- package/dist/plugin-sdk/src/plugins/runtime/runtime-telegram-ops.runtime.d.ts +20 -0
- package/dist/plugin-sdk/src/plugins/runtime/runtime-telegram-typing.d.ts +18 -0
- package/dist/plugin-sdk/src/plugins/runtime/runtime-telegram.d.ts +2 -0
- package/dist/plugin-sdk/src/plugins/runtime/runtime-tools.d.ts +2 -0
- package/dist/plugin-sdk/src/plugins/runtime/runtime-whatsapp-boundary.d.ts +35 -0
- package/dist/plugin-sdk/src/plugins/runtime/runtime-whatsapp-login-tool.d.ts +1 -0
- package/dist/plugin-sdk/src/plugins/runtime/runtime-whatsapp.d.ts +2 -0
- package/dist/plugin-sdk/src/plugins/runtime/types-channel.d.ts +242 -0
- package/dist/plugin-sdk/src/plugins/runtime/types-core.d.ts +100 -0
- package/dist/plugin-sdk/src/plugins/runtime/types.d.ts +50 -0
- package/dist/plugin-sdk/src/plugins/runtime.d.ts +12 -0
- package/dist/plugin-sdk/src/plugins/schema-validator.d.ts +17 -0
- package/dist/plugin-sdk/src/plugins/sdk-alias.d.ts +47 -0
- package/dist/plugin-sdk/src/plugins/setup-binary.d.ts +1 -0
- package/dist/plugin-sdk/src/plugins/setup-browser.d.ts +2 -0
- package/dist/plugin-sdk/src/plugins/signal-cli-install.d.ts +30 -0
- package/dist/plugin-sdk/src/plugins/slots.d.ts +24 -0
- package/dist/plugin-sdk/src/plugins/status.d.ts +97 -0
- package/dist/plugin-sdk/src/plugins/toggle-config.d.ts +2 -0
- package/dist/plugin-sdk/src/plugins/tools.d.ts +16 -0
- package/dist/plugin-sdk/src/plugins/types.d.ts +1566 -0
- package/dist/plugin-sdk/src/plugins/web-search-providers.d.ts +9 -0
- package/dist/plugin-sdk/src/plugins/web-search-providers.runtime.d.ts +16 -0
- package/dist/plugin-sdk/src/plugins/web-search-providers.shared.d.ts +13 -0
- package/dist/plugin-sdk/src/poll-params.d.ts +42 -0
- package/dist/plugin-sdk/src/polls.d.ts +32 -0
- package/dist/plugin-sdk/src/process/command-queue.d.ts +63 -0
- package/dist/plugin-sdk/src/process/exec.d.ts +36 -0
- package/dist/plugin-sdk/src/process/kill-tree.d.ts +12 -0
- package/dist/plugin-sdk/src/process/lanes.d.ts +6 -0
- package/dist/plugin-sdk/src/process/spawn-utils.d.ts +26 -0
- package/dist/plugin-sdk/src/process/supervisor/adapters/child.d.ts +10 -0
- package/dist/plugin-sdk/src/process/supervisor/adapters/env.d.ts +1 -0
- package/dist/plugin-sdk/src/process/supervisor/adapters/pty.d.ts +11 -0
- package/dist/plugin-sdk/src/process/supervisor/index.d.ts +4 -0
- package/dist/plugin-sdk/src/process/supervisor/registry.d.ts +21 -0
- package/dist/plugin-sdk/src/process/supervisor/supervisor.d.ts +2 -0
- package/dist/plugin-sdk/src/process/supervisor/types.d.ts +92 -0
- package/dist/plugin-sdk/src/process/windows-command.d.ts +5 -0
- package/dist/plugin-sdk/src/providers/github-copilot-auth.d.ts +5 -0
- package/dist/plugin-sdk/src/providers/kilocode-shared.d.ts +27 -0
- package/dist/plugin-sdk/src/providers/openai-defaults.d.ts +7 -0
- package/dist/plugin-sdk/src/routing/account-id.d.ts +3 -0
- package/dist/plugin-sdk/src/routing/account-lookup.d.ts +1 -0
- package/dist/plugin-sdk/src/routing/bindings.d.ts +11 -0
- package/dist/plugin-sdk/src/routing/default-account-warnings.d.ts +6 -0
- package/dist/plugin-sdk/src/routing/resolve-route.d.ts +53 -0
- package/dist/plugin-sdk/src/routing/session-key.d.ts +52 -0
- package/dist/plugin-sdk/src/runtime.d.ts +7 -0
- package/dist/plugin-sdk/src/secrets/command-config.d.ts +35 -0
- package/dist/plugin-sdk/src/secrets/json-pointer.d.ts +6 -0
- package/dist/plugin-sdk/src/secrets/path-utils.d.ts +5 -0
- package/dist/plugin-sdk/src/secrets/provider-env-vars.d.ts +21 -0
- package/dist/plugin-sdk/src/secrets/ref-contract.d.ts +33 -0
- package/dist/plugin-sdk/src/secrets/resolve-secret-input-string.d.ts +12 -0
- package/dist/plugin-sdk/src/secrets/resolve.d.ts +40 -0
- package/dist/plugin-sdk/src/secrets/runtime-auth-collectors.d.ts +7 -0
- package/dist/plugin-sdk/src/secrets/runtime-config-collectors-channels.d.ts +7 -0
- package/dist/plugin-sdk/src/secrets/runtime-config-collectors-core.d.ts +7 -0
- package/dist/plugin-sdk/src/secrets/runtime-config-collectors-tts.d.ts +9 -0
- package/dist/plugin-sdk/src/secrets/runtime-config-collectors.d.ts +6 -0
- package/dist/plugin-sdk/src/secrets/runtime-gateway-auth-surfaces.d.ts +16 -0
- package/dist/plugin-sdk/src/secrets/runtime-shared.d.ts +52 -0
- package/dist/plugin-sdk/src/secrets/runtime-web-tools.d.ts +9 -0
- package/dist/plugin-sdk/src/secrets/runtime-web-tools.types.d.ts +26 -0
- package/dist/plugin-sdk/src/secrets/runtime.d.ts +34 -0
- package/dist/plugin-sdk/src/secrets/secret-value.d.ts +8 -0
- package/dist/plugin-sdk/src/secrets/shared.d.ts +11 -0
- package/dist/plugin-sdk/src/secrets/target-registry-data.d.ts +3 -0
- package/dist/plugin-sdk/src/secrets/target-registry-pattern.d.ts +28 -0
- package/dist/plugin-sdk/src/secrets/target-registry-query.d.ts +18 -0
- package/dist/plugin-sdk/src/secrets/target-registry-types.d.ts +39 -0
- package/dist/plugin-sdk/src/secrets/target-registry.d.ts +1 -0
- package/dist/plugin-sdk/src/security/audit-fs.d.ts +44 -0
- package/dist/plugin-sdk/src/security/channel-metadata.d.ts +6 -0
- package/dist/plugin-sdk/src/security/config-regex.d.ts +22 -0
- package/dist/plugin-sdk/src/security/dm-policy-shared.d.ts +92 -0
- package/dist/plugin-sdk/src/security/external-content.d.ts +58 -0
- package/dist/plugin-sdk/src/security/safe-regex.d.ts +16 -0
- package/dist/plugin-sdk/src/security/scan-paths.d.ts +5 -0
- package/dist/plugin-sdk/src/security/secret-equal.d.ts +1 -0
- package/dist/plugin-sdk/src/security/windows-acl.d.ts +37 -0
- package/dist/plugin-sdk/src/sessions/input-provenance.d.ts +17 -0
- package/dist/plugin-sdk/src/sessions/level-overrides.d.ts +10 -0
- package/dist/plugin-sdk/src/sessions/model-overrides.d.ts +14 -0
- package/dist/plugin-sdk/src/sessions/send-policy.d.ts +11 -0
- package/dist/plugin-sdk/src/sessions/session-id-resolution.d.ts +2 -0
- package/dist/plugin-sdk/src/sessions/session-id.d.ts +2 -0
- package/dist/plugin-sdk/src/sessions/session-key-utils.d.ts +20 -0
- package/dist/plugin-sdk/src/sessions/session-label.d.ts +9 -0
- package/dist/plugin-sdk/src/sessions/session-lifecycle-events.d.ts +11 -0
- package/dist/plugin-sdk/src/sessions/transcript-events.d.ts +10 -0
- package/dist/plugin-sdk/src/shared/assistant-error-format.d.ts +16 -0
- package/dist/plugin-sdk/src/shared/avatar-policy.d.ts +16 -0
- package/dist/plugin-sdk/src/shared/chat-content.d.ts +5 -0
- package/dist/plugin-sdk/src/shared/chat-envelope.d.ts +2 -0
- package/dist/plugin-sdk/src/shared/config-eval.d.ts +26 -0
- package/dist/plugin-sdk/src/shared/device-auth-store.d.ts +23 -0
- package/dist/plugin-sdk/src/shared/device-auth.d.ts +13 -0
- package/dist/plugin-sdk/src/shared/frontmatter.d.ts +29 -0
- package/dist/plugin-sdk/src/shared/gateway-bind-url.d.ts +14 -0
- package/dist/plugin-sdk/src/shared/global-singleton.d.ts +2 -0
- package/dist/plugin-sdk/src/shared/lazy-runtime.d.ts +7 -0
- package/dist/plugin-sdk/src/shared/net/ip.d.ts +20 -0
- package/dist/plugin-sdk/src/shared/net/url-userinfo.d.ts +1 -0
- package/dist/plugin-sdk/src/shared/node-list-parse.d.ts +3 -0
- package/dist/plugin-sdk/src/shared/node-list-types.d.ts +48 -0
- package/dist/plugin-sdk/src/shared/node-match.d.ts +9 -0
- package/dist/plugin-sdk/src/shared/node-resolve.d.ts +8 -0
- package/dist/plugin-sdk/src/shared/operator-scope-compat.d.ts +10 -0
- package/dist/plugin-sdk/src/shared/pid-alive.d.ts +10 -0
- package/dist/plugin-sdk/src/shared/process-scoped-map.d.ts +1 -0
- package/dist/plugin-sdk/src/shared/session-types.d.ts +25 -0
- package/dist/plugin-sdk/src/shared/session-usage-timeseries-types.d.ts +15 -0
- package/dist/plugin-sdk/src/shared/string-normalization.d.ts +4 -0
- package/dist/plugin-sdk/src/shared/string-sample.d.ts +5 -0
- package/dist/plugin-sdk/src/shared/subagents-format.d.ts +15 -0
- package/dist/plugin-sdk/src/shared/tailscale-status.d.ts +8 -0
- package/dist/plugin-sdk/src/shared/text/assistant-visible-text.d.ts +1 -0
- package/dist/plugin-sdk/src/shared/text/auto-linked-file-ref.d.ts +2 -0
- package/dist/plugin-sdk/src/shared/text/code-regions.d.ts +6 -0
- package/dist/plugin-sdk/src/shared/text/join-segments.d.ts +9 -0
- package/dist/plugin-sdk/src/shared/text/reasoning-tags.d.ts +6 -0
- package/dist/plugin-sdk/src/shared/text-chunking.d.ts +1 -0
- package/dist/plugin-sdk/src/terminal/ansi.d.ts +9 -0
- package/dist/plugin-sdk/src/terminal/health-style.d.ts +1 -0
- package/dist/plugin-sdk/src/terminal/links.d.ts +6 -0
- package/dist/plugin-sdk/src/terminal/note.d.ts +5 -0
- package/dist/plugin-sdk/src/terminal/palette.d.ts +10 -0
- package/dist/plugin-sdk/src/terminal/progress-line.d.ts +3 -0
- package/dist/plugin-sdk/src/terminal/prompt-style.d.ts +3 -0
- package/dist/plugin-sdk/src/terminal/restore.d.ts +17 -0
- package/dist/plugin-sdk/src/terminal/safe-text.d.ts +4 -0
- package/dist/plugin-sdk/src/terminal/theme.d.ts +15 -0
- package/dist/plugin-sdk/src/test-utils/vitest-mock-fn.d.ts +1 -0
- package/dist/plugin-sdk/src/tts/provider-registry.d.ts +6 -0
- package/dist/plugin-sdk/src/tts/provider-types.d.ts +46 -0
- package/dist/plugin-sdk/src/tts/providers/elevenlabs.d.ts +7 -0
- package/dist/plugin-sdk/src/tts/providers/microsoft.d.ts +4 -0
- package/dist/plugin-sdk/src/tts/providers/openai.d.ts +2 -0
- package/dist/plugin-sdk/src/tts/runtime.d.ts +1 -0
- package/dist/plugin-sdk/src/tts/tts-core.d.ts +57 -0
- package/dist/plugin-sdk/src/tts/tts.d.ts +216 -0
- package/dist/plugin-sdk/src/utils/account-id.d.ts +1 -0
- package/dist/plugin-sdk/src/utils/boolean.d.ts +5 -0
- package/dist/plugin-sdk/src/utils/chunk-items.d.ts +1 -0
- package/dist/plugin-sdk/src/utils/delivery-context.d.ts +42 -0
- package/dist/plugin-sdk/src/utils/directive-tags.d.ts +29 -0
- package/dist/plugin-sdk/src/utils/fetch-timeout.d.ts +13 -0
- package/dist/plugin-sdk/src/utils/mask-api-key.d.ts +1 -0
- package/dist/plugin-sdk/src/utils/message-channel.d.ts +27 -0
- package/dist/plugin-sdk/src/utils/normalize-secret-input.d.ts +17 -0
- package/dist/plugin-sdk/src/utils/parse-json-compat.d.ts +1 -0
- package/dist/plugin-sdk/src/utils/provider-utils.d.ts +9 -0
- package/dist/plugin-sdk/src/utils/queue-helpers.d.ts +80 -0
- package/dist/plugin-sdk/src/utils/reaction-level.d.ts +15 -0
- package/dist/plugin-sdk/src/utils/run-with-concurrency.d.ts +11 -0
- package/dist/plugin-sdk/src/utils/safe-json.d.ts +1 -0
- package/dist/plugin-sdk/src/utils/shell-argv.d.ts +1 -0
- package/dist/plugin-sdk/src/utils/transcript-tools.d.ts +8 -0
- package/dist/plugin-sdk/src/utils/usage-format.d.ts +27 -0
- package/dist/plugin-sdk/src/utils/with-timeout.d.ts +1 -0
- package/dist/plugin-sdk/src/utils.d.ts +61 -0
- package/dist/plugin-sdk/src/version.d.ts +16 -0
- package/dist/plugin-sdk/src/web-search/runtime.d.ts +46 -0
- package/dist/plugin-sdk/src/whatsapp/normalize.d.ts +6 -0
- package/dist/plugin-sdk/src/whatsapp/resolve-outbound-target.d.ts +12 -0
- package/dist/plugin-sdk/src/wizard/prompts.d.ts +43 -0
- package/dist/plugin-sdk/src/wizard/session.d.ts +42 -0
- package/dist/plugin-sdk/ssrf-runtime.d.ts +1 -0
- package/dist/plugin-sdk/ssrf-runtime.js +5 -0
- package/dist/plugin-sdk/state-paths.d.ts +1 -0
- package/dist/plugin-sdk/state-paths.js +3 -0
- package/dist/plugin-sdk/status-helpers.d.ts +1 -0
- package/dist/plugin-sdk/status-helpers.js +9 -0
- package/dist/plugin-sdk/telegram-core.d.ts +1 -0
- package/dist/plugin-sdk/telegram-core.js +23 -0
- package/dist/plugin-sdk/telegram.d.ts +1 -0
- package/dist/plugin-sdk/telegram.js +224 -0
- package/dist/plugin-sdk/testing.d.ts +1 -0
- package/dist/plugin-sdk/testing.js +13174 -0
- package/dist/plugin-sdk/text-runtime.d.ts +1 -0
- package/dist/plugin-sdk/text-runtime.js +45 -0
- package/dist/plugin-sdk/thread-bindings-runtime.d.ts +1 -0
- package/dist/plugin-sdk/thread-bindings-runtime.js +2 -0
- package/dist/plugin-sdk/thread-ownership.d.ts +1 -0
- package/dist/plugin-sdk/thread-ownership.js +2 -0
- package/dist/plugin-sdk/tlon.d.ts +1 -0
- package/dist/plugin-sdk/tlon.js +57 -0
- package/dist/plugin-sdk/tool-send.d.ts +1 -0
- package/dist/plugin-sdk/tool-send.js +2 -0
- package/dist/plugin-sdk/twitch.d.ts +1 -0
- package/dist/plugin-sdk/twitch.js +46 -0
- package/dist/plugin-sdk/voice-call.d.ts +1 -0
- package/dist/plugin-sdk/voice-call.js +213 -0
- package/dist/plugin-sdk/web-media.d.ts +1 -0
- package/dist/plugin-sdk/web-media.js +28 -0
- package/dist/plugin-sdk/webhook-ingress.d.ts +1 -0
- package/dist/plugin-sdk/webhook-ingress.js +7 -0
- package/dist/plugin-sdk/webhook-path.d.ts +1 -0
- package/dist/plugin-sdk/webhook-path.js +29 -0
- package/dist/plugin-sdk/whatsapp-core.d.ts +1 -0
- package/dist/plugin-sdk/whatsapp-core.js +219 -0
- package/dist/plugin-sdk/whatsapp-shared.d.ts +1 -0
- package/dist/plugin-sdk/whatsapp-shared.js +18 -0
- package/dist/plugin-sdk/windows-spawn.d.ts +1 -0
- package/dist/plugin-sdk/windows-spawn.js +2 -0
- package/dist/plugin-sdk/zalo.d.ts +1 -0
- package/dist/plugin-sdk/zalo.js +239 -0
- package/dist/plugin-sdk/zalouser.d.ts +1 -0
- package/dist/plugin-sdk/zalouser.js +240 -0
- package/dist/plugins/build-smoke-entry.js +211 -0
- package/dist/plugins/runtime/index.js +229 -0
- package/dist/plugins-1Z50ecJ6.js +1 -0
- package/dist/plugins-C6fKmNuA.js +7 -0
- package/dist/plugins-cli-C9F7LFai.js +1192 -0
- package/dist/policy-CpkbSAfm.js +60 -0
- package/dist/polls-B2VH7SN9.js +35 -0
- package/dist/ports-BjWuIIQw.js +262 -0
- package/dist/ports-bjxjgHBT.js +385 -0
- package/dist/ports-lsof-DtJqhFOr.js +25 -0
- package/dist/ports-probe-BQqp8l8E.js +14 -0
- package/dist/preflight-audio.runtime-CHKtYFCD.js +216 -0
- package/dist/probe-B4addlGb.js +20 -0
- package/dist/probe-DEHTy47Q.js +134 -0
- package/dist/probe-auth-f8H5asG2.js +45 -0
- package/dist/probe-auth-w1LTAARt.js +48 -0
- package/dist/process-runtime-C7el-Ri4.js +1 -0
- package/dist/process-scoped-map-C4gOa-gv.js +61 -0
- package/dist/profile-utils-BcMYGFPT.js +15 -0
- package/dist/profiles-D17eMKQZ.js +683 -0
- package/dist/program-7yuBUzsM.js +155 -0
- package/dist/program-context-BMWNUfqL.js +10 -0
- package/dist/program-context-CD_RvRYh.js +2 -0
- package/dist/progress-D1r9bZU1.js +132 -0
- package/dist/prompt-select-styled-nNVADeGF.js +4879 -0
- package/dist/prompt-style-BvciNCqy.js +7 -0
- package/dist/prompts-NtuylUyl.js +9 -0
- package/dist/prototype-keys-Cm_8mWvq.js +11 -0
- package/dist/provider-api-key-auth-BE0taXiB.js +108 -0
- package/dist/provider-api-key-auth.runtime-jDZZUAMX.js +34 -0
- package/dist/provider-auth-Bw8x1a3o.js +58 -0
- package/dist/provider-auth-api-key-BrQYvdxi.js +1 -0
- package/dist/provider-auth-choice-CHLyhQwI.js +128 -0
- package/dist/provider-auth-choice-helpers-Bj1GkOSn.js +48 -0
- package/dist/provider-auth-choice-preference-DlolknHt.js +192 -0
- package/dist/provider-auth-choice.runtime-unOg_4AL.js +223 -0
- package/dist/provider-auth-choices-QSilukI1.js +58 -0
- package/dist/provider-auth-guidance-7WCTw6mb.js +34 -0
- package/dist/provider-auth-helpers-B0dS-1WK.js +86 -0
- package/dist/provider-auth-input-BftBdgvW.js +112 -0
- package/dist/provider-auth-login-MdVTo3EF.js +8 -0
- package/dist/provider-auth-login.runtime-CmHgk5FU.js +243 -0
- package/dist/provider-auth-mode-sTdccIKL.js +20 -0
- package/dist/provider-auth-ref-BS3gwrNr.js +168 -0
- package/dist/provider-auth-ref-BmEcEN7K.js +3 -0
- package/dist/provider-catalog--18-pW5t.js +11 -0
- package/dist/provider-catalog-2P2hel74.js +48 -0
- package/dist/provider-catalog-B0FqWSwe.js +48 -0
- package/dist/provider-catalog-BvORKzzD.js +91 -0
- package/dist/provider-catalog-C34j1_or.js +26 -0
- package/dist/provider-catalog-C5vmXjmb.js +11 -0
- package/dist/provider-catalog-CBufm2Dr.js +36 -0
- package/dist/provider-catalog-D7QvsUXS.js +12 -0
- package/dist/provider-catalog-DKy_dzQZ.js +41 -0
- package/dist/provider-env-vars-CsQlY7bF.js +110 -0
- package/dist/provider-id-BpXo5t6v.js +31 -0
- package/dist/provider-model-allowlist-4HSOnlX-.js +24 -0
- package/dist/provider-model-primary-NJ-xlhec.js +53 -0
- package/dist/provider-models-C2EjYMwW.js +2416 -0
- package/dist/provider-oauth-flow-BQN6F6EC.js +33 -0
- package/dist/provider-ollama-setup-DhQvDwAj.js +309 -0
- package/dist/provider-onboard-CjOfyeQG.js +1 -0
- package/dist/provider-onboarding-config-DOZ3pFA6.js +165 -0
- package/dist/provider-openai-codex-oauth-tls-CciH-ElI.js +101 -0
- package/dist/provider-runtime.runtime-CqLlOpNN.js +211 -0
- package/dist/provider-self-hosted-setup-CUrmsugW.js +182 -0
- package/dist/provider-usage-ClDVmkhl.js +633 -0
- package/dist/provider-usage-Da21nLuJ.js +211 -0
- package/dist/provider-web-search-D2JPMqCP.js +507 -0
- package/dist/provider-wizard-DLQlOsRE.js +236 -0
- package/dist/provider-zai-endpoint-DeDABzT4.js +106 -0
- package/dist/proxy-H5O2p6AP.js +121 -0
- package/dist/proxy-env-DG2u55RW.js +40 -0
- package/dist/push-apns-DthmTY-D.js +1050 -0
- package/dist/pw-ai-S7kXHa5n.js +1876 -0
- package/dist/qmd-manager-BpygGMW9.js +1571 -0
- package/dist/qr-cli-BujxPQbh.js +370 -0
- package/dist/qr-cli-DVmW5mdc.js +213 -0
- package/dist/query-expansion-Do45hILP.js +1114 -0
- package/dist/reactions-BlWPBR0l.js +281 -0
- package/dist/read-only-account-inspect-CuuTbX8x.js +42 -0
- package/dist/read-only-account-inspect.discord.runtime-BNqMWV41.js +216 -0
- package/dist/read-only-account-inspect.slack.runtime-CNRAytxm.js +216 -0
- package/dist/read-only-account-inspect.telegram.runtime-byPPLnsZ.js +216 -0
- package/dist/redact-BDinS1q9.js +102 -0
- package/dist/redact-identifier-FUiWQxv5.js +13 -0
- package/dist/redact-snapshot-DBPmeYy2.js +2654 -0
- package/dist/ref-contract-CCBBbf1r.js +53 -0
- package/dist/register-CppP7Ddc.js +43 -0
- package/dist/register.agent-Cy1pvUnS.js +546 -0
- package/dist/register.backup-Dxsn-Yi4.js +269 -0
- package/dist/register.configure-BOONWPZN.js +354 -0
- package/dist/register.maintenance-C_E5F3xW.js +694 -0
- package/dist/register.message-BwmuEJ7n.js +812 -0
- package/dist/register.onboard-D4Fu6BPi.js +298 -0
- package/dist/register.setup-DJYgl_5E.js +318 -0
- package/dist/register.status-health-sessions-B0KtOOEc.js +604 -0
- package/dist/register.subclis-CKJ5Qvch.js +315 -0
- package/dist/register.subclis-CcdM_H8W.js +13 -0
- package/dist/registry-C3q59Qj0.js +55 -0
- package/dist/registry-CPsHw6xU.js +219 -0
- package/dist/registry-CxgtJ09C.js +28 -0
- package/dist/registry-rgYi7KoO.js +160 -0
- package/dist/repair-qXnOAvDy.js +105 -0
- package/dist/replies-MyUi4VUF.js +122 -0
- package/dist/reply-history-CVCD5oE9.js +1 -0
- package/dist/reply-payload-DBGc074f.js +232 -0
- package/dist/report-cli-DB1jQx32.js +42 -0
- package/dist/request-url-BKfWAQx8.js +10 -0
- package/dist/resolve-Ckjd8TAk.js +14 -0
- package/dist/resolve-T2q_0ARF.js +619 -0
- package/dist/resolve-route-vEY3ONZ2.js +466 -0
- package/dist/resolve-utils-CF8cU9WO.js +102 -0
- package/dist/response-generator-VdoCcQ3y.js +153 -0
- package/dist/restart-stale-pids-CLGiqU2E.js +187 -0
- package/dist/retry-D15TD1S3.js +168 -0
- package/dist/root-help-2Fvs2dP7.js +32 -0
- package/dist/routes-LnFKW9Eh.js +7084 -0
- package/dist/routing-Y3m0o-kB.js +26 -0
- package/dist/rpc-lnQaxoYH.js +67 -0
- package/dist/run-command-DRKv5Lj6.js +32 -0
- package/dist/run-main-XmwwulYd.js +425 -0
- package/dist/run-with-concurrency-BrSjWzpg.js +41 -0
- package/dist/runtime-B66W9flm.js +43 -0
- package/dist/runtime-CT2LIJZu.js +91 -0
- package/dist/runtime-Cl6sSlDG.js +143 -0
- package/dist/runtime-CuvWMN7E.js +89 -0
- package/dist/runtime-D4_OpzA1.js +5 -0
- package/dist/runtime-DP-4DZja.js +5 -0
- package/dist/runtime-Dl17x_cV.js +1 -0
- package/dist/runtime-Dwejo3y0.js +2338 -0
- package/dist/runtime-Z35JoYPC.js +30 -0
- package/dist/runtime-api-AQf4CGN0.js +39 -0
- package/dist/runtime-api-D79M0lQN.js +1 -0
- package/dist/runtime-discord-ops.runtime-CvmUbfVm.js +234 -0
- package/dist/runtime-env-a_iwdJIv.js +1 -0
- package/dist/runtime-forwarders-DtMc8rBP.js +44 -0
- package/dist/runtime-group-policy-B7irU4eu.js +59 -0
- package/dist/runtime-guard-y62lPDGY.js +58 -0
- package/dist/runtime-parse-CeqXmZHJ.js +84 -0
- package/dist/runtime-paths-2jrzlMjr.js +334 -0
- package/dist/runtime-slack-ops.runtime-D7IhY8CD.js +226 -0
- package/dist/runtime-status-CgL02wYX.js +15 -0
- package/dist/runtime-store-Bt3Sdbrn.js +22 -0
- package/dist/runtime-telegram-ops.runtime-DMM0_L8z.js +233 -0
- package/dist/runtime-whatsapp-boundary-BE-h0Dkz.js +371 -0
- package/dist/safe-open-sync-Bt9R1Mnf.js +83 -0
- package/dist/safe-regex-tLlDZYfM.js +244 -0
- package/dist/safe-text-B_CQuica.js +16 -0
- package/dist/sandbox-Ceruxpo4.js +2795 -0
- package/dist/sandbox-cli-Bj_FeUbQ.js +499 -0
- package/dist/sandbox-paths-fqp_TZdO.js +144 -0
- package/dist/sandbox-qSs4h3sk.js +1 -0
- package/dist/sanitize-env-vars-vNSNqm0y.js +74 -0
- package/dist/scan-paths-BJmvUZ1E.js +28 -0
- package/dist/search-manager-5CMnrJiG.js +392 -0
- package/dist/search-manager-mbopau6D.js +17 -0
- package/dist/secret-equal-ObQfyZGa.js +9 -0
- package/dist/secret-file-Ch0yuOXR.js +11 -0
- package/dist/secret-file-DYJtH6kf.js +92 -0
- package/dist/secret-input-4REZ4sHo.js +35 -0
- package/dist/secrets-cli-CDAAxiLx.js +2304 -0
- package/dist/secure-random-Cs8tw_HQ.js +10 -0
- package/dist/security-cli-73x8ZrPY.js +676 -0
- package/dist/security-runtime-BuEhpJVE.js +23 -0
- package/dist/send-3tabvle6.js +100 -0
- package/dist/send-CK2mTZ2A.js +1026 -0
- package/dist/send-CoghdDtC.js +250 -0
- package/dist/send-deps-CrFMNvqO.js +19 -0
- package/dist/server-DsQSJw3K.js +116 -0
- package/dist/server-middleware-CCqKhKUb.js +106 -0
- package/dist/server-node-events-ByKRzTEW.js +611 -0
- package/dist/server-startup-matrix-migration-DXgvClaj.js +1595 -0
- package/dist/service-CCEFa-Yp.js +21 -0
- package/dist/service-DsLjWzXO.js +774 -0
- package/dist/session-cost-usage-Bcu2puh5.js +615 -0
- package/dist/session-cost-usage-CqAjBtg1.js +212 -0
- package/dist/session-fork.runtime-BZfcC1Nc.js +51 -0
- package/dist/session-key-gFFk3uv9.js +216 -0
- package/dist/session-write-lock-DNKvpjKf.js +324 -0
- package/dist/sessions-BjptmD-t.js +669 -0
- package/dist/sessions-CcXbjCp-.js +212 -0
- package/dist/sessions-DzQPJoHb.js +222 -0
- package/dist/setup-CN-teRpz.js +8 -0
- package/dist/setup-adapter-runtime-Bjv2adwG.js +1 -0
- package/dist/setup-binary-BOJA7zdN.js +30 -0
- package/dist/setup-browser-BhNPCUtK.js +71 -0
- package/dist/setup-core-7tpbsHoe.js +510 -0
- package/dist/setup-core-DsGvW4Oh.js +149 -0
- package/dist/setup-core-m6QfoAWl.js +162 -0
- package/dist/setup-entry-BgrHdl35.js +13 -0
- package/dist/setup-entry-DKV-8VNp.js +13 -0
- package/dist/setup-entry-Df-K2RuZ.js +12 -0
- package/dist/setup-entry-DxtbuNKQ.js +12 -0
- package/dist/setup-entry-Dzn7A8q7.js +10 -0
- package/dist/setup-entry-bSF8R2r8.js +14 -0
- package/dist/setup-group-access-BtPApRvE.js +70 -0
- package/dist/setup-helpers-B62Ecg9r.js +362 -0
- package/dist/setup-saJ2s_47.js +397 -0
- package/dist/setup-surface-BGYo0Juy.js +452 -0
- package/dist/setup-surface-Cx1YVfWw.js +298 -0
- package/dist/setup-surface-DF1wiFx2.js +380 -0
- package/dist/setup-tools-BPiMjAN7.js +1 -0
- package/dist/setup-wizard-helpers-COZ1UAdX.js +770 -0
- package/dist/setup-wizard-proxy-Slwi-1gX.js +116 -0
- package/dist/setup.finalize-BEoLI29h.js +633 -0
- package/dist/setup.gateway-config-6ACjCQcc.js +288 -0
- package/dist/setup.secret-input-BL-bqJpt.js +25 -0
- package/dist/shared-AygSbeCK.js +50 -0
- package/dist/shared-BEtSbYbS.js +70 -0
- package/dist/shared-BU0QgVMZ.js +36 -0
- package/dist/shared-B_i-s5Yg.js +127 -0
- package/dist/shared-CsOwQtm1.js +82 -0
- package/dist/shared-DA95aWfS.js +196 -0
- package/dist/shared-DsbqCNFQ.js +64 -0
- package/dist/shared-LeP8iUTz.js +54 -0
- package/dist/shared-N35AUgZI.js +351 -0
- package/dist/shared-qmfOl6pa.js +87 -0
- package/dist/shell-argv-DWV43Vya.js +72 -0
- package/dist/shell-env-cD92jEyV.js +181 -0
- package/dist/signal-8EYn_jCw.js +214 -0
- package/dist/signal-Ca7y47bM.js +46 -0
- package/dist/signal-CdndhLSx.js +315 -0
- package/dist/signal-cli-install-DxoL8CgF.js +188 -0
- package/dist/skill-commands-CiSwTFBQ.js +652 -0
- package/dist/skill-commands.runtime-CEwlWT4j.js +34 -0
- package/dist/skill-scanner-DG7MT7pu.js +354 -0
- package/dist/skills-BC8GJ9Rp.js +22 -0
- package/dist/skills-CCgKs_NJ.js +863 -0
- package/dist/skills-cli-Xqm4TQ_x.js +339 -0
- package/dist/skills-install-DiriUXJd.js +763 -0
- package/dist/skills-status-BmQTn4jL.js +23 -0
- package/dist/skills-status-a9b899Y3.js +169 -0
- package/dist/slack-C3ZawHgc.js +217 -0
- package/dist/slack-DnTAFEmr.js +730 -0
- package/dist/slack-UD0yJzLR.js +24536 -0
- package/dist/slack-core-DcsbATUs.js +1 -0
- package/dist/slash-commands.runtime-sOpKLp0F.js +228 -0
- package/dist/slash-dispatch.runtime-CbC_hoS7.js +238 -0
- package/dist/slash-skill-commands.runtime-CXNUQJQR.js +216 -0
- package/dist/speech-bSreRuDH.js +1 -0
- package/dist/speech-runtime-y1FcnGVA.js +1 -0
- package/dist/src-CmXHIz5f.js +846 -0
- package/dist/ssh-config-ChqR6ijV.js +77 -0
- package/dist/ssh-tunnel-BWqSNkJo.js +159 -0
- package/dist/ssh-tunnel-DXVCvSif.js +16 -0
- package/dist/ssrf-Dk9XaoKN.js +220 -0
- package/dist/ssrf-policy-Dk6oMa20.js +69 -0
- package/dist/ssrf-runtime-C-mAQLVA.js +1 -0
- package/dist/stagger-DU7FjHYo.js +54 -0
- package/dist/state-paths-DJIGEFq_.js +1 -0
- package/dist/status-1dN68Nry.js +212 -0
- package/dist/status-B5jKN_AU.js +606 -0
- package/dist/status-BQWWxkTB.js +235 -0
- package/dist/status-By03N6J2.js +44 -0
- package/dist/status-COGoXc70.js +202 -0
- package/dist/status-ClMSSlfZ.js +1665 -0
- package/dist/status-Dl_kHCzm.js +75 -0
- package/dist/status-helpers-Cda-rGLX.js +101 -0
- package/dist/status-json-DXiuJMkM.js +322 -0
- package/dist/status.link-channel-DVXC4ITW.js +40 -0
- package/dist/status.scan.deps.runtime-BklcI9d4.js +77 -0
- package/dist/status.scan.runtime-Bz0f5qUW.js +14 -0
- package/dist/status.summary-D8-ms-9P.js +600 -0
- package/dist/status.summary.runtime-Cng6MzRU.js +151 -0
- package/dist/status.update-CjoH4lVV.js +79 -0
- package/dist/store-AMSZUI0p.js +1446 -0
- package/dist/store.runtime-B0dFf2pa.js +43 -0
- package/dist/string-normalization-CvzuCAZv.js +19 -0
- package/dist/string-sample-BOLqzr4Y.js +11 -0
- package/dist/subagent-orphan-recovery-CDTomicF.js +407 -0
- package/dist/subagent-registry-runtime-kD87ylaJ.js +211 -0
- package/dist/subcli-descriptors-CteQXLPG.js +151 -0
- package/dist/subsystem-CUp-6QQf.js +421 -0
- package/dist/synology-chat-CFiJEDRu.js +12 -0
- package/dist/system-cli-D2pMYxTX.js +99 -0
- package/dist/system-events-mAu6Ap6K.js +75 -0
- package/dist/system-message-DA9eUYzB.js +16 -0
- package/dist/system-run-command-BV7UnYxn.js +258 -0
- package/dist/systemd-CrxZBFae.js +557 -0
- package/dist/systemd-hints-BLAoAquw.js +315 -0
- package/dist/systemd-linger-BdklDcLg.js +16 -0
- package/dist/systemd-linger-DLrbG9_d.js +68 -0
- package/dist/table-DFMOhmNZ.js +305 -0
- package/dist/tailnet-ofqBrXzu.js +38 -0
- package/dist/tailscale-Cbsx-2HB.js +254 -0
- package/dist/target-errors-ksphhzJg.js +26 -0
- package/dist/target-registry-krAVlXi_.js +1321 -0
- package/dist/telegram/audit.js +2 -0
- package/dist/telegram/token.js +211 -0
- package/dist/telegram--sUKZkSQ.js +218 -0
- package/dist/telegram-T7TInjDG.js +575 -0
- package/dist/telegram-core-B4Jo-uko.js +1 -0
- package/dist/telegram-gE5VPMy9.js +10910 -0
- package/dist/template-messages-kh7VfgOb.js +214 -0
- package/dist/text-chunking-CUf5WgqG.js +19 -0
- package/dist/text-format-sFXlJfHH.js +8 -0
- package/dist/text-runtime-C_Roi_Je.js +1418 -0
- package/dist/theme-B5HDbQfl.js +2 -0
- package/dist/theme-CdOoMzRk.js +34 -0
- package/dist/thinking-BBD_0HSp.js +68 -0
- package/dist/thinking.shared-CncvRHts.js +246 -0
- package/dist/thread-bindings-messages-Cdo8jSa9.js +229 -0
- package/dist/thread-bindings-policy-DMjOaNyR.js +119 -0
- package/dist/thread-bindings-runtime-Ckwk3Uuz.js +1 -0
- package/dist/threading-helpers-Cq55SUtb.js +14 -0
- package/dist/timeouts-BwR1sGom.js +72 -0
- package/dist/tmp-openclaw-dir-idKIOMmb.js +102 -0
- package/dist/token-Bgv8XEsC.js +50 -0
- package/dist/tool-catalog-BV6FcEWS.js +337 -0
- package/dist/tool-policy-match-hui3aCeL.js +46 -0
- package/dist/tool-send-9LXKcrda.js +16 -0
- package/dist/topology-cli-BhUXVViF.js +43 -0
- package/dist/transcript-events-B1V6z5ct.js +29 -0
- package/dist/tui-DPFSXSKf.js +3838 -0
- package/dist/tui-cli-ARm2kBar.js +237 -0
- package/dist/typebox-D0SHDJST.js +175 -0
- package/dist/types-BCKGVVld.js +83 -0
- package/dist/types-CtpUGsDP.js +30 -0
- package/dist/types.secrets-BWSeXrF4.js +80 -0
- package/dist/types.tools-BBO8HCi6.js +22 -0
- package/dist/typing-DG_YqWJ7.js +224 -0
- package/dist/unhandled-rejections-CDJ8dOVP.js +170 -0
- package/dist/unhandled-rejections-O6cVOz2D.js +4 -0
- package/dist/update-check-C3TeQaWg.js +464 -0
- package/dist/update-cli-d9OEgooM.js +1625 -0
- package/dist/update-offset-store-DxnWyB1g.js +211 -0
- package/dist/update-yEO8OZ1B.js +1039 -0
- package/dist/upsert-with-lock-Bb96JHpb.js +34 -0
- package/dist/url-userinfo-Db63ng4y.js +14 -0
- package/dist/utils-Bxk6BLTg.js +236 -0
- package/dist/utils-vDeUf98G.js +7 -0
- package/dist/version-BQotbaVq.js +65 -0
- package/dist/version-riajrkRq.js +2 -0
- package/dist/voice-call-D4fgwZNO.js +1 -0
- package/dist/warning-filter-CgvLQB4Y.js +56 -0
- package/dist/web-media-BfBb8i48.js +1 -0
- package/dist/web-media-CtU6jM5V.js +498 -0
- package/dist/webhook-ingress-CupqYpKM.js +338 -0
- package/dist/webhook-memory-guards-BHrFZ4yq.js +129 -0
- package/dist/webhook-path-BGFZ55ML.js +22 -0
- package/dist/webhook-shared-DPtckp_I.js +349 -0
- package/dist/webhooks-cli-DXesU9a9.js +357 -0
- package/dist/whatsapp-Ba6KkyUx.js +58 -0
- package/dist/whatsapp-DXbWlm3A.js +82 -0
- package/dist/whatsapp-core-Ca4IJFs0.js +89490 -0
- package/dist/whatsapp-heartbeat-CSWnPQ7q.js +84 -0
- package/dist/whatsapp-shared-BmHKqTtR.js +95 -0
- package/dist/widearea-dns-CXimgJzu.js +125 -0
- package/dist/windows-argv-IXrdWrJj.js +145 -0
- package/dist/windows-spawn-vMJGZo89.js +154 -0
- package/dist/with-timeout-2AKTISee.js +58 -0
- package/dist/workspace-BH7CXmrr.js +479 -0
- package/dist/workspace-dirs-_O4V3xCR.js +13 -0
- package/dist/workspace-v5XppK5M.js +302 -0
- package/dist/ws-By-QcLjg.js +11 -0
- package/dist/wsl-BV3Cb66X.js +57 -0
- package/dist/zalo-Ca9sr4FS.js +301 -0
- package/dist/zalo-x6b0tYi0.js +13 -0
- package/dist/zod-schema.agent-runtime-T_EC_6fg.js +600 -0
- package/dist/zod-schema.core-BdgRr-F1.js +545 -0
- package/dist/zod-schema.providers-core-Dgq7MTqU.js +1613 -0
- package/dist-runtime/extensions/acpx/openclaw.plugin.json +120 -0
- package/dist-runtime/extensions/acpx/package.json +14 -0
- package/dist-runtime/extensions/amazon-bedrock/index.js +3 -0
- package/dist-runtime/extensions/amazon-bedrock/openclaw.plugin.json +11 -0
- package/dist-runtime/extensions/amazon-bedrock/package.json +12 -0
- package/dist-runtime/extensions/anthropic/index.js +3 -0
- package/dist-runtime/extensions/anthropic/openclaw.plugin.json +42 -0
- package/dist-runtime/extensions/anthropic/package.json +12 -0
- package/dist-runtime/extensions/bluebubbles/index.js +3 -0
- package/dist-runtime/extensions/bluebubbles/openclaw.plugin.json +11 -0
- package/dist-runtime/extensions/bluebubbles/package.json +51 -0
- package/dist-runtime/extensions/bluebubbles/setup-entry.js +3 -0
- package/dist-runtime/extensions/brave/index.js +3 -0
- package/dist-runtime/extensions/brave/openclaw.plugin.json +45 -0
- package/dist-runtime/extensions/brave/package.json +12 -0
- package/dist-runtime/extensions/byteplus/index.js +3 -0
- package/dist-runtime/extensions/byteplus/openclaw.plugin.json +32 -0
- package/dist-runtime/extensions/byteplus/package.json +12 -0
- package/dist-runtime/extensions/chutes/index.js +3 -0
- package/dist-runtime/extensions/chutes/openclaw.plugin.json +44 -0
- package/dist-runtime/extensions/chutes/package.json +12 -0
- package/dist-runtime/extensions/cloudflare-ai-gateway/index.js +3 -0
- package/dist-runtime/extensions/cloudflare-ai-gateway/openclaw.plugin.json +32 -0
- package/dist-runtime/extensions/cloudflare-ai-gateway/package.json +12 -0
- package/dist-runtime/extensions/copilot-proxy/index.js +3 -0
- package/dist-runtime/extensions/copilot-proxy/openclaw.plugin.json +23 -0
- package/dist-runtime/extensions/copilot-proxy/package.json +12 -0
- package/dist-runtime/extensions/device-pair/index.js +3 -0
- package/dist-runtime/extensions/device-pair/openclaw.plugin.json +20 -0
- package/dist-runtime/extensions/diagnostics-otel/openclaw.plugin.json +8 -0
- package/dist-runtime/extensions/diagnostics-otel/package.json +27 -0
- package/dist-runtime/extensions/diffs/openclaw.plugin.json +216 -0
- package/dist-runtime/extensions/diffs/package.json +20 -0
- package/dist-runtime/extensions/discord/index.js +3 -0
- package/dist-runtime/extensions/discord/openclaw.plugin.json +11 -0
- package/dist-runtime/extensions/discord/package.json +40 -0
- package/dist-runtime/extensions/discord/setup-entry.js +3 -0
- package/dist-runtime/extensions/elevenlabs/index.js +3 -0
- package/dist-runtime/extensions/elevenlabs/openclaw.plugin.json +8 -0
- package/dist-runtime/extensions/elevenlabs/package.json +12 -0
- package/dist-runtime/extensions/fal/index.js +3 -0
- package/dist-runtime/extensions/fal/openclaw.plugin.json +34 -0
- package/dist-runtime/extensions/fal/package.json +12 -0
- package/dist-runtime/extensions/feishu/index.js +3 -0
- package/dist-runtime/extensions/feishu/openclaw.plugin.json +14 -0
- package/dist-runtime/extensions/feishu/package.json +42 -0
- package/dist-runtime/extensions/feishu/setup-entry.js +3 -0
- package/dist-runtime/extensions/firecrawl/index.js +3 -0
- package/dist-runtime/extensions/firecrawl/openclaw.plugin.json +41 -0
- package/dist-runtime/extensions/firecrawl/package.json +12 -0
- package/dist-runtime/extensions/github-copilot/index.js +3 -0
- package/dist-runtime/extensions/github-copilot/openclaw.plugin.json +30 -0
- package/dist-runtime/extensions/github-copilot/package.json +12 -0
- package/dist-runtime/extensions/google/index.js +3 -0
- package/dist-runtime/extensions/google/openclaw.plugin.json +71 -0
- package/dist-runtime/extensions/google/package.json +12 -0
- package/dist-runtime/extensions/googlechat/openclaw.plugin.json +11 -0
- package/dist-runtime/extensions/googlechat/package.json +46 -0
- package/dist-runtime/extensions/huggingface/index.js +3 -0
- package/dist-runtime/extensions/huggingface/openclaw.plugin.json +33 -0
- package/dist-runtime/extensions/huggingface/package.json +12 -0
- package/dist-runtime/extensions/imessage/index.js +3 -0
- package/dist-runtime/extensions/imessage/openclaw.plugin.json +11 -0
- package/dist-runtime/extensions/imessage/package.json +26 -0
- package/dist-runtime/extensions/imessage/setup-entry.js +3 -0
- package/dist-runtime/extensions/irc/index.js +3 -0
- package/dist-runtime/extensions/irc/openclaw.plugin.json +11 -0
- package/dist-runtime/extensions/irc/package.json +25 -0
- package/dist-runtime/extensions/irc/setup-entry.js +3 -0
- package/dist-runtime/extensions/kilocode/index.js +3 -0
- package/dist-runtime/extensions/kilocode/openclaw.plugin.json +32 -0
- package/dist-runtime/extensions/kilocode/package.json +12 -0
- package/dist-runtime/extensions/kimi-coding/index.js +3 -0
- package/dist-runtime/extensions/kimi-coding/openclaw.plugin.json +37 -0
- package/dist-runtime/extensions/kimi-coding/package.json +12 -0
- package/dist-runtime/extensions/line/index.js +3 -0
- package/dist-runtime/extensions/line/openclaw.plugin.json +11 -0
- package/dist-runtime/extensions/line/package.json +39 -0
- package/dist-runtime/extensions/line/setup-entry.js +3 -0
- package/dist-runtime/extensions/llm-task/index.js +3 -0
- package/dist-runtime/extensions/llm-task/openclaw.plugin.json +33 -0
- package/dist-runtime/extensions/llm-task/package.json +16 -0
- package/dist-runtime/extensions/lobster/index.js +3 -0
- package/dist-runtime/extensions/lobster/openclaw.plugin.json +10 -0
- package/dist-runtime/extensions/lobster/package.json +17 -0
- package/dist-runtime/extensions/matrix/openclaw.plugin.json +11 -0
- package/dist-runtime/extensions/matrix/package.json +53 -0
- package/dist-runtime/extensions/mattermost/index.js +3 -0
- package/dist-runtime/extensions/mattermost/openclaw.plugin.json +11 -0
- package/dist-runtime/extensions/mattermost/package.json +41 -0
- package/dist-runtime/extensions/mattermost/setup-entry.js +3 -0
- package/dist-runtime/extensions/memory-core/index.js +3 -0
- package/dist-runtime/extensions/memory-core/openclaw.plugin.json +9 -0
- package/dist-runtime/extensions/memory-core/package.json +20 -0
- package/dist-runtime/extensions/memory-lancedb/openclaw.plugin.json +92 -0
- package/dist-runtime/extensions/memory-lancedb/package.json +24 -0
- package/dist-runtime/extensions/microsoft/index.js +3 -0
- package/dist-runtime/extensions/microsoft/openclaw.plugin.json +8 -0
- package/dist-runtime/extensions/microsoft/package.json +12 -0
- package/dist-runtime/extensions/minimax/index.js +3 -0
- package/dist-runtime/extensions/minimax/openclaw.plugin.json +71 -0
- package/dist-runtime/extensions/minimax/package.json +12 -0
- package/dist-runtime/extensions/mistral/index.js +3 -0
- package/dist-runtime/extensions/mistral/openclaw.plugin.json +31 -0
- package/dist-runtime/extensions/mistral/package.json +12 -0
- package/dist-runtime/extensions/modelstudio/index.js +3 -0
- package/dist-runtime/extensions/modelstudio/openclaw.plugin.json +46 -0
- package/dist-runtime/extensions/modelstudio/package.json +12 -0
- package/dist-runtime/extensions/moonshot/index.js +3 -0
- package/dist-runtime/extensions/moonshot/openclaw.plugin.json +78 -0
- package/dist-runtime/extensions/moonshot/package.json +12 -0
- package/dist-runtime/extensions/msteams/openclaw.plugin.json +11 -0
- package/dist-runtime/extensions/msteams/package.json +48 -0
- package/dist-runtime/extensions/nextcloud-talk/index.js +3 -0
- package/dist-runtime/extensions/nextcloud-talk/openclaw.plugin.json +11 -0
- package/dist-runtime/extensions/nextcloud-talk/package.json +48 -0
- package/dist-runtime/extensions/nextcloud-talk/setup-entry.js +3 -0
- package/dist-runtime/extensions/nostr/openclaw.plugin.json +11 -0
- package/dist-runtime/extensions/nostr/package.json +45 -0
- package/dist-runtime/extensions/nvidia/index.js +3 -0
- package/dist-runtime/extensions/nvidia/openclaw.plugin.json +16 -0
- package/dist-runtime/extensions/nvidia/package.json +12 -0
- package/dist-runtime/extensions/ollama/index.js +3 -0
- package/dist-runtime/extensions/ollama/openclaw.plugin.json +28 -0
- package/dist-runtime/extensions/ollama/package.json +12 -0
- package/dist-runtime/extensions/open-prose/index.js +3 -0
- package/dist-runtime/extensions/open-prose/openclaw.plugin.json +13 -0
- package/dist-runtime/extensions/open-prose/package.json +12 -0
- package/dist-runtime/extensions/openai/index.js +3 -0
- package/dist-runtime/extensions/openai/openclaw.plugin.json +42 -0
- package/dist-runtime/extensions/openai/package.json +12 -0
- package/dist-runtime/extensions/opencode/index.js +3 -0
- package/dist-runtime/extensions/opencode/openclaw.plugin.json +32 -0
- package/dist-runtime/extensions/opencode/package.json +12 -0
- package/dist-runtime/extensions/opencode-go/index.js +3 -0
- package/dist-runtime/extensions/opencode-go/openclaw.plugin.json +32 -0
- package/dist-runtime/extensions/opencode-go/package.json +12 -0
- package/dist-runtime/extensions/openrouter/index.js +3 -0
- package/dist-runtime/extensions/openrouter/openclaw.plugin.json +31 -0
- package/dist-runtime/extensions/openrouter/package.json +12 -0
- package/dist-runtime/extensions/openshell/index.js +3 -0
- package/dist-runtime/extensions/openshell/openclaw.plugin.json +99 -0
- package/dist-runtime/extensions/openshell/package.json +12 -0
- package/dist-runtime/extensions/perplexity/index.js +3 -0
- package/dist-runtime/extensions/perplexity/openclaw.plugin.json +49 -0
- package/dist-runtime/extensions/perplexity/package.json +12 -0
- package/dist-runtime/extensions/phone-control/index.js +3 -0
- package/dist-runtime/extensions/phone-control/openclaw.plugin.json +10 -0
- package/dist-runtime/extensions/qianfan/index.js +3 -0
- package/dist-runtime/extensions/qianfan/openclaw.plugin.json +31 -0
- package/dist-runtime/extensions/qianfan/package.json +12 -0
- package/dist-runtime/extensions/qwen-portal-auth/index.js +3 -0
- package/dist-runtime/extensions/qwen-portal-auth/openclaw.plugin.json +29 -0
- package/dist-runtime/extensions/sglang/index.js +3 -0
- package/dist-runtime/extensions/sglang/openclaw.plugin.json +28 -0
- package/dist-runtime/extensions/sglang/package.json +12 -0
- package/dist-runtime/extensions/signal/index.js +3 -0
- package/dist-runtime/extensions/signal/openclaw.plugin.json +11 -0
- package/dist-runtime/extensions/signal/package.json +23 -0
- package/dist-runtime/extensions/signal/setup-entry.js +3 -0
- package/dist-runtime/extensions/slack/index.js +3 -0
- package/dist-runtime/extensions/slack/openclaw.plugin.json +11 -0
- package/dist-runtime/extensions/slack/package.json +30 -0
- package/dist-runtime/extensions/slack/setup-entry.js +3 -0
- package/dist-runtime/extensions/synology-chat/index.js +3 -0
- package/dist-runtime/extensions/synology-chat/openclaw.plugin.json +11 -0
- package/dist-runtime/extensions/synology-chat/package.json +29 -0
- package/dist-runtime/extensions/synology-chat/setup-entry.js +3 -0
- package/dist-runtime/extensions/synthetic/index.js +3 -0
- package/dist-runtime/extensions/synthetic/openclaw.plugin.json +31 -0
- package/dist-runtime/extensions/synthetic/package.json +12 -0
- package/dist-runtime/extensions/talk-voice/index.js +3 -0
- package/dist-runtime/extensions/talk-voice/openclaw.plugin.json +10 -0
- package/dist-runtime/extensions/tavily/index.js +3 -0
- package/dist-runtime/extensions/tavily/openclaw.plugin.json +44 -0
- package/dist-runtime/extensions/tavily/package.json +12 -0
- package/dist-runtime/extensions/telegram/index.js +3 -0
- package/dist-runtime/extensions/telegram/openclaw.plugin.json +11 -0
- package/dist-runtime/extensions/telegram/package.json +31 -0
- package/dist-runtime/extensions/telegram/setup-entry.js +3 -0
- package/dist-runtime/extensions/thread-ownership/index.js +3 -0
- package/dist-runtime/extensions/thread-ownership/openclaw.plugin.json +30 -0
- package/dist-runtime/extensions/tlon/bundled-skills/@tloncorp/tlon-skill/bin/tlon.js +3 -0
- package/dist-runtime/extensions/tlon/bundled-skills/@tloncorp/tlon-skill/package.json +40 -0
- package/dist-runtime/extensions/tlon/bundled-skills/@tloncorp/tlon-skill/scripts/postinstall.js +3 -0
- package/dist-runtime/extensions/tlon/openclaw.plugin.json +14 -0
- package/dist-runtime/extensions/tlon/package.json +45 -0
- package/dist-runtime/extensions/together/index.js +3 -0
- package/dist-runtime/extensions/together/openclaw.plugin.json +31 -0
- package/dist-runtime/extensions/together/package.json +12 -0
- package/dist-runtime/extensions/twitch/openclaw.plugin.json +11 -0
- package/dist-runtime/extensions/twitch/package.json +27 -0
- package/dist-runtime/extensions/venice/index.js +3 -0
- package/dist-runtime/extensions/venice/openclaw.plugin.json +31 -0
- package/dist-runtime/extensions/venice/package.json +12 -0
- package/dist-runtime/extensions/vercel-ai-gateway/index.js +3 -0
- package/dist-runtime/extensions/vercel-ai-gateway/openclaw.plugin.json +31 -0
- package/dist-runtime/extensions/vercel-ai-gateway/package.json +12 -0
- package/dist-runtime/extensions/vllm/index.js +3 -0
- package/dist-runtime/extensions/vllm/openclaw.plugin.json +28 -0
- package/dist-runtime/extensions/vllm/package.json +12 -0
- package/dist-runtime/extensions/voice-call/index.js +3 -0
- package/dist-runtime/extensions/voice-call/openclaw.plugin.json +648 -0
- package/dist-runtime/extensions/voice-call/package.json +31 -0
- package/dist-runtime/extensions/volcengine/index.js +3 -0
- package/dist-runtime/extensions/volcengine/openclaw.plugin.json +32 -0
- package/dist-runtime/extensions/volcengine/package.json +12 -0
- package/dist-runtime/extensions/whatsapp/openclaw.plugin.json +11 -0
- package/dist-runtime/extensions/whatsapp/package.json +44 -0
- package/dist-runtime/extensions/xai/index.js +3 -0
- package/dist-runtime/extensions/xai/openclaw.plugin.json +65 -0
- package/dist-runtime/extensions/xai/package.json +12 -0
- package/dist-runtime/extensions/xiaomi/index.js +3 -0
- package/dist-runtime/extensions/xiaomi/openclaw.plugin.json +31 -0
- package/dist-runtime/extensions/xiaomi/package.json +12 -0
- package/dist-runtime/extensions/zai/index.js +3 -0
- package/dist-runtime/extensions/zai/openclaw.plugin.json +88 -0
- package/dist-runtime/extensions/zai/package.json +12 -0
- package/dist-runtime/extensions/zalo/index.js +3 -0
- package/dist-runtime/extensions/zalo/openclaw.plugin.json +11 -0
- package/dist-runtime/extensions/zalo/package.json +48 -0
- package/dist-runtime/extensions/zalo/setup-entry.js +3 -0
- package/dist-runtime/extensions/zalouser/openclaw.plugin.json +11 -0
- package/dist-runtime/extensions/zalouser/package.json +49 -0
- package/openclaw.mjs +135 -0
- package/package.json +673 -0
- package/skills/1password/SKILL.md +70 -0
- package/skills/1password/references/cli-examples.md +29 -0
- package/skills/1password/references/get-started.md +17 -0
- package/skills/apple-notes/SKILL.md +77 -0
- package/skills/apple-reminders/SKILL.md +118 -0
- package/skills/bear-notes/SKILL.md +107 -0
- package/skills/blogwatcher/SKILL.md +69 -0
- package/skills/blucli/SKILL.md +47 -0
- package/skills/bluebubbles/SKILL.md +131 -0
- package/skills/camsnap/SKILL.md +45 -0
- package/skills/canvas/SKILL.md +198 -0
- package/skills/clawhub/SKILL.md +77 -0
- package/skills/coding-agent/SKILL.md +295 -0
- package/skills/discord/SKILL.md +197 -0
- package/skills/doubao-code/SKILL.md +43 -0
- package/skills/eightctl/SKILL.md +50 -0
- package/skills/gemini/SKILL.md +43 -0
- package/skills/gh-issues/SKILL.md +865 -0
- package/skills/gifgrep/SKILL.md +79 -0
- package/skills/github/SKILL.md +163 -0
- package/skills/gog/SKILL.md +116 -0
- package/skills/goplaces/SKILL.md +52 -0
- package/skills/healthcheck/SKILL.md +245 -0
- package/skills/himalaya/SKILL.md +257 -0
- package/skills/himalaya/references/configuration.md +184 -0
- package/skills/himalaya/references/message-composition.md +199 -0
- package/skills/imsg/SKILL.md +122 -0
- package/skills/kimi-code/SKILL.md +42 -0
- package/skills/mcporter/SKILL.md +61 -0
- package/skills/model-usage/SKILL.md +69 -0
- package/skills/model-usage/references/codexbar-cli.md +33 -0
- package/skills/model-usage/scripts/model_usage.py +320 -0
- package/skills/model-usage/scripts/test_model_usage.py +40 -0
- package/skills/nano-pdf/SKILL.md +38 -0
- package/skills/node-connect/SKILL.md +142 -0
- package/skills/notion/SKILL.md +174 -0
- package/skills/obsidian/SKILL.md +81 -0
- package/skills/openai-image-gen/SKILL.md +92 -0
- package/skills/openai-image-gen/scripts/gen.py +328 -0
- package/skills/openai-image-gen/scripts/test_gen.py +140 -0
- package/skills/openai-whisper/SKILL.md +38 -0
- package/skills/openai-whisper-api/SKILL.md +52 -0
- package/skills/openai-whisper-api/scripts/transcribe.sh +85 -0
- package/skills/openhue/SKILL.md +112 -0
- package/skills/oracle/SKILL.md +125 -0
- package/skills/ordercli/SKILL.md +78 -0
- package/skills/peekaboo/SKILL.md +190 -0
- package/skills/sag/SKILL.md +87 -0
- package/skills/session-logs/SKILL.md +115 -0
- package/skills/sherpa-onnx-tts/SKILL.md +103 -0
- package/skills/skill-creator/SKILL.md +372 -0
- package/skills/skill-creator/license.txt +202 -0
- package/skills/skill-creator/scripts/init_skill.py +378 -0
- package/skills/skill-creator/scripts/package_skill.py +139 -0
- package/skills/skill-creator/scripts/quick_validate.py +159 -0
- package/skills/skill-creator/scripts/test_package_skill.py +160 -0
- package/skills/skill-creator/scripts/test_quick_validate.py +72 -0
- package/skills/slack/SKILL.md +144 -0
- package/skills/songsee/SKILL.md +49 -0
- package/skills/sonoscli/SKILL.md +65 -0
- package/skills/spotify-player/SKILL.md +64 -0
- package/skills/summarize/SKILL.md +87 -0
- package/skills/things-mac/SKILL.md +86 -0
- package/skills/tmux/SKILL.md +153 -0
- package/skills/tmux/scripts/find-sessions.sh +112 -0
- package/skills/tmux/scripts/wait-for-text.sh +83 -0
- package/skills/trello/SKILL.md +95 -0
- package/skills/video-frames/SKILL.md +46 -0
- package/skills/video-frames/scripts/frame.sh +81 -0
- package/skills/voice-call/SKILL.md +45 -0
- package/skills/wacli/SKILL.md +72 -0
- package/skills/weather/SKILL.md +112 -0
- package/skills/xurl/SKILL.md +461 -0
|
@@ -0,0 +1,3838 @@
|
|
|
1
|
+
import { i as visibleWidth, r as stripAnsi$1 } from "./ansi-BEJF8NKS.js";
|
|
2
|
+
import { d as normalizeUsageDisplay, p as resolveResponseUsageMode } from "./thinking.shared-CncvRHts.js";
|
|
3
|
+
import { S as parseAgentSessionKey, c as normalizeAgentId, l as normalizeMainKey, r as buildAgentMainSessionKey } from "./session-key-gFFk3uv9.js";
|
|
4
|
+
import { c as resolveAgentIdByWorkspacePath, m as resolveDefaultAgentId } from "./agent-scope-DPP4Z_UU.js";
|
|
5
|
+
import { s as loadConfig } from "./io-BjKpaXU3.js";
|
|
6
|
+
import { n as VERSION } from "./version-BQotbaVq.js";
|
|
7
|
+
import { a as hasConfiguredSecretInput } from "./types.secrets-BWSeXrF4.js";
|
|
8
|
+
import { t as assertExplicitGatewayAuthModeWhenBothConfigured } from "./auth-mode-policy-DywddkT-.js";
|
|
9
|
+
import { f as GATEWAY_CLIENT_CAPS, h as GATEWAY_CLIENT_NAMES, m as GATEWAY_CLIENT_MODES } from "./message-channel-Cy-gN4K2.js";
|
|
10
|
+
import { u as GatewayClient } from "./method-scopes-ChbR5hu0.js";
|
|
11
|
+
import { c as resolveExplicitGatewayAuth, o as ensureExplicitGatewayAuth, t as buildGatewayConnectionDetails } from "./call-I0SGvyU7.js";
|
|
12
|
+
import { Go as stripLeadingInboundMetadata, im as formatRawAssistantErrorForUi, ld as formatTokenCount, nm as formatToolDetail, rm as resolveToolDisplay } from "./pi-embedded-CDH9LrEg.js";
|
|
13
|
+
import { n as listThinkingLevelLabels, t as formatThinkingLevels } from "./thinking-BBD_0HSp.js";
|
|
14
|
+
import { Y as resolveConfiguredSecretInputString } from "./routes-LnFKW9Eh.js";
|
|
15
|
+
import { c as listChatCommands, l as listChatCommandsForConfig } from "./commands-registry-ChCep1KJ.js";
|
|
16
|
+
import { n as formatTimeAgo, t as formatRelativeTimestamp } from "./format-relative-C3nDxnXz.js";
|
|
17
|
+
import { spawn } from "node:child_process";
|
|
18
|
+
import chalk from "chalk";
|
|
19
|
+
import { randomUUID } from "node:crypto";
|
|
20
|
+
import { Box, CombinedAutocompleteProvider, Container, Editor, Input, Key, Loader, Markdown, ProcessTerminal, SelectList, SettingsList, Spacer, TUI, Text, getEditorKeybindings, isKeyRelease, matchesKey, truncateToWidth } from "@mariozechner/pi-tui";
|
|
21
|
+
import { highlight, supportsLanguage } from "cli-highlight";
|
|
22
|
+
//#region src/tui/commands.ts
|
|
23
|
+
const VERBOSE_LEVELS = ["on", "off"];
|
|
24
|
+
const FAST_LEVELS = [
|
|
25
|
+
"status",
|
|
26
|
+
"on",
|
|
27
|
+
"off"
|
|
28
|
+
];
|
|
29
|
+
const REASONING_LEVELS = ["on", "off"];
|
|
30
|
+
const ELEVATED_LEVELS = [
|
|
31
|
+
"on",
|
|
32
|
+
"off",
|
|
33
|
+
"ask",
|
|
34
|
+
"full"
|
|
35
|
+
];
|
|
36
|
+
const ACTIVATION_LEVELS = ["mention", "always"];
|
|
37
|
+
const USAGE_FOOTER_LEVELS = [
|
|
38
|
+
"off",
|
|
39
|
+
"tokens",
|
|
40
|
+
"full"
|
|
41
|
+
];
|
|
42
|
+
const COMMAND_ALIASES = { elev: "elevated" };
|
|
43
|
+
function createLevelCompletion(levels) {
|
|
44
|
+
return (prefix) => levels.filter((value) => value.startsWith(prefix.toLowerCase())).map((value) => ({
|
|
45
|
+
value,
|
|
46
|
+
label: value
|
|
47
|
+
}));
|
|
48
|
+
}
|
|
49
|
+
function parseCommand(input) {
|
|
50
|
+
const trimmed = input.replace(/^\//, "").trim();
|
|
51
|
+
if (!trimmed) return {
|
|
52
|
+
name: "",
|
|
53
|
+
args: ""
|
|
54
|
+
};
|
|
55
|
+
const [name, ...rest] = trimmed.split(/\s+/);
|
|
56
|
+
const normalized = name.toLowerCase();
|
|
57
|
+
return {
|
|
58
|
+
name: COMMAND_ALIASES[normalized] ?? normalized,
|
|
59
|
+
args: rest.join(" ").trim()
|
|
60
|
+
};
|
|
61
|
+
}
|
|
62
|
+
function getSlashCommands(options = {}) {
|
|
63
|
+
const thinkLevels = listThinkingLevelLabels(options.provider, options.model);
|
|
64
|
+
const verboseCompletions = createLevelCompletion(VERBOSE_LEVELS);
|
|
65
|
+
const fastCompletions = createLevelCompletion(FAST_LEVELS);
|
|
66
|
+
const reasoningCompletions = createLevelCompletion(REASONING_LEVELS);
|
|
67
|
+
const usageCompletions = createLevelCompletion(USAGE_FOOTER_LEVELS);
|
|
68
|
+
const elevatedCompletions = createLevelCompletion(ELEVATED_LEVELS);
|
|
69
|
+
const activationCompletions = createLevelCompletion(ACTIVATION_LEVELS);
|
|
70
|
+
const commands = [
|
|
71
|
+
{
|
|
72
|
+
name: "help",
|
|
73
|
+
description: "Show slash command help"
|
|
74
|
+
},
|
|
75
|
+
{
|
|
76
|
+
name: "status",
|
|
77
|
+
description: "Show gateway status summary"
|
|
78
|
+
},
|
|
79
|
+
{
|
|
80
|
+
name: "agent",
|
|
81
|
+
description: "Switch agent (or open picker)"
|
|
82
|
+
},
|
|
83
|
+
{
|
|
84
|
+
name: "agents",
|
|
85
|
+
description: "Open agent picker"
|
|
86
|
+
},
|
|
87
|
+
{
|
|
88
|
+
name: "session",
|
|
89
|
+
description: "Switch session (or open picker)"
|
|
90
|
+
},
|
|
91
|
+
{
|
|
92
|
+
name: "sessions",
|
|
93
|
+
description: "Open session picker"
|
|
94
|
+
},
|
|
95
|
+
{
|
|
96
|
+
name: "model",
|
|
97
|
+
description: "Set model (or open picker)"
|
|
98
|
+
},
|
|
99
|
+
{
|
|
100
|
+
name: "models",
|
|
101
|
+
description: "Open model picker"
|
|
102
|
+
},
|
|
103
|
+
{
|
|
104
|
+
name: "think",
|
|
105
|
+
description: "Set thinking level",
|
|
106
|
+
getArgumentCompletions: (prefix) => thinkLevels.filter((v) => v.startsWith(prefix.toLowerCase())).map((value) => ({
|
|
107
|
+
value,
|
|
108
|
+
label: value
|
|
109
|
+
}))
|
|
110
|
+
},
|
|
111
|
+
{
|
|
112
|
+
name: "fast",
|
|
113
|
+
description: "Set fast mode on/off",
|
|
114
|
+
getArgumentCompletions: fastCompletions
|
|
115
|
+
},
|
|
116
|
+
{
|
|
117
|
+
name: "verbose",
|
|
118
|
+
description: "Set verbose on/off",
|
|
119
|
+
getArgumentCompletions: verboseCompletions
|
|
120
|
+
},
|
|
121
|
+
{
|
|
122
|
+
name: "reasoning",
|
|
123
|
+
description: "Set reasoning on/off",
|
|
124
|
+
getArgumentCompletions: reasoningCompletions
|
|
125
|
+
},
|
|
126
|
+
{
|
|
127
|
+
name: "usage",
|
|
128
|
+
description: "Toggle per-response usage line",
|
|
129
|
+
getArgumentCompletions: usageCompletions
|
|
130
|
+
},
|
|
131
|
+
{
|
|
132
|
+
name: "elevated",
|
|
133
|
+
description: "Set elevated on/off/ask/full",
|
|
134
|
+
getArgumentCompletions: elevatedCompletions
|
|
135
|
+
},
|
|
136
|
+
{
|
|
137
|
+
name: "elev",
|
|
138
|
+
description: "Alias for /elevated",
|
|
139
|
+
getArgumentCompletions: elevatedCompletions
|
|
140
|
+
},
|
|
141
|
+
{
|
|
142
|
+
name: "activation",
|
|
143
|
+
description: "Set group activation",
|
|
144
|
+
getArgumentCompletions: activationCompletions
|
|
145
|
+
},
|
|
146
|
+
{
|
|
147
|
+
name: "abort",
|
|
148
|
+
description: "Abort active run"
|
|
149
|
+
},
|
|
150
|
+
{
|
|
151
|
+
name: "new",
|
|
152
|
+
description: "Reset the session"
|
|
153
|
+
},
|
|
154
|
+
{
|
|
155
|
+
name: "reset",
|
|
156
|
+
description: "Reset the session"
|
|
157
|
+
},
|
|
158
|
+
{
|
|
159
|
+
name: "settings",
|
|
160
|
+
description: "Open settings"
|
|
161
|
+
},
|
|
162
|
+
{
|
|
163
|
+
name: "exit",
|
|
164
|
+
description: "Exit the TUI"
|
|
165
|
+
},
|
|
166
|
+
{
|
|
167
|
+
name: "quit",
|
|
168
|
+
description: "Exit the TUI"
|
|
169
|
+
}
|
|
170
|
+
];
|
|
171
|
+
const seen = new Set(commands.map((command) => command.name));
|
|
172
|
+
const gatewayCommands = options.cfg ? listChatCommandsForConfig(options.cfg) : listChatCommands();
|
|
173
|
+
for (const command of gatewayCommands) {
|
|
174
|
+
const aliases = command.textAliases.length > 0 ? command.textAliases : [`/${command.key}`];
|
|
175
|
+
for (const alias of aliases) {
|
|
176
|
+
const name = alias.replace(/^\//, "").trim();
|
|
177
|
+
if (!name || seen.has(name)) continue;
|
|
178
|
+
seen.add(name);
|
|
179
|
+
commands.push({
|
|
180
|
+
name,
|
|
181
|
+
description: command.description
|
|
182
|
+
});
|
|
183
|
+
}
|
|
184
|
+
}
|
|
185
|
+
return commands;
|
|
186
|
+
}
|
|
187
|
+
function helpText(options = {}) {
|
|
188
|
+
return [
|
|
189
|
+
"Slash commands:",
|
|
190
|
+
"/help",
|
|
191
|
+
"/commands",
|
|
192
|
+
"/status",
|
|
193
|
+
"/agent <id> (or /agents)",
|
|
194
|
+
"/session <key> (or /sessions)",
|
|
195
|
+
"/model <provider/model> (or /models)",
|
|
196
|
+
`/think <${formatThinkingLevels(options.provider, options.model, "|")}>`,
|
|
197
|
+
"/fast <status|on|off>",
|
|
198
|
+
"/verbose <on|off>",
|
|
199
|
+
"/reasoning <on|off>",
|
|
200
|
+
"/usage <off|tokens|full>",
|
|
201
|
+
"/elevated <on|off|ask|full>",
|
|
202
|
+
"/elev <on|off|ask|full>",
|
|
203
|
+
"/activation <mention|always>",
|
|
204
|
+
"/new or /reset",
|
|
205
|
+
"/abort",
|
|
206
|
+
"/settings",
|
|
207
|
+
"/exit"
|
|
208
|
+
].join("\n");
|
|
209
|
+
}
|
|
210
|
+
//#endregion
|
|
211
|
+
//#region src/tui/theme/syntax-theme.ts
|
|
212
|
+
/**
|
|
213
|
+
* Syntax highlighting theme for code blocks.
|
|
214
|
+
* Uses chalk functions to style different token types.
|
|
215
|
+
*/
|
|
216
|
+
function createSyntaxTheme(fallback, light = false) {
|
|
217
|
+
if (light) return {
|
|
218
|
+
keyword: chalk.hex("#AF00DB"),
|
|
219
|
+
built_in: chalk.hex("#267F99"),
|
|
220
|
+
type: chalk.hex("#267F99"),
|
|
221
|
+
literal: chalk.hex("#0000FF"),
|
|
222
|
+
number: chalk.hex("#098658"),
|
|
223
|
+
string: chalk.hex("#A31515"),
|
|
224
|
+
regexp: chalk.hex("#811F3F"),
|
|
225
|
+
symbol: chalk.hex("#098658"),
|
|
226
|
+
class: chalk.hex("#267F99"),
|
|
227
|
+
function: chalk.hex("#795E26"),
|
|
228
|
+
title: chalk.hex("#795E26"),
|
|
229
|
+
params: chalk.hex("#001080"),
|
|
230
|
+
comment: chalk.hex("#008000"),
|
|
231
|
+
doctag: chalk.hex("#008000"),
|
|
232
|
+
meta: chalk.hex("#001080"),
|
|
233
|
+
"meta-keyword": chalk.hex("#AF00DB"),
|
|
234
|
+
"meta-string": chalk.hex("#A31515"),
|
|
235
|
+
section: chalk.hex("#795E26"),
|
|
236
|
+
tag: chalk.hex("#800000"),
|
|
237
|
+
name: chalk.hex("#001080"),
|
|
238
|
+
attr: chalk.hex("#C50000"),
|
|
239
|
+
attribute: chalk.hex("#C50000"),
|
|
240
|
+
variable: chalk.hex("#001080"),
|
|
241
|
+
bullet: chalk.hex("#795E26"),
|
|
242
|
+
code: chalk.hex("#A31515"),
|
|
243
|
+
emphasis: chalk.italic,
|
|
244
|
+
strong: chalk.bold,
|
|
245
|
+
formula: chalk.hex("#AF00DB"),
|
|
246
|
+
link: chalk.hex("#267F99"),
|
|
247
|
+
quote: chalk.hex("#008000"),
|
|
248
|
+
addition: chalk.hex("#098658"),
|
|
249
|
+
deletion: chalk.hex("#A31515"),
|
|
250
|
+
"selector-tag": chalk.hex("#800000"),
|
|
251
|
+
"selector-id": chalk.hex("#800000"),
|
|
252
|
+
"selector-class": chalk.hex("#800000"),
|
|
253
|
+
"selector-attr": chalk.hex("#800000"),
|
|
254
|
+
"selector-pseudo": chalk.hex("#800000"),
|
|
255
|
+
"template-tag": chalk.hex("#AF00DB"),
|
|
256
|
+
"template-variable": chalk.hex("#001080"),
|
|
257
|
+
default: fallback
|
|
258
|
+
};
|
|
259
|
+
return {
|
|
260
|
+
keyword: chalk.hex("#C586C0"),
|
|
261
|
+
built_in: chalk.hex("#4EC9B0"),
|
|
262
|
+
type: chalk.hex("#4EC9B0"),
|
|
263
|
+
literal: chalk.hex("#569CD6"),
|
|
264
|
+
number: chalk.hex("#B5CEA8"),
|
|
265
|
+
string: chalk.hex("#CE9178"),
|
|
266
|
+
regexp: chalk.hex("#D16969"),
|
|
267
|
+
symbol: chalk.hex("#B5CEA8"),
|
|
268
|
+
class: chalk.hex("#4EC9B0"),
|
|
269
|
+
function: chalk.hex("#DCDCAA"),
|
|
270
|
+
title: chalk.hex("#DCDCAA"),
|
|
271
|
+
params: chalk.hex("#9CDCFE"),
|
|
272
|
+
comment: chalk.hex("#6A9955"),
|
|
273
|
+
doctag: chalk.hex("#608B4E"),
|
|
274
|
+
meta: chalk.hex("#9CDCFE"),
|
|
275
|
+
"meta-keyword": chalk.hex("#C586C0"),
|
|
276
|
+
"meta-string": chalk.hex("#CE9178"),
|
|
277
|
+
section: chalk.hex("#DCDCAA"),
|
|
278
|
+
tag: chalk.hex("#569CD6"),
|
|
279
|
+
name: chalk.hex("#9CDCFE"),
|
|
280
|
+
attr: chalk.hex("#9CDCFE"),
|
|
281
|
+
attribute: chalk.hex("#9CDCFE"),
|
|
282
|
+
variable: chalk.hex("#9CDCFE"),
|
|
283
|
+
bullet: chalk.hex("#D7BA7D"),
|
|
284
|
+
code: chalk.hex("#CE9178"),
|
|
285
|
+
emphasis: chalk.italic,
|
|
286
|
+
strong: chalk.bold,
|
|
287
|
+
formula: chalk.hex("#C586C0"),
|
|
288
|
+
link: chalk.hex("#4EC9B0"),
|
|
289
|
+
quote: chalk.hex("#6A9955"),
|
|
290
|
+
addition: chalk.hex("#B5CEA8"),
|
|
291
|
+
deletion: chalk.hex("#F44747"),
|
|
292
|
+
"selector-tag": chalk.hex("#D7BA7D"),
|
|
293
|
+
"selector-id": chalk.hex("#D7BA7D"),
|
|
294
|
+
"selector-class": chalk.hex("#D7BA7D"),
|
|
295
|
+
"selector-attr": chalk.hex("#D7BA7D"),
|
|
296
|
+
"selector-pseudo": chalk.hex("#D7BA7D"),
|
|
297
|
+
"template-tag": chalk.hex("#C586C0"),
|
|
298
|
+
"template-variable": chalk.hex("#9CDCFE"),
|
|
299
|
+
default: fallback
|
|
300
|
+
};
|
|
301
|
+
}
|
|
302
|
+
//#endregion
|
|
303
|
+
//#region src/tui/theme/theme.ts
|
|
304
|
+
const DARK_TEXT = "#E8E3D5";
|
|
305
|
+
const LIGHT_TEXT = "#1E1E1E";
|
|
306
|
+
const XTERM_LEVELS = [
|
|
307
|
+
0,
|
|
308
|
+
95,
|
|
309
|
+
135,
|
|
310
|
+
175,
|
|
311
|
+
215,
|
|
312
|
+
255
|
|
313
|
+
];
|
|
314
|
+
function channelToSrgb(value) {
|
|
315
|
+
const normalized = value / 255;
|
|
316
|
+
return normalized <= .03928 ? normalized / 12.92 : ((normalized + .055) / 1.055) ** 2.4;
|
|
317
|
+
}
|
|
318
|
+
function relativeLuminanceRgb(r, g, b) {
|
|
319
|
+
const red = channelToSrgb(r);
|
|
320
|
+
const green = channelToSrgb(g);
|
|
321
|
+
const blue = channelToSrgb(b);
|
|
322
|
+
return .2126 * red + .7152 * green + .0722 * blue;
|
|
323
|
+
}
|
|
324
|
+
function relativeLuminanceHex(hex) {
|
|
325
|
+
return relativeLuminanceRgb(Number.parseInt(hex.slice(1, 3), 16), Number.parseInt(hex.slice(3, 5), 16), Number.parseInt(hex.slice(5, 7), 16));
|
|
326
|
+
}
|
|
327
|
+
function contrastRatio(background, foregroundHex) {
|
|
328
|
+
const foreground = relativeLuminanceHex(foregroundHex);
|
|
329
|
+
const lighter = Math.max(background, foreground);
|
|
330
|
+
const darker = Math.min(background, foreground);
|
|
331
|
+
return (lighter + .05) / (darker + .05);
|
|
332
|
+
}
|
|
333
|
+
function pickHigherContrastText(r, g, b) {
|
|
334
|
+
const background = relativeLuminanceRgb(r, g, b);
|
|
335
|
+
return contrastRatio(background, LIGHT_TEXT) >= contrastRatio(background, DARK_TEXT);
|
|
336
|
+
}
|
|
337
|
+
function isLightBackground() {
|
|
338
|
+
const explicit = process.env.OPENCLAW_THEME?.toLowerCase();
|
|
339
|
+
if (explicit === "light") return true;
|
|
340
|
+
if (explicit === "dark") return false;
|
|
341
|
+
const colorfgbg = process.env.COLORFGBG;
|
|
342
|
+
if (colorfgbg && colorfgbg.length <= 64) {
|
|
343
|
+
const sep = colorfgbg.lastIndexOf(";");
|
|
344
|
+
const bg = Number.parseInt(sep >= 0 ? colorfgbg.slice(sep + 1) : colorfgbg, 10);
|
|
345
|
+
if (bg >= 0 && bg <= 255) {
|
|
346
|
+
if (bg <= 15) return bg === 7 || bg === 15;
|
|
347
|
+
if (bg >= 232) return bg >= 244;
|
|
348
|
+
const cubeIndex = bg - 16;
|
|
349
|
+
const bVal = XTERM_LEVELS[cubeIndex % 6];
|
|
350
|
+
const gVal = XTERM_LEVELS[Math.floor(cubeIndex / 6) % 6];
|
|
351
|
+
const rVal = XTERM_LEVELS[Math.floor(cubeIndex / 36)];
|
|
352
|
+
return pickHigherContrastText(rVal, gVal, bVal);
|
|
353
|
+
}
|
|
354
|
+
}
|
|
355
|
+
return false;
|
|
356
|
+
}
|
|
357
|
+
/** Whether the terminal has a light background. Exported for testing only. */
|
|
358
|
+
const lightMode = isLightBackground();
|
|
359
|
+
const palette = lightMode ? {
|
|
360
|
+
text: "#1E1E1E",
|
|
361
|
+
dim: "#5B6472",
|
|
362
|
+
accent: "#B45309",
|
|
363
|
+
accentSoft: "#C2410C",
|
|
364
|
+
border: "#5B6472",
|
|
365
|
+
userBg: "#F3F0E8",
|
|
366
|
+
userText: "#1E1E1E",
|
|
367
|
+
systemText: "#4B5563",
|
|
368
|
+
toolPendingBg: "#EFF6FF",
|
|
369
|
+
toolSuccessBg: "#ECFDF5",
|
|
370
|
+
toolErrorBg: "#FEF2F2",
|
|
371
|
+
toolTitle: "#B45309",
|
|
372
|
+
toolOutput: "#374151",
|
|
373
|
+
quote: "#1D4ED8",
|
|
374
|
+
quoteBorder: "#2563EB",
|
|
375
|
+
code: "#92400E",
|
|
376
|
+
codeBlock: "#F9FAFB",
|
|
377
|
+
codeBorder: "#92400E",
|
|
378
|
+
link: "#047857",
|
|
379
|
+
error: "#DC2626",
|
|
380
|
+
success: "#047857"
|
|
381
|
+
} : {
|
|
382
|
+
text: "#E8E3D5",
|
|
383
|
+
dim: "#7B7F87",
|
|
384
|
+
accent: "#F6C453",
|
|
385
|
+
accentSoft: "#F2A65A",
|
|
386
|
+
border: "#3C414B",
|
|
387
|
+
userBg: "#2B2F36",
|
|
388
|
+
userText: "#F3EEE0",
|
|
389
|
+
systemText: "#9BA3B2",
|
|
390
|
+
toolPendingBg: "#1F2A2F",
|
|
391
|
+
toolSuccessBg: "#1E2D23",
|
|
392
|
+
toolErrorBg: "#2F1F1F",
|
|
393
|
+
toolTitle: "#F6C453",
|
|
394
|
+
toolOutput: "#E1DACB",
|
|
395
|
+
quote: "#8CC8FF",
|
|
396
|
+
quoteBorder: "#3B4D6B",
|
|
397
|
+
code: "#F0C987",
|
|
398
|
+
codeBlock: "#1E232A",
|
|
399
|
+
codeBorder: "#343A45",
|
|
400
|
+
link: "#7DD3A5",
|
|
401
|
+
error: "#F97066",
|
|
402
|
+
success: "#7DD3A5"
|
|
403
|
+
};
|
|
404
|
+
const fg = (hex) => (text) => chalk.hex(hex)(text);
|
|
405
|
+
const bg = (hex) => (text) => chalk.bgHex(hex)(text);
|
|
406
|
+
const syntaxTheme = createSyntaxTheme(fg(palette.code), lightMode);
|
|
407
|
+
/**
|
|
408
|
+
* Highlight code with syntax coloring.
|
|
409
|
+
* Returns an array of lines with ANSI escape codes.
|
|
410
|
+
*/
|
|
411
|
+
function highlightCode(code, lang) {
|
|
412
|
+
try {
|
|
413
|
+
return highlight(code, {
|
|
414
|
+
language: lang && supportsLanguage(lang) ? lang : void 0,
|
|
415
|
+
theme: syntaxTheme,
|
|
416
|
+
ignoreIllegals: true
|
|
417
|
+
}).split("\n");
|
|
418
|
+
} catch {
|
|
419
|
+
return code.split("\n").map((line) => fg(palette.code)(line));
|
|
420
|
+
}
|
|
421
|
+
}
|
|
422
|
+
const theme = {
|
|
423
|
+
fg: fg(palette.text),
|
|
424
|
+
assistantText: (text) => text,
|
|
425
|
+
dim: fg(palette.dim),
|
|
426
|
+
accent: fg(palette.accent),
|
|
427
|
+
accentSoft: fg(palette.accentSoft),
|
|
428
|
+
success: fg(palette.success),
|
|
429
|
+
error: fg(palette.error),
|
|
430
|
+
header: (text) => chalk.bold(fg(palette.accent)(text)),
|
|
431
|
+
system: fg(palette.systemText),
|
|
432
|
+
userBg: bg(palette.userBg),
|
|
433
|
+
userText: fg(palette.userText),
|
|
434
|
+
toolTitle: fg(palette.toolTitle),
|
|
435
|
+
toolOutput: fg(palette.toolOutput),
|
|
436
|
+
toolPendingBg: bg(palette.toolPendingBg),
|
|
437
|
+
toolSuccessBg: bg(palette.toolSuccessBg),
|
|
438
|
+
toolErrorBg: bg(palette.toolErrorBg),
|
|
439
|
+
border: fg(palette.border),
|
|
440
|
+
bold: (text) => chalk.bold(text),
|
|
441
|
+
italic: (text) => chalk.italic(text)
|
|
442
|
+
};
|
|
443
|
+
const markdownTheme = {
|
|
444
|
+
heading: (text) => chalk.bold(fg(palette.accent)(text)),
|
|
445
|
+
link: (text) => fg(palette.link)(text),
|
|
446
|
+
linkUrl: (text) => chalk.dim(text),
|
|
447
|
+
code: (text) => fg(palette.code)(text),
|
|
448
|
+
codeBlock: (text) => fg(palette.code)(text),
|
|
449
|
+
codeBlockBorder: (text) => fg(palette.codeBorder)(text),
|
|
450
|
+
quote: (text) => fg(palette.quote)(text),
|
|
451
|
+
quoteBorder: (text) => fg(palette.quoteBorder)(text),
|
|
452
|
+
hr: (text) => fg(palette.border)(text),
|
|
453
|
+
listBullet: (text) => fg(palette.accentSoft)(text),
|
|
454
|
+
bold: (text) => chalk.bold(text),
|
|
455
|
+
italic: (text) => chalk.italic(text),
|
|
456
|
+
strikethrough: (text) => chalk.strikethrough(text),
|
|
457
|
+
underline: (text) => chalk.underline(text),
|
|
458
|
+
highlightCode
|
|
459
|
+
};
|
|
460
|
+
const baseSelectListTheme = {
|
|
461
|
+
selectedPrefix: (text) => fg(palette.accent)(text),
|
|
462
|
+
selectedText: (text) => chalk.bold(fg(palette.accent)(text)),
|
|
463
|
+
description: (text) => fg(palette.dim)(text),
|
|
464
|
+
scrollInfo: (text) => fg(palette.dim)(text),
|
|
465
|
+
noMatch: (text) => fg(palette.dim)(text)
|
|
466
|
+
};
|
|
467
|
+
const selectListTheme = baseSelectListTheme;
|
|
468
|
+
const filterableSelectListTheme = {
|
|
469
|
+
...baseSelectListTheme,
|
|
470
|
+
filterLabel: (text) => fg(palette.dim)(text)
|
|
471
|
+
};
|
|
472
|
+
const settingsListTheme = {
|
|
473
|
+
label: (text, selected) => selected ? chalk.bold(fg(palette.accent)(text)) : fg(palette.text)(text),
|
|
474
|
+
value: (text, selected) => selected ? fg(palette.accentSoft)(text) : fg(palette.dim)(text),
|
|
475
|
+
description: (text) => fg(palette.systemText)(text),
|
|
476
|
+
cursor: fg(palette.accent)("→ "),
|
|
477
|
+
hint: (text) => fg(palette.dim)(text)
|
|
478
|
+
};
|
|
479
|
+
const editorTheme = {
|
|
480
|
+
borderColor: (text) => fg(palette.border)(text),
|
|
481
|
+
selectList: selectListTheme
|
|
482
|
+
};
|
|
483
|
+
const searchableSelectListTheme = {
|
|
484
|
+
...baseSelectListTheme,
|
|
485
|
+
searchPrompt: (text) => fg(palette.accentSoft)(text),
|
|
486
|
+
searchInput: (text) => fg(palette.text)(text),
|
|
487
|
+
matchHighlight: (text) => chalk.bold(fg(palette.accent)(text))
|
|
488
|
+
};
|
|
489
|
+
//#endregion
|
|
490
|
+
//#region src/tui/osc8-hyperlinks.ts
|
|
491
|
+
const SGR_PATTERN = "\\x1b\\[[0-9;]*m";
|
|
492
|
+
const OSC8_PATTERN = "\\x1b\\]8;;.*?(?:\\x07|\\x1b\\\\)";
|
|
493
|
+
const ANSI_RE = new RegExp(`${SGR_PATTERN}|${OSC8_PATTERN}`, "g");
|
|
494
|
+
const SGR_START_RE = new RegExp(`^${SGR_PATTERN}`);
|
|
495
|
+
const OSC8_START_RE = new RegExp(`^${OSC8_PATTERN}`);
|
|
496
|
+
/**
|
|
497
|
+
* Extract all unique URLs from raw markdown text.
|
|
498
|
+
* Finds both bare URLs and markdown link hrefs [text](url).
|
|
499
|
+
*/
|
|
500
|
+
function extractUrls(markdown) {
|
|
501
|
+
const urls = /* @__PURE__ */ new Set();
|
|
502
|
+
const mdLinkRe = /\[(?:[^\]]*)\]\(\s*<?(https?:\/\/[^)\s>]+)>?(?:\s+["'][^"']*["'])?\s*\)/g;
|
|
503
|
+
let m;
|
|
504
|
+
while ((m = mdLinkRe.exec(markdown)) !== null) urls.add(m[1]);
|
|
505
|
+
const stripped = markdown.replace(/\[(?:[^\]]*)\]\(\s*<?https?:\/\/[^)\s>]+>?(?:\s+["'][^"']*["'])?\s*\)/g, "");
|
|
506
|
+
const bareRe = /https?:\/\/[^\s)\]>]+/g;
|
|
507
|
+
while ((m = bareRe.exec(stripped)) !== null) urls.add(m[0]);
|
|
508
|
+
return [...urls];
|
|
509
|
+
}
|
|
510
|
+
/** Strip ANSI SGR and OSC 8 sequences to get visible text. */
|
|
511
|
+
function stripAnsi(input) {
|
|
512
|
+
return input.replace(ANSI_RE, "");
|
|
513
|
+
}
|
|
514
|
+
/**
|
|
515
|
+
* Find URL ranges in a line's visible text, handling cross-line URL splits.
|
|
516
|
+
*/
|
|
517
|
+
function findUrlRanges(visibleText, knownUrls, pending) {
|
|
518
|
+
const ranges = [];
|
|
519
|
+
let newPending = null;
|
|
520
|
+
let searchFrom = 0;
|
|
521
|
+
if (pending) {
|
|
522
|
+
const remaining = pending.url.slice(pending.consumed);
|
|
523
|
+
const trimmed = visibleText.trimStart();
|
|
524
|
+
const leadingSpaces = visibleText.length - trimmed.length;
|
|
525
|
+
let matchLen = 0;
|
|
526
|
+
for (let j = 0; j < remaining.length && j < trimmed.length; j++) if (remaining[j] === trimmed[j]) matchLen++;
|
|
527
|
+
else break;
|
|
528
|
+
if (matchLen > 0) {
|
|
529
|
+
ranges.push({
|
|
530
|
+
start: leadingSpaces,
|
|
531
|
+
end: leadingSpaces + matchLen,
|
|
532
|
+
url: pending.url
|
|
533
|
+
});
|
|
534
|
+
searchFrom = leadingSpaces + matchLen;
|
|
535
|
+
if (pending.consumed + matchLen < pending.url.length) newPending = {
|
|
536
|
+
url: pending.url,
|
|
537
|
+
consumed: pending.consumed + matchLen
|
|
538
|
+
};
|
|
539
|
+
}
|
|
540
|
+
}
|
|
541
|
+
const urlRe = /https?:\/\/[^\s)\]>]+/g;
|
|
542
|
+
urlRe.lastIndex = searchFrom;
|
|
543
|
+
let match;
|
|
544
|
+
while ((match = urlRe.exec(visibleText)) !== null) {
|
|
545
|
+
const fragment = match[0];
|
|
546
|
+
const start = match.index;
|
|
547
|
+
let resolvedUrl = fragment;
|
|
548
|
+
let found = false;
|
|
549
|
+
for (const known of knownUrls) if (known === fragment) {
|
|
550
|
+
resolvedUrl = known;
|
|
551
|
+
found = true;
|
|
552
|
+
break;
|
|
553
|
+
}
|
|
554
|
+
if (!found) {
|
|
555
|
+
let bestLen = 0;
|
|
556
|
+
for (const known of knownUrls) if (known.startsWith(fragment) && known.length > bestLen) {
|
|
557
|
+
resolvedUrl = known;
|
|
558
|
+
bestLen = known.length;
|
|
559
|
+
found = true;
|
|
560
|
+
}
|
|
561
|
+
}
|
|
562
|
+
if (!found) {
|
|
563
|
+
let bestLen = 0;
|
|
564
|
+
for (const known of knownUrls) if (fragment.startsWith(known) && known.length > bestLen) {
|
|
565
|
+
resolvedUrl = known;
|
|
566
|
+
bestLen = known.length;
|
|
567
|
+
}
|
|
568
|
+
}
|
|
569
|
+
ranges.push({
|
|
570
|
+
start,
|
|
571
|
+
end: start + fragment.length,
|
|
572
|
+
url: resolvedUrl
|
|
573
|
+
});
|
|
574
|
+
if (resolvedUrl.length > fragment.length && resolvedUrl.startsWith(fragment)) newPending = {
|
|
575
|
+
url: resolvedUrl,
|
|
576
|
+
consumed: fragment.length
|
|
577
|
+
};
|
|
578
|
+
}
|
|
579
|
+
return {
|
|
580
|
+
ranges,
|
|
581
|
+
pending: newPending
|
|
582
|
+
};
|
|
583
|
+
}
|
|
584
|
+
/**
|
|
585
|
+
* Apply OSC 8 hyperlink sequences to a line based on visible-text URL ranges.
|
|
586
|
+
* Walks through the raw string character by character, inserting OSC 8
|
|
587
|
+
* open/close sequences at URL range boundaries while preserving ANSI codes.
|
|
588
|
+
*/
|
|
589
|
+
function applyOsc8Ranges(line, ranges) {
|
|
590
|
+
if (ranges.length === 0) return line;
|
|
591
|
+
const urlAt = /* @__PURE__ */ new Map();
|
|
592
|
+
for (const r of ranges) for (let p = r.start; p < r.end; p++) urlAt.set(p, r.url);
|
|
593
|
+
let result = "";
|
|
594
|
+
let visiblePos = 0;
|
|
595
|
+
let activeUrl = null;
|
|
596
|
+
let i = 0;
|
|
597
|
+
while (i < line.length) {
|
|
598
|
+
if (line.charCodeAt(i) === 27) {
|
|
599
|
+
const sgr = line.slice(i).match(SGR_START_RE);
|
|
600
|
+
if (sgr) {
|
|
601
|
+
result += sgr[0];
|
|
602
|
+
i += sgr[0].length;
|
|
603
|
+
continue;
|
|
604
|
+
}
|
|
605
|
+
const osc = line.slice(i).match(OSC8_START_RE);
|
|
606
|
+
if (osc) {
|
|
607
|
+
result += osc[0];
|
|
608
|
+
i += osc[0].length;
|
|
609
|
+
continue;
|
|
610
|
+
}
|
|
611
|
+
}
|
|
612
|
+
const targetUrl = urlAt.get(visiblePos) ?? null;
|
|
613
|
+
if (targetUrl !== activeUrl) {
|
|
614
|
+
if (activeUrl !== null) result += "\x1B]8;;\x07";
|
|
615
|
+
if (targetUrl !== null) result += `\x1b]8;;${targetUrl}\x07`;
|
|
616
|
+
activeUrl = targetUrl;
|
|
617
|
+
}
|
|
618
|
+
result += line[i];
|
|
619
|
+
visiblePos++;
|
|
620
|
+
i++;
|
|
621
|
+
}
|
|
622
|
+
if (activeUrl !== null) result += "\x1B]8;;\x07";
|
|
623
|
+
return result;
|
|
624
|
+
}
|
|
625
|
+
/**
|
|
626
|
+
* Add OSC 8 hyperlinks to rendered lines using a pre-extracted URL list.
|
|
627
|
+
*
|
|
628
|
+
* For each line, finds URL-like substrings in the visible text, matches them
|
|
629
|
+
* against known URLs, and wraps each fragment with OSC 8 escape sequences.
|
|
630
|
+
* Handles URLs broken across multiple lines by pi-tui's word wrapping.
|
|
631
|
+
*/
|
|
632
|
+
function addOsc8Hyperlinks(lines, urls) {
|
|
633
|
+
if (urls.length === 0) return lines;
|
|
634
|
+
let pending = null;
|
|
635
|
+
return lines.map((line) => {
|
|
636
|
+
const result = findUrlRanges(stripAnsi(line), urls, pending);
|
|
637
|
+
pending = result.pending;
|
|
638
|
+
return applyOsc8Ranges(line, result.ranges);
|
|
639
|
+
});
|
|
640
|
+
}
|
|
641
|
+
//#endregion
|
|
642
|
+
//#region src/tui/components/hyperlink-markdown.ts
|
|
643
|
+
/**
|
|
644
|
+
* Wrapper around pi-tui's Markdown component that adds OSC 8 terminal
|
|
645
|
+
* hyperlinks to rendered output, making URLs clickable even when broken
|
|
646
|
+
* across multiple lines by word wrapping.
|
|
647
|
+
*/
|
|
648
|
+
var HyperlinkMarkdown = class {
|
|
649
|
+
constructor(text, paddingX, paddingY, theme, options) {
|
|
650
|
+
this.inner = new Markdown(text, paddingX, paddingY, theme, options);
|
|
651
|
+
this.urls = extractUrls(text);
|
|
652
|
+
}
|
|
653
|
+
render(width) {
|
|
654
|
+
return addOsc8Hyperlinks(this.inner.render(width), this.urls);
|
|
655
|
+
}
|
|
656
|
+
setText(text) {
|
|
657
|
+
this.inner.setText(text);
|
|
658
|
+
this.urls = extractUrls(text);
|
|
659
|
+
}
|
|
660
|
+
invalidate() {
|
|
661
|
+
this.inner.invalidate();
|
|
662
|
+
}
|
|
663
|
+
};
|
|
664
|
+
//#endregion
|
|
665
|
+
//#region src/tui/components/assistant-message.ts
|
|
666
|
+
var AssistantMessageComponent = class extends Container {
|
|
667
|
+
constructor(text) {
|
|
668
|
+
super();
|
|
669
|
+
this.body = new HyperlinkMarkdown(text, 1, 0, markdownTheme, { color: (line) => theme.assistantText(line) });
|
|
670
|
+
this.addChild(new Spacer(1));
|
|
671
|
+
this.addChild(this.body);
|
|
672
|
+
}
|
|
673
|
+
setText(text) {
|
|
674
|
+
this.body.setText(text);
|
|
675
|
+
}
|
|
676
|
+
};
|
|
677
|
+
//#endregion
|
|
678
|
+
//#region src/tui/components/btw-inline-message.ts
|
|
679
|
+
var BtwInlineMessage = class extends Container {
|
|
680
|
+
constructor(params) {
|
|
681
|
+
super();
|
|
682
|
+
this.setResult(params);
|
|
683
|
+
}
|
|
684
|
+
setResult(params) {
|
|
685
|
+
this.clear();
|
|
686
|
+
this.addChild(new Spacer(1));
|
|
687
|
+
this.addChild(new Text(theme.header(`BTW: ${params.question}`), 1, 0));
|
|
688
|
+
if (params.isError) this.addChild(new Text(theme.error(params.text), 1, 0));
|
|
689
|
+
else this.addChild(new AssistantMessageComponent(params.text));
|
|
690
|
+
this.addChild(new Text(theme.dim("Press Enter or Esc to dismiss"), 1, 0));
|
|
691
|
+
}
|
|
692
|
+
};
|
|
693
|
+
//#endregion
|
|
694
|
+
//#region src/tui/tui-formatters.ts
|
|
695
|
+
const REPLACEMENT_CHAR_RE = /\uFFFD/g;
|
|
696
|
+
const MAX_TOKEN_CHARS = 32;
|
|
697
|
+
const LONG_TOKEN_RE = /\S{33,}/g;
|
|
698
|
+
const LONG_TOKEN_TEST_RE = /\S{33,}/;
|
|
699
|
+
const BINARY_LINE_REPLACEMENT_THRESHOLD = 12;
|
|
700
|
+
const URL_PREFIX_RE = /^(https?:\/\/|file:\/\/)/i;
|
|
701
|
+
const WINDOWS_DRIVE_RE = /^[a-zA-Z]:[\\/]/;
|
|
702
|
+
const FILE_LIKE_RE = /^[a-zA-Z0-9._-]+$/;
|
|
703
|
+
const EDGE_PUNCTUATION_RE = /^[`"'([{<]+|[`"')\]}>.,:;!?]+$/g;
|
|
704
|
+
const TOKENISH_MIN_LENGTH = 24;
|
|
705
|
+
const RTL_SCRIPT_RE = /[\u0590-\u08ff\ufb1d-\ufdff\ufe70-\ufefc]/;
|
|
706
|
+
const BIDI_CONTROL_RE = /[\u202a-\u202e\u2066-\u2069]/;
|
|
707
|
+
const RTL_ISOLATE_START = "";
|
|
708
|
+
const RTL_ISOLATE_END = "";
|
|
709
|
+
function hasControlChars(text) {
|
|
710
|
+
for (const char of text) {
|
|
711
|
+
const code = char.charCodeAt(0);
|
|
712
|
+
if (code <= 31 && code !== 9 && code !== 10 && code !== 13 || code >= 127 && code <= 159) return true;
|
|
713
|
+
}
|
|
714
|
+
return false;
|
|
715
|
+
}
|
|
716
|
+
function stripControlChars(text) {
|
|
717
|
+
if (!hasControlChars(text)) return text;
|
|
718
|
+
let sanitized = "";
|
|
719
|
+
for (const char of text) {
|
|
720
|
+
const code = char.charCodeAt(0);
|
|
721
|
+
if (!(code <= 31 && code !== 9 && code !== 10 && code !== 13) && !(code >= 127 && code <= 159)) sanitized += char;
|
|
722
|
+
}
|
|
723
|
+
return sanitized;
|
|
724
|
+
}
|
|
725
|
+
function chunkToken(token, maxChars) {
|
|
726
|
+
if (token.length <= maxChars) return [token];
|
|
727
|
+
const chunks = [];
|
|
728
|
+
for (let i = 0; i < token.length; i += maxChars) chunks.push(token.slice(i, i + maxChars));
|
|
729
|
+
return chunks;
|
|
730
|
+
}
|
|
731
|
+
function isCopySensitiveToken(token) {
|
|
732
|
+
const candidate = token.replace(EDGE_PUNCTUATION_RE, "") || token;
|
|
733
|
+
if (URL_PREFIX_RE.test(token)) return true;
|
|
734
|
+
if (token.startsWith("/") || token.startsWith("~/") || token.startsWith("./") || token.startsWith("../")) return true;
|
|
735
|
+
if (WINDOWS_DRIVE_RE.test(token) || token.startsWith("\\\\")) return true;
|
|
736
|
+
if (token.includes("/") || token.includes("\\")) return true;
|
|
737
|
+
if (token.includes("_") && FILE_LIKE_RE.test(token)) return true;
|
|
738
|
+
if (candidate.length >= TOKENISH_MIN_LENGTH && /[a-z]/i.test(candidate) && /\d/.test(candidate)) return true;
|
|
739
|
+
return false;
|
|
740
|
+
}
|
|
741
|
+
function normalizeLongTokenForDisplay(token) {
|
|
742
|
+
if (isCopySensitiveToken(token)) return token;
|
|
743
|
+
return chunkToken(token, MAX_TOKEN_CHARS).join(" ");
|
|
744
|
+
}
|
|
745
|
+
function redactBinaryLikeLine(line) {
|
|
746
|
+
const replacementCount = (line.match(REPLACEMENT_CHAR_RE) || []).length;
|
|
747
|
+
if (replacementCount >= BINARY_LINE_REPLACEMENT_THRESHOLD && replacementCount * 2 >= line.length) return "[binary data omitted]";
|
|
748
|
+
return line;
|
|
749
|
+
}
|
|
750
|
+
function isolateRtlLine(line) {
|
|
751
|
+
if (!RTL_SCRIPT_RE.test(line) || BIDI_CONTROL_RE.test(line)) return line;
|
|
752
|
+
return `${RTL_ISOLATE_START}${line}${RTL_ISOLATE_END}`;
|
|
753
|
+
}
|
|
754
|
+
function applyRtlIsolation(text) {
|
|
755
|
+
if (!RTL_SCRIPT_RE.test(text)) return text;
|
|
756
|
+
return text.split("\n").map((line) => isolateRtlLine(line)).join("\n");
|
|
757
|
+
}
|
|
758
|
+
function sanitizeRenderableText(text) {
|
|
759
|
+
if (!text) return text;
|
|
760
|
+
const hasAnsi = text.includes("\x1B");
|
|
761
|
+
const hasReplacementChars = text.includes("�");
|
|
762
|
+
const hasLongTokens = LONG_TOKEN_TEST_RE.test(text);
|
|
763
|
+
const hasControls = hasControlChars(text);
|
|
764
|
+
if (!hasAnsi && !hasReplacementChars && !hasLongTokens && !hasControls) return applyRtlIsolation(text);
|
|
765
|
+
const withoutAnsi = hasAnsi ? stripAnsi$1(text) : text;
|
|
766
|
+
const withoutControlChars = hasControls ? stripControlChars(withoutAnsi) : withoutAnsi;
|
|
767
|
+
const redacted = hasReplacementChars ? withoutControlChars.split("\n").map((line) => redactBinaryLikeLine(line)).join("\n") : withoutControlChars;
|
|
768
|
+
return applyRtlIsolation(LONG_TOKEN_TEST_RE.test(redacted) ? redacted.replace(LONG_TOKEN_RE, normalizeLongTokenForDisplay) : redacted);
|
|
769
|
+
}
|
|
770
|
+
function resolveFinalAssistantText(params) {
|
|
771
|
+
const finalText = params.finalText ?? "";
|
|
772
|
+
if (finalText.trim()) return finalText;
|
|
773
|
+
const streamedText = params.streamedText ?? "";
|
|
774
|
+
if (streamedText.trim()) return streamedText;
|
|
775
|
+
const errorMessage = params.errorMessage ?? "";
|
|
776
|
+
if (errorMessage.trim()) return formatRawAssistantErrorForUi(errorMessage);
|
|
777
|
+
return "(no output)";
|
|
778
|
+
}
|
|
779
|
+
function composeThinkingAndContent(params) {
|
|
780
|
+
const thinkingText = params.thinkingText?.trim() ?? "";
|
|
781
|
+
const contentText = params.contentText?.trim() ?? "";
|
|
782
|
+
const parts = [];
|
|
783
|
+
if (params.showThinking && thinkingText) parts.push(`[thinking]\n${thinkingText}`);
|
|
784
|
+
if (contentText) parts.push(contentText);
|
|
785
|
+
return parts.join("\n\n").trim();
|
|
786
|
+
}
|
|
787
|
+
function asMessageRecord(message) {
|
|
788
|
+
if (!message || typeof message !== "object") return;
|
|
789
|
+
return message;
|
|
790
|
+
}
|
|
791
|
+
function resolveMessageRecord(message) {
|
|
792
|
+
const record = asMessageRecord(message);
|
|
793
|
+
if (!record) return;
|
|
794
|
+
return {
|
|
795
|
+
record,
|
|
796
|
+
content: record.content
|
|
797
|
+
};
|
|
798
|
+
}
|
|
799
|
+
function formatAssistantErrorFromRecord(record) {
|
|
800
|
+
if ((typeof record.stopReason === "string" ? record.stopReason : "") !== "error") return "";
|
|
801
|
+
return formatRawAssistantErrorForUi(typeof record.errorMessage === "string" ? record.errorMessage : "");
|
|
802
|
+
}
|
|
803
|
+
function collectSanitizedBlockStrings(params) {
|
|
804
|
+
if (!Array.isArray(params.content)) return [];
|
|
805
|
+
const parts = [];
|
|
806
|
+
for (const block of params.content) {
|
|
807
|
+
if (!block || typeof block !== "object") continue;
|
|
808
|
+
const rec = block;
|
|
809
|
+
if (rec.type === params.blockType && typeof rec[params.valueKey] === "string") parts.push(sanitizeRenderableText(rec[params.valueKey]));
|
|
810
|
+
}
|
|
811
|
+
return parts;
|
|
812
|
+
}
|
|
813
|
+
/**
|
|
814
|
+
* Extract ONLY thinking blocks from message content.
|
|
815
|
+
* Model-agnostic: returns empty string if no thinking blocks exist.
|
|
816
|
+
*/
|
|
817
|
+
function extractThinkingFromMessage(message) {
|
|
818
|
+
const resolved = resolveMessageRecord(message);
|
|
819
|
+
if (!resolved) return "";
|
|
820
|
+
const { content } = resolved;
|
|
821
|
+
if (typeof content === "string") return "";
|
|
822
|
+
return collectSanitizedBlockStrings({
|
|
823
|
+
content,
|
|
824
|
+
blockType: "thinking",
|
|
825
|
+
valueKey: "thinking"
|
|
826
|
+
}).join("\n").trim();
|
|
827
|
+
}
|
|
828
|
+
/**
|
|
829
|
+
* Extract ONLY text content blocks from message (excludes thinking).
|
|
830
|
+
* Model-agnostic: works for any model with text content blocks.
|
|
831
|
+
*/
|
|
832
|
+
function extractContentFromMessage(message) {
|
|
833
|
+
const resolved = resolveMessageRecord(message);
|
|
834
|
+
if (!resolved) return "";
|
|
835
|
+
const { record, content } = resolved;
|
|
836
|
+
if (typeof content === "string") return sanitizeRenderableText(content).trim();
|
|
837
|
+
const parts = collectSanitizedBlockStrings({
|
|
838
|
+
content,
|
|
839
|
+
blockType: "text",
|
|
840
|
+
valueKey: "text"
|
|
841
|
+
});
|
|
842
|
+
if (parts.length > 0) return parts.join("\n").trim();
|
|
843
|
+
return formatAssistantErrorFromRecord(record);
|
|
844
|
+
}
|
|
845
|
+
function extractTextBlocks(content, opts) {
|
|
846
|
+
if (typeof content === "string") return sanitizeRenderableText(content).trim();
|
|
847
|
+
if (!Array.isArray(content)) return "";
|
|
848
|
+
const textParts = collectSanitizedBlockStrings({
|
|
849
|
+
content,
|
|
850
|
+
blockType: "text",
|
|
851
|
+
valueKey: "text"
|
|
852
|
+
});
|
|
853
|
+
return composeThinkingAndContent({
|
|
854
|
+
thinkingText: (opts?.includeThinking === true ? collectSanitizedBlockStrings({
|
|
855
|
+
content,
|
|
856
|
+
blockType: "thinking",
|
|
857
|
+
valueKey: "thinking"
|
|
858
|
+
}) : []).join("\n").trim(),
|
|
859
|
+
contentText: textParts.join("\n").trim(),
|
|
860
|
+
showThinking: opts?.includeThinking ?? false
|
|
861
|
+
});
|
|
862
|
+
}
|
|
863
|
+
function extractTextFromMessage(message, opts) {
|
|
864
|
+
const record = asMessageRecord(message);
|
|
865
|
+
if (!record) return "";
|
|
866
|
+
const text = extractTextBlocks(record.content, opts);
|
|
867
|
+
if (text) {
|
|
868
|
+
if (record.role === "user") return stripLeadingInboundMetadata(text);
|
|
869
|
+
return text;
|
|
870
|
+
}
|
|
871
|
+
const errorText = formatAssistantErrorFromRecord(record);
|
|
872
|
+
if (!errorText) return "";
|
|
873
|
+
return errorText;
|
|
874
|
+
}
|
|
875
|
+
function isCommandMessage(message) {
|
|
876
|
+
if (!message || typeof message !== "object") return false;
|
|
877
|
+
return message.command === true;
|
|
878
|
+
}
|
|
879
|
+
function formatTokens(total, context) {
|
|
880
|
+
if (total == null && context == null) return "tokens ?";
|
|
881
|
+
const totalLabel = total == null ? "?" : formatTokenCount(total);
|
|
882
|
+
if (context == null) return `tokens ${totalLabel}`;
|
|
883
|
+
const pct = typeof total === "number" && context > 0 ? Math.min(999, Math.round(total / context * 100)) : null;
|
|
884
|
+
return `tokens ${totalLabel}/${formatTokenCount(context)}${pct !== null ? ` (${pct}%)` : ""}`;
|
|
885
|
+
}
|
|
886
|
+
function formatContextUsageLine(params) {
|
|
887
|
+
const totalLabel = typeof params.total === "number" ? formatTokenCount(params.total) : "?";
|
|
888
|
+
const ctxLabel = typeof params.context === "number" ? formatTokenCount(params.context) : "?";
|
|
889
|
+
const pct = typeof params.percent === "number" ? Math.min(999, Math.round(params.percent)) : null;
|
|
890
|
+
const extra = [typeof params.remaining === "number" ? `${formatTokenCount(params.remaining)} left` : null, pct !== null ? `${pct}%` : null].filter(Boolean).join(", ");
|
|
891
|
+
return `tokens ${totalLabel}/${ctxLabel}${extra ? ` (${extra})` : ""}`;
|
|
892
|
+
}
|
|
893
|
+
function asString(value, fallback = "") {
|
|
894
|
+
if (typeof value === "string") return value;
|
|
895
|
+
if (typeof value === "number" || typeof value === "boolean") return String(value);
|
|
896
|
+
return fallback;
|
|
897
|
+
}
|
|
898
|
+
//#endregion
|
|
899
|
+
//#region src/tui/components/tool-execution.ts
|
|
900
|
+
const PREVIEW_LINES = 12;
|
|
901
|
+
function formatArgs(toolName, args) {
|
|
902
|
+
const detail = formatToolDetail(resolveToolDisplay({
|
|
903
|
+
name: toolName,
|
|
904
|
+
args
|
|
905
|
+
}));
|
|
906
|
+
if (detail) return sanitizeRenderableText(detail);
|
|
907
|
+
if (!args || typeof args !== "object") return "";
|
|
908
|
+
try {
|
|
909
|
+
return sanitizeRenderableText(JSON.stringify(args));
|
|
910
|
+
} catch {
|
|
911
|
+
return "";
|
|
912
|
+
}
|
|
913
|
+
}
|
|
914
|
+
function extractText(result) {
|
|
915
|
+
if (!result?.content) return "";
|
|
916
|
+
const lines = [];
|
|
917
|
+
for (const entry of result.content) if (entry.type === "text" && entry.text) lines.push(sanitizeRenderableText(entry.text));
|
|
918
|
+
else if (entry.type === "image") {
|
|
919
|
+
const mime = entry.mimeType ?? "image";
|
|
920
|
+
const size = entry.bytes ? ` ${Math.round(entry.bytes / 1024)}kb` : "";
|
|
921
|
+
const omitted = entry.omitted ? " (omitted)" : "";
|
|
922
|
+
lines.push(`[${mime}${size}${omitted}]`);
|
|
923
|
+
}
|
|
924
|
+
return lines.join("\n").trim();
|
|
925
|
+
}
|
|
926
|
+
var ToolExecutionComponent = class extends Container {
|
|
927
|
+
constructor(toolName, args) {
|
|
928
|
+
super();
|
|
929
|
+
this.expanded = false;
|
|
930
|
+
this.isError = false;
|
|
931
|
+
this.isPartial = true;
|
|
932
|
+
this.toolName = toolName;
|
|
933
|
+
this.args = args;
|
|
934
|
+
this.box = new Box(1, 1, (line) => theme.toolPendingBg(line));
|
|
935
|
+
this.header = new Text("", 0, 0);
|
|
936
|
+
this.argsLine = new Text("", 0, 0);
|
|
937
|
+
this.output = new Markdown("", 0, 0, markdownTheme, { color: (line) => theme.toolOutput(line) });
|
|
938
|
+
this.addChild(new Spacer(1));
|
|
939
|
+
this.addChild(this.box);
|
|
940
|
+
this.box.addChild(this.header);
|
|
941
|
+
this.box.addChild(this.argsLine);
|
|
942
|
+
this.box.addChild(this.output);
|
|
943
|
+
this.refresh();
|
|
944
|
+
}
|
|
945
|
+
setArgs(args) {
|
|
946
|
+
this.args = args;
|
|
947
|
+
this.refresh();
|
|
948
|
+
}
|
|
949
|
+
setExpanded(expanded) {
|
|
950
|
+
this.expanded = expanded;
|
|
951
|
+
this.refresh();
|
|
952
|
+
}
|
|
953
|
+
setResult(result, opts) {
|
|
954
|
+
this.result = result;
|
|
955
|
+
this.isPartial = false;
|
|
956
|
+
this.isError = Boolean(opts?.isError);
|
|
957
|
+
this.refresh();
|
|
958
|
+
}
|
|
959
|
+
setPartialResult(result) {
|
|
960
|
+
this.result = result;
|
|
961
|
+
this.isPartial = true;
|
|
962
|
+
this.refresh();
|
|
963
|
+
}
|
|
964
|
+
refresh() {
|
|
965
|
+
const bg = this.isPartial ? theme.toolPendingBg : this.isError ? theme.toolErrorBg : theme.toolSuccessBg;
|
|
966
|
+
this.box.setBgFn((line) => bg(line));
|
|
967
|
+
const display = resolveToolDisplay({
|
|
968
|
+
name: this.toolName,
|
|
969
|
+
args: this.args
|
|
970
|
+
});
|
|
971
|
+
const title = `${display.emoji} ${display.label}${this.isPartial ? " (running)" : ""}`;
|
|
972
|
+
this.header.setText(theme.toolTitle(theme.bold(title)));
|
|
973
|
+
const argLine = formatArgs(this.toolName, this.args);
|
|
974
|
+
this.argsLine.setText(argLine ? theme.dim(argLine) : theme.dim(" "));
|
|
975
|
+
const text = extractText(this.result) || (this.isPartial ? "…" : "");
|
|
976
|
+
if (!this.expanded && text) {
|
|
977
|
+
const lines = text.split("\n");
|
|
978
|
+
const preview = lines.length > PREVIEW_LINES ? `${lines.slice(0, PREVIEW_LINES).join("\n")}\n…` : text;
|
|
979
|
+
this.output.setText(preview);
|
|
980
|
+
} else this.output.setText(text);
|
|
981
|
+
}
|
|
982
|
+
};
|
|
983
|
+
//#endregion
|
|
984
|
+
//#region src/tui/components/markdown-message.ts
|
|
985
|
+
var MarkdownMessageComponent = class extends Container {
|
|
986
|
+
constructor(text, y, options) {
|
|
987
|
+
super();
|
|
988
|
+
this.body = new Markdown(text, 1, y, markdownTheme, options);
|
|
989
|
+
this.addChild(new Spacer(1));
|
|
990
|
+
this.addChild(this.body);
|
|
991
|
+
}
|
|
992
|
+
setText(text) {
|
|
993
|
+
this.body.setText(text);
|
|
994
|
+
}
|
|
995
|
+
};
|
|
996
|
+
//#endregion
|
|
997
|
+
//#region src/tui/components/user-message.ts
|
|
998
|
+
var UserMessageComponent = class extends MarkdownMessageComponent {
|
|
999
|
+
constructor(text) {
|
|
1000
|
+
super(text, 1, {
|
|
1001
|
+
bgColor: (line) => theme.userBg(line),
|
|
1002
|
+
color: (line) => theme.userText(line)
|
|
1003
|
+
});
|
|
1004
|
+
}
|
|
1005
|
+
};
|
|
1006
|
+
//#endregion
|
|
1007
|
+
//#region src/tui/components/chat-log.ts
|
|
1008
|
+
var ChatLog = class extends Container {
|
|
1009
|
+
constructor(maxComponents = 180) {
|
|
1010
|
+
super();
|
|
1011
|
+
this.toolById = /* @__PURE__ */ new Map();
|
|
1012
|
+
this.streamingRuns = /* @__PURE__ */ new Map();
|
|
1013
|
+
this.btwMessage = null;
|
|
1014
|
+
this.toolsExpanded = false;
|
|
1015
|
+
this.maxComponents = Math.max(20, Math.floor(maxComponents));
|
|
1016
|
+
}
|
|
1017
|
+
dropComponentReferences(component) {
|
|
1018
|
+
for (const [toolId, tool] of this.toolById.entries()) if (tool === component) this.toolById.delete(toolId);
|
|
1019
|
+
for (const [runId, message] of this.streamingRuns.entries()) if (message === component) this.streamingRuns.delete(runId);
|
|
1020
|
+
if (this.btwMessage === component) this.btwMessage = null;
|
|
1021
|
+
}
|
|
1022
|
+
pruneOverflow() {
|
|
1023
|
+
while (this.children.length > this.maxComponents) {
|
|
1024
|
+
const oldest = this.children[0];
|
|
1025
|
+
if (!oldest) return;
|
|
1026
|
+
this.removeChild(oldest);
|
|
1027
|
+
this.dropComponentReferences(oldest);
|
|
1028
|
+
}
|
|
1029
|
+
}
|
|
1030
|
+
append(component) {
|
|
1031
|
+
this.addChild(component);
|
|
1032
|
+
this.pruneOverflow();
|
|
1033
|
+
}
|
|
1034
|
+
clearAll() {
|
|
1035
|
+
this.clear();
|
|
1036
|
+
this.toolById.clear();
|
|
1037
|
+
this.streamingRuns.clear();
|
|
1038
|
+
this.btwMessage = null;
|
|
1039
|
+
}
|
|
1040
|
+
addSystem(text) {
|
|
1041
|
+
this.append(new Spacer(1));
|
|
1042
|
+
this.append(new Text(theme.system(text), 1, 0));
|
|
1043
|
+
}
|
|
1044
|
+
addUser(text) {
|
|
1045
|
+
this.append(new UserMessageComponent(text));
|
|
1046
|
+
}
|
|
1047
|
+
resolveRunId(runId) {
|
|
1048
|
+
return runId ?? "default";
|
|
1049
|
+
}
|
|
1050
|
+
startAssistant(text, runId) {
|
|
1051
|
+
const effectiveRunId = this.resolveRunId(runId);
|
|
1052
|
+
const existing = this.streamingRuns.get(effectiveRunId);
|
|
1053
|
+
if (existing) {
|
|
1054
|
+
existing.setText(text);
|
|
1055
|
+
return existing;
|
|
1056
|
+
}
|
|
1057
|
+
const component = new AssistantMessageComponent(text);
|
|
1058
|
+
this.streamingRuns.set(effectiveRunId, component);
|
|
1059
|
+
this.append(component);
|
|
1060
|
+
return component;
|
|
1061
|
+
}
|
|
1062
|
+
updateAssistant(text, runId) {
|
|
1063
|
+
const effectiveRunId = this.resolveRunId(runId);
|
|
1064
|
+
const existing = this.streamingRuns.get(effectiveRunId);
|
|
1065
|
+
if (!existing) {
|
|
1066
|
+
this.startAssistant(text, runId);
|
|
1067
|
+
return;
|
|
1068
|
+
}
|
|
1069
|
+
existing.setText(text);
|
|
1070
|
+
}
|
|
1071
|
+
finalizeAssistant(text, runId) {
|
|
1072
|
+
const effectiveRunId = this.resolveRunId(runId);
|
|
1073
|
+
const existing = this.streamingRuns.get(effectiveRunId);
|
|
1074
|
+
if (existing) {
|
|
1075
|
+
existing.setText(text);
|
|
1076
|
+
this.streamingRuns.delete(effectiveRunId);
|
|
1077
|
+
return;
|
|
1078
|
+
}
|
|
1079
|
+
this.append(new AssistantMessageComponent(text));
|
|
1080
|
+
}
|
|
1081
|
+
dropAssistant(runId) {
|
|
1082
|
+
const effectiveRunId = this.resolveRunId(runId);
|
|
1083
|
+
const existing = this.streamingRuns.get(effectiveRunId);
|
|
1084
|
+
if (!existing) return;
|
|
1085
|
+
this.removeChild(existing);
|
|
1086
|
+
this.streamingRuns.delete(effectiveRunId);
|
|
1087
|
+
}
|
|
1088
|
+
showBtw(params) {
|
|
1089
|
+
if (this.btwMessage) {
|
|
1090
|
+
this.btwMessage.setResult(params);
|
|
1091
|
+
if (this.children[this.children.length - 1] !== this.btwMessage) {
|
|
1092
|
+
this.removeChild(this.btwMessage);
|
|
1093
|
+
this.append(this.btwMessage);
|
|
1094
|
+
}
|
|
1095
|
+
return this.btwMessage;
|
|
1096
|
+
}
|
|
1097
|
+
const component = new BtwInlineMessage(params);
|
|
1098
|
+
this.btwMessage = component;
|
|
1099
|
+
this.append(component);
|
|
1100
|
+
return component;
|
|
1101
|
+
}
|
|
1102
|
+
dismissBtw() {
|
|
1103
|
+
if (!this.btwMessage) return;
|
|
1104
|
+
this.removeChild(this.btwMessage);
|
|
1105
|
+
this.btwMessage = null;
|
|
1106
|
+
}
|
|
1107
|
+
hasVisibleBtw() {
|
|
1108
|
+
return this.btwMessage !== null;
|
|
1109
|
+
}
|
|
1110
|
+
startTool(toolCallId, toolName, args) {
|
|
1111
|
+
const existing = this.toolById.get(toolCallId);
|
|
1112
|
+
if (existing) {
|
|
1113
|
+
existing.setArgs(args);
|
|
1114
|
+
return existing;
|
|
1115
|
+
}
|
|
1116
|
+
const component = new ToolExecutionComponent(toolName, args);
|
|
1117
|
+
component.setExpanded(this.toolsExpanded);
|
|
1118
|
+
this.toolById.set(toolCallId, component);
|
|
1119
|
+
this.append(component);
|
|
1120
|
+
return component;
|
|
1121
|
+
}
|
|
1122
|
+
updateToolArgs(toolCallId, args) {
|
|
1123
|
+
const existing = this.toolById.get(toolCallId);
|
|
1124
|
+
if (!existing) return;
|
|
1125
|
+
existing.setArgs(args);
|
|
1126
|
+
}
|
|
1127
|
+
updateToolResult(toolCallId, result, opts) {
|
|
1128
|
+
const existing = this.toolById.get(toolCallId);
|
|
1129
|
+
if (!existing) return;
|
|
1130
|
+
if (opts?.partial) {
|
|
1131
|
+
existing.setPartialResult(result);
|
|
1132
|
+
return;
|
|
1133
|
+
}
|
|
1134
|
+
existing.setResult(result, { isError: opts?.isError });
|
|
1135
|
+
}
|
|
1136
|
+
setToolsExpanded(expanded) {
|
|
1137
|
+
this.toolsExpanded = expanded;
|
|
1138
|
+
for (const tool of this.toolById.values()) tool.setExpanded(expanded);
|
|
1139
|
+
}
|
|
1140
|
+
};
|
|
1141
|
+
//#endregion
|
|
1142
|
+
//#region src/tui/components/custom-editor.ts
|
|
1143
|
+
var CustomEditor = class extends Editor {
|
|
1144
|
+
handleInput(data) {
|
|
1145
|
+
if (matchesKey(data, Key.alt("enter")) && this.onAltEnter) {
|
|
1146
|
+
this.onAltEnter();
|
|
1147
|
+
return;
|
|
1148
|
+
}
|
|
1149
|
+
if (matchesKey(data, Key.ctrl("l")) && this.onCtrlL) {
|
|
1150
|
+
this.onCtrlL();
|
|
1151
|
+
return;
|
|
1152
|
+
}
|
|
1153
|
+
if (matchesKey(data, Key.ctrl("o")) && this.onCtrlO) {
|
|
1154
|
+
this.onCtrlO();
|
|
1155
|
+
return;
|
|
1156
|
+
}
|
|
1157
|
+
if (matchesKey(data, Key.ctrl("p")) && this.onCtrlP) {
|
|
1158
|
+
this.onCtrlP();
|
|
1159
|
+
return;
|
|
1160
|
+
}
|
|
1161
|
+
if (matchesKey(data, Key.ctrl("g")) && this.onCtrlG) {
|
|
1162
|
+
this.onCtrlG();
|
|
1163
|
+
return;
|
|
1164
|
+
}
|
|
1165
|
+
if (matchesKey(data, Key.ctrl("t")) && this.onCtrlT) {
|
|
1166
|
+
this.onCtrlT();
|
|
1167
|
+
return;
|
|
1168
|
+
}
|
|
1169
|
+
if (matchesKey(data, Key.shift("tab")) && this.onShiftTab) {
|
|
1170
|
+
this.onShiftTab();
|
|
1171
|
+
return;
|
|
1172
|
+
}
|
|
1173
|
+
if (matchesKey(data, Key.escape) && this.onEscape && !this.isShowingAutocomplete()) {
|
|
1174
|
+
this.onEscape();
|
|
1175
|
+
return;
|
|
1176
|
+
}
|
|
1177
|
+
if (matchesKey(data, Key.ctrl("c")) && this.onCtrlC) {
|
|
1178
|
+
this.onCtrlC();
|
|
1179
|
+
return;
|
|
1180
|
+
}
|
|
1181
|
+
if (matchesKey(data, Key.ctrl("d"))) {
|
|
1182
|
+
if (this.getText().length === 0 && this.onCtrlD) this.onCtrlD();
|
|
1183
|
+
return;
|
|
1184
|
+
}
|
|
1185
|
+
super.handleInput(data);
|
|
1186
|
+
}
|
|
1187
|
+
};
|
|
1188
|
+
//#endregion
|
|
1189
|
+
//#region src/tui/gateway-chat.ts
|
|
1190
|
+
function trimToUndefined(value) {
|
|
1191
|
+
if (typeof value !== "string") return;
|
|
1192
|
+
const trimmed = value.trim();
|
|
1193
|
+
return trimmed.length > 0 ? trimmed : void 0;
|
|
1194
|
+
}
|
|
1195
|
+
function throwGatewayAuthResolutionError(reason) {
|
|
1196
|
+
throw new Error([
|
|
1197
|
+
reason,
|
|
1198
|
+
"Fix: set OPENCLAW_GATEWAY_TOKEN/OPENCLAW_GATEWAY_PASSWORD, pass --token/--password,",
|
|
1199
|
+
"or resolve the configured secret provider for this credential."
|
|
1200
|
+
].join("\n"));
|
|
1201
|
+
}
|
|
1202
|
+
var GatewayChatClient = class GatewayChatClient {
|
|
1203
|
+
constructor(connection) {
|
|
1204
|
+
this.connection = connection;
|
|
1205
|
+
this.readyPromise = new Promise((resolve) => {
|
|
1206
|
+
this.resolveReady = resolve;
|
|
1207
|
+
});
|
|
1208
|
+
this.client = new GatewayClient({
|
|
1209
|
+
url: connection.url,
|
|
1210
|
+
token: connection.token,
|
|
1211
|
+
password: connection.password,
|
|
1212
|
+
clientName: GATEWAY_CLIENT_NAMES.GATEWAY_CLIENT,
|
|
1213
|
+
clientDisplayName: "openclaw-tui",
|
|
1214
|
+
clientVersion: VERSION,
|
|
1215
|
+
platform: process.platform,
|
|
1216
|
+
mode: GATEWAY_CLIENT_MODES.UI,
|
|
1217
|
+
caps: [GATEWAY_CLIENT_CAPS.TOOL_EVENTS],
|
|
1218
|
+
instanceId: randomUUID(),
|
|
1219
|
+
minProtocol: 3,
|
|
1220
|
+
maxProtocol: 3,
|
|
1221
|
+
onHelloOk: (hello) => {
|
|
1222
|
+
this.hello = hello;
|
|
1223
|
+
this.resolveReady?.();
|
|
1224
|
+
this.onConnected?.();
|
|
1225
|
+
},
|
|
1226
|
+
onEvent: (evt) => {
|
|
1227
|
+
this.onEvent?.({
|
|
1228
|
+
event: evt.event,
|
|
1229
|
+
payload: evt.payload,
|
|
1230
|
+
seq: evt.seq
|
|
1231
|
+
});
|
|
1232
|
+
},
|
|
1233
|
+
onClose: (_code, reason) => {
|
|
1234
|
+
this.readyPromise = new Promise((resolve) => {
|
|
1235
|
+
this.resolveReady = resolve;
|
|
1236
|
+
});
|
|
1237
|
+
this.onDisconnected?.(reason);
|
|
1238
|
+
},
|
|
1239
|
+
onGap: (info) => {
|
|
1240
|
+
this.onGap?.(info);
|
|
1241
|
+
}
|
|
1242
|
+
});
|
|
1243
|
+
}
|
|
1244
|
+
static async connect(opts) {
|
|
1245
|
+
return new GatewayChatClient(await resolveGatewayConnection(opts));
|
|
1246
|
+
}
|
|
1247
|
+
start() {
|
|
1248
|
+
this.client.start();
|
|
1249
|
+
}
|
|
1250
|
+
stop() {
|
|
1251
|
+
this.client.stop();
|
|
1252
|
+
}
|
|
1253
|
+
async waitForReady() {
|
|
1254
|
+
await this.readyPromise;
|
|
1255
|
+
}
|
|
1256
|
+
async sendChat(opts) {
|
|
1257
|
+
const runId = opts.runId ?? randomUUID();
|
|
1258
|
+
await this.client.request("chat.send", {
|
|
1259
|
+
sessionKey: opts.sessionKey,
|
|
1260
|
+
message: opts.message,
|
|
1261
|
+
thinking: opts.thinking,
|
|
1262
|
+
deliver: opts.deliver,
|
|
1263
|
+
timeoutMs: opts.timeoutMs,
|
|
1264
|
+
idempotencyKey: runId
|
|
1265
|
+
});
|
|
1266
|
+
return { runId };
|
|
1267
|
+
}
|
|
1268
|
+
async abortChat(opts) {
|
|
1269
|
+
return await this.client.request("chat.abort", {
|
|
1270
|
+
sessionKey: opts.sessionKey,
|
|
1271
|
+
runId: opts.runId
|
|
1272
|
+
});
|
|
1273
|
+
}
|
|
1274
|
+
async loadHistory(opts) {
|
|
1275
|
+
return await this.client.request("chat.history", {
|
|
1276
|
+
sessionKey: opts.sessionKey,
|
|
1277
|
+
limit: opts.limit
|
|
1278
|
+
});
|
|
1279
|
+
}
|
|
1280
|
+
async listSessions(opts) {
|
|
1281
|
+
return await this.client.request("sessions.list", {
|
|
1282
|
+
limit: opts?.limit,
|
|
1283
|
+
activeMinutes: opts?.activeMinutes,
|
|
1284
|
+
includeGlobal: opts?.includeGlobal,
|
|
1285
|
+
includeUnknown: opts?.includeUnknown,
|
|
1286
|
+
includeDerivedTitles: opts?.includeDerivedTitles,
|
|
1287
|
+
includeLastMessage: opts?.includeLastMessage,
|
|
1288
|
+
agentId: opts?.agentId
|
|
1289
|
+
});
|
|
1290
|
+
}
|
|
1291
|
+
async listAgents() {
|
|
1292
|
+
return await this.client.request("agents.list", {});
|
|
1293
|
+
}
|
|
1294
|
+
async patchSession(opts) {
|
|
1295
|
+
return await this.client.request("sessions.patch", opts);
|
|
1296
|
+
}
|
|
1297
|
+
async resetSession(key, reason) {
|
|
1298
|
+
return await this.client.request("sessions.reset", {
|
|
1299
|
+
key,
|
|
1300
|
+
...reason ? { reason } : {}
|
|
1301
|
+
});
|
|
1302
|
+
}
|
|
1303
|
+
async getStatus() {
|
|
1304
|
+
return await this.client.request("status");
|
|
1305
|
+
}
|
|
1306
|
+
async listModels() {
|
|
1307
|
+
const res = await this.client.request("models.list");
|
|
1308
|
+
return Array.isArray(res?.models) ? res.models : [];
|
|
1309
|
+
}
|
|
1310
|
+
};
|
|
1311
|
+
async function resolveGatewayConnection(opts) {
|
|
1312
|
+
const config = loadConfig();
|
|
1313
|
+
const env = process.env;
|
|
1314
|
+
const gatewayAuthMode = config.gateway?.auth?.mode;
|
|
1315
|
+
const isRemoteMode = config.gateway?.mode === "remote";
|
|
1316
|
+
const remote = config.gateway?.remote;
|
|
1317
|
+
const envToken = trimToUndefined(env.OPENCLAW_GATEWAY_TOKEN);
|
|
1318
|
+
const envPassword = trimToUndefined(env.OPENCLAW_GATEWAY_PASSWORD);
|
|
1319
|
+
const urlOverride = typeof opts.url === "string" && opts.url.trim().length > 0 ? opts.url.trim() : void 0;
|
|
1320
|
+
const explicitAuth = resolveExplicitGatewayAuth({
|
|
1321
|
+
token: opts.token,
|
|
1322
|
+
password: opts.password
|
|
1323
|
+
});
|
|
1324
|
+
ensureExplicitGatewayAuth({
|
|
1325
|
+
urlOverride,
|
|
1326
|
+
urlOverrideSource: "cli",
|
|
1327
|
+
explicitAuth,
|
|
1328
|
+
errorHint: "Fix: pass --token or --password when using --url."
|
|
1329
|
+
});
|
|
1330
|
+
const url = buildGatewayConnectionDetails({
|
|
1331
|
+
config,
|
|
1332
|
+
...urlOverride ? { url: urlOverride } : {}
|
|
1333
|
+
}).url;
|
|
1334
|
+
if (urlOverride) return {
|
|
1335
|
+
url,
|
|
1336
|
+
token: explicitAuth.token,
|
|
1337
|
+
password: explicitAuth.password
|
|
1338
|
+
};
|
|
1339
|
+
if (isRemoteMode) {
|
|
1340
|
+
const remoteToken = explicitAuth.token ? { value: explicitAuth.token } : await resolveConfiguredSecretInputString({
|
|
1341
|
+
value: remote?.token,
|
|
1342
|
+
path: "gateway.remote.token",
|
|
1343
|
+
env,
|
|
1344
|
+
config
|
|
1345
|
+
});
|
|
1346
|
+
const remotePassword = explicitAuth.password || envPassword ? { value: explicitAuth.password ?? envPassword } : await resolveConfiguredSecretInputString({
|
|
1347
|
+
value: remote?.password,
|
|
1348
|
+
path: "gateway.remote.password",
|
|
1349
|
+
env,
|
|
1350
|
+
config
|
|
1351
|
+
});
|
|
1352
|
+
const token = explicitAuth.token ?? remoteToken.value;
|
|
1353
|
+
const password = explicitAuth.password ?? envPassword ?? remotePassword.value;
|
|
1354
|
+
if (!token && !password) throwGatewayAuthResolutionError(remoteToken.unresolvedRefReason ?? remotePassword.unresolvedRefReason ?? "Missing gateway auth credentials.");
|
|
1355
|
+
return {
|
|
1356
|
+
url,
|
|
1357
|
+
token,
|
|
1358
|
+
password
|
|
1359
|
+
};
|
|
1360
|
+
}
|
|
1361
|
+
if (gatewayAuthMode === "none" || gatewayAuthMode === "trusted-proxy") return {
|
|
1362
|
+
url,
|
|
1363
|
+
token: explicitAuth.token ?? envToken,
|
|
1364
|
+
password: explicitAuth.password ?? envPassword
|
|
1365
|
+
};
|
|
1366
|
+
try {
|
|
1367
|
+
assertExplicitGatewayAuthModeWhenBothConfigured(config);
|
|
1368
|
+
} catch (err) {
|
|
1369
|
+
throwGatewayAuthResolutionError(err instanceof Error ? err.message : String(err));
|
|
1370
|
+
}
|
|
1371
|
+
const defaults = config.secrets?.defaults;
|
|
1372
|
+
const hasConfiguredToken = hasConfiguredSecretInput(config.gateway?.auth?.token, defaults);
|
|
1373
|
+
const hasConfiguredPassword = hasConfiguredSecretInput(config.gateway?.auth?.password, defaults);
|
|
1374
|
+
if (gatewayAuthMode === "password") {
|
|
1375
|
+
const localPassword = explicitAuth.password || envPassword ? { value: explicitAuth.password ?? envPassword } : await resolveConfiguredSecretInputString({
|
|
1376
|
+
value: config.gateway?.auth?.password,
|
|
1377
|
+
path: "gateway.auth.password",
|
|
1378
|
+
env,
|
|
1379
|
+
config
|
|
1380
|
+
});
|
|
1381
|
+
const password = explicitAuth.password ?? envPassword ?? localPassword.value;
|
|
1382
|
+
if (!password) throwGatewayAuthResolutionError(localPassword.unresolvedRefReason ?? "Missing gateway auth password.");
|
|
1383
|
+
return {
|
|
1384
|
+
url,
|
|
1385
|
+
token: explicitAuth.token ?? envToken,
|
|
1386
|
+
password
|
|
1387
|
+
};
|
|
1388
|
+
}
|
|
1389
|
+
const resolveToken = async () => {
|
|
1390
|
+
const localToken = explicitAuth.token ? { value: explicitAuth.token } : await resolveConfiguredSecretInputString({
|
|
1391
|
+
value: config.gateway?.auth?.token,
|
|
1392
|
+
path: "gateway.auth.token",
|
|
1393
|
+
env,
|
|
1394
|
+
config
|
|
1395
|
+
});
|
|
1396
|
+
const token = explicitAuth.token ?? localToken.value ?? envToken;
|
|
1397
|
+
if (!token) throwGatewayAuthResolutionError(localToken.unresolvedRefReason ?? "Missing gateway auth token.");
|
|
1398
|
+
return token;
|
|
1399
|
+
};
|
|
1400
|
+
if (gatewayAuthMode === "token") return {
|
|
1401
|
+
url,
|
|
1402
|
+
token: await resolveToken(),
|
|
1403
|
+
password: explicitAuth.password ?? envPassword
|
|
1404
|
+
};
|
|
1405
|
+
const passwordCandidate = explicitAuth.password ?? envPassword;
|
|
1406
|
+
if (Boolean(passwordCandidate) || hasConfiguredPassword && !hasConfiguredToken) {
|
|
1407
|
+
const localPassword = passwordCandidate ? { value: passwordCandidate } : await resolveConfiguredSecretInputString({
|
|
1408
|
+
value: config.gateway?.auth?.password,
|
|
1409
|
+
path: "gateway.auth.password",
|
|
1410
|
+
env,
|
|
1411
|
+
config
|
|
1412
|
+
});
|
|
1413
|
+
const password = explicitAuth.password ?? localPassword.value ?? envPassword;
|
|
1414
|
+
if (!password) throwGatewayAuthResolutionError(localPassword.unresolvedRefReason ?? "Missing gateway auth password.");
|
|
1415
|
+
return {
|
|
1416
|
+
url,
|
|
1417
|
+
token: explicitAuth.token ?? envToken,
|
|
1418
|
+
password
|
|
1419
|
+
};
|
|
1420
|
+
}
|
|
1421
|
+
return {
|
|
1422
|
+
url,
|
|
1423
|
+
token: await resolveToken(),
|
|
1424
|
+
password: explicitAuth.password ?? envPassword
|
|
1425
|
+
};
|
|
1426
|
+
}
|
|
1427
|
+
//#endregion
|
|
1428
|
+
//#region src/tui/components/fuzzy-filter.ts
|
|
1429
|
+
/**
|
|
1430
|
+
* Shared fuzzy filtering utilities for select list components.
|
|
1431
|
+
*/
|
|
1432
|
+
/**
|
|
1433
|
+
* Word boundary characters for matching.
|
|
1434
|
+
*/
|
|
1435
|
+
const WORD_BOUNDARY_CHARS = /[\s\-_./:#@]/;
|
|
1436
|
+
/**
|
|
1437
|
+
* Check if position is at a word boundary.
|
|
1438
|
+
*/
|
|
1439
|
+
function isWordBoundary(text, index) {
|
|
1440
|
+
return index === 0 || WORD_BOUNDARY_CHARS.test(text[index - 1] ?? "");
|
|
1441
|
+
}
|
|
1442
|
+
/**
|
|
1443
|
+
* Find index where query matches at a word boundary in text.
|
|
1444
|
+
* Returns null if no match.
|
|
1445
|
+
*/
|
|
1446
|
+
function findWordBoundaryIndex(text, query) {
|
|
1447
|
+
if (!query) return null;
|
|
1448
|
+
const textLower = text.toLowerCase();
|
|
1449
|
+
const queryLower = query.toLowerCase();
|
|
1450
|
+
const maxIndex = textLower.length - queryLower.length;
|
|
1451
|
+
if (maxIndex < 0) return null;
|
|
1452
|
+
for (let i = 0; i <= maxIndex; i++) if (textLower.startsWith(queryLower, i) && isWordBoundary(textLower, i)) return i;
|
|
1453
|
+
return null;
|
|
1454
|
+
}
|
|
1455
|
+
/**
|
|
1456
|
+
* Fuzzy match with pre-lowercased inputs (avoids toLowerCase on every keystroke).
|
|
1457
|
+
* Returns score (lower = better) or null if no match.
|
|
1458
|
+
*/
|
|
1459
|
+
function fuzzyMatchLower(queryLower, textLower) {
|
|
1460
|
+
if (queryLower.length === 0) return 0;
|
|
1461
|
+
if (queryLower.length > textLower.length) return null;
|
|
1462
|
+
let queryIndex = 0;
|
|
1463
|
+
let score = 0;
|
|
1464
|
+
let lastMatchIndex = -1;
|
|
1465
|
+
let consecutiveMatches = 0;
|
|
1466
|
+
for (let i = 0; i < textLower.length && queryIndex < queryLower.length; i++) if (textLower[i] === queryLower[queryIndex]) {
|
|
1467
|
+
const isAtWordBoundary = isWordBoundary(textLower, i);
|
|
1468
|
+
if (lastMatchIndex === i - 1) {
|
|
1469
|
+
consecutiveMatches++;
|
|
1470
|
+
score -= consecutiveMatches * 5;
|
|
1471
|
+
} else {
|
|
1472
|
+
consecutiveMatches = 0;
|
|
1473
|
+
if (lastMatchIndex >= 0) score += (i - lastMatchIndex - 1) * 2;
|
|
1474
|
+
}
|
|
1475
|
+
if (isAtWordBoundary) score -= 10;
|
|
1476
|
+
score += i * .1;
|
|
1477
|
+
lastMatchIndex = i;
|
|
1478
|
+
queryIndex++;
|
|
1479
|
+
}
|
|
1480
|
+
return queryIndex < queryLower.length ? null : score;
|
|
1481
|
+
}
|
|
1482
|
+
/**
|
|
1483
|
+
* Filter items using pre-lowercased searchTextLower field.
|
|
1484
|
+
* Supports space-separated tokens (all must match).
|
|
1485
|
+
*/
|
|
1486
|
+
function fuzzyFilterLower(items, queryLower) {
|
|
1487
|
+
const trimmed = queryLower.trim();
|
|
1488
|
+
if (!trimmed) return items;
|
|
1489
|
+
const tokens = trimmed.split(/\s+/).filter((t) => t.length > 0);
|
|
1490
|
+
if (tokens.length === 0) return items;
|
|
1491
|
+
const results = [];
|
|
1492
|
+
for (const item of items) {
|
|
1493
|
+
const text = item.searchTextLower ?? "";
|
|
1494
|
+
let totalScore = 0;
|
|
1495
|
+
let allMatch = true;
|
|
1496
|
+
for (const token of tokens) {
|
|
1497
|
+
const score = fuzzyMatchLower(token, text);
|
|
1498
|
+
if (score !== null) totalScore += score;
|
|
1499
|
+
else {
|
|
1500
|
+
allMatch = false;
|
|
1501
|
+
break;
|
|
1502
|
+
}
|
|
1503
|
+
}
|
|
1504
|
+
if (allMatch) results.push({
|
|
1505
|
+
item,
|
|
1506
|
+
score: totalScore
|
|
1507
|
+
});
|
|
1508
|
+
}
|
|
1509
|
+
results.sort((a, b) => a.score - b.score);
|
|
1510
|
+
return results.map((r) => r.item);
|
|
1511
|
+
}
|
|
1512
|
+
/**
|
|
1513
|
+
* Prepare items for fuzzy filtering by pre-computing lowercase search text.
|
|
1514
|
+
*/
|
|
1515
|
+
function prepareSearchItems(items) {
|
|
1516
|
+
return items.map((item) => {
|
|
1517
|
+
const parts = [];
|
|
1518
|
+
if (item.label) parts.push(item.label);
|
|
1519
|
+
if (item.description) parts.push(item.description);
|
|
1520
|
+
if (item.searchText) parts.push(item.searchText);
|
|
1521
|
+
return {
|
|
1522
|
+
...item,
|
|
1523
|
+
searchTextLower: parts.join(" ").toLowerCase()
|
|
1524
|
+
};
|
|
1525
|
+
});
|
|
1526
|
+
}
|
|
1527
|
+
//#endregion
|
|
1528
|
+
//#region src/tui/components/filterable-select-list.ts
|
|
1529
|
+
/**
|
|
1530
|
+
* Combines text input filtering with a select list.
|
|
1531
|
+
* User types to filter, arrows/j/k to navigate, Enter to select, Escape to clear/cancel.
|
|
1532
|
+
*/
|
|
1533
|
+
var FilterableSelectList = class {
|
|
1534
|
+
constructor(items, maxVisible, theme) {
|
|
1535
|
+
this.filterText = "";
|
|
1536
|
+
this.allItems = prepareSearchItems(items);
|
|
1537
|
+
this.maxVisible = maxVisible;
|
|
1538
|
+
this.theme = theme;
|
|
1539
|
+
this.input = new Input();
|
|
1540
|
+
this.selectList = new SelectList(this.allItems, maxVisible, theme);
|
|
1541
|
+
}
|
|
1542
|
+
applyFilter() {
|
|
1543
|
+
const queryLower = this.filterText.toLowerCase();
|
|
1544
|
+
if (!queryLower.trim()) {
|
|
1545
|
+
this.selectList = new SelectList(this.allItems, this.maxVisible, this.theme);
|
|
1546
|
+
return;
|
|
1547
|
+
}
|
|
1548
|
+
this.selectList = new SelectList(fuzzyFilterLower(this.allItems, queryLower), this.maxVisible, this.theme);
|
|
1549
|
+
}
|
|
1550
|
+
invalidate() {
|
|
1551
|
+
this.input.invalidate();
|
|
1552
|
+
this.selectList.invalidate();
|
|
1553
|
+
}
|
|
1554
|
+
render(width) {
|
|
1555
|
+
const lines = [];
|
|
1556
|
+
const filterLabel = this.theme.filterLabel("Filter: ");
|
|
1557
|
+
const inputText = this.input.render(width - 8)[0] ?? "";
|
|
1558
|
+
lines.push(filterLabel + inputText);
|
|
1559
|
+
lines.push(chalk.dim("─".repeat(Math.max(0, width))));
|
|
1560
|
+
const listLines = this.selectList.render(width);
|
|
1561
|
+
lines.push(...listLines);
|
|
1562
|
+
return lines;
|
|
1563
|
+
}
|
|
1564
|
+
handleInput(keyData) {
|
|
1565
|
+
const allowVimNav = !this.filterText.trim();
|
|
1566
|
+
if (matchesKey(keyData, "up") || matchesKey(keyData, "ctrl+p") || allowVimNav && keyData === "k") {
|
|
1567
|
+
this.selectList.handleInput("\x1B[A");
|
|
1568
|
+
return;
|
|
1569
|
+
}
|
|
1570
|
+
if (matchesKey(keyData, "down") || matchesKey(keyData, "ctrl+n") || allowVimNav && keyData === "j") {
|
|
1571
|
+
this.selectList.handleInput("\x1B[B");
|
|
1572
|
+
return;
|
|
1573
|
+
}
|
|
1574
|
+
if (matchesKey(keyData, "enter")) {
|
|
1575
|
+
const selected = this.selectList.getSelectedItem();
|
|
1576
|
+
if (selected) this.onSelect?.(selected);
|
|
1577
|
+
return;
|
|
1578
|
+
}
|
|
1579
|
+
if (getEditorKeybindings().matches(keyData, "selectCancel")) {
|
|
1580
|
+
if (this.filterText) {
|
|
1581
|
+
this.filterText = "";
|
|
1582
|
+
this.input.setValue("");
|
|
1583
|
+
this.applyFilter();
|
|
1584
|
+
} else this.onCancel?.();
|
|
1585
|
+
return;
|
|
1586
|
+
}
|
|
1587
|
+
const prevValue = this.input.getValue();
|
|
1588
|
+
this.input.handleInput(keyData);
|
|
1589
|
+
const newValue = this.input.getValue();
|
|
1590
|
+
if (newValue !== prevValue) {
|
|
1591
|
+
this.filterText = newValue;
|
|
1592
|
+
this.applyFilter();
|
|
1593
|
+
}
|
|
1594
|
+
}
|
|
1595
|
+
getSelectedItem() {
|
|
1596
|
+
return this.selectList.getSelectedItem();
|
|
1597
|
+
}
|
|
1598
|
+
getFilterText() {
|
|
1599
|
+
return this.filterText;
|
|
1600
|
+
}
|
|
1601
|
+
};
|
|
1602
|
+
//#endregion
|
|
1603
|
+
//#region src/tui/components/searchable-select-list.ts
|
|
1604
|
+
const ANSI_ESCAPE = String.fromCharCode(27);
|
|
1605
|
+
const ANSI_SGR_REGEX = new RegExp(`${ANSI_ESCAPE}\\[[0-9;]*m`, "g");
|
|
1606
|
+
/**
|
|
1607
|
+
* A select list with a search input at the top for fuzzy filtering.
|
|
1608
|
+
*/
|
|
1609
|
+
var SearchableSelectList = class SearchableSelectList {
|
|
1610
|
+
static {
|
|
1611
|
+
this.DESCRIPTION_LAYOUT_MIN_WIDTH = 40;
|
|
1612
|
+
}
|
|
1613
|
+
static {
|
|
1614
|
+
this.DESCRIPTION_MIN_WIDTH = 12;
|
|
1615
|
+
}
|
|
1616
|
+
static {
|
|
1617
|
+
this.DESCRIPTION_SPACING_WIDTH = 2;
|
|
1618
|
+
}
|
|
1619
|
+
static {
|
|
1620
|
+
this.RIGHT_MARGIN_WIDTH = 2;
|
|
1621
|
+
}
|
|
1622
|
+
constructor(items, maxVisible, theme) {
|
|
1623
|
+
this.selectedIndex = 0;
|
|
1624
|
+
this.regexCache = /* @__PURE__ */ new Map();
|
|
1625
|
+
this.compareByScore = (a, b) => {
|
|
1626
|
+
if (a.tier !== b.tier) return a.tier - b.tier;
|
|
1627
|
+
if (a.score !== b.score) return a.score - b.score;
|
|
1628
|
+
return this.getItemLabel(a.item).localeCompare(this.getItemLabel(b.item));
|
|
1629
|
+
};
|
|
1630
|
+
this.items = items;
|
|
1631
|
+
this.filteredItems = items;
|
|
1632
|
+
this.maxVisible = maxVisible;
|
|
1633
|
+
this.theme = theme;
|
|
1634
|
+
this.searchInput = new Input();
|
|
1635
|
+
}
|
|
1636
|
+
getCachedRegex(pattern) {
|
|
1637
|
+
let regex = this.regexCache.get(pattern);
|
|
1638
|
+
if (!regex) {
|
|
1639
|
+
regex = new RegExp(this.escapeRegex(pattern), "gi");
|
|
1640
|
+
this.regexCache.set(pattern, regex);
|
|
1641
|
+
}
|
|
1642
|
+
return regex;
|
|
1643
|
+
}
|
|
1644
|
+
updateFilter() {
|
|
1645
|
+
const query = this.searchInput.getValue().trim();
|
|
1646
|
+
if (!query) this.filteredItems = this.items;
|
|
1647
|
+
else this.filteredItems = this.smartFilter(query);
|
|
1648
|
+
this.selectedIndex = 0;
|
|
1649
|
+
this.notifySelectionChange();
|
|
1650
|
+
}
|
|
1651
|
+
/**
|
|
1652
|
+
* Smart filtering that prioritizes:
|
|
1653
|
+
* 1. Exact substring match in label (highest priority)
|
|
1654
|
+
* 2. Word-boundary prefix match in label
|
|
1655
|
+
* 3. Exact substring in description
|
|
1656
|
+
* 4. Fuzzy match (lowest priority)
|
|
1657
|
+
*/
|
|
1658
|
+
smartFilter(query) {
|
|
1659
|
+
const q = query.toLowerCase();
|
|
1660
|
+
const scoredItems = [];
|
|
1661
|
+
const fuzzyCandidates = [];
|
|
1662
|
+
for (const item of this.items) {
|
|
1663
|
+
const rawLabel = this.getItemLabel(item);
|
|
1664
|
+
const rawDesc = item.description ?? "";
|
|
1665
|
+
const label = stripAnsi$1(rawLabel).toLowerCase();
|
|
1666
|
+
const desc = stripAnsi$1(rawDesc).toLowerCase();
|
|
1667
|
+
const labelIndex = label.indexOf(q);
|
|
1668
|
+
if (labelIndex !== -1) {
|
|
1669
|
+
scoredItems.push({
|
|
1670
|
+
item,
|
|
1671
|
+
tier: 0,
|
|
1672
|
+
score: labelIndex
|
|
1673
|
+
});
|
|
1674
|
+
continue;
|
|
1675
|
+
}
|
|
1676
|
+
const wordBoundaryIndex = findWordBoundaryIndex(label, q);
|
|
1677
|
+
if (wordBoundaryIndex !== null) {
|
|
1678
|
+
scoredItems.push({
|
|
1679
|
+
item,
|
|
1680
|
+
tier: 1,
|
|
1681
|
+
score: wordBoundaryIndex
|
|
1682
|
+
});
|
|
1683
|
+
continue;
|
|
1684
|
+
}
|
|
1685
|
+
const descIndex = desc.indexOf(q);
|
|
1686
|
+
if (descIndex !== -1) {
|
|
1687
|
+
scoredItems.push({
|
|
1688
|
+
item,
|
|
1689
|
+
tier: 2,
|
|
1690
|
+
score: descIndex
|
|
1691
|
+
});
|
|
1692
|
+
continue;
|
|
1693
|
+
}
|
|
1694
|
+
const searchText = item.searchText ?? "";
|
|
1695
|
+
fuzzyCandidates.push({
|
|
1696
|
+
item,
|
|
1697
|
+
searchTextLower: [
|
|
1698
|
+
rawLabel,
|
|
1699
|
+
rawDesc,
|
|
1700
|
+
searchText
|
|
1701
|
+
].map((value) => stripAnsi$1(value)).filter(Boolean).join(" ").toLowerCase()
|
|
1702
|
+
});
|
|
1703
|
+
}
|
|
1704
|
+
scoredItems.sort(this.compareByScore);
|
|
1705
|
+
const fuzzyMatches = fuzzyFilterLower(fuzzyCandidates, q);
|
|
1706
|
+
return [...scoredItems.map((s) => s.item), ...fuzzyMatches.map((entry) => entry.item)];
|
|
1707
|
+
}
|
|
1708
|
+
escapeRegex(str) {
|
|
1709
|
+
return str.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
|
|
1710
|
+
}
|
|
1711
|
+
getItemLabel(item) {
|
|
1712
|
+
return item.label || item.value;
|
|
1713
|
+
}
|
|
1714
|
+
splitAnsiParts(text) {
|
|
1715
|
+
const parts = [];
|
|
1716
|
+
ANSI_SGR_REGEX.lastIndex = 0;
|
|
1717
|
+
let lastIndex = 0;
|
|
1718
|
+
let match;
|
|
1719
|
+
while ((match = ANSI_SGR_REGEX.exec(text)) !== null) {
|
|
1720
|
+
if (match.index > lastIndex) parts.push({
|
|
1721
|
+
text: text.slice(lastIndex, match.index),
|
|
1722
|
+
isAnsi: false
|
|
1723
|
+
});
|
|
1724
|
+
parts.push({
|
|
1725
|
+
text: match[0],
|
|
1726
|
+
isAnsi: true
|
|
1727
|
+
});
|
|
1728
|
+
lastIndex = match.index + match[0].length;
|
|
1729
|
+
}
|
|
1730
|
+
if (lastIndex < text.length) parts.push({
|
|
1731
|
+
text: text.slice(lastIndex),
|
|
1732
|
+
isAnsi: false
|
|
1733
|
+
});
|
|
1734
|
+
return parts;
|
|
1735
|
+
}
|
|
1736
|
+
highlightMatch(text, query) {
|
|
1737
|
+
const tokens = query.trim().split(/\s+/).map((token) => token.toLowerCase()).filter((token) => token.length > 0);
|
|
1738
|
+
if (tokens.length === 0) return text;
|
|
1739
|
+
const uniqueTokens = Array.from(new Set(tokens)).toSorted((a, b) => b.length - a.length);
|
|
1740
|
+
let parts = this.splitAnsiParts(text);
|
|
1741
|
+
for (const token of uniqueTokens) {
|
|
1742
|
+
const regex = this.getCachedRegex(token);
|
|
1743
|
+
const nextParts = [];
|
|
1744
|
+
for (const part of parts) {
|
|
1745
|
+
if (part.isAnsi) {
|
|
1746
|
+
nextParts.push(part);
|
|
1747
|
+
continue;
|
|
1748
|
+
}
|
|
1749
|
+
regex.lastIndex = 0;
|
|
1750
|
+
const replaced = part.text.replace(regex, (match) => this.theme.matchHighlight(match));
|
|
1751
|
+
if (replaced === part.text) {
|
|
1752
|
+
nextParts.push(part);
|
|
1753
|
+
continue;
|
|
1754
|
+
}
|
|
1755
|
+
nextParts.push(...this.splitAnsiParts(replaced));
|
|
1756
|
+
}
|
|
1757
|
+
parts = nextParts;
|
|
1758
|
+
}
|
|
1759
|
+
return parts.map((part) => part.text).join("");
|
|
1760
|
+
}
|
|
1761
|
+
setSelectedIndex(index) {
|
|
1762
|
+
this.selectedIndex = Math.max(0, Math.min(index, this.filteredItems.length - 1));
|
|
1763
|
+
}
|
|
1764
|
+
invalidate() {
|
|
1765
|
+
this.searchInput.invalidate();
|
|
1766
|
+
}
|
|
1767
|
+
render(width) {
|
|
1768
|
+
const lines = [];
|
|
1769
|
+
const prompt = this.theme.searchPrompt("search: ");
|
|
1770
|
+
const inputWidth = Math.max(1, width - visibleWidth(prompt));
|
|
1771
|
+
const inputText = this.searchInput.render(inputWidth)[0] ?? "";
|
|
1772
|
+
lines.push(`${prompt}${this.theme.searchInput(inputText)}`);
|
|
1773
|
+
lines.push("");
|
|
1774
|
+
const query = this.searchInput.getValue().trim();
|
|
1775
|
+
if (this.filteredItems.length === 0) {
|
|
1776
|
+
lines.push(this.theme.noMatch(" No matches"));
|
|
1777
|
+
return lines;
|
|
1778
|
+
}
|
|
1779
|
+
const startIndex = Math.max(0, Math.min(this.selectedIndex - Math.floor(this.maxVisible / 2), this.filteredItems.length - this.maxVisible));
|
|
1780
|
+
const endIndex = Math.min(startIndex + this.maxVisible, this.filteredItems.length);
|
|
1781
|
+
for (let i = startIndex; i < endIndex; i++) {
|
|
1782
|
+
const item = this.filteredItems[i];
|
|
1783
|
+
if (!item) continue;
|
|
1784
|
+
const isSelected = i === this.selectedIndex;
|
|
1785
|
+
lines.push(this.renderItemLine(item, isSelected, width, query));
|
|
1786
|
+
}
|
|
1787
|
+
if (this.filteredItems.length > this.maxVisible) {
|
|
1788
|
+
const scrollInfo = `${this.selectedIndex + 1}/${this.filteredItems.length}`;
|
|
1789
|
+
lines.push(this.theme.scrollInfo(` ${scrollInfo}`));
|
|
1790
|
+
}
|
|
1791
|
+
return lines;
|
|
1792
|
+
}
|
|
1793
|
+
renderItemLine(item, isSelected, width, query) {
|
|
1794
|
+
const prefix = isSelected ? "→ " : " ";
|
|
1795
|
+
const prefixWidth = prefix.length;
|
|
1796
|
+
const displayValue = this.getItemLabel(item);
|
|
1797
|
+
const description = item.description;
|
|
1798
|
+
if (description) {
|
|
1799
|
+
const descriptionLayout = this.getDescriptionLayout(width, prefixWidth);
|
|
1800
|
+
if (descriptionLayout) {
|
|
1801
|
+
const truncatedValue = truncateToWidth(displayValue, descriptionLayout.maxValueWidth, "");
|
|
1802
|
+
const valueText = this.highlightMatch(truncatedValue, query);
|
|
1803
|
+
const usedByValue = visibleWidth(valueText);
|
|
1804
|
+
const descriptionWidth = descriptionLayout.availableWidth - usedByValue - descriptionLayout.spacingWidth;
|
|
1805
|
+
if (descriptionWidth >= SearchableSelectList.DESCRIPTION_MIN_WIDTH) {
|
|
1806
|
+
const spacing = " ".repeat(descriptionLayout.spacingWidth);
|
|
1807
|
+
const truncatedDesc = truncateToWidth(description, descriptionWidth, "");
|
|
1808
|
+
const highlightedDesc = this.highlightMatch(truncatedDesc, query);
|
|
1809
|
+
const line = `${prefix}${valueText}${spacing}${isSelected ? highlightedDesc : this.theme.description(highlightedDesc)}`;
|
|
1810
|
+
return isSelected ? this.theme.selectedText(line) : line;
|
|
1811
|
+
}
|
|
1812
|
+
}
|
|
1813
|
+
}
|
|
1814
|
+
const truncatedValue = truncateToWidth(displayValue, width - prefixWidth - 2, "");
|
|
1815
|
+
const line = `${prefix}${this.highlightMatch(truncatedValue, query)}`;
|
|
1816
|
+
return isSelected ? this.theme.selectedText(line) : line;
|
|
1817
|
+
}
|
|
1818
|
+
getDescriptionLayout(width, prefixWidth) {
|
|
1819
|
+
if (width <= SearchableSelectList.DESCRIPTION_LAYOUT_MIN_WIDTH) return null;
|
|
1820
|
+
const availableWidth = Math.max(1, width - prefixWidth - SearchableSelectList.RIGHT_MARGIN_WIDTH);
|
|
1821
|
+
const maxValueWidth = availableWidth - SearchableSelectList.DESCRIPTION_MIN_WIDTH - SearchableSelectList.DESCRIPTION_SPACING_WIDTH;
|
|
1822
|
+
if (maxValueWidth < 1) return null;
|
|
1823
|
+
return {
|
|
1824
|
+
availableWidth,
|
|
1825
|
+
maxValueWidth,
|
|
1826
|
+
spacingWidth: SearchableSelectList.DESCRIPTION_SPACING_WIDTH
|
|
1827
|
+
};
|
|
1828
|
+
}
|
|
1829
|
+
handleInput(keyData) {
|
|
1830
|
+
if (isKeyRelease(keyData)) return;
|
|
1831
|
+
const allowVimNav = !this.searchInput.getValue().trim();
|
|
1832
|
+
if (matchesKey(keyData, "up") || matchesKey(keyData, "ctrl+p") || allowVimNav && keyData === "k") {
|
|
1833
|
+
this.selectedIndex = Math.max(0, this.selectedIndex - 1);
|
|
1834
|
+
this.notifySelectionChange();
|
|
1835
|
+
return;
|
|
1836
|
+
}
|
|
1837
|
+
if (matchesKey(keyData, "down") || matchesKey(keyData, "ctrl+n") || allowVimNav && keyData === "j") {
|
|
1838
|
+
this.selectedIndex = Math.min(this.filteredItems.length - 1, this.selectedIndex + 1);
|
|
1839
|
+
this.notifySelectionChange();
|
|
1840
|
+
return;
|
|
1841
|
+
}
|
|
1842
|
+
if (matchesKey(keyData, "enter")) {
|
|
1843
|
+
const item = this.filteredItems[this.selectedIndex];
|
|
1844
|
+
if (item && this.onSelect) this.onSelect(item);
|
|
1845
|
+
return;
|
|
1846
|
+
}
|
|
1847
|
+
if (getEditorKeybindings().matches(keyData, "selectCancel")) {
|
|
1848
|
+
if (this.onCancel) this.onCancel();
|
|
1849
|
+
return;
|
|
1850
|
+
}
|
|
1851
|
+
const prevValue = this.searchInput.getValue();
|
|
1852
|
+
this.searchInput.handleInput(keyData);
|
|
1853
|
+
if (prevValue !== this.searchInput.getValue()) this.updateFilter();
|
|
1854
|
+
}
|
|
1855
|
+
notifySelectionChange() {
|
|
1856
|
+
const item = this.filteredItems[this.selectedIndex];
|
|
1857
|
+
if (item && this.onSelectionChange) this.onSelectionChange(item);
|
|
1858
|
+
}
|
|
1859
|
+
getSelectedItem() {
|
|
1860
|
+
return this.filteredItems[this.selectedIndex] ?? null;
|
|
1861
|
+
}
|
|
1862
|
+
};
|
|
1863
|
+
//#endregion
|
|
1864
|
+
//#region src/tui/components/selectors.ts
|
|
1865
|
+
function createSearchableSelectList(items, maxVisible = 7) {
|
|
1866
|
+
return new SearchableSelectList(items, maxVisible, searchableSelectListTheme);
|
|
1867
|
+
}
|
|
1868
|
+
function createFilterableSelectList(items, maxVisible = 7) {
|
|
1869
|
+
return new FilterableSelectList(items, maxVisible, filterableSelectListTheme);
|
|
1870
|
+
}
|
|
1871
|
+
function createSettingsList(items, onChange, onCancel, maxVisible = 7) {
|
|
1872
|
+
return new SettingsList(items, maxVisible, settingsListTheme, onChange, onCancel);
|
|
1873
|
+
}
|
|
1874
|
+
//#endregion
|
|
1875
|
+
//#region src/tui/tui-status-summary.ts
|
|
1876
|
+
function formatStatusSummary(summary) {
|
|
1877
|
+
const lines = [];
|
|
1878
|
+
lines.push("Gateway status");
|
|
1879
|
+
if (summary.runtimeVersion) lines.push(`Version: ${summary.runtimeVersion}`);
|
|
1880
|
+
if (!summary.linkChannel) lines.push("Link channel: unknown");
|
|
1881
|
+
else {
|
|
1882
|
+
const linkLabel = summary.linkChannel.label ?? "Link channel";
|
|
1883
|
+
const linked = summary.linkChannel.linked === true;
|
|
1884
|
+
const authAge = linked && typeof summary.linkChannel.authAgeMs === "number" ? ` (last refreshed ${formatTimeAgo(summary.linkChannel.authAgeMs)})` : "";
|
|
1885
|
+
lines.push(`${linkLabel}: ${linked ? "linked" : "not linked"}${authAge}`);
|
|
1886
|
+
}
|
|
1887
|
+
const providerSummary = Array.isArray(summary.providerSummary) ? summary.providerSummary : [];
|
|
1888
|
+
if (providerSummary.length > 0) {
|
|
1889
|
+
lines.push("");
|
|
1890
|
+
lines.push("System:");
|
|
1891
|
+
for (const line of providerSummary) lines.push(` ${line}`);
|
|
1892
|
+
}
|
|
1893
|
+
const heartbeatAgents = summary.heartbeat?.agents ?? [];
|
|
1894
|
+
if (heartbeatAgents.length > 0) {
|
|
1895
|
+
const heartbeatParts = heartbeatAgents.map((agent) => {
|
|
1896
|
+
const agentId = agent.agentId ?? "unknown";
|
|
1897
|
+
if (!agent.enabled || !agent.everyMs) return `disabled (${agentId})`;
|
|
1898
|
+
return `${agent.every ?? "unknown"} (${agentId})`;
|
|
1899
|
+
});
|
|
1900
|
+
lines.push("");
|
|
1901
|
+
lines.push(`Heartbeat: ${heartbeatParts.join(", ")}`);
|
|
1902
|
+
}
|
|
1903
|
+
const sessionPaths = summary.sessions?.paths ?? [];
|
|
1904
|
+
if (sessionPaths.length === 1) lines.push(`Session store: ${sessionPaths[0]}`);
|
|
1905
|
+
else if (sessionPaths.length > 1) lines.push(`Session stores: ${sessionPaths.length}`);
|
|
1906
|
+
const defaults = summary.sessions?.defaults;
|
|
1907
|
+
const defaultModel = defaults?.model ?? "unknown";
|
|
1908
|
+
const defaultCtx = typeof defaults?.contextTokens === "number" ? ` (${formatTokenCount(defaults.contextTokens)} ctx)` : "";
|
|
1909
|
+
lines.push(`Default model: ${defaultModel}${defaultCtx}`);
|
|
1910
|
+
const sessionCount = summary.sessions?.count ?? 0;
|
|
1911
|
+
lines.push(`Active sessions: ${sessionCount}`);
|
|
1912
|
+
const recent = Array.isArray(summary.sessions?.recent) ? summary.sessions?.recent : [];
|
|
1913
|
+
if (recent.length > 0) {
|
|
1914
|
+
lines.push("Recent sessions:");
|
|
1915
|
+
for (const entry of recent) {
|
|
1916
|
+
const ageLabel = typeof entry.age === "number" ? formatTimeAgo(entry.age) : "no activity";
|
|
1917
|
+
const model = entry.model ?? "unknown";
|
|
1918
|
+
const usage = formatContextUsageLine({
|
|
1919
|
+
total: entry.totalTokens ?? null,
|
|
1920
|
+
context: entry.contextTokens ?? null,
|
|
1921
|
+
remaining: entry.remainingTokens ?? null,
|
|
1922
|
+
percent: entry.percentUsed ?? null
|
|
1923
|
+
});
|
|
1924
|
+
const flags = entry.flags?.length ? ` | flags: ${entry.flags.join(", ")}` : "";
|
|
1925
|
+
lines.push(`- ${entry.key}${entry.kind ? ` [${entry.kind}]` : ""} | ${ageLabel} | model ${model} | ${usage}${flags}`);
|
|
1926
|
+
}
|
|
1927
|
+
}
|
|
1928
|
+
const queued = Array.isArray(summary.queuedSystemEvents) ? summary.queuedSystemEvents : [];
|
|
1929
|
+
if (queued.length > 0) {
|
|
1930
|
+
const preview = queued.slice(0, 3).join(" | ");
|
|
1931
|
+
lines.push(`Queued system events (${queued.length}): ${preview}`);
|
|
1932
|
+
}
|
|
1933
|
+
return lines;
|
|
1934
|
+
}
|
|
1935
|
+
//#endregion
|
|
1936
|
+
//#region src/tui/tui-command-handlers.ts
|
|
1937
|
+
function isBtwCommand(text) {
|
|
1938
|
+
return /^\/btw(?::|\s|$)/i.test(text.trim());
|
|
1939
|
+
}
|
|
1940
|
+
function createCommandHandlers(context) {
|
|
1941
|
+
const { client, chatLog, tui, opts, state, deliverDefault, openOverlay, closeOverlay, refreshSessionInfo, loadHistory, setSession, refreshAgents, abortActive, setActivityStatus, formatSessionKey, applySessionInfoFromPatch, noteLocalRunId, noteLocalBtwRunId, forgetLocalRunId, forgetLocalBtwRunId, requestExit } = context;
|
|
1942
|
+
const setAgent = async (id) => {
|
|
1943
|
+
state.currentAgentId = normalizeAgentId(id);
|
|
1944
|
+
await setSession("");
|
|
1945
|
+
};
|
|
1946
|
+
const closeOverlayAndRender = () => {
|
|
1947
|
+
closeOverlay();
|
|
1948
|
+
tui.requestRender();
|
|
1949
|
+
};
|
|
1950
|
+
const openSelector = (selector, onSelect) => {
|
|
1951
|
+
selector.onSelect = (item) => {
|
|
1952
|
+
(async () => {
|
|
1953
|
+
await onSelect(item.value);
|
|
1954
|
+
closeOverlayAndRender();
|
|
1955
|
+
})();
|
|
1956
|
+
};
|
|
1957
|
+
selector.onCancel = closeOverlayAndRender;
|
|
1958
|
+
openOverlay(selector);
|
|
1959
|
+
tui.requestRender();
|
|
1960
|
+
};
|
|
1961
|
+
const openModelSelector = async () => {
|
|
1962
|
+
try {
|
|
1963
|
+
const models = await client.listModels();
|
|
1964
|
+
if (models.length === 0) {
|
|
1965
|
+
chatLog.addSystem("no models available");
|
|
1966
|
+
tui.requestRender();
|
|
1967
|
+
return;
|
|
1968
|
+
}
|
|
1969
|
+
openSelector(createSearchableSelectList(models.map((model) => ({
|
|
1970
|
+
value: `${model.provider}/${model.id}`,
|
|
1971
|
+
label: `${model.provider}/${model.id}`,
|
|
1972
|
+
description: model.name && model.name !== model.id ? model.name : ""
|
|
1973
|
+
})), 9), async (value) => {
|
|
1974
|
+
try {
|
|
1975
|
+
const result = await client.patchSession({
|
|
1976
|
+
key: state.currentSessionKey,
|
|
1977
|
+
model: value
|
|
1978
|
+
});
|
|
1979
|
+
chatLog.addSystem(`model set to ${value}`);
|
|
1980
|
+
applySessionInfoFromPatch(result);
|
|
1981
|
+
await refreshSessionInfo();
|
|
1982
|
+
} catch (err) {
|
|
1983
|
+
chatLog.addSystem(`model set failed: ${String(err)}`);
|
|
1984
|
+
}
|
|
1985
|
+
});
|
|
1986
|
+
} catch (err) {
|
|
1987
|
+
chatLog.addSystem(`model list failed: ${String(err)}`);
|
|
1988
|
+
tui.requestRender();
|
|
1989
|
+
}
|
|
1990
|
+
};
|
|
1991
|
+
const openAgentSelector = async () => {
|
|
1992
|
+
await refreshAgents();
|
|
1993
|
+
if (state.agents.length === 0) {
|
|
1994
|
+
chatLog.addSystem("no agents found");
|
|
1995
|
+
tui.requestRender();
|
|
1996
|
+
return;
|
|
1997
|
+
}
|
|
1998
|
+
openSelector(createSearchableSelectList(state.agents.map((agent) => ({
|
|
1999
|
+
value: agent.id,
|
|
2000
|
+
label: agent.name ? `${agent.id} (${agent.name})` : agent.id,
|
|
2001
|
+
description: agent.id === state.agentDefaultId ? "default" : ""
|
|
2002
|
+
})), 9), async (value) => {
|
|
2003
|
+
await setAgent(value);
|
|
2004
|
+
});
|
|
2005
|
+
};
|
|
2006
|
+
const openSessionSelector = async () => {
|
|
2007
|
+
try {
|
|
2008
|
+
openSelector(createFilterableSelectList((await client.listSessions({
|
|
2009
|
+
includeGlobal: false,
|
|
2010
|
+
includeUnknown: false,
|
|
2011
|
+
includeDerivedTitles: true,
|
|
2012
|
+
includeLastMessage: true,
|
|
2013
|
+
agentId: state.currentAgentId
|
|
2014
|
+
})).sessions.map((session) => {
|
|
2015
|
+
const title = session.derivedTitle ?? session.displayName;
|
|
2016
|
+
const formattedKey = formatSessionKey(session.key);
|
|
2017
|
+
const label = title && title !== formattedKey ? `${title} (${formattedKey})` : formattedKey;
|
|
2018
|
+
const timePart = session.updatedAt ? formatRelativeTimestamp(session.updatedAt, {
|
|
2019
|
+
dateFallback: true,
|
|
2020
|
+
fallback: ""
|
|
2021
|
+
}) : "";
|
|
2022
|
+
const preview = session.lastMessagePreview?.replace(/\s+/g, " ").trim();
|
|
2023
|
+
const description = timePart && preview ? `${timePart} · ${preview}` : preview ?? timePart;
|
|
2024
|
+
return {
|
|
2025
|
+
value: session.key,
|
|
2026
|
+
label,
|
|
2027
|
+
description,
|
|
2028
|
+
searchText: [
|
|
2029
|
+
session.displayName,
|
|
2030
|
+
session.label,
|
|
2031
|
+
session.subject,
|
|
2032
|
+
session.sessionId,
|
|
2033
|
+
session.key,
|
|
2034
|
+
session.lastMessagePreview
|
|
2035
|
+
].filter(Boolean).join(" ")
|
|
2036
|
+
};
|
|
2037
|
+
}), 9), async (value) => {
|
|
2038
|
+
await setSession(value);
|
|
2039
|
+
});
|
|
2040
|
+
} catch (err) {
|
|
2041
|
+
chatLog.addSystem(`sessions list failed: ${String(err)}`);
|
|
2042
|
+
tui.requestRender();
|
|
2043
|
+
}
|
|
2044
|
+
};
|
|
2045
|
+
const openSettings = () => {
|
|
2046
|
+
openOverlay(createSettingsList([{
|
|
2047
|
+
id: "tools",
|
|
2048
|
+
label: "Tool output",
|
|
2049
|
+
currentValue: state.toolsExpanded ? "expanded" : "collapsed",
|
|
2050
|
+
values: ["collapsed", "expanded"]
|
|
2051
|
+
}, {
|
|
2052
|
+
id: "thinking",
|
|
2053
|
+
label: "Show thinking",
|
|
2054
|
+
currentValue: state.showThinking ? "on" : "off",
|
|
2055
|
+
values: ["off", "on"]
|
|
2056
|
+
}], (id, value) => {
|
|
2057
|
+
if (id === "tools") {
|
|
2058
|
+
state.toolsExpanded = value === "expanded";
|
|
2059
|
+
chatLog.setToolsExpanded(state.toolsExpanded);
|
|
2060
|
+
}
|
|
2061
|
+
if (id === "thinking") {
|
|
2062
|
+
state.showThinking = value === "on";
|
|
2063
|
+
loadHistory();
|
|
2064
|
+
}
|
|
2065
|
+
tui.requestRender();
|
|
2066
|
+
}, () => {
|
|
2067
|
+
closeOverlay();
|
|
2068
|
+
tui.requestRender();
|
|
2069
|
+
}));
|
|
2070
|
+
tui.requestRender();
|
|
2071
|
+
};
|
|
2072
|
+
const handleCommand = async (raw) => {
|
|
2073
|
+
const { name, args } = parseCommand(raw);
|
|
2074
|
+
if (!name) return;
|
|
2075
|
+
switch (name) {
|
|
2076
|
+
case "help":
|
|
2077
|
+
chatLog.addSystem(helpText({
|
|
2078
|
+
provider: state.sessionInfo.modelProvider,
|
|
2079
|
+
model: state.sessionInfo.model
|
|
2080
|
+
}));
|
|
2081
|
+
break;
|
|
2082
|
+
case "status":
|
|
2083
|
+
try {
|
|
2084
|
+
const status = await client.getStatus();
|
|
2085
|
+
if (typeof status === "string") {
|
|
2086
|
+
chatLog.addSystem(status);
|
|
2087
|
+
break;
|
|
2088
|
+
}
|
|
2089
|
+
if (status && typeof status === "object") {
|
|
2090
|
+
const lines = formatStatusSummary(status);
|
|
2091
|
+
for (const line of lines) chatLog.addSystem(line);
|
|
2092
|
+
break;
|
|
2093
|
+
}
|
|
2094
|
+
chatLog.addSystem("status: unknown response");
|
|
2095
|
+
} catch (err) {
|
|
2096
|
+
chatLog.addSystem(`status failed: ${String(err)}`);
|
|
2097
|
+
}
|
|
2098
|
+
break;
|
|
2099
|
+
case "agent":
|
|
2100
|
+
if (!args) await openAgentSelector();
|
|
2101
|
+
else await setAgent(args);
|
|
2102
|
+
break;
|
|
2103
|
+
case "agents":
|
|
2104
|
+
await openAgentSelector();
|
|
2105
|
+
break;
|
|
2106
|
+
case "session":
|
|
2107
|
+
if (!args) await openSessionSelector();
|
|
2108
|
+
else await setSession(args);
|
|
2109
|
+
break;
|
|
2110
|
+
case "sessions":
|
|
2111
|
+
await openSessionSelector();
|
|
2112
|
+
break;
|
|
2113
|
+
case "model":
|
|
2114
|
+
if (!args) await openModelSelector();
|
|
2115
|
+
else try {
|
|
2116
|
+
const result = await client.patchSession({
|
|
2117
|
+
key: state.currentSessionKey,
|
|
2118
|
+
model: args
|
|
2119
|
+
});
|
|
2120
|
+
chatLog.addSystem(`model set to ${args}`);
|
|
2121
|
+
applySessionInfoFromPatch(result);
|
|
2122
|
+
await refreshSessionInfo();
|
|
2123
|
+
} catch (err) {
|
|
2124
|
+
chatLog.addSystem(`model set failed: ${String(err)}`);
|
|
2125
|
+
}
|
|
2126
|
+
break;
|
|
2127
|
+
case "models":
|
|
2128
|
+
await openModelSelector();
|
|
2129
|
+
break;
|
|
2130
|
+
case "think":
|
|
2131
|
+
if (!args) {
|
|
2132
|
+
const levels = formatThinkingLevels(state.sessionInfo.modelProvider, state.sessionInfo.model, "|");
|
|
2133
|
+
chatLog.addSystem(`usage: /think <${levels}>`);
|
|
2134
|
+
break;
|
|
2135
|
+
}
|
|
2136
|
+
try {
|
|
2137
|
+
const result = await client.patchSession({
|
|
2138
|
+
key: state.currentSessionKey,
|
|
2139
|
+
thinkingLevel: args
|
|
2140
|
+
});
|
|
2141
|
+
chatLog.addSystem(`thinking set to ${args}`);
|
|
2142
|
+
applySessionInfoFromPatch(result);
|
|
2143
|
+
await refreshSessionInfo();
|
|
2144
|
+
} catch (err) {
|
|
2145
|
+
chatLog.addSystem(`think failed: ${String(err)}`);
|
|
2146
|
+
}
|
|
2147
|
+
break;
|
|
2148
|
+
case "verbose":
|
|
2149
|
+
if (!args) {
|
|
2150
|
+
chatLog.addSystem("usage: /verbose <on|off>");
|
|
2151
|
+
break;
|
|
2152
|
+
}
|
|
2153
|
+
try {
|
|
2154
|
+
const result = await client.patchSession({
|
|
2155
|
+
key: state.currentSessionKey,
|
|
2156
|
+
verboseLevel: args
|
|
2157
|
+
});
|
|
2158
|
+
chatLog.addSystem(`verbose set to ${args}`);
|
|
2159
|
+
applySessionInfoFromPatch(result);
|
|
2160
|
+
await loadHistory();
|
|
2161
|
+
} catch (err) {
|
|
2162
|
+
chatLog.addSystem(`verbose failed: ${String(err)}`);
|
|
2163
|
+
}
|
|
2164
|
+
break;
|
|
2165
|
+
case "fast":
|
|
2166
|
+
if (!args || args === "status") {
|
|
2167
|
+
chatLog.addSystem(`fast mode: ${state.sessionInfo.fastMode ? "on" : "off"}`);
|
|
2168
|
+
break;
|
|
2169
|
+
}
|
|
2170
|
+
if (args !== "on" && args !== "off") {
|
|
2171
|
+
chatLog.addSystem("usage: /fast <status|on|off>");
|
|
2172
|
+
break;
|
|
2173
|
+
}
|
|
2174
|
+
try {
|
|
2175
|
+
const result = await client.patchSession({
|
|
2176
|
+
key: state.currentSessionKey,
|
|
2177
|
+
fastMode: args === "on"
|
|
2178
|
+
});
|
|
2179
|
+
chatLog.addSystem(`fast mode ${args === "on" ? "enabled" : "disabled"}`);
|
|
2180
|
+
applySessionInfoFromPatch(result);
|
|
2181
|
+
await refreshSessionInfo();
|
|
2182
|
+
} catch (err) {
|
|
2183
|
+
chatLog.addSystem(`fast failed: ${String(err)}`);
|
|
2184
|
+
}
|
|
2185
|
+
break;
|
|
2186
|
+
case "reasoning":
|
|
2187
|
+
if (!args) {
|
|
2188
|
+
chatLog.addSystem("usage: /reasoning <on|off>");
|
|
2189
|
+
break;
|
|
2190
|
+
}
|
|
2191
|
+
try {
|
|
2192
|
+
const result = await client.patchSession({
|
|
2193
|
+
key: state.currentSessionKey,
|
|
2194
|
+
reasoningLevel: args
|
|
2195
|
+
});
|
|
2196
|
+
chatLog.addSystem(`reasoning set to ${args}`);
|
|
2197
|
+
applySessionInfoFromPatch(result);
|
|
2198
|
+
await refreshSessionInfo();
|
|
2199
|
+
} catch (err) {
|
|
2200
|
+
chatLog.addSystem(`reasoning failed: ${String(err)}`);
|
|
2201
|
+
}
|
|
2202
|
+
break;
|
|
2203
|
+
case "usage": {
|
|
2204
|
+
const normalized = args ? normalizeUsageDisplay(args) : void 0;
|
|
2205
|
+
if (args && !normalized) {
|
|
2206
|
+
chatLog.addSystem("usage: /usage <off|tokens|full>");
|
|
2207
|
+
break;
|
|
2208
|
+
}
|
|
2209
|
+
const currentRaw = state.sessionInfo.responseUsage;
|
|
2210
|
+
const current = resolveResponseUsageMode(currentRaw);
|
|
2211
|
+
const next = normalized ?? (current === "off" ? "tokens" : current === "tokens" ? "full" : "off");
|
|
2212
|
+
try {
|
|
2213
|
+
const result = await client.patchSession({
|
|
2214
|
+
key: state.currentSessionKey,
|
|
2215
|
+
responseUsage: next === "off" ? null : next
|
|
2216
|
+
});
|
|
2217
|
+
chatLog.addSystem(`usage footer: ${next}`);
|
|
2218
|
+
applySessionInfoFromPatch(result);
|
|
2219
|
+
await refreshSessionInfo();
|
|
2220
|
+
} catch (err) {
|
|
2221
|
+
chatLog.addSystem(`usage failed: ${String(err)}`);
|
|
2222
|
+
}
|
|
2223
|
+
break;
|
|
2224
|
+
}
|
|
2225
|
+
case "elevated":
|
|
2226
|
+
if (!args) {
|
|
2227
|
+
chatLog.addSystem("usage: /elevated <on|off|ask|full>");
|
|
2228
|
+
break;
|
|
2229
|
+
}
|
|
2230
|
+
if (![
|
|
2231
|
+
"on",
|
|
2232
|
+
"off",
|
|
2233
|
+
"ask",
|
|
2234
|
+
"full"
|
|
2235
|
+
].includes(args)) {
|
|
2236
|
+
chatLog.addSystem("usage: /elevated <on|off|ask|full>");
|
|
2237
|
+
break;
|
|
2238
|
+
}
|
|
2239
|
+
try {
|
|
2240
|
+
const result = await client.patchSession({
|
|
2241
|
+
key: state.currentSessionKey,
|
|
2242
|
+
elevatedLevel: args
|
|
2243
|
+
});
|
|
2244
|
+
chatLog.addSystem(`elevated set to ${args}`);
|
|
2245
|
+
applySessionInfoFromPatch(result);
|
|
2246
|
+
await refreshSessionInfo();
|
|
2247
|
+
} catch (err) {
|
|
2248
|
+
chatLog.addSystem(`elevated failed: ${String(err)}`);
|
|
2249
|
+
}
|
|
2250
|
+
break;
|
|
2251
|
+
case "activation":
|
|
2252
|
+
if (!args) {
|
|
2253
|
+
chatLog.addSystem("usage: /activation <mention|always>");
|
|
2254
|
+
break;
|
|
2255
|
+
}
|
|
2256
|
+
try {
|
|
2257
|
+
const result = await client.patchSession({
|
|
2258
|
+
key: state.currentSessionKey,
|
|
2259
|
+
groupActivation: args === "always" ? "always" : "mention"
|
|
2260
|
+
});
|
|
2261
|
+
chatLog.addSystem(`activation set to ${args}`);
|
|
2262
|
+
applySessionInfoFromPatch(result);
|
|
2263
|
+
await refreshSessionInfo();
|
|
2264
|
+
} catch (err) {
|
|
2265
|
+
chatLog.addSystem(`activation failed: ${String(err)}`);
|
|
2266
|
+
}
|
|
2267
|
+
break;
|
|
2268
|
+
case "new":
|
|
2269
|
+
try {
|
|
2270
|
+
state.sessionInfo.inputTokens = null;
|
|
2271
|
+
state.sessionInfo.outputTokens = null;
|
|
2272
|
+
state.sessionInfo.totalTokens = null;
|
|
2273
|
+
tui.requestRender();
|
|
2274
|
+
const uniqueKey = `tui-${randomUUID()}`;
|
|
2275
|
+
await setSession(uniqueKey);
|
|
2276
|
+
chatLog.addSystem(`new session: ${uniqueKey}`);
|
|
2277
|
+
} catch (err) {
|
|
2278
|
+
chatLog.addSystem(`new session failed: ${sanitizeRenderableText(String(err))}`);
|
|
2279
|
+
}
|
|
2280
|
+
break;
|
|
2281
|
+
case "reset":
|
|
2282
|
+
try {
|
|
2283
|
+
state.sessionInfo.inputTokens = null;
|
|
2284
|
+
state.sessionInfo.outputTokens = null;
|
|
2285
|
+
state.sessionInfo.totalTokens = null;
|
|
2286
|
+
tui.requestRender();
|
|
2287
|
+
await client.resetSession(state.currentSessionKey, name);
|
|
2288
|
+
chatLog.addSystem(`session ${state.currentSessionKey} reset`);
|
|
2289
|
+
await loadHistory();
|
|
2290
|
+
} catch (err) {
|
|
2291
|
+
chatLog.addSystem(`reset failed: ${sanitizeRenderableText(String(err))}`);
|
|
2292
|
+
}
|
|
2293
|
+
break;
|
|
2294
|
+
case "abort":
|
|
2295
|
+
await abortActive();
|
|
2296
|
+
break;
|
|
2297
|
+
case "settings":
|
|
2298
|
+
openSettings();
|
|
2299
|
+
break;
|
|
2300
|
+
case "exit":
|
|
2301
|
+
case "quit":
|
|
2302
|
+
requestExit();
|
|
2303
|
+
break;
|
|
2304
|
+
default:
|
|
2305
|
+
await sendMessage(raw);
|
|
2306
|
+
break;
|
|
2307
|
+
}
|
|
2308
|
+
tui.requestRender();
|
|
2309
|
+
};
|
|
2310
|
+
const sendMessage = async (text) => {
|
|
2311
|
+
if (!state.isConnected) {
|
|
2312
|
+
chatLog.addSystem("not connected to gateway — message not sent");
|
|
2313
|
+
setActivityStatus("disconnected");
|
|
2314
|
+
tui.requestRender();
|
|
2315
|
+
return;
|
|
2316
|
+
}
|
|
2317
|
+
const isBtw = isBtwCommand(text);
|
|
2318
|
+
const runId = randomUUID();
|
|
2319
|
+
try {
|
|
2320
|
+
if (!isBtw) {
|
|
2321
|
+
chatLog.addUser(text);
|
|
2322
|
+
noteLocalRunId(runId);
|
|
2323
|
+
state.activeChatRunId = runId;
|
|
2324
|
+
setActivityStatus("sending");
|
|
2325
|
+
} else noteLocalBtwRunId?.(runId);
|
|
2326
|
+
tui.requestRender();
|
|
2327
|
+
await client.sendChat({
|
|
2328
|
+
sessionKey: state.currentSessionKey,
|
|
2329
|
+
message: text,
|
|
2330
|
+
thinking: opts.thinking,
|
|
2331
|
+
deliver: deliverDefault,
|
|
2332
|
+
timeoutMs: opts.timeoutMs,
|
|
2333
|
+
runId
|
|
2334
|
+
});
|
|
2335
|
+
if (!isBtw) {
|
|
2336
|
+
setActivityStatus("waiting");
|
|
2337
|
+
tui.requestRender();
|
|
2338
|
+
}
|
|
2339
|
+
} catch (err) {
|
|
2340
|
+
if (isBtw) forgetLocalBtwRunId?.(runId);
|
|
2341
|
+
if (!isBtw && state.activeChatRunId) forgetLocalRunId?.(state.activeChatRunId);
|
|
2342
|
+
if (!isBtw) state.activeChatRunId = null;
|
|
2343
|
+
chatLog.addSystem(`${isBtw ? "btw failed" : "send failed"}: ${String(err)}`);
|
|
2344
|
+
if (!isBtw) setActivityStatus("error");
|
|
2345
|
+
tui.requestRender();
|
|
2346
|
+
}
|
|
2347
|
+
};
|
|
2348
|
+
return {
|
|
2349
|
+
handleCommand,
|
|
2350
|
+
sendMessage,
|
|
2351
|
+
openModelSelector,
|
|
2352
|
+
openAgentSelector,
|
|
2353
|
+
openSessionSelector,
|
|
2354
|
+
openSettings,
|
|
2355
|
+
setAgent
|
|
2356
|
+
};
|
|
2357
|
+
}
|
|
2358
|
+
//#endregion
|
|
2359
|
+
//#region src/tui/tui-stream-assembler.ts
|
|
2360
|
+
function extractTextBlocksAndSignals(message) {
|
|
2361
|
+
if (!message || typeof message !== "object") return {
|
|
2362
|
+
textBlocks: [],
|
|
2363
|
+
sawNonTextContentBlocks: false
|
|
2364
|
+
};
|
|
2365
|
+
const content = message.content;
|
|
2366
|
+
if (typeof content === "string") {
|
|
2367
|
+
const text = content.trim();
|
|
2368
|
+
return {
|
|
2369
|
+
textBlocks: text ? [text] : [],
|
|
2370
|
+
sawNonTextContentBlocks: false
|
|
2371
|
+
};
|
|
2372
|
+
}
|
|
2373
|
+
if (!Array.isArray(content)) return {
|
|
2374
|
+
textBlocks: [],
|
|
2375
|
+
sawNonTextContentBlocks: false
|
|
2376
|
+
};
|
|
2377
|
+
const textBlocks = [];
|
|
2378
|
+
let sawNonTextContentBlocks = false;
|
|
2379
|
+
for (const block of content) {
|
|
2380
|
+
if (!block || typeof block !== "object") continue;
|
|
2381
|
+
const rec = block;
|
|
2382
|
+
if (rec.type === "text" && typeof rec.text === "string") {
|
|
2383
|
+
const text = rec.text.trim();
|
|
2384
|
+
if (text) textBlocks.push(text);
|
|
2385
|
+
continue;
|
|
2386
|
+
}
|
|
2387
|
+
if (typeof rec.type === "string" && rec.type !== "thinking") sawNonTextContentBlocks = true;
|
|
2388
|
+
}
|
|
2389
|
+
return {
|
|
2390
|
+
textBlocks,
|
|
2391
|
+
sawNonTextContentBlocks
|
|
2392
|
+
};
|
|
2393
|
+
}
|
|
2394
|
+
function isDroppedBoundaryTextBlockSubset(params) {
|
|
2395
|
+
const { streamedTextBlocks, finalTextBlocks } = params;
|
|
2396
|
+
if (finalTextBlocks.length === 0 || finalTextBlocks.length >= streamedTextBlocks.length) return false;
|
|
2397
|
+
if (finalTextBlocks.every((block, index) => streamedTextBlocks[index] === block)) return true;
|
|
2398
|
+
const suffixStart = streamedTextBlocks.length - finalTextBlocks.length;
|
|
2399
|
+
return finalTextBlocks.every((block, index) => streamedTextBlocks[suffixStart + index] === block);
|
|
2400
|
+
}
|
|
2401
|
+
function shouldPreserveBoundaryDroppedText(params) {
|
|
2402
|
+
if (params.boundaryDropMode === "off") return false;
|
|
2403
|
+
if (!(params.boundaryDropMode === "streamed-or-incoming" ? params.streamedSawNonTextContentBlocks || params.incomingSawNonTextContentBlocks : params.streamedSawNonTextContentBlocks)) return false;
|
|
2404
|
+
return isDroppedBoundaryTextBlockSubset({
|
|
2405
|
+
streamedTextBlocks: params.streamedTextBlocks,
|
|
2406
|
+
finalTextBlocks: params.nextContentBlocks
|
|
2407
|
+
});
|
|
2408
|
+
}
|
|
2409
|
+
var TuiStreamAssembler = class {
|
|
2410
|
+
constructor() {
|
|
2411
|
+
this.runs = /* @__PURE__ */ new Map();
|
|
2412
|
+
}
|
|
2413
|
+
getOrCreateRun(runId) {
|
|
2414
|
+
let state = this.runs.get(runId);
|
|
2415
|
+
if (!state) {
|
|
2416
|
+
state = {
|
|
2417
|
+
thinkingText: "",
|
|
2418
|
+
contentText: "",
|
|
2419
|
+
contentBlocks: [],
|
|
2420
|
+
sawNonTextContentBlocks: false,
|
|
2421
|
+
displayText: ""
|
|
2422
|
+
};
|
|
2423
|
+
this.runs.set(runId, state);
|
|
2424
|
+
}
|
|
2425
|
+
return state;
|
|
2426
|
+
}
|
|
2427
|
+
updateRunState(state, message, showThinking, opts) {
|
|
2428
|
+
const thinkingText = extractThinkingFromMessage(message);
|
|
2429
|
+
const contentText = extractContentFromMessage(message);
|
|
2430
|
+
const { textBlocks, sawNonTextContentBlocks } = extractTextBlocksAndSignals(message);
|
|
2431
|
+
if (thinkingText) state.thinkingText = thinkingText;
|
|
2432
|
+
if (contentText) {
|
|
2433
|
+
const nextContentBlocks = textBlocks.length > 0 ? textBlocks : [contentText];
|
|
2434
|
+
if (!shouldPreserveBoundaryDroppedText({
|
|
2435
|
+
boundaryDropMode: opts?.boundaryDropMode ?? "off",
|
|
2436
|
+
streamedSawNonTextContentBlocks: state.sawNonTextContentBlocks,
|
|
2437
|
+
incomingSawNonTextContentBlocks: sawNonTextContentBlocks,
|
|
2438
|
+
streamedTextBlocks: state.contentBlocks,
|
|
2439
|
+
nextContentBlocks
|
|
2440
|
+
})) {
|
|
2441
|
+
state.contentText = contentText;
|
|
2442
|
+
state.contentBlocks = nextContentBlocks;
|
|
2443
|
+
}
|
|
2444
|
+
}
|
|
2445
|
+
if (sawNonTextContentBlocks) state.sawNonTextContentBlocks = true;
|
|
2446
|
+
state.displayText = composeThinkingAndContent({
|
|
2447
|
+
thinkingText: state.thinkingText,
|
|
2448
|
+
contentText: state.contentText,
|
|
2449
|
+
showThinking
|
|
2450
|
+
});
|
|
2451
|
+
}
|
|
2452
|
+
ingestDelta(runId, message, showThinking) {
|
|
2453
|
+
const state = this.getOrCreateRun(runId);
|
|
2454
|
+
const previousDisplayText = state.displayText;
|
|
2455
|
+
this.updateRunState(state, message, showThinking, { boundaryDropMode: "streamed-or-incoming" });
|
|
2456
|
+
if (!state.displayText || state.displayText === previousDisplayText) return null;
|
|
2457
|
+
return state.displayText;
|
|
2458
|
+
}
|
|
2459
|
+
finalize(runId, message, showThinking, errorMessage) {
|
|
2460
|
+
const state = this.getOrCreateRun(runId);
|
|
2461
|
+
const streamedDisplayText = state.displayText;
|
|
2462
|
+
const streamedTextBlocks = [...state.contentBlocks];
|
|
2463
|
+
const streamedSawNonTextContentBlocks = state.sawNonTextContentBlocks;
|
|
2464
|
+
this.updateRunState(state, message, showThinking, { boundaryDropMode: "streamed-only" });
|
|
2465
|
+
const finalComposed = state.displayText;
|
|
2466
|
+
const finalText = resolveFinalAssistantText({
|
|
2467
|
+
finalText: streamedSawNonTextContentBlocks && isDroppedBoundaryTextBlockSubset({
|
|
2468
|
+
streamedTextBlocks,
|
|
2469
|
+
finalTextBlocks: state.contentBlocks
|
|
2470
|
+
}) ? streamedDisplayText : finalComposed,
|
|
2471
|
+
streamedText: streamedDisplayText,
|
|
2472
|
+
errorMessage
|
|
2473
|
+
});
|
|
2474
|
+
this.runs.delete(runId);
|
|
2475
|
+
return finalText;
|
|
2476
|
+
}
|
|
2477
|
+
drop(runId) {
|
|
2478
|
+
this.runs.delete(runId);
|
|
2479
|
+
}
|
|
2480
|
+
};
|
|
2481
|
+
//#endregion
|
|
2482
|
+
//#region src/tui/tui-event-handlers.ts
|
|
2483
|
+
function createEventHandlers(context) {
|
|
2484
|
+
const { chatLog, btw, tui, state, setActivityStatus, refreshSessionInfo, loadHistory, isLocalRunId, forgetLocalRunId, clearLocalRunIds, isLocalBtwRunId, forgetLocalBtwRunId, clearLocalBtwRunIds } = context;
|
|
2485
|
+
const finalizedRuns = /* @__PURE__ */ new Map();
|
|
2486
|
+
const sessionRuns = /* @__PURE__ */ new Map();
|
|
2487
|
+
let streamAssembler = new TuiStreamAssembler();
|
|
2488
|
+
let lastSessionKey = state.currentSessionKey;
|
|
2489
|
+
const pruneRunMap = (runs) => {
|
|
2490
|
+
if (runs.size <= 200) return;
|
|
2491
|
+
const keepUntil = Date.now() - 600 * 1e3;
|
|
2492
|
+
for (const [key, ts] of runs) {
|
|
2493
|
+
if (runs.size <= 150) break;
|
|
2494
|
+
if (ts < keepUntil) runs.delete(key);
|
|
2495
|
+
}
|
|
2496
|
+
if (runs.size > 200) for (const key of runs.keys()) {
|
|
2497
|
+
runs.delete(key);
|
|
2498
|
+
if (runs.size <= 150) break;
|
|
2499
|
+
}
|
|
2500
|
+
};
|
|
2501
|
+
const syncSessionKey = () => {
|
|
2502
|
+
if (state.currentSessionKey === lastSessionKey) return;
|
|
2503
|
+
lastSessionKey = state.currentSessionKey;
|
|
2504
|
+
finalizedRuns.clear();
|
|
2505
|
+
sessionRuns.clear();
|
|
2506
|
+
streamAssembler = new TuiStreamAssembler();
|
|
2507
|
+
clearLocalRunIds?.();
|
|
2508
|
+
clearLocalBtwRunIds?.();
|
|
2509
|
+
btw.clear();
|
|
2510
|
+
};
|
|
2511
|
+
const noteSessionRun = (runId) => {
|
|
2512
|
+
sessionRuns.set(runId, Date.now());
|
|
2513
|
+
pruneRunMap(sessionRuns);
|
|
2514
|
+
};
|
|
2515
|
+
const noteFinalizedRun = (runId) => {
|
|
2516
|
+
finalizedRuns.set(runId, Date.now());
|
|
2517
|
+
sessionRuns.delete(runId);
|
|
2518
|
+
streamAssembler.drop(runId);
|
|
2519
|
+
pruneRunMap(finalizedRuns);
|
|
2520
|
+
};
|
|
2521
|
+
const clearActiveRunIfMatch = (runId) => {
|
|
2522
|
+
if (state.activeChatRunId === runId) state.activeChatRunId = null;
|
|
2523
|
+
};
|
|
2524
|
+
const finalizeRun = (params) => {
|
|
2525
|
+
noteFinalizedRun(params.runId);
|
|
2526
|
+
clearActiveRunIfMatch(params.runId);
|
|
2527
|
+
if (params.wasActiveRun) setActivityStatus(params.status);
|
|
2528
|
+
refreshSessionInfo?.();
|
|
2529
|
+
};
|
|
2530
|
+
const terminateRun = (params) => {
|
|
2531
|
+
streamAssembler.drop(params.runId);
|
|
2532
|
+
sessionRuns.delete(params.runId);
|
|
2533
|
+
clearActiveRunIfMatch(params.runId);
|
|
2534
|
+
if (params.wasActiveRun) setActivityStatus(params.status);
|
|
2535
|
+
refreshSessionInfo?.();
|
|
2536
|
+
};
|
|
2537
|
+
const hasConcurrentActiveRun = (runId) => {
|
|
2538
|
+
const activeRunId = state.activeChatRunId;
|
|
2539
|
+
if (!activeRunId || activeRunId === runId) return false;
|
|
2540
|
+
return sessionRuns.has(activeRunId);
|
|
2541
|
+
};
|
|
2542
|
+
const maybeRefreshHistoryForRun = (runId, opts) => {
|
|
2543
|
+
if (isLocalRunId?.(runId) ?? false) {
|
|
2544
|
+
forgetLocalRunId?.(runId);
|
|
2545
|
+
if (!opts?.allowLocalWithoutDisplayableFinal) return;
|
|
2546
|
+
}
|
|
2547
|
+
if (hasConcurrentActiveRun(runId)) return;
|
|
2548
|
+
loadHistory?.();
|
|
2549
|
+
};
|
|
2550
|
+
const isSameSessionKey = (left, right) => {
|
|
2551
|
+
const normalizedLeft = (left ?? "").trim().toLowerCase();
|
|
2552
|
+
const normalizedRight = (right ?? "").trim().toLowerCase();
|
|
2553
|
+
if (!normalizedLeft || !normalizedRight) return false;
|
|
2554
|
+
if (normalizedLeft === normalizedRight) return true;
|
|
2555
|
+
const parsedLeft = parseAgentSessionKey(normalizedLeft);
|
|
2556
|
+
const parsedRight = parseAgentSessionKey(normalizedRight);
|
|
2557
|
+
if (parsedLeft && parsedRight) return parsedLeft.agentId === parsedRight.agentId && parsedLeft.rest === parsedRight.rest;
|
|
2558
|
+
if (parsedLeft) return parsedLeft.rest === normalizedRight;
|
|
2559
|
+
if (parsedRight) return normalizedLeft === parsedRight.rest;
|
|
2560
|
+
return false;
|
|
2561
|
+
};
|
|
2562
|
+
const handleChatEvent = (payload) => {
|
|
2563
|
+
if (!payload || typeof payload !== "object") return;
|
|
2564
|
+
const evt = payload;
|
|
2565
|
+
syncSessionKey();
|
|
2566
|
+
if (!isSameSessionKey(evt.sessionKey, state.currentSessionKey)) return;
|
|
2567
|
+
if (finalizedRuns.has(evt.runId)) {
|
|
2568
|
+
if (evt.state === "delta") return;
|
|
2569
|
+
if (evt.state === "final") return;
|
|
2570
|
+
}
|
|
2571
|
+
noteSessionRun(evt.runId);
|
|
2572
|
+
if (!state.activeChatRunId && !isLocalBtwRunId?.(evt.runId)) state.activeChatRunId = evt.runId;
|
|
2573
|
+
if (evt.state === "delta") {
|
|
2574
|
+
const displayText = streamAssembler.ingestDelta(evt.runId, evt.message, state.showThinking);
|
|
2575
|
+
if (!displayText) return;
|
|
2576
|
+
chatLog.updateAssistant(displayText, evt.runId);
|
|
2577
|
+
setActivityStatus("streaming");
|
|
2578
|
+
}
|
|
2579
|
+
if (evt.state === "final") {
|
|
2580
|
+
const isLocalBtwRun = isLocalBtwRunId?.(evt.runId) ?? false;
|
|
2581
|
+
const wasActiveRun = state.activeChatRunId === evt.runId;
|
|
2582
|
+
if (!evt.message && isLocalBtwRun) {
|
|
2583
|
+
forgetLocalBtwRunId?.(evt.runId);
|
|
2584
|
+
noteFinalizedRun(evt.runId);
|
|
2585
|
+
tui.requestRender();
|
|
2586
|
+
return;
|
|
2587
|
+
}
|
|
2588
|
+
if (!evt.message) {
|
|
2589
|
+
maybeRefreshHistoryForRun(evt.runId, { allowLocalWithoutDisplayableFinal: true });
|
|
2590
|
+
chatLog.dropAssistant(evt.runId);
|
|
2591
|
+
finalizeRun({
|
|
2592
|
+
runId: evt.runId,
|
|
2593
|
+
wasActiveRun,
|
|
2594
|
+
status: "idle"
|
|
2595
|
+
});
|
|
2596
|
+
tui.requestRender();
|
|
2597
|
+
return;
|
|
2598
|
+
}
|
|
2599
|
+
if (isCommandMessage(evt.message)) {
|
|
2600
|
+
maybeRefreshHistoryForRun(evt.runId);
|
|
2601
|
+
const text = extractTextFromMessage(evt.message);
|
|
2602
|
+
if (text) chatLog.addSystem(text);
|
|
2603
|
+
finalizeRun({
|
|
2604
|
+
runId: evt.runId,
|
|
2605
|
+
wasActiveRun,
|
|
2606
|
+
status: "idle"
|
|
2607
|
+
});
|
|
2608
|
+
tui.requestRender();
|
|
2609
|
+
return;
|
|
2610
|
+
}
|
|
2611
|
+
maybeRefreshHistoryForRun(evt.runId);
|
|
2612
|
+
const stopReason = evt.message && typeof evt.message === "object" && !Array.isArray(evt.message) ? typeof evt.message.stopReason === "string" ? evt.message.stopReason : "" : "";
|
|
2613
|
+
const finalText = streamAssembler.finalize(evt.runId, evt.message, state.showThinking, evt.errorMessage);
|
|
2614
|
+
if (finalText === "(no output)" && !isLocalRunId?.(evt.runId)) chatLog.dropAssistant(evt.runId);
|
|
2615
|
+
else chatLog.finalizeAssistant(finalText, evt.runId);
|
|
2616
|
+
finalizeRun({
|
|
2617
|
+
runId: evt.runId,
|
|
2618
|
+
wasActiveRun,
|
|
2619
|
+
status: stopReason === "error" ? "error" : "idle"
|
|
2620
|
+
});
|
|
2621
|
+
}
|
|
2622
|
+
if (evt.state === "aborted") {
|
|
2623
|
+
forgetLocalBtwRunId?.(evt.runId);
|
|
2624
|
+
const wasActiveRun = state.activeChatRunId === evt.runId;
|
|
2625
|
+
chatLog.addSystem("run aborted");
|
|
2626
|
+
terminateRun({
|
|
2627
|
+
runId: evt.runId,
|
|
2628
|
+
wasActiveRun,
|
|
2629
|
+
status: "aborted"
|
|
2630
|
+
});
|
|
2631
|
+
maybeRefreshHistoryForRun(evt.runId);
|
|
2632
|
+
}
|
|
2633
|
+
if (evt.state === "error") {
|
|
2634
|
+
forgetLocalBtwRunId?.(evt.runId);
|
|
2635
|
+
const wasActiveRun = state.activeChatRunId === evt.runId;
|
|
2636
|
+
chatLog.addSystem(`run error: ${evt.errorMessage ?? "unknown"}`);
|
|
2637
|
+
terminateRun({
|
|
2638
|
+
runId: evt.runId,
|
|
2639
|
+
wasActiveRun,
|
|
2640
|
+
status: "error"
|
|
2641
|
+
});
|
|
2642
|
+
maybeRefreshHistoryForRun(evt.runId);
|
|
2643
|
+
}
|
|
2644
|
+
tui.requestRender();
|
|
2645
|
+
};
|
|
2646
|
+
const handleAgentEvent = (payload) => {
|
|
2647
|
+
if (!payload || typeof payload !== "object") return;
|
|
2648
|
+
const evt = payload;
|
|
2649
|
+
syncSessionKey();
|
|
2650
|
+
const isActiveRun = evt.runId === state.activeChatRunId;
|
|
2651
|
+
if (!(isActiveRun || sessionRuns.has(evt.runId) || finalizedRuns.has(evt.runId))) return;
|
|
2652
|
+
if (evt.stream === "tool") {
|
|
2653
|
+
const verbose = state.sessionInfo.verboseLevel ?? "off";
|
|
2654
|
+
const allowToolEvents = verbose !== "off";
|
|
2655
|
+
const allowToolOutput = verbose === "full";
|
|
2656
|
+
if (!allowToolEvents) return;
|
|
2657
|
+
const data = evt.data ?? {};
|
|
2658
|
+
const phase = asString(data.phase, "");
|
|
2659
|
+
const toolCallId = asString(data.toolCallId, "");
|
|
2660
|
+
const toolName = asString(data.name, "tool");
|
|
2661
|
+
if (!toolCallId) return;
|
|
2662
|
+
if (phase === "start") chatLog.startTool(toolCallId, toolName, data.args);
|
|
2663
|
+
else if (phase === "update") {
|
|
2664
|
+
if (!allowToolOutput) return;
|
|
2665
|
+
chatLog.updateToolResult(toolCallId, data.partialResult, { partial: true });
|
|
2666
|
+
} else if (phase === "result") if (allowToolOutput) chatLog.updateToolResult(toolCallId, data.result, { isError: Boolean(data.isError) });
|
|
2667
|
+
else chatLog.updateToolResult(toolCallId, { content: [] }, { isError: Boolean(data.isError) });
|
|
2668
|
+
tui.requestRender();
|
|
2669
|
+
return;
|
|
2670
|
+
}
|
|
2671
|
+
if (evt.stream === "lifecycle") {
|
|
2672
|
+
if (!isActiveRun) return;
|
|
2673
|
+
const phase = typeof evt.data?.phase === "string" ? evt.data.phase : "";
|
|
2674
|
+
if (phase === "start") setActivityStatus("running");
|
|
2675
|
+
if (phase === "end") setActivityStatus("idle");
|
|
2676
|
+
if (phase === "error") setActivityStatus("error");
|
|
2677
|
+
tui.requestRender();
|
|
2678
|
+
}
|
|
2679
|
+
};
|
|
2680
|
+
const handleBtwEvent = (payload) => {
|
|
2681
|
+
if (!payload || typeof payload !== "object") return;
|
|
2682
|
+
const evt = payload;
|
|
2683
|
+
syncSessionKey();
|
|
2684
|
+
if (!isSameSessionKey(evt.sessionKey, state.currentSessionKey)) return;
|
|
2685
|
+
if (evt.kind !== "btw") return;
|
|
2686
|
+
const question = evt.question.trim();
|
|
2687
|
+
const text = evt.text.trim();
|
|
2688
|
+
if (!question || !text) return;
|
|
2689
|
+
btw.showResult({
|
|
2690
|
+
question,
|
|
2691
|
+
text,
|
|
2692
|
+
isError: evt.isError
|
|
2693
|
+
});
|
|
2694
|
+
tui.requestRender();
|
|
2695
|
+
};
|
|
2696
|
+
return {
|
|
2697
|
+
handleChatEvent,
|
|
2698
|
+
handleAgentEvent,
|
|
2699
|
+
handleBtwEvent
|
|
2700
|
+
};
|
|
2701
|
+
}
|
|
2702
|
+
//#endregion
|
|
2703
|
+
//#region src/tui/tui-local-shell.ts
|
|
2704
|
+
function createLocalShellRunner(deps) {
|
|
2705
|
+
let localExecAsked = false;
|
|
2706
|
+
let localExecAllowed = false;
|
|
2707
|
+
const createSelector = deps.createSelector ?? createSearchableSelectList;
|
|
2708
|
+
const spawnCommand = deps.spawnCommand ?? spawn;
|
|
2709
|
+
const getCwd = deps.getCwd ?? (() => process.cwd());
|
|
2710
|
+
const env = deps.env ?? process.env;
|
|
2711
|
+
const maxChars = deps.maxOutputChars ?? 4e4;
|
|
2712
|
+
const ensureLocalExecAllowed = async () => {
|
|
2713
|
+
if (localExecAllowed) return true;
|
|
2714
|
+
if (localExecAsked) return false;
|
|
2715
|
+
localExecAsked = true;
|
|
2716
|
+
return await new Promise((resolve) => {
|
|
2717
|
+
deps.chatLog.addSystem("Allow local shell commands for this session?");
|
|
2718
|
+
deps.chatLog.addSystem("This runs commands on YOUR machine (not the gateway) and may delete files or reveal secrets.");
|
|
2719
|
+
deps.chatLog.addSystem("Select Yes/No (arrows + Enter), Esc to cancel.");
|
|
2720
|
+
const selector = createSelector([{
|
|
2721
|
+
value: "no",
|
|
2722
|
+
label: "No"
|
|
2723
|
+
}, {
|
|
2724
|
+
value: "yes",
|
|
2725
|
+
label: "Yes"
|
|
2726
|
+
}], 2);
|
|
2727
|
+
selector.onSelect = (item) => {
|
|
2728
|
+
deps.closeOverlay();
|
|
2729
|
+
if (item.value === "yes") {
|
|
2730
|
+
localExecAllowed = true;
|
|
2731
|
+
deps.chatLog.addSystem("local shell: enabled for this session");
|
|
2732
|
+
resolve(true);
|
|
2733
|
+
} else {
|
|
2734
|
+
deps.chatLog.addSystem("local shell: not enabled");
|
|
2735
|
+
resolve(false);
|
|
2736
|
+
}
|
|
2737
|
+
deps.tui.requestRender();
|
|
2738
|
+
};
|
|
2739
|
+
selector.onCancel = () => {
|
|
2740
|
+
deps.closeOverlay();
|
|
2741
|
+
deps.chatLog.addSystem("local shell: cancelled");
|
|
2742
|
+
deps.tui.requestRender();
|
|
2743
|
+
resolve(false);
|
|
2744
|
+
};
|
|
2745
|
+
deps.openOverlay(selector);
|
|
2746
|
+
deps.tui.requestRender();
|
|
2747
|
+
});
|
|
2748
|
+
};
|
|
2749
|
+
const runLocalShellLine = async (line) => {
|
|
2750
|
+
const cmd = line.slice(1);
|
|
2751
|
+
if (cmd === "") return;
|
|
2752
|
+
if (localExecAsked && !localExecAllowed) {
|
|
2753
|
+
deps.chatLog.addSystem("local shell: not enabled for this session");
|
|
2754
|
+
deps.tui.requestRender();
|
|
2755
|
+
return;
|
|
2756
|
+
}
|
|
2757
|
+
if (!await ensureLocalExecAllowed()) return;
|
|
2758
|
+
deps.chatLog.addSystem(`[local] $ ${cmd}`);
|
|
2759
|
+
deps.tui.requestRender();
|
|
2760
|
+
const appendWithCap = (text, chunk) => {
|
|
2761
|
+
const combined = text + chunk;
|
|
2762
|
+
return combined.length > maxChars ? combined.slice(-maxChars) : combined;
|
|
2763
|
+
};
|
|
2764
|
+
await new Promise((resolve) => {
|
|
2765
|
+
const child = spawnCommand(cmd, {
|
|
2766
|
+
shell: true,
|
|
2767
|
+
cwd: getCwd(),
|
|
2768
|
+
env: {
|
|
2769
|
+
...env,
|
|
2770
|
+
OPENCLAW_SHELL: "tui-local"
|
|
2771
|
+
}
|
|
2772
|
+
});
|
|
2773
|
+
let stdout = "";
|
|
2774
|
+
let stderr = "";
|
|
2775
|
+
child.stdout.on("data", (buf) => {
|
|
2776
|
+
stdout = appendWithCap(stdout, buf.toString("utf8"));
|
|
2777
|
+
});
|
|
2778
|
+
child.stderr.on("data", (buf) => {
|
|
2779
|
+
stderr = appendWithCap(stderr, buf.toString("utf8"));
|
|
2780
|
+
});
|
|
2781
|
+
child.on("close", (code, signal) => {
|
|
2782
|
+
const combined = (stdout + (stderr ? (stdout ? "\n" : "") + stderr : "")).slice(0, maxChars).trimEnd();
|
|
2783
|
+
if (combined) for (const line of combined.split("\n")) deps.chatLog.addSystem(`[local] ${line}`);
|
|
2784
|
+
deps.chatLog.addSystem(`[local] exit ${code ?? "?"}${signal ? ` (signal ${String(signal)})` : ""}`);
|
|
2785
|
+
deps.tui.requestRender();
|
|
2786
|
+
resolve();
|
|
2787
|
+
});
|
|
2788
|
+
child.on("error", (err) => {
|
|
2789
|
+
deps.chatLog.addSystem(`[local] error: ${String(err)}`);
|
|
2790
|
+
deps.tui.requestRender();
|
|
2791
|
+
resolve();
|
|
2792
|
+
});
|
|
2793
|
+
});
|
|
2794
|
+
};
|
|
2795
|
+
return { runLocalShellLine };
|
|
2796
|
+
}
|
|
2797
|
+
//#endregion
|
|
2798
|
+
//#region src/tui/tui-overlays.ts
|
|
2799
|
+
function createOverlayHandlers(host, fallbackFocus) {
|
|
2800
|
+
const openOverlay = (component) => {
|
|
2801
|
+
host.showOverlay(component);
|
|
2802
|
+
};
|
|
2803
|
+
const closeOverlay = () => {
|
|
2804
|
+
if (host.hasOverlay()) {
|
|
2805
|
+
host.hideOverlay();
|
|
2806
|
+
return;
|
|
2807
|
+
}
|
|
2808
|
+
host.setFocus(fallbackFocus);
|
|
2809
|
+
};
|
|
2810
|
+
return {
|
|
2811
|
+
openOverlay,
|
|
2812
|
+
closeOverlay
|
|
2813
|
+
};
|
|
2814
|
+
}
|
|
2815
|
+
//#endregion
|
|
2816
|
+
//#region src/tui/tui-session-actions.ts
|
|
2817
|
+
function createSessionActions(context) {
|
|
2818
|
+
const { client, chatLog, btw, tui, opts, state, agentNames, initialSessionInput, initialSessionAgentId, resolveSessionKey, updateHeader, updateFooter, updateAutocompleteProvider, setActivityStatus, clearLocalRunIds } = context;
|
|
2819
|
+
let refreshSessionInfoPromise = Promise.resolve();
|
|
2820
|
+
let lastSessionDefaults = null;
|
|
2821
|
+
const applyAgentsResult = (result) => {
|
|
2822
|
+
state.agentDefaultId = normalizeAgentId(result.defaultId);
|
|
2823
|
+
state.sessionMainKey = normalizeMainKey(result.mainKey);
|
|
2824
|
+
state.sessionScope = result.scope ?? state.sessionScope;
|
|
2825
|
+
state.agents = result.agents.map((agent) => ({
|
|
2826
|
+
id: normalizeAgentId(agent.id),
|
|
2827
|
+
name: agent.name?.trim() || void 0
|
|
2828
|
+
}));
|
|
2829
|
+
agentNames.clear();
|
|
2830
|
+
for (const agent of state.agents) if (agent.name) agentNames.set(agent.id, agent.name);
|
|
2831
|
+
if (!state.initialSessionApplied) {
|
|
2832
|
+
if (initialSessionAgentId) {
|
|
2833
|
+
if (state.agents.some((agent) => agent.id === initialSessionAgentId)) state.currentAgentId = initialSessionAgentId;
|
|
2834
|
+
} else if (!state.agents.some((agent) => agent.id === state.currentAgentId)) state.currentAgentId = state.agents[0]?.id ?? normalizeAgentId(result.defaultId ?? state.currentAgentId);
|
|
2835
|
+
const nextSessionKey = resolveSessionKey(initialSessionInput);
|
|
2836
|
+
if (nextSessionKey !== state.currentSessionKey) state.currentSessionKey = nextSessionKey;
|
|
2837
|
+
state.initialSessionApplied = true;
|
|
2838
|
+
} else if (!state.agents.some((agent) => agent.id === state.currentAgentId)) state.currentAgentId = state.agents[0]?.id ?? normalizeAgentId(result.defaultId ?? state.currentAgentId);
|
|
2839
|
+
updateHeader();
|
|
2840
|
+
updateFooter();
|
|
2841
|
+
};
|
|
2842
|
+
const refreshAgents = async () => {
|
|
2843
|
+
try {
|
|
2844
|
+
applyAgentsResult(await client.listAgents());
|
|
2845
|
+
} catch (err) {
|
|
2846
|
+
chatLog.addSystem(`agents list failed: ${String(err)}`);
|
|
2847
|
+
}
|
|
2848
|
+
};
|
|
2849
|
+
const updateAgentFromSessionKey = (key) => {
|
|
2850
|
+
const parsed = parseAgentSessionKey(key);
|
|
2851
|
+
if (!parsed) return;
|
|
2852
|
+
const next = normalizeAgentId(parsed.agentId);
|
|
2853
|
+
if (next !== state.currentAgentId) state.currentAgentId = next;
|
|
2854
|
+
};
|
|
2855
|
+
const resolveModelSelection = (entry) => {
|
|
2856
|
+
if (entry?.modelProvider || entry?.model) return {
|
|
2857
|
+
modelProvider: entry.modelProvider ?? state.sessionInfo.modelProvider,
|
|
2858
|
+
model: entry.model ?? state.sessionInfo.model
|
|
2859
|
+
};
|
|
2860
|
+
const overrideModel = entry?.modelOverride?.trim();
|
|
2861
|
+
if (overrideModel) return {
|
|
2862
|
+
modelProvider: entry?.providerOverride?.trim() || state.sessionInfo.modelProvider,
|
|
2863
|
+
model: overrideModel
|
|
2864
|
+
};
|
|
2865
|
+
return {
|
|
2866
|
+
modelProvider: state.sessionInfo.modelProvider,
|
|
2867
|
+
model: state.sessionInfo.model
|
|
2868
|
+
};
|
|
2869
|
+
};
|
|
2870
|
+
const applySessionInfo = (params) => {
|
|
2871
|
+
const entry = params.entry ?? void 0;
|
|
2872
|
+
const defaults = params.defaults ?? lastSessionDefaults ?? void 0;
|
|
2873
|
+
const previousDefaults = lastSessionDefaults;
|
|
2874
|
+
const defaultsChanged = params.defaults ? previousDefaults?.model !== params.defaults.model || previousDefaults?.modelProvider !== params.defaults.modelProvider || previousDefaults?.contextTokens !== params.defaults.contextTokens : false;
|
|
2875
|
+
if (params.defaults) lastSessionDefaults = params.defaults;
|
|
2876
|
+
const entryUpdatedAt = entry?.updatedAt ?? null;
|
|
2877
|
+
const currentUpdatedAt = state.sessionInfo.updatedAt ?? null;
|
|
2878
|
+
if (!params.force && entryUpdatedAt !== null && currentUpdatedAt !== null && entryUpdatedAt < currentUpdatedAt && !defaultsChanged) return;
|
|
2879
|
+
const next = { ...state.sessionInfo };
|
|
2880
|
+
if (entry?.thinkingLevel !== void 0) next.thinkingLevel = entry.thinkingLevel;
|
|
2881
|
+
if (entry?.fastMode !== void 0) next.fastMode = entry.fastMode;
|
|
2882
|
+
if (entry?.verboseLevel !== void 0) next.verboseLevel = entry.verboseLevel;
|
|
2883
|
+
if (entry?.reasoningLevel !== void 0) next.reasoningLevel = entry.reasoningLevel;
|
|
2884
|
+
if (entry?.responseUsage !== void 0) next.responseUsage = entry.responseUsage;
|
|
2885
|
+
if (entry?.inputTokens !== void 0) next.inputTokens = entry.inputTokens;
|
|
2886
|
+
if (entry?.outputTokens !== void 0) next.outputTokens = entry.outputTokens;
|
|
2887
|
+
if (entry?.totalTokens !== void 0) next.totalTokens = entry.totalTokens;
|
|
2888
|
+
if (entry?.contextTokens !== void 0 || defaults?.contextTokens !== void 0) next.contextTokens = entry?.contextTokens ?? defaults?.contextTokens ?? state.sessionInfo.contextTokens;
|
|
2889
|
+
if (entry?.displayName !== void 0) next.displayName = entry.displayName;
|
|
2890
|
+
if (entry?.updatedAt !== void 0) next.updatedAt = entry.updatedAt;
|
|
2891
|
+
const selection = resolveModelSelection(entry);
|
|
2892
|
+
if (selection.modelProvider !== void 0) next.modelProvider = selection.modelProvider;
|
|
2893
|
+
if (selection.model !== void 0) next.model = selection.model;
|
|
2894
|
+
state.sessionInfo = next;
|
|
2895
|
+
updateAutocompleteProvider();
|
|
2896
|
+
updateFooter();
|
|
2897
|
+
tui.requestRender();
|
|
2898
|
+
};
|
|
2899
|
+
const runRefreshSessionInfo = async () => {
|
|
2900
|
+
try {
|
|
2901
|
+
const resolveListAgentId = () => {
|
|
2902
|
+
if (state.currentSessionKey === "global" || state.currentSessionKey === "unknown") return;
|
|
2903
|
+
const parsed = parseAgentSessionKey(state.currentSessionKey);
|
|
2904
|
+
return parsed?.agentId ? normalizeAgentId(parsed.agentId) : state.currentAgentId;
|
|
2905
|
+
};
|
|
2906
|
+
const listAgentId = resolveListAgentId();
|
|
2907
|
+
const result = await client.listSessions({
|
|
2908
|
+
includeGlobal: false,
|
|
2909
|
+
includeUnknown: false,
|
|
2910
|
+
agentId: listAgentId
|
|
2911
|
+
});
|
|
2912
|
+
const normalizeMatchKey = (key) => parseAgentSessionKey(key)?.rest ?? key;
|
|
2913
|
+
const currentMatchKey = normalizeMatchKey(state.currentSessionKey);
|
|
2914
|
+
const entry = result.sessions.find((row) => {
|
|
2915
|
+
if (row.key === state.currentSessionKey) return true;
|
|
2916
|
+
return normalizeMatchKey(row.key) === currentMatchKey;
|
|
2917
|
+
});
|
|
2918
|
+
if (entry?.key && entry.key !== state.currentSessionKey) {
|
|
2919
|
+
updateAgentFromSessionKey(entry.key);
|
|
2920
|
+
state.currentSessionKey = entry.key;
|
|
2921
|
+
updateHeader();
|
|
2922
|
+
}
|
|
2923
|
+
applySessionInfo({
|
|
2924
|
+
entry,
|
|
2925
|
+
defaults: result.defaults
|
|
2926
|
+
});
|
|
2927
|
+
} catch (err) {
|
|
2928
|
+
chatLog.addSystem(`sessions list failed: ${String(err)}`);
|
|
2929
|
+
}
|
|
2930
|
+
};
|
|
2931
|
+
const refreshSessionInfo = async () => {
|
|
2932
|
+
refreshSessionInfoPromise = refreshSessionInfoPromise.then(runRefreshSessionInfo, runRefreshSessionInfo);
|
|
2933
|
+
await refreshSessionInfoPromise;
|
|
2934
|
+
};
|
|
2935
|
+
const applySessionInfoFromPatch = (result) => {
|
|
2936
|
+
if (!result?.entry) return;
|
|
2937
|
+
if (result.key && result.key !== state.currentSessionKey) {
|
|
2938
|
+
updateAgentFromSessionKey(result.key);
|
|
2939
|
+
state.currentSessionKey = result.key;
|
|
2940
|
+
updateHeader();
|
|
2941
|
+
}
|
|
2942
|
+
const resolved = result.resolved;
|
|
2943
|
+
applySessionInfo({
|
|
2944
|
+
entry: resolved && (resolved.modelProvider || resolved.model) ? {
|
|
2945
|
+
...result.entry,
|
|
2946
|
+
modelProvider: resolved.modelProvider ?? result.entry.modelProvider,
|
|
2947
|
+
model: resolved.model ?? result.entry.model
|
|
2948
|
+
} : result.entry,
|
|
2949
|
+
force: true
|
|
2950
|
+
});
|
|
2951
|
+
};
|
|
2952
|
+
const loadHistory = async () => {
|
|
2953
|
+
try {
|
|
2954
|
+
const record = await client.loadHistory({
|
|
2955
|
+
sessionKey: state.currentSessionKey,
|
|
2956
|
+
limit: opts.historyLimit ?? 200
|
|
2957
|
+
});
|
|
2958
|
+
state.currentSessionId = typeof record.sessionId === "string" ? record.sessionId : null;
|
|
2959
|
+
state.sessionInfo.thinkingLevel = record.thinkingLevel ?? state.sessionInfo.thinkingLevel;
|
|
2960
|
+
state.sessionInfo.fastMode = record.fastMode ?? state.sessionInfo.fastMode;
|
|
2961
|
+
state.sessionInfo.verboseLevel = record.verboseLevel ?? state.sessionInfo.verboseLevel;
|
|
2962
|
+
const showTools = (state.sessionInfo.verboseLevel ?? "off") !== "off";
|
|
2963
|
+
chatLog.clearAll();
|
|
2964
|
+
btw.clear();
|
|
2965
|
+
chatLog.addSystem(`session ${state.currentSessionKey}`);
|
|
2966
|
+
for (const entry of record.messages ?? []) {
|
|
2967
|
+
if (!entry || typeof entry !== "object") continue;
|
|
2968
|
+
const message = entry;
|
|
2969
|
+
if (isCommandMessage(message)) {
|
|
2970
|
+
const text = extractTextFromMessage(message);
|
|
2971
|
+
if (text) chatLog.addSystem(text);
|
|
2972
|
+
continue;
|
|
2973
|
+
}
|
|
2974
|
+
if (message.role === "user") {
|
|
2975
|
+
const text = extractTextFromMessage(message);
|
|
2976
|
+
if (text) chatLog.addUser(text);
|
|
2977
|
+
continue;
|
|
2978
|
+
}
|
|
2979
|
+
if (message.role === "assistant") {
|
|
2980
|
+
const text = extractTextFromMessage(message, { includeThinking: state.showThinking });
|
|
2981
|
+
if (text) chatLog.finalizeAssistant(text);
|
|
2982
|
+
continue;
|
|
2983
|
+
}
|
|
2984
|
+
if (message.role === "toolResult") {
|
|
2985
|
+
if (!showTools) continue;
|
|
2986
|
+
const toolCallId = asString(message.toolCallId, "");
|
|
2987
|
+
const toolName = asString(message.toolName, "tool");
|
|
2988
|
+
chatLog.startTool(toolCallId, toolName, {}).setResult({
|
|
2989
|
+
content: Array.isArray(message.content) ? message.content : [],
|
|
2990
|
+
details: typeof message.details === "object" && message.details ? message.details : void 0
|
|
2991
|
+
}, { isError: Boolean(message.isError) });
|
|
2992
|
+
}
|
|
2993
|
+
}
|
|
2994
|
+
state.historyLoaded = true;
|
|
2995
|
+
} catch (err) {
|
|
2996
|
+
chatLog.addSystem(`history failed: ${String(err)}`);
|
|
2997
|
+
}
|
|
2998
|
+
await refreshSessionInfo();
|
|
2999
|
+
tui.requestRender();
|
|
3000
|
+
};
|
|
3001
|
+
const setSession = async (rawKey) => {
|
|
3002
|
+
const nextKey = resolveSessionKey(rawKey);
|
|
3003
|
+
updateAgentFromSessionKey(nextKey);
|
|
3004
|
+
state.currentSessionKey = nextKey;
|
|
3005
|
+
state.activeChatRunId = null;
|
|
3006
|
+
state.currentSessionId = null;
|
|
3007
|
+
state.sessionInfo.updatedAt = null;
|
|
3008
|
+
state.historyLoaded = false;
|
|
3009
|
+
clearLocalRunIds?.();
|
|
3010
|
+
btw.clear();
|
|
3011
|
+
updateHeader();
|
|
3012
|
+
updateFooter();
|
|
3013
|
+
await loadHistory();
|
|
3014
|
+
};
|
|
3015
|
+
const abortActive = async () => {
|
|
3016
|
+
if (!state.activeChatRunId) {
|
|
3017
|
+
chatLog.addSystem("no active run");
|
|
3018
|
+
tui.requestRender();
|
|
3019
|
+
return;
|
|
3020
|
+
}
|
|
3021
|
+
try {
|
|
3022
|
+
await client.abortChat({
|
|
3023
|
+
sessionKey: state.currentSessionKey,
|
|
3024
|
+
runId: state.activeChatRunId
|
|
3025
|
+
});
|
|
3026
|
+
setActivityStatus("aborted");
|
|
3027
|
+
} catch (err) {
|
|
3028
|
+
chatLog.addSystem(`abort failed: ${String(err)}`);
|
|
3029
|
+
setActivityStatus("abort failed");
|
|
3030
|
+
}
|
|
3031
|
+
tui.requestRender();
|
|
3032
|
+
};
|
|
3033
|
+
return {
|
|
3034
|
+
applyAgentsResult,
|
|
3035
|
+
refreshAgents,
|
|
3036
|
+
refreshSessionInfo,
|
|
3037
|
+
applySessionInfoFromPatch,
|
|
3038
|
+
loadHistory,
|
|
3039
|
+
setSession,
|
|
3040
|
+
abortActive
|
|
3041
|
+
};
|
|
3042
|
+
}
|
|
3043
|
+
//#endregion
|
|
3044
|
+
//#region src/tui/tui-submit.ts
|
|
3045
|
+
function createEditorSubmitHandler(params) {
|
|
3046
|
+
return (text) => {
|
|
3047
|
+
const raw = text;
|
|
3048
|
+
const value = raw.trim();
|
|
3049
|
+
params.editor.setText("");
|
|
3050
|
+
if (!value) return;
|
|
3051
|
+
if (raw.startsWith("!") && raw !== "!") {
|
|
3052
|
+
params.editor.addToHistory(raw);
|
|
3053
|
+
params.handleBangLine(raw);
|
|
3054
|
+
return;
|
|
3055
|
+
}
|
|
3056
|
+
params.editor.addToHistory(value);
|
|
3057
|
+
if (value.startsWith("/")) {
|
|
3058
|
+
params.handleCommand(value);
|
|
3059
|
+
return;
|
|
3060
|
+
}
|
|
3061
|
+
params.sendMessage(value);
|
|
3062
|
+
};
|
|
3063
|
+
}
|
|
3064
|
+
function shouldEnableWindowsGitBashPasteFallback(params) {
|
|
3065
|
+
const platform = params?.platform ?? process.platform;
|
|
3066
|
+
const env = params?.env ?? process.env;
|
|
3067
|
+
const termProgram = (env.TERM_PROGRAM ?? "").toLowerCase();
|
|
3068
|
+
if (platform === "darwin") {
|
|
3069
|
+
if (termProgram.includes("iterm") || termProgram.includes("apple_terminal")) return true;
|
|
3070
|
+
return false;
|
|
3071
|
+
}
|
|
3072
|
+
if (platform !== "win32") return false;
|
|
3073
|
+
const msystem = (env.MSYSTEM ?? "").toUpperCase();
|
|
3074
|
+
const shell = env.SHELL ?? "";
|
|
3075
|
+
if (msystem.startsWith("MINGW") || msystem.startsWith("MSYS")) return true;
|
|
3076
|
+
if (shell.toLowerCase().includes("bash")) return true;
|
|
3077
|
+
return termProgram.includes("mintty");
|
|
3078
|
+
}
|
|
3079
|
+
function createSubmitBurstCoalescer(params) {
|
|
3080
|
+
const windowMs = Math.max(1, params.burstWindowMs ?? 50);
|
|
3081
|
+
const now = params.now ?? (() => Date.now());
|
|
3082
|
+
const setTimer = params.setTimer ?? setTimeout;
|
|
3083
|
+
const clearTimer = params.clearTimer ?? clearTimeout;
|
|
3084
|
+
let pending = null;
|
|
3085
|
+
let pendingAt = 0;
|
|
3086
|
+
let flushTimer = null;
|
|
3087
|
+
const clearFlushTimer = () => {
|
|
3088
|
+
if (!flushTimer) return;
|
|
3089
|
+
clearTimer(flushTimer);
|
|
3090
|
+
flushTimer = null;
|
|
3091
|
+
};
|
|
3092
|
+
const flushPending = () => {
|
|
3093
|
+
if (pending === null) return;
|
|
3094
|
+
const value = pending;
|
|
3095
|
+
pending = null;
|
|
3096
|
+
pendingAt = 0;
|
|
3097
|
+
clearFlushTimer();
|
|
3098
|
+
params.submit(value);
|
|
3099
|
+
};
|
|
3100
|
+
const scheduleFlush = () => {
|
|
3101
|
+
clearFlushTimer();
|
|
3102
|
+
flushTimer = setTimer(() => {
|
|
3103
|
+
flushPending();
|
|
3104
|
+
}, windowMs);
|
|
3105
|
+
};
|
|
3106
|
+
return (value) => {
|
|
3107
|
+
if (!params.enabled) {
|
|
3108
|
+
params.submit(value);
|
|
3109
|
+
return;
|
|
3110
|
+
}
|
|
3111
|
+
if (value.includes("\n")) {
|
|
3112
|
+
flushPending();
|
|
3113
|
+
params.submit(value);
|
|
3114
|
+
return;
|
|
3115
|
+
}
|
|
3116
|
+
const ts = now();
|
|
3117
|
+
if (pending === null) {
|
|
3118
|
+
pending = value;
|
|
3119
|
+
pendingAt = ts;
|
|
3120
|
+
scheduleFlush();
|
|
3121
|
+
return;
|
|
3122
|
+
}
|
|
3123
|
+
if (ts - pendingAt <= windowMs) {
|
|
3124
|
+
pending = `${pending}\n${value}`;
|
|
3125
|
+
pendingAt = ts;
|
|
3126
|
+
scheduleFlush();
|
|
3127
|
+
return;
|
|
3128
|
+
}
|
|
3129
|
+
flushPending();
|
|
3130
|
+
pending = value;
|
|
3131
|
+
pendingAt = ts;
|
|
3132
|
+
scheduleFlush();
|
|
3133
|
+
};
|
|
3134
|
+
}
|
|
3135
|
+
//#endregion
|
|
3136
|
+
//#region src/tui/tui-waiting.ts
|
|
3137
|
+
const defaultWaitingPhrases = [
|
|
3138
|
+
"flibbertigibbeting",
|
|
3139
|
+
"kerfuffling",
|
|
3140
|
+
"dillydallying",
|
|
3141
|
+
"twiddling thumbs",
|
|
3142
|
+
"noodling",
|
|
3143
|
+
"bamboozling",
|
|
3144
|
+
"moseying",
|
|
3145
|
+
"hobnobbing",
|
|
3146
|
+
"pondering",
|
|
3147
|
+
"conjuring"
|
|
3148
|
+
];
|
|
3149
|
+
function pickWaitingPhrase(tick, phrases = defaultWaitingPhrases) {
|
|
3150
|
+
return phrases[Math.floor(tick / 10) % phrases.length] ?? phrases[0] ?? "waiting";
|
|
3151
|
+
}
|
|
3152
|
+
function shimmerText(theme, text, tick) {
|
|
3153
|
+
const width = 6;
|
|
3154
|
+
const hi = (ch) => theme.bold(theme.accentSoft(ch));
|
|
3155
|
+
const pos = tick % (text.length + width);
|
|
3156
|
+
const start = Math.max(0, pos - width);
|
|
3157
|
+
const end = Math.min(text.length - 1, pos);
|
|
3158
|
+
let out = "";
|
|
3159
|
+
for (let i = 0; i < text.length; i++) {
|
|
3160
|
+
const ch = text[i];
|
|
3161
|
+
out += i >= start && i <= end ? hi(ch) : theme.dim(ch);
|
|
3162
|
+
}
|
|
3163
|
+
return out;
|
|
3164
|
+
}
|
|
3165
|
+
function buildWaitingStatusMessage(params) {
|
|
3166
|
+
const phrase = pickWaitingPhrase(params.tick, params.phrases);
|
|
3167
|
+
return `${shimmerText(params.theme, `${phrase}…`, params.tick)} • ${params.elapsed} | ${params.connectionStatus}`;
|
|
3168
|
+
}
|
|
3169
|
+
//#endregion
|
|
3170
|
+
//#region src/tui/tui.ts
|
|
3171
|
+
function resolveTuiSessionKey(params) {
|
|
3172
|
+
const trimmed = (params.raw ?? "").trim();
|
|
3173
|
+
if (!trimmed) {
|
|
3174
|
+
if (params.sessionScope === "global") return "global";
|
|
3175
|
+
return buildAgentMainSessionKey({
|
|
3176
|
+
agentId: params.currentAgentId,
|
|
3177
|
+
mainKey: params.sessionMainKey
|
|
3178
|
+
});
|
|
3179
|
+
}
|
|
3180
|
+
if (trimmed === "global" || trimmed === "unknown") return trimmed;
|
|
3181
|
+
if (trimmed.startsWith("agent:")) return trimmed.toLowerCase();
|
|
3182
|
+
return `agent:${params.currentAgentId}:${trimmed.toLowerCase()}`;
|
|
3183
|
+
}
|
|
3184
|
+
function resolveInitialTuiAgentId(params) {
|
|
3185
|
+
const parsed = parseAgentSessionKey((params.initialSessionInput ?? "").trim());
|
|
3186
|
+
if (parsed?.agentId) return normalizeAgentId(parsed.agentId);
|
|
3187
|
+
const inferredFromWorkspace = resolveAgentIdByWorkspacePath(params.cfg, params.cwd ?? process.cwd());
|
|
3188
|
+
if (inferredFromWorkspace) return inferredFromWorkspace;
|
|
3189
|
+
return normalizeAgentId(params.fallbackAgentId);
|
|
3190
|
+
}
|
|
3191
|
+
function resolveGatewayDisconnectState(reason) {
|
|
3192
|
+
const reasonLabel = reason?.trim() ? reason.trim() : "closed";
|
|
3193
|
+
if (/pairing required/i.test(reasonLabel)) return {
|
|
3194
|
+
connectionStatus: `gateway disconnected: ${reasonLabel}`,
|
|
3195
|
+
activityStatus: "pairing required: run openclaw devices list",
|
|
3196
|
+
pairingHint: "Pairing required. Run `openclaw devices list`, approve your request ID, then reconnect."
|
|
3197
|
+
};
|
|
3198
|
+
return {
|
|
3199
|
+
connectionStatus: `gateway disconnected: ${reasonLabel}`,
|
|
3200
|
+
activityStatus: "idle"
|
|
3201
|
+
};
|
|
3202
|
+
}
|
|
3203
|
+
function createBackspaceDeduper(params) {
|
|
3204
|
+
const dedupeWindowMs = Math.max(0, Math.floor(params?.dedupeWindowMs ?? 8));
|
|
3205
|
+
const now = params?.now ?? (() => Date.now());
|
|
3206
|
+
let lastBackspaceAt = -1;
|
|
3207
|
+
return (data) => {
|
|
3208
|
+
if (!matchesKey(data, Key.backspace)) return data;
|
|
3209
|
+
const ts = now();
|
|
3210
|
+
if (lastBackspaceAt >= 0 && ts - lastBackspaceAt <= dedupeWindowMs) return "";
|
|
3211
|
+
lastBackspaceAt = ts;
|
|
3212
|
+
return data;
|
|
3213
|
+
};
|
|
3214
|
+
}
|
|
3215
|
+
function isIgnorableTuiStopError(error) {
|
|
3216
|
+
if (!error || typeof error !== "object") return false;
|
|
3217
|
+
const err = error;
|
|
3218
|
+
const code = typeof err.code === "string" ? err.code : "";
|
|
3219
|
+
const syscall = typeof err.syscall === "string" ? err.syscall : "";
|
|
3220
|
+
const message = typeof err.message === "string" ? err.message : "";
|
|
3221
|
+
if (code === "EBADF" && syscall === "setRawMode") return true;
|
|
3222
|
+
return /setRawMode/i.test(message) && /EBADF/i.test(message);
|
|
3223
|
+
}
|
|
3224
|
+
function stopTuiSafely(stop) {
|
|
3225
|
+
try {
|
|
3226
|
+
stop();
|
|
3227
|
+
} catch (error) {
|
|
3228
|
+
if (!isIgnorableTuiStopError(error)) throw error;
|
|
3229
|
+
}
|
|
3230
|
+
}
|
|
3231
|
+
function resolveCtrlCAction(params) {
|
|
3232
|
+
const exitWindowMs = Math.max(1, Math.floor(params.exitWindowMs ?? 1e3));
|
|
3233
|
+
if (params.hasInput) return {
|
|
3234
|
+
action: "clear",
|
|
3235
|
+
nextLastCtrlCAt: params.now
|
|
3236
|
+
};
|
|
3237
|
+
if (params.now - params.lastCtrlCAt <= exitWindowMs) return {
|
|
3238
|
+
action: "exit",
|
|
3239
|
+
nextLastCtrlCAt: params.lastCtrlCAt
|
|
3240
|
+
};
|
|
3241
|
+
return {
|
|
3242
|
+
action: "warn",
|
|
3243
|
+
nextLastCtrlCAt: params.now
|
|
3244
|
+
};
|
|
3245
|
+
}
|
|
3246
|
+
async function runTui(opts) {
|
|
3247
|
+
const config = loadConfig();
|
|
3248
|
+
const initialSessionInput = (opts.session ?? "").trim();
|
|
3249
|
+
let sessionScope = config.session?.scope ?? "per-sender";
|
|
3250
|
+
let sessionMainKey = normalizeMainKey(config.session?.mainKey);
|
|
3251
|
+
let agentDefaultId = resolveDefaultAgentId(config);
|
|
3252
|
+
let currentAgentId = resolveInitialTuiAgentId({
|
|
3253
|
+
cfg: config,
|
|
3254
|
+
fallbackAgentId: agentDefaultId,
|
|
3255
|
+
initialSessionInput,
|
|
3256
|
+
cwd: process.cwd()
|
|
3257
|
+
});
|
|
3258
|
+
let agents = [];
|
|
3259
|
+
const agentNames = /* @__PURE__ */ new Map();
|
|
3260
|
+
let currentSessionKey = "";
|
|
3261
|
+
let initialSessionApplied = false;
|
|
3262
|
+
let currentSessionId = null;
|
|
3263
|
+
let activeChatRunId = null;
|
|
3264
|
+
let historyLoaded = false;
|
|
3265
|
+
let isConnected = false;
|
|
3266
|
+
let wasDisconnected = false;
|
|
3267
|
+
let toolsExpanded = false;
|
|
3268
|
+
let showThinking = false;
|
|
3269
|
+
let pairingHintShown = false;
|
|
3270
|
+
const localRunIds = /* @__PURE__ */ new Set();
|
|
3271
|
+
const localBtwRunIds = /* @__PURE__ */ new Set();
|
|
3272
|
+
const deliverDefault = opts.deliver ?? false;
|
|
3273
|
+
const autoMessage = opts.message?.trim();
|
|
3274
|
+
let autoMessageSent = false;
|
|
3275
|
+
let sessionInfo = {};
|
|
3276
|
+
let lastCtrlCAt = 0;
|
|
3277
|
+
let exitRequested = false;
|
|
3278
|
+
let activityStatus = "idle";
|
|
3279
|
+
let connectionStatus = "connecting";
|
|
3280
|
+
let statusTimeout = null;
|
|
3281
|
+
let statusTimer = null;
|
|
3282
|
+
let statusStartedAt = null;
|
|
3283
|
+
let lastActivityStatus = activityStatus;
|
|
3284
|
+
const state = {
|
|
3285
|
+
get agentDefaultId() {
|
|
3286
|
+
return agentDefaultId;
|
|
3287
|
+
},
|
|
3288
|
+
set agentDefaultId(value) {
|
|
3289
|
+
agentDefaultId = value;
|
|
3290
|
+
},
|
|
3291
|
+
get sessionMainKey() {
|
|
3292
|
+
return sessionMainKey;
|
|
3293
|
+
},
|
|
3294
|
+
set sessionMainKey(value) {
|
|
3295
|
+
sessionMainKey = value;
|
|
3296
|
+
},
|
|
3297
|
+
get sessionScope() {
|
|
3298
|
+
return sessionScope;
|
|
3299
|
+
},
|
|
3300
|
+
set sessionScope(value) {
|
|
3301
|
+
sessionScope = value;
|
|
3302
|
+
},
|
|
3303
|
+
get agents() {
|
|
3304
|
+
return agents;
|
|
3305
|
+
},
|
|
3306
|
+
set agents(value) {
|
|
3307
|
+
agents = value;
|
|
3308
|
+
},
|
|
3309
|
+
get currentAgentId() {
|
|
3310
|
+
return currentAgentId;
|
|
3311
|
+
},
|
|
3312
|
+
set currentAgentId(value) {
|
|
3313
|
+
currentAgentId = value;
|
|
3314
|
+
},
|
|
3315
|
+
get currentSessionKey() {
|
|
3316
|
+
return currentSessionKey;
|
|
3317
|
+
},
|
|
3318
|
+
set currentSessionKey(value) {
|
|
3319
|
+
currentSessionKey = value;
|
|
3320
|
+
},
|
|
3321
|
+
get currentSessionId() {
|
|
3322
|
+
return currentSessionId;
|
|
3323
|
+
},
|
|
3324
|
+
set currentSessionId(value) {
|
|
3325
|
+
currentSessionId = value;
|
|
3326
|
+
},
|
|
3327
|
+
get activeChatRunId() {
|
|
3328
|
+
return activeChatRunId;
|
|
3329
|
+
},
|
|
3330
|
+
set activeChatRunId(value) {
|
|
3331
|
+
activeChatRunId = value;
|
|
3332
|
+
},
|
|
3333
|
+
get historyLoaded() {
|
|
3334
|
+
return historyLoaded;
|
|
3335
|
+
},
|
|
3336
|
+
set historyLoaded(value) {
|
|
3337
|
+
historyLoaded = value;
|
|
3338
|
+
},
|
|
3339
|
+
get sessionInfo() {
|
|
3340
|
+
return sessionInfo;
|
|
3341
|
+
},
|
|
3342
|
+
set sessionInfo(value) {
|
|
3343
|
+
sessionInfo = value;
|
|
3344
|
+
},
|
|
3345
|
+
get initialSessionApplied() {
|
|
3346
|
+
return initialSessionApplied;
|
|
3347
|
+
},
|
|
3348
|
+
set initialSessionApplied(value) {
|
|
3349
|
+
initialSessionApplied = value;
|
|
3350
|
+
},
|
|
3351
|
+
get isConnected() {
|
|
3352
|
+
return isConnected;
|
|
3353
|
+
},
|
|
3354
|
+
set isConnected(value) {
|
|
3355
|
+
isConnected = value;
|
|
3356
|
+
},
|
|
3357
|
+
get autoMessageSent() {
|
|
3358
|
+
return autoMessageSent;
|
|
3359
|
+
},
|
|
3360
|
+
set autoMessageSent(value) {
|
|
3361
|
+
autoMessageSent = value;
|
|
3362
|
+
},
|
|
3363
|
+
get toolsExpanded() {
|
|
3364
|
+
return toolsExpanded;
|
|
3365
|
+
},
|
|
3366
|
+
set toolsExpanded(value) {
|
|
3367
|
+
toolsExpanded = value;
|
|
3368
|
+
},
|
|
3369
|
+
get showThinking() {
|
|
3370
|
+
return showThinking;
|
|
3371
|
+
},
|
|
3372
|
+
set showThinking(value) {
|
|
3373
|
+
showThinking = value;
|
|
3374
|
+
},
|
|
3375
|
+
get connectionStatus() {
|
|
3376
|
+
return connectionStatus;
|
|
3377
|
+
},
|
|
3378
|
+
set connectionStatus(value) {
|
|
3379
|
+
connectionStatus = value;
|
|
3380
|
+
},
|
|
3381
|
+
get activityStatus() {
|
|
3382
|
+
return activityStatus;
|
|
3383
|
+
},
|
|
3384
|
+
set activityStatus(value) {
|
|
3385
|
+
activityStatus = value;
|
|
3386
|
+
},
|
|
3387
|
+
get statusTimeout() {
|
|
3388
|
+
return statusTimeout;
|
|
3389
|
+
},
|
|
3390
|
+
set statusTimeout(value) {
|
|
3391
|
+
statusTimeout = value;
|
|
3392
|
+
},
|
|
3393
|
+
get lastCtrlCAt() {
|
|
3394
|
+
return lastCtrlCAt;
|
|
3395
|
+
},
|
|
3396
|
+
set lastCtrlCAt(value) {
|
|
3397
|
+
lastCtrlCAt = value;
|
|
3398
|
+
}
|
|
3399
|
+
};
|
|
3400
|
+
const noteLocalRunId = (runId) => {
|
|
3401
|
+
if (!runId) return;
|
|
3402
|
+
localRunIds.add(runId);
|
|
3403
|
+
if (localRunIds.size > 200) {
|
|
3404
|
+
const [first] = localRunIds;
|
|
3405
|
+
if (first) localRunIds.delete(first);
|
|
3406
|
+
}
|
|
3407
|
+
};
|
|
3408
|
+
const forgetLocalRunId = (runId) => {
|
|
3409
|
+
localRunIds.delete(runId);
|
|
3410
|
+
};
|
|
3411
|
+
const isLocalRunId = (runId) => localRunIds.has(runId);
|
|
3412
|
+
const clearLocalRunIds = () => {
|
|
3413
|
+
localRunIds.clear();
|
|
3414
|
+
};
|
|
3415
|
+
const noteLocalBtwRunId = (runId) => {
|
|
3416
|
+
if (!runId) return;
|
|
3417
|
+
localBtwRunIds.add(runId);
|
|
3418
|
+
if (localBtwRunIds.size > 200) {
|
|
3419
|
+
const [first] = localBtwRunIds;
|
|
3420
|
+
if (first) localBtwRunIds.delete(first);
|
|
3421
|
+
}
|
|
3422
|
+
};
|
|
3423
|
+
const forgetLocalBtwRunId = (runId) => {
|
|
3424
|
+
localBtwRunIds.delete(runId);
|
|
3425
|
+
};
|
|
3426
|
+
const isLocalBtwRunId = (runId) => localBtwRunIds.has(runId);
|
|
3427
|
+
const clearLocalBtwRunIds = () => {
|
|
3428
|
+
localBtwRunIds.clear();
|
|
3429
|
+
};
|
|
3430
|
+
const client = await GatewayChatClient.connect({
|
|
3431
|
+
url: opts.url,
|
|
3432
|
+
token: opts.token,
|
|
3433
|
+
password: opts.password
|
|
3434
|
+
});
|
|
3435
|
+
const tui = new TUI(new ProcessTerminal());
|
|
3436
|
+
const dedupeBackspace = createBackspaceDeduper();
|
|
3437
|
+
tui.addInputListener((data) => {
|
|
3438
|
+
const next = dedupeBackspace(data);
|
|
3439
|
+
if (next.length === 0) return { consume: true };
|
|
3440
|
+
return { data: next };
|
|
3441
|
+
});
|
|
3442
|
+
const header = new Text("", 1, 0);
|
|
3443
|
+
const statusContainer = new Container();
|
|
3444
|
+
const footer = new Text("", 1, 0);
|
|
3445
|
+
const chatLog = new ChatLog();
|
|
3446
|
+
const editor = new CustomEditor(tui, editorTheme);
|
|
3447
|
+
const root = new Container();
|
|
3448
|
+
root.addChild(header);
|
|
3449
|
+
root.addChild(chatLog);
|
|
3450
|
+
root.addChild(statusContainer);
|
|
3451
|
+
root.addChild(footer);
|
|
3452
|
+
root.addChild(editor);
|
|
3453
|
+
const updateAutocompleteProvider = () => {
|
|
3454
|
+
editor.setAutocompleteProvider(new CombinedAutocompleteProvider(getSlashCommands({
|
|
3455
|
+
cfg: config,
|
|
3456
|
+
provider: sessionInfo.modelProvider,
|
|
3457
|
+
model: sessionInfo.model
|
|
3458
|
+
}), process.cwd()));
|
|
3459
|
+
};
|
|
3460
|
+
tui.addChild(root);
|
|
3461
|
+
tui.setFocus(editor);
|
|
3462
|
+
const formatSessionKey = (key) => {
|
|
3463
|
+
if (key === "global" || key === "unknown") return key;
|
|
3464
|
+
return parseAgentSessionKey(key)?.rest ?? key;
|
|
3465
|
+
};
|
|
3466
|
+
const formatAgentLabel = (id) => {
|
|
3467
|
+
const name = agentNames.get(id);
|
|
3468
|
+
return name ? `${id} (${name})` : id;
|
|
3469
|
+
};
|
|
3470
|
+
const resolveSessionKey = (raw) => {
|
|
3471
|
+
return resolveTuiSessionKey({
|
|
3472
|
+
raw,
|
|
3473
|
+
sessionScope,
|
|
3474
|
+
currentAgentId,
|
|
3475
|
+
sessionMainKey
|
|
3476
|
+
});
|
|
3477
|
+
};
|
|
3478
|
+
currentSessionKey = resolveSessionKey(initialSessionInput);
|
|
3479
|
+
const updateHeader = () => {
|
|
3480
|
+
const sessionLabel = formatSessionKey(currentSessionKey);
|
|
3481
|
+
const agentLabel = formatAgentLabel(currentAgentId);
|
|
3482
|
+
header.setText(theme.header(`openclaw tui - ${client.connection.url} - agent ${agentLabel} - session ${sessionLabel}`));
|
|
3483
|
+
};
|
|
3484
|
+
const busyStates = new Set([
|
|
3485
|
+
"sending",
|
|
3486
|
+
"waiting",
|
|
3487
|
+
"streaming",
|
|
3488
|
+
"running"
|
|
3489
|
+
]);
|
|
3490
|
+
let statusText = null;
|
|
3491
|
+
let statusLoader = null;
|
|
3492
|
+
const formatElapsed = (startMs) => {
|
|
3493
|
+
const totalSeconds = Math.max(0, Math.floor((Date.now() - startMs) / 1e3));
|
|
3494
|
+
if (totalSeconds < 60) return `${totalSeconds}s`;
|
|
3495
|
+
return `${Math.floor(totalSeconds / 60)}m ${totalSeconds % 60}s`;
|
|
3496
|
+
};
|
|
3497
|
+
const ensureStatusText = () => {
|
|
3498
|
+
if (statusText) return;
|
|
3499
|
+
statusContainer.clear();
|
|
3500
|
+
statusLoader?.stop();
|
|
3501
|
+
statusLoader = null;
|
|
3502
|
+
statusText = new Text("", 1, 0);
|
|
3503
|
+
statusContainer.addChild(statusText);
|
|
3504
|
+
};
|
|
3505
|
+
const ensureStatusLoader = () => {
|
|
3506
|
+
if (statusLoader) return;
|
|
3507
|
+
statusContainer.clear();
|
|
3508
|
+
statusText = null;
|
|
3509
|
+
statusLoader = new Loader(tui, (spinner) => theme.accent(spinner), (text) => theme.bold(theme.accentSoft(text)), "");
|
|
3510
|
+
statusContainer.addChild(statusLoader);
|
|
3511
|
+
};
|
|
3512
|
+
let waitingTick = 0;
|
|
3513
|
+
let waitingTimer = null;
|
|
3514
|
+
let waitingPhrase = null;
|
|
3515
|
+
const updateBusyStatusMessage = () => {
|
|
3516
|
+
if (!statusLoader || !statusStartedAt) return;
|
|
3517
|
+
const elapsed = formatElapsed(statusStartedAt);
|
|
3518
|
+
if (activityStatus === "waiting") {
|
|
3519
|
+
waitingTick++;
|
|
3520
|
+
statusLoader.setMessage(buildWaitingStatusMessage({
|
|
3521
|
+
theme,
|
|
3522
|
+
tick: waitingTick,
|
|
3523
|
+
elapsed,
|
|
3524
|
+
connectionStatus,
|
|
3525
|
+
phrases: waitingPhrase ? [waitingPhrase] : void 0
|
|
3526
|
+
}));
|
|
3527
|
+
return;
|
|
3528
|
+
}
|
|
3529
|
+
statusLoader.setMessage(`${activityStatus} • ${elapsed} | ${connectionStatus}`);
|
|
3530
|
+
};
|
|
3531
|
+
const startStatusTimer = () => {
|
|
3532
|
+
if (statusTimer) return;
|
|
3533
|
+
statusTimer = setInterval(() => {
|
|
3534
|
+
if (!busyStates.has(activityStatus)) return;
|
|
3535
|
+
updateBusyStatusMessage();
|
|
3536
|
+
}, 1e3);
|
|
3537
|
+
};
|
|
3538
|
+
const stopStatusTimer = () => {
|
|
3539
|
+
if (!statusTimer) return;
|
|
3540
|
+
clearInterval(statusTimer);
|
|
3541
|
+
statusTimer = null;
|
|
3542
|
+
};
|
|
3543
|
+
const startWaitingTimer = () => {
|
|
3544
|
+
if (waitingTimer) return;
|
|
3545
|
+
if (!waitingPhrase) waitingPhrase = defaultWaitingPhrases[Math.floor(Math.random() * defaultWaitingPhrases.length)] ?? defaultWaitingPhrases[0] ?? "waiting";
|
|
3546
|
+
waitingTick = 0;
|
|
3547
|
+
waitingTimer = setInterval(() => {
|
|
3548
|
+
if (activityStatus !== "waiting") return;
|
|
3549
|
+
updateBusyStatusMessage();
|
|
3550
|
+
}, 120);
|
|
3551
|
+
};
|
|
3552
|
+
const stopWaitingTimer = () => {
|
|
3553
|
+
if (!waitingTimer) return;
|
|
3554
|
+
clearInterval(waitingTimer);
|
|
3555
|
+
waitingTimer = null;
|
|
3556
|
+
waitingPhrase = null;
|
|
3557
|
+
};
|
|
3558
|
+
const renderStatus = () => {
|
|
3559
|
+
if (busyStates.has(activityStatus)) {
|
|
3560
|
+
if (!statusStartedAt || lastActivityStatus !== activityStatus) statusStartedAt = Date.now();
|
|
3561
|
+
ensureStatusLoader();
|
|
3562
|
+
if (activityStatus === "waiting") {
|
|
3563
|
+
stopStatusTimer();
|
|
3564
|
+
startWaitingTimer();
|
|
3565
|
+
} else {
|
|
3566
|
+
stopWaitingTimer();
|
|
3567
|
+
startStatusTimer();
|
|
3568
|
+
}
|
|
3569
|
+
updateBusyStatusMessage();
|
|
3570
|
+
} else {
|
|
3571
|
+
statusStartedAt = null;
|
|
3572
|
+
stopStatusTimer();
|
|
3573
|
+
stopWaitingTimer();
|
|
3574
|
+
statusLoader?.stop();
|
|
3575
|
+
statusLoader = null;
|
|
3576
|
+
ensureStatusText();
|
|
3577
|
+
const text = activityStatus ? `${connectionStatus} | ${activityStatus}` : connectionStatus;
|
|
3578
|
+
statusText?.setText(theme.dim(text));
|
|
3579
|
+
}
|
|
3580
|
+
lastActivityStatus = activityStatus;
|
|
3581
|
+
};
|
|
3582
|
+
const setConnectionStatus = (text, ttlMs) => {
|
|
3583
|
+
connectionStatus = text;
|
|
3584
|
+
renderStatus();
|
|
3585
|
+
if (statusTimeout) clearTimeout(statusTimeout);
|
|
3586
|
+
if (ttlMs && ttlMs > 0) statusTimeout = setTimeout(() => {
|
|
3587
|
+
connectionStatus = isConnected ? "connected" : "disconnected";
|
|
3588
|
+
renderStatus();
|
|
3589
|
+
}, ttlMs);
|
|
3590
|
+
};
|
|
3591
|
+
const setActivityStatus = (text) => {
|
|
3592
|
+
activityStatus = text;
|
|
3593
|
+
renderStatus();
|
|
3594
|
+
};
|
|
3595
|
+
const updateFooter = () => {
|
|
3596
|
+
const sessionKeyLabel = formatSessionKey(currentSessionKey);
|
|
3597
|
+
const sessionLabel = sessionInfo.displayName ? `${sessionKeyLabel} (${sessionInfo.displayName})` : sessionKeyLabel;
|
|
3598
|
+
const agentLabel = formatAgentLabel(currentAgentId);
|
|
3599
|
+
const modelLabel = sessionInfo.model ? sessionInfo.modelProvider ? `${sessionInfo.modelProvider}/${sessionInfo.model}` : sessionInfo.model : "unknown";
|
|
3600
|
+
const tokens = formatTokens(sessionInfo.totalTokens ?? null, sessionInfo.contextTokens ?? null);
|
|
3601
|
+
const think = sessionInfo.thinkingLevel ?? "off";
|
|
3602
|
+
const fast = sessionInfo.fastMode === true;
|
|
3603
|
+
const verbose = sessionInfo.verboseLevel ?? "off";
|
|
3604
|
+
const reasoning = sessionInfo.reasoningLevel ?? "off";
|
|
3605
|
+
const reasoningLabel = reasoning === "on" ? "reasoning" : reasoning === "stream" ? "reasoning:stream" : null;
|
|
3606
|
+
const footerParts = [
|
|
3607
|
+
`agent ${agentLabel}`,
|
|
3608
|
+
`session ${sessionLabel}`,
|
|
3609
|
+
modelLabel,
|
|
3610
|
+
think !== "off" ? `think ${think}` : null,
|
|
3611
|
+
fast ? "fast" : null,
|
|
3612
|
+
verbose !== "off" ? `verbose ${verbose}` : null,
|
|
3613
|
+
reasoningLabel,
|
|
3614
|
+
tokens
|
|
3615
|
+
].filter(Boolean);
|
|
3616
|
+
footer.setText(theme.dim(footerParts.join(" | ")));
|
|
3617
|
+
};
|
|
3618
|
+
const { openOverlay, closeOverlay } = createOverlayHandlers(tui, editor);
|
|
3619
|
+
const btw = {
|
|
3620
|
+
showResult: (params) => {
|
|
3621
|
+
chatLog.showBtw(params);
|
|
3622
|
+
},
|
|
3623
|
+
clear: () => {
|
|
3624
|
+
chatLog.dismissBtw();
|
|
3625
|
+
}
|
|
3626
|
+
};
|
|
3627
|
+
const { refreshAgents, refreshSessionInfo, applySessionInfoFromPatch, loadHistory, setSession, abortActive } = createSessionActions({
|
|
3628
|
+
client,
|
|
3629
|
+
chatLog,
|
|
3630
|
+
btw,
|
|
3631
|
+
tui,
|
|
3632
|
+
opts,
|
|
3633
|
+
state,
|
|
3634
|
+
agentNames,
|
|
3635
|
+
initialSessionInput,
|
|
3636
|
+
initialSessionAgentId: (() => {
|
|
3637
|
+
if (!initialSessionInput) return null;
|
|
3638
|
+
const parsed = parseAgentSessionKey(initialSessionInput);
|
|
3639
|
+
return parsed ? normalizeAgentId(parsed.agentId) : null;
|
|
3640
|
+
})(),
|
|
3641
|
+
resolveSessionKey,
|
|
3642
|
+
updateHeader,
|
|
3643
|
+
updateFooter,
|
|
3644
|
+
updateAutocompleteProvider,
|
|
3645
|
+
setActivityStatus,
|
|
3646
|
+
clearLocalRunIds
|
|
3647
|
+
});
|
|
3648
|
+
const { handleChatEvent, handleAgentEvent, handleBtwEvent } = createEventHandlers({
|
|
3649
|
+
chatLog,
|
|
3650
|
+
btw,
|
|
3651
|
+
tui,
|
|
3652
|
+
state,
|
|
3653
|
+
setActivityStatus,
|
|
3654
|
+
refreshSessionInfo,
|
|
3655
|
+
loadHistory,
|
|
3656
|
+
isLocalRunId,
|
|
3657
|
+
forgetLocalRunId,
|
|
3658
|
+
clearLocalRunIds,
|
|
3659
|
+
isLocalBtwRunId,
|
|
3660
|
+
forgetLocalBtwRunId,
|
|
3661
|
+
clearLocalBtwRunIds
|
|
3662
|
+
});
|
|
3663
|
+
const requestExit = () => {
|
|
3664
|
+
if (exitRequested) return;
|
|
3665
|
+
exitRequested = true;
|
|
3666
|
+
client.stop();
|
|
3667
|
+
stopTuiSafely(() => tui.stop());
|
|
3668
|
+
process.exit(0);
|
|
3669
|
+
};
|
|
3670
|
+
const { handleCommand, sendMessage, openModelSelector, openAgentSelector, openSessionSelector } = createCommandHandlers({
|
|
3671
|
+
client,
|
|
3672
|
+
chatLog,
|
|
3673
|
+
tui,
|
|
3674
|
+
opts,
|
|
3675
|
+
state,
|
|
3676
|
+
deliverDefault,
|
|
3677
|
+
openOverlay,
|
|
3678
|
+
closeOverlay,
|
|
3679
|
+
refreshSessionInfo,
|
|
3680
|
+
applySessionInfoFromPatch,
|
|
3681
|
+
loadHistory,
|
|
3682
|
+
setSession,
|
|
3683
|
+
refreshAgents,
|
|
3684
|
+
abortActive,
|
|
3685
|
+
setActivityStatus,
|
|
3686
|
+
formatSessionKey,
|
|
3687
|
+
noteLocalRunId,
|
|
3688
|
+
noteLocalBtwRunId,
|
|
3689
|
+
forgetLocalRunId,
|
|
3690
|
+
forgetLocalBtwRunId,
|
|
3691
|
+
requestExit
|
|
3692
|
+
});
|
|
3693
|
+
const { runLocalShellLine } = createLocalShellRunner({
|
|
3694
|
+
chatLog,
|
|
3695
|
+
tui,
|
|
3696
|
+
openOverlay,
|
|
3697
|
+
closeOverlay
|
|
3698
|
+
});
|
|
3699
|
+
updateAutocompleteProvider();
|
|
3700
|
+
editor.onSubmit = createSubmitBurstCoalescer({
|
|
3701
|
+
submit: createEditorSubmitHandler({
|
|
3702
|
+
editor,
|
|
3703
|
+
handleCommand,
|
|
3704
|
+
sendMessage,
|
|
3705
|
+
handleBangLine: runLocalShellLine
|
|
3706
|
+
}),
|
|
3707
|
+
enabled: shouldEnableWindowsGitBashPasteFallback()
|
|
3708
|
+
});
|
|
3709
|
+
editor.onEscape = () => {
|
|
3710
|
+
if (chatLog.hasVisibleBtw()) {
|
|
3711
|
+
chatLog.dismissBtw();
|
|
3712
|
+
tui.requestRender();
|
|
3713
|
+
return;
|
|
3714
|
+
}
|
|
3715
|
+
abortActive();
|
|
3716
|
+
};
|
|
3717
|
+
const handleCtrlC = () => {
|
|
3718
|
+
const now = Date.now();
|
|
3719
|
+
const decision = resolveCtrlCAction({
|
|
3720
|
+
hasInput: editor.getText().trim().length > 0,
|
|
3721
|
+
now,
|
|
3722
|
+
lastCtrlCAt
|
|
3723
|
+
});
|
|
3724
|
+
lastCtrlCAt = decision.nextLastCtrlCAt;
|
|
3725
|
+
if (decision.action === "clear") {
|
|
3726
|
+
editor.setText("");
|
|
3727
|
+
setActivityStatus("cleared input; press ctrl+c again to exit");
|
|
3728
|
+
tui.requestRender();
|
|
3729
|
+
return;
|
|
3730
|
+
}
|
|
3731
|
+
if (decision.action === "exit") {
|
|
3732
|
+
requestExit();
|
|
3733
|
+
return;
|
|
3734
|
+
}
|
|
3735
|
+
setActivityStatus("press ctrl+c again to exit");
|
|
3736
|
+
tui.requestRender();
|
|
3737
|
+
};
|
|
3738
|
+
editor.onCtrlC = () => {
|
|
3739
|
+
handleCtrlC();
|
|
3740
|
+
};
|
|
3741
|
+
editor.onCtrlD = () => {
|
|
3742
|
+
requestExit();
|
|
3743
|
+
};
|
|
3744
|
+
editor.onCtrlO = () => {
|
|
3745
|
+
toolsExpanded = !toolsExpanded;
|
|
3746
|
+
chatLog.setToolsExpanded(toolsExpanded);
|
|
3747
|
+
setActivityStatus(toolsExpanded ? "tools expanded" : "tools collapsed");
|
|
3748
|
+
tui.requestRender();
|
|
3749
|
+
};
|
|
3750
|
+
editor.onCtrlL = () => {
|
|
3751
|
+
openModelSelector();
|
|
3752
|
+
};
|
|
3753
|
+
editor.onCtrlG = () => {
|
|
3754
|
+
openAgentSelector();
|
|
3755
|
+
};
|
|
3756
|
+
editor.onCtrlP = () => {
|
|
3757
|
+
openSessionSelector();
|
|
3758
|
+
};
|
|
3759
|
+
editor.onCtrlT = () => {
|
|
3760
|
+
showThinking = !showThinking;
|
|
3761
|
+
loadHistory();
|
|
3762
|
+
};
|
|
3763
|
+
tui.addInputListener((data) => {
|
|
3764
|
+
if (!chatLog.hasVisibleBtw()) return;
|
|
3765
|
+
if (editor.getText().length > 0) return;
|
|
3766
|
+
if (matchesKey(data, "enter")) {
|
|
3767
|
+
chatLog.dismissBtw();
|
|
3768
|
+
tui.requestRender();
|
|
3769
|
+
return { consume: true };
|
|
3770
|
+
}
|
|
3771
|
+
});
|
|
3772
|
+
client.onEvent = (evt) => {
|
|
3773
|
+
if (evt.event === "chat") handleChatEvent(evt.payload);
|
|
3774
|
+
if (evt.event === "chat.side_result") handleBtwEvent(evt.payload);
|
|
3775
|
+
if (evt.event === "agent") handleAgentEvent(evt.payload);
|
|
3776
|
+
};
|
|
3777
|
+
client.onConnected = () => {
|
|
3778
|
+
isConnected = true;
|
|
3779
|
+
pairingHintShown = false;
|
|
3780
|
+
const reconnected = wasDisconnected;
|
|
3781
|
+
wasDisconnected = false;
|
|
3782
|
+
setConnectionStatus("connected");
|
|
3783
|
+
(async () => {
|
|
3784
|
+
await refreshAgents();
|
|
3785
|
+
updateHeader();
|
|
3786
|
+
await loadHistory();
|
|
3787
|
+
setConnectionStatus(reconnected ? "gateway reconnected" : "gateway connected", 4e3);
|
|
3788
|
+
tui.requestRender();
|
|
3789
|
+
if (!autoMessageSent && autoMessage) {
|
|
3790
|
+
autoMessageSent = true;
|
|
3791
|
+
await sendMessage(autoMessage);
|
|
3792
|
+
}
|
|
3793
|
+
updateFooter();
|
|
3794
|
+
tui.requestRender();
|
|
3795
|
+
})();
|
|
3796
|
+
};
|
|
3797
|
+
client.onDisconnected = (reason) => {
|
|
3798
|
+
isConnected = false;
|
|
3799
|
+
wasDisconnected = true;
|
|
3800
|
+
historyLoaded = false;
|
|
3801
|
+
const disconnectState = resolveGatewayDisconnectState(reason);
|
|
3802
|
+
setConnectionStatus(disconnectState.connectionStatus, 5e3);
|
|
3803
|
+
setActivityStatus(disconnectState.activityStatus);
|
|
3804
|
+
if (disconnectState.pairingHint && !pairingHintShown) {
|
|
3805
|
+
pairingHintShown = true;
|
|
3806
|
+
chatLog.addSystem(disconnectState.pairingHint);
|
|
3807
|
+
}
|
|
3808
|
+
updateFooter();
|
|
3809
|
+
tui.requestRender();
|
|
3810
|
+
};
|
|
3811
|
+
client.onGap = (info) => {
|
|
3812
|
+
setConnectionStatus(`event gap: expected ${info.expected}, got ${info.received}`, 5e3);
|
|
3813
|
+
tui.requestRender();
|
|
3814
|
+
};
|
|
3815
|
+
updateHeader();
|
|
3816
|
+
setConnectionStatus("connecting");
|
|
3817
|
+
updateFooter();
|
|
3818
|
+
const sigintHandler = () => {
|
|
3819
|
+
handleCtrlC();
|
|
3820
|
+
};
|
|
3821
|
+
const sigtermHandler = () => {
|
|
3822
|
+
requestExit();
|
|
3823
|
+
};
|
|
3824
|
+
process.on("SIGINT", sigintHandler);
|
|
3825
|
+
process.on("SIGTERM", sigtermHandler);
|
|
3826
|
+
tui.start();
|
|
3827
|
+
client.start();
|
|
3828
|
+
await new Promise((resolve) => {
|
|
3829
|
+
const finish = () => {
|
|
3830
|
+
process.removeListener("SIGINT", sigintHandler);
|
|
3831
|
+
process.removeListener("SIGTERM", sigtermHandler);
|
|
3832
|
+
resolve();
|
|
3833
|
+
};
|
|
3834
|
+
process.once("exit", finish);
|
|
3835
|
+
});
|
|
3836
|
+
}
|
|
3837
|
+
//#endregion
|
|
3838
|
+
export { runTui as t };
|