abtars 0.1.0-alpha.2 → 0.1.0-alpha.21
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 +64 -0
- package/bundle/_registry.generated-KQODGKTQ.js +36 -0
- package/bundle/{_registry.generated-M4WY2MMI.js.map → _registry.generated-KQODGKTQ.js.map} +1 -1
- package/bundle/abtars-browser.js +8 -7
- package/bundle/abtars-browser.js.map +1 -1
- package/bundle/abtars-cli.js +646 -73
- package/bundle/abtars-cli.js.map +4 -4
- package/bundle/abtars-restart.js +7 -6
- package/bundle/abtars-rss.js +2 -1
- package/bundle/abtars-rss.js.map +1 -1
- package/bundle/abtars-task.js +9 -8
- package/bundle/abtars-task.js.map +1 -1
- package/bundle/abtars.js +103 -96
- package/bundle/abtars.js.map +2 -2
- package/bundle/{agent-api-rate-limit-OQNFMXTZ.js → agent-api-rate-limit-7R5TX2F2.js} +7 -6
- package/bundle/{agent-api-rate-limit-OQNFMXTZ.js.map → agent-api-rate-limit-7R5TX2F2.js.map} +1 -1
- package/bundle/agent-registry-5M77ZOMV.js +19 -0
- package/bundle/agent-registry-VJMNIQ5W.js +19 -0
- package/bundle/{anthropic-adapter-2APTH3LA.js → anthropic-adapter-IBY3NPXW.js} +4 -3
- package/bundle/{anthropic-adapter-2APTH3LA.js.map → anthropic-adapter-IBY3NPXW.js.map} +1 -1
- package/bundle/{bridge-lock-transport-4AC2G5G6.js → bridge-lock-transport-HO545SBK.js} +9 -8
- package/bundle/browse-delivery-64GQIUHG.js +18 -0
- package/bundle/browser-EXR5OQGK.js +19 -0
- package/bundle/capability-HIE7UGFU.js +18 -0
- package/bundle/{chunk-BUUVFUPO.js → chunk-2BY6I4P5.js} +5 -4
- package/bundle/{chunk-BUUVFUPO.js.map → chunk-2BY6I4P5.js.map} +1 -1
- package/bundle/{chunk-Y6XAEX2Q.js → chunk-2F6XKG7Y.js} +15 -9
- package/bundle/chunk-2F6XKG7Y.js.map +7 -0
- package/bundle/{chunk-V76TVMCM.js → chunk-3MO2MDXJ.js} +5 -4
- package/bundle/{chunk-V76TVMCM.js.map → chunk-3MO2MDXJ.js.map} +1 -1
- package/bundle/{chunk-6UCRKRWR.js → chunk-6XX4OAAM.js} +22 -21
- package/bundle/chunk-6XX4OAAM.js.map +7 -0
- package/bundle/{chunk-XREWVCUO.js → chunk-7CHLS36W.js} +16 -148
- package/bundle/chunk-7CHLS36W.js.map +7 -0
- package/bundle/{chunk-NWDBD4PA.js → chunk-7K2YZTLD.js} +3 -2
- package/bundle/{chunk-JCJS4ZIB.js → chunk-AQVOAQQI.js} +5 -4
- package/bundle/{chunk-JCJS4ZIB.js.map → chunk-AQVOAQQI.js.map} +1 -1
- package/bundle/chunk-AUQD2PKM.js +136 -0
- package/bundle/chunk-AUQD2PKM.js.map +7 -0
- package/bundle/{chunk-YOCTDKKL.js → chunk-BYDUMHXT.js} +4 -3
- package/bundle/{chunk-YOCTDKKL.js.map → chunk-BYDUMHXT.js.map} +1 -1
- package/bundle/{chunk-RVE2N7FA.js → chunk-CELR236Q.js} +5 -4
- package/bundle/{chunk-RVE2N7FA.js.map → chunk-CELR236Q.js.map} +1 -1
- package/bundle/{chunk-2XU2X4OI.js → chunk-CUQA2AJT.js} +3 -2
- package/bundle/{chunk-2XU2X4OI.js.map → chunk-CUQA2AJT.js.map} +1 -1
- package/bundle/chunk-DMPR5MYT.js +183 -0
- package/bundle/chunk-DMPR5MYT.js.map +7 -0
- package/bundle/{chunk-BHMZ4RCC.js → chunk-DY3R7LDW.js} +55 -54
- package/bundle/{chunk-BHMZ4RCC.js.map → chunk-DY3R7LDW.js.map} +1 -1
- package/bundle/{chunk-AR6GO6YC.js → chunk-ELRAH7VL.js} +5 -4
- package/bundle/{chunk-AR6GO6YC.js.map → chunk-ELRAH7VL.js.map} +1 -1
- package/bundle/{chunk-FMWKEPM7.js → chunk-EX2SRTUE.js} +5 -4
- package/bundle/{chunk-FMWKEPM7.js.map → chunk-EX2SRTUE.js.map} +1 -1
- package/bundle/{chunk-JW6RU47G.js → chunk-FVQGP5YO.js} +8 -7
- package/bundle/{chunk-JW6RU47G.js.map → chunk-FVQGP5YO.js.map} +1 -1
- package/bundle/{chunk-GRNENTPA.js → chunk-G6IXMYIO.js} +4 -3
- package/bundle/{chunk-GRNENTPA.js.map → chunk-G6IXMYIO.js.map} +1 -1
- package/bundle/{chunk-6NR3OHEW.js → chunk-H2RZ4NEJ.js} +6 -5
- package/bundle/{chunk-6NR3OHEW.js.map → chunk-H2RZ4NEJ.js.map} +1 -1
- package/bundle/chunk-HVKJN3AG.js +189 -0
- package/bundle/chunk-HVKJN3AG.js.map +7 -0
- package/bundle/{chunk-265TPOPC.js → chunk-HXJRZWKA.js} +3 -2
- package/bundle/{chunk-265TPOPC.js.map → chunk-HXJRZWKA.js.map} +1 -1
- package/bundle/chunk-IU3RI5E4.js +645 -0
- package/bundle/chunk-IU3RI5E4.js.map +7 -0
- package/bundle/{chunk-GST5T3WZ.js → chunk-J5YIMCLT.js} +6 -5
- package/bundle/{chunk-GST5T3WZ.js.map → chunk-J5YIMCLT.js.map} +1 -1
- package/bundle/chunk-JAJ3DUQ2.js +30 -0
- package/bundle/{chunk-OP7BTAWY.js.map → chunk-JAJ3DUQ2.js.map} +1 -1
- package/bundle/chunk-JHF25OOG.js +645 -0
- package/bundle/chunk-JHF25OOG.js.map +7 -0
- package/bundle/{chunk-MPX525QO.js → chunk-JRG4EFMP.js} +5 -4
- package/bundle/{chunk-MPX525QO.js.map → chunk-JRG4EFMP.js.map} +1 -1
- package/bundle/{chunk-VVEDVGCR.js → chunk-JU3UBWLN.js} +17 -16
- package/bundle/{chunk-VVEDVGCR.js.map → chunk-JU3UBWLN.js.map} +1 -1
- package/bundle/{chunk-QBGBT5QS.js → chunk-JX3ZZU3O.js} +5 -4
- package/bundle/{chunk-QBGBT5QS.js.map → chunk-JX3ZZU3O.js.map} +1 -1
- package/bundle/{chunk-6SETMHNN.js → chunk-K7P74UNQ.js} +8 -7
- package/bundle/{chunk-6SETMHNN.js.map → chunk-K7P74UNQ.js.map} +1 -1
- package/bundle/{chunk-AZJIODTQ.js → chunk-KED3G7HS.js} +6 -5
- package/bundle/{chunk-AZJIODTQ.js.map → chunk-KED3G7HS.js.map} +1 -1
- package/bundle/chunk-KI2ROWAH.js +3707 -0
- package/bundle/chunk-KI2ROWAH.js.map +7 -0
- package/bundle/{chunk-UHRP745J.js → chunk-L7YHV5DL.js} +6 -5
- package/bundle/{chunk-UHRP745J.js.map → chunk-L7YHV5DL.js.map} +1 -1
- package/bundle/{chunk-BSSBCSCL.js → chunk-LD5BMLHG.js} +11 -10
- package/bundle/{chunk-BSSBCSCL.js.map → chunk-LD5BMLHG.js.map} +1 -1
- package/bundle/{chunk-2UPU3OW6.js → chunk-LYEAHE5V.js} +5 -4
- package/bundle/{chunk-2UPU3OW6.js.map → chunk-LYEAHE5V.js.map} +1 -1
- package/bundle/{chunk-3B7BBE4F.js → chunk-MCGEXAG5.js} +8 -7
- package/bundle/{chunk-3B7BBE4F.js.map → chunk-MCGEXAG5.js.map} +1 -1
- package/bundle/{chunk-X76UX47U.js → chunk-MJ6PHMOK.js} +4 -3
- package/bundle/{chunk-X76UX47U.js.map → chunk-MJ6PHMOK.js.map} +1 -1
- package/bundle/{chunk-LSPKJQCI.js → chunk-MV6CJFWR.js} +3 -2
- package/bundle/{chunk-LSPKJQCI.js.map → chunk-MV6CJFWR.js.map} +1 -1
- package/bundle/chunk-MZWMYN4O.js +17 -0
- package/bundle/{chunk-M6VBAPNT.js.map → chunk-MZWMYN4O.js.map} +1 -1
- package/bundle/{chunk-HX7Y7EYP.js → chunk-NIRYBWUW.js} +4 -3
- package/bundle/{chunk-HX7Y7EYP.js.map → chunk-NIRYBWUW.js.map} +1 -1
- package/bundle/{chunk-3E545J66.js → chunk-OW64RUE5.js} +3 -2
- package/bundle/{chunk-3E545J66.js.map → chunk-OW64RUE5.js.map} +1 -1
- package/bundle/chunk-P56PLAIC.js +126 -0
- package/bundle/chunk-P56PLAIC.js.map +7 -0
- package/bundle/{chunk-TZHIDLDS.js → chunk-P6PN34XD.js} +5 -4
- package/bundle/{chunk-TZHIDLDS.js.map → chunk-P6PN34XD.js.map} +1 -1
- package/bundle/{chunk-2UENBO6M.js → chunk-PF5UQ64X.js} +9 -8
- package/bundle/{chunk-2UENBO6M.js.map → chunk-PF5UQ64X.js.map} +1 -1
- package/bundle/{chunk-6CPN4IGS.js → chunk-PQ62LZNA.js} +9 -8
- package/bundle/{chunk-6CPN4IGS.js.map → chunk-PQ62LZNA.js.map} +1 -1
- package/bundle/{chunk-UCQ2WC3B.js → chunk-PQW5QBPY.js} +15 -8
- package/bundle/chunk-PQW5QBPY.js.map +7 -0
- package/bundle/{chunk-D2DCBO6M.js → chunk-R36WIOYX.js} +3 -2
- package/bundle/{chunk-D2DCBO6M.js.map → chunk-R36WIOYX.js.map} +1 -1
- package/bundle/chunk-RB3X66KM.js +386 -0
- package/bundle/chunk-RB3X66KM.js.map +7 -0
- package/bundle/{chunk-GUQVJC3U.js → chunk-RE3F3CFW.js} +7 -6
- package/bundle/{chunk-GUQVJC3U.js.map → chunk-RE3F3CFW.js.map} +1 -1
- package/bundle/chunk-RWUINZUQ.js +19 -0
- package/bundle/chunk-RWUINZUQ.js.map +7 -0
- package/bundle/{chunk-NT3OBORC.js → chunk-S54DBUZ4.js} +10 -9
- package/bundle/{chunk-NT3OBORC.js.map → chunk-S54DBUZ4.js.map} +1 -1
- package/bundle/{chunk-CWOHNFUV.js → chunk-SY67HM2Y.js} +3 -2
- package/bundle/{chunk-CWOHNFUV.js.map → chunk-SY67HM2Y.js.map} +1 -1
- package/bundle/{chunk-BQ2L4GMG.js → chunk-TBLYGCPQ.js} +4 -3
- package/bundle/{chunk-BQ2L4GMG.js.map → chunk-TBLYGCPQ.js.map} +1 -1
- package/bundle/chunk-TCBMBX3Z.js +183 -0
- package/bundle/chunk-TCBMBX3Z.js.map +7 -0
- package/bundle/chunk-TXRWQIQQ.js +3707 -0
- package/bundle/chunk-TXRWQIQQ.js.map +7 -0
- package/bundle/chunk-U34CSHFS.js +645 -0
- package/bundle/chunk-U34CSHFS.js.map +7 -0
- package/bundle/{chunk-CEVRHKJY.js → chunk-UDZIZB5F.js} +6 -5
- package/bundle/{chunk-CEVRHKJY.js.map → chunk-UDZIZB5F.js.map} +1 -1
- package/bundle/{chunk-W6FAL35D.js → chunk-VA5WKN3Z.js} +7 -6
- package/bundle/{chunk-W6FAL35D.js.map → chunk-VA5WKN3Z.js.map} +1 -1
- package/bundle/{chunk-X6TERNVJ.js → chunk-WX7GHGFX.js} +10 -9
- package/bundle/{chunk-X6TERNVJ.js.map → chunk-WX7GHGFX.js.map} +1 -1
- package/bundle/{chunk-PNEDC45Y.js → chunk-XETTJVEU.js} +4 -3
- package/bundle/{chunk-PNEDC45Y.js.map → chunk-XETTJVEU.js.map} +1 -1
- package/bundle/{chunk-PLCY3GFH.js → chunk-XLLSPBBT.js} +5 -4
- package/bundle/{chunk-PLCY3GFH.js.map → chunk-XLLSPBBT.js.map} +1 -1
- package/bundle/{chunk-ZXPXCDA6.js → chunk-XOCP5BMO.js} +6 -5
- package/bundle/{chunk-ZXPXCDA6.js.map → chunk-XOCP5BMO.js.map} +1 -1
- package/bundle/chunk-ZEY6YZAB.js +138 -0
- package/bundle/chunk-ZEY6YZAB.js.map +7 -0
- package/bundle/{chunk-MW6WDLU7.js → chunk-ZZR3JZHR.js} +10 -9
- package/bundle/{chunk-MW6WDLU7.js.map → chunk-ZZR3JZHR.js.map} +1 -1
- package/bundle/commands-AIL4XOIZ.js +33 -0
- package/bundle/commands-K77NVSXZ.js +32 -0
- package/bundle/commands-V6RSVC4Y.js +32 -0
- package/bundle/completion-buffer-S3LXDZG2.js +14 -0
- package/bundle/config-C6VHRJQ7.js +20 -0
- package/bundle/{config-show-ERTATR6E.js → config-show-ZTXX27FW.js} +4 -3
- package/bundle/{config-show-ERTATR6E.js.map → config-show-ZTXX27FW.js.map} +1 -1
- package/bundle/{context-HCEGZNDC.js → context-OCS7HLJP.js} +5 -4
- package/bundle/{context-HCEGZNDC.js.map → context-OCS7HLJP.js.map} +1 -1
- package/bundle/daemon-NPKYZ3CJ.js +292 -0
- package/bundle/daemon-NPKYZ3CJ.js.map +7 -0
- package/bundle/delegation-tools-PF7RD2RW.js +28 -0
- package/bundle/{deploy-lib-import-32ZFKHWP.js → deploy-lib-import-ODLDL2DB.js} +5 -4
- package/bundle/digital-signature-PNY4TR2W.js +14 -0
- package/bundle/{direct-api-transport-YR7SXXNN.js → direct-api-transport-EADHM67Z.js} +21 -20
- package/bundle/{direct-api-transport-YR7SXXNN.js.map → direct-api-transport-EADHM67Z.js.map} +1 -1
- package/bundle/direct-api-transport-SLJ2Z6NX.js +861 -0
- package/bundle/direct-api-transport-SLJ2Z6NX.js.map +7 -0
- package/bundle/{discord-adapter-YYWVMPPU.js → discord-adapter-FBJOJSTW.js} +25 -24
- package/bundle/{discord-adapter-YYWVMPPU.js.map → discord-adapter-FBJOJSTW.js.map} +1 -1
- package/bundle/discord-adapter-IJISVHUE.js +585 -0
- package/bundle/discord-adapter-IJISVHUE.js.map +7 -0
- package/bundle/discord-adapter-UYOCKRDF.js +586 -0
- package/bundle/discord-adapter-UYOCKRDF.js.map +7 -0
- package/bundle/{dist-MTMKARCP.js → dist-J3T4XVKX.js} +4 -3
- package/bundle/{dist-MTMKARCP.js.map → dist-J3T4XVKX.js.map} +1 -1
- package/bundle/{dns-wakeup-27M7D2MR.js → dns-wakeup-RYOCQ6GR.js} +6 -5
- package/bundle/{dns-wakeup-27M7D2MR.js.map → dns-wakeup-RYOCQ6GR.js.map} +1 -1
- package/bundle/{doctor-QNUSDY73.js → doctor-R54GZPKL.js} +10 -9
- package/bundle/{doctor-QNUSDY73.js.map → doctor-R54GZPKL.js.map} +1 -1
- package/bundle/{ensure-invariants-NMXNS476.js → ensure-invariants-K2ZUZ6NR.js} +7 -6
- package/bundle/{ensure-invariants-NMXNS476.js.map → ensure-invariants-K2ZUZ6NR.js.map} +1 -1
- package/bundle/ensure-invariants-KUXIW73S.js +50 -0
- package/bundle/ensure-invariants-KUXIW73S.js.map +7 -0
- package/bundle/env-schema-DGD6QWPA.js +20 -0
- package/bundle/{esm-DDP6NCZG.js → esm-PFOJARXA.js} +5 -4
- package/bundle/{esm-DDP6NCZG.js.map → esm-PFOJARXA.js.map} +1 -1
- package/bundle/{fallback-policy-L4QV2PEJ.js → fallback-policy-SR6ED5I3.js} +4 -3
- package/bundle/{fallback-policy-L4QV2PEJ.js.map → fallback-policy-SR6ED5I3.js.map} +1 -1
- package/bundle/{health-check-SPA7NT6N.js → health-check-RJ2SUJYL.js} +4 -3
- package/bundle/{health-check-SPA7NT6N.js.map → health-check-RJ2SUJYL.js.map} +1 -1
- package/bundle/hook-system-POI5VRIX.js +18 -0
- package/bundle/hotskills-6ECHLXTJ.js +13 -0
- package/bundle/install-24XR5FO5.js +13 -0
- package/bundle/install-AJ7VW76P.js +13 -0
- package/bundle/{install-log-IAPHYKD4.js → install-log-Q6RUHKWC.js} +4 -3
- package/bundle/{install-log-IAPHYKD4.js.map → install-log-Q6RUHKWC.js.map} +1 -1
- package/bundle/{install-manifest-SPQRUNXL.js → install-manifest-MCJCAYSR.js} +9 -7
- package/bundle/install-manifest-MCJCAYSR.js.map +7 -0
- package/bundle/install-manifest-ZETY4AFS.js +104 -0
- package/bundle/install-manifest-ZETY4AFS.js.map +7 -0
- package/bundle/{install-validate-PVLZXYLQ.js → install-validate-H74LUCE2.js} +4 -3
- package/bundle/{install-validate-PVLZXYLQ.js.map → install-validate-H74LUCE2.js.map} +1 -1
- package/bundle/{irc-adapter-OI5UZSQF.js → irc-adapter-RKRUSZXB.js} +7 -6
- package/bundle/{irc-adapter-OI5UZSQF.js.map → irc-adapter-RKRUSZXB.js.map} +1 -1
- package/bundle/{irc-config-55YO6EGB.js → irc-config-6VY67UPQ.js} +8 -7
- package/bundle/{irc-config-55YO6EGB.js.map → irc-config-6VY67UPQ.js.map} +1 -1
- package/bundle/{logs-ZNYXX5PA.js → logs-EK4HYRKR.js} +4 -3
- package/bundle/{logs-ZNYXX5PA.js.map → logs-EK4HYRKR.js.map} +1 -1
- package/bundle/{media-utils-XNNDTYFI.js → media-utils-QBY5WBF3.js} +8 -7
- package/bundle/{media-utils-XNNDTYFI.js.map → media-utils-QBY5WBF3.js.map} +1 -1
- package/bundle/message-pipeline-ANSMPK5O.js +34 -0
- package/bundle/message-pipeline-HXZMRGXZ.js +34 -0
- package/bundle/message-pipeline-XUUTGPFH.js +35 -0
- package/bundle/meta.json +1828 -1650
- package/bundle/model-health-registry-7ECZFCW4.js +12 -0
- package/bundle/model-health-registry-LDC76RPP.js +12 -0
- package/bundle/notification-OJ4YE4VG.js +14 -0
- package/bundle/{openrouter-credits-EDY7ETAU.js → openrouter-credits-L45SYKT3.js} +7 -6
- package/bundle/{openrouter-credits-EDY7ETAU.js.map → openrouter-credits-L45SYKT3.js.map} +1 -1
- package/bundle/{passwd-RRFV4CC5.js → passwd-QSHZJ2CG.js} +4 -3
- package/bundle/{passwd-RRFV4CC5.js.map → passwd-QSHZJ2CG.js.map} +1 -1
- package/bundle/paths-ZJYIDND2.js +18 -0
- package/bundle/{peer-client-52XYMNI7.js → peer-client-T44VI7NB.js} +13 -12
- package/bundle/{peer-client-52XYMNI7.js.map → peer-client-T44VI7NB.js.map} +1 -1
- package/bundle/peer-config-D5A4454H.js +17 -0
- package/bundle/{peer-sessions-EAXTNQ36.js → peer-sessions-MY2YVXHC.js} +4 -3
- package/bundle/{peer-sessions-EAXTNQ36.js.map → peer-sessions-MY2YVXHC.js.map} +1 -1
- package/bundle/{pending-callback-RIMQZ7FJ.js → pending-callback-6KLBSHLX.js} +4 -3
- package/bundle/{pending-callback-RIMQZ7FJ.js.map → pending-callback-6KLBSHLX.js.map} +1 -1
- package/bundle/phase-transport-43NP5XBK.js +23 -0
- package/bundle/phase-transport-GNUZI6EW.js +23 -0
- package/bundle/phase-transport-Q7K6V3VZ.js +23 -0
- package/bundle/phase-transport-SLJXIAY5.js +23 -0
- package/bundle/{responses-adapter-AAQTY3K4.js → responses-adapter-DAV2JUL7.js} +4 -3
- package/bundle/{responses-adapter-AAQTY3K4.js.map → responses-adapter-DAV2JUL7.js.map} +1 -1
- package/bundle/{restore-ZE3SEPSS.js → restore-ROJF22R2.js} +5 -4
- package/bundle/{restore-ZE3SEPSS.js.map → restore-ROJF22R2.js.map} +1 -1
- package/bundle/{self-healer-utils-DMUUXC47.js → self-healer-utils-7NFH22VJ.js} +7 -6
- package/bundle/{self-healer-utils-DMUUXC47.js.map → self-healer-utils-7NFH22VJ.js.map} +1 -1
- package/bundle/skill-stats-IPVKMWN3.js +23 -0
- package/bundle/sleep-4NVWZHVN.js +20 -0
- package/bundle/soul-bundle-7EYTEKFE.js +15 -0
- package/bundle/soul-loader-7FN7WDHM.js +18 -0
- package/bundle/soul-loader-K237NP4T.js +17 -0
- package/bundle/soul-loader-K237NP4T.js.map +7 -0
- package/bundle/soul-loader-UVJ6HZM3.js +17 -0
- package/bundle/soul-loader-UVJ6HZM3.js.map +7 -0
- package/bundle/src-Z3WR7SRT.js +9 -0
- package/bundle/src-Z3WR7SRT.js.map +7 -0
- package/bundle/{sse-parser-anthropic-P7CE2MH2.js → sse-parser-anthropic-H42TTLBD.js} +7 -6
- package/bundle/{sse-parser-anthropic-P7CE2MH2.js.map → sse-parser-anthropic-H42TTLBD.js.map} +1 -1
- package/bundle/{sse-parser-responses-EQQA5FWN.js → sse-parser-responses-WG2LY2ML.js} +7 -6
- package/bundle/{sse-parser-responses-EQQA5FWN.js.map → sse-parser-responses-WG2LY2ML.js.map} +1 -1
- package/bundle/{ssrf-guard-FZCBYIVW.js → ssrf-guard-E2KBBC5E.js} +7 -6
- package/bundle/{ssrf-guard-FZCBYIVW.js.map → ssrf-guard-E2KBBC5E.js.map} +1 -1
- package/bundle/{start-FH3GRMJ4.js → start-4IWBKLWO.js} +4 -3
- package/bundle/{start-FH3GRMJ4.js.map → start-4IWBKLWO.js.map} +1 -1
- package/bundle/{stream-single-WSG4D53C.js → stream-single-RFJNUTL6.js} +4 -3
- package/bundle/{stream-single-WSG4D53C.js.map → stream-single-RFJNUTL6.js.map} +1 -1
- package/bundle/stt-CF3CPFDC.js +15 -0
- package/bundle/stt-CF3CPFDC.js.map +7 -0
- package/bundle/subagent-runtime-P7GCFBM3.js +13 -0
- package/bundle/subagent-runtime-P7GCFBM3.js.map +7 -0
- package/bundle/subagent-runtime-USNPO4WF.js +13 -0
- package/bundle/subagent-runtime-USNPO4WF.js.map +7 -0
- package/bundle/subagent-runtime-XS2ZXYOZ.js +13 -0
- package/bundle/subagent-runtime-XS2ZXYOZ.js.map +7 -0
- package/bundle/{system-message-T5R3EYYN.js → system-message-TALP6GP2.js} +6 -5
- package/bundle/{system-message-T5R3EYYN.js.map → system-message-TALP6GP2.js.map} +1 -1
- package/bundle/{system-status-KQ6KHFJ6.js → system-status-2CR5OUDY.js} +10 -9
- package/bundle/{system-status-KQ6KHFJ6.js.map → system-status-2CR5OUDY.js.map} +1 -1
- package/bundle/task-store-KIBFZL5A.js +23 -0
- package/bundle/task-store-KIBFZL5A.js.map +7 -0
- package/bundle/{telegram-adapter-2V3XUMT5.js → telegram-adapter-ISQRW7PN.js} +34 -33
- package/bundle/{telegram-adapter-2V3XUMT5.js.map → telegram-adapter-ISQRW7PN.js.map} +1 -1
- package/bundle/telegram-adapter-QCD7AG5D.js +1062 -0
- package/bundle/telegram-adapter-QCD7AG5D.js.map +7 -0
- package/bundle/telegram-adapter-Y3PVA25S.js +1061 -0
- package/bundle/telegram-adapter-Y3PVA25S.js.map +7 -0
- package/bundle/telegram-adapter-YAXSK2RT.js +1062 -0
- package/bundle/telegram-adapter-YAXSK2RT.js.map +7 -0
- package/bundle/tool-registry-DFCCGZCB.js +39 -0
- package/bundle/tool-registry-DFCCGZCB.js.map +7 -0
- package/bundle/tool-sandbox-OZMXJZLQ.js +21 -0
- package/bundle/tool-sandbox-OZMXJZLQ.js.map +7 -0
- package/bundle/{transport-config-YLXU33RO.js → transport-config-ANPS2RYT.js} +11 -10
- package/bundle/transport-config-ANPS2RYT.js.map +7 -0
- package/bundle/update-check-O5MS6B3L.js +13 -0
- package/bundle/update-check-O5MS6B3L.js.map +7 -0
- package/bundle/usage-tracker-S4Z2G2K5.js +18 -0
- package/bundle/usage-tracker-S4Z2G2K5.js.map +7 -0
- package/bundle/user-registry-GTAJIW6E.js +17 -0
- package/bundle/user-registry-GTAJIW6E.js.map +7 -0
- package/config/.env +2 -0
- package/config/auto-fix.json +14 -0
- package/config/irc.json.example +30 -0
- package/config/models.json.example +229 -0
- package/config/peers.json.example +12 -0
- package/config/schemas/irc.schema.json +42 -0
- package/config/schemas/models.schema.json +17 -0
- package/config/schemas/peers.schema.json +35 -0
- package/config/schemas/transport.schema.json +35 -0
- package/config/schemas/users.schema.json +22 -0
- package/config/transport.default.json +30 -0
- package/config/transport.json.example +102 -0
- package/config/users.json.example +11 -0
- package/install-manifest.json +148 -0
- package/package.json +4 -2
- package/scripts/abtars-daemon.service +1 -0
- package/scripts/watchdog.sh +1 -1
- package/bundle/_registry.generated-M4WY2MMI.js +0 -35
- package/bundle/agent-registry-LT4JNQH6.js +0 -18
- package/bundle/browse-delivery-JXBY36GK.js +0 -17
- package/bundle/browser-ELNDVPLC.js +0 -18
- package/bundle/capability-CIL3G4FI.js +0 -17
- package/bundle/chunk-5R2ANXQ7.js +0 -510
- package/bundle/chunk-5R2ANXQ7.js.map +0 -7
- package/bundle/chunk-6UCRKRWR.js.map +0 -7
- package/bundle/chunk-M6VBAPNT.js +0 -16
- package/bundle/chunk-OP7BTAWY.js +0 -29
- package/bundle/chunk-UCQ2WC3B.js.map +0 -7
- package/bundle/chunk-XREWVCUO.js.map +0 -7
- package/bundle/chunk-Y6XAEX2Q.js.map +0 -7
- package/bundle/commands-BHVUOU3V.js +0 -31
- package/bundle/completion-buffer-P253ONKF.js +0 -13
- package/bundle/config-RGSDAPZN.js +0 -19
- package/bundle/delegation-tools-GYTS2D6A.js +0 -27
- package/bundle/digital-signature-OFCGSHWO.js +0 -13
- package/bundle/env-schema-2KBHBDGN.js +0 -19
- package/bundle/hook-system-6Q5YTR53.js +0 -17
- package/bundle/hotskills-K7BM4YLB.js +0 -12
- package/bundle/install-6HRZVKUM.js +0 -15
- package/bundle/install-manifest-SPQRUNXL.js.map +0 -7
- package/bundle/message-pipeline-LLH5SYMO.js +0 -33
- package/bundle/model-health-registry-35LQNVQR.js +0 -11
- package/bundle/notification-Y5S5MMLV.js +0 -13
- package/bundle/paths-G33RZWZ7.js +0 -17
- package/bundle/peer-config-VK6EDLN5.js +0 -16
- package/bundle/phase-transport-KYERDL2O.js +0 -22
- package/bundle/skill-stats-LLEXEXLR.js +0 -22
- package/bundle/sleep-OYIUOVQD.js +0 -19
- package/bundle/soul-loader-54WCVNLJ.js +0 -16
- package/bundle/src-JL4PVO23.js +0 -8
- package/bundle/stt-2UH3RITX.js +0 -14
- package/bundle/subagent-runtime-LE2ZXH3G.js +0 -12
- package/bundle/task-store-K7CQDEPI.js +0 -22
- package/bundle/tool-registry-MU3OX4UI.js +0 -38
- package/bundle/tool-sandbox-VYOK4ZOA.js +0 -20
- package/bundle/update-QCW5LXRN.js +0 -13
- package/bundle/update-check-27KZSAP6.js +0 -12
- package/bundle/usage-tracker-OVVEVMOY.js +0 -17
- package/bundle/user-registry-D4SD73UV.js +0 -16
- /package/bundle/{agent-registry-LT4JNQH6.js.map → agent-registry-5M77ZOMV.js.map} +0 -0
- /package/bundle/{bridge-lock-transport-4AC2G5G6.js.map → agent-registry-VJMNIQ5W.js.map} +0 -0
- /package/bundle/{browse-delivery-JXBY36GK.js.map → bridge-lock-transport-HO545SBK.js.map} +0 -0
- /package/bundle/{browser-ELNDVPLC.js.map → browse-delivery-64GQIUHG.js.map} +0 -0
- /package/bundle/{capability-CIL3G4FI.js.map → browser-EXR5OQGK.js.map} +0 -0
- /package/bundle/{chunk-NWDBD4PA.js.map → capability-HIE7UGFU.js.map} +0 -0
- /package/bundle/{commands-BHVUOU3V.js.map → chunk-7K2YZTLD.js.map} +0 -0
- /package/bundle/{completion-buffer-P253ONKF.js.map → commands-AIL4XOIZ.js.map} +0 -0
- /package/bundle/{config-RGSDAPZN.js.map → commands-K77NVSXZ.js.map} +0 -0
- /package/bundle/{delegation-tools-GYTS2D6A.js.map → commands-V6RSVC4Y.js.map} +0 -0
- /package/bundle/{deploy-lib-import-32ZFKHWP.js.map → completion-buffer-S3LXDZG2.js.map} +0 -0
- /package/bundle/{digital-signature-OFCGSHWO.js.map → config-C6VHRJQ7.js.map} +0 -0
- /package/bundle/{env-schema-2KBHBDGN.js.map → delegation-tools-PF7RD2RW.js.map} +0 -0
- /package/bundle/{hook-system-6Q5YTR53.js.map → deploy-lib-import-ODLDL2DB.js.map} +0 -0
- /package/bundle/{hotskills-K7BM4YLB.js.map → digital-signature-PNY4TR2W.js.map} +0 -0
- /package/bundle/{install-6HRZVKUM.js.map → env-schema-DGD6QWPA.js.map} +0 -0
- /package/bundle/{message-pipeline-LLH5SYMO.js.map → hook-system-POI5VRIX.js.map} +0 -0
- /package/bundle/{model-health-registry-35LQNVQR.js.map → hotskills-6ECHLXTJ.js.map} +0 -0
- /package/bundle/{notification-Y5S5MMLV.js.map → install-24XR5FO5.js.map} +0 -0
- /package/bundle/{paths-G33RZWZ7.js.map → install-AJ7VW76P.js.map} +0 -0
- /package/bundle/{peer-config-VK6EDLN5.js.map → message-pipeline-ANSMPK5O.js.map} +0 -0
- /package/bundle/{phase-transport-KYERDL2O.js.map → message-pipeline-HXZMRGXZ.js.map} +0 -0
- /package/bundle/{skill-stats-LLEXEXLR.js.map → message-pipeline-XUUTGPFH.js.map} +0 -0
- /package/bundle/{sleep-OYIUOVQD.js.map → model-health-registry-7ECZFCW4.js.map} +0 -0
- /package/bundle/{soul-loader-54WCVNLJ.js.map → model-health-registry-LDC76RPP.js.map} +0 -0
- /package/bundle/{src-JL4PVO23.js.map → notification-OJ4YE4VG.js.map} +0 -0
- /package/bundle/{stt-2UH3RITX.js.map → paths-ZJYIDND2.js.map} +0 -0
- /package/bundle/{subagent-runtime-LE2ZXH3G.js.map → peer-config-D5A4454H.js.map} +0 -0
- /package/bundle/{task-store-K7CQDEPI.js.map → phase-transport-43NP5XBK.js.map} +0 -0
- /package/bundle/{tool-registry-MU3OX4UI.js.map → phase-transport-GNUZI6EW.js.map} +0 -0
- /package/bundle/{tool-sandbox-VYOK4ZOA.js.map → phase-transport-Q7K6V3VZ.js.map} +0 -0
- /package/bundle/{transport-config-YLXU33RO.js.map → phase-transport-SLJXIAY5.js.map} +0 -0
- /package/bundle/{update-QCW5LXRN.js.map → skill-stats-IPVKMWN3.js.map} +0 -0
- /package/bundle/{update-check-27KZSAP6.js.map → sleep-4NVWZHVN.js.map} +0 -0
- /package/bundle/{usage-tracker-OVVEVMOY.js.map → soul-bundle-7EYTEKFE.js.map} +0 -0
- /package/bundle/{user-registry-D4SD73UV.js.map → soul-loader-7FN7WDHM.js.map} +0 -0
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import { createRequire as __bundleCreateRequire } from 'node:module'; import { fileURLToPath as __bundleFileURLToPath } from 'node:url'; import { dirname as __bundleDirname } from 'node:path'; const require = __bundleCreateRequire(import.meta.url); const __chunk_filename = __bundleFileURLToPath(import.meta.url); const __chunk_dirname = __bundleDirname(__chunk_filename);
|
|
2
3
|
|
|
3
4
|
// src/components/usage-tracker.ts
|
|
4
5
|
import { appendFileSync, readFileSync, writeFileSync, existsSync, mkdirSync } from "node:fs";
|
|
@@ -66,4 +67,4 @@ export {
|
|
|
66
67
|
readUsage,
|
|
67
68
|
resetUsage
|
|
68
69
|
};
|
|
69
|
-
//# sourceMappingURL=chunk-
|
|
70
|
+
//# sourceMappingURL=chunk-OW64RUE5.js.map
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../src/components/usage-tracker.ts"],
|
|
4
4
|
"sourcesContent": ["/**\n * usage-tracker.ts \u2014 append-only token usage log + aggregation.\n * Storage: ~/.abtars/state/usage.jsonl (one JSON line per prompt).\n */\nimport { appendFileSync, readFileSync, writeFileSync, existsSync, mkdirSync } from \"node:fs\";\nimport { join } from \"node:path\";\n\nexport interface UsageEntry {\n ts: number;\n model: string;\n in: number;\n out: number;\n}\n\nlet buffer: UsageEntry[] = [];\nlet usagePath = \"\";\n\nexport function initUsageTracker(home: string): void {\n const stateDir = join(home, \"state\");\n if (!existsSync(stateDir)) mkdirSync(stateDir, { recursive: true });\n usagePath = join(stateDir, \"usage.jsonl\");\n}\n\nexport function recordUsage(model: string, inputTokens: number, outputTokens: number): void {\n if (!usagePath) return;\n buffer.push({ ts: Date.now(), model, in: inputTokens, out: outputTokens });\n if (buffer.length >= 100) flushUsage();\n}\n\nexport function flushUsage(): void {\n if (!usagePath || buffer.length === 0) return;\n const lines = buffer.map(e => JSON.stringify(e)).join(\"\\n\") + \"\\n\";\n appendFileSync(usagePath, lines);\n buffer = [];\n}\n\nexport interface UsageSummary {\n inputTokens: number;\n outputTokens: number;\n cost: number;\n byModel: Map<string, { in: number; out: number; cost: number }>;\n}\n\nexport function readUsage(since: number, costTable: Map<string, { input: number; output: number }>): UsageSummary {\n const result: UsageSummary = { inputTokens: 0, outputTokens: 0, cost: 0, byModel: new Map() };\n if (!usagePath) return result;\n\n // Include unflushed buffer\n const entries: UsageEntry[] = [...buffer];\n\n if (existsSync(usagePath)) {\n const raw = readFileSync(usagePath, \"utf-8\");\n for (const line of raw.split(\"\\n\")) {\n if (!line) continue;\n try { entries.push(JSON.parse(line)); } catch { /* skip malformed */ }\n }\n }\n\n for (const e of entries) {\n if (e.ts < since) continue;\n result.inputTokens += e.in;\n result.outputTokens += e.out;\n const pricing = costTable.get(e.model);\n const entryCost = pricing\n ? (e.in * pricing.input + e.out * pricing.output) / 1_000_000\n : 0;\n result.cost += entryCost;\n\n const existing = result.byModel.get(e.model);\n if (existing) {\n existing.in += e.in;\n existing.out += e.out;\n existing.cost += entryCost;\n } else {\n result.byModel.set(e.model, { in: e.in, out: e.out, cost: entryCost });\n }\n }\n return result;\n}\n\nexport function resetUsage(): void {\n if (!usagePath) return;\n buffer = [];\n writeFileSync(usagePath, \"\");\n}\n"],
|
|
5
|
-
"mappings": "
|
|
5
|
+
"mappings": ";;;;AAIA,SAAS,gBAAgB,cAAc,eAAe,YAAY,iBAAiB;AACnF,SAAS,YAAY;AASrB,IAAI,SAAuB,CAAC;AAC5B,IAAI,YAAY;AAET,SAAS,iBAAiB,MAAoB;AACnD,QAAM,WAAW,KAAK,MAAM,OAAO;AACnC,MAAI,CAAC,WAAW,QAAQ,EAAG,WAAU,UAAU,EAAE,WAAW,KAAK,CAAC;AAClE,cAAY,KAAK,UAAU,aAAa;AAC1C;AAEO,SAAS,YAAY,OAAe,aAAqB,cAA4B;AAC1F,MAAI,CAAC,UAAW;AAChB,SAAO,KAAK,EAAE,IAAI,KAAK,IAAI,GAAG,OAAO,IAAI,aAAa,KAAK,aAAa,CAAC;AACzE,MAAI,OAAO,UAAU,IAAK,YAAW;AACvC;AAEO,SAAS,aAAmB;AACjC,MAAI,CAAC,aAAa,OAAO,WAAW,EAAG;AACvC,QAAM,QAAQ,OAAO,IAAI,OAAK,KAAK,UAAU,CAAC,CAAC,EAAE,KAAK,IAAI,IAAI;AAC9D,iBAAe,WAAW,KAAK;AAC/B,WAAS,CAAC;AACZ;AASO,SAAS,UAAU,OAAe,WAAyE;AAChH,QAAM,SAAuB,EAAE,aAAa,GAAG,cAAc,GAAG,MAAM,GAAG,SAAS,oBAAI,IAAI,EAAE;AAC5F,MAAI,CAAC,UAAW,QAAO;AAGvB,QAAM,UAAwB,CAAC,GAAG,MAAM;AAExC,MAAI,WAAW,SAAS,GAAG;AACzB,UAAM,MAAM,aAAa,WAAW,OAAO;AAC3C,eAAW,QAAQ,IAAI,MAAM,IAAI,GAAG;AAClC,UAAI,CAAC,KAAM;AACX,UAAI;AAAE,gBAAQ,KAAK,KAAK,MAAM,IAAI,CAAC;AAAA,MAAG,QAAQ;AAAA,MAAuB;AAAA,IACvE;AAAA,EACF;AAEA,aAAW,KAAK,SAAS;AACvB,QAAI,EAAE,KAAK,MAAO;AAClB,WAAO,eAAe,EAAE;AACxB,WAAO,gBAAgB,EAAE;AACzB,UAAM,UAAU,UAAU,IAAI,EAAE,KAAK;AACrC,UAAM,YAAY,WACb,EAAE,KAAK,QAAQ,QAAQ,EAAE,MAAM,QAAQ,UAAU,MAClD;AACJ,WAAO,QAAQ;AAEf,UAAM,WAAW,OAAO,QAAQ,IAAI,EAAE,KAAK;AAC3C,QAAI,UAAU;AACZ,eAAS,MAAM,EAAE;AACjB,eAAS,OAAO,EAAE;AAClB,eAAS,QAAQ;AAAA,IACnB,OAAO;AACL,aAAO,QAAQ,IAAI,EAAE,OAAO,EAAE,IAAI,EAAE,IAAI,KAAK,EAAE,KAAK,MAAM,UAAU,CAAC;AAAA,IACvE;AAAA,EACF;AACA,SAAO;AACT;AAEO,SAAS,aAAmB;AACjC,MAAI,CAAC,UAAW;AAChB,WAAS,CAAC;AACV,gBAAc,WAAW,EAAE;AAC7B;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -0,0 +1,126 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import { createRequire as __bundleCreateRequire } from 'node:module'; import { fileURLToPath as __bundleFileURLToPath } from 'node:url'; import { dirname as __bundleDirname } from 'node:path'; const require = __bundleCreateRequire(import.meta.url); const __chunk_filename = __bundleFileURLToPath(import.meta.url); const __chunk_dirname = __bundleDirname(__chunk_filename);
|
|
3
|
+
import {
|
|
4
|
+
buildUsersBlock,
|
|
5
|
+
loadUsers
|
|
6
|
+
} from "./chunk-J5YIMCLT.js";
|
|
7
|
+
import {
|
|
8
|
+
init_log_and_swallow,
|
|
9
|
+
logAndSwallow
|
|
10
|
+
} from "./chunk-EX2SRTUE.js";
|
|
11
|
+
import {
|
|
12
|
+
getEnv,
|
|
13
|
+
init_env_schema
|
|
14
|
+
} from "./chunk-AQVOAQQI.js";
|
|
15
|
+
import {
|
|
16
|
+
init_logger,
|
|
17
|
+
logDebug,
|
|
18
|
+
logInfo,
|
|
19
|
+
logWarn
|
|
20
|
+
} from "./chunk-2BY6I4P5.js";
|
|
21
|
+
import {
|
|
22
|
+
abtarsHome,
|
|
23
|
+
init_paths
|
|
24
|
+
} from "./chunk-MJ6PHMOK.js";
|
|
25
|
+
|
|
26
|
+
// src/components/soul-bundle.ts
|
|
27
|
+
init_log_and_swallow();
|
|
28
|
+
init_env_schema();
|
|
29
|
+
init_logger();
|
|
30
|
+
init_paths();
|
|
31
|
+
import { existsSync, readFileSync } from "node:fs";
|
|
32
|
+
import { join } from "node:path";
|
|
33
|
+
var TAG = "soul-bundle";
|
|
34
|
+
var HOST_CORE_DIR = join(abtarsHome(), "core");
|
|
35
|
+
function readOr(path) {
|
|
36
|
+
try {
|
|
37
|
+
return existsSync(path) ? readFileSync(path, "utf-8").trim() : "";
|
|
38
|
+
} catch {
|
|
39
|
+
return "";
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
var TYPE_IDENTITY = {
|
|
43
|
+
A: null,
|
|
44
|
+
// uses full SOUL.md
|
|
45
|
+
B: "I am a browse agent. I fetch web content and return results. No memory access.",
|
|
46
|
+
C: "I am a coding agent. I write and fix code. Be concise.",
|
|
47
|
+
T: "I am a task agent. I execute scheduled tasks. Write all output to $WORKSPACE.",
|
|
48
|
+
S: "I am the self-healing agent. I diagnose and fix system failures. If unfixable, state: Requires human intervention.",
|
|
49
|
+
P: "I am responding to a peer agent request. Be precise and technical."
|
|
50
|
+
};
|
|
51
|
+
function buildModelInstructions() {
|
|
52
|
+
const lines = [];
|
|
53
|
+
if (getEnv().primingModelTopics) {
|
|
54
|
+
lines.push("End each response with [TOPICS: kw1, kw2, kw3] \u2014 your top 3 topics from this exchange. Keep them English, lowercase, concise.");
|
|
55
|
+
}
|
|
56
|
+
return lines.length > 0 ? `# Model Instructions
|
|
57
|
+
|
|
58
|
+
${lines.join("\n")}` : "";
|
|
59
|
+
}
|
|
60
|
+
function buildCurrentTime() {
|
|
61
|
+
const now = /* @__PURE__ */ new Date();
|
|
62
|
+
const days = ["Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday"];
|
|
63
|
+
return `[CURRENT TIME] ${now.toLocaleDateString("en-GB")} ${days[now.getDay()]}, ${now.toLocaleTimeString("en-GB", { hour: "2-digit", minute: "2-digit" })}`;
|
|
64
|
+
}
|
|
65
|
+
function buildSoulBundle(type, memory) {
|
|
66
|
+
const parts = [];
|
|
67
|
+
if (type === "A") {
|
|
68
|
+
let bundle = null;
|
|
69
|
+
try {
|
|
70
|
+
bundle = memory?.getSessionBundle() ?? null;
|
|
71
|
+
} catch (err) {
|
|
72
|
+
logAndSwallow(TAG, "op", err);
|
|
73
|
+
}
|
|
74
|
+
const soul = bundle?.soul || readOr(join(HOST_CORE_DIR, "SOUL.md"));
|
|
75
|
+
const memoryTools = bundle?.profile || readOr(join(HOST_CORE_DIR, "user_profile.md"));
|
|
76
|
+
const userProfile = bundle?.notes || readOr(join(HOST_CORE_DIR, "agent_notes.md"));
|
|
77
|
+
const agentNotes = bundle?.memoryTools || readOr(join(HOST_CORE_DIR, "TOOLS.md"));
|
|
78
|
+
const coreFacts = bundle?.coreFacts || readOr(join(HOST_CORE_DIR, "core_facts.md"));
|
|
79
|
+
if (soul) parts.push(soul);
|
|
80
|
+
if (memoryTools) parts.push(memoryTools);
|
|
81
|
+
if (userProfile) parts.push(userProfile);
|
|
82
|
+
if (agentNotes) parts.push(agentNotes);
|
|
83
|
+
if (coreFacts) parts.push(coreFacts);
|
|
84
|
+
const skillsCatalog = readOr(join(HOST_CORE_DIR, "skills_catalog.md"));
|
|
85
|
+
if (skillsCatalog) parts.push(skillsCatalog);
|
|
86
|
+
const modelInstructions = buildModelInstructions();
|
|
87
|
+
if (modelInstructions) parts.push(modelInstructions);
|
|
88
|
+
try {
|
|
89
|
+
const arcs = memory?.getEmotionalArcs() ?? [];
|
|
90
|
+
if (arcs.length > 0) {
|
|
91
|
+
const ARC_LABELS = { "\u2191": "user sentiment improving", "\u2193": "user sentiment worsening \u2014 be careful", "\u2195": "volatile \u2014 user feelings fluctuate", "\u2192": "stable" };
|
|
92
|
+
const lines = arcs.map((a) => `- ${a.topic}: ${a.arc} (${ARC_LABELS[a.arc] ?? "unknown"})`);
|
|
93
|
+
parts.push(`[EMOTIONAL CONTEXT]
|
|
94
|
+
${lines.join("\n")}`);
|
|
95
|
+
}
|
|
96
|
+
} catch (err) {
|
|
97
|
+
logAndSwallow(TAG, "op", err);
|
|
98
|
+
}
|
|
99
|
+
try {
|
|
100
|
+
const registry = loadUsers();
|
|
101
|
+
if (registry.users.length > 0) parts.push(buildUsersBlock(registry));
|
|
102
|
+
} catch (err) {
|
|
103
|
+
logAndSwallow(TAG, "op", err);
|
|
104
|
+
}
|
|
105
|
+
} else {
|
|
106
|
+
const identity = TYPE_IDENTITY[type];
|
|
107
|
+
if (identity) parts.push(identity);
|
|
108
|
+
const coreFacts = readOr(join(HOST_CORE_DIR, "core_facts.md"));
|
|
109
|
+
if (coreFacts) parts.push(coreFacts);
|
|
110
|
+
const skillsCatalog = readOr(join(HOST_CORE_DIR, "skills_catalog.md"));
|
|
111
|
+
if (skillsCatalog) parts.push(skillsCatalog);
|
|
112
|
+
}
|
|
113
|
+
parts.push(buildCurrentTime());
|
|
114
|
+
if (parts.length === 0) {
|
|
115
|
+
logWarn(TAG, "No bundle parts generated");
|
|
116
|
+
return null;
|
|
117
|
+
}
|
|
118
|
+
logInfo(TAG, `Bundle [${type}]: ${parts.length} parts`);
|
|
119
|
+
logDebug(TAG, `Parts: ${parts.map((p, i) => `${i}:${p.length}ch`).join(", ")}`);
|
|
120
|
+
return parts.join("\n\n---\n\n");
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
export {
|
|
124
|
+
buildSoulBundle
|
|
125
|
+
};
|
|
126
|
+
//# sourceMappingURL=chunk-P56PLAIC.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../src/components/soul-bundle.ts"],
|
|
4
|
+
"sourcesContent": ["/**\n * soul-bundle.ts \u2014 Unified SOUL bundle builder for all session types.\n * One function, one matrix. Replaces scattered injection logic.\n */\nimport { logAndSwallow } from \"./log-and-swallow.js\";\nimport { getEnv } from \"./env-schema.js\";\nimport { existsSync, readFileSync } from \"node:fs\";\nimport { join } from \"node:path\";\nimport { logInfo, logDebug, logWarn } from \"./logger.js\";\nimport { abtarsHome } from \"../paths.js\";\nimport { loadUsers, buildUsersBlock } from \"./user-registry.js\";\nimport type { MemoryManager } from \"abmind\";\nimport type { SessionType } from \"./session-manager.js\";\n\nconst TAG = \"soul-bundle\";\nconst HOST_CORE_DIR = join(abtarsHome(), \"core\");\n\nfunction readOr(path: string): string {\n try { return existsSync(path) ? readFileSync(path, \"utf-8\").trim() : \"\"; } catch { return \"\"; }\n}\n\n/** Type identity \u2014 hardcoded one-liners for non-Main sessions. */\nconst TYPE_IDENTITY: Record<SessionType, string | null> = {\n A: null, // uses full SOUL.md\n B: \"I am a browse agent. I fetch web content and return results. No memory access.\",\n C: \"I am a coding agent. I write and fix code. Be concise.\",\n T: \"I am a task agent. I execute scheduled tasks. Write all output to $WORKSPACE.\",\n S: \"I am the self-healing agent. I diagnose and fix system failures. If unfixable, state: Requires human intervention.\",\n P: \"I am responding to a peer agent request. Be precise and technical.\",\n};\n\nfunction buildModelInstructions(): string {\n const lines: string[] = [];\n if (getEnv().primingModelTopics) {\n lines.push(\"End each response with [TOPICS: kw1, kw2, kw3] \u2014 your top 3 topics from this exchange. Keep them English, lowercase, concise.\");\n }\n return lines.length > 0 ? `# Model Instructions\\n\\n${lines.join(\"\\n\")}` : \"\";\n}\n\nfunction buildCurrentTime(): string {\n const now = new Date();\n const days = [\"Sunday\", \"Monday\", \"Tuesday\", \"Wednesday\", \"Thursday\", \"Friday\", \"Saturday\"];\n return `[CURRENT TIME] ${now.toLocaleDateString(\"en-GB\")} ${days[now.getDay()]}, ${now.toLocaleTimeString(\"en-GB\", { hour: \"2-digit\", minute: \"2-digit\" })}`;\n}\n\n/**\n * Build the SOUL bundle for any session type.\n *\n * Main (A): full 9-part bundle (identity, tools, profile, notes, facts, skills, model-instructions, emotional, users, time)\n * Others: identity one-liner + core facts + skills + time\n */\nexport function buildSoulBundle(type: SessionType, memory?: MemoryManager | null): string | null {\n const parts: string[] = [];\n\n if (type === \"A\") {\n // Full Main bundle\n let bundle: { soul: string; profile: string; notes: string; memoryTools: string; coreFacts: string } | null = null;\n try { bundle = memory?.getSessionBundle() ?? null; } catch (err) { logAndSwallow(TAG, \"op\", err); }\n\n const soul = bundle?.soul || readOr(join(HOST_CORE_DIR, \"SOUL.md\"));\n const memoryTools = bundle?.profile || readOr(join(HOST_CORE_DIR, \"user_profile.md\"));\n const userProfile = bundle?.notes || readOr(join(HOST_CORE_DIR, \"agent_notes.md\"));\n const agentNotes = bundle?.memoryTools || readOr(join(HOST_CORE_DIR, \"TOOLS.md\"));\n const coreFacts = bundle?.coreFacts || readOr(join(HOST_CORE_DIR, \"core_facts.md\"));\n\n if (soul) parts.push(soul);\n if (memoryTools) parts.push(memoryTools);\n if (userProfile) parts.push(userProfile);\n if (agentNotes) parts.push(agentNotes);\n if (coreFacts) parts.push(coreFacts);\n\n const skillsCatalog = readOr(join(HOST_CORE_DIR, \"skills_catalog.md\"));\n if (skillsCatalog) parts.push(skillsCatalog);\n\n const modelInstructions = buildModelInstructions();\n if (modelInstructions) parts.push(modelInstructions);\n\n try {\n const arcs = memory?.getEmotionalArcs() ?? [];\n if (arcs.length > 0) {\n const ARC_LABELS: Record<string, string> = { \"\u2191\": \"user sentiment improving\", \"\u2193\": \"user sentiment worsening \u2014 be careful\", \"\u2195\": \"volatile \u2014 user feelings fluctuate\", \"\u2192\": \"stable\" };\n const lines = arcs.map(a => `- ${a.topic}: ${a.arc} (${ARC_LABELS[a.arc] ?? \"unknown\"})`);\n parts.push(`[EMOTIONAL CONTEXT]\\n${lines.join(\"\\n\")}`);\n }\n } catch (err) { logAndSwallow(TAG, \"op\", err); }\n\n try {\n const registry = loadUsers();\n if (registry.users.length > 0) parts.push(buildUsersBlock(registry));\n } catch (err) { logAndSwallow(TAG, \"op\", err); }\n } else {\n // Lightweight bundle: identity + core facts + skills\n const identity = TYPE_IDENTITY[type];\n if (identity) parts.push(identity);\n\n const coreFacts = readOr(join(HOST_CORE_DIR, \"core_facts.md\"));\n if (coreFacts) parts.push(coreFacts);\n\n const skillsCatalog = readOr(join(HOST_CORE_DIR, \"skills_catalog.md\"));\n if (skillsCatalog) parts.push(skillsCatalog);\n }\n\n parts.push(buildCurrentTime());\n\n if (parts.length === 0) {\n logWarn(TAG, \"No bundle parts generated\");\n return null;\n }\n\n logInfo(TAG, `Bundle [${type}]: ${parts.length} parts`);\n logDebug(TAG, `Parts: ${parts.map((p, i) => `${i}:${p.length}ch`).join(\", \")}`);\n return parts.join(\"\\n\\n---\\n\\n\");\n}\n"],
|
|
5
|
+
"mappings": "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",
|
|
6
|
+
"names": []
|
|
7
|
+
}
|
|
@@ -1,14 +1,15 @@
|
|
|
1
|
-
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import { createRequire as __bundleCreateRequire } from 'node:module'; import { fileURLToPath as __bundleFileURLToPath } from 'node:url'; import { dirname as __bundleDirname } from 'node:path'; const require = __bundleCreateRequire(import.meta.url); const __chunk_filename = __bundleFileURLToPath(import.meta.url); const __chunk_dirname = __bundleDirname(__chunk_filename);
|
|
2
3
|
import {
|
|
3
4
|
require_ws
|
|
4
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-NIRYBWUW.js";
|
|
5
6
|
import {
|
|
6
7
|
__commonJS,
|
|
7
8
|
__esm,
|
|
8
9
|
__export,
|
|
9
10
|
__require,
|
|
10
11
|
__toCommonJS
|
|
11
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-7K2YZTLD.js";
|
|
12
13
|
|
|
13
14
|
// node_modules/@discordjs/util/dist/index.js
|
|
14
15
|
var require_dist = __commonJS({
|
|
@@ -71907,4 +71908,4 @@ undici/lib/web/websocket/frame.js:
|
|
|
71907
71908
|
* @see https://github.com/colinhacks/zod/blob/master/LICENSE
|
|
71908
71909
|
*)
|
|
71909
71910
|
*/
|
|
71910
|
-
//# sourceMappingURL=chunk-
|
|
71911
|
+
//# sourceMappingURL=chunk-P6PN34XD.js.map
|