@namzu/cli 35.0.0 → 36.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +756 -0
- package/README.md +160 -394
- package/assets/pal-blender-mcp.py +123 -0
- package/assets/pal-godot-mcp-pin.json +135 -0
- package/assets/pal-godot-mcp.cjs +418 -0
- package/dist/bin-main.d.ts +3 -0
- package/dist/bin-main.d.ts.map +1 -0
- package/dist/bin.d.ts +2 -1
- package/dist/bin.d.ts.map +1 -1
- package/dist/bin.js +85 -23
- package/dist/bin.js.map +6 -1
- package/dist/boot-narrative.d.ts +16 -0
- package/dist/boot-narrative.d.ts.map +1 -0
- package/dist/checkpoints/manifest.d.ts +107 -0
- package/dist/checkpoints/manifest.d.ts.map +1 -0
- package/dist/checkpoints/store.d.ts +280 -40
- package/dist/checkpoints/store.d.ts.map +1 -1
- package/dist/checkpoints/undo-plan.d.ts +83 -0
- package/dist/checkpoints/undo-plan.d.ts.map +1 -0
- package/dist/checkpoints/wrap.d.ts +4 -0
- package/dist/checkpoints/wrap.d.ts.map +1 -1
- package/dist/chunks/acp-BOSEA4R3.js +13448 -0
- package/dist/chunks/acp-BOSEA4R3.js.map +6 -0
- package/dist/chunks/activity-command-ACS7KL3C.js +262 -0
- package/dist/chunks/activity-command-ACS7KL3C.js.map +6 -0
- package/dist/chunks/add-DLS54YKS.js +712 -0
- package/dist/chunks/add-DLS54YKS.js.map +6 -0
- package/dist/chunks/agent-GV3DWYQC.js +87 -0
- package/dist/chunks/agent-GV3DWYQC.js.map +6 -0
- package/dist/chunks/agent-session-7VE6GJJH.js +46 -0
- package/dist/chunks/agent-session-7VE6GJJH.js.map +6 -0
- package/dist/chunks/archive-6ZENIEBP.js +84 -0
- package/dist/chunks/archive-6ZENIEBP.js.map +6 -0
- package/dist/chunks/bin-main-NFFT5ZIU.js +126 -0
- package/dist/chunks/bin-main-NFFT5ZIU.js.map +6 -0
- package/dist/chunks/browser-VT2U6NG2.js +31 -0
- package/dist/chunks/browser-VT2U6NG2.js.map +6 -0
- package/dist/chunks/chat-UNYVLDFL.js +101 -0
- package/dist/chunks/chat-UNYVLDFL.js.map +6 -0
- package/dist/chunks/chunk-2IL6OG3X.js +311 -0
- package/dist/chunks/chunk-2IL6OG3X.js.map +6 -0
- package/dist/chunks/chunk-2RBYHHLM.js +319 -0
- package/dist/chunks/chunk-2RBYHHLM.js.map +6 -0
- package/dist/chunks/chunk-42ZK2AH4.js +71 -0
- package/dist/chunks/chunk-42ZK2AH4.js.map +6 -0
- package/dist/chunks/chunk-5PQVJBIO.js +168 -0
- package/dist/chunks/chunk-5PQVJBIO.js.map +6 -0
- package/dist/chunks/chunk-6CPT2ZBS.js +75 -0
- package/dist/chunks/chunk-6CPT2ZBS.js.map +6 -0
- package/dist/chunks/chunk-6LLJQ3KY.js +225 -0
- package/dist/chunks/chunk-6LLJQ3KY.js.map +6 -0
- package/dist/chunks/chunk-6YFJDVGA.js +161 -0
- package/dist/chunks/chunk-6YFJDVGA.js.map +6 -0
- package/dist/chunks/chunk-6YG7D7U4.js +159 -0
- package/dist/chunks/chunk-6YG7D7U4.js.map +6 -0
- package/dist/chunks/chunk-6ZPODOJN.js +828 -0
- package/dist/chunks/chunk-6ZPODOJN.js.map +6 -0
- package/dist/chunks/chunk-76FLAFCG.js +51 -0
- package/dist/chunks/chunk-76FLAFCG.js.map +6 -0
- package/dist/chunks/chunk-7HCPD673.js +25326 -0
- package/dist/chunks/chunk-7HCPD673.js.map +6 -0
- package/dist/chunks/chunk-7KWGR2YA.js +257 -0
- package/dist/chunks/chunk-7KWGR2YA.js.map +6 -0
- package/dist/chunks/chunk-A22MBIYU.js +42 -0
- package/dist/chunks/chunk-A22MBIYU.js.map +6 -0
- package/dist/chunks/chunk-AHIDYIRB.js +329 -0
- package/dist/chunks/chunk-AHIDYIRB.js.map +6 -0
- package/dist/chunks/chunk-AK2U3N2A.js +31 -0
- package/dist/chunks/chunk-AK2U3N2A.js.map +6 -0
- package/dist/chunks/chunk-AKKRZTPB.js +283 -0
- package/dist/chunks/chunk-AKKRZTPB.js.map +6 -0
- package/dist/chunks/chunk-BCZR2B3Y.js +97 -0
- package/dist/chunks/chunk-BCZR2B3Y.js.map +6 -0
- package/dist/chunks/chunk-CHIEVVQ2.js +32 -0
- package/dist/chunks/chunk-CHIEVVQ2.js.map +6 -0
- package/dist/chunks/chunk-D67YBUO3.js +110 -0
- package/dist/chunks/chunk-D67YBUO3.js.map +6 -0
- package/dist/chunks/chunk-DIHEHK7K.js +765 -0
- package/dist/chunks/chunk-DIHEHK7K.js.map +6 -0
- package/dist/chunks/chunk-E5VLANCO.js +101 -0
- package/dist/chunks/chunk-E5VLANCO.js.map +6 -0
- package/dist/chunks/chunk-EEDZOGV4.js +47 -0
- package/dist/chunks/chunk-EEDZOGV4.js.map +6 -0
- package/dist/chunks/chunk-ENGNEELC.js +271 -0
- package/dist/chunks/chunk-ENGNEELC.js.map +6 -0
- package/dist/chunks/chunk-EVY4MVRE.js +74 -0
- package/dist/chunks/chunk-EVY4MVRE.js.map +6 -0
- package/dist/chunks/chunk-FJNDNNNQ.js +115 -0
- package/dist/chunks/chunk-FJNDNNNQ.js.map +6 -0
- package/dist/chunks/chunk-FOFGMP7O.js +20 -0
- package/dist/chunks/chunk-FOFGMP7O.js.map +6 -0
- package/dist/chunks/chunk-FTMTO72X.js +95 -0
- package/dist/chunks/chunk-FTMTO72X.js.map +6 -0
- package/dist/chunks/chunk-GIXSS6KW.js +2228 -0
- package/dist/chunks/chunk-GIXSS6KW.js.map +6 -0
- package/dist/chunks/chunk-GNBMKISG.js +19 -0
- package/dist/chunks/chunk-GNBMKISG.js.map +6 -0
- package/dist/chunks/chunk-GWQEMJFS.js +28 -0
- package/dist/chunks/chunk-GWQEMJFS.js.map +6 -0
- package/dist/chunks/chunk-H6B6AROX.js +151 -0
- package/dist/chunks/chunk-H6B6AROX.js.map +6 -0
- package/dist/chunks/chunk-HE7WUOX2.js +26 -0
- package/dist/chunks/chunk-HE7WUOX2.js.map +6 -0
- package/dist/chunks/chunk-HZBKWL42.js +303 -0
- package/dist/chunks/chunk-HZBKWL42.js.map +6 -0
- package/dist/chunks/chunk-I7HQR6ET.js +75 -0
- package/dist/chunks/chunk-I7HQR6ET.js.map +6 -0
- package/dist/chunks/chunk-IJEB77SH.js +648 -0
- package/dist/chunks/chunk-IJEB77SH.js.map +6 -0
- package/dist/chunks/chunk-JNPDWME5.js +675 -0
- package/dist/chunks/chunk-JNPDWME5.js.map +6 -0
- package/dist/chunks/chunk-JORONMD3.js +18 -0
- package/dist/chunks/chunk-JORONMD3.js.map +6 -0
- package/dist/chunks/chunk-JV3LONAU.js +76 -0
- package/dist/chunks/chunk-JV3LONAU.js.map +6 -0
- package/dist/chunks/chunk-K5HARZ7G.js +82516 -0
- package/dist/chunks/chunk-K5HARZ7G.js.map +6 -0
- package/dist/chunks/chunk-KONYGNG6.js +7661 -0
- package/dist/chunks/chunk-KONYGNG6.js.map +6 -0
- package/dist/chunks/chunk-LXB3S4IC.js +19 -0
- package/dist/chunks/chunk-LXB3S4IC.js.map +6 -0
- package/dist/chunks/chunk-M3IAMIBJ.js +661 -0
- package/dist/chunks/chunk-M3IAMIBJ.js.map +6 -0
- package/dist/chunks/chunk-MH6KUKVV.js +1142 -0
- package/dist/chunks/chunk-MH6KUKVV.js.map +6 -0
- package/dist/chunks/chunk-MS3IYQ72.js +1479 -0
- package/dist/chunks/chunk-MS3IYQ72.js.map +6 -0
- package/dist/chunks/chunk-MZP6SH3M.js +3497 -0
- package/dist/chunks/chunk-MZP6SH3M.js.map +6 -0
- package/dist/chunks/chunk-N3ZEXVSS.js +76 -0
- package/dist/chunks/chunk-N3ZEXVSS.js.map +6 -0
- package/dist/chunks/chunk-N6SR54VC.js +207 -0
- package/dist/chunks/chunk-N6SR54VC.js.map +6 -0
- package/dist/chunks/chunk-NADQQMMG.js +46 -0
- package/dist/chunks/chunk-NADQQMMG.js.map +6 -0
- package/dist/chunks/chunk-NBH52WHS.js +247 -0
- package/dist/chunks/chunk-NBH52WHS.js.map +6 -0
- package/dist/chunks/chunk-NICLKFBG.js +109 -0
- package/dist/chunks/chunk-NICLKFBG.js.map +6 -0
- package/dist/chunks/chunk-NIPHHZ5G.js +283 -0
- package/dist/chunks/chunk-NIPHHZ5G.js.map +6 -0
- package/dist/chunks/chunk-NQT244I2.js +517 -0
- package/dist/chunks/chunk-NQT244I2.js.map +6 -0
- package/dist/chunks/chunk-NUGPLXVK.js +228 -0
- package/dist/chunks/chunk-NUGPLXVK.js.map +6 -0
- package/dist/chunks/chunk-OEW7CJKK.js +140 -0
- package/dist/chunks/chunk-OEW7CJKK.js.map +6 -0
- package/dist/chunks/chunk-OH6TB27S.js +111 -0
- package/dist/chunks/chunk-OH6TB27S.js.map +6 -0
- package/dist/chunks/chunk-OWH6QQY2.js +1858 -0
- package/dist/chunks/chunk-OWH6QQY2.js.map +6 -0
- package/dist/chunks/chunk-OWXJOD4H.js +773 -0
- package/dist/chunks/chunk-OWXJOD4H.js.map +6 -0
- package/dist/chunks/chunk-PT537V7B.js +787 -0
- package/dist/chunks/chunk-PT537V7B.js.map +6 -0
- package/dist/chunks/chunk-QEQZFG2X.js +106 -0
- package/dist/chunks/chunk-QEQZFG2X.js.map +6 -0
- package/dist/chunks/chunk-QL4O4UGZ.js +245 -0
- package/dist/chunks/chunk-QL4O4UGZ.js.map +6 -0
- package/dist/chunks/chunk-QL54XCF4.js +73 -0
- package/dist/chunks/chunk-QL54XCF4.js.map +6 -0
- package/dist/chunks/chunk-SB6UD3ED.js +1355 -0
- package/dist/chunks/chunk-SB6UD3ED.js.map +6 -0
- package/dist/chunks/chunk-SGGRGKGV.js +34 -0
- package/dist/chunks/chunk-SGGRGKGV.js.map +6 -0
- package/dist/chunks/chunk-SKKWMMFP.js +474 -0
- package/dist/chunks/chunk-SKKWMMFP.js.map +6 -0
- package/dist/chunks/chunk-SMIDV4KH.js +171 -0
- package/dist/chunks/chunk-SMIDV4KH.js.map +6 -0
- package/dist/chunks/chunk-T2VUTAHB.js +46 -0
- package/dist/chunks/chunk-T2VUTAHB.js.map +6 -0
- package/dist/chunks/chunk-T4SB6AAF.js +134 -0
- package/dist/chunks/chunk-T4SB6AAF.js.map +6 -0
- package/dist/chunks/chunk-TBIX6JRE.js +24 -0
- package/dist/chunks/chunk-TBIX6JRE.js.map +6 -0
- package/dist/chunks/chunk-THNCQJ33.js +11265 -0
- package/dist/chunks/chunk-THNCQJ33.js.map +6 -0
- package/dist/chunks/chunk-U56QFYGA.js +818 -0
- package/dist/chunks/chunk-U56QFYGA.js.map +6 -0
- package/dist/chunks/chunk-U6GZ7EW4.js +106 -0
- package/dist/chunks/chunk-U6GZ7EW4.js.map +6 -0
- package/dist/chunks/chunk-UDDSFIMB.js +1373 -0
- package/dist/chunks/chunk-UDDSFIMB.js.map +6 -0
- package/dist/chunks/chunk-UFHNXZL2.js +399 -0
- package/dist/chunks/chunk-UFHNXZL2.js.map +6 -0
- package/dist/chunks/chunk-US5ZFPAU.js +400 -0
- package/dist/chunks/chunk-US5ZFPAU.js.map +6 -0
- package/dist/chunks/chunk-VRL2WNQN.js +7534 -0
- package/dist/chunks/chunk-VRL2WNQN.js.map +6 -0
- package/dist/chunks/chunk-W3UQMRYA.js +380 -0
- package/dist/chunks/chunk-W3UQMRYA.js.map +6 -0
- package/dist/chunks/chunk-W5KGCUP3.js +11111 -0
- package/dist/chunks/chunk-W5KGCUP3.js.map +6 -0
- package/dist/chunks/chunk-WHODOMXA.js +132 -0
- package/dist/chunks/chunk-WHODOMXA.js.map +6 -0
- package/dist/chunks/chunk-WT6TFCPV.js +154 -0
- package/dist/chunks/chunk-WT6TFCPV.js.map +6 -0
- package/dist/chunks/chunk-WY2WUTFR.js +164 -0
- package/dist/chunks/chunk-WY2WUTFR.js.map +6 -0
- package/dist/chunks/chunk-XEUQN4JC.js +54 -0
- package/dist/chunks/chunk-XEUQN4JC.js.map +6 -0
- package/dist/chunks/chunk-Y7B67G22.js +26 -0
- package/dist/chunks/chunk-Y7B67G22.js.map +6 -0
- package/dist/chunks/chunk-YEMJX2DS.js +69 -0
- package/dist/chunks/chunk-YEMJX2DS.js.map +6 -0
- package/dist/chunks/chunk-YKLKHDZU.js +2953 -0
- package/dist/chunks/chunk-YKLKHDZU.js.map +6 -0
- package/dist/chunks/chunk-YQEWD2EN.js +127 -0
- package/dist/chunks/chunk-YQEWD2EN.js.map +6 -0
- package/dist/chunks/chunk-YYQJIECC.js +1439 -0
- package/dist/chunks/chunk-YYQJIECC.js.map +6 -0
- package/dist/chunks/chunk-ZKVZNOUS.js +106 -0
- package/dist/chunks/chunk-ZKVZNOUS.js.map +6 -0
- package/dist/chunks/chunk-ZPR4IMRT.js +36 -0
- package/dist/chunks/chunk-ZPR4IMRT.js.map +6 -0
- package/dist/chunks/chunk-ZWA2JRJV.js +45 -0
- package/dist/chunks/chunk-ZWA2JRJV.js.map +6 -0
- package/dist/chunks/cli-runtime-F4MBZ2UQ.js +129 -0
- package/dist/chunks/cli-runtime-F4MBZ2UQ.js.map +6 -0
- package/dist/chunks/commands-GMQGFTIY.js +21 -0
- package/dist/chunks/commands-GMQGFTIY.js.map +6 -0
- package/dist/chunks/computer-GXDY4H35.js +493 -0
- package/dist/chunks/computer-GXDY4H35.js.map +6 -0
- package/dist/chunks/crash-report-STOHSORG.js +21 -0
- package/dist/chunks/crash-report-STOHSORG.js.map +6 -0
- package/dist/chunks/devtools-LBE4PAQN.js +3851 -0
- package/dist/chunks/devtools-LBE4PAQN.js.map +6 -0
- package/dist/chunks/dist-3AF2X4S5.js +1339 -0
- package/dist/chunks/dist-3AF2X4S5.js.map +6 -0
- package/dist/chunks/dist-AZIMHV2B.js +514 -0
- package/dist/chunks/dist-AZIMHV2B.js.map +6 -0
- package/dist/chunks/dist-BGYRQ5BC.js +555 -0
- package/dist/chunks/dist-BGYRQ5BC.js.map +6 -0
- package/dist/chunks/dist-OTTZ7WVD.js +1415 -0
- package/dist/chunks/dist-OTTZ7WVD.js.map +6 -0
- package/dist/chunks/dist-R3I3ATSG.js +1018 -0
- package/dist/chunks/dist-R3I3ATSG.js.map +6 -0
- package/dist/chunks/dist-TXEKDBQO.js +40642 -0
- package/dist/chunks/dist-TXEKDBQO.js.map +6 -0
- package/dist/chunks/dist-XTWYQHHN.js +520 -0
- package/dist/chunks/dist-XTWYQHHN.js.map +6 -0
- package/dist/chunks/doctor-VXSB4Y4P.js +28 -0
- package/dist/chunks/doctor-VXSB4Y4P.js.map +6 -0
- package/dist/chunks/drain-DXVICQBR.js +471 -0
- package/dist/chunks/drain-DXVICQBR.js.map +6 -0
- package/dist/chunks/endpoint-M2DDENPP.js +15 -0
- package/dist/chunks/endpoint-M2DDENPP.js.map +6 -0
- package/dist/chunks/eval-BMJQXDKA.js +187 -0
- package/dist/chunks/eval-BMJQXDKA.js.map +6 -0
- package/dist/chunks/exec-3T5ESZPH.js +1284 -0
- package/dist/chunks/exec-3T5ESZPH.js.map +6 -0
- package/dist/chunks/home-ILHA7B6Z.js +16 -0
- package/dist/chunks/home-ILHA7B6Z.js.map +6 -0
- package/dist/chunks/host-queries-QCMWDZGS.js +152 -0
- package/dist/chunks/host-queries-QCMWDZGS.js.map +6 -0
- package/dist/chunks/lib-KXZZJJG2.js +2657 -0
- package/dist/chunks/lib-KXZZJJG2.js.map +6 -0
- package/dist/chunks/lifecycle-CB23VJI7.js +63 -0
- package/dist/chunks/lifecycle-CB23VJI7.js.map +6 -0
- package/dist/chunks/list-N6WXZBMD.js +293 -0
- package/dist/chunks/list-N6WXZBMD.js.map +6 -0
- package/dist/chunks/login-26NCG6EQ.js +29 -0
- package/dist/chunks/login-26NCG6EQ.js.map +6 -0
- package/dist/chunks/logs-V7SNM7LA.js +116 -0
- package/dist/chunks/logs-V7SNM7LA.js.map +6 -0
- package/dist/chunks/mcp-BTHCU5ZC.js +763 -0
- package/dist/chunks/mcp-BTHCU5ZC.js.map +6 -0
- package/dist/chunks/message-command-HMIOR52C.js +170 -0
- package/dist/chunks/message-command-HMIOR52C.js.map +6 -0
- package/dist/chunks/node-QB2FA2ZB.js +916 -0
- package/dist/chunks/node-QB2FA2ZB.js.map +6 -0
- package/dist/chunks/operator-tools-7LMWOHSN.js +115 -0
- package/dist/chunks/operator-tools-7LMWOHSN.js.map +6 -0
- package/dist/chunks/output-schema-XCONYVZ7.js +11 -0
- package/dist/chunks/output-schema-XCONYVZ7.js.map +6 -0
- package/dist/chunks/pal-YEUKHA6F.js +200 -0
- package/dist/chunks/pal-YEUKHA6F.js.map +6 -0
- package/dist/chunks/paths-DXYFKIJU.js +10 -0
- package/dist/chunks/paths-DXYFKIJU.js.map +6 -0
- package/dist/chunks/pica-WNHDDIFX.js +1736 -0
- package/dist/chunks/pica-WNHDDIFX.js.map +6 -0
- package/dist/chunks/providers-EI3FAKYB.js +160 -0
- package/dist/chunks/providers-EI3FAKYB.js.map +6 -0
- package/dist/chunks/resident-5ZY6OG6B.js +1314 -0
- package/dist/chunks/resident-5ZY6OG6B.js.map +6 -0
- package/dist/chunks/resume-command-ONYRZIIA.js +22 -0
- package/dist/chunks/resume-command-ONYRZIIA.js.map +6 -0
- package/dist/chunks/schedule-6JPEO4NR.js +143 -0
- package/dist/chunks/schedule-6JPEO4NR.js.map +6 -0
- package/dist/chunks/serve-S7UWNIR3.js +21 -0
- package/dist/chunks/serve-S7UWNIR3.js.map +6 -0
- package/dist/chunks/service-WSW3M6K5.js +1633 -0
- package/dist/chunks/service-WSW3M6K5.js.map +6 -0
- package/dist/chunks/session-step-2VZM3CCA.js +26 -0
- package/dist/chunks/session-step-2VZM3CCA.js.map +6 -0
- package/dist/chunks/skills-KAZJYGX5.js +282 -0
- package/dist/chunks/skills-KAZJYGX5.js.map +6 -0
- package/dist/chunks/state-263OUKQA.js +717 -0
- package/dist/chunks/state-263OUKQA.js.map +6 -0
- package/dist/chunks/store-3XLCJ7EL.js +42 -0
- package/dist/chunks/store-3XLCJ7EL.js.map +6 -0
- package/dist/chunks/store-KN65QI2M.js +82 -0
- package/dist/chunks/store-KN65QI2M.js.map +6 -0
- package/dist/chunks/store-X3TESBIN.js +34 -0
- package/dist/chunks/store-X3TESBIN.js.map +6 -0
- package/dist/chunks/tui-5MU7JBXX.js +56703 -0
- package/dist/chunks/tui-5MU7JBXX.js.map +6 -0
- package/dist/chunks/upgrade-BYM4MWBC.js +315 -0
- package/dist/chunks/upgrade-BYM4MWBC.js.map +6 -0
- package/dist/chunks/webapi-6HUHZUAH.js +2715 -0
- package/dist/chunks/webapi-6HUHZUAH.js.map +6 -0
- package/dist/chunks/worktree-K3ZIPXRM.js +116 -0
- package/dist/chunks/worktree-K3ZIPXRM.js.map +6 -0
- package/dist/cli-runtime.d.ts +19 -0
- package/dist/cli-runtime.d.ts.map +1 -0
- package/dist/cli.d.ts +0 -15
- package/dist/cli.d.ts.map +1 -1
- package/dist/commands/acp-harness.d.ts +64 -0
- package/dist/commands/acp-harness.d.ts.map +1 -0
- package/dist/commands/acp-provider-retry.d.ts +27 -0
- package/dist/commands/acp-provider-retry.d.ts.map +1 -0
- package/dist/commands/acp.d.ts +134 -3
- package/dist/commands/acp.d.ts.map +1 -1
- package/dist/commands/computer.d.ts +3 -0
- package/dist/commands/computer.d.ts.map +1 -0
- package/dist/commands/desktop-host-changes.d.ts +65 -0
- package/dist/commands/desktop-host-changes.d.ts.map +1 -0
- package/dist/commands/desktop-host-header.d.ts +30 -0
- package/dist/commands/desktop-host-header.d.ts.map +1 -0
- package/dist/commands/desktop-host.d.ts +354 -0
- package/dist/commands/desktop-host.d.ts.map +1 -0
- package/dist/commands/desktop-model-catalogue.d.ts +25 -0
- package/dist/commands/desktop-model-catalogue.d.ts.map +1 -0
- package/dist/commands/effort-levels.d.ts +3 -0
- package/dist/commands/effort-levels.d.ts.map +1 -0
- package/dist/commands/exec-flags.d.ts +4 -0
- package/dist/commands/exec-flags.d.ts.map +1 -1
- package/dist/commands/exec.d.ts.map +1 -1
- package/dist/commands/lazy.d.ts +20 -0
- package/dist/commands/lazy.d.ts.map +1 -0
- package/dist/commands/manifest.d.ts +33 -0
- package/dist/commands/manifest.d.ts.map +1 -0
- package/dist/commands/pal.d.ts +5 -0
- package/dist/commands/pal.d.ts.map +1 -0
- package/dist/commands/permission-preview.d.ts +38 -0
- package/dist/commands/permission-preview.d.ts.map +1 -0
- package/dist/commands/registry.d.ts +10 -0
- package/dist/commands/registry.d.ts.map +1 -1
- package/dist/commands/serve.d.ts +1 -12
- package/dist/commands/serve.d.ts.map +1 -1
- package/dist/commands/stdin.d.ts.map +1 -1
- package/dist/commands/upgrade.d.ts +14 -0
- package/dist/commands/upgrade.d.ts.map +1 -1
- package/dist/compile-cache-enable.d.ts +2 -0
- package/dist/compile-cache-enable.d.ts.map +1 -0
- package/dist/compile-cache.d.ts +53 -0
- package/dist/compile-cache.d.ts.map +1 -0
- package/dist/computer/bundle.d.ts +18 -0
- package/dist/computer/bundle.d.ts.map +1 -0
- package/dist/computer/run.d.ts +26 -0
- package/dist/computer/run.d.ts.map +1 -0
- package/dist/computer/sentences.d.ts +30 -0
- package/dist/computer/sentences.d.ts.map +1 -0
- package/dist/config/load.d.ts +10 -1
- package/dist/config/load.d.ts.map +1 -1
- package/dist/context/capabilities.d.ts +25 -2
- package/dist/context/capabilities.d.ts.map +1 -1
- package/dist/context/runtime-message.d.ts.map +1 -1
- package/dist/crash-report.d.ts +22 -0
- package/dist/crash-report.d.ts.map +1 -0
- package/dist/debug-requested.d.ts +7 -0
- package/dist/debug-requested.d.ts.map +1 -0
- package/dist/doctor/checks/credentials.d.ts.map +1 -1
- package/dist/exit-codes.d.ts +9 -1
- package/dist/exit-codes.d.ts.map +1 -1
- package/dist/index.js +105 -17
- package/dist/index.js.map +6 -1
- package/dist/integrations/harness/claude-adapter.d.ts +20 -0
- package/dist/integrations/harness/claude-adapter.d.ts.map +1 -0
- package/dist/integrations/harness/claude-protocol.d.ts +67 -0
- package/dist/integrations/harness/claude-protocol.d.ts.map +1 -0
- package/dist/integrations/harness/codex-adapter.d.ts +80 -0
- package/dist/integrations/harness/codex-adapter.d.ts.map +1 -0
- package/dist/integrations/harness/codex-protocol.d.ts +22 -0
- package/dist/integrations/harness/codex-protocol.d.ts.map +1 -0
- package/dist/integrations/harness/model-cache.d.ts +16 -0
- package/dist/integrations/harness/model-cache.d.ts.map +1 -0
- package/dist/integrations/harness/native-executable.d.ts +8 -0
- package/dist/integrations/harness/native-executable.d.ts.map +1 -0
- package/dist/integrations/harness/process.d.ts +25 -0
- package/dist/integrations/harness/process.d.ts.map +1 -0
- package/dist/integrations/peers/runtime.d.ts +64 -0
- package/dist/integrations/peers/runtime.d.ts.map +1 -0
- package/dist/integrations/plugins/inventory.d.ts +27 -0
- package/dist/integrations/plugins/inventory.d.ts.map +1 -0
- package/dist/integrations/providers/composer-settings.d.ts +33 -0
- package/dist/integrations/providers/composer-settings.d.ts.map +1 -0
- package/dist/integrations/providers/connections.d.ts +37 -0
- package/dist/integrations/providers/connections.d.ts.map +1 -0
- package/dist/integrations/providers/credential-store.d.ts +35 -0
- package/dist/integrations/providers/credential-store.d.ts.map +1 -1
- package/dist/integrations/providers/discover.d.ts +27 -1
- package/dist/integrations/providers/discover.d.ts.map +1 -1
- package/dist/integrations/providers/index.d.ts +2 -2
- package/dist/integrations/providers/index.d.ts.map +1 -1
- package/dist/integrations/providers/picker-operation.d.ts +6 -0
- package/dist/integrations/providers/picker-operation.d.ts.map +1 -0
- package/dist/integrations/providers/setup.d.ts +16 -1
- package/dist/integrations/providers/setup.d.ts.map +1 -1
- package/dist/integrations/resident/runner-worker.js +190 -161
- package/dist/integrations/resident/runner-worker.js.map +6 -1
- package/dist/integrations/sessions/display-title.d.ts +8 -0
- package/dist/integrations/sessions/display-title.d.ts.map +1 -1
- package/dist/integrations/sessions/store.d.ts +23 -9
- package/dist/integrations/sessions/store.d.ts.map +1 -1
- package/dist/integrations/sessions/task-context.d.ts +1 -1
- package/dist/integrations/sessions/task-context.d.ts.map +1 -1
- package/dist/integrations/sessions/transcript-export.d.ts.map +1 -1
- package/dist/integrations/subagents/activity.d.ts +9 -6
- package/dist/integrations/subagents/activity.d.ts.map +1 -1
- package/dist/integrations/subagents/operator-journal.d.ts +20 -0
- package/dist/integrations/subagents/operator-journal.d.ts.map +1 -0
- package/dist/integrations/subagents/runtime.d.ts +11 -0
- package/dist/integrations/subagents/runtime.d.ts.map +1 -1
- package/dist/integrations/trust/store.d.ts +14 -0
- package/dist/integrations/trust/store.d.ts.map +1 -1
- package/dist/integrations/web/search.d.ts +1 -1
- package/dist/pals/actions.d.ts +57 -0
- package/dist/pals/actions.d.ts.map +1 -0
- package/dist/pals/activity-command.d.ts +3 -0
- package/dist/pals/activity-command.d.ts.map +1 -0
- package/dist/pals/activity.d.ts +18 -0
- package/dist/pals/activity.d.ts.map +1 -0
- package/dist/pals/agent-session.d.ts +19 -0
- package/dist/pals/agent-session.d.ts.map +1 -0
- package/dist/pals/channel-actions.d.ts +5 -0
- package/dist/pals/channel-actions.d.ts.map +1 -0
- package/dist/pals/channel-local.d.ts +7 -0
- package/dist/pals/channel-local.d.ts.map +1 -0
- package/dist/pals/channel.d.ts +20 -0
- package/dist/pals/channel.d.ts.map +1 -0
- package/dist/pals/chat.d.ts +6 -0
- package/dist/pals/chat.d.ts.map +1 -0
- package/dist/pals/communication.d.ts +47 -0
- package/dist/pals/communication.d.ts.map +1 -0
- package/dist/pals/conversations.d.ts +26 -0
- package/dist/pals/conversations.d.ts.map +1 -0
- package/dist/pals/desktop-communication.d.ts +111 -0
- package/dist/pals/desktop-communication.d.ts.map +1 -0
- package/dist/pals/dispatch.d.ts +13 -0
- package/dist/pals/dispatch.d.ts.map +1 -0
- package/dist/pals/environment.d.ts +103 -0
- package/dist/pals/environment.d.ts.map +1 -0
- package/dist/pals/guest-mcp-transport.d.ts +28 -0
- package/dist/pals/guest-mcp-transport.d.ts.map +1 -0
- package/dist/pals/guest-mcp.d.ts +22 -0
- package/dist/pals/guest-mcp.d.ts.map +1 -0
- package/dist/pals/inbox-start.d.ts +35 -0
- package/dist/pals/inbox-start.d.ts.map +1 -0
- package/dist/pals/message-command.d.ts +3 -0
- package/dist/pals/message-command.d.ts.map +1 -0
- package/dist/pals/operator-tools.d.ts +23 -0
- package/dist/pals/operator-tools.d.ts.map +1 -0
- package/dist/pals/public-transcript.d.ts +4 -0
- package/dist/pals/public-transcript.d.ts.map +1 -0
- package/dist/pals/review.d.ts +16 -0
- package/dist/pals/review.d.ts.map +1 -0
- package/dist/pals/store.d.ts +16 -0
- package/dist/pals/store.d.ts.map +1 -0
- package/dist/pals/tui-session.d.ts +11 -0
- package/dist/pals/tui-session.d.ts.map +1 -0
- package/dist/permissions/mode-names.d.ts +2 -0
- package/dist/permissions/mode-names.d.ts.map +1 -0
- package/dist/resume-invocation.d.ts +1 -1
- package/dist/resume-invocation.d.ts.map +1 -1
- package/dist/resume-shell.d.ts +8 -0
- package/dist/resume-shell.d.ts.map +1 -0
- package/dist/schedule/build.d.ts +12 -3
- package/dist/schedule/build.d.ts.map +1 -1
- package/dist/schedule/commands/add.d.ts +1 -1
- package/dist/schedule/commands/add.d.ts.map +1 -1
- package/dist/schedule/commands/lifecycle.d.ts.map +1 -1
- package/dist/schedule/commands/list.d.ts +3 -1
- package/dist/schedule/commands/list.d.ts.map +1 -1
- package/dist/schedule/daemon/daemon.d.ts +2 -0
- package/dist/schedule/daemon/daemon.d.ts.map +1 -1
- package/dist/schedule/delivery.d.ts +66 -0
- package/dist/schedule/delivery.d.ts.map +1 -0
- package/dist/schedule/fire/fire.d.ts +1 -1
- package/dist/schedule/fire/fire.d.ts.map +1 -1
- package/dist/schedule/fire/run-script.d.ts +2 -2
- package/dist/schedule/fire/run-script.d.ts.map +1 -1
- package/dist/schedule/fire/script-report.d.ts +31 -0
- package/dist/schedule/fire/script-report.d.ts.map +1 -0
- package/dist/schedule/floor.d.ts +1 -1
- package/dist/schedule/floor.d.ts.map +1 -1
- package/dist/schedule/folder.d.ts +6 -0
- package/dist/schedule/folder.d.ts.map +1 -1
- package/dist/schedule/resume-command.d.ts +3 -3
- package/dist/schedule/resume-command.d.ts.map +1 -1
- package/dist/schedule/store/history.d.ts.map +1 -1
- package/dist/schedule/store/jobs.d.ts +6 -6
- package/dist/schedule/store/jobs.d.ts.map +1 -1
- package/dist/schedule/store/script-state.d.ts +31 -0
- package/dist/schedule/store/script-state.d.ts.map +1 -0
- package/dist/schedule/store/state.d.ts +4 -2
- package/dist/schedule/store/state.d.ts.map +1 -1
- package/dist/schedule/types.d.ts +61 -16
- package/dist/schedule/types.d.ts.map +1 -1
- package/dist/skills/store.d.ts.map +1 -1
- package/dist/terminal/host.d.ts +22 -0
- package/dist/terminal/host.d.ts.map +1 -0
- package/dist/terminal/manager.d.ts +124 -0
- package/dist/terminal/manager.d.ts.map +1 -0
- package/dist/terminal/protocol.d.ts +162 -0
- package/dist/terminal/protocol.d.ts.map +1 -0
- package/dist/terminal/pty.d.ts +85 -0
- package/dist/terminal/pty.d.ts.map +1 -0
- package/dist/terminal/ring.d.ts +23 -0
- package/dist/terminal/ring.d.ts.map +1 -0
- package/dist/terminal/screen.d.ts +31 -0
- package/dist/terminal/screen.d.ts.map +1 -0
- package/dist/termination-state.d.ts +19 -0
- package/dist/termination-state.d.ts.map +1 -0
- package/dist/termination.d.ts +2 -9
- package/dist/termination.d.ts.map +1 -1
- package/dist/tui/AgentExplorer.d.ts +4 -1
- package/dist/tui/AgentExplorer.d.ts.map +1 -1
- package/dist/tui/App.d.ts.map +1 -1
- package/dist/tui/BackgroundJobsPanel.d.ts.map +1 -1
- package/dist/tui/BrandHeader.d.ts.map +1 -1
- package/dist/tui/ChildComposer.d.ts +22 -0
- package/dist/tui/ChildComposer.d.ts.map +1 -0
- package/dist/tui/ChoicePicker.d.ts.map +1 -1
- package/dist/tui/Composer.d.ts +19 -3
- package/dist/tui/Composer.d.ts.map +1 -1
- package/dist/tui/ComposerFrame.d.ts.map +1 -1
- package/dist/tui/CopyPicker.d.ts.map +1 -1
- package/dist/tui/EditPromptPicker.d.ts.map +1 -1
- package/dist/tui/EffortSlider.d.ts.map +1 -1
- package/dist/tui/LiveActivity.d.ts +7 -1
- package/dist/tui/LiveActivity.d.ts.map +1 -1
- package/dist/tui/Markdown.d.ts.map +1 -1
- package/dist/tui/PendingInputPanel.d.ts.map +1 -1
- package/dist/tui/PermissionOverlay.d.ts.map +1 -1
- package/dist/tui/Picker.d.ts.map +1 -1
- package/dist/tui/ProviderSetup.d.ts.map +1 -1
- package/dist/tui/ResumePicker.d.ts.map +1 -1
- package/dist/tui/SaveSkillOverlay.d.ts.map +1 -1
- package/dist/tui/ScheduleReviewOverlay.d.ts +1 -1
- package/dist/tui/ScheduleReviewOverlay.d.ts.map +1 -1
- package/dist/tui/StatusBar.d.ts +7 -1
- package/dist/tui/StatusBar.d.ts.map +1 -1
- package/dist/tui/StatusPanel.d.ts.map +1 -1
- package/dist/tui/TextPrompt.d.ts.map +1 -1
- package/dist/tui/ToolOutputViewer.d.ts.map +1 -1
- package/dist/tui/Transcript.d.ts.map +1 -1
- package/dist/tui/TrustPrompt.d.ts +8 -0
- package/dist/tui/TrustPrompt.d.ts.map +1 -1
- package/dist/tui/agent.d.ts +125 -3
- package/dist/tui/agent.d.ts.map +1 -1
- package/dist/tui/browser-notices.d.ts.map +1 -1
- package/dist/tui/capability-notice.d.ts +38 -0
- package/dist/tui/capability-notice.d.ts.map +1 -0
- package/dist/tui/console-input.d.ts +31 -0
- package/dist/tui/console-input.d.ts.map +1 -0
- package/dist/tui/conversation-evidence-view.d.ts.map +1 -1
- package/dist/tui/credential-entry.d.ts.map +1 -1
- package/dist/tui/exit-summary.d.ts +9 -1
- package/dist/tui/exit-summary.d.ts.map +1 -1
- package/dist/tui/external-editor.d.ts.map +1 -1
- package/dist/tui/index.d.ts.map +1 -1
- package/dist/tui/key-hints.d.ts +51 -0
- package/dist/tui/key-hints.d.ts.map +1 -0
- package/dist/tui/launch-settings.d.ts +34 -0
- package/dist/tui/launch-settings.d.ts.map +1 -0
- package/dist/tui/log-pane.d.ts.map +1 -1
- package/dist/tui/model-choices.d.ts +39 -1
- package/dist/tui/model-choices.d.ts.map +1 -1
- package/dist/tui/model-search.d.ts +4 -1
- package/dist/tui/model-search.d.ts.map +1 -1
- package/dist/tui/output-size-watch.d.ts +32 -0
- package/dist/tui/output-size-watch.d.ts.map +1 -0
- package/dist/tui/permission-review.d.ts.map +1 -1
- package/dist/tui/person-terms.d.ts +58 -0
- package/dist/tui/person-terms.d.ts.map +1 -0
- package/dist/tui/plain-failure.d.ts +27 -0
- package/dist/tui/plain-failure.d.ts.map +1 -0
- package/dist/tui/plain-interruption.d.ts +46 -0
- package/dist/tui/plain-interruption.d.ts.map +1 -0
- package/dist/tui/provider-list.d.ts.map +1 -1
- package/dist/tui/render-mode.d.ts +19 -0
- package/dist/tui/render-mode.d.ts.map +1 -0
- package/dist/tui/schedule/host-commands.d.ts +2 -9
- package/dist/tui/schedule/host-commands.d.ts.map +1 -1
- package/dist/tui/schedule/integration.d.ts +8 -0
- package/dist/tui/schedule/integration.d.ts.map +1 -1
- package/dist/tui/schedule/source-deliveries.d.ts +37 -0
- package/dist/tui/schedule/source-deliveries.d.ts.map +1 -0
- package/dist/tui/schedule/startup.d.ts.map +1 -1
- package/dist/tui/schedule/tool-host.d.ts +3 -1
- package/dist/tui/schedule/tool-host.d.ts.map +1 -1
- package/dist/tui/setup-text.d.ts +14 -0
- package/dist/tui/setup-text.d.ts.map +1 -0
- package/dist/tui/shell-escape.d.ts.map +1 -1
- package/dist/tui/skills/suggest-setting.d.ts.map +1 -1
- package/dist/tui/slashCommands.d.ts +4 -1
- package/dist/tui/slashCommands.d.ts.map +1 -1
- package/dist/tui/terminal-choice-text.d.ts +7 -0
- package/dist/tui/terminal-choice-text.d.ts.map +1 -1
- package/dist/tui/tidy-tool-output.d.ts +83 -0
- package/dist/tui/tidy-tool-output.d.ts.map +1 -0
- package/dist/tui/tool-presentation.d.ts +6 -0
- package/dist/tui/tool-presentation.d.ts.map +1 -0
- package/dist/tui/triggers/copy.d.ts.map +1 -1
- package/dist/tui/triggers/setting.d.ts.map +1 -1
- package/dist/tui/turn-interruption.d.ts +1 -1
- package/dist/tui/turn-interruption.d.ts.map +1 -1
- package/dist/tui/turn-limits-settings.d.ts +4 -4
- package/dist/tui/turn-limits-settings.d.ts.map +1 -1
- package/dist/tui/types.d.ts +10 -0
- package/dist/tui/types.d.ts.map +1 -1
- package/dist/tui/web-activity.d.ts +3 -2
- package/dist/tui/web-activity.d.ts.map +1 -1
- package/dist/tui/zen-free-refusal.d.ts +17 -0
- package/dist/tui/zen-free-refusal.d.ts.map +1 -0
- package/dist/usage-error.d.ts +15 -0
- package/dist/usage-error.d.ts.map +1 -0
- package/dist/warning-filter.d.ts +30 -0
- package/dist/warning-filter.d.ts.map +1 -0
- package/package.json +21 -10
- package/skills/schedule-task/SKILL.md +74 -20
- package/dist/browser/commands.js +0 -365
- package/dist/browser/commands.js.map +0 -1
- package/dist/browser/control.js +0 -140
- package/dist/browser/control.js.map +0 -1
- package/dist/browser/describe.js +0 -27
- package/dist/browser/describe.js.map +0 -1
- package/dist/checkpoints/store.js +0 -192
- package/dist/checkpoints/store.js.map +0 -1
- package/dist/checkpoints/wrap.js +0 -37
- package/dist/checkpoints/wrap.js.map +0 -1
- package/dist/cli.js +0 -602
- package/dist/cli.js.map +0 -1
- package/dist/commands/acp.js +0 -388
- package/dist/commands/acp.js.map +0 -1
- package/dist/commands/archive.js +0 -65
- package/dist/commands/archive.js.map +0 -1
- package/dist/commands/browser.js +0 -16
- package/dist/commands/browser.js.map +0 -1
- package/dist/commands/doctor.js +0 -267
- package/dist/commands/doctor.js.map +0 -1
- package/dist/commands/drain.js +0 -498
- package/dist/commands/drain.js.map +0 -1
- package/dist/commands/eval.js +0 -237
- package/dist/commands/eval.js.map +0 -1
- package/dist/commands/exec-flags.js +0 -334
- package/dist/commands/exec-flags.js.map +0 -1
- package/dist/commands/exec-json.js +0 -497
- package/dist/commands/exec-json.js.map +0 -1
- package/dist/commands/exec.js +0 -688
- package/dist/commands/exec.js.map +0 -1
- package/dist/commands/host-queries.js +0 -156
- package/dist/commands/host-queries.js.map +0 -1
- package/dist/commands/login.js +0 -315
- package/dist/commands/login.js.map +0 -1
- package/dist/commands/mcp-oauth-login.js +0 -213
- package/dist/commands/mcp-oauth-login.js.map +0 -1
- package/dist/commands/mcp.js +0 -461
- package/dist/commands/mcp.js.map +0 -1
- package/dist/commands/prior-messages.js +0 -329
- package/dist/commands/prior-messages.js.map +0 -1
- package/dist/commands/provider-wait.js +0 -65
- package/dist/commands/provider-wait.js.map +0 -1
- package/dist/commands/registry.js +0 -40
- package/dist/commands/registry.js.map +0 -1
- package/dist/commands/resident-flags.js +0 -193
- package/dist/commands/resident-flags.js.map +0 -1
- package/dist/commands/resident-learning.js +0 -293
- package/dist/commands/resident-learning.js.map +0 -1
- package/dist/commands/resident.js +0 -419
- package/dist/commands/resident.js.map +0 -1
- package/dist/commands/resume.js +0 -109
- package/dist/commands/resume.js.map +0 -1
- package/dist/commands/schedule.js +0 -131
- package/dist/commands/schedule.js.map +0 -1
- package/dist/commands/serve.js +0 -21
- package/dist/commands/serve.js.map +0 -1
- package/dist/commands/skills.js +0 -178
- package/dist/commands/skills.js.map +0 -1
- package/dist/commands/state.js +0 -110
- package/dist/commands/state.js.map +0 -1
- package/dist/commands/stdin.js +0 -69
- package/dist/commands/stdin.js.map +0 -1
- package/dist/commands/types.js +0 -2
- package/dist/commands/types.js.map +0 -1
- package/dist/commands/upgrade-progress.js +0 -54
- package/dist/commands/upgrade-progress.js.map +0 -1
- package/dist/commands/upgrade.js +0 -232
- package/dist/commands/upgrade.js.map +0 -1
- package/dist/commands/worktree.js +0 -86
- package/dist/commands/worktree.js.map +0 -1
- package/dist/config/composer-triggers.js +0 -80
- package/dist/config/composer-triggers.js.map +0 -1
- package/dist/config/debug.js +0 -126
- package/dist/config/debug.js.map +0 -1
- package/dist/config/load.js +0 -1208
- package/dist/config/load.js.map +0 -1
- package/dist/config/schema.js +0 -13
- package/dist/config/schema.js.map +0 -1
- package/dist/config/tool-result-screens.js +0 -104
- package/dist/config/tool-result-screens.js.map +0 -1
- package/dist/config/trusted-project-context.js +0 -28
- package/dist/config/trusted-project-context.js.map +0 -1
- package/dist/config/turn-guards.js +0 -46
- package/dist/config/turn-guards.js.map +0 -1
- package/dist/config/user-config.js +0 -118
- package/dist/config/user-config.js.map +0 -1
- package/dist/context/capabilities.js +0 -164
- package/dist/context/capabilities.js.map +0 -1
- package/dist/context/directories.js +0 -69
- package/dist/context/directories.js.map +0 -1
- package/dist/context/doctrine.js +0 -24
- package/dist/context/doctrine.js.map +0 -1
- package/dist/context/environment.js +0 -255
- package/dist/context/environment.js.map +0 -1
- package/dist/context/project-path.js +0 -16
- package/dist/context/project-path.js.map +0 -1
- package/dist/context/project-tracker.js +0 -217
- package/dist/context/project-tracker.js.map +0 -1
- package/dist/context/project.js +0 -256
- package/dist/context/project.js.map +0 -1
- package/dist/context/runtime-message.js +0 -30
- package/dist/context/runtime-message.js.map +0 -1
- package/dist/context/sandbox.js +0 -114
- package/dist/context/sandbox.js.map +0 -1
- package/dist/context/turn-snapshot.js +0 -122
- package/dist/context/turn-snapshot.js.map +0 -1
- package/dist/doctor/checks/browser.js +0 -63
- package/dist/doctor/checks/browser.js.map +0 -1
- package/dist/doctor/checks/chain.js +0 -211
- package/dist/doctor/checks/chain.js.map +0 -1
- package/dist/doctor/checks/credentials.js +0 -98
- package/dist/doctor/checks/credentials.js.map +0 -1
- package/dist/doctor/checks/index.js +0 -72
- package/dist/doctor/checks/index.js.map +0 -1
- package/dist/doctor/checks/invariants.js +0 -79
- package/dist/doctor/checks/invariants.js.map +0 -1
- package/dist/doctor/checks/logging.js +0 -69
- package/dist/doctor/checks/logging.js.map +0 -1
- package/dist/doctor/checks/providers.js +0 -30
- package/dist/doctor/checks/providers.js.map +0 -1
- package/dist/doctor/checks/runtime.js +0 -40
- package/dist/doctor/checks/runtime.js.map +0 -1
- package/dist/doctor/checks/sandbox.js +0 -76
- package/dist/doctor/checks/sandbox.js.map +0 -1
- package/dist/doctor/checks/scheduler.js +0 -74
- package/dist/doctor/checks/scheduler.js.map +0 -1
- package/dist/doctor/checks/session-export.js +0 -62
- package/dist/doctor/checks/session-export.js.map +0 -1
- package/dist/doctor/checks/telemetry.js +0 -58
- package/dist/doctor/checks/telemetry.js.map +0 -1
- package/dist/doctor/checks/vault.js +0 -67
- package/dist/doctor/checks/vault.js.map +0 -1
- package/dist/doctor/index.js +0 -3
- package/dist/doctor/index.js.map +0 -1
- package/dist/doctor/registry.js +0 -230
- package/dist/doctor/registry.js.map +0 -1
- package/dist/exit-codes.js +0 -62
- package/dist/exit-codes.js.map +0 -1
- package/dist/installation.js +0 -48
- package/dist/installation.js.map +0 -1
- package/dist/integrations/clipboard/image.js +0 -119
- package/dist/integrations/clipboard/image.js.map +0 -1
- package/dist/integrations/clipboard/text.js +0 -43
- package/dist/integrations/clipboard/text.js.map +0 -1
- package/dist/integrations/files/attachment-store.js +0 -86
- package/dist/integrations/files/attachment-store.js.map +0 -1
- package/dist/integrations/mcp/oauth-store.js +0 -549
- package/dist/integrations/mcp/oauth-store.js.map +0 -1
- package/dist/integrations/mcp/servers.js +0 -611
- package/dist/integrations/mcp/servers.js.map +0 -1
- package/dist/integrations/mcp/user-config.js +0 -92
- package/dist/integrations/mcp/user-config.js.map +0 -1
- package/dist/integrations/notifications/desktop/freedesktop.js +0 -33
- package/dist/integrations/notifications/desktop/freedesktop.js.map +0 -1
- package/dist/integrations/notifications/desktop/macos.js +0 -17
- package/dist/integrations/notifications/desktop/macos.js.map +0 -1
- package/dist/integrations/notifications/desktop/sanitize.js +0 -49
- package/dist/integrations/notifications/desktop/sanitize.js.map +0 -1
- package/dist/integrations/notifications/desktop/throttle.js +0 -39
- package/dist/integrations/notifications/desktop/throttle.js.map +0 -1
- package/dist/integrations/notifications/desktop/windows-toast.js +0 -56
- package/dist/integrations/notifications/desktop/windows-toast.js.map +0 -1
- package/dist/integrations/notifications/desktop.js +0 -199
- package/dist/integrations/notifications/desktop.js.map +0 -1
- package/dist/integrations/notifications/terminal.js +0 -46
- package/dist/integrations/notifications/terminal.js.map +0 -1
- package/dist/integrations/npm-invocation.js +0 -23
- package/dist/integrations/npm-invocation.js.map +0 -1
- package/dist/integrations/plugins/runtime.js +0 -189
- package/dist/integrations/plugins/runtime.js.map +0 -1
- package/dist/integrations/plugins/settings.js +0 -106
- package/dist/integrations/plugins/settings.js.map +0 -1
- package/dist/integrations/providers/access.js +0 -23
- package/dist/integrations/providers/access.js.map +0 -1
- package/dist/integrations/providers/chain-capabilities.js +0 -211
- package/dist/integrations/providers/chain-capabilities.js.map +0 -1
- package/dist/integrations/providers/codex-device-login.js +0 -195
- package/dist/integrations/providers/codex-device-login.js.map +0 -1
- package/dist/integrations/providers/codex-oauth.js +0 -95
- package/dist/integrations/providers/codex-oauth.js.map +0 -1
- package/dist/integrations/providers/credential-provider.js +0 -74
- package/dist/integrations/providers/credential-provider.js.map +0 -1
- package/dist/integrations/providers/credential-store.js +0 -657
- package/dist/integrations/providers/credential-store.js.map +0 -1
- package/dist/integrations/providers/current-credential.js +0 -45
- package/dist/integrations/providers/current-credential.js.map +0 -1
- package/dist/integrations/providers/discover.js +0 -313
- package/dist/integrations/providers/discover.js.map +0 -1
- package/dist/integrations/providers/gemini-credentials.js +0 -148
- package/dist/integrations/providers/gemini-credentials.js.map +0 -1
- package/dist/integrations/providers/harness-credentials.js +0 -344
- package/dist/integrations/providers/harness-credentials.js.map +0 -1
- package/dist/integrations/providers/identity.js +0 -64
- package/dist/integrations/providers/identity.js.map +0 -1
- package/dist/integrations/providers/index.js +0 -14
- package/dist/integrations/providers/index.js.map +0 -1
- package/dist/integrations/providers/keychain.js +0 -78
- package/dist/integrations/providers/keychain.js.map +0 -1
- package/dist/integrations/providers/model-reasoning.js +0 -51
- package/dist/integrations/providers/model-reasoning.js.map +0 -1
- package/dist/integrations/providers/oauth.js +0 -302
- package/dist/integrations/providers/oauth.js.map +0 -1
- package/dist/integrations/providers/preferences.js +0 -287
- package/dist/integrations/providers/preferences.js.map +0 -1
- package/dist/integrations/providers/register.js +0 -154
- package/dist/integrations/providers/register.js.map +0 -1
- package/dist/integrations/providers/registry.js +0 -289
- package/dist/integrations/providers/registry.js.map +0 -1
- package/dist/integrations/providers/setup.js +0 -158
- package/dist/integrations/providers/setup.js.map +0 -1
- package/dist/integrations/providers/subscription-login.js +0 -328
- package/dist/integrations/providers/subscription-login.js.map +0 -1
- package/dist/integrations/providers/zen-catalogue.js +0 -196
- package/dist/integrations/providers/zen-catalogue.js.map +0 -1
- package/dist/integrations/resident/foreground.js +0 -95
- package/dist/integrations/resident/foreground.js.map +0 -1
- package/dist/integrations/resident/inspection.js +0 -282
- package/dist/integrations/resident/inspection.js.map +0 -1
- package/dist/integrations/resident/learning-sources.js +0 -79
- package/dist/integrations/resident/learning-sources.js.map +0 -1
- package/dist/integrations/resident/learning-storage.js +0 -55
- package/dist/integrations/resident/learning-storage.js.map +0 -1
- package/dist/integrations/resident/lifecycle-errors.js +0 -15
- package/dist/integrations/resident/lifecycle-errors.js.map +0 -1
- package/dist/integrations/resident/owned-runner.js +0 -91
- package/dist/integrations/resident/owned-runner.js.map +0 -1
- package/dist/integrations/resident/runner-control.js +0 -238
- package/dist/integrations/resident/runner-control.js.map +0 -1
- package/dist/integrations/resident/runner-launch.js +0 -142
- package/dist/integrations/resident/runner-launch.js.map +0 -1
- package/dist/integrations/resident/runner-store.js +0 -284
- package/dist/integrations/resident/runner-store.js.map +0 -1
- package/dist/integrations/resident/session-log-reads.js +0 -125
- package/dist/integrations/resident/session-log-reads.js.map +0 -1
- package/dist/integrations/resident/session-step.js +0 -476
- package/dist/integrations/resident/session-step.js.map +0 -1
- package/dist/integrations/resident/storage.js +0 -183
- package/dist/integrations/resident/storage.js.map +0 -1
- package/dist/integrations/resident/tool-evidence.js +0 -123
- package/dist/integrations/resident/tool-evidence.js.map +0 -1
- package/dist/integrations/resident/verification.js +0 -109
- package/dist/integrations/resident/verification.js.map +0 -1
- package/dist/integrations/sessions/checkpoint-view.js +0 -48
- package/dist/integrations/sessions/checkpoint-view.js.map +0 -1
- package/dist/integrations/sessions/context-inventory.js +0 -44
- package/dist/integrations/sessions/context-inventory.js.map +0 -1
- package/dist/integrations/sessions/conversation-search.js +0 -572
- package/dist/integrations/sessions/conversation-search.js.map +0 -1
- package/dist/integrations/sessions/display-title.js +0 -5
- package/dist/integrations/sessions/display-title.js.map +0 -1
- package/dist/integrations/sessions/evidence-page-validation.js +0 -74
- package/dist/integrations/sessions/evidence-page-validation.js.map +0 -1
- package/dist/integrations/sessions/evidence-recall.js +0 -117
- package/dist/integrations/sessions/evidence-recall.js.map +0 -1
- package/dist/integrations/sessions/store.js +0 -780
- package/dist/integrations/sessions/store.js.map +0 -1
- package/dist/integrations/sessions/task-context.js +0 -96
- package/dist/integrations/sessions/task-context.js.map +0 -1
- package/dist/integrations/sessions/transcript-export.js +0 -342
- package/dist/integrations/sessions/transcript-export.js.map +0 -1
- package/dist/integrations/state/home.js +0 -17
- package/dist/integrations/state/home.js.map +0 -1
- package/dist/integrations/state/identity.js +0 -49
- package/dist/integrations/state/identity.js.map +0 -1
- package/dist/integrations/state/immutable-json.js +0 -38
- package/dist/integrations/state/immutable-json.js.map +0 -1
- package/dist/integrations/state/private-directory.js +0 -43
- package/dist/integrations/state/private-directory.js.map +0 -1
- package/dist/integrations/state/project.js +0 -13
- package/dist/integrations/state/project.js.map +0 -1
- package/dist/integrations/state/report.js +0 -626
- package/dist/integrations/state/report.js.map +0 -1
- package/dist/integrations/state/retention.js +0 -18
- package/dist/integrations/state/retention.js.map +0 -1
- package/dist/integrations/subagents/NamzuCliAgent.js +0 -9
- package/dist/integrations/subagents/NamzuCliAgent.js.map +0 -1
- package/dist/integrations/subagents/activity.js +0 -759
- package/dist/integrations/subagents/activity.js.map +0 -1
- package/dist/integrations/subagents/batches.js +0 -172
- package/dist/integrations/subagents/batches.js.map +0 -1
- package/dist/integrations/subagents/definitions.js +0 -26
- package/dist/integrations/subagents/definitions.js.map +0 -1
- package/dist/integrations/subagents/model-effort.js +0 -12
- package/dist/integrations/subagents/model-effort.js.map +0 -1
- package/dist/integrations/subagents/parent.js +0 -47
- package/dist/integrations/subagents/parent.js.map +0 -1
- package/dist/integrations/subagents/policy.js +0 -3
- package/dist/integrations/subagents/policy.js.map +0 -1
- package/dist/integrations/subagents/replay.js +0 -295
- package/dist/integrations/subagents/replay.js.map +0 -1
- package/dist/integrations/subagents/runtime.js +0 -1317
- package/dist/integrations/subagents/runtime.js.map +0 -1
- package/dist/integrations/subagents/saved-agents.js +0 -102
- package/dist/integrations/subagents/saved-agents.js.map +0 -1
- package/dist/integrations/subagents/slash.js +0 -45
- package/dist/integrations/subagents/slash.js.map +0 -1
- package/dist/integrations/subagents/worktree-driver.js +0 -72
- package/dist/integrations/subagents/worktree-driver.js.map +0 -1
- package/dist/integrations/telemetry/session-export.js +0 -119
- package/dist/integrations/telemetry/session-export.js.map +0 -1
- package/dist/integrations/trust/store.js +0 -73
- package/dist/integrations/trust/store.js.map +0 -1
- package/dist/integrations/updates.js +0 -115
- package/dist/integrations/updates.js.map +0 -1
- package/dist/integrations/web/exa-search.js +0 -154
- package/dist/integrations/web/exa-search.js.map +0 -1
- package/dist/integrations/web/open-url.js +0 -73
- package/dist/integrations/web/open-url.js.map +0 -1
- package/dist/integrations/web/search.js +0 -68
- package/dist/integrations/web/search.js.map +0 -1
- package/dist/integrations/worktrees/managed.js +0 -231
- package/dist/integrations/worktrees/managed.js.map +0 -1
- package/dist/logging.js +0 -115
- package/dist/logging.js.map +0 -1
- package/dist/memory/io.js +0 -177
- package/dist/memory/io.js.map +0 -1
- package/dist/memory/presentation.js +0 -76
- package/dist/memory/presentation.js.map +0 -1
- package/dist/memory/store.js +0 -180
- package/dist/memory/store.js.map +0 -1
- package/dist/memory/typed.js +0 -336
- package/dist/memory/typed.js.map +0 -1
- package/dist/output/formatter.js +0 -16
- package/dist/output/formatter.js.map +0 -1
- package/dist/output/index.js +0 -22
- package/dist/output/index.js.map +0 -1
- package/dist/output/json.js +0 -51
- package/dist/output/json.js.map +0 -1
- package/dist/output/text.js +0 -50
- package/dist/output/text.js.map +0 -1
- package/dist/output/yaml.js +0 -26
- package/dist/output/yaml.js.map +0 -1
- package/dist/output-schema.js +0 -18
- package/dist/output-schema.js.map +0 -1
- package/dist/permissions/browser-sites.js +0 -270
- package/dist/permissions/browser-sites.js.map +0 -1
- package/dist/permissions/canonical-project.js +0 -13
- package/dist/permissions/canonical-project.js.map +0 -1
- package/dist/permissions/checks.js +0 -128
- package/dist/permissions/checks.js.map +0 -1
- package/dist/permissions/headless-trust.js +0 -86
- package/dist/permissions/headless-trust.js.map +0 -1
- package/dist/permissions/live-mode.js +0 -62
- package/dist/permissions/live-mode.js.map +0 -1
- package/dist/permissions/mode.js +0 -65
- package/dist/permissions/mode.js.map +0 -1
- package/dist/permissions/rules.js +0 -358
- package/dist/permissions/rules.js.map +0 -1
- package/dist/release-notes.js +0 -64
- package/dist/release-notes.js.map +0 -1
- package/dist/resume-invocation.js +0 -24
- package/dist/resume-invocation.js.map +0 -1
- package/dist/schedule/build.js +0 -374
- package/dist/schedule/build.js.map +0 -1
- package/dist/schedule/changes.js +0 -78
- package/dist/schedule/changes.js.map +0 -1
- package/dist/schedule/commands/add.js +0 -603
- package/dist/schedule/commands/add.js.map +0 -1
- package/dist/schedule/commands/args.js +0 -80
- package/dist/schedule/commands/args.js.map +0 -1
- package/dist/schedule/commands/confirm-prompt.js +0 -21
- package/dist/schedule/commands/confirm-prompt.js.map +0 -1
- package/dist/schedule/commands/lifecycle.js +0 -586
- package/dist/schedule/commands/lifecycle.js.map +0 -1
- package/dist/schedule/commands/list.js +0 -260
- package/dist/schedule/commands/list.js.map +0 -1
- package/dist/schedule/commands/logs.js +0 -106
- package/dist/schedule/commands/logs.js.map +0 -1
- package/dist/schedule/commands/service.js +0 -458
- package/dist/schedule/commands/service.js.map +0 -1
- package/dist/schedule/daemon/daemon.js +0 -1265
- package/dist/schedule/daemon/daemon.js.map +0 -1
- package/dist/schedule/daemon/endpoint.js +0 -158
- package/dist/schedule/daemon/endpoint.js.map +0 -1
- package/dist/schedule/daemon/exit.js +0 -8
- package/dist/schedule/daemon/exit.js.map +0 -1
- package/dist/schedule/daemon/log.js +0 -53
- package/dist/schedule/daemon/log.js.map +0 -1
- package/dist/schedule/daemon/notify.js +0 -158
- package/dist/schedule/daemon/notify.js.map +0 -1
- package/dist/schedule/daemon/retention.js +0 -46
- package/dist/schedule/daemon/retention.js.map +0 -1
- package/dist/schedule/daemon/sessions.js +0 -52
- package/dist/schedule/daemon/sessions.js.map +0 -1
- package/dist/schedule/env.js +0 -106
- package/dist/schedule/env.js.map +0 -1
- package/dist/schedule/fire/browser-preflight.js +0 -73
- package/dist/schedule/fire/browser-preflight.js.map +0 -1
- package/dist/schedule/fire/calls.js +0 -114
- package/dist/schedule/fire/calls.js.map +0 -1
- package/dist/schedule/fire/fire.js +0 -681
- package/dist/schedule/fire/fire.js.map +0 -1
- package/dist/schedule/fire/result.js +0 -19
- package/dist/schedule/fire/result.js.map +0 -1
- package/dist/schedule/fire/run-script.js +0 -81
- package/dist/schedule/fire/run-script.js.map +0 -1
- package/dist/schedule/fire/unattended-note.js +0 -51
- package/dist/schedule/fire/unattended-note.js.map +0 -1
- package/dist/schedule/fire/wake-gate.js +0 -90
- package/dist/schedule/fire/wake-gate.js.map +0 -1
- package/dist/schedule/floor.js +0 -1561
- package/dist/schedule/floor.js.map +0 -1
- package/dist/schedule/folder.js +0 -84
- package/dist/schedule/folder.js.map +0 -1
- package/dist/schedule/paths.js +0 -53
- package/dist/schedule/paths.js.map +0 -1
- package/dist/schedule/policy.js +0 -414
- package/dist/schedule/policy.js.map +0 -1
- package/dist/schedule/resume-command.js +0 -72
- package/dist/schedule/resume-command.js.map +0 -1
- package/dist/schedule/script-check.js +0 -146
- package/dist/schedule/script-check.js.map +0 -1
- package/dist/schedule/script-shell.js +0 -5
- package/dist/schedule/script-shell.js.map +0 -1
- package/dist/schedule/service/detect.js +0 -29
- package/dist/schedule/service/detect.js.map +0 -1
- package/dist/schedule/service/index.js +0 -361
- package/dist/schedule/service/index.js.map +0 -1
- package/dist/schedule/service/launchd.js +0 -84
- package/dist/schedule/service/launchd.js.map +0 -1
- package/dist/schedule/service/manifest.js +0 -16
- package/dist/schedule/service/manifest.js.map +0 -1
- package/dist/schedule/service/names.js +0 -22
- package/dist/schedule/service/names.js.map +0 -1
- package/dist/schedule/service/quote.js +0 -64
- package/dist/schedule/service/quote.js.map +0 -1
- package/dist/schedule/service/runner.js +0 -31
- package/dist/schedule/service/runner.js.map +0 -1
- package/dist/schedule/service/systemd.js +0 -96
- package/dist/schedule/service/systemd.js.map +0 -1
- package/dist/schedule/service/windows-task.js +0 -199
- package/dist/schedule/service/windows-task.js.map +0 -1
- package/dist/schedule/service/wsl.js +0 -121
- package/dist/schedule/service/wsl.js.map +0 -1
- package/dist/schedule/store/atomic.js +0 -138
- package/dist/schedule/store/atomic.js.map +0 -1
- package/dist/schedule/store/claims.js +0 -57
- package/dist/schedule/store/claims.js.map +0 -1
- package/dist/schedule/store/digest.js +0 -139
- package/dist/schedule/store/digest.js.map +0 -1
- package/dist/schedule/store/history.js +0 -117
- package/dist/schedule/store/history.js.map +0 -1
- package/dist/schedule/store/jobs.js +0 -277
- package/dist/schedule/store/jobs.js.map +0 -1
- package/dist/schedule/store/state.js +0 -38
- package/dist/schedule/store/state.js.map +0 -1
- package/dist/schedule/types.js +0 -33
- package/dist/schedule/types.js.map +0 -1
- package/dist/schedule/visible-source.js +0 -59
- package/dist/schedule/visible-source.js.map +0 -1
- package/dist/skills/audit.js +0 -75
- package/dist/skills/audit.js.map +0 -1
- package/dist/skills/catalog.js +0 -226
- package/dist/skills/catalog.js.map +0 -1
- package/dist/skills/directory.js +0 -51
- package/dist/skills/directory.js.map +0 -1
- package/dist/skills/save.js +0 -344
- package/dist/skills/save.js.map +0 -1
- package/dist/skills/store.js +0 -351
- package/dist/skills/store.js.map +0 -1
- package/dist/termination.js +0 -143
- package/dist/termination.js.map +0 -1
- package/dist/test-support/toolset.js +0 -27
- package/dist/test-support/toolset.js.map +0 -1
- package/dist/tui/AgentExplorer.js +0 -789
- package/dist/tui/AgentExplorer.js.map +0 -1
- package/dist/tui/App.js +0 -8499
- package/dist/tui/App.js.map +0 -1
- package/dist/tui/BackgroundJobsPanel.js +0 -129
- package/dist/tui/BackgroundJobsPanel.js.map +0 -1
- package/dist/tui/BrandHeader.js +0 -14
- package/dist/tui/BrandHeader.js.map +0 -1
- package/dist/tui/Checklist.js +0 -90
- package/dist/tui/Checklist.js.map +0 -1
- package/dist/tui/ChoicePicker.js +0 -64
- package/dist/tui/ChoicePicker.js.map +0 -1
- package/dist/tui/Composer.js +0 -939
- package/dist/tui/Composer.js.map +0 -1
- package/dist/tui/ComposerFrame.js +0 -79
- package/dist/tui/ComposerFrame.js.map +0 -1
- package/dist/tui/CopyPicker.js +0 -19
- package/dist/tui/CopyPicker.js.map +0 -1
- package/dist/tui/EditPromptPicker.js +0 -17
- package/dist/tui/EditPromptPicker.js.map +0 -1
- package/dist/tui/EffortSlider.js +0 -134
- package/dist/tui/EffortSlider.js.map +0 -1
- package/dist/tui/LiveActivity.js +0 -89
- package/dist/tui/LiveActivity.js.map +0 -1
- package/dist/tui/Markdown.js +0 -137
- package/dist/tui/Markdown.js.map +0 -1
- package/dist/tui/PendingInputPanel.js +0 -108
- package/dist/tui/PendingInputPanel.js.map +0 -1
- package/dist/tui/PermissionOverlay.js +0 -278
- package/dist/tui/PermissionOverlay.js.map +0 -1
- package/dist/tui/Picker.js +0 -1310
- package/dist/tui/Picker.js.map +0 -1
- package/dist/tui/ProviderSetup.js +0 -125
- package/dist/tui/ProviderSetup.js.map +0 -1
- package/dist/tui/ResumePicker.js +0 -34
- package/dist/tui/ResumePicker.js.map +0 -1
- package/dist/tui/SaveSkillOverlay.js +0 -118
- package/dist/tui/SaveSkillOverlay.js.map +0 -1
- package/dist/tui/ScheduleReviewOverlay.js +0 -166
- package/dist/tui/ScheduleReviewOverlay.js.map +0 -1
- package/dist/tui/StatusBar.js +0 -182
- package/dist/tui/StatusBar.js.map +0 -1
- package/dist/tui/StatusPanel.js +0 -11
- package/dist/tui/StatusPanel.js.map +0 -1
- package/dist/tui/TaskList.js +0 -43
- package/dist/tui/TaskList.js.map +0 -1
- package/dist/tui/TextPrompt.js +0 -185
- package/dist/tui/TextPrompt.js.map +0 -1
- package/dist/tui/ToolOutputViewer.js +0 -39
- package/dist/tui/ToolOutputViewer.js.map +0 -1
- package/dist/tui/Transcript.js +0 -235
- package/dist/tui/Transcript.js.map +0 -1
- package/dist/tui/TrustPrompt.js +0 -13
- package/dist/tui/TrustPrompt.js.map +0 -1
- package/dist/tui/ViewportBound.js +0 -55
- package/dist/tui/ViewportBound.js.map +0 -1
- package/dist/tui/agent-transcript-rows.js +0 -115
- package/dist/tui/agent-transcript-rows.js.map +0 -1
- package/dist/tui/agent.js +0 -4301
- package/dist/tui/agent.js.map +0 -1
- package/dist/tui/browser-notices.js +0 -107
- package/dist/tui/browser-notices.js.map +0 -1
- package/dist/tui/choice-selection.js +0 -38
- package/dist/tui/choice-selection.js.map +0 -1
- package/dist/tui/compact-transcript.js +0 -46
- package/dist/tui/compact-transcript.js.map +0 -1
- package/dist/tui/consent-timing.js +0 -48
- package/dist/tui/consent-timing.js.map +0 -1
- package/dist/tui/conversation-evidence-view.js +0 -96
- package/dist/tui/conversation-evidence-view.js.map +0 -1
- package/dist/tui/conversation-history.js +0 -33
- package/dist/tui/conversation-history.js.map +0 -1
- package/dist/tui/copy-targets.js +0 -189
- package/dist/tui/copy-targets.js.map +0 -1
- package/dist/tui/credential-entry.js +0 -134
- package/dist/tui/credential-entry.js.map +0 -1
- package/dist/tui/edit-prompts.js +0 -35
- package/dist/tui/edit-prompts.js.map +0 -1
- package/dist/tui/exit-summary.js +0 -30
- package/dist/tui/exit-summary.js.map +0 -1
- package/dist/tui/external-editor.js +0 -169
- package/dist/tui/external-editor.js.map +0 -1
- package/dist/tui/hypermode.js +0 -58
- package/dist/tui/hypermode.js.map +0 -1
- package/dist/tui/index.js +0 -81
- package/dist/tui/index.js.map +0 -1
- package/dist/tui/live-window.js +0 -281
- package/dist/tui/live-window.js.map +0 -1
- package/dist/tui/log-pane.js +0 -100
- package/dist/tui/log-pane.js.map +0 -1
- package/dist/tui/login-prompt.js +0 -105
- package/dist/tui/login-prompt.js.map +0 -1
- package/dist/tui/logo.js +0 -9
- package/dist/tui/logo.js.map +0 -1
- package/dist/tui/markdown-block-cache.js +0 -76
- package/dist/tui/markdown-block-cache.js.map +0 -1
- package/dist/tui/markdown-table.js +0 -175
- package/dist/tui/markdown-table.js.map +0 -1
- package/dist/tui/markdown-wrap.js +0 -189
- package/dist/tui/markdown-wrap.js.map +0 -1
- package/dist/tui/markdownParser.js +0 -237
- package/dist/tui/markdownParser.js.map +0 -1
- package/dist/tui/mentions.js +0 -150
- package/dist/tui/mentions.js.map +0 -1
- package/dist/tui/model-catalogue-view.js +0 -75
- package/dist/tui/model-catalogue-view.js.map +0 -1
- package/dist/tui/model-choices.js +0 -157
- package/dist/tui/model-choices.js.map +0 -1
- package/dist/tui/model-search.js +0 -28
- package/dist/tui/model-search.js.map +0 -1
- package/dist/tui/model-selection-intent.js +0 -96
- package/dist/tui/model-selection-intent.js.map +0 -1
- package/dist/tui/model-switch-tool.js +0 -74
- package/dist/tui/model-switch-tool.js.map +0 -1
- package/dist/tui/model-switch.js +0 -106
- package/dist/tui/model-switch.js.map +0 -1
- package/dist/tui/notices.js +0 -27
- package/dist/tui/notices.js.map +0 -1
- package/dist/tui/open-browser.js +0 -147
- package/dist/tui/open-browser.js.map +0 -1
- package/dist/tui/permission-review.js +0 -858
- package/dist/tui/permission-review.js.map +0 -1
- package/dist/tui/plugin-view.js +0 -59
- package/dist/tui/plugin-view.js.map +0 -1
- package/dist/tui/provider-list.js +0 -327
- package/dist/tui/provider-list.js.map +0 -1
- package/dist/tui/provider-selection.js +0 -16
- package/dist/tui/provider-selection.js.map +0 -1
- package/dist/tui/schedule/host-commands.js +0 -428
- package/dist/tui/schedule/host-commands.js.map +0 -1
- package/dist/tui/schedule/integration.js +0 -150
- package/dist/tui/schedule/integration.js.map +0 -1
- package/dist/tui/schedule/loop-host.js +0 -153
- package/dist/tui/schedule/loop-host.js.map +0 -1
- package/dist/tui/schedule/resume.js +0 -333
- package/dist/tui/schedule/resume.js.map +0 -1
- package/dist/tui/schedule/startup.js +0 -121
- package/dist/tui/schedule/startup.js.map +0 -1
- package/dist/tui/schedule/tool-host.js +0 -619
- package/dist/tui/schedule/tool-host.js.map +0 -1
- package/dist/tui/selection-window.js +0 -37
- package/dist/tui/selection-window.js.map +0 -1
- package/dist/tui/shell-escape.js +0 -110
- package/dist/tui/shell-escape.js.map +0 -1
- package/dist/tui/skills/learning.js +0 -131
- package/dist/tui/skills/learning.js.map +0 -1
- package/dist/tui/skills/suggest-setting.js +0 -55
- package/dist/tui/skills/suggest-setting.js.map +0 -1
- package/dist/tui/skills/suggestion-ledger.js +0 -52
- package/dist/tui/skills/suggestion-ledger.js.map +0 -1
- package/dist/tui/slashCommands.js +0 -1588
- package/dist/tui/slashCommands.js.map +0 -1
- package/dist/tui/status-card.js +0 -30
- package/dist/tui/status-card.js.map +0 -1
- package/dist/tui/status-panel-layout.js +0 -42
- package/dist/tui/status-panel-layout.js.map +0 -1
- package/dist/tui/stream-blocks.js +0 -187
- package/dist/tui/stream-blocks.js.map +0 -1
- package/dist/tui/task-activity.js +0 -157
- package/dist/tui/task-activity.js.map +0 -1
- package/dist/tui/terminal-choice-text.js +0 -118
- package/dist/tui/terminal-choice-text.js.map +0 -1
- package/dist/tui/terminal-display.js +0 -65
- package/dist/tui/terminal-display.js.map +0 -1
- package/dist/tui/terminal-hyperlinks.js +0 -70
- package/dist/tui/terminal-hyperlinks.js.map +0 -1
- package/dist/tui/theme.js +0 -34
- package/dist/tui/theme.js.map +0 -1
- package/dist/tui/triggers/analyze.js +0 -221
- package/dist/tui/triggers/analyze.js.map +0 -1
- package/dist/tui/triggers/context-text.js +0 -44
- package/dist/tui/triggers/context-text.js.map +0 -1
- package/dist/tui/triggers/copy.js +0 -163
- package/dist/tui/triggers/copy.js.map +0 -1
- package/dist/tui/triggers/detect.js +0 -295
- package/dist/tui/triggers/detect.js.map +0 -1
- package/dist/tui/triggers/fold.js +0 -44
- package/dist/tui/triggers/fold.js.map +0 -1
- package/dist/tui/triggers/pattern.js +0 -243
- package/dist/tui/triggers/pattern.js.map +0 -1
- package/dist/tui/triggers/provenance.js +0 -98
- package/dist/tui/triggers/provenance.js.map +0 -1
- package/dist/tui/triggers/registry.js +0 -164
- package/dist/tui/triggers/registry.js.map +0 -1
- package/dist/tui/triggers/setting.js +0 -61
- package/dist/tui/triggers/setting.js.map +0 -1
- package/dist/tui/triggers/verbs.js +0 -140
- package/dist/tui/triggers/verbs.js.map +0 -1
- package/dist/tui/turn-interruption.js +0 -160
- package/dist/tui/turn-interruption.js.map +0 -1
- package/dist/tui/turn-limits-settings.js +0 -88
- package/dist/tui/turn-limits-settings.js.map +0 -1
- package/dist/tui/types.js +0 -7
- package/dist/tui/types.js.map +0 -1
- package/dist/tui/units.js +0 -20
- package/dist/tui/units.js.map +0 -1
- package/dist/tui/use-selection-index.js +0 -13
- package/dist/tui/use-selection-index.js.map +0 -1
- package/dist/tui/web-activity.js +0 -105
- package/dist/tui/web-activity.js.map +0 -1
- package/dist/tui/workspace-diff.js +0 -101
- package/dist/tui/workspace-diff.js.map +0 -1
- package/dist/tui/workspace-review.js +0 -67
- package/dist/tui/workspace-review.js.map +0 -1
- package/dist/user-commands/store.js +0 -235
- package/dist/user-commands/store.js.map +0 -1
- package/dist/version.js +0 -23
- package/dist/version.js.map +0 -1
|
@@ -0,0 +1,1439 @@
|
|
|
1
|
+
import { createRequire as __namzuCreateRequire } from 'node:module';
|
|
2
|
+
const require = __namzuCreateRequire(import.meta.url);
|
|
3
|
+
import {
|
|
4
|
+
isFormatName,
|
|
5
|
+
require_dist
|
|
6
|
+
} from "./chunk-KONYGNG6.js";
|
|
7
|
+
import {
|
|
8
|
+
configMetadataLiteral
|
|
9
|
+
} from "./chunk-NICLKFBG.js";
|
|
10
|
+
import {
|
|
11
|
+
TOOL_RESULT_SCREEN_NAMES,
|
|
12
|
+
TOOL_RESULT_SCREEN_OPTION_KEYS,
|
|
13
|
+
isToolResultScreenName
|
|
14
|
+
} from "./chunk-42ZK2AH4.js";
|
|
15
|
+
import {
|
|
16
|
+
homePath
|
|
17
|
+
} from "./chunk-US5ZFPAU.js";
|
|
18
|
+
import {
|
|
19
|
+
BROWSER_ACT_TOOL_NAME,
|
|
20
|
+
BROWSER_TOOL_NAME,
|
|
21
|
+
RENAMED_PLUGIN_HOOK_EVENTS,
|
|
22
|
+
SHELL_HOOK_EVENTS,
|
|
23
|
+
canonicalizeBrowserSitePattern,
|
|
24
|
+
canonicalizeBrowserUrl,
|
|
25
|
+
resolveNamzuHome
|
|
26
|
+
} from "./chunk-K5HARZ7G.js";
|
|
27
|
+
import {
|
|
28
|
+
__name,
|
|
29
|
+
__toESM
|
|
30
|
+
} from "./chunk-76FLAFCG.js";
|
|
31
|
+
|
|
32
|
+
// src/permissions/browser-sites.ts
|
|
33
|
+
var BROWSER_SITE_LEVELS = ["deny", "read", "ask", "act"];
|
|
34
|
+
var DEFAULT_BROWSER_SITE_LEVEL = "ask";
|
|
35
|
+
function isBrowserSiteLevel(value) {
|
|
36
|
+
return typeof value === "string" && BROWSER_SITE_LEVELS.includes(value);
|
|
37
|
+
}
|
|
38
|
+
__name(isBrowserSiteLevel, "isBrowserSiteLevel");
|
|
39
|
+
function canonicalBrowserSiteKey(raw) {
|
|
40
|
+
if (raw.trim() === "*") return { ok: true, key: "*" };
|
|
41
|
+
const verdict = canonicalizeBrowserSitePattern(raw);
|
|
42
|
+
return verdict.ok ? { ok: true, key: verdict.pattern } : { ok: false, reason: verdict.reason };
|
|
43
|
+
}
|
|
44
|
+
__name(canonicalBrowserSiteKey, "canonicalBrowserSiteKey");
|
|
45
|
+
function parseSite(key, level) {
|
|
46
|
+
const match = /^(https?):\/\/(\*\.)?([^:]+)(?::(\*|\d+))?$/.exec(key);
|
|
47
|
+
if (!match) return void 0;
|
|
48
|
+
return {
|
|
49
|
+
key,
|
|
50
|
+
level,
|
|
51
|
+
scheme: match[1] ?? "",
|
|
52
|
+
host: match[3] ?? "",
|
|
53
|
+
wildcardHost: match[2] !== void 0,
|
|
54
|
+
port: match[4] ?? ""
|
|
55
|
+
};
|
|
56
|
+
}
|
|
57
|
+
__name(parseSite, "parseSite");
|
|
58
|
+
function specificity(site) {
|
|
59
|
+
return (site.wildcardHost ? 0 : 1e6) + site.host.length * 10 + (site.port === "*" ? 0 : 1);
|
|
60
|
+
}
|
|
61
|
+
__name(specificity, "specificity");
|
|
62
|
+
function escapeRegExp(value) {
|
|
63
|
+
return value.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
|
|
64
|
+
}
|
|
65
|
+
__name(escapeRegExp, "escapeRegExp");
|
|
66
|
+
function originSource(site) {
|
|
67
|
+
const host = site.wildcardHost ? `(?:[^./:?#@\\[\\]]+\\.)+${escapeRegExp(site.host)}` : escapeRegExp(site.host);
|
|
68
|
+
const port = site.port === "*" ? "(?::\\d{1,5})?" : site.port === "" ? "" : `:${site.port}`;
|
|
69
|
+
return `${site.scheme}://${host}${port}`;
|
|
70
|
+
}
|
|
71
|
+
__name(originSource, "originSource");
|
|
72
|
+
var NAVIGATE = {
|
|
73
|
+
deny: "deny",
|
|
74
|
+
read: "allow",
|
|
75
|
+
ask: "review",
|
|
76
|
+
act: "allow"
|
|
77
|
+
};
|
|
78
|
+
var ACT = {
|
|
79
|
+
deny: "deny",
|
|
80
|
+
read: "deny",
|
|
81
|
+
ask: "review",
|
|
82
|
+
act: "allow"
|
|
83
|
+
};
|
|
84
|
+
function rulesFor(origin, level) {
|
|
85
|
+
const url = origin === void 0 ? "^" : `^${origin}(?:[/?#]|$)`;
|
|
86
|
+
const act = origin === void 0 ? "^" : `^${origin}$`;
|
|
87
|
+
return [
|
|
88
|
+
{
|
|
89
|
+
type: "argument_pattern",
|
|
90
|
+
toolNames: [BROWSER_TOOL_NAME],
|
|
91
|
+
argument: "url",
|
|
92
|
+
pattern: url,
|
|
93
|
+
decision: NAVIGATE[level]
|
|
94
|
+
},
|
|
95
|
+
{
|
|
96
|
+
type: "argument_pattern",
|
|
97
|
+
toolNames: [BROWSER_ACT_TOOL_NAME],
|
|
98
|
+
argument: "origin",
|
|
99
|
+
pattern: act,
|
|
100
|
+
decision: ACT[level]
|
|
101
|
+
}
|
|
102
|
+
];
|
|
103
|
+
}
|
|
104
|
+
__name(rulesFor, "rulesFor");
|
|
105
|
+
var LOOKING = [
|
|
106
|
+
{
|
|
107
|
+
type: "argument_pattern",
|
|
108
|
+
toolNames: [BROWSER_TOOL_NAME],
|
|
109
|
+
argument: "action",
|
|
110
|
+
pattern: "^(?:snapshot|screenshot|scroll|wait_for)$",
|
|
111
|
+
decision: "allow"
|
|
112
|
+
},
|
|
113
|
+
{
|
|
114
|
+
type: "argument_pattern",
|
|
115
|
+
toolNames: [BROWSER_TOOL_NAME],
|
|
116
|
+
argument: "op",
|
|
117
|
+
pattern: "^(?:list|select|close)$",
|
|
118
|
+
decision: "allow"
|
|
119
|
+
}
|
|
120
|
+
];
|
|
121
|
+
function normalizeBrowserSites(sites) {
|
|
122
|
+
const out = {};
|
|
123
|
+
const diagnostics = [];
|
|
124
|
+
for (const [raw, level] of Object.entries(sites ?? {})) {
|
|
125
|
+
if (!isBrowserSiteLevel(level)) {
|
|
126
|
+
diagnostics.push(`browser.sites."${raw}": use deny, read, ask or act`);
|
|
127
|
+
continue;
|
|
128
|
+
}
|
|
129
|
+
const verdict = canonicalBrowserSiteKey(raw);
|
|
130
|
+
if (!verdict.ok) {
|
|
131
|
+
diagnostics.push(`browser.sites."${raw}": ${verdict.reason}`);
|
|
132
|
+
continue;
|
|
133
|
+
}
|
|
134
|
+
const existing = out[verdict.key];
|
|
135
|
+
out[verdict.key] = existing === void 0 ? level : narrower(existing, level);
|
|
136
|
+
}
|
|
137
|
+
if (out["*"] === void 0) out["*"] = DEFAULT_BROWSER_SITE_LEVEL;
|
|
138
|
+
return { sites: out, diagnostics };
|
|
139
|
+
}
|
|
140
|
+
__name(normalizeBrowserSites, "normalizeBrowserSites");
|
|
141
|
+
function narrower(a, b) {
|
|
142
|
+
return BROWSER_SITE_LEVELS.indexOf(a) <= BROWSER_SITE_LEVELS.indexOf(b) ? a : b;
|
|
143
|
+
}
|
|
144
|
+
__name(narrower, "narrower");
|
|
145
|
+
function compileBrowserSites(sites) {
|
|
146
|
+
const normalized = normalizeBrowserSites(sites);
|
|
147
|
+
const diagnostics = [...normalized.diagnostics];
|
|
148
|
+
const parsed = [];
|
|
149
|
+
for (const [key, level] of Object.entries(normalized.sites)) {
|
|
150
|
+
if (key === "*") continue;
|
|
151
|
+
const site = parseSite(key, level);
|
|
152
|
+
if (site) parsed.push(site);
|
|
153
|
+
else diagnostics.push(`browser.sites."${key}": could not be read`);
|
|
154
|
+
}
|
|
155
|
+
const denies = parsed.filter((site) => site.level === "deny");
|
|
156
|
+
const others = parsed.filter((site) => site.level !== "deny").sort((a, b) => specificity(b) - specificity(a) || (a.key < b.key ? -1 : 1));
|
|
157
|
+
const rules = [
|
|
158
|
+
// A blank tab is where the browser starts; it loads nothing.
|
|
159
|
+
{
|
|
160
|
+
type: "argument_pattern",
|
|
161
|
+
toolNames: [BROWSER_TOOL_NAME],
|
|
162
|
+
argument: "url",
|
|
163
|
+
pattern: "^about:blank$",
|
|
164
|
+
decision: "allow"
|
|
165
|
+
},
|
|
166
|
+
...denies.flatMap((site) => rulesFor(originSource(site), "deny")),
|
|
167
|
+
...others.flatMap((site) => rulesFor(originSource(site), site.level)),
|
|
168
|
+
...rulesFor(void 0, normalized.sites["*"] ?? DEFAULT_BROWSER_SITE_LEVEL),
|
|
169
|
+
...LOOKING
|
|
170
|
+
];
|
|
171
|
+
return { rules, sites: normalized.sites, diagnostics };
|
|
172
|
+
}
|
|
173
|
+
__name(compileBrowserSites, "compileBrowserSites");
|
|
174
|
+
var BROWSER_TOOLS = /* @__PURE__ */ new Set([BROWSER_TOOL_NAME, BROWSER_ACT_TOOL_NAME]);
|
|
175
|
+
function isBrowserDeny(rule) {
|
|
176
|
+
switch (rule.type) {
|
|
177
|
+
case "deny_by_name":
|
|
178
|
+
return rule.toolNames.some((name) => BROWSER_TOOLS.has(name));
|
|
179
|
+
case "argument_pattern":
|
|
180
|
+
return rule.decision === "deny" && rule.toolNames.some((name) => BROWSER_TOOLS.has(name));
|
|
181
|
+
case "custom_pattern":
|
|
182
|
+
return rule.decision === "deny" && (rule.pattern.startsWith(`^${BROWSER_TOOL_NAME}`) || rule.pattern.startsWith(`^${BROWSER_ACT_TOOL_NAME}`));
|
|
183
|
+
default:
|
|
184
|
+
return false;
|
|
185
|
+
}
|
|
186
|
+
}
|
|
187
|
+
__name(isBrowserDeny, "isBrowserDeny");
|
|
188
|
+
function withBrowserSiteRules(tableRules, siteRules) {
|
|
189
|
+
return [
|
|
190
|
+
...tableRules.filter(isBrowserDeny),
|
|
191
|
+
...siteRules,
|
|
192
|
+
...tableRules.filter((rule) => !isBrowserDeny(rule))
|
|
193
|
+
];
|
|
194
|
+
}
|
|
195
|
+
__name(withBrowserSiteRules, "withBrowserSiteRules");
|
|
196
|
+
function browserSiteRuleFor(sites, origin) {
|
|
197
|
+
const normalized = normalizeBrowserSites(sites).sites;
|
|
198
|
+
const parsed = Object.entries(normalized).filter(([key]) => key !== "*").map(([key, level]) => parseSite(key, level)).filter((site) => site !== void 0);
|
|
199
|
+
const hits = parsed.filter((site) => new RegExp(`^${originSource(site)}$`).test(origin));
|
|
200
|
+
const deny = hits.find((site) => site.level === "deny");
|
|
201
|
+
if (deny) return { site: deny.key, level: "deny" };
|
|
202
|
+
const best = hits.sort((a, b) => specificity(b) - specificity(a))[0];
|
|
203
|
+
if (best) return { site: best.key, level: best.level };
|
|
204
|
+
return { site: "*", level: normalized["*"] ?? DEFAULT_BROWSER_SITE_LEVEL };
|
|
205
|
+
}
|
|
206
|
+
__name(browserSiteRuleFor, "browserSiteRuleFor");
|
|
207
|
+
function browserCallOrigin(toolName, input) {
|
|
208
|
+
if (typeof input !== "object" || input === null) return void 0;
|
|
209
|
+
const record = input;
|
|
210
|
+
if (toolName === BROWSER_ACT_TOOL_NAME) {
|
|
211
|
+
return typeof record.origin === "string" ? record.origin : void 0;
|
|
212
|
+
}
|
|
213
|
+
if (toolName === BROWSER_TOOL_NAME && typeof record.url === "string") {
|
|
214
|
+
const verdict = canonicalizeBrowserUrl(record.url);
|
|
215
|
+
return verdict.ok && verdict.url !== "about:blank" ? verdict.origin : void 0;
|
|
216
|
+
}
|
|
217
|
+
return void 0;
|
|
218
|
+
}
|
|
219
|
+
__name(browserCallOrigin, "browserCallOrigin");
|
|
220
|
+
|
|
221
|
+
// src/config/schema.ts
|
|
222
|
+
var DEFAULT_CONFIG = Object.freeze({
|
|
223
|
+
format: "text",
|
|
224
|
+
quiet: false
|
|
225
|
+
});
|
|
226
|
+
|
|
227
|
+
// src/config/load.ts
|
|
228
|
+
import { readFileSync } from "node:fs";
|
|
229
|
+
import { basename, join, resolve } from "node:path";
|
|
230
|
+
var import_yaml = __toESM(require_dist(), 1);
|
|
231
|
+
|
|
232
|
+
// src/config/composer-triggers.ts
|
|
233
|
+
var COMPOSER_TRIGGER_IDS = [
|
|
234
|
+
"hypermode",
|
|
235
|
+
"save-skill",
|
|
236
|
+
"schedule",
|
|
237
|
+
"max-effort"
|
|
238
|
+
];
|
|
239
|
+
var COMPOSER_TRIGGER_LANGUAGES = ["en", "tr"];
|
|
240
|
+
var COMPOSER_TRIGGER_DEFAULTS = {
|
|
241
|
+
hypermode: "arm",
|
|
242
|
+
"save-skill": "arm",
|
|
243
|
+
schedule: "suggest",
|
|
244
|
+
"max-effort": "off"
|
|
245
|
+
};
|
|
246
|
+
var RANK = { off: 0, suggest: 1, arm: 2 };
|
|
247
|
+
function resolveComposerTriggers(config) {
|
|
248
|
+
return {
|
|
249
|
+
enabled: config?.enabled ?? true,
|
|
250
|
+
suggest: config?.suggest ?? true,
|
|
251
|
+
languages: config?.languages ?? COMPOSER_TRIGGER_LANGUAGES,
|
|
252
|
+
arming: { ...COMPOSER_TRIGGER_DEFAULTS, ...config?.builtin ?? {} }
|
|
253
|
+
};
|
|
254
|
+
}
|
|
255
|
+
__name(resolveComposerTriggers, "resolveComposerTriggers");
|
|
256
|
+
function mergeComposerTriggers(below, layer, projectControlled) {
|
|
257
|
+
if (!projectControlled) {
|
|
258
|
+
const builtin2 = { ...below?.builtin ?? {}, ...layer.builtin ?? {} };
|
|
259
|
+
return {
|
|
260
|
+
...below ?? {},
|
|
261
|
+
...layer,
|
|
262
|
+
...Object.keys(builtin2).length > 0 ? { builtin: builtin2 } : {}
|
|
263
|
+
};
|
|
264
|
+
}
|
|
265
|
+
const current = resolveComposerTriggers(below);
|
|
266
|
+
const enabled = current.enabled && (layer.enabled ?? true);
|
|
267
|
+
const suggest = current.suggest && (layer.suggest ?? true);
|
|
268
|
+
const languages = layer.languages ? current.languages.filter((language) => layer.languages?.includes(language)) : void 0;
|
|
269
|
+
const builtin = {
|
|
270
|
+
...below?.builtin ?? {}
|
|
271
|
+
};
|
|
272
|
+
for (const [id, arming] of Object.entries(layer.builtin ?? {})) {
|
|
273
|
+
const now = current.arming[id];
|
|
274
|
+
builtin[id] = RANK[arming] < RANK[now] ? arming : now;
|
|
275
|
+
}
|
|
276
|
+
return {
|
|
277
|
+
...below ?? {},
|
|
278
|
+
...layer.enabled !== void 0 || below?.enabled !== void 0 ? { enabled } : {},
|
|
279
|
+
...layer.suggest !== void 0 || below?.suggest !== void 0 ? { suggest } : {},
|
|
280
|
+
...languages !== void 0 ? { languages } : {},
|
|
281
|
+
...Object.keys(builtin).length > 0 ? { builtin } : {}
|
|
282
|
+
};
|
|
283
|
+
}
|
|
284
|
+
__name(mergeComposerTriggers, "mergeComposerTriggers");
|
|
285
|
+
|
|
286
|
+
// src/config/load.ts
|
|
287
|
+
var MANAGED_CONFIG_PATH = process.platform === "win32" ? join(process.env.PROGRAMDATA ?? "C:\\ProgramData", "namzu", "config.json") : "/etc/namzu/config.json";
|
|
288
|
+
function loadConfigWithProvenance(opts = {}) {
|
|
289
|
+
return resolveConfigWithProvenance(opts, {
|
|
290
|
+
includeProject: true,
|
|
291
|
+
deferUnknownProfile: false
|
|
292
|
+
});
|
|
293
|
+
}
|
|
294
|
+
__name(loadConfigWithProvenance, "loadConfigWithProvenance");
|
|
295
|
+
function loadBootstrapConfigWithProvenance(opts = {}) {
|
|
296
|
+
return resolveConfigWithProvenance(opts, {
|
|
297
|
+
includeProject: false,
|
|
298
|
+
deferUnknownProfile: true
|
|
299
|
+
});
|
|
300
|
+
}
|
|
301
|
+
__name(loadBootstrapConfigWithProvenance, "loadBootstrapConfigWithProvenance");
|
|
302
|
+
function resolveConfigWithProvenance(opts, mode) {
|
|
303
|
+
const cwd = opts.cwd ?? process.cwd();
|
|
304
|
+
const env = opts.env ?? process.env;
|
|
305
|
+
const userPath = join(
|
|
306
|
+
resolveNamzuHome({ ...opts.home ? { home: opts.home } : {}, env }),
|
|
307
|
+
"config.yaml"
|
|
308
|
+
);
|
|
309
|
+
const projectPath = resolve(cwd, "namzu.config.json");
|
|
310
|
+
const managedPath = opts.managedPath ?? MANAGED_CONFIG_PATH;
|
|
311
|
+
const userCfg = readYamlIfExists(userPath);
|
|
312
|
+
const projectCfg = mode.includeProject ? readJsonIfExists(projectPath, PROJECT_FILE_LABEL) : {};
|
|
313
|
+
const managedCfg = readJsonIfExists(managedPath, shortHomePath(managedPath));
|
|
314
|
+
const { config: envCfg, variables: envVariables } = readEnv(env);
|
|
315
|
+
const profileName = opts.profile ?? env.NAMZU_PROFILE;
|
|
316
|
+
const profiles = profileLayers(
|
|
317
|
+
profileName,
|
|
318
|
+
[
|
|
319
|
+
[userCfg, userPath],
|
|
320
|
+
[projectCfg, projectPath],
|
|
321
|
+
[managedCfg, managedPath]
|
|
322
|
+
],
|
|
323
|
+
mode.deferUnknownProfile
|
|
324
|
+
);
|
|
325
|
+
return mergeConfigs(
|
|
326
|
+
constantLayer(DEFAULT_CONFIG, { kind: "default" }),
|
|
327
|
+
constantLayer(userCfg, { kind: "user-file", path: userPath }),
|
|
328
|
+
constantLayer(projectCfg, { kind: "project-file", path: projectPath }),
|
|
329
|
+
...profiles,
|
|
330
|
+
{
|
|
331
|
+
config: envCfg,
|
|
332
|
+
sourceFor: /* @__PURE__ */ __name((key) => {
|
|
333
|
+
const variable = envVariables[key];
|
|
334
|
+
if (variable === void 0) {
|
|
335
|
+
throw new Error(`no env variable recorded for config key '${key}'`);
|
|
336
|
+
}
|
|
337
|
+
return { kind: "env", variable };
|
|
338
|
+
}, "sourceFor")
|
|
339
|
+
},
|
|
340
|
+
// Last, so it beats the project file and the environment both. That
|
|
341
|
+
// ordering is the whole of what a managed layer is.
|
|
342
|
+
constantLayer(managedCfg, { kind: "managed", path: managedPath })
|
|
343
|
+
);
|
|
344
|
+
}
|
|
345
|
+
__name(resolveConfigWithProvenance, "resolveConfigWithProvenance");
|
|
346
|
+
function readPermissionLayers(opts = {}) {
|
|
347
|
+
const cwd = opts.cwd ?? process.cwd();
|
|
348
|
+
const env = opts.env ?? process.env;
|
|
349
|
+
const userPath = join(
|
|
350
|
+
resolveNamzuHome({ ...opts.home ? { home: opts.home } : {}, env }),
|
|
351
|
+
"config.yaml"
|
|
352
|
+
);
|
|
353
|
+
const projectPath = resolve(cwd, "namzu.config.json");
|
|
354
|
+
const managedPath = opts.managedPath ?? MANAGED_CONFIG_PATH;
|
|
355
|
+
const layers = [];
|
|
356
|
+
for (const [source, path, config] of [
|
|
357
|
+
["user-file", userPath, readYamlIfExists(userPath)],
|
|
358
|
+
[
|
|
359
|
+
"project-file",
|
|
360
|
+
projectPath,
|
|
361
|
+
opts.includeProject === false ? {} : readJsonIfExists(projectPath, PROJECT_FILE_LABEL)
|
|
362
|
+
],
|
|
363
|
+
["managed", managedPath, readJsonIfExists(managedPath, shortHomePath(managedPath))]
|
|
364
|
+
]) {
|
|
365
|
+
const browserDenies = Object.entries(config.browser?.sites ?? {}).filter(([site, level]) => site !== "*" && level === "deny").map(([site]) => site);
|
|
366
|
+
if (config.permissions || browserDenies.length > 0)
|
|
367
|
+
layers.push({
|
|
368
|
+
source,
|
|
369
|
+
path,
|
|
370
|
+
permissions: config.permissions ?? {},
|
|
371
|
+
...browserDenies.length > 0 ? { browserDenies } : {}
|
|
372
|
+
});
|
|
373
|
+
}
|
|
374
|
+
return layers;
|
|
375
|
+
}
|
|
376
|
+
__name(readPermissionLayers, "readPermissionLayers");
|
|
377
|
+
function profileLayers(name, files, deferUnknown = false) {
|
|
378
|
+
if (name === void 0 || name === "") return [];
|
|
379
|
+
const layers = [];
|
|
380
|
+
const declared = /* @__PURE__ */ new Set();
|
|
381
|
+
const declaringFiles = [];
|
|
382
|
+
for (const [config, path] of files) {
|
|
383
|
+
const profiles = config.profiles;
|
|
384
|
+
if (profiles === void 0) continue;
|
|
385
|
+
declaringFiles.push(path);
|
|
386
|
+
for (const key of Object.keys(profiles)) declared.add(key);
|
|
387
|
+
if (!Object.hasOwn(profiles, name)) continue;
|
|
388
|
+
const selected = profiles[name];
|
|
389
|
+
if (selected === void 0) continue;
|
|
390
|
+
layers.push(constantLayer(selected, { kind: "profile", name, path }));
|
|
391
|
+
}
|
|
392
|
+
if (layers.length === 0) {
|
|
393
|
+
if (deferUnknown) return [];
|
|
394
|
+
const known = [...declared].sort();
|
|
395
|
+
const where = declaringFiles[0] ?? files[1]?.[1] ?? "";
|
|
396
|
+
throw new ConfigLoadError(
|
|
397
|
+
where,
|
|
398
|
+
known.length === 0 ? `No profile named "${name}" \u2014 no config file declares any profiles.` : `No profile named "${name}". Declared in ${declaringFiles.join(", ")}: ${known.join(", ")}.`
|
|
399
|
+
);
|
|
400
|
+
}
|
|
401
|
+
return layers;
|
|
402
|
+
}
|
|
403
|
+
__name(profileLayers, "profileLayers");
|
|
404
|
+
function loadConfig(opts = {}) {
|
|
405
|
+
return loadConfigWithProvenance(opts).config;
|
|
406
|
+
}
|
|
407
|
+
__name(loadConfig, "loadConfig");
|
|
408
|
+
var ConfigLoadError = class extends Error {
|
|
409
|
+
static {
|
|
410
|
+
__name(this, "ConfigLoadError");
|
|
411
|
+
}
|
|
412
|
+
/** The file whose contents could not be established. */
|
|
413
|
+
path;
|
|
414
|
+
/** The message already says what to do next, so the caller adds no second line. */
|
|
415
|
+
complete;
|
|
416
|
+
constructor(path, message, options) {
|
|
417
|
+
super(message, options?.cause === void 0 ? void 0 : { cause: options.cause });
|
|
418
|
+
this.name = "ConfigLoadError";
|
|
419
|
+
this.path = path;
|
|
420
|
+
this.complete = options?.complete === true;
|
|
421
|
+
}
|
|
422
|
+
};
|
|
423
|
+
var ConfigValueError = class extends Error {
|
|
424
|
+
static {
|
|
425
|
+
__name(this, "ConfigValueError");
|
|
426
|
+
}
|
|
427
|
+
source;
|
|
428
|
+
/** Dot/bracket path to the invalid known setting, without its source. */
|
|
429
|
+
settingPath;
|
|
430
|
+
constructor(source, settingPath, message) {
|
|
431
|
+
const origin = source.kind === "file" ? `config file ${configMetadataLiteral(source.path)}` : `environment variable ${source.variable}`;
|
|
432
|
+
super(`${origin}: ${settingPath} ${message}`);
|
|
433
|
+
this.name = "ConfigValueError";
|
|
434
|
+
this.source = source;
|
|
435
|
+
this.settingPath = settingPath;
|
|
436
|
+
}
|
|
437
|
+
};
|
|
438
|
+
function readYamlIfExists(path) {
|
|
439
|
+
const raw = readIfPresent(path);
|
|
440
|
+
if (raw === null) return {};
|
|
441
|
+
let parsed;
|
|
442
|
+
try {
|
|
443
|
+
parsed = (0, import_yaml.parse)(raw);
|
|
444
|
+
} catch (cause) {
|
|
445
|
+
const at = cause?.linePos?.[0];
|
|
446
|
+
const where = at === void 0 ? "" : ` (line ${at.line}, column ${at.col})`;
|
|
447
|
+
throw new ConfigLoadError(
|
|
448
|
+
path,
|
|
449
|
+
`${shortHomePath(path)} isn't valid YAML${where}. Fix it, then start Namzu again.`,
|
|
450
|
+
{ cause, complete: true }
|
|
451
|
+
);
|
|
452
|
+
}
|
|
453
|
+
return asConfigObject(path, parsed);
|
|
454
|
+
}
|
|
455
|
+
__name(readYamlIfExists, "readYamlIfExists");
|
|
456
|
+
var PROJECT_FILE_LABEL = "namzu.config.json in this project";
|
|
457
|
+
function shortHomePath(path) {
|
|
458
|
+
return homePath(path);
|
|
459
|
+
}
|
|
460
|
+
__name(shortHomePath, "shortHomePath");
|
|
461
|
+
function readJsonIfExists(path, label) {
|
|
462
|
+
const raw = readIfPresent(path);
|
|
463
|
+
if (raw === null) return {};
|
|
464
|
+
let parsed;
|
|
465
|
+
try {
|
|
466
|
+
parsed = JSON.parse(raw);
|
|
467
|
+
} catch (cause) {
|
|
468
|
+
throw new ConfigLoadError(path, invalidJsonSentence(label, raw, cause), {
|
|
469
|
+
cause,
|
|
470
|
+
complete: true
|
|
471
|
+
});
|
|
472
|
+
}
|
|
473
|
+
return asConfigObject(path, parsed, label);
|
|
474
|
+
}
|
|
475
|
+
__name(readJsonIfExists, "readJsonIfExists");
|
|
476
|
+
function invalidJsonSentence(name, raw, cause) {
|
|
477
|
+
const position = jsonErrorPosition(raw, cause);
|
|
478
|
+
let where = "";
|
|
479
|
+
if (position !== void 0) {
|
|
480
|
+
const before = raw.slice(0, position);
|
|
481
|
+
const line = before.split("\n").length;
|
|
482
|
+
const column = position - (before.lastIndexOf("\n") + 1) + 1;
|
|
483
|
+
where = ` (line ${line}, column ${column})`;
|
|
484
|
+
}
|
|
485
|
+
return `${name} isn't valid JSON${where}. Fix it, then start Namzu again.`;
|
|
486
|
+
}
|
|
487
|
+
__name(invalidJsonSentence, "invalidJsonSentence");
|
|
488
|
+
function jsonErrorPosition(raw, cause) {
|
|
489
|
+
const text = cause instanceof Error ? cause.message : String(cause);
|
|
490
|
+
const at = /position (\d+)/.exec(text);
|
|
491
|
+
if (at) return Math.min(Number(at[1]), raw.length);
|
|
492
|
+
if (/end of JSON input/i.test(text)) return raw.length;
|
|
493
|
+
return void 0;
|
|
494
|
+
}
|
|
495
|
+
__name(jsonErrorPosition, "jsonErrorPosition");
|
|
496
|
+
function readIfPresent(path) {
|
|
497
|
+
try {
|
|
498
|
+
return stripByteOrderMark(readFileSync(path, "utf8"));
|
|
499
|
+
} catch (cause) {
|
|
500
|
+
const code = cause?.code;
|
|
501
|
+
if (code === "ENOENT" || code === "ENOTDIR") return null;
|
|
502
|
+
throw new ConfigLoadError(path, `${path} could not be read: ${reasonOf(cause)}`, { cause });
|
|
503
|
+
}
|
|
504
|
+
}
|
|
505
|
+
__name(readIfPresent, "readIfPresent");
|
|
506
|
+
function asConfigObject(path, parsed, label = shortHomePath(path)) {
|
|
507
|
+
if (parsed === null || parsed === void 0) return {};
|
|
508
|
+
if (typeof parsed !== "object" || Array.isArray(parsed)) {
|
|
509
|
+
throw new ConfigLoadError(
|
|
510
|
+
path,
|
|
511
|
+
`${label} must be a set of named settings, not ${describe(parsed)}. Fix it, then start Namzu again.`,
|
|
512
|
+
{ complete: true }
|
|
513
|
+
);
|
|
514
|
+
}
|
|
515
|
+
return sanitize(parsed, { kind: "file", path });
|
|
516
|
+
}
|
|
517
|
+
__name(asConfigObject, "asConfigObject");
|
|
518
|
+
function describe(value) {
|
|
519
|
+
return Array.isArray(value) ? "a list" : `a ${typeof value}`;
|
|
520
|
+
}
|
|
521
|
+
__name(describe, "describe");
|
|
522
|
+
function stripByteOrderMark(text) {
|
|
523
|
+
return text.charCodeAt(0) === 65279 ? text.slice(1) : text;
|
|
524
|
+
}
|
|
525
|
+
__name(stripByteOrderMark, "stripByteOrderMark");
|
|
526
|
+
function reasonOf(cause) {
|
|
527
|
+
return cause instanceof Error ? cause.message : String(cause);
|
|
528
|
+
}
|
|
529
|
+
__name(reasonOf, "reasonOf");
|
|
530
|
+
var COMPOSER_TRIGGERS_KEYS = ["enabled", "suggest", "languages", "builtin"];
|
|
531
|
+
var SKILLS_CONFIG_KEYS = [
|
|
532
|
+
"builtin",
|
|
533
|
+
"disabled",
|
|
534
|
+
"suggest",
|
|
535
|
+
"suggestMinToolCalls"
|
|
536
|
+
];
|
|
537
|
+
var CONFIG_READERS = {
|
|
538
|
+
format: /* @__PURE__ */ __name((v, context) => {
|
|
539
|
+
if (typeof v === "string" && isFormatName(v)) return v;
|
|
540
|
+
return invalidConfigValue(context, [], 'must be one of "text", "json", or "yaml"');
|
|
541
|
+
}, "format"),
|
|
542
|
+
quiet: /* @__PURE__ */ __name((v, context) => {
|
|
543
|
+
if (typeof v === "boolean") return v;
|
|
544
|
+
return invalidConfigValue(context, [], "must be a boolean");
|
|
545
|
+
}, "quiet"),
|
|
546
|
+
modelCatalogueRefresh: /* @__PURE__ */ __name((v, context) => {
|
|
547
|
+
if (typeof v === "boolean") return v;
|
|
548
|
+
return invalidConfigValue(context, [], "must be a boolean");
|
|
549
|
+
}, "modelCatalogueRefresh"),
|
|
550
|
+
// Shape only. Per-entry validation belongs to `compilePermissions`, which
|
|
551
|
+
// reports a bad effect or an unusable pattern as a diagnostic the user
|
|
552
|
+
// sees; dropping those entries here would silence it.
|
|
553
|
+
permissions: /* @__PURE__ */ __name((v, context) => {
|
|
554
|
+
if (isConfigMapping(v)) return v;
|
|
555
|
+
return invalidConfigValue(context, [], "must be a mapping of tool names");
|
|
556
|
+
}, "permissions"),
|
|
557
|
+
// Shape only, like `permissions` and for the same reason: per-entry
|
|
558
|
+
// validation belongs to `verifyPermissionChecks`, which reports a bad
|
|
559
|
+
// check by index. Dropping a malformed one here would turn "your check is
|
|
560
|
+
// unreadable" into "your check passed".
|
|
561
|
+
permissionChecks: /* @__PURE__ */ __name((v, context) => {
|
|
562
|
+
if (Array.isArray(v)) return v;
|
|
563
|
+
return invalidConfigValue(context, [], "must be a list");
|
|
564
|
+
}, "permissionChecks"),
|
|
565
|
+
// Every declared profile is checked when its file loads, not only when it is
|
|
566
|
+
// selected. Typed config in a lower-precedence layer cannot become valid
|
|
567
|
+
// merely because another layer happens to win today. Unknown profile keys
|
|
568
|
+
// remain non-strict and are ignored by `sanitize`, like unknown base keys.
|
|
569
|
+
profiles: /* @__PURE__ */ __name((v, context) => {
|
|
570
|
+
if (!isConfigMapping(v)) {
|
|
571
|
+
return invalidConfigValue(context, [], "must be a mapping of profile names");
|
|
572
|
+
}
|
|
573
|
+
const profiles = {};
|
|
574
|
+
for (const name of Object.keys(v)) {
|
|
575
|
+
const entry = v[name];
|
|
576
|
+
if (!isConfigMapping(entry)) {
|
|
577
|
+
return invalidConfigValue(context, [name], "must be a mapping of settings");
|
|
578
|
+
}
|
|
579
|
+
const parsed = sanitize(entry, context.source, [...context.path, name], false);
|
|
580
|
+
Object.defineProperty(profiles, name, {
|
|
581
|
+
value: parsed,
|
|
582
|
+
enumerable: true,
|
|
583
|
+
configurable: true,
|
|
584
|
+
writable: true
|
|
585
|
+
});
|
|
586
|
+
}
|
|
587
|
+
return profiles;
|
|
588
|
+
}, "profiles"),
|
|
589
|
+
// Shape only, for the same reason as `permissions`: an entry that names
|
|
590
|
+
// neither a command nor a url — or both — is reported by name when the
|
|
591
|
+
// connection is attempted. Dropping it here would turn a mistake the
|
|
592
|
+
// operator can see into a server that silently was never there.
|
|
593
|
+
mcpServers: /* @__PURE__ */ __name((v, context) => {
|
|
594
|
+
if (isConfigMapping(v)) return v;
|
|
595
|
+
return invalidConfigValue(context, [], "must be a mapping of server names");
|
|
596
|
+
}, "mcpServers"),
|
|
597
|
+
memory: /* @__PURE__ */ __name((v, context) => {
|
|
598
|
+
if (!isConfigMapping(v)) return invalidConfigValue(context, [], "must be a mapping");
|
|
599
|
+
for (const key of Object.keys(v)) {
|
|
600
|
+
if (key !== "recall" && key !== "identifierGrounding")
|
|
601
|
+
return invalidConfigValue(context, [key], "is not a memory key");
|
|
602
|
+
}
|
|
603
|
+
if (v.recall !== void 0 && typeof v.recall !== "boolean") {
|
|
604
|
+
return invalidConfigValue(context, ["recall"], "must be true or false");
|
|
605
|
+
}
|
|
606
|
+
if (v.identifierGrounding !== void 0 && typeof v.identifierGrounding !== "boolean") {
|
|
607
|
+
return invalidConfigValue(context, ["identifierGrounding"], "must be true or false");
|
|
608
|
+
}
|
|
609
|
+
return {
|
|
610
|
+
...v.recall === void 0 ? {} : { recall: v.recall },
|
|
611
|
+
...v.identifierGrounding === void 0 ? {} : { identifierGrounding: v.identifierGrounding }
|
|
612
|
+
};
|
|
613
|
+
}, "memory"),
|
|
614
|
+
compaction: /* @__PURE__ */ __name((v, context) => {
|
|
615
|
+
if (!isConfigMapping(v)) return invalidConfigValue(context, [], "must be a mapping");
|
|
616
|
+
const raw = v;
|
|
617
|
+
for (const key of Object.keys(v)) {
|
|
618
|
+
if (key !== "strategy" && key !== "contextWindowTokens" && key !== "consolidate" && key !== "recallEvidence" && key !== "resolveEvidenceQueries" && key !== "retainedToolPreviewChars" && key !== "deduplicateObservations") {
|
|
619
|
+
return invalidConfigValue(context, [key], "is not a compaction key");
|
|
620
|
+
}
|
|
621
|
+
}
|
|
622
|
+
if (raw.deduplicateObservations !== void 0 && typeof raw.deduplicateObservations !== "boolean") {
|
|
623
|
+
return invalidConfigValue(context, ["deduplicateObservations"], "must be true or false");
|
|
624
|
+
}
|
|
625
|
+
if (raw.recallEvidence !== void 0 && typeof raw.recallEvidence !== "boolean")
|
|
626
|
+
return invalidConfigValue(context, ["recallEvidence"], "must be true or false");
|
|
627
|
+
if (raw.resolveEvidenceQueries !== void 0 && typeof raw.resolveEvidenceQueries !== "boolean")
|
|
628
|
+
return invalidConfigValue(context, ["resolveEvidenceQueries"], "must be true or false");
|
|
629
|
+
if (raw.consolidate !== void 0 && typeof raw.consolidate !== "boolean") {
|
|
630
|
+
return invalidConfigValue(context, ["consolidate"], "must be true or false");
|
|
631
|
+
}
|
|
632
|
+
if (raw.retainedToolPreviewChars !== void 0 && (typeof raw.retainedToolPreviewChars !== "number" || !Number.isSafeInteger(raw.retainedToolPreviewChars) || raw.retainedToolPreviewChars < 0)) {
|
|
633
|
+
return invalidConfigValue(
|
|
634
|
+
context,
|
|
635
|
+
["retainedToolPreviewChars"],
|
|
636
|
+
"must be a nonnegative safe integer"
|
|
637
|
+
);
|
|
638
|
+
}
|
|
639
|
+
if (raw.strategy !== void 0 && raw.strategy !== "structured" && raw.strategy !== "salience") {
|
|
640
|
+
return invalidConfigValue(context, ["strategy"], "must be `structured` or `salience`");
|
|
641
|
+
}
|
|
642
|
+
if (raw.contextWindowTokens !== void 0 && (typeof raw.contextWindowTokens !== "number" || !Number.isInteger(raw.contextWindowTokens) || raw.contextWindowTokens <= 0)) {
|
|
643
|
+
return invalidConfigValue(context, ["contextWindowTokens"], "must be a positive integer");
|
|
644
|
+
}
|
|
645
|
+
return {
|
|
646
|
+
...raw.strategy !== void 0 ? { strategy: raw.strategy } : {},
|
|
647
|
+
...raw.contextWindowTokens !== void 0 ? { contextWindowTokens: raw.contextWindowTokens } : {},
|
|
648
|
+
...raw.consolidate !== void 0 ? { consolidate: raw.consolidate } : {},
|
|
649
|
+
...raw.recallEvidence !== void 0 ? { recallEvidence: raw.recallEvidence } : {},
|
|
650
|
+
...raw.resolveEvidenceQueries !== void 0 ? { resolveEvidenceQueries: raw.resolveEvidenceQueries } : {},
|
|
651
|
+
...raw.retainedToolPreviewChars !== void 0 ? { retainedToolPreviewChars: raw.retainedToolPreviewChars } : {},
|
|
652
|
+
...raw.deduplicateObservations !== void 0 ? { deduplicateObservations: raw.deduplicateObservations } : {}
|
|
653
|
+
};
|
|
654
|
+
}, "compaction"),
|
|
655
|
+
additionalDirectories: /* @__PURE__ */ __name((v, context) => {
|
|
656
|
+
if (!Array.isArray(v)) return invalidConfigValue(context, [], "must be a list of directories");
|
|
657
|
+
for (const [index, entry] of v.entries()) {
|
|
658
|
+
if (typeof entry !== "string" || entry.trim().length === 0) {
|
|
659
|
+
return invalidConfigValue(context, [index], "must be a directory path");
|
|
660
|
+
}
|
|
661
|
+
}
|
|
662
|
+
return v;
|
|
663
|
+
}, "additionalDirectories"),
|
|
664
|
+
toolResultScreens: /* @__PURE__ */ __name((v, context) => {
|
|
665
|
+
if (!Array.isArray(v)) {
|
|
666
|
+
return invalidConfigValue(context, [], "must be a list of screen names");
|
|
667
|
+
}
|
|
668
|
+
const names = TOOL_RESULT_SCREEN_NAMES.join(", ");
|
|
669
|
+
for (const [index, entry] of v.entries()) {
|
|
670
|
+
if (typeof entry === "string") {
|
|
671
|
+
if (!isToolResultScreenName(entry)) {
|
|
672
|
+
return invalidConfigValue(context, [index], `must be one of: ${names}`);
|
|
673
|
+
}
|
|
674
|
+
continue;
|
|
675
|
+
}
|
|
676
|
+
if (!isConfigMapping(entry)) {
|
|
677
|
+
return invalidConfigValue(
|
|
678
|
+
context,
|
|
679
|
+
[index],
|
|
680
|
+
"must be a screen name, or a mapping with a `name`"
|
|
681
|
+
);
|
|
682
|
+
}
|
|
683
|
+
const { name, ...options } = entry;
|
|
684
|
+
if (typeof name !== "string" || !isToolResultScreenName(name)) {
|
|
685
|
+
return invalidConfigValue(context, [index, "name"], `must be one of: ${names}`);
|
|
686
|
+
}
|
|
687
|
+
for (const key of Object.keys(options)) {
|
|
688
|
+
if (!TOOL_RESULT_SCREEN_OPTION_KEYS[name].includes(key)) {
|
|
689
|
+
return invalidConfigValue(
|
|
690
|
+
context,
|
|
691
|
+
[index, key],
|
|
692
|
+
`is not an option of the "${name}" screen`
|
|
693
|
+
);
|
|
694
|
+
}
|
|
695
|
+
}
|
|
696
|
+
const passthroughTools = entry.passthroughTools;
|
|
697
|
+
if (passthroughTools === void 0) continue;
|
|
698
|
+
if (!Array.isArray(passthroughTools)) {
|
|
699
|
+
return invalidConfigValue(
|
|
700
|
+
context,
|
|
701
|
+
[index, "passthroughTools"],
|
|
702
|
+
"must be a list of tool names"
|
|
703
|
+
);
|
|
704
|
+
}
|
|
705
|
+
for (const [position, toolName] of passthroughTools.entries()) {
|
|
706
|
+
if (typeof toolName !== "string" || toolName.trim().length === 0) {
|
|
707
|
+
return invalidConfigValue(
|
|
708
|
+
context,
|
|
709
|
+
[index, "passthroughTools", position],
|
|
710
|
+
"must be a tool name"
|
|
711
|
+
);
|
|
712
|
+
}
|
|
713
|
+
}
|
|
714
|
+
}
|
|
715
|
+
return v;
|
|
716
|
+
}, "toolResultScreens"),
|
|
717
|
+
hooks: /* @__PURE__ */ __name((v, context) => {
|
|
718
|
+
if (!isConfigMapping(v))
|
|
719
|
+
return invalidConfigValue(context, [], "must be a mapping of event \u2192 list");
|
|
720
|
+
const events = new Set(SHELL_HOOK_EVENTS);
|
|
721
|
+
const out = {};
|
|
722
|
+
for (const [event, entries] of Object.entries(v)) {
|
|
723
|
+
const renamed = Object.hasOwn(RENAMED_PLUGIN_HOOK_EVENTS, event) ? RENAMED_PLUGIN_HOOK_EVENTS[event] : void 0;
|
|
724
|
+
if (renamed !== void 0) {
|
|
725
|
+
return invalidConfigValue(context, [event], `was renamed; name it \`${renamed}\``);
|
|
726
|
+
}
|
|
727
|
+
if (!events.has(event)) {
|
|
728
|
+
return invalidConfigValue(
|
|
729
|
+
context,
|
|
730
|
+
[event],
|
|
731
|
+
`is not a hook event (${SHELL_HOOK_EVENTS.join(", ")})`
|
|
732
|
+
);
|
|
733
|
+
}
|
|
734
|
+
if (!Array.isArray(entries))
|
|
735
|
+
return invalidConfigValue(context, [event], "must be a list of hooks");
|
|
736
|
+
const parsed = [];
|
|
737
|
+
for (const [index, entry] of entries.entries()) {
|
|
738
|
+
if (!isConfigMapping(entry)) {
|
|
739
|
+
return invalidConfigValue(context, [event, index], "must be a mapping with a `command`");
|
|
740
|
+
}
|
|
741
|
+
const raw = entry;
|
|
742
|
+
for (const key of Object.keys(entry)) {
|
|
743
|
+
if (key !== "command" && key !== "matcher" && key !== "timeoutMs") {
|
|
744
|
+
return invalidConfigValue(
|
|
745
|
+
context,
|
|
746
|
+
[event, index, key],
|
|
747
|
+
"is not a recognized hook setting"
|
|
748
|
+
);
|
|
749
|
+
}
|
|
750
|
+
}
|
|
751
|
+
if (typeof raw.command !== "string" || raw.command.trim().length === 0) {
|
|
752
|
+
return invalidConfigValue(
|
|
753
|
+
context,
|
|
754
|
+
[event, index, "command"],
|
|
755
|
+
"must be a non-empty string"
|
|
756
|
+
);
|
|
757
|
+
}
|
|
758
|
+
if (raw.matcher !== void 0 && typeof raw.matcher !== "string") {
|
|
759
|
+
return invalidConfigValue(context, [event, index, "matcher"], "must be a string");
|
|
760
|
+
}
|
|
761
|
+
if (raw.timeoutMs !== void 0 && (typeof raw.timeoutMs !== "number" || !Number.isInteger(raw.timeoutMs) || raw.timeoutMs <= 0)) {
|
|
762
|
+
return invalidConfigValue(
|
|
763
|
+
context,
|
|
764
|
+
[event, index, "timeoutMs"],
|
|
765
|
+
"must be a positive integer"
|
|
766
|
+
);
|
|
767
|
+
}
|
|
768
|
+
parsed.push({
|
|
769
|
+
command: raw.command,
|
|
770
|
+
...raw.matcher !== void 0 ? { matcher: raw.matcher } : {},
|
|
771
|
+
...raw.timeoutMs !== void 0 ? { timeoutMs: raw.timeoutMs } : {}
|
|
772
|
+
});
|
|
773
|
+
}
|
|
774
|
+
out[event] = parsed;
|
|
775
|
+
}
|
|
776
|
+
return out;
|
|
777
|
+
}, "hooks"),
|
|
778
|
+
browser: /* @__PURE__ */ __name((v, context) => readBrowserConfig(v, context), "browser"),
|
|
779
|
+
web: /* @__PURE__ */ __name((v, context) => {
|
|
780
|
+
if (!isConfigMapping(v)) return invalidConfigValue(context, [], "must be a mapping");
|
|
781
|
+
for (const key of Object.keys(v)) {
|
|
782
|
+
if (key !== "fetch" && key !== "search" && key !== "backend")
|
|
783
|
+
return invalidConfigValue(context, [key], "is not a recognized web setting");
|
|
784
|
+
}
|
|
785
|
+
const raw = v;
|
|
786
|
+
if (raw.backend !== void 0 && raw.backend !== "auto" && raw.backend !== "exa" && raw.backend !== "native")
|
|
787
|
+
return invalidConfigValue(context, ["backend"], "must be auto, exa or native");
|
|
788
|
+
if (raw.search === "cached" && raw.backend === "exa")
|
|
789
|
+
return invalidConfigValue(context, ["backend"], "cached search requires native");
|
|
790
|
+
if (raw.search !== void 0 && (typeof raw.search !== "string" || !["off", "cached", "live"].includes(raw.search))) {
|
|
791
|
+
return invalidConfigValue(context, ["search"], "must be off, cached, or live");
|
|
792
|
+
}
|
|
793
|
+
if (raw.fetch !== void 0 && typeof raw.fetch !== "boolean") {
|
|
794
|
+
return invalidConfigValue(context, ["fetch"], "must be a boolean");
|
|
795
|
+
}
|
|
796
|
+
return raw;
|
|
797
|
+
}, "web"),
|
|
798
|
+
limits: /* @__PURE__ */ __name((v, context) => {
|
|
799
|
+
if (!isConfigMapping(v)) return invalidConfigValue(context, [], "must be a mapping");
|
|
800
|
+
for (const key of Object.keys(v)) {
|
|
801
|
+
if (!["maxIterations", "tokenBudget", "timeoutMs", "waitForProviderMs"].includes(key))
|
|
802
|
+
return invalidConfigValue(
|
|
803
|
+
context,
|
|
804
|
+
[key],
|
|
805
|
+
"is not a limit (maxIterations, tokenBudget, timeoutMs, waitForProviderMs)"
|
|
806
|
+
);
|
|
807
|
+
const value = v[key];
|
|
808
|
+
const minimum = key === "waitForProviderMs" ? 1 : 0;
|
|
809
|
+
if (typeof value !== "number" || !Number.isSafeInteger(value) || value < minimum)
|
|
810
|
+
return invalidConfigValue(context, [key], `must be a safe whole number at least ${minimum}`);
|
|
811
|
+
if (key === "timeoutMs" && value > 2147483647)
|
|
812
|
+
return invalidConfigValue(
|
|
813
|
+
context,
|
|
814
|
+
[key],
|
|
815
|
+
"must be at most 2147483647 milliseconds; use 0 for unlimited"
|
|
816
|
+
);
|
|
817
|
+
}
|
|
818
|
+
return v;
|
|
819
|
+
}, "limits"),
|
|
820
|
+
plugins: /* @__PURE__ */ __name((v, context) => {
|
|
821
|
+
if (!isConfigMapping(v)) return invalidConfigValue(context, [], "must be a mapping");
|
|
822
|
+
const known = /* @__PURE__ */ new Set(["enabled", "autoDiscovery", "allowedScopes", "hookTimeoutMs"]);
|
|
823
|
+
for (const key of Object.keys(v)) {
|
|
824
|
+
if (!known.has(key)) {
|
|
825
|
+
return invalidConfigValue(context, [key], "is not a recognized plugin setting");
|
|
826
|
+
}
|
|
827
|
+
}
|
|
828
|
+
const raw = v;
|
|
829
|
+
if (raw.enabled !== void 0 && typeof raw.enabled !== "boolean") {
|
|
830
|
+
return invalidConfigValue(context, ["enabled"], "must be a boolean");
|
|
831
|
+
}
|
|
832
|
+
if (raw.autoDiscovery !== void 0 && typeof raw.autoDiscovery !== "boolean") {
|
|
833
|
+
return invalidConfigValue(context, ["autoDiscovery"], "must be a boolean");
|
|
834
|
+
}
|
|
835
|
+
let allowedScopes;
|
|
836
|
+
if (raw.allowedScopes !== void 0) {
|
|
837
|
+
if (!Array.isArray(raw.allowedScopes)) {
|
|
838
|
+
return invalidConfigValue(context, ["allowedScopes"], "must be a list");
|
|
839
|
+
}
|
|
840
|
+
const invalidIndex = raw.allowedScopes.findIndex(
|
|
841
|
+
(scope) => scope !== "project" && scope !== "user"
|
|
842
|
+
);
|
|
843
|
+
if (invalidIndex >= 0) {
|
|
844
|
+
return invalidConfigValue(
|
|
845
|
+
context,
|
|
846
|
+
["allowedScopes", invalidIndex],
|
|
847
|
+
'must be one of "project" or "user"'
|
|
848
|
+
);
|
|
849
|
+
}
|
|
850
|
+
if (new Set(raw.allowedScopes).size !== raw.allowedScopes.length) {
|
|
851
|
+
return invalidConfigValue(context, ["allowedScopes"], "must not contain duplicates");
|
|
852
|
+
}
|
|
853
|
+
allowedScopes = raw.allowedScopes;
|
|
854
|
+
}
|
|
855
|
+
if (raw.hookTimeoutMs !== void 0 && (!Number.isInteger(raw.hookTimeoutMs) || raw.hookTimeoutMs <= 0 || raw.hookTimeoutMs > 2147483647)) {
|
|
856
|
+
return invalidConfigValue(
|
|
857
|
+
context,
|
|
858
|
+
["hookTimeoutMs"],
|
|
859
|
+
"must be an integer from 1 to 2147483647"
|
|
860
|
+
);
|
|
861
|
+
}
|
|
862
|
+
return {
|
|
863
|
+
...raw.enabled !== void 0 ? { enabled: raw.enabled } : {},
|
|
864
|
+
...raw.autoDiscovery !== void 0 ? { autoDiscovery: raw.autoDiscovery } : {},
|
|
865
|
+
...allowedScopes !== void 0 ? { allowedScopes } : {},
|
|
866
|
+
...raw.hookTimeoutMs !== void 0 ? { hookTimeoutMs: raw.hookTimeoutMs } : {}
|
|
867
|
+
};
|
|
868
|
+
}, "plugins"),
|
|
869
|
+
// Read field by field rather than shape-only, unlike the two above.
|
|
870
|
+
// Those hand their entries to a compiler that reports a bad one by name;
|
|
871
|
+
// this one is consumed directly, and a misspelled `require_isolation` or
|
|
872
|
+
// a string where a list belongs would otherwise become "no requirement"
|
|
873
|
+
// — a security control silently downgraded by a typo, which is the
|
|
874
|
+
// failure this whole change exists to remove.
|
|
875
|
+
sandbox: /* @__PURE__ */ __name((v, context) => {
|
|
876
|
+
if (!isConfigMapping(v)) return invalidConfigValue(context, [], "must be a mapping");
|
|
877
|
+
const raw = v;
|
|
878
|
+
for (const key of ["enabled", "allowEscape", "allowUnattendedEscape"]) {
|
|
879
|
+
if (raw[key] !== void 0 && typeof raw[key] !== "boolean") {
|
|
880
|
+
return invalidConfigValue(context, [key], "must be a boolean");
|
|
881
|
+
}
|
|
882
|
+
}
|
|
883
|
+
if (raw.requireIsolation !== void 0 && !Array.isArray(raw.requireIsolation)) {
|
|
884
|
+
return invalidConfigValue(context, ["requireIsolation"], "must be a list");
|
|
885
|
+
}
|
|
886
|
+
const requireIsolation = raw.requireIsolation;
|
|
887
|
+
const invalidIndex = requireIsolation?.findIndex(
|
|
888
|
+
(value) => value !== "filesystem" && value !== "network" && value !== "process"
|
|
889
|
+
);
|
|
890
|
+
if (invalidIndex !== void 0 && invalidIndex >= 0) {
|
|
891
|
+
return invalidConfigValue(
|
|
892
|
+
context,
|
|
893
|
+
["requireIsolation", invalidIndex],
|
|
894
|
+
'must be one of "filesystem", "network", or "process"'
|
|
895
|
+
);
|
|
896
|
+
}
|
|
897
|
+
if (raw.workspace !== void 0 && raw.workspace !== "working-directory" && raw.workspace !== "ephemeral") {
|
|
898
|
+
return invalidConfigValue(
|
|
899
|
+
context,
|
|
900
|
+
["workspace"],
|
|
901
|
+
'must be one of "working-directory" or "ephemeral"'
|
|
902
|
+
);
|
|
903
|
+
}
|
|
904
|
+
if (raw.teardownTimeoutMs !== void 0 && (!Number.isInteger(raw.teardownTimeoutMs) || raw.teardownTimeoutMs < 0 || raw.teardownTimeoutMs > 2147483647)) {
|
|
905
|
+
return invalidConfigValue(
|
|
906
|
+
context,
|
|
907
|
+
["teardownTimeoutMs"],
|
|
908
|
+
"must be an integer from 0 to 2147483647"
|
|
909
|
+
);
|
|
910
|
+
}
|
|
911
|
+
return {
|
|
912
|
+
...raw.enabled !== void 0 ? { enabled: raw.enabled } : {},
|
|
913
|
+
...raw.allowEscape !== void 0 ? { allowEscape: raw.allowEscape } : {},
|
|
914
|
+
...raw.allowUnattendedEscape !== void 0 ? { allowUnattendedEscape: raw.allowUnattendedEscape } : {},
|
|
915
|
+
...requireIsolation !== void 0 ? {
|
|
916
|
+
requireIsolation
|
|
917
|
+
} : {},
|
|
918
|
+
...raw.workspace !== void 0 ? { workspace: raw.workspace } : {},
|
|
919
|
+
...raw.teardownTimeoutMs !== void 0 ? { teardownTimeoutMs: raw.teardownTimeoutMs } : {}
|
|
920
|
+
};
|
|
921
|
+
}, "sandbox"),
|
|
922
|
+
// Field by field, for the same reason as `sandbox` and one stronger:
|
|
923
|
+
// this one decides whether conversation content leaves the machine. A
|
|
924
|
+
// misspelled `redacters` read shape-only could change the export's security
|
|
925
|
+
// posture while it still ran. A malformed known field therefore refuses the
|
|
926
|
+
// config rather than selecting either "off" or a different redactor set.
|
|
927
|
+
telemetry: /* @__PURE__ */ __name((v, context) => {
|
|
928
|
+
if (!isConfigMapping(v)) return invalidConfigValue(context, [], "must be a mapping");
|
|
929
|
+
const raw = v;
|
|
930
|
+
if (raw.sessionExport === void 0) return {};
|
|
931
|
+
const se = raw.sessionExport;
|
|
932
|
+
if (!isConfigMapping(se)) {
|
|
933
|
+
return invalidConfigValue(context, ["sessionExport"], "must be a mapping");
|
|
934
|
+
}
|
|
935
|
+
const entry = se;
|
|
936
|
+
if (typeof entry.destination !== "string" || entry.destination.length === 0) {
|
|
937
|
+
return invalidConfigValue(
|
|
938
|
+
context,
|
|
939
|
+
["sessionExport", "destination"],
|
|
940
|
+
"must be a non-empty string"
|
|
941
|
+
);
|
|
942
|
+
}
|
|
943
|
+
let eventTypes;
|
|
944
|
+
if (entry.eventTypes !== void 0) {
|
|
945
|
+
if (!Array.isArray(entry.eventTypes)) {
|
|
946
|
+
return invalidConfigValue(context, ["sessionExport", "eventTypes"], "must be a list");
|
|
947
|
+
}
|
|
948
|
+
const invalidIndex = entry.eventTypes.findIndex((event) => typeof event !== "string");
|
|
949
|
+
if (invalidIndex >= 0) {
|
|
950
|
+
return invalidConfigValue(
|
|
951
|
+
context,
|
|
952
|
+
["sessionExport", "eventTypes", invalidIndex],
|
|
953
|
+
"must be a string"
|
|
954
|
+
);
|
|
955
|
+
}
|
|
956
|
+
eventTypes = entry.eventTypes;
|
|
957
|
+
}
|
|
958
|
+
let redactors;
|
|
959
|
+
if (entry.redactors !== void 0) {
|
|
960
|
+
if (!Array.isArray(entry.redactors)) {
|
|
961
|
+
return invalidConfigValue(context, ["sessionExport", "redactors"], "must be a list");
|
|
962
|
+
}
|
|
963
|
+
const invalidIndex = entry.redactors.findIndex((redactor) => redactor !== "secrets");
|
|
964
|
+
if (invalidIndex >= 0) {
|
|
965
|
+
return invalidConfigValue(
|
|
966
|
+
context,
|
|
967
|
+
["sessionExport", "redactors", invalidIndex],
|
|
968
|
+
'must be "secrets"'
|
|
969
|
+
);
|
|
970
|
+
}
|
|
971
|
+
redactors = entry.redactors;
|
|
972
|
+
}
|
|
973
|
+
return {
|
|
974
|
+
sessionExport: {
|
|
975
|
+
destination: entry.destination,
|
|
976
|
+
...eventTypes !== void 0 ? { eventTypes } : {},
|
|
977
|
+
...redactors !== void 0 ? { redactors } : {}
|
|
978
|
+
}
|
|
979
|
+
};
|
|
980
|
+
}, "telemetry"),
|
|
981
|
+
// TUI notifications are terminal escape writes only. Invalid nested values
|
|
982
|
+
// refuse rather than silently selecting a different event/protocol or
|
|
983
|
+
// disabling the feature the operator explicitly configured.
|
|
984
|
+
skills: /* @__PURE__ */ __name((v, context) => {
|
|
985
|
+
if (!isConfigMapping(v)) return invalidConfigValue(context, [], "must be a mapping");
|
|
986
|
+
for (const key of Object.keys(v)) {
|
|
987
|
+
if (!SKILLS_CONFIG_KEYS.includes(key)) {
|
|
988
|
+
return invalidConfigValue(
|
|
989
|
+
context,
|
|
990
|
+
[key],
|
|
991
|
+
`is not a skills setting (${SKILLS_CONFIG_KEYS.join(", ")})`
|
|
992
|
+
);
|
|
993
|
+
}
|
|
994
|
+
}
|
|
995
|
+
const raw = v;
|
|
996
|
+
if (raw.builtin !== void 0 && typeof raw.builtin !== "boolean") {
|
|
997
|
+
return invalidConfigValue(context, ["builtin"], "must be true or false");
|
|
998
|
+
}
|
|
999
|
+
if (raw.suggest !== void 0 && typeof raw.suggest !== "boolean") {
|
|
1000
|
+
return invalidConfigValue(context, ["suggest"], "must be true or false");
|
|
1001
|
+
}
|
|
1002
|
+
if (raw.suggestMinToolCalls !== void 0 && (typeof raw.suggestMinToolCalls !== "number" || !Number.isInteger(raw.suggestMinToolCalls) || raw.suggestMinToolCalls < 1)) {
|
|
1003
|
+
return invalidConfigValue(
|
|
1004
|
+
context,
|
|
1005
|
+
["suggestMinToolCalls"],
|
|
1006
|
+
"must be a whole number of at least 1"
|
|
1007
|
+
);
|
|
1008
|
+
}
|
|
1009
|
+
if (raw.disabled !== void 0 && (!Array.isArray(raw.disabled) || raw.disabled.some((name) => typeof name !== "string" || name.trim() === ""))) {
|
|
1010
|
+
return invalidConfigValue(context, ["disabled"], "must be a list of skill names");
|
|
1011
|
+
}
|
|
1012
|
+
return {
|
|
1013
|
+
...raw.builtin !== void 0 ? { builtin: raw.builtin } : {},
|
|
1014
|
+
...raw.disabled !== void 0 ? { disabled: raw.disabled.map((name) => name.trim()) } : {},
|
|
1015
|
+
...raw.suggest !== void 0 ? { suggest: raw.suggest } : {},
|
|
1016
|
+
...raw.suggestMinToolCalls !== void 0 ? { suggestMinToolCalls: raw.suggestMinToolCalls } : {}
|
|
1017
|
+
};
|
|
1018
|
+
}, "skills"),
|
|
1019
|
+
schedule: /* @__PURE__ */ __name((v, context) => {
|
|
1020
|
+
if (!isConfigMapping(v)) return invalidConfigValue(context, [], "must be a mapping");
|
|
1021
|
+
for (const key of Object.keys(v)) {
|
|
1022
|
+
if (key !== "maxConcurrentRuns" && key !== "notifications") {
|
|
1023
|
+
return invalidConfigValue(
|
|
1024
|
+
context,
|
|
1025
|
+
[key],
|
|
1026
|
+
"is not a schedule setting (maxConcurrentRuns, notifications)"
|
|
1027
|
+
);
|
|
1028
|
+
}
|
|
1029
|
+
}
|
|
1030
|
+
const raw = v;
|
|
1031
|
+
if (raw.maxConcurrentRuns !== void 0 && (typeof raw.maxConcurrentRuns !== "number" || !Number.isSafeInteger(raw.maxConcurrentRuns) || raw.maxConcurrentRuns < 1 || raw.maxConcurrentRuns > 16)) {
|
|
1032
|
+
return invalidConfigValue(
|
|
1033
|
+
context,
|
|
1034
|
+
["maxConcurrentRuns"],
|
|
1035
|
+
"must be a whole number from 1 to 16"
|
|
1036
|
+
);
|
|
1037
|
+
}
|
|
1038
|
+
if (raw.notifications !== void 0 && typeof raw.notifications !== "boolean") {
|
|
1039
|
+
return invalidConfigValue(context, ["notifications"], "must be a boolean");
|
|
1040
|
+
}
|
|
1041
|
+
return {
|
|
1042
|
+
...raw.maxConcurrentRuns !== void 0 ? { maxConcurrentRuns: raw.maxConcurrentRuns } : {},
|
|
1043
|
+
...raw.notifications !== void 0 ? { notifications: raw.notifications } : {}
|
|
1044
|
+
};
|
|
1045
|
+
}, "schedule"),
|
|
1046
|
+
// Shape only: the words themselves are matched by the interactive
|
|
1047
|
+
// terminal, which is the only reader. A wrong key or value still refuses,
|
|
1048
|
+
// because an operator who wrote `enabled: flase` believes it is off.
|
|
1049
|
+
composerTriggers: /* @__PURE__ */ __name((v, context) => {
|
|
1050
|
+
if (!isConfigMapping(v)) return invalidConfigValue(context, [], "must be a mapping");
|
|
1051
|
+
for (const key of Object.keys(v)) {
|
|
1052
|
+
if (!COMPOSER_TRIGGERS_KEYS.includes(key)) {
|
|
1053
|
+
return invalidConfigValue(
|
|
1054
|
+
context,
|
|
1055
|
+
[key],
|
|
1056
|
+
`is not a composerTriggers setting (${COMPOSER_TRIGGERS_KEYS.join(", ")})`
|
|
1057
|
+
);
|
|
1058
|
+
}
|
|
1059
|
+
}
|
|
1060
|
+
const raw = v;
|
|
1061
|
+
for (const key of ["enabled", "suggest"]) {
|
|
1062
|
+
if (raw[key] !== void 0 && typeof raw[key] !== "boolean")
|
|
1063
|
+
return invalidConfigValue(context, [key], "must be true or false");
|
|
1064
|
+
}
|
|
1065
|
+
let languages;
|
|
1066
|
+
if (raw.languages !== void 0) {
|
|
1067
|
+
if (!Array.isArray(raw.languages))
|
|
1068
|
+
return invalidConfigValue(context, ["languages"], "must be a list: en, tr");
|
|
1069
|
+
languages = [];
|
|
1070
|
+
for (const [index, language] of raw.languages.entries()) {
|
|
1071
|
+
if (!COMPOSER_TRIGGER_LANGUAGES.includes(language))
|
|
1072
|
+
return invalidConfigValue(context, ["languages", index], "must be en or tr");
|
|
1073
|
+
languages.push(language);
|
|
1074
|
+
}
|
|
1075
|
+
}
|
|
1076
|
+
let builtin;
|
|
1077
|
+
if (raw.builtin !== void 0) {
|
|
1078
|
+
if (!isConfigMapping(raw.builtin))
|
|
1079
|
+
return invalidConfigValue(
|
|
1080
|
+
context,
|
|
1081
|
+
["builtin"],
|
|
1082
|
+
"must be a mapping of trigger to arm, suggest or off"
|
|
1083
|
+
);
|
|
1084
|
+
builtin = {};
|
|
1085
|
+
for (const [id, arming] of Object.entries(raw.builtin)) {
|
|
1086
|
+
if (!COMPOSER_TRIGGER_IDS.includes(id))
|
|
1087
|
+
return invalidConfigValue(
|
|
1088
|
+
context,
|
|
1089
|
+
["builtin", id],
|
|
1090
|
+
`is not a built-in trigger (${COMPOSER_TRIGGER_IDS.join(", ")})`
|
|
1091
|
+
);
|
|
1092
|
+
if (arming !== "arm" && arming !== "suggest" && arming !== "off")
|
|
1093
|
+
return invalidConfigValue(context, ["builtin", id], "must be arm, suggest or off");
|
|
1094
|
+
builtin[id] = arming;
|
|
1095
|
+
}
|
|
1096
|
+
}
|
|
1097
|
+
return {
|
|
1098
|
+
...raw.enabled !== void 0 ? { enabled: raw.enabled } : {},
|
|
1099
|
+
...raw.suggest !== void 0 ? { suggest: raw.suggest } : {},
|
|
1100
|
+
...languages !== void 0 ? { languages } : {},
|
|
1101
|
+
...builtin !== void 0 ? { builtin } : {}
|
|
1102
|
+
};
|
|
1103
|
+
}, "composerTriggers"),
|
|
1104
|
+
tui: /* @__PURE__ */ __name((v, context) => {
|
|
1105
|
+
if (!isConfigMapping(v)) return invalidConfigValue(context, [], "must be a mapping");
|
|
1106
|
+
const raw = v;
|
|
1107
|
+
let notifications;
|
|
1108
|
+
if (typeof raw.notifications === "boolean") notifications = raw.notifications;
|
|
1109
|
+
else if (Array.isArray(raw.notifications)) {
|
|
1110
|
+
const invalidIndex = raw.notifications.findIndex(
|
|
1111
|
+
(event) => event !== "turn-settled" && event !== "approval-required"
|
|
1112
|
+
);
|
|
1113
|
+
if (invalidIndex >= 0) {
|
|
1114
|
+
return invalidConfigValue(
|
|
1115
|
+
context,
|
|
1116
|
+
["notifications", invalidIndex],
|
|
1117
|
+
'must be one of "turn-settled" or "approval-required"'
|
|
1118
|
+
);
|
|
1119
|
+
}
|
|
1120
|
+
notifications = raw.notifications;
|
|
1121
|
+
} else if (raw.notifications !== void 0) {
|
|
1122
|
+
return invalidConfigValue(context, ["notifications"], "must be a boolean or a list");
|
|
1123
|
+
}
|
|
1124
|
+
const method = raw.notificationMethod;
|
|
1125
|
+
if (method !== void 0 && method !== "osc9" && method !== "bel") {
|
|
1126
|
+
return invalidConfigValue(context, ["notificationMethod"], 'must be "osc9" or "bel"');
|
|
1127
|
+
}
|
|
1128
|
+
return {
|
|
1129
|
+
...notifications !== void 0 ? { notifications } : {},
|
|
1130
|
+
...method !== void 0 ? { notificationMethod: method } : {}
|
|
1131
|
+
};
|
|
1132
|
+
}, "tui")
|
|
1133
|
+
};
|
|
1134
|
+
var ENV_VARIABLE_NAMES = {
|
|
1135
|
+
format: "NAMZU_FORMAT",
|
|
1136
|
+
quiet: "NAMZU_QUIET",
|
|
1137
|
+
permissions: void 0,
|
|
1138
|
+
// Deliberately not env-settable, and for a sharper reason than the rest:
|
|
1139
|
+
// a variable that could replace the checks could also empty them, which
|
|
1140
|
+
// would silence the one thing that says a policy stopped meaning what its
|
|
1141
|
+
// author wrote — from a shell profile, with nothing in the config file to
|
|
1142
|
+
// show for it.
|
|
1143
|
+
permissionChecks: void 0,
|
|
1144
|
+
// The SET of profiles is not env-settable — it is the thing being chosen
|
|
1145
|
+
// BETWEEN, and a variable that could replace it could hand a shell a
|
|
1146
|
+
// profile the files never declared. `NAMZU_PROFILE` selects one of the
|
|
1147
|
+
// declared profiles and is read in the cascade rather than here, because
|
|
1148
|
+
// it does not set a config field.
|
|
1149
|
+
profiles: void 0,
|
|
1150
|
+
mcpServers: void 0,
|
|
1151
|
+
// Executable code must never be enabled by ambient shell state. The file
|
|
1152
|
+
// and its provenance are the reviewable source of this authority.
|
|
1153
|
+
plugins: void 0,
|
|
1154
|
+
sandbox: void 0,
|
|
1155
|
+
limits: void 0,
|
|
1156
|
+
// Outbound reach is opted into in the file, never from the environment.
|
|
1157
|
+
web: void 0,
|
|
1158
|
+
// A browser signed in to the operator's sites, and which of them it may
|
|
1159
|
+
// change: a file decision, never a shell's.
|
|
1160
|
+
browser: void 0,
|
|
1161
|
+
// A hook runs a command with the operator's authority; the file is the only
|
|
1162
|
+
// place one may be declared.
|
|
1163
|
+
hooks: void 0,
|
|
1164
|
+
additionalDirectories: void 0,
|
|
1165
|
+
// Absent here for the reason `additionalDirectories` is: the environment
|
|
1166
|
+
// carries scalars, and a screen is a list of names whose meaning belongs
|
|
1167
|
+
// where a project's runs are reviewed.
|
|
1168
|
+
toolResultScreens: void 0,
|
|
1169
|
+
// A strategy is a property of a project's runs, declared where they are reviewed.
|
|
1170
|
+
compaction: void 0,
|
|
1171
|
+
memory: void 0,
|
|
1172
|
+
// Deliberately not env-settable. A `NAMZU_TELEMETRY_SESSION_EXPORT=/tmp/x`
|
|
1173
|
+
// in a shell profile would start exporting conversation content with
|
|
1174
|
+
// nothing in the config file to show for it — the disclosure would be
|
|
1175
|
+
// honest and the *reason* would be invisible.
|
|
1176
|
+
telemetry: void 0,
|
|
1177
|
+
// Terminal notifications are an interactive UI choice. An environment
|
|
1178
|
+
// variable in a shell profile must not start producing them invisibly.
|
|
1179
|
+
tui: void 0,
|
|
1180
|
+
// How many unattended runs a machine starts is the machine owner's to say,
|
|
1181
|
+
// in a file; never a variable a profile could carry invisibly.
|
|
1182
|
+
schedule: void 0,
|
|
1183
|
+
// A list of names and a switch that decide what reaches the model's prompt;
|
|
1184
|
+
// declared in a file, where a project's runs are reviewed.
|
|
1185
|
+
skills: void 0,
|
|
1186
|
+
// What typed words do in the operator's own composer: a file decision,
|
|
1187
|
+
// never a variable a shell profile could carry invisibly.
|
|
1188
|
+
composerTriggers: void 0,
|
|
1189
|
+
// A scalar switch, and the one a CI job or a test harness needs to keep a
|
|
1190
|
+
// launch off the network without writing a config file.
|
|
1191
|
+
modelCatalogueRefresh: "NAMZU_MODEL_CATALOGUE_REFRESH"
|
|
1192
|
+
};
|
|
1193
|
+
function readEnv(env) {
|
|
1194
|
+
const config = {};
|
|
1195
|
+
const variables = {};
|
|
1196
|
+
const formatVar = ENV_VARIABLE_NAMES.format;
|
|
1197
|
+
if (formatVar) {
|
|
1198
|
+
const format = env[formatVar];
|
|
1199
|
+
if (format !== void 0) {
|
|
1200
|
+
if (!isFormatName(format)) {
|
|
1201
|
+
throw new ConfigValueError(
|
|
1202
|
+
{ kind: "environment", variable: formatVar },
|
|
1203
|
+
"format",
|
|
1204
|
+
'must be one of "text", "json", or "yaml"'
|
|
1205
|
+
);
|
|
1206
|
+
}
|
|
1207
|
+
config.format = format;
|
|
1208
|
+
variables.format = formatVar;
|
|
1209
|
+
}
|
|
1210
|
+
}
|
|
1211
|
+
const quietVar = ENV_VARIABLE_NAMES.quiet;
|
|
1212
|
+
if (quietVar) {
|
|
1213
|
+
const quiet = env[quietVar];
|
|
1214
|
+
if (quiet !== void 0) {
|
|
1215
|
+
if (quiet !== "1" && quiet !== "true" && quiet !== "0" && quiet !== "false") {
|
|
1216
|
+
throw new ConfigValueError(
|
|
1217
|
+
{ kind: "environment", variable: quietVar },
|
|
1218
|
+
"quiet",
|
|
1219
|
+
'must be one of "1", "true", "0", or "false"'
|
|
1220
|
+
);
|
|
1221
|
+
}
|
|
1222
|
+
config.quiet = quiet === "1" || quiet === "true";
|
|
1223
|
+
variables.quiet = quietVar;
|
|
1224
|
+
}
|
|
1225
|
+
}
|
|
1226
|
+
const refreshVar = ENV_VARIABLE_NAMES.modelCatalogueRefresh;
|
|
1227
|
+
if (refreshVar) {
|
|
1228
|
+
const refresh = env[refreshVar];
|
|
1229
|
+
if (refresh !== void 0) {
|
|
1230
|
+
if (refresh !== "1" && refresh !== "true" && refresh !== "0" && refresh !== "false") {
|
|
1231
|
+
throw new ConfigValueError(
|
|
1232
|
+
{ kind: "environment", variable: refreshVar },
|
|
1233
|
+
"modelCatalogueRefresh",
|
|
1234
|
+
'must be one of "1", "true", "0", or "false"'
|
|
1235
|
+
);
|
|
1236
|
+
}
|
|
1237
|
+
config.modelCatalogueRefresh = refresh === "1" || refresh === "true";
|
|
1238
|
+
variables.modelCatalogueRefresh = refreshVar;
|
|
1239
|
+
}
|
|
1240
|
+
}
|
|
1241
|
+
return { config, variables };
|
|
1242
|
+
}
|
|
1243
|
+
__name(readEnv, "readEnv");
|
|
1244
|
+
function sanitize(value, source, prefix = [], allowProfiles = true) {
|
|
1245
|
+
const v = value;
|
|
1246
|
+
const out = {};
|
|
1247
|
+
for (const key of Object.keys(CONFIG_READERS)) {
|
|
1248
|
+
if (!Object.hasOwn(v, key)) continue;
|
|
1249
|
+
if (!allowProfiles && (key === "profiles" || key === "plugins")) {
|
|
1250
|
+
throw new ConfigValueError(
|
|
1251
|
+
source,
|
|
1252
|
+
formatSettingPath([...prefix, key]),
|
|
1253
|
+
key === "plugins" ? "cannot be declared inside a profile because profiles may be selected by the environment" : "cannot be declared inside a profile"
|
|
1254
|
+
);
|
|
1255
|
+
}
|
|
1256
|
+
const parsed = CONFIG_READERS[key](v[key], {
|
|
1257
|
+
source,
|
|
1258
|
+
path: [...prefix, key]
|
|
1259
|
+
});
|
|
1260
|
+
out[key] = parsed;
|
|
1261
|
+
}
|
|
1262
|
+
return out;
|
|
1263
|
+
}
|
|
1264
|
+
__name(sanitize, "sanitize");
|
|
1265
|
+
function isConfigMapping(value) {
|
|
1266
|
+
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
1267
|
+
}
|
|
1268
|
+
__name(isConfigMapping, "isConfigMapping");
|
|
1269
|
+
function invalidConfigValue(context, suffix, message) {
|
|
1270
|
+
throw new ConfigValueError(
|
|
1271
|
+
context.source,
|
|
1272
|
+
formatSettingPath([...context.path, ...suffix]),
|
|
1273
|
+
message
|
|
1274
|
+
);
|
|
1275
|
+
}
|
|
1276
|
+
__name(invalidConfigValue, "invalidConfigValue");
|
|
1277
|
+
function formatSettingPath(segments) {
|
|
1278
|
+
let out = "";
|
|
1279
|
+
for (const segment of segments) {
|
|
1280
|
+
if (typeof segment === "number") {
|
|
1281
|
+
out += `[${segment}]`;
|
|
1282
|
+
continue;
|
|
1283
|
+
}
|
|
1284
|
+
if (/^[A-Za-z_$][A-Za-z0-9_$]*$/.test(segment)) {
|
|
1285
|
+
out += out === "" ? segment : `.${segment}`;
|
|
1286
|
+
continue;
|
|
1287
|
+
}
|
|
1288
|
+
out += `[${configMetadataLiteral(segment)}]`;
|
|
1289
|
+
}
|
|
1290
|
+
return out;
|
|
1291
|
+
}
|
|
1292
|
+
__name(formatSettingPath, "formatSettingPath");
|
|
1293
|
+
function constantLayer(config, source) {
|
|
1294
|
+
return { config, sourceFor: /* @__PURE__ */ __name(() => source, "sourceFor") };
|
|
1295
|
+
}
|
|
1296
|
+
__name(constantLayer, "constantLayer");
|
|
1297
|
+
function mergeConfigs(...layers) {
|
|
1298
|
+
const out = {};
|
|
1299
|
+
const provenance = {};
|
|
1300
|
+
for (const layer of layers) {
|
|
1301
|
+
for (const key of Object.keys(layer.config)) {
|
|
1302
|
+
if (key === "browser" && layer.config.browser) {
|
|
1303
|
+
out.browser = mergeBrowserConfig(out.browser, layer.config.browser, layer.sourceFor(key));
|
|
1304
|
+
provenance[key] = layer.sourceFor(key);
|
|
1305
|
+
continue;
|
|
1306
|
+
}
|
|
1307
|
+
if (key === "composerTriggers" && layer.config.composerTriggers) {
|
|
1308
|
+
out.composerTriggers = mergeComposerTriggers(
|
|
1309
|
+
out.composerTriggers,
|
|
1310
|
+
layer.config.composerTriggers,
|
|
1311
|
+
isProjectSource(layer.sourceFor(key))
|
|
1312
|
+
);
|
|
1313
|
+
provenance[key] = layer.sourceFor(key);
|
|
1314
|
+
continue;
|
|
1315
|
+
}
|
|
1316
|
+
;
|
|
1317
|
+
out[key] = layer.config[key];
|
|
1318
|
+
provenance[key] = layer.sourceFor(key);
|
|
1319
|
+
}
|
|
1320
|
+
}
|
|
1321
|
+
return { config: out, provenance };
|
|
1322
|
+
}
|
|
1323
|
+
__name(mergeConfigs, "mergeConfigs");
|
|
1324
|
+
var BROWSER_KEYS = /* @__PURE__ */ new Set([
|
|
1325
|
+
"enabled",
|
|
1326
|
+
"defaultProfile",
|
|
1327
|
+
"engine",
|
|
1328
|
+
"headless",
|
|
1329
|
+
"sites",
|
|
1330
|
+
"keepOpen"
|
|
1331
|
+
]);
|
|
1332
|
+
var BROWSER_PROFILE_NAME = /^[a-z0-9]+(?:-[a-z0-9]+)*$/;
|
|
1333
|
+
function readBrowserConfig(v, context) {
|
|
1334
|
+
if (!isConfigMapping(v)) return invalidConfigValue(context, [], "must be a mapping");
|
|
1335
|
+
for (const key of Object.keys(v)) {
|
|
1336
|
+
if (!BROWSER_KEYS.has(key)) {
|
|
1337
|
+
return invalidConfigValue(
|
|
1338
|
+
context,
|
|
1339
|
+
[key],
|
|
1340
|
+
"is not a browser setting (enabled, defaultProfile, engine, headless, sites, keepOpen)"
|
|
1341
|
+
);
|
|
1342
|
+
}
|
|
1343
|
+
}
|
|
1344
|
+
const raw = v;
|
|
1345
|
+
for (const key of ["enabled", "keepOpen"]) {
|
|
1346
|
+
if (raw[key] !== void 0 && typeof raw[key] !== "boolean")
|
|
1347
|
+
return invalidConfigValue(context, [key], "must be true or false");
|
|
1348
|
+
}
|
|
1349
|
+
if (raw.defaultProfile !== void 0 && (typeof raw.defaultProfile !== "string" || raw.defaultProfile.length > 64 || !BROWSER_PROFILE_NAME.test(raw.defaultProfile))) {
|
|
1350
|
+
return invalidConfigValue(
|
|
1351
|
+
context,
|
|
1352
|
+
["defaultProfile"],
|
|
1353
|
+
"must be a profile name: lowercase letters, digits and single hyphens, at most 64 characters"
|
|
1354
|
+
);
|
|
1355
|
+
}
|
|
1356
|
+
if (raw.engine !== void 0 && !["auto", "windows", "local"].includes(raw.engine))
|
|
1357
|
+
return invalidConfigValue(context, ["engine"], "must be auto, windows or local");
|
|
1358
|
+
if (raw.headless !== void 0 && !["auto", "always", "never"].includes(raw.headless))
|
|
1359
|
+
return invalidConfigValue(context, ["headless"], "must be auto, always or never");
|
|
1360
|
+
let sites;
|
|
1361
|
+
if (raw.sites !== void 0) {
|
|
1362
|
+
if (!isConfigMapping(raw.sites))
|
|
1363
|
+
return invalidConfigValue(context, ["sites"], "must be a mapping of site to level");
|
|
1364
|
+
sites = {};
|
|
1365
|
+
for (const [key, level] of Object.entries(raw.sites)) {
|
|
1366
|
+
if (!isBrowserSiteLevel(level))
|
|
1367
|
+
return invalidConfigValue(context, ["sites", key], "must be deny, read, ask or act");
|
|
1368
|
+
const verdict = canonicalBrowserSiteKey(key);
|
|
1369
|
+
if (!verdict.ok) return invalidConfigValue(context, ["sites", key], verdict.reason);
|
|
1370
|
+
const existing = sites[verdict.key];
|
|
1371
|
+
sites[verdict.key] = existing === void 0 ? level : narrower(existing, level);
|
|
1372
|
+
}
|
|
1373
|
+
}
|
|
1374
|
+
return {
|
|
1375
|
+
...raw.enabled !== void 0 ? { enabled: raw.enabled } : {},
|
|
1376
|
+
...raw.defaultProfile !== void 0 ? { defaultProfile: raw.defaultProfile } : {},
|
|
1377
|
+
...raw.engine !== void 0 ? { engine: raw.engine } : {},
|
|
1378
|
+
...raw.headless !== void 0 ? { headless: raw.headless } : {},
|
|
1379
|
+
...sites !== void 0 ? { sites } : {},
|
|
1380
|
+
...raw.keepOpen !== void 0 ? { keepOpen: raw.keepOpen } : {}
|
|
1381
|
+
};
|
|
1382
|
+
}
|
|
1383
|
+
__name(readBrowserConfig, "readBrowserConfig");
|
|
1384
|
+
function isProjectSource(source) {
|
|
1385
|
+
return source.kind === "project-file" || source.kind === "profile" && basename(source.path) === "namzu.config.json";
|
|
1386
|
+
}
|
|
1387
|
+
__name(isProjectSource, "isProjectSource");
|
|
1388
|
+
function mergeBrowserConfig(below, layer, source) {
|
|
1389
|
+
if (layer.defaultProfile !== void 0 && isProjectSource(source)) {
|
|
1390
|
+
throw new ConfigValueError(
|
|
1391
|
+
{ kind: "file", path: "path" in source ? source.path : "namzu.config.json" },
|
|
1392
|
+
"browser.defaultProfile",
|
|
1393
|
+
"cannot be set in a project file: a profile holds your sign-ins, so choose it in your user config or with /browser profile"
|
|
1394
|
+
);
|
|
1395
|
+
}
|
|
1396
|
+
if (!below) return layer;
|
|
1397
|
+
let sites = below.sites;
|
|
1398
|
+
if (layer.sites) {
|
|
1399
|
+
const merged = { ...below.sites ?? {} };
|
|
1400
|
+
const closed = below.sites?.["*"] === "deny";
|
|
1401
|
+
for (const [key, level] of Object.entries(layer.sites)) {
|
|
1402
|
+
const existing = merged[key];
|
|
1403
|
+
if (existing === void 0) {
|
|
1404
|
+
if (closed && key !== "*") continue;
|
|
1405
|
+
merged[key] = level;
|
|
1406
|
+
continue;
|
|
1407
|
+
}
|
|
1408
|
+
merged[key] = existing === "deny" ? "deny" : level;
|
|
1409
|
+
}
|
|
1410
|
+
sites = merged;
|
|
1411
|
+
}
|
|
1412
|
+
const enabled = below.enabled === false || layer.enabled === false ? false : layer.enabled ?? below.enabled;
|
|
1413
|
+
return {
|
|
1414
|
+
...below,
|
|
1415
|
+
...layer,
|
|
1416
|
+
...enabled !== void 0 ? { enabled } : {},
|
|
1417
|
+
...sites !== void 0 ? { sites } : {}
|
|
1418
|
+
};
|
|
1419
|
+
}
|
|
1420
|
+
__name(mergeBrowserConfig, "mergeBrowserConfig");
|
|
1421
|
+
|
|
1422
|
+
export {
|
|
1423
|
+
canonicalBrowserSiteKey,
|
|
1424
|
+
compileBrowserSites,
|
|
1425
|
+
withBrowserSiteRules,
|
|
1426
|
+
browserSiteRuleFor,
|
|
1427
|
+
browserCallOrigin,
|
|
1428
|
+
COMPOSER_TRIGGER_IDS,
|
|
1429
|
+
COMPOSER_TRIGGER_DEFAULTS,
|
|
1430
|
+
resolveComposerTriggers,
|
|
1431
|
+
DEFAULT_CONFIG,
|
|
1432
|
+
loadConfigWithProvenance,
|
|
1433
|
+
loadBootstrapConfigWithProvenance,
|
|
1434
|
+
readPermissionLayers,
|
|
1435
|
+
loadConfig,
|
|
1436
|
+
ConfigLoadError,
|
|
1437
|
+
ConfigValueError
|
|
1438
|
+
};
|
|
1439
|
+
//# sourceMappingURL=chunk-YYQJIECC.js.map
|