@namzu/cli 53.2.1 → 53.3.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 +45 -0
- package/dist/bin.js +1 -1
- package/dist/chunks/{acp-RVXP6JYI.js → acp-TDBFWPHB.js} +59 -57
- package/dist/chunks/acp-TDBFWPHB.js.map +6 -0
- package/dist/chunks/{activity-command-URELNCMX.js → activity-command-OS75DEKF.js} +12 -12
- package/dist/chunks/{add-S5EFCMBB.js → add-LNQAOHZS.js} +19 -19
- package/dist/chunks/{agent-FHKVVYCJ.js → agent-MM4SMTQS.js} +43 -41
- package/dist/chunks/agent-session-RPSTX6GN.js +79 -0
- package/dist/chunks/{apply-at-exit-LR5XT7FM.js → apply-at-exit-EY73HTUZ.js} +11 -12
- package/dist/chunks/apply-at-exit-EY73HTUZ.js.map +6 -0
- package/dist/chunks/{archive-A37GUHNR.js → archive-I7X74XA6.js} +10 -10
- package/dist/chunks/{bin-main-WTM64ZLB.js → bin-main-M66LUUMP.js} +9 -9
- package/dist/chunks/{binding-JIILVHUU.js → binding-L45TTMZJ.js} +3 -3
- package/dist/chunks/{browser-UYISYE63.js → browser-DNPDAQFD.js} +6 -6
- package/dist/chunks/{chat-AJVT3PZ4.js → chat-RPQFKIAD.js} +15 -15
- package/dist/chunks/{chunk-XTS4BWEA.js → chunk-27BVRMUJ.js} +2 -2
- package/dist/chunks/{chunk-CVUHHALT.js → chunk-2LOYDAU5.js} +6 -6
- package/dist/chunks/{chunk-N7Y7J6RY.js → chunk-2XOJQKYX.js} +16 -16
- package/dist/chunks/{chunk-2IMSB7XK.js → chunk-3EH3USMD.js} +2 -2
- package/dist/chunks/{chunk-ZGXGRKTT.js → chunk-4E6HWHOX.js} +4 -4
- package/dist/chunks/{chunk-NYSXRWIC.js → chunk-4ITXTSNQ.js} +2 -2
- package/dist/chunks/{chunk-4DER34EW.js → chunk-5CGQ2AOP.js} +2 -2
- package/dist/chunks/{chunk-LFJYO4YC.js → chunk-5KHKXEP5.js} +2 -2
- package/dist/chunks/{chunk-LL6ZXDH3.js → chunk-5LWBZYOK.js} +3 -3
- package/dist/chunks/{chunk-IFCUIKLP.js → chunk-62LRLDHY.js} +10 -10
- package/dist/chunks/{chunk-2FZ5I36Y.js → chunk-6IUD3NVQ.js} +345 -25
- package/dist/chunks/chunk-6IUD3NVQ.js.map +6 -0
- package/dist/chunks/{chunk-6E4XSINO.js → chunk-6NFHP44E.js} +2 -2
- package/dist/chunks/{chunk-GXFCNVRN.js → chunk-6PIZ3336.js} +5 -5
- package/dist/chunks/{chunk-MOMUAPLM.js → chunk-7DTV64LX.js} +9 -9
- package/dist/chunks/{chunk-3HLKXSR4.js → chunk-7KIVKXQB.js} +5 -5
- package/dist/chunks/{chunk-XNQMO4UQ.js → chunk-A4RKSHUI.js} +4 -4
- package/dist/chunks/{chunk-IFNX2DCK.js → chunk-ARPABLFS.js} +3 -3
- package/dist/chunks/{chunk-OARZW3MB.js → chunk-B5O2UDMT.js} +3 -3
- package/dist/chunks/{chunk-5HZGL2CJ.js → chunk-BGYZ3SVB.js} +2 -2
- package/dist/chunks/{chunk-FVSMLXXD.js → chunk-BRSUV2MI.js} +5 -5
- package/dist/chunks/{chunk-BY57QRDB.js → chunk-BULDCXFX.js} +357 -143
- package/dist/chunks/chunk-BULDCXFX.js.map +6 -0
- package/dist/chunks/{chunk-UTT4MLLS.js → chunk-BWUBI6VE.js} +2 -2
- package/dist/chunks/{chunk-XH3JG354.js → chunk-BZMMDJFZ.js} +3 -3
- package/dist/chunks/{chunk-DTI6LBPL.js → chunk-CS7Q2ZUU.js} +2 -2
- package/dist/chunks/{chunk-2JDHGE5X.js → chunk-D32E7XO6.js} +2 -2
- package/dist/chunks/{chunk-I2WWQWOI.js → chunk-DCV3FVXI.js} +2 -2
- package/dist/chunks/{chunk-YZAM5OII.js → chunk-DLHPY4VQ.js} +4 -4
- package/dist/chunks/{chunk-ZJ56MAER.js → chunk-E3L237Z7.js} +2 -2
- package/dist/chunks/{chunk-XO6WQQ67.js → chunk-ENJM7PYT.js} +3 -3
- package/dist/chunks/{chunk-EVGU3BR6.js → chunk-F7M6MIAS.js} +9 -5
- package/dist/chunks/chunk-F7M6MIAS.js.map +6 -0
- package/dist/chunks/{chunk-BT76TYMR.js → chunk-FLRYCMRH.js} +2 -2
- package/dist/chunks/{chunk-AR7JOE6W.js → chunk-FY3ZMDWN.js} +6 -6
- package/dist/chunks/{chunk-RYVWRI2O.js → chunk-G7PWYTB4.js} +2 -2
- package/dist/chunks/{chunk-EIK35VTY.js → chunk-GIKCLC27.js} +4 -4
- package/dist/chunks/{chunk-YWJ4WKSM.js → chunk-HLLAVDYT.js} +38 -38
- package/dist/chunks/{chunk-NTN4HVCG.js → chunk-HM5UJONE.js} +14 -14
- package/dist/chunks/{chunk-2UKMUTVB.js → chunk-HVFIYEP6.js} +6 -6
- package/dist/chunks/{chunk-FUPKNX52.js → chunk-IWZXZZMU.js} +3 -3
- package/dist/chunks/{chunk-QOGLGPLA.js → chunk-JG462CCT.js} +2 -2
- package/dist/chunks/{chunk-EP6JEZ6Y.js → chunk-K3AE66MM.js} +4 -4
- package/dist/chunks/{chunk-WWFYM2UR.js → chunk-KOGSKOU7.js} +2 -2
- package/dist/chunks/{chunk-YXX7ARE5.js → chunk-KP4H7FJ7.js} +2 -2
- package/dist/chunks/{chunk-4Q7Y6SKU.js → chunk-LAMQGSGH.js} +5 -5
- package/dist/chunks/{chunk-2CNFTOKO.js → chunk-LDMHANNT.js} +4 -4
- package/dist/chunks/chunk-LDMHANNT.js.map +6 -0
- package/dist/chunks/{chunk-KC2CIMAX.js → chunk-LITTVCZQ.js} +18 -11
- package/dist/chunks/chunk-LITTVCZQ.js.map +6 -0
- package/dist/chunks/{chunk-H6UQL66Z.js → chunk-LJQAGSYZ.js} +3 -3
- package/dist/chunks/{chunk-JLGLQMAN.js → chunk-LQ5L75T6.js} +4 -4
- package/dist/chunks/{chunk-NMYUBZZU.js → chunk-LYMSGP53.js} +2 -2
- package/dist/chunks/{chunk-JIWW55EF.js → chunk-LYTMEPN4.js} +12 -3
- package/dist/chunks/chunk-LYTMEPN4.js.map +6 -0
- package/dist/chunks/{chunk-ODQ6JG66.js → chunk-MDAEHXSL.js} +3 -3
- package/dist/chunks/{chunk-J6YNCFQG.js → chunk-MM4BFFRT.js} +3 -3
- package/dist/chunks/{chunk-UNSMBZM3.js → chunk-MRSWBORX.js} +40 -21
- package/dist/chunks/chunk-MRSWBORX.js.map +6 -0
- package/dist/chunks/{chunk-Y6WCUDCQ.js → chunk-MYHK6KOU.js} +3 -3
- package/dist/chunks/{chunk-AV7SMPXT.js → chunk-MYQ2MZKF.js} +6 -6
- package/dist/chunks/{chunk-5LSXNZBY.js → chunk-NA6FHE5K.js} +2 -2
- package/dist/chunks/{chunk-526VZQN4.js → chunk-NDGMUBFS.js} +3 -3
- package/dist/chunks/{chunk-G44HNSPD.js → chunk-NEYRPPT5.js} +2 -2
- package/dist/chunks/{chunk-DADJ4GQ2.js → chunk-NJ4PLSBZ.js} +2 -2
- package/dist/chunks/{chunk-RZILFYMH.js → chunk-NRHUKGZ3.js} +3 -3
- package/dist/chunks/{chunk-H4SIPZ3Q.js → chunk-O6NHCC4Q.js} +4 -4
- package/dist/chunks/{chunk-K7MLADWM.js → chunk-OH5T7ODG.js} +4 -4
- package/dist/chunks/{chunk-UZNITHS6.js → chunk-OLSRO4FC.js} +2 -2
- package/dist/chunks/{chunk-XBQFS7OK.js → chunk-OMFV2AEQ.js} +2 -2
- package/dist/chunks/{chunk-ZAJRK64O.js → chunk-P33ZADN3.js} +2 -2
- package/dist/chunks/{chunk-GELAA6HR.js → chunk-P6DJ6AS5.js} +2 -2
- package/dist/chunks/{chunk-G6FYM5SR.js → chunk-PGYSDVT7.js} +5 -5
- package/dist/chunks/{chunk-IFUOFLH7.js → chunk-PJPPWJIB.js} +5 -5
- package/dist/chunks/{chunk-Q3HGNRKL.js → chunk-QWCFMVAZ.js} +3 -3
- package/dist/chunks/{chunk-XHLQEV4L.js → chunk-QYKPC5HO.js} +9 -9
- package/dist/chunks/{chunk-AZIXXTEN.js → chunk-RBUVQQLL.js} +4 -4
- package/dist/chunks/{chunk-WM6TW355.js → chunk-RMRGVJOA.js} +274 -71
- package/dist/chunks/chunk-RMRGVJOA.js.map +6 -0
- package/dist/chunks/{chunk-PIV6IFK2.js → chunk-RO7HHDLW.js} +4 -4
- package/dist/chunks/{chunk-YZPZQJTG.js → chunk-SC2FLZAI.js} +2 -2
- package/dist/chunks/{chunk-ZIEVVDOR.js → chunk-T6BRCKD3.js} +9 -9
- package/dist/chunks/{chunk-PZCNHP7O.js → chunk-TCAS4XVK.js} +2 -2
- package/dist/chunks/{chunk-VXRC5XNZ.js → chunk-U77IVKFU.js} +5 -5
- package/dist/chunks/{chunk-QIBMSMZA.js → chunk-UAD3AUKO.js} +2 -2
- package/dist/chunks/{cost-2D4AKLSB.js → chunk-UE2MJ5YP.js} +22 -103
- package/dist/chunks/chunk-UE2MJ5YP.js.map +6 -0
- package/dist/chunks/{chunk-AUNCOQGN.js → chunk-UQFW622M.js} +2 -2
- package/dist/chunks/{chunk-KNIPTSFW.js → chunk-UYC7YSMD.js} +3 -3
- package/dist/chunks/{chunk-GXOQRU72.js → chunk-V2OLXCTE.js} +7 -7
- package/dist/chunks/{chunk-TFXV3553.js → chunk-V73ZJCIQ.js} +3 -3
- package/dist/chunks/{chunk-M56YCKGZ.js → chunk-V7U4OXBC.js} +4 -4
- package/dist/chunks/{chunk-XNBNN3OW.js → chunk-VUNKDZ34.js} +3 -3
- package/dist/chunks/{chunk-EMLOKSP6.js → chunk-WUCZIFEU.js} +12 -12
- package/dist/chunks/{chunk-L4XN5ILM.js → chunk-WVQRVEZ7.js} +2 -2
- package/dist/chunks/{chunk-KGGI2PH4.js → chunk-WVZG6GRE.js} +3 -3
- package/dist/chunks/{chunk-LEFLHBYY.js → chunk-XQHHFTFX.js} +195 -144
- package/dist/chunks/chunk-XQHHFTFX.js.map +6 -0
- package/dist/chunks/{chunk-M5NXCEVY.js → chunk-XTYVS4SM.js} +3 -3
- package/dist/chunks/{chunk-UHFJTEZV.js → chunk-XZXE7L4B.js} +3 -3
- package/dist/chunks/{chunk-WL3HPARH.js → chunk-YDE7ZNUH.js} +2 -2
- package/dist/chunks/{chunk-YVLXLUGP.js → chunk-YJ25LOMP.js} +897 -693
- package/dist/chunks/chunk-YJ25LOMP.js.map +6 -0
- package/dist/chunks/{chunk-3WYIYJID.js → chunk-YOBDE45E.js} +4 -4
- package/dist/chunks/{chunk-SVEAODES.js → chunk-YZIUYGJT.js} +4 -4
- package/dist/chunks/{chunk-BBOGGNTL.js → chunk-Z4TNPAB4.js} +7 -7
- package/dist/chunks/{chunk-K6GW3ZS7.js → chunk-ZKCOQZ3U.js} +7 -1
- package/dist/chunks/chunk-ZKCOQZ3U.js.map +6 -0
- package/dist/chunks/{chunk-IRCIEEOM.js → chunk-ZNGRNTOY.js} +2 -2
- package/dist/chunks/{cli-runtime-ULOMVN5Y.js → cli-runtime-IJWC2OTK.js} +12 -12
- package/dist/chunks/{commands-MENGP42Y.js → commands-S7OW6RX6.js} +5 -5
- package/dist/chunks/cost-VA6HZQE6.js +118 -0
- package/dist/chunks/cost-VA6HZQE6.js.map +6 -0
- package/dist/chunks/{crash-report-NNFSJ43Y.js → crash-report-F663DOML.js} +6 -6
- package/dist/chunks/{dist-QXUTKQ55.js → dist-IOJ4RD22.js} +2 -2
- package/dist/chunks/{dist-PNWD3XCT.js → dist-KXNNNQJP.js} +10 -2
- package/dist/chunks/{dist-AXIGKZIL.js → dist-OZTQJUXV.js} +352 -46
- package/dist/chunks/dist-OZTQJUXV.js.map +6 -0
- package/dist/chunks/{dist-EQE2TVFV.js → dist-S7E46RVO.js} +2 -2
- package/dist/chunks/{dist-INIQ54DO.js → dist-VNVQM6JU.js} +2 -2
- package/dist/chunks/{dist-7JVVF6E3.js → dist-XY5CE56Y.js} +2 -2
- package/dist/chunks/{dist-GWSFISZW.js → dist-ZHVTRMOZ.js} +2 -2
- package/dist/chunks/{dist-6BYDAAGG.js → dist-ZXZ4LH3H.js} +2 -2
- package/dist/chunks/{doctor-GIFSKHDE.js → doctor-GH3XGHIB.js} +39 -39
- package/dist/chunks/{drain-WNGSFYGG.js → drain-YZXZQAUT.js} +9 -9
- package/dist/chunks/{entry-3ZDHM5YQ.js → entry-LGDDSUPB.js} +6 -6
- package/dist/chunks/{eval-4IIX7NIV.js → eval-EYN5BPLR.js} +7 -7
- package/dist/chunks/{exec-NNLZUIZJ.js → exec-BMAOOSOF.js} +41 -41
- package/dist/chunks/{home-S3SNMFFG.js → home-5OAGR5X5.js} +3 -3
- package/dist/chunks/{hooks-3T5XVQSK.js → hooks-WV6P6LIP.js} +16 -16
- package/dist/chunks/{hooks-report-3GDKOXB3.js → hooks-report-JUCEQJ73.js} +15 -15
- package/dist/chunks/{host-BTE2HSHJ.js → host-EISOQGKE.js} +10 -10
- package/dist/chunks/{host-queries-MWZKZJOA.js → host-queries-HJHMGU5N.js} +15 -15
- package/dist/chunks/{learn-DA2U4OPO.js → learn-27BG44YG.js} +11 -11
- package/dist/chunks/{learn-builtin-R5A4MYGZ.js → learn-builtin-K5HQZDEA.js} +14 -14
- package/dist/chunks/{lifecycle-P3BZYTFI.js → lifecycle-L3BEM34W.js} +28 -28
- package/dist/chunks/{list-SIJK3GE5.js → list-AB4VHNL2.js} +12 -12
- package/dist/chunks/{live-KY5OOYNO.js → live-UWUEDSPR.js} +37 -37
- package/dist/chunks/{load-SI2C6QKJ.js → load-NFDONLZ2.js} +7 -7
- package/dist/chunks/{login-WOAZ5OLO.js → login-GON2CRE6.js} +12 -12
- package/dist/chunks/{logs-ZXSLLFAK.js → logs-C7WBBIJR.js} +4 -4
- package/dist/chunks/{mcp-TRDRYPNW.js → mcp-EBV34ZOW.js} +20 -20
- package/dist/chunks/{message-command-LR5MNLOD.js → message-command-Q7U54E4U.js} +49 -47
- package/dist/chunks/message-command-Q7U54E4U.js.map +6 -0
- package/dist/chunks/{open-KTUOVJCU.js → open-DLDZOPHP.js} +8 -8
- package/dist/chunks/{operator-tools-HN6MNPZW.js → operator-tools-HT2GSJ56.js} +13 -13
- package/dist/chunks/{output-schema-4LL23SA5.js → output-schema-UODVJVW4.js} +3 -3
- package/dist/chunks/{pal-C7A3S6MR.js → pal-PN4RXHBT.js} +15 -15
- package/dist/chunks/{peers-HINKWP3P.js → peers-HYMQ3RDX.js} +9 -9
- package/dist/chunks/{peers-IYCZ3OWB.js → peers-MVQTZ4ND.js} +6 -6
- package/dist/chunks/{plugin-YBGRF5FP.js → plugin-Y4XV5CKG.js} +15 -15
- package/dist/chunks/{providers-AI27XYWT.js → providers-K23QPBYN.js} +10 -10
- package/dist/chunks/{pty-7OTKGV53.js → pty-UIYKKO63.js} +3 -3
- package/dist/chunks/resume-ON75M2JL.js +23 -0
- package/dist/chunks/{resume-command-PG63DMVD.js → resume-command-O6FGFDSE.js} +4 -4
- package/dist/chunks/{running-CNUUXGYY.js → running-DAUDQDDJ.js} +6 -5
- package/dist/chunks/{schedule-37J3S7UQ.js → schedule-U7UZBKHQ.js} +8 -8
- package/dist/chunks/{send-7JV6J5T5.js → send-3R5RDV2H.js} +15 -15
- package/dist/chunks/{send-person-J5BSYFXQ.js → send-person-6NMIN4OT.js} +13 -13
- package/dist/chunks/{service-NSMWSI2E.js → service-2PDUZZPQ.js} +28 -28
- package/dist/chunks/{skills-AXZ5ETFS.js → skills-4UXJESZB.js} +13 -13
- package/dist/chunks/{start-check-V2U4533P.js → start-check-L62L5YIZ.js} +2 -2
- package/dist/chunks/{startup-failure-4HKS72EM.js → startup-failure-VS2U4JIC.js} +2 -2
- package/dist/chunks/{state-NVCB2RFV.js → state-DMLD6RWU.js} +2 -2
- package/dist/chunks/{store-2BFQ2UUT.js → store-3WIIBVKJ.js} +4 -4
- package/dist/chunks/{store-XBERR7IC.js → store-DIVYPBNS.js} +3 -3
- package/dist/chunks/{store-IACUKT6H.js → store-TYFJML3O.js} +10 -10
- package/dist/chunks/{store-FUNVZ2G4.js → store-ZLCDFCYI.js} +6 -6
- package/dist/chunks/{tui-UOTMH2CQ.js → tui-MMFCXIWN.js} +90 -85
- package/dist/chunks/tui-MMFCXIWN.js.map +6 -0
- package/dist/chunks/{upgrade-FBBMIEF6.js → upgrade-F6JAFFIV.js} +11 -12
- package/dist/chunks/upgrade-F6JAFFIV.js.map +6 -0
- package/dist/chunks/{watch-KKCKSEUU.js → watch-TU7OG2DS.js} +82 -81
- package/dist/chunks/watch-TU7OG2DS.js.map +6 -0
- package/dist/chunks/{workspaces-WDQH4NP3.js → workspaces-ZHM5N3OY.js} +16 -16
- package/dist/chunks/{worktree-SRCZK4CS.js → worktree-2MMIAPGE.js} +19 -19
- package/dist/context/doctrine.d.ts.map +1 -1
- package/dist/context/identity.d.ts.map +1 -1
- package/dist/doctor/checks/updates.d.ts.map +1 -1
- package/dist/index.js +39 -39
- package/dist/integrations/analysis/provider.d.ts.map +1 -1
- package/dist/integrations/auto-update/apply.d.ts +7 -0
- package/dist/integrations/auto-update/apply.d.ts.map +1 -1
- package/dist/integrations/auto-update/replaced-install.d.ts +2 -0
- package/dist/integrations/auto-update/replaced-install.d.ts.map +1 -1
- package/dist/integrations/auto-update/running.d.ts +16 -5
- package/dist/integrations/auto-update/running.d.ts.map +1 -1
- package/dist/integrations/auto-update/start.d.ts.map +1 -1
- package/dist/integrations/auto-update/status.d.ts +8 -0
- package/dist/integrations/auto-update/status.d.ts.map +1 -1
- package/dist/integrations/auto-update/swap.d.ts +77 -0
- package/dist/integrations/auto-update/swap.d.ts.map +1 -0
- package/dist/integrations/auto-update/updater.d.ts +4 -0
- package/dist/integrations/auto-update/updater.d.ts.map +1 -1
- package/dist/integrations/small-model/side-model.d.ts.map +1 -1
- package/dist/integrations/spend/fold.d.ts +2 -0
- package/dist/integrations/spend/fold.d.ts.map +1 -1
- package/dist/integrations/spend/session-cost.d.ts +46 -0
- package/dist/integrations/spend/session-cost.d.ts.map +1 -0
- package/dist/integrations/subagents/runtime.d.ts.map +1 -1
- package/dist/integrations/workflows/doctrine.d.ts.map +1 -1
- package/dist/integrations/workflows/offering.d.ts +6 -2
- package/dist/integrations/workflows/offering.d.ts.map +1 -1
- package/dist/termination.d.ts +1 -1
- package/dist/termination.d.ts.map +1 -1
- package/dist/tui/AgentExplorer.d.ts +29 -34
- package/dist/tui/AgentExplorer.d.ts.map +1 -1
- package/dist/tui/App.d.ts.map +1 -1
- package/dist/tui/BackgroundAgentRows.d.ts.map +1 -1
- package/dist/tui/ComposerFrame.d.ts +6 -1
- package/dist/tui/ComposerFrame.d.ts.map +1 -1
- package/dist/tui/StatusBar.d.ts +13 -19
- package/dist/tui/StatusBar.d.ts.map +1 -1
- package/dist/tui/Transcript.d.ts +9 -3
- package/dist/tui/Transcript.d.ts.map +1 -1
- package/dist/tui/UpdateNoticeRow.d.ts +36 -0
- package/dist/tui/UpdateNoticeRow.d.ts.map +1 -0
- package/dist/tui/agent-transcript-rows.d.ts +8 -4
- package/dist/tui/agent-transcript-rows.d.ts.map +1 -1
- package/dist/tui/agent.d.ts.map +1 -1
- package/dist/tui/fullscreen/layout.d.ts +3 -1
- package/dist/tui/fullscreen/layout.d.ts.map +1 -1
- package/dist/tui/index.d.ts.map +1 -1
- package/dist/tui/paint/live-paint.d.ts +19 -1
- package/dist/tui/paint/live-paint.d.ts.map +1 -1
- package/dist/tui/reply-mark.d.ts +12 -0
- package/dist/tui/reply-mark.d.ts.map +1 -0
- package/dist/tui/restored-rows.d.ts.map +1 -1
- package/dist/tui/transcript-scroll.d.ts +4 -0
- package/dist/tui/transcript-scroll.d.ts.map +1 -1
- package/package.json +5 -5
- package/dist/chunks/acp-RVXP6JYI.js.map +0 -6
- package/dist/chunks/agent-session-NJ6H25QY.js +0 -77
- package/dist/chunks/apply-at-exit-LR5XT7FM.js.map +0 -6
- package/dist/chunks/chunk-2CNFTOKO.js.map +0 -6
- package/dist/chunks/chunk-2FZ5I36Y.js.map +0 -6
- package/dist/chunks/chunk-BY57QRDB.js.map +0 -6
- package/dist/chunks/chunk-EVGU3BR6.js.map +0 -6
- package/dist/chunks/chunk-JIWW55EF.js.map +0 -6
- package/dist/chunks/chunk-K6GW3ZS7.js.map +0 -6
- package/dist/chunks/chunk-KC2CIMAX.js.map +0 -6
- package/dist/chunks/chunk-LEFLHBYY.js.map +0 -6
- package/dist/chunks/chunk-QVVJ5GAJ.js +0 -107
- package/dist/chunks/chunk-QVVJ5GAJ.js.map +0 -6
- package/dist/chunks/chunk-UNSMBZM3.js.map +0 -6
- package/dist/chunks/chunk-WM6TW355.js.map +0 -6
- package/dist/chunks/chunk-YVLXLUGP.js.map +0 -6
- package/dist/chunks/cost-2D4AKLSB.js.map +0 -6
- package/dist/chunks/dist-AXIGKZIL.js.map +0 -6
- package/dist/chunks/message-command-LR5MNLOD.js.map +0 -6
- package/dist/chunks/resume-2P6LYLYX.js +0 -23
- package/dist/chunks/tui-UOTMH2CQ.js.map +0 -6
- package/dist/chunks/upgrade-FBBMIEF6.js.map +0 -6
- package/dist/chunks/watch-KKCKSEUU.js.map +0 -6
- /package/dist/chunks/{activity-command-URELNCMX.js.map → activity-command-OS75DEKF.js.map} +0 -0
- /package/dist/chunks/{add-S5EFCMBB.js.map → add-LNQAOHZS.js.map} +0 -0
- /package/dist/chunks/{agent-FHKVVYCJ.js.map → agent-MM4SMTQS.js.map} +0 -0
- /package/dist/chunks/{agent-session-NJ6H25QY.js.map → agent-session-RPSTX6GN.js.map} +0 -0
- /package/dist/chunks/{archive-A37GUHNR.js.map → archive-I7X74XA6.js.map} +0 -0
- /package/dist/chunks/{bin-main-WTM64ZLB.js.map → bin-main-M66LUUMP.js.map} +0 -0
- /package/dist/chunks/{binding-JIILVHUU.js.map → binding-L45TTMZJ.js.map} +0 -0
- /package/dist/chunks/{browser-UYISYE63.js.map → browser-DNPDAQFD.js.map} +0 -0
- /package/dist/chunks/{chat-AJVT3PZ4.js.map → chat-RPQFKIAD.js.map} +0 -0
- /package/dist/chunks/{chunk-XTS4BWEA.js.map → chunk-27BVRMUJ.js.map} +0 -0
- /package/dist/chunks/{chunk-CVUHHALT.js.map → chunk-2LOYDAU5.js.map} +0 -0
- /package/dist/chunks/{chunk-N7Y7J6RY.js.map → chunk-2XOJQKYX.js.map} +0 -0
- /package/dist/chunks/{chunk-2IMSB7XK.js.map → chunk-3EH3USMD.js.map} +0 -0
- /package/dist/chunks/{chunk-ZGXGRKTT.js.map → chunk-4E6HWHOX.js.map} +0 -0
- /package/dist/chunks/{chunk-NYSXRWIC.js.map → chunk-4ITXTSNQ.js.map} +0 -0
- /package/dist/chunks/{chunk-4DER34EW.js.map → chunk-5CGQ2AOP.js.map} +0 -0
- /package/dist/chunks/{chunk-LFJYO4YC.js.map → chunk-5KHKXEP5.js.map} +0 -0
- /package/dist/chunks/{chunk-LL6ZXDH3.js.map → chunk-5LWBZYOK.js.map} +0 -0
- /package/dist/chunks/{chunk-IFCUIKLP.js.map → chunk-62LRLDHY.js.map} +0 -0
- /package/dist/chunks/{chunk-6E4XSINO.js.map → chunk-6NFHP44E.js.map} +0 -0
- /package/dist/chunks/{chunk-GXFCNVRN.js.map → chunk-6PIZ3336.js.map} +0 -0
- /package/dist/chunks/{chunk-MOMUAPLM.js.map → chunk-7DTV64LX.js.map} +0 -0
- /package/dist/chunks/{chunk-3HLKXSR4.js.map → chunk-7KIVKXQB.js.map} +0 -0
- /package/dist/chunks/{chunk-XNQMO4UQ.js.map → chunk-A4RKSHUI.js.map} +0 -0
- /package/dist/chunks/{chunk-IFNX2DCK.js.map → chunk-ARPABLFS.js.map} +0 -0
- /package/dist/chunks/{chunk-OARZW3MB.js.map → chunk-B5O2UDMT.js.map} +0 -0
- /package/dist/chunks/{chunk-5HZGL2CJ.js.map → chunk-BGYZ3SVB.js.map} +0 -0
- /package/dist/chunks/{chunk-FVSMLXXD.js.map → chunk-BRSUV2MI.js.map} +0 -0
- /package/dist/chunks/{chunk-UTT4MLLS.js.map → chunk-BWUBI6VE.js.map} +0 -0
- /package/dist/chunks/{chunk-XH3JG354.js.map → chunk-BZMMDJFZ.js.map} +0 -0
- /package/dist/chunks/{chunk-DTI6LBPL.js.map → chunk-CS7Q2ZUU.js.map} +0 -0
- /package/dist/chunks/{chunk-2JDHGE5X.js.map → chunk-D32E7XO6.js.map} +0 -0
- /package/dist/chunks/{chunk-I2WWQWOI.js.map → chunk-DCV3FVXI.js.map} +0 -0
- /package/dist/chunks/{chunk-YZAM5OII.js.map → chunk-DLHPY4VQ.js.map} +0 -0
- /package/dist/chunks/{chunk-ZJ56MAER.js.map → chunk-E3L237Z7.js.map} +0 -0
- /package/dist/chunks/{chunk-XO6WQQ67.js.map → chunk-ENJM7PYT.js.map} +0 -0
- /package/dist/chunks/{chunk-BT76TYMR.js.map → chunk-FLRYCMRH.js.map} +0 -0
- /package/dist/chunks/{chunk-AR7JOE6W.js.map → chunk-FY3ZMDWN.js.map} +0 -0
- /package/dist/chunks/{chunk-RYVWRI2O.js.map → chunk-G7PWYTB4.js.map} +0 -0
- /package/dist/chunks/{chunk-EIK35VTY.js.map → chunk-GIKCLC27.js.map} +0 -0
- /package/dist/chunks/{chunk-YWJ4WKSM.js.map → chunk-HLLAVDYT.js.map} +0 -0
- /package/dist/chunks/{chunk-NTN4HVCG.js.map → chunk-HM5UJONE.js.map} +0 -0
- /package/dist/chunks/{chunk-2UKMUTVB.js.map → chunk-HVFIYEP6.js.map} +0 -0
- /package/dist/chunks/{chunk-FUPKNX52.js.map → chunk-IWZXZZMU.js.map} +0 -0
- /package/dist/chunks/{chunk-QOGLGPLA.js.map → chunk-JG462CCT.js.map} +0 -0
- /package/dist/chunks/{chunk-EP6JEZ6Y.js.map → chunk-K3AE66MM.js.map} +0 -0
- /package/dist/chunks/{chunk-WWFYM2UR.js.map → chunk-KOGSKOU7.js.map} +0 -0
- /package/dist/chunks/{chunk-YXX7ARE5.js.map → chunk-KP4H7FJ7.js.map} +0 -0
- /package/dist/chunks/{chunk-4Q7Y6SKU.js.map → chunk-LAMQGSGH.js.map} +0 -0
- /package/dist/chunks/{chunk-H6UQL66Z.js.map → chunk-LJQAGSYZ.js.map} +0 -0
- /package/dist/chunks/{chunk-JLGLQMAN.js.map → chunk-LQ5L75T6.js.map} +0 -0
- /package/dist/chunks/{chunk-NMYUBZZU.js.map → chunk-LYMSGP53.js.map} +0 -0
- /package/dist/chunks/{chunk-ODQ6JG66.js.map → chunk-MDAEHXSL.js.map} +0 -0
- /package/dist/chunks/{chunk-J6YNCFQG.js.map → chunk-MM4BFFRT.js.map} +0 -0
- /package/dist/chunks/{chunk-Y6WCUDCQ.js.map → chunk-MYHK6KOU.js.map} +0 -0
- /package/dist/chunks/{chunk-AV7SMPXT.js.map → chunk-MYQ2MZKF.js.map} +0 -0
- /package/dist/chunks/{chunk-5LSXNZBY.js.map → chunk-NA6FHE5K.js.map} +0 -0
- /package/dist/chunks/{chunk-526VZQN4.js.map → chunk-NDGMUBFS.js.map} +0 -0
- /package/dist/chunks/{chunk-G44HNSPD.js.map → chunk-NEYRPPT5.js.map} +0 -0
- /package/dist/chunks/{chunk-DADJ4GQ2.js.map → chunk-NJ4PLSBZ.js.map} +0 -0
- /package/dist/chunks/{chunk-RZILFYMH.js.map → chunk-NRHUKGZ3.js.map} +0 -0
- /package/dist/chunks/{chunk-H4SIPZ3Q.js.map → chunk-O6NHCC4Q.js.map} +0 -0
- /package/dist/chunks/{chunk-K7MLADWM.js.map → chunk-OH5T7ODG.js.map} +0 -0
- /package/dist/chunks/{chunk-UZNITHS6.js.map → chunk-OLSRO4FC.js.map} +0 -0
- /package/dist/chunks/{chunk-XBQFS7OK.js.map → chunk-OMFV2AEQ.js.map} +0 -0
- /package/dist/chunks/{chunk-ZAJRK64O.js.map → chunk-P33ZADN3.js.map} +0 -0
- /package/dist/chunks/{chunk-GELAA6HR.js.map → chunk-P6DJ6AS5.js.map} +0 -0
- /package/dist/chunks/{chunk-G6FYM5SR.js.map → chunk-PGYSDVT7.js.map} +0 -0
- /package/dist/chunks/{chunk-IFUOFLH7.js.map → chunk-PJPPWJIB.js.map} +0 -0
- /package/dist/chunks/{chunk-Q3HGNRKL.js.map → chunk-QWCFMVAZ.js.map} +0 -0
- /package/dist/chunks/{chunk-XHLQEV4L.js.map → chunk-QYKPC5HO.js.map} +0 -0
- /package/dist/chunks/{chunk-AZIXXTEN.js.map → chunk-RBUVQQLL.js.map} +0 -0
- /package/dist/chunks/{chunk-PIV6IFK2.js.map → chunk-RO7HHDLW.js.map} +0 -0
- /package/dist/chunks/{chunk-YZPZQJTG.js.map → chunk-SC2FLZAI.js.map} +0 -0
- /package/dist/chunks/{chunk-ZIEVVDOR.js.map → chunk-T6BRCKD3.js.map} +0 -0
- /package/dist/chunks/{chunk-PZCNHP7O.js.map → chunk-TCAS4XVK.js.map} +0 -0
- /package/dist/chunks/{chunk-VXRC5XNZ.js.map → chunk-U77IVKFU.js.map} +0 -0
- /package/dist/chunks/{chunk-QIBMSMZA.js.map → chunk-UAD3AUKO.js.map} +0 -0
- /package/dist/chunks/{chunk-AUNCOQGN.js.map → chunk-UQFW622M.js.map} +0 -0
- /package/dist/chunks/{chunk-KNIPTSFW.js.map → chunk-UYC7YSMD.js.map} +0 -0
- /package/dist/chunks/{chunk-GXOQRU72.js.map → chunk-V2OLXCTE.js.map} +0 -0
- /package/dist/chunks/{chunk-TFXV3553.js.map → chunk-V73ZJCIQ.js.map} +0 -0
- /package/dist/chunks/{chunk-M56YCKGZ.js.map → chunk-V7U4OXBC.js.map} +0 -0
- /package/dist/chunks/{chunk-XNBNN3OW.js.map → chunk-VUNKDZ34.js.map} +0 -0
- /package/dist/chunks/{chunk-EMLOKSP6.js.map → chunk-WUCZIFEU.js.map} +0 -0
- /package/dist/chunks/{chunk-L4XN5ILM.js.map → chunk-WVQRVEZ7.js.map} +0 -0
- /package/dist/chunks/{chunk-KGGI2PH4.js.map → chunk-WVZG6GRE.js.map} +0 -0
- /package/dist/chunks/{chunk-M5NXCEVY.js.map → chunk-XTYVS4SM.js.map} +0 -0
- /package/dist/chunks/{chunk-UHFJTEZV.js.map → chunk-XZXE7L4B.js.map} +0 -0
- /package/dist/chunks/{chunk-WL3HPARH.js.map → chunk-YDE7ZNUH.js.map} +0 -0
- /package/dist/chunks/{chunk-3WYIYJID.js.map → chunk-YOBDE45E.js.map} +0 -0
- /package/dist/chunks/{chunk-SVEAODES.js.map → chunk-YZIUYGJT.js.map} +0 -0
- /package/dist/chunks/{chunk-BBOGGNTL.js.map → chunk-Z4TNPAB4.js.map} +0 -0
- /package/dist/chunks/{chunk-IRCIEEOM.js.map → chunk-ZNGRNTOY.js.map} +0 -0
- /package/dist/chunks/{cli-runtime-ULOMVN5Y.js.map → cli-runtime-IJWC2OTK.js.map} +0 -0
- /package/dist/chunks/{commands-MENGP42Y.js.map → commands-S7OW6RX6.js.map} +0 -0
- /package/dist/chunks/{crash-report-NNFSJ43Y.js.map → crash-report-F663DOML.js.map} +0 -0
- /package/dist/chunks/{dist-QXUTKQ55.js.map → dist-IOJ4RD22.js.map} +0 -0
- /package/dist/chunks/{dist-PNWD3XCT.js.map → dist-KXNNNQJP.js.map} +0 -0
- /package/dist/chunks/{dist-EQE2TVFV.js.map → dist-S7E46RVO.js.map} +0 -0
- /package/dist/chunks/{dist-INIQ54DO.js.map → dist-VNVQM6JU.js.map} +0 -0
- /package/dist/chunks/{dist-7JVVF6E3.js.map → dist-XY5CE56Y.js.map} +0 -0
- /package/dist/chunks/{dist-GWSFISZW.js.map → dist-ZHVTRMOZ.js.map} +0 -0
- /package/dist/chunks/{dist-6BYDAAGG.js.map → dist-ZXZ4LH3H.js.map} +0 -0
- /package/dist/chunks/{doctor-GIFSKHDE.js.map → doctor-GH3XGHIB.js.map} +0 -0
- /package/dist/chunks/{drain-WNGSFYGG.js.map → drain-YZXZQAUT.js.map} +0 -0
- /package/dist/chunks/{entry-3ZDHM5YQ.js.map → entry-LGDDSUPB.js.map} +0 -0
- /package/dist/chunks/{eval-4IIX7NIV.js.map → eval-EYN5BPLR.js.map} +0 -0
- /package/dist/chunks/{exec-NNLZUIZJ.js.map → exec-BMAOOSOF.js.map} +0 -0
- /package/dist/chunks/{home-S3SNMFFG.js.map → home-5OAGR5X5.js.map} +0 -0
- /package/dist/chunks/{hooks-3T5XVQSK.js.map → hooks-WV6P6LIP.js.map} +0 -0
- /package/dist/chunks/{hooks-report-3GDKOXB3.js.map → hooks-report-JUCEQJ73.js.map} +0 -0
- /package/dist/chunks/{host-BTE2HSHJ.js.map → host-EISOQGKE.js.map} +0 -0
- /package/dist/chunks/{host-queries-MWZKZJOA.js.map → host-queries-HJHMGU5N.js.map} +0 -0
- /package/dist/chunks/{learn-DA2U4OPO.js.map → learn-27BG44YG.js.map} +0 -0
- /package/dist/chunks/{learn-builtin-R5A4MYGZ.js.map → learn-builtin-K5HQZDEA.js.map} +0 -0
- /package/dist/chunks/{lifecycle-P3BZYTFI.js.map → lifecycle-L3BEM34W.js.map} +0 -0
- /package/dist/chunks/{list-SIJK3GE5.js.map → list-AB4VHNL2.js.map} +0 -0
- /package/dist/chunks/{live-KY5OOYNO.js.map → live-UWUEDSPR.js.map} +0 -0
- /package/dist/chunks/{load-SI2C6QKJ.js.map → load-NFDONLZ2.js.map} +0 -0
- /package/dist/chunks/{login-WOAZ5OLO.js.map → login-GON2CRE6.js.map} +0 -0
- /package/dist/chunks/{logs-ZXSLLFAK.js.map → logs-C7WBBIJR.js.map} +0 -0
- /package/dist/chunks/{mcp-TRDRYPNW.js.map → mcp-EBV34ZOW.js.map} +0 -0
- /package/dist/chunks/{open-KTUOVJCU.js.map → open-DLDZOPHP.js.map} +0 -0
- /package/dist/chunks/{operator-tools-HN6MNPZW.js.map → operator-tools-HT2GSJ56.js.map} +0 -0
- /package/dist/chunks/{output-schema-4LL23SA5.js.map → output-schema-UODVJVW4.js.map} +0 -0
- /package/dist/chunks/{pal-C7A3S6MR.js.map → pal-PN4RXHBT.js.map} +0 -0
- /package/dist/chunks/{peers-HINKWP3P.js.map → peers-HYMQ3RDX.js.map} +0 -0
- /package/dist/chunks/{peers-IYCZ3OWB.js.map → peers-MVQTZ4ND.js.map} +0 -0
- /package/dist/chunks/{plugin-YBGRF5FP.js.map → plugin-Y4XV5CKG.js.map} +0 -0
- /package/dist/chunks/{providers-AI27XYWT.js.map → providers-K23QPBYN.js.map} +0 -0
- /package/dist/chunks/{pty-7OTKGV53.js.map → pty-UIYKKO63.js.map} +0 -0
- /package/dist/chunks/{resume-2P6LYLYX.js.map → resume-ON75M2JL.js.map} +0 -0
- /package/dist/chunks/{resume-command-PG63DMVD.js.map → resume-command-O6FGFDSE.js.map} +0 -0
- /package/dist/chunks/{running-CNUUXGYY.js.map → running-DAUDQDDJ.js.map} +0 -0
- /package/dist/chunks/{schedule-37J3S7UQ.js.map → schedule-U7UZBKHQ.js.map} +0 -0
- /package/dist/chunks/{send-7JV6J5T5.js.map → send-3R5RDV2H.js.map} +0 -0
- /package/dist/chunks/{send-person-J5BSYFXQ.js.map → send-person-6NMIN4OT.js.map} +0 -0
- /package/dist/chunks/{service-NSMWSI2E.js.map → service-2PDUZZPQ.js.map} +0 -0
- /package/dist/chunks/{skills-AXZ5ETFS.js.map → skills-4UXJESZB.js.map} +0 -0
- /package/dist/chunks/{start-check-V2U4533P.js.map → start-check-L62L5YIZ.js.map} +0 -0
- /package/dist/chunks/{startup-failure-4HKS72EM.js.map → startup-failure-VS2U4JIC.js.map} +0 -0
- /package/dist/chunks/{state-NVCB2RFV.js.map → state-DMLD6RWU.js.map} +0 -0
- /package/dist/chunks/{store-2BFQ2UUT.js.map → store-3WIIBVKJ.js.map} +0 -0
- /package/dist/chunks/{store-FUNVZ2G4.js.map → store-DIVYPBNS.js.map} +0 -0
- /package/dist/chunks/{store-IACUKT6H.js.map → store-TYFJML3O.js.map} +0 -0
- /package/dist/chunks/{store-XBERR7IC.js.map → store-ZLCDFCYI.js.map} +0 -0
- /package/dist/chunks/{workspaces-WDQH4NP3.js.map → workspaces-ZHM5N3OY.js.map} +0 -0
- /package/dist/chunks/{worktree-SRCZK4CS.js.map → worktree-2MMIAPGE.js.map} +0 -0
|
@@ -325,7 +325,7 @@ var require_brace_expansion = __commonJS({
|
|
|
325
325
|
});
|
|
326
326
|
|
|
327
327
|
// ../sdk/dist/version.js
|
|
328
|
-
var VERSION = "
|
|
328
|
+
var VERSION = "65.0.0";
|
|
329
329
|
|
|
330
330
|
// ../sdk/dist/runtime/harness-session/index.js
|
|
331
331
|
import { posix, win32 } from "node:path";
|
|
@@ -31873,6 +31873,18 @@ function accumulateUnpricedCost(current, additionalUsage) {
|
|
|
31873
31873
|
};
|
|
31874
31874
|
}
|
|
31875
31875
|
__name(accumulateUnpricedCost, "accumulateUnpricedCost");
|
|
31876
|
+
function accumulateReportedCost(current, reportedCostUsd) {
|
|
31877
|
+
return {
|
|
31878
|
+
totalCost: current.totalCost + reportedCostUsd,
|
|
31879
|
+
cacheDiscount: current.cacheDiscount,
|
|
31880
|
+
unpricedTokens: current.unpricedTokens
|
|
31881
|
+
};
|
|
31882
|
+
}
|
|
31883
|
+
__name(accumulateReportedCost, "accumulateReportedCost");
|
|
31884
|
+
function hasReportedCost(usage) {
|
|
31885
|
+
return Number.isFinite(usage.reportedCostUsd) && usage.reportedCostUsd >= 0;
|
|
31886
|
+
}
|
|
31887
|
+
__name(hasReportedCost, "hasReportedCost");
|
|
31876
31888
|
function formatCost(usd) {
|
|
31877
31889
|
if (usd === 0)
|
|
31878
31890
|
return "$0.00";
|
|
@@ -32006,15 +32018,22 @@ var WINDOWS = [
|
|
|
32006
32018
|
// (a fine-tune, a distill), and nothing says it keeps the parent's window.
|
|
32007
32019
|
// Over-estimating ends a turn on a provider rejection; under-estimating
|
|
32008
32020
|
// costs a summary. So an id not named here falls to the bare `deepseek`
|
|
32009
|
-
// row below, the 64k the older ids (chat, reasoner, R1 distills) had.
|
|
32010
|
-
//
|
|
32021
|
+
// row below, the 64k the older ids (chat, reasoner, R1 distills) had. Listed
|
|
32022
|
+
// ids are matched whole (see `DEEPSEEK_ONE_MILLION_IDS`), never by
|
|
32011
32023
|
// substring.
|
|
32012
32024
|
["deepseek", 64e3]
|
|
32013
32025
|
];
|
|
32014
32026
|
var DEEPSEEK_ONE_MILLION_IDS = /* @__PURE__ */ new Set([
|
|
32015
32027
|
"deepseek-v4-flash",
|
|
32016
32028
|
"deepseek-v4-pro",
|
|
32017
|
-
"deepseek-flash"
|
|
32029
|
+
"deepseek-flash",
|
|
32030
|
+
// The revisions and dated snapshots a gateway's model list names for the
|
|
32031
|
+
// same generation. Each is listed whole: a new revision is a new row here
|
|
32032
|
+
// (or is reported by the provider), never a prefix match.
|
|
32033
|
+
"deepseek-v4.1-flash",
|
|
32034
|
+
"deepseek-v4.1-flash-1017",
|
|
32035
|
+
"deepseek-v4-flash-0731",
|
|
32036
|
+
"deepseek-v4-pro-0813"
|
|
32018
32037
|
]);
|
|
32019
32038
|
function bareModelName(id3) {
|
|
32020
32039
|
const afterSlash = id3.slice(id3.lastIndexOf("/") + 1);
|
|
@@ -34280,7 +34299,7 @@ function withStreamIdleTimeout(provider, options) {
|
|
|
34280
34299
|
supportsImageInputFor: /* @__PURE__ */ __name((model) => provider.supportsImageInputFor?.(model) ?? true, "supportsImageInputFor")
|
|
34281
34300
|
} : {},
|
|
34282
34301
|
...provider.acceptsForcedToolChoiceFor ? {
|
|
34283
|
-
acceptsForcedToolChoiceFor: /* @__PURE__ */ __name((model, thinking, effort) => provider.acceptsForcedToolChoiceFor?.(model, thinking, effort) ??
|
|
34302
|
+
acceptsForcedToolChoiceFor: /* @__PURE__ */ __name((model, thinking, effort) => provider.acceptsForcedToolChoiceFor?.(model, thinking, effort) ?? false, "acceptsForcedToolChoiceFor")
|
|
34284
34303
|
} : {},
|
|
34285
34304
|
...provider.reasoningEffortLevelsFor ? {
|
|
34286
34305
|
reasoningEffortLevelsFor: /* @__PURE__ */ __name((model, thinking) => provider.reasoningEffortLevelsFor?.(model, thinking), "reasoningEffortLevelsFor")
|
|
@@ -36477,7 +36496,8 @@ function accumulateTokenUsage(current, addition) {
|
|
|
36477
36496
|
// and a turn mixing a reporting driver with a silent one would read as
|
|
36478
36497
|
// though the silent turns did no thinking.
|
|
36479
36498
|
...current.reasoningTokens !== void 0 || addition.reasoningTokens !== void 0 ? { reasoningTokens: (current.reasoningTokens ?? 0) + (addition.reasoningTokens ?? 0) } : {},
|
|
36480
|
-
...current.webSearchRequests !== void 0 || addition.webSearchRequests !== void 0 ? { webSearchRequests: (current.webSearchRequests ?? 0) + (addition.webSearchRequests ?? 0) } : {}
|
|
36499
|
+
...current.webSearchRequests !== void 0 || addition.webSearchRequests !== void 0 ? { webSearchRequests: (current.webSearchRequests ?? 0) + (addition.webSearchRequests ?? 0) } : {},
|
|
36500
|
+
...current.reportedCostUsd !== void 0 || addition.reportedCostUsd !== void 0 ? { reportedCostUsd: (current.reportedCostUsd ?? 0) + (addition.reportedCostUsd ?? 0) } : {}
|
|
36481
36501
|
// `fullPromptTokens`, `cacheTtlMs`, `cacheWriteTtlTokens`, `speed`, `serviceTier`,
|
|
36482
36502
|
// `inferenceGeo` and `cacheMiss` are per-call facts and are deliberately
|
|
36483
36503
|
// not carried into a sum.
|
|
@@ -36509,6 +36529,8 @@ function mergeTokenUsage(current, next2) {
|
|
|
36509
36529
|
...next2.cacheWriteTtlTokens !== void 0 || current.cacheWriteTtlTokens !== void 0 ? { cacheWriteTtlTokens: next2.cacheWriteTtlTokens ?? current.cacheWriteTtlTokens } : {},
|
|
36510
36530
|
...next2.speed !== void 0 || current.speed !== void 0 ? { speed: next2.speed ?? current.speed } : {},
|
|
36511
36531
|
...next2.webSearchRequests !== void 0 || current.webSearchRequests !== void 0 ? { webSearchRequests: Math.max(current.webSearchRequests ?? 0, next2.webSearchRequests ?? 0) } : {},
|
|
36532
|
+
// Cumulative within one call, like the token counts.
|
|
36533
|
+
...next2.reportedCostUsd !== void 0 || current.reportedCostUsd !== void 0 ? { reportedCostUsd: Math.max(current.reportedCostUsd ?? 0, next2.reportedCostUsd ?? 0) } : {},
|
|
36512
36534
|
...next2.serviceTier !== void 0 || current.serviceTier !== void 0 ? { serviceTier: next2.serviceTier ?? current.serviceTier } : {},
|
|
36513
36535
|
...next2.inferenceGeo !== void 0 || current.inferenceGeo !== void 0 ? { inferenceGeo: next2.inferenceGeo ?? current.inferenceGeo } : {},
|
|
36514
36536
|
...next2.cacheMiss !== void 0 || current.cacheMiss !== void 0 ? { cacheMiss: next2.cacheMiss ?? current.cacheMiss } : {}
|
|
@@ -37335,7 +37357,8 @@ ${callCtx.workingStateSummary}`);
|
|
|
37335
37357
|
return [createUserMessage(contextParts.join("\n\n"))];
|
|
37336
37358
|
}
|
|
37337
37359
|
/**
|
|
37338
|
-
* Cost for one call
|
|
37360
|
+
* Cost for one call: the provider's reported charge, else the advisor's own
|
|
37361
|
+
* pricing, else the catalogue.
|
|
37339
37362
|
*
|
|
37340
37363
|
* When neither has a rate this reports the tokens as UNPRICED rather than
|
|
37341
37364
|
* as a cost of zero. The previous version returned a zero rate card and a
|
|
@@ -37347,6 +37370,9 @@ ${callCtx.workingStateSummary}`);
|
|
|
37347
37370
|
* because the number happens to be unenforced.
|
|
37348
37371
|
*/
|
|
37349
37372
|
computeCost(advisor, usage) {
|
|
37373
|
+
if (hasReportedCost(usage)) {
|
|
37374
|
+
return accumulateReportedCost(ZERO_COST, usage.reportedCostUsd);
|
|
37375
|
+
}
|
|
37350
37376
|
const pricing = advisor.pricing ?? resolveModelPricing(advisor.provider.id, advisor.model);
|
|
37351
37377
|
if (!pricing) {
|
|
37352
37378
|
return accumulateUnpricedCost(ZERO_COST, usage);
|
|
@@ -46395,7 +46421,12 @@ var TurnRecorder = class {
|
|
|
46395
46421
|
return resolveModelPricing(servedBy.providerId, servedBy.model);
|
|
46396
46422
|
}
|
|
46397
46423
|
accumulateUsage(usage, servedBy) {
|
|
46398
|
-
|
|
46424
|
+
const { reportedCostUsd: _charged, ...counted } = usage;
|
|
46425
|
+
this.#turn.tokenUsage = accumulateTokenUsage(this.#turn.tokenUsage, counted);
|
|
46426
|
+
if (hasReportedCost(usage)) {
|
|
46427
|
+
this.#turn.costInfo = accumulateReportedCost(this.#turn.costInfo, usage.reportedCostUsd);
|
|
46428
|
+
return;
|
|
46429
|
+
}
|
|
46399
46430
|
const pricing = this.#resolvePricing(servedBy);
|
|
46400
46431
|
this.#turn.costInfo = pricing === void 0 ? accumulateUnpricedCost(this.#turn.costInfo, usage) : accumulateCost(this.#turn.costInfo, usage, pricing);
|
|
46401
46432
|
}
|
|
@@ -52207,6 +52238,9 @@ var GuardCoordinator = class {
|
|
|
52207
52238
|
}
|
|
52208
52239
|
};
|
|
52209
52240
|
|
|
52241
|
+
// ../sdk/dist/runtime/query/iteration/index.js
|
|
52242
|
+
import { createHash as createHash22 } from "node:crypto";
|
|
52243
|
+
|
|
52210
52244
|
// ../sdk/dist/types/agent/task.js
|
|
52211
52245
|
function isTerminalAgentTaskState(state) {
|
|
52212
52246
|
return state === "completed" || state === "failed" || state === "canceled" || state === "rejected";
|
|
@@ -53674,6 +53708,67 @@ function createMemoryRecallStep(options) {
|
|
|
53674
53708
|
}
|
|
53675
53709
|
__name(createMemoryRecallStep, "createMemoryRecallStep");
|
|
53676
53710
|
|
|
53711
|
+
// ../sdk/dist/provider/side-request-reasoning.js
|
|
53712
|
+
var SIDE_REQUEST_REASONING_HEADROOM = 2048;
|
|
53713
|
+
var DISABLED = { type: "disabled" };
|
|
53714
|
+
var LOWEST_FIRST = ["none", "minimal", "low", "medium"];
|
|
53715
|
+
function sideRequestReasoning(provider, model, maxTokens) {
|
|
53716
|
+
let levels;
|
|
53717
|
+
try {
|
|
53718
|
+
levels = provider.reasoningEffortLevelsFor?.(model, DISABLED);
|
|
53719
|
+
} catch {
|
|
53720
|
+
levels = void 0;
|
|
53721
|
+
}
|
|
53722
|
+
if (levels?.includes("none")) {
|
|
53723
|
+
return { thinking: DISABLED, effort: "none", maxTokens };
|
|
53724
|
+
}
|
|
53725
|
+
const roomy = maxTokens + SIDE_REQUEST_REASONING_HEADROOM;
|
|
53726
|
+
if (levels !== void 0 && levels.length > 0) {
|
|
53727
|
+
const lowest = LOWEST_FIRST.find((level) => levels.includes(level)) ?? levels[0];
|
|
53728
|
+
return { thinking: DISABLED, ...lowest ? { effort: lowest } : {}, maxTokens: roomy };
|
|
53729
|
+
}
|
|
53730
|
+
return { thinking: DISABLED, maxTokens: roomy };
|
|
53731
|
+
}
|
|
53732
|
+
__name(sideRequestReasoning, "sideRequestReasoning");
|
|
53733
|
+
function refusesReasoningControls(error62) {
|
|
53734
|
+
const text11 = error62 instanceof Error ? error62.message : String(error62);
|
|
53735
|
+
if (/rate.?limit|too many requests|overloaded|timed? ?out|\b(429|5\d\d)\b/i.test(text11))
|
|
53736
|
+
return false;
|
|
53737
|
+
const names = /\b(thinking|reasoning|effort)\b/i.test(text11);
|
|
53738
|
+
const rejects = /unsupported|not supported|unsupport|invalid|unknown|unrecogni[sz]ed|unexpected|not allowed|not permitted|does not (?:accept|support|allow)|not accept|extra inputs|bad request|\b400\b|\b422\b/i.test(text11);
|
|
53739
|
+
return names && rejects;
|
|
53740
|
+
}
|
|
53741
|
+
__name(refusesReasoningControls, "refusesReasoningControls");
|
|
53742
|
+
var noControls = /* @__PURE__ */ new WeakMap();
|
|
53743
|
+
async function* chatStreamForSideRequest(provider, params, send = (request) => provider.chatStream(request)) {
|
|
53744
|
+
const base3 = params.maxTokens ?? 256;
|
|
53745
|
+
const skip = noControls.get(provider)?.has(params.model) === true;
|
|
53746
|
+
const fields2 = sideRequestReasoning(provider, params.model, base3);
|
|
53747
|
+
const plain = {
|
|
53748
|
+
...params,
|
|
53749
|
+
maxTokens: base3 + SIDE_REQUEST_REASONING_HEADROOM
|
|
53750
|
+
};
|
|
53751
|
+
if (skip) {
|
|
53752
|
+
yield* send(plain);
|
|
53753
|
+
return;
|
|
53754
|
+
}
|
|
53755
|
+
let yielded = false;
|
|
53756
|
+
try {
|
|
53757
|
+
for await (const chunk of send({ ...params, ...fields2 })) {
|
|
53758
|
+
yielded = true;
|
|
53759
|
+
yield chunk;
|
|
53760
|
+
}
|
|
53761
|
+
} catch (error62) {
|
|
53762
|
+
if (yielded || params.signal?.aborted || !refusesReasoningControls(error62))
|
|
53763
|
+
throw error62;
|
|
53764
|
+
const seen = noControls.get(provider) ?? /* @__PURE__ */ new Set();
|
|
53765
|
+
seen.add(params.model);
|
|
53766
|
+
noControls.set(provider, seen);
|
|
53767
|
+
yield* send(plain);
|
|
53768
|
+
}
|
|
53769
|
+
}
|
|
53770
|
+
__name(chatStreamForSideRequest, "chatStreamForSideRequest");
|
|
53771
|
+
|
|
53677
53772
|
// ../sdk/dist/runtime/query/callback-inference.js
|
|
53678
53773
|
var requestSchema = external_exports.object({
|
|
53679
53774
|
system: external_exports.string().min(1).max(12e3),
|
|
@@ -53716,15 +53811,17 @@ function createCallbackInference(ctx, model, phase) {
|
|
|
53716
53811
|
const text11 = new StreamTextAccumulator();
|
|
53717
53812
|
let invalidOutput;
|
|
53718
53813
|
let usage;
|
|
53814
|
+
let finishReason;
|
|
53719
53815
|
try {
|
|
53720
|
-
for await (const chunk of ctx.provider
|
|
53816
|
+
for await (const chunk of chatStreamForSideRequest(ctx.provider, {
|
|
53721
53817
|
model,
|
|
53722
53818
|
providerRoute: route(),
|
|
53723
53819
|
messages: [createSystemMessage(input2.system), createUserMessage(input2.prompt)],
|
|
53724
53820
|
maxTokens: input2.maxTokens,
|
|
53725
|
-
...ctx.turnConfig.effort ? { effort: ctx.turnConfig.effort } : {},
|
|
53726
53821
|
signal
|
|
53727
53822
|
})) {
|
|
53823
|
+
if (chunk.finishReason)
|
|
53824
|
+
finishReason = chunk.finishReason;
|
|
53728
53825
|
if (chunk.usage)
|
|
53729
53826
|
usage = usage ? mergeTokenUsage(usage, chunk.usage) : { ...chunk.usage };
|
|
53730
53827
|
if (chunk.error)
|
|
@@ -53743,7 +53840,12 @@ function createCallbackInference(ctx, model, phase) {
|
|
|
53743
53840
|
throw new Error(`${label5} inference ended without usage.`);
|
|
53744
53841
|
if (invalidOutput)
|
|
53745
53842
|
throw new Error(invalidOutput);
|
|
53746
|
-
return {
|
|
53843
|
+
return {
|
|
53844
|
+
text: text11.text,
|
|
53845
|
+
usage,
|
|
53846
|
+
servedBy: route(),
|
|
53847
|
+
...finishReason ? { finishReason } : {}
|
|
53848
|
+
};
|
|
53747
53849
|
} finally {
|
|
53748
53850
|
if (usage)
|
|
53749
53851
|
ctx.recorder.accumulateUsage(usage, route());
|
|
@@ -55944,9 +56046,11 @@ function parseSnapshot(value) {
|
|
|
55944
56046
|
__name(parseSnapshot, "parseSnapshot");
|
|
55945
56047
|
|
|
55946
56048
|
// ../sdk/dist/runtime/query/turn/stall-monitor.js
|
|
55947
|
-
var REASONING_CAPPED_MESSAGE = "Your thinking for that step reached its limit before you acted, so it was cut short. Act now on what you already know: make the first change, or
|
|
56049
|
+
var REASONING_CAPPED_MESSAGE = "Your thinking for that step reached its limit before you acted, so it was cut short. Act now on what you already know: make the first change, or, if you were asked a question, answer with what you have and say what is missing. Refine as you go; do not plan the whole task again.";
|
|
55948
56050
|
var REASONING_ONLY_MESSAGE = "Your last reply held thinking only: no answer and no action. Continue now: give your answer, or make the call that moves the task forward.";
|
|
55949
|
-
var STALL_NUDGE_MESSAGE = "Several steps have passed and nothing has changed yet. Begin changing things now: make the first edit you are sure of
|
|
56051
|
+
var STALL_NUDGE_MESSAGE = "Several steps have passed and nothing has changed yet. Begin changing things now: make the first edit you are sure of. If you were asked a question, answer it now with what you have and say what is missing. Reading more or planning again will not move the task.";
|
|
56052
|
+
var STALL_REPORT_MESSAGE = "The last steps have not turned up anything new. Report now what you have found and what is still unknown, using what you have already seen. Do not repeat a look you have already made.";
|
|
56053
|
+
var ANSWER_NOW_MESSAGE = "You were asked a question and the last steps only looked around. Answer it now, in the language the person used and within what they asked for, using what you have already seen. If something is still missing, say what it is instead of running another command. Do not open with an apology.";
|
|
55950
56054
|
var FORCED_STEP_MESSAGE = "This reply must be a tool call, not more planning. Make the call that moves the task forward now.";
|
|
55951
56055
|
var DEFAULT_MAX_REASONING_TOKENS = 24e3;
|
|
55952
56056
|
var CHARS_PER_TOKEN2 = 4;
|
|
@@ -55978,6 +56082,30 @@ function callChangedState(toolName, readOnly, isError) {
|
|
|
55978
56082
|
return readOnly !== true;
|
|
55979
56083
|
}
|
|
55980
56084
|
__name(callChangedState, "callChangedState");
|
|
56085
|
+
function callMadeProgress(toolName, readOnly, isError, cannotChange) {
|
|
56086
|
+
if (cannotChange && isSetAsideTool(toolName))
|
|
56087
|
+
return false;
|
|
56088
|
+
if (callChangedState(toolName, readOnly, isError))
|
|
56089
|
+
return true;
|
|
56090
|
+
if (!cannotChange || isError)
|
|
56091
|
+
return false;
|
|
56092
|
+
return readOnly === true;
|
|
56093
|
+
}
|
|
56094
|
+
__name(callMadeProgress, "callMadeProgress");
|
|
56095
|
+
function isSetAsideTool(toolName) {
|
|
56096
|
+
return TASK_LIST_TOOLS.has(toolName) || toolName === "send_message";
|
|
56097
|
+
}
|
|
56098
|
+
__name(isSetAsideTool, "isSetAsideTool");
|
|
56099
|
+
var QUESTION_MAX_CHARS = 400;
|
|
56100
|
+
function asksQuestion(text11) {
|
|
56101
|
+
if (text11 === void 0)
|
|
56102
|
+
return false;
|
|
56103
|
+
const trimmed = text11.trim();
|
|
56104
|
+
if (trimmed.length === 0 || trimmed.length > QUESTION_MAX_CHARS)
|
|
56105
|
+
return false;
|
|
56106
|
+
return /[?\uFF1F\u061F](?=$|[\s"'\u201D\u2019)\]])/.test(trimmed);
|
|
56107
|
+
}
|
|
56108
|
+
__name(asksQuestion, "asksQuestion");
|
|
55981
56109
|
var StallMonitor = class {
|
|
55982
56110
|
static {
|
|
55983
56111
|
__name(this, "StallMonitor");
|
|
@@ -55985,6 +56113,7 @@ var StallMonitor = class {
|
|
|
55985
56113
|
nudgeAfterSteps;
|
|
55986
56114
|
nudgeAfterChars;
|
|
55987
56115
|
forceAfterSteps;
|
|
56116
|
+
answerAfterSteps;
|
|
55988
56117
|
idleSteps = 0;
|
|
55989
56118
|
idleChars = 0;
|
|
55990
56119
|
nudged = false;
|
|
@@ -55993,6 +56122,7 @@ var StallMonitor = class {
|
|
|
55993
56122
|
this.nudgeAfterSteps = config2?.nudgeAfterSteps ?? 12;
|
|
55994
56123
|
this.nudgeAfterChars = config2?.nudgeAfterReasoningChars ?? 8e4;
|
|
55995
56124
|
this.forceAfterSteps = config2?.forceAfterSteps ?? 5;
|
|
56125
|
+
this.answerAfterSteps = config2?.answerAfterSteps ?? 6;
|
|
55996
56126
|
}
|
|
55997
56127
|
observe(step) {
|
|
55998
56128
|
if (step.changedState) {
|
|
@@ -56001,18 +56131,26 @@ var StallMonitor = class {
|
|
|
56001
56131
|
}
|
|
56002
56132
|
this.idleSteps += 1;
|
|
56003
56133
|
this.idleChars += step.reasoningChars;
|
|
56134
|
+
const question = step.question === true;
|
|
56135
|
+
const cannotChange = step.cannotChange === true;
|
|
56136
|
+
const stallText = question ? ANSWER_NOW_MESSAGE : cannotChange ? STALL_REPORT_MESSAGE : STALL_NUDGE_MESSAGE;
|
|
56004
56137
|
if (!this.nudged) {
|
|
56138
|
+
if (question && this.idleSteps >= this.answerAfterSteps) {
|
|
56139
|
+
this.nudged = true;
|
|
56140
|
+
this.stepsSinceNudge = 0;
|
|
56141
|
+
return { kind: "nudge", text: ANSWER_NOW_MESSAGE };
|
|
56142
|
+
}
|
|
56005
56143
|
if (this.idleSteps >= this.nudgeAfterSteps || this.idleChars >= this.nudgeAfterChars) {
|
|
56006
56144
|
this.nudged = true;
|
|
56007
56145
|
this.stepsSinceNudge = 0;
|
|
56008
|
-
return { kind: "nudge", text:
|
|
56146
|
+
return { kind: "nudge", text: stallText };
|
|
56009
56147
|
}
|
|
56010
56148
|
return { kind: "none" };
|
|
56011
56149
|
}
|
|
56012
56150
|
this.stepsSinceNudge += 1;
|
|
56013
56151
|
if (this.stepsSinceNudge >= this.forceAfterSteps) {
|
|
56014
56152
|
this.reset();
|
|
56015
|
-
return { kind: "force" };
|
|
56153
|
+
return question || cannotChange ? { kind: "nudge", text: stallText } : { kind: "force" };
|
|
56016
56154
|
}
|
|
56017
56155
|
return { kind: "none" };
|
|
56018
56156
|
}
|
|
@@ -61695,7 +61833,7 @@ var RepeatCallTracker = class {
|
|
|
61695
61833
|
toolName,
|
|
61696
61834
|
count: count7,
|
|
61697
61835
|
level: "escalated",
|
|
61698
|
-
text: `You have now called \`${toolName}\` with identical arguments ${count7} times in this turn. Check whether the results or the state have changed. If there is no progress, change the approach or tell the user what is
|
|
61836
|
+
text: `You have now called \`${toolName}\` with identical arguments ${count7} times in this turn. Check whether the results or the state have changed. If there is no progress, change the approach, or answer with what you have and tell the user what is missing.`
|
|
61699
61837
|
};
|
|
61700
61838
|
}
|
|
61701
61839
|
if (count7 >= this.thresholds.notifyAfter && already === void 0) {
|
|
@@ -61704,7 +61842,7 @@ var RepeatCallTracker = class {
|
|
|
61704
61842
|
toolName,
|
|
61705
61843
|
count: count7,
|
|
61706
61844
|
level: "notice",
|
|
61707
|
-
text: `Note: this is call ${count7} of \`${toolName}\` with identical arguments in this turn. If the previous results were not what you needed,
|
|
61845
|
+
text: `Note: this is call ${count7} of \`${toolName}\` with identical arguments in this turn. If the previous results were not what you needed, change the arguments, or answer with what you already have and say what is missing.`
|
|
61708
61846
|
};
|
|
61709
61847
|
}
|
|
61710
61848
|
return void 0;
|
|
@@ -65336,7 +65474,7 @@ function createAutoReviewClassifier(options) {
|
|
|
65336
65474
|
controller.abort(new DeadlineError());
|
|
65337
65475
|
}, deadlineMs);
|
|
65338
65476
|
try {
|
|
65339
|
-
const
|
|
65477
|
+
const request = {
|
|
65340
65478
|
model: options.model,
|
|
65341
65479
|
messages,
|
|
65342
65480
|
maxTokens: stage === 1 ? 64 : 8192,
|
|
@@ -65344,7 +65482,8 @@ function createAutoReviewClassifier(options) {
|
|
|
65344
65482
|
...stage === 1 ? { stop: [VERDICT_STOP] } : {},
|
|
65345
65483
|
cacheControl: { type: "auto" },
|
|
65346
65484
|
signal: controller.signal
|
|
65347
|
-
}
|
|
65485
|
+
};
|
|
65486
|
+
const collected = collectChatCompletion(stage === 1 ? chatStreamForSideRequest(options.provider, request, (sent) => chatStreamWithSamplingRepair(options.provider, sent)) : chatStreamWithSamplingRepair(options.provider, request));
|
|
65348
65487
|
collected.catch(() => {
|
|
65349
65488
|
});
|
|
65350
65489
|
const cutOff = new Promise((_resolve, reject2) => {
|
|
@@ -78735,6 +78874,7 @@ var IterationOrchestrator = class {
|
|
|
78735
78874
|
...deferredMcpContext ? [deferredMcpContext] : []
|
|
78736
78875
|
].join("\n\n");
|
|
78737
78876
|
const llmTools = this.ctx.tools.toLLMTools(stepAllowedTools).filter((tool) => this.ctx.structuredOutput?.mode !== "native" || tool.function.name !== STRUCTURED_OUTPUT_TOOL_NAME);
|
|
78877
|
+
this.stepCannotChange = this.toolsCannotChange(llmTools);
|
|
78738
78878
|
this.ctx.toolExecutor.setStepAllowedTools(stepAllowedTools);
|
|
78739
78879
|
const enforceToolInputSchema = enforcedModelInputToolNames(this.ctx.tools, llmTools);
|
|
78740
78880
|
stepModel = this.refusalPinnedModel ?? step.model ?? model;
|
|
@@ -78864,7 +79004,10 @@ var IterationOrchestrator = class {
|
|
|
78864
79004
|
}
|
|
78865
79005
|
const offeredEfforts = this.ctx.provider.reasoningEffortLevelsFor?.(stepModel);
|
|
78866
79006
|
const stepEffort = forcedAction && requestEffort && (offeredEfforts?.includes("low") ?? false) ? "low" : requestEffort;
|
|
78867
|
-
const
|
|
79007
|
+
const stepChoiceForced = step.toolChoice !== void 0 && step.toolChoice !== "auto" && step.toolChoice !== "none";
|
|
79008
|
+
const thinkingOn = turnConfig.thinking !== void 0 && turnConfig.thinking.type !== "disabled";
|
|
79009
|
+
const forcedChoiceAnswer = forcedAction || stepChoiceForced ? this.ctx.provider.acceptsForcedToolChoiceFor?.(stepModel, turnConfig.thinking, stepEffort) : void 0;
|
|
79010
|
+
const forcedChoiceRefused = forcedAction && (forcedChoiceAnswer !== true || thinkingOn) || !forcedAction && stepChoiceForced && forcedChoiceAnswer === false;
|
|
78868
79011
|
const operatorInputAtDispatch = this.latestUserMessage;
|
|
78869
79012
|
const latestReviewUserMessage = (this.ctx.reviewAnswer || this.ctx.structuredOutput?.review) && operatorInputAtDispatch ? structuredClone(operatorInputAtDispatch) : void 0;
|
|
78870
79013
|
const { response, messageId: messageId4, requestMessages, reasoningCapped = false } = yield* streamProviderTurn(
|
|
@@ -78890,7 +79033,7 @@ var IterationOrchestrator = class {
|
|
|
78890
79033
|
// asking for them. Otherwise the step's choice applies —
|
|
78891
79034
|
// and only to this step, because the next one is prepared
|
|
78892
79035
|
// from scratch.
|
|
78893
|
-
toolChoice: forceFinalize && llmTools.length > 0 ? "none" : llmTools.length > 0 ? forcedAction && !forcedChoiceRefused ? step.toolChoice ?? "required" : step.toolChoice : void 0,
|
|
79036
|
+
toolChoice: forceFinalize && llmTools.length > 0 ? "none" : llmTools.length > 0 ? forcedAction && !forcedChoiceRefused ? step.toolChoice ?? "required" : stepChoiceForced && forcedChoiceRefused ? void 0 : step.toolChoice : void 0,
|
|
78894
79037
|
temperature: step.temperature ?? turnConfig.temperature,
|
|
78895
79038
|
maxTokens: outputCapOverride ?? step.maxResponseTokens ?? turnConfig.maxResponseTokens,
|
|
78896
79039
|
cacheControl: { type: "auto" },
|
|
@@ -80463,6 +80606,8 @@ ${feedback}`, "hook-feedback"));
|
|
|
80463
80606
|
return;
|
|
80464
80607
|
const calls = new Map((response.message.toolCalls ?? []).map((c) => [c.id, c]));
|
|
80465
80608
|
let changedState = false;
|
|
80609
|
+
const question = asksQuestion(this.latestUserMessage?.content);
|
|
80610
|
+
const cannotChange = this.stepCannotChange;
|
|
80466
80611
|
for (const result of results) {
|
|
80467
80612
|
const call2 = calls.get(result.toolCallId);
|
|
80468
80613
|
let readOnly;
|
|
@@ -80472,11 +80617,19 @@ ${feedback}`, "hook-feedback"));
|
|
|
80472
80617
|
} catch {
|
|
80473
80618
|
readOnly = void 0;
|
|
80474
80619
|
}
|
|
80475
|
-
if (
|
|
80476
|
-
|
|
80620
|
+
if (callMadeProgress(result.toolName, readOnly, result.isError, cannotChange)) {
|
|
80621
|
+
if (EDIT_TOOLS.has(result.toolName) || !this.seenAgain(result.toolName, call2, result.output)) {
|
|
80622
|
+
changedState = true;
|
|
80623
|
+
}
|
|
80624
|
+
}
|
|
80477
80625
|
}
|
|
80478
80626
|
const reasoningChars = (response.message.reasoning ?? []).reduce((n, block) => n + (block.text?.length ?? 0), 0);
|
|
80479
|
-
const directive = monitor.observe({
|
|
80627
|
+
const directive = monitor.observe({
|
|
80628
|
+
reasoningChars,
|
|
80629
|
+
changedState,
|
|
80630
|
+
question,
|
|
80631
|
+
cannotChange
|
|
80632
|
+
});
|
|
80480
80633
|
if (directive.kind === "nudge") {
|
|
80481
80634
|
this.ctx.log.info("Many steps without a change \u2014 nudging the model to act", {
|
|
80482
80635
|
[NAMZU.TURN_ID]: this.ctx.recorder.turnId
|
|
@@ -80489,6 +80642,43 @@ ${feedback}`, "hook-feedback"));
|
|
|
80489
80642
|
this.forceActionNextStep = true;
|
|
80490
80643
|
}
|
|
80491
80644
|
}
|
|
80645
|
+
/** Whether every tool offered to the step in flight only reads. */
|
|
80646
|
+
stepCannotChange = false;
|
|
80647
|
+
/**
|
|
80648
|
+
* Whether an agent given these tools can change nothing: each one declares
|
|
80649
|
+
* itself read-only without being shown an input (the test the read-only
|
|
80650
|
+
* sub-agents' roster uses), task-list tools and `send_message` aside. A tool that does not say,
|
|
80651
|
+
* or that says so only for some inputs, counts as one that can change things.
|
|
80652
|
+
*/
|
|
80653
|
+
toolsCannotChange(llmTools) {
|
|
80654
|
+
let looked = false;
|
|
80655
|
+
for (const { function: fn } of llmTools) {
|
|
80656
|
+
if (isSetAsideTool(fn.name))
|
|
80657
|
+
continue;
|
|
80658
|
+
try {
|
|
80659
|
+
if (this.ctx.tools.get(fn.name)?.isReadOnly?.(void 0) !== true)
|
|
80660
|
+
return false;
|
|
80661
|
+
} catch {
|
|
80662
|
+
return false;
|
|
80663
|
+
}
|
|
80664
|
+
looked = true;
|
|
80665
|
+
}
|
|
80666
|
+
return looked;
|
|
80667
|
+
}
|
|
80668
|
+
/** Fingerprints of the calls this turn has finished, for {@link seenAgain}. */
|
|
80669
|
+
finishedCalls = /* @__PURE__ */ new Set();
|
|
80670
|
+
/**
|
|
80671
|
+
* Whether this call, with this input and this output, was already finished
|
|
80672
|
+
* earlier in the turn; records it either way. A call that gave the same
|
|
80673
|
+
* answer twice did not move anything the second time.
|
|
80674
|
+
*/
|
|
80675
|
+
seenAgain(toolName, call2, output2) {
|
|
80676
|
+
const key6 = createHash22("sha256").update(`${toolName}\0${call2?.function.arguments ?? ""}\0${output2}`).digest("hex");
|
|
80677
|
+
if (this.finishedCalls.has(key6))
|
|
80678
|
+
return true;
|
|
80679
|
+
this.finishedCalls.add(key6);
|
|
80680
|
+
return false;
|
|
80681
|
+
}
|
|
80492
80682
|
async requestFinalResponse(model, reason) {
|
|
80493
80683
|
if (this.ctx.structuredOutput?.mode === "native")
|
|
80494
80684
|
return "structured_output_failed";
|
|
@@ -80814,7 +81004,7 @@ function withProviderRetry(provider, options = {}) {
|
|
|
80814
81004
|
supportsImageInputFor: /* @__PURE__ */ __name((model) => provider.supportsImageInputFor?.(model) ?? true, "supportsImageInputFor")
|
|
80815
81005
|
} : {},
|
|
80816
81006
|
...provider.acceptsForcedToolChoiceFor ? {
|
|
80817
|
-
acceptsForcedToolChoiceFor: /* @__PURE__ */ __name((model, thinking, effort) => provider.acceptsForcedToolChoiceFor?.(model, thinking, effort) ??
|
|
81007
|
+
acceptsForcedToolChoiceFor: /* @__PURE__ */ __name((model, thinking, effort) => provider.acceptsForcedToolChoiceFor?.(model, thinking, effort) ?? false, "acceptsForcedToolChoiceFor")
|
|
80818
81008
|
} : {},
|
|
80819
81009
|
...provider.reasoningEffortLevelsFor ? {
|
|
80820
81010
|
reasoningEffortLevelsFor: /* @__PURE__ */ __name((model, thinking) => provider.reasoningEffortLevelsFor?.(model, thinking), "reasoningEffortLevelsFor")
|
|
@@ -81043,9 +81233,10 @@ function withProviderFallback(members2, options = {}) {
|
|
|
81043
81233
|
const serving = members2[cursor] ?? first;
|
|
81044
81234
|
return serving.provider.supportsImageInputFor?.(serving.model ?? model) ?? true;
|
|
81045
81235
|
}, "supportsImageInputFor"),
|
|
81046
|
-
// A chain takes a forced choice only if every member does: the
|
|
81047
|
-
// be served by any of them, and
|
|
81048
|
-
|
|
81236
|
+
// A chain takes a forced choice only if every member says it does: the
|
|
81237
|
+
// request may be served by any of them, and one that refuses (or cannot
|
|
81238
|
+
// say) must not be sent a choice it may turn down.
|
|
81239
|
+
acceptsForcedToolChoiceFor: /* @__PURE__ */ __name((model, thinking, effort) => members2.every((member) => member.provider.acceptsForcedToolChoiceFor?.(member.model ?? model, thinking, effort) ?? false), "acceptsForcedToolChoiceFor"),
|
|
81049
81240
|
reasoningEffortLevelsFor: /* @__PURE__ */ __name((model, thinking) => commonReasoningEffortLevels(members2, model, thinking), "reasoningEffortLevelsFor"),
|
|
81050
81241
|
// Present on the chain wrapper for the same reason the menu method is:
|
|
81051
81242
|
// `undefined` is the honest answer when a member cannot answer, defaults
|
|
@@ -81846,7 +82037,7 @@ import { lstat as lstat4 } from "node:fs/promises";
|
|
|
81846
82037
|
import { resolve as resolve13 } from "node:path";
|
|
81847
82038
|
|
|
81848
82039
|
// ../sdk/dist/store/evidence/index-page.js
|
|
81849
|
-
import { createHash as
|
|
82040
|
+
import { createHash as createHash23, createHmac as createHmac2, timingSafeEqual as timingSafeEqual2 } from "node:crypto";
|
|
81850
82041
|
|
|
81851
82042
|
// ../sdk/dist/store/evidence/compaction-provenance.js
|
|
81852
82043
|
function record2(value) {
|
|
@@ -81961,7 +82152,7 @@ var positionSchema = external_exports.object({
|
|
|
81961
82152
|
textIndex: integer3.default(0)
|
|
81962
82153
|
});
|
|
81963
82154
|
function evidenceSeal(sessionStart, sourceKey) {
|
|
81964
|
-
const key6 =
|
|
82155
|
+
const key6 = createHash23("sha256").update("namzu-session-evidence-v1\n").update(sessionStart).digest();
|
|
81965
82156
|
const mac3 = /* @__PURE__ */ __name((value) => createHmac2("sha256", key6).update(`${sourceKey}
|
|
81966
82157
|
${value}`).digest(), "mac");
|
|
81967
82158
|
return {
|
|
@@ -84146,7 +84337,7 @@ var InMemorySessionTokenBudgetStore = class {
|
|
|
84146
84337
|
};
|
|
84147
84338
|
|
|
84148
84339
|
// ../sdk/dist/store/checkpoint/contract.js
|
|
84149
|
-
import { createHash as
|
|
84340
|
+
import { createHash as createHash24 } from "node:crypto";
|
|
84150
84341
|
var CheckpointIntegrityError = class extends Error {
|
|
84151
84342
|
static {
|
|
84152
84343
|
__name(this, "CheckpointIntegrityError");
|
|
@@ -84181,7 +84372,7 @@ function serializeCheckpoint(checkpoint) {
|
|
|
84181
84372
|
}
|
|
84182
84373
|
__name(serializeCheckpoint, "serializeCheckpoint");
|
|
84183
84374
|
function sha256Hex5(text11) {
|
|
84184
|
-
return
|
|
84375
|
+
return createHash24("sha256").update(text11, "utf8").digest("hex");
|
|
84185
84376
|
}
|
|
84186
84377
|
__name(sha256Hex5, "sha256Hex");
|
|
84187
84378
|
function checkpointRecordPath(checkpointId4) {
|
|
@@ -84771,6 +84962,8 @@ function assertBudgetIsMeasurable(params) {
|
|
|
84771
84962
|
return;
|
|
84772
84963
|
if (params.pricing !== void 0)
|
|
84773
84964
|
return;
|
|
84965
|
+
if (params.provider.capabilities?.reportsRequestCost === true)
|
|
84966
|
+
return;
|
|
84774
84967
|
const model = params.turnConfig.model;
|
|
84775
84968
|
if (resolveModelPricing(params.provider.id, model) !== void 0)
|
|
84776
84969
|
return;
|
|
@@ -87328,7 +87521,7 @@ async function startBidiTurn(params) {
|
|
|
87328
87521
|
__name(startBidiTurn, "startBidiTurn");
|
|
87329
87522
|
|
|
87330
87523
|
// ../sdk/dist/runtime/query/prompt-cache.js
|
|
87331
|
-
import { createHash as
|
|
87524
|
+
import { createHash as createHash25 } from "node:crypto";
|
|
87332
87525
|
var PromptCache = class {
|
|
87333
87526
|
static {
|
|
87334
87527
|
__name(this, "PromptCache");
|
|
@@ -87403,7 +87596,7 @@ var PromptCache = class {
|
|
|
87403
87596
|
this.cachedStaticHash = void 0;
|
|
87404
87597
|
}
|
|
87405
87598
|
computeStaticHash(staticSegment) {
|
|
87406
|
-
return
|
|
87599
|
+
return createHash25("sha256").update(staticSegment).digest("hex").slice(0, 16);
|
|
87407
87600
|
}
|
|
87408
87601
|
computeConfigHash(input2, prompt) {
|
|
87409
87602
|
const parts = [
|
|
@@ -87413,7 +87606,7 @@ var PromptCache = class {
|
|
|
87413
87606
|
// unsegmented text happens to be identical.
|
|
87414
87607
|
input2.contributions?.list().map((c) => [c.id, c.placement]) ?? []
|
|
87415
87608
|
];
|
|
87416
|
-
return
|
|
87609
|
+
return createHash25("sha256").update(JSON.stringify(parts)).digest("hex").slice(0, 16);
|
|
87417
87610
|
}
|
|
87418
87611
|
};
|
|
87419
87612
|
|
|
@@ -91064,7 +91257,7 @@ var LocalExecutionContext = class extends BaseExecutionContext {
|
|
|
91064
91257
|
};
|
|
91065
91258
|
|
|
91066
91259
|
// ../sdk/dist/turn/workspace-fingerprint.js
|
|
91067
|
-
import { createHash as
|
|
91260
|
+
import { createHash as createHash26 } from "node:crypto";
|
|
91068
91261
|
import { lstat as lstat5, readFile as readFile13, readlink } from "node:fs/promises";
|
|
91069
91262
|
import { join as join27 } from "node:path";
|
|
91070
91263
|
var NODE_FS = { lstat: lstat5, readlink, readFile: readFile13 };
|
|
@@ -91080,7 +91273,7 @@ async function untrackedEntry(cwd, rel, fs) {
|
|
|
91080
91273
|
if (!stats.isFile())
|
|
91081
91274
|
return `? ${rel}`;
|
|
91082
91275
|
const body = await fs.readFile(abs);
|
|
91083
|
-
return `F ${rel}\0${
|
|
91276
|
+
return `F ${rel}\0${createHash26("sha256").update(body).digest("hex")}`;
|
|
91084
91277
|
} catch {
|
|
91085
91278
|
return null;
|
|
91086
91279
|
}
|
|
@@ -91125,7 +91318,7 @@ async function fingerprintWorkspace(options) {
|
|
|
91125
91318
|
return null;
|
|
91126
91319
|
parts.push(entry);
|
|
91127
91320
|
}
|
|
91128
|
-
const hash4 =
|
|
91321
|
+
const hash4 = createHash26("sha256");
|
|
91129
91322
|
for (const part2 of parts)
|
|
91130
91323
|
hash4.update(`${Buffer.byteLength(part2, "utf8")}:${part2}`);
|
|
91131
91324
|
return hash4.digest("hex");
|
|
@@ -91355,7 +91548,7 @@ function createMemoryPromoter(options) {
|
|
|
91355
91548
|
__name(createMemoryPromoter, "createMemoryPromoter");
|
|
91356
91549
|
|
|
91357
91550
|
// ../sdk/dist/turn/json-claim-verifier.js
|
|
91358
|
-
import { createHash as
|
|
91551
|
+
import { createHash as createHash27, randomUUID as randomUUID5 } from "node:crypto";
|
|
91359
91552
|
import { performance as performance2 } from "node:perf_hooks";
|
|
91360
91553
|
function scalar(value) {
|
|
91361
91554
|
return value === null || typeof value === "boolean" || typeof value === "string" && value.length <= 2e3 || typeof value === "number" && Number.isSafeInteger(value);
|
|
@@ -91488,7 +91681,7 @@ function createJsonClaimVerifier(options) {
|
|
|
91488
91681
|
requestId: request.requestId,
|
|
91489
91682
|
observedAt: observation.observedAt,
|
|
91490
91683
|
bytes: bytes.byteLength,
|
|
91491
|
-
sha256:
|
|
91684
|
+
sha256: createHash27("sha256").update(bytes).digest("hex")
|
|
91492
91685
|
});
|
|
91493
91686
|
}
|
|
91494
91687
|
ensureActive();
|
|
@@ -91756,7 +91949,12 @@ function createEvidenceQueryResolver() {
|
|
|
91756
91949
|
prompt: input2.prompt,
|
|
91757
91950
|
maxTokens: 512,
|
|
91758
91951
|
signal: context2.signal
|
|
91759
|
-
}).then(({ text: text11 }) =>
|
|
91952
|
+
}).then(({ text: text11, finishReason }) => (
|
|
91953
|
+
// A planner that came back empty, or ran out of tokens before it
|
|
91954
|
+
// finished, said nothing about the question. That is not a failed
|
|
91955
|
+
// plan to report to the model: the lookup adds nothing this turn.
|
|
91956
|
+
!text11.trim() || finishReason === "length" ? null : validateEvidenceQueryResolution(text11, current, history)
|
|
91957
|
+
));
|
|
91760
91958
|
cached4 = { turnId: context2.turnId, query: query2, operator: identity, plan };
|
|
91761
91959
|
return plan;
|
|
91762
91960
|
};
|
|
@@ -97930,7 +98128,7 @@ var EXPLORE_AGENT_PROMPT = [
|
|
|
97930
98128
|
"You are a read-only sub-agent dispatched to find things out: where something is defined, which files reference it, how a piece of code works, what a directory contains.",
|
|
97931
98129
|
"You cannot see the parent conversation \u2014 work only from the prompt you were given.",
|
|
97932
98130
|
"You have reading and searching tools only. You cannot edit, write or run commands, and you must not describe a change as made.",
|
|
97933
|
-
"Search broadly first, then read what matters. Report file paths with line numbers, quote the relevant lines, and say plainly what you did not find and what you did not read.",
|
|
98131
|
+
"Search broadly first, then read what matters. Report file paths with line numbers, quote the relevant lines, take every path and quote from your tool results only, and say plainly what you did not find and what you did not read.",
|
|
97934
98132
|
"You are best at locating answers; prefer locating over auditing whole files, and say so when a task asks for more than you can cover.",
|
|
97935
98133
|
"End with a concise answer the parent can act on; do not ask the parent questions."
|
|
97936
98134
|
].join("\n");
|
|
@@ -97944,7 +98142,7 @@ var PLAN_AGENT_PROMPT = [
|
|
|
97944
98142
|
"You have reading and searching tools only. You cannot edit, write or run commands, and you must not describe a change as made.",
|
|
97945
98143
|
"Read first: find the code the change touches, the patterns it should follow and the tests that cover it. Prefer what the code already does over a design of your own.",
|
|
97946
98144
|
"Return the plan in this shape: a one-paragraph approach; numbered steps in the order to do them, each naming the files it changes; the files to read or change first, as paths with line numbers where it helps; the risks and open questions, including what could break and how to check it.",
|
|
97947
|
-
"
|
|
98145
|
+
"Take every path and quote from your tool results only, and say plainly what you could not determine. End with the plan; do not ask the parent questions."
|
|
97948
98146
|
].join("\n");
|
|
97949
98147
|
|
|
97950
98148
|
// ../sdk/dist/store/InMemoryStore.js
|
|
@@ -98586,7 +98784,7 @@ var DiskTaskStore = class {
|
|
|
98586
98784
|
};
|
|
98587
98785
|
|
|
98588
98786
|
// ../sdk/dist/store/memory/revision.js
|
|
98589
|
-
import { createHash as
|
|
98787
|
+
import { createHash as createHash28 } from "node:crypto";
|
|
98590
98788
|
var MemoryRevisionUnavailableError = class extends Error {
|
|
98591
98789
|
static {
|
|
98592
98790
|
__name(this, "MemoryRevisionUnavailableError");
|
|
@@ -98692,7 +98890,7 @@ function canonicalRecord(record4) {
|
|
|
98692
98890
|
}
|
|
98693
98891
|
__name(canonicalRecord, "canonicalRecord");
|
|
98694
98892
|
function memoryRevision(record4) {
|
|
98695
|
-
return `m2:${
|
|
98893
|
+
return `m2:${createHash28("sha256").update(canonicalRecord(record4)).digest("hex")}`;
|
|
98696
98894
|
}
|
|
98697
98895
|
__name(memoryRevision, "memoryRevision");
|
|
98698
98896
|
var MemoryRevisionConflictError = class extends NamzuError {
|
|
@@ -99452,7 +99650,7 @@ var DiskMemoryStore = class {
|
|
|
99452
99650
|
};
|
|
99453
99651
|
|
|
99454
99652
|
// ../sdk/dist/store/memory/markdown.js
|
|
99455
|
-
import { createHash as
|
|
99653
|
+
import { createHash as createHash29 } from "node:crypto";
|
|
99456
99654
|
import { lstat as lstat8, mkdir as mkdir15, readFile as readFile18, readdir as readdir11, realpath as realpath9, rename as rename6, unlink as unlink12 } from "node:fs/promises";
|
|
99457
99655
|
import { dirname as dirname19, join as join34, resolve as resolve18 } from "node:path";
|
|
99458
99656
|
|
|
@@ -99692,7 +99890,7 @@ function invalidFile(file2, reason, cause) {
|
|
|
99692
99890
|
}
|
|
99693
99891
|
__name(invalidFile, "invalidFile");
|
|
99694
99892
|
function derivedMemoryId(name2) {
|
|
99695
|
-
const hex4 =
|
|
99893
|
+
const hex4 = createHash29("sha256").update(`namzu-memory-name:${name2}`).digest("hex");
|
|
99696
99894
|
const variant = (Number.parseInt(hex4[16] ?? "0", 16) & 3 | 8).toString(16);
|
|
99697
99895
|
return `${hex4.slice(0, 8)}-${hex4.slice(8, 12)}-8${hex4.slice(13, 16)}-${variant}${hex4.slice(17, 20)}-${hex4.slice(20, 32)}`;
|
|
99698
99896
|
}
|
|
@@ -105607,7 +105805,7 @@ function toolResultToMCPToolResult(result) {
|
|
|
105607
105805
|
__name(toolResultToMCPToolResult, "toolResultToMCPToolResult");
|
|
105608
105806
|
|
|
105609
105807
|
// ../sdk/dist/connector/mcp/policy.js
|
|
105610
|
-
import { createHash as
|
|
105808
|
+
import { createHash as createHash30 } from "node:crypto";
|
|
105611
105809
|
function applyToolPolicy(tools, policy) {
|
|
105612
105810
|
return applyNamePolicy(tools, policy);
|
|
105613
105811
|
}
|
|
@@ -105647,7 +105845,7 @@ function toolsHash(tools) {
|
|
|
105647
105845
|
// fingerprint built to catch exactly that rug-pull saw nothing.
|
|
105648
105846
|
annotations: stableStringify2(tool.annotations)
|
|
105649
105847
|
}));
|
|
105650
|
-
return
|
|
105848
|
+
return createHash30("sha256").update(JSON.stringify(canonical4)).digest("hex");
|
|
105651
105849
|
}
|
|
105652
105850
|
__name(toolsHash, "toolsHash");
|
|
105653
105851
|
function diffTools(before, after) {
|
|
@@ -105870,7 +106068,7 @@ var MCPToolDiscovery = class {
|
|
|
105870
106068
|
};
|
|
105871
106069
|
|
|
105872
106070
|
// ../sdk/dist/connector/mcp/mcp-toolset.js
|
|
105873
|
-
import { createHash as
|
|
106071
|
+
import { createHash as createHash31 } from "node:crypto";
|
|
105874
106072
|
|
|
105875
106073
|
// ../sdk/dist/connector/mcp/prompt-adapter.js
|
|
105876
106074
|
function renderPromptMessages(serverName, promptName, messages, description) {
|
|
@@ -105941,7 +106139,7 @@ function mcpToolsetName(serverName, ...segments) {
|
|
|
105941
106139
|
const full = ["mcp", serverName, ...segments].join("__");
|
|
105942
106140
|
if (full.length <= MCP_TOOLSET_NAME_MAX_LENGTH)
|
|
105943
106141
|
return full;
|
|
105944
|
-
const hash4 =
|
|
106142
|
+
const hash4 = createHash31("sha256").update(full).digest("hex").slice(0, 8);
|
|
105945
106143
|
const suffix = `_${hash4}`;
|
|
105946
106144
|
return `${full.slice(0, MCP_TOOLSET_NAME_MAX_LENGTH - suffix.length)}${suffix}`;
|
|
105947
106145
|
}
|
|
@@ -109678,7 +109876,7 @@ var AgentManager = class {
|
|
|
109678
109876
|
deps;
|
|
109679
109877
|
topicManager;
|
|
109680
109878
|
pendingSpawns = /* @__PURE__ */ new Map();
|
|
109681
|
-
drainingParents = /* @__PURE__ */ new
|
|
109879
|
+
drainingParents = /* @__PURE__ */ new Map();
|
|
109682
109880
|
executingTasks = /* @__PURE__ */ new Set();
|
|
109683
109881
|
cancelingTasks = /* @__PURE__ */ new Set();
|
|
109684
109882
|
admissionTimer;
|
|
@@ -109775,14 +109973,19 @@ var AgentManager = class {
|
|
|
109775
109973
|
} catch (error62) {
|
|
109776
109974
|
this.failAdmission(entry, error62);
|
|
109777
109975
|
}
|
|
109778
|
-
this.pumpAdmissions(options.parentSessionId);
|
|
109976
|
+
await this.pumpAdmissions(options.parentSessionId);
|
|
109977
|
+
if (entry.ready && task.state === "pending" && !this.disposed)
|
|
109978
|
+
await this.pumpAdmissions(options.parentSessionId);
|
|
109779
109979
|
return task;
|
|
109780
109980
|
}
|
|
109981
|
+
/** Run one admission pass; resolves when it has started what it can, never rejects. */
|
|
109781
109982
|
pumpAdmissions(parentSessionId) {
|
|
109782
|
-
if (this.disposed
|
|
109783
|
-
return;
|
|
109784
|
-
this.drainingParents.
|
|
109785
|
-
|
|
109983
|
+
if (this.disposed)
|
|
109984
|
+
return Promise.resolve();
|
|
109985
|
+
const running = this.drainingParents.get(parentSessionId);
|
|
109986
|
+
if (running)
|
|
109987
|
+
return running;
|
|
109988
|
+
const pass = this.drainAdmissions(parentSessionId).finally(() => {
|
|
109786
109989
|
this.drainingParents.delete(parentSessionId);
|
|
109787
109990
|
if (!this.disposed && this.pendingSpawns.size > 0 && !this.admissionTimer) {
|
|
109788
109991
|
this.admissionTimer = setTimeout(() => {
|
|
@@ -109795,6 +109998,8 @@ var AgentManager = class {
|
|
|
109795
109998
|
}).catch((error62) => this.log.error("Delegation admission failed", {
|
|
109796
109999
|
"exception.message": toErrorMessage(error62)
|
|
109797
110000
|
}));
|
|
110001
|
+
this.drainingParents.set(parentSessionId, pass);
|
|
110002
|
+
return pass;
|
|
109798
110003
|
}
|
|
109799
110004
|
async drainAdmissions(parentSessionId) {
|
|
109800
110005
|
const queue = this.pendingSpawns.get(parentSessionId);
|
|
@@ -119727,7 +119932,7 @@ function extractStreamUsage(usage) {
|
|
|
119727
119932
|
inputTokens: u.inputTokens ?? u.promptTokens,
|
|
119728
119933
|
outputTokens: u.outputTokens ?? u.completionTokens,
|
|
119729
119934
|
totalTokens: u.totalTokens,
|
|
119730
|
-
costUsd: u.costUsd
|
|
119935
|
+
costUsd: u.costUsd ?? u.reportedCostUsd
|
|
119731
119936
|
};
|
|
119732
119937
|
}
|
|
119733
119938
|
__name(extractStreamUsage, "extractStreamUsage");
|
|
@@ -120474,7 +120679,7 @@ function upsertBy(items, key6, next2) {
|
|
|
120474
120679
|
__name(upsertBy, "upsertBy");
|
|
120475
120680
|
|
|
120476
120681
|
// ../sdk/dist/session/workspace/hooked-driver.js
|
|
120477
|
-
import { createHash as
|
|
120682
|
+
import { createHash as createHash32 } from "node:crypto";
|
|
120478
120683
|
import { lstat as lstat10, readdir as readdir14, stat as stat16 } from "node:fs/promises";
|
|
120479
120684
|
import { isAbsolute as isAbsolute18, join as join42, resolve as resolve24 } from "node:path";
|
|
120480
120685
|
function worktreeHookHost(manager, sessionId5) {
|
|
@@ -120532,7 +120737,7 @@ async function fingerprint(root) {
|
|
|
120532
120737
|
} catch {
|
|
120533
120738
|
return void 0;
|
|
120534
120739
|
}
|
|
120535
|
-
return
|
|
120740
|
+
return createHash32("sha1").update(lines.join("\n")).digest("hex");
|
|
120536
120741
|
}
|
|
120537
120742
|
__name(fingerprint, "fingerprint");
|
|
120538
120743
|
var HookedWorkspaceDriver = class {
|
|
@@ -122100,7 +122305,7 @@ var InMemorySessionStore = class {
|
|
|
122100
122305
|
};
|
|
122101
122306
|
|
|
122102
122307
|
// ../sdk/dist/store/session/disk.js
|
|
122103
|
-
import { createHash as
|
|
122308
|
+
import { createHash as createHash33 } from "node:crypto";
|
|
122104
122309
|
import { mkdir as mkdir19, rm as rm7 } from "node:fs/promises";
|
|
122105
122310
|
import { join as join44, resolve as resolve27 } from "node:path";
|
|
122106
122311
|
var SCHEMA9 = defineSchema({
|
|
@@ -122269,7 +122474,7 @@ var DiskSessionStore = class {
|
|
|
122269
122474
|
}
|
|
122270
122475
|
rootPathBindingLocation(rootPath, tenantId2) {
|
|
122271
122476
|
const key6 = rootPathIndexKey(rootPath, tenantId2);
|
|
122272
|
-
const digest8 =
|
|
122477
|
+
const digest8 = createHash33("sha256").update(key6).digest("hex");
|
|
122273
122478
|
const root = join44(this.rootDir, "projects", ".root-path-index", digest8.slice(0, 2));
|
|
122274
122479
|
return {
|
|
122275
122480
|
legacyPath: join44(root, `${digest8.slice(2)}.json`),
|
|
@@ -123865,7 +124070,7 @@ function evalSetting(path2) {
|
|
|
123865
124070
|
__name(evalSetting, "evalSetting");
|
|
123866
124071
|
|
|
123867
124072
|
// ../sdk/dist/eval/settings.js
|
|
123868
|
-
import { createHash as
|
|
124073
|
+
import { createHash as createHash34 } from "node:crypto";
|
|
123869
124074
|
var SETTINGS_DIGEST_ALGORITHM = "sha256-canonical-json-1";
|
|
123870
124075
|
var DEFAULT_SETTINGS_NAME = "default";
|
|
123871
124076
|
function isRecord7(value) {
|
|
@@ -123961,7 +124166,7 @@ function buildSettingsSnapshot(name2, values = {}) {
|
|
|
123961
124166
|
}
|
|
123962
124167
|
return {
|
|
123963
124168
|
name: name2,
|
|
123964
|
-
digest:
|
|
124169
|
+
digest: createHash34("sha256").update(canonical4).digest("hex"),
|
|
123965
124170
|
algorithm: SETTINGS_DIGEST_ALGORITHM,
|
|
123966
124171
|
// A copy through the canonical form, so what is stored is what was hashed.
|
|
123967
124172
|
values: JSON.parse(canonical4)
|
|
@@ -124006,7 +124211,7 @@ function diffSettings(a, b) {
|
|
|
124006
124211
|
__name(diffSettings, "diffSettings");
|
|
124007
124212
|
|
|
124008
124213
|
// ../sdk/dist/eval/split.js
|
|
124009
|
-
import { createHash as
|
|
124214
|
+
import { createHash as createHash35 } from "node:crypto";
|
|
124010
124215
|
var SPLIT_FILTERS = ["tune", "held-out", "all"];
|
|
124011
124216
|
var TASK_SPLIT_SEED = "namzu-eval-split-1";
|
|
124012
124217
|
var HELD_OUT_FRACTION = 0.5;
|
|
@@ -124015,7 +124220,7 @@ function taskId(suite, name2) {
|
|
|
124015
124220
|
}
|
|
124016
124221
|
__name(taskId, "taskId");
|
|
124017
124222
|
function hashedSplit(suite, name2) {
|
|
124018
|
-
const digest8 =
|
|
124223
|
+
const digest8 = createHash35("sha256").update(`${TASK_SPLIT_SEED}\0${suite}\0${name2}`).digest();
|
|
124019
124224
|
const fraction = digest8.readUIntBE(0, 6) / 2 ** 48;
|
|
124020
124225
|
return fraction < HELD_OUT_FRACTION ? "held-out" : "tune";
|
|
124021
124226
|
}
|
|
@@ -124539,15 +124744,19 @@ function judgeScorer(config2) {
|
|
|
124539
124744
|
return {
|
|
124540
124745
|
name: config2.name ?? "judge",
|
|
124541
124746
|
async score(turn, evalCase, signal) {
|
|
124542
|
-
const response = await collectChatCompletion(
|
|
124543
|
-
|
|
124544
|
-
|
|
124545
|
-
|
|
124546
|
-
|
|
124547
|
-
|
|
124548
|
-
|
|
124549
|
-
|
|
124550
|
-
|
|
124747
|
+
const response = await collectChatCompletion(
|
|
124748
|
+
// A grade is a side request: a thinking model must not spend the
|
|
124749
|
+
// whole allowance on reasoning and hand back nothing to grade.
|
|
124750
|
+
chatStreamForSideRequest(provider, {
|
|
124751
|
+
model: config2.model,
|
|
124752
|
+
messages: [{ role: "user", content: buildPrompt(config2, turn, evalCase, scale) }],
|
|
124753
|
+
// The same turn must grade the same way twice, or a
|
|
124754
|
+
// regression cannot be told from sampling noise.
|
|
124755
|
+
temperature: 0,
|
|
124756
|
+
maxTokens: 512,
|
|
124757
|
+
...signal ? { signal } : {}
|
|
124758
|
+
}, (request) => chatStreamWithSamplingRepair(provider, request))
|
|
124759
|
+
);
|
|
124551
124760
|
const verdict2 = parseVerdict2(response.message.content ?? "", scale);
|
|
124552
124761
|
return {
|
|
124553
124762
|
score: verdict2.grade / scale,
|
|
@@ -125306,60 +125515,61 @@ __name(coalesce, "coalesce");
|
|
|
125306
125515
|
// ../sdk/dist/prompt/coding-agent-doctrine.js
|
|
125307
125516
|
var CODING_AGENT_WORKING_DOCTRINE = `## How you work
|
|
125308
125517
|
|
|
125309
|
-
###
|
|
125310
|
-
-
|
|
125311
|
-
-
|
|
125312
|
-
-
|
|
125313
|
-
-
|
|
125314
|
-
|
|
125315
|
-
|
|
125518
|
+
### Answering a question
|
|
125519
|
+
- A question, or a description of a problem, gets an answer or an assessment first. Act only when asked to act, or when the answer needs a fact one look can get.
|
|
125520
|
+
- Make that look one step: independent tool calls, such as every search for the fact, go in one response. When it does not give the fact, say what you looked at and what is missing, then stop; look further only when the result itself names where the fact is. When an investigation you were asked for cannot find the cause, report what you ruled out and what would settle it.
|
|
125521
|
+
- Open with the answer, not with an apology or with agreement for its own sake.
|
|
125522
|
+
- A step that says it will do something does it in that step, and a turn never ends on a promise of a later answer.
|
|
125523
|
+
|
|
125524
|
+
### Asking and proceeding
|
|
125525
|
+
- Act when you have enough information. Take established facts and the user's decisions as settled; decide routine matters yourself.
|
|
125526
|
+
- Ask only when you cannot name the most likely reading of the request, or when proceeding under any assumption would be unsafe or would make the work useless if wrong. Ask once, with your best guess, because ending the turn stops all work.
|
|
125527
|
+
- If you find a real problem with the task as stated, say so in a sentence, then keep going under a stated assumption. If the user repeats or reaffirms a request after you raised a concern, that is their decision: say so and do the full request.
|
|
125528
|
+
- After a refused or empty result, change the request or report it; do not issue the same call again.
|
|
125316
125529
|
|
|
125317
125530
|
### Reporting
|
|
125318
|
-
- Report outcomes faithfully
|
|
125319
|
-
- Report identifiers exactly as the evidence spells them, so
|
|
125320
|
-
-
|
|
125321
|
-
- Reference code as \`path:line\` so the user can jump to it.
|
|
125322
|
-
- Correct an earlier statement only when the error would change the user's code, conclusions or decisions; state it once, plainly, and continue, and keep apologies and tallies of past mistakes out of it, because they spend the reader's attention on the past.
|
|
125531
|
+
- Report outcomes faithfully: show failing test output, say what you skipped, and state what is done and verified.
|
|
125532
|
+
- Report identifiers exactly as the evidence spells them, and reference code as \`path:line\`. Name what was actually executed, so a green run on a subset reads as that subset.
|
|
125533
|
+
- Correct an earlier statement only when the error would change the user's code, conclusions or decisions; state it once, plainly, with no apology or tally of past mistakes, because they spend the reader's attention on the past.
|
|
125323
125534
|
|
|
125324
125535
|
### Using available evidence
|
|
125325
|
-
-
|
|
125326
|
-
-
|
|
125327
|
-
-
|
|
125328
|
-
|
|
125329
|
-
|
|
125330
|
-
|
|
125331
|
-
|
|
125332
|
-
|
|
125333
|
-
-
|
|
125334
|
-
-
|
|
125335
|
-
-
|
|
125536
|
+
- A successful tool result with its exact inputs is evidence of what happened, and so is content you wrote; an announced action, a failed call or another agent's unsupported claim is not. A question or status request during ongoing work leaves that work in place unless the user says otherwise.
|
|
125537
|
+
- Reuse evidence still in the conversation instead of observing it again by habit, and when you do observe, ask the narrowest question that resolves the uncertainty (a known file, not a directory). Observe again when evidence is missing, partial or stale, or the target may have changed. Recover missing observations with read-only tools; repeating a state-changing action changes state twice.
|
|
125538
|
+
- If a check or an exact-match edit reports a mismatch, inspect the current state and revise the action.
|
|
125539
|
+
- For a question about an earlier state, use that observation or its retained original; a fresh read of a mutable source cannot show what it held earlier. When the detail is gone, say so and leave today's value out.
|
|
125540
|
+
- Wait for a mutation to finish before an observation or another action that depends on it.
|
|
125541
|
+
|
|
125542
|
+
### When the task is to change code
|
|
125543
|
+
This section applies only when you were asked to change something.
|
|
125544
|
+
- Begin editing once you know the first change, and refine as you go. The requested scope is the deliverable, at the size asked.
|
|
125545
|
+
- Finish the whole task, not just the easy parts. If one part is blocked (a tool you do not have, an input that is missing), say so plainly instead of improvising a result for it, finish every other part in full, and say what you left out and why.
|
|
125546
|
+
- Before editing, use file content you already read or wrote; if it may be stale, read the needed portion again, and match the surrounding naming and idiom.
|
|
125547
|
+
- Prefer the dedicated tools over shell equivalents (\`read\` over \`cat\`, \`grep\` over a shell grep, \`glob\` over \`find\`, \`edit\` over \`sed -i\`, \`write\` over a shell redirect); use \`bash\` for a shell.
|
|
125548
|
+
- For a defect, reproduce it first with a small script or a failing test, and keep it; make the change, then rerun that reproduction. Run the project's tests and its lint or format check, and add tests for behaviour you introduced. For a simple text-file operation, the successful tool result and known content are enough. Claim only the checks you ran.
|
|
125549
|
+
- Say where any throwaway file you made is, and which files outside the request you touched.
|
|
125336
125550
|
|
|
125337
125551
|
### Working with git
|
|
125338
125552
|
- Never push, force-push, reset, rebase, clean, or otherwise discard or rewrite history unless the user explicitly asked for that action. Approval for one push does not extend to the next.
|
|
125339
125553
|
- Before any command that could discard uncommitted work, run \`git status\`. If there are changes there that you did not make, stop and ask rather than stashing, committing or discarding somebody else's work.
|
|
125340
|
-
- Commit only when the user asks, on the branch that is checked out
|
|
125341
|
-
- After a broad \`git add\`, review what was staged before committing; a file whose name looks harmless can still carry a secret.
|
|
125554
|
+
- Commit only when the user asks, on the branch that is checked out, and switch branches only when asked or the project's instructions require it, because the checked-out branch is the user's working state. After a broad \`git add\`, review what was staged.
|
|
125342
125555
|
- Never change git configuration or other persistent settings without asking: not \`user.name\` or \`user.email\`, hooks, remotes, credential helpers, or any \`git config\` (local or global), nor a shell profile or a tool's own config file. If a commit fails because no identity is set, stop and tell the user the command to set one; do not invent one.
|
|
125343
125556
|
|
|
125344
125557
|
### Keeping the user informed
|
|
125345
|
-
-
|
|
125346
|
-
-
|
|
125558
|
+
- For work that takes several calls, say one short line before the first call and one more when you find something, change direction or hit a blocker, and a few words on where you are after a long stretch without one; a question that needs at most one look gets no such line, and no line goes beside each call, because the tool rows on screen show the details.
|
|
125559
|
+
- When you changed something, close with what changed, what was verified and what is left. For a question the reply is the answer.`;
|
|
125347
125560
|
var CODING_AGENT_DELEGATION_DOCTRINE = `### Planning and delegating
|
|
125348
|
-
- A task list is optional. For work of three or more distinct steps
|
|
125349
|
-
- When the \`Agent\` tool is available, do small work, or work whose target you already know, yourself: a file you can name, one search, one edit. A fresh sub-agent starts with none of your context. Delegate work that is independent of your next step, large, or whose output would flood your context,
|
|
125350
|
-
- You keep the understanding
|
|
125561
|
+
- A task list is optional. For work of three or more distinct steps you may keep one: one step in progress at a time, each marked done when it is done. Do not make one for a two-step job.
|
|
125562
|
+
- When the \`Agent\` tool is available, do small work, or work whose target you already know, yourself: a file you can name, one search, one edit. A fresh sub-agent starts with none of your context. Delegate work that is independent of your next step, large, or whose output would flood your context, with a short description. Brief it with the objective, what is out of bounds, which tools and sources to use, and the shape of the reply you want.
|
|
125563
|
+
- You keep the understanding: pass paths, line numbers and what is already ruled out, never a conclusion for the sub-agent to confirm, and once delegated, do not do the work again yourself.
|
|
125351
125564
|
- A sub-agent's report is a claim, not a fact. Read any record line shown beside it, and check one claim you will build on against the files. Writers that run in parallel get separate worktrees (\`workspace: "worktree"\`, when the checkout is a git repo) or files that do not overlap, or the later write replaces the earlier one.
|
|
125352
|
-
- When the \`Agent\` tool lists a \`fork\` type, use \`subagent_type: "fork"\`
|
|
125353
|
-
- When delegated agents finish, tell the user what each one found in your next message
|
|
125354
|
-
- Use \`subagent_type: "explore"\` to locate something small
|
|
125565
|
+
- When the \`Agent\` tool lists a \`fork\` type, use \`subagent_type: "fork"\` for a side task whose output you will not need again; its prompt is only the directive. Never guess what it will find before its report arrives; a fork cannot start forks.
|
|
125566
|
+
- When delegated agents finish, tell the user what each one found in your next message, because their results reach you and not the user.
|
|
125567
|
+
- Use \`subagent_type: "explore"\` to locate something small; it only reads and searches, and never asks the user for permission. It is not for reviewing or auditing whole files. Reserve the default sub-agent for work that changes files or runs commands.
|
|
125355
125568
|
|
|
125356
125569
|
### Answering how work is going
|
|
125357
|
-
-
|
|
125358
|
-
- Give each item the state you were given for it (progressing, waiting, stalled or dead) and how long ago it last moved
|
|
125359
|
-
-
|
|
125360
|
-
- Name each item by what it is doing, not by its id: an id means nothing to the person, so give one only when they ask for it or need it for a command.
|
|
125361
|
-
- A result exists only once its completion message has arrived, so for an unfinished item say it is still running; a predicted result reads as a fact and may be wrong.
|
|
125362
|
-
- For an item reported dead, say it ended without a result and offer to run it again; starting the same work again unasked could repeat what it already did.`;
|
|
125570
|
+
- Read the note about running work on your request first if the host gives you one, and add one status read from the tool that started an item only when the note does not say enough. Leave the work running.
|
|
125571
|
+
- Give each item the state you were given for it (progressing, waiting, stalled or dead) and how long ago it last moved; stalled means only quiet for a while. Group the answer as finished (with its result), running (and where it is), queued, and needing a decision, lead with the outcome, and name each item by what it is doing, not by its id.
|
|
125572
|
+
- A result exists only once its completion message has arrived, so for an unfinished item say it is still running. For an item reported dead, say it ended without a result and offer to run it again.`;
|
|
125363
125573
|
var PLAN_MODE_DOCTRINE = `## Plan mode
|
|
125364
125574
|
|
|
125365
125575
|
You are in plan mode. Read, search and think, and leave everything as it is. \`read\`, \`grep\`, \`glob\` and the other read-only tools work as usual, and you may keep a task list. Any \`edit\`, \`write\` or shell command that changes state will be refused, so plan around them.
|
|
@@ -125829,7 +126039,7 @@ function analyzeContextUsage(input2) {
|
|
|
125829
126039
|
__name(analyzeContextUsage, "analyzeContextUsage");
|
|
125830
126040
|
|
|
125831
126041
|
// ../sdk/dist/learning/skill.js
|
|
125832
|
-
import { createHash as
|
|
126042
|
+
import { createHash as createHash36 } from "node:crypto";
|
|
125833
126043
|
var label = external_exports.string().trim().min(1).max(256);
|
|
125834
126044
|
var name = external_exports.string().regex(/^[a-z0-9][a-z0-9_-]{0,63}$/);
|
|
125835
126045
|
var digest3 = external_exports.string().regex(/^[a-f0-9]{64}$/);
|
|
@@ -125982,7 +126192,7 @@ function reviseLearningProfile(current, input2) {
|
|
|
125982
126192
|
__name(reviseLearningProfile, "reviseLearningProfile");
|
|
125983
126193
|
function hashLearningSkill(input2) {
|
|
125984
126194
|
const candidate = candidateSchema.parse(input2);
|
|
125985
|
-
return
|
|
126195
|
+
return createHash36("sha256").update(JSON.stringify([
|
|
125986
126196
|
candidate.name,
|
|
125987
126197
|
candidate.description,
|
|
125988
126198
|
candidate.body,
|
|
@@ -126022,13 +126232,13 @@ function promoteLearningSkill(current, input2, evaluation, inputEvidence) {
|
|
|
126022
126232
|
verification: {
|
|
126023
126233
|
baselineHash,
|
|
126024
126234
|
candidateHash: hash4,
|
|
126025
|
-
evidenceDigest:
|
|
126235
|
+
evidenceDigest: createHash36("sha256").update(JSON.stringify({ ...evaluation, protection })).digest("hex"),
|
|
126026
126236
|
verificationTasks: review.verification.tasks.length,
|
|
126027
126237
|
confirmationTasks: review.confirmation?.tasks.length ?? 0,
|
|
126028
126238
|
protection: {
|
|
126029
126239
|
verificationTasks: protection.verification.length,
|
|
126030
126240
|
confirmationTasks: protection.confirmation.length,
|
|
126031
|
-
planDigest:
|
|
126241
|
+
planDigest: createHash36("sha256").update(JSON.stringify(protection)).digest("hex")
|
|
126032
126242
|
}
|
|
126033
126243
|
}
|
|
126034
126244
|
};
|
|
@@ -126137,10 +126347,10 @@ function projectLearning(current, options) {
|
|
|
126137
126347
|
__name(projectLearning, "projectLearning");
|
|
126138
126348
|
|
|
126139
126349
|
// ../sdk/dist/learning/cycle.js
|
|
126140
|
-
import { createHash as
|
|
126350
|
+
import { createHash as createHash38, randomUUID as randomUUID9 } from "node:crypto";
|
|
126141
126351
|
|
|
126142
126352
|
// ../sdk/dist/learning/guidance.js
|
|
126143
|
-
import { createHash as
|
|
126353
|
+
import { createHash as createHash37 } from "node:crypto";
|
|
126144
126354
|
import { readdir as readdir16 } from "node:fs/promises";
|
|
126145
126355
|
import { join as join45 } from "node:path";
|
|
126146
126356
|
import { isDeepStrictEqual as isDeepStrictEqual7 } from "node:util";
|
|
@@ -126185,7 +126395,7 @@ var ADOPTED_MARKER = "adopted.json";
|
|
|
126185
126395
|
var REVISION_FILE = /^([1-9][0-9]{0,15})\.json$/;
|
|
126186
126396
|
function keySegment(key6) {
|
|
126187
126397
|
const encoded = revisionFileSegment(key6);
|
|
126188
|
-
return encoded.length <= 255 ? encoded : `~sha256-${
|
|
126398
|
+
return encoded.length <= 255 ? encoded : `~sha256-${createHash37("sha256").update(encoded).digest("hex")}`;
|
|
126189
126399
|
}
|
|
126190
126400
|
__name(keySegment, "keySegment");
|
|
126191
126401
|
function earlierGuidanceDirectory(root, scope) {
|
|
@@ -126755,7 +126965,7 @@ ${exploration.evidence.reason}`
|
|
|
126755
126965
|
}, { subject: "exploration.trace", text: exploration.trace });
|
|
126756
126966
|
await append("exploration", {
|
|
126757
126967
|
observations: exploration,
|
|
126758
|
-
digest:
|
|
126968
|
+
digest: createHash38("sha256").update(JSON.stringify(exploration)).digest("hex")
|
|
126759
126969
|
}, "explore");
|
|
126760
126970
|
const problem2 = resourceProblem(true);
|
|
126761
126971
|
if (problem2)
|
|
@@ -126804,7 +127014,7 @@ ${s.revision}`).join("\n"),
|
|
|
126804
127014
|
await append("evaluation", {
|
|
126805
127015
|
baselineRevision,
|
|
126806
127016
|
candidateRevision,
|
|
126807
|
-
digest:
|
|
127017
|
+
digest: createHash38("sha256").update(JSON.stringify(batch)).digest("hex"),
|
|
126808
127018
|
baselineTrajectories: batch.baseline.map((t) => t.trajectoryId),
|
|
126809
127019
|
candidateTrajectories: batch.candidate.map((t) => t.trajectoryId)
|
|
126810
127020
|
}, name2);
|
|
@@ -127335,7 +127545,7 @@ var SqliteLearningExperienceStore = class {
|
|
|
127335
127545
|
};
|
|
127336
127546
|
|
|
127337
127547
|
// ../sdk/dist/learning/store.js
|
|
127338
|
-
import { createHash as
|
|
127548
|
+
import { createHash as createHash39, randomUUID as randomUUID11 } from "node:crypto";
|
|
127339
127549
|
import { closeSync as closeSync3, existsSync as existsSync6, fsyncSync, linkSync, lstatSync as lstatSync4, mkdirSync as mkdirSync7, openSync as openSync3, readFileSync as readFileSync6, unlinkSync, writeFileSync as writeFileSync4 } from "node:fs";
|
|
127340
127550
|
import { createRequire as createRequire4 } from "node:module";
|
|
127341
127551
|
import { dirname as dirname25, join as join46, resolve as resolve29 } from "node:path";
|
|
@@ -127364,7 +127574,7 @@ var learningObservationSchema = learningTargetSchema.extend({
|
|
|
127364
127574
|
|
|
127365
127575
|
// ../sdk/dist/learning/store.js
|
|
127366
127576
|
var uuid5 = external_exports.string().uuid().transform((id3) => id3.toLowerCase());
|
|
127367
|
-
var digest4 = /* @__PURE__ */ __name((text11) =>
|
|
127577
|
+
var digest4 = /* @__PURE__ */ __name((text11) => createHash39("sha256").update(text11).digest("hex"), "digest");
|
|
127368
127578
|
var MAX_EVENT_BYTES = 256 * 1024;
|
|
127369
127579
|
var MAX_ARTIFACT_BYTES = 8 * 1024 * 1024;
|
|
127370
127580
|
var MAX_EVENTS = 4096;
|
|
@@ -128083,7 +128293,7 @@ function parsePeerAddress(address2) {
|
|
|
128083
128293
|
__name(parsePeerAddress, "parsePeerAddress");
|
|
128084
128294
|
|
|
128085
128295
|
// ../sdk/dist/peers/record.js
|
|
128086
|
-
import { createHash as
|
|
128296
|
+
import { createHash as createHash40 } from "node:crypto";
|
|
128087
128297
|
|
|
128088
128298
|
// ../sdk/dist/peers/protocol.js
|
|
128089
128299
|
var PEER_PROTOCOL_VERSION = "namzu-peer/1";
|
|
@@ -128234,7 +128444,7 @@ var PeerRecordSchema = external_exports.object({
|
|
|
128234
128444
|
var PeerRecordReaderSchema = PeerRecordSchema.strip();
|
|
128235
128445
|
var PEER_REF_HEX_LENGTH = 6;
|
|
128236
128446
|
function derivePeerRef(sessionId5) {
|
|
128237
|
-
return
|
|
128447
|
+
return createHash40("sha256").update(sessionId5, "utf8").digest("hex").slice(0, PEER_REF_HEX_LENGTH);
|
|
128238
128448
|
}
|
|
128239
128449
|
__name(derivePeerRef, "derivePeerRef");
|
|
128240
128450
|
|
|
@@ -130410,7 +130620,7 @@ var PAL_WORK_GUIDANCE = [
|
|
|
130410
130620
|
].join("\n\n");
|
|
130411
130621
|
|
|
130412
130622
|
// ../sdk/dist/pals/reference-images.js
|
|
130413
|
-
import { createHash as
|
|
130623
|
+
import { createHash as createHash41, randomUUID as randomUUID13 } from "node:crypto";
|
|
130414
130624
|
import { posix as posix4 } from "node:path";
|
|
130415
130625
|
var MAX_IMAGES = 8;
|
|
130416
130626
|
var MAX_IMAGE_BYTES = 3 * 1024 * 1024;
|
|
@@ -130454,7 +130664,7 @@ function preparePalReferenceImages(attachments) {
|
|
|
130454
130664
|
attachmentIndex: index + 1,
|
|
130455
130665
|
mediaType: attachment.mediaType,
|
|
130456
130666
|
data: attachment.data,
|
|
130457
|
-
sha256:
|
|
130667
|
+
sha256: createHash41("sha256").update(bytes).digest("hex"),
|
|
130458
130668
|
bytes: bytes.length
|
|
130459
130669
|
}));
|
|
130460
130670
|
}
|
|
@@ -130641,7 +130851,7 @@ import { isDeepStrictEqual as isDeepStrictEqual10 } from "node:util";
|
|
|
130641
130851
|
import { isDeepStrictEqual as isDeepStrictEqual8 } from "node:util";
|
|
130642
130852
|
|
|
130643
130853
|
// ../sdk/dist/pals/communication/schema.js
|
|
130644
|
-
import { createHash as
|
|
130854
|
+
import { createHash as createHash42 } from "node:crypto";
|
|
130645
130855
|
var id2 = external_exports.string().uuid();
|
|
130646
130856
|
var sessionId3 = external_exports.custom((s) => isEntityId(s, "session"));
|
|
130647
130857
|
var turnId4 = external_exports.custom((s) => isEntityId(s, "turn"));
|
|
@@ -130736,7 +130946,7 @@ function freezeCommunicationValue(value) {
|
|
|
130736
130946
|
}
|
|
130737
130947
|
__name(freezeCommunicationValue, "freezeCommunicationValue");
|
|
130738
130948
|
function hash3(value) {
|
|
130739
|
-
return
|
|
130949
|
+
return createHash42("sha256").update(JSON.stringify(value)).digest("hex");
|
|
130740
130950
|
}
|
|
130741
130951
|
__name(hash3, "hash");
|
|
130742
130952
|
function addressTuple(value) {
|
|
@@ -132444,10 +132654,10 @@ var DiskPalMessagePolicy = class {
|
|
|
132444
132654
|
};
|
|
132445
132655
|
|
|
132446
132656
|
// ../sdk/dist/pals/activity/source.js
|
|
132447
|
-
import { createHash as
|
|
132657
|
+
import { createHash as createHash44 } from "node:crypto";
|
|
132448
132658
|
|
|
132449
132659
|
// ../sdk/dist/pals/activity/projection.js
|
|
132450
|
-
import { createHash as
|
|
132660
|
+
import { createHash as createHash43 } from "node:crypto";
|
|
132451
132661
|
var activityId2 = external_exports.custom((value) => isEntityId(value, "activity"));
|
|
132452
132662
|
var checkpointId3 = external_exports.custom((value) => isEntityId(value, "checkpoint"));
|
|
132453
132663
|
var toolUseId2 = external_exports.string().min(1).max(512).regex(/^[A-Za-z0-9_.:-]+$/);
|
|
@@ -132506,7 +132716,7 @@ function projectPalActivity(entry, scopeHash) {
|
|
|
132506
132716
|
return null;
|
|
132507
132717
|
}
|
|
132508
132718
|
return Object.freeze({
|
|
132509
|
-
id:
|
|
132719
|
+
id: createHash43("sha256").update(JSON.stringify(["pal-activity/1", scopeHash, pointer2])).digest("hex"),
|
|
132510
132720
|
type: record4.type,
|
|
132511
132721
|
sessionId: record4.sessionId,
|
|
132512
132722
|
..."turnId" in record4 ? { turnId: record4.turnId } : {},
|
|
@@ -132600,7 +132810,7 @@ function createPalActivitySource(options) {
|
|
|
132600
132810
|
if (definition.id !== scope.palId || definition.revision !== scope.profileRevision)
|
|
132601
132811
|
throw new PalActivityIntegrityError();
|
|
132602
132812
|
const workspace = definition.workspace;
|
|
132603
|
-
const scopeHash =
|
|
132813
|
+
const scopeHash = createHash44("sha256").update(JSON.stringify([
|
|
132604
132814
|
"pal-activity/1",
|
|
132605
132815
|
scope.tenantId,
|
|
132606
132816
|
scope.projectId,
|
|
@@ -132993,7 +133203,7 @@ import { join as join55, resolve as resolve34 } from "node:path";
|
|
|
132993
133203
|
import { isDeepStrictEqual as isDeepStrictEqual11 } from "node:util";
|
|
132994
133204
|
|
|
132995
133205
|
// ../sdk/dist/pals/channels/schema.js
|
|
132996
|
-
import { createHash as
|
|
133206
|
+
import { createHash as createHash45 } from "node:crypto";
|
|
132997
133207
|
var connectionSchema = external_exports.object({
|
|
132998
133208
|
tenantId: addressSchema2.shape.tenantId,
|
|
132999
133209
|
provider: label4,
|
|
@@ -133024,7 +133234,7 @@ var verifiedActionSchema = external_exports.object({
|
|
|
133024
133234
|
actionId: label4,
|
|
133025
133235
|
payloadDigest: external_exports.string().regex(/^[a-f0-9]{64}$/),
|
|
133026
133236
|
payload: external_exports.string().min(1).max(32e3).refine((value) => !value.includes("\0"))
|
|
133027
|
-
}).strict().refine((value) =>
|
|
133237
|
+
}).strict().refine((value) => createHash45("sha256").update(value.payload).digest("hex") === value.payloadDigest, "Channel action payload does not match its authenticated digest.");
|
|
133028
133238
|
var routeDecisionSchema = external_exports.object({
|
|
133029
133239
|
v: external_exports.literal(1),
|
|
133030
133240
|
revision: external_exports.literal(1),
|
|
@@ -133877,7 +134087,7 @@ async function publishPalActivityOnce(options, id3, input2) {
|
|
|
133877
134087
|
__name(publishPalActivityOnce, "publishPalActivityOnce");
|
|
133878
134088
|
|
|
133879
134089
|
// ../sdk/dist/pals/activity/causality.js
|
|
133880
|
-
import { createHash as
|
|
134090
|
+
import { createHash as createHash46 } from "node:crypto";
|
|
133881
134091
|
import { isDeepStrictEqual as isDeepStrictEqual17 } from "node:util";
|
|
133882
134092
|
var requestMarkerSchema = external_exports.object({
|
|
133883
134093
|
type: external_exports.literal("request_envelope"),
|
|
@@ -133956,7 +134166,7 @@ function createPalActivityCausalityResolver(options) {
|
|
|
133956
134166
|
const root = entries2[0]?.record;
|
|
133957
134167
|
if (root?.type !== "session_started" || root.parent || root.forkedFrom || root.tenantId !== scope.tenantId || root.projectId !== scope.projectId || root.cwd !== workspace || root.origin?.protocol !== "desktop" || root.origin.externalSessionId !== JSON.stringify(["namzu-pal", scope.palId, scope.profileRevision, scope.sessionId]))
|
|
133958
134168
|
unavailable3();
|
|
133959
|
-
const scopeHash =
|
|
134169
|
+
const scopeHash = createHash46("sha256").update(JSON.stringify([
|
|
133960
134170
|
"pal-activity/1",
|
|
133961
134171
|
scope.tenantId,
|
|
133962
134172
|
scope.projectId,
|
|
@@ -136287,7 +136497,7 @@ ${observed}
|
|
|
136287
136497
|
});
|
|
136288
136498
|
|
|
136289
136499
|
// ../sdk/dist/tools/builtins/skill.js
|
|
136290
|
-
import { createHash as
|
|
136500
|
+
import { createHash as createHash47 } from "node:crypto";
|
|
136291
136501
|
var inputSchema16 = external_exports.object({
|
|
136292
136502
|
name: external_exports.string().min(1).optional().describe("The skill to load, exactly as listed in the available-skills manifest. Omit it to list model-invocable skills."),
|
|
136293
136503
|
args: external_exports.string().max(8e3).optional().describe("What to apply the skill to, in your own words. A skill that runs as a delegated agent sees only this and its own instructions, so say what it needs. Omit it on a continuation."),
|
|
@@ -136298,7 +136508,7 @@ var LIST_CURSOR_PATTERN = /^v1\.list\.(0|[1-9][0-9]*)\.([01])\.([A-Za-z0-9_-]{43
|
|
|
136298
136508
|
var MAX_SKILLS_PER_PAGE = 20;
|
|
136299
136509
|
var OVERSIZED_CATALOG_WARNING = "Some skills were omitted because their metadata is too large for this response budget.";
|
|
136300
136510
|
function snapshotDigest(snapshot) {
|
|
136301
|
-
return
|
|
136511
|
+
return createHash47("sha256").update(JSON.stringify({
|
|
136302
136512
|
version: 1,
|
|
136303
136513
|
name: snapshot.name,
|
|
136304
136514
|
body: snapshot.body,
|
|
@@ -136342,7 +136552,7 @@ function activeOutputCap(maxChars2) {
|
|
|
136342
136552
|
}
|
|
136343
136553
|
__name(activeOutputCap, "activeOutputCap");
|
|
136344
136554
|
function listDigest(skills, maxChars2) {
|
|
136345
|
-
return
|
|
136555
|
+
return createHash47("sha256").update(JSON.stringify({ version: 1, kind: "list", maxChars: maxChars2 ?? null, skills })).digest("base64url");
|
|
136346
136556
|
}
|
|
136347
136557
|
__name(listDigest, "listDigest");
|
|
136348
136558
|
function serializeListPage(page) {
|
|
@@ -142355,6 +142565,7 @@ export {
|
|
|
142355
142565
|
calculateCost,
|
|
142356
142566
|
accumulateCost,
|
|
142357
142567
|
accumulateUnpricedCost,
|
|
142568
|
+
accumulateReportedCost,
|
|
142358
142569
|
formatCost,
|
|
142359
142570
|
describeCost,
|
|
142360
142571
|
ONE_MILLION_WINDOW_TOKENS,
|
|
@@ -142741,6 +142952,9 @@ export {
|
|
|
142741
142952
|
MEMORY_VERIFY_NOTICE,
|
|
142742
142953
|
recalledMemoryIds,
|
|
142743
142954
|
createMemoryRecallStep,
|
|
142955
|
+
SIDE_REQUEST_REASONING_HEADROOM,
|
|
142956
|
+
sideRequestReasoning,
|
|
142957
|
+
chatStreamForSideRequest,
|
|
142744
142958
|
findRetainedIndices,
|
|
142745
142959
|
snapshotRequestContext,
|
|
142746
142960
|
diffRequestContext,
|
|
@@ -143560,4 +143774,4 @@ export {
|
|
|
143560
143774
|
WakeBudget,
|
|
143561
143775
|
wakeBudgetFromEnv
|
|
143562
143776
|
};
|
|
143563
|
-
//# sourceMappingURL=chunk-
|
|
143777
|
+
//# sourceMappingURL=chunk-BULDCXFX.js.map
|