@gguf/claw 2026.2.4 → 2026.2.5
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/CHANGELOG.md +50 -1
- package/LICENSE +1 -1
- package/README.md +50 -43
- package/dist/{accounts-BlHoTziG.js → accounts-BgZmhIm6.js} +4 -4
- package/dist/{accounts-B5QZU96b.js → accounts-Dto4p9zB.js} +2 -2
- package/dist/{acp-cli-DU_cVWbN.js → acp-cli-BOKabdeW.js} +15 -15
- package/dist/{acp-cli-O8LcQigE.js → acp-cli-BwcHtBDk.js} +19 -19
- package/dist/{agent-BBI-UGkN.js → agent-DztWhVCH.js} +20 -13
- package/dist/{agent-DuQt3QDO.js → agent-_H-0rbHV.js} +21 -14
- package/dist/{agent-scope-jm0ZdXwM.js → agent-scope-C9VjJXEK.js} +5 -180
- package/dist/{agent-scope-CrgUOY3f.js → agent-scope-CMs5Y7l-.js} +6 -181
- package/dist/{agent-scope-COnICB_7.js → agent-scope-Csu2B6AM.js} +2 -2
- package/dist/{audit-D-OqdjQu.js → audit-BWbjQmyv.js} +182 -15
- package/dist/{audit-CWGOX7Eh.js → audit-ZY6Dk5Ec.js} +183 -16
- package/dist/{auth-viF_w60n.js → auth-CbhB03Rz.js} +2 -2
- package/dist/{auth-DK3l201_.js → auth-DksjO6WG.js} +2 -2
- package/dist/{auth-health-DcKoxhDo.js → auth-health-C4bElkgf.js} +1 -1
- package/dist/{auth-health-Ba9GTScq.js → auth-health-Ctf-_JFE.js} +1 -1
- package/dist/{auth-profiles-CfFGCDJa.js → auth-profiles-CYBuGiBb.js} +38 -13
- package/dist/build-info.json +2 -2
- package/dist/{call-CfqL-4Nc.js → call-90HgQQ8o.js} +34 -8
- package/dist/{call-CPBhMXxo.js → call-BTbA5OB4.js} +35 -9
- package/dist/canvas-host/a2ui/.bundle.hash +1 -1
- package/dist/canvas-host/a2ui/a2ui.bundle.js +29 -44
- package/dist/{channel-options-eRR8_a8h.js → channel-options-DrUmtdd9.js} +3 -3
- package/dist/{channel-options-BCSvD6JM.js → channel-options-uftAnT5P.js} +7 -7
- package/dist/{channel-selection-BAwiO0li.js → channel-selection-CJWYmCLf.js} +2 -2
- package/dist/{channel-selection-BCn8_qun.js → channel-selection-PZuuCvrp.js} +2 -2
- package/dist/{channel-summary-BkqO8zZ9.js → channel-summary-D9nzC5WB.js} +8 -42
- package/dist/{channel-summary-C8GoEKgH.js → channel-summary-DUiKDBLv.js} +9 -43
- package/dist/{channels-cli-CBGINubh.js → channels-cli-PAlqhOZ7.js} +56 -54
- package/dist/{channels-cli-yQo-Rzw6.js → channels-cli-PPk5wwuy.js} +59 -57
- package/dist/{channels-status-issues-C9vMMPG0.js → channels-status-issues-CJ8PJgDc.js} +1 -1
- package/dist/{channels-status-issues-DRXQXvhY.js → channels-status-issues-CrS1r5sr.js} +1 -1
- package/dist/{chrome-DlqPCh1y.js → chrome-B3IuUad-.js} +2 -2
- package/dist/{chrome-D2LUApAY.js → chrome-BNSd7Bie.js} +5 -5
- package/dist/{clack-prompter-OmDa1Hm1.js → clack-prompter-CEKDd_Vg.js} +5 -5
- package/dist/{clack-prompter-BJuVh97L.js → clack-prompter-DuBVnTKy.js} +4 -4
- package/dist/cli/daemon-cli.js +1 -1
- package/dist/cli-DBAccB3n.js +86 -0
- package/dist/cli-DD5dW58-.js +89 -0
- package/dist/{client-zqMhLTAX.js → client-BYVbRnuQ.js} +13 -5
- package/dist/{client-cU7Xg1MO.js → client-CxbkcEZ7.js} +12 -4
- package/dist/{command-options-51bBgSJL.js → command-options-DUUINcz0.js} +3 -3
- package/dist/{commands-DMKDOFmC.js → commands-DAC7XMAT.js} +5 -4
- package/dist/completion-cli-BPIeQDFy.js +773 -0
- package/dist/{completion-cli-BoF86Oeq.js → completion-cli-BbhA_JbG.js} +62 -15
- package/dist/{config-qgIz1lbh.js → config-CAuZ-EkU.js} +93 -31
- package/dist/{config-CGsoho7J.js → config-CG73z4h6.js} +61 -28
- package/dist/{config-DCT1RAo6.js → config-CKLedg5Y.js} +92 -30
- package/dist/{config-guard-CJuPkD5Y.js → config-guard-a5ynrKd-.js} +181 -57
- package/dist/{configure-C1_0rFdQ.js → configure-B47GYdlB.js} +33 -23
- package/dist/{configure-D0OAmW2s.js → configure-ChnTy7Jz.js} +31 -21
- package/dist/{control-service-BW5sW2U1.js → control-service-CS61Road.js} +13 -6
- package/dist/{control-service-Ds9ompnU.js → control-service-D2E9NKqQ.js} +12 -5
- package/dist/control-ui/assets/{index-RwcW4Xl0.css → index-BoXosYY6.css} +1 -1
- package/dist/control-ui/assets/index-Dm6g1E26.js +7553 -0
- package/dist/control-ui/assets/index-Dm6g1E26.js.map +1 -0
- package/dist/control-ui/index.html +2 -2
- package/dist/{cron-cli-Bn_e3WGb.js → cron-cli-CssI71-c.js} +20 -19
- package/dist/{cron-cli-BVARiNrv.js → cron-cli-Ys53MyTg.js} +24 -23
- package/dist/{daemon-cli-fHXAapHL.js → daemon-cli-B6aLZ8OE.js} +28 -23
- package/dist/{daemon-cli-yy_MAYxv.js → daemon-cli-CMKd_D6h.js} +26 -21
- package/dist/{daemon-runtime-vNkYv9tq.js → daemon-runtime-BCn_QIHK.js} +64 -7
- package/dist/{daemon-runtime-ELWW7q0C.js → daemon-runtime-DMd0mgTK.js} +64 -7
- package/dist/{deliver-Bsvrattg.js → deliver-C3bnXkg5.js} +12 -10
- package/dist/{deliver-Dl8TEyHM.js → deliver-CZPhTA7x.js} +7 -5
- package/dist/{deliver-eE21zdeQ.js → deliver-Cau4HL7W.js} +11 -9
- package/dist/{deps-BrcOX0ht.js → deps-BG1LonF6.js} +2 -2
- package/dist/{deps-wXkiMwLZ.js → deps-ytXmI88x.js} +2 -2
- package/dist/{devices-cli-BjlwgE6B.js → devices-cli-Cm0ENrXH.js} +16 -16
- package/dist/{devices-cli-BVc_Ic5O.js → devices-cli-D_rnGkqO.js} +12 -12
- package/dist/{directory-cli-cc9ivzEM.js → directory-cli-CGLolzJC.js} +15 -15
- package/dist/{directory-cli-CULRQACb.js → directory-cli-CTtv_AB7.js} +19 -19
- package/dist/{dispatcher-BNB5aCZ6.js → dispatcher-6oI-H42S.js} +1 -1
- package/dist/{dns-cli-BwDdBlsK.js → dns-cli-BRkJGLqK.js} +15 -15
- package/dist/{dns-cli-B79COhmu.js → dns-cli-CoeI4817.js} +11 -11
- package/dist/{docs-cli-BM55jf4Y.js → docs-cli-BH9bMx3a.js} +7 -7
- package/dist/{docs-cli-t7IEzxr8.js → docs-cli-Bh1Coji2.js} +10 -10
- package/dist/{doctor-CT9JPoCt.js → doctor-CwSrWRCp.js} +43 -38
- package/dist/{doctor-OmfNRlMS.js → doctor-JnMryC_M.js} +40 -35
- package/dist/entry.js +12 -8
- package/dist/{env-DOcCob95.js → env-0_mKbEWW.js} +2 -2
- package/dist/{errors-DdT2Dtkb.js → errors-CZ9opC6L.js} +4 -4
- package/dist/{exec-B7WKla_0.js → exec-BMnoMcZW.js} +1 -1
- package/dist/{exec-CTo4hK94.js → exec-HEWTMJ7j.js} +1 -1
- package/dist/{exec-approvals-WdYFyy5N.js → exec-approvals-BCEFzcbC.js} +19 -2
- package/dist/{exec-approvals-CK-Umdr3.js → exec-approvals-DZixgolZ.js} +19 -2
- package/dist/{exec-approvals-cli-DD_z4fL9.js → exec-approvals-cli-D7aVv5hN.js} +19 -19
- package/dist/{exec-approvals-cli-BK2toX2b.js → exec-approvals-cli-DzLp5G7t.js} +23 -23
- package/dist/extensionAPI.js +1186 -267
- package/dist/{gateway-cli-BCC0T5iY.js → gateway-cli-DHP5DRUH.js} +910 -199
- package/dist/{gateway-cli-BTlr6Uwl.js → gateway-cli-ape0pnBU.js} +912 -202
- package/dist/{gateway-rpc-CMAcradB.js → gateway-rpc-C8rNIC0P.js} +3 -3
- package/dist/{gateway-rpc-SvVB4Fmv.js → gateway-rpc-CWnTaSEY.js} +3 -3
- package/dist/{github-copilot-auth-BHLcQ1sN.js → github-copilot-auth-B_lK1g__.js} +173 -87
- package/dist/{github-copilot-auth-BoRchp_Q.js → github-copilot-auth-C8Uf0Q03.js} +174 -88
- package/dist/{github-copilot-token-BEtihsn6.js → github-copilot-token-B3SA95yo.js} +8 -2
- package/dist/{github-copilot-token-rP-6QdKv.js → github-copilot-token-SLWintYd.js} +7 -1
- package/dist/{github-copilot-token-VZsS4013.js → github-copilot-token-pGSmVaW-.js} +8 -2
- package/dist/{gmail-setup-utils-4czdWNCN.js → gmail-setup-utils-Bi6W14MK.js} +3 -3
- package/dist/{gmail-setup-utils-B1CTmT2V.js → gmail-setup-utils-QpN7TEXS.js} +4 -4
- package/dist/{health-format-B4_A88V3.js → health-format-B3eStY5r.js} +215 -21
- package/dist/{health-format-Ct8J0fwc.js → health-format-ND2rUbQO.js} +213 -19
- package/dist/{help-format-CGcnDM3D.js → help-format-Bozi4K9H.js} +1 -1
- package/dist/{helpers-DfgBr1D5.js → helpers-BIc7L8EF.js} +1 -1
- package/dist/{helpers-Cw9kFCkw.js → helpers-D66_XoIz.js} +1 -1
- package/dist/{hooks-cli-NmkXLKmj.js → hooks-cli-BMu_-4Ru.js} +49 -49
- package/dist/{hooks-cli-B-28F__A.js → hooks-cli-CmeQxEOM.js} +45 -45
- package/dist/{hooks-status-I3Y60zVN.js → hooks-status-CKmUPU-M.js} +3 -3
- package/dist/{hooks-status-XV9oQICf.js → hooks-status-DepPyfBb.js} +4 -4
- package/dist/{image-ClOB6QDJ.js → image-Ca_PtqY7.js} +8 -6
- package/dist/{image-BYmtfVH8.js → image-CgBndiQy.js} +9 -7
- package/dist/{image-CXg7Z0WD.js → image-nRwqkmtf.js} +8 -6
- package/dist/index.js +231 -105
- package/dist/{installs-C5cjVarj.js → installs-BhEjOqPy.js} +43 -6
- package/dist/{installs-W4Pc1LJz.js → installs-DsJkyWfL.js} +43 -6
- package/dist/{links-C9fyAH-V.js → links-B5pRdmo1.js} +1 -1
- package/dist/{links-jGisPfXW.js → links-D0uzJbi6.js} +1 -1
- package/dist/{loader-BYWxo-_j.js → loader-_Pj-TZS2.js} +920 -491
- package/dist/{logging-BnUUuH3y.js → logging-Cc7m6PTv.js} +1 -1
- package/dist/{logging-CLCWl7Iu.js → logging-TXWhN8jG.js} +2 -2
- package/dist/{login-qr-C2H_iQJU.js → login-qr-BIlr0vwe.js} +12 -7
- package/dist/{login-qr-7WOtj6zE.js → login-qr-CcOWO_dR.js} +9 -4
- package/dist/{login-qr-sEcxw1_U.js → login-qr-Cmsf7BGt.js} +11 -6
- package/dist/{logs-cli-C5v4fEDj.js → logs-cli-5L3NxTsc.js} +19 -19
- package/dist/{logs-cli-nVwK5g60.js → logs-cli-DtiFFkZL.js} +15 -15
- package/dist/{manager-rDmdE7O9.js → manager-BXiIQku7.js} +9 -7
- package/dist/{manager-JSP5pLyv.js → manager-C4ILl-d3.js} +10 -8
- package/dist/{manager-BArueSTR.js → manager-LpytrxUw.js} +12 -10
- package/dist/{manifest-registry-tuAcHxrV.js → manifest-registry-C69Z-I4v.js} +1 -1
- package/dist/{manifest-registry-BFpLJJDB.js → manifest-registry-DHaa1SJb.js} +1 -1
- package/dist/{message-channel-CAFcg7mw.js → message-channel-BlgPSDAh.js} +6 -1
- package/dist/{message-channel-CQGWXVL4.js → message-channel-Bpfe5l5f.js} +7 -2
- package/dist/{model-selection-Cp1maz7B.js → model-selection-DMUrNhQP.js} +41 -16
- package/dist/{model-selection-Cs1y6OBv.js → model-selection-mzTqrNoj.js} +38 -14
- package/dist/{models-cli-n9a8pESx.js → models-cli-DHzyyLvp.js} +49 -49
- package/dist/{models-cli-DGnLcr4X.js → models-cli-EhrWjNLH.js} +53 -53
- package/dist/{net-DaJz_a4n.js → net-C8YRVt16.js} +1 -1
- package/dist/{net-DeiCIMU6.js → net-CWMMy37F.js} +1 -1
- package/dist/{node-cli-rtEq-YyU.js → node-cli-2oYmIWJt.js} +30 -30
- package/dist/{node-cli-AOO0HsM1.js → node-cli-DH7Ykym5.js} +26 -26
- package/dist/{node-service-CjtBRyjp.js → node-service-BAYHx0E7.js} +2 -2
- package/dist/{node-service-BW_LhY5w.js → node-service-Lc1LlnFH.js} +2 -2
- package/dist/{nodes-cli-Coxj5hDA.js → nodes-cli-Bc5K-0Lt.js} +22 -22
- package/dist/{nodes-cli-ChBsNXzz.js → nodes-cli-hT8yYD7S.js} +18 -18
- package/dist/{nodes-screen-Ln98EX_f.js → nodes-screen-DGlNPbk4.js} +2 -2
- package/dist/{nodes-screen-DOhGEibx.js → nodes-screen-DT5HvhJV.js} +2 -2
- package/dist/{note-BFpD-42H.js → note-B5HnoeZX.js} +2 -2
- package/dist/{note-CBiVaqG7.js → note-Ci08TSbV.js} +1 -1
- package/dist/{onboard-channels-CF7lTDNu.js → onboard-channels-D-ZQTy5V.js} +9 -8
- package/dist/{onboard-channels-CJCy7TTQ.js → onboard-channels-DKT27PdN.js} +10 -9
- package/dist/{onboard-skills-DdFGj9pt.js → onboard-skills-YobctE-R.js} +259 -194
- package/dist/{onboard-skills-fL84FI8F.js → onboard-skills-s8J5xbUr.js} +259 -194
- package/dist/{onboarding-DcN1avQK.js → onboarding-BP4-5uzE.js} +96 -60
- package/dist/{pairing-cli-DbP9KqPL.js → pairing-cli-C8KHRjaU.js} +15 -15
- package/dist/{pairing-cli-B7RQFp4r.js → pairing-cli-i7wiTmYC.js} +19 -19
- package/dist/{pairing-labels-DK2aLSd2.js → pairing-labels-BbydDT7w.js} +1 -1
- package/dist/{pairing-labels-C6I3dD-m.js → pairing-labels-CtqLxbG6.js} +1 -1
- package/dist/{pairing-store-BnMngoWQ.js → pairing-store-DFq7WtOv.js} +2 -2
- package/dist/{pairing-store-DMex6WWe.js → pairing-store-DTfv_FGA.js} +1 -1
- package/dist/{path-env-CuGC6r1F.js → path-env-DP3DsVge.js} +2 -2
- package/dist/{path-env-CUhrC5DA.js → path-env-h3xp5PqO.js} +1 -1
- package/dist/{paths-xPuk88Yf.js → paths-B4kigINg.js} +2 -2
- package/dist/{paths-50eo6DV6.js → paths-Bb0nwPeu.js} +2 -2
- package/dist/{paths-RvF0P6tQ.js → paths-CTg8F3AE.js} +1 -1
- package/dist/{pi-embedded-helpers-DJgCXZEz.js → pi-embedded-helpers-BB4uACeq.js} +175 -170
- package/dist/{pi-embedded-helpers-DiK8Qn1l.js → pi-embedded-helpers-BxqZh6U7.js} +43 -19
- package/dist/{pi-embedded-helpers-CC00lEFI.js → pi-embedded-helpers-DF8SAHU-.js} +175 -170
- package/dist/{pi-model-discovery-DjGamP_B.js → pi-model-discovery-CV2V1HHz.js} +8 -1
- package/dist/{pi-model-discovery-CnK2Dol8.js → pi-model-discovery-DzEIEgHL.js} +8 -1
- package/dist/{pi-model-discovery-CsRo-xMp.js → pi-model-discovery-EhM2JAQo.js} +8 -1
- package/dist/{pi-tools.policy-DleRi9eC.js → pi-tools.policy-BQ8N5y8a.js} +5 -4
- package/dist/{plugin-auto-enable-JQ63k0Ce.js → plugin-auto-enable-Ci7TBlH2.js} +5 -5
- package/dist/{plugin-auto-enable-CIVp3SAp.js → plugin-auto-enable-DyW8lHTT.js} +4 -4
- package/dist/plugin-sdk/index.d.ts +228 -283
- package/dist/plugin-sdk/index.js +22528 -69091
- package/dist/plugin-sdk/pi-model-discovery-Dw3A6oXH.js +37 -0
- package/dist/{plugins-TrKFfrLt.js → plugins-BUPpq5aS.js} +3 -2
- package/dist/{plugins-D1CxUobm.js → plugins-BYIWo0Cp.js} +5 -4
- package/dist/{plugins-cli-17wYux52.js → plugins-cli-CGfxctIx.js} +50 -49
- package/dist/{plugins-cli-VyQWn_LW.js → plugins-cli-Dr_R2-FY.js} +46 -45
- package/dist/{ports-B27T1uRn.js → ports-0V-Mu4ch.js} +2 -2
- package/dist/{program-BA9_uWfO.js → program-oR55MCAT.js} +84 -81
- package/dist/{progress-uNDQDtGB.js → progress-xpLtQsNY.js} +1 -1
- package/dist/{prompt-style-gfROyHgB.js → prompt-style-vzh0MGHs.js} +1 -1
- package/dist/{pw-ai-BC4dLE7k.js → pw-ai-B7Fvw8DW.js} +4 -4
- package/dist/{pw-ai-DlTBXZjY.js → pw-ai-DYpQO6HI.js} +6 -6
- package/dist/{pw-ai-BEqPnalN.js → pw-ai-tNPuRNn3.js} +4 -4
- package/dist/{qmd-manager-8xWxIGbO.js → qmd-manager-BKkFEEN_.js} +9 -8
- package/dist/{plugin-sdk/qmd-manager-DvkA01DP.js → qmd-manager-CF52nuBg.js} +6 -6
- package/dist/{qmd-manager-BSCOmXYZ.js → qmd-manager-Dub8jfbo.js} +7 -6
- package/dist/{register.subclis-CWWz9WdX.js → register.subclis-BpIR6Iqi.js} +36 -30
- package/dist/{reply-CoztdrN_.js → reply-B8pOiUNN.js} +935 -506
- package/dist/rolldown-runtime-Cbj13DAv.js +20 -0
- package/dist/{routes-yI5QIzeL.js → routes-BSfXf8a5.js} +5 -5
- package/dist/{routes-Ds-tIZFJ.js → routes-DchZU3EK.js} +6 -6
- package/dist/{rpc-HF82_iLh.js → rpc-DqI3QH59.js} +3 -3
- package/dist/{rpc-HdKLb6jx.js → rpc-Vo2ACfn-.js} +3 -3
- package/dist/{run-main-B3krVvc1.js → run-main-DrVUUPHV.js} +84 -84
- package/dist/{sandbox-BXUfp_qv.js → sandbox-CV8VwPij.js} +36 -16
- package/dist/{sandbox-Cnq9TXEn.js → sandbox-DuqLKN5J.js} +34 -14
- package/dist/{sandbox-cli-C7j1V6tb.js → sandbox-cli-C0_Hrk7i.js} +25 -24
- package/dist/{sandbox-cli-CnS9JJlO.js → sandbox-cli-Ces6i3n2.js} +21 -20
- package/dist/{security-cli-Clg7RQT3.js → security-cli-CybLT9XS.js} +32 -30
- package/dist/{security-cli-BGd4NO4l.js → security-cli-T7yrd3lb.js} +28 -26
- package/dist/{server-context-D2cv-pIA.js → server-context-vChIAqjH.js} +6 -6
- package/dist/{server-context-CM_E6wD5.js → server-context-yKyxyxOJ.js} +5 -5
- package/dist/{server-node-events-IMwI538C.js → server-node-events-BR2vHqf6.js} +44 -43
- package/dist/{server-node-events-C5EqDe_U.js → server-node-events-D39FA0NG.js} +48 -47
- package/dist/{service-CAxAjHNB.js → service-BZesBIaG.js} +3 -3
- package/dist/{service-BoDHq_LN.js → service-_JwSmGSn.js} +2 -2
- package/dist/{service-audit-Bf33pqEM.js → service-audit-C-IA4omi.js} +6 -6
- package/dist/{service-audit-DBSAGhm8.js → service-audit-DDX1kO3k.js} +6 -6
- package/dist/session-cost-usage-BTXosU1k.js +692 -0
- package/dist/session-cost-usage-CBP4Hv9D.js +692 -0
- package/dist/session-key-CZkcvAtx.js +177 -0
- package/dist/session-key-Dm2EOhrH.js +177 -0
- package/dist/{shared-ChNOqAzp.js → shared-BmtNKsPq.js} +4 -4
- package/dist/{shared-D42-KbPa.js → shared-C1XLEyB0.js} +3 -3
- package/dist/{shared-xZjRQa6y.js → shared-C8_5pNbb.js} +4 -4
- package/dist/{shared-DBGw227P.js → shared-fnGLWyZ6.js} +3 -3
- package/dist/skill-scanner-BoGjHXUZ.js +255 -0
- package/dist/skill-scanner-Bp1D9gra.js +255 -0
- package/dist/{skills-DtwGIkTI.js → skills-CmU0Q92f.js} +3 -3
- package/dist/{skills-C4b1FA1e.js → skills-D5JDj3TR.js} +5 -5
- package/dist/{skills-cli-BPkuJAz9.js → skills-cli-C1yJvIkL.js} +16 -16
- package/dist/{skills-cli-b0ZmGlmh.js → skills-cli-DBC5zFat.js} +12 -12
- package/dist/{skills-status-CSCMqNZP.js → skills-status-CEvVUD3U.js} +3 -3
- package/dist/{skills-status-CWkBweWW.js → skills-status-DtXrj3fy.js} +2 -2
- package/dist/{status-BIWeu5mN.js → status-BRXuHUsK.js} +94 -58
- package/dist/{status-CcM6W8r4.js → status-BTGXSvZ1.js} +3 -3
- package/dist/{status-PjegR5Cv.js → status-DBZ5Z7ng.js} +4 -4
- package/dist/{subsystem-46MXi6Ip.js → subsystem-CAq3uyo7.js} +1 -1
- package/dist/{system-cli-B4FEIE5d.js → system-cli-Dqnt-b0D.js} +13 -13
- package/dist/{system-cli-BL_QZ1VP.js → system-cli-SJLtqI47.js} +17 -17
- package/dist/{systemd-DAgZTW06.js → systemd-8sIc6isV.js} +2 -2
- package/dist/{systemd-CNYEkRek.js → systemd-B-3NdMmA.js} +3 -3
- package/dist/{systemd-hints-CcgK8AJE.js → systemd-hints-DO88c_nD.js} +1 -1
- package/dist/{systemd-hints-okqOoOug.js → systemd-hints-Wim4Bq6j.js} +1 -1
- package/dist/{systemd-linger-CTe0ZDxD.js → systemd-linger-N-cIaegf.js} +8 -3
- package/dist/{systemd-linger-Cbkoh9qw.js → systemd-linger-SsSOsJST.js} +8 -3
- package/dist/{table-f0EgX-YI.js → table-CJSx0YID.js} +1 -1
- package/dist/{table-DuNe7Qes.js → table-CLtGjVsx.js} +2 -2
- package/dist/{tailscale-BUcKO8Rr.js → tailscale-9MusRvOi.js} +1 -1
- package/dist/{tailscale-Cvk3mQDZ.js → tailscale-BVGD9gSD.js} +2 -2
- package/dist/{tool-display-rIUh61kT.js → tool-display-BxZG0o1b.js} +2 -2
- package/dist/{tool-display-BMYWrp0L.js → tool-display-DmgKs6-V.js} +2 -2
- package/dist/{tui-cV-R-JXi.js → tui-DPorsF4z.js} +203 -75
- package/dist/{tui-DBmFYQTk.js → tui-XH6_v0qC.js} +204 -74
- package/dist/{tui-cli-B_CKOjZ1.js → tui-cli-DRSIBDgZ.js} +30 -29
- package/dist/{tui-cli-CVdJ28TX.js → tui-cli-DV_JAtnq.js} +26 -25
- package/dist/{update-BDyA5Iqy.js → update-DNAVcIQ7.js} +3 -3
- package/dist/{update-BIB5jGcv.js → update-DzMcwy1G.js} +3 -3
- package/dist/{update-cli-p49uMWby.js → update-cli-OAcZiYuA.js} +112 -27
- package/dist/{update-cli-C5vwquH_.js → update-cli-tQcy8mkI.js} +109 -23
- package/dist/{update-runner-8XFxQglY.js → update-runner-2i8_mIG5.js} +254 -17
- package/dist/{update-runner-s8Rs8ex3.js → update-runner-BDdk_K2S.js} +254 -17
- package/dist/usage-format-DvowRSs-.js +36 -0
- package/dist/usage-format-E3bMcUMV.js +36 -0
- package/dist/{utils-Dg0Xbl6w.js → utils-CKSrBNwq.js} +2 -2
- package/dist/{webhooks-cli-DkQGQ2ae.js → webhooks-cli-BztQHEco.js} +11 -11
- package/dist/{webhooks-cli-kRN8qR7B.js → webhooks-cli-ZAn97osC.js} +15 -15
- package/dist/{widearea-dns-BIhjVRG1.js → widearea-dns-CsSylzXH.js} +2 -2
- package/dist/{widearea-dns-D4yoSNNw.js → widearea-dns-D9Al4QRv.js} +2 -2
- package/dist/{ws-log-DQ6nkLys.js → ws-log-B7UNLFLC.js} +3 -3
- package/dist/{ws-log-C4IerKk4.js → ws-log-DJIXahf0.js} +2 -2
- package/dist/{wsl-DASmek7h.js → wsl-ATjkMwMA.js} +1 -1
- package/docs/.i18n/glossary.zh-CN.json +20 -0
- package/docs/assets/macos-onboarding/01-macos-warning.jpeg +0 -0
- package/docs/assets/macos-onboarding/02-local-networks.jpeg +0 -0
- package/docs/assets/macos-onboarding/03-security-notice.png +0 -0
- package/docs/assets/macos-onboarding/04-choose-gateway.png +0 -0
- package/docs/assets/macos-onboarding/05-permissions.png +0 -0
- package/docs/bedrock.md +3 -3
- package/docs/channels/discord.md +2 -1
- package/docs/channels/feishu.md +72 -2
- package/docs/channels/telegram.md +19 -0
- package/docs/cli/devices.md +3 -0
- package/docs/cli/gateway.md +3 -0
- package/docs/cli/index.md +2 -0
- package/docs/cli/onboard.md +16 -2
- package/docs/concepts/features.md +53 -0
- package/docs/concepts/memory.md +1 -1
- package/docs/concepts/messages.md +1 -1
- package/docs/concepts/model-providers.md +11 -11
- package/docs/concepts/models.md +1 -1
- package/docs/concepts/multi-agent.md +2 -2
- package/docs/concepts/session.md +19 -3
- package/docs/docs.json +331 -182
- package/docs/gateway/cli-backends.md +7 -5
- package/docs/gateway/configuration-examples.md +4 -4
- package/docs/gateway/configuration.md +34 -16
- package/docs/gateway/heartbeat.md +61 -1
- package/docs/gateway/local-models.md +3 -3
- package/docs/gateway/network-model.md +17 -0
- package/docs/gateway/remote.md +3 -1
- package/docs/gateway/security/index.md +1 -1
- package/docs/help/faq.md +25 -26
- package/docs/help/submitting-a-pr.md +214 -0
- package/docs/help/submitting-an-issue.md +165 -0
- package/docs/index.md +127 -193
- package/docs/install/docker.md +2 -2
- package/docs/{platforms → install}/exe-dev.md +4 -3
- package/docs/{platforms → install}/fly.md +1 -1
- package/docs/install/index.md +4 -2
- package/docs/nodes/media-understanding.md +2 -2
- package/docs/platforms/digitalocean.md +2 -2
- package/docs/platforms/index.md +4 -4
- package/docs/platforms/linux.md +1 -1
- package/docs/platforms/mac/release.md +7 -7
- package/docs/platforms/oracle.md +1 -1
- package/docs/platforms/raspberry-pi.md +1 -1
- package/docs/providers/anthropic.md +3 -3
- package/docs/providers/index.md +1 -1
- package/docs/providers/minimax.md +3 -3
- package/docs/providers/models.md +1 -1
- package/docs/providers/ollama.md +60 -6
- package/docs/providers/openai.md +2 -2
- package/docs/providers/opencode.md +1 -1
- package/docs/providers/vercel-ai-gateway.md +1 -1
- package/docs/reference/credits.md +27 -0
- package/docs/reference/wizard.md +268 -0
- package/docs/start/bootstrapping.md +41 -0
- package/docs/start/docs-directory.md +64 -0
- package/docs/start/getting-started.md +109 -197
- package/docs/start/hubs.md +12 -0
- package/docs/start/onboarding.md +51 -81
- package/docs/start/openclaw.md +3 -20
- package/docs/start/quickstart.md +22 -0
- package/docs/start/setup.md +14 -1
- package/docs/start/wizard-cli-automation.md +141 -0
- package/docs/start/wizard-cli-reference.md +244 -0
- package/docs/start/wizard.md +48 -289
- package/docs/style.css +3 -0
- package/docs/testing.md +9 -9
- package/docs/token-use.md +2 -2
- package/docs/tools/index.md +3 -0
- package/docs/tools/llm-task.md +1 -1
- package/docs/tools/thinking.md +1 -0
- package/docs/tui.md +3 -0
- package/docs/vps.md +6 -6
- package/docs/web/control-ui.md +2 -0
- package/docs/web/dashboard.md +7 -7
- package/docs/zh-CN/channels/feishu.md +119 -3
- package/docs/zh-CN/concepts/features.md +59 -0
- package/docs/zh-CN/gateway/network-model.md +23 -0
- package/docs/zh-CN/gateway/remote.md +1 -1
- package/docs/zh-CN/help/faq.md +5 -5
- package/docs/zh-CN/index.md +124 -202
- package/docs/zh-CN/install/docker.md +1 -1
- package/docs/zh-CN/platforms/digitalocean.md +2 -2
- package/docs/zh-CN/platforms/index.md +4 -4
- package/docs/zh-CN/platforms/linux.md +1 -1
- package/docs/zh-CN/platforms/oracle.md +1 -1
- package/docs/zh-CN/platforms/raspberry-pi.md +1 -1
- package/docs/zh-CN/providers/ollama.md +1 -1
- package/docs/zh-CN/reference/credits.md +34 -0
- package/docs/zh-CN/start/docs-directory.md +70 -0
- package/docs/zh-CN/start/getting-started.md +1 -1
- package/docs/zh-CN/start/hubs.md +39 -30
- package/docs/zh-CN/start/quickstart.md +88 -0
- package/docs/zh-CN/vps.md +4 -4
- package/extensions/bluebubbles/package.json +1 -1
- package/extensions/bluebubbles/src/monitor.ts +9 -0
- package/extensions/copilot-proxy/index.ts +1 -0
- package/extensions/copilot-proxy/package.json +1 -1
- package/extensions/diagnostics-otel/package.json +1 -1
- package/extensions/discord/package.json +1 -1
- package/extensions/feishu/index.ts +49 -1
- package/extensions/feishu/openclaw.plugin.json +1 -0
- package/extensions/feishu/package.json +9 -5
- package/extensions/feishu/skills/feishu-doc/SKILL.md +105 -0
- package/extensions/feishu/skills/feishu-doc/references/block-types.md +103 -0
- package/extensions/feishu/skills/feishu-drive/SKILL.md +97 -0
- package/extensions/feishu/skills/feishu-perm/SKILL.md +119 -0
- package/extensions/feishu/skills/feishu-wiki/SKILL.md +111 -0
- package/extensions/feishu/src/accounts.ts +144 -0
- package/extensions/feishu/src/bitable.ts +459 -0
- package/extensions/feishu/src/bot.ts +871 -0
- package/extensions/feishu/src/channel.ts +267 -202
- package/extensions/feishu/src/client.ts +118 -0
- package/extensions/feishu/src/config-schema.ts +152 -26
- package/extensions/feishu/src/directory.ts +177 -0
- package/extensions/feishu/src/doc-schema.ts +47 -0
- package/extensions/feishu/src/docx.ts +521 -0
- package/extensions/feishu/src/drive-schema.ts +46 -0
- package/extensions/feishu/src/drive.ts +227 -0
- package/extensions/feishu/src/media.ts +527 -0
- package/extensions/feishu/src/mention.ts +126 -0
- package/extensions/feishu/src/monitor.ts +190 -0
- package/extensions/feishu/src/onboarding.ts +278 -200
- package/extensions/feishu/src/outbound.ts +40 -0
- package/extensions/feishu/src/perm-schema.ts +52 -0
- package/extensions/feishu/src/perm.ts +173 -0
- package/extensions/feishu/src/policy.ts +104 -0
- package/extensions/feishu/src/probe.ts +44 -0
- package/extensions/feishu/src/reactions.ts +160 -0
- package/extensions/feishu/src/reply-dispatcher.ts +184 -0
- package/extensions/feishu/src/runtime.ts +14 -0
- package/extensions/feishu/src/send.ts +358 -0
- package/extensions/feishu/src/targets.ts +78 -0
- package/extensions/feishu/src/tools-config.ts +21 -0
- package/extensions/feishu/src/types.ts +75 -0
- package/extensions/feishu/src/typing.ts +80 -0
- package/extensions/feishu/src/wiki-schema.ts +55 -0
- package/extensions/feishu/src/wiki.ts +232 -0
- package/extensions/google-antigravity-auth/package.json +1 -1
- package/extensions/google-gemini-cli-auth/package.json +1 -1
- package/extensions/googlechat/package.json +1 -1
- package/extensions/googlechat/src/monitor.ts +12 -1
- package/extensions/imessage/package.json +1 -1
- package/extensions/line/package.json +1 -1
- package/extensions/llm-task/package.json +1 -1
- package/extensions/lobster/package.json +1 -1
- package/extensions/matrix/CHANGELOG.md +6 -0
- package/extensions/matrix/package.json +1 -1
- package/extensions/matrix/src/config-schema.ts +1 -0
- package/extensions/matrix/src/matrix/monitor/handler.ts +9 -5
- package/extensions/matrix/src/types.ts +2 -0
- package/extensions/mattermost/package.json +1 -1
- package/extensions/mattermost/src/channel.test.ts +24 -0
- package/extensions/mattermost/src/config-schema.ts +1 -0
- package/extensions/mattermost/src/mattermost/monitor.ts +9 -5
- package/extensions/mattermost/src/types.ts +2 -0
- package/extensions/memory-core/package.json +1 -1
- package/extensions/memory-lancedb/node_modules/.bin/openai +2 -2
- package/extensions/memory-lancedb/node_modules/.bin/openai.CMD +2 -2
- package/extensions/memory-lancedb/node_modules/.bin/openai.ps1 +2 -2
- package/extensions/memory-lancedb/package.json +2 -2
- package/extensions/minimax-portal-auth/package.json +1 -1
- package/extensions/msteams/CHANGELOG.md +6 -0
- package/extensions/msteams/package.json +1 -1
- package/extensions/msteams/src/monitor-handler/message-handler.ts +1 -0
- package/extensions/msteams/src/reply-dispatcher.ts +7 -5
- package/extensions/nextcloud-talk/package.json +1 -1
- package/extensions/nextcloud-talk/src/config-schema.ts +1 -0
- package/extensions/nextcloud-talk/src/inbound.ts +10 -0
- package/extensions/nextcloud-talk/src/send.ts +7 -2
- package/extensions/nextcloud-talk/src/types.ts +2 -0
- package/extensions/nostr/CHANGELOG.md +6 -0
- package/extensions/nostr/package.json +1 -1
- package/extensions/open-prose/package.json +1 -1
- package/extensions/signal/package.json +1 -1
- package/extensions/slack/package.json +1 -1
- package/extensions/telegram/package.json +1 -1
- package/extensions/tlon/package.json +1 -1
- package/extensions/tlon/src/config-schema.ts +2 -0
- package/extensions/tlon/src/monitor/index.ts +41 -14
- package/extensions/tlon/src/monitor/utils.ts +1 -0
- package/extensions/twitch/CHANGELOG.md +6 -0
- package/extensions/twitch/package.json +1 -1
- package/extensions/twitch/src/config-schema.ts +2 -0
- package/extensions/twitch/src/monitor.ts +11 -0
- package/extensions/twitch/src/types.ts +2 -0
- package/extensions/voice-call/CHANGELOG.md +6 -0
- package/extensions/voice-call/package.json +1 -1
- package/extensions/voice-call/src/manager.test.ts +30 -0
- package/extensions/whatsapp/package.json +1 -1
- package/extensions/zalo/CHANGELOG.md +6 -0
- package/extensions/zalo/package.json +1 -1
- package/extensions/zalo/src/config-schema.ts +1 -0
- package/extensions/zalo/src/monitor.ts +11 -0
- package/extensions/zalo/src/types.ts +2 -0
- package/extensions/zalouser/CHANGELOG.md +6 -0
- package/extensions/zalouser/package.json +1 -1
- package/extensions/zalouser/src/config-schema.ts +1 -0
- package/extensions/zalouser/src/monitor.ts +12 -1
- package/extensions/zalouser/src/types.ts +2 -0
- package/package.json +14 -14
- package/dist/auth-profiles-3t9aTwDR.js +0 -11
- package/dist/auth-profiles-BYvLI-zr.js +0 -7
- package/dist/auth-profiles-DswR7tzt.js +0 -7
- package/dist/cli-BxIwNzhi.js +0 -89
- package/dist/cli-wFmvNjpg.js +0 -86
- package/dist/command-format-SkzzRqR1.js +0 -52
- package/dist/completion-cli-vxe-jqwC.js +0 -390
- package/dist/config-BwVg6hhl.js +0 -13
- package/dist/config-jKcyRiMo.js +0 -10
- package/dist/configure-DaecSBSI.js +0 -60
- package/dist/configure-t-7r9i4H.js +0 -64
- package/dist/control-service-Dag9b-dU.js +0 -16
- package/dist/control-service-DsUyuevF.js +0 -12
- package/dist/control-ui/assets/index-ryaCcbyp.js +0 -4584
- package/dist/control-ui/assets/index-ryaCcbyp.js.map +0 -1
- package/dist/daemon-cli-CUkUiGoK.js +0 -53
- package/dist/daemon-cli-D6FF4tmP.js +0 -49
- package/dist/deliver-BGnJ4-vz.js +0 -12
- package/dist/deliver-CXpx7BNb.js +0 -25
- package/dist/deliver-Ds2yqOA3.js +0 -21
- package/dist/doctor-BwqqPqMX.js +0 -58
- package/dist/doctor-DGrfzoKj.js +0 -62
- package/dist/github-copilot-token-B0CUgVkW.js +0 -4
- package/dist/github-copilot-token-B_uWT0Yi.js +0 -4
- package/dist/github-copilot-token-CXUZ9Lrb.js +0 -3
- package/dist/image-CgTMdnmz.js +0 -28
- package/dist/image-D1O-ebQc.js +0 -14
- package/dist/image-njq9Rf6U.js +0 -24
- package/dist/login-qr-BfbIJ1wP.js +0 -12
- package/dist/login-qr-CGWNrSQq.js +0 -9
- package/dist/login-qr-CUV9HZCg.js +0 -16
- package/dist/manager-DKpTd5pc.js +0 -10
- package/dist/manager-Dr_eVHpN.js +0 -10
- package/dist/manager-DtFcs1NT.js +0 -14
- package/dist/pi-model-discovery-BOramrmp.js +0 -3
- package/dist/pi-model-discovery-Bj98Srfa.js +0 -3
- package/dist/pi-model-discovery-DHPwfwKu.js +0 -3
- package/dist/plugin-sdk/agent-scope-qNPdmst1.js +0 -606
- package/dist/plugin-sdk/auth-profiles-D0LhX8iB.js +0 -7
- package/dist/plugin-sdk/chrome-DMuEXuKT.js +0 -1953
- package/dist/plugin-sdk/config-D5CsedNn.js +0 -5623
- package/dist/plugin-sdk/deliver-DOlMKwJ9.js +0 -12
- package/dist/plugin-sdk/deliver-Dl2ednkv.js +0 -2555
- package/dist/plugin-sdk/exec-CjyVHUuE.js +0 -1107
- package/dist/plugin-sdk/github-copilot-token-BoPqI-5_.js +0 -97
- package/dist/plugin-sdk/github-copilot-token-YEH9Bwov.js +0 -4
- package/dist/plugin-sdk/image-B_t0xXCb.js +0 -1419
- package/dist/plugin-sdk/image-DYTdodiR.js +0 -14
- package/dist/plugin-sdk/login-qr-B7ec28AI.js +0 -9
- package/dist/plugin-sdk/login-qr-BVBRxQRt.js +0 -470
- package/dist/plugin-sdk/manager-B-EITu1a.js +0 -10
- package/dist/plugin-sdk/manager-WCGzgWdf.js +0 -2868
- package/dist/plugin-sdk/model-selection-Bo7pocNu.js +0 -2667
- package/dist/plugin-sdk/paths-BFxmmTT5.js +0 -164
- package/dist/plugin-sdk/paths-Bkjq_KcG.js +0 -40
- package/dist/plugin-sdk/pi-embedded-helpers-fm5_Eokw.js +0 -8755
- package/dist/plugin-sdk/pi-model-discovery-CLgDNnGq.js +0 -13
- package/dist/plugin-sdk/pi-model-discovery-P2-pVRmz.js +0 -3
- package/dist/plugin-sdk/pw-ai-BN7Cwl9J.js +0 -1649
- package/dist/qmd-manager-CzArLjr6.js +0 -615
- package/dist/redact-BR0IM00e.js +0 -94
- package/dist/register.subclis-Bo-xmQ-W.js +0 -342
- package/dist/register.subclis-BuT7ZpPf.js +0 -3
- package/dist/restart-sentinel-CdcBcziq.js +0 -65
- package/dist/restart-sentinel-DywisDen.js +0 -65
- package/dist/runtime-guard-BG6JybtL.js +0 -60
- package/dist/runtime-guard-DvBpNsbR.js +0 -60
- package/dist/sqlite-Dz6S6ijV.js +0 -215
- package/dist/status.update-2ZdxeIeT.js +0 -79
- package/dist/status.update-ChwCPLBt.js +0 -79
- package/dist/systemd-linger-BZb1Uwsd.js +0 -7
- package/dist/systemd-linger-DemNCT5l.js +0 -9
- package/dist/transcript-events-fUhPZcB5.js +0 -17
- package/docs/_config.yml +0 -53
- package/docs/_layouts/default.html +0 -145
- package/docs/assets/docs-chat-widget.js +0 -667
- package/docs/assets/markdown.css +0 -179
- package/docs/assets/terminal.css +0 -473
- package/docs/assets/theme.js +0 -55
- package/extensions/feishu/README.md +0 -47
- /package/dist/{archive-BrH5WBhI.js → archive-D0z3LZDK.js} +0 -0
- /package/dist/{archive-mFgwsll-.js → archive-Dy3Ezb-5.js} +0 -0
- /package/dist/{boolean-CE7i9tBR.js → boolean-BgXe2hyu.js} +0 -0
- /package/dist/{brew-0HRgjHZw.js → brew-CAcErcKz.js} +0 -0
- /package/dist/{brew-Qdppmdlx.js → brew-CcZV0dSS.js} +0 -0
- /package/dist/{cli-utils-CukoNm8O.js → cli-utils-BkRQdAoC.js} +0 -0
- /package/dist/{cli-utils-DFbPmfWB.js → cli-utils-ByANh4Sp.js} +0 -0
- /package/dist/{plugin-sdk/command-format-CFzL448l.js → command-format-CFzL448l.js} +0 -0
- /package/dist/{command-format-BQK1OIvH.js → command-format-ChfKqObn.js} +0 -0
- /package/dist/{command-format-3xiXujG0.js → command-format-ayFsmwwz.js} +0 -0
- /package/dist/{constants-3er_81qc.js → constants-D1op9uGI.js} +0 -0
- /package/dist/{constants-CLUi6T-M.js → constants-HPrOsATF.js} +0 -0
- /package/dist/{exec-BIMFe4XS.js → exec-B8JKbXKW.js} +0 -0
- /package/dist/{format-BnjMmWWT.js → format-B7OjpGnt.js} +0 -0
- /package/dist/{format-hyFOmVZc.js → format-CS7EI0xF.js} +0 -0
- /package/dist/{help-format-af1XWYxC.js → help-format-CfZ94KRN.js} +0 -0
- /package/dist/{helpers-HZ-6iA1e.js → helpers-5yebzF4C.js} +0 -0
- /package/dist/{helpers-uGhPZ_kK.js → helpers-EKm3X92T.js} +0 -0
- /package/dist/{is-main-DD0MG3N8.js → is-main-B6kCyqsv.js} +0 -0
- /package/dist/{is-main-DrJg4t1R.js → is-main-qJ675wPV.js} +0 -0
- /package/dist/{logging-BdnOSVPD.js → logging-BWRYHvLp.js} +0 -0
- /package/dist/{logging-fywhKCmE.js → logging-CfEk_PnX.js} +0 -0
- /package/dist/{openclaw-root-Dean7Fp2.js → openclaw-root-9ILYSmJ9.js} +0 -0
- /package/dist/{openclaw-root-CJKDUIBP.js → openclaw-root-Cvotktkd.js} +0 -0
- /package/dist/{parse-BB0Cqon8.js → parse-BZz5lHzQ.js} +0 -0
- /package/dist/{parse-DLFPuO7w.js → parse-gTOGQPH6.js} +0 -0
- /package/dist/{parse-log-line-B3U8Kflp.js → parse-log-line-C6szvNBZ.js} +0 -0
- /package/dist/{parse-log-line-BmyeB3J2.js → parse-log-line-CARp5QyJ.js} +0 -0
- /package/dist/{parse-timeout-BIB19Upi.js → parse-timeout-CbVKLZ4B.js} +0 -0
- /package/dist/{parse-timeout-CmBmmqZZ.js → parse-timeout-Du-wHHNi.js} +0 -0
- /package/dist/{paths-VslOJiD2.js → paths-B1kfl4h5.js} +0 -0
- /package/dist/{paths-BDd7_JUB.js → paths-scjhy7N2.js} +0 -0
- /package/dist/{progress-Dn3kWpaL.js → progress-Da1ehW-x.js} +0 -0
- /package/dist/{prompt-style-D5D7b3cX.js → prompt-style-Dc0C5HC9.js} +0 -0
- /package/dist/{prompts-CIDznuZR.js → prompts-CXLLIBwP.js} +0 -0
- /package/dist/{prompts-CSlE5VZB.js → prompts-FbZThK8w.js} +0 -0
- /package/dist/{redact-BKh-zp-c.js → redact-B8YiFlwn.js} +0 -0
- /package/dist/{plugin-sdk/redact-wH73ib3-.js → redact-BIMJ3ntQ.js} +0 -0
- /package/dist/{redact-CDPAzwi8.js → redact-DJCFY628.js} +0 -0
- /package/dist/{plugin-sdk/sqlite-CqVsQPIl.js → sqlite-BKl1HJFe.js} +0 -0
- /package/dist/{sqlite-C59YNxdL.js → sqlite-Dnmf3LS7.js} +0 -0
- /package/dist/{sqlite-B_L84oiu.js → sqlite-DqUEZnjO.js} +0 -0
- /package/dist/{status-DkW6wMxZ.js → status-CRIEi8Mc.js} +0 -0
- /package/dist/{status-IDW1pkc0.js → status-tCu4RWZH.js} +0 -0
- /package/dist/{tailnet-BijMqkqa.js → tailnet-Byp3obcc.js} +0 -0
- /package/dist/{tailnet-Bk5cGmwE.js → tailnet-DLDGNuH2.js} +0 -0
- /package/dist/{plugin-sdk/transcript-events-DOI14YeV.js → transcript-events-CZ8CG4ht.js} +0 -0
- /package/dist/{transcript-events-Cj85Mq0h.js → transcript-events-ChU6IQwp.js} +0 -0
- /package/dist/{transcript-events-DW_H__a1.js → transcript-events-JLH5W4He.js} +0 -0
- /package/dist/{utils-PmTbZoD1.js → utils-DX85MiPR.js} +0 -0
- /package/dist/{ws-Cxo2p9fH.js → ws-CEcdsnN9.js} +0 -0
- /package/dist/{ws-DlSkA_BG.js → ws-D091yo4M.js} +0 -0
- /package/docs/{platforms → install}/gcp.md +0 -0
- /package/docs/{platforms → install}/hetzner.md +0 -0
- /package/docs/{platforms → install}/macos-vm.md +0 -0
- /package/docs/{northflank.mdx → install/northflank.mdx} +0 -0
- /package/docs/{railway.mdx → install/railway.mdx} +0 -0
- /package/docs/{render.mdx → install/render.mdx} +0 -0
- /package/docs/zh-CN/{platforms → install}/exe-dev.md +0 -0
- /package/docs/zh-CN/{platforms → install}/fly.md +0 -0
- /package/docs/zh-CN/{platforms → install}/gcp.md +0 -0
- /package/docs/zh-CN/{platforms → install}/hetzner.md +0 -0
- /package/docs/zh-CN/{platforms → install}/macos-vm.md +0 -0
- /package/docs/zh-CN/{northflank.mdx → install/northflank.mdx} +0 -0
- /package/docs/zh-CN/{railway.mdx → install/railway.mdx} +0 -0
- /package/docs/zh-CN/{render.mdx → install/render.mdx} +0 -0
|
@@ -1,1419 +0,0 @@
|
|
|
1
|
-
import { T as shortenHomeInString } from "./exec-CjyVHUuE.js";
|
|
2
|
-
import { t as loadConfig } from "./config-D5CsedNn.js";
|
|
3
|
-
import { D as sanitizeUserFacingText } from "./pi-embedded-helpers-fm5_Eokw.js";
|
|
4
|
-
import { F as resolveOpenClawAgentDir, f as normalizeProviders, g as getApiKeyForModel, h as resolveImplicitProviders, m as resolveImplicitCopilotProvider, p as resolveImplicitBedrockProvider, v as requireApiKey } from "./model-selection-Bo7pocNu.js";
|
|
5
|
-
import { i as discoverModels, r as discoverAuthStorage } from "./pi-model-discovery-CLgDNnGq.js";
|
|
6
|
-
import { n as redactToolDetail } from "./redact-wH73ib3-.js";
|
|
7
|
-
import path from "node:path";
|
|
8
|
-
import fs from "node:fs/promises";
|
|
9
|
-
import { complete } from "@mariozechner/pi-ai";
|
|
10
|
-
|
|
11
|
-
//#region src/agents/minimax-vlm.ts
|
|
12
|
-
function coerceApiHost(params) {
|
|
13
|
-
const env = params.env ?? process.env;
|
|
14
|
-
const raw = params.apiHost?.trim() || env.MINIMAX_API_HOST?.trim() || params.modelBaseUrl?.trim() || "https://api.minimax.io";
|
|
15
|
-
try {
|
|
16
|
-
return new URL(raw).origin;
|
|
17
|
-
} catch {}
|
|
18
|
-
try {
|
|
19
|
-
return new URL(`https://${raw}`).origin;
|
|
20
|
-
} catch {
|
|
21
|
-
return "https://api.minimax.io";
|
|
22
|
-
}
|
|
23
|
-
}
|
|
24
|
-
function isRecord$1(value) {
|
|
25
|
-
return Boolean(value && typeof value === "object" && !Array.isArray(value));
|
|
26
|
-
}
|
|
27
|
-
function pickString(rec, key) {
|
|
28
|
-
const v = rec[key];
|
|
29
|
-
return typeof v === "string" ? v : "";
|
|
30
|
-
}
|
|
31
|
-
async function minimaxUnderstandImage(params) {
|
|
32
|
-
const apiKey = params.apiKey.trim();
|
|
33
|
-
if (!apiKey) throw new Error("MiniMax VLM: apiKey required");
|
|
34
|
-
const prompt = params.prompt.trim();
|
|
35
|
-
if (!prompt) throw new Error("MiniMax VLM: prompt required");
|
|
36
|
-
const imageDataUrl = params.imageDataUrl.trim();
|
|
37
|
-
if (!imageDataUrl) throw new Error("MiniMax VLM: imageDataUrl required");
|
|
38
|
-
if (!/^data:image\/(png|jpeg|webp);base64,/i.test(imageDataUrl)) throw new Error("MiniMax VLM: imageDataUrl must be a base64 data:image/(png|jpeg|webp) URL");
|
|
39
|
-
const host = coerceApiHost({
|
|
40
|
-
apiHost: params.apiHost,
|
|
41
|
-
modelBaseUrl: params.modelBaseUrl
|
|
42
|
-
});
|
|
43
|
-
const url = new URL("/v1/coding_plan/vlm", host).toString();
|
|
44
|
-
const res = await fetch(url, {
|
|
45
|
-
method: "POST",
|
|
46
|
-
headers: {
|
|
47
|
-
Authorization: `Bearer ${apiKey}`,
|
|
48
|
-
"Content-Type": "application/json",
|
|
49
|
-
"MM-API-Source": "OpenClaw"
|
|
50
|
-
},
|
|
51
|
-
body: JSON.stringify({
|
|
52
|
-
prompt,
|
|
53
|
-
image_url: imageDataUrl
|
|
54
|
-
})
|
|
55
|
-
});
|
|
56
|
-
const traceId = res.headers.get("Trace-Id") ?? "";
|
|
57
|
-
if (!res.ok) {
|
|
58
|
-
const body = await res.text().catch(() => "");
|
|
59
|
-
const trace = traceId ? ` Trace-Id: ${traceId}` : "";
|
|
60
|
-
throw new Error(`MiniMax VLM request failed (${res.status} ${res.statusText}).${trace}${body ? ` Body: ${body.slice(0, 400)}` : ""}`);
|
|
61
|
-
}
|
|
62
|
-
const json = await res.json().catch(() => null);
|
|
63
|
-
if (!isRecord$1(json)) {
|
|
64
|
-
const trace = traceId ? ` Trace-Id: ${traceId}` : "";
|
|
65
|
-
throw new Error(`MiniMax VLM response was not JSON.${trace}`);
|
|
66
|
-
}
|
|
67
|
-
const baseResp = isRecord$1(json.base_resp) ? json.base_resp : {};
|
|
68
|
-
const code = typeof baseResp.status_code === "number" ? baseResp.status_code : -1;
|
|
69
|
-
if (code !== 0) {
|
|
70
|
-
const msg = (baseResp.status_msg ?? "").trim();
|
|
71
|
-
const trace = traceId ? ` Trace-Id: ${traceId}` : "";
|
|
72
|
-
throw new Error(`MiniMax VLM API error (${code})${msg ? `: ${msg}` : ""}.${trace}`);
|
|
73
|
-
}
|
|
74
|
-
const content = pickString(json, "content").trim();
|
|
75
|
-
if (!content) {
|
|
76
|
-
const trace = traceId ? ` Trace-Id: ${traceId}` : "";
|
|
77
|
-
throw new Error(`MiniMax VLM returned no content.${trace}`);
|
|
78
|
-
}
|
|
79
|
-
return content;
|
|
80
|
-
}
|
|
81
|
-
|
|
82
|
-
//#endregion
|
|
83
|
-
//#region src/agents/models-config.ts
|
|
84
|
-
const DEFAULT_MODE = "merge";
|
|
85
|
-
function isRecord(value) {
|
|
86
|
-
return Boolean(value && typeof value === "object" && !Array.isArray(value));
|
|
87
|
-
}
|
|
88
|
-
function mergeProviderModels(implicit, explicit) {
|
|
89
|
-
const implicitModels = Array.isArray(implicit.models) ? implicit.models : [];
|
|
90
|
-
const explicitModels = Array.isArray(explicit.models) ? explicit.models : [];
|
|
91
|
-
if (implicitModels.length === 0) return {
|
|
92
|
-
...implicit,
|
|
93
|
-
...explicit
|
|
94
|
-
};
|
|
95
|
-
const getId = (model) => {
|
|
96
|
-
if (!model || typeof model !== "object") return "";
|
|
97
|
-
const id = model.id;
|
|
98
|
-
return typeof id === "string" ? id.trim() : "";
|
|
99
|
-
};
|
|
100
|
-
const seen = new Set(explicitModels.map(getId).filter(Boolean));
|
|
101
|
-
const mergedModels = [...explicitModels, ...implicitModels.filter((model) => {
|
|
102
|
-
const id = getId(model);
|
|
103
|
-
if (!id) return false;
|
|
104
|
-
if (seen.has(id)) return false;
|
|
105
|
-
seen.add(id);
|
|
106
|
-
return true;
|
|
107
|
-
})];
|
|
108
|
-
return {
|
|
109
|
-
...implicit,
|
|
110
|
-
...explicit,
|
|
111
|
-
models: mergedModels
|
|
112
|
-
};
|
|
113
|
-
}
|
|
114
|
-
function mergeProviders(params) {
|
|
115
|
-
const out = params.implicit ? { ...params.implicit } : {};
|
|
116
|
-
for (const [key, explicit] of Object.entries(params.explicit ?? {})) {
|
|
117
|
-
const providerKey = key.trim();
|
|
118
|
-
if (!providerKey) continue;
|
|
119
|
-
const implicit = out[providerKey];
|
|
120
|
-
out[providerKey] = implicit ? mergeProviderModels(implicit, explicit) : explicit;
|
|
121
|
-
}
|
|
122
|
-
return out;
|
|
123
|
-
}
|
|
124
|
-
async function readJson(pathname) {
|
|
125
|
-
try {
|
|
126
|
-
const raw = await fs.readFile(pathname, "utf8");
|
|
127
|
-
return JSON.parse(raw);
|
|
128
|
-
} catch {
|
|
129
|
-
return null;
|
|
130
|
-
}
|
|
131
|
-
}
|
|
132
|
-
async function ensureOpenClawModelsJson(config, agentDirOverride) {
|
|
133
|
-
const cfg = config ?? loadConfig();
|
|
134
|
-
const agentDir = agentDirOverride?.trim() ? agentDirOverride.trim() : resolveOpenClawAgentDir();
|
|
135
|
-
const explicitProviders = cfg.models?.providers ?? {};
|
|
136
|
-
const providers = mergeProviders({
|
|
137
|
-
implicit: await resolveImplicitProviders({ agentDir }),
|
|
138
|
-
explicit: explicitProviders
|
|
139
|
-
});
|
|
140
|
-
const implicitBedrock = await resolveImplicitBedrockProvider({
|
|
141
|
-
agentDir,
|
|
142
|
-
config: cfg
|
|
143
|
-
});
|
|
144
|
-
if (implicitBedrock) {
|
|
145
|
-
const existing = providers["amazon-bedrock"];
|
|
146
|
-
providers["amazon-bedrock"] = existing ? mergeProviderModels(implicitBedrock, existing) : implicitBedrock;
|
|
147
|
-
}
|
|
148
|
-
const implicitCopilot = await resolveImplicitCopilotProvider({ agentDir });
|
|
149
|
-
if (implicitCopilot && !providers["github-copilot"]) providers["github-copilot"] = implicitCopilot;
|
|
150
|
-
if (Object.keys(providers).length === 0) return {
|
|
151
|
-
agentDir,
|
|
152
|
-
wrote: false
|
|
153
|
-
};
|
|
154
|
-
const mode = cfg.models?.mode ?? DEFAULT_MODE;
|
|
155
|
-
const targetPath = path.join(agentDir, "models.json");
|
|
156
|
-
let mergedProviders = providers;
|
|
157
|
-
let existingRaw = "";
|
|
158
|
-
if (mode === "merge") {
|
|
159
|
-
const existing = await readJson(targetPath);
|
|
160
|
-
if (isRecord(existing) && isRecord(existing.providers)) mergedProviders = {
|
|
161
|
-
...existing.providers,
|
|
162
|
-
...providers
|
|
163
|
-
};
|
|
164
|
-
}
|
|
165
|
-
const normalizedProviders = normalizeProviders({
|
|
166
|
-
providers: mergedProviders,
|
|
167
|
-
agentDir
|
|
168
|
-
});
|
|
169
|
-
const next = `${JSON.stringify({ providers: normalizedProviders }, null, 2)}\n`;
|
|
170
|
-
try {
|
|
171
|
-
existingRaw = await fs.readFile(targetPath, "utf8");
|
|
172
|
-
} catch {
|
|
173
|
-
existingRaw = "";
|
|
174
|
-
}
|
|
175
|
-
if (existingRaw === next) return {
|
|
176
|
-
agentDir,
|
|
177
|
-
wrote: false
|
|
178
|
-
};
|
|
179
|
-
await fs.mkdir(agentDir, {
|
|
180
|
-
recursive: true,
|
|
181
|
-
mode: 448
|
|
182
|
-
});
|
|
183
|
-
await fs.writeFile(targetPath, next, { mode: 384 });
|
|
184
|
-
return {
|
|
185
|
-
agentDir,
|
|
186
|
-
wrote: true
|
|
187
|
-
};
|
|
188
|
-
}
|
|
189
|
-
|
|
190
|
-
//#endregion
|
|
191
|
-
//#region src/shared/text/reasoning-tags.ts
|
|
192
|
-
const QUICK_TAG_RE = /<\s*\/?\s*(?:think(?:ing)?|thought|antthinking|final)\b/i;
|
|
193
|
-
const FINAL_TAG_RE = /<\s*\/?\s*final\b[^<>]*>/gi;
|
|
194
|
-
const THINKING_TAG_RE = /<\s*(\/?)\s*(?:think(?:ing)?|thought|antthinking)\b[^<>]*>/gi;
|
|
195
|
-
function findCodeRegions(text) {
|
|
196
|
-
const regions = [];
|
|
197
|
-
for (const match of text.matchAll(/(^|\n)(```|~~~)[^\n]*\n[\s\S]*?(?:\n\2(?:\n|$)|$)/g)) {
|
|
198
|
-
const start = (match.index ?? 0) + match[1].length;
|
|
199
|
-
regions.push({
|
|
200
|
-
start,
|
|
201
|
-
end: start + match[0].length - match[1].length
|
|
202
|
-
});
|
|
203
|
-
}
|
|
204
|
-
for (const match of text.matchAll(/`+[^`]+`+/g)) {
|
|
205
|
-
const start = match.index ?? 0;
|
|
206
|
-
const end = start + match[0].length;
|
|
207
|
-
if (!regions.some((r) => start >= r.start && end <= r.end)) regions.push({
|
|
208
|
-
start,
|
|
209
|
-
end
|
|
210
|
-
});
|
|
211
|
-
}
|
|
212
|
-
regions.sort((a, b) => a.start - b.start);
|
|
213
|
-
return regions;
|
|
214
|
-
}
|
|
215
|
-
function isInsideCode(pos, regions) {
|
|
216
|
-
return regions.some((r) => pos >= r.start && pos < r.end);
|
|
217
|
-
}
|
|
218
|
-
function applyTrim(value, mode) {
|
|
219
|
-
if (mode === "none") return value;
|
|
220
|
-
if (mode === "start") return value.trimStart();
|
|
221
|
-
return value.trim();
|
|
222
|
-
}
|
|
223
|
-
function stripReasoningTagsFromText(text, options) {
|
|
224
|
-
if (!text) return text;
|
|
225
|
-
if (!QUICK_TAG_RE.test(text)) return text;
|
|
226
|
-
const mode = options?.mode ?? "strict";
|
|
227
|
-
const trimMode = options?.trim ?? "both";
|
|
228
|
-
let cleaned = text;
|
|
229
|
-
if (FINAL_TAG_RE.test(cleaned)) {
|
|
230
|
-
FINAL_TAG_RE.lastIndex = 0;
|
|
231
|
-
const finalMatches = [];
|
|
232
|
-
const preCodeRegions = findCodeRegions(cleaned);
|
|
233
|
-
for (const match of cleaned.matchAll(FINAL_TAG_RE)) {
|
|
234
|
-
const start = match.index ?? 0;
|
|
235
|
-
finalMatches.push({
|
|
236
|
-
start,
|
|
237
|
-
length: match[0].length,
|
|
238
|
-
inCode: isInsideCode(start, preCodeRegions)
|
|
239
|
-
});
|
|
240
|
-
}
|
|
241
|
-
for (let i = finalMatches.length - 1; i >= 0; i--) {
|
|
242
|
-
const m = finalMatches[i];
|
|
243
|
-
if (!m.inCode) cleaned = cleaned.slice(0, m.start) + cleaned.slice(m.start + m.length);
|
|
244
|
-
}
|
|
245
|
-
} else FINAL_TAG_RE.lastIndex = 0;
|
|
246
|
-
const codeRegions = findCodeRegions(cleaned);
|
|
247
|
-
THINKING_TAG_RE.lastIndex = 0;
|
|
248
|
-
let result = "";
|
|
249
|
-
let lastIndex = 0;
|
|
250
|
-
let inThinking = false;
|
|
251
|
-
for (const match of cleaned.matchAll(THINKING_TAG_RE)) {
|
|
252
|
-
const idx = match.index ?? 0;
|
|
253
|
-
const isClose = match[1] === "/";
|
|
254
|
-
if (isInsideCode(idx, codeRegions)) continue;
|
|
255
|
-
if (!inThinking) {
|
|
256
|
-
result += cleaned.slice(lastIndex, idx);
|
|
257
|
-
if (!isClose) inThinking = true;
|
|
258
|
-
} else if (isClose) inThinking = false;
|
|
259
|
-
lastIndex = idx + match[0].length;
|
|
260
|
-
}
|
|
261
|
-
if (!inThinking || mode === "preserve") result += cleaned.slice(lastIndex);
|
|
262
|
-
return applyTrim(result, trimMode);
|
|
263
|
-
}
|
|
264
|
-
|
|
265
|
-
//#endregion
|
|
266
|
-
//#region src/agents/tool-display.json
|
|
267
|
-
var tool_display_default = {
|
|
268
|
-
version: 1,
|
|
269
|
-
fallback: {
|
|
270
|
-
"emoji": "🧩",
|
|
271
|
-
"detailKeys": [
|
|
272
|
-
"command",
|
|
273
|
-
"path",
|
|
274
|
-
"url",
|
|
275
|
-
"targetUrl",
|
|
276
|
-
"targetId",
|
|
277
|
-
"ref",
|
|
278
|
-
"element",
|
|
279
|
-
"node",
|
|
280
|
-
"nodeId",
|
|
281
|
-
"id",
|
|
282
|
-
"requestId",
|
|
283
|
-
"to",
|
|
284
|
-
"channelId",
|
|
285
|
-
"guildId",
|
|
286
|
-
"userId",
|
|
287
|
-
"name",
|
|
288
|
-
"query",
|
|
289
|
-
"pattern",
|
|
290
|
-
"messageId"
|
|
291
|
-
]
|
|
292
|
-
},
|
|
293
|
-
tools: {
|
|
294
|
-
"exec": {
|
|
295
|
-
"emoji": "🛠️",
|
|
296
|
-
"title": "Exec",
|
|
297
|
-
"detailKeys": ["command"]
|
|
298
|
-
},
|
|
299
|
-
"process": {
|
|
300
|
-
"emoji": "🧰",
|
|
301
|
-
"title": "Process",
|
|
302
|
-
"detailKeys": ["sessionId"]
|
|
303
|
-
},
|
|
304
|
-
"read": {
|
|
305
|
-
"emoji": "📖",
|
|
306
|
-
"title": "Read",
|
|
307
|
-
"detailKeys": ["path"]
|
|
308
|
-
},
|
|
309
|
-
"write": {
|
|
310
|
-
"emoji": "✍️",
|
|
311
|
-
"title": "Write",
|
|
312
|
-
"detailKeys": ["path"]
|
|
313
|
-
},
|
|
314
|
-
"edit": {
|
|
315
|
-
"emoji": "📝",
|
|
316
|
-
"title": "Edit",
|
|
317
|
-
"detailKeys": ["path"]
|
|
318
|
-
},
|
|
319
|
-
"apply_patch": {
|
|
320
|
-
"emoji": "🩹",
|
|
321
|
-
"title": "Apply Patch",
|
|
322
|
-
"detailKeys": []
|
|
323
|
-
},
|
|
324
|
-
"attach": {
|
|
325
|
-
"emoji": "📎",
|
|
326
|
-
"title": "Attach",
|
|
327
|
-
"detailKeys": [
|
|
328
|
-
"path",
|
|
329
|
-
"url",
|
|
330
|
-
"fileName"
|
|
331
|
-
]
|
|
332
|
-
},
|
|
333
|
-
"browser": {
|
|
334
|
-
"emoji": "🌐",
|
|
335
|
-
"title": "Browser",
|
|
336
|
-
"actions": {
|
|
337
|
-
"status": { "label": "status" },
|
|
338
|
-
"start": { "label": "start" },
|
|
339
|
-
"stop": { "label": "stop" },
|
|
340
|
-
"tabs": { "label": "tabs" },
|
|
341
|
-
"open": {
|
|
342
|
-
"label": "open",
|
|
343
|
-
"detailKeys": ["targetUrl"]
|
|
344
|
-
},
|
|
345
|
-
"focus": {
|
|
346
|
-
"label": "focus",
|
|
347
|
-
"detailKeys": ["targetId"]
|
|
348
|
-
},
|
|
349
|
-
"close": {
|
|
350
|
-
"label": "close",
|
|
351
|
-
"detailKeys": ["targetId"]
|
|
352
|
-
},
|
|
353
|
-
"snapshot": {
|
|
354
|
-
"label": "snapshot",
|
|
355
|
-
"detailKeys": [
|
|
356
|
-
"targetUrl",
|
|
357
|
-
"targetId",
|
|
358
|
-
"ref",
|
|
359
|
-
"element",
|
|
360
|
-
"format"
|
|
361
|
-
]
|
|
362
|
-
},
|
|
363
|
-
"screenshot": {
|
|
364
|
-
"label": "screenshot",
|
|
365
|
-
"detailKeys": [
|
|
366
|
-
"targetUrl",
|
|
367
|
-
"targetId",
|
|
368
|
-
"ref",
|
|
369
|
-
"element"
|
|
370
|
-
]
|
|
371
|
-
},
|
|
372
|
-
"navigate": {
|
|
373
|
-
"label": "navigate",
|
|
374
|
-
"detailKeys": ["targetUrl", "targetId"]
|
|
375
|
-
},
|
|
376
|
-
"console": {
|
|
377
|
-
"label": "console",
|
|
378
|
-
"detailKeys": ["level", "targetId"]
|
|
379
|
-
},
|
|
380
|
-
"pdf": {
|
|
381
|
-
"label": "pdf",
|
|
382
|
-
"detailKeys": ["targetId"]
|
|
383
|
-
},
|
|
384
|
-
"upload": {
|
|
385
|
-
"label": "upload",
|
|
386
|
-
"detailKeys": [
|
|
387
|
-
"paths",
|
|
388
|
-
"ref",
|
|
389
|
-
"inputRef",
|
|
390
|
-
"element",
|
|
391
|
-
"targetId"
|
|
392
|
-
]
|
|
393
|
-
},
|
|
394
|
-
"dialog": {
|
|
395
|
-
"label": "dialog",
|
|
396
|
-
"detailKeys": [
|
|
397
|
-
"accept",
|
|
398
|
-
"promptText",
|
|
399
|
-
"targetId"
|
|
400
|
-
]
|
|
401
|
-
},
|
|
402
|
-
"act": {
|
|
403
|
-
"label": "act",
|
|
404
|
-
"detailKeys": [
|
|
405
|
-
"request.kind",
|
|
406
|
-
"request.ref",
|
|
407
|
-
"request.selector",
|
|
408
|
-
"request.text",
|
|
409
|
-
"request.value"
|
|
410
|
-
]
|
|
411
|
-
}
|
|
412
|
-
}
|
|
413
|
-
},
|
|
414
|
-
"canvas": {
|
|
415
|
-
"emoji": "🖼️",
|
|
416
|
-
"title": "Canvas",
|
|
417
|
-
"actions": {
|
|
418
|
-
"present": {
|
|
419
|
-
"label": "present",
|
|
420
|
-
"detailKeys": [
|
|
421
|
-
"target",
|
|
422
|
-
"node",
|
|
423
|
-
"nodeId"
|
|
424
|
-
]
|
|
425
|
-
},
|
|
426
|
-
"hide": {
|
|
427
|
-
"label": "hide",
|
|
428
|
-
"detailKeys": ["node", "nodeId"]
|
|
429
|
-
},
|
|
430
|
-
"navigate": {
|
|
431
|
-
"label": "navigate",
|
|
432
|
-
"detailKeys": [
|
|
433
|
-
"url",
|
|
434
|
-
"node",
|
|
435
|
-
"nodeId"
|
|
436
|
-
]
|
|
437
|
-
},
|
|
438
|
-
"eval": {
|
|
439
|
-
"label": "eval",
|
|
440
|
-
"detailKeys": [
|
|
441
|
-
"javaScript",
|
|
442
|
-
"node",
|
|
443
|
-
"nodeId"
|
|
444
|
-
]
|
|
445
|
-
},
|
|
446
|
-
"snapshot": {
|
|
447
|
-
"label": "snapshot",
|
|
448
|
-
"detailKeys": [
|
|
449
|
-
"format",
|
|
450
|
-
"node",
|
|
451
|
-
"nodeId"
|
|
452
|
-
]
|
|
453
|
-
},
|
|
454
|
-
"a2ui_push": {
|
|
455
|
-
"label": "A2UI push",
|
|
456
|
-
"detailKeys": [
|
|
457
|
-
"jsonlPath",
|
|
458
|
-
"node",
|
|
459
|
-
"nodeId"
|
|
460
|
-
]
|
|
461
|
-
},
|
|
462
|
-
"a2ui_reset": {
|
|
463
|
-
"label": "A2UI reset",
|
|
464
|
-
"detailKeys": ["node", "nodeId"]
|
|
465
|
-
}
|
|
466
|
-
}
|
|
467
|
-
},
|
|
468
|
-
"nodes": {
|
|
469
|
-
"emoji": "📱",
|
|
470
|
-
"title": "Nodes",
|
|
471
|
-
"actions": {
|
|
472
|
-
"status": { "label": "status" },
|
|
473
|
-
"describe": {
|
|
474
|
-
"label": "describe",
|
|
475
|
-
"detailKeys": ["node", "nodeId"]
|
|
476
|
-
},
|
|
477
|
-
"pending": { "label": "pending" },
|
|
478
|
-
"approve": {
|
|
479
|
-
"label": "approve",
|
|
480
|
-
"detailKeys": ["requestId"]
|
|
481
|
-
},
|
|
482
|
-
"reject": {
|
|
483
|
-
"label": "reject",
|
|
484
|
-
"detailKeys": ["requestId"]
|
|
485
|
-
},
|
|
486
|
-
"notify": {
|
|
487
|
-
"label": "notify",
|
|
488
|
-
"detailKeys": [
|
|
489
|
-
"node",
|
|
490
|
-
"nodeId",
|
|
491
|
-
"title",
|
|
492
|
-
"body"
|
|
493
|
-
]
|
|
494
|
-
},
|
|
495
|
-
"camera_snap": {
|
|
496
|
-
"label": "camera snap",
|
|
497
|
-
"detailKeys": [
|
|
498
|
-
"node",
|
|
499
|
-
"nodeId",
|
|
500
|
-
"facing",
|
|
501
|
-
"deviceId"
|
|
502
|
-
]
|
|
503
|
-
},
|
|
504
|
-
"camera_list": {
|
|
505
|
-
"label": "camera list",
|
|
506
|
-
"detailKeys": ["node", "nodeId"]
|
|
507
|
-
},
|
|
508
|
-
"camera_clip": {
|
|
509
|
-
"label": "camera clip",
|
|
510
|
-
"detailKeys": [
|
|
511
|
-
"node",
|
|
512
|
-
"nodeId",
|
|
513
|
-
"facing",
|
|
514
|
-
"duration",
|
|
515
|
-
"durationMs"
|
|
516
|
-
]
|
|
517
|
-
},
|
|
518
|
-
"screen_record": {
|
|
519
|
-
"label": "screen record",
|
|
520
|
-
"detailKeys": [
|
|
521
|
-
"node",
|
|
522
|
-
"nodeId",
|
|
523
|
-
"duration",
|
|
524
|
-
"durationMs",
|
|
525
|
-
"fps",
|
|
526
|
-
"screenIndex"
|
|
527
|
-
]
|
|
528
|
-
}
|
|
529
|
-
}
|
|
530
|
-
},
|
|
531
|
-
"cron": {
|
|
532
|
-
"emoji": "⏰",
|
|
533
|
-
"title": "Cron",
|
|
534
|
-
"actions": {
|
|
535
|
-
"status": { "label": "status" },
|
|
536
|
-
"list": { "label": "list" },
|
|
537
|
-
"add": {
|
|
538
|
-
"label": "add",
|
|
539
|
-
"detailKeys": [
|
|
540
|
-
"job.name",
|
|
541
|
-
"job.id",
|
|
542
|
-
"job.schedule",
|
|
543
|
-
"job.cron"
|
|
544
|
-
]
|
|
545
|
-
},
|
|
546
|
-
"update": {
|
|
547
|
-
"label": "update",
|
|
548
|
-
"detailKeys": ["id"]
|
|
549
|
-
},
|
|
550
|
-
"remove": {
|
|
551
|
-
"label": "remove",
|
|
552
|
-
"detailKeys": ["id"]
|
|
553
|
-
},
|
|
554
|
-
"run": {
|
|
555
|
-
"label": "run",
|
|
556
|
-
"detailKeys": ["id"]
|
|
557
|
-
},
|
|
558
|
-
"runs": {
|
|
559
|
-
"label": "runs",
|
|
560
|
-
"detailKeys": ["id"]
|
|
561
|
-
},
|
|
562
|
-
"wake": {
|
|
563
|
-
"label": "wake",
|
|
564
|
-
"detailKeys": ["text", "mode"]
|
|
565
|
-
}
|
|
566
|
-
}
|
|
567
|
-
},
|
|
568
|
-
"gateway": {
|
|
569
|
-
"emoji": "🔌",
|
|
570
|
-
"title": "Gateway",
|
|
571
|
-
"actions": { "restart": {
|
|
572
|
-
"label": "restart",
|
|
573
|
-
"detailKeys": ["reason", "delayMs"]
|
|
574
|
-
} }
|
|
575
|
-
},
|
|
576
|
-
"message": {
|
|
577
|
-
"emoji": "✉️",
|
|
578
|
-
"title": "Message",
|
|
579
|
-
"actions": {
|
|
580
|
-
"send": {
|
|
581
|
-
"label": "send",
|
|
582
|
-
"detailKeys": [
|
|
583
|
-
"provider",
|
|
584
|
-
"to",
|
|
585
|
-
"media",
|
|
586
|
-
"replyTo",
|
|
587
|
-
"threadId"
|
|
588
|
-
]
|
|
589
|
-
},
|
|
590
|
-
"poll": {
|
|
591
|
-
"label": "poll",
|
|
592
|
-
"detailKeys": [
|
|
593
|
-
"provider",
|
|
594
|
-
"to",
|
|
595
|
-
"pollQuestion"
|
|
596
|
-
]
|
|
597
|
-
},
|
|
598
|
-
"react": {
|
|
599
|
-
"label": "react",
|
|
600
|
-
"detailKeys": [
|
|
601
|
-
"provider",
|
|
602
|
-
"to",
|
|
603
|
-
"messageId",
|
|
604
|
-
"emoji",
|
|
605
|
-
"remove"
|
|
606
|
-
]
|
|
607
|
-
},
|
|
608
|
-
"reactions": {
|
|
609
|
-
"label": "reactions",
|
|
610
|
-
"detailKeys": [
|
|
611
|
-
"provider",
|
|
612
|
-
"to",
|
|
613
|
-
"messageId",
|
|
614
|
-
"limit"
|
|
615
|
-
]
|
|
616
|
-
},
|
|
617
|
-
"read": {
|
|
618
|
-
"label": "read",
|
|
619
|
-
"detailKeys": [
|
|
620
|
-
"provider",
|
|
621
|
-
"to",
|
|
622
|
-
"limit"
|
|
623
|
-
]
|
|
624
|
-
},
|
|
625
|
-
"edit": {
|
|
626
|
-
"label": "edit",
|
|
627
|
-
"detailKeys": [
|
|
628
|
-
"provider",
|
|
629
|
-
"to",
|
|
630
|
-
"messageId"
|
|
631
|
-
]
|
|
632
|
-
},
|
|
633
|
-
"delete": {
|
|
634
|
-
"label": "delete",
|
|
635
|
-
"detailKeys": [
|
|
636
|
-
"provider",
|
|
637
|
-
"to",
|
|
638
|
-
"messageId"
|
|
639
|
-
]
|
|
640
|
-
},
|
|
641
|
-
"pin": {
|
|
642
|
-
"label": "pin",
|
|
643
|
-
"detailKeys": [
|
|
644
|
-
"provider",
|
|
645
|
-
"to",
|
|
646
|
-
"messageId"
|
|
647
|
-
]
|
|
648
|
-
},
|
|
649
|
-
"unpin": {
|
|
650
|
-
"label": "unpin",
|
|
651
|
-
"detailKeys": [
|
|
652
|
-
"provider",
|
|
653
|
-
"to",
|
|
654
|
-
"messageId"
|
|
655
|
-
]
|
|
656
|
-
},
|
|
657
|
-
"list-pins": {
|
|
658
|
-
"label": "list pins",
|
|
659
|
-
"detailKeys": ["provider", "to"]
|
|
660
|
-
},
|
|
661
|
-
"permissions": {
|
|
662
|
-
"label": "permissions",
|
|
663
|
-
"detailKeys": [
|
|
664
|
-
"provider",
|
|
665
|
-
"channelId",
|
|
666
|
-
"to"
|
|
667
|
-
]
|
|
668
|
-
},
|
|
669
|
-
"thread-create": {
|
|
670
|
-
"label": "thread create",
|
|
671
|
-
"detailKeys": [
|
|
672
|
-
"provider",
|
|
673
|
-
"channelId",
|
|
674
|
-
"threadName"
|
|
675
|
-
]
|
|
676
|
-
},
|
|
677
|
-
"thread-list": {
|
|
678
|
-
"label": "thread list",
|
|
679
|
-
"detailKeys": [
|
|
680
|
-
"provider",
|
|
681
|
-
"guildId",
|
|
682
|
-
"channelId"
|
|
683
|
-
]
|
|
684
|
-
},
|
|
685
|
-
"thread-reply": {
|
|
686
|
-
"label": "thread reply",
|
|
687
|
-
"detailKeys": [
|
|
688
|
-
"provider",
|
|
689
|
-
"channelId",
|
|
690
|
-
"messageId"
|
|
691
|
-
]
|
|
692
|
-
},
|
|
693
|
-
"search": {
|
|
694
|
-
"label": "search",
|
|
695
|
-
"detailKeys": [
|
|
696
|
-
"provider",
|
|
697
|
-
"guildId",
|
|
698
|
-
"query"
|
|
699
|
-
]
|
|
700
|
-
},
|
|
701
|
-
"sticker": {
|
|
702
|
-
"label": "sticker",
|
|
703
|
-
"detailKeys": [
|
|
704
|
-
"provider",
|
|
705
|
-
"to",
|
|
706
|
-
"stickerId"
|
|
707
|
-
]
|
|
708
|
-
},
|
|
709
|
-
"member-info": {
|
|
710
|
-
"label": "member",
|
|
711
|
-
"detailKeys": [
|
|
712
|
-
"provider",
|
|
713
|
-
"guildId",
|
|
714
|
-
"userId"
|
|
715
|
-
]
|
|
716
|
-
},
|
|
717
|
-
"role-info": {
|
|
718
|
-
"label": "roles",
|
|
719
|
-
"detailKeys": ["provider", "guildId"]
|
|
720
|
-
},
|
|
721
|
-
"emoji-list": {
|
|
722
|
-
"label": "emoji list",
|
|
723
|
-
"detailKeys": ["provider", "guildId"]
|
|
724
|
-
},
|
|
725
|
-
"emoji-upload": {
|
|
726
|
-
"label": "emoji upload",
|
|
727
|
-
"detailKeys": [
|
|
728
|
-
"provider",
|
|
729
|
-
"guildId",
|
|
730
|
-
"emojiName"
|
|
731
|
-
]
|
|
732
|
-
},
|
|
733
|
-
"sticker-upload": {
|
|
734
|
-
"label": "sticker upload",
|
|
735
|
-
"detailKeys": [
|
|
736
|
-
"provider",
|
|
737
|
-
"guildId",
|
|
738
|
-
"stickerName"
|
|
739
|
-
]
|
|
740
|
-
},
|
|
741
|
-
"role-add": {
|
|
742
|
-
"label": "role add",
|
|
743
|
-
"detailKeys": [
|
|
744
|
-
"provider",
|
|
745
|
-
"guildId",
|
|
746
|
-
"userId",
|
|
747
|
-
"roleId"
|
|
748
|
-
]
|
|
749
|
-
},
|
|
750
|
-
"role-remove": {
|
|
751
|
-
"label": "role remove",
|
|
752
|
-
"detailKeys": [
|
|
753
|
-
"provider",
|
|
754
|
-
"guildId",
|
|
755
|
-
"userId",
|
|
756
|
-
"roleId"
|
|
757
|
-
]
|
|
758
|
-
},
|
|
759
|
-
"channel-info": {
|
|
760
|
-
"label": "channel",
|
|
761
|
-
"detailKeys": ["provider", "channelId"]
|
|
762
|
-
},
|
|
763
|
-
"channel-list": {
|
|
764
|
-
"label": "channels",
|
|
765
|
-
"detailKeys": ["provider", "guildId"]
|
|
766
|
-
},
|
|
767
|
-
"voice-status": {
|
|
768
|
-
"label": "voice",
|
|
769
|
-
"detailKeys": [
|
|
770
|
-
"provider",
|
|
771
|
-
"guildId",
|
|
772
|
-
"userId"
|
|
773
|
-
]
|
|
774
|
-
},
|
|
775
|
-
"event-list": {
|
|
776
|
-
"label": "events",
|
|
777
|
-
"detailKeys": ["provider", "guildId"]
|
|
778
|
-
},
|
|
779
|
-
"event-create": {
|
|
780
|
-
"label": "event create",
|
|
781
|
-
"detailKeys": [
|
|
782
|
-
"provider",
|
|
783
|
-
"guildId",
|
|
784
|
-
"eventName"
|
|
785
|
-
]
|
|
786
|
-
},
|
|
787
|
-
"timeout": {
|
|
788
|
-
"label": "timeout",
|
|
789
|
-
"detailKeys": [
|
|
790
|
-
"provider",
|
|
791
|
-
"guildId",
|
|
792
|
-
"userId"
|
|
793
|
-
]
|
|
794
|
-
},
|
|
795
|
-
"kick": {
|
|
796
|
-
"label": "kick",
|
|
797
|
-
"detailKeys": [
|
|
798
|
-
"provider",
|
|
799
|
-
"guildId",
|
|
800
|
-
"userId"
|
|
801
|
-
]
|
|
802
|
-
},
|
|
803
|
-
"ban": {
|
|
804
|
-
"label": "ban",
|
|
805
|
-
"detailKeys": [
|
|
806
|
-
"provider",
|
|
807
|
-
"guildId",
|
|
808
|
-
"userId"
|
|
809
|
-
]
|
|
810
|
-
}
|
|
811
|
-
}
|
|
812
|
-
},
|
|
813
|
-
"agents_list": {
|
|
814
|
-
"emoji": "🧭",
|
|
815
|
-
"title": "Agents",
|
|
816
|
-
"detailKeys": []
|
|
817
|
-
},
|
|
818
|
-
"sessions_list": {
|
|
819
|
-
"emoji": "🗂️",
|
|
820
|
-
"title": "Sessions",
|
|
821
|
-
"detailKeys": [
|
|
822
|
-
"kinds",
|
|
823
|
-
"limit",
|
|
824
|
-
"activeMinutes",
|
|
825
|
-
"messageLimit"
|
|
826
|
-
]
|
|
827
|
-
},
|
|
828
|
-
"sessions_history": {
|
|
829
|
-
"emoji": "🧾",
|
|
830
|
-
"title": "Session History",
|
|
831
|
-
"detailKeys": [
|
|
832
|
-
"sessionKey",
|
|
833
|
-
"limit",
|
|
834
|
-
"includeTools"
|
|
835
|
-
]
|
|
836
|
-
},
|
|
837
|
-
"sessions_send": {
|
|
838
|
-
"emoji": "📨",
|
|
839
|
-
"title": "Session Send",
|
|
840
|
-
"detailKeys": [
|
|
841
|
-
"label",
|
|
842
|
-
"sessionKey",
|
|
843
|
-
"agentId",
|
|
844
|
-
"timeoutSeconds"
|
|
845
|
-
]
|
|
846
|
-
},
|
|
847
|
-
"sessions_spawn": {
|
|
848
|
-
"emoji": "🧑🔧",
|
|
849
|
-
"title": "Sub-agent",
|
|
850
|
-
"detailKeys": [
|
|
851
|
-
"label",
|
|
852
|
-
"task",
|
|
853
|
-
"agentId",
|
|
854
|
-
"model",
|
|
855
|
-
"thinking",
|
|
856
|
-
"runTimeoutSeconds",
|
|
857
|
-
"cleanup",
|
|
858
|
-
"timeoutSeconds"
|
|
859
|
-
]
|
|
860
|
-
},
|
|
861
|
-
"session_status": {
|
|
862
|
-
"emoji": "📊",
|
|
863
|
-
"title": "Session Status",
|
|
864
|
-
"detailKeys": ["sessionKey", "model"]
|
|
865
|
-
},
|
|
866
|
-
"memory_search": {
|
|
867
|
-
"emoji": "🧠",
|
|
868
|
-
"title": "Memory Search",
|
|
869
|
-
"detailKeys": ["query"]
|
|
870
|
-
},
|
|
871
|
-
"memory_get": {
|
|
872
|
-
"emoji": "📓",
|
|
873
|
-
"title": "Memory Get",
|
|
874
|
-
"detailKeys": [
|
|
875
|
-
"path",
|
|
876
|
-
"from",
|
|
877
|
-
"lines"
|
|
878
|
-
]
|
|
879
|
-
},
|
|
880
|
-
"web_search": {
|
|
881
|
-
"emoji": "🔎",
|
|
882
|
-
"title": "Web Search",
|
|
883
|
-
"detailKeys": ["query", "count"]
|
|
884
|
-
},
|
|
885
|
-
"web_fetch": {
|
|
886
|
-
"emoji": "📄",
|
|
887
|
-
"title": "Web Fetch",
|
|
888
|
-
"detailKeys": [
|
|
889
|
-
"url",
|
|
890
|
-
"extractMode",
|
|
891
|
-
"maxChars"
|
|
892
|
-
]
|
|
893
|
-
},
|
|
894
|
-
"whatsapp_login": {
|
|
895
|
-
"emoji": "🟢",
|
|
896
|
-
"title": "WhatsApp Login",
|
|
897
|
-
"actions": {
|
|
898
|
-
"start": { "label": "start" },
|
|
899
|
-
"wait": { "label": "wait" }
|
|
900
|
-
}
|
|
901
|
-
}
|
|
902
|
-
}
|
|
903
|
-
};
|
|
904
|
-
|
|
905
|
-
//#endregion
|
|
906
|
-
//#region src/agents/tool-display.ts
|
|
907
|
-
const TOOL_DISPLAY_CONFIG = tool_display_default;
|
|
908
|
-
const FALLBACK = TOOL_DISPLAY_CONFIG.fallback ?? { emoji: "🧩" };
|
|
909
|
-
const TOOL_MAP = TOOL_DISPLAY_CONFIG.tools ?? {};
|
|
910
|
-
const DETAIL_LABEL_OVERRIDES = {
|
|
911
|
-
agentId: "agent",
|
|
912
|
-
sessionKey: "session",
|
|
913
|
-
targetId: "target",
|
|
914
|
-
targetUrl: "url",
|
|
915
|
-
nodeId: "node",
|
|
916
|
-
requestId: "request",
|
|
917
|
-
messageId: "message",
|
|
918
|
-
threadId: "thread",
|
|
919
|
-
channelId: "channel",
|
|
920
|
-
guildId: "guild",
|
|
921
|
-
userId: "user",
|
|
922
|
-
runTimeoutSeconds: "timeout",
|
|
923
|
-
timeoutSeconds: "timeout",
|
|
924
|
-
includeTools: "tools",
|
|
925
|
-
pollQuestion: "poll",
|
|
926
|
-
maxChars: "max chars"
|
|
927
|
-
};
|
|
928
|
-
const MAX_DETAIL_ENTRIES = 8;
|
|
929
|
-
function normalizeToolName(name) {
|
|
930
|
-
return (name ?? "tool").trim();
|
|
931
|
-
}
|
|
932
|
-
function defaultTitle(name) {
|
|
933
|
-
const cleaned = name.replace(/_/g, " ").trim();
|
|
934
|
-
if (!cleaned) return "Tool";
|
|
935
|
-
return cleaned.split(/\s+/).map((part) => part.length <= 2 && part.toUpperCase() === part ? part : `${part.at(0)?.toUpperCase() ?? ""}${part.slice(1)}`).join(" ");
|
|
936
|
-
}
|
|
937
|
-
function normalizeVerb(value) {
|
|
938
|
-
const trimmed = value?.trim();
|
|
939
|
-
if (!trimmed) return;
|
|
940
|
-
return trimmed.replace(/_/g, " ");
|
|
941
|
-
}
|
|
942
|
-
function coerceDisplayValue(value) {
|
|
943
|
-
if (value === null || value === void 0) return;
|
|
944
|
-
if (typeof value === "string") {
|
|
945
|
-
const trimmed = value.trim();
|
|
946
|
-
if (!trimmed) return;
|
|
947
|
-
const firstLine = trimmed.split(/\r?\n/)[0]?.trim() ?? "";
|
|
948
|
-
if (!firstLine) return;
|
|
949
|
-
return firstLine.length > 160 ? `${firstLine.slice(0, 157)}…` : firstLine;
|
|
950
|
-
}
|
|
951
|
-
if (typeof value === "boolean") return value ? "true" : void 0;
|
|
952
|
-
if (typeof value === "number") {
|
|
953
|
-
if (!Number.isFinite(value) || value === 0) return;
|
|
954
|
-
return String(value);
|
|
955
|
-
}
|
|
956
|
-
if (Array.isArray(value)) {
|
|
957
|
-
const values = value.map((item) => coerceDisplayValue(item)).filter((item) => Boolean(item));
|
|
958
|
-
if (values.length === 0) return;
|
|
959
|
-
const preview = values.slice(0, 3).join(", ");
|
|
960
|
-
return values.length > 3 ? `${preview}…` : preview;
|
|
961
|
-
}
|
|
962
|
-
}
|
|
963
|
-
function lookupValueByPath(args, path) {
|
|
964
|
-
if (!args || typeof args !== "object") return;
|
|
965
|
-
let current = args;
|
|
966
|
-
for (const segment of path.split(".")) {
|
|
967
|
-
if (!segment) return;
|
|
968
|
-
if (!current || typeof current !== "object") return;
|
|
969
|
-
current = current[segment];
|
|
970
|
-
}
|
|
971
|
-
return current;
|
|
972
|
-
}
|
|
973
|
-
function formatDetailKey(raw) {
|
|
974
|
-
const last = raw.split(".").filter(Boolean).at(-1) ?? raw;
|
|
975
|
-
const override = DETAIL_LABEL_OVERRIDES[last];
|
|
976
|
-
if (override) return override;
|
|
977
|
-
return last.replace(/_/g, " ").replace(/-/g, " ").replace(/([a-z0-9])([A-Z])/g, "$1 $2").trim().toLowerCase() || last.toLowerCase();
|
|
978
|
-
}
|
|
979
|
-
function resolveDetailFromKeys(args, keys) {
|
|
980
|
-
const entries = [];
|
|
981
|
-
for (const key of keys) {
|
|
982
|
-
const display = coerceDisplayValue(lookupValueByPath(args, key));
|
|
983
|
-
if (!display) continue;
|
|
984
|
-
entries.push({
|
|
985
|
-
label: formatDetailKey(key),
|
|
986
|
-
value: display
|
|
987
|
-
});
|
|
988
|
-
}
|
|
989
|
-
if (entries.length === 0) return;
|
|
990
|
-
if (entries.length === 1) return entries[0].value;
|
|
991
|
-
const seen = /* @__PURE__ */ new Set();
|
|
992
|
-
const unique = [];
|
|
993
|
-
for (const entry of entries) {
|
|
994
|
-
const token = `${entry.label}:${entry.value}`;
|
|
995
|
-
if (seen.has(token)) continue;
|
|
996
|
-
seen.add(token);
|
|
997
|
-
unique.push(entry);
|
|
998
|
-
}
|
|
999
|
-
if (unique.length === 0) return;
|
|
1000
|
-
return unique.slice(0, MAX_DETAIL_ENTRIES).map((entry) => `${entry.label} ${entry.value}`).join(" · ");
|
|
1001
|
-
}
|
|
1002
|
-
function resolveReadDetail(args) {
|
|
1003
|
-
if (!args || typeof args !== "object") return;
|
|
1004
|
-
const record = args;
|
|
1005
|
-
const path = typeof record.path === "string" ? record.path : void 0;
|
|
1006
|
-
if (!path) return;
|
|
1007
|
-
const offset = typeof record.offset === "number" ? record.offset : void 0;
|
|
1008
|
-
const limit = typeof record.limit === "number" ? record.limit : void 0;
|
|
1009
|
-
if (offset !== void 0 && limit !== void 0) return `${path}:${offset}-${offset + limit}`;
|
|
1010
|
-
return path;
|
|
1011
|
-
}
|
|
1012
|
-
function resolveWriteDetail(args) {
|
|
1013
|
-
if (!args || typeof args !== "object") return;
|
|
1014
|
-
const record = args;
|
|
1015
|
-
return typeof record.path === "string" ? record.path : void 0;
|
|
1016
|
-
}
|
|
1017
|
-
function resolveActionSpec(spec, action) {
|
|
1018
|
-
if (!spec || !action) return;
|
|
1019
|
-
return spec.actions?.[action] ?? void 0;
|
|
1020
|
-
}
|
|
1021
|
-
function resolveToolDisplay(params) {
|
|
1022
|
-
const name = normalizeToolName(params.name);
|
|
1023
|
-
const key = name.toLowerCase();
|
|
1024
|
-
const spec = TOOL_MAP[key];
|
|
1025
|
-
const emoji = spec?.emoji ?? FALLBACK.emoji ?? "🧩";
|
|
1026
|
-
const title = spec?.title ?? defaultTitle(name);
|
|
1027
|
-
const label = spec?.label ?? title;
|
|
1028
|
-
const actionRaw = params.args && typeof params.args === "object" ? params.args.action : void 0;
|
|
1029
|
-
const action = typeof actionRaw === "string" ? actionRaw.trim() : void 0;
|
|
1030
|
-
const actionSpec = resolveActionSpec(spec, action);
|
|
1031
|
-
const verb = normalizeVerb(actionSpec?.label ?? action);
|
|
1032
|
-
let detail;
|
|
1033
|
-
if (key === "read") detail = resolveReadDetail(params.args);
|
|
1034
|
-
if (!detail && (key === "write" || key === "edit" || key === "attach")) detail = resolveWriteDetail(params.args);
|
|
1035
|
-
const detailKeys = actionSpec?.detailKeys ?? spec?.detailKeys ?? FALLBACK.detailKeys ?? [];
|
|
1036
|
-
if (!detail && detailKeys.length > 0) detail = resolveDetailFromKeys(params.args, detailKeys);
|
|
1037
|
-
if (!detail && params.meta) detail = params.meta;
|
|
1038
|
-
if (detail) detail = shortenHomeInString(detail);
|
|
1039
|
-
return {
|
|
1040
|
-
name,
|
|
1041
|
-
emoji,
|
|
1042
|
-
title,
|
|
1043
|
-
label,
|
|
1044
|
-
verb,
|
|
1045
|
-
detail
|
|
1046
|
-
};
|
|
1047
|
-
}
|
|
1048
|
-
function formatToolDetail(display) {
|
|
1049
|
-
const parts = [];
|
|
1050
|
-
if (display.verb) parts.push(display.verb);
|
|
1051
|
-
if (display.detail) parts.push(redactToolDetail(display.detail));
|
|
1052
|
-
if (parts.length === 0) return;
|
|
1053
|
-
return parts.join(" · ");
|
|
1054
|
-
}
|
|
1055
|
-
|
|
1056
|
-
//#endregion
|
|
1057
|
-
//#region src/agents/pi-embedded-utils.ts
|
|
1058
|
-
/**
|
|
1059
|
-
* Strip malformed Minimax tool invocations that leak into text content.
|
|
1060
|
-
* Minimax sometimes embeds tool calls as XML in text blocks instead of
|
|
1061
|
-
* proper structured tool calls. This removes:
|
|
1062
|
-
* - <invoke name="...">...</invoke> blocks
|
|
1063
|
-
* - </minimax:tool_call> closing tags
|
|
1064
|
-
*/
|
|
1065
|
-
function stripMinimaxToolCallXml(text) {
|
|
1066
|
-
if (!text) return text;
|
|
1067
|
-
if (!/minimax:tool_call/i.test(text)) return text;
|
|
1068
|
-
let cleaned = text.replace(/<invoke\b[^>]*>[\s\S]*?<\/invoke>/gi, "");
|
|
1069
|
-
cleaned = cleaned.replace(/<\/?minimax:tool_call>/gi, "");
|
|
1070
|
-
return cleaned;
|
|
1071
|
-
}
|
|
1072
|
-
/**
|
|
1073
|
-
* Strip downgraded tool call text representations that leak into text content.
|
|
1074
|
-
* When replaying history to Gemini, tool calls without `thought_signature` are
|
|
1075
|
-
* downgraded to text blocks like `[Tool Call: name (ID: ...)]`. These should
|
|
1076
|
-
* not be shown to users.
|
|
1077
|
-
*/
|
|
1078
|
-
function stripDowngradedToolCallText(text) {
|
|
1079
|
-
if (!text) return text;
|
|
1080
|
-
if (!/\[Tool (?:Call|Result)/i.test(text)) return text;
|
|
1081
|
-
const consumeJsonish = (input, start, options) => {
|
|
1082
|
-
const { allowLeadingNewlines = false } = options ?? {};
|
|
1083
|
-
let index = start;
|
|
1084
|
-
while (index < input.length) {
|
|
1085
|
-
const ch = input[index];
|
|
1086
|
-
if (ch === " " || ch === " ") {
|
|
1087
|
-
index += 1;
|
|
1088
|
-
continue;
|
|
1089
|
-
}
|
|
1090
|
-
if (allowLeadingNewlines && (ch === "\n" || ch === "\r")) {
|
|
1091
|
-
index += 1;
|
|
1092
|
-
continue;
|
|
1093
|
-
}
|
|
1094
|
-
break;
|
|
1095
|
-
}
|
|
1096
|
-
if (index >= input.length) return null;
|
|
1097
|
-
const startChar = input[index];
|
|
1098
|
-
if (startChar === "{" || startChar === "[") {
|
|
1099
|
-
let depth = 0;
|
|
1100
|
-
let inString = false;
|
|
1101
|
-
let escape = false;
|
|
1102
|
-
for (let i = index; i < input.length; i += 1) {
|
|
1103
|
-
const ch = input[i];
|
|
1104
|
-
if (inString) {
|
|
1105
|
-
if (escape) escape = false;
|
|
1106
|
-
else if (ch === "\\") escape = true;
|
|
1107
|
-
else if (ch === "\"") inString = false;
|
|
1108
|
-
continue;
|
|
1109
|
-
}
|
|
1110
|
-
if (ch === "\"") {
|
|
1111
|
-
inString = true;
|
|
1112
|
-
continue;
|
|
1113
|
-
}
|
|
1114
|
-
if (ch === "{" || ch === "[") {
|
|
1115
|
-
depth += 1;
|
|
1116
|
-
continue;
|
|
1117
|
-
}
|
|
1118
|
-
if (ch === "}" || ch === "]") {
|
|
1119
|
-
depth -= 1;
|
|
1120
|
-
if (depth === 0) return i + 1;
|
|
1121
|
-
}
|
|
1122
|
-
}
|
|
1123
|
-
return null;
|
|
1124
|
-
}
|
|
1125
|
-
if (startChar === "\"") {
|
|
1126
|
-
let escape = false;
|
|
1127
|
-
for (let i = index + 1; i < input.length; i += 1) {
|
|
1128
|
-
const ch = input[i];
|
|
1129
|
-
if (escape) {
|
|
1130
|
-
escape = false;
|
|
1131
|
-
continue;
|
|
1132
|
-
}
|
|
1133
|
-
if (ch === "\\") {
|
|
1134
|
-
escape = true;
|
|
1135
|
-
continue;
|
|
1136
|
-
}
|
|
1137
|
-
if (ch === "\"") return i + 1;
|
|
1138
|
-
}
|
|
1139
|
-
return null;
|
|
1140
|
-
}
|
|
1141
|
-
let end = index;
|
|
1142
|
-
while (end < input.length && input[end] !== "\n" && input[end] !== "\r") end += 1;
|
|
1143
|
-
return end;
|
|
1144
|
-
};
|
|
1145
|
-
const stripToolCalls = (input) => {
|
|
1146
|
-
const markerRe = /\[Tool Call:[^\]]*\]/gi;
|
|
1147
|
-
let result = "";
|
|
1148
|
-
let cursor = 0;
|
|
1149
|
-
for (const match of input.matchAll(markerRe)) {
|
|
1150
|
-
const start = match.index ?? 0;
|
|
1151
|
-
if (start < cursor) continue;
|
|
1152
|
-
result += input.slice(cursor, start);
|
|
1153
|
-
let index = start + match[0].length;
|
|
1154
|
-
while (index < input.length && (input[index] === " " || input[index] === " ")) index += 1;
|
|
1155
|
-
if (input[index] === "\r") {
|
|
1156
|
-
index += 1;
|
|
1157
|
-
if (input[index] === "\n") index += 1;
|
|
1158
|
-
} else if (input[index] === "\n") index += 1;
|
|
1159
|
-
while (index < input.length && (input[index] === " " || input[index] === " ")) index += 1;
|
|
1160
|
-
if (input.slice(index, index + 9).toLowerCase() === "arguments") {
|
|
1161
|
-
index += 9;
|
|
1162
|
-
if (input[index] === ":") index += 1;
|
|
1163
|
-
if (input[index] === " ") index += 1;
|
|
1164
|
-
const end = consumeJsonish(input, index, { allowLeadingNewlines: true });
|
|
1165
|
-
if (end !== null) index = end;
|
|
1166
|
-
}
|
|
1167
|
-
if ((input[index] === "\n" || input[index] === "\r") && (result.endsWith("\n") || result.endsWith("\r") || result.length === 0)) {
|
|
1168
|
-
if (input[index] === "\r") index += 1;
|
|
1169
|
-
if (input[index] === "\n") index += 1;
|
|
1170
|
-
}
|
|
1171
|
-
cursor = index;
|
|
1172
|
-
}
|
|
1173
|
-
result += input.slice(cursor);
|
|
1174
|
-
return result;
|
|
1175
|
-
};
|
|
1176
|
-
let cleaned = stripToolCalls(text);
|
|
1177
|
-
cleaned = cleaned.replace(/\[Tool Result for ID[^\]]*\]\n?[\s\S]*?(?=\n*\[Tool |\n*$)/gi, "");
|
|
1178
|
-
return cleaned.trim();
|
|
1179
|
-
}
|
|
1180
|
-
/**
|
|
1181
|
-
* Strip thinking tags and their content from text.
|
|
1182
|
-
* This is a safety net for cases where the model outputs <think> tags
|
|
1183
|
-
* that slip through other filtering mechanisms.
|
|
1184
|
-
*/
|
|
1185
|
-
function stripThinkingTagsFromText(text) {
|
|
1186
|
-
return stripReasoningTagsFromText(text, {
|
|
1187
|
-
mode: "strict",
|
|
1188
|
-
trim: "both"
|
|
1189
|
-
});
|
|
1190
|
-
}
|
|
1191
|
-
function extractAssistantText(msg) {
|
|
1192
|
-
const isTextBlock = (block) => {
|
|
1193
|
-
if (!block || typeof block !== "object") return false;
|
|
1194
|
-
const rec = block;
|
|
1195
|
-
return rec.type === "text" && typeof rec.text === "string";
|
|
1196
|
-
};
|
|
1197
|
-
return sanitizeUserFacingText((Array.isArray(msg.content) ? msg.content.filter(isTextBlock).map((c) => stripThinkingTagsFromText(stripDowngradedToolCallText(stripMinimaxToolCallXml(c.text))).trim()).filter(Boolean) : []).join("\n").trim());
|
|
1198
|
-
}
|
|
1199
|
-
function extractAssistantThinking(msg) {
|
|
1200
|
-
if (!Array.isArray(msg.content)) return "";
|
|
1201
|
-
return msg.content.map((block) => {
|
|
1202
|
-
if (!block || typeof block !== "object") return "";
|
|
1203
|
-
const record = block;
|
|
1204
|
-
if (record.type === "thinking" && typeof record.thinking === "string") return record.thinking.trim();
|
|
1205
|
-
return "";
|
|
1206
|
-
}).filter(Boolean).join("\n").trim();
|
|
1207
|
-
}
|
|
1208
|
-
function formatReasoningMessage(text) {
|
|
1209
|
-
const trimmed = text.trim();
|
|
1210
|
-
if (!trimmed) return "";
|
|
1211
|
-
return `Reasoning:\n${trimmed.split("\n").map((line) => line ? `_${line}_` : line).join("\n")}`;
|
|
1212
|
-
}
|
|
1213
|
-
function splitThinkingTaggedText(text) {
|
|
1214
|
-
const trimmedStart = text.trimStart();
|
|
1215
|
-
if (!trimmedStart.startsWith("<")) return null;
|
|
1216
|
-
const openRe = /<\s*(?:think(?:ing)?|thought|antthinking)\s*>/i;
|
|
1217
|
-
const closeRe = /<\s*\/\s*(?:think(?:ing)?|thought|antthinking)\s*>/i;
|
|
1218
|
-
if (!openRe.test(trimmedStart)) return null;
|
|
1219
|
-
if (!closeRe.test(text)) return null;
|
|
1220
|
-
const scanRe = /<\s*(\/?)\s*(?:think(?:ing)?|thought|antthinking)\s*>/gi;
|
|
1221
|
-
let inThinking = false;
|
|
1222
|
-
let cursor = 0;
|
|
1223
|
-
let thinkingStart = 0;
|
|
1224
|
-
const blocks = [];
|
|
1225
|
-
const pushText = (value) => {
|
|
1226
|
-
if (!value) return;
|
|
1227
|
-
blocks.push({
|
|
1228
|
-
type: "text",
|
|
1229
|
-
text: value
|
|
1230
|
-
});
|
|
1231
|
-
};
|
|
1232
|
-
const pushThinking = (value) => {
|
|
1233
|
-
const cleaned = value.trim();
|
|
1234
|
-
if (!cleaned) return;
|
|
1235
|
-
blocks.push({
|
|
1236
|
-
type: "thinking",
|
|
1237
|
-
thinking: cleaned
|
|
1238
|
-
});
|
|
1239
|
-
};
|
|
1240
|
-
for (const match of text.matchAll(scanRe)) {
|
|
1241
|
-
const index = match.index ?? 0;
|
|
1242
|
-
const isClose = Boolean(match[1]?.includes("/"));
|
|
1243
|
-
if (!inThinking && !isClose) {
|
|
1244
|
-
pushText(text.slice(cursor, index));
|
|
1245
|
-
thinkingStart = index + match[0].length;
|
|
1246
|
-
inThinking = true;
|
|
1247
|
-
continue;
|
|
1248
|
-
}
|
|
1249
|
-
if (inThinking && isClose) {
|
|
1250
|
-
pushThinking(text.slice(thinkingStart, index));
|
|
1251
|
-
cursor = index + match[0].length;
|
|
1252
|
-
inThinking = false;
|
|
1253
|
-
}
|
|
1254
|
-
}
|
|
1255
|
-
if (inThinking) return null;
|
|
1256
|
-
pushText(text.slice(cursor));
|
|
1257
|
-
if (!blocks.some((b) => b.type === "thinking")) return null;
|
|
1258
|
-
return blocks;
|
|
1259
|
-
}
|
|
1260
|
-
function promoteThinkingTagsToBlocks(message) {
|
|
1261
|
-
if (!Array.isArray(message.content)) return;
|
|
1262
|
-
if (message.content.some((block) => block.type === "thinking")) return;
|
|
1263
|
-
const next = [];
|
|
1264
|
-
let changed = false;
|
|
1265
|
-
for (const block of message.content) {
|
|
1266
|
-
if (block.type !== "text") {
|
|
1267
|
-
next.push(block);
|
|
1268
|
-
continue;
|
|
1269
|
-
}
|
|
1270
|
-
const split = splitThinkingTaggedText(block.text);
|
|
1271
|
-
if (!split) {
|
|
1272
|
-
next.push(block);
|
|
1273
|
-
continue;
|
|
1274
|
-
}
|
|
1275
|
-
changed = true;
|
|
1276
|
-
for (const part of split) if (part.type === "thinking") next.push({
|
|
1277
|
-
type: "thinking",
|
|
1278
|
-
thinking: part.thinking
|
|
1279
|
-
});
|
|
1280
|
-
else if (part.type === "text") {
|
|
1281
|
-
const cleaned = part.text.trimStart();
|
|
1282
|
-
if (cleaned) next.push({
|
|
1283
|
-
type: "text",
|
|
1284
|
-
text: cleaned
|
|
1285
|
-
});
|
|
1286
|
-
}
|
|
1287
|
-
}
|
|
1288
|
-
if (!changed) return;
|
|
1289
|
-
message.content = next;
|
|
1290
|
-
}
|
|
1291
|
-
function extractThinkingFromTaggedText(text) {
|
|
1292
|
-
if (!text) return "";
|
|
1293
|
-
const scanRe = /<\s*(\/?)\s*(?:think(?:ing)?|thought|antthinking)\s*>/gi;
|
|
1294
|
-
let result = "";
|
|
1295
|
-
let lastIndex = 0;
|
|
1296
|
-
let inThinking = false;
|
|
1297
|
-
for (const match of text.matchAll(scanRe)) {
|
|
1298
|
-
const idx = match.index ?? 0;
|
|
1299
|
-
if (inThinking) result += text.slice(lastIndex, idx);
|
|
1300
|
-
inThinking = !(match[1] === "/");
|
|
1301
|
-
lastIndex = idx + match[0].length;
|
|
1302
|
-
}
|
|
1303
|
-
return result.trim();
|
|
1304
|
-
}
|
|
1305
|
-
function extractThinkingFromTaggedStream(text) {
|
|
1306
|
-
if (!text) return "";
|
|
1307
|
-
const closed = extractThinkingFromTaggedText(text);
|
|
1308
|
-
if (closed) return closed;
|
|
1309
|
-
const openRe = /<\s*(?:think(?:ing)?|thought|antthinking)\s*>/gi;
|
|
1310
|
-
const closeRe = /<\s*\/\s*(?:think(?:ing)?|thought|antthinking)\s*>/gi;
|
|
1311
|
-
const openMatches = [...text.matchAll(openRe)];
|
|
1312
|
-
if (openMatches.length === 0) return "";
|
|
1313
|
-
const closeMatches = [...text.matchAll(closeRe)];
|
|
1314
|
-
const lastOpen = openMatches[openMatches.length - 1];
|
|
1315
|
-
const lastClose = closeMatches[closeMatches.length - 1];
|
|
1316
|
-
if (lastClose && (lastClose.index ?? -1) > (lastOpen.index ?? -1)) return closed;
|
|
1317
|
-
const start = (lastOpen.index ?? 0) + lastOpen[0].length;
|
|
1318
|
-
return text.slice(start).trim();
|
|
1319
|
-
}
|
|
1320
|
-
function inferToolMetaFromArgs(toolName, args) {
|
|
1321
|
-
return formatToolDetail(resolveToolDisplay({
|
|
1322
|
-
name: toolName,
|
|
1323
|
-
args
|
|
1324
|
-
}));
|
|
1325
|
-
}
|
|
1326
|
-
|
|
1327
|
-
//#endregion
|
|
1328
|
-
//#region src/agents/tools/image-tool.helpers.ts
|
|
1329
|
-
function decodeDataUrl(dataUrl) {
|
|
1330
|
-
const trimmed = dataUrl.trim();
|
|
1331
|
-
const match = /^data:([^;,]+);base64,([a-z0-9+/=\r\n]+)$/i.exec(trimmed);
|
|
1332
|
-
if (!match) throw new Error("Invalid data URL (expected base64 data: URL).");
|
|
1333
|
-
const mimeType = (match[1] ?? "").trim().toLowerCase();
|
|
1334
|
-
if (!mimeType.startsWith("image/")) throw new Error(`Unsupported data URL type: ${mimeType || "unknown"}`);
|
|
1335
|
-
const b64 = (match[2] ?? "").trim();
|
|
1336
|
-
const buffer = Buffer.from(b64, "base64");
|
|
1337
|
-
if (buffer.length === 0) throw new Error("Invalid data URL: empty payload.");
|
|
1338
|
-
return {
|
|
1339
|
-
buffer,
|
|
1340
|
-
mimeType,
|
|
1341
|
-
kind: "image"
|
|
1342
|
-
};
|
|
1343
|
-
}
|
|
1344
|
-
function coerceImageAssistantText(params) {
|
|
1345
|
-
const stop = params.message.stopReason;
|
|
1346
|
-
const errorMessage = params.message.errorMessage?.trim();
|
|
1347
|
-
if (stop === "error" || stop === "aborted") throw new Error(errorMessage ? `Image model failed (${params.provider}/${params.model}): ${errorMessage}` : `Image model failed (${params.provider}/${params.model})`);
|
|
1348
|
-
if (errorMessage) throw new Error(`Image model failed (${params.provider}/${params.model}): ${errorMessage}`);
|
|
1349
|
-
const text = extractAssistantText(params.message);
|
|
1350
|
-
if (text.trim()) return text.trim();
|
|
1351
|
-
throw new Error(`Image model returned no text (${params.provider}/${params.model}).`);
|
|
1352
|
-
}
|
|
1353
|
-
function coerceImageModelConfig(cfg) {
|
|
1354
|
-
const imageModel = cfg?.agents?.defaults?.imageModel;
|
|
1355
|
-
const primary = typeof imageModel === "string" ? imageModel.trim() : imageModel?.primary;
|
|
1356
|
-
const fallbacks = typeof imageModel === "object" ? imageModel?.fallbacks ?? [] : [];
|
|
1357
|
-
return {
|
|
1358
|
-
...primary?.trim() ? { primary: primary.trim() } : {},
|
|
1359
|
-
...fallbacks.length > 0 ? { fallbacks } : {}
|
|
1360
|
-
};
|
|
1361
|
-
}
|
|
1362
|
-
function resolveProviderVisionModelFromConfig(params) {
|
|
1363
|
-
const models = (params.cfg?.models?.providers?.[params.provider])?.models ?? [];
|
|
1364
|
-
const id = (((params.provider === "minimax" ? models.find((m) => (m?.id ?? "").trim() === "MiniMax-VL-01" && Array.isArray(m?.input) && m.input.includes("image")) : null) ?? models.find((m) => Boolean((m?.id ?? "").trim()) && m.input?.includes("image")))?.id ?? "").trim();
|
|
1365
|
-
return id ? `${params.provider}/${id}` : null;
|
|
1366
|
-
}
|
|
1367
|
-
|
|
1368
|
-
//#endregion
|
|
1369
|
-
//#region src/media-understanding/providers/image.ts
|
|
1370
|
-
async function describeImageWithModel(params) {
|
|
1371
|
-
await ensureOpenClawModelsJson(params.cfg, params.agentDir);
|
|
1372
|
-
const authStorage = discoverAuthStorage(params.agentDir);
|
|
1373
|
-
const model = discoverModels(authStorage, params.agentDir).find(params.provider, params.model);
|
|
1374
|
-
if (!model) throw new Error(`Unknown model: ${params.provider}/${params.model}`);
|
|
1375
|
-
if (!model.input?.includes("image")) throw new Error(`Model does not support images: ${params.provider}/${params.model}`);
|
|
1376
|
-
const apiKey = requireApiKey(await getApiKeyForModel({
|
|
1377
|
-
model,
|
|
1378
|
-
cfg: params.cfg,
|
|
1379
|
-
agentDir: params.agentDir,
|
|
1380
|
-
profileId: params.profile,
|
|
1381
|
-
preferredProfile: params.preferredProfile
|
|
1382
|
-
}), model.provider);
|
|
1383
|
-
authStorage.setRuntimeApiKey(model.provider, apiKey);
|
|
1384
|
-
const base64 = params.buffer.toString("base64");
|
|
1385
|
-
if (model.provider === "minimax") return {
|
|
1386
|
-
text: await minimaxUnderstandImage({
|
|
1387
|
-
apiKey,
|
|
1388
|
-
prompt: params.prompt ?? "Describe the image.",
|
|
1389
|
-
imageDataUrl: `data:${params.mime ?? "image/jpeg"};base64,${base64}`,
|
|
1390
|
-
modelBaseUrl: model.baseUrl
|
|
1391
|
-
}),
|
|
1392
|
-
model: model.id
|
|
1393
|
-
};
|
|
1394
|
-
return {
|
|
1395
|
-
text: coerceImageAssistantText({
|
|
1396
|
-
message: await complete(model, { messages: [{
|
|
1397
|
-
role: "user",
|
|
1398
|
-
content: [{
|
|
1399
|
-
type: "text",
|
|
1400
|
-
text: params.prompt ?? "Describe the image."
|
|
1401
|
-
}, {
|
|
1402
|
-
type: "image",
|
|
1403
|
-
data: base64,
|
|
1404
|
-
mimeType: params.mime ?? "image/jpeg"
|
|
1405
|
-
}],
|
|
1406
|
-
timestamp: Date.now()
|
|
1407
|
-
}] }, {
|
|
1408
|
-
apiKey,
|
|
1409
|
-
maxTokens: params.maxTokens ?? 512
|
|
1410
|
-
}),
|
|
1411
|
-
provider: model.provider,
|
|
1412
|
-
model: model.id
|
|
1413
|
-
}),
|
|
1414
|
-
model: model.id
|
|
1415
|
-
};
|
|
1416
|
-
}
|
|
1417
|
-
|
|
1418
|
-
//#endregion
|
|
1419
|
-
export { ensureOpenClawModelsJson as _, resolveProviderVisionModelFromConfig as a, extractThinkingFromTaggedStream as c, inferToolMetaFromArgs as d, promoteThinkingTagsToBlocks as f, resolveToolDisplay as g, stripThinkingTagsFromText as h, decodeDataUrl as i, extractThinkingFromTaggedText as l, stripMinimaxToolCallXml as m, coerceImageAssistantText as n, extractAssistantText as o, stripDowngradedToolCallText as p, coerceImageModelConfig as r, extractAssistantThinking as s, describeImageWithModel as t, formatReasoningMessage as u, minimaxUnderstandImage as v };
|