@namzu/cli 57.0.0 → 58.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 +142 -0
- package/README.md +5 -5
- package/dist/bin.js +1 -1
- package/dist/boot-narrative.d.ts.map +1 -1
- package/dist/browser/control.d.ts +25 -2
- package/dist/browser/control.d.ts.map +1 -1
- package/dist/chunks/{acp-KBPTK4GN.js → acp-OZG7H75P.js} +441 -205
- package/dist/chunks/acp-OZG7H75P.js.map +6 -0
- package/dist/chunks/{activity-command-JOED2VWN.js → activity-command-ZROH53CS.js} +14 -15
- package/dist/chunks/activity-command-ZROH53CS.js.map +6 -0
- package/dist/chunks/{add-66AQ7SKZ.js → add-DKSV5Y3C.js} +36 -34
- package/dist/chunks/add-DKSV5Y3C.js.map +6 -0
- package/dist/chunks/{agent-DL7YTL5B.js → agent-MSSMOEBP.js} +58 -48
- package/dist/chunks/agent-session-VCB6HX3E.js +89 -0
- package/dist/chunks/{apply-at-exit-5GUCOPX3.js → apply-at-exit-Z34ZOT4A.js} +9 -9
- package/dist/chunks/{apply-at-exit-5GUCOPX3.js.map → apply-at-exit-Z34ZOT4A.js.map} +1 -1
- package/dist/chunks/{archive-ED4CWEU2.js → archive-UMNSALTJ.js} +16 -13
- package/dist/chunks/archive-UMNSALTJ.js.map +6 -0
- package/dist/chunks/auth-2NEDWCS7.js +242 -0
- package/dist/chunks/auth-2NEDWCS7.js.map +6 -0
- package/dist/chunks/{bin-main-JDJ6LEOK.js → bin-main-2E6XD7MQ.js} +8 -8
- package/dist/chunks/{binding-NU3G3EBQ.js → binding-NAPEU62B.js} +3 -3
- package/dist/chunks/browser-M7U6GZOY.js +76 -0
- package/dist/chunks/browser-M7U6GZOY.js.map +6 -0
- package/dist/chunks/{chat-ISFH5CPZ.js → chat-34SAREPI.js} +17 -18
- package/dist/chunks/chat-34SAREPI.js.map +6 -0
- package/dist/chunks/{chunk-C4CUPDOU.js → chunk-27ICMJVV.js} +3 -3
- package/dist/chunks/{chunk-6XIPTDOH.js → chunk-2D5WW5KP.js} +2 -2
- package/dist/chunks/{chunk-T3VMBZEY.js → chunk-2GKFWJ3O.js} +7 -186
- package/dist/chunks/chunk-2GKFWJ3O.js.map +6 -0
- package/dist/chunks/{chunk-K3NVHXN7.js → chunk-2J2Z6S3V.js} +21 -21
- package/dist/chunks/{chunk-G3WCIRCZ.js → chunk-2PRVGX6U.js} +8 -8
- package/dist/chunks/chunk-2QJNPJOC.js +39 -0
- package/dist/chunks/chunk-2QJNPJOC.js.map +6 -0
- package/dist/chunks/{chunk-K5FGK5AP.js → chunk-32CPPPKX.js} +3 -3
- package/dist/chunks/{chunk-ETDOSJF7.js → chunk-3SBROSVS.js} +2 -2
- package/dist/chunks/{chunk-ZT3DLJQZ.js → chunk-3ZL6YBMT.js} +6 -6
- package/dist/chunks/chunk-4AWE33MD.js +186 -0
- package/dist/chunks/chunk-4AWE33MD.js.map +6 -0
- package/dist/chunks/{chunk-C534SIJI.js → chunk-4RCXY7WO.js} +2 -2
- package/dist/chunks/{chunk-IH5NEU2Y.js → chunk-4WLMPRGO.js} +4 -4
- package/dist/chunks/{chunk-IH5NEU2Y.js.map → chunk-4WLMPRGO.js.map} +1 -1
- package/dist/chunks/{chunk-NQ3MZ6N4.js → chunk-4YQJ262B.js} +2 -2
- package/dist/chunks/{chunk-WEL6L6DN.js → chunk-52DZTN4C.js} +5 -3
- package/dist/chunks/{chunk-QF4HGWRL.js → chunk-5564PCLT.js} +11 -9
- package/dist/chunks/chunk-5564PCLT.js.map +6 -0
- package/dist/chunks/{chunk-2TU3QQRG.js → chunk-5COLG33E.js} +35 -6
- package/dist/chunks/chunk-5COLG33E.js.map +6 -0
- package/dist/chunks/{chunk-MTSXDMJB.js → chunk-5GI7W4SM.js} +9 -9
- package/dist/chunks/{chunk-I7WXDTCF.js → chunk-5NIQMCRF.js} +2 -2
- package/dist/chunks/{chunk-JOORBY5L.js → chunk-5WS5Q2KW.js} +3 -3
- package/dist/chunks/{chunk-T5MBQXU2.js → chunk-655EBPZH.js} +36 -12
- package/dist/chunks/{chunk-T5MBQXU2.js.map → chunk-655EBPZH.js.map} +1 -1
- package/dist/chunks/{chunk-7EL5RPEU.js → chunk-66DFXMZG.js} +5 -5
- package/dist/chunks/{chunk-6SEDSZBH.js → chunk-6MMKNZYL.js} +3 -3
- package/dist/chunks/{chunk-Y3KKZ7HS.js → chunk-6QQVZXUE.js} +2 -2
- package/dist/chunks/{chunk-X2JFYB5A.js → chunk-6RBEIDSC.js} +3 -3
- package/dist/chunks/{chunk-IRCAPHCE.js → chunk-6V4VYVRZ.js} +2 -2
- package/dist/chunks/{chunk-QJYK566B.js → chunk-6ZWEKSAV.js} +7 -7
- package/dist/chunks/{chunk-AFNHI46Y.js → chunk-774DAIPO.js} +1188 -744
- package/dist/chunks/chunk-774DAIPO.js.map +6 -0
- package/dist/chunks/{chunk-F7ECENUK.js → chunk-7BSLOLTU.js} +2 -2
- package/dist/chunks/{chunk-TOADRNOV.js → chunk-7BXJPOEG.js} +4 -4
- package/dist/chunks/{chunk-BFTAE67C.js → chunk-7DERK6IR.js} +3 -3
- package/dist/chunks/{chunk-4KGXEARZ.js → chunk-7EASTT3H.js} +2 -2
- package/dist/chunks/{chunk-OP2GILCA.js → chunk-7LCU5IKH.js} +20 -20
- package/dist/chunks/{chunk-OP2GILCA.js.map → chunk-7LCU5IKH.js.map} +1 -1
- package/dist/chunks/{chunk-5PTXGBPL.js → chunk-7MYLYFIV.js} +2 -2
- package/dist/chunks/{chunk-KOVWQARO.js → chunk-7NAHUZAR.js} +2 -2
- package/dist/chunks/{chunk-GQU3OUV5.js → chunk-7NQLCFYX.js} +5 -5
- package/dist/chunks/{chunk-ICQYIDIR.js → chunk-7ROZ2N57.js} +35 -3
- package/dist/chunks/chunk-7ROZ2N57.js.map +6 -0
- package/dist/chunks/{chunk-SIG7WHBU.js → chunk-7YC42EXB.js} +5 -1
- package/dist/chunks/{chunk-SIG7WHBU.js.map → chunk-7YC42EXB.js.map} +1 -1
- package/dist/chunks/{chunk-JRIDJW3W.js → chunk-A5O5VTQM.js} +3 -3
- package/dist/chunks/{chunk-VFB4ZUOR.js → chunk-ADLNBLRA.js} +28 -16
- package/dist/chunks/chunk-ADLNBLRA.js.map +6 -0
- package/dist/chunks/{chunk-JB3UZ7JJ.js → chunk-BATWKQWV.js} +2 -2
- package/dist/chunks/{chunk-6JAWZGSH.js → chunk-CK47DTW6.js} +5 -5
- package/dist/chunks/{chunk-P7UV5M73.js → chunk-CSO7BHDJ.js} +2 -2
- package/dist/chunks/{chunk-ECDMJNZU.js → chunk-D42SQGEO.js} +2 -2
- package/dist/chunks/{chunk-DYCSVG2K.js → chunk-DIBXZBOP.js} +7 -7
- package/dist/chunks/{chunk-3ZHOM2L7.js → chunk-DZA7UXA2.js} +15 -63
- package/dist/chunks/chunk-DZA7UXA2.js.map +6 -0
- package/dist/chunks/{chunk-CJUK4IWQ.js → chunk-EFWF72V4.js} +3 -3
- package/dist/chunks/{chunk-A4I24ISL.js → chunk-ENNAZGUX.js} +3 -3
- package/dist/chunks/{chunk-5GRTRQTV.js → chunk-EOLXS2ZV.js} +5 -5
- package/dist/chunks/{chunk-QF2FZ2DM.js → chunk-ESHAWCBR.js} +43 -12
- package/dist/chunks/chunk-ESHAWCBR.js.map +6 -0
- package/dist/chunks/{chunk-YBAPUTER.js → chunk-F6NUMURW.js} +3 -3
- package/dist/chunks/{chunk-LD4COIFG.js → chunk-FJG7JN4W.js} +5 -5
- package/dist/chunks/{chunk-LD4COIFG.js.map → chunk-FJG7JN4W.js.map} +1 -1
- package/dist/chunks/{chunk-ZFQOF5A5.js → chunk-FZPIEOFR.js} +3 -3
- package/dist/chunks/{chunk-372SLS6Y.js → chunk-G7UGGWOR.js} +2 -2
- package/dist/chunks/{chunk-4PX62LQ2.js → chunk-GLZJBFDO.js} +4 -4
- package/dist/chunks/{chunk-O5YDY6XR.js → chunk-GVLU2YM7.js} +17 -20
- package/dist/chunks/{chunk-O5YDY6XR.js.map → chunk-GVLU2YM7.js.map} +1 -1
- package/dist/chunks/{chunk-QERO7OI6.js → chunk-HBGRWJU5.js} +13 -13
- package/dist/chunks/{chunk-DBXWOXG3.js → chunk-HGOU2QRN.js} +19 -19
- package/dist/chunks/{chunk-DBXWOXG3.js.map → chunk-HGOU2QRN.js.map} +1 -1
- package/dist/chunks/{chunk-BQR2C4RM.js → chunk-HICZARAY.js} +2 -2
- package/dist/chunks/{chunk-HQFAVCTF.js → chunk-HONSYTUC.js} +4 -4
- package/dist/chunks/{chunk-XYF26ZUO.js → chunk-HRKY4ARS.js} +13 -11
- package/dist/chunks/chunk-HRKY4ARS.js.map +6 -0
- package/dist/chunks/{chunk-X4W4DN3S.js → chunk-I5BNXO63.js} +2 -2
- package/dist/chunks/{chunk-RF6EIDPV.js → chunk-IBENEKM4.js} +27 -5
- package/dist/chunks/chunk-IBENEKM4.js.map +6 -0
- package/dist/chunks/{chunk-DID4WFOD.js → chunk-IH2JBJ6I.js} +4 -4
- package/dist/chunks/{chunk-5X4XLHLF.js → chunk-J4GPHTRN.js} +8 -8
- package/dist/chunks/{chunk-I5CWCNRN.js → chunk-JFA2XPTW.js} +5 -5
- package/dist/chunks/{chunk-IT2OFHF7.js → chunk-JSY23B3Q.js} +3 -3
- package/dist/chunks/{chunk-L2Q467T7.js → chunk-JX6O7Y55.js} +4 -4
- package/dist/chunks/{chunk-L2Q467T7.js.map → chunk-JX6O7Y55.js.map} +1 -1
- package/dist/chunks/{chunk-U77GVCK3.js → chunk-K5VLCRHY.js} +2 -2
- package/dist/chunks/chunk-K7ZQYJJE.js +197 -0
- package/dist/chunks/chunk-K7ZQYJJE.js.map +6 -0
- package/dist/chunks/{chunk-7AXLZKTB.js → chunk-KCBOIL5Q.js} +7 -7
- package/dist/chunks/{chunk-KE53UTUG.js → chunk-KIWLK2WZ.js} +7 -9
- package/dist/chunks/chunk-KIWLK2WZ.js.map +6 -0
- package/dist/chunks/chunk-L4LGUBYZ.js +167 -0
- package/dist/chunks/chunk-L4LGUBYZ.js.map +6 -0
- package/dist/chunks/{chunk-X7QC2Q7P.js → chunk-L5FCGDB7.js} +1674 -688
- package/dist/chunks/chunk-L5FCGDB7.js.map +6 -0
- package/dist/chunks/{chunk-LS5KVRMV.js → chunk-LM2OGSW5.js} +6 -6
- package/dist/chunks/{chunk-LS5KVRMV.js.map → chunk-LM2OGSW5.js.map} +1 -1
- package/dist/chunks/{chunk-QUI2ZAGY.js → chunk-LRUY5C6H.js} +83 -18
- package/dist/chunks/chunk-LRUY5C6H.js.map +6 -0
- package/dist/chunks/{chunk-QW3Y3RDE.js → chunk-MJ32RCFZ.js} +4 -4
- package/dist/chunks/{chunk-Q4LXBL4Z.js → chunk-MJJA277Z.js} +19 -4
- package/dist/chunks/{chunk-Q4LXBL4Z.js.map → chunk-MJJA277Z.js.map} +1 -1
- package/dist/chunks/{chunk-5TJZWGTZ.js → chunk-MOY2OERC.js} +463 -135
- package/dist/chunks/chunk-MOY2OERC.js.map +6 -0
- package/dist/chunks/{chunk-PHDA4JI7.js → chunk-MX3U5TBQ.js} +17 -6
- package/dist/chunks/chunk-MX3U5TBQ.js.map +6 -0
- package/dist/chunks/{chunk-WIO3JRB5.js → chunk-NBJ4OTXL.js} +8 -8
- package/dist/chunks/{chunk-BFYETM56.js → chunk-NFTQDITK.js} +91 -6
- package/dist/chunks/chunk-NFTQDITK.js.map +6 -0
- package/dist/chunks/{chunk-66ZXPQGB.js → chunk-NO3F3QQ3.js} +13 -13
- package/dist/chunks/{chunk-LJDAHRWI.js → chunk-NQYOMRPT.js} +2 -2
- package/dist/chunks/{chunk-WXCJTJK4.js → chunk-O6C4RETO.js} +3 -3
- package/dist/chunks/{chunk-W5TYUJI5.js → chunk-O6EDUJ77.js} +6 -6
- package/dist/chunks/{chunk-F7LHGSEQ.js → chunk-OD2PMTXS.js} +3 -3
- package/dist/chunks/{chunk-5LDYBGOZ.js → chunk-OGEOUETU.js} +3 -3
- package/dist/chunks/{chunk-WSO7YQLR.js → chunk-OY3UN3KD.js} +145 -3
- package/dist/chunks/{chunk-WSO7YQLR.js.map → chunk-OY3UN3KD.js.map} +2 -2
- package/dist/chunks/chunk-P6RYPNSD.js +435 -0
- package/dist/chunks/chunk-P6RYPNSD.js.map +6 -0
- package/dist/chunks/{chunk-MI6WMBDQ.js → chunk-PYTTGYZS.js} +3 -3
- package/dist/chunks/chunk-RHJOIAFS.js +201 -0
- package/dist/chunks/chunk-RHJOIAFS.js.map +6 -0
- package/dist/chunks/{chunk-U2MFIQ6X.js → chunk-RR7FS6SQ.js} +3 -3
- package/dist/chunks/{chunk-7O2WNQQZ.js → chunk-RTMX7IDM.js} +2 -2
- package/dist/chunks/{chunk-ZAPPY4VF.js → chunk-S4OEUN6F.js} +2 -2
- package/dist/chunks/{chunk-EXE7JBHE.js → chunk-SEVORRUA.js} +2 -2
- package/dist/chunks/{chunk-WCPKRDGR.js → chunk-TAIC3PC2.js} +3 -3
- package/dist/chunks/{chunk-AF4ILHID.js → chunk-TGLXWW5B.js} +3 -3
- package/dist/chunks/{chunk-4YN7VGLV.js → chunk-TJAUF5NX.js} +3 -3
- package/dist/chunks/{chunk-AWU5MYX3.js → chunk-TL535OCL.js} +29 -13
- package/dist/chunks/chunk-TL535OCL.js.map +6 -0
- package/dist/chunks/{chunk-E7RD32NX.js → chunk-TSU4F6DF.js} +2 -2
- package/dist/chunks/{chunk-MPIYLDWJ.js → chunk-TXMWKHYW.js} +2 -2
- package/dist/chunks/{chunk-6F3M3P3W.js → chunk-U4DBETHR.js} +807 -755
- package/dist/chunks/chunk-U4DBETHR.js.map +6 -0
- package/dist/chunks/{chunk-PYR7VRWF.js → chunk-UBGDYBSQ.js} +2 -2
- package/dist/chunks/{chunk-73VS7EXG.js → chunk-ULFR2FWA.js} +2 -2
- package/dist/chunks/{chunk-HXW5DQLU.js → chunk-UMPJ4VXN.js} +4 -4
- package/dist/chunks/{chunk-MN426ZWA.js → chunk-URZPVSHV.js} +4 -4
- package/dist/chunks/{chunk-7WDKN3QG.js → chunk-UXLQNJDR.js} +4 -4
- package/dist/chunks/{chunk-QS44GK4N.js → chunk-WEPINZBQ.js} +12 -4
- package/dist/chunks/{chunk-QS44GK4N.js.map → chunk-WEPINZBQ.js.map} +1 -1
- package/dist/chunks/{chunk-GWH6BOVE.js → chunk-XQZMTH3S.js} +12 -40
- package/dist/chunks/chunk-XQZMTH3S.js.map +6 -0
- package/dist/chunks/{chunk-SQ32S3OE.js → chunk-XWP64X6U.js} +6 -6
- package/dist/chunks/{chunk-YQOT7ABG.js → chunk-Y3NC6RIL.js} +4 -4
- package/dist/chunks/{chunk-LMPUBX5R.js → chunk-YEWJVAM4.js} +57 -9
- package/dist/chunks/chunk-YEWJVAM4.js.map +6 -0
- package/dist/chunks/{chunk-FNSWIOFJ.js → chunk-ZDMI3JSL.js} +26 -4
- package/dist/chunks/{chunk-FNSWIOFJ.js.map → chunk-ZDMI3JSL.js.map} +1 -1
- package/dist/chunks/{cli-runtime-2HOSJR5Y.js → cli-runtime-BLOWAO6Q.js} +34 -19
- package/dist/chunks/cli-runtime-BLOWAO6Q.js.map +6 -0
- package/dist/chunks/{commands-TKD5BHAC.js → commands-VWBRELWZ.js} +6 -6
- package/dist/chunks/{computer-FQRWTC6M.js → computer-6P3GAOV2.js} +15 -7
- package/dist/chunks/computer-6P3GAOV2.js.map +6 -0
- package/dist/chunks/{config-2JST7BZT.js → config-77NN5LSS.js} +20 -17
- package/dist/chunks/config-77NN5LSS.js.map +6 -0
- package/dist/chunks/{cost-AZAQ3AC5.js → cost-IVLAFD5T.js} +5 -5
- package/dist/chunks/{crash-report-IYMUJRDT.js → crash-report-CA3Y7LA6.js} +6 -6
- package/dist/chunks/{dist-5JRS362B.js → dist-3SGAVJFN.js} +2 -2
- package/dist/chunks/{dist-PYOYSQIZ.js → dist-5G52QS75.js} +193 -33
- package/dist/chunks/dist-5G52QS75.js.map +6 -0
- package/dist/chunks/{dist-S4GG5BOF.js → dist-7BSYEFE5.js} +2 -2
- package/dist/chunks/{dist-SPKR3SBF.js → dist-AM6FWCIJ.js} +10 -2
- package/dist/chunks/{dist-YGZEZT7E.js → dist-ISRJEZRF.js} +2 -2
- package/dist/chunks/{dist-BECOVIWQ.js → dist-PBFZXU4L.js} +2 -2
- package/dist/chunks/{dist-VQGHI5SR.js → dist-RDXEBTCL.js} +2 -2
- package/dist/chunks/{dist-NLY5ZLEK.js → dist-V43PPTPF.js} +2 -2
- package/dist/chunks/{doctor-MYN7YCXB.js → doctor-FGOCO7UR.js} +39 -39
- package/dist/chunks/{drain-IEZMA72M.js → drain-A3DLR5A4.js} +18 -18
- package/dist/chunks/{entry-SS5QYOOM.js → entry-4LHTI3VQ.js} +6 -6
- package/dist/chunks/{eval-4QK2EYXU.js → eval-IYWGGPWF.js} +12 -12
- package/dist/chunks/{eval-4QK2EYXU.js.map → eval-IYWGGPWF.js.map} +1 -1
- package/dist/chunks/{exec-Z6TIWDJM.js → exec-HWK44ZYI.js} +104 -60
- package/dist/chunks/exec-HWK44ZYI.js.map +6 -0
- package/dist/chunks/{extension-4SMB7XQP.js → extension-BP7Q3PFK.js} +5 -5
- package/dist/chunks/{github-X352BD5R.js → github-IF3JVVJF.js} +5 -1
- package/dist/chunks/github-IF3JVVJF.js.map +6 -0
- package/dist/chunks/{home-YYLBZ3E7.js → home-GR6YDAAE.js} +3 -3
- package/dist/chunks/{hooks-KVCP7AHB.js → hooks-KSSNBDF2.js} +22 -22
- package/dist/chunks/{hooks-report-7BAQ5FJD.js → hooks-report-H4JAHJXE.js} +18 -18
- package/dist/chunks/{host-CAZNAKUM.js → host-ISKJDJ7B.js} +10 -10
- package/dist/chunks/host-queries-CUG75GYD.js +37 -0
- package/dist/chunks/{installed-list-X7D2METU.js → installed-list-GPVOP4E3.js} +4 -4
- package/dist/chunks/{learn-BSA4OH3O.js → learn-AFNJQGOU.js} +18 -18
- package/dist/chunks/{learn-builtin-YIJE4KDM.js → learn-builtin-LUD6XO6W.js} +21 -21
- package/dist/chunks/{lifecycle-4CCVUYHX.js → lifecycle-TCRMEVJP.js} +31 -32
- package/dist/chunks/{list-Y365NWT5.js → list-4OJNF5N2.js} +16 -16
- package/dist/chunks/{live-3URICZBD.js → live-LJ76XHPK.js} +38 -38
- package/dist/chunks/{load-LXAWOITU.js → load-2ERMTCD4.js} +12 -10
- package/dist/chunks/{logs-OGG4QEIR.js → logs-DV6GC7PT.js} +4 -4
- package/dist/chunks/{mcp-VCZRILZ2.js → mcp-5VV24FGZ.js} +449 -61
- package/dist/chunks/mcp-5VV24FGZ.js.map +6 -0
- package/dist/chunks/mcp-serve-TT4Q7V55.js +311 -0
- package/dist/chunks/mcp-serve-TT4Q7V55.js.map +6 -0
- package/dist/chunks/{message-command-RN3TYTUE.js → message-command-6RHBI3R4.js} +56 -54
- package/dist/chunks/message-command-6RHBI3R4.js.map +6 -0
- package/dist/chunks/{open-S3T2QSFD.js → open-3VUS3XWX.js} +7 -7
- package/dist/chunks/{operator-tools-4FKDVXEJ.js → operator-tools-BZ5X5ZDE.js} +15 -16
- package/dist/chunks/operator-tools-BZ5X5ZDE.js.map +6 -0
- package/dist/chunks/{output-schema-JZS2DYJS.js → output-schema-2GHHC5ZZ.js} +3 -3
- package/dist/chunks/{pal-N4BQKNXH.js → pal-TT7X5JF3.js} +150 -15
- package/dist/chunks/pal-TT7X5JF3.js.map +6 -0
- package/dist/chunks/{peers-3QJCXMVT.js → peers-SJFCJTA6.js} +149 -19
- package/dist/chunks/peers-SJFCJTA6.js.map +6 -0
- package/dist/chunks/{peers-B46EOYXB.js → peers-SLFOET3O.js} +7 -7
- package/dist/chunks/{plugin-SJ3Y2P53.js → plugin-I35EQ4CC.js} +22 -18
- package/dist/chunks/plugin-I35EQ4CC.js.map +6 -0
- package/dist/chunks/{providers-6HCMKQUI.js → providers-MX47EUPL.js} +22 -19
- package/dist/chunks/providers-MX47EUPL.js.map +6 -0
- package/dist/chunks/{providers-AAGYOW7X.js → providers-SOFGNZ4F.js} +10 -10
- package/dist/chunks/{pty-Y6DQ3O7S.js → pty-3T7AE7ZA.js} +3 -3
- package/dist/chunks/resume-5JACRBQO.js +25 -0
- package/dist/chunks/{resume-command-GPX3ZFJG.js → resume-command-H4FOREZO.js} +4 -4
- package/dist/chunks/{running-XXZFJXM2.js → running-NONPWC5C.js} +4 -4
- package/dist/chunks/{schedule-36SDQUHA.js → schedule-BWR4NKGX.js} +245 -10
- package/dist/chunks/schedule-BWR4NKGX.js.map +6 -0
- package/dist/chunks/{send-3I5I445I.js → send-H27WTBLZ.js} +18 -18
- package/dist/chunks/send-person-NNGL2U4H.js +31 -0
- package/dist/chunks/{serve-CZDHGDZL.js → serve-4VIDXLEB.js} +2 -2
- package/dist/chunks/{service-2KVKUVPK.js → service-NVOIN2MV.js} +32 -33
- package/dist/chunks/service-NVOIN2MV.js.map +6 -0
- package/dist/chunks/{setting-cli-BIG2WZWH.js → setting-cli-ETVPDSRA.js} +13 -13
- package/dist/chunks/{skills-ROGIKQBK.js → skills-XAONTP56.js} +28 -25
- package/dist/chunks/skills-XAONTP56.js.map +6 -0
- package/dist/chunks/{start-check-WZ3L3FAC.js → start-check-A5FG7224.js} +2 -2
- package/dist/chunks/{startup-failure-Y6OKFLWB.js → startup-failure-6MZNIJXI.js} +2 -2
- package/dist/chunks/{state-EK4XKBK5.js → state-MVYWWBAA.js} +556 -26
- package/dist/chunks/state-MVYWWBAA.js.map +6 -0
- package/dist/chunks/{store-IOOFZ6PN.js → store-4PPSKMYT.js} +3 -3
- package/dist/chunks/{store-A6ZRPCAB.js → store-5K5HIPUT.js} +12 -13
- package/dist/chunks/{store-FLT5PL3C.js → store-6WG6CRWK.js} +4 -4
- package/dist/chunks/{store-NX2MC2JN.js → store-UPAOLS5B.js} +8 -8
- package/dist/chunks/{tui-DT36PST5.js → tui-MRMMX2TV.js} +99 -87
- package/dist/chunks/tui-MRMMX2TV.js.map +6 -0
- package/dist/chunks/{upgrade-AHGIHDGH.js → update-RMHLR4LI.js} +35 -35
- package/dist/chunks/{upgrade-AHGIHDGH.js.map → update-RMHLR4LI.js.map} +2 -2
- package/dist/chunks/{watch-AFI4NLCR.js → watch-3QQJ4XHX.js} +93 -89
- package/dist/chunks/watch-3QQJ4XHX.js.map +6 -0
- package/dist/chunks/{workspaces-QKVXLISC.js → workspaces-HEA2VNIH.js} +15 -20
- package/dist/chunks/workspaces-HEA2VNIH.js.map +6 -0
- package/dist/chunks/{worktree-NWJLCB5C.js → worktree-NAVT42R4.js} +26 -23
- package/dist/chunks/worktree-NAVT42R4.js.map +6 -0
- package/dist/cli-runtime.d.ts +3 -1
- package/dist/cli-runtime.d.ts.map +1 -1
- package/dist/cli.d.ts +15 -0
- package/dist/cli.d.ts.map +1 -1
- package/dist/commands/acp-browser-pane.d.ts +81 -0
- package/dist/commands/acp-browser-pane.d.ts.map +1 -0
- package/dist/commands/acp-provider-retry.d.ts +2 -1
- package/dist/commands/acp-provider-retry.d.ts.map +1 -1
- package/dist/commands/acp.d.ts +18 -1
- package/dist/commands/acp.d.ts.map +1 -1
- package/dist/commands/action-help.d.ts +37 -0
- package/dist/commands/action-help.d.ts.map +1 -0
- package/dist/commands/actions/auth.d.ts +3 -0
- package/dist/commands/actions/auth.d.ts.map +1 -0
- package/dist/commands/actions/browser.d.ts +3 -0
- package/dist/commands/actions/browser.d.ts.map +1 -0
- package/dist/commands/actions/extension.d.ts +3 -0
- package/dist/commands/actions/extension.d.ts.map +1 -0
- package/dist/commands/actions/mcp.d.ts +3 -0
- package/dist/commands/actions/mcp.d.ts.map +1 -0
- package/dist/commands/actions/pal.d.ts +3 -0
- package/dist/commands/actions/pal.d.ts.map +1 -0
- package/dist/commands/actions/peers.d.ts +3 -0
- package/dist/commands/actions/peers.d.ts.map +1 -0
- package/dist/commands/actions/schedule.d.ts +3 -0
- package/dist/commands/actions/schedule.d.ts.map +1 -0
- package/dist/commands/actions/small.d.ts +11 -0
- package/dist/commands/actions/small.d.ts.map +1 -0
- package/dist/commands/archive.d.ts.map +1 -1
- package/dist/commands/auth-status.d.ts +24 -0
- package/dist/commands/auth-status.d.ts.map +1 -0
- package/dist/commands/auth.d.ts +9 -0
- package/dist/commands/auth.d.ts.map +1 -0
- package/dist/commands/browser.d.ts.map +1 -1
- package/dist/commands/computer.d.ts.map +1 -1
- package/dist/commands/config.d.ts.map +1 -1
- package/dist/commands/desktop-host.d.ts +3 -3
- package/dist/commands/desktop-host.d.ts.map +1 -1
- package/dist/commands/exec-flags.d.ts +17 -3
- package/dist/commands/exec-flags.d.ts.map +1 -1
- package/dist/commands/exec-json.d.ts.map +1 -1
- package/dist/commands/exec.d.ts.map +1 -1
- package/dist/commands/extension.d.ts.map +1 -1
- package/dist/commands/github.d.ts.map +1 -1
- package/dist/commands/launch-extras.d.ts +48 -0
- package/dist/commands/launch-extras.d.ts.map +1 -0
- package/dist/commands/lazy.d.ts +3 -3
- package/dist/commands/lazy.d.ts.map +1 -1
- package/dist/commands/login.d.ts +1 -1
- package/dist/commands/manifest.d.ts +3 -4
- package/dist/commands/manifest.d.ts.map +1 -1
- package/dist/commands/mcp-serve.d.ts +16 -0
- package/dist/commands/mcp-serve.d.ts.map +1 -0
- package/dist/commands/mcp.d.ts.map +1 -1
- package/dist/commands/pal.d.ts.map +1 -1
- package/dist/commands/peers.d.ts.map +1 -1
- package/dist/commands/plugin.d.ts.map +1 -1
- package/dist/commands/providers.d.ts.map +1 -1
- package/dist/commands/registry.d.ts.map +1 -1
- package/dist/commands/run-flags.d.ts +10 -2
- package/dist/commands/run-flags.d.ts.map +1 -1
- package/dist/commands/schedule.d.ts.map +1 -1
- package/dist/commands/skills.d.ts.map +1 -1
- package/dist/commands/state.d.ts +11 -0
- package/dist/commands/state.d.ts.map +1 -1
- package/dist/commands/types.d.ts +9 -2
- package/dist/commands/types.d.ts.map +1 -1
- package/dist/commands/{upgrade-progress.d.ts → update-progress.d.ts} +3 -3
- package/dist/commands/update-progress.d.ts.map +1 -0
- package/dist/commands/{upgrade.d.ts → update.d.ts} +9 -9
- package/dist/commands/update.d.ts.map +1 -0
- package/dist/commands/workspaces.d.ts +1 -1
- package/dist/commands/workspaces.d.ts.map +1 -1
- package/dist/commands/worktree.d.ts.map +1 -1
- package/dist/computer/run.d.ts.map +1 -1
- package/dist/config/debug.d.ts.map +1 -1
- package/dist/config/hooks-report.d.ts +3 -1
- package/dist/config/hooks-report.d.ts.map +1 -1
- package/dist/config/load.d.ts +37 -0
- package/dist/config/load.d.ts.map +1 -1
- package/dist/config/schema.d.ts +15 -2
- package/dist/config/schema.d.ts.map +1 -1
- package/dist/config/settings-descriptors.d.ts +4 -0
- package/dist/config/settings-descriptors.d.ts.map +1 -1
- package/dist/config/turn-duration-default.d.ts +6 -0
- package/dist/config/turn-duration-default.d.ts.map +1 -0
- package/dist/context/doctrine.d.ts.map +1 -1
- package/dist/context/environment.d.ts +18 -0
- package/dist/context/environment.d.ts.map +1 -1
- package/dist/context/file-placement.d.ts.map +1 -1
- package/dist/context/project-tracker.d.ts +3 -0
- package/dist/context/project-tracker.d.ts.map +1 -1
- package/dist/context/system-prompt.d.ts +6 -0
- package/dist/context/system-prompt.d.ts.map +1 -1
- package/dist/index.js +39 -39
- package/dist/integrations/auto-update/apply.d.ts +1 -1
- package/dist/integrations/auto-update/apply.d.ts.map +1 -1
- package/dist/integrations/auto-update/policy.d.ts +1 -1
- package/dist/integrations/auto-update/policy.d.ts.map +1 -1
- package/dist/integrations/auto-update/state.d.ts +1 -1
- package/dist/integrations/auto-update/state.d.ts.map +1 -1
- package/dist/integrations/mcp/project-file.d.ts +16 -0
- package/dist/integrations/mcp/project-file.d.ts.map +1 -0
- package/dist/integrations/mcp/serve.d.ts +55 -0
- package/dist/integrations/mcp/serve.d.ts.map +1 -0
- package/dist/integrations/mcp/servers.d.ts +6 -0
- package/dist/integrations/mcp/servers.d.ts.map +1 -1
- package/dist/integrations/mcp/shared-file.d.ts +2 -1
- package/dist/integrations/mcp/shared-file.d.ts.map +1 -1
- package/dist/integrations/network/controller.d.ts.map +1 -1
- package/dist/integrations/network/format.d.ts.map +1 -1
- package/dist/integrations/network/runtime.d.ts +7 -0
- package/dist/integrations/network/runtime.d.ts.map +1 -1
- package/dist/integrations/network/types.d.ts +2 -0
- package/dist/integrations/network/types.d.ts.map +1 -1
- package/dist/integrations/npm-global.d.ts +2 -2
- package/dist/integrations/npm-global.d.ts.map +1 -1
- package/dist/integrations/outstanding/status.d.ts +4 -0
- package/dist/integrations/outstanding/status.d.ts.map +1 -1
- package/dist/integrations/providers/connections.d.ts +1 -1
- package/dist/integrations/providers/connections.d.ts.map +1 -1
- package/dist/integrations/providers/pending-login.d.ts +1 -1
- package/dist/integrations/providers/subscription-login.d.ts +1 -1
- package/dist/integrations/sessions/session-watch.d.ts +8 -1
- package/dist/integrations/sessions/session-watch.d.ts.map +1 -1
- package/dist/integrations/state/purge.d.ts +66 -0
- package/dist/integrations/state/purge.d.ts.map +1 -0
- package/dist/integrations/subagents/activity.d.ts +1 -1
- package/dist/integrations/subagents/agent-names.d.ts +1 -1
- package/dist/integrations/subagents/row-labels.d.ts +18 -0
- package/dist/integrations/subagents/row-labels.d.ts.map +1 -0
- package/dist/integrations/subagents/runtime.d.ts +8 -1
- package/dist/integrations/subagents/runtime.d.ts.map +1 -1
- package/dist/integrations/subagents/stop-guidance.d.ts +14 -0
- package/dist/integrations/subagents/stop-guidance.d.ts.map +1 -0
- package/dist/integrations/web/open-url.d.ts +1 -1
- package/dist/integrations/web/search.d.ts +1 -1
- package/dist/integrations/workflows/host.d.ts.map +1 -1
- package/dist/integrations/workflows/notice.d.ts +9 -0
- package/dist/integrations/workflows/notice.d.ts.map +1 -1
- package/dist/integrations/workflows/offering.d.ts +3 -2
- package/dist/integrations/workflows/offering.d.ts.map +1 -1
- package/dist/integrations/workflows/orphans.d.ts +17 -0
- package/dist/integrations/workflows/orphans.d.ts.map +1 -1
- package/dist/integrations/workflows/owners.d.ts +17 -0
- package/dist/integrations/workflows/owners.d.ts.map +1 -0
- package/dist/integrations/workflows/registry.d.ts +17 -2
- package/dist/integrations/workflows/registry.d.ts.map +1 -1
- package/dist/logging.d.ts +10 -1
- package/dist/logging.d.ts.map +1 -1
- package/dist/memory/screen-archive.d.ts +2 -0
- package/dist/memory/screen-archive.d.ts.map +1 -1
- package/dist/permissions/auto-classifier.d.ts.map +1 -1
- package/dist/permissions/launch.d.ts +1 -1
- package/dist/permissions/mode.d.ts +2 -2
- package/dist/permissions/path-rules.d.ts.map +1 -1
- package/dist/permissions/rules.d.ts +2 -0
- package/dist/permissions/rules.d.ts.map +1 -1
- package/dist/permissions/tool-flags.d.ts +5 -1
- package/dist/permissions/tool-flags.d.ts.map +1 -1
- package/dist/reminders/changed-files.d.ts.map +1 -1
- package/dist/reminders/frame.d.ts +1 -1
- package/dist/reminders/frame.d.ts.map +1 -1
- package/dist/reminders/hypermode.d.ts.map +1 -1
- package/dist/reminders/index.d.ts +3 -0
- package/dist/reminders/index.d.ts.map +1 -1
- package/dist/reminders/memory-nudge.d.ts +20 -0
- package/dist/reminders/memory-nudge.d.ts.map +1 -0
- package/dist/rounds/types.d.ts +6 -1
- package/dist/rounds/types.d.ts.map +1 -1
- package/dist/schedule/commands/add.d.ts.map +1 -1
- package/dist/schedule/fire/fire.d.ts +1 -1
- package/dist/schedule/fire/fire.d.ts.map +1 -1
- package/dist/tui/AgentExplorer.d.ts +11 -8
- package/dist/tui/AgentExplorer.d.ts.map +1 -1
- package/dist/tui/App.d.ts +2 -0
- package/dist/tui/App.d.ts.map +1 -1
- package/dist/tui/ChoicePicker.d.ts +7 -1
- package/dist/tui/ChoicePicker.d.ts.map +1 -1
- package/dist/tui/Composer.d.ts +1 -7
- package/dist/tui/Composer.d.ts.map +1 -1
- package/dist/tui/PendingInputPanel.d.ts +2 -0
- package/dist/tui/PendingInputPanel.d.ts.map +1 -1
- package/dist/tui/StatusBar.d.ts +8 -1
- package/dist/tui/StatusBar.d.ts.map +1 -1
- package/dist/tui/agent-calls.d.ts.map +1 -1
- package/dist/tui/agent-transcript-rows.d.ts +6 -1
- package/dist/tui/agent-transcript-rows.d.ts.map +1 -1
- package/dist/tui/agent.d.ts +61 -6
- package/dist/tui/agent.d.ts.map +1 -1
- package/dist/tui/choice-selection.d.ts +3 -1
- package/dist/tui/choice-selection.d.ts.map +1 -1
- package/dist/tui/computer-use-live.d.ts +41 -0
- package/dist/tui/computer-use-live.d.ts.map +1 -0
- package/dist/tui/context-grid.d.ts +5 -0
- package/dist/tui/context-grid.d.ts.map +1 -1
- package/dist/tui/fullscreen/FullscreenTranscript.d.ts +3 -2
- package/dist/tui/fullscreen/FullscreenTranscript.d.ts.map +1 -1
- package/dist/tui/keypad-keys.d.ts +1 -1
- package/dist/tui/keypad-keys.d.ts.map +1 -1
- package/dist/tui/launch-settings.d.ts +2 -0
- package/dist/tui/launch-settings.d.ts.map +1 -1
- package/dist/tui/login-prompt.d.ts +1 -1
- package/dist/tui/notice-display.d.ts +8 -0
- package/dist/tui/notice-display.d.ts.map +1 -0
- package/dist/tui/outcome-line.d.ts.map +1 -1
- package/dist/tui/plain-interruption.d.ts +7 -0
- package/dist/tui/plain-interruption.d.ts.map +1 -1
- package/dist/tui/restored-rows.d.ts +2 -0
- package/dist/tui/restored-rows.d.ts.map +1 -1
- package/dist/tui/sign-in-watch.d.ts +31 -0
- package/dist/tui/sign-in-watch.d.ts.map +1 -0
- package/dist/tui/slashCommands.d.ts +11 -0
- package/dist/tui/slashCommands.d.ts.map +1 -1
- package/dist/tui/stopped-turn-line.d.ts +22 -0
- package/dist/tui/stopped-turn-line.d.ts.map +1 -0
- package/dist/tui/tidy-tool-output.d.ts.map +1 -1
- package/dist/tui/tool-presentation.d.ts +2 -0
- package/dist/tui/tool-presentation.d.ts.map +1 -1
- package/dist/tui/turn-duration-setting.d.ts +11 -0
- package/dist/tui/turn-duration-setting.d.ts.map +1 -0
- package/dist/tui/turn-interruption.d.ts +1 -1
- package/dist/tui/turn-interruption.d.ts.map +1 -1
- package/dist/tui/types.d.ts +13 -1
- package/dist/tui/types.d.ts.map +1 -1
- package/dist/tui/untrusted-display.d.ts +12 -0
- package/dist/tui/untrusted-display.d.ts.map +1 -0
- package/dist/tui/web-activity.d.ts +4 -2
- package/dist/tui/web-activity.d.ts.map +1 -1
- package/dist/usage-error.d.ts.map +1 -1
- package/package.json +5 -5
- package/skills/document/SKILL.md +22 -11
- package/skills/verify-change/SKILL.md +2 -1
- package/dist/chunks/acp-KBPTK4GN.js.map +0 -6
- package/dist/chunks/activity-command-JOED2VWN.js.map +0 -6
- package/dist/chunks/add-66AQ7SKZ.js.map +0 -6
- package/dist/chunks/agent-session-KQIXHDGU.js +0 -87
- package/dist/chunks/archive-ED4CWEU2.js.map +0 -6
- package/dist/chunks/browser-7DRWOIEZ.js +0 -31
- package/dist/chunks/browser-7DRWOIEZ.js.map +0 -6
- package/dist/chunks/chat-ISFH5CPZ.js.map +0 -6
- package/dist/chunks/chunk-2TU3QQRG.js.map +0 -6
- package/dist/chunks/chunk-3ZHOM2L7.js.map +0 -6
- package/dist/chunks/chunk-5TJZWGTZ.js.map +0 -6
- package/dist/chunks/chunk-6F3M3P3W.js.map +0 -6
- package/dist/chunks/chunk-AFNHI46Y.js.map +0 -6
- package/dist/chunks/chunk-AWU5MYX3.js.map +0 -6
- package/dist/chunks/chunk-BFYETM56.js.map +0 -6
- package/dist/chunks/chunk-GBOOHDIH.js +0 -94
- package/dist/chunks/chunk-GBOOHDIH.js.map +0 -6
- package/dist/chunks/chunk-GWH6BOVE.js.map +0 -6
- package/dist/chunks/chunk-ICQYIDIR.js.map +0 -6
- package/dist/chunks/chunk-KE53UTUG.js.map +0 -6
- package/dist/chunks/chunk-LMPUBX5R.js.map +0 -6
- package/dist/chunks/chunk-PHDA4JI7.js.map +0 -6
- package/dist/chunks/chunk-QF2FZ2DM.js.map +0 -6
- package/dist/chunks/chunk-QF4HGWRL.js.map +0 -6
- package/dist/chunks/chunk-QUI2ZAGY.js.map +0 -6
- package/dist/chunks/chunk-RF6EIDPV.js.map +0 -6
- package/dist/chunks/chunk-T3VMBZEY.js.map +0 -6
- package/dist/chunks/chunk-VFB4ZUOR.js.map +0 -6
- package/dist/chunks/chunk-X7QC2Q7P.js.map +0 -6
- package/dist/chunks/chunk-XYF26ZUO.js.map +0 -6
- package/dist/chunks/cli-runtime-2HOSJR5Y.js.map +0 -6
- package/dist/chunks/computer-FQRWTC6M.js.map +0 -6
- package/dist/chunks/config-2JST7BZT.js.map +0 -6
- package/dist/chunks/dist-PYOYSQIZ.js.map +0 -6
- package/dist/chunks/exec-Z6TIWDJM.js.map +0 -6
- package/dist/chunks/github-X352BD5R.js.map +0 -6
- package/dist/chunks/host-queries-NVNPXLV6.js +0 -38
- package/dist/chunks/login-QDMS62PW.js +0 -38
- package/dist/chunks/mcp-VCZRILZ2.js.map +0 -6
- package/dist/chunks/message-command-RN3TYTUE.js.map +0 -6
- package/dist/chunks/operator-tools-4FKDVXEJ.js.map +0 -6
- package/dist/chunks/pal-N4BQKNXH.js.map +0 -6
- package/dist/chunks/peers-3QJCXMVT.js.map +0 -6
- package/dist/chunks/plugin-SJ3Y2P53.js.map +0 -6
- package/dist/chunks/providers-6HCMKQUI.js.map +0 -6
- package/dist/chunks/resume-URQRK5DV.js +0 -26
- package/dist/chunks/schedule-36SDQUHA.js.map +0 -6
- package/dist/chunks/send-person-YWJEDJLC.js +0 -31
- package/dist/chunks/service-2KVKUVPK.js.map +0 -6
- package/dist/chunks/skills-ROGIKQBK.js.map +0 -6
- package/dist/chunks/state-EK4XKBK5.js.map +0 -6
- package/dist/chunks/store-NX2MC2JN.js.map +0 -6
- package/dist/chunks/tui-DT36PST5.js.map +0 -6
- package/dist/chunks/watch-AFI4NLCR.js.map +0 -6
- package/dist/chunks/workspaces-QKVXLISC.js.map +0 -6
- package/dist/chunks/worktree-NWJLCB5C.js.map +0 -6
- package/dist/commands/upgrade-progress.d.ts.map +0 -1
- package/dist/commands/upgrade.d.ts.map +0 -1
- /package/dist/chunks/{agent-DL7YTL5B.js.map → agent-MSSMOEBP.js.map} +0 -0
- /package/dist/chunks/{agent-session-KQIXHDGU.js.map → agent-session-VCB6HX3E.js.map} +0 -0
- /package/dist/chunks/{bin-main-JDJ6LEOK.js.map → bin-main-2E6XD7MQ.js.map} +0 -0
- /package/dist/chunks/{binding-NU3G3EBQ.js.map → binding-NAPEU62B.js.map} +0 -0
- /package/dist/chunks/{chunk-C4CUPDOU.js.map → chunk-27ICMJVV.js.map} +0 -0
- /package/dist/chunks/{chunk-6XIPTDOH.js.map → chunk-2D5WW5KP.js.map} +0 -0
- /package/dist/chunks/{chunk-K3NVHXN7.js.map → chunk-2J2Z6S3V.js.map} +0 -0
- /package/dist/chunks/{chunk-G3WCIRCZ.js.map → chunk-2PRVGX6U.js.map} +0 -0
- /package/dist/chunks/{chunk-K5FGK5AP.js.map → chunk-32CPPPKX.js.map} +0 -0
- /package/dist/chunks/{chunk-ETDOSJF7.js.map → chunk-3SBROSVS.js.map} +0 -0
- /package/dist/chunks/{chunk-ZT3DLJQZ.js.map → chunk-3ZL6YBMT.js.map} +0 -0
- /package/dist/chunks/{chunk-C534SIJI.js.map → chunk-4RCXY7WO.js.map} +0 -0
- /package/dist/chunks/{chunk-NQ3MZ6N4.js.map → chunk-4YQJ262B.js.map} +0 -0
- /package/dist/chunks/{chunk-WEL6L6DN.js.map → chunk-52DZTN4C.js.map} +0 -0
- /package/dist/chunks/{chunk-MTSXDMJB.js.map → chunk-5GI7W4SM.js.map} +0 -0
- /package/dist/chunks/{chunk-I7WXDTCF.js.map → chunk-5NIQMCRF.js.map} +0 -0
- /package/dist/chunks/{chunk-JOORBY5L.js.map → chunk-5WS5Q2KW.js.map} +0 -0
- /package/dist/chunks/{chunk-7EL5RPEU.js.map → chunk-66DFXMZG.js.map} +0 -0
- /package/dist/chunks/{chunk-6SEDSZBH.js.map → chunk-6MMKNZYL.js.map} +0 -0
- /package/dist/chunks/{chunk-Y3KKZ7HS.js.map → chunk-6QQVZXUE.js.map} +0 -0
- /package/dist/chunks/{chunk-X2JFYB5A.js.map → chunk-6RBEIDSC.js.map} +0 -0
- /package/dist/chunks/{chunk-IRCAPHCE.js.map → chunk-6V4VYVRZ.js.map} +0 -0
- /package/dist/chunks/{chunk-QJYK566B.js.map → chunk-6ZWEKSAV.js.map} +0 -0
- /package/dist/chunks/{chunk-F7ECENUK.js.map → chunk-7BSLOLTU.js.map} +0 -0
- /package/dist/chunks/{chunk-TOADRNOV.js.map → chunk-7BXJPOEG.js.map} +0 -0
- /package/dist/chunks/{chunk-BFTAE67C.js.map → chunk-7DERK6IR.js.map} +0 -0
- /package/dist/chunks/{chunk-4KGXEARZ.js.map → chunk-7EASTT3H.js.map} +0 -0
- /package/dist/chunks/{chunk-5PTXGBPL.js.map → chunk-7MYLYFIV.js.map} +0 -0
- /package/dist/chunks/{chunk-KOVWQARO.js.map → chunk-7NAHUZAR.js.map} +0 -0
- /package/dist/chunks/{chunk-GQU3OUV5.js.map → chunk-7NQLCFYX.js.map} +0 -0
- /package/dist/chunks/{chunk-JRIDJW3W.js.map → chunk-A5O5VTQM.js.map} +0 -0
- /package/dist/chunks/{chunk-JB3UZ7JJ.js.map → chunk-BATWKQWV.js.map} +0 -0
- /package/dist/chunks/{chunk-6JAWZGSH.js.map → chunk-CK47DTW6.js.map} +0 -0
- /package/dist/chunks/{chunk-P7UV5M73.js.map → chunk-CSO7BHDJ.js.map} +0 -0
- /package/dist/chunks/{chunk-ECDMJNZU.js.map → chunk-D42SQGEO.js.map} +0 -0
- /package/dist/chunks/{chunk-DYCSVG2K.js.map → chunk-DIBXZBOP.js.map} +0 -0
- /package/dist/chunks/{chunk-CJUK4IWQ.js.map → chunk-EFWF72V4.js.map} +0 -0
- /package/dist/chunks/{chunk-A4I24ISL.js.map → chunk-ENNAZGUX.js.map} +0 -0
- /package/dist/chunks/{chunk-5GRTRQTV.js.map → chunk-EOLXS2ZV.js.map} +0 -0
- /package/dist/chunks/{chunk-YBAPUTER.js.map → chunk-F6NUMURW.js.map} +0 -0
- /package/dist/chunks/{chunk-ZFQOF5A5.js.map → chunk-FZPIEOFR.js.map} +0 -0
- /package/dist/chunks/{chunk-372SLS6Y.js.map → chunk-G7UGGWOR.js.map} +0 -0
- /package/dist/chunks/{chunk-4PX62LQ2.js.map → chunk-GLZJBFDO.js.map} +0 -0
- /package/dist/chunks/{chunk-QERO7OI6.js.map → chunk-HBGRWJU5.js.map} +0 -0
- /package/dist/chunks/{chunk-BQR2C4RM.js.map → chunk-HICZARAY.js.map} +0 -0
- /package/dist/chunks/{chunk-HQFAVCTF.js.map → chunk-HONSYTUC.js.map} +0 -0
- /package/dist/chunks/{chunk-X4W4DN3S.js.map → chunk-I5BNXO63.js.map} +0 -0
- /package/dist/chunks/{chunk-DID4WFOD.js.map → chunk-IH2JBJ6I.js.map} +0 -0
- /package/dist/chunks/{chunk-5X4XLHLF.js.map → chunk-J4GPHTRN.js.map} +0 -0
- /package/dist/chunks/{chunk-I5CWCNRN.js.map → chunk-JFA2XPTW.js.map} +0 -0
- /package/dist/chunks/{chunk-IT2OFHF7.js.map → chunk-JSY23B3Q.js.map} +0 -0
- /package/dist/chunks/{chunk-U77GVCK3.js.map → chunk-K5VLCRHY.js.map} +0 -0
- /package/dist/chunks/{chunk-7AXLZKTB.js.map → chunk-KCBOIL5Q.js.map} +0 -0
- /package/dist/chunks/{chunk-QW3Y3RDE.js.map → chunk-MJ32RCFZ.js.map} +0 -0
- /package/dist/chunks/{chunk-WIO3JRB5.js.map → chunk-NBJ4OTXL.js.map} +0 -0
- /package/dist/chunks/{chunk-66ZXPQGB.js.map → chunk-NO3F3QQ3.js.map} +0 -0
- /package/dist/chunks/{chunk-LJDAHRWI.js.map → chunk-NQYOMRPT.js.map} +0 -0
- /package/dist/chunks/{chunk-WXCJTJK4.js.map → chunk-O6C4RETO.js.map} +0 -0
- /package/dist/chunks/{chunk-W5TYUJI5.js.map → chunk-O6EDUJ77.js.map} +0 -0
- /package/dist/chunks/{chunk-F7LHGSEQ.js.map → chunk-OD2PMTXS.js.map} +0 -0
- /package/dist/chunks/{chunk-5LDYBGOZ.js.map → chunk-OGEOUETU.js.map} +0 -0
- /package/dist/chunks/{chunk-MI6WMBDQ.js.map → chunk-PYTTGYZS.js.map} +0 -0
- /package/dist/chunks/{chunk-U2MFIQ6X.js.map → chunk-RR7FS6SQ.js.map} +0 -0
- /package/dist/chunks/{chunk-7O2WNQQZ.js.map → chunk-RTMX7IDM.js.map} +0 -0
- /package/dist/chunks/{chunk-ZAPPY4VF.js.map → chunk-S4OEUN6F.js.map} +0 -0
- /package/dist/chunks/{chunk-EXE7JBHE.js.map → chunk-SEVORRUA.js.map} +0 -0
- /package/dist/chunks/{chunk-WCPKRDGR.js.map → chunk-TAIC3PC2.js.map} +0 -0
- /package/dist/chunks/{chunk-AF4ILHID.js.map → chunk-TGLXWW5B.js.map} +0 -0
- /package/dist/chunks/{chunk-4YN7VGLV.js.map → chunk-TJAUF5NX.js.map} +0 -0
- /package/dist/chunks/{chunk-E7RD32NX.js.map → chunk-TSU4F6DF.js.map} +0 -0
- /package/dist/chunks/{chunk-MPIYLDWJ.js.map → chunk-TXMWKHYW.js.map} +0 -0
- /package/dist/chunks/{chunk-PYR7VRWF.js.map → chunk-UBGDYBSQ.js.map} +0 -0
- /package/dist/chunks/{chunk-73VS7EXG.js.map → chunk-ULFR2FWA.js.map} +0 -0
- /package/dist/chunks/{chunk-HXW5DQLU.js.map → chunk-UMPJ4VXN.js.map} +0 -0
- /package/dist/chunks/{chunk-MN426ZWA.js.map → chunk-URZPVSHV.js.map} +0 -0
- /package/dist/chunks/{chunk-7WDKN3QG.js.map → chunk-UXLQNJDR.js.map} +0 -0
- /package/dist/chunks/{chunk-SQ32S3OE.js.map → chunk-XWP64X6U.js.map} +0 -0
- /package/dist/chunks/{chunk-YQOT7ABG.js.map → chunk-Y3NC6RIL.js.map} +0 -0
- /package/dist/chunks/{commands-TKD5BHAC.js.map → commands-VWBRELWZ.js.map} +0 -0
- /package/dist/chunks/{cost-AZAQ3AC5.js.map → cost-IVLAFD5T.js.map} +0 -0
- /package/dist/chunks/{crash-report-IYMUJRDT.js.map → crash-report-CA3Y7LA6.js.map} +0 -0
- /package/dist/chunks/{dist-5JRS362B.js.map → dist-3SGAVJFN.js.map} +0 -0
- /package/dist/chunks/{dist-S4GG5BOF.js.map → dist-7BSYEFE5.js.map} +0 -0
- /package/dist/chunks/{dist-SPKR3SBF.js.map → dist-AM6FWCIJ.js.map} +0 -0
- /package/dist/chunks/{dist-YGZEZT7E.js.map → dist-ISRJEZRF.js.map} +0 -0
- /package/dist/chunks/{dist-BECOVIWQ.js.map → dist-PBFZXU4L.js.map} +0 -0
- /package/dist/chunks/{dist-VQGHI5SR.js.map → dist-RDXEBTCL.js.map} +0 -0
- /package/dist/chunks/{dist-NLY5ZLEK.js.map → dist-V43PPTPF.js.map} +0 -0
- /package/dist/chunks/{doctor-MYN7YCXB.js.map → doctor-FGOCO7UR.js.map} +0 -0
- /package/dist/chunks/{drain-IEZMA72M.js.map → drain-A3DLR5A4.js.map} +0 -0
- /package/dist/chunks/{entry-SS5QYOOM.js.map → entry-4LHTI3VQ.js.map} +0 -0
- /package/dist/chunks/{extension-4SMB7XQP.js.map → extension-BP7Q3PFK.js.map} +0 -0
- /package/dist/chunks/{home-YYLBZ3E7.js.map → home-GR6YDAAE.js.map} +0 -0
- /package/dist/chunks/{hooks-KVCP7AHB.js.map → hooks-KSSNBDF2.js.map} +0 -0
- /package/dist/chunks/{hooks-report-7BAQ5FJD.js.map → hooks-report-H4JAHJXE.js.map} +0 -0
- /package/dist/chunks/{host-CAZNAKUM.js.map → host-ISKJDJ7B.js.map} +0 -0
- /package/dist/chunks/{host-queries-NVNPXLV6.js.map → host-queries-CUG75GYD.js.map} +0 -0
- /package/dist/chunks/{installed-list-X7D2METU.js.map → installed-list-GPVOP4E3.js.map} +0 -0
- /package/dist/chunks/{learn-BSA4OH3O.js.map → learn-AFNJQGOU.js.map} +0 -0
- /package/dist/chunks/{learn-builtin-YIJE4KDM.js.map → learn-builtin-LUD6XO6W.js.map} +0 -0
- /package/dist/chunks/{lifecycle-4CCVUYHX.js.map → lifecycle-TCRMEVJP.js.map} +0 -0
- /package/dist/chunks/{list-Y365NWT5.js.map → list-4OJNF5N2.js.map} +0 -0
- /package/dist/chunks/{live-3URICZBD.js.map → live-LJ76XHPK.js.map} +0 -0
- /package/dist/chunks/{load-LXAWOITU.js.map → load-2ERMTCD4.js.map} +0 -0
- /package/dist/chunks/{logs-OGG4QEIR.js.map → logs-DV6GC7PT.js.map} +0 -0
- /package/dist/chunks/{login-QDMS62PW.js.map → open-3VUS3XWX.js.map} +0 -0
- /package/dist/chunks/{open-S3T2QSFD.js.map → output-schema-2GHHC5ZZ.js.map} +0 -0
- /package/dist/chunks/{output-schema-JZS2DYJS.js.map → peers-SLFOET3O.js.map} +0 -0
- /package/dist/chunks/{peers-B46EOYXB.js.map → providers-SOFGNZ4F.js.map} +0 -0
- /package/dist/chunks/{providers-AAGYOW7X.js.map → pty-3T7AE7ZA.js.map} +0 -0
- /package/dist/chunks/{pty-Y6DQ3O7S.js.map → resume-5JACRBQO.js.map} +0 -0
- /package/dist/chunks/{resume-URQRK5DV.js.map → resume-command-H4FOREZO.js.map} +0 -0
- /package/dist/chunks/{resume-command-GPX3ZFJG.js.map → running-NONPWC5C.js.map} +0 -0
- /package/dist/chunks/{running-XXZFJXM2.js.map → send-H27WTBLZ.js.map} +0 -0
- /package/dist/chunks/{send-3I5I445I.js.map → send-person-NNGL2U4H.js.map} +0 -0
- /package/dist/chunks/{serve-CZDHGDZL.js.map → serve-4VIDXLEB.js.map} +0 -0
- /package/dist/chunks/{send-person-YWJEDJLC.js.map → setting-cli-ETVPDSRA.js.map} +0 -0
- /package/dist/chunks/{setting-cli-BIG2WZWH.js.map → start-check-A5FG7224.js.map} +0 -0
- /package/dist/chunks/{startup-failure-Y6OKFLWB.js.map → startup-failure-6MZNIJXI.js.map} +0 -0
- /package/dist/chunks/{start-check-WZ3L3FAC.js.map → store-4PPSKMYT.js.map} +0 -0
- /package/dist/chunks/{store-A6ZRPCAB.js.map → store-5K5HIPUT.js.map} +0 -0
- /package/dist/chunks/{store-FLT5PL3C.js.map → store-6WG6CRWK.js.map} +0 -0
- /package/dist/chunks/{store-IOOFZ6PN.js.map → store-UPAOLS5B.js.map} +0 -0
|
@@ -2,39 +2,49 @@ import { createRequire as __namzuCreateRequire } from 'node:module';
|
|
|
2
2
|
const require = __namzuCreateRequire(import.meta.url);
|
|
3
3
|
import {
|
|
4
4
|
openWorktreeHookRuntime
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-PYTTGYZS.js";
|
|
6
6
|
import {
|
|
7
7
|
NAMZU_COMPACT_WORDMARK,
|
|
8
8
|
NAMZU_WORDMARK,
|
|
9
9
|
NAMZU_WORDMARK_MIN_WIDTH
|
|
10
10
|
} from "./chunk-27R3OTVS.js";
|
|
11
|
+
import {
|
|
12
|
+
appendPromptHistory,
|
|
13
|
+
loggedPromptsOf,
|
|
14
|
+
pastedTextsOf,
|
|
15
|
+
promptHistoryEnabled,
|
|
16
|
+
promptHistoryEntryFor,
|
|
17
|
+
promptHistorySkipped,
|
|
18
|
+
readPromptHistory,
|
|
19
|
+
recallPromptHistory,
|
|
20
|
+
rewritePromptHistory,
|
|
21
|
+
seedPromptHistory,
|
|
22
|
+
trimPromptHistory
|
|
23
|
+
} from "./chunk-P6RYPNSD.js";
|
|
11
24
|
import {
|
|
12
25
|
changesBlock,
|
|
13
26
|
changesSinceConfirmed,
|
|
14
27
|
confirmationView,
|
|
15
28
|
describeChanges,
|
|
16
29
|
permissionsChanged
|
|
17
|
-
} from "./chunk-
|
|
30
|
+
} from "./chunk-4RCXY7WO.js";
|
|
18
31
|
import {
|
|
19
32
|
visibleScheduleMessage
|
|
20
33
|
} from "./chunk-NADQQMMG.js";
|
|
21
34
|
import {
|
|
22
35
|
selectDesktopBackend
|
|
23
|
-
} from "./chunk-
|
|
36
|
+
} from "./chunk-CSO7BHDJ.js";
|
|
24
37
|
import {
|
|
25
38
|
hooksOf
|
|
26
|
-
} from "./chunk-
|
|
27
|
-
import {
|
|
28
|
-
applyProviderFlags
|
|
29
|
-
} from "./chunk-LMPUBX5R.js";
|
|
39
|
+
} from "./chunk-NQYOMRPT.js";
|
|
30
40
|
import {
|
|
31
41
|
settleAnsweredPark
|
|
32
|
-
} from "./chunk-
|
|
42
|
+
} from "./chunk-DIBXZBOP.js";
|
|
33
43
|
import {
|
|
34
44
|
DELIVERY_READ_LIMIT,
|
|
35
45
|
readSourceDeliveryPage,
|
|
36
46
|
takeSuppressedCount
|
|
37
|
-
} from "./chunk-
|
|
47
|
+
} from "./chunk-HGOU2QRN.js";
|
|
38
48
|
import {
|
|
39
49
|
DEFAULT_MAX_ITERATIONS,
|
|
40
50
|
DEFAULT_TIMEOUT_MS,
|
|
@@ -45,7 +55,7 @@ import {
|
|
|
45
55
|
editedJob,
|
|
46
56
|
previewLines,
|
|
47
57
|
runsPerDay
|
|
48
|
-
} from "./chunk-
|
|
58
|
+
} from "./chunk-EOLXS2ZV.js";
|
|
49
59
|
import {
|
|
50
60
|
callsCount
|
|
51
61
|
} from "./chunk-OG2MLME3.js";
|
|
@@ -54,13 +64,13 @@ import {
|
|
|
54
64
|
gateRefusal,
|
|
55
65
|
scriptShellUnavailableReason,
|
|
56
66
|
verifyScheduledScript
|
|
57
|
-
} from "./chunk-
|
|
67
|
+
} from "./chunk-EFWF72V4.js";
|
|
58
68
|
import {
|
|
59
69
|
allowsCommands,
|
|
60
70
|
compileJobPolicy,
|
|
61
71
|
compileScriptCheckPolicy,
|
|
62
72
|
isPresetName
|
|
63
|
-
} from "./chunk-
|
|
73
|
+
} from "./chunk-3ZL6YBMT.js";
|
|
64
74
|
import {
|
|
65
75
|
callEndpoint,
|
|
66
76
|
readEndpoint
|
|
@@ -74,20 +84,23 @@ import {
|
|
|
74
84
|
hasAcknowledgedBypass,
|
|
75
85
|
hasSeenAutoModeDefaultNotice,
|
|
76
86
|
markAutoModeDefaultNoticeSeen
|
|
77
|
-
} from "./chunk-
|
|
87
|
+
} from "./chunk-6QQVZXUE.js";
|
|
78
88
|
import {
|
|
79
89
|
applyFallbackFlag
|
|
80
90
|
} from "./chunk-RL2CTUF2.js";
|
|
91
|
+
import {
|
|
92
|
+
applyProviderFlags
|
|
93
|
+
} from "./chunk-YEWJVAM4.js";
|
|
81
94
|
import {
|
|
82
95
|
parkedRunWords,
|
|
83
96
|
resumeCommand
|
|
84
|
-
} from "./chunk-
|
|
97
|
+
} from "./chunk-TSU4F6DF.js";
|
|
85
98
|
import {
|
|
86
99
|
appendHistory,
|
|
87
100
|
nextFireOf,
|
|
88
101
|
readHistory,
|
|
89
102
|
readState
|
|
90
|
-
} from "./chunk-
|
|
103
|
+
} from "./chunk-7EASTT3H.js";
|
|
91
104
|
import {
|
|
92
105
|
PERSON_ONLY_OPS,
|
|
93
106
|
controlDispatch,
|
|
@@ -105,7 +118,7 @@ import {
|
|
|
105
118
|
renderPeersScreen,
|
|
106
119
|
startControlServer,
|
|
107
120
|
writeControlInfo
|
|
108
|
-
} from "./chunk-
|
|
121
|
+
} from "./chunk-7LCU5IKH.js";
|
|
109
122
|
import {
|
|
110
123
|
CLIPBOARD_KILL_SWITCH,
|
|
111
124
|
ClickCounter,
|
|
@@ -118,7 +131,7 @@ import {
|
|
|
118
131
|
orderRange,
|
|
119
132
|
snapRange,
|
|
120
133
|
wordAt
|
|
121
|
-
} from "./chunk-
|
|
134
|
+
} from "./chunk-RTMX7IDM.js";
|
|
122
135
|
import {
|
|
123
136
|
buildPeerTools,
|
|
124
137
|
openLivePeers,
|
|
@@ -126,7 +139,7 @@ import {
|
|
|
126
139
|
peerMailMessage,
|
|
127
140
|
resolvePeerRuntime,
|
|
128
141
|
runsUnderAny
|
|
129
|
-
} from "./chunk-
|
|
142
|
+
} from "./chunk-OD2PMTXS.js";
|
|
130
143
|
import {
|
|
131
144
|
AUTO_CHOICE_ID,
|
|
132
145
|
PR_NONE,
|
|
@@ -147,13 +160,13 @@ import {
|
|
|
147
160
|
sharedExtensionHost,
|
|
148
161
|
withAutoChoice,
|
|
149
162
|
writeConversationExport
|
|
150
|
-
} from "./chunk-
|
|
163
|
+
} from "./chunk-2PRVGX6U.js";
|
|
151
164
|
import {
|
|
152
165
|
tuiPalDefinition,
|
|
153
166
|
tuiPalEnvironment,
|
|
154
167
|
tuiPalOwner,
|
|
155
168
|
tuiPalPreferences
|
|
156
|
-
} from "./chunk-
|
|
169
|
+
} from "./chunk-CK47DTW6.js";
|
|
157
170
|
import {
|
|
158
171
|
isModelOnlyContext,
|
|
159
172
|
runtimeContextRowLabel
|
|
@@ -165,10 +178,10 @@ import {
|
|
|
165
178
|
handedBackLines,
|
|
166
179
|
hypermodeRefusal,
|
|
167
180
|
outcomeNotice
|
|
168
|
-
} from "./chunk-
|
|
181
|
+
} from "./chunk-MX3U5TBQ.js";
|
|
169
182
|
import {
|
|
170
183
|
defaultStartMode
|
|
171
|
-
} from "./chunk-
|
|
184
|
+
} from "./chunk-ULFR2FWA.js";
|
|
172
185
|
import {
|
|
173
186
|
COMMAND_ROW_INDENT,
|
|
174
187
|
COMPACTED_HINT,
|
|
@@ -259,17 +272,18 @@ import {
|
|
|
259
272
|
webCallTitle,
|
|
260
273
|
webLiveStatus,
|
|
261
274
|
webSettledLine,
|
|
262
|
-
withDebugDetail
|
|
263
|
-
|
|
275
|
+
withDebugDetail,
|
|
276
|
+
withoutUntrustedFrames
|
|
277
|
+
} from "./chunk-774DAIPO.js";
|
|
264
278
|
import {
|
|
265
279
|
openManagedWorktrees,
|
|
266
280
|
worktreeOpenHint
|
|
267
|
-
} from "./chunk-
|
|
281
|
+
} from "./chunk-J4GPHTRN.js";
|
|
268
282
|
import {
|
|
269
283
|
MCP_OUTPUT_CHARS,
|
|
270
284
|
boundedMcpText,
|
|
271
285
|
validatePromptArguments
|
|
272
|
-
} from "./chunk-
|
|
286
|
+
} from "./chunk-ZDMI3JSL.js";
|
|
273
287
|
import {
|
|
274
288
|
completionNotice,
|
|
275
289
|
countAgents,
|
|
@@ -279,13 +293,13 @@ import {
|
|
|
279
293
|
resumeCallText,
|
|
280
294
|
resumeReviewLines,
|
|
281
295
|
runTokens
|
|
282
|
-
} from "./chunk-
|
|
296
|
+
} from "./chunk-MJJA277Z.js";
|
|
283
297
|
import {
|
|
284
298
|
openInBrowser
|
|
285
|
-
} from "./chunk-
|
|
299
|
+
} from "./chunk-I5BNXO63.js";
|
|
286
300
|
import {
|
|
287
301
|
describeBrowserStatus
|
|
288
|
-
} from "./chunk-
|
|
302
|
+
} from "./chunk-ADLNBLRA.js";
|
|
289
303
|
import {
|
|
290
304
|
MAY_BE_LIMITED_WINDOW_MS,
|
|
291
305
|
accountProductName,
|
|
@@ -297,19 +311,19 @@ import {
|
|
|
297
311
|
import {
|
|
298
312
|
beginSubscriptionLogin,
|
|
299
313
|
parsePastedInput
|
|
300
|
-
} from "./chunk-
|
|
314
|
+
} from "./chunk-KCBOIL5Q.js";
|
|
301
315
|
import {
|
|
302
316
|
API_KEY_ACCOUNT_PROVIDERS,
|
|
303
317
|
openCliAccounts,
|
|
304
318
|
storedAccountSignedIn
|
|
305
|
-
} from "./chunk-
|
|
319
|
+
} from "./chunk-JFA2XPTW.js";
|
|
306
320
|
import {
|
|
307
321
|
beginCodexDeviceLogin
|
|
308
|
-
} from "./chunk-
|
|
322
|
+
} from "./chunk-32CPPPKX.js";
|
|
309
323
|
import {
|
|
310
324
|
claimPalConversation,
|
|
311
325
|
listPalConversations
|
|
312
|
-
} from "./chunk-
|
|
326
|
+
} from "./chunk-UXLQNJDR.js";
|
|
313
327
|
import {
|
|
314
328
|
ConversationIndexRefreshError,
|
|
315
329
|
activeConversationTurn,
|
|
@@ -340,7 +354,6 @@ import {
|
|
|
340
354
|
matchesPullRequestFilter,
|
|
341
355
|
noteAttachmentNumber,
|
|
342
356
|
numberAttachments,
|
|
343
|
-
openConversationLog,
|
|
344
357
|
openSessions,
|
|
345
358
|
pasteChip,
|
|
346
359
|
pullRequestLabel,
|
|
@@ -361,15 +374,15 @@ import {
|
|
|
361
374
|
unarchiveConversation,
|
|
362
375
|
unchipPastedRanges,
|
|
363
376
|
widenOverChips
|
|
364
|
-
} from "./chunk-
|
|
377
|
+
} from "./chunk-KIWLK2WZ.js";
|
|
365
378
|
import {
|
|
366
379
|
bindAccount,
|
|
367
380
|
findAccountByName,
|
|
368
381
|
isDefaultAccountId
|
|
369
|
-
} from "./chunk-
|
|
382
|
+
} from "./chunk-6V4VYVRZ.js";
|
|
370
383
|
import {
|
|
371
384
|
startAutoUpdate
|
|
372
|
-
} from "./chunk-
|
|
385
|
+
} from "./chunk-LM2OGSW5.js";
|
|
373
386
|
import {
|
|
374
387
|
readManifest
|
|
375
388
|
} from "./chunk-AK2U3N2A.js";
|
|
@@ -489,15 +502,16 @@ import {
|
|
|
489
502
|
use_window_size_default,
|
|
490
503
|
waitedOnBlock,
|
|
491
504
|
workflowAgentProgress,
|
|
505
|
+
workflowAgentTotal,
|
|
492
506
|
workflowNotice,
|
|
493
507
|
wroteBy,
|
|
494
508
|
wroteLineText,
|
|
495
509
|
wroteOf,
|
|
496
510
|
wroteRailText
|
|
497
|
-
} from "./chunk-
|
|
511
|
+
} from "./chunk-LRUY5C6H.js";
|
|
498
512
|
import {
|
|
499
513
|
discoverUserCommands
|
|
500
|
-
} from "./chunk-
|
|
514
|
+
} from "./chunk-MJ32RCFZ.js";
|
|
501
515
|
import {
|
|
502
516
|
describeAllCredentialsLogout,
|
|
503
517
|
describeApiKeyLogout,
|
|
@@ -508,7 +522,7 @@ import {
|
|
|
508
522
|
} from "./chunk-MDK4RMBQ.js";
|
|
509
523
|
import {
|
|
510
524
|
resolveNpmInvocation
|
|
511
|
-
} from "./chunk-
|
|
525
|
+
} from "./chunk-FJG7JN4W.js";
|
|
512
526
|
import {
|
|
513
527
|
capChoiceLines,
|
|
514
528
|
choiceDisplayText,
|
|
@@ -548,7 +562,7 @@ import {
|
|
|
548
562
|
describeCacheLifetime,
|
|
549
563
|
promptCacheTtl,
|
|
550
564
|
providerOffersCacheLifetime
|
|
551
|
-
} from "./chunk-
|
|
565
|
+
} from "./chunk-OGEOUETU.js";
|
|
552
566
|
import {
|
|
553
567
|
CLICK_EXPAND_HINT,
|
|
554
568
|
CLICK_FOLD_HINT,
|
|
@@ -584,13 +598,13 @@ import {
|
|
|
584
598
|
sandboxRunsShellUnasked,
|
|
585
599
|
settledElapsed,
|
|
586
600
|
withoutCdToCwd
|
|
587
|
-
} from "./chunk-
|
|
601
|
+
} from "./chunk-TL535OCL.js";
|
|
588
602
|
import {
|
|
589
603
|
describePlainInterruption,
|
|
590
604
|
describeProviderWait,
|
|
591
605
|
isSelfMending,
|
|
592
606
|
isSpentAllowance
|
|
593
|
-
} from "./chunk-
|
|
607
|
+
} from "./chunk-JX6O7Y55.js";
|
|
594
608
|
import {
|
|
595
609
|
debugRequested
|
|
596
610
|
} from "./chunk-GNBMKISG.js";
|
|
@@ -602,14 +616,14 @@ import {
|
|
|
602
616
|
handoffContinuationNote,
|
|
603
617
|
refusalDetail,
|
|
604
618
|
retryAfterMs
|
|
605
|
-
} from "./chunk-
|
|
619
|
+
} from "./chunk-WEPINZBQ.js";
|
|
606
620
|
import {
|
|
607
621
|
autoAvailable,
|
|
608
622
|
nextCycleMode,
|
|
609
623
|
permissionModeDescription,
|
|
610
624
|
permissionModeLabel,
|
|
611
625
|
permissionModeName
|
|
612
|
-
} from "./chunk-
|
|
626
|
+
} from "./chunk-4YQJ262B.js";
|
|
613
627
|
import {
|
|
614
628
|
paint,
|
|
615
629
|
rowTints,
|
|
@@ -618,18 +632,18 @@ import {
|
|
|
618
632
|
} from "./chunk-P65AXQPL.js";
|
|
619
633
|
import {
|
|
620
634
|
discoverAgentDefinitions
|
|
621
|
-
} from "./chunk-
|
|
635
|
+
} from "./chunk-7NQLCFYX.js";
|
|
622
636
|
import {
|
|
623
637
|
readAgentHooks
|
|
624
|
-
} from "./chunk-
|
|
638
|
+
} from "./chunk-HONSYTUC.js";
|
|
625
639
|
import {
|
|
626
640
|
readSkillHooks,
|
|
627
641
|
withoutSessionStart
|
|
628
|
-
} from "./chunk-
|
|
642
|
+
} from "./chunk-TGLXWW5B.js";
|
|
629
643
|
import {
|
|
630
644
|
primaryProvider,
|
|
631
645
|
writePreferences
|
|
632
|
-
} from "./chunk-
|
|
646
|
+
} from "./chunk-NO3F3QQ3.js";
|
|
633
647
|
import {
|
|
634
648
|
apiKeyLogoutWord,
|
|
635
649
|
automaticChoice,
|
|
@@ -640,7 +654,7 @@ import {
|
|
|
640
654
|
hasApiCredential,
|
|
641
655
|
isApiKeyLogoutTarget,
|
|
642
656
|
signedInSubscriptionProviders
|
|
643
|
-
} from "./chunk-
|
|
657
|
+
} from "./chunk-TJAUF5NX.js";
|
|
644
658
|
import {
|
|
645
659
|
isAnthropicOAuthToken
|
|
646
660
|
} from "./chunk-LPPFJYL6.js";
|
|
@@ -651,26 +665,27 @@ import {
|
|
|
651
665
|
loadSkillBody,
|
|
652
666
|
renderSkillRoster,
|
|
653
667
|
skillTierLabel
|
|
654
|
-
} from "./chunk-
|
|
668
|
+
} from "./chunk-RR7FS6SQ.js";
|
|
655
669
|
import {
|
|
656
670
|
isTrusted,
|
|
657
671
|
isTrustedAtStateRoot,
|
|
658
672
|
startNewTrustList,
|
|
659
673
|
trustDir,
|
|
660
674
|
trustListProblem
|
|
661
|
-
} from "./chunk-
|
|
675
|
+
} from "./chunk-27ICMJVV.js";
|
|
662
676
|
import {
|
|
663
677
|
expandTabs,
|
|
664
678
|
scriptText,
|
|
665
679
|
terminalDisplayText
|
|
666
680
|
} from "./chunk-I4GTRFPK.js";
|
|
667
681
|
import {
|
|
682
|
+
DEFAULT_SHOW_TURN_DURATION,
|
|
668
683
|
getScreenModeNow
|
|
669
|
-
} from "./chunk-
|
|
684
|
+
} from "./chunk-5COLG33E.js";
|
|
670
685
|
import {
|
|
671
686
|
deleteUserConfigValue,
|
|
672
687
|
setUserConfigValue
|
|
673
|
-
} from "./chunk-
|
|
688
|
+
} from "./chunk-7BXJPOEG.js";
|
|
674
689
|
import {
|
|
675
690
|
COMPOSER_TRIGGER_DEFAULTS,
|
|
676
691
|
COMPOSER_TRIGGER_IDS,
|
|
@@ -706,11 +721,11 @@ import {
|
|
|
706
721
|
verdictOf,
|
|
707
722
|
withWorkflowKeywordSwitch,
|
|
708
723
|
writeConnection
|
|
709
|
-
} from "./chunk-
|
|
724
|
+
} from "./chunk-ESHAWCBR.js";
|
|
710
725
|
import {
|
|
711
726
|
PROJECT_MCP_FILE,
|
|
712
727
|
parseMcpServerFile
|
|
713
|
-
} from "./chunk-
|
|
728
|
+
} from "./chunk-7YC42EXB.js";
|
|
714
729
|
import {
|
|
715
730
|
displayPath,
|
|
716
731
|
formatSize,
|
|
@@ -748,15 +763,17 @@ import {
|
|
|
748
763
|
restrictToOwner,
|
|
749
764
|
writeStoredApiKey,
|
|
750
765
|
writeStoredGeminiApiKey
|
|
751
|
-
} from "./chunk-
|
|
766
|
+
} from "./chunk-GLZJBFDO.js";
|
|
752
767
|
import {
|
|
753
768
|
namzuHomePath
|
|
754
|
-
} from "./chunk-
|
|
769
|
+
} from "./chunk-K5VLCRHY.js";
|
|
755
770
|
import {
|
|
756
771
|
stringWidth
|
|
757
772
|
} from "./chunk-U5UV2YRE.js";
|
|
758
773
|
import {
|
|
759
774
|
ACCEPT_EDITS_TOOLS,
|
|
775
|
+
AUTO_REVIEW_BLOCKED_PREFIX,
|
|
776
|
+
AUTO_REVIEW_UNAVAILABLE_PREFIX,
|
|
760
777
|
AccountRegistryError,
|
|
761
778
|
AuthorizationGate,
|
|
762
779
|
CompactionRefusedError,
|
|
@@ -771,7 +788,6 @@ import {
|
|
|
771
788
|
HAND_BACK_RECEIPT,
|
|
772
789
|
HAND_BACK_TOOL_NAME,
|
|
773
790
|
HostCommandRegistry,
|
|
774
|
-
LOG_SECRET_PATTERNS,
|
|
775
791
|
MONITOR_TOOL_NAME,
|
|
776
792
|
NOOP_LOGGER,
|
|
777
793
|
PEER_PROTOCOL_VERSION,
|
|
@@ -816,6 +832,7 @@ import {
|
|
|
816
832
|
isEntityId,
|
|
817
833
|
isLeaseLive,
|
|
818
834
|
isPeerRecordLive,
|
|
835
|
+
isReviewRefusalResult,
|
|
819
836
|
kernelHostCommands,
|
|
820
837
|
mustAskPerson,
|
|
821
838
|
newPasteNonce,
|
|
@@ -841,7 +858,6 @@ import {
|
|
|
841
858
|
sanitizeName,
|
|
842
859
|
sanitizeRole,
|
|
843
860
|
sessionDisplayName,
|
|
844
|
-
startedBySession,
|
|
845
861
|
sweepPrivateTempRoot,
|
|
846
862
|
systemClock,
|
|
847
863
|
turnContextEntries,
|
|
@@ -852,7 +868,7 @@ import {
|
|
|
852
868
|
withAccountLock,
|
|
853
869
|
wrapUntrusted,
|
|
854
870
|
writePeerRecord
|
|
855
|
-
} from "./chunk-
|
|
871
|
+
} from "./chunk-L5FCGDB7.js";
|
|
856
872
|
import {
|
|
857
873
|
__name,
|
|
858
874
|
__toESM
|
|
@@ -1420,8 +1436,8 @@ __name(entryFor, "entryFor");
|
|
|
1420
1436
|
function continuation(source, read) {
|
|
1421
1437
|
if (read.stopped) return STOPPED;
|
|
1422
1438
|
if (read.atRest) return "";
|
|
1423
|
-
const
|
|
1424
|
-
return
|
|
1439
|
+
const open = source.slice(read.start).join("\n");
|
|
1440
|
+
return open.length > OPEN_LIMIT ? STOPPED : open;
|
|
1425
1441
|
}
|
|
1426
1442
|
__name(continuation, "continuation");
|
|
1427
1443
|
function colourLines(word, lines3, flow = NO_FLOW) {
|
|
@@ -2349,7 +2365,7 @@ __name(useTerminalFocused, "useTerminalFocused");
|
|
|
2349
2365
|
// src/tui/App.tsx
|
|
2350
2366
|
import { existsSync as existsSync4, rmSync as rmSync2 } from "node:fs";
|
|
2351
2367
|
import { homedir } from "node:os";
|
|
2352
|
-
import { join as
|
|
2368
|
+
import { join as join18, relative as relative5, resolve as resolve9 } from "node:path";
|
|
2353
2369
|
var import_react30 = __toESM(require_react(), 1);
|
|
2354
2370
|
|
|
2355
2371
|
// src/integrations/network/runtime.ts
|
|
@@ -2430,12 +2446,13 @@ function createNetworkController(options) {
|
|
|
2430
2446
|
}
|
|
2431
2447
|
}
|
|
2432
2448
|
});
|
|
2433
|
-
const joinView = /* @__PURE__ */ __name((
|
|
2434
|
-
requestId:
|
|
2435
|
-
|
|
2436
|
-
|
|
2437
|
-
|
|
2438
|
-
|
|
2449
|
+
const joinView = /* @__PURE__ */ __name((join19, trustOffer) => ({
|
|
2450
|
+
requestId: join19.requestId,
|
|
2451
|
+
...join19.joinerMachineId ? { machineId: join19.joinerMachineId } : {},
|
|
2452
|
+
name: join19.name,
|
|
2453
|
+
code: formatJoinCode(join19.code),
|
|
2454
|
+
sourceAddr: join19.sourceAddr,
|
|
2455
|
+
expiresAt: join19.expiresAt,
|
|
2439
2456
|
...trustOffer ? { trustOffer } : {}
|
|
2440
2457
|
}), "joinView");
|
|
2441
2458
|
const networkView = /* @__PURE__ */ __name((n) => ({
|
|
@@ -2443,8 +2460,8 @@ function createNetworkController(options) {
|
|
|
2443
2460
|
name: n.name,
|
|
2444
2461
|
trustedAt: n.trustedAt
|
|
2445
2462
|
}), "networkView");
|
|
2446
|
-
const offerFor = /* @__PURE__ */ __name(async (
|
|
2447
|
-
const ref = await service.networkOf(
|
|
2463
|
+
const offerFor = /* @__PURE__ */ __name(async (join19) => {
|
|
2464
|
+
const ref = await service.networkOf(join19.sourceAddr).catch(() => void 0);
|
|
2448
2465
|
return ref && !ref.trusted ? { suggestedName: ref.suggestedName } : void 0;
|
|
2449
2466
|
}, "offerFor");
|
|
2450
2467
|
const findMachine = /* @__PURE__ */ __name((query) => {
|
|
@@ -2508,7 +2525,7 @@ function createNetworkController(options) {
|
|
|
2508
2525
|
nearbyNetworks: status.nearbyNetworks,
|
|
2509
2526
|
nearby: service.nearbyNetworks().map((n) => ({ ...n })),
|
|
2510
2527
|
joinRequests: await Promise.all(
|
|
2511
|
-
service.pendingJoins().map(async (
|
|
2528
|
+
service.pendingJoins().map(async (join19) => joinView(join19, await offerFor(join19)))
|
|
2512
2529
|
),
|
|
2513
2530
|
autoJoined: [...autoJoined],
|
|
2514
2531
|
trustedNetworks: (await service.trustedNetworks()).map(networkView),
|
|
@@ -2928,6 +2945,8 @@ function createNetworkRuntime(options) {
|
|
|
2928
2945
|
let previous;
|
|
2929
2946
|
let previousMachines;
|
|
2930
2947
|
const seenOutcomes = /* @__PURE__ */ new Set();
|
|
2948
|
+
const announcedJoiners = /* @__PURE__ */ new Set();
|
|
2949
|
+
let reportedJoinCount;
|
|
2931
2950
|
const pid = options.pid ?? process.pid;
|
|
2932
2951
|
const current = /* @__PURE__ */ __name(() => controller ?? client, "current");
|
|
2933
2952
|
async function stopLeading() {
|
|
@@ -3038,12 +3057,20 @@ function createNetworkRuntime(options) {
|
|
|
3038
3057
|
}
|
|
3039
3058
|
const before = previous;
|
|
3040
3059
|
previous = now;
|
|
3041
|
-
const
|
|
3042
|
-
|
|
3043
|
-
|
|
3044
|
-
|
|
3045
|
-
|
|
3046
|
-
|
|
3060
|
+
const waiting = now.joinRequests.length;
|
|
3061
|
+
if (waiting !== reportedJoinCount) {
|
|
3062
|
+
reportedJoinCount = waiting;
|
|
3063
|
+
options.onJoinRequests?.(waiting);
|
|
3064
|
+
}
|
|
3065
|
+
for (const join19 of now.joinRequests) {
|
|
3066
|
+
const who = join19.machineId ?? `${join19.name}@${join19.sourceAddr}`;
|
|
3067
|
+
if (announcedJoiners.has(who)) continue;
|
|
3068
|
+
announcedJoiners.add(who);
|
|
3069
|
+
const text = `${join19.name} wants to join your Namzu network. /peers to allow or deny.`;
|
|
3070
|
+
if (options.notice) options.notice(`network-join:${who}`, text);
|
|
3071
|
+
else options.notify(text);
|
|
3072
|
+
}
|
|
3073
|
+
if (announcedJoiners.size > 256) announcedJoiners.clear();
|
|
3047
3074
|
const ref = options.ownRef?.();
|
|
3048
3075
|
const autoBefore = new Set(before?.autoJoined.map((j) => `${j.machineId}:${j.at}`));
|
|
3049
3076
|
for (const joined of now.autoJoined)
|
|
@@ -4709,7 +4736,7 @@ async function probeHarnesses(detected, cwd, signal) {
|
|
|
4709
4736
|
version: result.code === 0 ? versionFromProbe(result.output) ?? "" : "",
|
|
4710
4737
|
checked: result.code === 0 || result.missing,
|
|
4711
4738
|
raw: result.output,
|
|
4712
|
-
access: harness.provider === "zen" && provider !== void 0 && !hasApiCredential(provider.entry, provider.apiKey) ? "Zen free models \xB7 experimental, and Zen may refuse them" : source ? describeAccess(source) : harness.id === "claude" ? "Not signed in for Namzu \xB7 run namzu login claude" : "Not connected \xB7 sign in or add an API key"
|
|
4739
|
+
access: harness.provider === "zen" && provider !== void 0 && !hasApiCredential(provider.entry, provider.apiKey) ? "Zen free models \xB7 experimental, and Zen may refuse them" : source ? describeAccess(source) : harness.id === "claude" ? "Not signed in for Namzu \xB7 run namzu auth login claude" : "Not connected \xB7 sign in or add an API key"
|
|
4713
4740
|
};
|
|
4714
4741
|
})
|
|
4715
4742
|
);
|
|
@@ -5593,25 +5620,25 @@ __name(gridLayout, "gridLayout");
|
|
|
5593
5620
|
function columnWidths(want, least, room) {
|
|
5594
5621
|
if (want.reduce((a, b) => a + b, 0) <= room) return [...want];
|
|
5595
5622
|
const widths = want.map(() => 0);
|
|
5596
|
-
let
|
|
5623
|
+
let open = want.map((_, c) => c);
|
|
5597
5624
|
let remaining = room;
|
|
5598
5625
|
for (; ; ) {
|
|
5599
|
-
const share2 = Math.floor(remaining / Math.max(1,
|
|
5600
|
-
const settled2 =
|
|
5601
|
-
if (settled2.length === 0 || settled2.length ===
|
|
5626
|
+
const share2 = Math.floor(remaining / Math.max(1, open.length));
|
|
5627
|
+
const settled2 = open.filter((c) => (want[c] ?? 0) <= share2);
|
|
5628
|
+
if (settled2.length === 0 || settled2.length === open.length) break;
|
|
5602
5629
|
for (const c of settled2) {
|
|
5603
5630
|
widths[c] = want[c] ?? 0;
|
|
5604
5631
|
remaining -= want[c] ?? 0;
|
|
5605
5632
|
}
|
|
5606
|
-
|
|
5633
|
+
open = open.filter((c) => !settled2.includes(c));
|
|
5607
5634
|
}
|
|
5608
|
-
const floor =
|
|
5635
|
+
const floor = open.map((c) => Math.min(least[c] ?? 1, want[c] ?? 1));
|
|
5609
5636
|
const floorTotal = floor.reduce((a, b) => a + b, 0);
|
|
5610
5637
|
if (floorTotal > remaining) return void 0;
|
|
5611
5638
|
const spare = remaining - floorTotal;
|
|
5612
|
-
const extra =
|
|
5639
|
+
const extra = open.map((c, i) => (want[c] ?? 0) - (floor[i] ?? 0));
|
|
5613
5640
|
const extraTotal = extra.reduce((a, b) => a + b, 0);
|
|
5614
|
-
|
|
5641
|
+
open.forEach((c, i) => {
|
|
5615
5642
|
widths[c] = (floor[i] ?? 0) + (extraTotal === 0 ? 0 : Math.floor(spare * (extra[i] ?? 0) / extraTotal));
|
|
5616
5643
|
});
|
|
5617
5644
|
let left = room - widths.reduce((a, b) => a + b, 0);
|
|
@@ -5690,7 +5717,7 @@ function Markdown({
|
|
|
5690
5717
|
text,
|
|
5691
5718
|
color = theme.text.primary,
|
|
5692
5719
|
hyperlinks = false,
|
|
5693
|
-
join:
|
|
5720
|
+
join: join19 = "block",
|
|
5694
5721
|
lang,
|
|
5695
5722
|
fence,
|
|
5696
5723
|
lead = null,
|
|
@@ -5699,9 +5726,9 @@ function Markdown({
|
|
|
5699
5726
|
const cache = (0, import_react3.useRef)(void 0);
|
|
5700
5727
|
cache.current ??= createBlockCache();
|
|
5701
5728
|
const shown = terminalDisplayText(text);
|
|
5702
|
-
const source =
|
|
5729
|
+
const source = join19 === "code" ? `${fence ?? `\`\`\`${lang ?? ""}`}
|
|
5703
5730
|
${shown}` : shown;
|
|
5704
|
-
const blocks = cache.current.parse(source,
|
|
5731
|
+
const blocks = cache.current.parse(source, join19 === "text" ? "text" : void 0);
|
|
5705
5732
|
const width = useContentWidth();
|
|
5706
5733
|
return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
5707
5734
|
BlockList,
|
|
@@ -5710,7 +5737,7 @@ ${shown}` : shown;
|
|
|
5710
5737
|
color,
|
|
5711
5738
|
hyperlinks,
|
|
5712
5739
|
width,
|
|
5713
|
-
lead:
|
|
5740
|
+
lead: join19 === "block" ? lead : "join",
|
|
5714
5741
|
flow
|
|
5715
5742
|
}
|
|
5716
5743
|
);
|
|
@@ -6276,6 +6303,10 @@ var KNOWN_TOOL_ADVICE = {
|
|
|
6276
6303
|
saves: 0.4
|
|
6277
6304
|
}
|
|
6278
6305
|
};
|
|
6306
|
+
function windowGuessLine(windowTokens) {
|
|
6307
|
+
return `The window for this model is a guess (${formatTokens(windowTokens)} tokens). Set the real one with compaction.contextWindowTokens in your settings.`;
|
|
6308
|
+
}
|
|
6309
|
+
__name(windowGuessLine, "windowGuessLine");
|
|
6279
6310
|
function buildContextView(input) {
|
|
6280
6311
|
const { breakdown } = input;
|
|
6281
6312
|
const window = breakdown.windowTokens;
|
|
@@ -6292,7 +6323,7 @@ function buildContextView(input) {
|
|
|
6292
6323
|
value: `${formatTokens(window)} tokens (you set ${formatTokens(input.windowRequested)}; the model's own window is the cap)`
|
|
6293
6324
|
} : input.autoCompact && input.windowSource !== "auto" ? {
|
|
6294
6325
|
label: "Auto-compact window: ",
|
|
6295
|
-
value: input.windowSource === "default" ? `${formatTokens(window)} tokens (
|
|
6326
|
+
value: input.windowSource === "default" ? `${formatTokens(window)} tokens (a guess: this model's window is not known; set compaction.contextWindowTokens)` : `${formatTokens(window)} tokens`
|
|
6296
6327
|
} : void 0;
|
|
6297
6328
|
const cells = buildGridCells(breakdown.categories, window, input.terminalColumns);
|
|
6298
6329
|
const legend = buildLegend(breakdown);
|
|
@@ -6837,7 +6868,7 @@ function freezeMore(content, printed, ctx) {
|
|
|
6837
6868
|
if (!codeReady(tail2, ranges, final, state, ctx.code)) break;
|
|
6838
6869
|
const r = ranges[final];
|
|
6839
6870
|
const cut3 = r.end + 1;
|
|
6840
|
-
const
|
|
6871
|
+
const open = "none";
|
|
6841
6872
|
const lang = state.join === "code" ? state.lang : void 0;
|
|
6842
6873
|
const fence = state.join === "code" ? state.fence : void 0;
|
|
6843
6874
|
chunks = [
|
|
@@ -6849,7 +6880,7 @@ function freezeMore(content, printed, ctx) {
|
|
|
6849
6880
|
...lang !== void 0 ? { lang } : {},
|
|
6850
6881
|
...fence !== void 0 ? { fence } : {},
|
|
6851
6882
|
last: TYPE_OF[r.kind],
|
|
6852
|
-
open
|
|
6883
|
+
open
|
|
6853
6884
|
},
|
|
6854
6885
|
state,
|
|
6855
6886
|
ctx.code
|
|
@@ -8084,9 +8115,9 @@ function trimUrl(raw) {
|
|
|
8084
8115
|
continue;
|
|
8085
8116
|
}
|
|
8086
8117
|
const pairs = { ")": "(", "]": "[", "}": "{", ">": "<" };
|
|
8087
|
-
const
|
|
8088
|
-
if (
|
|
8089
|
-
const opens = url.split(
|
|
8118
|
+
const open = pairs[last];
|
|
8119
|
+
if (open !== void 0) {
|
|
8120
|
+
const opens = url.split(open).length - 1;
|
|
8090
8121
|
const closes = url.split(last).length - 1;
|
|
8091
8122
|
if (closes > opens) {
|
|
8092
8123
|
url = url.slice(0, -1);
|
|
@@ -9530,14 +9561,14 @@ function hungRows(rows, body, markColor) {
|
|
|
9530
9561
|
});
|
|
9531
9562
|
}
|
|
9532
9563
|
__name(hungRows, "hungRows");
|
|
9533
|
-
function clickableRows(message, hasPrev, width,
|
|
9564
|
+
function clickableRows(message, hasPrev, width, open) {
|
|
9534
9565
|
if (message.role !== "tool" && message.role !== "system") return null;
|
|
9535
9566
|
const fit2 = hangsResult(message) ? Math.max(4, width - RESULT_HANG) : width;
|
|
9536
9567
|
const closed = messageScrollRows(message, hasPrev, fit2, { hint: CLICK_EXPAND_HINT });
|
|
9537
9568
|
if (!closed.hinted) return null;
|
|
9538
|
-
const shown =
|
|
9539
|
-
const hint =
|
|
9540
|
-
const plain2 =
|
|
9569
|
+
const shown = open ? openedMessage(message) : message;
|
|
9570
|
+
const hint = open ? void 0 : CLICK_EXPAND_HINT;
|
|
9571
|
+
const plain2 = open ? messageScrollRows(shown, hasPrev, fit2) : closed;
|
|
9541
9572
|
const text = scrollBodyText(shown, hint, fit2);
|
|
9542
9573
|
const body = wrapChoiceText(text, fit2).length;
|
|
9543
9574
|
const joins = wrapJoiners(
|
|
@@ -9549,7 +9580,7 @@ function clickableRows(message, hasPrev, width, open2) {
|
|
|
9549
9580
|
return {
|
|
9550
9581
|
gap: plain2.gap ? plainRow(plain2.gap) : null,
|
|
9551
9582
|
rows: laid.map((own2, i) => {
|
|
9552
|
-
const answers = i < body || !
|
|
9583
|
+
const answers = i < body || !open && (plain2.rows[i]?.command === true || plain2.rows[i]?.hint === true);
|
|
9553
9584
|
return answers ? { ...own2, opens: true } : own2;
|
|
9554
9585
|
})
|
|
9555
9586
|
};
|
|
@@ -10033,8 +10064,8 @@ function FullscreenTranscript({
|
|
|
10033
10064
|
const cache = (0, import_react6.useRef)(createLayoutCache()).current;
|
|
10034
10065
|
const epoch = useThemeEpoch();
|
|
10035
10066
|
const click = subscribePointer !== void 0;
|
|
10036
|
-
const [
|
|
10037
|
-
const openRef = (0, import_react6.useRef)(
|
|
10067
|
+
const [open, setOpen] = (0, import_react6.useState)(() => /* @__PURE__ */ new Set());
|
|
10068
|
+
const openRef = (0, import_react6.useRef)(open);
|
|
10038
10069
|
const [view, setView] = (0, import_react6.useState)(FOLLOWING);
|
|
10039
10070
|
const away = (0, import_react6.useRef)(null);
|
|
10040
10071
|
const markRef = (0, import_react6.useRef)(null);
|
|
@@ -10057,20 +10088,20 @@ function FullscreenTranscript({
|
|
|
10057
10088
|
pendingAt,
|
|
10058
10089
|
columns,
|
|
10059
10090
|
cache,
|
|
10060
|
-
{ click, open
|
|
10091
|
+
{ click, open, detailed },
|
|
10061
10092
|
mark
|
|
10062
10093
|
),
|
|
10063
|
-
[messages, pending, pendingAt, columns, cache, epoch, click,
|
|
10094
|
+
[messages, pending, pendingAt, columns, cache, epoch, click, open, detailed, mark]
|
|
10064
10095
|
);
|
|
10065
10096
|
(0, import_react6.useEffect)(() => {
|
|
10066
|
-
if (
|
|
10097
|
+
if (open.size === 0) return;
|
|
10067
10098
|
const present = new Set(index.ids);
|
|
10068
|
-
const kept = [...
|
|
10069
|
-
if (kept.length ===
|
|
10099
|
+
const kept = [...open].filter((id) => present.has(id));
|
|
10100
|
+
if (kept.length === open.size) return;
|
|
10070
10101
|
const next = new Set(kept);
|
|
10071
10102
|
openRef.current = next;
|
|
10072
10103
|
setOpen(next);
|
|
10073
|
-
}, [
|
|
10104
|
+
}, [open, index]);
|
|
10074
10105
|
const boxRef = (0, import_react6.useRef)(null);
|
|
10075
10106
|
const headerBox = (0, import_react6.useRef)(null);
|
|
10076
10107
|
const boxHeight = (0, import_react6.useRef)(maxRows);
|
|
@@ -10217,11 +10248,12 @@ function FullscreenTranscript({
|
|
|
10217
10248
|
(dragging) => {
|
|
10218
10249
|
const { rows: now } = latest.current;
|
|
10219
10250
|
const text = selectedText(now, textWidth, dragging.selection);
|
|
10220
|
-
if (text.trim() === "" || !copy) return;
|
|
10251
|
+
if (text.trim() === "" || !copy) return false;
|
|
10221
10252
|
updateSelection({ ...dragging, copied: true });
|
|
10222
10253
|
void copy(text).then((report) => {
|
|
10223
10254
|
if (report) showNote(report);
|
|
10224
10255
|
});
|
|
10256
|
+
return true;
|
|
10225
10257
|
},
|
|
10226
10258
|
[copy, showNote, textWidth, updateSelection]
|
|
10227
10259
|
);
|
|
@@ -10446,23 +10478,27 @@ function FullscreenTranscript({
|
|
|
10446
10478
|
}, "takeEscape"),
|
|
10447
10479
|
takeCopy: /* @__PURE__ */ __name(() => {
|
|
10448
10480
|
const current = selectionRef.current;
|
|
10449
|
-
if (
|
|
10450
|
-
if (current.copied)
|
|
10451
|
-
|
|
10452
|
-
|
|
10481
|
+
if (!current?.moved || current.pressing) return false;
|
|
10482
|
+
if (current.copied) {
|
|
10483
|
+
updateSelection(null);
|
|
10484
|
+
return true;
|
|
10485
|
+
}
|
|
10486
|
+
if (copySelection(current)) return true;
|
|
10487
|
+
updateSelection(null);
|
|
10488
|
+
return false;
|
|
10453
10489
|
}, "takeCopy")
|
|
10454
10490
|
};
|
|
10455
10491
|
return () => {
|
|
10456
10492
|
control.current = null;
|
|
10457
10493
|
};
|
|
10458
|
-
}, [control, scroll, closeSearch, updateSelection,
|
|
10494
|
+
}, [control, scroll, closeSearch, updateSelection, copySelection]);
|
|
10459
10495
|
(0, import_react6.useEffect)(() => {
|
|
10460
10496
|
if (!keysActive && searchRef.current) closeSearch();
|
|
10461
10497
|
}, [keysActive, closeSearch]);
|
|
10462
10498
|
use_input_default(
|
|
10463
10499
|
(input, key) => {
|
|
10464
|
-
const
|
|
10465
|
-
if (
|
|
10500
|
+
const open2 = searchRef.current;
|
|
10501
|
+
if (open2) {
|
|
10466
10502
|
if (key.pageUp) {
|
|
10467
10503
|
scroll("page-up");
|
|
10468
10504
|
return;
|
|
@@ -10471,22 +10507,22 @@ function FullscreenTranscript({
|
|
|
10471
10507
|
scroll("page-down");
|
|
10472
10508
|
return;
|
|
10473
10509
|
}
|
|
10474
|
-
if (
|
|
10475
|
-
if (input === "/") updateSearch({ ...
|
|
10510
|
+
if (open2.browsing) {
|
|
10511
|
+
if (input === "/") updateSearch({ ...open2, browsing: false });
|
|
10476
10512
|
else if (input === "n" || input === "N") {
|
|
10477
|
-
const found = findMatches(latest.current.rows,
|
|
10513
|
+
const found = findMatches(latest.current.rows, open2.query);
|
|
10478
10514
|
const was = found.findIndex(
|
|
10479
|
-
(m) => m.row ===
|
|
10515
|
+
(m) => m.row === open2.cursor?.row && m.from === open2.cursor?.from
|
|
10480
10516
|
);
|
|
10481
10517
|
const to2 = found[stepMatch(found.length, was, input === "n" ? 1 : -1)];
|
|
10482
10518
|
if (to2) {
|
|
10483
|
-
updateSearch({ ...
|
|
10519
|
+
updateSearch({ ...open2, cursor: { row: to2.row, from: to2.from } });
|
|
10484
10520
|
goTo(to2);
|
|
10485
10521
|
}
|
|
10486
10522
|
}
|
|
10487
10523
|
return;
|
|
10488
10524
|
}
|
|
10489
|
-
const edit = editSearch(
|
|
10525
|
+
const edit = editSearch(open2.query, input, key);
|
|
10490
10526
|
const { rows: now, synced: state, index: at } = latest.current;
|
|
10491
10527
|
if (edit.kind === "query") {
|
|
10492
10528
|
const found = findMatches(now, edit.query);
|
|
@@ -10496,26 +10532,26 @@ function FullscreenTranscript({
|
|
|
10496
10532
|
cursor: first ? { row: first.row, from: first.from } : null
|
|
10497
10533
|
});
|
|
10498
10534
|
goTo(first);
|
|
10499
|
-
} else if (detailed && edit.kind === "next" &&
|
|
10500
|
-
const found = findMatches(now,
|
|
10535
|
+
} else if (detailed && edit.kind === "next" && open2.query.length > 0) {
|
|
10536
|
+
const found = findMatches(now, open2.query);
|
|
10501
10537
|
const current = found.findIndex(
|
|
10502
|
-
(m) => m.row ===
|
|
10538
|
+
(m) => m.row === open2.cursor?.row && m.from === open2.cursor?.from
|
|
10503
10539
|
);
|
|
10504
10540
|
const to2 = found[current >= 0 ? current : startMatch(found, bottomRow(state, at))];
|
|
10505
10541
|
updateSearch({
|
|
10506
|
-
...
|
|
10542
|
+
...open2,
|
|
10507
10543
|
browsing: true,
|
|
10508
|
-
cursor: to2 ? { row: to2.row, from: to2.from } :
|
|
10544
|
+
cursor: to2 ? { row: to2.row, from: to2.from } : open2.cursor
|
|
10509
10545
|
});
|
|
10510
10546
|
goTo(to2);
|
|
10511
10547
|
} else if (edit.kind === "next" || edit.kind === "previous") {
|
|
10512
|
-
const found = findMatches(now,
|
|
10548
|
+
const found = findMatches(now, open2.query);
|
|
10513
10549
|
const was = found.findIndex(
|
|
10514
|
-
(m) => m.row ===
|
|
10550
|
+
(m) => m.row === open2.cursor?.row && m.from === open2.cursor?.from
|
|
10515
10551
|
);
|
|
10516
10552
|
const to2 = found[stepMatch(found.length, was, edit.kind === "next" ? 1 : -1)];
|
|
10517
10553
|
if (to2) {
|
|
10518
|
-
updateSearch({ ...
|
|
10554
|
+
updateSearch({ ...open2, cursor: { row: to2.row, from: to2.from } });
|
|
10519
10555
|
goTo(to2);
|
|
10520
10556
|
}
|
|
10521
10557
|
}
|
|
@@ -10727,7 +10763,7 @@ function DetailedScreen({
|
|
|
10727
10763
|
detailed: true,
|
|
10728
10764
|
top: 2,
|
|
10729
10765
|
control,
|
|
10730
|
-
onSearchChange: (
|
|
10766
|
+
onSearchChange: (open, typingNow) => setTyping(open && typingNow !== false)
|
|
10731
10767
|
}
|
|
10732
10768
|
)
|
|
10733
10769
|
] });
|
|
@@ -12131,11 +12167,8 @@ function mergeUndeliveredLiveInput(queued, undelivered) {
|
|
|
12131
12167
|
return merged;
|
|
12132
12168
|
}
|
|
12133
12169
|
__name(mergeUndeliveredLiveInput, "mergeUndeliveredLiveInput");
|
|
12134
|
-
function humanPromptMeta(attachedFiles
|
|
12135
|
-
|
|
12136
|
-
if (attachedFiles > 0) parts.push(`${attachedFiles} file${attachedFiles > 1 ? "s" : ""} attached`);
|
|
12137
|
-
if (live) parts.push("sent while working");
|
|
12138
|
-
return parts.length > 0 ? parts.join(" \xB7 ") : void 0;
|
|
12170
|
+
function humanPromptMeta(attachedFiles) {
|
|
12171
|
+
return attachedFiles > 0 ? `${attachedFiles} file${attachedFiles > 1 ? "s" : ""} attached` : void 0;
|
|
12139
12172
|
}
|
|
12140
12173
|
__name(humanPromptMeta, "humanPromptMeta");
|
|
12141
12174
|
function goalRoundPrompt(authority) {
|
|
@@ -12399,13 +12432,13 @@ var WakeLedger = class {
|
|
|
12399
12432
|
this.#workflows.clear();
|
|
12400
12433
|
this.#childMessages.clear();
|
|
12401
12434
|
const jobs = this.#jobs;
|
|
12402
|
-
const
|
|
12403
|
-
for (const [id] of
|
|
12435
|
+
const jobLines2 = jobs.ownerSession === owner ? [...jobs.pending].filter(([id]) => this.#wakeJobIds.has(id)) : [];
|
|
12436
|
+
for (const [id] of jobLines2) {
|
|
12404
12437
|
jobs.delivered.add(id);
|
|
12405
12438
|
jobs.pending.delete(id);
|
|
12406
12439
|
this.#wakeJobIds.delete(id);
|
|
12407
12440
|
}
|
|
12408
|
-
return { workflowIds, ended, jobLines };
|
|
12441
|
+
return { workflowIds, ended, jobLines: jobLines2 };
|
|
12409
12442
|
}
|
|
12410
12443
|
/**
|
|
12411
12444
|
* What a turn is about to carry. Everything stays pending until
|
|
@@ -12629,16 +12662,47 @@ var PHASE_DETAIL_LINE_BUDGET = 3;
|
|
|
12629
12662
|
var REPLAYED_TRANSCRIPT_NOTICE = "Replayed from the saved record. This agent has finished and cannot be continued.";
|
|
12630
12663
|
var COCKPIT_CHROME_ROWS = 2;
|
|
12631
12664
|
var DETAIL_CHROME_ROWS = 8;
|
|
12665
|
+
function detailChromeRows(sideBySide) {
|
|
12666
|
+
return sideBySide ? DETAIL_CHROME_ROWS : DETAIL_CHROME_ROWS - 1;
|
|
12667
|
+
}
|
|
12668
|
+
__name(detailChromeRows, "detailChromeRows");
|
|
12669
|
+
var DETAIL_MIN_LIST_ROWS = 2;
|
|
12632
12670
|
var DETAIL_MIN_ROWS = 4;
|
|
12633
|
-
var
|
|
12634
|
-
|
|
12635
|
-
|
|
12636
|
-
|
|
12637
|
-
const
|
|
12638
|
-
const
|
|
12639
|
-
|
|
12671
|
+
var DETAIL_CONVERSATION_ROWS = 10;
|
|
12672
|
+
var DETAIL_TIGHT_ROWS = 24;
|
|
12673
|
+
var DETAIL_AROUND_BOX_ROWS = 6;
|
|
12674
|
+
function workflowDetailBoxRows(rows) {
|
|
12675
|
+
const tight = rows <= DETAIL_TIGHT_ROWS;
|
|
12676
|
+
const avail = Math.max(1, rows - DETAIL_CONVERSATION_ROWS);
|
|
12677
|
+
const least = Math.max(tight ? 8 : 12, Math.min(avail - 1, rows - 6));
|
|
12678
|
+
const most = Math.max(tight ? 8 : 11, avail - 1);
|
|
12679
|
+
return Math.min(least, most);
|
|
12680
|
+
}
|
|
12681
|
+
__name(workflowDetailBoxRows, "workflowDetailBoxRows");
|
|
12682
|
+
function workflowDetailHeight(rows) {
|
|
12683
|
+
return Math.max(
|
|
12684
|
+
DETAIL_MIN_ROWS,
|
|
12685
|
+
Math.min(workflowDetailBoxRows(rows) + DETAIL_AROUND_BOX_ROWS, rows - 1)
|
|
12686
|
+
);
|
|
12640
12687
|
}
|
|
12641
12688
|
__name(workflowDetailHeight, "workflowDetailHeight");
|
|
12689
|
+
function detailGeometry(workflow, phases, columns) {
|
|
12690
|
+
const boxWidth = columns - 2;
|
|
12691
|
+
const leftTitleCells = Math.min(
|
|
12692
|
+
22,
|
|
12693
|
+
Math.max(6, ...phases.map((item) => stringWidth(oneLine3(phaseTitle(item)))))
|
|
12694
|
+
);
|
|
12695
|
+
const countCells = Math.max(
|
|
12696
|
+
3,
|
|
12697
|
+
...phases.map(
|
|
12698
|
+
(item) => phaseCount(item, workflow.runStatus === "stopped").length + phaseFailedTail(item).length
|
|
12699
|
+
)
|
|
12700
|
+
);
|
|
12701
|
+
const leftInner = 5 + leftTitleCells + 1 + countCells + 1;
|
|
12702
|
+
const rightInner = boxWidth - 3 - leftInner;
|
|
12703
|
+
return { leftInner, rightInner, sideBySide: columns >= DETAIL_WIDE_COLUMNS && rightInner >= 24 };
|
|
12704
|
+
}
|
|
12705
|
+
__name(detailGeometry, "detailGeometry");
|
|
12642
12706
|
var graphemes2 = new Intl.Segmenter(void 0, { granularity: "grapheme" });
|
|
12643
12707
|
function AgentNarrationBand({ lines: lines3 }) {
|
|
12644
12708
|
if (lines3.length === 0) return null;
|
|
@@ -13418,9 +13482,21 @@ function WorkflowDetail({
|
|
|
13418
13482
|
now
|
|
13419
13483
|
}) {
|
|
13420
13484
|
const columns = Math.max(20, terminalColumns);
|
|
13485
|
+
const chromeRows = detailChromeRows(detailGeometry(workflow, phases, columns).sideBySide);
|
|
13421
13486
|
const loggedLines = workflow.logs?.length ?? 0;
|
|
13422
|
-
const logLines = height === void 0 ? detailLogLineCount(terminalRows) : Math.min(
|
|
13423
|
-
|
|
13487
|
+
const logLines = height === void 0 ? detailLogLineCount(terminalRows) : Math.min(
|
|
13488
|
+
detailLogLineCount(terminalRows),
|
|
13489
|
+
// A list of fewer than four rows leaves its spare rows to the log lines.
|
|
13490
|
+
Math.max(
|
|
13491
|
+
0,
|
|
13492
|
+
height - chromeRows - Math.min(
|
|
13493
|
+
4,
|
|
13494
|
+
Math.max(phases.length, phases[selectedPhaseIndex]?.agents.length ?? 0, 1)
|
|
13495
|
+
)
|
|
13496
|
+
),
|
|
13497
|
+
loggedLines
|
|
13498
|
+
);
|
|
13499
|
+
const pageSize2 = height === void 0 ? workflowDetailPageSize(terminalRows) : Math.max(DETAIL_MIN_LIST_ROWS, height - chromeRows - logLines);
|
|
13424
13500
|
const phase = phases[selectedPhaseIndex];
|
|
13425
13501
|
const isRun = workflow.runId !== void 0;
|
|
13426
13502
|
const settled2 = workflow.agents.filter((agent) => agent.status === "completed").length;
|
|
@@ -13440,21 +13516,18 @@ function WorkflowDetail({
|
|
|
13440
13516
|
const hint = fitHints(
|
|
13441
13517
|
level === 1 ? [
|
|
13442
13518
|
{ text: "\u2191\u2193 select", rank: 4 },
|
|
13443
|
-
{ text: "enter open", rank: 3 },
|
|
13444
13519
|
...canStop ? [{ text: "x stop workflow", rank: 2 }] : [],
|
|
13445
|
-
{ text: "esc back", rank: 5 }
|
|
13446
|
-
{ text: "space close", rank: 1 }
|
|
13520
|
+
{ text: "esc back", rank: 5 }
|
|
13447
13521
|
] : [
|
|
13448
|
-
{ text: "\u2191\u2193
|
|
13522
|
+
{ text: "\u2191\u2193 agent", rank: 4 },
|
|
13449
13523
|
{ text: "enter view", rank: 3 },
|
|
13450
13524
|
...canStop ? [{ text: `x ${isRun ? "skip" : "stop"}`, rank: 2 }] : [],
|
|
13451
|
-
{ text: "esc back", rank: 5 }
|
|
13452
|
-
{ text: "space close", rank: 1 }
|
|
13525
|
+
{ text: "esc back", rank: 5 }
|
|
13453
13526
|
],
|
|
13454
13527
|
Math.max(1, columns - 2)
|
|
13455
13528
|
);
|
|
13456
13529
|
const agents = phase?.agents ?? [];
|
|
13457
|
-
const agentsTitle = phase ? `${oneLine3(phaseTitle(phase))} \xB7 ${agents.length} ${agents.length === 1 ? "agent" : "agents"}
|
|
13530
|
+
const agentsTitle = phase ? `${oneLine3(phaseTitle(phase))} \xB7 ${agents.length} ${agents.length === 1 ? "agent" : "agents"}` : "";
|
|
13458
13531
|
const agentsFailed = agents.filter((agent) => agent.status === "failed").length;
|
|
13459
13532
|
const failedTail = agentsFailed > 0 ? ` \xB7 ${agentsFailed} failed` : "";
|
|
13460
13533
|
const titleWithFailed = /* @__PURE__ */ __name((text) => {
|
|
@@ -13476,7 +13549,7 @@ function WorkflowDetail({
|
|
|
13476
13549
|
text: outcome === "done" ? "\u2714" : outcome === "failed" || outcome === "skipped" ? "\u2718" : String(index + 1)
|
|
13477
13550
|
};
|
|
13478
13551
|
}, "phaseGlyph");
|
|
13479
|
-
const
|
|
13552
|
+
const { leftInner, rightInner, sideBySide } = detailGeometry(workflow, phases, columns);
|
|
13480
13553
|
const leftTitleCells = Math.min(
|
|
13481
13554
|
22,
|
|
13482
13555
|
Math.max(6, ...phases.map((item) => stringWidth(oneLine3(phaseTitle(item)))))
|
|
@@ -13487,15 +13560,12 @@ function WorkflowDetail({
|
|
|
13487
13560
|
(item) => phaseCount(item, workflow.runStatus === "stopped").length + phaseFailedTail(item).length
|
|
13488
13561
|
)
|
|
13489
13562
|
);
|
|
13490
|
-
const leftInner = 5 + leftTitleCells + 1 + countCells + 1;
|
|
13491
|
-
const rightInner = boxWidth - 3 - leftInner;
|
|
13492
|
-
const sideBySide = columns >= DETAIL_WIDE_COLUMNS && rightInner >= 24;
|
|
13493
13563
|
const recentLogs = (logLines === 0 ? [] : (workflow.logs ?? []).slice(-logLines)).map(
|
|
13494
13564
|
(line) => terminalDisplayText(oneLine3(line))
|
|
13495
13565
|
);
|
|
13496
13566
|
const header = /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(import_jsx_runtime11.Fragment, { children: [
|
|
13497
13567
|
/* @__PURE__ */ (0, import_jsx_runtime11.jsx)(Text, { color: theme.border.default, wrap: "truncate-end", children: "\u2500".repeat(columns) }),
|
|
13498
|
-
/* @__PURE__ */ (0, import_jsx_runtime11.jsx)(Box_default, { paddingX: 1, children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(Text, { color: theme.
|
|
13568
|
+
/* @__PURE__ */ (0, import_jsx_runtime11.jsx)(Box_default, { paddingX: 1, children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(Text, { color: theme.accent.assistant, bold: true, wrap: "truncate-end", children: title }) }),
|
|
13499
13569
|
/* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(Box_default, { paddingX: 1, children: [
|
|
13500
13570
|
/* @__PURE__ */ (0, import_jsx_runtime11.jsx)(Box_default, { flexGrow: 1, minWidth: 0, children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(Text, { color: theme.text.muted, wrap: "truncate-end", children: workflow.description ? terminalDisplayText(oneLine3(workflow.description)) : "" }) }),
|
|
13501
13571
|
/* @__PURE__ */ (0, import_jsx_runtime11.jsx)(Box_default, { flexShrink: 0, marginLeft: 1, children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(Text, { color: theme.text.muted, children: stats }) })
|
|
@@ -13514,7 +13584,7 @@ function WorkflowDetail({
|
|
|
13514
13584
|
)),
|
|
13515
13585
|
/* @__PURE__ */ (0, import_jsx_runtime11.jsx)(Text, { children: " " })
|
|
13516
13586
|
] });
|
|
13517
|
-
const footer = /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(Box_default, { paddingX: 1, children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(Text, { color: theme.text.muted, wrap: "truncate-end", children: hint }) });
|
|
13587
|
+
const footer = /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(Box_default, { paddingX: 1, children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(Text, { color: theme.text.muted, dimColor: true, italic: true, wrap: "truncate-end", children: hint }) });
|
|
13518
13588
|
const stackedDetail = level === 1 && terminalRows >= 20 && phase?.detail && phaseWindow.items.length + 1 + 1 <= pageSize2 ? wrapPhaseDetailLines(phase.detail, columns - 4).slice(
|
|
13519
13589
|
0,
|
|
13520
13590
|
Math.min(PHASE_DETAIL_LINE_BUDGET, pageSize2 - phaseWindow.items.length - 1)
|
|
@@ -13585,9 +13655,7 @@ function WorkflowDetail({
|
|
|
13585
13655
|
footer
|
|
13586
13656
|
] });
|
|
13587
13657
|
}
|
|
13588
|
-
const
|
|
13589
|
-
const showDetail = detailLines.length > 0 && detailLines.length + 1 + agentWindow.items.length <= pageSize2;
|
|
13590
|
-
const detailRows = showDetail ? detailLines.length + 1 : 0;
|
|
13658
|
+
const detailRows = 0;
|
|
13591
13659
|
const border = theme.border.default;
|
|
13592
13660
|
const leftTitle = " Phases ";
|
|
13593
13661
|
const rightTitle = ` ${truncateChoiceText(`${agentsTitle}${failedTail}`, Math.max(1, rightInner - 4))} `;
|
|
@@ -13625,7 +13693,6 @@ function WorkflowDetail({
|
|
|
13625
13693
|
Math.max(0, ...agentWindow.items.map((value) => stringWidth(agentDetailLabel(value)))),
|
|
13626
13694
|
Math.floor(rightInner * 0.45)
|
|
13627
13695
|
);
|
|
13628
|
-
const detailRow = showDetail && row2 < detailLines.length ? row2 : -1;
|
|
13629
13696
|
return /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(Box_default, { paddingX: 1, children: [
|
|
13630
13697
|
/* @__PURE__ */ (0, import_jsx_runtime11.jsx)(Text, { color: border, children: "\u2502" }),
|
|
13631
13698
|
/* @__PURE__ */ (0, import_jsx_runtime11.jsx)(Box_default, { width: leftInner, flexShrink: 0, children: item && glyph ? /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(Text, { wrap: "truncate-end", children: [
|
|
@@ -13682,9 +13749,6 @@ function WorkflowDetail({
|
|
|
13682
13749
|
),
|
|
13683
13750
|
" "
|
|
13684
13751
|
] }) })
|
|
13685
|
-
] }) : detailRow >= 0 && detailLines[detailRow] !== void 0 ? /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(Text, { color: theme.text.muted, wrap: "truncate-end", children: [
|
|
13686
|
-
" ",
|
|
13687
|
-
detailLines[detailRow]
|
|
13688
13752
|
] }) : row2 === detailRows && emptyNote ? /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(Text, { color: theme.text.muted, dimColor: true, wrap: "truncate-end", children: [
|
|
13689
13753
|
" ",
|
|
13690
13754
|
emptyNote
|
|
@@ -14330,10 +14394,11 @@ function choicePickerWindowSize({
|
|
|
14330
14394
|
rule = false,
|
|
14331
14395
|
windowSize = SELECTION_WINDOW_SIZE,
|
|
14332
14396
|
rowHeight: givenRowHeight,
|
|
14333
|
-
detailRows = 0
|
|
14397
|
+
detailRows = 0,
|
|
14398
|
+
bodyRows = 0
|
|
14334
14399
|
}) {
|
|
14335
14400
|
const availableRows = Math.max(6, rows - 4);
|
|
14336
|
-
const furnitureRows = 4 + Number(searchable) + Number(notice) + Number(selectedDescription) + Number(rule) + detailRows;
|
|
14401
|
+
const furnitureRows = 4 + Number(searchable) + Number(notice) + Number(selectedDescription) + Number(rule) + detailRows + bodyRows;
|
|
14337
14402
|
const rowHeight2 = givenRowHeight ?? (columns < 70 ? 2 : 1);
|
|
14338
14403
|
return Math.max(1, Math.min(windowSize, Math.floor((availableRows - furnitureRows) / rowHeight2)));
|
|
14339
14404
|
}
|
|
@@ -14341,6 +14406,11 @@ __name(choicePickerWindowSize, "choicePickerWindowSize");
|
|
|
14341
14406
|
|
|
14342
14407
|
// src/tui/ChoicePicker.tsx
|
|
14343
14408
|
var import_jsx_runtime14 = __toESM(require_jsx_runtime(), 1);
|
|
14409
|
+
function capBody(lines3, max) {
|
|
14410
|
+
if (lines3.length <= max) return lines3;
|
|
14411
|
+
return [...lines3.slice(0, max - 1), `\u2026 ${lines3.length - (max - 1)} more lines`];
|
|
14412
|
+
}
|
|
14413
|
+
__name(capBody, "capBody");
|
|
14344
14414
|
var SELECTED_DESCRIPTION_LINES = 8;
|
|
14345
14415
|
var STACKED_DESCRIPTION_LINES = 2;
|
|
14346
14416
|
function ChoicePicker({
|
|
@@ -14348,6 +14418,7 @@ function ChoicePicker({
|
|
|
14348
14418
|
title,
|
|
14349
14419
|
notice,
|
|
14350
14420
|
subtitle,
|
|
14421
|
+
body,
|
|
14351
14422
|
hints,
|
|
14352
14423
|
options,
|
|
14353
14424
|
selected,
|
|
@@ -14379,7 +14450,9 @@ function ChoicePicker({
|
|
|
14379
14450
|
Math.max(1, contentWidth - 4)
|
|
14380
14451
|
), "wholeDescription");
|
|
14381
14452
|
const detailRows = !describeSelected ? 0 : stacked ? SELECTED_DESCRIPTION_LINES - STACKED_DESCRIPTION_LINES : Math.max(0, ...options.map((option) => wholeDescription(option).length));
|
|
14453
|
+
const bodyLines = capBody(body ?? [], Math.max(3, terminal.rows - 14));
|
|
14382
14454
|
const pageSize2 = choicePickerWindowSize({
|
|
14455
|
+
bodyRows: bodyLines.length,
|
|
14383
14456
|
rowHeight: stacked ? 1 + Math.max(1, ...options.map((option) => stackedDescription(option).length)) : 1,
|
|
14384
14457
|
rows: terminal.rows,
|
|
14385
14458
|
columns,
|
|
@@ -14431,6 +14504,10 @@ function ChoicePicker({
|
|
|
14431
14504
|
/* @__PURE__ */ (0, import_jsx_runtime14.jsx)(Text, { color: theme.text.muted, children: count2 })
|
|
14432
14505
|
] }),
|
|
14433
14506
|
subtitle ? /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(Text, { color: theme.text.muted, children: truncateChoiceText(subtitle, contentWidth) }) : null,
|
|
14507
|
+
bodyLines.map((line, lineIndex) => (
|
|
14508
|
+
// biome-ignore lint/suspicious/noArrayIndexKey: a body line has no identity beyond its position.
|
|
14509
|
+
/* @__PURE__ */ (0, import_jsx_runtime14.jsx)(Text, { color: theme.text.secondary, children: line.length === 0 ? " " : truncateChoiceText(line, contentWidth) }, `b-${lineIndex}`)
|
|
14510
|
+
)),
|
|
14434
14511
|
query !== void 0 ? /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(Text, { color: query.length > 0 ? theme.text.primary : theme.text.muted, children: truncateChoiceText(`Search: ${query || searchPlaceholder}`, contentWidth) }) : null,
|
|
14435
14512
|
notice ? /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(Text, { color: theme.status.warn, children: truncateChoiceText(notice, contentWidth) }) : null,
|
|
14436
14513
|
visible.length === 0 ? /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(Text, { color: theme.text.muted, children: "No matching options" }) : null,
|
|
@@ -15420,7 +15497,7 @@ function matchMentionableFiles(query, files, limit = 100) {
|
|
|
15420
15497
|
).slice(0, Math.max(0, limit)).map(({ path }) => path);
|
|
15421
15498
|
}
|
|
15422
15499
|
__name(matchMentionableFiles, "matchMentionableFiles");
|
|
15423
|
-
function expandFileMentions(text, cwd,
|
|
15500
|
+
function expandFileMentions(text, cwd, readFile4, known = {}) {
|
|
15424
15501
|
const attached = [];
|
|
15425
15502
|
const blocks = [];
|
|
15426
15503
|
const seen = /* @__PURE__ */ new Set();
|
|
@@ -15451,9 +15528,9 @@ function expandFileMentions(text, cwd, readFile5, known = {}) {
|
|
|
15451
15528
|
attemptedFiles++;
|
|
15452
15529
|
const maxChars = Math.min(MAX_FILE_CHARS, remainingChars);
|
|
15453
15530
|
let content;
|
|
15454
|
-
if (
|
|
15531
|
+
if (readFile4) {
|
|
15455
15532
|
try {
|
|
15456
|
-
const whole =
|
|
15533
|
+
const whole = readFile4(parsed.path);
|
|
15457
15534
|
content = whole === null ? null : parsed.range ? lineRange(whole, parsed.range) : whole;
|
|
15458
15535
|
} catch {
|
|
15459
15536
|
content = null;
|
|
@@ -15527,13 +15604,13 @@ async function attachMentionedResources(expanded, original, read, maxChars = MAX
|
|
|
15527
15604
|
omitted = true;
|
|
15528
15605
|
continue;
|
|
15529
15606
|
}
|
|
15530
|
-
const
|
|
15607
|
+
const open = `<resource-${marker} server="${escapeAttribute(server)}" uri="${escapeAttribute(uri)}">
|
|
15531
15608
|
`;
|
|
15532
15609
|
const close = `
|
|
15533
15610
|
</resource-${marker}>`;
|
|
15534
15611
|
const available = Math.max(
|
|
15535
15612
|
0,
|
|
15536
|
-
Math.min(perResource, remaining -
|
|
15613
|
+
Math.min(perResource, remaining - open.length - close.length - 32)
|
|
15537
15614
|
);
|
|
15538
15615
|
if (available <= 0) {
|
|
15539
15616
|
omitted = true;
|
|
@@ -15544,7 +15621,7 @@ async function attachMentionedResources(expanded, original, read, maxChars = MAX
|
|
|
15544
15621
|
if (content === null) continue;
|
|
15545
15622
|
const body = content.length > available ? `${content.slice(0, available)}
|
|
15546
15623
|
\u2026 (truncated)` : content;
|
|
15547
|
-
const block =
|
|
15624
|
+
const block = open + body + close;
|
|
15548
15625
|
remaining -= block.length + 2;
|
|
15549
15626
|
blocks.push(block);
|
|
15550
15627
|
attached.push(`${server}:${uri}`);
|
|
@@ -16048,7 +16125,7 @@ function scanDelimited(draft, zones) {
|
|
|
16048
16125
|
index = end;
|
|
16049
16126
|
continue;
|
|
16050
16127
|
}
|
|
16051
|
-
const pair = PAIRS.find(([
|
|
16128
|
+
const pair = PAIRS.find(([open]) => open === char);
|
|
16052
16129
|
if (pair) {
|
|
16053
16130
|
const close = draft.indexOf(pair[1], index + 1);
|
|
16054
16131
|
const end = close < 0 ? draft.length : close + 1;
|
|
@@ -16891,9 +16968,9 @@ function matchBracket(doc, from) {
|
|
|
16891
16968
|
while (at < end && !(OPENING + CLOSING).includes(doc.chars[at])) at += 1;
|
|
16892
16969
|
if (at >= end) return null;
|
|
16893
16970
|
const ch = doc.chars[at];
|
|
16894
|
-
const
|
|
16895
|
-
if (
|
|
16896
|
-
const close = CLOSING[
|
|
16971
|
+
const open = OPENING.indexOf(ch);
|
|
16972
|
+
if (open >= 0) {
|
|
16973
|
+
const close = CLOSING[open];
|
|
16897
16974
|
let depth2 = 0;
|
|
16898
16975
|
for (let i = at + 1; i < doc.n; i += 1) {
|
|
16899
16976
|
const here = doc.chars[i];
|
|
@@ -16980,10 +17057,10 @@ function quoteObject(doc, at, quote, inner) {
|
|
|
16980
17057
|
}
|
|
16981
17058
|
let pair = null;
|
|
16982
17059
|
for (let k = 0; k + 1 < marks.length; k += 2) {
|
|
16983
|
-
const
|
|
17060
|
+
const open = marks[k];
|
|
16984
17061
|
const close = marks[k + 1];
|
|
16985
17062
|
if (at <= close) {
|
|
16986
|
-
pair = [
|
|
17063
|
+
pair = [open, close];
|
|
16987
17064
|
break;
|
|
16988
17065
|
}
|
|
16989
17066
|
}
|
|
@@ -16999,13 +17076,13 @@ function quoteObject(doc, at, quote, inner) {
|
|
|
16999
17076
|
return [begin, stop];
|
|
17000
17077
|
}
|
|
17001
17078
|
__name(quoteObject, "quoteObject");
|
|
17002
|
-
function bracketObject(doc, at,
|
|
17079
|
+
function bracketObject(doc, at, open, close, inner, count2) {
|
|
17003
17080
|
const enclosing = /* @__PURE__ */ __name((from, skipSelf) => {
|
|
17004
17081
|
let depth2 = 0;
|
|
17005
17082
|
for (let j = from; j >= 0; j -= 1) {
|
|
17006
17083
|
const ch = doc.chars[j];
|
|
17007
17084
|
if (ch === close && !(skipSelf && j === from)) depth2 += 1;
|
|
17008
|
-
else if (ch ===
|
|
17085
|
+
else if (ch === open) {
|
|
17009
17086
|
if (depth2 === 0) return j;
|
|
17010
17087
|
depth2 -= 1;
|
|
17011
17088
|
}
|
|
@@ -17023,7 +17100,7 @@ function bracketObject(doc, at, open2, close, inner, count2) {
|
|
|
17023
17100
|
let e = -1;
|
|
17024
17101
|
for (let j = s + 1; j < doc.n; j += 1) {
|
|
17025
17102
|
const ch = doc.chars[j];
|
|
17026
|
-
if (ch ===
|
|
17103
|
+
if (ch === open) depth += 1;
|
|
17027
17104
|
else if (ch === close) {
|
|
17028
17105
|
if (depth === 0) {
|
|
17029
17106
|
e = j;
|
|
@@ -18468,7 +18545,6 @@ function Composer({
|
|
|
18468
18545
|
onBackgroundCommand,
|
|
18469
18546
|
onStopAllAgents,
|
|
18470
18547
|
railFocused = false,
|
|
18471
|
-
parked = false,
|
|
18472
18548
|
onCycleMode,
|
|
18473
18549
|
triggers,
|
|
18474
18550
|
turnActive = false,
|
|
@@ -19859,7 +19935,7 @@ ${valueRef.current.slice(position2)}`, position2);
|
|
|
19859
19935
|
/* @__PURE__ */ (0, import_jsx_runtime15.jsx)(import_react10.Fragment, { children: renderSegments(displaySegments(value, trail, to, styledSpans)) }, "vim-after")
|
|
19860
19936
|
];
|
|
19861
19937
|
}, "blockLine");
|
|
19862
|
-
const shown = railFocused
|
|
19938
|
+
const shown = railFocused;
|
|
19863
19939
|
const shellGlyph = shellMode && !(disabled && !shown);
|
|
19864
19940
|
const promptGlyph = disabled && !shown ? "\u2026" : shellGlyph ? "!" : "\u276F";
|
|
19865
19941
|
const showPlaceholder = (!disabled || shown) && value.length === 0 && !shellMode;
|
|
@@ -20295,6 +20371,8 @@ var PENDING_POINTER = "\u276F";
|
|
|
20295
20371
|
var SEND_NOW_HINT = "ctrl+x ctrl+s to send now";
|
|
20296
20372
|
var MAX_PREVIEW_CODEPOINTS = 400;
|
|
20297
20373
|
var QUEUED_SUFFIX = " \xB7 after this reply";
|
|
20374
|
+
var QUEUED_COMMAND_SUFFIX = " \xB7 Queued, runs after this reply";
|
|
20375
|
+
var QUEUED_COMMAND_SHORT_SUFFIX = " \xB7 Queued";
|
|
20298
20376
|
function previewText(source) {
|
|
20299
20377
|
let head2 = "";
|
|
20300
20378
|
let count2 = 0;
|
|
@@ -20396,7 +20474,8 @@ function PendingInputPanel({
|
|
|
20396
20474
|
const text = previewText(row2.item.text) || (row2.item.attachmentCount ? "(attachment only)" : "(empty message)");
|
|
20397
20475
|
const room = Math.max(0, width - choiceDisplayWidth(lead));
|
|
20398
20476
|
const keep = Math.min(choiceDisplayWidth(text), 12) + choiceDisplayWidth(files);
|
|
20399
|
-
const
|
|
20477
|
+
const suffixes = row2.item.command ? [QUEUED_COMMAND_SUFFIX, QUEUED_COMMAND_SHORT_SUFFIX] : [QUEUED_SUFFIX];
|
|
20478
|
+
const tail2 = row2.queued ? suffixes.find((suffix) => room - keep >= choiceDisplayWidth(suffix)) ?? "" : "";
|
|
20400
20479
|
const shownFiles = truncateChoiceText(files, Math.max(0, room - choiceDisplayWidth(tail2)));
|
|
20401
20480
|
const shownText = truncateChoiceText(
|
|
20402
20481
|
text,
|
|
@@ -23986,6 +24065,10 @@ function monitorPill(count2) {
|
|
|
23986
24065
|
return count2 > 0 ? `${count2} ${count2 === 1 ? "monitor" : "monitors"}` : null;
|
|
23987
24066
|
}
|
|
23988
24067
|
__name(monitorPill, "monitorPill");
|
|
24068
|
+
function joinRequestPill(count2) {
|
|
24069
|
+
return count2 > 0 ? `${count2 > 99 ? "99+" : count2} join ${count2 === 1 ? "request" : "requests"} \xB7 /peers` : null;
|
|
24070
|
+
}
|
|
24071
|
+
__name(joinRequestPill, "joinRequestPill");
|
|
23989
24072
|
function StatusBar({
|
|
23990
24073
|
provider,
|
|
23991
24074
|
model,
|
|
@@ -24004,6 +24087,7 @@ function StatusBar({
|
|
|
24004
24087
|
restingHint = true,
|
|
24005
24088
|
shellCount = 0,
|
|
24006
24089
|
monitorCount = 0,
|
|
24090
|
+
joinRequests = 0,
|
|
24007
24091
|
pr,
|
|
24008
24092
|
hyperlinks = false,
|
|
24009
24093
|
agentCount = 0,
|
|
@@ -24043,7 +24127,7 @@ function StatusBar({
|
|
|
24043
24127
|
const activeMode = permissionMode !== void 0 && permissionMode !== "prompt" ? modeGlyph(permissionMode) : null;
|
|
24044
24128
|
const working = state !== "idle";
|
|
24045
24129
|
const hasPr = pr !== void 0 && pr.kind !== "none";
|
|
24046
|
-
const nothingElse = !activeMode && shellCount + monitorCount === 0 && !hasPr && agentCount === 0 && workflowCount === 0 && !canManage && !shellsSelected;
|
|
24130
|
+
const nothingElse = !activeMode && shellCount + monitorCount === 0 && joinRequests === 0 && !hasPr && agentCount === 0 && workflowCount === 0 && !canManage && !shellsSelected;
|
|
24047
24131
|
const layout = fitStatusLine({
|
|
24048
24132
|
// The line starts in the first column and App keeps one cell empty at the
|
|
24049
24133
|
// right edge. Ink's stdout width is the whole terminal, so reserve that cell
|
|
@@ -24063,6 +24147,7 @@ function StatusBar({
|
|
|
24063
24147
|
// the row: the pill is what the row is about then.
|
|
24064
24148
|
cycleSuffix: activeMode && canCycleMode && composerMounted && !dialogOpen && shellCount + monitorCount === 0 ? CYCLE_SUFFIX : null,
|
|
24065
24149
|
interrupt: working && !hint && !dialogOpen ? INTERRUPT_HINT : null,
|
|
24150
|
+
joins: joinRequestPill(joinRequests),
|
|
24066
24151
|
shells: shellPill(shellCount),
|
|
24067
24152
|
monitors: monitorPill(monitorCount),
|
|
24068
24153
|
agents: runningText(agentCount, workflowCount),
|
|
@@ -24086,6 +24171,11 @@ function StatusBar({
|
|
|
24086
24171
|
] }, "mode")
|
|
24087
24172
|
);
|
|
24088
24173
|
}
|
|
24174
|
+
if (layout.joins) {
|
|
24175
|
+
parts.push(
|
|
24176
|
+
/* @__PURE__ */ (0, import_jsx_runtime29.jsx)(Text, { color: theme.status.warn, children: layout.joins }, "joins")
|
|
24177
|
+
);
|
|
24178
|
+
}
|
|
24089
24179
|
if (layout.pr) {
|
|
24090
24180
|
parts.push(
|
|
24091
24181
|
/* @__PURE__ */ (0, import_jsx_runtime29.jsx)(Text, { children: pr?.kind === "pr" && layout.pr.prefix ? /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)(import_jsx_runtime29.Fragment, { children: [
|
|
@@ -24143,6 +24233,7 @@ function StatusBar({
|
|
|
24143
24233
|
const leftTexts = [
|
|
24144
24234
|
["vim", layout.vim ?? null],
|
|
24145
24235
|
["mode", layout.mode ? `${layout.mode}${layout.cycleSuffix ?? ""}` : null],
|
|
24236
|
+
["joins", layout.joins],
|
|
24146
24237
|
[
|
|
24147
24238
|
"pr",
|
|
24148
24239
|
layout.pr ? `${layout.pr.prefix ? `${layout.pr.prefix} ` : ""}${layout.pr.label}` : null
|
|
@@ -24227,6 +24318,7 @@ function fitStatusLine(input) {
|
|
|
24227
24318
|
let mode = input.modeLabel.length > 0 ? input.modeLabel : null;
|
|
24228
24319
|
let cycleSuffix = input.cycleSuffix ?? null;
|
|
24229
24320
|
let interrupt = input.interrupt ?? null;
|
|
24321
|
+
let joins = input.joins ?? null;
|
|
24230
24322
|
let shells = input.shells ?? null;
|
|
24231
24323
|
let monitors = input.monitors ?? null;
|
|
24232
24324
|
let agents = input.agents ?? null;
|
|
@@ -24238,6 +24330,7 @@ function fitStatusLine(input) {
|
|
|
24238
24330
|
const parts = /* @__PURE__ */ __name(() => [
|
|
24239
24331
|
vim,
|
|
24240
24332
|
mode ? `${mode}${cycleSuffix ?? ""}` : null,
|
|
24333
|
+
joins,
|
|
24241
24334
|
pr ? `${pr.prefix ? `${pr.prefix} ` : ""}${pr.label}` : null,
|
|
24242
24335
|
shells,
|
|
24243
24336
|
monitors,
|
|
@@ -24269,6 +24362,7 @@ function fitStatusLine(input) {
|
|
|
24269
24362
|
}
|
|
24270
24363
|
if (over()) pr = null;
|
|
24271
24364
|
if (over() && (mode === QUIET_MODE_HINT || mode === QUIET_SANDBOX_HINT)) mode = null;
|
|
24365
|
+
if (over()) joins = null;
|
|
24272
24366
|
if (over() && mode) {
|
|
24273
24367
|
const whole = mode;
|
|
24274
24368
|
mode = null;
|
|
@@ -24286,6 +24380,7 @@ function fitStatusLine(input) {
|
|
|
24286
24380
|
mode,
|
|
24287
24381
|
cycleSuffix: mode ? cycleSuffix : null,
|
|
24288
24382
|
interrupt,
|
|
24383
|
+
joins,
|
|
24289
24384
|
shells,
|
|
24290
24385
|
monitors,
|
|
24291
24386
|
pr,
|
|
@@ -25483,414 +25578,12 @@ __name(runnableCommands, "runnableCommands");
|
|
|
25483
25578
|
|
|
25484
25579
|
// src/tui/cross-session-history.ts
|
|
25485
25580
|
import { utimes } from "node:fs/promises";
|
|
25486
|
-
import { join as
|
|
25581
|
+
import { join as join13 } from "node:path";
|
|
25487
25582
|
|
|
25488
25583
|
// src/integrations/sessions/cleanup.ts
|
|
25489
25584
|
import { readFileSync as readFileSync5, readdirSync as readdirSync2, writeFileSync as writeFileSync4 } from "node:fs";
|
|
25490
|
-
import { lstat as
|
|
25491
|
-
import { join as join13 } from "node:path";
|
|
25492
|
-
|
|
25493
|
-
// src/integrations/sessions/prompt-history.ts
|
|
25494
|
-
import { createHash as createHash5, randomBytes as randomBytes3 } from "node:crypto";
|
|
25495
|
-
import { constants as constants3 } from "node:fs";
|
|
25496
|
-
import { lstat as lstat2, mkdir, open, readFile as readFile4, rename, stat as stat2, unlink, writeFile as writeFile2 } from "node:fs/promises";
|
|
25585
|
+
import { lstat as lstat2, readdir, rm as rm3, stat as stat2 } from "node:fs/promises";
|
|
25497
25586
|
import { join as join12 } from "node:path";
|
|
25498
|
-
var PROMPT_HISTORY_FILE = "history.jsonl";
|
|
25499
|
-
var PROMPT_HISTORY_KEEP = 2e3;
|
|
25500
|
-
var TRIM_SLACK = 500;
|
|
25501
|
-
var PROMPT_HISTORY_RECALL = 500;
|
|
25502
|
-
var PROMPT_HISTORY_MAX_CHARS = 64 * 1024;
|
|
25503
|
-
var PROMPT_HISTORY_SEED_SESSIONS = 20;
|
|
25504
|
-
var PROMPT_HISTORY_SEEDED_MARKER = ".history-seeded";
|
|
25505
|
-
var MAX_READ_BYTES = 16 * 1024 * 1024;
|
|
25506
|
-
var MAX_PASTE_SESSIONS = 20;
|
|
25507
|
-
function promptHistoryPath(home) {
|
|
25508
|
-
return join12(home, PROMPT_HISTORY_FILE);
|
|
25509
|
-
}
|
|
25510
|
-
__name(promptHistoryPath, "promptHistoryPath");
|
|
25511
|
-
function sha256Hex(text) {
|
|
25512
|
-
return createHash5("sha256").update(text, "utf8").digest("hex");
|
|
25513
|
-
}
|
|
25514
|
-
__name(sha256Hex, "sha256Hex");
|
|
25515
|
-
var CREDENTIAL_SHAPES = LOG_SECRET_PATTERNS.map(
|
|
25516
|
-
([, pattern]) => new RegExp(pattern.source, pattern.flags.replace("g", ""))
|
|
25517
|
-
);
|
|
25518
|
-
function promptLooksSensitive(text) {
|
|
25519
|
-
if (/^\s*\/login\s+\S/.test(text)) return true;
|
|
25520
|
-
try {
|
|
25521
|
-
return CREDENTIAL_SHAPES.some((shape) => shape.test(text));
|
|
25522
|
-
} catch {
|
|
25523
|
-
return true;
|
|
25524
|
-
}
|
|
25525
|
-
}
|
|
25526
|
-
__name(promptLooksSensitive, "promptLooksSensitive");
|
|
25527
|
-
function promptHistorySkipped(env = process.env) {
|
|
25528
|
-
return startedBySession(env);
|
|
25529
|
-
}
|
|
25530
|
-
__name(promptHistorySkipped, "promptHistorySkipped");
|
|
25531
|
-
function promptHistoryEnabled(options = {}) {
|
|
25532
|
-
try {
|
|
25533
|
-
return loadBootstrapConfigWithProvenance(options).config.promptHistory !== false;
|
|
25534
|
-
} catch {
|
|
25535
|
-
return false;
|
|
25536
|
-
}
|
|
25537
|
-
}
|
|
25538
|
-
__name(promptHistoryEnabled, "promptHistoryEnabled");
|
|
25539
|
-
function promptHistoryEntryFor(input) {
|
|
25540
|
-
const { text } = input;
|
|
25541
|
-
if (text.trim().length === 0) return void 0;
|
|
25542
|
-
const ranges = [...input.pasted ?? []].sort((a, b) => a.start - b.start);
|
|
25543
|
-
let display = "";
|
|
25544
|
-
let at = 0;
|
|
25545
|
-
const pasted = [];
|
|
25546
|
-
for (const range of ranges) {
|
|
25547
|
-
if (!Number.isSafeInteger(range.start) || !Number.isSafeInteger(range.end) || range.start < at || range.end <= range.start || range.end > text.length)
|
|
25548
|
-
return void 0;
|
|
25549
|
-
display += text.slice(at, range.start);
|
|
25550
|
-
const piece = text.slice(range.start, range.end);
|
|
25551
|
-
pasted.push({ offset: display.length, length: piece.length, sha256: sha256Hex(piece) });
|
|
25552
|
-
at = range.end;
|
|
25553
|
-
}
|
|
25554
|
-
display += text.slice(at);
|
|
25555
|
-
if (display.length > PROMPT_HISTORY_MAX_CHARS) return void 0;
|
|
25556
|
-
if (promptLooksSensitive(display)) return void 0;
|
|
25557
|
-
return {
|
|
25558
|
-
display,
|
|
25559
|
-
...pasted.length > 0 ? { pasted } : {},
|
|
25560
|
-
project: input.project,
|
|
25561
|
-
sessionId: input.sessionId,
|
|
25562
|
-
timestamp: input.timestamp
|
|
25563
|
-
};
|
|
25564
|
-
}
|
|
25565
|
-
__name(promptHistoryEntryFor, "promptHistoryEntryFor");
|
|
25566
|
-
function isPaste(value) {
|
|
25567
|
-
if (typeof value !== "object" || value === null) return false;
|
|
25568
|
-
const v = value;
|
|
25569
|
-
return Number.isSafeInteger(v.offset) && v.offset >= 0 && Number.isSafeInteger(v.length) && v.length > 0 && typeof v.sha256 === "string" && /^[0-9a-f]{64}$/.test(v.sha256);
|
|
25570
|
-
}
|
|
25571
|
-
__name(isPaste, "isPaste");
|
|
25572
|
-
function parsePromptHistoryLine(line) {
|
|
25573
|
-
let value;
|
|
25574
|
-
try {
|
|
25575
|
-
value = JSON.parse(line);
|
|
25576
|
-
} catch {
|
|
25577
|
-
return void 0;
|
|
25578
|
-
}
|
|
25579
|
-
if (typeof value !== "object" || value === null || Array.isArray(value)) return void 0;
|
|
25580
|
-
const v = value;
|
|
25581
|
-
if (typeof v.display !== "string" || typeof v.project !== "string" || typeof v.sessionId !== "string" || typeof v.timestamp !== "number" || !Number.isFinite(v.timestamp))
|
|
25582
|
-
return void 0;
|
|
25583
|
-
let pasted;
|
|
25584
|
-
if (v.pasted !== void 0) {
|
|
25585
|
-
if (!Array.isArray(v.pasted) || !v.pasted.every(isPaste)) return void 0;
|
|
25586
|
-
pasted = [...v.pasted].sort((a, b) => a.offset - b.offset);
|
|
25587
|
-
if (pasted.some((paste) => paste.offset > v.display.length)) return void 0;
|
|
25588
|
-
}
|
|
25589
|
-
return {
|
|
25590
|
-
display: v.display,
|
|
25591
|
-
...pasted && pasted.length > 0 ? { pasted } : {},
|
|
25592
|
-
project: v.project,
|
|
25593
|
-
sessionId: v.sessionId,
|
|
25594
|
-
timestamp: v.timestamp
|
|
25595
|
-
};
|
|
25596
|
-
}
|
|
25597
|
-
__name(parsePromptHistoryLine, "parsePromptHistoryLine");
|
|
25598
|
-
var realWait = /* @__PURE__ */ __name(() => new Promise((resolveWait) => setTimeout(resolveWait, 20)), "realWait");
|
|
25599
|
-
function withHistoryLock(home, operation, options = {}) {
|
|
25600
|
-
return withAccountLock(`${promptHistoryPath(home)}.lock`, operation, {
|
|
25601
|
-
attempts: options.attempts ?? 50,
|
|
25602
|
-
wait: options.wait ?? realWait
|
|
25603
|
-
});
|
|
25604
|
-
}
|
|
25605
|
-
__name(withHistoryLock, "withHistoryLock");
|
|
25606
|
-
async function notARegularFile(path) {
|
|
25607
|
-
try {
|
|
25608
|
-
const entry = await lstat2(path);
|
|
25609
|
-
if (entry.isSymbolicLink()) return "it is a link";
|
|
25610
|
-
if (!entry.isFile()) return "it is not a regular file";
|
|
25611
|
-
return void 0;
|
|
25612
|
-
} catch (error) {
|
|
25613
|
-
if (error.code === "ENOENT") return void 0;
|
|
25614
|
-
throw error;
|
|
25615
|
-
}
|
|
25616
|
-
}
|
|
25617
|
-
__name(notARegularFile, "notARegularFile");
|
|
25618
|
-
var NOFOLLOW = constants3.O_NOFOLLOW ?? 0;
|
|
25619
|
-
async function appendLines(home, lines3) {
|
|
25620
|
-
if (lines3.length === 0) return;
|
|
25621
|
-
const path = promptHistoryPath(home);
|
|
25622
|
-
const refused = await notARegularFile(path);
|
|
25623
|
-
if (refused) throw new Error(`${path} is not used: ${refused}.`);
|
|
25624
|
-
const handle = await open(
|
|
25625
|
-
path,
|
|
25626
|
-
constants3.O_WRONLY | constants3.O_APPEND | constants3.O_CREAT | NOFOLLOW,
|
|
25627
|
-
384
|
|
25628
|
-
);
|
|
25629
|
-
try {
|
|
25630
|
-
const entry = await handle.stat();
|
|
25631
|
-
if (!entry.isFile()) throw new Error(`${path} is not used: it is not a regular file.`);
|
|
25632
|
-
if (process.platform !== "win32" && (entry.mode & 63) !== 0) await handle.chmod(384);
|
|
25633
|
-
await handle.write(lines3.map((line) => `${line}
|
|
25634
|
-
`).join(""));
|
|
25635
|
-
} finally {
|
|
25636
|
-
await handle.close();
|
|
25637
|
-
}
|
|
25638
|
-
}
|
|
25639
|
-
__name(appendLines, "appendLines");
|
|
25640
|
-
async function appendPromptHistory(home, entry, options = {}) {
|
|
25641
|
-
try {
|
|
25642
|
-
await mkdir(home, { recursive: true, mode: 448 });
|
|
25643
|
-
await withHistoryLock(home, () => appendLines(home, [JSON.stringify(entry)]), options);
|
|
25644
|
-
return true;
|
|
25645
|
-
} catch {
|
|
25646
|
-
return false;
|
|
25647
|
-
}
|
|
25648
|
-
}
|
|
25649
|
-
__name(appendPromptHistory, "appendPromptHistory");
|
|
25650
|
-
async function readPromptHistory(home) {
|
|
25651
|
-
const path = promptHistoryPath(home);
|
|
25652
|
-
let text;
|
|
25653
|
-
try {
|
|
25654
|
-
if (await notARegularFile(path)) return { entries: [], lines: 0 };
|
|
25655
|
-
const handle = await open(path, constants3.O_RDONLY | NOFOLLOW);
|
|
25656
|
-
try {
|
|
25657
|
-
const size = (await handle.stat()).size;
|
|
25658
|
-
const start2 = Math.max(0, size - MAX_READ_BYTES);
|
|
25659
|
-
const buffer = Buffer.alloc(size - start2);
|
|
25660
|
-
await handle.read(buffer, 0, buffer.length, start2);
|
|
25661
|
-
text = buffer.toString("utf8");
|
|
25662
|
-
if (start2 > 0) text = text.slice(text.indexOf("\n") + 1);
|
|
25663
|
-
} finally {
|
|
25664
|
-
await handle.close();
|
|
25665
|
-
}
|
|
25666
|
-
} catch {
|
|
25667
|
-
return { entries: [], lines: 0 };
|
|
25668
|
-
}
|
|
25669
|
-
const entries = [];
|
|
25670
|
-
let lines3 = 0;
|
|
25671
|
-
for (const line of text.split("\n")) {
|
|
25672
|
-
if (line.trim().length === 0) continue;
|
|
25673
|
-
lines3 += 1;
|
|
25674
|
-
const entry = parsePromptHistoryLine(line);
|
|
25675
|
-
if (entry) entries.push(entry);
|
|
25676
|
-
}
|
|
25677
|
-
return { entries, lines: lines3 };
|
|
25678
|
-
}
|
|
25679
|
-
__name(readPromptHistory, "readPromptHistory");
|
|
25680
|
-
async function loggedPromptsOf(s, sessionId) {
|
|
25681
|
-
let records;
|
|
25682
|
-
try {
|
|
25683
|
-
records = await readConversationRecords(s, sessionId, "tolerant");
|
|
25684
|
-
} catch {
|
|
25685
|
-
return [];
|
|
25686
|
-
}
|
|
25687
|
-
if (!records) return [];
|
|
25688
|
-
const log = openConversationLog(s, sessionId);
|
|
25689
|
-
const out = [];
|
|
25690
|
-
for (const record3 of records.records) {
|
|
25691
|
-
if (record3.type !== "message" || record3.role !== "user") continue;
|
|
25692
|
-
let message = record3.content;
|
|
25693
|
-
if (record3.spill) {
|
|
25694
|
-
try {
|
|
25695
|
-
message = JSON.parse(await log.readSpill(record3.spill));
|
|
25696
|
-
} catch {
|
|
25697
|
-
continue;
|
|
25698
|
-
}
|
|
25699
|
-
}
|
|
25700
|
-
if (message.role !== "user" || message.source || typeof message.content !== "string") continue;
|
|
25701
|
-
if (message.content.trim().length === 0) continue;
|
|
25702
|
-
const at = Date.parse(record3.ts);
|
|
25703
|
-
if (!Number.isFinite(at)) continue;
|
|
25704
|
-
out.push({
|
|
25705
|
-
content: message.content,
|
|
25706
|
-
...message.pasted?.length ? { pasted: message.pasted.map(({ start: start2, end }) => ({ start: start2, end })) } : {},
|
|
25707
|
-
timestamp: at
|
|
25708
|
-
});
|
|
25709
|
-
}
|
|
25710
|
-
return out;
|
|
25711
|
-
}
|
|
25712
|
-
__name(loggedPromptsOf, "loggedPromptsOf");
|
|
25713
|
-
async function pastedTextsOf(s, sessionId) {
|
|
25714
|
-
const out = /* @__PURE__ */ new Map();
|
|
25715
|
-
for (const prompt of await loggedPromptsOf(s, sessionId)) {
|
|
25716
|
-
for (const range of prompt.pasted ?? []) {
|
|
25717
|
-
const piece = prompt.content.slice(range.start, range.end);
|
|
25718
|
-
if (piece.length > 0) out.set(sha256Hex(piece), piece);
|
|
25719
|
-
}
|
|
25720
|
-
}
|
|
25721
|
-
return out;
|
|
25722
|
-
}
|
|
25723
|
-
__name(pastedTextsOf, "pastedTextsOf");
|
|
25724
|
-
function rebuild(entry, pastes) {
|
|
25725
|
-
if (!entry.pasted?.length) return entry.display;
|
|
25726
|
-
let out = "";
|
|
25727
|
-
let at = 0;
|
|
25728
|
-
for (const paste of entry.pasted) {
|
|
25729
|
-
const piece = pastes.get(paste.sha256);
|
|
25730
|
-
if (piece === void 0 || piece.length !== paste.length || paste.offset < at) return void 0;
|
|
25731
|
-
out += entry.display.slice(at, paste.offset) + piece;
|
|
25732
|
-
at = paste.offset;
|
|
25733
|
-
}
|
|
25734
|
-
return out + entry.display.slice(at);
|
|
25735
|
-
}
|
|
25736
|
-
__name(rebuild, "rebuild");
|
|
25737
|
-
async function recallPromptHistory(options) {
|
|
25738
|
-
const { entries } = await readPromptHistory(options.home);
|
|
25739
|
-
const limit = options.limit ?? PROMPT_HISTORY_RECALL;
|
|
25740
|
-
const mine = entries.filter(
|
|
25741
|
-
(entry) => entry.project === options.project && entry.sessionId !== options.excludeSession && (options.before === void 0 || entry.timestamp < options.before)
|
|
25742
|
-
).sort((a, b) => a.timestamp - b.timestamp).slice(-limit);
|
|
25743
|
-
const needed = [...new Set(mine.filter((e) => e.pasted?.length).map((e) => e.sessionId))].slice(-MAX_PASTE_SESSIONS).filter((id) => isEntityId(id, "session"));
|
|
25744
|
-
const pastes = /* @__PURE__ */ new Map();
|
|
25745
|
-
for (const id of needed) {
|
|
25746
|
-
try {
|
|
25747
|
-
pastes.set(id, await options.pastesOf(asSessionId(id)));
|
|
25748
|
-
} catch {
|
|
25749
|
-
pastes.set(id, /* @__PURE__ */ new Map());
|
|
25750
|
-
}
|
|
25751
|
-
}
|
|
25752
|
-
const out = [];
|
|
25753
|
-
for (const entry of mine) {
|
|
25754
|
-
const text = rebuild(entry, pastes.get(entry.sessionId) ?? /* @__PURE__ */ new Map());
|
|
25755
|
-
if (text === void 0 || text === out.at(-1)) continue;
|
|
25756
|
-
out.push(text);
|
|
25757
|
-
}
|
|
25758
|
-
return out;
|
|
25759
|
-
}
|
|
25760
|
-
__name(recallPromptHistory, "recallPromptHistory");
|
|
25761
|
-
async function rewritePromptHistory(home, keep, options = {}) {
|
|
25762
|
-
const path = promptHistoryPath(home);
|
|
25763
|
-
return await withHistoryLock(
|
|
25764
|
-
home,
|
|
25765
|
-
async () => {
|
|
25766
|
-
if (await notARegularFile(path)) return 0;
|
|
25767
|
-
let text;
|
|
25768
|
-
try {
|
|
25769
|
-
text = await readFile4(path, "utf8");
|
|
25770
|
-
} catch (error) {
|
|
25771
|
-
if (error.code === "ENOENT") return 0;
|
|
25772
|
-
throw error;
|
|
25773
|
-
}
|
|
25774
|
-
const raw = text.split("\n").filter((line) => line.trim().length > 0);
|
|
25775
|
-
const parsed = raw.map((line) => parsePromptHistoryLine(line));
|
|
25776
|
-
const entries = parsed.filter((entry) => entry !== void 0);
|
|
25777
|
-
const kept = [];
|
|
25778
|
-
let index = 0;
|
|
25779
|
-
let dropped = 0;
|
|
25780
|
-
for (let i = 0; i < raw.length; i++) {
|
|
25781
|
-
const entry = parsed[i];
|
|
25782
|
-
if (entry === void 0) {
|
|
25783
|
-
kept.push(raw[i]);
|
|
25784
|
-
continue;
|
|
25785
|
-
}
|
|
25786
|
-
if (keep(entry, index++, entries)) kept.push(raw[i]);
|
|
25787
|
-
else dropped += 1;
|
|
25788
|
-
}
|
|
25789
|
-
if (dropped === 0) return 0;
|
|
25790
|
-
const body = kept.map((line) => `${line}
|
|
25791
|
-
`).join("");
|
|
25792
|
-
const temporary = `${path}.${process.pid}.${randomBytes3(4).toString("hex")}.tmp`;
|
|
25793
|
-
const handle = await open(temporary, "wx", 384);
|
|
25794
|
-
try {
|
|
25795
|
-
await handle.writeFile(body, "utf8");
|
|
25796
|
-
await handle.sync();
|
|
25797
|
-
} finally {
|
|
25798
|
-
await handle.close();
|
|
25799
|
-
}
|
|
25800
|
-
try {
|
|
25801
|
-
if (await readFile4(temporary, "utf8") !== body)
|
|
25802
|
-
throw new Error("the new copy did not read back as written");
|
|
25803
|
-
await rename(temporary, path);
|
|
25804
|
-
} catch (error) {
|
|
25805
|
-
await unlink(temporary).catch(() => void 0);
|
|
25806
|
-
throw error;
|
|
25807
|
-
}
|
|
25808
|
-
return dropped;
|
|
25809
|
-
},
|
|
25810
|
-
options
|
|
25811
|
-
);
|
|
25812
|
-
}
|
|
25813
|
-
__name(rewritePromptHistory, "rewritePromptHistory");
|
|
25814
|
-
function newestKept() {
|
|
25815
|
-
let chosen;
|
|
25816
|
-
return (_entry, index, entries) => {
|
|
25817
|
-
chosen ??= new Set(
|
|
25818
|
-
entries.map((e, i) => ({ t: e.timestamp, i })).sort((a, b) => b.t - a.t || b.i - a.i).slice(0, PROMPT_HISTORY_KEEP).map((e) => e.i)
|
|
25819
|
-
);
|
|
25820
|
-
return chosen.has(index);
|
|
25821
|
-
};
|
|
25822
|
-
}
|
|
25823
|
-
__name(newestKept, "newestKept");
|
|
25824
|
-
async function trimPromptHistory(home, lines3, options = {}) {
|
|
25825
|
-
if (lines3 <= PROMPT_HISTORY_KEEP + TRIM_SLACK) return 0;
|
|
25826
|
-
try {
|
|
25827
|
-
return await rewritePromptHistory(home, newestKept(), options);
|
|
25828
|
-
} catch {
|
|
25829
|
-
return 0;
|
|
25830
|
-
}
|
|
25831
|
-
}
|
|
25832
|
-
__name(trimPromptHistory, "trimPromptHistory");
|
|
25833
|
-
async function seedPromptHistory(options) {
|
|
25834
|
-
const marker = join12(options.projectDir, PROMPT_HISTORY_SEEDED_MARKER);
|
|
25835
|
-
const seeded = /* @__PURE__ */ __name(async () => {
|
|
25836
|
-
try {
|
|
25837
|
-
await stat2(marker);
|
|
25838
|
-
return true;
|
|
25839
|
-
} catch {
|
|
25840
|
-
return false;
|
|
25841
|
-
}
|
|
25842
|
-
}, "seeded");
|
|
25843
|
-
if (await seeded()) return 0;
|
|
25844
|
-
const ids = (await options.conversations()).slice(0, PROMPT_HISTORY_SEED_SESSIONS);
|
|
25845
|
-
const candidates = [];
|
|
25846
|
-
for (const id of ids) {
|
|
25847
|
-
for (const prompt of await options.promptsOf(id)) {
|
|
25848
|
-
const entry = promptHistoryEntryFor({
|
|
25849
|
-
text: prompt.content,
|
|
25850
|
-
...prompt.pasted ? { pasted: prompt.pasted } : {},
|
|
25851
|
-
project: options.project,
|
|
25852
|
-
sessionId: id,
|
|
25853
|
-
timestamp: prompt.timestamp
|
|
25854
|
-
});
|
|
25855
|
-
if (entry) candidates.push(entry);
|
|
25856
|
-
}
|
|
25857
|
-
}
|
|
25858
|
-
const key = /* @__PURE__ */ __name((entry) => JSON.stringify([
|
|
25859
|
-
entry.sessionId,
|
|
25860
|
-
entry.display,
|
|
25861
|
-
(entry.pasted ?? []).map((paste) => paste.sha256)
|
|
25862
|
-
]), "key");
|
|
25863
|
-
await mkdir(options.home, { recursive: true, mode: 448 });
|
|
25864
|
-
return await withHistoryLock(
|
|
25865
|
-
options.home,
|
|
25866
|
-
async () => {
|
|
25867
|
-
if (await seeded()) return 0;
|
|
25868
|
-
const present = /* @__PURE__ */ new Map();
|
|
25869
|
-
for (const entry of (await readPromptHistory(options.home)).entries) {
|
|
25870
|
-
const k = key(entry);
|
|
25871
|
-
present.set(k, (present.get(k) ?? 0) + 1);
|
|
25872
|
-
}
|
|
25873
|
-
const fresh = candidates.sort((a, b) => a.timestamp - b.timestamp).filter((entry) => {
|
|
25874
|
-
const k = key(entry);
|
|
25875
|
-
const left = present.get(k) ?? 0;
|
|
25876
|
-
if (left === 0) return true;
|
|
25877
|
-
present.set(k, left - 1);
|
|
25878
|
-
return false;
|
|
25879
|
-
}).slice(-PROMPT_HISTORY_KEEP);
|
|
25880
|
-
await appendLines(
|
|
25881
|
-
options.home,
|
|
25882
|
-
fresh.map((entry) => JSON.stringify(entry))
|
|
25883
|
-
);
|
|
25884
|
-
await writeFile2(marker, `${(/* @__PURE__ */ new Date()).toISOString()}
|
|
25885
|
-
`, { mode: 384, flag: "w" });
|
|
25886
|
-
return fresh.length;
|
|
25887
|
-
},
|
|
25888
|
-
options
|
|
25889
|
-
);
|
|
25890
|
-
}
|
|
25891
|
-
__name(seedPromptHistory, "seedPromptHistory");
|
|
25892
|
-
|
|
25893
|
-
// src/integrations/sessions/cleanup.ts
|
|
25894
25587
|
var DEFAULT_CLEANUP_PERIOD_DAYS = 30;
|
|
25895
25588
|
var CLEANUP_EVERY_MS = 24 * 60 * 60 * 1e3;
|
|
25896
25589
|
var CLEANUP_NOTICE_GRACE_MS = 7 * 24 * 60 * 60 * 1e3;
|
|
@@ -25953,7 +25646,7 @@ function scheduleBoundSessions(home) {
|
|
|
25953
25646
|
if (name.startsWith(".")) continue;
|
|
25954
25647
|
let text;
|
|
25955
25648
|
try {
|
|
25956
|
-
text = readFileSync5(
|
|
25649
|
+
text = readFileSync5(join12(paths.jobs, name), "utf8");
|
|
25957
25650
|
} catch (error) {
|
|
25958
25651
|
if (error.code === "ENOENT") continue;
|
|
25959
25652
|
throw error;
|
|
@@ -25965,7 +25658,7 @@ function scheduleBoundSessions(home) {
|
|
|
25965
25658
|
for (const match of text.matchAll(SESSION_ID_IN_TEXT)) bound.add(match[0]);
|
|
25966
25659
|
}
|
|
25967
25660
|
}
|
|
25968
|
-
for (const name of list(
|
|
25661
|
+
for (const name of list(join12(paths.root, "deliveries"))) bound.add(name);
|
|
25969
25662
|
return bound;
|
|
25970
25663
|
}
|
|
25971
25664
|
__name(scheduleBoundSessions, "scheduleBoundSessions");
|
|
@@ -25997,7 +25690,7 @@ async function newestChange(path) {
|
|
|
25997
25690
|
const current = pending.pop();
|
|
25998
25691
|
let entry;
|
|
25999
25692
|
try {
|
|
26000
|
-
entry = await
|
|
25693
|
+
entry = await lstat2(current);
|
|
26001
25694
|
} catch (error) {
|
|
26002
25695
|
if (error.code === "ENOENT") continue;
|
|
26003
25696
|
throw error;
|
|
@@ -26007,7 +25700,7 @@ async function newestChange(path) {
|
|
|
26007
25700
|
const names = await readdir(current);
|
|
26008
25701
|
seen += names.length;
|
|
26009
25702
|
if (seen > MAX_FOLDER_ENTRIES) return void 0;
|
|
26010
|
-
for (const name of names) pending.push(
|
|
25703
|
+
for (const name of names) pending.push(join12(current, name));
|
|
26011
25704
|
}
|
|
26012
25705
|
return newest;
|
|
26013
25706
|
}
|
|
@@ -26041,7 +25734,7 @@ async function sweepProject(home, slug, cutoff, remove, gates, tally) {
|
|
|
26041
25734
|
if (!await isOld(logPath, dir, cutoff)) continue;
|
|
26042
25735
|
const hasLog = logs.has(raw);
|
|
26043
25736
|
if (hasLog) {
|
|
26044
|
-
const entry = await
|
|
25737
|
+
const entry = await lstat2(logPath);
|
|
26045
25738
|
if (!entry.isFile()) {
|
|
26046
25739
|
tally.kept += 1;
|
|
26047
25740
|
continue;
|
|
@@ -26052,7 +25745,7 @@ async function sweepProject(home, slug, cutoff, remove, gates, tally) {
|
|
|
26052
25745
|
continue;
|
|
26053
25746
|
}
|
|
26054
25747
|
} else {
|
|
26055
|
-
const entry = await
|
|
25748
|
+
const entry = await lstat2(dir);
|
|
26056
25749
|
if (!entry.isDirectory()) continue;
|
|
26057
25750
|
if (isLeaseLive(await readSessionLease(dir).catch(() => null), Date.now())) {
|
|
26058
25751
|
tally.kept += 1;
|
|
@@ -26091,7 +25784,7 @@ async function removeConversation(paths, id, hasLog, cutoff, tempRoot, slug) {
|
|
|
26091
25784
|
});
|
|
26092
25785
|
if (!lease) return false;
|
|
26093
25786
|
const facts = await readConversationFacts({ paths }, id, "tolerant").catch(() => null);
|
|
26094
|
-
const log = await
|
|
25787
|
+
const log = await stat2(logPath).catch(() => void 0);
|
|
26095
25788
|
if (!facts || facts.activeTurn || !log || log.mtimeMs >= cutoff) {
|
|
26096
25789
|
await new DiskSessionLeaseStore(dir).release(lease).catch(() => void 0);
|
|
26097
25790
|
return false;
|
|
@@ -26100,12 +25793,12 @@ async function removeConversation(paths, id, hasLog, cutoff, tempRoot, slug) {
|
|
|
26100
25793
|
}
|
|
26101
25794
|
await rm3(dir, { recursive: true, force: true });
|
|
26102
25795
|
if (tempRoot)
|
|
26103
|
-
await rm3(
|
|
25796
|
+
await rm3(join12(tempRoot, slug, id), { recursive: true, force: true }).catch(() => void 0);
|
|
26104
25797
|
return true;
|
|
26105
25798
|
}
|
|
26106
25799
|
__name(removeConversation, "removeConversation");
|
|
26107
25800
|
async function markCleanupNoticeShown(home, now = Date.now()) {
|
|
26108
|
-
const statePath =
|
|
25801
|
+
const statePath = join12(home, CLEANUP_STATE_FILE);
|
|
26109
25802
|
try {
|
|
26110
25803
|
await withAccountLock(`${statePath}.lock`, async () => {
|
|
26111
25804
|
const state = readState2(statePath);
|
|
@@ -26129,7 +25822,7 @@ async function runCleanup(options) {
|
|
|
26129
25822
|
if (periodDays === void 0 || !Number.isSafeInteger(periodDays) || periodDays < 1)
|
|
26130
25823
|
return NOT_RUN;
|
|
26131
25824
|
const now = options.now ?? Date.now();
|
|
26132
|
-
const statePath =
|
|
25825
|
+
const statePath = join12(home, CLEANUP_STATE_FILE);
|
|
26133
25826
|
return await withAccountLock(`${statePath}.lock`, async () => {
|
|
26134
25827
|
const state = readState2(statePath);
|
|
26135
25828
|
const everyMs = options.everyMs ?? CLEANUP_EVERY_MS;
|
|
@@ -26152,15 +25845,15 @@ async function runCleanup(options) {
|
|
|
26152
25845
|
const tally = { conversations: 0, folders: 0, kept: 0 };
|
|
26153
25846
|
let slugs = [];
|
|
26154
25847
|
try {
|
|
26155
|
-
const projects =
|
|
26156
|
-
const top = await
|
|
25848
|
+
const projects = join12(home, "projects");
|
|
25849
|
+
const top = await lstat2(projects);
|
|
26157
25850
|
if (top.isDirectory() && !top.isSymbolicLink()) slugs = await readdir(projects);
|
|
26158
25851
|
} catch {
|
|
26159
25852
|
slugs = [];
|
|
26160
25853
|
}
|
|
26161
25854
|
for (const slug of slugs) {
|
|
26162
25855
|
try {
|
|
26163
|
-
const entry = await
|
|
25856
|
+
const entry = await lstat2(join12(home, "projects", slug));
|
|
26164
25857
|
if (!entry.isDirectory() || entry.isSymbolicLink()) continue;
|
|
26165
25858
|
} catch {
|
|
26166
25859
|
continue;
|
|
@@ -26183,7 +25876,7 @@ async function runCleanup(options) {
|
|
|
26183
25876
|
now,
|
|
26184
25877
|
keep: gates.keep,
|
|
26185
25878
|
isSessionLive: /* @__PURE__ */ __name(async (slug, sessionId) => gates.onScreen.has(sessionId) || isLeaseLive(
|
|
26186
|
-
await readSessionLease(
|
|
25879
|
+
await readSessionLease(join12(home, "projects", slug, sessionId)),
|
|
26187
25880
|
Date.now()
|
|
26188
25881
|
), "isSessionLive")
|
|
26189
25882
|
}).catch(() => void 0);
|
|
@@ -26191,7 +25884,7 @@ async function runCleanup(options) {
|
|
|
26191
25884
|
if (!options.explicit && !told && tally.conversations > 0) {
|
|
26192
25885
|
const from = new Date(now + CLEANUP_NOTICE_GRACE_MS).toISOString().slice(0, 10);
|
|
26193
25886
|
const count2 = tally.conversations === 1 ? "1 conversation" : `${tally.conversations} conversations`;
|
|
26194
|
-
notice = `Namzu keeps conversations on this computer for ${periodDays} days. From ${from} it removes older ones: ${count2} now. To keep them longer, set cleanupPeriodDays in ${options.settingsFile ??
|
|
25887
|
+
notice = `Namzu keeps conversations on this computer for ${periodDays} days. From ${from} it removes older ones: ${count2} now. To keep them longer, set cleanupPeriodDays in ${options.settingsFile ?? join12(home, "config.yaml")}, for example to 3650.`;
|
|
26195
25888
|
}
|
|
26196
25889
|
return {
|
|
26197
25890
|
ran: true,
|
|
@@ -26286,7 +25979,7 @@ async function cleanupOnStart(start2, show2) {
|
|
|
26286
25979
|
}
|
|
26287
25980
|
return answer;
|
|
26288
25981
|
}, "isTrusted"),
|
|
26289
|
-
settingsFile: homePath(
|
|
25982
|
+
settingsFile: homePath(join13(root, "config.yaml"))
|
|
26290
25983
|
});
|
|
26291
25984
|
if (report.notice && show2(report.notice)) await markCleanupNoticeShown(root);
|
|
26292
25985
|
}
|
|
@@ -26662,13 +26355,13 @@ async function fastModeVerdict(providerId, model, options = {}) {
|
|
|
26662
26355
|
if (tier === "ultrafast") {
|
|
26663
26356
|
return refuse("Ultrafast is not offered on Anthropic models. /fast turns on fast mode.");
|
|
26664
26357
|
}
|
|
26665
|
-
const { resolveFastModeVerdict: resolveFastModeVerdict2 } = await import("./dist-
|
|
26358
|
+
const { resolveFastModeVerdict: resolveFastModeVerdict2 } = await import("./dist-V43PPTPF.js");
|
|
26666
26359
|
const verdict2 = resolveFastModeVerdict2(model, now);
|
|
26667
26360
|
return verdict2.ok ? { ok: true, provider: "anthropic", tier: "fast", rate: { kind: "billing", multiplier: 2 } } : refuse(verdict2.reason);
|
|
26668
26361
|
}
|
|
26669
26362
|
if (!model) return refuse("Fast mode needs a model; pick one with /model.");
|
|
26670
26363
|
const otherHost = providerId === "openai" ? options.otherHost === void 0 ? openAIThirdPartyHost() ?? null : options.otherHost : null;
|
|
26671
|
-
const { resolveFastModeVerdict } = await import("./dist-
|
|
26364
|
+
const { resolveFastModeVerdict } = await import("./dist-5G52QS75.js");
|
|
26672
26365
|
const verdict = resolveFastModeVerdict({
|
|
26673
26366
|
route: providerId === "openai" ? "api" : "subscription",
|
|
26674
26367
|
model,
|
|
@@ -26808,15 +26501,15 @@ function messageLines(message, hasPrev, raw, columns) {
|
|
|
26808
26501
|
${hiddenTextRule(hiddenTextNote(cut3), 20)}
|
|
26809
26502
|
${cut3.tail}`;
|
|
26810
26503
|
const group = message.group !== void 0 && !isOneCommand(message.group) ? message.group : void 0;
|
|
26811
|
-
const
|
|
26504
|
+
const open = group !== void 0 && message.pending === true;
|
|
26812
26505
|
return [
|
|
26813
26506
|
...hasPrev && message.glyph !== "\u23BF" ? [""] : [],
|
|
26814
|
-
` ${shown}${meta ? ` \xB7 ${meta}` : ""}${
|
|
26507
|
+
` ${shown}${meta ? ` \xB7 ${meta}` : ""}${open ? ` ${EXPAND_HINT}` : ""}`,
|
|
26815
26508
|
...(message.attachments ?? []).map((row2) => ` ${terminalDisplayText(attachmentLine(row2))}`),
|
|
26816
26509
|
...group ? commandRows(group, (columns ?? 80) - COMMAND_ROW_INDENT - 1).map(
|
|
26817
26510
|
(line) => ` ${terminalDisplayText(line)}`
|
|
26818
26511
|
) : [],
|
|
26819
|
-
...
|
|
26512
|
+
...open && group ? hintRows(group).map((line) => ` ${terminalDisplayText(line)}`) : [],
|
|
26820
26513
|
...renderedDetailLines(message, columns)
|
|
26821
26514
|
];
|
|
26822
26515
|
}
|
|
@@ -26969,8 +26662,8 @@ __name(memoryUsedRow, "memoryUsedRow");
|
|
|
26969
26662
|
function nextTask(tasks) {
|
|
26970
26663
|
const pending = tasks.filter((task) => task.status === "pending");
|
|
26971
26664
|
if (pending.length === 0) return void 0;
|
|
26972
|
-
const
|
|
26973
|
-
return pending.find((task) => !(task.blockedBy ?? []).some((id) =>
|
|
26665
|
+
const open = new Set(tasks.filter((task) => task.status !== "completed").map((task) => task.id));
|
|
26666
|
+
return pending.find((task) => !(task.blockedBy ?? []).some((id) => open.has(id))) ?? pending[0];
|
|
26974
26667
|
}
|
|
26975
26668
|
__name(nextTask, "nextTask");
|
|
26976
26669
|
function nextTaskLine(task) {
|
|
@@ -26978,6 +26671,69 @@ function nextTaskLine(task) {
|
|
|
26978
26671
|
}
|
|
26979
26672
|
__name(nextTaskLine, "nextTaskLine");
|
|
26980
26673
|
|
|
26674
|
+
// src/tui/notice-display.ts
|
|
26675
|
+
var NOTICE_FRAME = /^<namzu-notice-([0-9a-f]+) kind="[a-z-]+">\n[^\n]*\n(?:Namzu sent this automatically[^\n]*\n)?[^\n]*\n([\s\S]*)\n<\/namzu-notice-\1>$/;
|
|
26676
|
+
function withoutNoticeFrame(text) {
|
|
26677
|
+
const trimmed = text.trim();
|
|
26678
|
+
const inside = NOTICE_FRAME.exec(trimmed)?.[2];
|
|
26679
|
+
return inside === void 0 ? text : inside;
|
|
26680
|
+
}
|
|
26681
|
+
__name(withoutNoticeFrame, "withoutNoticeFrame");
|
|
26682
|
+
var WORKFLOW_HEAD = /^Workflow "(.+)" \([0-9a-z]+\) (completed|failed|was stopped)/;
|
|
26683
|
+
var USAGE = /^<usage>(.*)<\/usage>$/m;
|
|
26684
|
+
var JOB_HEAD = /^Background job \S+ \((.*)\) (exited with code (\d+)|was stopped)/;
|
|
26685
|
+
function usageNumber(usage, key) {
|
|
26686
|
+
const found = new RegExp(`(?:^|, )${key}: (\\d+)`).exec(usage)?.[1];
|
|
26687
|
+
return found === void 0 ? void 0 : Number(found);
|
|
26688
|
+
}
|
|
26689
|
+
__name(usageNumber, "usageNumber");
|
|
26690
|
+
function workflowLine(text) {
|
|
26691
|
+
const head2 = WORKFLOW_HEAD.exec(text);
|
|
26692
|
+
if (!head2) return void 0;
|
|
26693
|
+
const word = head2[2] === "completed" ? "finished" : head2[2] === "failed" ? "failed" : "stopped";
|
|
26694
|
+
const usage = USAGE.exec(text)?.[1] ?? "";
|
|
26695
|
+
const duration = /duration: ([^,<]+)/.exec(usage)?.[1]?.trim();
|
|
26696
|
+
const agents = usageNumber(usage, "agents");
|
|
26697
|
+
const tokens = usageNumber(usage, "tokens");
|
|
26698
|
+
return [
|
|
26699
|
+
`Workflow ${head2[1].replace(/\s+/g, " ")} ${word}`,
|
|
26700
|
+
...duration ? [duration] : [],
|
|
26701
|
+
...agents !== void 0 && agents > 0 ? [workflowAgentTotal(agents)] : [],
|
|
26702
|
+
...tokens !== void 0 && tokens > 0 ? [`${formatCompactCount(tokens)} tokens`] : []
|
|
26703
|
+
].join(" \xB7 ");
|
|
26704
|
+
}
|
|
26705
|
+
__name(workflowLine, "workflowLine");
|
|
26706
|
+
function jobLines(text) {
|
|
26707
|
+
const out = [];
|
|
26708
|
+
for (const line of text.split("\n")) {
|
|
26709
|
+
const job = JOB_HEAD.exec(line.replace(/^- /, ""));
|
|
26710
|
+
if (!job) continue;
|
|
26711
|
+
out.push(
|
|
26712
|
+
jobExitRow({
|
|
26713
|
+
command: job[1],
|
|
26714
|
+
status: job[2] === "was stopped" ? "killed" : "exited",
|
|
26715
|
+
...job[3] !== void 0 ? { exitCode: Number(job[3]) } : {}
|
|
26716
|
+
}).text
|
|
26717
|
+
);
|
|
26718
|
+
}
|
|
26719
|
+
return out;
|
|
26720
|
+
}
|
|
26721
|
+
__name(jobLines, "jobLines");
|
|
26722
|
+
function noticeDisplay(content) {
|
|
26723
|
+
const body = withoutUntrustedFrames(withoutNoticeFrame(content)).trim();
|
|
26724
|
+
const workflow = workflowLine(body);
|
|
26725
|
+
if (workflow !== void 0) return { label: workflow, detail: [] };
|
|
26726
|
+
const jobs = jobLines(body);
|
|
26727
|
+
if (jobs.length > 0) {
|
|
26728
|
+
return {
|
|
26729
|
+
label: jobs.length === 1 ? jobs[0] : `${jobs[0]} and ${jobs.length - 1} more`,
|
|
26730
|
+
detail: []
|
|
26731
|
+
};
|
|
26732
|
+
}
|
|
26733
|
+
return { detail: [body.replace(/<\/?namzu-(?:notice|untrusted)-[^>]*>/g, "")] };
|
|
26734
|
+
}
|
|
26735
|
+
__name(noticeDisplay, "noticeDisplay");
|
|
26736
|
+
|
|
26981
26737
|
// src/tui/notices.ts
|
|
26982
26738
|
function isRepeatedNotice(last, candidate) {
|
|
26983
26739
|
if (!last || candidate.role !== "system" || last.role !== "system") return false;
|
|
@@ -27274,7 +27030,7 @@ var AskQueue = class {
|
|
|
27274
27030
|
};
|
|
27275
27031
|
|
|
27276
27032
|
// src/tui/plugin-view.ts
|
|
27277
|
-
import { join as
|
|
27033
|
+
import { join as join14 } from "node:path";
|
|
27278
27034
|
function pluginOption(plugin) {
|
|
27279
27035
|
return {
|
|
27280
27036
|
label: plugin.name,
|
|
@@ -27318,9 +27074,9 @@ function emptyPluginReport(config, cwd) {
|
|
|
27318
27074
|
const reason = config?.enabled !== true ? "Plugins are off. Set plugins.enabled: true in your Namzu configuration to load trusted plugins at startup." : config.autoDiscovery === false ? "Plugin discovery is off (plugins.autoDiscovery: false)." : scopes.length === 0 ? "No plugin scopes are allowed (plugins.allowedScopes: [])." : "No plugins are loaded in this conversation.";
|
|
27319
27075
|
return [
|
|
27320
27076
|
reason,
|
|
27321
|
-
`Configuration: ${
|
|
27322
|
-
...scopes.includes("project") ? [`Project plugins: ${
|
|
27323
|
-
...scopes.includes("user") ? [`User plugins: ${
|
|
27077
|
+
`Configuration: ${join14(home, "config.yaml")}`,
|
|
27078
|
+
...scopes.includes("project") ? [`Project plugins: ${join14(cwd, ".namzu", "plugins")}`] : [],
|
|
27079
|
+
...scopes.includes("user") ? [`User plugins: ${join14(home, "plugins")}`] : [],
|
|
27324
27080
|
"Each plugin directory contains plugin.json. Only Namzu plugin manifests are supported.",
|
|
27325
27081
|
"Tools, hooks and MCP servers can execute code. Enable only plugins you trust, then restart Namzu."
|
|
27326
27082
|
].map(choiceDisplayText).join("\n");
|
|
@@ -27935,7 +27691,7 @@ __name(noResumeText, "noResumeText");
|
|
|
27935
27691
|
import { isAbsolute as isAbsolute4, relative as relative3, resolve as resolve4 } from "node:path";
|
|
27936
27692
|
|
|
27937
27693
|
// src/tui/schedule/loop-host.ts
|
|
27938
|
-
import { randomBytes as
|
|
27694
|
+
import { randomBytes as randomBytes3 } from "node:crypto";
|
|
27939
27695
|
import { readFileSync as readFileSync6 } from "node:fs";
|
|
27940
27696
|
var MAX_LOOPS = 20;
|
|
27941
27697
|
var LOOP_LIFETIME_MS = 7 * 24 * 60 * 60 * 1e3;
|
|
@@ -28003,7 +27759,7 @@ var SessionLoopScheduler = class {
|
|
|
28003
27759
|
const now = new Date(this.#now());
|
|
28004
27760
|
const spec = request.interval === void 0 ? void 0 : loopSpec(request.interval, now);
|
|
28005
27761
|
const loop = {
|
|
28006
|
-
id:
|
|
27762
|
+
id: randomBytes3(3).toString("hex"),
|
|
28007
27763
|
schedule: spec ? describeSchedule(spec, { tz: hostTimeZone() }) : "self-paced",
|
|
28008
27764
|
prompt: request.prompt,
|
|
28009
27765
|
createdAt: now.toISOString(),
|
|
@@ -28163,7 +27919,7 @@ function describeLoopSchedule(l) {
|
|
|
28163
27919
|
__name(describeLoopSchedule, "describeLoopSchedule");
|
|
28164
27920
|
|
|
28165
27921
|
// src/tui/schedule/host-commands.ts
|
|
28166
|
-
var
|
|
27922
|
+
var USAGE2 = [
|
|
28167
27923
|
"/schedule jobs, and what needs you",
|
|
28168
27924
|
"/schedule confirm <job> confirm a job created without a terminal, or held after an edit",
|
|
28169
27925
|
"/schedule pause|resume <job>",
|
|
@@ -28390,7 +28146,7 @@ async function runScheduleCommand(args, ctx) {
|
|
|
28390
28146
|
ctx.say(await listScheduleJobs(ctx));
|
|
28391
28147
|
return;
|
|
28392
28148
|
case "help":
|
|
28393
|
-
say(
|
|
28149
|
+
say(USAGE2);
|
|
28394
28150
|
return;
|
|
28395
28151
|
case "confirm": {
|
|
28396
28152
|
const job = findJob(paths, rest[0] ?? "");
|
|
@@ -28532,7 +28288,7 @@ For anything else: namzu schedule add --help`
|
|
|
28532
28288
|
return;
|
|
28533
28289
|
}
|
|
28534
28290
|
default:
|
|
28535
|
-
say(
|
|
28291
|
+
say(USAGE2);
|
|
28536
28292
|
}
|
|
28537
28293
|
} catch (error) {
|
|
28538
28294
|
say(
|
|
@@ -28703,7 +28459,7 @@ function scheduledResumeMismatch(job, environment) {
|
|
|
28703
28459
|
reasons.push("the job has no model; edit and confirm it again");
|
|
28704
28460
|
} else if (job.model && environment.providers && !environment.providers.includes(job.model.provider)) {
|
|
28705
28461
|
reasons.push(
|
|
28706
|
-
`the job runs on ${job.model.provider}${job.model.model ? `/${job.model.model}` : ""} and this conversation has no credential for ${job.model.provider} (sign in with \`namzu login\`, or set its API key)`
|
|
28462
|
+
`the job runs on ${job.model.provider}${job.model.model ? `/${job.model.model}` : ""} and this conversation has no credential for ${job.model.provider} (sign in with \`namzu auth login\`, or set its API key)`
|
|
28707
28463
|
);
|
|
28708
28464
|
}
|
|
28709
28465
|
return reasons;
|
|
@@ -28847,7 +28603,7 @@ __name(prepareScheduledResume, "prepareScheduledResume");
|
|
|
28847
28603
|
|
|
28848
28604
|
// src/tui/schedule/startup.ts
|
|
28849
28605
|
import { readFileSync as readFileSync7 } from "node:fs";
|
|
28850
|
-
import { join as
|
|
28606
|
+
import { join as join15 } from "node:path";
|
|
28851
28607
|
function ago(ms) {
|
|
28852
28608
|
if (ms < 36e5) return `${Math.max(1, Math.round(ms / 6e4))} min`;
|
|
28853
28609
|
if (ms < 1728e5) return `${Math.round(ms / 36e5)} h`;
|
|
@@ -28931,7 +28687,7 @@ function scheduleStartupLine(home, cwd, now = Date.now()) {
|
|
|
28931
28687
|
parts.push("The scheduler is installed but has not started \u2014 namzu schedule service status");
|
|
28932
28688
|
}
|
|
28933
28689
|
}
|
|
28934
|
-
const suppressed = takeSuppressedCount(
|
|
28690
|
+
const suppressed = takeSuppressedCount(join15(paths.daemon, "notify.json"));
|
|
28935
28691
|
if (suppressed > 0)
|
|
28936
28692
|
parts.push(
|
|
28937
28693
|
`${plural(suppressed, "scheduled notification")} ${suppressed === 1 ? "was" : "were"} held back`
|
|
@@ -28949,7 +28705,7 @@ function scheduleStartupLine(home, cwd, now = Date.now()) {
|
|
|
28949
28705
|
__name(scheduleStartupLine, "scheduleStartupLine");
|
|
28950
28706
|
|
|
28951
28707
|
// src/tui/schedule/timer-host.ts
|
|
28952
|
-
import { randomBytes as
|
|
28708
|
+
import { randomBytes as randomBytes4 } from "node:crypto";
|
|
28953
28709
|
var MAX_TIMERS = 50;
|
|
28954
28710
|
var TIMER_LIFETIME_MS = 7 * 24 * 60 * 60 * 1e3;
|
|
28955
28711
|
var RECURRING_JITTER_FRACTION = 0.5;
|
|
@@ -29021,7 +28777,7 @@ var SessionTimerScheduler = class {
|
|
|
29021
28777
|
const now = this.#now();
|
|
29022
28778
|
const spec = timerSpec(request.when, request.recurring, new Date(now));
|
|
29023
28779
|
const recurring = request.recurring && spec.kind !== "at";
|
|
29024
|
-
const id =
|
|
28780
|
+
const id = randomBytes4(3).toString("hex");
|
|
29025
28781
|
const jitter = Number.parseInt(id, 16) / 16777216;
|
|
29026
28782
|
const nextAt = this.#plan(spec, recurring, jitter, now, now);
|
|
29027
28783
|
if (nextAt === null) throw new Error(`"${request.when}" does not fire again.`);
|
|
@@ -29131,7 +28887,7 @@ async function credentialText(provider) {
|
|
|
29131
28887
|
(d) => d.entry.id === provider
|
|
29132
28888
|
);
|
|
29133
28889
|
if (!found)
|
|
29134
|
-
return `no ${provider} credential found here; the scheduler must find one (namzu login or daemon.env)`;
|
|
28890
|
+
return `no ${provider} credential found here; the scheduler must find one (namzu auth login or daemon.env)`;
|
|
29135
28891
|
const source = found.source;
|
|
29136
28892
|
return source.kind === "env" ? `environment variable ${source.envName ?? ""} (a service does not see your shell\u2019s variables)` : `${source.kind}${source.path ? ` (${source.path})` : ""}`;
|
|
29137
28893
|
} catch {
|
|
@@ -30177,11 +29933,11 @@ __name(setSkillSuggestions, "setSkillSuggestions");
|
|
|
30177
29933
|
|
|
30178
29934
|
// src/tui/skills/suggestion-ledger.ts
|
|
30179
29935
|
import { mkdirSync as mkdirSync5, readFileSync as readFileSync8, renameSync as renameSync4, writeFileSync as writeFileSync5 } from "node:fs";
|
|
30180
|
-
import { dirname as dirname2, join as
|
|
29936
|
+
import { dirname as dirname2, join as join16 } from "node:path";
|
|
30181
29937
|
var SUGGESTION_IGNORE_LIMIT = 3;
|
|
30182
29938
|
var FRESH_LEDGER = { v: 1, unanswered: 0, stopped: false };
|
|
30183
29939
|
function suggestionLedgerPath(namzuHome) {
|
|
30184
|
-
return
|
|
29940
|
+
return join16(namzuHome, "skills", ".suggestions.json");
|
|
30185
29941
|
}
|
|
30186
29942
|
__name(suggestionLedgerPath, "suggestionLedgerPath");
|
|
30187
29943
|
function readSuggestionLedger(namzuHome) {
|
|
@@ -30500,6 +30256,35 @@ function describeComposerTriggers(enabledNow, opts = {}) {
|
|
|
30500
30256
|
}
|
|
30501
30257
|
__name(describeComposerTriggers, "describeComposerTriggers");
|
|
30502
30258
|
|
|
30259
|
+
// src/tui/turn-duration-setting.ts
|
|
30260
|
+
function describeTurnDuration(on) {
|
|
30261
|
+
return on ? "Turn duration is on: each reply ends with how long it took and when it finished. /config showTurnDuration off turns it off." : "Turn duration is off: replies end without the time line. /config showTurnDuration on turns it back on.";
|
|
30262
|
+
}
|
|
30263
|
+
__name(describeTurnDuration, "describeTurnDuration");
|
|
30264
|
+
function setShowTurnDuration(on, opts = {}) {
|
|
30265
|
+
try {
|
|
30266
|
+
setUserConfigValue(["tui", "showTurnDuration"], on, {
|
|
30267
|
+
...opts.home ? { home: opts.home } : {},
|
|
30268
|
+
...opts.env ? { env: opts.env } : {}
|
|
30269
|
+
});
|
|
30270
|
+
} catch (error) {
|
|
30271
|
+
return `${explainFailure(error, "Could not save that setting.")} This conversation ${on ? "shows" : "hides"} the turn duration until it ends.`;
|
|
30272
|
+
}
|
|
30273
|
+
const saved = describeTurnDuration(on);
|
|
30274
|
+
let resolved;
|
|
30275
|
+
try {
|
|
30276
|
+
resolved = loadConfigWithProvenance(opts);
|
|
30277
|
+
} catch (error) {
|
|
30278
|
+
return `${saved} ${explainFailure(error, "Could not check the other config files.")} This conversation follows your choice.`;
|
|
30279
|
+
}
|
|
30280
|
+
const effective = resolved.config.tui?.showTurnDuration ?? DEFAULT_SHOW_TURN_DURATION;
|
|
30281
|
+
if (effective === on) return saved;
|
|
30282
|
+
const source = resolved.provenance.tui;
|
|
30283
|
+
const winner = source ? formatConfigSource(source) : "another config layer";
|
|
30284
|
+
return `${saved} But ${winner} turns it ${effective ? "on" : "off"}, so from the next start it will be ${effective ? "on" : "off"}; this conversation follows your choice.`;
|
|
30285
|
+
}
|
|
30286
|
+
__name(setShowTurnDuration, "setShowTurnDuration");
|
|
30287
|
+
|
|
30503
30288
|
// src/tui/typed-input.ts
|
|
30504
30289
|
function typedInputOf(prompt) {
|
|
30505
30290
|
if (prompt.kind !== "human" || prompt.skillFlow === true) return void 0;
|
|
@@ -31131,22 +30916,23 @@ function describeBrowserHandoff(handoff, browser) {
|
|
|
31131
30916
|
if (detail.cause === "http-auth") {
|
|
31132
30917
|
if (browser && !browser.headless) {
|
|
31133
30918
|
return `${lead}
|
|
31134
|
-
Check access to ${origin} in the browser window (profile ${profile}). If authentication succeeds, press Enter to continue, or Esc to stop.`;
|
|
30919
|
+
Check access to ${origin} in the browser window (profile ${profile}). If authentication succeeds, press Enter to continue, type a message to answer instead, or press Esc to stop.`;
|
|
31135
30920
|
}
|
|
31136
30921
|
return `${lead}
|
|
31137
30922
|
This browser has no window, so Namzu closed it to free the profile. In another terminal run:
|
|
31138
30923
|
${command}
|
|
31139
|
-
Check access in the window it opens, then close it. If authentication succeeds, press Enter here to continue, or Esc to stop.`;
|
|
30924
|
+
Check access in the window it opens, then close it. If authentication succeeds, press Enter here to continue, type a message to answer instead, or press Esc to stop.`;
|
|
31140
30925
|
}
|
|
31141
30926
|
if (browser && !browser.headless) {
|
|
31142
30927
|
const verb = AT_THE_WINDOW[detail.cause ?? ""] ?? "sign in to";
|
|
31143
30928
|
return `${lead}
|
|
31144
|
-
${verb.charAt(0).toUpperCase()}${verb.slice(1)} ${origin} in the browser window (profile ${profile}), then press Enter to continue, or Esc to stop
|
|
30929
|
+
${verb.charAt(0).toUpperCase()}${verb.slice(1)} ${origin} in the browser window (profile ${profile}), then press Enter to continue, type a message to answer instead, or press Esc to stop.
|
|
30930
|
+
This is Namzu's own browser profile, not the browser you use every day, so a sign-in there is not visible here. It is remembered for next time.`;
|
|
31145
30931
|
}
|
|
31146
30932
|
return `${lead}
|
|
31147
30933
|
This browser has no window, so Namzu closed it to free the profile. In another terminal run:
|
|
31148
30934
|
${command}
|
|
31149
|
-
sign in in the window it opens, close it, then press Enter here to continue, or Esc to stop.`;
|
|
30935
|
+
sign in in the window it opens, close it, then press Enter here to continue, type a message to answer instead, or press Esc to stop.`;
|
|
31150
30936
|
}
|
|
31151
30937
|
__name(describeBrowserHandoff, "describeBrowserHandoff");
|
|
31152
30938
|
function browserSiteNotes(toolCalls, browser) {
|
|
@@ -31212,7 +30998,7 @@ var EXIT_HINT_MS = 800;
|
|
|
31212
30998
|
// src/tui/extension-indicators.ts
|
|
31213
30999
|
var import_react23 = __toESM(require_react(), 1);
|
|
31214
31000
|
import { existsSync as existsSync3 } from "node:fs";
|
|
31215
|
-
import { join as
|
|
31001
|
+
import { join as join17 } from "node:path";
|
|
31216
31002
|
function useExtensionIndicators() {
|
|
31217
31003
|
const [marks, setMarks] = (0, import_react23.useState)([]);
|
|
31218
31004
|
(0, import_react23.useEffect)(() => {
|
|
@@ -31220,7 +31006,7 @@ function useExtensionIndicators() {
|
|
|
31220
31006
|
let off;
|
|
31221
31007
|
let shared;
|
|
31222
31008
|
try {
|
|
31223
|
-
if (!existsSync3(
|
|
31009
|
+
if (!existsSync3(join17(namzuHomePath(), "extensions"))) return;
|
|
31224
31010
|
const host = sharedExtensionHost("cli");
|
|
31225
31011
|
shared = host;
|
|
31226
31012
|
const read = /* @__PURE__ */ __name(() => {
|
|
@@ -31812,7 +31598,8 @@ function createRestoredTurnWriter(messages, nextId, options) {
|
|
|
31812
31598
|
Math.max(0, turn.endedAt - turn.startedAt),
|
|
31813
31599
|
stand,
|
|
31814
31600
|
new Date(turn.endedAt),
|
|
31815
|
-
turn.agentTokens
|
|
31601
|
+
turn.agentTokens,
|
|
31602
|
+
options.showTurnDuration ?? DEFAULT_SHOW_TURN_DURATION
|
|
31816
31603
|
) : void 0;
|
|
31817
31604
|
if (line)
|
|
31818
31605
|
rows.push({
|
|
@@ -32124,6 +31911,47 @@ function describeShellEscape(command, result) {
|
|
|
32124
31911
|
}
|
|
32125
31912
|
__name(describeShellEscape, "describeShellEscape");
|
|
32126
31913
|
|
|
31914
|
+
// src/tui/sign-in-watch.ts
|
|
31915
|
+
var SIGNIN_POLL_MS = 3e3;
|
|
31916
|
+
var SIGNIN_WATCH_MS = 10 * 6e4;
|
|
31917
|
+
var SIGNIN_CLEARED_LOOKS = 2;
|
|
31918
|
+
var SIGNIN_AUTO_RESUME_CAP = 2;
|
|
31919
|
+
function startSignInWatch(options) {
|
|
31920
|
+
const pollMs = options.pollMs ?? SIGNIN_POLL_MS;
|
|
31921
|
+
let stopped = false;
|
|
31922
|
+
let looking = false;
|
|
31923
|
+
let cleared = 0;
|
|
31924
|
+
const finish = /* @__PURE__ */ __name(() => {
|
|
31925
|
+
stopped = true;
|
|
31926
|
+
clearInterval(poll);
|
|
31927
|
+
clearTimeout(limit);
|
|
31928
|
+
}, "finish");
|
|
31929
|
+
const poll = setInterval(() => {
|
|
31930
|
+
if (stopped || looking) return;
|
|
31931
|
+
if (options.ready && !options.ready()) {
|
|
31932
|
+
cleared = 0;
|
|
31933
|
+
return;
|
|
31934
|
+
}
|
|
31935
|
+
looking = true;
|
|
31936
|
+
void options.peek().catch(() => "unknown").then((answer) => {
|
|
31937
|
+
looking = false;
|
|
31938
|
+
if (stopped) return;
|
|
31939
|
+
cleared = answer === "cleared" ? cleared + 1 : 0;
|
|
31940
|
+
if (cleared >= SIGNIN_CLEARED_LOOKS) {
|
|
31941
|
+
finish();
|
|
31942
|
+
options.onCleared();
|
|
31943
|
+
}
|
|
31944
|
+
});
|
|
31945
|
+
}, pollMs);
|
|
31946
|
+
const limit = setTimeout(() => {
|
|
31947
|
+
if (stopped) return;
|
|
31948
|
+
finish();
|
|
31949
|
+
options.onTimeout();
|
|
31950
|
+
}, options.watchMs ?? SIGNIN_WATCH_MS);
|
|
31951
|
+
return finish;
|
|
31952
|
+
}
|
|
31953
|
+
__name(startSignInWatch, "startSignInWatch");
|
|
31954
|
+
|
|
32127
31955
|
// src/tui/status-line/output.ts
|
|
32128
31956
|
var ESC3 = "\\x1b";
|
|
32129
31957
|
var BEL = "\\x07";
|
|
@@ -32493,6 +32321,25 @@ function useStatusLine(options) {
|
|
|
32493
32321
|
}
|
|
32494
32322
|
__name(useStatusLine, "useStatusLine");
|
|
32495
32323
|
|
|
32324
|
+
// src/tui/stopped-turn-line.ts
|
|
32325
|
+
function isCallNotRun(output) {
|
|
32326
|
+
if (output === void 0) return false;
|
|
32327
|
+
if (isReviewRefusalResult(output)) return true;
|
|
32328
|
+
const match = /^Error: Tool "[^"]*" was not executed\. /.exec(output);
|
|
32329
|
+
if (match === null) return false;
|
|
32330
|
+
const reason = output.slice(match[0].length);
|
|
32331
|
+
return reason.startsWith(AUTO_REVIEW_UNAVAILABLE_PREFIX) || reason.startsWith(AUTO_REVIEW_BLOCKED_PREFIX);
|
|
32332
|
+
}
|
|
32333
|
+
__name(isCallNotRun, "isCallNotRun");
|
|
32334
|
+
function stoppedTurnLine(input) {
|
|
32335
|
+
const changed2 = input.outcome?.changes.total ?? 0;
|
|
32336
|
+
const maybe = input.outcome !== void 0 && (input.outcome.verdict === "unknown" || input.outcome.changes.outsideKnownTools === true);
|
|
32337
|
+
const done = changed2 > 0 ? `changed ${changed2} ${changed2 === 1 ? "file" : "files"} so far${maybe ? " and a command may have changed more" : ""}` : maybe ? "some files may have changed" : "nothing was changed";
|
|
32338
|
+
const left = input.notRun > 0 ? `${input.notRun} ${input.notRun === 1 ? "call" : "calls"} not run` : "the rest of the task is not done";
|
|
32339
|
+
return `Stopped before the task was finished \xB7 ${done} \xB7 ${left} \xB7 send a message to carry on`;
|
|
32340
|
+
}
|
|
32341
|
+
__name(stoppedTurnLine, "stoppedTurnLine");
|
|
32342
|
+
|
|
32496
32343
|
// src/tui/terminal-title.ts
|
|
32497
32344
|
var DEFAULT_TERMINAL_TITLE = "Namzu";
|
|
32498
32345
|
var IDLE_TITLE_GLYPH = "\u2733";
|
|
@@ -32812,13 +32659,13 @@ function useReadSearchGroup(setMessages, nextId, takeThinking) {
|
|
|
32812
32659
|
const openRef = (0, import_react29.useRef)(null);
|
|
32813
32660
|
const start2 = (0, import_react29.useCallback)(
|
|
32814
32661
|
(memberKey, op, section) => {
|
|
32815
|
-
const
|
|
32816
|
-
if (
|
|
32817
|
-
|
|
32818
|
-
|
|
32819
|
-
|
|
32820
|
-
if (section)
|
|
32821
|
-
const { id: id2, state: state2, detail: detail2 } =
|
|
32662
|
+
const open = openRef.current;
|
|
32663
|
+
if (open) {
|
|
32664
|
+
open.state = foldOp(open.state, op);
|
|
32665
|
+
open.ops.push({ key: memberKey, op });
|
|
32666
|
+
open.members.add(memberKey);
|
|
32667
|
+
if (section) open.detail = joinSections(open.detail, section);
|
|
32668
|
+
const { id: id2, state: state2, detail: detail2 } = open;
|
|
32822
32669
|
const more = takeThinking?.();
|
|
32823
32670
|
setMessages(
|
|
32824
32671
|
(prev) => prev.map(
|
|
@@ -32863,10 +32710,10 @@ function useReadSearchGroup(setMessages, nextId, takeThinking) {
|
|
|
32863
32710
|
);
|
|
32864
32711
|
const finish = (0, import_react29.useCallback)(
|
|
32865
32712
|
(memberKey, section) => {
|
|
32866
|
-
const
|
|
32867
|
-
if (!
|
|
32868
|
-
|
|
32869
|
-
const { id, detail } =
|
|
32713
|
+
const open = openRef.current;
|
|
32714
|
+
if (!open?.members.has(memberKey)) return false;
|
|
32715
|
+
open.detail = joinSections(open.detail, section);
|
|
32716
|
+
const { id, detail } = open;
|
|
32870
32717
|
setMessages((prev) => prev.map((m) => m.id === id ? { ...m, detail } : m));
|
|
32871
32718
|
return true;
|
|
32872
32719
|
},
|
|
@@ -32874,28 +32721,28 @@ function useReadSearchGroup(setMessages, nextId, takeThinking) {
|
|
|
32874
32721
|
);
|
|
32875
32722
|
const retract = (0, import_react29.useCallback)(
|
|
32876
32723
|
(memberKey) => {
|
|
32877
|
-
const
|
|
32878
|
-
if (!
|
|
32879
|
-
|
|
32880
|
-
|
|
32881
|
-
const { id } =
|
|
32882
|
-
if (
|
|
32724
|
+
const open = openRef.current;
|
|
32725
|
+
if (!open?.members.has(memberKey)) return;
|
|
32726
|
+
open.members.delete(memberKey);
|
|
32727
|
+
open.ops = open.ops.filter((entry) => entry.key !== memberKey);
|
|
32728
|
+
const { id } = open;
|
|
32729
|
+
if (open.ops.length === 0) {
|
|
32883
32730
|
openRef.current = null;
|
|
32884
32731
|
setMessages((prev) => prev.filter((m) => m.id !== id));
|
|
32885
32732
|
return;
|
|
32886
32733
|
}
|
|
32887
|
-
|
|
32888
|
-
const { state } =
|
|
32734
|
+
open.state = rebuilt(open.ops, open.state);
|
|
32735
|
+
const { state } = open;
|
|
32889
32736
|
setMessages((prev) => prev.map((m) => m.id === id ? shaped(m, state, true, prev) : m));
|
|
32890
32737
|
},
|
|
32891
32738
|
[setMessages]
|
|
32892
32739
|
);
|
|
32893
32740
|
const close = (0, import_react29.useCallback)(() => {
|
|
32894
|
-
const
|
|
32895
|
-
if (!
|
|
32741
|
+
const open = openRef.current;
|
|
32742
|
+
if (!open) return;
|
|
32896
32743
|
openRef.current = null;
|
|
32897
|
-
const { id, detail } =
|
|
32898
|
-
const state = settled(
|
|
32744
|
+
const { id, detail } = open;
|
|
32745
|
+
const state = settled(open.state);
|
|
32899
32746
|
setMessages(
|
|
32900
32747
|
(prev) => prev.map((m) => {
|
|
32901
32748
|
if (m.id !== id) return m;
|
|
@@ -32943,14 +32790,14 @@ async function workspaceDiff(cwd) {
|
|
|
32943
32790
|
return null;
|
|
32944
32791
|
}
|
|
32945
32792
|
}, "git");
|
|
32946
|
-
const
|
|
32947
|
-
if (
|
|
32793
|
+
const stat3 = await git2(["diff", "--stat", "HEAD", "--"]);
|
|
32794
|
+
if (stat3 === null) return null;
|
|
32948
32795
|
const patchRaw = await git2(["diff", "HEAD", "--"]) ?? "";
|
|
32949
32796
|
const truncated = Buffer.byteLength(patchRaw, "utf8") > DIFF_MAX_BYTES;
|
|
32950
32797
|
const patch = truncated ? patchRaw.slice(0, DIFF_MAX_BYTES) : patchRaw;
|
|
32951
32798
|
const untrackedRaw = await git2(["ls-files", "--others", "--exclude-standard"]) ?? "";
|
|
32952
32799
|
const untracked = untrackedRaw.split("\n").filter((line) => line.length > 0);
|
|
32953
|
-
return { stat:
|
|
32800
|
+
return { stat: stat3.trimEnd(), patch, truncated, untracked };
|
|
32954
32801
|
}
|
|
32955
32802
|
__name(workspaceDiff, "workspaceDiff");
|
|
32956
32803
|
function parsePatch(patch) {
|
|
@@ -33171,7 +33018,8 @@ function projectConversation(messages, nextId, readableUserTexts = [], restore)
|
|
|
33171
33018
|
...restore?.trail ? { trail: restore.trail } : {},
|
|
33172
33019
|
...restore?.cwd ? { cwd: restore.cwd } : {},
|
|
33173
33020
|
...restore?.cannotTellReason ? { cannotTellReason: restore.cannotTellReason } : {},
|
|
33174
|
-
...restore?.telling ? { telling: restore.telling } : {}
|
|
33021
|
+
...restore?.telling ? { telling: restore.telling } : {},
|
|
33022
|
+
...restore?.showTurnDuration !== void 0 ? { showTurnDuration: restore.showTurnDuration } : {}
|
|
33175
33023
|
});
|
|
33176
33024
|
const out = [];
|
|
33177
33025
|
for (const message of messages) {
|
|
@@ -33227,14 +33075,15 @@ function projectConversation(messages, nextId, readableUserTexts = [], restore)
|
|
|
33227
33075
|
return [];
|
|
33228
33076
|
}
|
|
33229
33077
|
if (message.source?.type === "runtime-context") {
|
|
33078
|
+
const shown = typeof message.content === "string" && (message.source.kind === "task-completion" || message.source.kind === "job-exit") ? noticeDisplay(message.content) : void 0;
|
|
33230
33079
|
return [
|
|
33231
33080
|
{
|
|
33232
33081
|
id: nextId(),
|
|
33233
33082
|
role: "system",
|
|
33234
|
-
content: runtimeContextRowLabel(message),
|
|
33083
|
+
content: shown?.label ?? runtimeContextRowLabel(message),
|
|
33235
33084
|
glyph: SYSTEM_ROW_GLYPH,
|
|
33236
33085
|
glyphColor: systemRowStyle("notice").color,
|
|
33237
|
-
detail: [message.content]
|
|
33086
|
+
...shown ? shown.detail.length > 0 ? { detail: [...shown.detail] } : {} : { detail: [message.content] }
|
|
33238
33087
|
}
|
|
33239
33088
|
];
|
|
33240
33089
|
}
|
|
@@ -33713,19 +33562,23 @@ ${blocks.join("\n\n")}`;
|
|
|
33713
33562
|
clearInterval(timer);
|
|
33714
33563
|
};
|
|
33715
33564
|
}, [session]);
|
|
33716
|
-
(0, import_react30.
|
|
33565
|
+
const announceUnfinishedRuns = (0, import_react30.useCallback)(() => {
|
|
33717
33566
|
const source = session?.workflows;
|
|
33718
33567
|
if (!source) return;
|
|
33719
33568
|
void source.recoverUnfinished().then((notices2) => {
|
|
33720
33569
|
if (previousSessionRef.current !== session || appLifetime.signal.aborted) return;
|
|
33721
33570
|
for (const notice of notices2) {
|
|
33722
|
-
|
|
33723
|
-
|
|
33724
|
-
|
|
33725
|
-
);
|
|
33571
|
+
const key = `${ORPHAN_NOTICE_PREFIX}${notice.runIds.join(",")}`;
|
|
33572
|
+
if (wakeLedgerRef.current.workflowIds().includes(key)) continue;
|
|
33573
|
+
wakeLedgerRef.current.noteWorkflowEnd(key, notice.text);
|
|
33726
33574
|
pushMessage("system", notice.line);
|
|
33727
33575
|
}
|
|
33728
33576
|
}).catch(() => void 0);
|
|
33577
|
+
}, [session]);
|
|
33578
|
+
(0, import_react30.useEffect)(() => {
|
|
33579
|
+
const source = session?.workflows;
|
|
33580
|
+
if (!source) return;
|
|
33581
|
+
announceUnfinishedRuns();
|
|
33729
33582
|
return source.subscribe(() => {
|
|
33730
33583
|
const live = new Set(source.runs().map((view) => view.runId));
|
|
33731
33584
|
for (const id of wakeLedgerRef.current.workflowIds()) {
|
|
@@ -33737,7 +33590,7 @@ ${blocks.join("\n\n")}`;
|
|
|
33737
33590
|
}
|
|
33738
33591
|
}
|
|
33739
33592
|
});
|
|
33740
|
-
}, [session]);
|
|
33593
|
+
}, [announceUnfinishedRuns, session]);
|
|
33741
33594
|
const [usage, setUsage] = (0, import_react30.useState)(null);
|
|
33742
33595
|
const [thinking, setThinking] = (0, import_react30.useState)(null);
|
|
33743
33596
|
const [providerWaitNotice, setProviderWaitNotice] = (0, import_react30.useState)(null);
|
|
@@ -33909,6 +33762,10 @@ ${blocks.join("\n\n")}`;
|
|
|
33909
33762
|
peersRef.current?.publish();
|
|
33910
33763
|
}, []);
|
|
33911
33764
|
const autoResumeAttemptRef = (0, import_react30.useRef)(0);
|
|
33765
|
+
const signInAutoResumesRef = (0, import_react30.useRef)(0);
|
|
33766
|
+
const signInWatchGaveUpRef = (0, import_react30.useRef)(null);
|
|
33767
|
+
const signInWatchStartRef = (0, import_react30.useRef)(null);
|
|
33768
|
+
const pausedTurnMayBeWaitingRef = (0, import_react30.useRef)(false);
|
|
33912
33769
|
const selfMendingPauseRowRef = (0, import_react30.useRef)(new SelfMendingPauseRow());
|
|
33913
33770
|
const [, setAutoResumeTick] = (0, import_react30.useState)(0);
|
|
33914
33771
|
const composerDraftTokenRef = (0, import_react30.useRef)(0);
|
|
@@ -34354,6 +34211,8 @@ ${AUTO_MODE_DEFAULT_NOTICE_BODY}`,
|
|
|
34354
34211
|
}
|
|
34355
34212
|
const stoppedAtPromptRef = (0, import_react30.useRef)(/* @__PURE__ */ new Set());
|
|
34356
34213
|
const refusalEndedTurnRef = (0, import_react30.useRef)(false);
|
|
34214
|
+
const checkStoppedTurnRef = (0, import_react30.useRef)(false);
|
|
34215
|
+
const callsNotRunRef = (0, import_react30.useRef)(0);
|
|
34357
34216
|
const learningQuestionsRef = (0, import_react30.useRef)(null);
|
|
34358
34217
|
if (learningQuestionsRef.current === null) learningQuestionsRef.current = createQuestionGate();
|
|
34359
34218
|
const learningQuestions = learningQuestionsRef.current;
|
|
@@ -34428,6 +34287,7 @@ ${AUTO_MODE_DEFAULT_NOTICE_BODY}`,
|
|
|
34428
34287
|
}, [promptHiddenNow]);
|
|
34429
34288
|
const trustGrants = (0, import_react30.useMemo)(() => readFolderGrants(trustedCwdRef.current), []);
|
|
34430
34289
|
const sessionsRef = (0, import_react30.useRef)(null);
|
|
34290
|
+
const [joinRequestCount, setJoinRequestCount] = (0, import_react30.useState)(0);
|
|
34431
34291
|
const scopeRef = (0, import_react30.useRef)(null);
|
|
34432
34292
|
const attachmentFloor = (0, import_react30.useMemo)(() => {
|
|
34433
34293
|
let highest = 0;
|
|
@@ -34485,7 +34345,7 @@ ${AUTO_MODE_DEFAULT_NOTICE_BODY}`,
|
|
|
34485
34345
|
const scope = scopeRef.current;
|
|
34486
34346
|
if (!sessions || !scope || !conversationMaterializedRef.current) return void 0;
|
|
34487
34347
|
try {
|
|
34488
|
-
return
|
|
34348
|
+
return join18(sessions.paths.sessionDir({ sessionId: scope.sessionId }), "loops.json");
|
|
34489
34349
|
} catch {
|
|
34490
34350
|
return void 0;
|
|
34491
34351
|
}
|
|
@@ -34747,9 +34607,9 @@ ${AUTO_MODE_DEFAULT_NOTICE_BODY}`,
|
|
|
34747
34607
|
const scrollWasOpenRef = (0, import_react30.useRef)(false);
|
|
34748
34608
|
(0, import_react30.useEffect)(() => {
|
|
34749
34609
|
const wasOpen = scrollWasOpenRef.current;
|
|
34750
|
-
const
|
|
34751
|
-
scrollWasOpenRef.current =
|
|
34752
|
-
if (wasOpen !==
|
|
34610
|
+
const open = scrollOpen || transcriptScreen;
|
|
34611
|
+
scrollWasOpenRef.current = open;
|
|
34612
|
+
if (wasOpen !== open) resetTranscript({ preserveTranscriptScreen: true });
|
|
34753
34613
|
}, [scrollOpen, transcriptScreen, resetTranscript]);
|
|
34754
34614
|
const previousTerminalRef = (0, import_react30.useRef)(terminal);
|
|
34755
34615
|
(0, import_react30.useEffect)(() => {
|
|
@@ -35064,7 +34924,13 @@ ${AUTO_MODE_DEFAULT_NOTICE_BODY}`,
|
|
|
35064
34924
|
closingWaitRef.current = null;
|
|
35065
34925
|
setClosingWaitVersion((version2) => version2 + 1);
|
|
35066
34926
|
if (wait.silent === true) return;
|
|
35067
|
-
const line = settleLine(
|
|
34927
|
+
const line = settleLine(
|
|
34928
|
+
Math.max(0, Date.now() - wait.since - wait.pausedMs),
|
|
34929
|
+
mine,
|
|
34930
|
+
/* @__PURE__ */ new Date(),
|
|
34931
|
+
void 0,
|
|
34932
|
+
showTurnDurationRef.current
|
|
34933
|
+
);
|
|
35068
34934
|
if (line) pushMessage("system", line, false, CLOSING_GLYPH, void 0, tokenColor("text.muted"));
|
|
35069
34935
|
}, [subagents, workflowRuns, state, closingWaitVersion, pushMessage]);
|
|
35070
34936
|
const [queueSelection, setQueueSelectionState] = (0, import_react30.useState)(null);
|
|
@@ -35166,6 +35032,10 @@ ${AUTO_MODE_DEFAULT_NOTICE_BODY}`,
|
|
|
35166
35032
|
recapOnRef.current = recapOn;
|
|
35167
35033
|
const [spinnerTipsOverride, setSpinnerTipsOverride] = (0, import_react30.useState)();
|
|
35168
35034
|
const spinnerTipsOn = spinnerTipsOverride ?? ctx.tui?.spinnerTips !== false;
|
|
35035
|
+
const [turnDurationOverride, setTurnDurationOverride] = (0, import_react30.useState)();
|
|
35036
|
+
const showTurnDuration = turnDurationOverride ?? ctx.tui?.showTurnDuration ?? DEFAULT_SHOW_TURN_DURATION;
|
|
35037
|
+
const showTurnDurationRef = (0, import_react30.useRef)(showTurnDuration);
|
|
35038
|
+
showTurnDurationRef.current = showTurnDuration;
|
|
35169
35039
|
const turnToolCallsRef = (0, import_react30.useRef)(0);
|
|
35170
35040
|
const spinnerTip = useSpinnerTip({
|
|
35171
35041
|
store: tipHistory,
|
|
@@ -35524,13 +35394,21 @@ ${AUTO_MODE_DEFAULT_NOTICE_BODY}`,
|
|
|
35524
35394
|
);
|
|
35525
35395
|
const handleAutoModeLimit = (0, import_react30.useCallback)(
|
|
35526
35396
|
(event) => {
|
|
35397
|
+
if (event.limit === "asked") {
|
|
35398
|
+
pushMessage(
|
|
35399
|
+
"system",
|
|
35400
|
+
`Auto mode asks you instead: ${event.reason.replace(/, so the action was not run$/, "")}.`
|
|
35401
|
+
);
|
|
35402
|
+
return;
|
|
35403
|
+
}
|
|
35527
35404
|
if (event.limit === "unavailable") {
|
|
35405
|
+
checkStoppedTurnRef.current = true;
|
|
35528
35406
|
if (permissionModeSourceRef.current === "auto-default" && permissionModeRef.current === "classify") {
|
|
35529
35407
|
commitPermissionMode("prompt", false);
|
|
35530
|
-
pushMessage("system", AUTO_MODE_DEFAULT_STOPPED_NOTICE);
|
|
35408
|
+
pushMessage("system", `${AUTO_MODE_DEFAULT_STOPPED_NOTICE} ${event.reason}`);
|
|
35531
35409
|
return;
|
|
35532
35410
|
}
|
|
35533
|
-
pushMessage("system", AUTO_MODE_STOPPED_NOTICE);
|
|
35411
|
+
pushMessage("system", `${AUTO_MODE_STOPPED_NOTICE} ${event.reason}`);
|
|
35534
35412
|
return;
|
|
35535
35413
|
}
|
|
35536
35414
|
if (permissionModeRef.current !== "classify") return;
|
|
@@ -36401,7 +36279,7 @@ ${AUTO_MODE_DEFAULT_NOTICE_BODY}`,
|
|
|
36401
36279
|
pushMessage("system", "Not changed.");
|
|
36402
36280
|
return;
|
|
36403
36281
|
}
|
|
36404
|
-
void import("./setting-cli-
|
|
36282
|
+
void import("./setting-cli-ETVPDSRA.js").then(({ planSettingChange }) => {
|
|
36405
36283
|
const plan = planSettingChange(picker.change.key, picker.change.text);
|
|
36406
36284
|
if (!plan.ok) {
|
|
36407
36285
|
pushMessage("system", plan.error);
|
|
@@ -36720,6 +36598,7 @@ ${AUTO_MODE_DEFAULT_NOTICE_BODY}`,
|
|
|
36720
36598
|
cwd: ctxRef.current.cwd,
|
|
36721
36599
|
attachmentDir: attachmentDirOf(sessions, asSessionId(requestedConversationId)),
|
|
36722
36600
|
...cannotTellReasonRef.current ? { cannotTellReason: cannotTellReasonRef.current } : {},
|
|
36601
|
+
showTurnDuration: showTurnDurationRef.current,
|
|
36723
36602
|
onTold: /* @__PURE__ */ __name((telling) => {
|
|
36724
36603
|
outcomeToldRef.current = { id: requestedConversationId, telling };
|
|
36725
36604
|
}, "onTold")
|
|
@@ -36910,8 +36789,11 @@ ${AUTO_MODE_DEFAULT_NOTICE_BODY}`,
|
|
|
36910
36789
|
flushLearnedRef.current();
|
|
36911
36790
|
}, "onLearned")
|
|
36912
36791
|
},
|
|
36913
|
-
//
|
|
36914
|
-
|
|
36792
|
+
// Offered here; whether it is on is the user's own setting
|
|
36793
|
+
// (`computerUse.enabled`, off until they turn it on), read at the top
|
|
36794
|
+
// of every turn so a change applies from the next message.
|
|
36795
|
+
enableComputerUse: true,
|
|
36796
|
+
computerUseSwitch: activeCtx.readComputerUseEnabled ?? (() => activeCtx.computerUse?.enabled === true),
|
|
36915
36797
|
...activeCtx.computerUse?.deniedApps?.length ? { deniedComputerApps: activeCtx.computerUse.deniedApps } : {},
|
|
36916
36798
|
// The terminal is watched live: the quiet-stretch nudge, unless the
|
|
36917
36799
|
// config turned it off.
|
|
@@ -36926,6 +36808,9 @@ ${AUTO_MODE_DEFAULT_NOTICE_BODY}`,
|
|
|
36926
36808
|
...activeCtx.codeAnalysis?.enabled === false ? {} : { codeAnalysis: activeCtx.codeAnalysis ?? {} },
|
|
36927
36809
|
rules: activeCtx.rules,
|
|
36928
36810
|
...activeCtx.appendSystem ? { appendSystem: activeCtx.appendSystem } : {},
|
|
36811
|
+
...activeCtx.replaceSystem ? { replaceSystem: activeCtx.replaceSystem } : {},
|
|
36812
|
+
...activeCtx.onlyTools ? { onlyTools: activeCtx.onlyTools } : {},
|
|
36813
|
+
...activeCtx.bare ? { bare: true } : {},
|
|
36929
36814
|
...sessionsRef.current ? {
|
|
36930
36815
|
sessionGoals: sessionsRef.current.goals,
|
|
36931
36816
|
...activeCtx.goal?.confirmedBy ? { goalConfirmedBy: activeCtx.goal.confirmedBy } : {},
|
|
@@ -37655,7 +37540,8 @@ ${AUTO_MODE_DEFAULT_NOTICE_BODY}`,
|
|
|
37655
37540
|
}));
|
|
37656
37541
|
const queuedInputItems = queued.map((prompt) => ({
|
|
37657
37542
|
text: prompt.kind === "goal" ? "Automatic goal continuation" : prompt.kind === "notice" ? "Something finished in the background" : prompt.kind === "peer" ? peerMailLabel(prompt.mail) : prompt.recallText ?? prompt.text,
|
|
37658
|
-
attachmentCount: prompt.kind === "human" ? prompt.attachments?.length : void 0
|
|
37543
|
+
attachmentCount: prompt.kind === "human" ? prompt.attachments?.length : void 0,
|
|
37544
|
+
...prompt.kind === "human" && prompt.command ? { command: true } : {}
|
|
37659
37545
|
}));
|
|
37660
37546
|
const pendingInputVisible = phase === "ready" && agentSurface === null && !transcriptScreen && !scrollOpen && jobSurface === null && permission === null && saveSkillPrompt === null && planPrompt === null && questionDialog === null && scheduleReviewPrompt === null && textPrompt === null && choicePicker === null && copyPicker === null;
|
|
37661
37547
|
const pendingInputFurniture = pendingInputVisible ? pendingInputPanelRows({
|
|
@@ -37854,23 +37740,31 @@ ${AUTO_MODE_DEFAULT_NOTICE_BODY}`,
|
|
|
37854
37740
|
return;
|
|
37855
37741
|
}
|
|
37856
37742
|
await session.abandonTurn(active.turnId, reason);
|
|
37743
|
+
setHandoffPark(null);
|
|
37744
|
+
pausedTurnMayBeWaitingRef.current = false;
|
|
37857
37745
|
pushMessage("system", PAUSED_TURN_LINES.abandoned);
|
|
37858
37746
|
} catch (err) {
|
|
37859
37747
|
pushSystem("error", explainFailure(err, "Couldn\u2019t stop the paused reply."));
|
|
37860
37748
|
}
|
|
37861
37749
|
},
|
|
37862
|
-
[pushMessage, session, state, pushSystem]
|
|
37750
|
+
[pushMessage, session, state, pushSystem, setHandoffPark]
|
|
37863
37751
|
);
|
|
37864
37752
|
const applyEventRef = (0, import_react30.useRef)(null);
|
|
37865
37753
|
const resumeActiveTurn = (0, import_react30.useCallback)(
|
|
37866
37754
|
async (resume) => {
|
|
37867
37755
|
const sessions = sessionsRef.current;
|
|
37868
37756
|
const scope = scopeRef.current;
|
|
37869
|
-
if (!sessions || !scope || !conversationMaterializedRef.current || !session?.hasProvider)
|
|
37757
|
+
if (!sessions || !scope || !conversationMaterializedRef.current || !session?.hasProvider) {
|
|
37758
|
+
if (resume?.explain)
|
|
37759
|
+
pushMessage("system", "Nothing to continue here: this conversation has no reply yet.");
|
|
37870
37760
|
return false;
|
|
37761
|
+
}
|
|
37871
37762
|
const resumedSessionId = scope.sessionId;
|
|
37872
37763
|
const active = await activeConversationTurn(sessions, resumedSessionId).catch(() => void 0);
|
|
37873
|
-
if (!active)
|
|
37764
|
+
if (!active) {
|
|
37765
|
+
if (resume?.explain) pushMessage("system", "Nothing to continue here: no reply is paused.");
|
|
37766
|
+
return false;
|
|
37767
|
+
}
|
|
37874
37768
|
if (abortRef.current || state !== "idle") {
|
|
37875
37769
|
pushMessage(
|
|
37876
37770
|
"system",
|
|
@@ -37891,6 +37785,7 @@ ${AUTO_MODE_DEFAULT_NOTICE_BODY}`,
|
|
|
37891
37785
|
return true;
|
|
37892
37786
|
}
|
|
37893
37787
|
setHandoffPark(null);
|
|
37788
|
+
pausedTurnMayBeWaitingRef.current = false;
|
|
37894
37789
|
const ac = new AbortController();
|
|
37895
37790
|
abortRef.current = ac;
|
|
37896
37791
|
replyCutOffRef.current = false;
|
|
@@ -37952,7 +37847,12 @@ ${AUTO_MODE_DEFAULT_NOTICE_BODY}`,
|
|
|
37952
37847
|
// The skills the operator has on, as a new turn carries them.
|
|
37953
37848
|
extraSystem: composeSkillsPrompt(activeSkills) || void 0,
|
|
37954
37849
|
...resume?.handoffReason ? {
|
|
37955
|
-
systemNote: handoffContinuationNote(
|
|
37850
|
+
systemNote: handoffContinuationNote(
|
|
37851
|
+
resume.handoffReason,
|
|
37852
|
+
void 0,
|
|
37853
|
+
void 0,
|
|
37854
|
+
resume.operatorNote
|
|
37855
|
+
)
|
|
37956
37856
|
} : {}
|
|
37957
37857
|
}
|
|
37958
37858
|
})) {
|
|
@@ -38036,6 +37936,54 @@ ${AUTO_MODE_DEFAULT_NOTICE_BODY}`,
|
|
|
38036
37936
|
const timer = setInterval(() => setAutoResumeTick((n) => n + 1), 1e3);
|
|
38037
37937
|
return () => clearInterval(timer);
|
|
38038
37938
|
}, [autoResumeAt]);
|
|
37939
|
+
const signInPark = handoffPark?.browserSignIn ? handoffPark : void 0;
|
|
37940
|
+
const signInWatchTurn = signInPark?.turnId;
|
|
37941
|
+
const signInWatchOn = ctx.browser?.signInWatch !== false;
|
|
37942
|
+
const resumeActiveTurnRef = (0, import_react30.useRef)(resumeActiveTurn);
|
|
37943
|
+
resumeActiveTurnRef.current = resumeActiveTurn;
|
|
37944
|
+
const pushMessageRef = (0, import_react30.useRef)(pushMessage);
|
|
37945
|
+
pushMessageRef.current = pushMessage;
|
|
37946
|
+
const windowGuessNotedRef = (0, import_react30.useRef)(/* @__PURE__ */ new Set());
|
|
37947
|
+
(0, import_react30.useEffect)(() => {
|
|
37948
|
+
if (signInWatchTurn === void 0) signInWatchStartRef.current = null;
|
|
37949
|
+
if (signInWatchTurn === void 0 || !signInWatchOn) return;
|
|
37950
|
+
if (signInWatchGaveUpRef.current === signInWatchTurn) return;
|
|
37951
|
+
if (phase !== "ready" || state !== "idle") return;
|
|
37952
|
+
const control = browserControlRef.current;
|
|
37953
|
+
if (!control || control.status().headless) return;
|
|
37954
|
+
const startedAt = signInWatchStartRef.current?.turnId === signInWatchTurn ? signInWatchStartRef.current.at : Date.now();
|
|
37955
|
+
signInWatchStartRef.current = { turnId: signInWatchTurn, at: startedAt };
|
|
37956
|
+
const remaining = SIGNIN_WATCH_MS - (Date.now() - startedAt);
|
|
37957
|
+
if (remaining <= 0) return;
|
|
37958
|
+
return startSignInWatch({
|
|
37959
|
+
watchMs: remaining,
|
|
37960
|
+
peek: /* @__PURE__ */ __name(() => control.peekSignIn(), "peek"),
|
|
37961
|
+
ready: /* @__PURE__ */ __name(() => handoffParkRef.current?.turnId === signInWatchTurn && !composerHasDraftRef.current && !abortRef.current, "ready"),
|
|
37962
|
+
onTimeout: /* @__PURE__ */ __name(() => {
|
|
37963
|
+
if (handoffParkRef.current?.turnId !== signInWatchTurn) return;
|
|
37964
|
+
signInWatchGaveUpRef.current = signInWatchTurn;
|
|
37965
|
+
pushMessageRef.current(
|
|
37966
|
+
"system",
|
|
37967
|
+
"Still waiting for you to sign in. Press Enter when you have, or Esc to stop."
|
|
37968
|
+
);
|
|
37969
|
+
}, "onTimeout"),
|
|
37970
|
+
onCleared: /* @__PURE__ */ __name(() => {
|
|
37971
|
+
const parked = handoffParkRef.current;
|
|
37972
|
+
if (parked?.turnId !== signInWatchTurn || parked.reason === void 0) return;
|
|
37973
|
+
if (signInAutoResumesRef.current >= SIGNIN_AUTO_RESUME_CAP) {
|
|
37974
|
+
signInWatchGaveUpRef.current = signInWatchTurn;
|
|
37975
|
+
pushMessageRef.current(
|
|
37976
|
+
"system",
|
|
37977
|
+
"Stopped checking for your sign-in. Press Enter when you have signed in, or Esc to stop."
|
|
37978
|
+
);
|
|
37979
|
+
return;
|
|
37980
|
+
}
|
|
37981
|
+
signInAutoResumesRef.current += 1;
|
|
37982
|
+
pushMessageRef.current("system", "Looks like you signed in. Continuing.");
|
|
37983
|
+
void resumeActiveTurnRef.current({ handoffReason: parked.reason, automatic: true });
|
|
37984
|
+
}, "onCleared")
|
|
37985
|
+
});
|
|
37986
|
+
}, [signInPark, signInWatchTurn, signInWatchOn, phase, state]);
|
|
38039
37987
|
const openResumePicker = (0, import_react30.useCallback)(
|
|
38040
37988
|
async (query, pr) => {
|
|
38041
37989
|
const sessions = sessionsRef.current ?? await ensureSessions().then(() => sessionsRef.current);
|
|
@@ -38102,10 +38050,10 @@ ${AUTO_MODE_DEFAULT_NOTICE_BODY}`,
|
|
|
38102
38050
|
const progressId = pushMessage("system", "Reading spend\u2026");
|
|
38103
38051
|
try {
|
|
38104
38052
|
const [{ buildCostReport }, { renderSpend }, { systemClock: systemClock2 }, { resolveNamzuHome: resolveNamzuHome2 }] = await Promise.all([
|
|
38105
|
-
import("./cost-
|
|
38053
|
+
import("./cost-IVLAFD5T.js"),
|
|
38106
38054
|
import("./render-QFCCPEEL.js"),
|
|
38107
38055
|
import("./day-CU5J7UAK.js"),
|
|
38108
|
-
import("./home-
|
|
38056
|
+
import("./home-GR6YDAAE.js")
|
|
38109
38057
|
]);
|
|
38110
38058
|
const report = await buildCostReport(days, {
|
|
38111
38059
|
home: resolveNamzuHome2(),
|
|
@@ -38131,7 +38079,7 @@ ${AUTO_MODE_DEFAULT_NOTICE_BODY}`,
|
|
|
38131
38079
|
doctorRunningRef.current = true;
|
|
38132
38080
|
const progressId = pushMessage("system", "Checking\u2026");
|
|
38133
38081
|
try {
|
|
38134
|
-
const { runLiveDoctor } = await import("./live-
|
|
38082
|
+
const { runLiveDoctor } = await import("./live-LJ76XHPK.js");
|
|
38135
38083
|
const { describePlainDoctor } = await import("./plain-report-U37TZYMU.js");
|
|
38136
38084
|
const report = await runLiveDoctor({
|
|
38137
38085
|
...ctxRef.current.telemetry ? { telemetry: ctxRef.current.telemetry } : {}
|
|
@@ -38427,6 +38375,7 @@ ${AUTO_MODE_DEFAULT_NOTICE_BODY}`,
|
|
|
38427
38375
|
cwd: ctxRef.current.cwd,
|
|
38428
38376
|
attachmentDir: attachmentDirOf(sessions, conv.id),
|
|
38429
38377
|
...cannotTellReasonRef.current ? { cannotTellReason: cannotTellReasonRef.current } : {},
|
|
38378
|
+
showTurnDuration: showTurnDurationRef.current,
|
|
38430
38379
|
onTold: /* @__PURE__ */ __name((telling) => {
|
|
38431
38380
|
outcomeToldRef.current = { id: conv.id, telling };
|
|
38432
38381
|
}, "onTold")
|
|
@@ -38439,6 +38388,7 @@ ${AUTO_MODE_DEFAULT_NOTICE_BODY}`,
|
|
|
38439
38388
|
cancelPendingModelSwitch();
|
|
38440
38389
|
conversationGenRef.current += 1;
|
|
38441
38390
|
setHandoffPark(null);
|
|
38391
|
+
pausedTurnMayBeWaitingRef.current = false;
|
|
38442
38392
|
autoResumeAttemptRef.current = 0;
|
|
38443
38393
|
selfMendingPauseRowRef.current.forget();
|
|
38444
38394
|
resetSubagentActivity();
|
|
@@ -38478,6 +38428,7 @@ ${AUTO_MODE_DEFAULT_NOTICE_BODY}`,
|
|
|
38478
38428
|
}
|
|
38479
38429
|
}
|
|
38480
38430
|
void hydrateSavedChildren();
|
|
38431
|
+
announceUnfinishedRuns();
|
|
38481
38432
|
conversationMaterializedRef.current = true;
|
|
38482
38433
|
sourceDeliveryPollRef.current();
|
|
38483
38434
|
pushMessage(
|
|
@@ -38506,6 +38457,7 @@ ${AUTO_MODE_DEFAULT_NOTICE_BODY}`,
|
|
|
38506
38457
|
pushMessage,
|
|
38507
38458
|
cancelPendingModelSwitch,
|
|
38508
38459
|
hydrateSavedChildren,
|
|
38460
|
+
announceUnfinishedRuns,
|
|
38509
38461
|
hasUnsettledTurn,
|
|
38510
38462
|
hydrateSession,
|
|
38511
38463
|
detected,
|
|
@@ -38594,6 +38546,7 @@ ${AUTO_MODE_DEFAULT_NOTICE_BODY}`,
|
|
|
38594
38546
|
cancelPendingModelSwitch();
|
|
38595
38547
|
conversationGenRef.current += 1;
|
|
38596
38548
|
setHandoffPark(null);
|
|
38549
|
+
pausedTurnMayBeWaitingRef.current = false;
|
|
38597
38550
|
autoResumeAttemptRef.current = 0;
|
|
38598
38551
|
selfMendingPauseRowRef.current.forget();
|
|
38599
38552
|
resetSubagentActivity();
|
|
@@ -39379,6 +39332,7 @@ ${AUTO_MODE_DEFAULT_NOTICE_BODY}`,
|
|
|
39379
39332
|
setMessages(
|
|
39380
39333
|
projectConversation(forked.messages, nextId, readablePrefix, {
|
|
39381
39334
|
cwd: ctxRef.current.cwd,
|
|
39335
|
+
showTurnDuration: showTurnDurationRef.current,
|
|
39382
39336
|
attachmentDir: attachmentDirOf(sessions, forked.id)
|
|
39383
39337
|
})
|
|
39384
39338
|
);
|
|
@@ -39472,6 +39426,7 @@ ${AUTO_MODE_DEFAULT_NOTICE_BODY}`,
|
|
|
39472
39426
|
setMessages(
|
|
39473
39427
|
projectConversation(result.messages, nextId, readable, {
|
|
39474
39428
|
cwd: ctxRef.current.cwd,
|
|
39429
|
+
showTurnDuration: showTurnDurationRef.current,
|
|
39475
39430
|
...sessionsRef.current && scopeRef.current ? { attachmentDir: attachmentDirOf(sessionsRef.current, scopeRef.current.sessionId) } : {}
|
|
39476
39431
|
})
|
|
39477
39432
|
);
|
|
@@ -39710,6 +39665,7 @@ ${plain2(err)}`
|
|
|
39710
39665
|
signal?.addEventListener("abort", onAbort, { once: true });
|
|
39711
39666
|
setSelectedChoice(0);
|
|
39712
39667
|
setJobSurface(null);
|
|
39668
|
+
if (agentSurfaceRef.current?.kind === "cockpit") setAgentSurface(null);
|
|
39713
39669
|
setChoicePicker(picker);
|
|
39714
39670
|
announceApproval();
|
|
39715
39671
|
}),
|
|
@@ -39720,6 +39676,7 @@ ${plain2(err)}`
|
|
|
39720
39676
|
setQuestionDialog,
|
|
39721
39677
|
setSelectedChoice,
|
|
39722
39678
|
setJobSurface,
|
|
39679
|
+
setAgentSurface,
|
|
39723
39680
|
resolveQuestion
|
|
39724
39681
|
]
|
|
39725
39682
|
);
|
|
@@ -40020,9 +39977,7 @@ ${plain2(err)}`
|
|
|
40020
39977
|
readSearchGroup.close();
|
|
40021
39978
|
setThinking(null);
|
|
40022
39979
|
setState("tool");
|
|
40023
|
-
const waitingAgent = event.toolName === "wait_for_task" && event.taskId ? subagentsRef.current.find(
|
|
40024
|
-
(agent) => agent.taskId === event.taskId && (event.turnId === void 0 || agent.workflowId === event.turnId)
|
|
40025
|
-
) : void 0;
|
|
39980
|
+
const waitingAgent = event.toolName === "wait_for_task" && event.taskId ? subagentsRef.current.find((agent) => agent.taskId === event.taskId) : void 0;
|
|
40026
39981
|
const tool = {
|
|
40027
39982
|
...waitingAgent ? {
|
|
40028
39983
|
taskId: waitingAgent.taskId,
|
|
@@ -40071,6 +40026,7 @@ ${plain2(err)}`
|
|
|
40071
40026
|
break;
|
|
40072
40027
|
}
|
|
40073
40028
|
case "tool-end": {
|
|
40029
|
+
if (isCallNotRun(event.output)) callsNotRunRef.current += 1;
|
|
40074
40030
|
if (event.toolName === "bash" || event.toolName === "job" || event.toolName === MONITOR_TOOL_NAME)
|
|
40075
40031
|
setJobSnapshot({
|
|
40076
40032
|
ownerSession: previousSessionRef.current,
|
|
@@ -40102,7 +40058,7 @@ ${plain2(err)}`
|
|
|
40102
40058
|
setActiveTools(activeToolsRef.current);
|
|
40103
40059
|
}
|
|
40104
40060
|
const inspectableWait = done?.taskId && subagentsRef.current.some(
|
|
40105
|
-
(agent) => agent.taskId === done.taskId &&
|
|
40061
|
+
(agent) => agent.taskId === done.taskId && agent.transcript.some(
|
|
40106
40062
|
(row2) => row2.kind === "assistant" && row2.text.trim().length > 0
|
|
40107
40063
|
)
|
|
40108
40064
|
);
|
|
@@ -40154,6 +40110,10 @@ ${plain2(err)}`
|
|
|
40154
40110
|
case "usage":
|
|
40155
40111
|
closeAssistant();
|
|
40156
40112
|
st.lastUsage = event;
|
|
40113
|
+
if (event.windowSource === "default" && event.contextWindowTokens !== void 0 && !windowGuessNotedRef.current.has(replyModelRef.current ?? "")) {
|
|
40114
|
+
windowGuessNotedRef.current.add(replyModelRef.current ?? "");
|
|
40115
|
+
pushMessage("system", windowGuessLine(event.contextWindowTokens));
|
|
40116
|
+
}
|
|
40157
40117
|
idleCompaction.compactor.recordCall(event.cache);
|
|
40158
40118
|
idleCompaction.contextTokens.current = event.contextTokens;
|
|
40159
40119
|
setUsage({
|
|
@@ -40370,6 +40330,7 @@ ${plain2(err)}`
|
|
|
40370
40330
|
st.answeredFallbackModel = pending.model;
|
|
40371
40331
|
}
|
|
40372
40332
|
}
|
|
40333
|
+
const stoppedByReview = refusalEndedTurnRef.current || checkStoppedTurnRef.current;
|
|
40373
40334
|
if (refusalEndedTurnRef.current) {
|
|
40374
40335
|
refusalEndedTurnRef.current = false;
|
|
40375
40336
|
if (event.stopReason === "cancelled") {
|
|
@@ -40377,6 +40338,13 @@ ${plain2(err)}`
|
|
|
40377
40338
|
pushMessage("system", row2.content, false, row2.glyph, void 0, row2.color);
|
|
40378
40339
|
}
|
|
40379
40340
|
}
|
|
40341
|
+
checkStoppedTurnRef.current = false;
|
|
40342
|
+
if (stoppedByReview && event.stopReason === "cancelled") {
|
|
40343
|
+
pushSystem(
|
|
40344
|
+
"notice",
|
|
40345
|
+
stoppedTurnLine({ outcome: event.outcome, notRun: callsNotRunRef.current })
|
|
40346
|
+
);
|
|
40347
|
+
}
|
|
40380
40348
|
const stopNotice = event.stopReason === "refused" && st.refusalRowShown ? void 0 : describeTurnStop(event.stopReason, event.budget);
|
|
40381
40349
|
if (stopNotice) pushSystem("warning", stopNotice);
|
|
40382
40350
|
const conversationId = scopeRef.current?.sessionId;
|
|
@@ -40418,7 +40386,13 @@ ${plain2(err)}`
|
|
|
40418
40386
|
};
|
|
40419
40387
|
setClosingWaitVersion((version2) => version2 + 1);
|
|
40420
40388
|
}
|
|
40421
|
-
const closing = closingWaitRef.current === null && (delegated.length > 0 || st.completed) ? settleLine(
|
|
40389
|
+
const closing = closingWaitRef.current === null && (delegated.length > 0 || st.completed) ? settleLine(
|
|
40390
|
+
Date.now() - since - pausedMs,
|
|
40391
|
+
delegated,
|
|
40392
|
+
/* @__PURE__ */ new Date(),
|
|
40393
|
+
void 0,
|
|
40394
|
+
showTurnDurationRef.current
|
|
40395
|
+
) : void 0;
|
|
40422
40396
|
for (const agent of delegated) endedWorkflowTurnsRef.current.add(agent.workflowId);
|
|
40423
40397
|
flushWorkflowNotices();
|
|
40424
40398
|
if (st.planChanged && tasksRef.current.length > 0) {
|
|
@@ -40452,9 +40426,11 @@ ${plain2(err)}`
|
|
|
40452
40426
|
const browserNotice = describeBrowserHandoff(event.handoff, browserStatus);
|
|
40453
40427
|
if (browserNotice && browser && browserStatus?.headless) void browser.release();
|
|
40454
40428
|
pushSystem("warning", browserNotice ?? describePlainInterruption(event, plainOptions()));
|
|
40429
|
+
pausedTurnMayBeWaitingRef.current = true;
|
|
40455
40430
|
setHandoffPark({
|
|
40456
40431
|
turnId: event.turnId,
|
|
40457
|
-
reason: event.handoff.reason
|
|
40432
|
+
reason: event.handoff.reason,
|
|
40433
|
+
...browserNotice && browserStatus && !browserStatus.headless && event.handoff.detail?.cause !== "http-auth" ? { browserSignIn: true } : {}
|
|
40458
40434
|
});
|
|
40459
40435
|
} else {
|
|
40460
40436
|
const pauseText = describePlainInterruption(event, plainOptions());
|
|
@@ -40579,11 +40555,11 @@ ${plain2(err)}`
|
|
|
40579
40555
|
}
|
|
40580
40556
|
let noticeKind = "task-completion";
|
|
40581
40557
|
if (prompt.kind === "notice") {
|
|
40582
|
-
const { ended, jobLines, workflowIds } = wakeLedgerRef.current.takeForWake(session);
|
|
40558
|
+
const { ended, jobLines: jobLines2, workflowIds } = wakeLedgerRef.current.takeForWake(session);
|
|
40583
40559
|
markOrphanNoticesDelivered(workflowIds);
|
|
40584
|
-
if (
|
|
40560
|
+
if (jobLines2.length > 0) wakeBudgetRef.current.recordWake();
|
|
40585
40561
|
const monitorNotice = session?.monitors?.take();
|
|
40586
|
-
if (ended.length === 0 &&
|
|
40562
|
+
if (ended.length === 0 && jobLines2.length === 0 && !monitorNotice?.text) {
|
|
40587
40563
|
setState("idle");
|
|
40588
40564
|
return;
|
|
40589
40565
|
}
|
|
@@ -40591,8 +40567,8 @@ ${plain2(err)}`
|
|
|
40591
40567
|
text = [
|
|
40592
40568
|
...ended,
|
|
40593
40569
|
...monitorNotice?.text ? [monitorNotice.text] : [],
|
|
40594
|
-
...
|
|
40595
|
-
${
|
|
40570
|
+
...jobLines2.length > 0 ? [`Background jobs that ended:
|
|
40571
|
+
${jobLines2.map(([, line]) => `- ${line}`).join("\n")}`] : []
|
|
40596
40572
|
].join("\n\n");
|
|
40597
40573
|
}
|
|
40598
40574
|
const named = prompt.kind === "human" ? mentionSourcesRef.current : NO_MENTION_SOURCES;
|
|
@@ -40756,6 +40732,8 @@ ${jobLines.map(([, line]) => `- ${line}`).join("\n")}`] : []
|
|
|
40756
40732
|
abortRef.current = ac;
|
|
40757
40733
|
replyCutOffRef.current = false;
|
|
40758
40734
|
refusalEndedTurnRef.current = false;
|
|
40735
|
+
checkStoppedTurnRef.current = false;
|
|
40736
|
+
callsNotRunRef.current = 0;
|
|
40759
40737
|
activeTurnTokenRef.current = turnToken;
|
|
40760
40738
|
takeBackRef.current = userEchoId !== void 0 && prompt.kind === "human" && isRecallableHumanPrompt(prompt) ? {
|
|
40761
40739
|
token: turnToken,
|
|
@@ -40894,7 +40872,7 @@ ${jobLines.map(([, line]) => `- ${line}`).join("\n")}`] : []
|
|
|
40894
40872
|
void 0,
|
|
40895
40873
|
void 0,
|
|
40896
40874
|
void 0,
|
|
40897
|
-
humanPromptMeta(input.attachedFiles
|
|
40875
|
+
humanPromptMeta(input.attachedFiles),
|
|
40898
40876
|
void 0,
|
|
40899
40877
|
void 0,
|
|
40900
40878
|
void 0,
|
|
@@ -41891,7 +41869,7 @@ ${jobLines.map(([, line]) => `- ${line}`).join("\n")}`] : []
|
|
|
41891
41869
|
}
|
|
41892
41870
|
try {
|
|
41893
41871
|
const sameSignIn = accounts.registry.list("codex").find(
|
|
41894
|
-
(other) => other.source.kind === "codex-home" && readCodexCredentialFile(
|
|
41872
|
+
(other) => other.source.kind === "codex-home" && readCodexCredentialFile(join18(other.source.dir, "auth.json"))?.accountId === result.accountId
|
|
41895
41873
|
);
|
|
41896
41874
|
if (sameSignIn) {
|
|
41897
41875
|
rmSync2(dir, { recursive: true, force: true });
|
|
@@ -42318,8 +42296,30 @@ ${jobLines.map(([, line]) => `- ${line}`).join("\n")}`] : []
|
|
|
42318
42296
|
}
|
|
42319
42297
|
setViewNotice(void 0);
|
|
42320
42298
|
}
|
|
42321
|
-
|
|
42299
|
+
const parkedForPerson = handoffParkRef.current;
|
|
42300
|
+
if (parkedForPerson?.reason !== void 0 && !parkedForPerson.spentAllowance && meta.source === "composer" && !attachments?.length && !value.trimStart().startsWith("/") && // `!` and `#` are the operator acting directly, not an answer.
|
|
42301
|
+
shellEscapeCommand(value) === null && !value.startsWith("#") && phase === "ready" && state === "idle" && !abortRef.current) {
|
|
42302
|
+
const answer = value.trim();
|
|
42303
|
+
if (answer.length > 0) {
|
|
42304
|
+
setHandoffPark(null);
|
|
42305
|
+
pausedTurnMayBeWaitingRef.current = false;
|
|
42306
|
+
autoResumeAttemptRef.current = 0;
|
|
42307
|
+
signInAutoResumesRef.current = 0;
|
|
42308
|
+
selfMendingPauseRowRef.current.forget();
|
|
42309
|
+
setHistory((prev) => [...prev, value]);
|
|
42310
|
+
recordSentPrompt(sessionsRef.current, scopeRef.current?.sessionId, value, meta.pasted);
|
|
42311
|
+
pushMessage("user", answer);
|
|
42312
|
+
void resumeActiveTurn({
|
|
42313
|
+
handoffReason: parkedForPerson.reason,
|
|
42314
|
+
operatorNote: answer,
|
|
42315
|
+
explain: true
|
|
42316
|
+
});
|
|
42317
|
+
return;
|
|
42318
|
+
}
|
|
42319
|
+
}
|
|
42320
|
+
if (!(handoffParkRef.current && value.trimStart().startsWith("/"))) setHandoffPark(null);
|
|
42322
42321
|
autoResumeAttemptRef.current = 0;
|
|
42322
|
+
signInAutoResumesRef.current = 0;
|
|
42323
42323
|
selfMendingPauseRowRef.current.forget();
|
|
42324
42324
|
const fromLoop = meta.source === "operator-loop" || meta.source === "model-loop";
|
|
42325
42325
|
keybindingDraftRef.current = meta.source === "keybinding" ? meta.draft ?? null : null;
|
|
@@ -42577,6 +42577,7 @@ ${jobLines.map(([, line]) => `- ${line}`).join("\n")}`] : []
|
|
|
42577
42577
|
}
|
|
42578
42578
|
}
|
|
42579
42579
|
const heldLocal = peers.held();
|
|
42580
|
+
let screen;
|
|
42580
42581
|
if (!summary2) {
|
|
42581
42582
|
const local = `Peer messaging ${peers.enabled ? "on" : "off"} \xB7 ${peers.pending} pending
|
|
42582
42583
|
${localList.map((peer) => `${peer.self ? "This terminal" : peer.title} [${peer.ref}] \xB7 ${peer.state} \xB7 ${peer.permission_mode}${peer.accepts_messages ? "" : " \xB7 not accepting messages"}`).join("\n")}`;
|
|
@@ -42584,21 +42585,17 @@ ${localList.map((peer) => `${peer.self ? "This terminal" : peer.title} [${peer.r
|
|
|
42584
42585
|
${network.decision.text}` : "";
|
|
42585
42586
|
const held2 = heldLocal.length ? `
|
|
42586
42587
|
Held (${heldLocal.length}): ${heldLocal.map((item) => `${item.fromName} \xB7 ${item.reason}`).join("; ")}` : "";
|
|
42587
|
-
|
|
42588
|
-
if (heldLocal.length === 0) return;
|
|
42588
|
+
screen = `${local}${off}${held2}`;
|
|
42589
42589
|
} else {
|
|
42590
|
-
|
|
42591
|
-
|
|
42592
|
-
|
|
42593
|
-
|
|
42594
|
-
|
|
42595
|
-
|
|
42596
|
-
|
|
42597
|
-
|
|
42598
|
-
|
|
42599
|
-
columns: (terminal.columns ?? 80) - 4
|
|
42600
|
-
})
|
|
42601
|
-
);
|
|
42590
|
+
screen = renderPeersScreen({
|
|
42591
|
+
summary: summary2,
|
|
42592
|
+
roster,
|
|
42593
|
+
selfRef: peers.ref,
|
|
42594
|
+
heldLocal,
|
|
42595
|
+
now: Date.now(),
|
|
42596
|
+
// The picker draws it inside its frame, two columns of padding and a margin in.
|
|
42597
|
+
columns: (terminal.columns ?? 80) - SCREEN_MARGIN - 4
|
|
42598
|
+
});
|
|
42602
42599
|
}
|
|
42603
42600
|
const actions = peersActions(
|
|
42604
42601
|
summary2 ?? {
|
|
@@ -42614,11 +42611,15 @@ Held (${heldLocal.length}): ${heldLocal.map((item) => `${item.fromName} \xB7 ${i
|
|
|
42614
42611
|
},
|
|
42615
42612
|
heldLocal
|
|
42616
42613
|
);
|
|
42617
|
-
if (actions.length === 0)
|
|
42614
|
+
if (actions.length === 0) {
|
|
42615
|
+
pushMessage("system", screen);
|
|
42616
|
+
return;
|
|
42617
|
+
}
|
|
42618
42618
|
setSelectedChoice(0);
|
|
42619
42619
|
setChoicePicker({
|
|
42620
42620
|
kind: "peers-network",
|
|
42621
42621
|
title: "Waiting for you",
|
|
42622
|
+
body: screen.split("\n"),
|
|
42622
42623
|
actions,
|
|
42623
42624
|
values: actions.map((_, index) => String(index)),
|
|
42624
42625
|
options: actions.map((action) => describeAction(action))
|
|
@@ -42809,6 +42810,11 @@ Held (${heldLocal.length}): ${heldLocal.map((item) => `${item.fromName} \xB7 ${i
|
|
|
42809
42810
|
label: "Tips",
|
|
42810
42811
|
description: spinnerTipsOn ? "On \xB7 one short tip shows under the working row. Select to turn off." : "Off \xB7 no tip under the working row. Select to turn on."
|
|
42811
42812
|
},
|
|
42813
|
+
{
|
|
42814
|
+
name: `config showTurnDuration ${showTurnDuration ? "off" : "on"}`,
|
|
42815
|
+
label: "Show turn duration",
|
|
42816
|
+
description: showTurnDuration ? "On \xB7 each reply ends with how long it took and when it finished. Select to turn off." : "Off \xB7 no time line after a reply. Select to turn on."
|
|
42817
|
+
},
|
|
42812
42818
|
{
|
|
42813
42819
|
name: "config sources",
|
|
42814
42820
|
label: "Setting sources",
|
|
@@ -43673,6 +43679,15 @@ ${answered.context}` : slash.text;
|
|
|
43673
43679
|
}
|
|
43674
43680
|
case "context": {
|
|
43675
43681
|
pushMessage("system", dispatch.trim(), false, "\u203A", void 0, tokenColor("accent.user"));
|
|
43682
|
+
if (state !== "idle" || abortRef.current !== null || hasUnsettledTurn()) {
|
|
43683
|
+
pushMessage(
|
|
43684
|
+
"system",
|
|
43685
|
+
"Numbers are as of the last finished reply; the running reply is not counted yet.",
|
|
43686
|
+
false,
|
|
43687
|
+
"\u23BF"
|
|
43688
|
+
);
|
|
43689
|
+
}
|
|
43690
|
+
const anchorId = idRef.current;
|
|
43676
43691
|
void (async () => {
|
|
43677
43692
|
const view = await buildContextRow({
|
|
43678
43693
|
usage,
|
|
@@ -43693,15 +43708,19 @@ ${answered.context}` : slash.text;
|
|
|
43693
43708
|
pushMessage("system", view, false, "\u23BF");
|
|
43694
43709
|
return;
|
|
43695
43710
|
}
|
|
43696
|
-
|
|
43697
|
-
|
|
43698
|
-
|
|
43699
|
-
|
|
43700
|
-
|
|
43701
|
-
|
|
43702
|
-
|
|
43703
|
-
|
|
43704
|
-
|
|
43711
|
+
const row2 = {
|
|
43712
|
+
id: nextId(),
|
|
43713
|
+
role: "system",
|
|
43714
|
+
content: view.text,
|
|
43715
|
+
contextView: view
|
|
43716
|
+
};
|
|
43717
|
+
setMessages((previous) => {
|
|
43718
|
+
const later = previous.findIndex((message) => {
|
|
43719
|
+
const n = /^m(\d+)$/.exec(message.id);
|
|
43720
|
+
return n !== null && Number(n[1]) > anchorId;
|
|
43721
|
+
});
|
|
43722
|
+
return later < 0 ? [...previous, row2] : [...previous.slice(0, later), row2, ...previous.slice(later)];
|
|
43723
|
+
});
|
|
43705
43724
|
})();
|
|
43706
43725
|
return;
|
|
43707
43726
|
}
|
|
@@ -43960,7 +43979,7 @@ ${answered.context}` : slash.text;
|
|
|
43960
43979
|
return;
|
|
43961
43980
|
}
|
|
43962
43981
|
case "config-setting": {
|
|
43963
|
-
void import("./setting-cli-
|
|
43982
|
+
void import("./setting-cli-ETVPDSRA.js").then((cli) => {
|
|
43964
43983
|
if (slash.text === void 0 && slash.clear !== true) {
|
|
43965
43984
|
try {
|
|
43966
43985
|
pushMessage("system", cli.describeSetting(slash.key));
|
|
@@ -44022,6 +44041,22 @@ ${answered.context}` : slash.text;
|
|
|
44022
44041
|
);
|
|
44023
44042
|
return;
|
|
44024
44043
|
}
|
|
44044
|
+
case "turn-duration": {
|
|
44045
|
+
if (slash.on === "list") {
|
|
44046
|
+
pushMessage("system", describeTurnDuration(showTurnDuration));
|
|
44047
|
+
return;
|
|
44048
|
+
}
|
|
44049
|
+
const profile = ctx.configDebug?.selectedProfile?.name;
|
|
44050
|
+
setTurnDurationOverride(slash.on);
|
|
44051
|
+
pushMessage(
|
|
44052
|
+
"system",
|
|
44053
|
+
setShowTurnDuration(slash.on, {
|
|
44054
|
+
cwd: ctx.cwd,
|
|
44055
|
+
...profile ? { profile } : {}
|
|
44056
|
+
})
|
|
44057
|
+
);
|
|
44058
|
+
return;
|
|
44059
|
+
}
|
|
44025
44060
|
case "fast-mode": {
|
|
44026
44061
|
void applyFastMode(slash.tier);
|
|
44027
44062
|
return;
|
|
@@ -44412,6 +44447,13 @@ ${answered.context}` : slash.text;
|
|
|
44412
44447
|
source: "launch-message"
|
|
44413
44448
|
});
|
|
44414
44449
|
}, [phase, state, session, permission, textPrompt, choicePicker, handleSubmit]);
|
|
44450
|
+
const launchNameRef = (0, import_react30.useRef)(initialCtx.launchSettings?.name);
|
|
44451
|
+
(0, import_react30.useEffect)(() => {
|
|
44452
|
+
const name = launchNameRef.current;
|
|
44453
|
+
if (name === void 0 || phase !== "ready" || !session?.hasProvider) return;
|
|
44454
|
+
launchNameRef.current = void 0;
|
|
44455
|
+
void doTitle(name, false);
|
|
44456
|
+
}, [phase, session, doTitle]);
|
|
44415
44457
|
commandPickerSubmitRef.current = (command) => handleSubmit(command, void 0, "submit", { source: "command-picker" });
|
|
44416
44458
|
triggerFollowUpsRef.current = (st, ending) => {
|
|
44417
44459
|
const followUps = st.followUps ?? [];
|
|
@@ -44726,6 +44768,9 @@ ${answered.context}` : slash.text;
|
|
|
44726
44768
|
settings: networkSettings(ctxRef.current.network),
|
|
44727
44769
|
interactive: ctxRef.current.runNetwork === true && stdout.isTTY === true,
|
|
44728
44770
|
notify: /* @__PURE__ */ __name((text) => pushSystem("notice", text), "notify"),
|
|
44771
|
+
// A machine asking to join is a footer mark and one passing line, never a transcript row.
|
|
44772
|
+
notice: /* @__PURE__ */ __name((key, text) => addNotice({ key, text, tone: "warn", priority: "high", timeoutMs: 8e3 }), "notice"),
|
|
44773
|
+
onJoinRequests: /* @__PURE__ */ __name((count2) => setJoinRequestCount(count2), "onJoinRequests"),
|
|
44729
44774
|
ownRef: /* @__PURE__ */ __name(() => peersRef.current?.ref, "ownRef")
|
|
44730
44775
|
});
|
|
44731
44776
|
networkRef.current = network;
|
|
@@ -44780,7 +44825,7 @@ ${answered.context}` : slash.text;
|
|
|
44780
44825
|
appLifetime.signal.removeEventListener("abort", onClose);
|
|
44781
44826
|
if (!disposed) pushSystem("error", explainFailure(error, "Peer messaging unavailable."));
|
|
44782
44827
|
});
|
|
44783
|
-
}, [phase, appLifetime.signal, pushMessage, pushSystem, stdout.isTTY]);
|
|
44828
|
+
}, [phase, appLifetime.signal, pushMessage, pushSystem, addNotice, stdout.isTTY]);
|
|
44784
44829
|
const peerName = conversationNames.named ?? conversationNames.generated;
|
|
44785
44830
|
(0, import_react30.useEffect)(() => {
|
|
44786
44831
|
peersRef.current?.publish();
|
|
@@ -45507,7 +45552,7 @@ ${answered.context}` : slash.text;
|
|
|
45507
45552
|
return;
|
|
45508
45553
|
}
|
|
45509
45554
|
setAgentSurface(null);
|
|
45510
|
-
setRailFocus(
|
|
45555
|
+
setRailFocus(null);
|
|
45511
45556
|
return;
|
|
45512
45557
|
}
|
|
45513
45558
|
if (agentView.focus === "agents" && hasPhaseLevel) {
|
|
@@ -45525,7 +45570,7 @@ ${answered.context}` : slash.text;
|
|
|
45525
45570
|
} else if (agentView.focus !== "workflows") {
|
|
45526
45571
|
if (agentView.railReturn !== void 0) {
|
|
45527
45572
|
setAgentSurface(null);
|
|
45528
|
-
setRailFocus(
|
|
45573
|
+
setRailFocus(null);
|
|
45529
45574
|
} else if (workflows.length > 1) {
|
|
45530
45575
|
setAgentSurface({ ...agentView, focus: "workflows" });
|
|
45531
45576
|
} else {
|
|
@@ -45867,6 +45912,10 @@ ${answered.context}` : slash.text;
|
|
|
45867
45912
|
});
|
|
45868
45913
|
return;
|
|
45869
45914
|
}
|
|
45915
|
+
if (key.ctrl && key.shift && input === "c") {
|
|
45916
|
+
fullscreenControl.current?.takeCopy();
|
|
45917
|
+
return;
|
|
45918
|
+
}
|
|
45870
45919
|
if (fullscreenControl.current) {
|
|
45871
45920
|
if (key.escape && fullscreenControl.current.takeEscape()) return;
|
|
45872
45921
|
if (isAction("app:interrupt", input, key) && fullscreenControl.current.takeCopy()) return;
|
|
@@ -45879,6 +45928,8 @@ ${answered.context}` : slash.text;
|
|
|
45879
45928
|
(key.return && !composerHasDraft || key.escape && !vimOwnsEscapeRef.current)) {
|
|
45880
45929
|
const parked = handoffParkRef.current;
|
|
45881
45930
|
setHandoffPark(null);
|
|
45931
|
+
pausedTurnMayBeWaitingRef.current = false;
|
|
45932
|
+
signInAutoResumesRef.current = 0;
|
|
45882
45933
|
if (parked.spentAllowance) {
|
|
45883
45934
|
if (key.return) accountActionsRef.current?.open(parked.spentAllowance);
|
|
45884
45935
|
return;
|
|
@@ -45886,10 +45937,15 @@ ${answered.context}` : slash.text;
|
|
|
45886
45937
|
if (key.return) {
|
|
45887
45938
|
autoResumeAttemptRef.current = 0;
|
|
45888
45939
|
selfMendingPauseRowRef.current.forget();
|
|
45889
|
-
void resumeActiveTurn({ handoffReason: parked.reason });
|
|
45940
|
+
void resumeActiveTurn({ handoffReason: parked.reason, explain: true });
|
|
45890
45941
|
} else void abandonActiveTurn("The operator stopped the turn a tool paused for them.");
|
|
45891
45942
|
return;
|
|
45892
45943
|
}
|
|
45944
|
+
if (key.return && !composerHasDraft && !handoffParkRef.current && phase === "ready" && state === "idle" && !abortRef.current && pausedTurnMayBeWaitingRef.current) {
|
|
45945
|
+
pausedTurnMayBeWaitingRef.current = false;
|
|
45946
|
+
void resumeActiveTurn({ explain: true });
|
|
45947
|
+
return;
|
|
45948
|
+
}
|
|
45893
45949
|
if (key.escape && queueSelectionRef.current !== null) {
|
|
45894
45950
|
setQueueSelection(null);
|
|
45895
45951
|
return;
|
|
@@ -45980,7 +46036,7 @@ ${answered.context}` : slash.text;
|
|
|
45980
46036
|
const currentNotice = notices.current;
|
|
45981
46037
|
const noticeIsImmediate = currentNotice?.priority === "immediate";
|
|
45982
46038
|
const noticeIsCritical = noticeHoldsFooter(currentNotice, boxOwnsKeys);
|
|
45983
|
-
const statusHint = exitHint ? `Press ${exitHint} again to exit` : noticeIsImmediate ? void 0 : conversationMutation === "fork" ? "forking conversation \u2014 input is paused" : conversationMutation === "edit" ? "branching before prompt \u2014 input is paused" : conversationMutation === "archive" ? "archiving conversation \u2014 input is paused" : conversationMutation === "new" ? "starting a fresh conversation \u2014 input is paused" : compacting ? "compacting conversation \u2014 input is paused" : boxOwnsKeys ? void 0 : handoffPark && phase === "ready" && state === "idle" && !composerHasDraft ? handoffPark.spentAllowance ? CONTINUE_WITH_ANOTHER_ACCOUNT : handoffPark.autoResume ? `trying again in ${formatSpan(Math.max(0, handoffPark.autoResume.at - Date.now()))} \xB7 enter try now \xB7 esc stop` : "enter continue \xB7 esc stop" : goalStatus && phase === "ready" && state === "idle" ? void 0 : hintForPhase(phase, state, composerHasDraft);
|
|
46039
|
+
const statusHint = exitHint ? `Press ${exitHint} again to exit` : noticeIsImmediate ? void 0 : conversationMutation === "fork" ? "forking conversation \u2014 input is paused" : conversationMutation === "edit" ? "branching before prompt \u2014 input is paused" : conversationMutation === "archive" ? "archiving conversation \u2014 input is paused" : conversationMutation === "new" ? "starting a fresh conversation \u2014 input is paused" : compacting ? "compacting conversation \u2014 input is paused" : boxOwnsKeys ? void 0 : handoffPark && phase === "ready" && state === "idle" && !composerHasDraft ? handoffPark.spentAllowance ? CONTINUE_WITH_ANOTHER_ACCOUNT : handoffPark.autoResume ? `trying again in ${formatSpan(Math.max(0, handoffPark.autoResume.at - Date.now()))} \xB7 enter try now \xB7 esc stop` : "enter continue \xB7 or type a message \xB7 esc stop" : goalStatus && phase === "ready" && state === "idle" ? void 0 : hintForPhase(phase, state, composerHasDraft);
|
|
45984
46040
|
const permissionSource = reviewSource(permission, scopeRef.current?.sessionId);
|
|
45985
46041
|
const permissionOwner = permissionSource ? subagents.find((agent) => agent.sessionId === permissionSource) : void 0;
|
|
45986
46042
|
const permissionSourceLabel = permissionSource ? permissionOwner ? `from the ${permissionOwner.description} agent` : "from another agent" : void 0;
|
|
@@ -46014,12 +46070,8 @@ ${answered.context}` : slash.text;
|
|
|
46014
46070
|
const showComposerSurface = !providerSetup && phase !== "trust" && phase !== "unhealthy" && phase !== "resume" && phase !== "edit" && phase !== "picker";
|
|
46015
46071
|
const childSurfaceOpen = agentSurface !== null && viewingAgent === void 0 || transcriptScreen || jobSurface !== null;
|
|
46016
46072
|
const replyRunningNow = !compacting && (state === "thinking" || state === "tool" || pendingModelSwitchRef.current !== null) || handoffPark !== null && state === "idle";
|
|
46017
|
-
const workflowDetailOpen = showComposerSurface && permission === null && scheduleReviewPrompt === null && agentSurface?.kind === "cockpit" && !transcriptScreen && jobSurface === null;
|
|
46018
|
-
const detailRows = workflowDetailHeight(
|
|
46019
|
-
terminal.rows,
|
|
46020
|
-
fullscreen !== void 0,
|
|
46021
|
-
composerBoxRows + 1 + (extensionMarks.length > 0 ? 1 : 0) + 4
|
|
46022
|
-
);
|
|
46073
|
+
const workflowDetailOpen = showComposerSurface && permission === null && scheduleReviewPrompt === null && questionDialog === null && planPrompt === null && saveSkillPrompt === null && textPrompt === null && choicePicker === null && copyPicker === null && agentSurface?.kind === "cockpit" && !transcriptScreen && jobSurface === null;
|
|
46074
|
+
const detailRows = workflowDetailHeight(terminal.rows - (extensionMarks.length > 0 ? 1 : 0));
|
|
46023
46075
|
const viewRailRows = liveSubagents.length > 0 || liveWorkflows.length > 0 ? 1 + (railShowsMain(liveSubagents.length, viewingAgent?.viewId) ? 1 : 0) + Math.min(liveSubagents.length, AGENT_RAIL_WINDOW) + (liveSubagents.length > AGENT_RAIL_WINDOW ? 1 : 0) + liveWorkflows.length : 0;
|
|
46024
46076
|
viewRailRowsRef.current = viewRailRows;
|
|
46025
46077
|
const viewPageRows = agentViewPageRows(terminal.rows, viewRailRows);
|
|
@@ -46341,6 +46393,7 @@ ${answered.context}` : slash.text;
|
|
|
46341
46393
|
subtitle: choicePicker.subtitle,
|
|
46342
46394
|
hints: workflowRunsHints(workflowPickerCanStop, workflowPickerCanResume)
|
|
46343
46395
|
} : {},
|
|
46396
|
+
...choicePicker.kind === "peers-network" && choicePicker.body ? { body: choicePicker.body } : {},
|
|
46344
46397
|
...choicePicker.kind === "account" ? { hints: ACCOUNT_PICKER_HINTS } : {},
|
|
46345
46398
|
options: filterChoiceOptions(choicePicker.options, choiceQuery),
|
|
46346
46399
|
describeSelected: choicePicker.kind === "user-question" || choicePicker.kind === "peers-network",
|
|
@@ -46381,8 +46434,7 @@ ${answered.context}` : slash.text;
|
|
|
46381
46434
|
}
|
|
46382
46435
|
) : null,
|
|
46383
46436
|
workflowDetailOpen && agentSurface?.kind === "cockpit" ? (
|
|
46384
|
-
//
|
|
46385
|
-
// above, and the box and the status line stay under it.
|
|
46437
|
+
// In place of the message box and the status line, under the conversation.
|
|
46386
46438
|
/* @__PURE__ */ (0, import_jsx_runtime37.jsx)(Box_default, { height: detailRows, flexShrink: 0, flexDirection: "column", overflowY: "hidden", children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
|
|
46387
46439
|
AgentCockpit,
|
|
46388
46440
|
{
|
|
@@ -46416,7 +46468,7 @@ ${answered.context}` : slash.text;
|
|
|
46416
46468
|
activation: hypermodeActivation,
|
|
46417
46469
|
animate: externalEditorRequest === null,
|
|
46418
46470
|
focus: phase === "ready" && state !== "awaiting-permission" && !compacting && externalEditorRequest === null && conversationMutation === null && textPrompt === null && choicePicker === null && copyPicker === null && saveSkillPrompt === null && planPrompt === null && questionDialog === null && scheduleReviewPrompt === null && !scrollOpen && !childSurfaceOpen,
|
|
46419
|
-
hidden: permission !== null || saveSkillPrompt !== null || planPrompt !== null || questionDialog !== null || scheduleReviewPrompt !== null || textPrompt !== null || choicePicker !== null || copyPicker !== null || childSurfaceOpen
|
|
46471
|
+
hidden: permission !== null || saveSkillPrompt !== null || planPrompt !== null || questionDialog !== null || scheduleReviewPrompt !== null || textPrompt !== null || choicePicker !== null || copyPicker !== null || childSurfaceOpen,
|
|
46420
46472
|
children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
|
|
46421
46473
|
Composer,
|
|
46422
46474
|
{
|
|
@@ -46426,12 +46478,11 @@ ${answered.context}` : slash.text;
|
|
|
46426
46478
|
} : examplePrompts && history.length === 0 && !messages.some((message) => message.role === "user") ? {
|
|
46427
46479
|
placeholder: examplePlaceholder(exampleFile, exampleSeedRef.current)
|
|
46428
46480
|
} : promptSuggestion !== void 0 ? { promptSuggestion } : {},
|
|
46429
|
-
parked: workflowDetailOpen,
|
|
46430
46481
|
mayReadImage: imageReadPolicy,
|
|
46431
46482
|
reasoningEffortLevels: session?.reasoningEffortLevels,
|
|
46432
46483
|
onCycleMode: cyclePermissionMode,
|
|
46433
46484
|
disabled: transcriptScreen || fullscreenSearching || scrollOpen || jobSurface !== null || phase !== "ready" || state === "awaiting-permission" || compacting || conversationMutation !== null || externalEditorRequest !== null || railFocus !== null || childSurfaceOpen,
|
|
46434
|
-
hidden: permission !== null || saveSkillPrompt !== null || planPrompt !== null || questionDialog !== null || scheduleReviewPrompt !== null || textPrompt !== null || choicePicker !== null || copyPicker !== null || childSurfaceOpen
|
|
46485
|
+
hidden: permission !== null || saveSkillPrompt !== null || planPrompt !== null || questionDialog !== null || scheduleReviewPrompt !== null || textPrompt !== null || choicePicker !== null || copyPicker !== null || childSurfaceOpen,
|
|
46435
46486
|
escapeInterrupts: !compacting && (state === "thinking" || state === "tool" || pendingModelSwitchRef.current !== null) || handoffPark !== null && state === "idle",
|
|
46436
46487
|
onSubmit: handleSubmit,
|
|
46437
46488
|
onNotice: (text) => pushMessage("system", text),
|
|
@@ -46501,9 +46552,9 @@ ${answered.context}` : slash.text;
|
|
|
46501
46552
|
}
|
|
46502
46553
|
) })
|
|
46503
46554
|
] }),
|
|
46504
|
-
phase === "trust" || transcriptScreen || !showComposerSurface || statusLineText === void 0 ? null : /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(StatusLineRows, { text: statusLineText, padding: ctx.statusLine?.padding ?? 0 }),
|
|
46555
|
+
phase === "trust" || transcriptScreen || workflowDetailOpen || !showComposerSurface || statusLineText === void 0 ? null : /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(StatusLineRows, { text: statusLineText, padding: ctx.statusLine?.padding ?? 0 }),
|
|
46505
46556
|
phase === "trust" ? null : /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(ExtensionIndicatorRow, { marks: extensionMarks }),
|
|
46506
|
-
phase === "trust" || transcriptScreen || dialogShowing && !exitHint && !noticeIsImmediate ? null : /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
|
|
46557
|
+
phase === "trust" || transcriptScreen || workflowDetailOpen || dialogShowing && !exitHint && !noticeIsImmediate ? null : /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
|
|
46507
46558
|
StatusBar,
|
|
46508
46559
|
{
|
|
46509
46560
|
provider: session?.providerSummary ?? null,
|
|
@@ -46532,6 +46583,7 @@ ${answered.context}` : slash.text;
|
|
|
46532
46583
|
restingHint: ctx.statusLine === void 0,
|
|
46533
46584
|
shellCount: showComposerSurface && !childSurfaceOpen ? runningShellCount : 0,
|
|
46534
46585
|
monitorCount: showComposerSurface && !childSurfaceOpen ? runningMonitorCount : 0,
|
|
46586
|
+
joinRequests: joinRequestCount,
|
|
46535
46587
|
pr: prStatus,
|
|
46536
46588
|
hyperlinks,
|
|
46537
46589
|
agentCount: leftOffersAgents ? runningAgentCount : 0,
|
|
@@ -46926,7 +46978,7 @@ function pluginActionPicker(owner, name) {
|
|
|
46926
46978
|
};
|
|
46927
46979
|
}
|
|
46928
46980
|
__name(pluginActionPicker, "pluginActionPicker");
|
|
46929
|
-
var BYPASS_UNAVAILABLE_NOTICE = "Bypass mode is not available in this session. Start Namzu with --allow-dangerously-skip-permissions
|
|
46981
|
+
var BYPASS_UNAVAILABLE_NOTICE = "Bypass mode is not available in this session. Start Namzu with --allow-dangerously-skip-permissions, or set permissions.allowBypassMode to true in your own config file, to use it, unless permissions.disableBypassMode is set.";
|
|
46930
46982
|
var AUTO_UNAVAILABLE_NOTICE = "Auto mode is not available in this session.";
|
|
46931
46983
|
var AUTO_MODE_STOPPED_NOTICE = "Auto mode could not get a safety decision, so nothing was run and Namzu stopped. Send a message to try again, or press Shift+Tab to change the mode.";
|
|
46932
46984
|
var AUTO_MODE_DEFAULT_STOPPED_NOTICE = "Auto mode could not get a safety decision, so nothing was run and Namzu stopped. This terminal now asks before changes: send a message to carry on, or use /permissions auto to go back to auto mode.";
|
|
@@ -47072,4 +47124,4 @@ export {
|
|
|
47072
47124
|
projectConversation,
|
|
47073
47125
|
App
|
|
47074
47126
|
};
|
|
47075
|
-
//# sourceMappingURL=chunk-
|
|
47127
|
+
//# sourceMappingURL=chunk-U4DBETHR.js.map
|