@theokit/sdk 5.15.0 → 5.15.2
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 +18 -0
- package/dist/a2a/index.cjs +3 -3
- package/dist/a2a/index.js +1 -1
- package/dist/{agent-B6FQad6P.d.cts → agent-BL4kxgwq.d.cts} +7 -1
- package/dist/{agent-B6C9i_qu.d.ts → agent-ByDx7K30.d.ts} +7 -1
- package/dist/agent-D6WBBNGR.cjs +72 -0
- package/dist/{agent-VI2HITPT.cjs.map → agent-D6WBBNGR.cjs.map} +1 -1
- package/dist/agent-QRIFX2SY.js +63 -0
- package/dist/{agent-DRDGUU6T.js.map → agent-QRIFX2SY.js.map} +1 -1
- package/dist/agent-session-store-2LQEPS4H.js +6 -0
- package/dist/{agent-session-store-22GKA7O4.js.map → agent-session-store-2LQEPS4H.js.map} +1 -1
- package/dist/agent-session-store-IOH6BREF.cjs +23 -0
- package/dist/{agent-session-store-WP6NGDVX.cjs.map → agent-session-store-IOH6BREF.cjs.map} +1 -1
- package/dist/auth/index.cjs +15 -15
- package/dist/auth/index.js +3 -3
- package/dist/{batch-N2XDYZED.js → batch-7IGV2OKA.js} +8 -8
- package/dist/{batch-N2XDYZED.js.map → batch-7IGV2OKA.js.map} +1 -1
- package/dist/{batch-VFR2MAUE.cjs → batch-FIWQZ3JD.cjs} +14 -14
- package/dist/{batch-VFR2MAUE.cjs.map → batch-FIWQZ3JD.cjs.map} +1 -1
- package/dist/{chunk-AT2PESXB.cjs → chunk-2UYAL4N7.cjs} +5 -5
- package/dist/chunk-2UYAL4N7.cjs.map +1 -0
- package/dist/{chunk-K2BQQ445.js → chunk-3GQYMKVJ.js} +3 -3
- package/dist/{chunk-K2BQQ445.js.map → chunk-3GQYMKVJ.js.map} +1 -1
- package/dist/{chunk-YSTXFWQE.cjs → chunk-3HL43XBD.cjs} +4 -4
- package/dist/{chunk-YSTXFWQE.cjs.map → chunk-3HL43XBD.cjs.map} +1 -1
- package/dist/{chunk-XESYJ4JC.js → chunk-3VX7JHJI.js} +7 -7
- package/dist/{chunk-XESYJ4JC.js.map → chunk-3VX7JHJI.js.map} +1 -1
- package/dist/{chunk-6XQLTQB6.cjs → chunk-3YCNBOX7.cjs} +3 -3
- package/dist/{chunk-6XQLTQB6.cjs.map → chunk-3YCNBOX7.cjs.map} +1 -1
- package/dist/{chunk-CHKV2L2Y.cjs → chunk-46YYJIHL.cjs} +30 -30
- package/dist/chunk-46YYJIHL.cjs.map +1 -0
- package/dist/{chunk-73IITAF7.js → chunk-4C37ELQL.js} +9 -9
- package/dist/{chunk-73IITAF7.js.map → chunk-4C37ELQL.js.map} +1 -1
- package/dist/{chunk-AGO5S5WD.js → chunk-4E4D6H77.js} +3 -3
- package/dist/{chunk-AGO5S5WD.js.map → chunk-4E4D6H77.js.map} +1 -1
- package/dist/{chunk-R35ZJAYT.cjs → chunk-4JF52NED.cjs} +12 -12
- package/dist/{chunk-R35ZJAYT.cjs.map → chunk-4JF52NED.cjs.map} +1 -1
- package/dist/{chunk-INVEGVGO.js → chunk-4TA47IK4.js} +8 -8
- package/dist/{chunk-INVEGVGO.js.map → chunk-4TA47IK4.js.map} +1 -1
- package/dist/{chunk-MLGETTYX.js → chunk-4YUIYSZO.js} +6 -6
- package/dist/{chunk-MLGETTYX.js.map → chunk-4YUIYSZO.js.map} +1 -1
- package/dist/{chunk-RZL2W4C3.js → chunk-5L7S2VOL.js} +5 -5
- package/dist/{chunk-RZL2W4C3.js.map → chunk-5L7S2VOL.js.map} +1 -1
- package/dist/{chunk-3WKWBYPO.cjs → chunk-6EHOJLJ3.cjs} +20 -20
- package/dist/chunk-6EHOJLJ3.cjs.map +1 -0
- package/dist/{chunk-XOU3CL7S.cjs → chunk-6HQFPX7N.cjs} +28 -28
- package/dist/chunk-6HQFPX7N.cjs.map +1 -0
- package/dist/{chunk-DJKGDLYZ.cjs → chunk-6XT5LAZG.cjs} +126 -59
- package/dist/chunk-6XT5LAZG.cjs.map +1 -0
- package/dist/{chunk-R427EOZE.cjs → chunk-7EFT6N5C.cjs} +13 -13
- package/dist/{chunk-R427EOZE.cjs.map → chunk-7EFT6N5C.cjs.map} +1 -1
- package/dist/{chunk-L7V4DDIE.cjs → chunk-7VNFOGRD.cjs} +12 -12
- package/dist/chunk-7VNFOGRD.cjs.map +1 -0
- package/dist/{chunk-YKNBTHMD.js → chunk-AQ23NII7.js} +3 -3
- package/dist/{chunk-YKNBTHMD.js.map → chunk-AQ23NII7.js.map} +1 -1
- package/dist/{chunk-ARC2V7NY.js → chunk-ATGSV4GS.js} +4 -4
- package/dist/{chunk-ARC2V7NY.js.map → chunk-ATGSV4GS.js.map} +1 -1
- package/dist/{chunk-H7HD6RXO.cjs → chunk-AW72G4TC.cjs} +5 -5
- package/dist/{chunk-H7HD6RXO.cjs.map → chunk-AW72G4TC.cjs.map} +1 -1
- package/dist/{chunk-M4U24U6G.js → chunk-AZK3QM36.js} +5 -5
- package/dist/{chunk-M4U24U6G.js.map → chunk-AZK3QM36.js.map} +1 -1
- package/dist/{chunk-QK2ERTO3.js → chunk-BH6M2DGV.js} +4 -4
- package/dist/{chunk-QK2ERTO3.js.map → chunk-BH6M2DGV.js.map} +1 -1
- package/dist/{chunk-64ECM3XM.cjs → chunk-BTGYRM4J.cjs} +264 -264
- package/dist/chunk-BTGYRM4J.cjs.map +1 -0
- package/dist/{chunk-5M5GQYBM.js → chunk-CG64VPPU.js} +50 -50
- package/dist/{chunk-5M5GQYBM.js.map → chunk-CG64VPPU.js.map} +1 -1
- package/dist/{chunk-CBBT42VX.js → chunk-CMDM4VF6.js} +3 -3
- package/dist/{chunk-CBBT42VX.js.map → chunk-CMDM4VF6.js.map} +1 -1
- package/dist/{chunk-OLJOI4LK.js → chunk-CN732Z5C.js} +4 -4
- package/dist/{chunk-OLJOI4LK.js.map → chunk-CN732Z5C.js.map} +1 -1
- package/dist/{chunk-SETHRLQS.cjs → chunk-D3BL3EEB.cjs} +9 -9
- package/dist/chunk-D3BL3EEB.cjs.map +1 -0
- package/dist/{chunk-LCCT5ZXJ.js → chunk-DB5RYCXX.js} +13 -13
- package/dist/{chunk-LCCT5ZXJ.js.map → chunk-DB5RYCXX.js.map} +1 -1
- package/dist/{chunk-SV63WTA2.js → chunk-DBH2WA2U.js} +4 -4
- package/dist/{chunk-SV63WTA2.js.map → chunk-DBH2WA2U.js.map} +1 -1
- package/dist/{chunk-XE3CAY6Z.cjs → chunk-DEHPRORL.cjs} +4 -4
- package/dist/{chunk-XE3CAY6Z.cjs.map → chunk-DEHPRORL.cjs.map} +1 -1
- package/dist/{chunk-UKMBRMGT.js → chunk-DGO4LPLP.js} +4 -4
- package/dist/{chunk-UKMBRMGT.js.map → chunk-DGO4LPLP.js.map} +1 -1
- package/dist/{chunk-RS7YQR4X.cjs → chunk-EBX6XUN7.cjs} +7 -7
- package/dist/{chunk-RS7YQR4X.cjs.map → chunk-EBX6XUN7.cjs.map} +1 -1
- package/dist/chunk-EDIYR4VR.cjs +18 -0
- package/dist/{chunk-SPEN7RJU.cjs.map → chunk-EDIYR4VR.cjs.map} +1 -1
- package/dist/{chunk-QGDPMM3C.js → chunk-EF5IONLL.js} +5 -5
- package/dist/{chunk-QGDPMM3C.js.map → chunk-EF5IONLL.js.map} +1 -1
- package/dist/{chunk-MSW7LB2V.cjs → chunk-EOWIUDKG.cjs} +5 -5
- package/dist/{chunk-MSW7LB2V.cjs.map → chunk-EOWIUDKG.cjs.map} +1 -1
- package/dist/{chunk-L7JPXZ2C.cjs → chunk-ER3BF23R.cjs} +19 -19
- package/dist/{chunk-L7JPXZ2C.cjs.map → chunk-ER3BF23R.cjs.map} +1 -1
- package/dist/{chunk-BNEUB52I.cjs → chunk-ERBKPA2N.cjs} +4 -4
- package/dist/{chunk-BNEUB52I.cjs.map → chunk-ERBKPA2N.cjs.map} +1 -1
- package/dist/{chunk-4QCJAJAG.js → chunk-F54PXZIA.js} +5 -5
- package/dist/{chunk-4QCJAJAG.js.map → chunk-F54PXZIA.js.map} +1 -1
- package/dist/{chunk-2XWAYCFM.cjs → chunk-FBT2SF2S.cjs} +12 -12
- package/dist/{chunk-2XWAYCFM.cjs.map → chunk-FBT2SF2S.cjs.map} +1 -1
- package/dist/{chunk-AUH2EVWY.cjs → chunk-FZSPVIFK.cjs} +16 -16
- package/dist/chunk-FZSPVIFK.cjs.map +1 -0
- package/dist/{chunk-CYWOJA6B.js → chunk-GA27FFT5.js} +3 -3
- package/dist/{chunk-CYWOJA6B.js.map → chunk-GA27FFT5.js.map} +1 -1
- package/dist/{chunk-HWMGR3HA.js → chunk-GEQLHBJM.js} +6 -6
- package/dist/{chunk-HWMGR3HA.js.map → chunk-GEQLHBJM.js.map} +1 -1
- package/dist/{chunk-IJ7M6GOG.cjs → chunk-GKERJ52A.cjs} +4 -4
- package/dist/{chunk-IJ7M6GOG.cjs.map → chunk-GKERJ52A.cjs.map} +1 -1
- package/dist/{chunk-NEH3BPFD.cjs → chunk-HI5TJWQE.cjs} +19 -19
- package/dist/{chunk-NEH3BPFD.cjs.map → chunk-HI5TJWQE.cjs.map} +1 -1
- package/dist/{chunk-ZOFRNNZD.cjs → chunk-IZV72OEI.cjs} +11 -11
- package/dist/chunk-IZV72OEI.cjs.map +1 -0
- package/dist/{chunk-KU5O7WPK.js → chunk-JD3EKKKB.js} +4 -4
- package/dist/{chunk-KU5O7WPK.js.map → chunk-JD3EKKKB.js.map} +1 -1
- package/dist/{chunk-DFBWYETS.js → chunk-JRP2W2DR.js} +3 -3
- package/dist/{chunk-DFBWYETS.js.map → chunk-JRP2W2DR.js.map} +1 -1
- package/dist/{chunk-IOBHFP2E.js → chunk-JRQJMZKY.js} +82 -15
- package/dist/chunk-JRQJMZKY.js.map +1 -0
- package/dist/{chunk-YQ3XC6C2.cjs → chunk-JVH3NNJ3.cjs} +13 -13
- package/dist/chunk-JVH3NNJ3.cjs.map +1 -0
- package/dist/{chunk-VWYFGE27.cjs → chunk-KC2HKUPT.cjs} +56 -56
- package/dist/chunk-KC2HKUPT.cjs.map +1 -0
- package/dist/{chunk-PDOXYXWX.cjs → chunk-KDJTECE6.cjs} +4 -4
- package/dist/{chunk-PDOXYXWX.cjs.map → chunk-KDJTECE6.cjs.map} +1 -1
- package/dist/{chunk-QD6B6W6I.js → chunk-L2KC2G7H.js} +5 -5
- package/dist/{chunk-QD6B6W6I.js.map → chunk-L2KC2G7H.js.map} +1 -1
- package/dist/{chunk-3BBTHFGJ.js → chunk-L5B7EWWH.js} +5 -5
- package/dist/{chunk-3BBTHFGJ.js.map → chunk-L5B7EWWH.js.map} +1 -1
- package/dist/{chunk-X7CE7Y5W.js → chunk-LG4JCJEI.js} +11 -11
- package/dist/{chunk-X7CE7Y5W.js.map → chunk-LG4JCJEI.js.map} +1 -1
- package/dist/{chunk-2HXTNVLM.js → chunk-LSURFRJA.js} +6 -6
- package/dist/{chunk-2HXTNVLM.js.map → chunk-LSURFRJA.js.map} +1 -1
- package/dist/{chunk-55LLQFHW.cjs → chunk-MJGY3E3C.cjs} +4 -4
- package/dist/{chunk-55LLQFHW.cjs.map → chunk-MJGY3E3C.cjs.map} +1 -1
- package/dist/{chunk-EQ5IDL6W.cjs → chunk-MKS5FFH5.cjs} +15 -15
- package/dist/chunk-MKS5FFH5.cjs.map +1 -0
- package/dist/{chunk-WM646HEN.js → chunk-MTNCJ7MQ.js} +6 -6
- package/dist/{chunk-WM646HEN.js.map → chunk-MTNCJ7MQ.js.map} +1 -1
- package/dist/{chunk-SA6K24NB.cjs → chunk-MXJJMP4U.cjs} +7 -7
- package/dist/chunk-MXJJMP4U.cjs.map +1 -0
- package/dist/{chunk-FTXY4D44.cjs → chunk-N2ORTDSO.cjs} +20 -20
- package/dist/chunk-N2ORTDSO.cjs.map +1 -0
- package/dist/{chunk-7YUPSBDV.cjs → chunk-NDXZXGVP.cjs} +6 -6
- package/dist/{chunk-7YUPSBDV.cjs.map → chunk-NDXZXGVP.cjs.map} +1 -1
- package/dist/{chunk-3UMPP553.cjs → chunk-NMRNE6QX.cjs} +11 -11
- package/dist/{chunk-3UMPP553.cjs.map → chunk-NMRNE6QX.cjs.map} +1 -1
- package/dist/{chunk-PKRPV3R7.js → chunk-NO6AG22P.js} +6 -6
- package/dist/{chunk-PKRPV3R7.js.map → chunk-NO6AG22P.js.map} +1 -1
- package/dist/{chunk-NK5EOTDY.js → chunk-OIOSY5G6.js} +3 -3
- package/dist/{chunk-NK5EOTDY.js.map → chunk-OIOSY5G6.js.map} +1 -1
- package/dist/{chunk-RGVMJU57.js → chunk-P7B64NFK.js} +8 -8
- package/dist/{chunk-RGVMJU57.js.map → chunk-P7B64NFK.js.map} +1 -1
- package/dist/{chunk-TDED5XES.js → chunk-PCPYTBVV.js} +6 -6
- package/dist/chunk-PCPYTBVV.js.map +1 -0
- package/dist/{chunk-U7PRI3XM.cjs → chunk-PDFSLD5P.cjs} +6 -6
- package/dist/{chunk-U7PRI3XM.cjs.map → chunk-PDFSLD5P.cjs.map} +1 -1
- package/dist/{chunk-YMVTUV5K.js → chunk-PISZRLES.js} +5 -5
- package/dist/{chunk-YMVTUV5K.js.map → chunk-PISZRLES.js.map} +1 -1
- package/dist/{chunk-BUUUWQMB.cjs → chunk-PNL63WDP.cjs} +4 -4
- package/dist/{chunk-BUUUWQMB.cjs.map → chunk-PNL63WDP.cjs.map} +1 -1
- package/dist/{chunk-23SS4ID4.js → chunk-PSMWZYW6.js} +4 -4
- package/dist/{chunk-23SS4ID4.js.map → chunk-PSMWZYW6.js.map} +1 -1
- package/dist/{chunk-5645PMVU.cjs → chunk-PXYINWBC.cjs} +20 -20
- package/dist/chunk-PXYINWBC.cjs.map +1 -0
- package/dist/{chunk-RTDVSHJR.cjs → chunk-Q4UOCMAO.cjs} +5 -5
- package/dist/{chunk-RTDVSHJR.cjs.map → chunk-Q4UOCMAO.cjs.map} +1 -1
- package/dist/{chunk-5IRDK5BC.js → chunk-QH6MWGOA.js} +4 -4
- package/dist/{chunk-5IRDK5BC.js.map → chunk-QH6MWGOA.js.map} +1 -1
- package/dist/{chunk-3LMVJTNJ.js → chunk-QPUKIZOT.js} +3 -3
- package/dist/{chunk-3LMVJTNJ.js.map → chunk-QPUKIZOT.js.map} +1 -1
- package/dist/{chunk-SWALPLFQ.cjs → chunk-RTCO3USA.cjs} +16 -16
- package/dist/chunk-RTCO3USA.cjs.map +1 -0
- package/dist/{chunk-SAGRF4IB.js → chunk-S2CMEJ5F.js} +3 -3
- package/dist/{chunk-SAGRF4IB.js.map → chunk-S2CMEJ5F.js.map} +1 -1
- package/dist/{chunk-VZGE7NAI.js → chunk-S5ERB3CH.js} +3 -3
- package/dist/{chunk-VZGE7NAI.js.map → chunk-S5ERB3CH.js.map} +1 -1
- package/dist/{chunk-XJ3WU5CZ.js → chunk-S7IZEVXX.js} +6 -6
- package/dist/{chunk-XJ3WU5CZ.js.map → chunk-S7IZEVXX.js.map} +1 -1
- package/dist/{chunk-Q7UG242V.js → chunk-TIYQDJFK.js} +3 -3
- package/dist/{chunk-Q7UG242V.js.map → chunk-TIYQDJFK.js.map} +1 -1
- package/dist/{chunk-POBZXULR.cjs → chunk-TTNJOM5W.cjs} +16 -16
- package/dist/{chunk-POBZXULR.cjs.map → chunk-TTNJOM5W.cjs.map} +1 -1
- package/dist/{chunk-VCQ37TC5.js → chunk-TTXRNCXY.js} +3 -3
- package/dist/{chunk-VCQ37TC5.js.map → chunk-TTXRNCXY.js.map} +1 -1
- package/dist/{chunk-3HA7N2BB.cjs → chunk-TYKBAKAS.cjs} +5 -5
- package/dist/{chunk-3HA7N2BB.cjs.map → chunk-TYKBAKAS.cjs.map} +1 -1
- package/dist/{chunk-A77UMVMD.cjs → chunk-UMCCYXFZ.cjs} +8 -8
- package/dist/{chunk-A77UMVMD.cjs.map → chunk-UMCCYXFZ.cjs.map} +1 -1
- package/dist/{chunk-3GTN4HOO.js → chunk-UNP4NCMZ.js} +3 -3
- package/dist/{chunk-3GTN4HOO.js.map → chunk-UNP4NCMZ.js.map} +1 -1
- package/dist/{chunk-BPL5CVZ5.js → chunk-VFT63FJF.js} +3 -3
- package/dist/{chunk-BPL5CVZ5.js.map → chunk-VFT63FJF.js.map} +1 -1
- package/dist/{chunk-3KIUY67P.cjs → chunk-VHY6NVCJ.cjs} +30 -30
- package/dist/chunk-VHY6NVCJ.cjs.map +1 -0
- package/dist/{chunk-KMFBNKCT.cjs → chunk-VT3NWHFH.cjs} +6 -6
- package/dist/{chunk-KMFBNKCT.cjs.map → chunk-VT3NWHFH.cjs.map} +1 -1
- package/dist/{chunk-FJWQP6EE.js → chunk-WJ6OGKAO.js} +3 -3
- package/dist/{chunk-FJWQP6EE.js.map → chunk-WJ6OGKAO.js.map} +1 -1
- package/dist/{chunk-FLDHYF5C.cjs → chunk-X2XLSE2N.cjs} +9 -9
- package/dist/chunk-X2XLSE2N.cjs.map +1 -0
- package/dist/{chunk-UDAKAE4Z.cjs → chunk-X4ZYEZPD.cjs} +12 -12
- package/dist/chunk-X4ZYEZPD.cjs.map +1 -0
- package/dist/{chunk-QG4SXZ2A.cjs → chunk-XR6O6G3B.cjs} +27 -27
- package/dist/chunk-XR6O6G3B.cjs.map +1 -0
- package/dist/{chunk-BWYC7RZG.cjs → chunk-XTQWTVVI.cjs} +11 -11
- package/dist/chunk-XTQWTVVI.cjs.map +1 -0
- package/dist/{chunk-MLJDW2YK.js → chunk-YSGS57DA.js} +4 -4
- package/dist/{chunk-MLJDW2YK.js.map → chunk-YSGS57DA.js.map} +1 -1
- package/dist/{chunk-KCM3RMKR.js → chunk-YUQNHLKN.js} +8 -8
- package/dist/{chunk-KCM3RMKR.js.map → chunk-YUQNHLKN.js.map} +1 -1
- package/dist/{chunk-P7QYG4RZ.cjs → chunk-Z5MB2HAN.cjs} +8 -8
- package/dist/{chunk-P7QYG4RZ.cjs.map → chunk-Z5MB2HAN.cjs.map} +1 -1
- package/dist/{chunk-HJ2LV464.js → chunk-ZUWVO442.js} +4 -4
- package/dist/{chunk-HJ2LV464.js.map → chunk-ZUWVO442.js.map} +1 -1
- package/dist/{compact-session-NX7HUNTB.cjs → compact-session-5DWFHMW4.cjs} +21 -21
- package/dist/{compact-session-NX7HUNTB.cjs.map → compact-session-5DWFHMW4.cjs.map} +1 -1
- package/dist/{compact-session-Q5IGNFPW.js → compact-session-AL65PEMX.js} +12 -12
- package/dist/{compact-session-Q5IGNFPW.js.map → compact-session-AL65PEMX.js.map} +1 -1
- package/dist/context/index.cjs +11 -11
- package/dist/context/index.js +6 -6
- package/dist/context-4XSD2V3G.js +7 -0
- package/dist/{context-7EBZST3L.js.map → context-4XSD2V3G.js.map} +1 -1
- package/dist/context-ZX2VBGSX.cjs +24 -0
- package/dist/{context-4RSI3AXT.cjs.map → context-ZX2VBGSX.cjs.map} +1 -1
- package/dist/{cron-Bh3aWgQ2.d.cts → cron-B7KH9sHW.d.cts} +1 -1
- package/dist/{cron-CCDxeeFZ.d.ts → cron-FEO7UAQF.d.ts} +1 -1
- package/dist/cron.cjs +40 -40
- package/dist/cron.d.cts +2 -2
- package/dist/cron.d.ts +2 -2
- package/dist/cron.js +39 -39
- package/dist/eval.cjs +51 -51
- package/dist/eval.cjs.map +1 -1
- package/dist/eval.js +41 -41
- package/dist/{executor-THUXNAFR.js → executor-ZHIUSHRV.js} +7 -7
- package/dist/{executor-THUXNAFR.js.map → executor-ZHIUSHRV.js.map} +1 -1
- package/dist/{executor-5QL5AXIZ.cjs → executor-ZTLJZ5LK.cjs} +24 -24
- package/dist/{executor-5QL5AXIZ.cjs.map → executor-ZTLJZ5LK.cjs.map} +1 -1
- package/dist/filesystem/index.cjs +14 -14
- package/dist/filesystem/index.cjs.map +1 -1
- package/dist/filesystem/index.js +4 -4
- package/dist/{fork-agent-S2EPIML7.js → fork-agent-BHVTALT5.js} +3 -3
- package/dist/{fork-agent-S2EPIML7.js.map → fork-agent-BHVTALT5.js.map} +1 -1
- package/dist/{fork-agent-WAEQI2DL.cjs → fork-agent-DCOPPXM2.cjs} +4 -4
- package/dist/{fork-agent-WAEQI2DL.cjs.map → fork-agent-DCOPPXM2.cjs.map} +1 -1
- package/dist/fs-session-store-EZ32TFGB.js +11 -0
- package/dist/{fs-session-store-MYQEVUFL.js.map → fs-session-store-EZ32TFGB.js.map} +1 -1
- package/dist/fs-session-store-G664LDDN.cjs +20 -0
- package/dist/{fs-session-store-CYNTEPJZ.cjs.map → fs-session-store-G664LDDN.cjs.map} +1 -1
- package/dist/generate-object-JFZTK567.cjs +20 -0
- package/dist/{generate-object-A5F576IT.cjs.map → generate-object-JFZTK567.cjs.map} +1 -1
- package/dist/{generate-object-TBDOBBYW.js → generate-object-RPBXY2U3.js} +4 -4
- package/dist/{generate-object-TBDOBBYW.js.map → generate-object-RPBXY2U3.js.map} +1 -1
- package/dist/index-manager-2MJEEN2O.js +18 -0
- package/dist/{index-manager-NF2WRLOU.js.map → index-manager-2MJEEN2O.js.map} +1 -1
- package/dist/index-manager-CT6MMG7S.cjs +27 -0
- package/dist/{index-manager-2KH75BRW.cjs.map → index-manager-CT6MMG7S.cjs.map} +1 -1
- package/dist/index.cjs +130 -130
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +3 -3
- package/dist/index.d.ts +3 -3
- package/dist/index.js +56 -56
- package/dist/{inject-session-4ROYLZHY.js → inject-session-E2SZ4A35.js} +6 -6
- package/dist/{inject-session-4ROYLZHY.js.map → inject-session-E2SZ4A35.js.map} +1 -1
- package/dist/{inject-session-AWKDCGHV.cjs → inject-session-QZULG65O.cjs} +8 -8
- package/dist/{inject-session-AWKDCGHV.cjs.map → inject-session-QZULG65O.cjs.map} +1 -1
- package/dist/internal/llm/hermes-tool-extract.d.ts +2 -0
- package/dist/internal/memory/adapters/index.cjs +4 -4
- package/dist/internal/memory/adapters/index.js +3 -3
- package/dist/internal/memory/storage/index.cjs +45 -45
- package/dist/internal/memory/storage/index.js +9 -9
- package/dist/internal/persistence/index.cjs +22 -22
- package/dist/internal/persistence/index.js +6 -6
- package/dist/internal/security/index.cjs +9 -9
- package/dist/internal/security/index.js +2 -2
- package/dist/mcp-auth.cjs +8 -8
- package/dist/mcp-auth.js +3 -3
- package/dist/models.cjs +30 -30
- package/dist/models.cjs.map +1 -1
- package/dist/models.js +8 -8
- package/dist/{oauth-transaction-store-U34YLEGP.js → oauth-transaction-store-QQBWGNE2.js} +3 -3
- package/dist/{oauth-transaction-store-U34YLEGP.js.map → oauth-transaction-store-QQBWGNE2.js.map} +1 -1
- package/dist/{oauth-transaction-store-OMX436YB.cjs → oauth-transaction-store-YF7WOA6B.cjs} +10 -10
- package/dist/{oauth-transaction-store-OMX436YB.cjs.map → oauth-transaction-store-YF7WOA6B.cjs.map} +1 -1
- package/dist/path-safety.cjs +9 -9
- package/dist/path-safety.js +2 -2
- package/dist/persistence.cjs +41 -41
- package/dist/persistence.cjs.map +1 -1
- package/dist/persistence.js +11 -11
- package/dist/project.cjs +7 -7
- package/dist/project.cjs.map +1 -1
- package/dist/project.js +4 -4
- package/dist/providers.cjs +6 -6
- package/dist/providers.js +4 -4
- package/dist/{registry-5TDAF7RK.js → registry-DOYBR237.js} +6 -6
- package/dist/{registry-5TDAF7RK.js.map → registry-DOYBR237.js.map} +1 -1
- package/dist/{registry-W7TSCLQO.cjs → registry-PB7JFVUJ.cjs} +14 -14
- package/dist/{registry-W7TSCLQO.cjs.map → registry-PB7JFVUJ.cjs.map} +1 -1
- package/dist/sandbox/index.cjs +41 -41
- package/dist/sandbox/index.cjs.map +1 -1
- package/dist/sandbox/index.js +7 -7
- package/dist/sanitize/index.cjs +2 -2
- package/dist/sanitize/index.js +1 -1
- package/dist/server/auth/index.cjs +9 -9
- package/dist/server/auth/index.cjs.map +1 -1
- package/dist/server/auth/index.js +4 -4
- package/dist/{session-transcript-7TZ6HXSX.cjs → session-transcript-EBVGLZ6B.cjs} +17 -17
- package/dist/{session-transcript-7TZ6HXSX.cjs.map → session-transcript-EBVGLZ6B.cjs.map} +1 -1
- package/dist/{session-transcript-BSHZYYY6.js → session-transcript-GU2VE7JX.js} +4 -4
- package/dist/{session-transcript-BSHZYYY6.js.map → session-transcript-GU2VE7JX.js.map} +1 -1
- package/dist/skills.cjs +7 -7
- package/dist/skills.js +4 -4
- package/dist/stream-object-3AU7QDHT.js +7 -0
- package/dist/{stream-object-EKM4WGTI.js.map → stream-object-3AU7QDHT.js.map} +1 -1
- package/dist/stream-object-SLGR2KIA.cjs +20 -0
- package/dist/{stream-object-AS4YYM4B.cjs.map → stream-object-SLGR2KIA.cjs.map} +1 -1
- package/dist/subagents-loader-4PQS7ULK.cjs +16 -0
- package/dist/{subagents-loader-KLWF4QPD.cjs.map → subagents-loader-4PQS7ULK.cjs.map} +1 -1
- package/dist/subagents-loader-CPFVLWLH.js +7 -0
- package/dist/{subagents-loader-SXETS2F2.js.map → subagents-loader-CPFVLWLH.js.map} +1 -1
- package/dist/subagents-loader.cjs +4 -4
- package/dist/subagents-loader.d.cts +1 -1
- package/dist/subagents-loader.d.ts +1 -1
- package/dist/subagents-loader.js +3 -3
- package/dist/subagents.cjs +2 -2
- package/dist/subagents.js +1 -1
- package/dist/task-store.cjs +5 -5
- package/dist/task-store.js +2 -2
- package/dist/types/hooks.d.ts +7 -1
- package/dist/workflow.cjs +28 -28
- package/dist/workflow.js +5 -5
- package/package.json +1 -1
- package/dist/agent-DRDGUU6T.js +0 -63
- package/dist/agent-VI2HITPT.cjs +0 -72
- package/dist/agent-session-store-22GKA7O4.js +0 -6
- package/dist/agent-session-store-WP6NGDVX.cjs +0 -23
- package/dist/chunk-3KIUY67P.cjs.map +0 -1
- package/dist/chunk-3WKWBYPO.cjs.map +0 -1
- package/dist/chunk-5645PMVU.cjs.map +0 -1
- package/dist/chunk-64ECM3XM.cjs.map +0 -1
- package/dist/chunk-AT2PESXB.cjs.map +0 -1
- package/dist/chunk-AUH2EVWY.cjs.map +0 -1
- package/dist/chunk-BWYC7RZG.cjs.map +0 -1
- package/dist/chunk-CHKV2L2Y.cjs.map +0 -1
- package/dist/chunk-DJKGDLYZ.cjs.map +0 -1
- package/dist/chunk-EQ5IDL6W.cjs.map +0 -1
- package/dist/chunk-FLDHYF5C.cjs.map +0 -1
- package/dist/chunk-FTXY4D44.cjs.map +0 -1
- package/dist/chunk-IOBHFP2E.js.map +0 -1
- package/dist/chunk-L7V4DDIE.cjs.map +0 -1
- package/dist/chunk-QG4SXZ2A.cjs.map +0 -1
- package/dist/chunk-SA6K24NB.cjs.map +0 -1
- package/dist/chunk-SETHRLQS.cjs.map +0 -1
- package/dist/chunk-SPEN7RJU.cjs +0 -18
- package/dist/chunk-SWALPLFQ.cjs.map +0 -1
- package/dist/chunk-TDED5XES.js.map +0 -1
- package/dist/chunk-UDAKAE4Z.cjs.map +0 -1
- package/dist/chunk-VWYFGE27.cjs.map +0 -1
- package/dist/chunk-XOU3CL7S.cjs.map +0 -1
- package/dist/chunk-YQ3XC6C2.cjs.map +0 -1
- package/dist/chunk-ZOFRNNZD.cjs.map +0 -1
- package/dist/context-4RSI3AXT.cjs +0 -24
- package/dist/context-7EBZST3L.js +0 -7
- package/dist/fs-session-store-CYNTEPJZ.cjs +0 -20
- package/dist/fs-session-store-MYQEVUFL.js +0 -11
- package/dist/generate-object-A5F576IT.cjs +0 -20
- package/dist/index-manager-2KH75BRW.cjs +0 -27
- package/dist/index-manager-NF2WRLOU.js +0 -18
- package/dist/stream-object-AS4YYM4B.cjs +0 -20
- package/dist/stream-object-EKM4WGTI.js +0 -7
- package/dist/subagents-loader-KLWF4QPD.cjs +0 -16
- package/dist/subagents-loader-SXETS2F2.js +0 -7
|
@@ -1,30 +1,30 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var chunkMJGY3E3C_cjs = require('./chunk-MJGY3E3C.cjs');
|
|
4
4
|
var chunkYJNYDJ2T_cjs = require('./chunk-YJNYDJ2T.cjs');
|
|
5
5
|
var chunk3F53FLQ7_cjs = require('./chunk-3F53FLQ7.cjs');
|
|
6
6
|
var chunkQOGNZMHD_cjs = require('./chunk-QOGNZMHD.cjs');
|
|
7
|
-
var
|
|
7
|
+
var chunk3HL43XBD_cjs = require('./chunk-3HL43XBD.cjs');
|
|
8
8
|
var chunkFRITRLZQ_cjs = require('./chunk-FRITRLZQ.cjs');
|
|
9
|
-
var
|
|
9
|
+
var chunk6EHOJLJ3_cjs = require('./chunk-6EHOJLJ3.cjs');
|
|
10
10
|
var chunkKX5QXLBS_cjs = require('./chunk-KX5QXLBS.cjs');
|
|
11
11
|
var chunk3EE6LVWT_cjs = require('./chunk-3EE6LVWT.cjs');
|
|
12
|
-
var
|
|
12
|
+
var chunkZ5MB2HAN_cjs = require('./chunk-Z5MB2HAN.cjs');
|
|
13
13
|
var chunkNVXXWAU7_cjs = require('./chunk-NVXXWAU7.cjs');
|
|
14
|
-
var
|
|
14
|
+
var chunkPXYINWBC_cjs = require('./chunk-PXYINWBC.cjs');
|
|
15
15
|
var chunkEHD25JBZ_cjs = require('./chunk-EHD25JBZ.cjs');
|
|
16
16
|
var chunkCEGU5AVD_cjs = require('./chunk-CEGU5AVD.cjs');
|
|
17
17
|
var chunkRNXXYF22_cjs = require('./chunk-RNXXYF22.cjs');
|
|
18
|
-
var
|
|
19
|
-
var promises = require('fs/promises');
|
|
20
|
-
var
|
|
21
|
-
var
|
|
22
|
-
var
|
|
23
|
-
var
|
|
18
|
+
var node_fs = require('node:fs');
|
|
19
|
+
var promises = require('node:fs/promises');
|
|
20
|
+
var node_os = require('node:os');
|
|
21
|
+
var node_path = require('node:path');
|
|
22
|
+
var node_url = require('node:url');
|
|
23
|
+
var node_module = require('node:module');
|
|
24
24
|
|
|
25
25
|
var _documentCurrentScript = typeof document !== 'undefined' ? document.currentScript : null;
|
|
26
26
|
function trustFilePath() {
|
|
27
|
-
return
|
|
27
|
+
return node_path.join(node_os.homedir(), ".theokit", "plugins", "trusted-providers.json");
|
|
28
28
|
}
|
|
29
29
|
function readTrustedNames() {
|
|
30
30
|
const trusted = new Set(readTrustArray(trustFilePath(), PROVIDER_TRUST));
|
|
@@ -39,10 +39,10 @@ var PROVIDER_TRUST = {
|
|
|
39
39
|
entries: "plugin-name strings"
|
|
40
40
|
};
|
|
41
41
|
function readTrustArray(path, shape) {
|
|
42
|
-
if (!
|
|
42
|
+
if (!node_fs.existsSync(path)) return [];
|
|
43
43
|
let parsed;
|
|
44
44
|
try {
|
|
45
|
-
parsed = JSON.parse(
|
|
45
|
+
parsed = JSON.parse(node_fs.readFileSync(path, "utf-8"));
|
|
46
46
|
} catch {
|
|
47
47
|
chunkRNXXYF22_cjs.diag(
|
|
48
48
|
`[theokit-sdk] WARN: ${path} is not valid JSON \u2014 trusting NO ${shape.subject} (fail-closed)
|
|
@@ -76,11 +76,11 @@ var discoveryState = chunkNVXXWAU7_cjs.globalSingleton("theokit-sdk.providers.di
|
|
|
76
76
|
warned: /* @__PURE__ */ new Set()
|
|
77
77
|
}));
|
|
78
78
|
function pluginsRoot() {
|
|
79
|
-
return
|
|
79
|
+
return node_path.join(node_os.homedir(), ".theokit", "plugins", "model-providers");
|
|
80
80
|
}
|
|
81
81
|
async function discoverProviderPlugins() {
|
|
82
82
|
const root = pluginsRoot();
|
|
83
|
-
if (!
|
|
83
|
+
if (!node_fs.existsSync(root)) return;
|
|
84
84
|
let entries;
|
|
85
85
|
try {
|
|
86
86
|
entries = await promises.readdir(root);
|
|
@@ -95,7 +95,7 @@ async function discoverProviderPlugins() {
|
|
|
95
95
|
continue;
|
|
96
96
|
}
|
|
97
97
|
discoveryState.loaded.add(entry);
|
|
98
|
-
await loadOne(
|
|
98
|
+
await loadOne(node_path.join(root, entry), entry);
|
|
99
99
|
}
|
|
100
100
|
}
|
|
101
101
|
function warnUntrusted(entry) {
|
|
@@ -108,15 +108,15 @@ function warnUntrusted(entry) {
|
|
|
108
108
|
}
|
|
109
109
|
async function loadOne(dir, entryName) {
|
|
110
110
|
for (const ext of ["index.mjs", "index.js"]) {
|
|
111
|
-
const indexPath =
|
|
112
|
-
if (!
|
|
111
|
+
const indexPath = node_path.join(dir, ext);
|
|
112
|
+
if (!node_fs.existsSync(indexPath)) continue;
|
|
113
113
|
try {
|
|
114
|
-
const mod = await import(
|
|
114
|
+
const mod = await import(node_url.pathToFileURL(indexPath).href);
|
|
115
115
|
const plugin = mod.default ?? mod[entryName] ?? mod;
|
|
116
116
|
if (plugin !== null && typeof plugin === "object" && plugin.kind === "model-provider") {
|
|
117
117
|
const profile = plugin.profile;
|
|
118
118
|
if (profile !== void 0 && typeof profile === "object") {
|
|
119
|
-
|
|
119
|
+
chunkZ5MB2HAN_cjs.registerProvider(profile);
|
|
120
120
|
}
|
|
121
121
|
}
|
|
122
122
|
return;
|
|
@@ -196,8 +196,8 @@ function parseToolArguments(buffered) {
|
|
|
196
196
|
try {
|
|
197
197
|
return JSON.parse(buffered);
|
|
198
198
|
} catch {
|
|
199
|
-
const repaired =
|
|
200
|
-
if (
|
|
199
|
+
const repaired = chunk3HL43XBD_cjs.tryJson(buffered, true);
|
|
200
|
+
if (chunk3HL43XBD_cjs.isPlainObject(repaired)) return repaired;
|
|
201
201
|
return { raw: buffered };
|
|
202
202
|
}
|
|
203
203
|
}
|
|
@@ -814,7 +814,7 @@ async function resolveBedrockToken(region) {
|
|
|
814
814
|
return cachedToken.value;
|
|
815
815
|
}
|
|
816
816
|
try {
|
|
817
|
-
const r =
|
|
817
|
+
const r = node_module.createRequire((typeof document === 'undefined' ? require('u' + 'rl').pathToFileURL(__filename).href : (_documentCurrentScript && _documentCurrentScript.tagName.toUpperCase() === 'SCRIPT' && _documentCurrentScript.src || new URL('chunk-6XT5LAZG.cjs', document.baseURI).href)));
|
|
818
818
|
const gen = r("@aws/bedrock-token-generator");
|
|
819
819
|
if (typeof gen.getToken !== "function") return void 0;
|
|
820
820
|
const providers = r("@aws-sdk/credential-providers");
|
|
@@ -848,10 +848,10 @@ var BedrockAnthropicClient = class {
|
|
|
848
848
|
);
|
|
849
849
|
}
|
|
850
850
|
async *stream(request, signal) {
|
|
851
|
-
const region =
|
|
851
|
+
const region = chunkZ5MB2HAN_cjs.inferRegionFromModelId(request.model) ?? process.env.AWS_REGION ?? "us-east-1";
|
|
852
852
|
const token = await this.resolveTokenOrThrow(region);
|
|
853
|
-
const bareModel =
|
|
854
|
-
const baseUrl = this.options.baseUrl ??
|
|
853
|
+
const bareModel = chunkZ5MB2HAN_cjs.stripBedrockPrefix(request.model);
|
|
854
|
+
const baseUrl = this.options.baseUrl ?? chunkZ5MB2HAN_cjs.resolveBedrockBaseUrl(request.model);
|
|
855
855
|
const endpoint = `/model/${encodeURIComponent(bareModel)}/invoke`;
|
|
856
856
|
const url = `${baseUrl}${endpoint}`;
|
|
857
857
|
const response = await postAnthropicRequest({
|
|
@@ -1542,16 +1542,38 @@ function pickString(record, key) {
|
|
|
1542
1542
|
// src/internal/llm/hermes-tool-extract.ts
|
|
1543
1543
|
var HERMES_BLOCK = /<function=\s*([^>\s]+)\s*>([\s\S]*?)<\/tool_call>/g;
|
|
1544
1544
|
var HERMES_PARAM = /<parameter=\s*([^>\s]+)\s*>([\s\S]*?)<\/parameter>/g;
|
|
1545
|
+
var CTRL_CALL_SRC = String.raw`print\(\s*default_api\.([A-Za-z_]\w*)\(([\s\S]*?)\)\s*\)(?=\s*(?:print\(\s*default_api\.|<ctrl\d+>|$))`;
|
|
1546
|
+
var CTRL_BLOCK = new RegExp(`<ctrl42>call\\s*((?:${CTRL_CALL_SRC}\\s*)+)(?=<ctrl\\d+>|$)`, "g");
|
|
1547
|
+
var CTRL_MARKER = "<ctrl42>call";
|
|
1548
|
+
var CTRL_PREFIX = "print(default_api.";
|
|
1545
1549
|
function extractHermesToolCalls(content, makeId, allowedToolNames) {
|
|
1546
1550
|
const isPromoted = (name) => name.length > 0 && (allowedToolNames === void 0 || allowedToolNames.has(name));
|
|
1547
1551
|
const toolCalls = [];
|
|
1548
1552
|
const droppedNames = [];
|
|
1553
|
+
const formats = /* @__PURE__ */ new Set();
|
|
1554
|
+
for (const block of content.matchAll(CTRL_BLOCK)) {
|
|
1555
|
+
for (const call of (block[1] ?? "").matchAll(new RegExp(CTRL_CALL_SRC, "g"))) {
|
|
1556
|
+
const name = call[1] ?? "";
|
|
1557
|
+
if (!isPromoted(name)) {
|
|
1558
|
+
if (allowedToolNames !== void 0) droppedNames.push(name);
|
|
1559
|
+
continue;
|
|
1560
|
+
}
|
|
1561
|
+
toolCalls.push({
|
|
1562
|
+
type: "tool_use",
|
|
1563
|
+
id: makeId(),
|
|
1564
|
+
name,
|
|
1565
|
+
input: parseCtrlArgs(call[2] ?? "")
|
|
1566
|
+
});
|
|
1567
|
+
formats.add("gemini-ctrl42");
|
|
1568
|
+
}
|
|
1569
|
+
}
|
|
1549
1570
|
for (const block of content.matchAll(HERMES_BLOCK)) {
|
|
1550
1571
|
const name = (block[1] ?? "").trim();
|
|
1551
1572
|
if (!isPromoted(name)) {
|
|
1552
1573
|
if (name.length > 0 && allowedToolNames !== void 0) droppedNames.push(name);
|
|
1553
1574
|
continue;
|
|
1554
1575
|
}
|
|
1576
|
+
formats.add("hermes");
|
|
1555
1577
|
toolCalls.push({
|
|
1556
1578
|
type: "tool_use",
|
|
1557
1579
|
id: makeId(),
|
|
@@ -1560,10 +1582,37 @@ function extractHermesToolCalls(content, makeId, allowedToolNames) {
|
|
|
1560
1582
|
});
|
|
1561
1583
|
}
|
|
1562
1584
|
const residualText = toolCalls.length === 0 ? content : content.replace(
|
|
1585
|
+
CTRL_BLOCK,
|
|
1586
|
+
(_full, calls) => keepUnpromotedCtrl(calls, isPromoted)
|
|
1587
|
+
).replace(
|
|
1563
1588
|
HERMES_BLOCK,
|
|
1564
1589
|
(full, rawName) => isPromoted((rawName ?? "").trim()) ? "" : full
|
|
1565
1590
|
).trim();
|
|
1566
|
-
return { toolCalls, residualText, droppedNames };
|
|
1591
|
+
return { toolCalls, residualText, droppedNames, formats: [...formats] };
|
|
1592
|
+
}
|
|
1593
|
+
function keepUnpromotedCtrl(calls, isPromoted) {
|
|
1594
|
+
const kept = [...calls.matchAll(new RegExp(CTRL_CALL_SRC, "g"))].filter((c) => !isPromoted(c[1] ?? "")).map((c) => c[0]);
|
|
1595
|
+
return kept.length === 0 ? "" : `<ctrl42>call
|
|
1596
|
+
${kept.join("\n")}`;
|
|
1597
|
+
}
|
|
1598
|
+
var CTRL_ARG = /\s*([A-Za-z_]\w*)\s*=\s*("(?:[^"\\]|\\.)*"|'(?:[^'\\]|\\.)*'|[^,]+)\s*(?:,|$)/y;
|
|
1599
|
+
function parseCtrlArgs(raw) {
|
|
1600
|
+
const input = {};
|
|
1601
|
+
CTRL_ARG.lastIndex = 0;
|
|
1602
|
+
for (let m = CTRL_ARG.exec(raw); m !== null; m = CTRL_ARG.exec(raw)) {
|
|
1603
|
+
input[m[1]] = parseCtrlValue(m[2].trim());
|
|
1604
|
+
}
|
|
1605
|
+
return chunk3HL43XBD_cjs.sanitizeToolInput(input, { trim: true }).value;
|
|
1606
|
+
}
|
|
1607
|
+
function parseCtrlValue(v) {
|
|
1608
|
+
const q = v[0];
|
|
1609
|
+
if ((q === '"' || q === "'") && v.length >= 2 && v.endsWith(q)) {
|
|
1610
|
+
return v.slice(1, -1).replace(/\\(.)/g, (_, c) => c === "n" ? "\n" : c === "t" ? " " : c);
|
|
1611
|
+
}
|
|
1612
|
+
if (v === "True") return true;
|
|
1613
|
+
if (v === "False") return false;
|
|
1614
|
+
if (v === "None") return null;
|
|
1615
|
+
return /^-?\d+(\.\d+)?$/.test(v) ? Number(v) : v;
|
|
1567
1616
|
}
|
|
1568
1617
|
function parseHermesParams(inner) {
|
|
1569
1618
|
const input = {};
|
|
@@ -1573,7 +1622,7 @@ function parseHermesParams(inner) {
|
|
|
1573
1622
|
if (key === void 0 || value === void 0) continue;
|
|
1574
1623
|
input[key.trim()] = value;
|
|
1575
1624
|
}
|
|
1576
|
-
return
|
|
1625
|
+
return chunk3HL43XBD_cjs.sanitizeToolInput(input, { trim: true }).value;
|
|
1577
1626
|
}
|
|
1578
1627
|
var STREAM_MARKER = "<function=";
|
|
1579
1628
|
var DEFAULT_STREAM_BUFFER_CAP = 8192;
|
|
@@ -1581,6 +1630,10 @@ var isStreamWs = (c) => c === " " || c === " " || c === "\n" || c === "\r";
|
|
|
1581
1630
|
function streamToolCallBufferState(held, allowedToolNames, cap = DEFAULT_STREAM_BUFFER_CAP) {
|
|
1582
1631
|
if (allowedToolNames.size === 0) return "impossible";
|
|
1583
1632
|
const t = held.trimStart();
|
|
1633
|
+
if (t.startsWith("<c")) return ctrlState(t, held.length, allowedToolNames, cap);
|
|
1634
|
+
return functionMarkerState(held, t, allowedToolNames, cap);
|
|
1635
|
+
}
|
|
1636
|
+
function functionMarkerState(held, t, allowedToolNames, cap) {
|
|
1584
1637
|
if (t.length < STREAM_MARKER.length) {
|
|
1585
1638
|
return STREAM_MARKER.startsWith(t) ? "possible" : "impossible";
|
|
1586
1639
|
}
|
|
@@ -1592,6 +1645,20 @@ function streamToolCallBufferState(held, allowedToolNames, cap = DEFAULT_STREAM_
|
|
|
1592
1645
|
if (!nameOk) return "impossible";
|
|
1593
1646
|
return held.length > cap ? "impossible" : "possible";
|
|
1594
1647
|
}
|
|
1648
|
+
function ctrlState(t, heldLength, allowedToolNames, cap) {
|
|
1649
|
+
if (t.length < CTRL_MARKER.length) return CTRL_MARKER.startsWith(t) ? "possible" : "impossible";
|
|
1650
|
+
if (!t.startsWith(CTRL_MARKER)) return "impossible";
|
|
1651
|
+
const rest = t.slice(CTRL_MARKER.length).trimStart();
|
|
1652
|
+
if (rest.length <= CTRL_PREFIX.length)
|
|
1653
|
+
return CTRL_PREFIX.startsWith(rest) ? "possible" : "impossible";
|
|
1654
|
+
if (!rest.startsWith(CTRL_PREFIX)) return "impossible";
|
|
1655
|
+
const afterPrefix = rest.slice(CTRL_PREFIX.length);
|
|
1656
|
+
const paren = afterPrefix.indexOf("(");
|
|
1657
|
+
const name = paren === -1 ? afterPrefix : afterPrefix.slice(0, paren);
|
|
1658
|
+
if (!/^\w*$/.test(name)) return "impossible";
|
|
1659
|
+
const nameOk = paren === -1 ? someToolNameStartsWith(allowedToolNames, name) : allowedToolNames.has(name);
|
|
1660
|
+
return nameOk && heldLength <= cap ? "possible" : "impossible";
|
|
1661
|
+
}
|
|
1595
1662
|
function parseStreamMarkerName(t) {
|
|
1596
1663
|
let cursor = STREAM_MARKER.length;
|
|
1597
1664
|
while (cursor < t.length && isStreamWs(t[cursor])) cursor += 1;
|
|
@@ -1947,7 +2014,7 @@ var OpenAIStreamAccumulator = class {
|
|
|
1947
2014
|
text = recovered.residualText;
|
|
1948
2015
|
stopReason = "tool_use";
|
|
1949
2016
|
chunkRNXXYF22_cjs.diag(
|
|
1950
|
-
`[theokit-sdk] recovered ${recovered.toolCalls.length} leaked tool call(s) from assistant content (provider="${this.providerName}", names=${recovered.toolCalls.map((c) => c.name).join(",")})
|
|
2017
|
+
`[theokit-sdk] recovered ${recovered.toolCalls.length} leaked tool call(s) from assistant content (provider="${this.providerName}", format=${recovered.formats.join(",") || "hermes"}, names=${recovered.toolCalls.map((c) => c.name).join(",")})
|
|
1951
2018
|
`
|
|
1952
2019
|
);
|
|
1953
2020
|
}
|
|
@@ -2708,7 +2775,7 @@ async function resolveVertexAccessToken() {
|
|
|
2708
2775
|
async function getAuthClientOrThrow() {
|
|
2709
2776
|
let mod;
|
|
2710
2777
|
try {
|
|
2711
|
-
const r =
|
|
2778
|
+
const r = node_module.createRequire((typeof document === 'undefined' ? require('u' + 'rl').pathToFileURL(__filename).href : (_documentCurrentScript && _documentCurrentScript.tagName.toUpperCase() === 'SCRIPT' && _documentCurrentScript.src || new URL('chunk-6XT5LAZG.cjs', document.baseURI).href)));
|
|
2712
2779
|
mod = r("google-auth-library");
|
|
2713
2780
|
} catch (err) {
|
|
2714
2781
|
const isModuleMissing = err instanceof Error && (err.message.includes("Cannot find module") || err.code === "MODULE_NOT_FOUND");
|
|
@@ -2769,8 +2836,8 @@ var VertexAnthropicClient = class {
|
|
|
2769
2836
|
const projectId = this.resolveProjectOrThrow();
|
|
2770
2837
|
const location = this.options.location ?? resolveVertexLocation();
|
|
2771
2838
|
const accessToken = await this.resolveTokenOrThrow();
|
|
2772
|
-
const baseUrl =
|
|
2773
|
-
const bareModel =
|
|
2839
|
+
const baseUrl = chunkZ5MB2HAN_cjs.resolveVertexBaseUrl({ projectId, location, modelDialect: "anthropic" });
|
|
2840
|
+
const bareModel = chunkZ5MB2HAN_cjs.stripVertexPrefix(request.model);
|
|
2774
2841
|
const endpoint = `/models/${encodeURIComponent(bareModel)}:rawPredict`;
|
|
2775
2842
|
const url = `${baseUrl}${endpoint}`;
|
|
2776
2843
|
const response = await postAnthropicRequest({
|
|
@@ -2819,7 +2886,7 @@ var VertexGeminiClient = class {
|
|
|
2819
2886
|
{ code: "auth_failed" }
|
|
2820
2887
|
);
|
|
2821
2888
|
}
|
|
2822
|
-
const baseUrl =
|
|
2889
|
+
const baseUrl = chunkZ5MB2HAN_cjs.resolveVertexBaseUrl({ projectId, location, modelDialect: "gemini" });
|
|
2823
2890
|
const url = `${baseUrl}/chat/completions`;
|
|
2824
2891
|
const innerFetch = chunkEHD25JBZ_cjs.boundFetch(this.options.fetch);
|
|
2825
2892
|
const rewriteFetch = (_input, init) => innerFetch(url, init);
|
|
@@ -2841,7 +2908,7 @@ var VertexRouterClient = class {
|
|
|
2841
2908
|
options;
|
|
2842
2909
|
name = "vertex";
|
|
2843
2910
|
async *stream(request, signal) {
|
|
2844
|
-
const dialect =
|
|
2911
|
+
const dialect = chunkZ5MB2HAN_cjs.inferModelDialect(request.model);
|
|
2845
2912
|
if (dialect === "anthropic") {
|
|
2846
2913
|
const inner2 = new VertexAnthropicClient(this.options);
|
|
2847
2914
|
return yield* inner2.stream(request, signal);
|
|
@@ -2853,7 +2920,7 @@ var VertexRouterClient = class {
|
|
|
2853
2920
|
|
|
2854
2921
|
// src/internal/llm/router.ts
|
|
2855
2922
|
function resolveProviderChain(options) {
|
|
2856
|
-
|
|
2923
|
+
chunkZ5MB2HAN_cjs.registerBuiltins();
|
|
2857
2924
|
return buildChain(options);
|
|
2858
2925
|
}
|
|
2859
2926
|
function buildChain(options) {
|
|
@@ -2873,7 +2940,7 @@ function buildChain(options) {
|
|
|
2873
2940
|
addClient(fallback);
|
|
2874
2941
|
}
|
|
2875
2942
|
if (clients.length === 0) {
|
|
2876
|
-
if (
|
|
2943
|
+
if (chunkZ5MB2HAN_cjs.getProviderProfile(normalizeProviderName(options.primary)) === void 0) {
|
|
2877
2944
|
throw new chunkCEGU5AVD_cjs.ConfigurationError(unregisteredProviderMessage(options.primary), {
|
|
2878
2945
|
code: "provider_unresolved"
|
|
2879
2946
|
});
|
|
@@ -2890,7 +2957,7 @@ function normalizeProviderName(name) {
|
|
|
2890
2957
|
}
|
|
2891
2958
|
function unregisteredProviderMessage(name) {
|
|
2892
2959
|
const normalized = normalizeProviderName(name);
|
|
2893
|
-
const caseOnlyMatch =
|
|
2960
|
+
const caseOnlyMatch = chunkZ5MB2HAN_cjs.listProviders().find(
|
|
2894
2961
|
(profile) => normalizeProviderName(profile.name) === normalized
|
|
2895
2962
|
);
|
|
2896
2963
|
if (caseOnlyMatch !== void 0) {
|
|
@@ -2898,11 +2965,11 @@ function unregisteredProviderMessage(name) {
|
|
|
2898
2965
|
}
|
|
2899
2966
|
const aliasMessage = caseOnlyAliasMessage(name, normalized);
|
|
2900
2967
|
if (aliasMessage !== void 0) return aliasMessage;
|
|
2901
|
-
const registered =
|
|
2968
|
+
const registered = chunkZ5MB2HAN_cjs.listProviders().map((profile) => profile.name).sort((a, b) => a.localeCompare(b)).join(", ");
|
|
2902
2969
|
return `No provider client could be resolved: "${name}" is not a known provider. Registered providers: ${registered}.`;
|
|
2903
2970
|
}
|
|
2904
2971
|
function caseOnlyAliasMessage(name, normalized) {
|
|
2905
|
-
for (const profile of
|
|
2972
|
+
for (const profile of chunkZ5MB2HAN_cjs.listProviders()) {
|
|
2906
2973
|
const alias = profile.aliases?.find((entry) => normalizeProviderName(entry) === normalized);
|
|
2907
2974
|
if (alias === void 0) continue;
|
|
2908
2975
|
return `No provider client could be resolved: "${name}" matches the alias "${alias}" of the registered provider "${profile.name}" only when case is ignored, and routes look provider names up in lowercase. Register the alias as "${normalized}", or route to "${profile.name}".`;
|
|
@@ -2910,11 +2977,11 @@ function caseOnlyAliasMessage(name, normalized) {
|
|
|
2910
2977
|
return void 0;
|
|
2911
2978
|
}
|
|
2912
2979
|
function buildTransport(name, routerOptions, perCallBaseUrl) {
|
|
2913
|
-
const baseProfile =
|
|
2980
|
+
const baseProfile = chunkZ5MB2HAN_cjs.getProviderProfile(name);
|
|
2914
2981
|
if (baseProfile === void 0) return void 0;
|
|
2915
2982
|
const profile = routerOptions.extractToolCallsFromContent === true && baseProfile.extractToolCallsFromContent !== true ? { ...baseProfile, extractToolCallsFromContent: true } : baseProfile;
|
|
2916
2983
|
const resilience = routerOptions.onRateLimit !== void 0 ? { onRateLimit: routerOptions.onRateLimit } : {};
|
|
2917
|
-
const ambient =
|
|
2984
|
+
const ambient = chunkMJGY3E3C_cjs.currentCredentialPool(name);
|
|
2918
2985
|
if (ambient !== void 0) {
|
|
2919
2986
|
return new PoolAwareLlmClient(
|
|
2920
2987
|
ambient,
|
|
@@ -2946,9 +3013,9 @@ function buildPoolOrSingle(args) {
|
|
|
2946
3013
|
if (poolKeys !== void 0 && poolKeys.length >= 2) {
|
|
2947
3014
|
const strategy = routerOptions.credentialPoolStrategy?.[name] ?? "fill_first";
|
|
2948
3015
|
const entries = poolKeys.map(
|
|
2949
|
-
(accessToken, priority) =>
|
|
3016
|
+
(accessToken, priority) => chunkMJGY3E3C_cjs.newPooledCredential({ provider: name, accessToken, priority, source: "manual" })
|
|
2950
3017
|
);
|
|
2951
|
-
const pool = new
|
|
3018
|
+
const pool = new chunkMJGY3E3C_cjs.CredentialPool(name, entries, strategy);
|
|
2952
3019
|
const resilience = routerOptions.onRateLimit !== void 0 ? { onRateLimit: routerOptions.onRateLimit } : {};
|
|
2953
3020
|
return new PoolAwareLlmClient(
|
|
2954
3021
|
pool,
|
|
@@ -3005,7 +3072,7 @@ function warnUnknownProvidersInApiKeys(apiKeys) {
|
|
|
3005
3072
|
if (apiKeys === void 0) return;
|
|
3006
3073
|
for (const name of Object.keys(apiKeys)) {
|
|
3007
3074
|
if (warnedProviders.has(name)) continue;
|
|
3008
|
-
const profile =
|
|
3075
|
+
const profile = chunkZ5MB2HAN_cjs.getProviderProfile(name);
|
|
3009
3076
|
if (profile === void 0) {
|
|
3010
3077
|
warnedProviders.add(name);
|
|
3011
3078
|
chunkRNXXYF22_cjs.diag(
|
|
@@ -3018,7 +3085,7 @@ function warnUnknownProvidersInApiKeys(apiKeys) {
|
|
|
3018
3085
|
function warnUnknownFallback(name) {
|
|
3019
3086
|
const key = `fallback:${normalizeProviderName(name)}`;
|
|
3020
3087
|
if (warnedProviders.has(key)) return;
|
|
3021
|
-
if (
|
|
3088
|
+
if (chunkZ5MB2HAN_cjs.getProviderProfile(normalizeProviderName(name)) !== void 0) return;
|
|
3022
3089
|
warnedProviders.add(key);
|
|
3023
3090
|
chunkRNXXYF22_cjs.diag(
|
|
3024
3091
|
`[theokit-sdk] providers.fallback: unknown provider "${name}" (no profile registered) \u2014 dropped from the fallback chain
|
|
@@ -3190,7 +3257,7 @@ function checkProviderPrefix(key, provider) {
|
|
|
3190
3257
|
function registerPluginProviderProfiles(entries) {
|
|
3191
3258
|
let registered = 0;
|
|
3192
3259
|
for (const entry of entries) {
|
|
3193
|
-
|
|
3260
|
+
chunkZ5MB2HAN_cjs.registerProvider(entry.profile);
|
|
3194
3261
|
registered += 1;
|
|
3195
3262
|
}
|
|
3196
3263
|
return registered;
|
|
@@ -3207,14 +3274,14 @@ function presentProviderCredentialEnvVars() {
|
|
|
3207
3274
|
});
|
|
3208
3275
|
}
|
|
3209
3276
|
var AMBIENT_STORE = {
|
|
3210
|
-
home:
|
|
3277
|
+
home: node_os.homedir(),
|
|
3211
3278
|
dirName: ".theokit",
|
|
3212
3279
|
fileName: "auth.json",
|
|
3213
3280
|
homeEnvVar: "THEOKIT_AUTH_HOME"
|
|
3214
3281
|
};
|
|
3215
3282
|
function isStoredOAuthAvailable(env = process.env) {
|
|
3216
3283
|
try {
|
|
3217
|
-
return
|
|
3284
|
+
return chunkPXYINWBC_cjs.readStoredOAuth(AMBIENT_STORE, env) !== void 0;
|
|
3218
3285
|
} catch {
|
|
3219
3286
|
return false;
|
|
3220
3287
|
}
|
|
@@ -3235,7 +3302,7 @@ function awsCredentialsFileExists() {
|
|
|
3235
3302
|
try {
|
|
3236
3303
|
const home = process.env.HOME ?? process.env.USERPROFILE;
|
|
3237
3304
|
if (home === void 0 || home.length === 0) return false;
|
|
3238
|
-
return
|
|
3305
|
+
return node_fs.existsSync(`${home}/.aws/credentials`) || node_fs.existsSync(`${home}/.aws/config`);
|
|
3239
3306
|
} catch {
|
|
3240
3307
|
return false;
|
|
3241
3308
|
}
|
|
@@ -3274,7 +3341,7 @@ function shouldUseRealLocalRuntime(apiKey) {
|
|
|
3274
3341
|
function inferProviderFromApiKey(apiKey) {
|
|
3275
3342
|
const provider = chunkFRITRLZQ_cjs.providerFromApiKeyPrefix(apiKey);
|
|
3276
3343
|
if (provider === void 0) return void 0;
|
|
3277
|
-
return
|
|
3344
|
+
return chunkZ5MB2HAN_cjs.getProviderProfile(provider) === void 0 ? void 0 : provider;
|
|
3278
3345
|
}
|
|
3279
3346
|
function detectPrimaryProvider() {
|
|
3280
3347
|
if (process.env.ANTHROPIC_API_KEY !== void 0 && process.env.ANTHROPIC_API_KEY.length > 0) {
|
|
@@ -3301,7 +3368,7 @@ function warnProviderPrecedenceOnce(asked, used) {
|
|
|
3301
3368
|
}
|
|
3302
3369
|
var pluginProvidersAnnounced = false;
|
|
3303
3370
|
function resolveRunProvider(options) {
|
|
3304
|
-
|
|
3371
|
+
chunkZ5MB2HAN_cjs.registerBuiltins();
|
|
3305
3372
|
const profiles = options.pluginManager?.aggregated.providerProfiles ?? [];
|
|
3306
3373
|
const registered = registerPluginProviderProfiles(profiles);
|
|
3307
3374
|
if (registered > 0 && !pluginProvidersAnnounced) {
|
|
@@ -3311,7 +3378,7 @@ function resolveRunProvider(options) {
|
|
|
3311
3378
|
`);
|
|
3312
3379
|
}
|
|
3313
3380
|
const parsedModel = chunk3EE6LVWT_cjs.parseModelId(options.model?.id);
|
|
3314
|
-
const modelInferredProvider = parsedModel.provider !== void 0 &&
|
|
3381
|
+
const modelInferredProvider = parsedModel.provider !== void 0 && chunkZ5MB2HAN_cjs.getProviderProfile(parsedModel.provider) !== void 0 ? parsedModel.provider : void 0;
|
|
3315
3382
|
const keyInferredProvider = inferProviderFromApiKey(options.agentOptions.apiKey);
|
|
3316
3383
|
const primary = options.agentOptions.providers?.routes?.[0]?.provider ?? keyInferredProvider ?? modelInferredProvider ?? detectPrimaryProvider();
|
|
3317
3384
|
warnProviderPrecedenceOnce(modelInferredProvider, primary);
|
|
@@ -3394,7 +3461,7 @@ async function runPreCompactBounded(handler, ctx, timeoutMs, onError) {
|
|
|
3394
3461
|
}
|
|
3395
3462
|
async function compactSessionTranscript(opts) {
|
|
3396
3463
|
const prior = await opts.store.readRecords(opts.loc.agentId);
|
|
3397
|
-
const history =
|
|
3464
|
+
const history = chunk6EHOJLJ3_cjs.reconstructMessages(prior);
|
|
3398
3465
|
const compressible = [];
|
|
3399
3466
|
for (const m of history) {
|
|
3400
3467
|
const text = plainText(m.content);
|
|
@@ -3431,7 +3498,7 @@ async function compactSessionTranscript(opts) {
|
|
|
3431
3498
|
}
|
|
3432
3499
|
const summary = `${COMPACT_SUMMARY_MARKER}
|
|
3433
3500
|
${summaryBody}`;
|
|
3434
|
-
const transcript =
|
|
3501
|
+
const transcript = chunk6EHOJLJ3_cjs.SessionTranscript.fromRecords(prior, {
|
|
3435
3502
|
cwd: opts.loc.cwd,
|
|
3436
3503
|
sessionId: opts.sessionId,
|
|
3437
3504
|
model: opts.loc.model ?? "unknown"
|
|
@@ -3451,9 +3518,9 @@ function resolveSummarizerRoute(opts) {
|
|
|
3451
3518
|
}
|
|
3452
3519
|
function buildDefaultSummarizer(opts) {
|
|
3453
3520
|
return async (messages) => {
|
|
3454
|
-
|
|
3521
|
+
chunkZ5MB2HAN_cjs.registerBuiltins();
|
|
3455
3522
|
const modelPrefix = opts.agentModel.includes("/") ? opts.agentModel.slice(0, opts.agentModel.indexOf("/")) : void 0;
|
|
3456
|
-
const prefixProfile = modelPrefix !== void 0 ?
|
|
3523
|
+
const prefixProfile = modelPrefix !== void 0 ? chunkZ5MB2HAN_cjs.getProviderProfile(modelPrefix) : void 0;
|
|
3457
3524
|
const prefixUsable = prefixProfile !== void 0 && (prefixProfile.authType !== "api_key" || prefixProfile.envVars.some((v) => (process.env[v] ?? "").length > 0));
|
|
3458
3525
|
const route = resolveSummarizerRoute({
|
|
3459
3526
|
keyProvider: inferProviderFromApiKey(opts.apiKey),
|
|
@@ -3561,5 +3628,5 @@ exports.shouldUseRealLocalRuntime = shouldUseRealLocalRuntime;
|
|
|
3561
3628
|
exports.trustFilePath = trustFilePath;
|
|
3562
3629
|
exports.tryFirstEvent = tryFirstEvent;
|
|
3563
3630
|
exports.validateApiKeyShape = validateApiKeyShape;
|
|
3564
|
-
//# sourceMappingURL=chunk-
|
|
3565
|
-
//# sourceMappingURL=chunk-
|
|
3631
|
+
//# sourceMappingURL=chunk-6XT5LAZG.cjs.map
|
|
3632
|
+
//# sourceMappingURL=chunk-6XT5LAZG.cjs.map
|