@symerian/symi 2.0.6 → 2.0.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{agents-CypLQ-TX.js → agents-Ck7Cf272.js} +4 -4
- package/dist/{agents.config-DWqwPV32.js → agents.config-BTWn70A_.js} +1 -1
- package/dist/{agents.config-S5g63_Ww.js → agents.config-DRDcXXQC.js} +1 -1
- package/dist/{audio-preflight-Cq4C-m27.js → audio-preflight-B6L8N6Ly.js} +13 -12
- package/dist/{audio-preflight-DSeaWZZW.js → audio-preflight-BQbkYWBq.js} +6 -5
- package/dist/{audio-preflight-DbUFnPX1.js → audio-preflight-Bk54IW__.js} +17 -16
- package/dist/{audio-preflight-CO2seHjy.js → audio-preflight-Bl8Xkt6g.js} +12 -11
- package/dist/{audit-DKUpFt8z.js → audit-Bv_hWhC7.js} +2 -2
- package/dist/{audit-CiugrQda.js → audit-Dmg0_STU.js} +2 -2
- package/dist/{auth-choice-1csNxn5J.js → auth-choice-B2vfWdxb.js} +1 -1
- package/dist/{auth-choice-DxhF9BuU.js → auth-choice-BTHtq4sU.js} +4 -4
- package/dist/{banner-CV_YEEQe.js → banner-C93WYZhg.js} +1 -1
- package/dist/build-info.json +3 -3
- package/dist/bundled/boot-md/handler.js +34 -34
- package/dist/bundled/session-memory/handler.js +34 -34
- package/dist/canvas-host/a2ui/.bundle.hash +1 -1
- package/dist/{channel-options-NbbM348A.js → channel-options-DzVgaV8r.js} +1 -1
- package/dist/{channel-options-DN7ZZEMr.js → channel-options-FXf1Vm4X.js} +1 -1
- package/dist/{channel-web-BUODlmfF.js → channel-web-DXNS1120.js} +8 -8
- package/dist/{channels-cli-6MNbtk6T.js → channels-cli-VMjbf17C.js} +32 -32
- package/dist/{channels-cli-DOoGJd4k.js → channels-cli-jwN3bQiA.js} +12 -12
- package/dist/{chrome-BATLK3yK.js → chrome-2-wXJfuH.js} +8 -8
- package/dist/{chrome-h6BnL8Lp.js → chrome-B_zrSLce.js} +7 -7
- package/dist/{chunk-BW5f05BR.js → chunk-BPSLqkZN.js} +1 -1
- package/dist/{chunk-DTMTDXwE.js → chunk-rw3-yl6B.js} +1 -1
- package/dist/{cli-TVchR8N9.js → cli-B0zfZMTk.js} +29 -29
- package/dist/{cli-DxHEDvD7.js → cli-pVI3InZO.js} +9 -9
- package/dist/{command-registry-S2yEeoft.js → command-registry-BfDMSQVM.js} +9 -9
- package/dist/{commands-registry-C3C4Rv3O.js → commands-registry-CZ5P8CpC.js} +2 -2
- package/dist/{commands-registry-Copoizgv.js → commands-registry-UwWpNkQg.js} +1 -1
- package/dist/{completion-cli-u1z9O4lQ.js → completion-cli-BIb71n9R.js} +2 -2
- package/dist/{completion-cli-BrgaQVPk.js → completion-cli-CtFc2LrR.js} +1 -1
- package/dist/{config-DM0K7qC1.js → config-D3XlX-h-.js} +1 -1
- package/dist/{config-cli-CUdFNGGC.js → config-cli-5k0J0n8w.js} +1 -1
- package/dist/{config-cli-CipxRDcw.js → config-cli-S34vsL8T.js} +1 -1
- package/dist/{config-guard-BpQn1MKk.js → config-guard-Ca5SgLv4.js} +1 -1
- package/dist/{config-guard-Cnu2qssk.js → config-guard-lpwxY7-I.js} +3 -2
- package/dist/{configure-D9n_M6Ra.js → configure-CwPEm658.js} +3 -3
- package/dist/{configure-B2DVh1MI.js → configure-DK60UZR-.js} +6 -6
- package/dist/{deliver-DONp5mgd.js → deliver-BubWdk2x.js} +2 -2
- package/dist/{deliver-DD3gs9SF.js → deliver-DGaRNkFI.js} +5 -5
- package/dist/{deliver-2Y_F_0yh.js → deliver-DTHhqsN5.js} +5 -5
- package/dist/{deliver-CZF9f8aC.js → deliver-jK_qcWx-.js} +5 -5
- package/dist/{diagnostic-CI0kRQkt.js → diagnostic-BIVLRT_X.js} +1 -1
- package/dist/{diagnostic-D0xmLpej.js → diagnostic-C-7DW8ZL.js} +1 -1
- package/dist/{doctor-completion-Beg_3VG2.js → doctor-completion-B0H-LZ9F.js} +1 -1
- package/dist/{doctor-completion-94bdxcgy.js → doctor-completion-B7omSm-D.js} +1 -1
- package/dist/{doctor-config-flow-C_56SUPO.js → doctor-config-flow-CifTPMbU.js} +1 -1
- package/dist/{doctor-config-flow-B150h841.js → doctor-config-flow-Da5WjdWM.js} +1 -1
- package/dist/entry.js +1 -1
- package/dist/extensionAPI.js +29 -29
- package/dist/{fetch-DTNGXEzX.js → fetch-BrtlUMgb.js} +1 -1
- package/dist/{fetch-guard-DOPkVbh3.js → fetch-guard-DPA1vbaF.js} +1 -1
- package/dist/{gateway-cli-CKIJn013.js → gateway-cli-BIQu6Utl.js} +43 -43
- package/dist/{gateway-cli-BkfAKxxR.js → gateway-cli-C9FvkbFy.js} +20 -20
- package/dist/{gemini-auth-7AWT6JXV.js → gemini-auth-Ca6F0cNq.js} +1 -1
- package/dist/{glass-ui-ws-BQ6j-PII.js → glass-ui-ws-CwHtwMkP.js} +16 -16
- package/dist/{glass-ui-ws-BrvN2A06.js → glass-ui-ws-DpKEdS_Z.js} +39 -39
- package/dist/{health-BUaaGug2.js → health-Cey03nVq.js} +4 -4
- package/dist/{health-9kUMJPU4.js → health-KL2iuEbF.js} +5 -5
- package/dist/{heartbeat-visibility-U4BL57eQ.js → heartbeat-visibility-D4Xy8Sv0.js} +2 -2
- package/dist/{heartbeat-visibility-B8TDjqpW.js → heartbeat-visibility-DS9JNq6T.js} +2 -2
- package/dist/{hooks-cli-CBkjAKu_.js → hooks-cli-BQF_wX5P.js} +10 -10
- package/dist/{hooks-cli-CxqrpSnT.js → hooks-cli-Dzw7jPNk.js} +30 -30
- package/dist/{image-RLbZ3RUn.js → image-BJiE96Ml.js} +4 -4
- package/dist/{image-DrZEJQwQ.js → image-BPHwlO8o.js} +2 -2
- package/dist/{image-B4LY9KFw.js → image-CPNmq0j8.js} +1 -1
- package/dist/{image-DOnOTocl.js → image-qnqUW4nb.js} +2 -2
- package/dist/index.js +36 -36
- package/dist/{ir-DccrnjsE.js → ir-B4l25ISI.js} +3 -3
- package/dist/{ir-DZam9q5M.js → ir-DEVHhjq7.js} +1 -1
- package/dist/{ir-F0moAwIl.js → ir-DPLo2LIn.js} +3 -3
- package/dist/llm-slug-generator.js +34 -34
- package/dist/{local-roots-CC8jiKDk.js → local-roots-BDORNz_Q.js} +1 -1
- package/dist/{local-roots-aAFLQGkY.js → local-roots-C31eq7PP.js} +1 -1
- package/dist/{local-roots-DMwIh5cS.js → local-roots-Dg0r0pJL.js} +1 -1
- package/dist/{login-BG_7eJLu.js → login-DNi-TGJT.js} +2 -2
- package/dist/{login-qr-9OQSnm5L.js → login-qr-DWlyS1Bc.js} +4 -4
- package/dist/{manager-B5EXdBQV.js → manager-BX65xO2I.js} +2 -2
- package/dist/{manager-C_DoJrcP.js → manager-DjVWQ1JF.js} +3 -3
- package/dist/{memory-cli-D4J9SO7Z.js → memory-cli-BsBiPX0L.js} +4 -4
- package/dist/{model-auth-CeL58m55.js → model-auth-Daguh6Kb.js} +1 -1
- package/dist/{model-picker-DXwUsLAy.js → model-picker-CiSWZdy1.js} +1 -1
- package/dist/{models-CZSMuo5B.js → models-CmtHVZ9B.js} +2 -2
- package/dist/{models-cli-Ds23awjm.js → models-cli-CoLpqD2i.js} +11 -11
- package/dist/{models-cli-MqWvGB7f.js → models-cli-CzXJgEMc.js} +30 -30
- package/dist/{onboard-G9IN6QQx.js → onboard-CYpfv_zR.js} +2 -2
- package/dist/{onboard-D3oW4O-4.js → onboard-CctP17cu.js} +5 -5
- package/dist/{onboard-channels-dfTDyb59.js → onboard-channels-BfEIJ5D9.js} +1 -1
- package/dist/{onboard-channels-oFTqVfhO.js → onboard-channels-KDLz_5CQ.js} +1 -1
- package/dist/{onboard-custom-DoIhWPnb.js → onboard-custom-B3RZopk5.js} +2 -2
- package/dist/{onboard-skills-BD8JNVwL.js → onboard-skills-DfKmsYuM.js} +1 -1
- package/dist/{onboarding-Ckpz4QDg.js → onboarding-D8u579LU.js} +7 -7
- package/dist/{onboarding-g2bI9l8x.js → onboarding-HyPoSPVD.js} +4 -4
- package/dist/{onboarding.finalize-C1lR3Y__.js → onboarding.finalize-BVxx88Nj.js} +15 -15
- package/dist/{onboarding.finalize-MWEKi_hL.js → onboarding.finalize-DKJJyaEK.js} +34 -34
- package/dist/{onboarding.gateway-config-DipSuaKH.js → onboarding.gateway-config-C88Tut4n.js} +2 -1
- package/dist/{onboarding.gateway-config-Cj_s_IG8.js → onboarding.gateway-config-svEaDNCf.js} +2 -1
- package/dist/{openai-model-default-DF334-MD.js → openai-model-default-BkscYpXX.js} +1 -1
- package/dist/{outbound-DfOF58G2.js → outbound-56UQxS1I.js} +2 -2
- package/dist/{outbound-BNMysnJ1.js → outbound-ByC0HdWz.js} +2 -2
- package/dist/{outbound-Cedd_yui.js → outbound-DpGc1neG.js} +3 -3
- package/dist/{outbound-attachment-D_QuKi8U.js → outbound-attachment-C-GD7uJh.js} +1 -1
- package/dist/{outbound-attachment-DjNDa3zn.js → outbound-attachment-CJZwroQb.js} +2 -2
- package/dist/{outbound-attachment-entfcjDW.js → outbound-attachment-Cir36qaG.js} +2 -2
- package/dist/{pi-auth-json-BNhcohVK.js → pi-auth-json-CHgA276j.js} +2 -2
- package/dist/{pi-embedded-BJC3CNWN.js → pi-embedded-C5XncARS.js} +223 -161
- package/dist/{pi-embedded-Cll2enMR.js → pi-embedded-FBOXa0Py.js} +211 -149
- package/dist/{pi-embedded-helpers-x8rJur4F.js → pi-embedded-helpers-B8JQjQlx.js} +109 -13
- package/dist/{pi-embedded-helpers--yFTAWwW.js → pi-embedded-helpers-BqnI9Mzn.js} +107 -11
- package/dist/{pi-embedded-helpers-ueCT6VlS.js → pi-embedded-helpers-Ct3OLzYp.js} +2 -2
- package/dist/{pi-embedded-helpers-CgxKWHj9.js → pi-embedded-helpers-DhWpSwU-.js} +1 -1
- package/dist/{pi-tools.policy-DPmdlOwE.js → pi-tools.policy-BXcx55vF.js} +1 -1
- package/dist/{pi-tools.policy-T6Z5F-_n.js → pi-tools.policy-Bs2MTSlR.js} +1 -1
- package/dist/{plugin-registry-C5KPfoPc.js → plugin-registry-BDz-xHIX.js} +1 -1
- package/dist/{plugin-registry-KUffgxdX.js → plugin-registry-CdUu6pO0.js} +1 -1
- package/dist/plugin-sdk/agents/plan-mode.d.ts +32 -0
- package/dist/plugin-sdk/{audio-preflight-CpYjfwrA.js → audio-preflight-CAWn5TBW.js} +4 -3
- package/dist/plugin-sdk/{channel-web-DTV6QoJV.js → channel-web-CdAlKpn7.js} +3 -3
- package/dist/plugin-sdk/{deliver-BwnrMlHO.js → deliver-PnVwVXLm.js} +1 -1
- package/dist/plugin-sdk/gateway/chat-sanitize.d.ts +10 -0
- package/dist/plugin-sdk/{image-k_W1USVr.js → image-BGfQ0dkr.js} +1 -1
- package/dist/plugin-sdk/index.js +6 -6
- package/dist/plugin-sdk/{pi-embedded-helpers-Cs2-_EpL.js → pi-embedded-helpers-BMudP5Tn.js} +98 -2
- package/dist/plugin-sdk/{reply-CzCsghFB.js → reply-QYyMp-Tw.js} +169 -107
- package/dist/plugin-sdk/{runner-Br1179I4.js → runner-qajBqJHY.js} +1 -1
- package/dist/plugin-sdk/{web-BLcsH45O.js → web-CVs35ve3.js} +6 -6
- package/dist/{plugins-cli-DRDUAaBR.js → plugins-cli-D0KwuqdQ.js} +30 -30
- package/dist/{plugins-cli-BIHhue19.js → plugins-cli-g3VAbxTK.js} +10 -10
- package/dist/{program-BCEnYzi8.js → program-CARq3XaO.js} +16 -16
- package/dist/{program-context-CS1wSnZE.js → program-context-D3z9orfX.js} +21 -21
- package/dist/{prompt-select-styled-AZW_g_xe.js → prompt-select-styled-BFHQx73x.js} +10 -10
- package/dist/{prompt-select-styled-99u32PPK.js → prompt-select-styled-CwssKDY4.js} +7 -7
- package/dist/{provider-auth-helpers-CeJqzcdK.js → provider-auth-helpers-DJ3yECqH.js} +1 -1
- package/dist/{provider-auth-helpers-DqJ69hdw.js → provider-auth-helpers-gNJWrk0O.js} +1 -1
- package/dist/{push-apns-Dwt-_Kns.js → push-apns-CZM-8wga.js} +1 -1
- package/dist/{push-apns-C5xLtVxl.js → push-apns-D1GxPyeO.js} +1 -1
- package/dist/{pw-ai-CCt1nIO-.js → pw-ai-D8UzqLyI.js} +4 -4
- package/dist/{pw-ai-C_C5as1t.js → pw-ai-s-d46DCX.js} +1 -1
- package/dist/{qmd-manager-D85GJrir.js → qmd-manager-DeZm1nJL.js} +1 -1
- package/dist/{register.agent-nnrj8tc5.js → register.agent-4Vr8rfNN.js} +35 -35
- package/dist/{register.agent-Cyq17z22.js → register.agent-BQ5ERQ9d.js} +14 -14
- package/dist/{register.configure-D1zZ3jgM.js → register.configure-BKh4lgRd.js} +14 -14
- package/dist/{register.configure-DSknC_88.js → register.configure-Do3kZMFp.js} +39 -39
- package/dist/{register.maintenance-Dt1AUhn3.js → register.maintenance-BMPh4huD.js} +17 -17
- package/dist/{register.maintenance-ClQi_hVH.js → register.maintenance-DvrBn6u3.js} +37 -37
- package/dist/{register.message-x7nPJjwN.js → register.message-BNNSKB5m.js} +10 -10
- package/dist/{register.message-C0R7nCJf.js → register.message-BYL16pRB.js} +30 -30
- package/dist/{register.onboard-BOXdnoFU.js → register.onboard-CPPotri6.js} +35 -35
- package/dist/{register.onboard-Bry0wxl_.js → register.onboard-CZY5K__u.js} +12 -12
- package/dist/{register.setup-C5d8909b.js → register.setup-CMc-wYv4.js} +12 -12
- package/dist/{register.setup-fPrs1eMy.js → register.setup-DU2rUacO.js} +35 -35
- package/dist/{register.status-health-sessions-Bg3bAzzg.js → register.status-health-sessions-DDeNkHlW.js} +13 -13
- package/dist/{register.status-health-sessions-C6FKgGFx.js → register.status-health-sessions-Dm0neK04.js} +34 -34
- package/dist/{register.subclis-BrOWQICr.js → register.subclis-D69k9OGJ.js} +12 -12
- package/dist/{replies-D9V19U2-.js → replies-B4-OBhpP.js} +2 -2
- package/dist/{replies-DqdOBkTB.js → replies-ConxSQu4.js} +2 -2
- package/dist/{replies-QloQerhz.js → replies-DPvPoRgq.js} +2 -2
- package/dist/{reply-D_FZec1Q.js → reply-B7N_xCT0.js} +202 -166
- package/dist/{run-main-BNSY40iN.js → run-main-Dw4qcIps.js} +25 -25
- package/dist/{runner-C0tJTZmp.js → runner-BJmolY3h.js} +6 -6
- package/dist/{runner-BXN4KYDK.js → runner-CR105aVj.js} +1 -1
- package/dist/{runner-DjHRFXSI.js → runner-Ct0-sE8b.js} +8 -8
- package/dist/{runner-uDZlTCm2.js → runner-t-wbbvf-.js} +4 -4
- package/dist/{sandbox-rMmahr2s.js → sandbox-BGegLZ1X.js} +1 -1
- package/dist/{sandbox-CbuJolk2.js → sandbox-CAcCcpV3.js} +1 -1
- package/dist/{sandbox-cli-C90jqh9l.js → sandbox-cli-CvvSZr3D.js} +3 -2
- package/dist/{sandbox-cli-Duc05KL9.js → sandbox-cli-GaFIkZTh.js} +3 -2
- package/dist/{security-cli-Bt0VkUtO.js → security-cli-DJpFpYUY.js} +5 -4
- package/dist/{security-cli-YGXUUBvD.js → security-cli-Vyuc8XY7.js} +5 -4
- package/dist/{send-CzE5UKr-.js → send-B9JhmJSo.js} +5 -5
- package/dist/{send-D_yJMeJa.js → send-COvqFO3S.js} +4 -4
- package/dist/{send-DEWzWqfZ.js → send-CiVBt5gu.js} +4 -4
- package/dist/{send-BeASPkFg.js → send-D3qb_2Q-.js} +4 -4
- package/dist/{send-mi3NHnwI.js → send-DBTO2dLX.js} +2 -2
- package/dist/{send-De_WCeGZ.js → send-DDt3Bdxx.js} +4 -4
- package/dist/{send-3YM-aarb.js → send-DXoJ5lC_.js} +1 -1
- package/dist/{send-Do-0Kcmv.js → send-DmlK72uJ.js} +3 -3
- package/dist/{send-BsocounR.js → send-Dz76LuDQ.js} +2 -2
- package/dist/{send-CHOArYFe.js → send-DzmRVAHq.js} +3 -3
- package/dist/{send-BVZGeP2r.js → send-LZO3UNRb.js} +3 -3
- package/dist/{send-B18gkuvz.js → send-OEyo5LFE.js} +2 -2
- package/dist/{send-D0dzPf6g.js → send-TQWniAsM.js} +2 -2
- package/dist/{send-D16XtYvC.js → send-bTMPppyJ.js} +4 -4
- package/dist/{send-D3M6pMr5.js → send-yBb6c4og.js} +5 -5
- package/dist/{server-methods-BBkI0oCw.js → server-methods-C7N7UMSW.js} +14 -14
- package/dist/{server-methods-CQo9n7_8.js → server-methods-CkOu6zha.js} +13 -13
- package/dist/{server-node-events-DBIaf_Oj.js → server-node-events-BVdEI7tT.js} +10 -10
- package/dist/{server-node-events-DXVd5rRh.js → server-node-events-DHR0gLJD.js} +30 -30
- package/dist/{session-T0JXlYWe.js → session-_ViRAnAz.js} +1 -1
- package/dist/{session-utils-Cdv2Qaq2.js → session-utils-BcI6SO4J.js} +1 -1
- package/dist/{sessions-CX93jXmG.js → sessions-Cyr_cPRu.js} +2 -2
- package/dist/{sessions-BEyCtqBB.js → sessions-DcjESPyL.js} +263 -3
- package/dist/{sessions-DJAxaVI7.js → sessions-WDdS9Yo7.js} +262 -2
- package/dist/{skill-commands-DWcJOIzP.js → skill-commands-Bc-ztbDr.js} +1 -1
- package/dist/{skill-commands-B64uavY9.js → skill-commands-D_bBwwvA.js} +1 -1
- package/dist/{skills-install-D67isO1L.js → skills-install-CKFZBTH2.js} +1 -1
- package/dist/{status-CqnXLNV0.js → status-BenJOJF2.js} +5 -5
- package/dist/{status-CsoUJxpm.js → status-C8wS7Lbr.js} +7 -7
- package/dist/{status-B77mKduK.js → status-DcY3KTFx.js} +1 -1
- package/dist/{status-Be3sgGJN.js → status-DxNQmdA8.js} +1 -1
- package/dist/{status.update-DlaskfTr.js → status.update-D40obmG1.js} +1 -1
- package/dist/{store-C0wvOkae.js → store-Bb4oiLME.js} +1 -1
- package/dist/{store-bnzGvI16.js → store-C4ZvS7QX.js} +1 -1
- package/dist/{subagent-registry-BH79W7i1.js → subagent-registry-ujHhkiDm.js} +174 -138
- package/dist/{tables-BEzT0Da4.js → tables-CjPLB3aX.js} +1 -1
- package/dist/{tables-DuZspiBu.js → tables-XnT3BCYh.js} +1 -1
- package/dist/{tables-COnZ169v.js → tables-dfFTl4Oa.js} +1 -1
- package/dist/{target-errors-7AvoVa10.js → target-errors-B_xs1J06.js} +1 -1
- package/dist/{target-errors-BbOqxMY0.js → target-errors-CL9BfceM.js} +2 -2
- package/dist/{target-errors-Be1SwYlW.js → target-errors-LR7w6--g.js} +2 -2
- package/dist/{thinking-CdlENGRW.js → thinking-EjJEKdLq.js} +1 -1
- package/dist/{thinking-W85Rb32m.js → thinking-XA7vussX.js} +1 -1
- package/dist/{tool-images-ChC2CXaN.js → tool-images-BHM4TeU5.js} +1 -1
- package/dist/{tool-images-DXB7tqWi.js → tool-images-BwAkbbBM.js} +1 -1
- package/dist/{tui-CcirlGg5.js → tui-CzysFxZ0.js} +3 -3
- package/dist/{tui-0rURH3b3.js → tui-DMKdRwFF.js} +2 -2
- package/dist/{tui-cli-hcbzeOtp.js → tui-cli-CKHu_yYJ.js} +5 -4
- package/dist/{tui-cli-D3VMk5c8.js → tui-cli-Hzw_5-oe.js} +7 -6
- package/dist/{update-check-CtckACbb.js → update-check-DK1kMuwI.js} +1 -1
- package/dist/{update-cli-Ce9xf_CT.js → update-cli-Byw3vUdU.js} +17 -17
- package/dist/{update-cli-BhPzUXNP.js → update-cli-D__K_5cn.js} +38 -38
- package/dist/{update-runner-DYnn5y5L.js → update-runner-CqciHxLK.js} +2 -2
- package/dist/{update-runner-BpQxWph5.js → update-runner-yKAKuw2W.js} +1 -1
- package/dist/{web-uh4O13Iu.js → web-B2v6AvX-.js} +31 -31
- package/dist/{web-sN6ARhg2.js → web-DJzj2HU0.js} +9 -9
- package/dist/{web-D3J3pm9B.js → web-ENDSDPaD.js} +37 -37
- package/dist/{web-07aQbQrq.js → web-cJUlI_Wb.js} +30 -30
- package/dist/{whatsapp-actions-Jfx4zcwv.js → whatsapp-actions-BcsFR5tf.js} +7 -7
- package/dist/{whatsapp-actions-BIjGyW3T.js → whatsapp-actions-CUczC854.js} +9 -9
- package/dist/{whatsapp-actions-BL7tCNC_.js → whatsapp-actions-ia2odzch.js} +12 -12
- package/docs/reference/templates/AGENTS.md +18 -0
- package/docs/reference/templates/SYMICORE.md +2 -0
- package/package.json +1 -1
- /package/dist/{accounts-8zZqL37v.js → accounts-9VRq1rY7.js} +0 -0
- /package/dist/{accounts-CWktKM8a.js → accounts-BCS-nbgN.js} +0 -0
- /package/dist/{api-key-rotation-BukD0zzl.js → api-key-rotation-erqZ9Tuc.js} +0 -0
- /package/dist/{diagnostic-session-state-Bxo4UHOL.js → diagnostic-session-state-Bu3E4Enn.js} +0 -0
- /package/dist/{diagnostic-session-state-C1vRJs5w.js → diagnostic-session-state-DmrztgHU.js} +0 -0
- /package/dist/{fetch-timeout-Db3da8yR.js → fetch-timeout-DoySHqfO.js} +0 -0
- /package/dist/{github-copilot-token-C_qUP7p5.js → github-copilot-token-BqpAEW8G.js} +0 -0
- /package/dist/{image-ops-CvJzsyvE.js → image-ops-DD37OhdR.js} +0 -0
- /package/dist/{image-ops-ByaQt43P.js → image-ops-UtlmP67m.js} +0 -0
- /package/dist/{message-channel-BQINJQIT.js → message-channel-B3YUM8IG.js} +0 -0
- /package/dist/{message-channel-Dz5lr5b0.js → message-channel-Bj7aZphL.js} +0 -0
- /package/dist/{model-catalog-DjJ9GtKX.js → model-catalog-DhaH7him.js} +0 -0
- /package/dist/{pi-model-discovery-j5tVLINv.js → pi-model-discovery-C-yOXpma.js} +0 -0
- /package/dist/{sqlite-Dx3J_aSE.js → sqlite-DhNyBVPk.js} +0 -0
- /package/dist/{tokens-BuceUQDl.js → tokens-DBCvs-Ns.js} +0 -0
- /package/dist/{tool-display-D8N3rsYt.js → tool-display-pHB3J5PK.js} +0 -0
- /package/dist/{tool-images-DvUBlqjX.js → tool-images-CLRUTPlM.js} +0 -0
- /package/dist/{transcript-events-DdnTeoR1.js → transcript-events-CJRvASY_.js} +0 -0
|
@@ -5,63 +5,63 @@ import { $ as warn, B as sleep$1, D as escapeRegExp, E as ensureDir$3, G as dang
|
|
|
5
5
|
import { a as resolveAgentModelPrimary, c as resolveDefaultAgentId, d as resolveSessionAgentIds, i as resolveAgentModelFallbacksOverride, l as resolveEffectiveModelFallbacks, n as resolveAgentConfig, o as resolveAgentSkillsFilter, r as resolveAgentDir, s as resolveAgentWorkspaceDir, t as listAgentIds, u as resolveSessionAgentId } from "./agent-scope-BxoUQqgM.js";
|
|
6
6
|
import { a as registerActiveProgressLine, i as clearActiveProgressLine, n as createNonExitingRuntime, o as unregisterActiveProgressLine, r as defaultRuntime, t as createSubsystemLogger } from "./subsystem-Bs9YvKLa.js";
|
|
7
7
|
import { S as logWarn, _ as runExec, b as logError, f as loadWorkspaceBootstrapFiles, g as runCommandWithTimeout, i as DEFAULT_IDENTITY_FILENAME, l as ensureAgentWorkspace, m as resolveSymiPackageRoot, n as DEFAULT_AGENT_WORKSPACE_DIR, r as DEFAULT_BOOTSTRAP_FILENAME, u as filterBootstrapFilesForSession, v as spawnWithFallback, x as logInfo, y as logDebug } from "./workspace-wAaHI8-5.js";
|
|
8
|
-
import { a as isSilentReplyText, i as isSilentReplyPrefixText, n as SILENT_REPLY_TOKEN,
|
|
8
|
+
import { a as isSilentReplyText, i as isSilentReplyPrefixText, n as SILENT_REPLY_TOKEN, t as HEARTBEAT_TOKEN } from "./tokens-H1H1LiSQ.js";
|
|
9
|
+
import { $ as normalizeDeliveryContext, $t as stripHeartbeatToken, A as isTransientHttpError, At as DEFAULT_UPLOAD_DIR, Bt as expandToolGroups, C as isContextOverflowError, Ct as resolveGroupSessionKey, D as isRateLimitAssistantError, Dt as registerBrowserRoutes, E as isLikelyContextOverflowError, Et as createBrowserRouteContext, F as resolveSandboxContext, Ft as resolveSandboxConfigForAgent, G as updateLastRoute, Gt as compileGlobPatterns, H as loadSessionStore, Ht as normalizeToolName, I as resolveSandboxRuntimeStatus, It as applyOwnerOnlyToolPolicy, J as isCacheEnabled, Jt as ensureSessionHeader, K as updateSessionStore, Kt as matchesAnyGlobPattern, L as extractDeliveryInfo, Lt as buildPluginToolGroups, M as parseImageSizeError, Mt as getBridgeAuthForPort, N as sanitizeUserFacingText, Nt as ensureBrowserControlAuth, O as isRawApiErrorPayload, Ot as resolveBrowserConfig, P as ensureSandboxWorkspaceForSession, Pt as resolveBrowserControlAuth, Q as mergeDeliveryContext, Qt as resolveHeartbeatPrompt, R as parseSessionThreadInfo, Rt as collectExplicitAllowlist, S as isCompactionFailureError, St as deriveSessionMetaPatch, T as isFailoverErrorMessage, Tt as resolveSessionLockMaxHoldFromTimeout, U as readSessionUpdatedAt, Ut as resolveToolProfilePolicy, V as resolveAndPersistSessionFile, Vt as mergeAlsoAllowPolicy, W as recordSessionMetaFromInbound, Wt as stripPluginOnlyAllowlist, X as deliveryContextFromSession, Xt as resolveBootstrapTotalMaxChars, Y as resolveCacheTtlMs$1, Yt as resolveBootstrapMaxChars, Z as deliveryContextKey, Zt as sanitizeGoogleTurnOrdering, _ as formatRawAssistantErrorForUi, _t as resolveFreshSessionTotalTokens, a as isMessagingToolDuplicateNormalized, at as extractToolCallNames, b as isBillingAssistantError, bt as resolveExplicitAgentSessionKey, c as extractToolCallsFromAssistant, ct as hasInterSessionUserProvenance, d as isAntigravityClaude, dt as evaluateSessionFreshness, et as normalizeSessionDeliveryFields, f as isGoogleModelApi, ft as resolveChannelResetConfig, g as formatBillingErrorMessage, gt as DEFAULT_RESET_TRIGGERS, h as formatAssistantErrorText, ht as resolveThreadFlag, it as countToolResults, j as parseImageDimensionError, jt as resolveExistingPathsWithinRoot, k as isTimeoutErrorMessage, kt as resolveProfile, l as extractToolResultId, lt as normalizeInputProvenance, m as classifyFailoverReason, mt as resolveSessionResetType, n as validateGeminiTurns, nt as archiveSessionTranscripts, o as normalizeTextForComparison, ot as INPUT_PROVENANCE_KIND_VALUES, p as BILLING_ERROR_USER_MESSAGE, pt as resolveSessionResetPolicy, q as updateSessionStoreEntry, qt as buildBootstrapContextFiles, r as pickFallbackThinkingLevel, rt as capArrayByJsonBytes, s as sanitizeSessionMessagesImages, st as applyInputProvenanceToUserMessage, t as validateAnthropicTurns, tt as normalizeAccountId$3, u as downgradeOpenAIReasoningBlocks, ut as resolveSessionKey, v as getApiErrorPayloadFingerprint, vt as canonicalizeMainSessionAlias, w as isFailoverAssistantError, wt as acquireSessionWriteLock, x as isCloudCodeAssistFormatError, xt as resolveMainSessionKey, y as isAuthAssistantError, z as appendAssistantMessageToSessionTranscript, zt as expandPolicyWithPluginGroups } from "./pi-embedded-helpers-B8JQjQlx.js";
|
|
9
10
|
import { _ as resolveDiscordAccount, a as normalizeWhatsAppTarget, c as listTelegramAccountIds, d as resolveSlackAccount, g as listEnabledDiscordAccounts, h as createDiscordActionGate, i as isWhatsAppGroupJid, l as resolveTelegramAccount, m as resolveSlackBotToken, n as listChannelPlugins, o as createTelegramActionGate, p as resolveSlackAppToken, r as normalizeChannelId$1, s as listEnabledTelegramAccounts, t as getChannelPlugin, u as resolveTelegramToken, v as normalizeDiscordToken } from "./plugins-DQYI3Fr-.js";
|
|
10
11
|
import { a as logoutWeb, i as logWebSelfId, l as readWebSelfId, p as webAuthExists, r as getWebAuthAgeMs, t as resolveWhatsAppAccount } from "./accounts-tNElYrCH.js";
|
|
11
12
|
import { t as normalizeChatType } from "./chat-type-C_KiWNAH.js";
|
|
12
13
|
import { t as parseBooleanValue$1 } from "./boolean-B8-BqKGQ.js";
|
|
13
14
|
import { n as resolveCliName, r as isTruthyEnvValue, t as formatCliCommand } from "./command-format-BaxDnULz.js";
|
|
14
|
-
import { a as resolveSlackWebClientOptions, c as buildSlackBlocksFallbackText, i as createSlackWebClient, l as parseSlackTarget, o as parseSlackBlocksInput, s as validateSlackBlocksArray, t as sendMessageSlack, u as resolveSlackChannelId } from "./send-
|
|
15
|
-
import { $ as fetchChannelPermissionsDiscord, A as unpinMessageDiscord, B as listScheduledEventsDiscord, C as editMessageDiscord, Ct as resolveTimestampMs, D as pinMessageDiscord, Dt as normalizeChannelSlug, E as listThreadsDiscord, Et as buildChannelKeyCandidates, F as fetchMemberInfoDiscord, G as uploadStickerDiscord, H as timeoutMemberDiscord, I as fetchRoleInfoDiscord, J as editChannelDiscord, K as createChannelDiscord, L as fetchVoiceStatusDiscord, M as banMemberDiscord, N as createScheduledEventDiscord, O as readMessagesDiscord, Ot as resolveChannelEntryMatchWithFallback, P as fetchChannelInfoDiscord, Q as stripUndefinedFields, R as kickMemberDiscord, S as deleteMessageDiscord, St as resolveDiscordSystemLocation, T as listPinsDiscord, Tt as applyChannelMatchMeta, U as listGuildEmojisDiscord, V as removeRoleDiscord, W as uploadEmojiDiscord, X as removeChannelPermissionDiscord, Y as moveChannelDiscord, Z as setChannelPermissionDiscord, _ as sendPollDiscord, _t as resolveDiscordShouldRequireMention, a as removeReactionDiscord, at as resolveDiscordChannelId, b as sendWebhookMessageDiscord, bt as formatDiscordReactionEmoji, c as formatDiscordComponentEventText, ct as allowListMatches$1, d as parseDiscordModalCustomId, dt as normalizeDiscordSlug, et as hasAnyGuildPermissionDiscord, f as parseDiscordModalCustomIdForCarbon, ft as resolveDiscordAllowListMatch, g as sendMessageDiscord, gt as resolveDiscordOwnerAllowFrom, h as resolveDiscordModalEntry, ht as resolveDiscordMemberAccessState, i as removeOwnReactionsDiscord, it as parseDiscordTarget, j as addRoleDiscord, k as searchMessagesDiscord, l as parseDiscordComponentCustomId, lt as isDiscordGroupAllowedByPolicy, m as resolveDiscordComponentEntry, mt as resolveDiscordGuildEntry, n as fetchReactionsDiscord, nt as createDiscordClient, o as sendDiscordComponentMessage, ot as listDiscordDirectoryGroupsLive, p as readDiscordComponentSpec, pt as resolveDiscordChannelConfigWithFallback, q as deleteChannelDiscord, r as reactMessageDiscord, rt as createDiscordRestClient, s as createDiscordFormModal, st as listDiscordDirectoryPeersLive, tt as chunkDiscordTextWithMode, u as parseDiscordComponentCustomIdForCarbon, ut as normalizeDiscordAllowList, v as sendStickerDiscord, vt as resolveGroupDmAllow, w as fetchMessageDiscord, wt as fetchDiscord, x as createThreadDiscord, xt as formatDiscordUserTag, y as sendVoiceMessageDiscord, yt as shouldEmitDiscordReactionNotification, z as listGuildChannelsDiscord } from "./send-
|
|
16
|
-
import { C as getGlobalHookRunner, S as parseInlineDirectives$1, _ as normalizeTargetForProvider, a as normalizeOutboundPayloadsForJson, b as MEDIA_TOKEN_RE, c as applyReplyThreading, d as isRenderablePayload, f as shouldSuppressMessagingToolReplies, g as normalizeChannelTargetInput, h as buildTargetResolverSignature, i as normalizeOutboundPayloads, l as filterMessagingToolDuplicates, m as resolveReplyToMode, o as normalizeReplyPayloadsForDelivery, p as createReplyToModeFilterForChannel, r as formatOutboundPayloadLog, s as applyReplyTagsToPayload, t as deliverOutboundPayloads, u as filterMessagingToolMediaDuplicates, v as throwIfAborted, w as initializeGlobalHookRunner, x as splitMediaFromOutput, y as parseReplyDirectives } from "./deliver-
|
|
17
|
-
import { a as logMessageProcessed, c as logWebhookError, d as startDiagnosticHeartbeat, f as stopDiagnosticHeartbeat, i as logLaneEnqueue, l as logWebhookProcessed, m as isDiagnosticsEnabled, o as logMessageQueued, p as emitDiagnosticEvent, r as logLaneDequeue, s as logSessionStateChange, t as diag, u as logWebhookReceived } from "./diagnostic-
|
|
18
|
-
import { r as getDiagnosticSessionState } from "./diagnostic-session-state-
|
|
19
|
-
import { n as resolveSignalAccount, t as listEnabledSignalAccounts } from "./accounts-
|
|
20
|
-
import { $ as isVoiceCompatibleAudio, A as extractTelegramLocation, B as normalizeAllowFromWithStore$1, C as buildTelegramGroupFrom, D as buildTypingThreadParams, E as buildTelegramThreadParams, F as resolveTelegramMediaPlaceholder, G as formatLocationText, H as firstDefined$1, I as resolveTelegramReplyId, J as readChannelAllowFromStore, K as toLocationContext, L as resolveTelegramStreamMode, M as normalizeForwardedContext, N as resolveTelegramForumThreadId, O as describeReplyTarget, P as resolveTelegramGroupAllowFromContext, Q as listPairingChannels, R as resolveTelegramThreadSpec, S as buildSenderName, T as buildTelegramParentPeer, U as isSenderIdAllowed, V as resolveSenderAllowMatch, W as mergeAllowFromSources, X as upsertChannelPairingRequest, Y as removeChannelAllowFromStoreEntry, Z as getPairingAdapter, _ as resolveTelegramFetch, a as reactMessageTelegram, b as buildGroupLabel, c as sendStickerTelegram, d as wasSentByBot, et as parseTelegramTarget, f as isRecoverableTelegramNetworkError, g as wrapFileReferencesInHtml, h as renderTelegramHtmlText, i as editMessageTelegram, j as hasBotMention, k as expandTextLinks, m as markdownToTelegramHtml, n as createForumTopicTelegram, o as sendMessageTelegram, p as markdownToTelegramChunks, q as addChannelAllowFromStoreEntry, r as deleteMessageTelegram, s as sendPollTelegram, t as buildInlineKeyboard, tt as resolveTelegramTargetChatType, u as resolveTelegramVoiceSend, v as splitTelegramCaption, w as buildTelegramGroupPeerId, x as buildSenderLabel, y as withTelegramApiErrorLogging, z as isSenderAllowed$1 } from "./send-
|
|
21
|
-
import { d as detectMime, f as extensionForMime, g as isGifMedia, h as isAudioFileName, i as getImageMetadata, m as imageMimeFromFormat, s as resizeToJpeg, x as mediaKindFromMime, y as MAX_IMAGE_BYTES } from "./image-ops-
|
|
22
|
-
import { A as normalizeProviderId, C as buildAllowedModelSet, D as isCliProvider, E as findNormalizedProviderValue, F as resolveSubagentSpawnModelSelection, G as DEFAULT_MODEL, H as OLLAMA_NATIVE_BASE_URL, I as resolveThinkingDefault, J as normalizeSecretInput, K as DEFAULT_PROVIDER, M as resolveConfiguredModelRef, N as resolveDefaultModelForAgent, O as modelKey, P as resolveModelRefFromString, T as buildModelAliasIndex, U as createOllamaStreamFn, W as DEFAULT_CONTEXT_TOKENS, Y as getShellPathFromLoginShell, Z as resolveShellEnvFallbackTimeoutMs, _ as ensureAuthProfileStore, a as resolveEnvApiKey, b as withFileLock, c as resolveAuthProfileOrder, d as markAuthProfileFailure, f as markAuthProfileUsed, g as markAuthProfileGood, h as listProfilesForProvider, i as resolveApiKeyForProvider, k as normalizeModelRef$2, l as getSoonestCooldownExpiry, m as dedupeProfileIds, n as getCustomProviderApiKey, o as resolveModelAuthMode, p as resolveApiKeyForProfile, q as resolveAuthProfileDisplayLabel, r as requireApiKey, t as getApiKeyForModel, u as isProfileInCooldown, v as resolveAuthStorePathForDisplay, w as buildConfiguredAllowlistKeys, y as resolveSymiAgentDir } from "./model-auth-
|
|
23
|
-
import { a as saveJsonFile, i as loadJsonFile } from "./github-copilot-token-
|
|
24
|
-
import { n as discoverModels, t as discoverAuthStorage } from "./pi-model-discovery-
|
|
25
|
-
import { a as isMarkdownCapableMessageChannel, c as resolveGatewayMessageChannel, d as GATEWAY_CLIENT_MODES, f as GATEWAY_CLIENT_NAMES, i as isInternalMessageChannel, l as resolveMessageChannel, n as isDeliverableMessageChannel, o as listDeliverableMessageChannels, r as isGatewayMessageChannel, s as normalizeMessageChannel, t as INTERNAL_MESSAGE_CHANNEL, u as GATEWAY_CLIENT_IDS } from "./message-channel-
|
|
26
|
-
import {
|
|
27
|
-
import { A as VERSION, C as getConfigValueAtPath, D as isSafeExecutableValue, E as unsetConfigValueAtPath, O as DEFAULT_SUBAGENT_MAX_SPAWN_DEPTH, S as unsetConfigOverride, T as setConfigValueAtPath, _ as parseDurationMs, a as writeConfigFile, b as resetConfigOverrides, c as TELEGRAM_COMMAND_NAME_PATTERN, f as isInboundPathAllowed, g as normalizeScpRemoteHost, h as resolveIMessageRemoteAttachmentRoots, i as resolveConfigSnapshotHash, k as resolveAgentMaxConcurrent, l as normalizeTelegramCommandName, m as resolveIMessageAttachmentRoots, n as loadConfig, o as validateConfigObjectWithPlugins, r as readConfigFileSnapshot, u as resolveTelegramCustomCommands, v as validateJsonSchemaValue, w as parseConfigPath, x as setConfigOverride, y as getConfigOverrides } from "./config-DM0K7qC1.js";
|
|
15
|
+
import { a as resolveSlackWebClientOptions, c as buildSlackBlocksFallbackText, i as createSlackWebClient, l as parseSlackTarget, o as parseSlackBlocksInput, s as validateSlackBlocksArray, t as sendMessageSlack, u as resolveSlackChannelId } from "./send-DzmRVAHq.js";
|
|
16
|
+
import { $ as fetchChannelPermissionsDiscord, A as unpinMessageDiscord, B as listScheduledEventsDiscord, C as editMessageDiscord, Ct as resolveTimestampMs, D as pinMessageDiscord, Dt as normalizeChannelSlug, E as listThreadsDiscord, Et as buildChannelKeyCandidates, F as fetchMemberInfoDiscord, G as uploadStickerDiscord, H as timeoutMemberDiscord, I as fetchRoleInfoDiscord, J as editChannelDiscord, K as createChannelDiscord, L as fetchVoiceStatusDiscord, M as banMemberDiscord, N as createScheduledEventDiscord, O as readMessagesDiscord, Ot as resolveChannelEntryMatchWithFallback, P as fetchChannelInfoDiscord, Q as stripUndefinedFields, R as kickMemberDiscord, S as deleteMessageDiscord, St as resolveDiscordSystemLocation, T as listPinsDiscord, Tt as applyChannelMatchMeta, U as listGuildEmojisDiscord, V as removeRoleDiscord, W as uploadEmojiDiscord, X as removeChannelPermissionDiscord, Y as moveChannelDiscord, Z as setChannelPermissionDiscord, _ as sendPollDiscord, _t as resolveDiscordShouldRequireMention, a as removeReactionDiscord, at as resolveDiscordChannelId, b as sendWebhookMessageDiscord, bt as formatDiscordReactionEmoji, c as formatDiscordComponentEventText, ct as allowListMatches$1, d as parseDiscordModalCustomId, dt as normalizeDiscordSlug, et as hasAnyGuildPermissionDiscord, f as parseDiscordModalCustomIdForCarbon, ft as resolveDiscordAllowListMatch, g as sendMessageDiscord, gt as resolveDiscordOwnerAllowFrom, h as resolveDiscordModalEntry, ht as resolveDiscordMemberAccessState, i as removeOwnReactionsDiscord, it as parseDiscordTarget, j as addRoleDiscord, k as searchMessagesDiscord, l as parseDiscordComponentCustomId, lt as isDiscordGroupAllowedByPolicy, m as resolveDiscordComponentEntry, mt as resolveDiscordGuildEntry, n as fetchReactionsDiscord, nt as createDiscordClient, o as sendDiscordComponentMessage, ot as listDiscordDirectoryGroupsLive, p as readDiscordComponentSpec, pt as resolveDiscordChannelConfigWithFallback, q as deleteChannelDiscord, r as reactMessageDiscord, rt as createDiscordRestClient, s as createDiscordFormModal, st as listDiscordDirectoryPeersLive, tt as chunkDiscordTextWithMode, u as parseDiscordComponentCustomIdForCarbon, ut as normalizeDiscordAllowList, v as sendStickerDiscord, vt as resolveGroupDmAllow, w as fetchMessageDiscord, wt as fetchDiscord, x as createThreadDiscord, xt as formatDiscordUserTag, y as sendVoiceMessageDiscord, yt as shouldEmitDiscordReactionNotification, z as listGuildChannelsDiscord } from "./send-yBb6c4og.js";
|
|
17
|
+
import { C as getGlobalHookRunner, S as parseInlineDirectives$1, _ as normalizeTargetForProvider, a as normalizeOutboundPayloadsForJson, b as MEDIA_TOKEN_RE, c as applyReplyThreading, d as isRenderablePayload, f as shouldSuppressMessagingToolReplies, g as normalizeChannelTargetInput, h as buildTargetResolverSignature, i as normalizeOutboundPayloads, l as filterMessagingToolDuplicates, m as resolveReplyToMode, o as normalizeReplyPayloadsForDelivery, p as createReplyToModeFilterForChannel, r as formatOutboundPayloadLog, s as applyReplyTagsToPayload, t as deliverOutboundPayloads, u as filterMessagingToolMediaDuplicates, v as throwIfAborted, w as initializeGlobalHookRunner, x as splitMediaFromOutput, y as parseReplyDirectives } from "./deliver-DGaRNkFI.js";
|
|
18
|
+
import { a as logMessageProcessed, c as logWebhookError, d as startDiagnosticHeartbeat, f as stopDiagnosticHeartbeat, i as logLaneEnqueue, l as logWebhookProcessed, m as isDiagnosticsEnabled, o as logMessageQueued, p as emitDiagnosticEvent, r as logLaneDequeue, s as logSessionStateChange, t as diag, u as logWebhookReceived } from "./diagnostic-BIVLRT_X.js";
|
|
19
|
+
import { r as getDiagnosticSessionState } from "./diagnostic-session-state-DmrztgHU.js";
|
|
20
|
+
import { n as resolveSignalAccount, t as listEnabledSignalAccounts } from "./accounts-BCS-nbgN.js";
|
|
21
|
+
import { $ as isVoiceCompatibleAudio, A as extractTelegramLocation, B as normalizeAllowFromWithStore$1, C as buildTelegramGroupFrom, D as buildTypingThreadParams, E as buildTelegramThreadParams, F as resolveTelegramMediaPlaceholder, G as formatLocationText, H as firstDefined$1, I as resolveTelegramReplyId, J as readChannelAllowFromStore, K as toLocationContext, L as resolveTelegramStreamMode, M as normalizeForwardedContext, N as resolveTelegramForumThreadId, O as describeReplyTarget, P as resolveTelegramGroupAllowFromContext, Q as listPairingChannels, R as resolveTelegramThreadSpec, S as buildSenderName, T as buildTelegramParentPeer, U as isSenderIdAllowed, V as resolveSenderAllowMatch, W as mergeAllowFromSources, X as upsertChannelPairingRequest, Y as removeChannelAllowFromStoreEntry, Z as getPairingAdapter, _ as resolveTelegramFetch, a as reactMessageTelegram, b as buildGroupLabel, c as sendStickerTelegram, d as wasSentByBot, et as parseTelegramTarget, f as isRecoverableTelegramNetworkError, g as wrapFileReferencesInHtml, h as renderTelegramHtmlText, i as editMessageTelegram, j as hasBotMention, k as expandTextLinks, m as markdownToTelegramHtml, n as createForumTopicTelegram, o as sendMessageTelegram, p as markdownToTelegramChunks, q as addChannelAllowFromStoreEntry, r as deleteMessageTelegram, s as sendPollTelegram, t as buildInlineKeyboard, tt as resolveTelegramTargetChatType, u as resolveTelegramVoiceSend, v as splitTelegramCaption, w as buildTelegramGroupPeerId, x as buildSenderLabel, y as withTelegramApiErrorLogging, z as isSenderAllowed$1 } from "./send-COvqFO3S.js";
|
|
22
|
+
import { d as detectMime, f as extensionForMime, g as isGifMedia, h as isAudioFileName, i as getImageMetadata, m as imageMimeFromFormat, s as resizeToJpeg, x as mediaKindFromMime, y as MAX_IMAGE_BYTES } from "./image-ops-DD37OhdR.js";
|
|
23
|
+
import { A as normalizeProviderId, C as buildAllowedModelSet, D as isCliProvider, E as findNormalizedProviderValue, F as resolveSubagentSpawnModelSelection, G as DEFAULT_MODEL, H as OLLAMA_NATIVE_BASE_URL, I as resolveThinkingDefault, J as normalizeSecretInput, K as DEFAULT_PROVIDER, M as resolveConfiguredModelRef, N as resolveDefaultModelForAgent, O as modelKey, P as resolveModelRefFromString, T as buildModelAliasIndex, U as createOllamaStreamFn, W as DEFAULT_CONTEXT_TOKENS, Y as getShellPathFromLoginShell, Z as resolveShellEnvFallbackTimeoutMs, _ as ensureAuthProfileStore, a as resolveEnvApiKey, b as withFileLock, c as resolveAuthProfileOrder, d as markAuthProfileFailure, f as markAuthProfileUsed, g as markAuthProfileGood, h as listProfilesForProvider, i as resolveApiKeyForProvider, k as normalizeModelRef$2, l as getSoonestCooldownExpiry, m as dedupeProfileIds, n as getCustomProviderApiKey, o as resolveModelAuthMode, p as resolveApiKeyForProfile, q as resolveAuthProfileDisplayLabel, r as requireApiKey, t as getApiKeyForModel, u as isProfileInCooldown, v as resolveAuthStorePathForDisplay, w as buildConfiguredAllowlistKeys, y as resolveSymiAgentDir } from "./model-auth-Daguh6Kb.js";
|
|
24
|
+
import { a as saveJsonFile, i as loadJsonFile } from "./github-copilot-token-BqpAEW8G.js";
|
|
25
|
+
import { n as discoverModels, t as discoverAuthStorage } from "./pi-model-discovery-C-yOXpma.js";
|
|
26
|
+
import { a as isMarkdownCapableMessageChannel, c as resolveGatewayMessageChannel, d as GATEWAY_CLIENT_MODES, f as GATEWAY_CLIENT_NAMES, i as isInternalMessageChannel, l as resolveMessageChannel, n as isDeliverableMessageChannel, o as listDeliverableMessageChannels, r as isGatewayMessageChannel, s as normalizeMessageChannel, t as INTERNAL_MESSAGE_CHANNEL, u as GATEWAY_CLIENT_IDS } from "./message-channel-Bj7aZphL.js";
|
|
27
|
+
import { A as VERSION, C as getConfigValueAtPath, D as isSafeExecutableValue, E as unsetConfigValueAtPath, O as DEFAULT_SUBAGENT_MAX_SPAWN_DEPTH, S as unsetConfigOverride, T as setConfigValueAtPath, _ as parseDurationMs, a as writeConfigFile, b as resetConfigOverrides, c as TELEGRAM_COMMAND_NAME_PATTERN, f as isInboundPathAllowed, g as normalizeScpRemoteHost, h as resolveIMessageRemoteAttachmentRoots, i as resolveConfigSnapshotHash, k as resolveAgentMaxConcurrent, l as normalizeTelegramCommandName, m as resolveIMessageAttachmentRoots, n as loadConfig, o as validateConfigObjectWithPlugins, r as readConfigFileSnapshot, u as resolveTelegramCustomCommands, v as validateJsonSchemaValue, w as parseConfigPath, x as setConfigOverride, y as getConfigOverrides } from "./config-D3XlX-h-.js";
|
|
28
28
|
import { a as applyTestPluginDefaults, c as resolveMemorySlotDecision, d as isDangerousHostEnvVarName, i as safeStatSync, n as discoverSymiPlugins, o as normalizePluginsConfig, r as isPathInside, s as resolveEnableState, t as loadPluginManifestRegistry, u as isPathInsideWithRealpath } from "./manifest-registry-D0IQ3WuX.js";
|
|
29
|
-
import { C as rawDataToString, O as DEFAULT_AI_SNAPSHOT_MAX_CHARS, T as isSecureWebSocketUrl, x as ensureChromeExtensionRelayServer } from "./chrome-
|
|
29
|
+
import { C as rawDataToString, O as DEFAULT_AI_SNAPSHOT_MAX_CHARS, T as isSecureWebSocketUrl, x as ensureChromeExtensionRelayServer } from "./chrome-2-wXJfuH.js";
|
|
30
30
|
import { c as assertSandboxPath, d as resolveSandboxedMediaSource, f as applySkillEnvOverrides, i as resolveSkillsPromptForRun, l as resolveSandboxInputPath, n as buildWorkspaceSkillSnapshot, p as applySkillEnvOverridesFromSnapshot, r as loadWorkspaceSkillEntries, s as assertMediaNotDataUrl } from "./skills-BFekKL7i.js";
|
|
31
31
|
import { n as formatErrorMessage, r as formatUncaughtError } from "./errors-BoQgnc8X.js";
|
|
32
32
|
import { i as isBlockedHostnameOrIp, o as normalizeHostname, t as SsrFBlockedError } from "./ssrf-BTMDZjHT.js";
|
|
33
|
-
import { n as getMediaDir, r as saveMediaBuffer } from "./store-
|
|
34
|
-
import { _ as normalizeAtHashSlug, a as normalizeReasoningLevel, b as normalizeStringEntriesLower, c as normalizeVerboseLevel, d as getChannelDock, f as listChannelDocks, g as resolveChannelGroupToolsPolicy, h as resolveChannelGroupRequireMention, i as normalizeElevatedLevel, l as resolveResponseUsageMode, m as resolveChannelGroupPolicy, n as formatXHighModelHint, o as normalizeThinkLevel, p as normalizeSignalMessagingTarget, s as normalizeUsageDisplay, t as formatThinkingLevels, u as supportsXHighThinking, v as normalizeHyphenSlug, y as normalizeStringEntries } from "./thinking-
|
|
33
|
+
import { n as getMediaDir, r as saveMediaBuffer } from "./store-Bb4oiLME.js";
|
|
34
|
+
import { _ as normalizeAtHashSlug, a as normalizeReasoningLevel, b as normalizeStringEntriesLower, c as normalizeVerboseLevel, d as getChannelDock, f as listChannelDocks, g as resolveChannelGroupToolsPolicy, h as resolveChannelGroupRequireMention, i as normalizeElevatedLevel, l as resolveResponseUsageMode, m as resolveChannelGroupPolicy, n as formatXHighModelHint, o as normalizeThinkLevel, p as normalizeSignalMessagingTarget, s as normalizeUsageDisplay, t as formatThinkingLevels, u as supportsXHighThinking, v as normalizeHyphenSlug, y as normalizeStringEntries } from "./thinking-EjJEKdLq.js";
|
|
35
35
|
import { n as resolveConversationLabel } from "./conversation-label-DXUkoKcB.js";
|
|
36
36
|
import { t as resolveIMessageAccount } from "./accounts-qtxJ-6em.js";
|
|
37
37
|
import { i as resolveSessionTranscriptPath, n as resolveSessionFilePath, o as resolveSessionTranscriptsDirForAgent, r as resolveSessionFilePathOptions, s as resolveStorePath, t as resolveDefaultSessionStorePath } from "./paths-DLyHUt31.js";
|
|
38
38
|
import { t as emitSessionTranscriptUpdate } from "./transcript-events-DDYvbmRV.js";
|
|
39
|
-
import { i as resolveImageSanitizationLimits, n as sanitizeImageBlocks, r as sanitizeToolResultImages } from "./tool-images-
|
|
40
|
-
import { S as ensureSymiModelsJson, _ as stripMinimaxToolCallXml, a as decodeDataUrl, b as stripReasoningTagsFromText, c as extractAssistantText$1, d as extractThinkingFromTaggedText, f as formatReasoningMessage, g as stripDowngradedToolCallText, h as promoteThinkingTagsToBlocks, i as coerceImageModelConfig, l as extractAssistantThinking, m as isAssistantMessage, o as resolveProviderVisionModelFromConfig, p as inferToolMetaFromArgs, r as coerceImageAssistantText, s as minimaxUnderstandImage, u as extractThinkingFromTaggedStream, v as stripThinkingTagsFromText, x as extractTextFromChatContent, y as resolveToolDisplay } from "./image-
|
|
39
|
+
import { i as resolveImageSanitizationLimits, n as sanitizeImageBlocks, r as sanitizeToolResultImages } from "./tool-images-BwAkbbBM.js";
|
|
40
|
+
import { S as ensureSymiModelsJson, _ as stripMinimaxToolCallXml, a as decodeDataUrl, b as stripReasoningTagsFromText, c as extractAssistantText$1, d as extractThinkingFromTaggedText, f as formatReasoningMessage, g as stripDowngradedToolCallText, h as promoteThinkingTagsToBlocks, i as coerceImageModelConfig, l as extractAssistantThinking, m as isAssistantMessage, o as resolveProviderVisionModelFromConfig, p as inferToolMetaFromArgs, r as coerceImageAssistantText, s as minimaxUnderstandImage, u as extractThinkingFromTaggedStream, v as stripThinkingTagsFromText, x as extractTextFromChatContent, y as resolveToolDisplay } from "./image-BJiE96Ml.js";
|
|
41
41
|
import { a as resolveAgentIdentity, i as resolveAckReaction, o as resolveEffectiveMessagesConfig, r as resolveResponsePrefixTemplate, s as resolveHumanDelayConfig, t as createReplyPrefixOptions } from "./reply-prefix-XlyuyChD.js";
|
|
42
|
-
import { n as resolveMemorySearchConfig } from "./manager-
|
|
42
|
+
import { n as resolveMemorySearchConfig } from "./manager-BX65xO2I.js";
|
|
43
43
|
import { d as listMemoryFiles, f as normalizeExtraMemoryPaths, g as runTasksWithConcurrency } from "./sqlite-DRbx2dhW.js";
|
|
44
44
|
import { n as retryAsync } from "./retry-Cly39XZB.js";
|
|
45
|
-
import { a as createActionGate, c as jsonResult, d as readReactionParams, f as readStringArrayParam, l as parseAvailableTags, m as readStringParam, n as missingTargetError, o as imageResult, p as readStringOrNumberParam, r as unknownTargetError, s as imageResultFromFile, t as ambiguousTargetError, u as readNumberParam } from "./target-errors-
|
|
46
|
-
import { a as chunkText, c as resolveChunkMode, d as isSafeFenceBreak, f as parseFenceSpans, i as chunkMarkdownTextWithMode, l as resolveTextChunkLimit, o as chunkTextWithMode, r as chunkMarkdownText, t as chunkByNewline, u as findFenceSpanAt } from "./chunk-
|
|
45
|
+
import { a as createActionGate, c as jsonResult, d as readReactionParams, f as readStringArrayParam, l as parseAvailableTags, m as readStringParam, n as missingTargetError, o as imageResult, p as readStringOrNumberParam, r as unknownTargetError, s as imageResultFromFile, t as ambiguousTargetError, u as readNumberParam } from "./target-errors-CL9BfceM.js";
|
|
46
|
+
import { a as chunkText, c as resolveChunkMode, d as isSafeFenceBreak, f as parseFenceSpans, i as chunkMarkdownTextWithMode, l as resolveTextChunkLimit, o as chunkTextWithMode, r as chunkMarkdownText, t as chunkByNewline, u as findFenceSpanAt } from "./chunk-BPSLqkZN.js";
|
|
47
47
|
import { n as resolveMarkdownTableMode } from "./markdown-tables-iMQQZu4Q.js";
|
|
48
48
|
import { n as fetchWithTimeout, t as bindAbortRelay } from "./fetch-timeout-DL3f_O53.js";
|
|
49
|
-
import { a as readResponseWithLimit, i as fetchRemoteMedia, n as getDefaultMediaLocalRoots, o as fetchWithSsrFGuard, t as getAgentScopedMediaLocalRoots } from "./local-roots-
|
|
50
|
-
import { a as loadWebMedia, i as getDefaultLocalRoots } from "./ir-
|
|
51
|
-
import { _ as resolveNativeCommandsEnabled, a as listChatCommandsForConfig, c as normalizeCommandBody, d as resolveCommandArgMenu, f as serializeCommandArgs, g as isRestartEnabled, h as isNativeCommandsExplicitlyDisabled, i as listChatCommands, l as parseCommandArgs, m as isCommandFlagEnabled, o as listNativeCommandSpecs, p as shouldHandleTextCommands, r as findCommandByNativeName, s as listNativeCommandSpecsForConfig, t as buildCommandTextFromArgs, u as resolveCommandArgChoices, v as resolveNativeSkillsEnabled } from "./commands-registry-
|
|
52
|
-
import { c as getSkillsSnapshotVersion, d as createAsyncLock, f as readJsonFile, i as resolveSkillCommandInvocation, l as pruneExpiredPending, n as listSkillCommandsForAgents, o as getRemoteSkillEligibility, p as writeJsonAtomic, r as listSkillCommandsForWorkspace, s as ensureSkillsWatcher, t as listReservedChatSlashCommandNames, u as resolvePairingPaths } from "./skill-commands-
|
|
49
|
+
import { a as readResponseWithLimit, i as fetchRemoteMedia, n as getDefaultMediaLocalRoots, o as fetchWithSsrFGuard, t as getAgentScopedMediaLocalRoots } from "./local-roots-Dg0r0pJL.js";
|
|
50
|
+
import { a as loadWebMedia, i as getDefaultLocalRoots } from "./ir-B4l25ISI.js";
|
|
51
|
+
import { _ as resolveNativeCommandsEnabled, a as listChatCommandsForConfig, c as normalizeCommandBody, d as resolveCommandArgMenu, f as serializeCommandArgs, g as isRestartEnabled, h as isNativeCommandsExplicitlyDisabled, i as listChatCommands, l as parseCommandArgs, m as isCommandFlagEnabled, o as listNativeCommandSpecs, p as shouldHandleTextCommands, r as findCommandByNativeName, s as listNativeCommandSpecsForConfig, t as buildCommandTextFromArgs, u as resolveCommandArgChoices, v as resolveNativeSkillsEnabled } from "./commands-registry-CZ5P8CpC.js";
|
|
52
|
+
import { c as getSkillsSnapshotVersion, d as createAsyncLock, f as readJsonFile, i as resolveSkillCommandInvocation, l as pruneExpiredPending, n as listSkillCommandsForAgents, o as getRemoteSkillEligibility, p as writeJsonAtomic, r as listSkillCommandsForWorkspace, s as ensureSkillsWatcher, t as listReservedChatSlashCommandNames, u as resolvePairingPaths } from "./skill-commands-D_bBwwvA.js";
|
|
53
53
|
import { r as normalizeInboundTextNewlines, t as finalizeInboundContext } from "./inbound-context-BlHX0H3E.js";
|
|
54
|
-
import { _ as resolveMediaUnderstandingScope, a as resolveMediaAttachmentLocalRoots, c as loadModelCatalog, d as resolveAttachmentKind, f as buildRandomTempFilePath, g as normalizeMediaUnderstandingChatType, h as resolveTimeoutMs$1, i as resolveAutoImageModel, l as modelSupportsVision, m as resolveConcurrency, n as createMediaAttachmentCache, o as runCapability, p as registerUnhandledRejectionHandler, r as normalizeMediaAttachments, s as findModelInCatalog, t as buildProviderRegistry, v as CLI_OUTPUT_MAX_BUFFER, y as applyTemplate } from "./runner-
|
|
54
|
+
import { _ as resolveMediaUnderstandingScope, a as resolveMediaAttachmentLocalRoots, c as loadModelCatalog, d as resolveAttachmentKind, f as buildRandomTempFilePath, g as normalizeMediaUnderstandingChatType, h as resolveTimeoutMs$1, i as resolveAutoImageModel, l as modelSupportsVision, m as resolveConcurrency, n as createMediaAttachmentCache, o as runCapability, p as registerUnhandledRejectionHandler, r as normalizeMediaAttachments, s as findModelInCatalog, t as buildProviderRegistry, v as CLI_OUTPUT_MAX_BUFFER, y as applyTemplate } from "./runner-Ct0-sE8b.js";
|
|
55
55
|
import { n as wrapFetchWithAbortSignal, t as resolveFetch } from "./fetch-Bso4i15F.js";
|
|
56
56
|
import { n as recordCommandPoll, r as resetCommandPollCount } from "./command-poll-backoff-Bup9wS1y.js";
|
|
57
57
|
import { n as recordChannelActivity, r as createDiscordRetryRunner, t as getChannelActivity } from "./channel-activity-CsM_hJ_s.js";
|
|
58
58
|
import { n as normalizePollInput } from "./polls-CCuCaqgv.js";
|
|
59
|
-
import { t as convertMarkdownTables } from "./tables-
|
|
60
|
-
import { a as resolveSignalRpcContext, c as streamSignalEvents, n as sendReadReceiptSignal, o as signalCheck, r as sendTypingSignal, s as signalRpcRequest, t as sendMessageSignal } from "./send-
|
|
61
|
-
import { a as formatIMessageChatTarget, c as parseIMessageTarget, i as DEFAULT_IMESSAGE_PROBE_TIMEOUT_MS, o as isAllowedIMessageSender, r as createIMessageRpcClient, s as normalizeIMessageHandle, t as sendMessageIMessage } from "./send-
|
|
59
|
+
import { t as convertMarkdownTables } from "./tables-XnT3BCYh.js";
|
|
60
|
+
import { a as resolveSignalRpcContext, c as streamSignalEvents, n as sendReadReceiptSignal, o as signalCheck, r as sendTypingSignal, s as signalRpcRequest, t as sendMessageSignal } from "./send-B9JhmJSo.js";
|
|
61
|
+
import { a as formatIMessageChatTarget, c as parseIMessageTarget, i as DEFAULT_IMESSAGE_PROBE_TIMEOUT_MS, o as isAllowedIMessageSender, r as createIMessageRpcClient, s as normalizeIMessageHandle, t as sendMessageIMessage } from "./send-D3qb_2Q-.js";
|
|
62
62
|
import { n as resolveAgentRoute, t as buildAgentSessionKey } from "./resolve-route-CZ-1eqw0.js";
|
|
63
63
|
import { t as makeProxyFetch } from "./proxy-CBJ1upuz.js";
|
|
64
|
-
import { a as createReplyReferencePlanner, i as resolveSlackThreadTs, n as deliverReplies$3, t as createSlackReplyDeliveryPlan } from "./replies-
|
|
64
|
+
import { a as createReplyReferencePlanner, i as resolveSlackThreadTs, n as deliverReplies$3, t as createSlackReplyDeliveryPlan } from "./replies-B4-OBhpP.js";
|
|
65
65
|
import { t as getActiveWebListener } from "./active-listener-C9r8ZB9m.js";
|
|
66
66
|
import { createRequire } from "node:module";
|
|
67
67
|
import * as fs$2 from "node:fs/promises";
|
|
@@ -81,7 +81,7 @@ import { EdgeTTS } from "node-edge-tts";
|
|
|
81
81
|
import AjvPkg from "ajv";
|
|
82
82
|
import { createServer } from "node:http";
|
|
83
83
|
import { ProxyAgent, fetch as fetch$1 } from "undici";
|
|
84
|
-
import WebSocket
|
|
84
|
+
import WebSocket, { WebSocket as WebSocket$1 } from "ws";
|
|
85
85
|
import { Buffer as Buffer$1 } from "node:buffer";
|
|
86
86
|
import { createJiti } from "jiti";
|
|
87
87
|
import { Type } from "@sinclair/typebox";
|
|
@@ -102,101 +102,6 @@ import { run, sequentialize } from "@grammyjs/runner";
|
|
|
102
102
|
import { apiThrottler } from "@grammyjs/transformer-throttler";
|
|
103
103
|
import { EventEmitter } from "node:events";
|
|
104
104
|
|
|
105
|
-
//#region src/auto-reply/heartbeat.ts
|
|
106
|
-
const HEARTBEAT_PROMPT = "Read SYMIPULSE.md if it exists (workspace context). Follow it strictly. Do not infer or repeat old tasks from prior chats. If nothing needs attention, reply SYMIPULSE_OK.";
|
|
107
|
-
const DEFAULT_HEARTBEAT_ACK_MAX_CHARS = 300;
|
|
108
|
-
function resolveHeartbeatPrompt(raw) {
|
|
109
|
-
return (typeof raw === "string" ? raw.trim() : "") || HEARTBEAT_PROMPT;
|
|
110
|
-
}
|
|
111
|
-
function stripTokenAtEdges(raw) {
|
|
112
|
-
let text = raw.trim();
|
|
113
|
-
if (!text) return {
|
|
114
|
-
text: "",
|
|
115
|
-
didStrip: false
|
|
116
|
-
};
|
|
117
|
-
const token = SYMIPULSE_TOKEN;
|
|
118
|
-
const tokenAtEndWithOptionalTrailingPunctuation = new RegExp(`${escapeRegExp(token)}[^\\w]{0,4}$`);
|
|
119
|
-
if (!text.includes(token)) return {
|
|
120
|
-
text,
|
|
121
|
-
didStrip: false
|
|
122
|
-
};
|
|
123
|
-
let didStrip = false;
|
|
124
|
-
let changed = true;
|
|
125
|
-
while (changed) {
|
|
126
|
-
changed = false;
|
|
127
|
-
const next = text.trim();
|
|
128
|
-
if (next.startsWith(token)) {
|
|
129
|
-
text = next.slice(token.length).trimStart();
|
|
130
|
-
didStrip = true;
|
|
131
|
-
changed = true;
|
|
132
|
-
continue;
|
|
133
|
-
}
|
|
134
|
-
if (tokenAtEndWithOptionalTrailingPunctuation.test(next)) {
|
|
135
|
-
const idx = next.lastIndexOf(token);
|
|
136
|
-
const before = next.slice(0, idx).trimEnd();
|
|
137
|
-
if (!before) text = "";
|
|
138
|
-
else text = `${before}${next.slice(idx + token.length).trimStart()}`.trimEnd();
|
|
139
|
-
didStrip = true;
|
|
140
|
-
changed = true;
|
|
141
|
-
}
|
|
142
|
-
}
|
|
143
|
-
return {
|
|
144
|
-
text: text.replace(/\s+/g, " ").trim(),
|
|
145
|
-
didStrip
|
|
146
|
-
};
|
|
147
|
-
}
|
|
148
|
-
function stripHeartbeatToken(raw, opts = {}) {
|
|
149
|
-
if (!raw) return {
|
|
150
|
-
shouldSkip: true,
|
|
151
|
-
text: "",
|
|
152
|
-
didStrip: false
|
|
153
|
-
};
|
|
154
|
-
const trimmed = raw.trim();
|
|
155
|
-
if (!trimmed) return {
|
|
156
|
-
shouldSkip: true,
|
|
157
|
-
text: "",
|
|
158
|
-
didStrip: false
|
|
159
|
-
};
|
|
160
|
-
const mode = opts.mode ?? "message";
|
|
161
|
-
const maxAckCharsRaw = opts.maxAckChars;
|
|
162
|
-
const parsedAckChars = typeof maxAckCharsRaw === "string" ? Number(maxAckCharsRaw) : maxAckCharsRaw;
|
|
163
|
-
const maxAckChars = Math.max(0, typeof parsedAckChars === "number" && Number.isFinite(parsedAckChars) ? parsedAckChars : DEFAULT_HEARTBEAT_ACK_MAX_CHARS);
|
|
164
|
-
const stripMarkup = (text) => text.replace(/<[^>]*>/g, " ").replace(/ /gi, " ").replace(/^[*`~_]+/, "").replace(/[*`~_]+$/, "");
|
|
165
|
-
const trimmedNormalized = stripMarkup(trimmed);
|
|
166
|
-
if (!(trimmed.includes(SYMIPULSE_TOKEN) || trimmedNormalized.includes(SYMIPULSE_TOKEN))) return {
|
|
167
|
-
shouldSkip: false,
|
|
168
|
-
text: trimmed,
|
|
169
|
-
didStrip: false
|
|
170
|
-
};
|
|
171
|
-
const strippedOriginal = stripTokenAtEdges(trimmed);
|
|
172
|
-
const strippedNormalized = stripTokenAtEdges(trimmedNormalized);
|
|
173
|
-
const picked = strippedOriginal.didStrip && strippedOriginal.text ? strippedOriginal : strippedNormalized;
|
|
174
|
-
if (!picked.didStrip) return {
|
|
175
|
-
shouldSkip: false,
|
|
176
|
-
text: trimmed,
|
|
177
|
-
didStrip: false
|
|
178
|
-
};
|
|
179
|
-
if (!picked.text) return {
|
|
180
|
-
shouldSkip: true,
|
|
181
|
-
text: "",
|
|
182
|
-
didStrip: true
|
|
183
|
-
};
|
|
184
|
-
const rest = picked.text.trim();
|
|
185
|
-
if (mode === "heartbeat") {
|
|
186
|
-
if (rest.length <= maxAckChars) return {
|
|
187
|
-
shouldSkip: true,
|
|
188
|
-
text: "",
|
|
189
|
-
didStrip: true
|
|
190
|
-
};
|
|
191
|
-
}
|
|
192
|
-
return {
|
|
193
|
-
shouldSkip: false,
|
|
194
|
-
text: rest,
|
|
195
|
-
didStrip: true
|
|
196
|
-
};
|
|
197
|
-
}
|
|
198
|
-
|
|
199
|
-
//#endregion
|
|
200
105
|
//#region src/channels/allowlist-match.ts
|
|
201
106
|
function formatAllowlistMatchMeta(match) {
|
|
202
107
|
return `matchKey=${match?.matchKey ?? "none"} matchSource=${match?.matchSource ?? "none"}`;
|
|
@@ -3474,7 +3379,7 @@ async function getMemorySearchManager(params) {
|
|
|
3474
3379
|
const wrapper = new FallbackMemoryManager({
|
|
3475
3380
|
primary,
|
|
3476
3381
|
fallbackFactory: async () => {
|
|
3477
|
-
const { MemoryIndexManager } = await import("./manager-
|
|
3382
|
+
const { MemoryIndexManager } = await import("./manager-BX65xO2I.js").then((n) => n.t);
|
|
3478
3383
|
return await MemoryIndexManager.get(params);
|
|
3479
3384
|
}
|
|
3480
3385
|
}, () => QMD_MANAGER_CACHE.delete(cacheKey));
|
|
@@ -3487,7 +3392,7 @@ async function getMemorySearchManager(params) {
|
|
|
3487
3392
|
}
|
|
3488
3393
|
}
|
|
3489
3394
|
try {
|
|
3490
|
-
const { MemoryIndexManager } = await import("./manager-
|
|
3395
|
+
const { MemoryIndexManager } = await import("./manager-BX65xO2I.js").then((n) => n.t);
|
|
3491
3396
|
return { manager: await MemoryIndexManager.get(params) };
|
|
3492
3397
|
} catch (err) {
|
|
3493
3398
|
return {
|
|
@@ -5715,7 +5620,7 @@ var GatewayClient = class {
|
|
|
5715
5620
|
if (fingerprint !== expected) return /* @__PURE__ */ new Error("gateway tls fingerprint mismatch");
|
|
5716
5621
|
});
|
|
5717
5622
|
}
|
|
5718
|
-
this.ws = new WebSocket(url, wsOptions);
|
|
5623
|
+
this.ws = new WebSocket$1(url, wsOptions);
|
|
5719
5624
|
this.ws.on("open", () => {
|
|
5720
5625
|
if (url.startsWith("wss://") && this.opts.tlsFingerprint) {
|
|
5721
5626
|
const tlsError = this.validateTlsFingerprint();
|
|
@@ -5934,7 +5839,7 @@ var GatewayClient = class {
|
|
|
5934
5839
|
return null;
|
|
5935
5840
|
}
|
|
5936
5841
|
async request(method, params, opts) {
|
|
5937
|
-
if (!this.ws || this.ws.readyState !== WebSocket.OPEN) throw new Error("gateway not connected");
|
|
5842
|
+
if (!this.ws || this.ws.readyState !== WebSocket$1.OPEN) throw new Error("gateway not connected");
|
|
5938
5843
|
const id = randomUUID();
|
|
5939
5844
|
const frame = {
|
|
5940
5845
|
type: "req",
|
|
@@ -7200,7 +7105,7 @@ async function routeReply(params) {
|
|
|
7200
7105
|
const resolvedReplyToId = replyToId ?? (channelId === "slack" && threadId != null && threadId !== "" ? String(threadId) : void 0);
|
|
7201
7106
|
const resolvedThreadId = channelId === "slack" ? null : threadId ?? null;
|
|
7202
7107
|
try {
|
|
7203
|
-
const { deliverOutboundPayloads } = await import("./deliver-
|
|
7108
|
+
const { deliverOutboundPayloads } = await import("./deliver-DGaRNkFI.js").then((n) => n.n);
|
|
7204
7109
|
return {
|
|
7205
7110
|
ok: true,
|
|
7206
7111
|
messageId: (await deliverOutboundPayloads({
|
|
@@ -12435,7 +12340,7 @@ const MODEL_CACHE = /* @__PURE__ */ new Map();
|
|
|
12435
12340
|
await ensureSymiModelsJson(cfg);
|
|
12436
12341
|
} catch {}
|
|
12437
12342
|
try {
|
|
12438
|
-
const { discoverAuthStorage, discoverModels } = await import("./pi-model-discovery-
|
|
12343
|
+
const { discoverAuthStorage, discoverModels } = await import("./pi-model-discovery-C-yOXpma.js").then((n) => n.r);
|
|
12439
12344
|
const agentDir = resolveSymiAgentDir();
|
|
12440
12345
|
const modelRegistry = discoverModels(discoverAuthStorage(agentDir), agentDir);
|
|
12441
12346
|
applyDiscoveredContextWindows({
|
|
@@ -12653,7 +12558,7 @@ async function createModelSelectionState(params) {
|
|
|
12653
12558
|
}
|
|
12654
12559
|
}
|
|
12655
12560
|
if (sessionEntry && sessionStore && sessionKey && sessionEntry.authProfileOverride) {
|
|
12656
|
-
const { ensureAuthProfileStore } = await import("./model-auth-
|
|
12561
|
+
const { ensureAuthProfileStore } = await import("./model-auth-Daguh6Kb.js").then((n) => n.s);
|
|
12657
12562
|
const profile = ensureAuthProfileStore(void 0, { allowKeychainPrompt: false }).profiles[sessionEntry.authProfileOverride];
|
|
12658
12563
|
const providerKey = normalizeProviderId(provider);
|
|
12659
12564
|
if (!profile || normalizeProviderId(profile.provider) !== providerKey) await clearSessionAuthProfileOverride({
|
|
@@ -41573,7 +41478,7 @@ async function deliverSessionMaintenanceWarning(params) {
|
|
|
41573
41478
|
return;
|
|
41574
41479
|
}
|
|
41575
41480
|
try {
|
|
41576
|
-
const { deliverOutboundPayloads } = await import("./deliver-
|
|
41481
|
+
const { deliverOutboundPayloads } = await import("./deliver-DGaRNkFI.js").then((n) => n.n);
|
|
41577
41482
|
await deliverOutboundPayloads({
|
|
41578
41483
|
cfg: params.cfg,
|
|
41579
41484
|
channel,
|
|
@@ -45016,7 +44921,7 @@ async function describeStickerImage(params) {
|
|
|
45016
44921
|
logVerbose(`telegram: describing sticker with ${provider}/${model}`);
|
|
45017
44922
|
try {
|
|
45018
44923
|
const buffer = await fs.readFile(imagePath);
|
|
45019
|
-
const { describeImageWithModel } = await import("./image-
|
|
44924
|
+
const { describeImageWithModel } = await import("./image-BJiE96Ml.js").then((n) => n.n);
|
|
45020
44925
|
return (await describeImageWithModel({
|
|
45021
44926
|
buffer,
|
|
45022
44927
|
fileName: "sticker.webp",
|
|
@@ -45439,7 +45344,7 @@ function createWhatsAppLoginTool() {
|
|
|
45439
45344
|
force: Type.Optional(Type.Boolean())
|
|
45440
45345
|
}),
|
|
45441
45346
|
execute: async (_toolCallId, args) => {
|
|
45442
|
-
const { startWebLoginWithQr, waitForWebLogin } = await import("./login-qr-
|
|
45347
|
+
const { startWebLoginWithQr, waitForWebLogin } = await import("./login-qr-DWlyS1Bc.js");
|
|
45443
45348
|
if ((args?.action ?? "start") === "wait") {
|
|
45444
45349
|
const result = await waitForWebLogin({ timeoutMs: typeof args.timeoutMs === "number" ? args.timeoutMs : void 0 });
|
|
45445
45350
|
return {
|
|
@@ -47477,7 +47382,7 @@ async function preflightDiscordMessage(params) {
|
|
|
47477
47382
|
let preflightTranscript;
|
|
47478
47383
|
const hasAudioAttachment = message.attachments?.some((att) => att.contentType?.startsWith("audio/"));
|
|
47479
47384
|
if (!isDirectMessage && shouldRequireMention && hasAudioAttachment && !baseText && mentionRegexes.length > 0) try {
|
|
47480
|
-
const { transcribeFirstAudio } = await import("./audio-preflight-
|
|
47385
|
+
const { transcribeFirstAudio } = await import("./audio-preflight-Bk54IW__.js");
|
|
47481
47386
|
const audioPaths = message.attachments?.filter((att) => att.contentType?.startsWith("audio/")).map((att) => att.url) ?? [];
|
|
47482
47387
|
if (audioPaths.length > 0) preflightTranscript = await transcribeFirstAudio({
|
|
47483
47388
|
ctx: {
|
|
@@ -51483,27 +51388,27 @@ function isVoiceChannelType(type) {
|
|
|
51483
51388
|
function createDefaultDeps() {
|
|
51484
51389
|
return {
|
|
51485
51390
|
sendMessageWhatsApp: async (...args) => {
|
|
51486
|
-
const { sendMessageWhatsApp } = await import("./web-
|
|
51391
|
+
const { sendMessageWhatsApp } = await import("./web-ENDSDPaD.js");
|
|
51487
51392
|
return await sendMessageWhatsApp(...args);
|
|
51488
51393
|
},
|
|
51489
51394
|
sendMessageTelegram: async (...args) => {
|
|
51490
|
-
const { sendMessageTelegram } = await import("./send-
|
|
51395
|
+
const { sendMessageTelegram } = await import("./send-COvqFO3S.js").then((n) => n.l);
|
|
51491
51396
|
return await sendMessageTelegram(...args);
|
|
51492
51397
|
},
|
|
51493
51398
|
sendMessageDiscord: async (...args) => {
|
|
51494
|
-
const { sendMessageDiscord } = await import("./send-
|
|
51399
|
+
const { sendMessageDiscord } = await import("./send-yBb6c4og.js").then((n) => n.t);
|
|
51495
51400
|
return await sendMessageDiscord(...args);
|
|
51496
51401
|
},
|
|
51497
51402
|
sendMessageSlack: async (...args) => {
|
|
51498
|
-
const { sendMessageSlack } = await import("./send-
|
|
51403
|
+
const { sendMessageSlack } = await import("./send-DzmRVAHq.js").then((n) => n.n);
|
|
51499
51404
|
return await sendMessageSlack(...args);
|
|
51500
51405
|
},
|
|
51501
51406
|
sendMessageSignal: async (...args) => {
|
|
51502
|
-
const { sendMessageSignal } = await import("./send-
|
|
51407
|
+
const { sendMessageSignal } = await import("./send-B9JhmJSo.js").then((n) => n.i);
|
|
51503
51408
|
return await sendMessageSignal(...args);
|
|
51504
51409
|
},
|
|
51505
51410
|
sendMessageIMessage: async (...args) => {
|
|
51506
|
-
const { sendMessageIMessage } = await import("./send-
|
|
51411
|
+
const { sendMessageIMessage } = await import("./send-D3qb_2Q-.js").then((n) => n.n);
|
|
51507
51412
|
return await sendMessageIMessage(...args);
|
|
51508
51413
|
}
|
|
51509
51414
|
};
|
|
@@ -54387,7 +54292,7 @@ function createDiscordGatewayPlugin(params) {
|
|
|
54387
54292
|
super(options);
|
|
54388
54293
|
}
|
|
54389
54294
|
createWebSocket(url) {
|
|
54390
|
-
return new WebSocket
|
|
54295
|
+
return new WebSocket(url, { agent });
|
|
54391
54296
|
}
|
|
54392
54297
|
}
|
|
54393
54298
|
return new ProxyGatewayPlugin();
|
|
@@ -61929,7 +61834,7 @@ function readSlackExternalArgMenuToken(raw) {
|
|
|
61929
61834
|
}
|
|
61930
61835
|
let commandsRegistry;
|
|
61931
61836
|
async function getCommandsRegistry() {
|
|
61932
|
-
if (!commandsRegistry) commandsRegistry = await import("./commands-registry-
|
|
61837
|
+
if (!commandsRegistry) commandsRegistry = await import("./commands-registry-CZ5P8CpC.js").then((n) => n.n);
|
|
61933
61838
|
return commandsRegistry;
|
|
61934
61839
|
}
|
|
61935
61840
|
function encodeSlackCommandArgValue(parts) {
|
|
@@ -62332,8 +62237,8 @@ async function registerSlackMonitorSlashCommands(params) {
|
|
|
62332
62237
|
});
|
|
62333
62238
|
const deliverSlashPayloads = async (replies) => {
|
|
62334
62239
|
const [{ deliverSlackSlashReplies }, { resolveChunkMode }, { resolveMarkdownTableMode }] = await Promise.all([
|
|
62335
|
-
import("./replies-
|
|
62336
|
-
import("./chunk-
|
|
62240
|
+
import("./replies-B4-OBhpP.js").then((n) => n.r),
|
|
62241
|
+
import("./chunk-BPSLqkZN.js").then((n) => n.s),
|
|
62337
62242
|
import("./markdown-tables-iMQQZu4Q.js").then((n) => n.t)
|
|
62338
62243
|
]);
|
|
62339
62244
|
await deliverSlackSlashReplies({
|
|
@@ -62387,7 +62292,7 @@ async function registerSlackMonitorSlashCommands(params) {
|
|
|
62387
62292
|
let nativeCommands = [];
|
|
62388
62293
|
if (nativeEnabled) {
|
|
62389
62294
|
reg = await getCommandsRegistry();
|
|
62390
|
-
const skillCommands = nativeSkillsEnabled ? (await import("./skill-commands-
|
|
62295
|
+
const skillCommands = nativeSkillsEnabled ? (await import("./skill-commands-D_bBwwvA.js").then((n) => n.a)).listSkillCommandsForAgents({ cfg }) : [];
|
|
62391
62296
|
nativeCommands = reg.listNativeCommandSpecsForConfig(cfg, {
|
|
62392
62297
|
skillCommands,
|
|
62393
62298
|
provider: "slack"
|
|
@@ -64605,7 +64510,7 @@ const buildTelegramMessageContext = async ({ primaryCtx, allMedia, storeAllowFro
|
|
|
64605
64510
|
const hasAudio = allMedia.some((media) => media.contentType?.startsWith("audio/"));
|
|
64606
64511
|
let preflightTranscript;
|
|
64607
64512
|
if (isGroup && requireMention && hasAudio && !hasUserText && mentionRegexes.length > 0) try {
|
|
64608
|
-
const { transcribeFirstAudio } = await import("./audio-preflight-
|
|
64513
|
+
const { transcribeFirstAudio } = await import("./audio-preflight-Bk54IW__.js");
|
|
64609
64514
|
preflightTranscript = await transcribeFirstAudio({
|
|
64610
64515
|
ctx: {
|
|
64611
64516
|
MediaPaths: allMedia.length > 0 ? allMedia.map((m) => m.path) : void 0,
|
|
@@ -66750,23 +66655,23 @@ let webLoginQrPromise = null;
|
|
|
66750
66655
|
let webChannelPromise = null;
|
|
66751
66656
|
let whatsappActionsPromise = null;
|
|
66752
66657
|
function loadWebOutbound() {
|
|
66753
|
-
webOutboundPromise ??= import("./outbound-
|
|
66658
|
+
webOutboundPromise ??= import("./outbound-DpGc1neG.js").then((n) => n.t);
|
|
66754
66659
|
return webOutboundPromise;
|
|
66755
66660
|
}
|
|
66756
66661
|
function loadWebLogin() {
|
|
66757
|
-
webLoginPromise ??= import("./login-
|
|
66662
|
+
webLoginPromise ??= import("./login-DNi-TGJT.js").then((n) => n.n);
|
|
66758
66663
|
return webLoginPromise;
|
|
66759
66664
|
}
|
|
66760
66665
|
function loadWebLoginQr() {
|
|
66761
|
-
webLoginQrPromise ??= import("./login-qr-
|
|
66666
|
+
webLoginQrPromise ??= import("./login-qr-DWlyS1Bc.js");
|
|
66762
66667
|
return webLoginQrPromise;
|
|
66763
66668
|
}
|
|
66764
66669
|
function loadWebChannel() {
|
|
66765
|
-
webChannelPromise ??= import("./web-
|
|
66670
|
+
webChannelPromise ??= import("./web-ENDSDPaD.js");
|
|
66766
66671
|
return webChannelPromise;
|
|
66767
66672
|
}
|
|
66768
66673
|
function loadWhatsAppActions() {
|
|
66769
|
-
whatsappActionsPromise ??= import("./whatsapp-actions-
|
|
66674
|
+
whatsappActionsPromise ??= import("./whatsapp-actions-ia2odzch.js");
|
|
66770
66675
|
return whatsappActionsPromise;
|
|
66771
66676
|
}
|
|
66772
66677
|
function createPluginRuntime() {
|
|
@@ -68044,7 +67949,7 @@ function shouldEmitLoopWarning(state, warningKey, count) {
|
|
|
68044
67949
|
async function recordLoopOutcome(args) {
|
|
68045
67950
|
if (!args.ctx?.sessionKey) return;
|
|
68046
67951
|
try {
|
|
68047
|
-
const { getDiagnosticSessionState } = await import("./diagnostic-session-state-
|
|
67952
|
+
const { getDiagnosticSessionState } = await import("./diagnostic-session-state-DmrztgHU.js").then((n) => n.n);
|
|
68048
67953
|
const { recordToolCallOutcome } = await import("./tool-loop-detection-Cs8_HCsx.js");
|
|
68049
67954
|
recordToolCallOutcome(getDiagnosticSessionState({
|
|
68050
67955
|
sessionKey: args.ctx.sessionKey,
|
|
@@ -68065,8 +67970,8 @@ async function runBeforeToolCallHook(args) {
|
|
|
68065
67970
|
const toolName = normalizeToolName(args.toolName || "tool");
|
|
68066
67971
|
const params = args.params;
|
|
68067
67972
|
if (args.ctx?.sessionKey) {
|
|
68068
|
-
const { getDiagnosticSessionState } = await import("./diagnostic-session-state-
|
|
68069
|
-
const { logToolLoopAction } = await import("./diagnostic-
|
|
67973
|
+
const { getDiagnosticSessionState } = await import("./diagnostic-session-state-DmrztgHU.js").then((n) => n.n);
|
|
67974
|
+
const { logToolLoopAction } = await import("./diagnostic-BIVLRT_X.js").then((n) => n.n);
|
|
68070
67975
|
const { detectToolCallLoop, recordToolCall } = await import("./tool-loop-detection-Cs8_HCsx.js");
|
|
68071
67976
|
const sessionState = getDiagnosticSessionState({
|
|
68072
67977
|
sessionKey: args.ctx.sessionKey,
|
|
@@ -71928,7 +71833,7 @@ async function compactEmbeddedPiSessionDirect(params) {
|
|
|
71928
71833
|
if (!apiKeyInfo.apiKey) {
|
|
71929
71834
|
if (apiKeyInfo.mode !== "aws-sdk") throw new Error(`No API key resolved for provider "${model.provider}" (auth mode: ${apiKeyInfo.mode}).`);
|
|
71930
71835
|
} else if (model.provider === "github-copilot") {
|
|
71931
|
-
const { resolveCopilotApiToken } = await import("./github-copilot-token-
|
|
71836
|
+
const { resolveCopilotApiToken } = await import("./github-copilot-token-BqpAEW8G.js").then((n) => n.n);
|
|
71932
71837
|
const copilotToken = await resolveCopilotApiToken({ githubToken: apiKeyInfo.apiKey });
|
|
71933
71838
|
authStorage.setRuntimeApiKey(model.provider, copilotToken.token);
|
|
71934
71839
|
} else authStorage.setRuntimeApiKey(model.provider, apiKeyInfo.apiKey);
|
|
@@ -74589,6 +74494,152 @@ function subscribeEmbeddedPiSession(params) {
|
|
|
74589
74494
|
};
|
|
74590
74495
|
}
|
|
74591
74496
|
|
|
74497
|
+
//#endregion
|
|
74498
|
+
//#region src/agents/plan-mode.ts
|
|
74499
|
+
/**
|
|
74500
|
+
* Plan Mode — automatic complexity detection and structured planning.
|
|
74501
|
+
*
|
|
74502
|
+
* When a user message is complex (multi-step, multi-file, refactoring, etc.),
|
|
74503
|
+
* Symi auto-enters plan mode: read-only investigation → structured plan →
|
|
74504
|
+
* user approval → context-cleared execution.
|
|
74505
|
+
*/
|
|
74506
|
+
const PLAN_KEYWORDS = new Set([
|
|
74507
|
+
"investigate",
|
|
74508
|
+
"refactor",
|
|
74509
|
+
"migrate",
|
|
74510
|
+
"redesign",
|
|
74511
|
+
"set up",
|
|
74512
|
+
"setup",
|
|
74513
|
+
"build",
|
|
74514
|
+
"implement",
|
|
74515
|
+
"architect",
|
|
74516
|
+
"overhaul",
|
|
74517
|
+
"restructure",
|
|
74518
|
+
"rewrite"
|
|
74519
|
+
]);
|
|
74520
|
+
const ANALYSIS_KEYWORDS = new Set([
|
|
74521
|
+
"analyze",
|
|
74522
|
+
"analyse",
|
|
74523
|
+
"compare",
|
|
74524
|
+
"audit",
|
|
74525
|
+
"review",
|
|
74526
|
+
"evaluate",
|
|
74527
|
+
"assess"
|
|
74528
|
+
]);
|
|
74529
|
+
const SEQUENTIAL_MARKERS = [
|
|
74530
|
+
/\bthen\b/i,
|
|
74531
|
+
/\bafter that\b/i,
|
|
74532
|
+
/\bonce .+ is done\b/i,
|
|
74533
|
+
/\bnext,?\s/i,
|
|
74534
|
+
/\bfollowed by\b/i,
|
|
74535
|
+
/\bfinally\b/i
|
|
74536
|
+
];
|
|
74537
|
+
const NUMBERED_LIST_RE = /^\s*\d+[.)]\s/gm;
|
|
74538
|
+
const FILE_PATH_RE = /(?:\/[\w.-]+){2,}|[\w.-]+\.[a-z]{1,4}/g;
|
|
74539
|
+
/**
|
|
74540
|
+
* Score a user message for complexity.
|
|
74541
|
+
* Returns a numeric score; >= PLAN_MODE_THRESHOLD triggers plan mode.
|
|
74542
|
+
*/
|
|
74543
|
+
function scorePlanComplexity(prompt) {
|
|
74544
|
+
let score = 0;
|
|
74545
|
+
const lower = prompt.toLowerCase();
|
|
74546
|
+
if (prompt.length > 500) {
|
|
74547
|
+
if ([...PLAN_KEYWORDS, ...ANALYSIS_KEYWORDS].some((kw) => lower.includes(kw)) || FILE_PATH_RE.test(prompt)) score += 3;
|
|
74548
|
+
}
|
|
74549
|
+
const numberedItems = prompt.match(NUMBERED_LIST_RE);
|
|
74550
|
+
if (numberedItems && numberedItems.length >= 3) score += 2;
|
|
74551
|
+
for (const kw of PLAN_KEYWORDS) if (lower.includes(kw)) {
|
|
74552
|
+
score += 2;
|
|
74553
|
+
break;
|
|
74554
|
+
}
|
|
74555
|
+
for (const re of SEQUENTIAL_MARKERS) if (re.test(prompt)) {
|
|
74556
|
+
score += 2;
|
|
74557
|
+
break;
|
|
74558
|
+
}
|
|
74559
|
+
const filePaths = prompt.match(FILE_PATH_RE);
|
|
74560
|
+
if (filePaths && new Set(filePaths).size >= 2) score += 1;
|
|
74561
|
+
for (const kw of ANALYSIS_KEYWORDS) if (lower.includes(kw)) {
|
|
74562
|
+
score += 1;
|
|
74563
|
+
break;
|
|
74564
|
+
}
|
|
74565
|
+
return score;
|
|
74566
|
+
}
|
|
74567
|
+
const PLAN_MODE_THRESHOLD = 5;
|
|
74568
|
+
/**
|
|
74569
|
+
* Determine whether a prompt should trigger plan mode.
|
|
74570
|
+
*
|
|
74571
|
+
* Priority:
|
|
74572
|
+
* 1. /plan prefix → always
|
|
74573
|
+
* 2. /noplan prefix → never
|
|
74574
|
+
* 3. Subagent/cron sessions → never
|
|
74575
|
+
* 4. Heuristic scoring
|
|
74576
|
+
*/
|
|
74577
|
+
function shouldEnterPlanMode(prompt, opts = {}) {
|
|
74578
|
+
const trimmed = prompt.trim();
|
|
74579
|
+
if (/^\/plan\b/i.test(trimmed)) return {
|
|
74580
|
+
enter: true,
|
|
74581
|
+
reason: "explicit /plan directive",
|
|
74582
|
+
score: 99,
|
|
74583
|
+
stripped: trimmed.replace(/^\/plan\s*/i, "").trim()
|
|
74584
|
+
};
|
|
74585
|
+
if (/^\/noplan\b/i.test(trimmed)) return {
|
|
74586
|
+
enter: false,
|
|
74587
|
+
reason: "explicit /noplan directive",
|
|
74588
|
+
score: 0,
|
|
74589
|
+
stripped: trimmed.replace(/^\/noplan\s*/i, "").trim()
|
|
74590
|
+
};
|
|
74591
|
+
if (opts.isSubagent) return {
|
|
74592
|
+
enter: false,
|
|
74593
|
+
reason: "subagent session",
|
|
74594
|
+
score: 0
|
|
74595
|
+
};
|
|
74596
|
+
if (opts.isCron) return {
|
|
74597
|
+
enter: false,
|
|
74598
|
+
reason: "cron session",
|
|
74599
|
+
score: 0
|
|
74600
|
+
};
|
|
74601
|
+
const score = scorePlanComplexity(trimmed);
|
|
74602
|
+
if (score >= PLAN_MODE_THRESHOLD) return {
|
|
74603
|
+
enter: true,
|
|
74604
|
+
reason: `complexity score ${score} >= ${PLAN_MODE_THRESHOLD}`,
|
|
74605
|
+
score
|
|
74606
|
+
};
|
|
74607
|
+
return {
|
|
74608
|
+
enter: false,
|
|
74609
|
+
reason: `complexity score ${score} < ${PLAN_MODE_THRESHOLD}`,
|
|
74610
|
+
score
|
|
74611
|
+
};
|
|
74612
|
+
}
|
|
74613
|
+
const PLAN_MODE_SYSTEM_PROMPT = `<plan_mode>
|
|
74614
|
+
You have entered PLAN MODE because this task is complex.
|
|
74615
|
+
|
|
74616
|
+
RULES:
|
|
74617
|
+
- DO NOT write, edit, or create any files yet
|
|
74618
|
+
- DO NOT execute destructive commands (rm, mv, git reset, etc.)
|
|
74619
|
+
- DO read files, search code, check runtime state
|
|
74620
|
+
- DO use memory_search, web_search, exec (read-only commands like ls, cat, git status, git log)
|
|
74621
|
+
- Produce a detailed step-by-step implementation plan
|
|
74622
|
+
|
|
74623
|
+
OUTPUT FORMAT:
|
|
74624
|
+
1. **Summary** — what needs to be done and why
|
|
74625
|
+
2. **Investigation** — files read, code searched, state checked
|
|
74626
|
+
3. **Files to modify** — list every file that will be created, edited, or deleted
|
|
74627
|
+
4. **Implementation phases** — numbered steps with:
|
|
74628
|
+
- What changes in each phase
|
|
74629
|
+
- Which files are touched
|
|
74630
|
+
- Dependencies on prior phases
|
|
74631
|
+
5. **Risks & considerations** — things that could go wrong, edge cases, rollback strategy
|
|
74632
|
+
|
|
74633
|
+
After presenting the plan, ask the user to choose one of these options.
|
|
74634
|
+
Present these as inline buttons if the channel supports them:
|
|
74635
|
+
- **Proceed** — clear context and execute the plan
|
|
74636
|
+
- **Modify** — adjust the plan based on feedback
|
|
74637
|
+
- **Cancel** — abandon the plan
|
|
74638
|
+
|
|
74639
|
+
Use the message tool with buttons:
|
|
74640
|
+
[{"label": "✅ Proceed", "data": "/plan-proceed"}, {"label": "✏️ Modify", "data": "/plan-modify"}, {"label": "❌ Cancel", "data": "/plan-cancel"}]
|
|
74641
|
+
</plan_mode>`;
|
|
74642
|
+
|
|
74592
74643
|
//#endregion
|
|
74593
74644
|
//#region src/agents/pi-embedded-runner/abort.ts
|
|
74594
74645
|
/**
|
|
@@ -75842,6 +75893,17 @@ async function runEmbeddedAttempt(params) {
|
|
|
75842
75893
|
log$2.debug(`auto-recall: skipped (${String(recallErr)})`);
|
|
75843
75894
|
}
|
|
75844
75895
|
}
|
|
75896
|
+
{
|
|
75897
|
+
const planResult = shouldEnterPlanMode(effectivePrompt, {
|
|
75898
|
+
isSubagent: isSubagentSessionKey(params.sessionKey),
|
|
75899
|
+
isCron: isCronSessionKey(params.sessionKey)
|
|
75900
|
+
});
|
|
75901
|
+
if (planResult.enter) {
|
|
75902
|
+
if (planResult.stripped != null) effectivePrompt = planResult.stripped;
|
|
75903
|
+
effectivePrompt = `${PLAN_MODE_SYSTEM_PROMPT}\n\n${effectivePrompt}`;
|
|
75904
|
+
log$2.info(`plan-mode: activated (${planResult.reason}) for runId=${params.runId}`);
|
|
75905
|
+
} else if (planResult.stripped != null) effectivePrompt = planResult.stripped;
|
|
75906
|
+
}
|
|
75845
75907
|
log$2.debug(`embedded run prompt start: runId=${params.runId} sessionId=${params.sessionId}`);
|
|
75846
75908
|
cacheTrace?.recordStage("prompt:before", {
|
|
75847
75909
|
prompt: effectivePrompt,
|
|
@@ -76394,7 +76456,7 @@ async function runEmbeddedPiAgent(params) {
|
|
|
76394
76456
|
return;
|
|
76395
76457
|
}
|
|
76396
76458
|
if (model.provider === "github-copilot") {
|
|
76397
|
-
const { resolveCopilotApiToken } = await import("./github-copilot-token-
|
|
76459
|
+
const { resolveCopilotApiToken } = await import("./github-copilot-token-BqpAEW8G.js").then((n) => n.n);
|
|
76398
76460
|
const copilotToken = await resolveCopilotApiToken({ githubToken: apiKeyInfo.apiKey });
|
|
76399
76461
|
authStorage.setRuntimeApiKey(model.provider, copilotToken.token);
|
|
76400
76462
|
} else authStorage.setRuntimeApiKey(model.provider, apiKeyInfo.apiKey);
|