@theokit/sdk 0.0.0-compat-580-20260905204608
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 +7923 -0
- package/LICENSE +201 -0
- package/README.md +114 -0
- package/dist/a2a/agent-mailbox.d.cts +54 -0
- package/dist/a2a/agent-mailbox.d.ts +54 -0
- package/dist/a2a/index.cjs +138 -0
- package/dist/a2a/index.cjs.map +1 -0
- package/dist/a2a/index.d.cts +10 -0
- package/dist/a2a/index.d.ts +10 -0
- package/dist/a2a/index.js +125 -0
- package/dist/a2a/index.js.map +1 -0
- package/dist/a2a/message-bus.d.cts +118 -0
- package/dist/a2a/message-bus.d.ts +118 -0
- package/dist/a2a/subagent.d.cts +231 -0
- package/dist/a2a/subagent.d.ts +231 -0
- package/dist/a2a/types.d.cts +45 -0
- package/dist/a2a/types.d.ts +45 -0
- package/dist/agent-ARLOD4JX.cjs +67 -0
- package/dist/agent-ARLOD4JX.cjs.map +1 -0
- package/dist/agent-C3KO5LKm.d.cts +1871 -0
- package/dist/agent-CvmTR9uf.d.ts +1871 -0
- package/dist/agent-N6WJ54ML.js +58 -0
- package/dist/agent-N6WJ54ML.js.map +1 -0
- package/dist/agent-builder.d.ts +72 -0
- package/dist/agent-factory-registry-UU46BUMU.cjs +16 -0
- package/dist/agent-factory-registry-UU46BUMU.cjs.map +1 -0
- package/dist/agent-factory-registry-ZVTABLEY.js +3 -0
- package/dist/agent-factory-registry-ZVTABLEY.js.map +1 -0
- package/dist/agent-factory.d.ts +24 -0
- package/dist/agent-generate.d.ts +12 -0
- package/dist/agent-session-store-AFML3AXC.js +6 -0
- package/dist/agent-session-store-AFML3AXC.js.map +1 -0
- package/dist/agent-session-store-MTSIY3MH.cjs +23 -0
- package/dist/agent-session-store-MTSIY3MH.cjs.map +1 -0
- package/dist/agent.d.ts +276 -0
- package/dist/auth/index.cjs +306 -0
- package/dist/auth/index.cjs.map +1 -0
- package/dist/auth/index.d.cts +34 -0
- package/dist/auth/index.d.ts +34 -0
- package/dist/auth/index.js +247 -0
- package/dist/auth/index.js.map +1 -0
- package/dist/batch-I6T6MXZO.cjs +263 -0
- package/dist/batch-I6T6MXZO.cjs.map +1 -0
- package/dist/batch-US4F6WPK.js +260 -0
- package/dist/batch-US4F6WPK.js.map +1 -0
- package/dist/chunk-24MGQDK3.js +31 -0
- package/dist/chunk-24MGQDK3.js.map +1 -0
- package/dist/chunk-24SYBZPL.cjs +121 -0
- package/dist/chunk-24SYBZPL.cjs.map +1 -0
- package/dist/chunk-2HPNT6HH.cjs +3373 -0
- package/dist/chunk-2HPNT6HH.cjs.map +1 -0
- package/dist/chunk-2SFBB54R.js +23 -0
- package/dist/chunk-2SFBB54R.js.map +1 -0
- package/dist/chunk-2WXHA33T.js +105 -0
- package/dist/chunk-2WXHA33T.js.map +1 -0
- package/dist/chunk-2XC6KDJM.js +22 -0
- package/dist/chunk-2XC6KDJM.js.map +1 -0
- package/dist/chunk-2XRAWOZZ.js +172 -0
- package/dist/chunk-2XRAWOZZ.js.map +1 -0
- package/dist/chunk-2ZPEDVLM.cjs +59 -0
- package/dist/chunk-2ZPEDVLM.cjs.map +1 -0
- package/dist/chunk-3EE6LVWT.cjs +29 -0
- package/dist/chunk-3EE6LVWT.cjs.map +1 -0
- package/dist/chunk-3JHIFQ4I.js +102 -0
- package/dist/chunk-3JHIFQ4I.js.map +1 -0
- package/dist/chunk-44I6UYVH.js +133 -0
- package/dist/chunk-44I6UYVH.js.map +1 -0
- package/dist/chunk-47TF32NQ.js +79 -0
- package/dist/chunk-47TF32NQ.js.map +1 -0
- package/dist/chunk-4A3SKJ53.cjs +297 -0
- package/dist/chunk-4A3SKJ53.cjs.map +1 -0
- package/dist/chunk-4HS6FFGL.cjs +433 -0
- package/dist/chunk-4HS6FFGL.cjs.map +1 -0
- package/dist/chunk-4MMWFSCD.js +25 -0
- package/dist/chunk-4MMWFSCD.js.map +1 -0
- package/dist/chunk-4NLCWGH7.cjs +177 -0
- package/dist/chunk-4NLCWGH7.cjs.map +1 -0
- package/dist/chunk-55GB6JYQ.js +208 -0
- package/dist/chunk-55GB6JYQ.js.map +1 -0
- package/dist/chunk-5WKQDIGO.js +136 -0
- package/dist/chunk-5WKQDIGO.js.map +1 -0
- package/dist/chunk-67SBTGMA.cjs +457 -0
- package/dist/chunk-67SBTGMA.cjs.map +1 -0
- package/dist/chunk-6LHQPOMI.cjs +193 -0
- package/dist/chunk-6LHQPOMI.cjs.map +1 -0
- package/dist/chunk-6M2OIS4Y.js +158 -0
- package/dist/chunk-6M2OIS4Y.js.map +1 -0
- package/dist/chunk-6PWOWXMC.js +121 -0
- package/dist/chunk-6PWOWXMC.js.map +1 -0
- package/dist/chunk-6X6ID4MO.js +20 -0
- package/dist/chunk-6X6ID4MO.js.map +1 -0
- package/dist/chunk-7A6535RA.cjs +231 -0
- package/dist/chunk-7A6535RA.cjs.map +1 -0
- package/dist/chunk-7FDKWDA2.cjs +135 -0
- package/dist/chunk-7FDKWDA2.cjs.map +1 -0
- package/dist/chunk-7I5Z3UBJ.js +10 -0
- package/dist/chunk-7I5Z3UBJ.js.map +1 -0
- package/dist/chunk-7JJ3A6AT.cjs +88 -0
- package/dist/chunk-7JJ3A6AT.cjs.map +1 -0
- package/dist/chunk-7SZAV6QG.js +593 -0
- package/dist/chunk-7SZAV6QG.js.map +1 -0
- package/dist/chunk-A4RAL2ER.cjs +51 -0
- package/dist/chunk-A4RAL2ER.cjs.map +1 -0
- package/dist/chunk-AA27GEYS.cjs +12 -0
- package/dist/chunk-AA27GEYS.cjs.map +1 -0
- package/dist/chunk-AAEZSPTC.js +133 -0
- package/dist/chunk-AAEZSPTC.js.map +1 -0
- package/dist/chunk-AGACYRJ2.js +11 -0
- package/dist/chunk-AGACYRJ2.js.map +1 -0
- package/dist/chunk-ALUN2B4W.js +356 -0
- package/dist/chunk-ALUN2B4W.js.map +1 -0
- package/dist/chunk-ANMJJD6D.cjs +18 -0
- package/dist/chunk-ANMJJD6D.cjs.map +1 -0
- package/dist/chunk-ATT276RD.cjs +173 -0
- package/dist/chunk-ATT276RD.cjs.map +1 -0
- package/dist/chunk-AW6F6HZR.js +166 -0
- package/dist/chunk-AW6F6HZR.js.map +1 -0
- package/dist/chunk-AWINL3ZC.js +109 -0
- package/dist/chunk-AWINL3ZC.js.map +1 -0
- package/dist/chunk-BJUJT5ED.cjs +186 -0
- package/dist/chunk-BJUJT5ED.cjs.map +1 -0
- package/dist/chunk-BUUUWQMB.cjs +34 -0
- package/dist/chunk-BUUUWQMB.cjs.map +1 -0
- package/dist/chunk-BV2MWEMV.cjs +26 -0
- package/dist/chunk-BV2MWEMV.cjs.map +1 -0
- package/dist/chunk-CFE6QF2Q.js +221 -0
- package/dist/chunk-CFE6QF2Q.js.map +1 -0
- package/dist/chunk-CZJ6Q7CW.js +183 -0
- package/dist/chunk-CZJ6Q7CW.js.map +1 -0
- package/dist/chunk-D3CCY3A2.cjs +10995 -0
- package/dist/chunk-D3CCY3A2.cjs.map +1 -0
- package/dist/chunk-D6POWE7E.cjs +210 -0
- package/dist/chunk-D6POWE7E.cjs.map +1 -0
- package/dist/chunk-DMRT67Y6.js +100 -0
- package/dist/chunk-DMRT67Y6.js.map +1 -0
- package/dist/chunk-DQZU7JK6.cjs +125 -0
- package/dist/chunk-DQZU7JK6.cjs.map +1 -0
- package/dist/chunk-EFMFILPG.js +77 -0
- package/dist/chunk-EFMFILPG.js.map +1 -0
- package/dist/chunk-EH6XD3FY.js +222 -0
- package/dist/chunk-EH6XD3FY.js.map +1 -0
- package/dist/chunk-EIQFAOFD.js +229 -0
- package/dist/chunk-EIQFAOFD.js.map +1 -0
- package/dist/chunk-EPSICJLZ.js +79 -0
- package/dist/chunk-EPSICJLZ.js.map +1 -0
- package/dist/chunk-EXTRW7GW.cjs +155 -0
- package/dist/chunk-EXTRW7GW.cjs.map +1 -0
- package/dist/chunk-FD2UT76F.js +3 -0
- package/dist/chunk-FD2UT76F.js.map +1 -0
- package/dist/chunk-FJWQP6EE.js +122 -0
- package/dist/chunk-FJWQP6EE.js.map +1 -0
- package/dist/chunk-FRITRLZQ.cjs +24 -0
- package/dist/chunk-FRITRLZQ.cjs.map +1 -0
- package/dist/chunk-FUSDYC2B.cjs +280 -0
- package/dist/chunk-FUSDYC2B.cjs.map +1 -0
- package/dist/chunk-G7BLGBRN.js +43 -0
- package/dist/chunk-G7BLGBRN.js.map +1 -0
- package/dist/chunk-GBCVPKHE.js +282 -0
- package/dist/chunk-GBCVPKHE.js.map +1 -0
- package/dist/chunk-GHX4P3V2.cjs +34 -0
- package/dist/chunk-GHX4P3V2.cjs.map +1 -0
- package/dist/chunk-GZV6AVRL.cjs +282 -0
- package/dist/chunk-GZV6AVRL.cjs.map +1 -0
- package/dist/chunk-H73MEMQB.js +31 -0
- package/dist/chunk-H73MEMQB.js.map +1 -0
- package/dist/chunk-HCT4HPCL.cjs +235 -0
- package/dist/chunk-HCT4HPCL.cjs.map +1 -0
- package/dist/chunk-HFEJE7AC.js +424 -0
- package/dist/chunk-HFEJE7AC.js.map +1 -0
- package/dist/chunk-HKCKOAIO.js +57 -0
- package/dist/chunk-HKCKOAIO.js.map +1 -0
- package/dist/chunk-HUFSABUZ.cjs +48 -0
- package/dist/chunk-HUFSABUZ.cjs.map +1 -0
- package/dist/chunk-HW7SEELD.cjs +46 -0
- package/dist/chunk-HW7SEELD.cjs.map +1 -0
- package/dist/chunk-HY66GLM6.js +13 -0
- package/dist/chunk-HY66GLM6.js.map +1 -0
- package/dist/chunk-I2PWY7VM.cjs +27 -0
- package/dist/chunk-I2PWY7VM.cjs.map +1 -0
- package/dist/chunk-IJ7M6GOG.cjs +28 -0
- package/dist/chunk-IJ7M6GOG.cjs.map +1 -0
- package/dist/chunk-IU5N5224.cjs +288 -0
- package/dist/chunk-IU5N5224.cjs.map +1 -0
- package/dist/chunk-IUMAQURF.js +130 -0
- package/dist/chunk-IUMAQURF.js.map +1 -0
- package/dist/chunk-J7J7J2GN.cjs +377 -0
- package/dist/chunk-J7J7J2GN.cjs.map +1 -0
- package/dist/chunk-JLRLCBJ4.cjs +108 -0
- package/dist/chunk-JLRLCBJ4.cjs.map +1 -0
- package/dist/chunk-JMDDYA22.js +171 -0
- package/dist/chunk-JMDDYA22.js.map +1 -0
- package/dist/chunk-JNAA4G4H.js +43 -0
- package/dist/chunk-JNAA4G4H.js.map +1 -0
- package/dist/chunk-JOFVLOFY.js +268 -0
- package/dist/chunk-JOFVLOFY.js.map +1 -0
- package/dist/chunk-K2BQQ445.js +30 -0
- package/dist/chunk-K2BQQ445.js.map +1 -0
- package/dist/chunk-K2VMFZQ5.js +487 -0
- package/dist/chunk-K2VMFZQ5.js.map +1 -0
- package/dist/chunk-K3NH62DG.js +3343 -0
- package/dist/chunk-K3NH62DG.js.map +1 -0
- package/dist/chunk-KGANQYP7.cjs +172 -0
- package/dist/chunk-KGANQYP7.cjs.map +1 -0
- package/dist/chunk-KRD3GQAA.cjs +71 -0
- package/dist/chunk-KRD3GQAA.cjs.map +1 -0
- package/dist/chunk-KTTHHYEW.cjs +45 -0
- package/dist/chunk-KTTHHYEW.cjs.map +1 -0
- package/dist/chunk-KVNWIAO4.js +68 -0
- package/dist/chunk-KVNWIAO4.js.map +1 -0
- package/dist/chunk-KVSAY6NZ.cjs +497 -0
- package/dist/chunk-KVSAY6NZ.cjs.map +1 -0
- package/dist/chunk-LOHMT36V.cjs +178 -0
- package/dist/chunk-LOHMT36V.cjs.map +1 -0
- package/dist/chunk-LX7SEXOQ.js +152 -0
- package/dist/chunk-LX7SEXOQ.js.map +1 -0
- package/dist/chunk-MUUQ2WFJ.cjs +4 -0
- package/dist/chunk-MUUQ2WFJ.cjs.map +1 -0
- package/dist/chunk-N6OOOYFZ.js +281 -0
- package/dist/chunk-N6OOOYFZ.js.map +1 -0
- package/dist/chunk-NAF4L3T6.js +22 -0
- package/dist/chunk-NAF4L3T6.js.map +1 -0
- package/dist/chunk-NINIJCHU.cjs +23 -0
- package/dist/chunk-NINIJCHU.cjs.map +1 -0
- package/dist/chunk-NJWYQWDL.js +43 -0
- package/dist/chunk-NJWYQWDL.js.map +1 -0
- package/dist/chunk-NQTD6QOW.cjs +226 -0
- package/dist/chunk-NQTD6QOW.cjs.map +1 -0
- package/dist/chunk-NQTNSHSB.cjs +843 -0
- package/dist/chunk-NQTNSHSB.cjs.map +1 -0
- package/dist/chunk-NVXXWAU7.cjs +13 -0
- package/dist/chunk-NVXXWAU7.cjs.map +1 -0
- package/dist/chunk-NYQ3IS7K.cjs +130 -0
- package/dist/chunk-NYQ3IS7K.cjs.map +1 -0
- package/dist/chunk-O6USDERH.js +165 -0
- package/dist/chunk-O6USDERH.js.map +1 -0
- package/dist/chunk-OBA6YK2R.cjs +8 -0
- package/dist/chunk-OBA6YK2R.cjs.map +1 -0
- package/dist/chunk-OQRGVTQF.js +169 -0
- package/dist/chunk-OQRGVTQF.js.map +1 -0
- package/dist/chunk-OR6XIWLB.js +19 -0
- package/dist/chunk-OR6XIWLB.js.map +1 -0
- package/dist/chunk-OYD3U3LY.js +10981 -0
- package/dist/chunk-OYD3U3LY.js.map +1 -0
- package/dist/chunk-PRZ3BES7.cjs +79 -0
- package/dist/chunk-PRZ3BES7.cjs.map +1 -0
- package/dist/chunk-PY2RQOA7.js +6 -0
- package/dist/chunk-PY2RQOA7.js.map +1 -0
- package/dist/chunk-Q5EWJPRY.js +18 -0
- package/dist/chunk-Q5EWJPRY.js.map +1 -0
- package/dist/chunk-QATRS7JD.cjs +158 -0
- package/dist/chunk-QATRS7JD.cjs.map +1 -0
- package/dist/chunk-QC55H6RJ.cjs +601 -0
- package/dist/chunk-QC55H6RJ.cjs.map +1 -0
- package/dist/chunk-QDM3OHUT.cjs +134 -0
- package/dist/chunk-QDM3OHUT.cjs.map +1 -0
- package/dist/chunk-QKLOP4VC.cjs +90 -0
- package/dist/chunk-QKLOP4VC.cjs.map +1 -0
- package/dist/chunk-QOGNZMHD.cjs +34 -0
- package/dist/chunk-QOGNZMHD.cjs.map +1 -0
- package/dist/chunk-QWD3CZWE.cjs +108 -0
- package/dist/chunk-QWD3CZWE.cjs.map +1 -0
- package/dist/chunk-QWD4RDZ3.cjs +136 -0
- package/dist/chunk-QWD4RDZ3.cjs.map +1 -0
- package/dist/chunk-QYLZQ43D.cjs +172 -0
- package/dist/chunk-QYLZQ43D.cjs.map +1 -0
- package/dist/chunk-R7WIIPUR.js +27 -0
- package/dist/chunk-R7WIIPUR.js.map +1 -0
- package/dist/chunk-RQMCOFAI.cjs +85 -0
- package/dist/chunk-RQMCOFAI.cjs.map +1 -0
- package/dist/chunk-SA6K24NB.cjs +25 -0
- package/dist/chunk-SA6K24NB.cjs.map +1 -0
- package/dist/chunk-SADXXGWU.js +809 -0
- package/dist/chunk-SADXXGWU.js.map +1 -0
- package/dist/chunk-SAGRF4IB.js +25 -0
- package/dist/chunk-SAGRF4IB.js.map +1 -0
- package/dist/chunk-SVQIW5RJ.js +81 -0
- package/dist/chunk-SVQIW5RJ.js.map +1 -0
- package/dist/chunk-TA3K7SBK.js +180 -0
- package/dist/chunk-TA3K7SBK.js.map +1 -0
- package/dist/chunk-TFG5IBZS.cjs +139 -0
- package/dist/chunk-TFG5IBZS.cjs.map +1 -0
- package/dist/chunk-TMKTSYDS.cjs +21 -0
- package/dist/chunk-TMKTSYDS.cjs.map +1 -0
- package/dist/chunk-UADQJBHR.cjs +172 -0
- package/dist/chunk-UADQJBHR.cjs.map +1 -0
- package/dist/chunk-UBR5PWD7.js +275 -0
- package/dist/chunk-UBR5PWD7.js.map +1 -0
- package/dist/chunk-UKMBRMGT.js +22 -0
- package/dist/chunk-UKMBRMGT.js.map +1 -0
- package/dist/chunk-V22DZIXO.js +147 -0
- package/dist/chunk-V22DZIXO.js.map +1 -0
- package/dist/chunk-VE6DFSKU.js +107 -0
- package/dist/chunk-VE6DFSKU.js.map +1 -0
- package/dist/chunk-VPK6PHIE.cjs +211 -0
- package/dist/chunk-VPK6PHIE.cjs.map +1 -0
- package/dist/chunk-VTYY7XL5.cjs +15 -0
- package/dist/chunk-VTYY7XL5.cjs.map +1 -0
- package/dist/chunk-VWUXIVEI.js +583 -0
- package/dist/chunk-VWUXIVEI.js.map +1 -0
- package/dist/chunk-WE22OXQA.js +48 -0
- package/dist/chunk-WE22OXQA.js.map +1 -0
- package/dist/chunk-WMWEI3NS.js +120 -0
- package/dist/chunk-WMWEI3NS.js.map +1 -0
- package/dist/chunk-WS5ULCL4.js +204 -0
- package/dist/chunk-WS5ULCL4.js.map +1 -0
- package/dist/chunk-XB4GI5RZ.js +115 -0
- package/dist/chunk-XB4GI5RZ.js.map +1 -0
- package/dist/chunk-XU6MLSC6.js +455 -0
- package/dist/chunk-XU6MLSC6.js.map +1 -0
- package/dist/chunk-XYFGKVZ7.js +15 -0
- package/dist/chunk-XYFGKVZ7.js.map +1 -0
- package/dist/chunk-Y2KYR2ED.cjs +118 -0
- package/dist/chunk-Y2KYR2ED.cjs.map +1 -0
- package/dist/chunk-YIFFF23U.cjs +109 -0
- package/dist/chunk-YIFFF23U.cjs.map +1 -0
- package/dist/chunk-YJNYDJ2T.cjs +27 -0
- package/dist/chunk-YJNYDJ2T.cjs.map +1 -0
- package/dist/chunk-YSTXFWQE.cjs +127 -0
- package/dist/chunk-YSTXFWQE.cjs.map +1 -0
- package/dist/chunk-Z2JFX372.cjs +595 -0
- package/dist/chunk-Z2JFX372.cjs.map +1 -0
- package/dist/chunk-Z3NTRKIC.cjs +111 -0
- package/dist/chunk-Z3NTRKIC.cjs.map +1 -0
- package/dist/chunk-ZF2LDKQQ.cjs +20 -0
- package/dist/chunk-ZF2LDKQQ.cjs.map +1 -0
- package/dist/client/index.cjs +73 -0
- package/dist/client/index.cjs.map +1 -0
- package/dist/client/index.d.cts +12 -0
- package/dist/client/index.d.ts +12 -0
- package/dist/client/index.js +71 -0
- package/dist/client/index.js.map +1 -0
- package/dist/client/theokit-client.d.cts +60 -0
- package/dist/client/theokit-client.d.ts +60 -0
- package/dist/client/types.d.cts +51 -0
- package/dist/client/types.d.ts +51 -0
- package/dist/compact-session-BHTPCIHA.cjs +61 -0
- package/dist/compact-session-BHTPCIHA.cjs.map +1 -0
- package/dist/compact-session-W4WLJTHA.js +24 -0
- package/dist/compact-session-W4WLJTHA.js.map +1 -0
- package/dist/compaction.cjs +66 -0
- package/dist/compaction.cjs.map +1 -0
- package/dist/compaction.d.cts +240 -0
- package/dist/compaction.d.ts +240 -0
- package/dist/compaction.js +5 -0
- package/dist/compaction.js.map +1 -0
- package/dist/concurrency.cjs +23 -0
- package/dist/concurrency.cjs.map +1 -0
- package/dist/concurrency.d.cts +22 -0
- package/dist/concurrency.d.ts +22 -0
- package/dist/concurrency.js +17 -0
- package/dist/concurrency.js.map +1 -0
- package/dist/context/index.cjs +37 -0
- package/dist/context/index.cjs.map +1 -0
- package/dist/context/index.d.cts +78 -0
- package/dist/context/index.d.ts +78 -0
- package/dist/context/index.js +20 -0
- package/dist/context/index.js.map +1 -0
- package/dist/context-4QOEWRDF.cjs +23 -0
- package/dist/context-4QOEWRDF.cjs.map +1 -0
- package/dist/context-Z3CFTT3H.js +6 -0
- package/dist/context-Z3CFTT3H.js.map +1 -0
- package/dist/create-skill.d.ts +40 -0
- package/dist/cron-C3PhZED0.d.cts +246 -0
- package/dist/cron-crfMMdAw.d.ts +246 -0
- package/dist/cron.cjs +68 -0
- package/dist/cron.cjs.map +1 -0
- package/dist/cron.d.cts +7 -0
- package/dist/cron.d.ts +7 -0
- package/dist/cron.js +59 -0
- package/dist/cron.js.map +1 -0
- package/dist/define-tool.d.ts +86 -0
- package/dist/errors-CLOAyuiv.d.ts +569 -0
- package/dist/errors-DrDEgyz1.d.cts +569 -0
- package/dist/errors-base-B5g01neU.d.cts +75 -0
- package/dist/errors-base-B5g01neU.d.ts +75 -0
- package/dist/errors-base.d.ts +73 -0
- package/dist/errors.cjs +89 -0
- package/dist/errors.cjs.map +1 -0
- package/dist/errors.d.cts +4 -0
- package/dist/errors.d.ts +4 -0
- package/dist/errors.js +4 -0
- package/dist/errors.js.map +1 -0
- package/dist/eval.cjs +1056 -0
- package/dist/eval.cjs.map +1 -0
- package/dist/eval.d.cts +77 -0
- package/dist/eval.d.ts +77 -0
- package/dist/eval.js +1042 -0
- package/dist/eval.js.map +1 -0
- package/dist/event-bus.d.ts +42 -0
- package/dist/executor-XQAOQOHD.cjs +993 -0
- package/dist/executor-XQAOQOHD.cjs.map +1 -0
- package/dist/executor-ZNDQDX6Q.js +989 -0
- package/dist/executor-ZNDQDX6Q.js.map +1 -0
- package/dist/filesystem/index.cjs +204 -0
- package/dist/filesystem/index.cjs.map +1 -0
- package/dist/filesystem/index.d.cts +12 -0
- package/dist/filesystem/index.d.ts +12 -0
- package/dist/filesystem/index.js +195 -0
- package/dist/filesystem/index.js.map +1 -0
- package/dist/filesystem/local-filesystem.d.cts +54 -0
- package/dist/filesystem/local-filesystem.d.ts +54 -0
- package/dist/filesystem/types.d.cts +136 -0
- package/dist/filesystem/types.d.ts +136 -0
- package/dist/fork-agent-S2EPIML7.js +61 -0
- package/dist/fork-agent-S2EPIML7.js.map +1 -0
- package/dist/fork-agent-WAEQI2DL.cjs +64 -0
- package/dist/fork-agent-WAEQI2DL.cjs.map +1 -0
- package/dist/fs-session-store-77JU46UZ.js +10 -0
- package/dist/fs-session-store-77JU46UZ.js.map +1 -0
- package/dist/fs-session-store-E4U3P56L.cjs +19 -0
- package/dist/fs-session-store-E4U3P56L.cjs.map +1 -0
- package/dist/generate-object-BXV7BZRP.js +7 -0
- package/dist/generate-object-BXV7BZRP.js.map +1 -0
- package/dist/generate-object-YBI2TDJ3.cjs +20 -0
- package/dist/generate-object-YBI2TDJ3.cjs.map +1 -0
- package/dist/generate-object.d.ts +111 -0
- package/dist/index-manager-3UNPYH34.cjs +26 -0
- package/dist/index-manager-3UNPYH34.cjs.map +1 -0
- package/dist/index-manager-W7FDMGEG.js +17 -0
- package/dist/index-manager-W7FDMGEG.js.map +1 -0
- package/dist/index.cjs +2487 -0
- package/dist/index.cjs.map +1 -0
- package/dist/index.d.cts +4166 -0
- package/dist/index.d.ts +4166 -0
- package/dist/index.js +2289 -0
- package/dist/index.js.map +1 -0
- package/dist/inject-session-SUM6TDJF.js +27 -0
- package/dist/inject-session-SUM6TDJF.js.map +1 -0
- package/dist/inject-session-W6A46J3E.cjs +29 -0
- package/dist/inject-session-W6A46J3E.cjs.map +1 -0
- package/dist/interactive/index.cjs +35 -0
- package/dist/interactive/index.cjs.map +1 -0
- package/dist/interactive/index.d.cts +12 -0
- package/dist/interactive/index.d.ts +12 -0
- package/dist/interactive/index.js +30 -0
- package/dist/interactive/index.js.map +1 -0
- package/dist/interactive/types.d.cts +95 -0
- package/dist/interactive/types.d.ts +95 -0
- package/dist/internal/agent/batch.d.ts +11 -0
- package/dist/internal/agent/helpers.d.ts +1 -0
- package/dist/internal/agent-loop/budget-gate.d.ts +1 -0
- package/dist/internal/agent-loop/doom-loop-tracker.d.ts +22 -0
- package/dist/internal/agent-loop/live-events.d.ts +46 -0
- package/dist/internal/agent-loop/loop-context-init.d.ts +2 -0
- package/dist/internal/agent-loop/loop-finalize.d.ts +25 -0
- package/dist/internal/agent-loop/loop-llm-stream.d.ts +1 -0
- package/dist/internal/agent-loop/loop-thinking-steps.d.ts +28 -0
- package/dist/internal/agent-loop/loop.d.ts +7 -0
- package/dist/internal/agent-loop/message-builders.d.ts +21 -0
- package/dist/internal/agent-loop/replay-messages.d.ts +41 -0
- package/dist/internal/agent-loop/tool-dispatch.d.ts +27 -0
- package/dist/internal/agent-loop/tool-executors.d.ts +1 -0
- package/dist/internal/agent-loop/tool-result-guard.d.ts +20 -0
- package/dist/internal/agent-loop/tool-timeout.d.ts +23 -0
- package/dist/internal/agent-loop/types.d.ts +43 -0
- package/dist/internal/agent-loop/usage-and-cost.d.ts +25 -0
- package/dist/internal/auth/api-key-prefix.d.ts +23 -0
- package/dist/internal/auth/api-key-validator.d.ts +46 -0
- package/dist/internal/auth/credential-availability.d.ts +61 -0
- package/dist/internal/auth/credential-store.d.ts +77 -0
- package/dist/internal/auth/oauth-device.d.ts +54 -0
- package/dist/internal/auth/oauth-engine.d.ts +21 -0
- package/dist/internal/auth/resolve-credential.d.ts +56 -0
- package/dist/internal/auth/types.d.ts +175 -0
- package/dist/internal/base-url.d.ts +14 -0
- package/dist/internal/budget/compute-cost.d.ts +28 -0
- package/dist/internal/budget/pricing-registry.d.ts +36 -0
- package/dist/internal/budget/tracker/budget-tracker.d.ts +11 -0
- package/dist/internal/budget/tracker/budget.d.ts +34 -0
- package/dist/internal/budget/usage-accumulator.d.ts +46 -0
- package/dist/internal/cloud-agent/cloud-agent.d.ts +1 -0
- package/dist/internal/cloud-agent/cloud-config-serializer.d.ts +3 -0
- package/dist/internal/cloud-agent/cloud-run.d.ts +1 -0
- package/dist/internal/cloud-agent/cloud-tool-parity.d.ts +1 -0
- package/dist/internal/cloud-agent/index.d.ts +7 -0
- package/dist/internal/cloud-agent/real-cloud-run.d.ts +2 -0
- package/dist/internal/cloud-agent/types.d.ts +56 -0
- package/dist/internal/concurrency/abort-utils.d.ts +21 -0
- package/dist/internal/concurrency/async-local-storage.d.ts +20 -0
- package/dist/internal/concurrency/async-semaphore.d.ts +24 -0
- package/dist/internal/concurrency/delegation-depth.d.ts +27 -0
- package/dist/internal/concurrency/map-with-concurrency.d.ts +28 -0
- package/dist/internal/concurrency/subagent-credentials.d.ts +112 -0
- package/dist/internal/diagnostics.d.ts +69 -0
- package/dist/internal/emit-run-event.d.ts +16 -0
- package/dist/internal/env.d.ts +1 -0
- package/dist/internal/error-mappers/anthropic.d.ts +30 -0
- package/dist/internal/error-mappers/bedrock.d.ts +16 -0
- package/dist/internal/error-mappers/default-retriable.d.ts +1 -0
- package/dist/internal/error-mappers/ollama.d.ts +41 -0
- package/dist/internal/error-mappers/openai-compatible.d.ts +25 -0
- package/dist/internal/error-mappers/shared.d.ts +23 -0
- package/dist/internal/error-mappers/vertex.d.ts +15 -0
- package/dist/internal/eval/aggregate.d.ts +9 -0
- package/dist/internal/eval/assert.d.ts +27 -0
- package/dist/internal/eval/code-runner.d.ts +28 -0
- package/dist/internal/eval/dataset-iter.d.ts +9 -0
- package/dist/internal/eval/runner.d.ts +9 -0
- package/dist/internal/eval/single-flight.d.ts +17 -0
- package/dist/internal/eval/telemetry.d.ts +23 -0
- package/dist/internal/eval/trials.d.ts +19 -0
- package/dist/internal/global-singleton.d.ts +16 -0
- package/dist/internal/http.d.ts +1 -0
- package/dist/internal/ids.d.ts +1 -0
- package/dist/internal/judge/judge-call.d.ts +48 -0
- package/dist/internal/judge/parse-verdict.d.ts +11 -0
- package/dist/internal/llm/abort-error.d.ts +1 -0
- package/dist/internal/llm/anthropic-shared.d.ts +100 -0
- package/dist/internal/llm/anthropic.d.ts +9 -0
- package/dist/internal/llm/bedrock-anthropic.d.ts +36 -0
- package/dist/internal/llm/bedrock-token-cache.d.ts +18 -0
- package/dist/internal/llm/credential-pool-context.d.ts +11 -0
- package/dist/internal/llm/credential-pool-types.d.ts +22 -0
- package/dist/internal/llm/credential-pool.d.ts +18 -0
- package/dist/internal/llm/fallback-client.d.ts +1 -0
- package/dist/internal/llm/fault-injection.d.ts +50 -0
- package/dist/internal/llm/finish.d.ts +1 -0
- package/dist/internal/llm/hermes-tool-extract.d.ts +11 -0
- package/dist/internal/llm/model-capabilities.d.ts +40 -0
- package/dist/internal/llm/model-identifier.d.ts +58 -0
- package/dist/internal/llm/model-option.d.ts +38 -0
- package/dist/internal/llm/ollama-native.d.ts +27 -0
- package/dist/internal/llm/openai-messages.d.ts +2 -0
- package/dist/internal/llm/openai.d.ts +146 -0
- package/dist/internal/llm/pool-aware-client.d.ts +16 -0
- package/dist/internal/llm/prompt-cache-key.d.ts +1 -0
- package/dist/internal/llm/responses.d.ts +97 -0
- package/dist/internal/llm/retry.d.ts +22 -0
- package/dist/internal/llm/retrying-client.d.ts +53 -0
- package/dist/internal/llm/router.d.ts +40 -0
- package/dist/internal/llm/sse.d.ts +21 -0
- package/dist/internal/llm/stream-relay.d.ts +17 -0
- package/dist/internal/llm/tool-result-content.d.ts +40 -0
- package/dist/internal/llm/transport-error.d.ts +9 -0
- package/dist/internal/llm/types.d.ts +226 -0
- package/dist/internal/llm/vertex-anthropic.d.ts +40 -0
- package/dist/internal/llm/vertex-auth.d.ts +30 -0
- package/dist/internal/llm/vertex-gemini.d.ts +28 -0
- package/dist/internal/llm/vertex-router.d.ts +21 -0
- package/dist/internal/local-agent/index.d.ts +6 -0
- package/dist/internal/local-agent/local-agent-bootstrap.d.ts +37 -0
- package/dist/internal/local-agent/local-agent-capabilities.d.ts +38 -0
- package/dist/internal/local-agent/local-agent-dispatch.d.ts +57 -0
- package/dist/internal/local-agent/local-agent-invalidate.d.ts +1 -0
- package/dist/internal/local-agent/local-agent-lifecycle.d.ts +13 -0
- package/dist/internal/local-agent/local-agent-memory-direct.d.ts +12 -0
- package/dist/internal/local-agent/local-agent-memory-hooks.d.ts +41 -0
- package/dist/internal/local-agent/local-agent-memory-provider.d.ts +57 -0
- package/dist/internal/local-agent/local-agent-memory.d.ts +1 -0
- package/dist/internal/local-agent/local-agent-personality-extensions.d.ts +43 -0
- package/dist/internal/local-agent/local-agent-runtime-extensions.d.ts +13 -0
- package/dist/internal/local-agent/local-agent-send.d.ts +42 -0
- package/dist/internal/local-agent/local-agent-task-wrap.d.ts +11 -0
- package/dist/internal/local-agent/local-agent.d.ts +1 -0
- package/dist/internal/local-agent/local-option-keys.d.ts +2 -0
- package/dist/internal/local-agent/local-run.d.ts +1 -0
- package/dist/internal/local-agent/mcp-pool.d.ts +43 -0
- package/dist/internal/local-agent/real-local-run-mcp.d.ts +26 -0
- package/dist/internal/local-agent/real-local-run-options.d.ts +26 -0
- package/dist/internal/local-agent/real-local-run-provider.d.ts +13 -0
- package/dist/internal/local-agent/real-local-run-tools.d.ts +55 -0
- package/dist/internal/local-agent/real-local-run.d.ts +4 -0
- package/dist/internal/mcp/client.d.ts +16 -0
- package/dist/internal/mcp/handshake-timeout.d.ts +53 -0
- package/dist/internal/mcp/oauth.d.ts +19 -0
- package/dist/internal/mcp/token-storage.d.ts +52 -0
- package/dist/internal/memory/active-memory-cache.d.ts +10 -0
- package/dist/internal/memory/active-memory-types.d.ts +8 -0
- package/dist/internal/memory/active-memory.d.ts +56 -0
- package/dist/internal/memory/adapters/azure-openai-embedding.d.cts +2 -0
- package/dist/internal/memory/adapters/azure-openai-embedding.d.ts +2 -0
- package/dist/internal/memory/adapters/catalog.d.cts +1 -0
- package/dist/internal/memory/adapters/catalog.d.ts +1 -0
- package/dist/internal/memory/adapters/cohere-embedding.d.cts +2 -0
- package/dist/internal/memory/adapters/cohere-embedding.d.ts +2 -0
- package/dist/internal/memory/adapters/deepinfra-embedding.d.cts +2 -0
- package/dist/internal/memory/adapters/deepinfra-embedding.d.ts +2 -0
- package/dist/internal/memory/adapters/gemini-embedding.d.cts +2 -0
- package/dist/internal/memory/adapters/gemini-embedding.d.ts +2 -0
- package/dist/internal/memory/adapters/index.cjs +30 -0
- package/dist/internal/memory/adapters/index.cjs.map +1 -0
- package/dist/internal/memory/adapters/index.d.cts +18 -0
- package/dist/internal/memory/adapters/index.d.ts +18 -0
- package/dist/internal/memory/adapters/index.js +13 -0
- package/dist/internal/memory/adapters/index.js.map +1 -0
- package/dist/internal/memory/adapters/jina-embedding.d.cts +2 -0
- package/dist/internal/memory/adapters/jina-embedding.d.ts +2 -0
- package/dist/internal/memory/adapters/mistral-embedding.d.cts +2 -0
- package/dist/internal/memory/adapters/mistral-embedding.d.ts +2 -0
- package/dist/internal/memory/adapters/ollama-embedding.d.cts +34 -0
- package/dist/internal/memory/adapters/ollama-embedding.d.ts +34 -0
- package/dist/internal/memory/adapters/openai-compatible.d.cts +96 -0
- package/dist/internal/memory/adapters/openai-compatible.d.ts +96 -0
- package/dist/internal/memory/adapters/openai-embedding.d.cts +12 -0
- package/dist/internal/memory/adapters/openai-embedding.d.ts +12 -0
- package/dist/internal/memory/adapters/openrouter-embedding.d.cts +2 -0
- package/dist/internal/memory/adapters/openrouter-embedding.d.ts +2 -0
- package/dist/internal/memory/adapters/voyage-embedding.d.cts +2 -0
- package/dist/internal/memory/adapters/voyage-embedding.d.ts +2 -0
- package/dist/internal/memory/corpus-sync.d.ts +23 -0
- package/dist/internal/memory/dreaming/diary.d.ts +41 -0
- package/dist/internal/memory/dreaming/phases.d.ts +35 -0
- package/dist/internal/memory/dreaming/run.d.ts +10 -0
- package/dist/internal/memory/embedding-adapter.d.ts +42 -0
- package/dist/internal/memory/embedding-cache.d.ts +42 -0
- package/dist/internal/memory/escape-like-pattern.d.ts +22 -0
- package/dist/internal/memory/index-db.d.ts +67 -0
- package/dist/internal/memory/index-manager-contract.d.ts +48 -0
- package/dist/internal/memory/index-manager-dispatch.d.ts +23 -0
- package/dist/internal/memory/index-manager-helpers.d.ts +20 -0
- package/dist/internal/memory/index-manager.d.ts +44 -0
- package/dist/internal/memory/index-repository.d.ts +58 -0
- package/dist/internal/memory/index-schema.d.ts +21 -0
- package/dist/internal/memory/lance-index.d.ts +46 -0
- package/dist/internal/memory/lance-memory-adapter.d.ts +45 -0
- package/dist/internal/memory/memory-index.d.ts +67 -0
- package/dist/internal/memory/migrate-sqlite-to-lance.d.ts +58 -0
- package/dist/internal/memory/migration.d.ts +9 -0
- package/dist/internal/memory/sdk-memory-peer-loader.d.ts +74 -0
- package/dist/internal/memory/sqlite-vec-loader.d.ts +1 -0
- package/dist/internal/memory/storage/chunk-markdown.d.cts +2 -0
- package/dist/internal/memory/storage/chunk-markdown.d.ts +2 -0
- package/dist/internal/memory/storage/index.cjs +141 -0
- package/dist/internal/memory/storage/index.cjs.map +1 -0
- package/dist/internal/memory/storage/index.d.cts +28 -0
- package/dist/internal/memory/storage/index.d.ts +28 -0
- package/dist/internal/memory/storage/index.js +16 -0
- package/dist/internal/memory/storage/index.js.map +1 -0
- package/dist/internal/memory/storage/list-markdown.d.cts +1 -0
- package/dist/internal/memory/storage/list-markdown.d.ts +1 -0
- package/dist/internal/memory/storage/markdown-store.d.cts +48 -0
- package/dist/internal/memory/storage/markdown-store.d.ts +48 -0
- package/dist/internal/memory/storage/memory-file.d.cts +90 -0
- package/dist/internal/memory/storage/memory-file.d.ts +90 -0
- package/dist/internal/memory/storage/memory-root.d.cts +119 -0
- package/dist/internal/memory/storage/memory-root.d.ts +119 -0
- package/dist/internal/memory/storage/reader.d.cts +8 -0
- package/dist/internal/memory/storage/reader.d.ts +8 -0
- package/dist/internal/memory/storage/session-loader.d.cts +35 -0
- package/dist/internal/memory/storage/session-loader.d.ts +35 -0
- package/dist/internal/memory/storage/session-summary-writer.d.cts +50 -0
- package/dist/internal/memory/storage/session-summary-writer.d.ts +50 -0
- package/dist/internal/memory/storage/threat-scan.d.cts +62 -0
- package/dist/internal/memory/storage/threat-scan.d.ts +62 -0
- package/dist/internal/memory/storage/transcript-store.d.cts +38 -0
- package/dist/internal/memory/storage/transcript-store.d.ts +38 -0
- package/dist/internal/memory/storage/wiki-loader.d.cts +27 -0
- package/dist/internal/memory/storage/wiki-loader.d.ts +27 -0
- package/dist/internal/memory/tools.d.ts +21 -0
- package/dist/internal/memory/types.d.ts +78 -0
- package/dist/internal/memory/vec-index.d.ts +28 -0
- package/dist/internal/persistence/atomic-write.d.cts +107 -0
- package/dist/internal/persistence/atomic-write.d.ts +107 -0
- package/dist/internal/persistence/cwd-mutex.d.cts +35 -0
- package/dist/internal/persistence/cwd-mutex.d.ts +35 -0
- package/dist/internal/persistence/exclusive-create.d.cts +53 -0
- package/dist/internal/persistence/exclusive-create.d.ts +53 -0
- package/dist/internal/persistence/file-lock.d.cts +54 -0
- package/dist/internal/persistence/file-lock.d.ts +54 -0
- package/dist/internal/persistence/fs-session-store.d.cts +68 -0
- package/dist/internal/persistence/fs-session-store.d.ts +68 -0
- package/dist/internal/persistence/fts5-sanitize.d.cts +44 -0
- package/dist/internal/persistence/fts5-sanitize.d.ts +44 -0
- package/dist/internal/persistence/index.cjs +127 -0
- package/dist/internal/persistence/index.cjs.map +1 -0
- package/dist/internal/persistence/index.d.cts +33 -0
- package/dist/internal/persistence/index.d.ts +33 -0
- package/dist/internal/persistence/index.js +40 -0
- package/dist/internal/persistence/index.js.map +1 -0
- package/dist/internal/persistence/jsonl.d.cts +43 -0
- package/dist/internal/persistence/jsonl.d.ts +43 -0
- package/dist/internal/persistence/markdown-config-loader.d.cts +35 -0
- package/dist/internal/persistence/markdown-config-loader.d.ts +35 -0
- package/dist/internal/persistence/pagination.d.cts +21 -0
- package/dist/internal/persistence/pagination.d.ts +21 -0
- package/dist/internal/persistence/paths.d.cts +137 -0
- package/dist/internal/persistence/paths.d.ts +137 -0
- package/dist/internal/persistence/persistence-schema.d.cts +29 -0
- package/dist/internal/persistence/persistence-schema.d.ts +29 -0
- package/dist/internal/persistence/schema-version.d.cts +227 -0
- package/dist/internal/persistence/schema-version.d.ts +227 -0
- package/dist/internal/persistence/session-artifacts.d.cts +27 -0
- package/dist/internal/persistence/session-artifacts.d.ts +27 -0
- package/dist/internal/persistence/session-dir.d.cts +1 -0
- package/dist/internal/persistence/session-dir.d.ts +1 -0
- package/dist/internal/persistence/session-transcript.d.cts +128 -0
- package/dist/internal/persistence/session-transcript.d.ts +128 -0
- package/dist/internal/persistence/session-writer.d.cts +104 -0
- package/dist/internal/persistence/session-writer.d.ts +104 -0
- package/dist/internal/persistence/sqlite-cas.d.cts +61 -0
- package/dist/internal/persistence/sqlite-cas.d.ts +61 -0
- package/dist/internal/persistence/sqlite-open.d.cts +61 -0
- package/dist/internal/persistence/sqlite-open.d.ts +61 -0
- package/dist/internal/persistence/sqlite-wal.d.cts +54 -0
- package/dist/internal/persistence/sqlite-wal.d.ts +54 -0
- package/dist/internal/persistence/transcript-ops.d.cts +99 -0
- package/dist/internal/persistence/transcript-ops.d.ts +99 -0
- package/dist/internal/personality/context.d.ts +17 -0
- package/dist/internal/personality/registry.d.ts +17 -0
- package/dist/internal/personality/store.d.ts +27 -0
- package/dist/internal/personality/switch.d.ts +36 -0
- package/dist/internal/personality/types.d.ts +18 -0
- package/dist/internal/plugins/context.d.cts +21 -0
- package/dist/internal/plugins/context.d.ts +21 -0
- package/dist/internal/plugins/enabled-names.d.cts +1 -0
- package/dist/internal/plugins/enabled-names.d.ts +1 -0
- package/dist/internal/plugins/index.d.cts +9 -0
- package/dist/internal/plugins/index.d.ts +9 -0
- package/dist/internal/plugins/lifecycle.d.cts +15 -0
- package/dist/internal/plugins/lifecycle.d.ts +15 -0
- package/dist/internal/plugins/manager.d.cts +57 -0
- package/dist/internal/plugins/manager.d.ts +57 -0
- package/dist/internal/plugins/plugin-guards.d.cts +13 -0
- package/dist/internal/plugins/plugin-guards.d.ts +13 -0
- package/dist/internal/plugins/types.d.cts +26 -0
- package/dist/internal/plugins/types.d.ts +26 -0
- package/dist/internal/providers/builtin/anthropic.d.ts +2 -0
- package/dist/internal/providers/builtin/bedrock.d.ts +25 -0
- package/dist/internal/providers/builtin/cerebras.d.ts +5 -0
- package/dist/internal/providers/builtin/cohere.d.ts +8 -0
- package/dist/internal/providers/builtin/deepinfra.d.ts +2 -0
- package/dist/internal/providers/builtin/gemini.d.ts +10 -0
- package/dist/internal/providers/builtin/google.d.ts +6 -0
- package/dist/internal/providers/builtin/groq.d.ts +2 -0
- package/dist/internal/providers/builtin/index.d.ts +20 -0
- package/dist/internal/providers/builtin/llamacpp.d.ts +1 -0
- package/dist/internal/providers/builtin/lmstudio.d.ts +1 -0
- package/dist/internal/providers/builtin/mistral.d.ts +2 -0
- package/dist/internal/providers/builtin/ollama.d.ts +17 -0
- package/dist/internal/providers/builtin/openai-chatgpt.d.ts +14 -0
- package/dist/internal/providers/builtin/openai-compatible.d.ts +1 -0
- package/dist/internal/providers/builtin/openai.d.ts +2 -0
- package/dist/internal/providers/builtin/openrouter.d.ts +2 -0
- package/dist/internal/providers/builtin/perplexity.d.ts +5 -0
- package/dist/internal/providers/builtin/together.d.ts +2 -0
- package/dist/internal/providers/builtin/vertex.d.ts +27 -0
- package/dist/internal/providers/builtin/xai.d.ts +2 -0
- package/dist/internal/providers/catalog-loader.d.ts +55 -0
- package/dist/internal/providers/catalog-schema.d.ts +202 -0
- package/dist/internal/providers/catalog-source-models-dev.d.ts +80 -0
- package/dist/internal/providers/discovery.d.ts +14 -0
- package/dist/internal/providers/index.d.ts +8 -0
- package/dist/internal/providers/register-plugin-providers.d.ts +22 -0
- package/dist/internal/providers/registry.d.ts +13 -0
- package/dist/internal/providers/types.d.ts +11 -0
- package/dist/internal/retry/circuit-breaker.d.ts +26 -0
- package/dist/internal/retry/with-retry.d.ts +40 -0
- package/dist/internal/runtime/compat/compat-config-file.d.ts +31 -0
- package/dist/internal/runtime/compat/foreign-config-sources.d.ts +139 -0
- package/dist/internal/runtime/compression/compression-attempt.d.ts +24 -0
- package/dist/internal/runtime/compression/compression-config.d.ts +33 -0
- package/dist/internal/runtime/compression/compression-decision.d.ts +10 -0
- package/dist/internal/runtime/compression/compression-helpers.d.ts +18 -0
- package/dist/internal/runtime/compression/compression-model-registry.d.ts +41 -0
- package/dist/internal/runtime/compression/compression-summarizer.d.ts +34 -0
- package/dist/internal/runtime/config/default-model.d.ts +1 -0
- package/dist/internal/runtime/config/providers-manager.d.ts +1 -0
- package/dist/internal/runtime/config/workspace-dir.d.ts +9 -0
- package/dist/internal/runtime/context/context-aggregator.d.ts +26 -0
- package/dist/internal/runtime/context/context-discovery-runner.d.ts +80 -0
- package/dist/internal/runtime/context/context-discovery.d.ts +79 -0
- package/dist/internal/runtime/context/context-frontmatter.d.ts +16 -0
- package/dist/internal/runtime/context/context-glob.d.ts +1 -0
- package/dist/internal/runtime/context/context-import-resolver.d.ts +41 -0
- package/dist/internal/runtime/context/context-loaders.d.ts +42 -0
- package/dist/internal/runtime/context/context-manager.d.ts +28 -0
- package/dist/internal/runtime/context/context-mdc-parser.d.ts +25 -0
- package/dist/internal/runtime/context/context-rules-frontmatter.d.ts +99 -0
- package/dist/internal/runtime/context/context-yaml-lite.d.ts +26 -0
- package/dist/internal/runtime/context/project-instructions.d.ts +66 -0
- package/dist/internal/runtime/context/yaml-frontmatter.d.ts +20 -0
- package/dist/internal/runtime/fixtures/fixture-events.d.ts +12 -0
- package/dist/internal/runtime/fixtures/fixture-mode.d.ts +24 -0
- package/dist/internal/runtime/fixtures/fixture-responder.d.ts +1 -0
- package/dist/internal/runtime/fixtures/fixture-run-base.d.ts +96 -0
- package/dist/internal/runtime/fixtures/fixture-scripts.d.ts +21 -0
- package/dist/internal/runtime/fixtures/types.d.ts +1 -0
- package/dist/internal/runtime/hooks/hooks-executor.d.ts +49 -0
- package/dist/internal/runtime/hooks/hooks-source.d.ts +35 -0
- package/dist/internal/runtime/lifecycle/context-budget-event.d.ts +25 -0
- package/dist/internal/runtime/lifecycle/env-policy.d.ts +29 -0
- package/dist/internal/runtime/lifecycle/fork-agent.d.ts +15 -0
- package/dist/internal/runtime/lifecycle/goal-marker.d.ts +13 -0
- package/dist/internal/runtime/lifecycle/post-run-lifecycle.d.ts +16 -0
- package/dist/internal/runtime/lifecycle/run-to-completion.d.ts +22 -0
- package/dist/internal/runtime/lifecycle/run-until.d.ts +21 -0
- package/dist/internal/runtime/lifecycle/spawn-collect.d.ts +8 -0
- package/dist/internal/runtime/lifecycle/stream-to-completion.d.ts +31 -0
- package/dist/internal/runtime/lifecycle/wrap-completion-check-run.d.ts +30 -0
- package/dist/internal/runtime/memory-glue/memory-provider.d.ts +11 -0
- package/dist/internal/runtime/memory-glue/memory-store.d.ts +4 -0
- package/dist/internal/runtime/memory-glue/select-facts.d.ts +63 -0
- package/dist/internal/runtime/model-selection.d.ts +14 -0
- package/dist/internal/runtime/plugin-loader/plugin-bundles.d.ts +22 -0
- package/dist/internal/runtime/plugin-loader/plugin-frontmatter.d.ts +17 -0
- package/dist/internal/runtime/plugin-loader/plugins-manager.d.ts +1 -0
- package/dist/internal/runtime/processors/run-processors.d.ts +10 -0
- package/dist/internal/runtime/processors/tripwire-run.d.ts +16 -0
- package/dist/internal/runtime/processors/wrap-output-run.d.ts +18 -0
- package/dist/internal/runtime/registry/agent-factory-registry.d.ts +19 -0
- package/dist/internal/runtime/registry/agent-registry-contract.d.ts +31 -0
- package/dist/internal/runtime/registry/agent-registry-store.d.ts +75 -0
- package/dist/internal/runtime/registry/agent-registry.d.ts +6 -0
- package/dist/internal/runtime/registry/live-agent-registry.d.ts +132 -0
- package/dist/internal/runtime/registry/run-registry.d.ts +4 -0
- package/dist/internal/runtime/skills/discover-skills.d.ts +103 -0
- package/dist/internal/runtime/skills/skill-frontmatter.d.ts +6 -0
- package/dist/internal/runtime/skills/skills-block.d.ts +18 -0
- package/dist/internal/runtime/skills/skills-manager.d.ts +1 -0
- package/dist/internal/runtime/skills/subagent-tool-scope.d.ts +25 -0
- package/dist/internal/runtime/skills/subagents-loader.d.ts +1 -0
- package/dist/internal/runtime/system-prompt/escape.d.ts +1 -0
- package/dist/internal/runtime/system-prompt/local-assembly.d.ts +2 -0
- package/dist/internal/runtime/system-prompt/native-reasoning.d.ts +25 -0
- package/dist/internal/runtime/system-prompt/pipeline.d.ts +1 -0
- package/dist/internal/runtime/system-prompt/safe-call.d.ts +1 -0
- package/dist/internal/runtime/system-prompt/sources/active-memory-provider.d.ts +1 -0
- package/dist/internal/runtime/system-prompt/sources/base-provider.d.ts +1 -0
- package/dist/internal/runtime/system-prompt/sources/context-provider.d.ts +1 -0
- package/dist/internal/runtime/system-prompt/sources/memory-provider.d.ts +6 -0
- package/dist/internal/runtime/system-prompt/sources/reasoning-provider.d.ts +1 -0
- package/dist/internal/runtime/system-prompt/sources/skills-provider.d.ts +1 -0
- package/dist/internal/runtime/system-prompt/system-prompt.d.ts +1 -0
- package/dist/internal/runtime/system-prompt/types.d.ts +5 -0
- package/dist/internal/runtime/tools/shell-tool.d.ts +7 -0
- package/dist/internal/runtime/validation/validate-agent-options.d.ts +1 -0
- package/dist/internal/runtime/validation/validate-response.d.ts +18 -0
- package/dist/internal/scorers/levenshtein.d.ts +11 -0
- package/dist/internal/scorers/llm-judge.d.ts +41 -0
- package/dist/internal/security/index.cjs +52 -0
- package/dist/internal/security/index.cjs.map +1 -0
- package/dist/internal/security/index.d.cts +19 -0
- package/dist/internal/security/index.d.ts +19 -0
- package/dist/internal/security/index.js +7 -0
- package/dist/internal/security/index.js.map +1 -0
- package/dist/internal/security/path-containment.d.cts +24 -0
- package/dist/internal/security/path-containment.d.ts +24 -0
- package/dist/internal/security/path-guard.d.cts +166 -0
- package/dist/internal/security/path-guard.d.ts +166 -0
- package/dist/internal/security/redact.d.cts +74 -0
- package/dist/internal/security/redact.d.ts +74 -0
- package/dist/internal/security/test-reset.d.cts +10 -0
- package/dist/internal/security/test-reset.d.ts +10 -0
- package/dist/internal/session/agent-session-store.d.ts +65 -0
- package/dist/internal/session/agent-session.d.ts +48 -0
- package/dist/internal/session/compact-session.d.ts +97 -0
- package/dist/internal/session/index.d.ts +7 -0
- package/dist/internal/session/inject-session.d.ts +15 -0
- package/dist/internal/session/session-cache.d.ts +31 -0
- package/dist/internal/session/types.d.ts +46 -0
- package/dist/internal/structured-output-helpers.d.ts +54 -0
- package/dist/internal/task/registry.d.ts +60 -0
- package/dist/internal/task/ring-buffer.d.ts +10 -0
- package/dist/internal/task/store.d.ts +145 -0
- package/dist/internal/task/subscribe.d.ts +15 -0
- package/dist/internal/task/task-id.d.ts +22 -0
- package/dist/internal/task/task-run-event-bridge.d.ts +10 -0
- package/dist/internal/task/telemetry.d.ts +27 -0
- package/dist/internal/telemetry/adapter-registry.d.ts +12 -0
- package/dist/internal/telemetry/adapters/arize.d.ts +2 -0
- package/dist/internal/telemetry/adapters/braintrust.d.ts +7 -0
- package/dist/internal/telemetry/adapters/datadog.d.ts +2 -0
- package/dist/internal/telemetry/adapters/langfuse.d.ts +2 -0
- package/dist/internal/telemetry/adapters/langsmith.d.ts +7 -0
- package/dist/internal/telemetry/adapters/posthog.d.ts +2 -0
- package/dist/internal/telemetry/adapters/sentry.d.ts +2 -0
- package/dist/internal/telemetry/safe-require.d.ts +1 -0
- package/dist/internal/telemetry/span-names.d.ts +10 -0
- package/dist/internal/telemetry/tracer-loader.d.ts +20 -0
- package/dist/internal/telemetry/tracer.d.ts +57 -0
- package/dist/internal/tool-dispatch/repair-middleware.d.ts +34 -0
- package/dist/internal/tool-dispatch/strip-think.d.ts +22 -0
- package/dist/internal/tool-registry/personality-filter.d.ts +37 -0
- package/dist/internal/workflow/ctx.d.ts +24 -0
- package/dist/internal/workflow/error-shape.d.ts +7 -0
- package/dist/internal/workflow/event-stream.d.ts +13 -0
- package/dist/internal/workflow/evented-executor.d.ts +42 -0
- package/dist/internal/workflow/executor-helpers.d.ts +30 -0
- package/dist/internal/workflow/executor.d.ts +16 -0
- package/dist/internal/workflow/retry-policy.d.ts +14 -0
- package/dist/internal/workflow/run-id.d.ts +9 -0
- package/dist/internal/workflow/scheduler.d.ts +23 -0
- package/dist/internal/workflow/single-flight.d.ts +18 -0
- package/dist/internal/workflow/snapshot-store.d.ts +23 -0
- package/dist/internal/workflow/step-agent.d.ts +12 -0
- package/dist/internal/workflow/step-branch.d.ts +10 -0
- package/dist/internal/workflow/step-dowhile.d.ts +8 -0
- package/dist/internal/workflow/step-execution.d.ts +25 -0
- package/dist/internal/workflow/step-fn.d.ts +10 -0
- package/dist/internal/workflow/step-foreach.d.ts +11 -0
- package/dist/internal/workflow/step-parallel.d.ts +17 -0
- package/dist/internal/workflow/step-sleep.d.ts +7 -0
- package/dist/internal/workflow/telemetry.d.ts +21 -0
- package/dist/internal/zod-to-json-schema.d.ts +11 -0
- package/dist/job-queue.d.ts +68 -0
- package/dist/judge-call-46M2E5FA.cjs +22 -0
- package/dist/judge-call-46M2E5FA.cjs.map +1 -0
- package/dist/judge-call-FGUNNWEI.js +5 -0
- package/dist/judge-call-FGUNNWEI.js.map +1 -0
- package/dist/mcp-auth.cjs +314 -0
- package/dist/mcp-auth.cjs.map +1 -0
- package/dist/mcp-auth.d.cts +19 -0
- package/dist/mcp-auth.d.ts +19 -0
- package/dist/mcp-auth.js +307 -0
- package/dist/mcp-auth.js.map +1 -0
- package/dist/messages.cjs +24 -0
- package/dist/messages.cjs.map +1 -0
- package/dist/messages.d.cts +33 -0
- package/dist/messages.d.ts +33 -0
- package/dist/messages.js +20 -0
- package/dist/messages.js.map +1 -0
- package/dist/models.cjs +295 -0
- package/dist/models.cjs.map +1 -0
- package/dist/models.d.cts +18 -0
- package/dist/models.d.ts +18 -0
- package/dist/models.js +286 -0
- package/dist/models.js.map +1 -0
- package/dist/oauth-transaction-store-5RIR6D5C.js +5 -0
- package/dist/oauth-transaction-store-5RIR6D5C.js.map +1 -0
- package/dist/oauth-transaction-store-SXIE57OD.cjs +38 -0
- package/dist/oauth-transaction-store-SXIE57OD.cjs.map +1 -0
- package/dist/path-safety.cjs +39 -0
- package/dist/path-safety.cjs.map +1 -0
- package/dist/path-safety.d.cts +16 -0
- package/dist/path-safety.d.ts +16 -0
- package/dist/path-safety.js +6 -0
- package/dist/path-safety.js.map +1 -0
- package/dist/permission-engine.d.ts +134 -0
- package/dist/persistence.cjs +197 -0
- package/dist/persistence.cjs.map +1 -0
- package/dist/persistence.d.cts +40 -0
- package/dist/persistence.d.ts +40 -0
- package/dist/persistence.js +100 -0
- package/dist/persistence.js.map +1 -0
- package/dist/project.cjs +45 -0
- package/dist/project.cjs.map +1 -0
- package/dist/project.d.cts +14 -0
- package/dist/project.d.ts +14 -0
- package/dist/project.js +42 -0
- package/dist/project.js.map +1 -0
- package/dist/provider-catalog.json +1295 -0
- package/dist/providers.cjs +23 -0
- package/dist/providers.cjs.map +1 -0
- package/dist/providers.d.cts +31 -0
- package/dist/providers.d.ts +31 -0
- package/dist/providers.js +10 -0
- package/dist/providers.js.map +1 -0
- package/dist/registry-BZQFYRTL.cjs +46 -0
- package/dist/registry-BZQFYRTL.cjs.map +1 -0
- package/dist/registry-DMWCJKRF.js +9 -0
- package/dist/registry-DMWCJKRF.js.map +1 -0
- package/dist/retry.cjs +14 -0
- package/dist/retry.cjs.map +1 -0
- package/dist/retry.d.cts +35 -0
- package/dist/retry.d.ts +35 -0
- package/dist/retry.js +5 -0
- package/dist/retry.js.map +1 -0
- package/dist/run-CTAdRU3U.d.cts +1813 -0
- package/dist/run-CTAdRU3U.d.ts +1813 -0
- package/dist/run-to-completion-DRO77625.js +3 -0
- package/dist/run-to-completion-DRO77625.js.map +1 -0
- package/dist/run-to-completion-X4OWM673.cjs +48 -0
- package/dist/run-to-completion-X4OWM673.cjs.map +1 -0
- package/dist/run-until-6D6TQ4JN.js +146 -0
- package/dist/run-until-6D6TQ4JN.js.map +1 -0
- package/dist/run-until-DG2KXWB2.cjs +149 -0
- package/dist/run-until-DG2KXWB2.cjs.map +1 -0
- package/dist/sandbox/bwrap.d.cts +112 -0
- package/dist/sandbox/bwrap.d.ts +112 -0
- package/dist/sandbox/index.cjs +495 -0
- package/dist/sandbox/index.cjs.map +1 -0
- package/dist/sandbox/index.d.cts +13 -0
- package/dist/sandbox/index.d.ts +13 -0
- package/dist/sandbox/index.js +451 -0
- package/dist/sandbox/index.js.map +1 -0
- package/dist/sandbox/linux-sandbox.d.cts +218 -0
- package/dist/sandbox/linux-sandbox.d.ts +218 -0
- package/dist/sandbox/local-sandbox.d.cts +66 -0
- package/dist/sandbox/local-sandbox.d.ts +66 -0
- package/dist/sandbox/provision.d.cts +60 -0
- package/dist/sandbox/provision.d.ts +60 -0
- package/dist/sandbox/seccomp.d.cts +16 -0
- package/dist/sandbox/seccomp.d.ts +16 -0
- package/dist/sandbox/shell-escape.d.cts +8 -0
- package/dist/sandbox/shell-escape.d.ts +8 -0
- package/dist/sandbox/types.d.cts +143 -0
- package/dist/sandbox/types.d.ts +143 -0
- package/dist/sanitize/coerce.d.cts +1 -0
- package/dist/sanitize/coerce.d.ts +1 -0
- package/dist/sanitize/index.cjs +12 -0
- package/dist/sanitize/index.cjs.map +1 -0
- package/dist/sanitize/index.d.cts +9 -0
- package/dist/sanitize/index.d.ts +9 -0
- package/dist/sanitize/index.js +3 -0
- package/dist/sanitize/index.js.map +1 -0
- package/dist/sanitize/sanitize-tool-input.d.cts +11 -0
- package/dist/sanitize/sanitize-tool-input.d.ts +11 -0
- package/dist/sanitize/types.d.cts +52 -0
- package/dist/sanitize/types.d.ts +52 -0
- package/dist/scorers.d.ts +181 -0
- package/dist/sdk-agent-BOiKqOgL.d.cts +940 -0
- package/dist/sdk-agent-D4a_BR_6.d.ts +940 -0
- package/dist/server/auth/errors.d.cts +54 -0
- package/dist/server/auth/errors.d.ts +54 -0
- package/dist/server/auth/index.cjs +210 -0
- package/dist/server/auth/index.cjs.map +1 -0
- package/dist/server/auth/index.d.cts +244 -0
- package/dist/server/auth/index.d.ts +244 -0
- package/dist/server/auth/index.js +189 -0
- package/dist/server/auth/index.js.map +1 -0
- package/dist/server/auth/oauth-transaction-store.d.cts +52 -0
- package/dist/server/auth/oauth-transaction-store.d.ts +52 -0
- package/dist/server/auth/orchestrator.d.cts +15 -0
- package/dist/server/auth/orchestrator.d.ts +15 -0
- package/dist/server/auth/types.d.cts +109 -0
- package/dist/server/auth/types.d.ts +109 -0
- package/dist/server/auth/validate-return-to.d.cts +27 -0
- package/dist/server/auth/validate-return-to.d.ts +27 -0
- package/dist/server/errors-envelope.cjs +101 -0
- package/dist/server/errors-envelope.cjs.map +1 -0
- package/dist/server/errors-envelope.d.cts +67 -0
- package/dist/server/errors-envelope.d.ts +67 -0
- package/dist/server/errors-envelope.js +95 -0
- package/dist/server/errors-envelope.js.map +1 -0
- package/dist/session-transcript-LGHSNVY5.cjs +62 -0
- package/dist/session-transcript-LGHSNVY5.cjs.map +1 -0
- package/dist/session-transcript-VTBTCGQX.js +5 -0
- package/dist/session-transcript-VTBTCGQX.js.map +1 -0
- package/dist/skills.cjs +25 -0
- package/dist/skills.cjs.map +1 -0
- package/dist/skills.d.cts +19 -0
- package/dist/skills.d.ts +19 -0
- package/dist/skills.js +8 -0
- package/dist/skills.js.map +1 -0
- package/dist/stream-object-HBFMIZLD.js +7 -0
- package/dist/stream-object-HBFMIZLD.js.map +1 -0
- package/dist/stream-object-QSKHISDJ.cjs +20 -0
- package/dist/stream-object-QSKHISDJ.cjs.map +1 -0
- package/dist/stream-object.d.ts +73 -0
- package/dist/stream-to-completion-QV5HCL3J.js +30 -0
- package/dist/stream-to-completion-QV5HCL3J.js.map +1 -0
- package/dist/stream-to-completion-SRISU5AB.cjs +32 -0
- package/dist/stream-to-completion-SRISU5AB.cjs.map +1 -0
- package/dist/subagents-loader-DOBTTICM.js +7 -0
- package/dist/subagents-loader-DOBTTICM.js.map +1 -0
- package/dist/subagents-loader-GEHYCMEX.cjs +16 -0
- package/dist/subagents-loader-GEHYCMEX.cjs.map +1 -0
- package/dist/subagents-loader.cjs +35 -0
- package/dist/subagents-loader.cjs.map +1 -0
- package/dist/subagents-loader.d.cts +90 -0
- package/dist/subagents-loader.d.ts +90 -0
- package/dist/subagents-loader.js +32 -0
- package/dist/subagents-loader.js.map +1 -0
- package/dist/subagents.cjs +18 -0
- package/dist/subagents.cjs.map +1 -0
- package/dist/subagents.d.cts +14 -0
- package/dist/subagents.d.ts +14 -0
- package/dist/subagents.js +15 -0
- package/dist/subagents.js.map +1 -0
- package/dist/subscription/define-subscription.d.cts +71 -0
- package/dist/subscription/define-subscription.d.ts +71 -0
- package/dist/subscription/index.cjs +408 -0
- package/dist/subscription/index.cjs.map +1 -0
- package/dist/subscription/index.d.cts +20 -0
- package/dist/subscription/index.d.ts +20 -0
- package/dist/subscription/index.js +400 -0
- package/dist/subscription/index.js.map +1 -0
- package/dist/subscription/internal/backpressure.d.cts +24 -0
- package/dist/subscription/internal/backpressure.d.ts +24 -0
- package/dist/subscription/internal/server-integration.d.cts +22 -0
- package/dist/subscription/internal/server-integration.d.ts +22 -0
- package/dist/subscription/internal/sse-encoder.d.cts +13 -0
- package/dist/subscription/internal/sse-encoder.d.ts +13 -0
- package/dist/subscription/internal/sse-parser.d.cts +15 -0
- package/dist/subscription/internal/sse-parser.d.ts +15 -0
- package/dist/subscription/internal/subscription-runtime.d.cts +21 -0
- package/dist/subscription/internal/subscription-runtime.d.ts +21 -0
- package/dist/subscription/internal/types.d.cts +11 -0
- package/dist/subscription/internal/types.d.ts +11 -0
- package/dist/subscription/internal/ws-adapter-node.d.cts +10 -0
- package/dist/subscription/internal/ws-adapter-node.d.ts +10 -0
- package/dist/subscription/theokit-subscribe.d.cts +54 -0
- package/dist/subscription/theokit-subscribe.d.ts +54 -0
- package/dist/subscription/types.d.cts +158 -0
- package/dist/subscription/types.d.ts +158 -0
- package/dist/task-errors.d.ts +58 -0
- package/dist/task-store.cjs +23 -0
- package/dist/task-store.cjs.map +1 -0
- package/dist/task-store.d.cts +10 -0
- package/dist/task-store.d.ts +10 -0
- package/dist/task-store.js +6 -0
- package/dist/task-store.js.map +1 -0
- package/dist/tool-error.d.ts +30 -0
- package/dist/types/agent-prims.d.ts +137 -0
- package/dist/types/agent.d.ts +947 -0
- package/dist/types/batch.d.ts +121 -0
- package/dist/types/budget-tracker.d.ts +80 -0
- package/dist/types/budget.d.ts +97 -0
- package/dist/types/content-blocks.d.ts +50 -0
- package/dist/types/context.d.ts +96 -0
- package/dist/types/conversation.d.ts +127 -0
- package/dist/types/cron.d.ts +172 -0
- package/dist/types/env-policy.d.ts +21 -0
- package/dist/types/eval.d.ts +255 -0
- package/dist/types/fork.d.ts +52 -0
- package/dist/types/goal-events.d.ts +144 -0
- package/dist/types/index.d.ts +19 -0
- package/dist/types/mcp.d.ts +90 -0
- package/dist/types/memory-adapter.d.ts +189 -0
- package/dist/types/memory-provider.d.ts +206 -0
- package/dist/types/messages-base.d.ts +24 -0
- package/dist/types/messages.d.ts +161 -0
- package/dist/types/plugin.d.ts +308 -0
- package/dist/types/processors.d.ts +87 -0
- package/dist/types/provider-profile.d.ts +116 -0
- package/dist/types/providers.d.ts +116 -0
- package/dist/types/run-events.d.ts +197 -0
- package/dist/types/run.d.ts +671 -0
- package/dist/types/sdk-agent.d.ts +342 -0
- package/dist/types/session-message.d.ts +62 -0
- package/dist/types/session-record.d.ts +103 -0
- package/dist/types/session-store.d.ts +104 -0
- package/dist/types/task.d.ts +146 -0
- package/dist/types/theokit.d.ts +73 -0
- package/dist/types/trajectory.d.ts +52 -0
- package/dist/types/updates.d.ts +184 -0
- package/dist/types/usage.d.ts +64 -0
- package/dist/types/workflow.d.ts +426 -0
- package/dist/workflow-as-tool.d.ts +66 -0
- package/dist/workflow-errors.d.ts +164 -0
- package/dist/workflow.cjs +100 -0
- package/dist/workflow.cjs.map +1 -0
- package/dist/workflow.d.cts +911 -0
- package/dist/workflow.d.ts +911 -0
- package/dist/workflow.js +11 -0
- package/dist/workflow.js.map +1 -0
- package/docs/adr/README.md +2604 -0
- package/docs/error-codes.md +253 -0
- package/docs/harness-capability-map.md +1435 -0
- package/docs/memory-decisions.md +265 -0
- package/package.json +455 -0
|
@@ -0,0 +1,671 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Owner: `internal/local-agent/` (8 of 34 importers). Derived from the import graph, not
|
|
3
|
+
* declared — `tests/lint/types-name-their-owner.test.ts` re-derives it.
|
|
4
|
+
*
|
|
5
|
+
*/
|
|
6
|
+
import type { CustomTool, ModelSelection, PermissionMode } from "./agent-prims.js";
|
|
7
|
+
import type { ConversationStep, ConversationTurn } from "./conversation.js";
|
|
8
|
+
import type { McpServerConfig } from "./mcp.js";
|
|
9
|
+
import type { SDKMessage } from "./messages.js";
|
|
10
|
+
import type { InteractionUpdate } from "./updates.js";
|
|
11
|
+
import type { CostBreakdown, TokenUsage } from "./usage.js";
|
|
12
|
+
/**
|
|
13
|
+
* Options for the tool-result guard (spotlighting + PII redaction on tool
|
|
14
|
+
* output). Contract type owned by `types/` (SE45 / D435) — the implementation
|
|
15
|
+
* lives in `internal/agent-loop/tool-result-guard.ts`, which re-exports this.
|
|
16
|
+
*
|
|
17
|
+
* @public
|
|
18
|
+
*/
|
|
19
|
+
export interface ToolResultGuardOptions {
|
|
20
|
+
/** Wrap tool-result content in explicit data boundaries (spotlighting). */
|
|
21
|
+
delimit?: boolean;
|
|
22
|
+
/** Redact common PII patterns (email, phone) in tool-result content. */
|
|
23
|
+
redactPii?: boolean;
|
|
24
|
+
}
|
|
25
|
+
/**
|
|
26
|
+
* Lifecycle status of a {@link Run}.
|
|
27
|
+
*
|
|
28
|
+
* @public
|
|
29
|
+
*/
|
|
30
|
+
export type RunStatus = "running" | "finished" | "error" | "cancelled";
|
|
31
|
+
/**
|
|
32
|
+
* Operations that may or may not be supported on a given {@link Run}, or on
|
|
33
|
+
* its parent agent.
|
|
34
|
+
*
|
|
35
|
+
* Runtime-specific availability — query at runtime with `run.supports(op)` and
|
|
36
|
+
* read the human reason via `run.unsupportedReason(op)`.
|
|
37
|
+
*
|
|
38
|
+
* @public
|
|
39
|
+
*/
|
|
40
|
+
export type RunOperation = "stream" | "wait" | "cancel" | "conversation" | "listArtifacts" | "downloadArtifact" | "runUntil" | "runToCompletion" | "streamToCompletion" | "fork" | "usePersonality" | "workflow";
|
|
41
|
+
/**
|
|
42
|
+
* Git metadata attached to cloud runs.
|
|
43
|
+
*
|
|
44
|
+
* @public
|
|
45
|
+
*/
|
|
46
|
+
export interface RunGitInfo {
|
|
47
|
+
branches: Array<{
|
|
48
|
+
repoUrl: string;
|
|
49
|
+
branch?: string;
|
|
50
|
+
prUrl?: string;
|
|
51
|
+
}>;
|
|
52
|
+
}
|
|
53
|
+
/**
|
|
54
|
+
* SE3 — provenance of the turn that produced a run: WHO triggered it. Metadata-only —
|
|
55
|
+
* it never changes routing or dispatch. Stamped in the multi-agent path (Squad / a2a /
|
|
56
|
+
* handoff / background-delegation) and forwarded onto {@link RunResult.origin}, so
|
|
57
|
+
* consumers can attribute/route turns by their trigger; discriminate on `kind`. Mirrors
|
|
58
|
+
* the Anthropic Agent SDK's `origin` shape.
|
|
59
|
+
*
|
|
60
|
+
* Producers: `peer` (Squad step / a2a envelope), `coordinator` (subagent delegation) and
|
|
61
|
+
* `auto-continuation` (the run-to-completion / stream-to-completion driver's continuation
|
|
62
|
+
* rounds) are stamped BY the SDK. `human` and `task-notification` are positive markers a
|
|
63
|
+
* HOST stamps (e.g. re-sending an agent after a background task completed).
|
|
64
|
+
*
|
|
65
|
+
* Encoding note (distinct from absence): an ABSENT origin (`undefined`) means the
|
|
66
|
+
* provenance was NOT stamped — the default for a plain `agent.send()`. The explicit
|
|
67
|
+
* `{ kind: "human" }` is a positive marker a HOST stamps to say "this turn is
|
|
68
|
+
* definitely from a human" (e.g. to distinguish a real user message from an
|
|
69
|
+
* un-attributed one in an audit UI). The two are not interchangeable: `undefined`
|
|
70
|
+
* = unknown/unstamped; `{ kind: "human" }` = explicitly human. Consumers writing an
|
|
71
|
+
* exhaustive `switch (origin?.kind)` therefore handle `undefined` (unstamped) and
|
|
72
|
+
* `"human"` (explicit) as separate, meaningful cases.
|
|
73
|
+
*
|
|
74
|
+
* @public
|
|
75
|
+
*/
|
|
76
|
+
export type MessageOrigin =
|
|
77
|
+
/** Explicitly a human-triggered turn — a positive marker a host stamps (NOT the
|
|
78
|
+
* same as an absent/unstamped origin, which is `undefined`). */
|
|
79
|
+
{
|
|
80
|
+
readonly kind: "human";
|
|
81
|
+
}
|
|
82
|
+
/** Another agent (a Squad peer or an a2a sender) triggered this turn. */
|
|
83
|
+
| {
|
|
84
|
+
readonly kind: "peer";
|
|
85
|
+
readonly from: string;
|
|
86
|
+
}
|
|
87
|
+
/** A background task's completion re-entered the agent as a follow-up turn. */
|
|
88
|
+
| {
|
|
89
|
+
readonly kind: "task-notification";
|
|
90
|
+
}
|
|
91
|
+
/** A delegating/handoff coordinator triggered this turn. `from` is the coordinator's
|
|
92
|
+
* id when known, omitted for an anonymous coordinator. */
|
|
93
|
+
| {
|
|
94
|
+
readonly kind: "coordinator";
|
|
95
|
+
readonly from?: string;
|
|
96
|
+
}
|
|
97
|
+
/** The loop's continuation driver re-sent to continue truncated work. */
|
|
98
|
+
| {
|
|
99
|
+
readonly kind: "auto-continuation";
|
|
100
|
+
};
|
|
101
|
+
/**
|
|
102
|
+
* Terminal result of a {@link Run}.
|
|
103
|
+
*
|
|
104
|
+
* @public
|
|
105
|
+
*/
|
|
106
|
+
export interface RunResult {
|
|
107
|
+
id: string;
|
|
108
|
+
status: "finished" | "error" | "cancelled";
|
|
109
|
+
result?: string;
|
|
110
|
+
/**
|
|
111
|
+
* SE24 — set when a guardrail processor called `abort()`. The run stops
|
|
112
|
+
* (`status: "cancelled"`) and `tripwire` carries the blocking reason +
|
|
113
|
+
* processor id. `undefined` on every non-guardrail outcome. A
|
|
114
|
+
* `throwOnError: true` agent resolves normally on a tripwire (status is
|
|
115
|
+
* `"cancelled"`, not `"error"`). On an OUTPUT block the model already ran, so
|
|
116
|
+
* `usage`/`cost` survive (billing) while `result` is suppressed; an INPUT
|
|
117
|
+
* block never reaches the model, so `usage` is absent.
|
|
118
|
+
*
|
|
119
|
+
* @public
|
|
120
|
+
*/
|
|
121
|
+
tripwire?: import("./processors.js").ProcessorTripwire;
|
|
122
|
+
model?: ModelSelection;
|
|
123
|
+
durationMs?: number;
|
|
124
|
+
git?: RunGitInfo;
|
|
125
|
+
/**
|
|
126
|
+
* SE3 — provenance forwarded from {@link SendOptions.origin}: who triggered
|
|
127
|
+
* this turn (human / peer / task-notification / coordinator / auto-continuation).
|
|
128
|
+
* `undefined` means the provenance was not stamped (a plain `agent.send()`).
|
|
129
|
+
* Metadata-only — never affects routing.
|
|
130
|
+
*
|
|
131
|
+
* @public
|
|
132
|
+
*/
|
|
133
|
+
origin?: MessageOrigin;
|
|
134
|
+
/**
|
|
135
|
+
* Structured error detail, populated when `status === "error"`. Surfaces
|
|
136
|
+
* the diagnostic that emit-error-event pushes into the stream so callers
|
|
137
|
+
* that don't drain `run.stream()` still get the cause via `run.wait()`.
|
|
138
|
+
*
|
|
139
|
+
* For successful runs (`status: "finished"`) this is undefined.
|
|
140
|
+
*
|
|
141
|
+
* @public
|
|
142
|
+
*/
|
|
143
|
+
error?: RunErrorDetail;
|
|
144
|
+
/**
|
|
145
|
+
* Token usage observed for this run (ADR D376). Populated in every
|
|
146
|
+
* status where ≥1 LLM call COMPLETED — including partial-failure
|
|
147
|
+
* runs (EC-5). `undefined` when zero LLM calls executed (e.g. an
|
|
148
|
+
* abort before send) and, for the same reason, when the only call was
|
|
149
|
+
* cut mid-stream: the counts arrive with the provider's terminating
|
|
150
|
+
* frame, which a severed connection never delivers. Such a run can
|
|
151
|
+
* therefore return partial text (#371) with no usage to bill it
|
|
152
|
+
* against — the tokens were generated and are not reported here.
|
|
153
|
+
*
|
|
154
|
+
* @public
|
|
155
|
+
*/
|
|
156
|
+
usage?: TokenUsage;
|
|
157
|
+
/**
|
|
158
|
+
* Estimated/actual USD cost for this run (ADR D377). Always paired
|
|
159
|
+
* with `usage` when populated. `cost.status` tells caller how to
|
|
160
|
+
* trust the figure.
|
|
161
|
+
*
|
|
162
|
+
* @public
|
|
163
|
+
*/
|
|
164
|
+
cost?: CostBreakdown;
|
|
165
|
+
/**
|
|
166
|
+
* M1-2: `true` when the run stopped because the agent loop hit its iteration
|
|
167
|
+
* ceiling (`SendOptions.maxIterations` or the default of 8) while the model
|
|
168
|
+
* still wanted to call tools — i.e. the work was silently truncated rather
|
|
169
|
+
* than finished. `undefined`/absent on a clean finish. A continuation driver
|
|
170
|
+
* (or a careful caller) inspects this to decide whether to send again.
|
|
171
|
+
*
|
|
172
|
+
* @public
|
|
173
|
+
*/
|
|
174
|
+
stoppedAtIterationLimit?: boolean;
|
|
175
|
+
/**
|
|
176
|
+
* `true` when the run stopped because the **doom-loop guard** detected the model repeating
|
|
177
|
+
* IDENTICAL tool calls (same name + same input) to the hard threshold — making no progress (e.g.
|
|
178
|
+
* a tool that keeps failing and is retried unchanged). `undefined`/absent otherwise. Through the
|
|
179
|
+
* continuation driver this surfaces as `terminal: "no_progress"` (a controlled stop, NOT a
|
|
180
|
+
* truncation to re-send). Tune or disable via {@link SendOptions.doomLoop}.
|
|
181
|
+
*
|
|
182
|
+
* @public
|
|
183
|
+
*/
|
|
184
|
+
stoppedByDoomLoop?: boolean;
|
|
185
|
+
/**
|
|
186
|
+
* SE34 — the per-send completion verdict, populated when
|
|
187
|
+
* {@link SendOptions.completionCheck} was set AND the run finished. Absent on
|
|
188
|
+
* non-finished runs and when no completion check was requested. Reuses the
|
|
189
|
+
* shipped LLM-as-judge (same one `runUntil` drives). @public
|
|
190
|
+
*/
|
|
191
|
+
completionCheck?: CompletionCheckResult;
|
|
192
|
+
}
|
|
193
|
+
/**
|
|
194
|
+
* Doom-loop guard thresholds (see {@link SendOptions.doomLoop}). Both are counts of CONSECUTIVE
|
|
195
|
+
* identical tool calls: `softThreshold` injects a one-time guidance nudge; `hardThreshold` stops.
|
|
196
|
+
*
|
|
197
|
+
* @public
|
|
198
|
+
*/
|
|
199
|
+
export interface DoomLoopThresholds {
|
|
200
|
+
/** Consecutive-identical count at which a one-time guidance nudge is injected. Default 3. */
|
|
201
|
+
softThreshold?: number;
|
|
202
|
+
/** Consecutive-identical count at which the run stops (`no_progress`). Default 5. */
|
|
203
|
+
hardThreshold?: number;
|
|
204
|
+
}
|
|
205
|
+
/**
|
|
206
|
+
* Options for {@link SDKAgent.runToCompletion} (M1 Phase 3 — continuation driver).
|
|
207
|
+
*
|
|
208
|
+
* @public
|
|
209
|
+
*/
|
|
210
|
+
export interface RunToCompletionOptions {
|
|
211
|
+
/**
|
|
212
|
+
* Maximum number of continuation rounds (re-sends) before giving up with
|
|
213
|
+
* `terminal: "step_limit"`. Default 5. A hard ceiling that prevents a
|
|
214
|
+
* runaway loop when the model keeps truncating.
|
|
215
|
+
*/
|
|
216
|
+
maxRounds?: number;
|
|
217
|
+
/**
|
|
218
|
+
* The short prompt re-sent after a truncated round to make the (stateful)
|
|
219
|
+
* agent resume. Defaults to a generic "continue" instruction. The original
|
|
220
|
+
* conversation is preserved by the agent's session, so this need not repeat
|
|
221
|
+
* the task.
|
|
222
|
+
*/
|
|
223
|
+
continuationPrompt?: string;
|
|
224
|
+
/** Called once per truncated round that triggers a re-send (for metrics/logging). */
|
|
225
|
+
onTruncated?: (event: {
|
|
226
|
+
round: number;
|
|
227
|
+
}) => void | Promise<void>;
|
|
228
|
+
/** Abort signal; checked between rounds — once aborted, no further round starts. */
|
|
229
|
+
signal?: AbortSignal;
|
|
230
|
+
/** Per-send options forwarded to each underlying `send()` (e.g. `maxIterations`). */
|
|
231
|
+
sendOptions?: SendOptions;
|
|
232
|
+
}
|
|
233
|
+
/**
|
|
234
|
+
* Result of {@link SDKAgent.runToCompletion}.
|
|
235
|
+
*
|
|
236
|
+
* @public
|
|
237
|
+
*/
|
|
238
|
+
export interface RunToCompletionResult {
|
|
239
|
+
/**
|
|
240
|
+
* Why the driver stopped:
|
|
241
|
+
* - `"done"` — a round finished without truncating (the model is done).
|
|
242
|
+
* - `"step_limit"` — `maxRounds` exhausted (or aborted) while still truncating.
|
|
243
|
+
* - `"no_progress"` — two consecutive rounds produced empty output.
|
|
244
|
+
*/
|
|
245
|
+
terminal: "done" | "step_limit" | "no_progress";
|
|
246
|
+
/**
|
|
247
|
+
* Index of the final round. Round 0 is the initial `send`; rounds ≥ 1 are
|
|
248
|
+
* continuation re-sends. So `terminal: "done"` with `rounds: 0` means the
|
|
249
|
+
* first send finished without truncating; `rounds: N` means N continuation
|
|
250
|
+
* re-sends happened. For `step_limit`, `rounds` equals `maxRounds`.
|
|
251
|
+
*/
|
|
252
|
+
rounds: number;
|
|
253
|
+
/** The `RunResult` of the final round. */
|
|
254
|
+
lastResult: RunResult;
|
|
255
|
+
/** Token usage summed across all rounds; `undefined` when no round reported usage. */
|
|
256
|
+
usage?: TokenUsage;
|
|
257
|
+
}
|
|
258
|
+
/**
|
|
259
|
+
* Result of {@link SDKAgent.streamToCompletion} (V3-4 — the STREAMING continuation
|
|
260
|
+
* driver). Same shape + terminal semantics as {@link RunToCompletionResult}; it is
|
|
261
|
+
* the generator's RETURN value (read it via a manual `gen.next()` loop — a plain
|
|
262
|
+
* `for await...of` consumes the yielded `SDKMessage`s but discards this return value).
|
|
263
|
+
*
|
|
264
|
+
* @public
|
|
265
|
+
*/
|
|
266
|
+
export type StreamToCompletionResult = RunToCompletionResult;
|
|
267
|
+
/**
|
|
268
|
+
* Structured error attached to a {@link RunResult} when the underlying run
|
|
269
|
+
* transitioned to `"error"` status. `message` is always present; `code` is
|
|
270
|
+
* a stable identifier suitable for branching (e.g. `"llm_4xx"`,
|
|
271
|
+
* `"tool_dispatch_failed"`, `"mcp_init_failed"`); `cause` is the raw error
|
|
272
|
+
* for further inspection when available.
|
|
273
|
+
*
|
|
274
|
+
* @public
|
|
275
|
+
*/
|
|
276
|
+
export interface RunErrorDetail {
|
|
277
|
+
message: string;
|
|
278
|
+
code?: string;
|
|
279
|
+
cause?: unknown;
|
|
280
|
+
}
|
|
281
|
+
/**
|
|
282
|
+
* Dimensions of an inline image attachment.
|
|
283
|
+
*
|
|
284
|
+
* @public
|
|
285
|
+
*/
|
|
286
|
+
export interface SDKImageDimension {
|
|
287
|
+
width: number;
|
|
288
|
+
height: number;
|
|
289
|
+
}
|
|
290
|
+
/**
|
|
291
|
+
* Either a remote URL or inline base64 payload.
|
|
292
|
+
*
|
|
293
|
+
* @public
|
|
294
|
+
*/
|
|
295
|
+
export type SDKImage = {
|
|
296
|
+
url: string;
|
|
297
|
+
dimension?: SDKImageDimension;
|
|
298
|
+
} | {
|
|
299
|
+
data: string;
|
|
300
|
+
mimeType: string;
|
|
301
|
+
dimension?: SDKImageDimension;
|
|
302
|
+
};
|
|
303
|
+
/**
|
|
304
|
+
* Structured form of `agent.send()`'s message argument. Use it to send images
|
|
305
|
+
* alongside text.
|
|
306
|
+
*
|
|
307
|
+
* @public
|
|
308
|
+
*/
|
|
309
|
+
export interface SDKUserMessage {
|
|
310
|
+
text: string;
|
|
311
|
+
images?: SDKImage[];
|
|
312
|
+
}
|
|
313
|
+
/**
|
|
314
|
+
* Per-send overrides and callbacks.
|
|
315
|
+
*
|
|
316
|
+
* ## Which options do I need?
|
|
317
|
+
*
|
|
318
|
+
* Twenty-one optional fields with genuinely different audiences, so most callers read all of them to
|
|
319
|
+
* find their two. This table is the fix that was chosen; the alternative — nesting the groups under
|
|
320
|
+
* `observe?` and `toolPolicy?` and carrying the flat keys as deprecated aliases for one major — would
|
|
321
|
+
* have added surface to remove surface, and the harm here is the READING cost, not a representable
|
|
322
|
+
* illegal state. There is no measured defect behind this grouping and no consumer census; the fields
|
|
323
|
+
* and the audiences are what was measured.
|
|
324
|
+
*
|
|
325
|
+
* | If you are… | you want |
|
|
326
|
+
* |---|---|
|
|
327
|
+
* | rendering a live UI | `onDelta`, `onStep`, `onRunEvent` |
|
|
328
|
+
* | applying a policy | `permissionMode`, `activeTools`, `toolChoice`, `toolResultGuard`, `perToolTimeoutMs` |
|
|
329
|
+
* | running an eval or a harness | `maxIterations`, `completionCheck`, `doomLoop`, `signal` |
|
|
330
|
+
* | orchestrating agents | `origin`, `task`, `context` |
|
|
331
|
+
* | overriding this one send | `model`, `systemPrompt`, `tools`, `mcpServers`, `contextPaths`, `local` |
|
|
332
|
+
*
|
|
333
|
+
* Every field appears in exactly one row, and
|
|
334
|
+
* `tests/lint/send-options-audience-table.test.ts` fails when one is added without a row — a table
|
|
335
|
+
* that silently stops covering the type is worse than none, because a reader trusts it and stops
|
|
336
|
+
* looking.
|
|
337
|
+
*
|
|
338
|
+
* @public
|
|
339
|
+
*/
|
|
340
|
+
export interface SendOptions {
|
|
341
|
+
/**
|
|
342
|
+
* Per-send model override. SE8 — accepts a bare-string id shorthand
|
|
343
|
+
* (`"openai/gpt-4o-mini"`, normalized to `{ id }`) OR a {@link ModelSelection}
|
|
344
|
+
* object (use the object form to pass `params`).
|
|
345
|
+
*/
|
|
346
|
+
model?: string | ModelSelection;
|
|
347
|
+
/**
|
|
348
|
+
* SE3 — provenance of this turn (who triggered it). Stamped by the multi-agent
|
|
349
|
+
* path (Squad peer, a2a sender, coordinator/handoff, background task-notification)
|
|
350
|
+
* and forwarded onto {@link RunResult.origin}. Metadata-only — the value never
|
|
351
|
+
* changes routing or dispatch. Omit to leave the turn un-attributed; a host may
|
|
352
|
+
* pass `{ kind: "human" }` to positively mark a human turn.
|
|
353
|
+
*/
|
|
354
|
+
origin?: MessageOrigin;
|
|
355
|
+
/**
|
|
356
|
+
* SE2 — opt-in typed runtime-EVENT sink. Receives out-of-band `RunEvent`s
|
|
357
|
+
* (permission_denied, tool_progress, rate_limit, task_*, compact_boundary) for
|
|
358
|
+
* observability, ADDITIVE to the `SDKMessage` content stream. Best-effort: a
|
|
359
|
+
* throwing sink never breaks the run. Discriminate on `event.type`.
|
|
360
|
+
*/
|
|
361
|
+
onRunEvent?: import("./run-events.js").RunEventSink;
|
|
362
|
+
/**
|
|
363
|
+
* Doom-loop guard config. The loop stops (with `terminal: "no_progress"`, `RunResult.stoppedByDoomLoop`)
|
|
364
|
+
* when the model repeats IDENTICAL tool calls to the hard threshold. On by default with generous
|
|
365
|
+
* thresholds (soft 3 / hard 5). Set `false` to disable, or an object to tune the thresholds.
|
|
366
|
+
*/
|
|
367
|
+
doomLoop?: false | DoomLoopThresholds;
|
|
368
|
+
/**
|
|
369
|
+
* Per-call system prompt override. Wins over `AgentOptions.systemPrompt`.
|
|
370
|
+
* String only — for dynamic resolvers, configure on `AgentOptions`. An
|
|
371
|
+
* empty string is honoured (it explicitly clears the system context).
|
|
372
|
+
*/
|
|
373
|
+
systemPrompt?: string;
|
|
374
|
+
/** Fully replaces creation-time servers for this run (not merged). */
|
|
375
|
+
mcpServers?: Record<string, McpServerConfig>;
|
|
376
|
+
/**
|
|
377
|
+
* Per-call inline custom tools. Fully replaces `AgentOptions.tools` for
|
|
378
|
+
* this run (not merged). Local runtime only — cloud agents reject any
|
|
379
|
+
* non-empty per-call tools array with the same error code as creation
|
|
380
|
+
* (`cloud_custom_tools_rejected`). Semantics:
|
|
381
|
+
* - `undefined` → fall back to `AgentOptions.tools`
|
|
382
|
+
* - `[]` → explicitly clear (no custom tools for this run)
|
|
383
|
+
* - `[t1, t2]` → use exactly these tools for this run
|
|
384
|
+
*/
|
|
385
|
+
tools?: CustomTool[];
|
|
386
|
+
/**
|
|
387
|
+
* The set of repo-relative file paths in scope for THIS send (local runtime).
|
|
388
|
+
* Declares "which files am I working on" so path-scoped rule files
|
|
389
|
+
* (`.theokit/rules/*.md` with `paths:`/`globs:`, and `.cursor/rules/*.mdc`
|
|
390
|
+
* globs) activate when a pattern matches one of these paths. `alwaysApply`
|
|
391
|
+
* rules load regardless. Omit ⇒ only unconditional rules load (the create-time
|
|
392
|
+
* snapshot is untouched). Matching is glob-based (`**`, `*`, `?`).
|
|
393
|
+
*/
|
|
394
|
+
contextPaths?: readonly string[];
|
|
395
|
+
/**
|
|
396
|
+
* SE1 — the permission mode for THIS run, threaded to a registered
|
|
397
|
+
* `PermissionPlugin`'s pre-tool gate. Precedence: this per-send value wins over
|
|
398
|
+
* `AgentOptions.permissionMode` (creation-time default). Modes: `default` (rules
|
|
399
|
+
* decide; unmatched ⇒ fail-closed ask), `plan` (read-only — allow rules pass,
|
|
400
|
+
* everything else denied), `acceptEdits` (auto-approve unmatched, honor explicit
|
|
401
|
+
* ask rules), `bypass` / `bypassPermissions` (allow all except an explicit deny).
|
|
402
|
+
* Absent ⇒ the plugin's own construction-time mode applies. Local runtime.
|
|
403
|
+
*/
|
|
404
|
+
permissionMode?: PermissionMode;
|
|
405
|
+
onStep?: (args: {
|
|
406
|
+
step: ConversationStep;
|
|
407
|
+
}) => void | Promise<void>;
|
|
408
|
+
onDelta?: (args: {
|
|
409
|
+
update: InteractionUpdate;
|
|
410
|
+
}) => void | Promise<void>;
|
|
411
|
+
/**
|
|
412
|
+
* Per-call tool gate (OpenAI/OpenRouter `tool_choice`). `"none"` forces a text answer even when
|
|
413
|
+
* the agent has tools registered — used by an agent loop to force a closing summary at its step
|
|
414
|
+
* ceiling (a cached agent's tools cannot be un-registered, so the gate is per-send). `"required"`
|
|
415
|
+
* forces a tool call; `"auto"` (or omitted) is the default. Local runtime; OpenAI-compat providers.
|
|
416
|
+
*/
|
|
417
|
+
toolChoice?: "auto" | "none" | "required";
|
|
418
|
+
/**
|
|
419
|
+
* SE18 — per-send runtime tool subset (**local runtime only**; cloud agents
|
|
420
|
+
* ignore it). When set, only tools whose name is in this list may be called for
|
|
421
|
+
* this send; a call to any other registered tool is vetoed at dispatch (the same
|
|
422
|
+
* `withToolWhitelist` path `Agent.fork`'s `allowedTools` uses — NOT
|
|
423
|
+
* `PermissionEngine`). Composes with `toolChoice`: `activeTools` narrows the set,
|
|
424
|
+
* `toolChoice` gates calling within it. Absent ⇒ the full toolset is available.
|
|
425
|
+
*
|
|
426
|
+
* Matching is EXACT against the tool's registered name — the same name the
|
|
427
|
+
* dispatch sees after tool-name repair (mirrors `Agent.fork`'s `allowedTools`;
|
|
428
|
+
* it is NOT lowercased for you, so a mixed-case registered tool needs its exact
|
|
429
|
+
* registered name here). An empty list (`[]`) vetoes EVERY tool (fail-closed —
|
|
430
|
+
* "restrict to the empty set"); pass `undefined` (or omit) for no restriction.
|
|
431
|
+
* A subagent invoked within this send inherits the whitelist via async-context
|
|
432
|
+
* propagation unless it declares its own tool scope.
|
|
433
|
+
*/
|
|
434
|
+
activeTools?: string[];
|
|
435
|
+
/** Local agents only. Expire a stuck active run before starting this message. */
|
|
436
|
+
local?: {
|
|
437
|
+
force?: boolean;
|
|
438
|
+
};
|
|
439
|
+
/**
|
|
440
|
+
* Optional `AbortSignal` propagated to memory adapter `pre_user_send`
|
|
441
|
+
* hooks (EC-H). Note: the LLM HTTP call itself is NOT cancellable
|
|
442
|
+
* mid-stream — same constraint as `Agent.batch` (ADR D140).
|
|
443
|
+
*
|
|
444
|
+
* @public
|
|
445
|
+
*/
|
|
446
|
+
signal?: AbortSignal;
|
|
447
|
+
/**
|
|
448
|
+
* M7 — an opaque user `context` forwarded to every tool handler's `ctx.context`
|
|
449
|
+
* for this run. Set shared config (e.g. `projectRoot`) once here instead of
|
|
450
|
+
* baking it into each tool factory (mirrors a framework `experimental_context`,
|
|
451
|
+
* a peer framework `RuntimeContext`, a peer SDK `RunContext`).
|
|
452
|
+
*
|
|
453
|
+
* @public
|
|
454
|
+
*/
|
|
455
|
+
context?: unknown;
|
|
456
|
+
/**
|
|
457
|
+
* #58 — per-tool execution timeout in ms. Each tool call is bounded by this
|
|
458
|
+
* deadline (merged with `signal`); a hung tool yields a typed timeout result
|
|
459
|
+
* (exit 124) instead of wedging the run. Undefined = no per-tool timeout.
|
|
460
|
+
*
|
|
461
|
+
* @public
|
|
462
|
+
*/
|
|
463
|
+
perToolTimeoutMs?: number;
|
|
464
|
+
/**
|
|
465
|
+
* #57 — opt-in tool-result content guard applied before tool output reaches
|
|
466
|
+
* the LLM. `{ delimit: true }` frames untrusted tool output as data
|
|
467
|
+
* (prompt-injection mitigation); `{ redactPii: true }` redacts email/phone.
|
|
468
|
+
* Undefined = no guard.
|
|
469
|
+
*
|
|
470
|
+
* @public
|
|
471
|
+
*/
|
|
472
|
+
toolResultGuard?: ToolResultGuardOptions;
|
|
473
|
+
/**
|
|
474
|
+
* Opt-in task wrapping (ADRs D363, D374). When truthy, the entire
|
|
475
|
+
* run is registered as a `Task` in the SDK's observable registry —
|
|
476
|
+
* caller can list / inspect / cancel / subscribe via the `Task`
|
|
477
|
+
* namespace. Default behavior (no `task` option) is byte-identical
|
|
478
|
+
* to v1.1 (no Task overhead).
|
|
479
|
+
*
|
|
480
|
+
* Accepts:
|
|
481
|
+
* - `true` — auto-generate task id; no extra metadata.
|
|
482
|
+
* - `{ id, meta }` — user-supplied id (D368 grammar enforced) and/or
|
|
483
|
+
* metadata attached to the handle's `meta` field.
|
|
484
|
+
*
|
|
485
|
+
* The work-fn `signal` is **merged** with `options.signal` (whichever
|
|
486
|
+
* aborts first wins). Local agents only — CloudAgent throws
|
|
487
|
+
* `UnsupportedTaskOperationError` (D370).
|
|
488
|
+
*
|
|
489
|
+
* @public
|
|
490
|
+
*/
|
|
491
|
+
task?: true | {
|
|
492
|
+
id?: string;
|
|
493
|
+
meta?: Record<string, unknown>;
|
|
494
|
+
};
|
|
495
|
+
/**
|
|
496
|
+
* Per-send ceiling on the agent loop's tool-calling turns (M1-2). Raises (or
|
|
497
|
+
* lowers) the default cap of 8 for this single send — useful when one heavy
|
|
498
|
+
* task needs more rounds than the agent's default. Must be a positive
|
|
499
|
+
* integer; invalid values throw `ConfigurationError` at the boundary. When
|
|
500
|
+
* unset, the loop uses the default of 8.
|
|
501
|
+
*
|
|
502
|
+
* @public
|
|
503
|
+
*/
|
|
504
|
+
maxIterations?: number;
|
|
505
|
+
/**
|
|
506
|
+
* SE34 — per-send completion check (`isTaskComplete`). After this single
|
|
507
|
+
* `send()` reaches a terminal `finished` state, the shipped LLM-as-judge
|
|
508
|
+
* scores the final reply against `criteria` and surfaces the verdict on
|
|
509
|
+
* {@link RunResult.completionCheck} + a `completion_check` run-event. This is
|
|
510
|
+
* the finer-grained, single-`send()` gate (contrast `runUntil`, which judges
|
|
511
|
+
* the FULL response BETWEEN sends). Opt-in — absent ⇒ the send is byte-identical
|
|
512
|
+
* to today (no extra judge call). Non-finished runs skip the check. The judge
|
|
513
|
+
* runs when `wait()` is called on the returned `Run`; a stream-only consumer
|
|
514
|
+
* must call `wait()` to trigger the verdict + the `completion_check` event.
|
|
515
|
+
*
|
|
516
|
+
* @public
|
|
517
|
+
*/
|
|
518
|
+
completionCheck?: CompletionCheck;
|
|
519
|
+
}
|
|
520
|
+
/**
|
|
521
|
+
* SE34 — the per-send completion criterion (see {@link SendOptions.completionCheck}).
|
|
522
|
+
*
|
|
523
|
+
* @public
|
|
524
|
+
*/
|
|
525
|
+
export interface CompletionCheck {
|
|
526
|
+
/** What "complete" means for this send — fed to the judge as the goal. */
|
|
527
|
+
criteria: string;
|
|
528
|
+
/** Judge model identifier. Default `"openai/gpt-4o-mini"`. */
|
|
529
|
+
judgeModel?: string;
|
|
530
|
+
/** Override env for the judge auxiliary agent. Default `OPENROUTER_API_KEY`. */
|
|
531
|
+
apiKey?: string;
|
|
532
|
+
}
|
|
533
|
+
/**
|
|
534
|
+
* SE34 — the resolved per-send completion verdict (see {@link RunResult.completionCheck}).
|
|
535
|
+
*
|
|
536
|
+
* @public
|
|
537
|
+
*/
|
|
538
|
+
export interface CompletionCheckResult {
|
|
539
|
+
/** `true` when the judge ruled the send's reply satisfies the criteria. */
|
|
540
|
+
complete: boolean;
|
|
541
|
+
/** The judge's stated reason. */
|
|
542
|
+
reason: string;
|
|
543
|
+
/** `true` when the judge output could not be parsed — fail-safe `complete: false`. */
|
|
544
|
+
parseFailed: boolean;
|
|
545
|
+
}
|
|
546
|
+
/**
|
|
547
|
+
* theokit#140 - one element of {@link Run.events}: either a structural SDK message or a live delta.
|
|
548
|
+
*
|
|
549
|
+
* A discriminated union rather than a widened `SDKMessage`, because a token delta is not a message
|
|
550
|
+
* and pretending otherwise would force every consumer to guess which of the two it is holding.
|
|
551
|
+
*
|
|
552
|
+
* @public
|
|
553
|
+
*/
|
|
554
|
+
export type RunTimelineEvent = {
|
|
555
|
+
kind: "message";
|
|
556
|
+
message: SDKMessage;
|
|
557
|
+
/**
|
|
558
|
+
* theokit#140 - `true` when this message's TEXT content already crossed the timeline as
|
|
559
|
+
* `kind: "delta"` events. Absent when the question does not apply (no text to duplicate).
|
|
560
|
+
*
|
|
561
|
+
* Unifying the source fixed ordering and the `callId` namespace; it did NOT stop the same
|
|
562
|
+
* text arriving twice, because the run's event log carries the complete assistant message and
|
|
563
|
+
* the deltas are additional. Without this field a consumer has to infer the relation by
|
|
564
|
+
* COMPARING TEXT - which is where the `callId`-namespace and timestamp-fallback bugs came
|
|
565
|
+
* from. The SDK emitted the deltas and emits the message from the same scope, so it knows the
|
|
566
|
+
* answer as a fact; stating it replaces the inference with a boolean.
|
|
567
|
+
*
|
|
568
|
+
* Marked rather than suppressed: the message also carries tool calls and metadata, so
|
|
569
|
+
* dropping it would trade a duplicate for a hole. Optional, so no existing consumer breaks.
|
|
570
|
+
*/
|
|
571
|
+
textAlreadyStreamed?: boolean;
|
|
572
|
+
} | {
|
|
573
|
+
kind: "delta";
|
|
574
|
+
update: import("./updates.js").InteractionUpdate;
|
|
575
|
+
};
|
|
576
|
+
/**
|
|
577
|
+
* Handle to a single prompt submission, returned by `agent.send()` before the model has answered.
|
|
578
|
+
*
|
|
579
|
+
* It is a live handle rather than a result — `status` is `"running"` when you receive it — and how
|
|
580
|
+
* you consume the turn is the decision it asks of you. Call `wait()` when only the final answer
|
|
581
|
+
* matters. Call `events()` when you want the whole timeline: structural messages and token/tool
|
|
582
|
+
* deltas interleaved in true order, from one source. That is the one to reach for instead of fusing
|
|
583
|
+
* `stream()` with `SendOptions.onDelta` yourself, which is what produced the ordering and
|
|
584
|
+
* duplicate-text bugs it replaces. `stream()` remains the SDKMessage-only view, and
|
|
585
|
+
* `conversation()` returns the finished turn grouped per turn instead of as a stream.
|
|
586
|
+
*
|
|
587
|
+
* `cancel()` moves the run to `"cancelled"`, aborts the stream and stops in-flight tool calls.
|
|
588
|
+
*
|
|
589
|
+
* Not every method is available on every runtime — see {@link RunOperation}. Ask `supports(op)`
|
|
590
|
+
* before calling an optional one and surface `unsupportedReason(op)`, rather than calling it and
|
|
591
|
+
* catching. The optional fields (`result`, `model`, `durationMs`, `git`, `createdAt`) fill in as the
|
|
592
|
+
* run progresses, so treat their absence as "not yet", not as an error.
|
|
593
|
+
*/
|
|
594
|
+
export interface Run {
|
|
595
|
+
readonly id: string;
|
|
596
|
+
readonly agentId: string;
|
|
597
|
+
readonly status: RunStatus;
|
|
598
|
+
readonly result?: string;
|
|
599
|
+
readonly model?: ModelSelection;
|
|
600
|
+
readonly durationMs?: number;
|
|
601
|
+
readonly git?: RunGitInfo;
|
|
602
|
+
readonly createdAt?: number;
|
|
603
|
+
/** AsyncGenerator of normalized stream events. Discriminate on `event.type`. */
|
|
604
|
+
stream(): AsyncGenerator<SDKMessage, void>;
|
|
605
|
+
/**
|
|
606
|
+
* theokit#140 - every event of this run in TRUE order, from one source: structural messages and
|
|
607
|
+
* live token/tool deltas interleaved as they occurred.
|
|
608
|
+
*
|
|
609
|
+
* Use this instead of fusing `stream()` with `SendOptions.onDelta` by hand. Neither of those is
|
|
610
|
+
* complete alone - `onDelta` carries no `run_started`/`system`, `stream()` carries no token
|
|
611
|
+
* granularity - and reconciling them in the consumer is what produced the ordering and dedup
|
|
612
|
+
* bugs this replaces.
|
|
613
|
+
*
|
|
614
|
+
* `stream()` is unchanged and remains the SDKMessage-only view.
|
|
615
|
+
*/
|
|
616
|
+
events(): AsyncGenerator<RunTimelineEvent, void>;
|
|
617
|
+
/** Resolves to the terminal {@link RunResult}. */
|
|
618
|
+
wait(): Promise<RunResult>;
|
|
619
|
+
/** Move status to `"cancelled"`, abort the stream, stop in-flight tool calls. */
|
|
620
|
+
cancel(): Promise<void>;
|
|
621
|
+
/** Structured per-turn view of the conversation. */
|
|
622
|
+
conversation(): Promise<ConversationTurn[]>;
|
|
623
|
+
/** Whether the given operation is available on this run's runtime. */
|
|
624
|
+
supports(operation: RunOperation): boolean;
|
|
625
|
+
/** Human-readable reason that `supports(operation)` returned `false`. */
|
|
626
|
+
unsupportedReason(operation: RunOperation): string | undefined;
|
|
627
|
+
/** Subscribe to status changes. Returns an unsubscribe function. */
|
|
628
|
+
onDidChangeStatus(listener: (status: RunStatus) => void): () => void;
|
|
629
|
+
}
|
|
630
|
+
/**
|
|
631
|
+
* SE9 — options for the integrated structured-output method `agent.generate`: the
|
|
632
|
+
* {@link SendOptions} that drive the tool loop (phase 1) plus the required `output`
|
|
633
|
+
* Zod schema and structuring knobs (phase 2). Co-located with `SendOptions` /
|
|
634
|
+
* `RunResult` (which they extend/use) so the public `SDKAgent` interface does not
|
|
635
|
+
* import the runtime `agent-generate` module (breaks the type cycle).
|
|
636
|
+
*
|
|
637
|
+
* @public
|
|
638
|
+
*/
|
|
639
|
+
export interface GenerateOptions<T extends import("zod").ZodType> extends SendOptions {
|
|
640
|
+
/** Zod schema the final answer is coerced into (the structuring contract). */
|
|
641
|
+
output: T;
|
|
642
|
+
/** Retry budget on the structuring phase's parse-failures (reused from generateObject). Default 1. */
|
|
643
|
+
maxRetries?: number;
|
|
644
|
+
/**
|
|
645
|
+
* What the STRUCTURING phase (phase 2) does when the model's output still fails
|
|
646
|
+
* Zod validation after retries. Default `"throw"`. `"return-partial"` / `"return-raw"`
|
|
647
|
+
* salvage the object; the salvaged/raw value is in {@link GenerateRunResult.raw}
|
|
648
|
+
* (the pre-parse structuring input) — NOT the phase-1 text answer, which is in
|
|
649
|
+
* `result.result`.
|
|
650
|
+
*/
|
|
651
|
+
errorStrategy?: "throw" | "return-partial" | "return-raw";
|
|
652
|
+
}
|
|
653
|
+
/**
|
|
654
|
+
* SE9 — result of `agent.generate`: the validated typed object plus the underlying
|
|
655
|
+
* tool-loop {@link RunResult} (status / usage / model) and the raw pre-parse input.
|
|
656
|
+
*
|
|
657
|
+
* @public
|
|
658
|
+
*/
|
|
659
|
+
export interface GenerateRunResult<O> {
|
|
660
|
+
/** The validated object — inferred type from the `output` schema. */
|
|
661
|
+
object: O;
|
|
662
|
+
/** The underlying tool-loop run (phase 1). */
|
|
663
|
+
result: RunResult;
|
|
664
|
+
/** Raw model input to the synthetic `output` tool, before the Zod parse. */
|
|
665
|
+
raw: unknown;
|
|
666
|
+
/** Combined token usage of the structuring phase. */
|
|
667
|
+
usage: {
|
|
668
|
+
inputTokens: number;
|
|
669
|
+
outputTokens: number;
|
|
670
|
+
};
|
|
671
|
+
}
|