@makaio/framework 1.0.0-dev-1781023871421 → 1.0.0-dev-1781081952714
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/dist/.makaio-build.json +2 -2
- package/dist/{account-identity-DT5NOtFi.mjs → account-identity-CgzOqnVm.mjs} +1 -1
- package/dist/{adapter-C1eI-fGV.mjs → adapter-Dt2FDMs4.mjs} +1 -1
- package/dist/adapters/acp-client/index.d.mts +4 -4
- package/dist/adapters/config/index.d.mts +1 -1
- package/dist/adapters/config/index.mjs +1 -1
- package/dist/adapters/index.d.mts +24 -23
- package/dist/adapters/index.mjs +6 -13
- package/dist/adapters/node.d.mts +1 -1
- package/dist/adapters/node.mjs +1 -1
- package/dist/ajv-BJsabpMb.mjs +8 -0
- package/dist/await-trigger-DREnXCEJ.mjs +1 -0
- package/dist/bus/index.d.mts +19 -19
- package/dist/{client-bx74gm4R.mjs → client-BBJf1mVA.mjs} +1 -1
- package/dist/contracts/adapter/index.d.mts +2 -2
- package/dist/contracts/adapter/index.mjs +1 -1
- package/dist/contracts/adapter/schemas/session-lineage.d.mts +1 -1
- package/dist/contracts/artifact/index.d.mts +1 -1
- package/dist/contracts/client/index.d.mts +2 -2
- package/dist/contracts/client/index.mjs +1 -1
- package/dist/contracts/common/index.d.mts +1 -1
- package/dist/contracts/config/index.d.mts +1 -1
- package/dist/contracts/config/index.mjs +1 -1
- package/dist/contracts/extension/index.d.mts +3 -3
- package/dist/contracts/extension/index.mjs +1 -1
- package/dist/contracts/facet/index.d.mts +1 -1
- package/dist/contracts/facet/index.mjs +1 -1
- package/dist/contracts/harness/index.d.mts +1 -1
- package/dist/contracts/harness/index.mjs +1 -1
- package/dist/contracts/host/index.d.mts +1 -1
- package/dist/contracts/host/index.mjs +1 -1
- package/dist/contracts/index.d.mts +425 -425
- package/dist/contracts/index.mjs +1 -1
- package/dist/contracts/materialization/index.d.mts +3 -3
- package/dist/contracts/materialization/index.mjs +1 -1
- package/dist/contracts/model-registry/index.d.mts +1 -1
- package/dist/contracts/model-registry/index.mjs +1 -1
- package/dist/contracts/native-session-supervisor/index.d.mts +1 -1
- package/dist/contracts/native-session-supervisor/index.mjs +1 -1
- package/dist/contracts/platform/index.d.mts +1 -1
- package/dist/contracts/platform/index.mjs +1 -1
- package/dist/contracts/provider/index.d.mts +2 -2
- package/dist/contracts/session/index.d.mts +2 -2
- package/dist/contracts/session/index.mjs +1 -1
- package/dist/contracts/shared/index.d.mts +1 -1
- package/dist/contracts/skill/index.d.mts +1 -1
- package/dist/contracts/skill/index.mjs +1 -1
- package/dist/contracts/telemetry/index.d.mts +1 -1
- package/dist/contracts/telemetry/index.mjs +1 -1
- package/dist/contracts/timeout/index.d.mts +1 -1
- package/dist/contracts/toast/index.mjs +1 -1
- package/dist/contracts/variant/index.d.mts +1 -1
- package/dist/contracts/variant/index.mjs +1 -1
- package/dist/create-static-mount-CFGo91CI.mjs +1 -0
- package/dist/cross-spawn-BL6EvJBv.mjs +1 -0
- package/dist/{cursor-storage-CtVJ3JzB.mjs → cursor-storage-C_WTAESV.mjs} +1 -1
- package/dist/{definition-CrgHIpTK.d.mts → definition-DqJOg6Lv.d.mts} +1 -1
- package/dist/descriptor-to-package-CY8oc2gl.mjs +1 -0
- package/dist/detached-extension-handle-CxEBQnSa.mjs +1 -0
- package/dist/drizzle/0000_charming_prowler.sql +443 -0
- package/dist/drizzle/0001_known_stephen_strange.sql +25 -0
- package/dist/drizzle/0002_woozy_gladiator.sql +1 -0
- package/dist/drizzle/0003_overjoyed_adam_destine.sql +1 -0
- package/dist/drizzle/0004_solid_goliath.sql +1 -0
- package/dist/drizzle/0005_round_calypso.sql +51 -0
- package/dist/drizzle/0006_free_tiger_shark.sql +4 -0
- package/dist/drizzle/0007_sparkling_terror.sql +2 -0
- package/dist/drizzle/0008_petite_deathstrike.sql +1 -0
- package/dist/drizzle/0009_lethal_malcolm_colcord.sql +6 -0
- package/dist/drizzle/0010_grey_chronomancer.sql +1 -0
- package/dist/drizzle/0011_solid_nomad.sql +1 -0
- package/dist/drizzle/meta/0000_snapshot.json +2813 -0
- package/dist/drizzle/meta/0001_snapshot.json +2820 -0
- package/dist/drizzle/meta/0002_snapshot.json +2827 -0
- package/dist/drizzle/meta/0003_snapshot.json +2834 -0
- package/dist/drizzle/meta/0004_snapshot.json +2842 -0
- package/dist/drizzle/meta/0005_snapshot.json +2849 -0
- package/dist/drizzle/meta/0006_snapshot.json +2865 -0
- package/dist/drizzle/meta/0007_snapshot.json +2879 -0
- package/dist/drizzle/meta/0008_snapshot.json +2886 -0
- package/dist/drizzle/meta/0009_snapshot.json +2901 -0
- package/dist/drizzle/meta/0010_snapshot.json +2908 -0
- package/dist/drizzle/meta/0011_snapshot.json +2915 -0
- package/dist/drizzle/meta/_journal.json +90 -0
- package/dist/esm-BdLRFEUy.mjs +3 -0
- package/dist/expression/index.d.mts +120 -0
- package/dist/expression/index.mjs +1431 -0
- package/dist/extension--5Q190u_.mjs +1 -0
- package/dist/{extension-CpIUgBKI.mjs → extension-DFIZ3FCJ.mjs} +1 -1
- package/dist/extension-discovery-CkV_VRdJ.d.mts +163 -0
- package/dist/fast-uri-BF2Xuiop.mjs +1 -0
- package/dist/{filesystem-service-B8rhBRgB.mjs → filesystem-service-DH9zlxyd.mjs} +1 -1
- package/dist/git/index.mjs +17 -17
- package/dist/globby-4SrlyIlj.mjs +1 -0
- package/dist/{handlers-CkTsQLra.mjs → handlers-Bev7-xjL.mjs} +1 -1
- package/dist/{index-472sOmsW.d.mts → index-BAhJKQLX.d.mts} +7 -7
- package/dist/{index-D9MwJ2Q8.d.mts → index-BCKRUuI2.d.mts} +2 -2
- package/dist/{index-mNec7V-9.d.mts → index-BYkOUd0x.d.mts} +12 -12
- package/dist/{index-8SZkg7s6.d.mts → index-Bibt5jAX.d.mts} +8 -8
- package/dist/{index-DBw-89vC2.d.mts → index-BmV60tMf.d.mts} +18 -18
- package/dist/{index-B_zQC98V.d.mts → index-BpniJgxu.d.mts} +4 -4
- package/dist/{index-soFznFCy2.d.mts → index-Bw_zL7Rs.d.mts} +1 -1
- package/dist/{index-CelJCBjk.d.mts → index-C3zfJg6s.d.mts} +13 -13
- package/dist/{index-Caig6TeF.d.mts → index-CNOTkyGw.d.mts} +379 -303
- package/dist/{index-Bh_Ne7LF.d.mts → index-CwKzQuIX.d.mts} +28 -28
- package/dist/{index-B3PK4FIn.d.mts → index-D6bw4qJp.d.mts} +112 -112
- package/dist/{index-Cm0dUkWL.d.mts → index-DETxgKS2.d.mts} +24 -24
- package/dist/{index-D90OmGmV.d.mts → index-Db0uJ_Cg2.d.mts} +3 -3
- package/dist/{index-Bvb2mMH6.d.mts → index-IekAD8Gp.d.mts} +44 -44
- package/dist/index-YDfOv0GT.d.mts +1133 -0
- package/dist/{index-L4GjJDKb.d.mts → index-fVgKVvta.d.mts} +3 -3
- package/dist/{index-DUaw0Dw8.d.mts → index-jlQ4IhR5.d.mts} +497 -497
- package/dist/jsonl-transport-BxNXizIm.mjs +3 -0
- package/dist/kernel/cli/index.d.mts +2 -95
- package/dist/kernel/cli/index.mjs +1 -1
- package/dist/kernel/cli/register.d.mts +2 -0
- package/dist/kernel/cli/register.mjs +1 -0
- package/dist/kernel/cli/schemas.mjs +1 -1
- package/dist/kernel/extension/index.d.mts +1 -1
- package/dist/kernel/extension/index.mjs +1 -1
- package/dist/kernel/index.d.mts +5 -5
- package/dist/kernel/index.mjs +1 -1
- package/dist/kernel/namespace/index.d.mts +1 -1
- package/dist/kernel/namespace/index.mjs +1 -1
- package/dist/kernel/observability/index.d.mts +1 -1
- package/dist/kernel/observability/index.mjs +1 -1
- package/dist/kernel/providers/index.d.mts +1 -1
- package/dist/kernel/providers/index.mjs +1 -1
- package/dist/kernel/window/index.d.mts +1 -1
- package/dist/kernel/window/index.mjs +1 -1
- package/dist/lib-B9kVK_1_.mjs +4 -0
- package/dist/lib-DPruLs5D.mjs +155 -0
- package/dist/lib-aRogYLqg.mjs +5 -0
- package/dist/load-extensions-C-TqCwzL.mjs +1 -0
- package/dist/load-extensions-D9nbDIiW.d.mts +117 -0
- package/dist/mcp-http-server/index.d.mts +561 -0
- package/dist/mcp-http-server/index.mjs +4 -0
- package/dist/{namespace-EQniz-Aw.d.mts → namespace-B60mn8J-2.d.mts} +4 -4
- package/dist/{namespace-CxhsoFUP.d.mts → namespace-BBVtD1gu.d.mts} +14 -14
- package/dist/namespace-BXqetkc3.mjs +1 -0
- package/dist/{namespace-Dr8K0MCp.d.mts → namespace-BlS_i9KT.d.mts} +17 -17
- package/dist/{namespace-5QQqbF-B.d.mts → namespace-ByyuIFpL.d.mts} +91 -91
- package/dist/{namespace-DLovh2Ws.d.mts → namespace-CHMszppN.d.mts} +6 -6
- package/dist/{namespace-BM7Djng9.d.mts → namespace-CqUGzG53.d.mts} +2 -2
- package/dist/{namespace-DD8Oiqo7.d.mts → namespace-D1Iw_d1P.d.mts} +20 -20
- package/dist/{namespace-DgqkaOVu.d.mts → namespace-DBKWNrk7.d.mts} +22 -22
- package/dist/{namespace-CaaNnKcR.d.mts → namespace-Ds6HkJEU.d.mts} +138 -138
- package/dist/namespace-DzVf1hVH.d.mts +96 -0
- package/dist/{namespace-TyiTsLFv.d.mts → namespace-aBIAWxY3.d.mts} +46 -46
- package/dist/{namespace-DuXK5AYN.mjs → namespace-h0HIuqx0.mjs} +1 -1
- package/dist/{native-session-supervisor-B1TnaPUF.mjs → native-session-supervisor-DeKpxhWO.mjs} +1 -1
- package/dist/node/bus-server/index.d.mts +1 -1
- package/dist/node/bus-server/index.mjs +1 -1
- package/dist/node/bus-server/server-lifecycle.d.mts +1 -1
- package/dist/node/bus-server/server-lifecycle.mjs +1 -1
- package/dist/{orchestrator-shared-CIDiFJMD.mjs → orchestrator-shared-FnWrPS09.mjs} +1 -1
- package/dist/out-CvZYgczi.mjs +41 -0
- package/dist/package-1DS4bXg5.mjs +1 -0
- package/dist/package-BSnp1zOR.d.mts +372 -0
- package/dist/package.json +5 -0
- package/dist/primitive-runtime-DcYYWy_6.mjs +8 -0
- package/dist/{profile-6ynCD5k3.mjs → profile-D39-Zy_W.mjs} +1 -1
- package/dist/{provider-context-CK6B4X_8.mjs → provider-context-lfG0BpqX.mjs} +1 -1
- package/dist/quick-lru-B9nWXbXI.mjs +1 -0
- package/dist/rules/index.d.mts +27 -0
- package/dist/rules/index.mjs +1 -0
- package/dist/rules/schemas.d.mts +2 -0
- package/dist/rules/schemas.mjs +1 -0
- package/dist/runtime-bun/index.d.mts +385 -0
- package/dist/runtime-bun/index.mjs +1 -0
- package/dist/runtime-node/bus/runtime/namespace.d.mts +61 -0
- package/dist/runtime-node/bus/runtime/namespace.mjs +1 -0
- package/dist/runtime-node/bus/runtime/schemas.d.mts +54 -0
- package/dist/runtime-node/bus/runtime/schemas.mjs +1 -0
- package/dist/runtime-node/extension-discovery.d.mts +2 -0
- package/dist/runtime-node/extension-discovery.mjs +1 -0
- package/dist/runtime-node/extension-validation.d.mts +2 -0
- package/dist/runtime-node/extension-validation.mjs +1 -0
- package/dist/runtime-node/index.d.mts +745 -0
- package/dist/runtime-node/index.mjs +148 -0
- package/dist/runtime-node/makaio-config.d.mts +153 -0
- package/dist/runtime-node/makaio-config.mjs +1 -0
- package/dist/runtime-node/workflow-worker/index.d.mts +2 -0
- package/dist/runtime-node/workflow-worker/index.mjs +1 -0
- package/dist/runtime-node/workflow-worker/worker-entry.d.mts +39 -0
- package/dist/runtime-node/workflow-worker/worker-entry.mjs +1 -0
- package/dist/{schema-M5YTvSAG.d.mts → schema-CDL_pyyM.d.mts} +4 -4
- package/dist/{schema-e0wU_lcV.mjs → schema-DCJyzRHe.mjs} +1 -1
- package/dist/schema-introspection-CuRZPYEc.mjs +1 -0
- package/dist/{schemas-C46QfKzv.d.mts → schemas-B5ToLwIs.d.mts} +14 -14
- package/dist/schemas-C792eVAZ.d.mts +171 -0
- package/dist/{schemas-CaLhkkLn.mjs → schemas-CSUwpaNm.mjs} +1 -1
- package/dist/{schemas-DVF1A4DF.d.mts → schemas-Chyj6HuZ.d.mts} +9 -9
- package/dist/{schemas-DATniTHb.d.mts → schemas-DZUaRcYl.d.mts} +14 -14
- package/dist/{schemas-DiYVzG6e.d.mts → schemas-Exixg77V2.d.mts} +16 -16
- package/dist/{schemas-ClOOT1W6.d.mts → schemas-lqvZ6UpK.d.mts} +3 -3
- package/dist/{schemas-j7ivZ2HI.d.mts → schemas-on3_N5HP.d.mts} +138 -138
- package/dist/{schemas-wg_6PAdV.d.mts → schemas-t1VR6_b_.d.mts} +4 -4
- package/dist/semver-DhHJv6Dt.mjs +1 -0
- package/dist/services/adapter-runtime/index.d.mts +3 -3
- package/dist/services/adapter-runtime/index.mjs +1 -1
- package/dist/services/adapter-runtime/namespace.d.mts +1 -1
- package/dist/services/adapter-runtime/schemas.d.mts +1 -1
- package/dist/services/adapter-subsystem/index.d.mts +2 -2
- package/dist/services/adapter-subsystem/index.mjs +1 -1
- package/dist/services/adapter-subsystem/namespace.d.mts +1 -1
- package/dist/services/adapter-subsystem/namespace.mjs +1 -1
- package/dist/services/agent-runtime/index.d.mts +2 -2
- package/dist/services/agent-runtime/namespace.d.mts +1 -1
- package/dist/services/agent-runtime/schemas.d.mts +1 -1
- package/dist/services/capability/index.d.mts +1 -1
- package/dist/services/capability/index.mjs +1 -1
- package/dist/services/codebase/index.d.mts +2 -2
- package/dist/services/codebase/namespace.d.mts +1 -1
- package/dist/services/codebase/schemas.d.mts +1 -1
- package/dist/services/compression/index.d.mts +2 -2
- package/dist/services/compression/namespace.d.mts +1 -1
- package/dist/services/compression/schemas.d.mts +1 -1
- package/dist/services/context-rules/index.d.mts +7 -7
- package/dist/services/context-rules/index.mjs +1 -1
- package/dist/services/execution-target/index.d.mts +3 -3
- package/dist/services/execution-target/index.mjs +1 -1
- package/dist/services/execution-target/namespace.d.mts +1 -1
- package/dist/services/execution-target/schemas.d.mts +1 -1
- package/dist/services/filesystem/index.d.mts +1 -1
- package/dist/services/filesystem/index.mjs +1 -1
- package/dist/services/filesystem/namespace.d.mts +6 -6
- package/dist/services/filesystem/schemas.d.mts +3 -3
- package/dist/services/git/namespace.d.mts +6 -6
- package/dist/services/git/namespace.mjs +1 -1
- package/dist/services/git/schemas.d.mts +6 -6
- package/dist/services/git/schemas.mjs +1 -1
- package/dist/services/harness/index.d.mts +12 -12
- package/dist/services/harness/index.mjs +1 -1
- package/dist/services/index.d.mts +159 -158
- package/dist/services/index.mjs +1 -1
- package/dist/services/log-import/browser.d.mts +2 -2
- package/dist/services/log-import/index.d.mts +3 -3
- package/dist/services/log-import/log-import.d.mts +1 -1
- package/dist/services/log-import/log-import.mjs +1 -1
- package/dist/services/log-import/namespace.d.mts +6 -6
- package/dist/services/log-import/namespace.mjs +1 -1
- package/dist/services/log-import/schemas.d.mts +3 -3
- package/dist/services/log-import/schemas.mjs +1 -1
- package/dist/services/model-registry/index.d.mts +1 -1
- package/dist/services/model-registry/index.mjs +1 -1
- package/dist/services/preferences/index.d.mts +2 -2
- package/dist/services/preferences/schemas.d.mts +1 -1
- package/dist/services/preferences/storage-namespace.d.mts +2 -2
- package/dist/services/provider-context/index.d.mts +1 -1
- package/dist/services/provider-context/index.mjs +1 -1
- package/dist/services/provider-runtime/index.mjs +1 -1
- package/dist/services/session/handlers/index.d.mts +1 -1
- package/dist/services/session/handlers/index.mjs +1 -1
- package/dist/services/session/index.d.mts +9 -9
- package/dist/services/session/index.mjs +1 -1
- package/dist/services/session/messages/namespace.d.mts +1 -1
- package/dist/services/session/messages/namespace.mjs +1 -1
- package/dist/services/session/orchestrator-testing/index.d.mts +1 -1
- package/dist/services/session/orchestrator-testing/index.mjs +1 -1
- package/dist/services/session/session-events/namespace.d.mts +1 -1
- package/dist/services/session/session-events/namespace.mjs +1 -1
- package/dist/services/session/storage/namespace.d.mts +1 -1
- package/dist/services/session/storage/schema.d.mts +1 -1
- package/dist/services/session/testing/index.mjs +1 -1
- package/dist/services/session/testing/orchestrator-shared.d.mts +1 -1
- package/dist/services/session/testing/orchestrator-shared.mjs +1 -1
- package/dist/services/session/turns/namespace.d.mts +1 -1
- package/dist/services/session/turns/namespace.mjs +1 -1
- package/dist/services/session-editor/index.d.mts +1 -1
- package/dist/services/session-editor/index.mjs +1 -1
- package/dist/services/settings/index.d.mts +3 -3
- package/dist/services/settings/index.mjs +1 -1
- package/dist/services/settings/namespace.d.mts +10 -10
- package/dist/services/settings/namespace.mjs +1 -1
- package/dist/services/settings/storage/clients-namespace.d.mts +1 -1
- package/dist/services/settings/storage/clients-namespace.mjs +1 -1
- package/dist/services/settings/storage/extension-configs/namespace.d.mts +3 -3
- package/dist/services/settings/storage/index.d.mts +3 -3
- package/dist/services/settings/storage/index.mjs +1 -1
- package/dist/services/settings/storage/providers-namespace.d.mts +1 -1
- package/dist/services/settings/storage/providers-namespace.mjs +1 -1
- package/dist/services/subagent/index.d.mts +1 -1
- package/dist/services/subagent/index.mjs +1 -1
- package/dist/services/subagent-template/index.d.mts +2 -2
- package/dist/services/subagent-template/namespace.d.mts +1 -1
- package/dist/services/subagent-template/schemas.d.mts +1 -1
- package/dist/services/tool-approval/index.d.mts +1 -1
- package/dist/services/tool-approval/index.mjs +1 -1
- package/dist/services/tools/index.d.mts +1 -1
- package/dist/services/tools/index.mjs +1 -1
- package/dist/services/tray-menu/index.d.mts +3 -3
- package/dist/services/tray-menu/index.mjs +1 -1
- package/dist/services/tray-menu/namespace.d.mts +1 -1
- package/dist/services/tray-menu/schemas.d.mts +1 -1
- package/dist/services/turn/index.d.mts +1 -1
- package/dist/services/turn/namespace.d.mts +1 -1
- package/dist/services/turn/schemas.d.mts +10 -10
- package/dist/{session-BoldSdNZ2.mjs → session-BnfsJoZi.mjs} +1 -1
- package/dist/{session-DuVOYctZ.mjs → session-C1Cami7U.mjs} +1 -1
- package/dist/{session-lineage-CRsc9g1x.d.mts → session-lineage-CKg6mErA.d.mts} +1 -1
- package/dist/{skill-CQO4mDqK.mjs → skill-BNQnWVIG.mjs} +1 -1
- package/dist/src-Dvp41Cg2.mjs +1 -0
- package/dist/src-Z3vAZJfw.mjs +21 -0
- package/dist/storage/drizzle/client.d.mts +1 -1
- package/dist/storage/drizzle/index.d.mts +1 -1
- package/dist/storage/handlers/drizzle/index.d.mts +1 -1
- package/dist/storage/handlers/drizzle/index.mjs +1 -1
- package/dist/storage/handlers/index.d.mts +1 -1
- package/dist/storage/handlers/index.mjs +1 -1
- package/dist/storage-namespace-BXO3lDVy.mjs +1 -0
- package/dist/{storage-namespace-BXkoh5Sy.d.mts → storage-namespace-BXmMUd7a.d.mts} +20 -20
- package/dist/style.css +540 -540
- package/dist/supports-color-fVsgozsi.mjs +1 -0
- package/dist/tool-approval-service-BgNcJvKx.mjs +1 -0
- package/dist/tools-DC4KrqI1.mjs +1 -0
- package/dist/{types-CCdqjeuH.d.mts → types-B0BtvVAq.d.mts} +2 -81
- package/dist/{types-BCMUtBj1.d.mts → types-CmMesAgR.d.mts} +1 -1
- package/dist/{types-DZHvOc_Q.d.mts → types-D0fPFh-D.d.mts} +1 -1
- package/dist/{types-Dy3YTcTF.d.mts → types-DiGqpZOD.d.mts} +288 -288
- package/dist/ui-components/index.d.mts +1 -1
- package/dist/ui-components/index.mjs +2 -2
- package/dist/ui-hooks/index.d.mts +6 -6
- package/dist/ui-kernel/index.d.mts +7 -7
- package/dist/ui-kernel/pages/namespace.d.mts +8 -8
- package/dist/ui-kernel/pages/schemas.d.mts +1 -1
- package/dist/ui-views/index.mjs +2 -2
- package/dist/version-B4NO_fID.mjs +1 -0
- package/dist/workflow-engine/index.d.mts +6568 -0
- package/dist/workflow-engine/index.mjs +1 -0
- package/dist/workflow-engine/package.d.mts +2 -0
- package/dist/workflow-engine/package.mjs +1 -0
- package/dist/workflow-engine/workflow-orchestrator.d.mts +61 -0
- package/dist/workflow-engine/workflow-orchestrator.mjs +1 -0
- package/dist/workflow-worker-DvP753UN.mjs +1 -0
- package/package.json +65 -1
- package/dist/extension-C-4BHMRI.mjs +0 -1
- package/dist/globby-rtWVaFHv.mjs +0 -41
- package/dist/schema-introspection-Dn1jWQs1.mjs +0 -1
- package/dist/schemas-CVvwIfG4.mjs +0 -1
- package/dist/storage-namespace-DWsYLAXa.mjs +0 -1
- package/dist/tool-approval-service-BvZWhYZp.mjs +0 -1
- package/dist/tools-D-luYcDw.mjs +0 -1431
- package/dist/version-BeT3ASEe.mjs +0 -1
- /package/dist/{base-orchestrator-wyumsn3b.d.mts → base-orchestrator-M5mAB5-w.d.mts} +0 -0
- /package/dist/{capability-service-CJbmhfv9.mjs → capability-service-jjrFLM6r.mjs} +0 -0
- /package/dist/{cleanEnvForAdapter-KkYzQa1f.mjs → cleanEnvForAdapter-BlpmyXYk.mjs} +0 -0
- /package/dist/{clients-namespace-GmSJpBUV.d.mts → clients-namespace-SFk7OTop.d.mts} +0 -0
- /package/dist/{config-namespace-CPY9YsR8.d.mts → config-namespace-BzAvE2nY.d.mts} +0 -0
- /package/dist/{config-namespace-ncYg2ct_.mjs → config-namespace-DydHz9so.mjs} +0 -0
- /package/dist/{definition-BLCdXGzh.d.mts → definition-BSghHJpQ.d.mts} +0 -0
- /package/dist/{definition-pkJ6szUl.d.mts → definition-q6iLw11H.d.mts} +0 -0
- /package/dist/{drizzle-Eq8W1EbD.mjs → drizzle-DpjZFY_j.mjs} +0 -0
- /package/dist/{event-Ca2yUf5i.mjs → event-BEllCn16.mjs} +0 -0
- /package/dist/{execution-target-CRPTfZlc.mjs → execution-target-CQGYaaM2.mjs} +0 -0
- /package/dist/{extension-namespace-cMh_mMiL.mjs → extension-namespace-BBgYOttA.mjs} +0 -0
- /package/dist/{facet-BuwhrThl.mjs → facet-DMrryX_0.mjs} +0 -0
- /package/dist/{filesystem-service-p_iJVHd4.d.mts → filesystem-service-Ddngll0j.d.mts} +0 -0
- /package/dist/{harness-BRCMcvQN.mjs → harness-B8E_wRwa.mjs} +0 -0
- /package/dist/{host-Br9VuOyr.mjs → host-DbMiI5wQ.mjs} +0 -0
- /package/dist/{identity-Cz2IeEtm.mjs → identity-Bmx-8fPa.mjs} +0 -0
- /package/dist/{index-U-A8eyGT.d.mts → index-9IDJUJ4X.d.mts} +0 -0
- /package/dist/{index-CGmcS0Ma.d.mts → index-BBvcP-P0.d.mts} +0 -0
- /package/dist/{index-BGfWS6GE.d.mts → index-BKKNWqkP2.d.mts} +0 -0
- /package/dist/{index-DKia0MX1.d.mts → index-BMpRB6iE.d.mts} +0 -0
- /package/dist/{index-CHQ1SqT0.d.mts → index-BbCjtc3h.d.mts} +0 -0
- /package/dist/{index-BFg9BUpx.d.mts → index-BheaEhyI.d.mts} +0 -0
- /package/dist/{index-Cs0kZXIz2.d.mts → index-BnQSPC6c.d.mts} +0 -0
- /package/dist/{index-CCGVh9BF2.d.mts → index-BpXX9WZJ.d.mts} +0 -0
- /package/dist/{index-DMKnON5s.d.mts → index-Bsp0O_sI.d.mts} +0 -0
- /package/dist/{index-DANINzMu.d.mts → index-Buo9H8RK.d.mts} +0 -0
- /package/dist/{index-CLpjm52M.d.mts → index-BxFA1XcP.d.mts} +0 -0
- /package/dist/{index-ChunCFu4.d.mts → index-C33Tq1ei2.d.mts} +0 -0
- /package/dist/{index-DGBu6bHi2.d.mts → index-C6BhKRnH.d.mts} +0 -0
- /package/dist/{index-eemAKwsB.d.mts → index-CDU_s69P.d.mts} +0 -0
- /package/dist/{index-DKC62dY5.d.mts → index-CGJjA-hR2.d.mts} +0 -0
- /package/dist/{index-CokQYGVP.d.mts → index-Clut1ljB.d.mts} +0 -0
- /package/dist/{index-BVgfS-AJ.d.mts → index-Cz9JMjZK.d.mts} +0 -0
- /package/dist/{index-vtXJuwrz.d.mts → index-D0SUjZmU.d.mts} +0 -0
- /package/dist/{index-x_lVDp_J.d.mts → index-D6Iyvz9T.d.mts} +0 -0
- /package/dist/{index-D5d5HeWI2.d.mts → index-DOfq0qqv.d.mts} +0 -0
- /package/dist/{index-De3kPhlN.d.mts → index-DSV1aFgK.d.mts} +0 -0
- /package/dist/{index-B80L4YqA.d.mts → index-Dsq2zKvu.d.mts} +0 -0
- /package/dist/{materialization-CuUBu4XI.mjs → materialization-3QUnQLbC.mjs} +0 -0
- /package/dist/{model-registry-Scn_MC2d.mjs → model-registry-B0AIdj7O.mjs} +0 -0
- /package/dist/{model-registry-CfXytvzx.mjs → model-registry-j-rCKcik.mjs} +0 -0
- /package/dist/{namespace-CFLAmQfh.mjs → namespace-BbjCyZC9.mjs} +0 -0
- /package/dist/{namespace-BwzZJqTV.mjs → namespace-BgPoC46Q.mjs} +0 -0
- /package/dist/{namespace-Yna5-Pws.mjs → namespace-CDiM5Bcr.mjs} +0 -0
- /package/dist/{namespace-BoD94mrN.mjs → namespace-CUOGcGPG.mjs} +0 -0
- /package/dist/{namespace-LViZ-EQk.mjs → namespace-D6X67cUk.mjs} +0 -0
- /package/dist/{namespace-DkRgbZYn.mjs → namespace-ENv7H7Na.mjs} +0 -0
- /package/dist/{namespace-xcmbQlxh.mjs → namespace-FT8igkn4.mjs} +0 -0
- /package/dist/{namespace-CaoZ3S78.d.mts → namespace-XTGCaSXj.d.mts} +0 -0
- /package/dist/{namespace-CTm3nEvh.d.mts → namespace-nlsvvMtD.d.mts} +0 -0
- /package/dist/{namespace-IV1QK__V.d.mts → namespace-uuR0Fg5r.d.mts} +0 -0
- /package/dist/{orchestrator-shared-Dfa7FMyw.d.mts → orchestrator-shared-D91Wk7z-.d.mts} +0 -0
- /package/dist/{package-DKVlsMP3.mjs → package-OE9dMQsq.mjs} +0 -0
- /package/dist/{platform-DZ7z-wXD.mjs → platform-Dhv22LiX.mjs} +0 -0
- /package/dist/{providers-u8i15co9.mjs → providers-B1p0P-vB.mjs} +0 -0
- /package/dist/{providers-namespace-DSEpli4A.d.mts → providers-namespace-BqWYkydw.d.mts} +0 -0
- /package/dist/{schema-CoyE6mPt.mjs → schema-DOnJmAPw.mjs} +0 -0
- /package/dist/{schemas-Bd0OjRQf.d.mts → schemas-B77Gi8Xr.d.mts} +0 -0
- /package/dist/{schemas-jFe1AuI-.mjs → schemas-BCIuTWRl2.mjs} +0 -0
- /package/dist/{schemas-DE-GNmSD.mjs → schemas-BdAf5u58.mjs} +0 -0
- /package/dist/{schemas-CDBSjg7o.d.mts → schemas-Dyk7JuVl.d.mts} +0 -0
- /package/dist/{schemas-DaRSfYLf.d.mts → schemas-Kq33MTPY.d.mts} +0 -0
- /package/dist/{server-lifecycle-YoSGFGnU.d.mts → server-lifecycle-47mygK3E.d.mts} +0 -0
- /package/dist/{server-lifecycle-FXTPW39-.mjs → server-lifecycle-Cg47L59Q.mjs} +0 -0
- /package/dist/{shared-schemas-CPShiLNp.mjs → shared-schemas-CKe2uN4-.mjs} +0 -0
- /package/dist/{storage-namespace-definition-Bkx5rSto.d.mts → storage-namespace-definition-C3XbpiP8.d.mts} +0 -0
- /package/dist/{storage-namespace-definition-CqSdsuCC.mjs → storage-namespace-definition-RvjfFysN.mjs} +0 -0
- /package/dist/{telemetry-CvdLBWuk.mjs → telemetry-O0394b7p.mjs} +0 -0
- /package/dist/{tray-menu-service-DuXq5k22.mjs → tray-menu-service-B5YPK_YF.mjs} +0 -0
- /package/dist/{types-C2Ob9zz_.d.mts → types-5Gw3iVpK.d.mts} +0 -0
- /package/dist/{types-dyP-bXXE.d.mts → types-BhXRffJ_.d.mts} +0 -0
- /package/dist/{types-MfJZ67e9.d.mts → types-D-bP8RRE.d.mts} +0 -0
- /package/dist/{variant-CT6XBP6T.mjs → variant-COVbYmMs.mjs} +0 -0
- /package/dist/{window-registry-CBcrGTv4.d.mts → window-registry-CfEi_Ji4.d.mts} +0 -0
- /package/dist/{window-registry-DW-dKRjQ.mjs → window-registry-XjOExitT.mjs} +0 -0
|
@@ -0,0 +1,745 @@
|
|
|
1
|
+
import { RuntimeSubjects } from "./bus/runtime/namespace.mjs";
|
|
2
|
+
import { a as FilesystemDescriptorDiscovery, n as ExplicitDescriptorDiscovery, o as FilesystemDescriptorDiscoveryOptions, r as ExtensionDiscovery, t as DiscoveredExtension } from "../extension-discovery-CkV_VRdJ.mjs";
|
|
3
|
+
import { a as isMakaioExtensionLike, c as resolveConventionEntrypoint, i as isCliContributionLike, n as LoadExtensionsOptions, o as isWithinDirectory, r as entrypointStem, s as loadExtensions, t as DescriptorSourcePackageGroup } from "../load-extensions-D9nbDIiW.mjs";
|
|
4
|
+
import { A as normalizeNodeHostCapabilities, B as HttpContributionPhase, C as TransportReadyInfo, D as WorkflowWorkerEntryResolverOptions, E as WorkflowWorkerEntryMode, F as NodeFrameworkModuleResolver, H as HonoRouteGraph, I as NoopFrameworkModuleResolver, L as resolveFrameworkSpecifier, M as ShutdownStep, N as BridgeBrowserOptions, O as resolveWorkflowWorkerEntry, P as FrameworkModuleResolver, R as HttpRouteGraphBuilder, S as ServerTransportProvider, T as WorkflowRunnerBootOptions, U as HonoRouteGraphOptions, V as HttpRouteContribution, W as createHonoRouteGraph, _ as WorkflowRunResult, a as InProcessWorkflowRunnerOptions, b as CoreBootOptions, g as ThinWorkflowPiscinaRunnerOptions, h as IWorkflowRunner, i as InProcessWorkflowRunner, j as selectFrameworkCorePackages, k as HostCapabilityDeclaration, m as ThinWorkflowPiscinaRunner, v as BootCoordinatorSetupContext, w as UpstreamTelemetryBootOptions, x as MakaioRuntime, y as BootMakaioRuntimeOptions, z as createHttpRouteGraphBuilder } from "../index-YDfOv0GT.mjs";
|
|
5
|
+
import { ConfiguredRuntimeOptions, LoadMakaioConfigOptions, LoadedMakaioConfig, MAKAIO_CONFIG_FILE_ENV, MAKAIO_HOME_ENV, MakaioConfig, ParseMakaioConfigOptions, ParsedMakaioConfig, WorkflowRunnerConfig, buildConfiguredRuntimeOptions, createMakaioConfigDiscovery, defineMakaioConfig, loadMakaioConfig, parseMakaioConfig, resolveMakaioConfigPath, resolveMakaioHome, shouldIncludeExtension } from "./makaio-config.mjs";
|
|
6
|
+
import { z } from "zod";
|
|
7
|
+
import { IConfigStorage } from "@makaio/framework/core";
|
|
8
|
+
import { BusTransport, IMakaioBus } from "@makaio/framework/bus";
|
|
9
|
+
import { AdapterClientRef, AdapterProviderDefinitionContract, Config, MakaioNodeExtension, ProtocolId } from "@makaio/framework/contracts";
|
|
10
|
+
import { BaseService } from "@makaio/framework/service-base";
|
|
11
|
+
import { MakaioDatabase } from "@makaio/framework/storage/drizzle";
|
|
12
|
+
import { AdapterFile, CredentialRef, ProviderConfigFile } from "@makaio/framework/contracts/config";
|
|
13
|
+
import { IAdapterConfigRepository, IAdapterConfigRepository as IAdapterConfigRepository$1 } from "@makaio/framework/services/adapter-subsystem";
|
|
14
|
+
import { DispatchingAuth } from "@makaio/framework/node/transports";
|
|
15
|
+
import { DatabaseClient } from "@makaio/framework/storage/drizzle/client";
|
|
16
|
+
import { ContributionProcessor, ExtensionCoordinator, KernelMakaioExtension, TransportProvider } from "@makaio/framework/kernel";
|
|
17
|
+
import { IModelRegistryCache, ModelRegistry } from "@makaio/framework/services/model-registry";
|
|
18
|
+
import { MachineKeyStatus, MachineKeyValidation, PersistedMachineIdentity, loadOrCreateMachineIdentity, machineKeysExist, validateMachineKeys } from "@makaio/framework/node/machine-identity";
|
|
19
|
+
import { TransportAuth as TransportAuth$1 } from "@makaio/framework/node/bus-server";
|
|
20
|
+
import { ConfigProvider } from "@makaio/framework/providers";
|
|
21
|
+
import { Server } from "node:http";
|
|
22
|
+
//#region runtimes/node/src/register-adapter-name-resolver.d.ts
|
|
23
|
+
/**
|
|
24
|
+
* Register middleware to resolve `adapterName` to `adapterId` for `getCapabilities` requests.
|
|
25
|
+
*
|
|
26
|
+
* Problem: Adapter handlers filter by `adapterId` only — name-only requests never reach handlers.
|
|
27
|
+
* Solution: Middleware with priority 20 resolves `adapterName` through the
|
|
28
|
+
* runtime identity seam before adapter handlers run.
|
|
29
|
+
* @param bus - The bus instance to register the middleware on
|
|
30
|
+
* @returns Cleanup function to unsubscribe the middleware
|
|
31
|
+
*/
|
|
32
|
+
declare function registerAdapterNameResolver(bus: IMakaioBus): () => void;
|
|
33
|
+
//#endregion
|
|
34
|
+
//#region subsystems/adapter/src/adapter-runtime-lifecycle.d.ts
|
|
35
|
+
/**
|
|
36
|
+
* Platform-provided defaults injected by the runtime host.
|
|
37
|
+
*
|
|
38
|
+
* Mirrors the shape of `PlatformDefaults` from `@makaio/ai-adapters-core`
|
|
39
|
+
* without taking a dependency on the host-layer package.
|
|
40
|
+
*/
|
|
41
|
+
interface PlatformDefaults {
|
|
42
|
+
/** Default working directory for agent execution (e.g. `os.tmpdir()` on Node.js). */
|
|
43
|
+
cwd?: string;
|
|
44
|
+
/** Default environment variables. */
|
|
45
|
+
env?: Record<string, string>;
|
|
46
|
+
}
|
|
47
|
+
//#endregion
|
|
48
|
+
//#region subsystems/adapter/src/index.d.ts
|
|
49
|
+
/**
|
|
50
|
+
* Options for creating the adapter subsystem extension package.
|
|
51
|
+
*/
|
|
52
|
+
interface CreateAdapterSubsystemPackageOptions {
|
|
53
|
+
/**
|
|
54
|
+
* Repository seam used by the subsystem service for file-backed config storage.
|
|
55
|
+
*/
|
|
56
|
+
readonly configRepository: IAdapterConfigRepository;
|
|
57
|
+
/**
|
|
58
|
+
* Extension coordinator forwarded to {@link AdapterContributionProcessor}.
|
|
59
|
+
*
|
|
60
|
+
* The composition root registers the contribution processor (via
|
|
61
|
+
* {@link createAdapterSubsystemContributionProcessor}) with this coordinator
|
|
62
|
+
* before `coordinator.startAll()` so adapter contributions run in a stable
|
|
63
|
+
* order relative to other contribution processors.
|
|
64
|
+
*/
|
|
65
|
+
readonly coordinator: ExtensionCoordinator;
|
|
66
|
+
/**
|
|
67
|
+
* Platform-provided defaults forwarded to adapter factories.
|
|
68
|
+
*/
|
|
69
|
+
readonly platformDefaults: PlatformDefaults;
|
|
70
|
+
}
|
|
71
|
+
/**
|
|
72
|
+
* Create the adapter subsystem extension package.
|
|
73
|
+
*
|
|
74
|
+
* The returned package is critical and declares the `adapters` capability.
|
|
75
|
+
* The composition root must register the contribution processor via
|
|
76
|
+
* {@link createAdapterSubsystemContributionProcessor} before calling
|
|
77
|
+
* `coordinator.startAll()` to ensure adapter contributions are processed in a
|
|
78
|
+
* stable order.
|
|
79
|
+
* @param options - Package-scoped dependencies including the coordinator.
|
|
80
|
+
* @returns Critical Makaio extension for the adapter subsystem.
|
|
81
|
+
*/
|
|
82
|
+
declare function createAdapterSubsystemPackage(options: CreateAdapterSubsystemPackageOptions): MakaioNodeExtension<IMakaioBus>;
|
|
83
|
+
//#endregion
|
|
84
|
+
//#region runtimes/node/src/compose-adapter-runtime.d.ts
|
|
85
|
+
/**
|
|
86
|
+
* Composition seam for booting a local adapter runtime.
|
|
87
|
+
*
|
|
88
|
+
* Encapsulates the proven host sequence for making `adapter.*` execution
|
|
89
|
+
* subjects locally owned, so every adapter-capable runtime composes it the
|
|
90
|
+
* same way instead of reinventing it. There are two phases because the kernel
|
|
91
|
+
* lifecycle requires it:
|
|
92
|
+
*
|
|
93
|
+
* 1. {@link prepareAdapterRuntime} — call **before** `coordinator.startAll()`:
|
|
94
|
+
* builds the adapter-subsystem package (add it to the coordinator load set)
|
|
95
|
+
* and registers the adapter contribution processor so adapter contributions
|
|
96
|
+
* are awaited during activation.
|
|
97
|
+
* 2. {@link activateAdapterRuntimeIdentity} — call **after** `coordinator.startAll()`:
|
|
98
|
+
* registers the adapter-runtime identity handlers and the adapter-name
|
|
99
|
+
* resolver, which resolve `adapterName` to the deterministic adapter id that
|
|
100
|
+
* live `AIAdapter` instances filter `AdapterSubjects.startAgent` on.
|
|
101
|
+
*
|
|
102
|
+
* The locality invariant this seam upholds: the `currentMachineId` passed to
|
|
103
|
+
* {@link activateAdapterRuntimeIdentity} MUST be the same machine id the
|
|
104
|
+
* coordinator injects as `extensionContextBase.machineId` (and therefore the
|
|
105
|
+
* id `AdapterSubsystemService` and `SubagentService` derive adapter ids from).
|
|
106
|
+
* If they diverge, `AdapterRuntimeSubjects.resolveId` yields an id no local
|
|
107
|
+
* adapter listens on and `startAgent` silently falls through to the transport.
|
|
108
|
+
*/
|
|
109
|
+
/** Input for {@link prepareAdapterRuntime} (the pre-`startAll` phase). */
|
|
110
|
+
interface PrepareAdapterRuntimeInput {
|
|
111
|
+
/** Coordinator that loads the adapter-subsystem package and owns activation. */
|
|
112
|
+
readonly coordinator: ExtensionCoordinator;
|
|
113
|
+
/** Persistence seam for adapter/provider configuration. */
|
|
114
|
+
readonly configRepository: IAdapterConfigRepository$1;
|
|
115
|
+
/** Platform defaults (cwd/env) supplied to adapter instances. */
|
|
116
|
+
readonly platformDefaults: PlatformDefaults;
|
|
117
|
+
}
|
|
118
|
+
/** Result of {@link prepareAdapterRuntime}. */
|
|
119
|
+
interface PreparedAdapterRuntime {
|
|
120
|
+
/**
|
|
121
|
+
* The adapter-subsystem package. The caller MUST add this to the array passed
|
|
122
|
+
* to `coordinator.load(...)`; its `create` reads `ctx.machineId`, so adapter
|
|
123
|
+
* ids derive from the coordinator's machine id.
|
|
124
|
+
*/
|
|
125
|
+
readonly adapterSubsystemPackage: ReturnType<typeof createAdapterSubsystemPackage>;
|
|
126
|
+
}
|
|
127
|
+
/** Input for {@link activateAdapterRuntimeIdentity} (the post-`startAll` phase). */
|
|
128
|
+
interface ActivateAdapterRuntimeIdentityInput {
|
|
129
|
+
/** Bus the identity handlers and name resolver are registered on. */
|
|
130
|
+
readonly bus: IMakaioBus;
|
|
131
|
+
/**
|
|
132
|
+
* The runtime's machine id. MUST equal the coordinator's
|
|
133
|
+
* `extensionContextBase.machineId` (see the locality invariant above).
|
|
134
|
+
*/
|
|
135
|
+
readonly currentMachineId: string;
|
|
136
|
+
/**
|
|
137
|
+
* Optional override for enumerating known adapter names. Defaults to querying
|
|
138
|
+
* `AdapterSubsystemSubjects.listAdapterConfigs` on the bus, matching the host.
|
|
139
|
+
*/
|
|
140
|
+
readonly listKnownAdapterNames?: () => Promise<Iterable<string>>;
|
|
141
|
+
}
|
|
142
|
+
/** Result of {@link activateAdapterRuntimeIdentity}. */
|
|
143
|
+
interface ActivatedAdapterRuntimeIdentity {
|
|
144
|
+
/** Tear down the identity handlers and the adapter-name resolver. */
|
|
145
|
+
readonly cleanup: () => void;
|
|
146
|
+
}
|
|
147
|
+
/**
|
|
148
|
+
* Build the adapter-subsystem package and register its contribution processor.
|
|
149
|
+
*
|
|
150
|
+
* Call before `coordinator.startAll()`. Registering the contribution processor
|
|
151
|
+
* only stores it for use during activation, so it is order-independent relative
|
|
152
|
+
* to `coordinator.load(...)` as long as it happens before `startAll()`.
|
|
153
|
+
* @param input - Coordinator, config repository, and platform defaults.
|
|
154
|
+
* @returns The adapter-subsystem package to add to the coordinator load set.
|
|
155
|
+
*/
|
|
156
|
+
declare function prepareAdapterRuntime(input: PrepareAdapterRuntimeInput): PreparedAdapterRuntime;
|
|
157
|
+
/**
|
|
158
|
+
* Register the adapter-runtime identity handlers and adapter-name resolver.
|
|
159
|
+
*
|
|
160
|
+
* Call after `coordinator.startAll()` so that `CapabilityService` and the
|
|
161
|
+
* adapter subsystem have registered their handlers.
|
|
162
|
+
* @param input - Bus, the runtime machine id, and an optional name enumerator.
|
|
163
|
+
* @returns A cleanup that tears both registrations down.
|
|
164
|
+
*/
|
|
165
|
+
declare function activateAdapterRuntimeIdentity(input: ActivateAdapterRuntimeIdentityInput): ActivatedAdapterRuntimeIdentity;
|
|
166
|
+
//#endregion
|
|
167
|
+
//#region runtimes/node/src/db-migrations.d.ts
|
|
168
|
+
/** Options for applying framework central migrations. */
|
|
169
|
+
interface RunMigrationsOptions {
|
|
170
|
+
/** Optional filesystem path to a bundled framework `drizzle/` migrations directory. */
|
|
171
|
+
readonly migrationsDir?: string;
|
|
172
|
+
}
|
|
173
|
+
/**
|
|
174
|
+
* Run all database migrations.
|
|
175
|
+
*
|
|
176
|
+
* 1. Runs Drizzle-generated migrations for all framework tables
|
|
177
|
+
* 2. Creates framework-owned FTS5 virtual tables and triggers (not supported by Drizzle)
|
|
178
|
+
* @param db - Drizzle database instance
|
|
179
|
+
* @param options - Optional migration source overrides for bundled hosts.
|
|
180
|
+
*/
|
|
181
|
+
declare function runMigrations(db: MakaioDatabase, options?: RunMigrationsOptions): Promise<void>;
|
|
182
|
+
//#endregion
|
|
183
|
+
//#region runtimes/node/src/file-config-storage.d.ts
|
|
184
|
+
/**
|
|
185
|
+
* File-based config storage for Node.js runtime.
|
|
186
|
+
*
|
|
187
|
+
* Reads/writes `<makaioHome>/config.json` for bootstrap configuration.
|
|
188
|
+
* Returns default config if file is missing.
|
|
189
|
+
*/
|
|
190
|
+
declare class FileConfigStorage implements IConfigStorage<Config> {
|
|
191
|
+
private readonly configPath;
|
|
192
|
+
/**
|
|
193
|
+
* Create a new FileConfigStorage instance.
|
|
194
|
+
* @param makaioHome - Makaio home directory (e.g. `~/.makaio`). The config
|
|
195
|
+
* file is stored as `config.json` inside this directory.
|
|
196
|
+
*/
|
|
197
|
+
constructor(makaioHome: string);
|
|
198
|
+
/**
|
|
199
|
+
* Get the current config.
|
|
200
|
+
* Returns default config (applying Zod defaults) if file doesn't exist.
|
|
201
|
+
* @returns The config object
|
|
202
|
+
*/
|
|
203
|
+
getConfig(): Promise<Config>;
|
|
204
|
+
/**
|
|
205
|
+
* Save the config.
|
|
206
|
+
* Creates directory if it doesn't exist.
|
|
207
|
+
* @param config - The config object to save
|
|
208
|
+
*/
|
|
209
|
+
saveConfig(config: Config): Promise<void>;
|
|
210
|
+
}
|
|
211
|
+
//#endregion
|
|
212
|
+
//#region runtimes/node/src/model-registry/static-registry-path.d.ts
|
|
213
|
+
/**
|
|
214
|
+
* Resolve the source-tree static model registry YAML when running from a repo checkout.
|
|
215
|
+
*
|
|
216
|
+
* Packaged Electron bundles run from `app.asar/dist`, where no workspace root
|
|
217
|
+
* exists. In that case the static source-tree fallback is unavailable and the
|
|
218
|
+
* registry fetcher chain should continue with the other configured sources.
|
|
219
|
+
* @param baseDir - Absolute directory inside the source workspace when available
|
|
220
|
+
* @returns Static model registry path, or `undefined` outside a source checkout
|
|
221
|
+
*/
|
|
222
|
+
declare function resolveStaticModelRegistryPath(baseDir: string): string | undefined;
|
|
223
|
+
//#endregion
|
|
224
|
+
//#region runtimes/node/src/http-server-utils.d.ts
|
|
225
|
+
/**
|
|
226
|
+
* Wait until an HTTP server emits `listening` or fails with an error.
|
|
227
|
+
*
|
|
228
|
+
* Fast-exits if the server is already bound. Attaches a persistent error
|
|
229
|
+
* handler after binding to prevent unhandled rejections from post-bind errors.
|
|
230
|
+
* @param server - HTTP server to observe.
|
|
231
|
+
* @param port - Configured port, used in the EADDRINUSE error message.
|
|
232
|
+
*/
|
|
233
|
+
declare function waitForServerListening(server: Server, port: number): Promise<void>;
|
|
234
|
+
/**
|
|
235
|
+
* Resolve the bound TCP port from an HTTP server that is already listening.
|
|
236
|
+
* @param server - HTTP server instance.
|
|
237
|
+
* @returns Numeric TCP port.
|
|
238
|
+
*/
|
|
239
|
+
declare function resolveListeningPort(server: Server): number;
|
|
240
|
+
//#endregion
|
|
241
|
+
//#region runtimes/node/src/optional-package.d.ts
|
|
242
|
+
/**
|
|
243
|
+
* Detect the intentional absence of an optional runtime package.
|
|
244
|
+
*
|
|
245
|
+
* Only errors proving the named package itself is missing are swallowed.
|
|
246
|
+
* Transitive dependency failures or module evaluation errors must surface so
|
|
247
|
+
* callers do not treat a broken package the same as an absent one.
|
|
248
|
+
* @param error - Dynamic import error.
|
|
249
|
+
* @param packageName - Exact package name the host attempted to import.
|
|
250
|
+
* @returns `true` when the named package is not installed.
|
|
251
|
+
*/
|
|
252
|
+
declare function isMissingOptionalRuntimePackage(error: unknown, packageName: string): boolean;
|
|
253
|
+
/**
|
|
254
|
+
* Attempt a dynamic import, returning `null` when the package is not installed.
|
|
255
|
+
*
|
|
256
|
+
* Only swallows errors caused by the package itself being absent. Transitive
|
|
257
|
+
* dependency failures and module evaluation errors are re-thrown so callers
|
|
258
|
+
* do not silently ignore broken packages.
|
|
259
|
+
* @typeParam T - Expected module shape (caller-asserted, not runtime-verified).
|
|
260
|
+
* @param specifier - Package specifier to import (e.g. `'@makaio/foo'` or `'@makaio/foo/runtime'`).
|
|
261
|
+
* @returns The imported module cast to `T`, or `null` when the package is not installed.
|
|
262
|
+
*/
|
|
263
|
+
declare function tryImport<T>(specifier: string): Promise<T | null>;
|
|
264
|
+
//#endregion
|
|
265
|
+
//#region runtimes/node/src/boot.d.ts
|
|
266
|
+
/**
|
|
267
|
+
* Platform-agnostic Makaio runtime boot core.
|
|
268
|
+
*
|
|
269
|
+
* Runs the full startup sequence (steps 1–12) given a pre-constructed
|
|
270
|
+
* transport provider and the bound address of the server it is attached to.
|
|
271
|
+
* The transport must be constructed but NOT yet connected — this function
|
|
272
|
+
* calls `transport.connect(bus, machineId)` internally once the bus and
|
|
273
|
+
* machine ID are available (step 3).
|
|
274
|
+
*
|
|
275
|
+
* This function is the shared implementation reused by both
|
|
276
|
+
* {@link bootMakaioRuntime} (Node.js) and the Bun platform wrapper in
|
|
277
|
+
* `@makaio/runtime-bun`.
|
|
278
|
+
* @param transport - Pre-constructed (not yet connected) server transport provider.
|
|
279
|
+
* @param boundPort - TCP port the server is listening on.
|
|
280
|
+
* @param boundHost - Host address the server is bound to.
|
|
281
|
+
* @param options - Platform-agnostic boot options.
|
|
282
|
+
* @returns Runtime handle with `port`, `machineId`, and `shutdown()`.
|
|
283
|
+
*/
|
|
284
|
+
declare function bootMakaioRuntimeCore(transport: ServerTransportProvider, boundPort: number, boundHost: string, options: CoreBootOptions): Promise<MakaioRuntime>;
|
|
285
|
+
/**
|
|
286
|
+
* Boot the full Makaio runtime against a pre-existing Node.js HTTP server.
|
|
287
|
+
*
|
|
288
|
+
* Thin Node.js wrapper around {@link bootMakaioRuntimeCore}. Creates a
|
|
289
|
+
* {@link BusServerTransportProvider} from the provided HTTP server, resolves
|
|
290
|
+
* the bound address via `httpServer.address()`, then delegates all startup
|
|
291
|
+
* logic to the platform-agnostic core.
|
|
292
|
+
*
|
|
293
|
+
* The caller owns the HTTP server and Hono app lifecycle. This function owns
|
|
294
|
+
* everything from step 1 (Config) through step 12 (Ready) and returns a
|
|
295
|
+
* {@link MakaioRuntime} handle that the caller uses to shut down.
|
|
296
|
+
* @param options - Boot configuration including the pre-bound HTTP server.
|
|
297
|
+
* @returns Runtime handle with `port`, `machineId`, and `shutdown()`.
|
|
298
|
+
*/
|
|
299
|
+
declare function bootMakaioRuntime(options: BootMakaioRuntimeOptions): Promise<MakaioRuntime>;
|
|
300
|
+
//#endregion
|
|
301
|
+
//#region runtimes/node/src/upstream-telemetry.d.ts
|
|
302
|
+
/**
|
|
303
|
+
* Returned by {@link attachUpstreamTelemetry} after the projected transport is connected
|
|
304
|
+
* and the bus observer is attached.
|
|
305
|
+
*/
|
|
306
|
+
interface AttachedUpstreamTelemetry {
|
|
307
|
+
/** Shutdown step that detaches the observer and disconnects the inner transport. */
|
|
308
|
+
readonly shutdown: ShutdownStep;
|
|
309
|
+
}
|
|
310
|
+
/**
|
|
311
|
+
* Attach a projected telemetry exporter to a booted runtime bus.
|
|
312
|
+
*
|
|
313
|
+
* Observed local messages are projected into sanitized `subject-telemetry.fact`
|
|
314
|
+
* events and forwarded upstream. The exporter is driven by
|
|
315
|
+
* {@link IMakaioBus.observeMessages} instead of being registered as a normal
|
|
316
|
+
* bus transport: upstream telemetry is a collector, not an application message
|
|
317
|
+
* peer, and must observe local requests that would not otherwise route through
|
|
318
|
+
* transport dispatch.
|
|
319
|
+
*
|
|
320
|
+
* The raw inner transport is never registered directly on the bus.
|
|
321
|
+
* @param bus - Runtime bus whose namespace registry is used for projection.
|
|
322
|
+
* @param machineId - Source machine identifier included in telemetry facts.
|
|
323
|
+
* @param options - Upstream telemetry boot options.
|
|
324
|
+
* @returns Shutdown hook for boot rollback/shutdown.
|
|
325
|
+
*/
|
|
326
|
+
declare function attachUpstreamTelemetry(bus: IMakaioBus, machineId: string, options: UpstreamTelemetryBootOptions): Promise<AttachedUpstreamTelemetry>;
|
|
327
|
+
//#endregion
|
|
328
|
+
//#region runtimes/node/src/upstream-telemetry-config.d.ts
|
|
329
|
+
/**
|
|
330
|
+
* Environment surface used by {@link resolveUpstreamTelemetryBootOptionsFromEnv}.
|
|
331
|
+
*/
|
|
332
|
+
interface UpstreamTelemetryEnv {
|
|
333
|
+
/** WebSocket URL for the upstream collector bus. */
|
|
334
|
+
readonly MAKAIO_UPSTREAM_URL?: string;
|
|
335
|
+
/** Optional HMAC secret for the upstream collector bus. */
|
|
336
|
+
readonly MAKAIO_UPSTREAM_SECRET?: string;
|
|
337
|
+
}
|
|
338
|
+
/**
|
|
339
|
+
* Transport factory input resolved from upstream telemetry environment.
|
|
340
|
+
*/
|
|
341
|
+
interface UpstreamTelemetryTransportConfig {
|
|
342
|
+
/** WebSocket URL for the upstream collector bus. */
|
|
343
|
+
readonly url: string;
|
|
344
|
+
/** Optional HMAC secret for upstream bus authentication. */
|
|
345
|
+
readonly secret?: string;
|
|
346
|
+
}
|
|
347
|
+
/**
|
|
348
|
+
* Options for resolving push embedded upstream telemetry boot configuration.
|
|
349
|
+
*/
|
|
350
|
+
interface ResolveUpstreamTelemetryBootOptionsFromEnvOptions {
|
|
351
|
+
/** Environment variables to read. Defaults to `process.env`. */
|
|
352
|
+
readonly env?: UpstreamTelemetryEnv;
|
|
353
|
+
/** Transport factory override for tests and alternate host transports. */
|
|
354
|
+
readonly createTransport?: (config: UpstreamTelemetryTransportConfig) => BusTransport;
|
|
355
|
+
}
|
|
356
|
+
/** Environment variable that enables push embedded upstream telemetry. */
|
|
357
|
+
declare const MAKAIO_UPSTREAM_URL_ENV = "MAKAIO_UPSTREAM_URL";
|
|
358
|
+
/** Environment variable carrying the optional HMAC secret for upstream telemetry. */
|
|
359
|
+
declare const MAKAIO_UPSTREAM_SECRET_ENV = "MAKAIO_UPSTREAM_SECRET";
|
|
360
|
+
/**
|
|
361
|
+
* Create the default upstream telemetry WebSocket transport.
|
|
362
|
+
* @param config - Resolved upstream telemetry transport configuration.
|
|
363
|
+
* @returns WebSocket client transport configured for upstream telemetry.
|
|
364
|
+
*/
|
|
365
|
+
declare function createUpstreamTelemetryTransport(config: UpstreamTelemetryTransportConfig): BusTransport;
|
|
366
|
+
/**
|
|
367
|
+
* Resolve push embedded upstream telemetry boot options from environment.
|
|
368
|
+
*
|
|
369
|
+
* `MAKAIO_UPSTREAM_URL` is the activation switch. When it is absent or blank,
|
|
370
|
+
* no upstream telemetry transport is created. `MAKAIO_UPSTREAM_SECRET` is
|
|
371
|
+
* optional, but when set it must be non-empty and requires a URL.
|
|
372
|
+
* @param options - Environment and transport factory overrides.
|
|
373
|
+
* @returns Boot options for projected upstream telemetry, or `undefined` when disabled.
|
|
374
|
+
*/
|
|
375
|
+
declare function resolveUpstreamTelemetryBootOptionsFromEnv(options?: ResolveUpstreamTelemetryBootOptionsFromEnvOptions): UpstreamTelemetryBootOptions | undefined;
|
|
376
|
+
//#endregion
|
|
377
|
+
//#region runtimes/node/src/node-runtime-options.d.ts
|
|
378
|
+
/**
|
|
379
|
+
* Node runtime discovery options.
|
|
380
|
+
*
|
|
381
|
+
* Narrows the generic boot option shape so Node entrypoints can pass the same
|
|
382
|
+
* discovery strategy to both CLI command discovery and runtime boot.
|
|
383
|
+
*/
|
|
384
|
+
interface NodeRuntimeOptions extends ConfiguredRuntimeOptions {
|
|
385
|
+
/**
|
|
386
|
+
* Extension discovery strategy selected by runtime config.
|
|
387
|
+
*
|
|
388
|
+
* Corresponds to {@link CoreBootOptions.discovery}. Node entrypoints use the
|
|
389
|
+
* same `makaio.config.*` loader path as the CLI, so runtime extension
|
|
390
|
+
* selection is controlled by explicit config, `MAKAIO_CONFIG_FILE`, or
|
|
391
|
+
* user-home defaults.
|
|
392
|
+
*/
|
|
393
|
+
readonly discovery: ExtensionDiscovery;
|
|
394
|
+
/** Host capability facts for Node.js boot. */
|
|
395
|
+
readonly hostCapabilities: readonly HostCapabilityDeclaration[];
|
|
396
|
+
}
|
|
397
|
+
/**
|
|
398
|
+
* Build runtime options for Node.js boot.
|
|
399
|
+
*
|
|
400
|
+
* Runtime extension selection is owned by `makaio.config.*`, including the
|
|
401
|
+
* no-config defaults for installed extension roots. Host capabilities stay out
|
|
402
|
+
* of runtime config and only express the narrow Node.js environment gate used
|
|
403
|
+
* by extension `requires`.
|
|
404
|
+
* @param options - Runtime config lookup options.
|
|
405
|
+
* @returns Runtime options for Node.js boot.
|
|
406
|
+
*/
|
|
407
|
+
declare function buildNodeRuntimeOptions(options: LoadMakaioConfigOptions): Promise<NodeRuntimeOptions>;
|
|
408
|
+
//#endregion
|
|
409
|
+
//#region runtimes/node/src/initialize-node-database.d.ts
|
|
410
|
+
/**
|
|
411
|
+
* Options for {@link initializeNodeDatabase}.
|
|
412
|
+
*/
|
|
413
|
+
interface InitializeNodeDatabaseOptions {
|
|
414
|
+
/** Override database file path. Defaults to MAKAIO_DATABASE_PATH env var, then `<makaioHome>/makaio.db`. */
|
|
415
|
+
dbPath?: string;
|
|
416
|
+
/**
|
|
417
|
+
* Override framework central migrations directory.
|
|
418
|
+
*
|
|
419
|
+
* Bundled hosts copy migrations next to their entrypoint and pass that
|
|
420
|
+
* runtime asset path explicitly because package-local source paths are not
|
|
421
|
+
* available in the final image.
|
|
422
|
+
*/
|
|
423
|
+
migrationsDir?: string;
|
|
424
|
+
/**
|
|
425
|
+
* Makaio home directory used to derive the default database path.
|
|
426
|
+
* Superseded by `dbPath` and `MAKAIO_DATABASE_PATH`.
|
|
427
|
+
*/
|
|
428
|
+
makaioHome: string;
|
|
429
|
+
}
|
|
430
|
+
/**
|
|
431
|
+
* Result returned by {@link initializeNodeDatabase}.
|
|
432
|
+
*/
|
|
433
|
+
interface InitializeNodeDatabaseResult {
|
|
434
|
+
databaseClient: DatabaseClient;
|
|
435
|
+
dbPath: string;
|
|
436
|
+
}
|
|
437
|
+
/**
|
|
438
|
+
* Initialize SQLite database for Node runtime persistence.
|
|
439
|
+
*
|
|
440
|
+
* Supports `MAKAIO_DATABASE_PATH` for test or custom environments.
|
|
441
|
+
* When `options.dbPath` is provided it takes precedence over the environment
|
|
442
|
+
* variable, avoiding the need for callers to mutate `process.env`.
|
|
443
|
+
* @param options - Configuration; see {@link InitializeNodeDatabaseOptions}.
|
|
444
|
+
* @returns Initialized database client and resolved database path.
|
|
445
|
+
*/
|
|
446
|
+
declare function initializeNodeDatabase(options: InitializeNodeDatabaseOptions): Promise<InitializeNodeDatabaseResult>;
|
|
447
|
+
//#endregion
|
|
448
|
+
//#region runtimes/node/src/bus-server-transport.d.ts
|
|
449
|
+
/**
|
|
450
|
+
* Configuration options for {@link BusServerTransportProvider}.
|
|
451
|
+
*/
|
|
452
|
+
interface BusServerTransportOptions {
|
|
453
|
+
/** Pre-existing HTTP server that is already listening. */
|
|
454
|
+
httpServer: Server;
|
|
455
|
+
/**
|
|
456
|
+
* Auth strategy.
|
|
457
|
+
*
|
|
458
|
+
* When `undefined` the server runs with no authentication. Pass a
|
|
459
|
+
* {@link DispatchingAuth} to support hot-swapping E2E auth after machine
|
|
460
|
+
* identity is loaded.
|
|
461
|
+
*/
|
|
462
|
+
auth?: TransportAuth$1;
|
|
463
|
+
/**
|
|
464
|
+
* Loopback transport registry name for in-process cross-client relay.
|
|
465
|
+
*
|
|
466
|
+
* Defaults to `'node'`.
|
|
467
|
+
*/
|
|
468
|
+
loopbackName?: string;
|
|
469
|
+
}
|
|
470
|
+
/**
|
|
471
|
+
* Platform-specific bus server transport provider for Node.js.
|
|
472
|
+
*/
|
|
473
|
+
declare class BusServerTransportProvider implements TransportProvider {
|
|
474
|
+
private readonly options;
|
|
475
|
+
/** Active bus server instance. Set during connect, cleared on disconnect. */
|
|
476
|
+
private busServer;
|
|
477
|
+
/** Active `ws` server instance. Set during connect, cleared on disconnect. */
|
|
478
|
+
private websocketServer;
|
|
479
|
+
/** HTTP server that currently owns the active upgrade handler. */
|
|
480
|
+
private upgradeHandlerServer;
|
|
481
|
+
/** Active `/bus` upgrade handler attached during connect. */
|
|
482
|
+
private upgradeHandler;
|
|
483
|
+
/**
|
|
484
|
+
* Whether the bus server has completed startup and is accepting connections.
|
|
485
|
+
* Guards against WebSocket upgrade requests racing with bus startup.
|
|
486
|
+
*/
|
|
487
|
+
private busReady;
|
|
488
|
+
/**
|
|
489
|
+
* Set synchronously at the top of {@link connect} to close the TOCTOU window
|
|
490
|
+
* between the guard check and the first `await`.
|
|
491
|
+
*/
|
|
492
|
+
private connecting;
|
|
493
|
+
/**
|
|
494
|
+
* @param options - Transport configuration. `httpServer` must already be listening.
|
|
495
|
+
*/
|
|
496
|
+
constructor(options: BusServerTransportOptions);
|
|
497
|
+
/**
|
|
498
|
+
* The {@link DispatchingAuth} instance if the caller passed one.
|
|
499
|
+
*
|
|
500
|
+
* Exposed so composition roots that need to hot-swap E2E auth after machine
|
|
501
|
+
* identity becomes available can call `dispatchingAuth.setE2EAuth(e2eAuth)`.
|
|
502
|
+
* @returns The {@link DispatchingAuth} instance, or `undefined` when auth was
|
|
503
|
+
* not provided or is not a `DispatchingAuth`.
|
|
504
|
+
*/
|
|
505
|
+
get dispatchingAuth(): DispatchingAuth | undefined;
|
|
506
|
+
/**
|
|
507
|
+
* Attach the `/bus` upgrade handler to the HTTP server and start the bus server.
|
|
508
|
+
* @param bus - Bus instance to attach the transport to.
|
|
509
|
+
* @param _machineId - Machine identifier (unused; callers provide auth externally).
|
|
510
|
+
*/
|
|
511
|
+
connect(bus: IMakaioBus, _machineId: string): Promise<void>;
|
|
512
|
+
/**
|
|
513
|
+
* Stop the bus server and detach the upgrade wiring.
|
|
514
|
+
*
|
|
515
|
+
* The HTTP server and Hono app are owned by the composition root and are not
|
|
516
|
+
* closed here.
|
|
517
|
+
*/
|
|
518
|
+
disconnect(): Promise<void>;
|
|
519
|
+
/**
|
|
520
|
+
* Stop the bus server and mark the transport as not ready.
|
|
521
|
+
* @param reason - Context string used in error log messages.
|
|
522
|
+
*/
|
|
523
|
+
private stopBusServer;
|
|
524
|
+
/**
|
|
525
|
+
* Detach the active upgrade handler from the HTTP server.
|
|
526
|
+
*/
|
|
527
|
+
private detachUpgradeHandler;
|
|
528
|
+
/**
|
|
529
|
+
* Close the `ws` server.
|
|
530
|
+
*
|
|
531
|
+
* "The server is not running" is silently ignored: the HTTP server closes the
|
|
532
|
+
* underlying socket when it shuts down first, so `wss.close()` finds it
|
|
533
|
+
* already gone. This is not an error — it is the expected teardown order in
|
|
534
|
+
* tests and in production when the HTTP server is closed before disconnect().
|
|
535
|
+
* @param reason - Context string used in error log messages.
|
|
536
|
+
*/
|
|
537
|
+
private stopWebSocketServer;
|
|
538
|
+
}
|
|
539
|
+
//#endregion
|
|
540
|
+
//#region runtimes/node/src/credential-provider.d.ts
|
|
541
|
+
/**
|
|
542
|
+
* Credential provider interface for resolving credential references.
|
|
543
|
+
*
|
|
544
|
+
* Implementations are platform-specific (e.g. Node.js keychain, stored refs).
|
|
545
|
+
*/
|
|
546
|
+
interface CredentialProvider {
|
|
547
|
+
/**
|
|
548
|
+
* Resolve a credential reference to its runtime value.
|
|
549
|
+
* @param ref - Credential reference string
|
|
550
|
+
* @returns Resolved value, or null if unavailable
|
|
551
|
+
*/
|
|
552
|
+
resolve(ref: CredentialRef): Promise<string | null>;
|
|
553
|
+
}
|
|
554
|
+
/**
|
|
555
|
+
* Node.js credential provider.
|
|
556
|
+
*
|
|
557
|
+
* Resolves env:, file:, and keychain: credential references.
|
|
558
|
+
*/
|
|
559
|
+
declare class NodeCredentialProvider implements CredentialProvider {
|
|
560
|
+
/**
|
|
561
|
+
* Resolve a credential reference to its plaintext value.
|
|
562
|
+
* @param ref - Credential reference (`env:`, `file:`, or `keychain:`)
|
|
563
|
+
* @returns Resolved credential value, or null when unavailable
|
|
564
|
+
*/
|
|
565
|
+
resolve(ref: CredentialRef): Promise<string | null>;
|
|
566
|
+
private resolveKeychain;
|
|
567
|
+
}
|
|
568
|
+
/**
|
|
569
|
+
* Credential provider that resolves stored refs via credential service.
|
|
570
|
+
*
|
|
571
|
+
* Falls back to NodeCredentialProvider for env/file/keychain refs.
|
|
572
|
+
* Uses a lazy-opened DirectChannel for the channel-only `credential.get` subject.
|
|
573
|
+
*/
|
|
574
|
+
declare class StoredCredentialProvider implements CredentialProvider {
|
|
575
|
+
private readonly bus;
|
|
576
|
+
private readonly fallbackProvider;
|
|
577
|
+
/** Lazily-opened channel to the credentials endpoint. */
|
|
578
|
+
private channelPromise?;
|
|
579
|
+
/**
|
|
580
|
+
* Create a new stored credential provider.
|
|
581
|
+
* @param bus - Bus instance for credential retrieval
|
|
582
|
+
*/
|
|
583
|
+
constructor(bus: IMakaioBus);
|
|
584
|
+
/**
|
|
585
|
+
* Resolve a credential reference, including stored refs.
|
|
586
|
+
*
|
|
587
|
+
* Handles the `stored:providerConfig:<configId>:<key>` format via
|
|
588
|
+
* `CredentialSubjects.get` over an encrypted DirectChannel. Falls back to
|
|
589
|
+
* NodeCredentialProvider for env:, file:, and keychain: refs.
|
|
590
|
+
* @param ref - Credential reference to resolve
|
|
591
|
+
* @returns Resolved credential value, or null when unavailable
|
|
592
|
+
*/
|
|
593
|
+
resolve(ref: CredentialRef): Promise<string | null>;
|
|
594
|
+
/**
|
|
595
|
+
* Lazily open (and cache) the encrypted channel to the credentials endpoint.
|
|
596
|
+
*
|
|
597
|
+
* The promise is cleared on `ChannelClosedError` (post-open channel closure)
|
|
598
|
+
* and also on open failures so the next call always retries rather than
|
|
599
|
+
* re-using a permanently-rejected or permanently-closed promise.
|
|
600
|
+
* @returns The open DirectChannel
|
|
601
|
+
*/
|
|
602
|
+
private getChannel;
|
|
603
|
+
/**
|
|
604
|
+
* Open a fresh encrypted channel to the credentials endpoint.
|
|
605
|
+
* @returns Newly opened DirectChannel
|
|
606
|
+
*/
|
|
607
|
+
private openCredentialChannel;
|
|
608
|
+
}
|
|
609
|
+
//#endregion
|
|
610
|
+
//#region runtimes/node/src/read-framework-version.d.ts
|
|
611
|
+
/**
|
|
612
|
+
* Read the framework version from `@makaio/runtime-node`'s `package.json`.
|
|
613
|
+
*
|
|
614
|
+
* Resolves `package.json` relative to the compiled source using
|
|
615
|
+
* `import.meta.url`, which is always available in ESM. Used as a fallback
|
|
616
|
+
* when the caller does not pass an explicit `frameworkVersion`.
|
|
617
|
+
* @returns The `version` field from `package.json`.
|
|
618
|
+
* @throws If `package.json` cannot be read or has no `version` field.
|
|
619
|
+
*/
|
|
620
|
+
declare function readFrameworkVersion(): Promise<string>;
|
|
621
|
+
//#endregion
|
|
622
|
+
//#region runtimes/node/src/model-registry/file-registry-cache.d.ts
|
|
623
|
+
/**
|
|
624
|
+
* Options for file-backed registry cache persistence.
|
|
625
|
+
*/
|
|
626
|
+
interface FileRegistryCacheOptions {
|
|
627
|
+
/**
|
|
628
|
+
* Persist an ISO timestamp next to the registry payload.
|
|
629
|
+
*
|
|
630
|
+
* The read contract still returns only the registry; the timestamp is a
|
|
631
|
+
* persistence seam for future TTL policy.
|
|
632
|
+
*/
|
|
633
|
+
readonly trackFetchedAt?: boolean;
|
|
634
|
+
}
|
|
635
|
+
/**
|
|
636
|
+
* File-based model registry cache for Node.js.
|
|
637
|
+
*
|
|
638
|
+
* Persists the model registry as JSON at `<cachePath>`.
|
|
639
|
+
* Silently returns null on read errors (cache miss) and logs warnings on
|
|
640
|
+
* write errors (non-fatal, in-memory data still serves requests).
|
|
641
|
+
*/
|
|
642
|
+
declare class FileRegistryCache implements IModelRegistryCache {
|
|
643
|
+
private readonly cachePath;
|
|
644
|
+
private readonly trackFetchedAt;
|
|
645
|
+
/**
|
|
646
|
+
* Creates a new FileRegistryCache.
|
|
647
|
+
* @param cachePath - Absolute path to the cache file (e.g. `~/.makaio/cache/model-registry.json`)
|
|
648
|
+
* @param options - Cache persistence options.
|
|
649
|
+
*/
|
|
650
|
+
constructor(cachePath: string, options?: FileRegistryCacheOptions);
|
|
651
|
+
/**
|
|
652
|
+
* Read cached registry from disk.
|
|
653
|
+
* @returns Parsed registry or null if file missing or corrupt
|
|
654
|
+
*/
|
|
655
|
+
get(): Promise<ModelRegistry | null>;
|
|
656
|
+
/**
|
|
657
|
+
* Write registry to disk cache.
|
|
658
|
+
* Creates parent directories if they don't exist.
|
|
659
|
+
* @param registry - Registry data to persist
|
|
660
|
+
*/
|
|
661
|
+
set(registry: ModelRegistry): Promise<void>;
|
|
662
|
+
}
|
|
663
|
+
//#endregion
|
|
664
|
+
//#region runtimes/node/src/extension-browser-entry-paths.d.ts
|
|
665
|
+
/**
|
|
666
|
+
* Build the Rollup input name for a descriptor browser entry.
|
|
667
|
+
*
|
|
668
|
+
* Vite appends `.js` through the `[name].js` output pattern, so the input name
|
|
669
|
+
* intentionally omits the descriptor source extension.
|
|
670
|
+
* @param extensionName - Descriptor/package name of the extension.
|
|
671
|
+
* @param browserEntrypoint - Descriptor browser entrypoint path.
|
|
672
|
+
* @returns Stable Rollup input name for the browser bundle.
|
|
673
|
+
*/
|
|
674
|
+
declare function buildExtensionBrowserRollupInputName(extensionName: string, browserEntrypoint: string): string;
|
|
675
|
+
/**
|
|
676
|
+
* Build the runtime import URL for a descriptor browser entry.
|
|
677
|
+
*
|
|
678
|
+
* Runtime URLs point at the JavaScript asset emitted by Vite, even when the
|
|
679
|
+
* descriptor points at a TypeScript source entry.
|
|
680
|
+
* @param extensionName - Descriptor/package name of the extension.
|
|
681
|
+
* @param browserEntrypoint - Descriptor browser entrypoint path.
|
|
682
|
+
* @returns Public browser entrypoint URL.
|
|
683
|
+
*/
|
|
684
|
+
declare function buildExtensionBrowserRuntimeEntrypoint(extensionName: string, browserEntrypoint: string): string;
|
|
685
|
+
//#endregion
|
|
686
|
+
//#region runtimes/node/src/bridge-extension-browser-entries.d.ts
|
|
687
|
+
/**
|
|
688
|
+
* Augment extension packages with browser entry and HTTP serving fields.
|
|
689
|
+
*
|
|
690
|
+
* For each loaded package whose descriptor declares `entrypoints.browser`,
|
|
691
|
+
* adds `browser` (URL entrypoint) and `http` (static file serving) fields.
|
|
692
|
+
* Skips packages that already declare either field — the server entry author
|
|
693
|
+
* is assumed to handle their own serving.
|
|
694
|
+
*
|
|
695
|
+
* The URL convention is `/extensions/<name>/browser/<entry-stem>.js`.
|
|
696
|
+
* Static files are served from the directory containing the browser bundle.
|
|
697
|
+
* @param discovered - The discovered extensions (for descriptor access).
|
|
698
|
+
* @param packages - Loaded {@link KernelMakaioExtension} array from `loadExtensions`.
|
|
699
|
+
* @param options - Optional injection overrides for testability.
|
|
700
|
+
* @returns New array with augmented packages. Input array is not mutated.
|
|
701
|
+
*/
|
|
702
|
+
declare function bridgeExtensionBrowserEntries(discovered: ReadonlyArray<DiscoveredExtension>, packages: ReadonlyArray<KernelMakaioExtension>, options?: BridgeBrowserOptions): KernelMakaioExtension[];
|
|
703
|
+
//#endregion
|
|
704
|
+
//#region runtimes/node/src/find-workspace-root.d.ts
|
|
705
|
+
/**
|
|
706
|
+
* Error raised when no workspace root exists above the supplied start
|
|
707
|
+
* directory.
|
|
708
|
+
*/
|
|
709
|
+
declare class WorkspaceRootNotFoundError extends Error {
|
|
710
|
+
/**
|
|
711
|
+
* Creates a workspace-root lookup failure.
|
|
712
|
+
* @param startDir - Directory where the workspace-root search started.
|
|
713
|
+
*/
|
|
714
|
+
constructor(startDir: string);
|
|
715
|
+
}
|
|
716
|
+
/** Parsed workspace-root metadata from the nearest workspace package.json. */
|
|
717
|
+
interface WorkspaceRootInfo {
|
|
718
|
+
/** Absolute workspace root directory. */
|
|
719
|
+
readonly root: string;
|
|
720
|
+
/** Absolute path to the root package.json that declared workspaces. */
|
|
721
|
+
readonly packageJsonPath: string;
|
|
722
|
+
/** Workspace glob entries declared by the root package.json. */
|
|
723
|
+
readonly workspaces: readonly string[];
|
|
724
|
+
}
|
|
725
|
+
/**
|
|
726
|
+
* Walk up from `startDir` to find the nearest directory containing a
|
|
727
|
+
* `package.json` with a `workspaces` field (the workspace root).
|
|
728
|
+
*
|
|
729
|
+
* Use {@link findWorkspaceRootInfo} when the caller also needs the parsed
|
|
730
|
+
* workspace globs; that avoids re-reading the same root package.json.
|
|
731
|
+
* @param startDir - Directory to start searching from.
|
|
732
|
+
* @returns Absolute path to the workspace root.
|
|
733
|
+
* @throws If no workspace root is found before reaching the filesystem root.
|
|
734
|
+
*/
|
|
735
|
+
declare function findWorkspaceRoot(startDir: string): string;
|
|
736
|
+
/**
|
|
737
|
+
* Walk up from `startDir` and return the nearest workspace root plus its
|
|
738
|
+
* parsed workspace globs.
|
|
739
|
+
* @param startDir - Directory to start searching from.
|
|
740
|
+
* @returns Workspace root metadata.
|
|
741
|
+
* @throws If no workspace root is found before reaching the filesystem root.
|
|
742
|
+
*/
|
|
743
|
+
declare function findWorkspaceRootInfo(startDir: string): WorkspaceRootInfo;
|
|
744
|
+
//#endregion
|
|
745
|
+
export { type ActivateAdapterRuntimeIdentityInput, type ActivatedAdapterRuntimeIdentity, type AttachedUpstreamTelemetry, type BootCoordinatorSetupContext, type BootMakaioRuntimeOptions, type BridgeBrowserOptions, type BusServerTransportOptions, BusServerTransportProvider, type ConfiguredRuntimeOptions, type CoreBootOptions, type CredentialProvider, type DescriptorSourcePackageGroup, type DiscoveredExtension, ExplicitDescriptorDiscovery, type ExtensionDiscovery, FileConfigStorage, FileRegistryCache, FilesystemDescriptorDiscovery, type FilesystemDescriptorDiscoveryOptions, type FrameworkModuleResolver, type HonoRouteGraph, type HonoRouteGraphOptions, type HttpContributionPhase, type HttpRouteContribution, type HttpRouteGraphBuilder, type IWorkflowRunner, InProcessWorkflowRunner, type InProcessWorkflowRunnerOptions, type InitializeNodeDatabaseOptions, type InitializeNodeDatabaseResult, type LoadExtensionsOptions, type LoadMakaioConfigOptions, type LoadedMakaioConfig, MAKAIO_CONFIG_FILE_ENV, MAKAIO_HOME_ENV, MAKAIO_UPSTREAM_SECRET_ENV, MAKAIO_UPSTREAM_URL_ENV, type MachineKeyStatus, type MachineKeyValidation, type MakaioConfig, type MakaioRuntime, NodeCredentialProvider, NodeFrameworkModuleResolver, type NodeRuntimeOptions, NoopFrameworkModuleResolver, type ParseMakaioConfigOptions, type ParsedMakaioConfig, type PersistedMachineIdentity, type PrepareAdapterRuntimeInput, type PreparedAdapterRuntime, type ResolveUpstreamTelemetryBootOptionsFromEnvOptions, RuntimeSubjects, type ServerTransportProvider, StoredCredentialProvider, ThinWorkflowPiscinaRunner, type ThinWorkflowPiscinaRunnerOptions, type TransportReadyInfo, type UpstreamTelemetryBootOptions, type UpstreamTelemetryEnv, type UpstreamTelemetryTransportConfig, type WorkflowRunResult, type WorkflowRunnerBootOptions, type WorkflowRunnerConfig, type WorkflowWorkerEntryMode, type WorkflowWorkerEntryResolverOptions, type WorkspaceRootInfo, WorkspaceRootNotFoundError, activateAdapterRuntimeIdentity, attachUpstreamTelemetry, bootMakaioRuntime, bootMakaioRuntimeCore, bridgeExtensionBrowserEntries, buildConfiguredRuntimeOptions, buildExtensionBrowserRollupInputName, buildExtensionBrowserRuntimeEntrypoint, buildNodeRuntimeOptions, createHonoRouteGraph, createHttpRouteGraphBuilder, createMakaioConfigDiscovery, createUpstreamTelemetryTransport, defineMakaioConfig, entrypointStem, findWorkspaceRoot, findWorkspaceRootInfo, initializeNodeDatabase, isCliContributionLike, isMakaioExtensionLike, isMissingOptionalRuntimePackage, isWithinDirectory, loadExtensions, loadMakaioConfig, loadOrCreateMachineIdentity, machineKeysExist, normalizeNodeHostCapabilities, parseMakaioConfig, prepareAdapterRuntime, readFrameworkVersion, registerAdapterNameResolver, resolveConventionEntrypoint, resolveFrameworkSpecifier, resolveListeningPort, resolveMakaioConfigPath, resolveMakaioHome, resolveStaticModelRegistryPath, resolveUpstreamTelemetryBootOptionsFromEnv, resolveWorkflowWorkerEntry, runMigrations, selectFrameworkCorePackages, shouldIncludeExtension, tryImport, validateMachineKeys, waitForServerListening };
|