@makaio/framework 1.0.0-dev-1781022866275 → 1.0.0-dev-1781023871421
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 +5 -0
- package/dist/account-identity-DT5NOtFi.mjs +1 -0
- package/dist/adapter-C1eI-fGV.mjs +1 -0
- package/dist/adapters/acp-client/index.d.mts +6208 -0
- package/dist/adapters/acp-client/index.mjs +3 -0
- package/dist/adapters/config/index.d.mts +429 -0
- package/dist/adapters/config/index.mjs +1 -0
- package/dist/adapters/index.d.mts +4202 -0
- package/dist/adapters/index.mjs +18 -0
- package/dist/adapters/node.d.mts +263 -0
- package/dist/adapters/node.mjs +4 -0
- package/dist/adapters/stream-session/index.d.mts +1414 -0
- package/dist/adapters/stream-session/index.mjs +1 -0
- package/dist/adapters/stream-session/testing/index.d.mts +29 -0
- package/dist/adapters/stream-session/testing/index.mjs +1 -0
- package/dist/artifact-B3npq1cy.mjs +1 -0
- package/dist/base-orchestrator-wyumsn3b.d.mts +772 -0
- package/dist/bus/index.d.mts +3994 -0
- package/dist/bus/index.mjs +1 -0
- package/dist/bus-Caz3Jpbc.mjs +1 -0
- package/dist/bus-Hb-LGzgb.mjs +2 -0
- package/dist/capability-service-CJbmhfv9.mjs +1 -0
- package/dist/chunk-DTipWd-i.mjs +1 -0
- package/dist/chunk-cpUYaJdV.mjs +1 -0
- package/dist/cleanEnvForAdapter-KkYzQa1f.mjs +1 -0
- package/dist/client-bx74gm4R.mjs +1 -0
- package/dist/clients/index.d.mts +2639 -0
- package/dist/clients/index.mjs +2 -0
- package/dist/clients-namespace-GmSJpBUV.d.mts +332 -0
- package/dist/config-namespace-CPY9YsR8.d.mts +638 -0
- package/dist/config-namespace-ncYg2ct_.mjs +1 -0
- package/dist/contracts/adapter/index.d.mts +3 -0
- package/dist/contracts/adapter/index.mjs +1 -0
- package/dist/contracts/adapter/schemas/session-lineage.d.mts +2 -0
- package/dist/contracts/adapter/schemas/session-lineage.mjs +1 -0
- package/dist/contracts/artifact/index.d.mts +2 -0
- package/dist/contracts/artifact/index.mjs +1 -0
- package/dist/contracts/client/index.d.mts +3 -0
- package/dist/contracts/client/index.mjs +1 -0
- package/dist/contracts/common/index.d.mts +2 -0
- package/dist/contracts/common/index.mjs +1 -0
- package/dist/contracts/config/index.d.mts +455 -0
- package/dist/contracts/config/index.mjs +1 -0
- package/dist/contracts/extension/index.d.mts +4 -0
- package/dist/contracts/extension/index.mjs +1 -0
- package/dist/contracts/facet/index.d.mts +2 -0
- package/dist/contracts/facet/index.mjs +1 -0
- package/dist/contracts/harness/index.d.mts +2 -0
- package/dist/contracts/harness/index.mjs +1 -0
- package/dist/contracts/host/index.d.mts +2 -0
- package/dist/contracts/host/index.mjs +1 -0
- package/dist/contracts/index.d.mts +23046 -0
- package/dist/contracts/index.mjs +1 -0
- package/dist/contracts/materialization/index.d.mts +4 -0
- package/dist/contracts/materialization/index.mjs +1 -0
- package/dist/contracts/model-registry/index.d.mts +2 -0
- package/dist/contracts/model-registry/index.mjs +1 -0
- package/dist/contracts/native-session-supervisor/index.d.mts +2 -0
- package/dist/contracts/native-session-supervisor/index.mjs +1 -0
- package/dist/contracts/platform/index.d.mts +2 -0
- package/dist/contracts/platform/index.mjs +1 -0
- package/dist/contracts/provider/index.d.mts +3 -0
- package/dist/contracts/provider/index.mjs +1 -0
- package/dist/contracts/session/index.d.mts +3 -0
- package/dist/contracts/session/index.mjs +1 -0
- package/dist/contracts/shared/index.d.mts +2 -0
- package/dist/contracts/shared/index.mjs +1 -0
- package/dist/contracts/skill/index.d.mts +2 -0
- package/dist/contracts/skill/index.mjs +1 -0
- package/dist/contracts/telemetry/index.d.mts +2 -0
- package/dist/contracts/telemetry/index.mjs +1 -0
- package/dist/contracts/timeout/index.d.mts +2 -0
- package/dist/contracts/timeout/index.mjs +1 -0
- package/dist/contracts/toast/index.d.mts +198 -0
- package/dist/contracts/toast/index.mjs +1 -0
- package/dist/contracts/variant/index.d.mts +2 -0
- package/dist/contracts/variant/index.mjs +1 -0
- package/dist/core/index.d.mts +1263 -0
- package/dist/core/index.mjs +1 -0
- package/dist/credential-ref-YWQQENEo.mjs +1 -0
- package/dist/cursor-storage-CtVJ3JzB.mjs +1 -0
- package/dist/definition-BLCdXGzh.d.mts +383 -0
- package/dist/definition-CrgHIpTK.d.mts +60 -0
- package/dist/definition-DZMXOnjX.mjs +1 -0
- package/dist/definition-pkJ6szUl.d.mts +158 -0
- package/dist/drizzle-Eq8W1EbD.mjs +1 -0
- package/dist/event-Ca2yUf5i.mjs +1 -0
- package/dist/execution-target-CRPTfZlc.mjs +1 -0
- package/dist/extension-C-4BHMRI.mjs +1 -0
- package/dist/extension-CpIUgBKI.mjs +1 -0
- package/dist/extension-namespace-cMh_mMiL.mjs +1 -0
- package/dist/facet-BuwhrThl.mjs +1 -0
- package/dist/filesystem-service-B8rhBRgB.mjs +1 -0
- package/dist/filesystem-service-p_iJVHd4.d.mts +66 -0
- package/dist/git/index.d.mts +210 -0
- package/dist/git/index.mjs +18 -0
- package/dist/globby-rtWVaFHv.mjs +41 -0
- package/dist/handlers-CkTsQLra.mjs +41 -0
- package/dist/harness-BRCMcvQN.mjs +1 -0
- package/dist/hooks/index.d.mts +423 -0
- package/dist/hooks/index.mjs +1 -0
- package/dist/host-Br9VuOyr.mjs +1 -0
- package/dist/identity-Cz2IeEtm.mjs +1 -0
- package/dist/index-472sOmsW.d.mts +218 -0
- package/dist/index-8SZkg7s6.d.mts +353 -0
- package/dist/index-B3PK4FIn.d.mts +5116 -0
- package/dist/index-B80L4YqA.d.mts +180 -0
- package/dist/index-BFg9BUpx.d.mts +355 -0
- package/dist/index-BGfWS6GE.d.mts +483 -0
- package/dist/index-BVgfS-AJ.d.mts +109 -0
- package/dist/index-B_zQC98V.d.mts +995 -0
- package/dist/index-Bh_Ne7LF.d.mts +1008 -0
- package/dist/index-Bvb2mMH6.d.mts +1730 -0
- package/dist/index-CCGVh9BF2.d.mts +749 -0
- package/dist/index-CGmcS0Ma.d.mts +412 -0
- package/dist/index-CHQ1SqT0.d.mts +117 -0
- package/dist/index-CLpjm52M.d.mts +183 -0
- package/dist/index-Caig6TeF.d.mts +6746 -0
- package/dist/index-CelJCBjk.d.mts +2992 -0
- package/dist/index-ChunCFu4.d.mts +11 -0
- package/dist/index-Cm0dUkWL.d.mts +4651 -0
- package/dist/index-CokQYGVP.d.mts +184 -0
- package/dist/index-Cs0kZXIz2.d.mts +37 -0
- package/dist/index-D5d5HeWI2.d.mts +259 -0
- package/dist/index-D90OmGmV.d.mts +389 -0
- package/dist/index-D9MwJ2Q8.d.mts +67 -0
- package/dist/index-DANINzMu.d.mts +40 -0
- package/dist/index-DBw-89vC2.d.mts +3640 -0
- package/dist/index-DGBu6bHi2.d.mts +438 -0
- package/dist/index-DKC62dY5.d.mts +146 -0
- package/dist/index-DKia0MX1.d.mts +43 -0
- package/dist/index-DMKnON5s.d.mts +28 -0
- package/dist/index-DUaw0Dw8.d.mts +14747 -0
- package/dist/index-De3kPhlN.d.mts +72 -0
- package/dist/index-L4GjJDKb.d.mts +822 -0
- package/dist/index-U-A8eyGT.d.mts +1490 -0
- package/dist/index-eemAKwsB.d.mts +362 -0
- package/dist/index-mNec7V-9.d.mts +1075 -0
- package/dist/index-soFznFCy2.d.mts +89 -0
- package/dist/index-vtXJuwrz.d.mts +40 -0
- package/dist/index-x_lVDp_J.d.mts +134 -0
- package/dist/json-value-CmhSGMLv.mjs +1 -0
- package/dist/kernel/cli/index.d.mts +143 -0
- package/dist/kernel/cli/index.mjs +1 -0
- package/dist/kernel/cli/schemas.d.mts +64 -0
- package/dist/kernel/cli/schemas.mjs +1 -0
- package/dist/kernel/extension/index.d.mts +2 -0
- package/dist/kernel/extension/index.mjs +1 -0
- package/dist/kernel/index.d.mts +296 -0
- package/dist/kernel/index.mjs +1 -0
- package/dist/kernel/namespace/index.d.mts +2 -0
- package/dist/kernel/namespace/index.mjs +1 -0
- package/dist/kernel/observability/index.d.mts +2 -0
- package/dist/kernel/observability/index.mjs +1 -0
- package/dist/kernel/providers/index.d.mts +2 -0
- package/dist/kernel/providers/index.mjs +1 -0
- package/dist/kernel/window/index.d.mts +2 -0
- package/dist/kernel/window/index.mjs +1 -0
- package/dist/materialization-CuUBu4XI.mjs +1 -0
- package/dist/model-registry-CfXytvzx.mjs +1 -0
- package/dist/model-registry-Scn_MC2d.mjs +1 -0
- package/dist/namespace-5QQqbF-B.d.mts +3133 -0
- package/dist/namespace-BM7Djng9.d.mts +189 -0
- package/dist/namespace-BoD94mrN.mjs +1 -0
- package/dist/namespace-BwzZJqTV.mjs +1 -0
- package/dist/namespace-CFLAmQfh.mjs +1 -0
- package/dist/namespace-CTm3nEvh.d.mts +51 -0
- package/dist/namespace-CaaNnKcR.d.mts +921 -0
- package/dist/namespace-CaoZ3S78.d.mts +43 -0
- package/dist/namespace-CxhsoFUP.d.mts +607 -0
- package/dist/namespace-DD8Oiqo7.d.mts +580 -0
- package/dist/namespace-DLovh2Ws.d.mts +1313 -0
- package/dist/namespace-DgqkaOVu.d.mts +768 -0
- package/dist/namespace-DkRgbZYn.mjs +1 -0
- package/dist/namespace-Dr8K0MCp.d.mts +2047 -0
- package/dist/namespace-DuXK5AYN.mjs +1 -0
- package/dist/namespace-EQniz-Aw.d.mts +142 -0
- package/dist/namespace-IV1QK__V.d.mts +159 -0
- package/dist/namespace-LViZ-EQk.mjs +1 -0
- package/dist/namespace-TyiTsLFv.d.mts +3020 -0
- package/dist/namespace-Yna5-Pws.mjs +1 -0
- package/dist/namespace-xcmbQlxh.mjs +1 -0
- package/dist/native-session-supervisor-B1TnaPUF.mjs +1 -0
- package/dist/node/bus-server/index.d.mts +178 -0
- package/dist/node/bus-server/index.mjs +1 -0
- package/dist/node/bus-server/server-lifecycle.d.mts +2 -0
- package/dist/node/bus-server/server-lifecycle.mjs +1 -0
- package/dist/node/machine-identity/index.d.mts +85 -0
- package/dist/node/machine-identity/index.mjs +3 -0
- package/dist/node/transports/index.d.mts +1945 -0
- package/dist/node/transports/index.mjs +2 -0
- package/dist/orchestrator-shared-CIDiFJMD.mjs +1 -0
- package/dist/orchestrator-shared-Dfa7FMyw.d.mts +249 -0
- package/dist/package-DKVlsMP3.mjs +1 -0
- package/dist/platform-DZ7z-wXD.mjs +1 -0
- package/dist/profile-6ynCD5k3.mjs +1 -0
- package/dist/provider-context-CK6B4X_8.mjs +1 -0
- package/dist/providers/index.d.mts +135 -0
- package/dist/providers/index.mjs +1 -0
- package/dist/providers-namespace-DSEpli4A.d.mts +583 -0
- package/dist/providers-u8i15co9.mjs +1 -0
- package/dist/schema-CoyE6mPt.mjs +1 -0
- package/dist/schema-M5YTvSAG.d.mts +949 -0
- package/dist/schema-e0wU_lcV.mjs +1 -0
- package/dist/schema-introspection-Dn1jWQs1.mjs +1 -0
- package/dist/schemas-Bd0OjRQf.d.mts +46 -0
- package/dist/schemas-C46QfKzv.d.mts +459 -0
- package/dist/schemas-CDBSjg7o.d.mts +237 -0
- package/dist/schemas-CR1Rripy.mjs +1 -0
- package/dist/schemas-CVvwIfG4.mjs +1 -0
- package/dist/schemas-CaLhkkLn.mjs +1 -0
- package/dist/schemas-ClOOT1W6.d.mts +174 -0
- package/dist/schemas-DATniTHb.d.mts +182 -0
- package/dist/schemas-DE-GNmSD.mjs +1 -0
- package/dist/schemas-DVF1A4DF.d.mts +160 -0
- package/dist/schemas-DaRSfYLf.d.mts +73 -0
- package/dist/schemas-DiYVzG6e.d.mts +315 -0
- package/dist/schemas-hSrzflwZ.mjs +1 -0
- package/dist/schemas-j7ivZ2HI.d.mts +944 -0
- package/dist/schemas-jFe1AuI-.mjs +1 -0
- package/dist/schemas-wg_6PAdV.d.mts +153 -0
- package/dist/scoped-bus-04pwo1uM.mjs +1 -0
- package/dist/server-lifecycle-FXTPW39-.mjs +1 -0
- package/dist/server-lifecycle-YoSGFGnU.d.mts +160 -0
- package/dist/service-base/index.d.mts +98 -0
- package/dist/service-base/index.mjs +1 -0
- package/dist/services/adapter-runtime/index.d.mts +4 -0
- package/dist/services/adapter-runtime/index.mjs +1 -0
- package/dist/services/adapter-runtime/namespace.d.mts +2 -0
- package/dist/services/adapter-runtime/namespace.mjs +1 -0
- package/dist/services/adapter-runtime/schemas.d.mts +2 -0
- package/dist/services/adapter-runtime/schemas.mjs +1 -0
- package/dist/services/adapter-subsystem/index.d.mts +3 -0
- package/dist/services/adapter-subsystem/index.mjs +1 -0
- package/dist/services/adapter-subsystem/namespace.d.mts +2 -0
- package/dist/services/adapter-subsystem/namespace.mjs +1 -0
- package/dist/services/agent-runtime/index.d.mts +3 -0
- package/dist/services/agent-runtime/index.mjs +1 -0
- package/dist/services/agent-runtime/namespace.d.mts +2 -0
- package/dist/services/agent-runtime/namespace.mjs +1 -0
- package/dist/services/agent-runtime/schemas.d.mts +2 -0
- package/dist/services/agent-runtime/schemas.mjs +1 -0
- package/dist/services/capability/index.d.mts +2 -0
- package/dist/services/capability/index.mjs +1 -0
- package/dist/services/cli-detection/namespace.d.mts +56 -0
- package/dist/services/cli-detection/namespace.mjs +1 -0
- package/dist/services/codebase/index.d.mts +3 -0
- package/dist/services/codebase/index.mjs +1 -0
- package/dist/services/codebase/namespace.d.mts +2 -0
- package/dist/services/codebase/namespace.mjs +1 -0
- package/dist/services/codebase/schemas.d.mts +2 -0
- package/dist/services/codebase/schemas.mjs +1 -0
- package/dist/services/compression/index.d.mts +3 -0
- package/dist/services/compression/index.mjs +1 -0
- package/dist/services/compression/namespace.d.mts +2 -0
- package/dist/services/compression/namespace.mjs +1 -0
- package/dist/services/compression/schemas.d.mts +2 -0
- package/dist/services/compression/schemas.mjs +1 -0
- package/dist/services/context-rules/index.d.mts +412 -0
- package/dist/services/context-rules/index.mjs +1 -0
- package/dist/services/credential-change/index.d.mts +17 -0
- package/dist/services/credential-change/index.mjs +1 -0
- package/dist/services/definition/index.d.mts +2 -0
- package/dist/services/definition/index.mjs +1 -0
- package/dist/services/definition/namespace.d.mts +71 -0
- package/dist/services/definition/namespace.mjs +1 -0
- package/dist/services/definition/schemas.d.mts +38 -0
- package/dist/services/definition/schemas.mjs +1 -0
- package/dist/services/dialog/namespace.d.mts +105 -0
- package/dist/services/dialog/namespace.mjs +1 -0
- package/dist/services/dialog/schemas.d.mts +109 -0
- package/dist/services/dialog/schemas.mjs +1 -0
- package/dist/services/execution-target/index.d.mts +4 -0
- package/dist/services/execution-target/index.mjs +1 -0
- package/dist/services/execution-target/namespace.d.mts +2 -0
- package/dist/services/execution-target/namespace.mjs +1 -0
- package/dist/services/execution-target/schemas.d.mts +2 -0
- package/dist/services/execution-target/schemas.mjs +1 -0
- package/dist/services/filesystem/index.d.mts +3 -0
- package/dist/services/filesystem/index.mjs +1 -0
- package/dist/services/filesystem/namespace.d.mts +432 -0
- package/dist/services/filesystem/namespace.mjs +1 -0
- package/dist/services/filesystem/schemas.d.mts +240 -0
- package/dist/services/filesystem/schemas.mjs +1 -0
- package/dist/services/git/namespace.d.mts +1163 -0
- package/dist/services/git/namespace.mjs +1 -0
- package/dist/services/git/schemas.d.mts +932 -0
- package/dist/services/git/schemas.mjs +1 -0
- package/dist/services/harness/index.d.mts +861 -0
- package/dist/services/harness/index.mjs +1 -0
- package/dist/services/harness/storage/schema.d.mts +424 -0
- package/dist/services/harness/storage/schema.mjs +1 -0
- package/dist/services/index.d.mts +6185 -0
- package/dist/services/index.mjs +1 -0
- package/dist/services/local-notification/index.d.mts +25 -0
- package/dist/services/local-notification/index.mjs +1 -0
- package/dist/services/local-notification/namespace.d.mts +73 -0
- package/dist/services/local-notification/namespace.mjs +1 -0
- package/dist/services/local-notification/schemas.d.mts +88 -0
- package/dist/services/local-notification/schemas.mjs +1 -0
- package/dist/services/log-import/browser.d.mts +3 -0
- package/dist/services/log-import/browser.mjs +1 -0
- package/dist/services/log-import/index.d.mts +274 -0
- package/dist/services/log-import/index.mjs +2 -0
- package/dist/services/log-import/log-import.d.mts +3 -0
- package/dist/services/log-import/log-import.mjs +1 -0
- package/dist/services/log-import/namespace.d.mts +327 -0
- package/dist/services/log-import/namespace.mjs +1 -0
- package/dist/services/log-import/schemas.d.mts +217 -0
- package/dist/services/log-import/schemas.mjs +1 -0
- package/dist/services/model-registry/index.d.mts +2 -0
- package/dist/services/model-registry/index.mjs +1 -0
- package/dist/services/preferences/index.d.mts +3 -0
- package/dist/services/preferences/index.mjs +1 -0
- package/dist/services/preferences/schemas.d.mts +2 -0
- package/dist/services/preferences/schemas.mjs +1 -0
- package/dist/services/preferences/storage-namespace.d.mts +3 -0
- package/dist/services/preferences/storage-namespace.mjs +1 -0
- package/dist/services/provider-context/index.d.mts +2 -0
- package/dist/services/provider-context/index.mjs +1 -0
- package/dist/services/provider-runtime/index.d.mts +136 -0
- package/dist/services/provider-runtime/index.mjs +1 -0
- package/dist/services/session/handlers/index.d.mts +2 -0
- package/dist/services/session/handlers/index.mjs +1 -0
- package/dist/services/session/index.d.mts +10 -0
- package/dist/services/session/index.mjs +1 -0
- package/dist/services/session/messages/namespace.d.mts +2 -0
- package/dist/services/session/messages/namespace.mjs +1 -0
- package/dist/services/session/orchestrator-testing/index.d.mts +2 -0
- package/dist/services/session/orchestrator-testing/index.mjs +1 -0
- package/dist/services/session/session-events/namespace.d.mts +2 -0
- package/dist/services/session/session-events/namespace.mjs +1 -0
- package/dist/services/session/storage/namespace.d.mts +2 -0
- package/dist/services/session/storage/namespace.mjs +1 -0
- package/dist/services/session/storage/schema.d.mts +2 -0
- package/dist/services/session/storage/schema.mjs +1 -0
- package/dist/services/session/testing/index.d.mts +35 -0
- package/dist/services/session/testing/index.mjs +65 -0
- package/dist/services/session/testing/orchestrator-shared.d.mts +2 -0
- package/dist/services/session/testing/orchestrator-shared.mjs +1 -0
- package/dist/services/session/turns/namespace.d.mts +2 -0
- package/dist/services/session/turns/namespace.mjs +1 -0
- package/dist/services/session-editor/index.d.mts +119 -0
- package/dist/services/session-editor/index.mjs +1 -0
- package/dist/services/settings/index.d.mts +47 -0
- package/dist/services/settings/index.mjs +1 -0
- package/dist/services/settings/namespace.d.mts +663 -0
- package/dist/services/settings/namespace.mjs +1 -0
- package/dist/services/settings/storage/clients-namespace.d.mts +2 -0
- package/dist/services/settings/storage/clients-namespace.mjs +1 -0
- package/dist/services/settings/storage/extension-configs/namespace.d.mts +184 -0
- package/dist/services/settings/storage/extension-configs/namespace.mjs +1 -0
- package/dist/services/settings/storage/index.d.mts +4 -0
- package/dist/services/settings/storage/index.mjs +1 -0
- package/dist/services/settings/storage/providers-namespace.d.mts +2 -0
- package/dist/services/settings/storage/providers-namespace.mjs +1 -0
- package/dist/services/subagent/index.d.mts +2 -0
- package/dist/services/subagent/index.mjs +1 -0
- package/dist/services/subagent-template/index.d.mts +3 -0
- package/dist/services/subagent-template/index.mjs +1 -0
- package/dist/services/subagent-template/namespace.d.mts +2 -0
- package/dist/services/subagent-template/namespace.mjs +1 -0
- package/dist/services/subagent-template/schemas.d.mts +2 -0
- package/dist/services/subagent-template/schemas.mjs +1 -0
- package/dist/services/tool-approval/index.d.mts +2 -0
- package/dist/services/tool-approval/index.mjs +1 -0
- package/dist/services/tools/index.d.mts +2 -0
- package/dist/services/tools/index.mjs +1 -0
- package/dist/services/tray-menu/index.d.mts +4 -0
- package/dist/services/tray-menu/index.mjs +1 -0
- package/dist/services/tray-menu/namespace.d.mts +2 -0
- package/dist/services/tray-menu/namespace.mjs +1 -0
- package/dist/services/tray-menu/schemas.d.mts +2 -0
- package/dist/services/tray-menu/schemas.mjs +1 -0
- package/dist/services/turn/index.d.mts +2 -0
- package/dist/services/turn/index.mjs +1 -0
- package/dist/services/turn/namespace.d.mts +2 -0
- package/dist/services/turn/namespace.mjs +1 -0
- package/dist/services/turn/schemas.d.mts +335 -0
- package/dist/services/turn/schemas.mjs +1 -0
- package/dist/session-BoldSdNZ2.mjs +134 -0
- package/dist/session-DuVOYctZ.mjs +1 -0
- package/dist/session-lineage-CRsc9g1x.d.mts +65 -0
- package/dist/shared-DpOEfD8F.mjs +1 -0
- package/dist/shared-schemas-CPShiLNp.mjs +1 -0
- package/dist/skill-CQO4mDqK.mjs +1 -0
- package/dist/storage/drizzle/client.d.mts +78 -0
- package/dist/storage/drizzle/client.mjs +1 -0
- package/dist/storage/drizzle/index.d.mts +137 -0
- package/dist/storage/drizzle/index.mjs +1 -0
- package/dist/storage/handlers/drizzle/index.d.mts +2 -0
- package/dist/storage/handlers/drizzle/index.mjs +1 -0
- package/dist/storage/handlers/index.d.mts +33 -0
- package/dist/storage/handlers/index.mjs +1 -0
- package/dist/storage/index.d.mts +192 -0
- package/dist/storage/index.mjs +1 -0
- package/dist/storage-namespace-BXkoh5Sy.d.mts +221 -0
- package/dist/storage-namespace-DWsYLAXa.mjs +1 -0
- package/dist/storage-namespace-definition-Bkx5rSto.d.mts +17 -0
- package/dist/storage-namespace-definition-CqSdsuCC.mjs +1 -0
- package/dist/style.css +3782 -0
- package/dist/telemetry-CvdLBWuk.mjs +1 -0
- package/dist/testing/drizzle-harness.d.mts +130 -0
- package/dist/testing/drizzle-harness.mjs +1 -0
- package/dist/testing/index.d.mts +106 -0
- package/dist/testing/index.mjs +1 -0
- package/dist/timeout-XsYIOKrc.mjs +1 -0
- package/dist/tool-approval-service-BvZWhYZp.mjs +1 -0
- package/dist/tools/index.d.mts +835 -0
- package/dist/tools/index.mjs +1 -0
- package/dist/tools/testing/index.d.mts +53 -0
- package/dist/tools/testing/index.mjs +1 -0
- package/dist/tools-D-luYcDw.mjs +1431 -0
- package/dist/tray-menu-service-DuXq5k22.mjs +1 -0
- package/dist/types-BCMUtBj1.d.mts +1106 -0
- package/dist/types-C2Ob9zz_.d.mts +128 -0
- package/dist/types-CCdqjeuH.d.mts +262 -0
- package/dist/types-DZHvOc_Q.d.mts +305 -0
- package/dist/types-Dy3YTcTF.d.mts +6777 -0
- package/dist/types-MfJZ67e9.d.mts +315 -0
- package/dist/types-dyP-bXXE.d.mts +31 -0
- package/dist/ui-components/index.d.mts +2342 -0
- package/dist/ui-components/index.mjs +8 -0
- package/dist/ui-config-9bDRwFZr.mjs +1 -0
- package/dist/ui-hooks/index.d.mts +1915 -0
- package/dist/ui-hooks/index.mjs +1 -0
- package/dist/ui-kernel/index.d.mts +2793 -0
- package/dist/ui-kernel/index.mjs +1 -0
- package/dist/ui-kernel/pages/namespace.d.mts +88 -0
- package/dist/ui-kernel/pages/namespace.mjs +1 -0
- package/dist/ui-kernel/pages/schemas.d.mts +2 -0
- package/dist/ui-kernel/pages/schemas.mjs +1 -0
- package/dist/ui-views/index.d.mts +487 -0
- package/dist/ui-views/index.mjs +30 -0
- package/dist/utils/health-probe.d.mts +26 -0
- package/dist/utils/health-probe.mjs +1 -0
- package/dist/utils/index.d.mts +262 -0
- package/dist/utils/index.mjs +2 -0
- package/dist/utils/keychain.d.mts +31 -0
- package/dist/utils/keychain.mjs +1 -0
- package/dist/utils/project-manifest.d.mts +130 -0
- package/dist/utils/project-manifest.mjs +1 -0
- package/dist/utils/resolve-package-root.d.mts +12 -0
- package/dist/utils/resolve-package-root.mjs +1 -0
- package/dist/utils/scope-paths.d.mts +33 -0
- package/dist/utils/scope-paths.mjs +1 -0
- package/dist/utils/workspace-packages.d.mts +59 -0
- package/dist/utils/workspace-packages.mjs +1 -0
- package/dist/utils/workspace-root.d.mts +24 -0
- package/dist/utils/workspace-root.mjs +2 -0
- package/dist/variant-CT6XBP6T.mjs +1 -0
- package/dist/version-BeT3ASEe.mjs +1 -0
- package/dist/visibility-Cb62p9bv.mjs +1 -0
- package/dist/window-registry-CBcrGTv4.d.mts +130 -0
- package/dist/window-registry-DW-dKRjQ.mjs +1 -0
- package/package.json +1 -1
|
@@ -0,0 +1,1490 @@
|
|
|
1
|
+
import * as _$zod from "zod";
|
|
2
|
+
import { z } from "zod";
|
|
3
|
+
import * as _$_makaio_core0 from "@makaio/framework/core";
|
|
4
|
+
import { IMakaioBus } from "@makaio/framework/bus";
|
|
5
|
+
import { AIModelMetadata } from "@makaio/framework/contracts";
|
|
6
|
+
import { BaseService } from "@makaio/framework/service-base";
|
|
7
|
+
import * as _$zod_v4_core0 from "zod/v4/core";
|
|
8
|
+
|
|
9
|
+
//#region services/core/src/model-registry/schemas.d.ts
|
|
10
|
+
/**
|
|
11
|
+
* Provider-specific model override schema.
|
|
12
|
+
*
|
|
13
|
+
* Provider entries may override serving-specific model fields, but identity
|
|
14
|
+
* remains owned by the lab model reference and is resolved at merge time.
|
|
15
|
+
*/
|
|
16
|
+
declare const ProviderModelOverrideSchema: z.ZodObject<{
|
|
17
|
+
friendlyName: z.ZodOptional<z.ZodOptional<z.ZodString>>;
|
|
18
|
+
family: z.ZodOptional<z.ZodOptional<z.ZodString>>;
|
|
19
|
+
contextWindowSize: z.ZodOptional<z.ZodNumber>;
|
|
20
|
+
supportedReasoningLevels: z.ZodOptional<z.ZodOptional<z.ZodObject<{
|
|
21
|
+
none: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodString]>>;
|
|
22
|
+
low: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodString]>>;
|
|
23
|
+
medium: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodString]>>;
|
|
24
|
+
high: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodString]>>;
|
|
25
|
+
'extra-high': z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodString]>>;
|
|
26
|
+
}, z.core.$strip>>>;
|
|
27
|
+
metadata: z.ZodOptional<z.ZodOptional<z.ZodObject<{
|
|
28
|
+
maxOutputTokens: z.ZodOptional<z.ZodNumber>;
|
|
29
|
+
capabilities: z.ZodOptional<z.ZodObject<{
|
|
30
|
+
vision: z.ZodOptional<z.ZodBoolean>;
|
|
31
|
+
toolCalling: z.ZodOptional<z.ZodBoolean>;
|
|
32
|
+
parallelToolCalls: z.ZodOptional<z.ZodBoolean>;
|
|
33
|
+
structuredOutput: z.ZodOptional<z.ZodBoolean>;
|
|
34
|
+
pdfUpload: z.ZodOptional<z.ZodBoolean>;
|
|
35
|
+
speechToText: z.ZodOptional<z.ZodObject<{
|
|
36
|
+
modes: z.ZodArray<z.ZodEnum<{
|
|
37
|
+
batch: "batch";
|
|
38
|
+
streaming: "streaming";
|
|
39
|
+
}>>;
|
|
40
|
+
vocabularyBiasing: z.ZodOptional<z.ZodBoolean>;
|
|
41
|
+
}, z.core.$strip>>;
|
|
42
|
+
textToSpeech: z.ZodOptional<z.ZodObject<{
|
|
43
|
+
modes: z.ZodArray<z.ZodEnum<{
|
|
44
|
+
streaming: "streaming";
|
|
45
|
+
buffered: "buffered";
|
|
46
|
+
}>>;
|
|
47
|
+
voiceSelection: z.ZodOptional<z.ZodBoolean>;
|
|
48
|
+
voiceInstructions: z.ZodOptional<z.ZodBoolean>;
|
|
49
|
+
outputFormats: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
50
|
+
}, z.core.$strip>>;
|
|
51
|
+
}, z.core.$strip>>;
|
|
52
|
+
pricing: z.ZodOptional<z.ZodObject<{
|
|
53
|
+
token: z.ZodOptional<z.ZodObject<{
|
|
54
|
+
inputPerMillion: z.ZodNumber;
|
|
55
|
+
inputCachedPerMillion: z.ZodOptional<z.ZodNumber>;
|
|
56
|
+
cacheWritePerMillion: z.ZodOptional<z.ZodNumber>;
|
|
57
|
+
outputPerMillion: z.ZodNumber;
|
|
58
|
+
}, z.core.$strip>>;
|
|
59
|
+
request: z.ZodOptional<z.ZodObject<{
|
|
60
|
+
multiplier: z.ZodNumber;
|
|
61
|
+
}, z.core.$strip>>;
|
|
62
|
+
}, z.core.$strip>>;
|
|
63
|
+
includedInSubscription: z.ZodOptional<z.ZodBoolean>;
|
|
64
|
+
description: z.ZodOptional<z.ZodString>;
|
|
65
|
+
}, z.core.$strip>>>;
|
|
66
|
+
canonicalModel: z.ZodOptional<z.ZodString>;
|
|
67
|
+
name: z.ZodOptional<z.ZodNever>;
|
|
68
|
+
labId: z.ZodOptional<z.ZodNever>;
|
|
69
|
+
}, z.core.$strip>;
|
|
70
|
+
/** Inferred type for provider-specific model overrides. */
|
|
71
|
+
type ProviderModelOverride = z.infer<typeof ProviderModelOverrideSchema>;
|
|
72
|
+
/**
|
|
73
|
+
* Schema for the complete v2 model registry.
|
|
74
|
+
*
|
|
75
|
+
* The v2 format separates lab definitions (canonical model metadata) from
|
|
76
|
+
* provider overrides (serving-specific fields like pricing and capabilities).
|
|
77
|
+
* This allows a single lab model to be served by multiple providers with
|
|
78
|
+
* minimal duplication.
|
|
79
|
+
*/
|
|
80
|
+
declare const ModelRegistrySchema: z.ZodObject<{
|
|
81
|
+
$schema: z.ZodLiteral<"makaio/model-registry/v2">;
|
|
82
|
+
updatedAt: z.ZodString;
|
|
83
|
+
labs: z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
84
|
+
name: z.ZodString;
|
|
85
|
+
models: z.ZodArray<z.ZodObject<{
|
|
86
|
+
name: z.ZodString;
|
|
87
|
+
friendlyName: z.ZodOptional<z.ZodString>;
|
|
88
|
+
family: z.ZodOptional<z.ZodString>;
|
|
89
|
+
contextWindowSize: z.ZodNumber;
|
|
90
|
+
labId: z.ZodString;
|
|
91
|
+
supportedReasoningLevels: z.ZodOptional<z.ZodObject<{
|
|
92
|
+
none: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodString]>>;
|
|
93
|
+
low: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodString]>>;
|
|
94
|
+
medium: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodString]>>;
|
|
95
|
+
high: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodString]>>;
|
|
96
|
+
'extra-high': z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodString]>>;
|
|
97
|
+
}, z.core.$strip>>;
|
|
98
|
+
metadata: z.ZodOptional<z.ZodObject<{
|
|
99
|
+
maxOutputTokens: z.ZodOptional<z.ZodNumber>;
|
|
100
|
+
capabilities: z.ZodOptional<z.ZodObject<{
|
|
101
|
+
vision: z.ZodOptional<z.ZodBoolean>;
|
|
102
|
+
toolCalling: z.ZodOptional<z.ZodBoolean>;
|
|
103
|
+
parallelToolCalls: z.ZodOptional<z.ZodBoolean>;
|
|
104
|
+
structuredOutput: z.ZodOptional<z.ZodBoolean>;
|
|
105
|
+
pdfUpload: z.ZodOptional<z.ZodBoolean>;
|
|
106
|
+
speechToText: z.ZodOptional<z.ZodObject<{
|
|
107
|
+
modes: z.ZodArray<z.ZodEnum<{
|
|
108
|
+
batch: "batch";
|
|
109
|
+
streaming: "streaming";
|
|
110
|
+
}>>;
|
|
111
|
+
vocabularyBiasing: z.ZodOptional<z.ZodBoolean>;
|
|
112
|
+
}, z.core.$strip>>;
|
|
113
|
+
textToSpeech: z.ZodOptional<z.ZodObject<{
|
|
114
|
+
modes: z.ZodArray<z.ZodEnum<{
|
|
115
|
+
streaming: "streaming";
|
|
116
|
+
buffered: "buffered";
|
|
117
|
+
}>>;
|
|
118
|
+
voiceSelection: z.ZodOptional<z.ZodBoolean>;
|
|
119
|
+
voiceInstructions: z.ZodOptional<z.ZodBoolean>;
|
|
120
|
+
outputFormats: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
121
|
+
}, z.core.$strip>>;
|
|
122
|
+
}, z.core.$strip>>;
|
|
123
|
+
pricing: z.ZodOptional<z.ZodObject<{
|
|
124
|
+
token: z.ZodOptional<z.ZodObject<{
|
|
125
|
+
inputPerMillion: z.ZodNumber;
|
|
126
|
+
inputCachedPerMillion: z.ZodOptional<z.ZodNumber>;
|
|
127
|
+
cacheWritePerMillion: z.ZodOptional<z.ZodNumber>;
|
|
128
|
+
outputPerMillion: z.ZodNumber;
|
|
129
|
+
}, z.core.$strip>>;
|
|
130
|
+
request: z.ZodOptional<z.ZodObject<{
|
|
131
|
+
multiplier: z.ZodNumber;
|
|
132
|
+
}, z.core.$strip>>;
|
|
133
|
+
}, z.core.$strip>>;
|
|
134
|
+
includedInSubscription: z.ZodOptional<z.ZodBoolean>;
|
|
135
|
+
description: z.ZodOptional<z.ZodString>;
|
|
136
|
+
}, z.core.$strip>>;
|
|
137
|
+
}, z.core.$strip>>;
|
|
138
|
+
}, z.core.$strip>>;
|
|
139
|
+
providers: z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
140
|
+
name: z.ZodString;
|
|
141
|
+
models: z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
142
|
+
friendlyName: z.ZodOptional<z.ZodOptional<z.ZodString>>;
|
|
143
|
+
family: z.ZodOptional<z.ZodOptional<z.ZodString>>;
|
|
144
|
+
contextWindowSize: z.ZodOptional<z.ZodNumber>;
|
|
145
|
+
supportedReasoningLevels: z.ZodOptional<z.ZodOptional<z.ZodObject<{
|
|
146
|
+
none: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodString]>>;
|
|
147
|
+
low: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodString]>>;
|
|
148
|
+
medium: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodString]>>;
|
|
149
|
+
high: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodString]>>;
|
|
150
|
+
'extra-high': z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodString]>>;
|
|
151
|
+
}, z.core.$strip>>>;
|
|
152
|
+
metadata: z.ZodOptional<z.ZodOptional<z.ZodObject<{
|
|
153
|
+
maxOutputTokens: z.ZodOptional<z.ZodNumber>;
|
|
154
|
+
capabilities: z.ZodOptional<z.ZodObject<{
|
|
155
|
+
vision: z.ZodOptional<z.ZodBoolean>;
|
|
156
|
+
toolCalling: z.ZodOptional<z.ZodBoolean>;
|
|
157
|
+
parallelToolCalls: z.ZodOptional<z.ZodBoolean>;
|
|
158
|
+
structuredOutput: z.ZodOptional<z.ZodBoolean>;
|
|
159
|
+
pdfUpload: z.ZodOptional<z.ZodBoolean>;
|
|
160
|
+
speechToText: z.ZodOptional<z.ZodObject<{
|
|
161
|
+
modes: z.ZodArray<z.ZodEnum<{
|
|
162
|
+
batch: "batch";
|
|
163
|
+
streaming: "streaming";
|
|
164
|
+
}>>;
|
|
165
|
+
vocabularyBiasing: z.ZodOptional<z.ZodBoolean>;
|
|
166
|
+
}, z.core.$strip>>;
|
|
167
|
+
textToSpeech: z.ZodOptional<z.ZodObject<{
|
|
168
|
+
modes: z.ZodArray<z.ZodEnum<{
|
|
169
|
+
streaming: "streaming";
|
|
170
|
+
buffered: "buffered";
|
|
171
|
+
}>>;
|
|
172
|
+
voiceSelection: z.ZodOptional<z.ZodBoolean>;
|
|
173
|
+
voiceInstructions: z.ZodOptional<z.ZodBoolean>;
|
|
174
|
+
outputFormats: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
175
|
+
}, z.core.$strip>>;
|
|
176
|
+
}, z.core.$strip>>;
|
|
177
|
+
pricing: z.ZodOptional<z.ZodObject<{
|
|
178
|
+
token: z.ZodOptional<z.ZodObject<{
|
|
179
|
+
inputPerMillion: z.ZodNumber;
|
|
180
|
+
inputCachedPerMillion: z.ZodOptional<z.ZodNumber>;
|
|
181
|
+
cacheWritePerMillion: z.ZodOptional<z.ZodNumber>;
|
|
182
|
+
outputPerMillion: z.ZodNumber;
|
|
183
|
+
}, z.core.$strip>>;
|
|
184
|
+
request: z.ZodOptional<z.ZodObject<{
|
|
185
|
+
multiplier: z.ZodNumber;
|
|
186
|
+
}, z.core.$strip>>;
|
|
187
|
+
}, z.core.$strip>>;
|
|
188
|
+
includedInSubscription: z.ZodOptional<z.ZodBoolean>;
|
|
189
|
+
description: z.ZodOptional<z.ZodString>;
|
|
190
|
+
}, z.core.$strip>>>;
|
|
191
|
+
canonicalModel: z.ZodOptional<z.ZodString>;
|
|
192
|
+
name: z.ZodOptional<z.ZodNever>;
|
|
193
|
+
labId: z.ZodOptional<z.ZodNever>;
|
|
194
|
+
}, z.core.$strip>>;
|
|
195
|
+
}, z.core.$strip>>;
|
|
196
|
+
}, z.core.$strip>;
|
|
197
|
+
/**
|
|
198
|
+
* Inferred type for the v2 model registry.
|
|
199
|
+
*/
|
|
200
|
+
type ModelRegistry = z.infer<typeof ModelRegistrySchema>;
|
|
201
|
+
/**
|
|
202
|
+
* Model registry bus schemas.
|
|
203
|
+
*
|
|
204
|
+
* Subjects for model-registry-related bus communication.
|
|
205
|
+
* Each key becomes a subject identifier as: `modelRegistry.{key}`
|
|
206
|
+
*
|
|
207
|
+
* **Bus subjects:**
|
|
208
|
+
* - `modelRegistry.getForProvider` — Resolve a single model for a provider
|
|
209
|
+
* - `modelRegistry.getLabModels` — List all canonical models for a lab
|
|
210
|
+
* - `modelRegistry.getProviderModels` — List all models available from a provider
|
|
211
|
+
* - `modelRegistry.refresh` — Force refresh from remote registry
|
|
212
|
+
* - `modelRegistry.changed` — Broadcast that the in-memory registry changed
|
|
213
|
+
* @example Get models for a provider
|
|
214
|
+
* ```typescript
|
|
215
|
+
* const result = await bus.request(ModelRegistrySubjects.getProviderModels, {
|
|
216
|
+
* providerId: 'anthropic',
|
|
217
|
+
* });
|
|
218
|
+
* ```
|
|
219
|
+
* @example Force refresh from remote
|
|
220
|
+
* ```typescript
|
|
221
|
+
* await bus.request(ModelRegistrySubjects.refresh, {});
|
|
222
|
+
* ```
|
|
223
|
+
*/
|
|
224
|
+
declare const ModelRegistrySchemas: {
|
|
225
|
+
/**
|
|
226
|
+
* Resolve a single model by provider and provider-native model ID.
|
|
227
|
+
*
|
|
228
|
+
* Returns the merged model descriptor (lab definition + provider overrides),
|
|
229
|
+
* or `undefined` if the model is not found for the given provider.
|
|
230
|
+
*/
|
|
231
|
+
getForProvider: {
|
|
232
|
+
request: z.ZodObject<{
|
|
233
|
+
providerId: z.ZodString;
|
|
234
|
+
model: z.ZodString;
|
|
235
|
+
}, z.core.$strip>;
|
|
236
|
+
response: z.ZodObject<{
|
|
237
|
+
model: z.ZodOptional<z.ZodObject<{
|
|
238
|
+
name: z.ZodString;
|
|
239
|
+
friendlyName: z.ZodOptional<z.ZodString>;
|
|
240
|
+
family: z.ZodOptional<z.ZodString>;
|
|
241
|
+
contextWindowSize: z.ZodNumber;
|
|
242
|
+
labId: z.ZodString;
|
|
243
|
+
supportedReasoningLevels: z.ZodOptional<z.ZodObject<{
|
|
244
|
+
none: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodString]>>;
|
|
245
|
+
low: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodString]>>;
|
|
246
|
+
medium: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodString]>>;
|
|
247
|
+
high: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodString]>>;
|
|
248
|
+
'extra-high': z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodString]>>;
|
|
249
|
+
}, z.core.$strip>>;
|
|
250
|
+
metadata: z.ZodOptional<z.ZodObject<{
|
|
251
|
+
maxOutputTokens: z.ZodOptional<z.ZodNumber>;
|
|
252
|
+
capabilities: z.ZodOptional<z.ZodObject<{
|
|
253
|
+
vision: z.ZodOptional<z.ZodBoolean>;
|
|
254
|
+
toolCalling: z.ZodOptional<z.ZodBoolean>;
|
|
255
|
+
parallelToolCalls: z.ZodOptional<z.ZodBoolean>;
|
|
256
|
+
structuredOutput: z.ZodOptional<z.ZodBoolean>;
|
|
257
|
+
pdfUpload: z.ZodOptional<z.ZodBoolean>;
|
|
258
|
+
speechToText: z.ZodOptional<z.ZodObject<{
|
|
259
|
+
modes: z.ZodArray<z.ZodEnum<{
|
|
260
|
+
batch: "batch";
|
|
261
|
+
streaming: "streaming";
|
|
262
|
+
}>>;
|
|
263
|
+
vocabularyBiasing: z.ZodOptional<z.ZodBoolean>;
|
|
264
|
+
}, z.core.$strip>>;
|
|
265
|
+
textToSpeech: z.ZodOptional<z.ZodObject<{
|
|
266
|
+
modes: z.ZodArray<z.ZodEnum<{
|
|
267
|
+
streaming: "streaming";
|
|
268
|
+
buffered: "buffered";
|
|
269
|
+
}>>;
|
|
270
|
+
voiceSelection: z.ZodOptional<z.ZodBoolean>;
|
|
271
|
+
voiceInstructions: z.ZodOptional<z.ZodBoolean>;
|
|
272
|
+
outputFormats: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
273
|
+
}, z.core.$strip>>;
|
|
274
|
+
}, z.core.$strip>>;
|
|
275
|
+
pricing: z.ZodOptional<z.ZodObject<{
|
|
276
|
+
token: z.ZodOptional<z.ZodObject<{
|
|
277
|
+
inputPerMillion: z.ZodNumber;
|
|
278
|
+
inputCachedPerMillion: z.ZodOptional<z.ZodNumber>;
|
|
279
|
+
cacheWritePerMillion: z.ZodOptional<z.ZodNumber>;
|
|
280
|
+
outputPerMillion: z.ZodNumber;
|
|
281
|
+
}, z.core.$strip>>;
|
|
282
|
+
request: z.ZodOptional<z.ZodObject<{
|
|
283
|
+
multiplier: z.ZodNumber;
|
|
284
|
+
}, z.core.$strip>>;
|
|
285
|
+
}, z.core.$strip>>;
|
|
286
|
+
includedInSubscription: z.ZodOptional<z.ZodBoolean>;
|
|
287
|
+
description: z.ZodOptional<z.ZodString>;
|
|
288
|
+
}, z.core.$strip>>;
|
|
289
|
+
}, z.core.$strip>>;
|
|
290
|
+
}, z.core.$strip>;
|
|
291
|
+
};
|
|
292
|
+
/**
|
|
293
|
+
* List all canonical model definitions published by a lab.
|
|
294
|
+
*
|
|
295
|
+
* Returns the full lab model array without any provider-specific overrides.
|
|
296
|
+
*/
|
|
297
|
+
getLabModels: {
|
|
298
|
+
request: z.ZodObject<{
|
|
299
|
+
labId: z.ZodString;
|
|
300
|
+
}, z.core.$strip>;
|
|
301
|
+
response: z.ZodObject<{
|
|
302
|
+
models: z.ZodArray<z.ZodObject<{
|
|
303
|
+
name: z.ZodString;
|
|
304
|
+
friendlyName: z.ZodOptional<z.ZodString>;
|
|
305
|
+
family: z.ZodOptional<z.ZodString>;
|
|
306
|
+
contextWindowSize: z.ZodNumber;
|
|
307
|
+
labId: z.ZodString;
|
|
308
|
+
supportedReasoningLevels: z.ZodOptional<z.ZodObject<{
|
|
309
|
+
none: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodString]>>;
|
|
310
|
+
low: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodString]>>;
|
|
311
|
+
medium: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodString]>>;
|
|
312
|
+
high: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodString]>>;
|
|
313
|
+
'extra-high': z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodString]>>;
|
|
314
|
+
}, z.core.$strip>>;
|
|
315
|
+
metadata: z.ZodOptional<z.ZodObject<{
|
|
316
|
+
maxOutputTokens: z.ZodOptional<z.ZodNumber>;
|
|
317
|
+
capabilities: z.ZodOptional<z.ZodObject<{
|
|
318
|
+
vision: z.ZodOptional<z.ZodBoolean>;
|
|
319
|
+
toolCalling: z.ZodOptional<z.ZodBoolean>;
|
|
320
|
+
parallelToolCalls: z.ZodOptional<z.ZodBoolean>;
|
|
321
|
+
structuredOutput: z.ZodOptional<z.ZodBoolean>;
|
|
322
|
+
pdfUpload: z.ZodOptional<z.ZodBoolean>;
|
|
323
|
+
speechToText: z.ZodOptional<z.ZodObject<{
|
|
324
|
+
modes: z.ZodArray<z.ZodEnum<{
|
|
325
|
+
batch: "batch";
|
|
326
|
+
streaming: "streaming";
|
|
327
|
+
}>>;
|
|
328
|
+
vocabularyBiasing: z.ZodOptional<z.ZodBoolean>;
|
|
329
|
+
}, z.core.$strip>>;
|
|
330
|
+
textToSpeech: z.ZodOptional<z.ZodObject<{
|
|
331
|
+
modes: z.ZodArray<z.ZodEnum<{
|
|
332
|
+
streaming: "streaming";
|
|
333
|
+
buffered: "buffered";
|
|
334
|
+
}>>;
|
|
335
|
+
voiceSelection: z.ZodOptional<z.ZodBoolean>;
|
|
336
|
+
voiceInstructions: z.ZodOptional<z.ZodBoolean>;
|
|
337
|
+
outputFormats: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
338
|
+
}, z.core.$strip>>;
|
|
339
|
+
}, z.core.$strip>>;
|
|
340
|
+
pricing: z.ZodOptional<z.ZodObject<{
|
|
341
|
+
token: z.ZodOptional<z.ZodObject<{
|
|
342
|
+
inputPerMillion: z.ZodNumber;
|
|
343
|
+
inputCachedPerMillion: z.ZodOptional<z.ZodNumber>;
|
|
344
|
+
cacheWritePerMillion: z.ZodOptional<z.ZodNumber>;
|
|
345
|
+
outputPerMillion: z.ZodNumber;
|
|
346
|
+
}, z.core.$strip>>;
|
|
347
|
+
request: z.ZodOptional<z.ZodObject<{
|
|
348
|
+
multiplier: z.ZodNumber;
|
|
349
|
+
}, z.core.$strip>>;
|
|
350
|
+
}, z.core.$strip>>;
|
|
351
|
+
includedInSubscription: z.ZodOptional<z.ZodBoolean>;
|
|
352
|
+
description: z.ZodOptional<z.ZodString>;
|
|
353
|
+
}, z.core.$strip>>;
|
|
354
|
+
}, z.core.$strip>>;
|
|
355
|
+
}, z.core.$strip>;
|
|
356
|
+
};
|
|
357
|
+
/**
|
|
358
|
+
* List all models available from a provider (merged with lab definitions).
|
|
359
|
+
*
|
|
360
|
+
* Returns the full merged model list for the provider — lab defaults with
|
|
361
|
+
* provider-specific overrides applied.
|
|
362
|
+
*/
|
|
363
|
+
getProviderModels: {
|
|
364
|
+
request: z.ZodObject<{
|
|
365
|
+
providerId: z.ZodString;
|
|
366
|
+
}, z.core.$strip>;
|
|
367
|
+
response: z.ZodObject<{
|
|
368
|
+
models: z.ZodArray<z.ZodObject<{
|
|
369
|
+
name: z.ZodString;
|
|
370
|
+
friendlyName: z.ZodOptional<z.ZodString>;
|
|
371
|
+
family: z.ZodOptional<z.ZodString>;
|
|
372
|
+
contextWindowSize: z.ZodNumber;
|
|
373
|
+
labId: z.ZodString;
|
|
374
|
+
supportedReasoningLevels: z.ZodOptional<z.ZodObject<{
|
|
375
|
+
none: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodString]>>;
|
|
376
|
+
low: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodString]>>;
|
|
377
|
+
medium: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodString]>>;
|
|
378
|
+
high: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodString]>>;
|
|
379
|
+
'extra-high': z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodString]>>;
|
|
380
|
+
}, z.core.$strip>>;
|
|
381
|
+
metadata: z.ZodOptional<z.ZodObject<{
|
|
382
|
+
maxOutputTokens: z.ZodOptional<z.ZodNumber>;
|
|
383
|
+
capabilities: z.ZodOptional<z.ZodObject<{
|
|
384
|
+
vision: z.ZodOptional<z.ZodBoolean>;
|
|
385
|
+
toolCalling: z.ZodOptional<z.ZodBoolean>;
|
|
386
|
+
parallelToolCalls: z.ZodOptional<z.ZodBoolean>;
|
|
387
|
+
structuredOutput: z.ZodOptional<z.ZodBoolean>;
|
|
388
|
+
pdfUpload: z.ZodOptional<z.ZodBoolean>;
|
|
389
|
+
speechToText: z.ZodOptional<z.ZodObject<{
|
|
390
|
+
modes: z.ZodArray<z.ZodEnum<{
|
|
391
|
+
batch: "batch";
|
|
392
|
+
streaming: "streaming";
|
|
393
|
+
}>>;
|
|
394
|
+
vocabularyBiasing: z.ZodOptional<z.ZodBoolean>;
|
|
395
|
+
}, z.core.$strip>>;
|
|
396
|
+
textToSpeech: z.ZodOptional<z.ZodObject<{
|
|
397
|
+
modes: z.ZodArray<z.ZodEnum<{
|
|
398
|
+
streaming: "streaming";
|
|
399
|
+
buffered: "buffered";
|
|
400
|
+
}>>;
|
|
401
|
+
voiceSelection: z.ZodOptional<z.ZodBoolean>;
|
|
402
|
+
voiceInstructions: z.ZodOptional<z.ZodBoolean>;
|
|
403
|
+
outputFormats: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
404
|
+
}, z.core.$strip>>;
|
|
405
|
+
}, z.core.$strip>>;
|
|
406
|
+
pricing: z.ZodOptional<z.ZodObject<{
|
|
407
|
+
token: z.ZodOptional<z.ZodObject<{
|
|
408
|
+
inputPerMillion: z.ZodNumber;
|
|
409
|
+
inputCachedPerMillion: z.ZodOptional<z.ZodNumber>;
|
|
410
|
+
cacheWritePerMillion: z.ZodOptional<z.ZodNumber>;
|
|
411
|
+
outputPerMillion: z.ZodNumber;
|
|
412
|
+
}, z.core.$strip>>;
|
|
413
|
+
request: z.ZodOptional<z.ZodObject<{
|
|
414
|
+
multiplier: z.ZodNumber;
|
|
415
|
+
}, z.core.$strip>>;
|
|
416
|
+
}, z.core.$strip>>;
|
|
417
|
+
includedInSubscription: z.ZodOptional<z.ZodBoolean>;
|
|
418
|
+
description: z.ZodOptional<z.ZodString>;
|
|
419
|
+
}, z.core.$strip>>;
|
|
420
|
+
}, z.core.$strip>>;
|
|
421
|
+
}, z.core.$strip>;
|
|
422
|
+
};
|
|
423
|
+
/**
|
|
424
|
+
* Force refresh of the model registry from remote source.
|
|
425
|
+
* Fetches latest registry and updates cache.
|
|
426
|
+
*/
|
|
427
|
+
refresh: {
|
|
428
|
+
request: z.ZodObject<{}, z.core.$strip>;
|
|
429
|
+
response: z.ZodObject<{
|
|
430
|
+
success: z.ZodBoolean;
|
|
431
|
+
error: z.ZodOptional<z.ZodString>;
|
|
432
|
+
}, z.core.$strip>;
|
|
433
|
+
};
|
|
434
|
+
/**
|
|
435
|
+
* Batch-check model availability across multiple providers in a single RPC.
|
|
436
|
+
*
|
|
437
|
+
* Accepts an array of provider IDs and a canonical lab model name. Returns a map of
|
|
438
|
+
* `providerId → resolved ProviderAIModel` containing only the providers
|
|
439
|
+
* that have the model. Providers absent from the registry or that do not
|
|
440
|
+
* list the model are omitted from the result.
|
|
441
|
+
*
|
|
442
|
+
* Use this subject instead of calling `getForProvider` in a loop — it
|
|
443
|
+
* collapses N sequential RPCs into a single bus request.
|
|
444
|
+
* @example
|
|
445
|
+
* ```typescript
|
|
446
|
+
* const { matches } = await bus.request(ModelRegistrySubjects.checkModelInProviders, {
|
|
447
|
+
* providerIds: ['anthropic', 'openrouter', 'z-ai'],
|
|
448
|
+
* model: 'claude-sonnet-4-6',
|
|
449
|
+
* });
|
|
450
|
+
* // matches: { anthropic: AIModel, openrouter: AIModel }
|
|
451
|
+
* ```
|
|
452
|
+
*/
|
|
453
|
+
checkModelInProviders: {
|
|
454
|
+
request: z.ZodObject<{
|
|
455
|
+
providerIds: z.ZodArray<z.ZodString>;
|
|
456
|
+
model: z.ZodString;
|
|
457
|
+
}, z.core.$strip>;
|
|
458
|
+
response: z.ZodObject<{
|
|
459
|
+
matches: z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
460
|
+
name: z.ZodString;
|
|
461
|
+
friendlyName: z.ZodOptional<z.ZodString>;
|
|
462
|
+
family: z.ZodOptional<z.ZodString>;
|
|
463
|
+
contextWindowSize: z.ZodNumber;
|
|
464
|
+
labId: z.ZodString;
|
|
465
|
+
supportedReasoningLevels: z.ZodOptional<z.ZodObject<{
|
|
466
|
+
none: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodString]>>;
|
|
467
|
+
low: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodString]>>;
|
|
468
|
+
medium: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodString]>>;
|
|
469
|
+
high: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodString]>>;
|
|
470
|
+
'extra-high': z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodString]>>;
|
|
471
|
+
}, z.core.$strip>>;
|
|
472
|
+
metadata: z.ZodOptional<z.ZodObject<{
|
|
473
|
+
maxOutputTokens: z.ZodOptional<z.ZodNumber>;
|
|
474
|
+
capabilities: z.ZodOptional<z.ZodObject<{
|
|
475
|
+
vision: z.ZodOptional<z.ZodBoolean>;
|
|
476
|
+
toolCalling: z.ZodOptional<z.ZodBoolean>;
|
|
477
|
+
parallelToolCalls: z.ZodOptional<z.ZodBoolean>;
|
|
478
|
+
structuredOutput: z.ZodOptional<z.ZodBoolean>;
|
|
479
|
+
pdfUpload: z.ZodOptional<z.ZodBoolean>;
|
|
480
|
+
speechToText: z.ZodOptional<z.ZodObject<{
|
|
481
|
+
modes: z.ZodArray<z.ZodEnum<{
|
|
482
|
+
batch: "batch";
|
|
483
|
+
streaming: "streaming";
|
|
484
|
+
}>>;
|
|
485
|
+
vocabularyBiasing: z.ZodOptional<z.ZodBoolean>;
|
|
486
|
+
}, z.core.$strip>>;
|
|
487
|
+
textToSpeech: z.ZodOptional<z.ZodObject<{
|
|
488
|
+
modes: z.ZodArray<z.ZodEnum<{
|
|
489
|
+
streaming: "streaming";
|
|
490
|
+
buffered: "buffered";
|
|
491
|
+
}>>;
|
|
492
|
+
voiceSelection: z.ZodOptional<z.ZodBoolean>;
|
|
493
|
+
voiceInstructions: z.ZodOptional<z.ZodBoolean>;
|
|
494
|
+
outputFormats: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
495
|
+
}, z.core.$strip>>;
|
|
496
|
+
}, z.core.$strip>>;
|
|
497
|
+
pricing: z.ZodOptional<z.ZodObject<{
|
|
498
|
+
token: z.ZodOptional<z.ZodObject<{
|
|
499
|
+
inputPerMillion: z.ZodNumber;
|
|
500
|
+
inputCachedPerMillion: z.ZodOptional<z.ZodNumber>;
|
|
501
|
+
cacheWritePerMillion: z.ZodOptional<z.ZodNumber>;
|
|
502
|
+
outputPerMillion: z.ZodNumber;
|
|
503
|
+
}, z.core.$strip>>;
|
|
504
|
+
request: z.ZodOptional<z.ZodObject<{
|
|
505
|
+
multiplier: z.ZodNumber;
|
|
506
|
+
}, z.core.$strip>>;
|
|
507
|
+
}, z.core.$strip>>;
|
|
508
|
+
includedInSubscription: z.ZodOptional<z.ZodBoolean>;
|
|
509
|
+
description: z.ZodOptional<z.ZodString>;
|
|
510
|
+
}, z.core.$strip>>;
|
|
511
|
+
}, z.core.$strip>>;
|
|
512
|
+
}, z.core.$strip>;
|
|
513
|
+
};
|
|
514
|
+
/**
|
|
515
|
+
* Broadcast that the registry has been refreshed and committed.
|
|
516
|
+
*
|
|
517
|
+
* Fire-and-forget event used by consumers that need to rescan registry-backed
|
|
518
|
+
* capabilities after a successful refresh.
|
|
519
|
+
*/
|
|
520
|
+
changed: z.ZodObject<{}, z.core.$strip>;
|
|
521
|
+
};
|
|
522
|
+
/**
|
|
523
|
+
* Type for modelRegistry.getForProvider request.
|
|
524
|
+
*/
|
|
525
|
+
type ModelRegistryGetForProviderRequest = z.infer<typeof ModelRegistrySchemas.getForProvider.request>;
|
|
526
|
+
/**
|
|
527
|
+
* Type for modelRegistry.getForProvider response.
|
|
528
|
+
*/
|
|
529
|
+
type ModelRegistryGetForProviderResponse = z.infer<typeof ModelRegistrySchemas.getForProvider.response>;
|
|
530
|
+
/**
|
|
531
|
+
* Type for modelRegistry.getLabModels request.
|
|
532
|
+
*/
|
|
533
|
+
type ModelRegistryGetLabModelsRequest = z.infer<typeof ModelRegistrySchemas.getLabModels.request>;
|
|
534
|
+
/**
|
|
535
|
+
* Type for modelRegistry.getLabModels response.
|
|
536
|
+
*/
|
|
537
|
+
type ModelRegistryGetLabModelsResponse = z.infer<typeof ModelRegistrySchemas.getLabModels.response>;
|
|
538
|
+
/**
|
|
539
|
+
* Type for modelRegistry.getProviderModels request.
|
|
540
|
+
*/
|
|
541
|
+
type ModelRegistryGetProviderModelsRequest = z.infer<typeof ModelRegistrySchemas.getProviderModels.request>;
|
|
542
|
+
/**
|
|
543
|
+
* Type for modelRegistry.getProviderModels response.
|
|
544
|
+
*/
|
|
545
|
+
type ModelRegistryGetProviderModelsResponse = z.infer<typeof ModelRegistrySchemas.getProviderModels.response>;
|
|
546
|
+
/**
|
|
547
|
+
* Type for modelRegistry.refresh request.
|
|
548
|
+
*/
|
|
549
|
+
type ModelRegistryRefreshRequest = z.infer<typeof ModelRegistrySchemas.refresh.request>;
|
|
550
|
+
/**
|
|
551
|
+
* Type for modelRegistry.refresh response.
|
|
552
|
+
*/
|
|
553
|
+
type ModelRegistryRefreshResponse = z.infer<typeof ModelRegistrySchemas.refresh.response>;
|
|
554
|
+
/**
|
|
555
|
+
* Type for modelRegistry.checkModelInProviders request.
|
|
556
|
+
*/
|
|
557
|
+
type ModelRegistryCheckModelInProvidersRequest = z.infer<typeof ModelRegistrySchemas.checkModelInProviders.request>;
|
|
558
|
+
/**
|
|
559
|
+
* Type for modelRegistry.checkModelInProviders response.
|
|
560
|
+
*/
|
|
561
|
+
type ModelRegistryCheckModelInProvidersResponse = z.infer<typeof ModelRegistrySchemas.checkModelInProviders.response>;
|
|
562
|
+
//#endregion
|
|
563
|
+
//#region services/core/src/model-registry/namespace.d.ts
|
|
564
|
+
/**
|
|
565
|
+
* Model Registry namespace for accessing model information.
|
|
566
|
+
*
|
|
567
|
+
* Provides bus subjects for:
|
|
568
|
+
* - Resolving a single model for a provider
|
|
569
|
+
* - Listing all models for a lab or provider
|
|
570
|
+
* - Refreshing registry from remote source
|
|
571
|
+
* - Observing registry refresh commits
|
|
572
|
+
*
|
|
573
|
+
* Prefix: 'modelRegistry.'
|
|
574
|
+
* @example
|
|
575
|
+
* ```typescript
|
|
576
|
+
* // Get all models for a provider
|
|
577
|
+
* const result = await bus.request(ModelRegistrySubjects.getProviderModels, {
|
|
578
|
+
* providerId: 'anthropic',
|
|
579
|
+
* });
|
|
580
|
+
*
|
|
581
|
+
* // Resolve a single model
|
|
582
|
+
* const resolved = await bus.request(ModelRegistrySubjects.getForProvider, {
|
|
583
|
+
* providerId: 'anthropic',
|
|
584
|
+
* model: 'claude-sonnet-4-6',
|
|
585
|
+
* });
|
|
586
|
+
*
|
|
587
|
+
* // Force refresh from remote
|
|
588
|
+
* await bus.request(ModelRegistrySubjects.refresh, {});
|
|
589
|
+
*
|
|
590
|
+
* // Observe committed refreshes
|
|
591
|
+
* bus.on(ModelRegistrySubjects.changed, () => {
|
|
592
|
+
* // Rescan dependent providers
|
|
593
|
+
* });
|
|
594
|
+
* ```
|
|
595
|
+
*/
|
|
596
|
+
declare const ModelRegistryNamespace: _$_makaio_core0.BusNamespaceDefinition<"modelRegistry", {
|
|
597
|
+
getForProvider: {
|
|
598
|
+
request: _$zod.ZodObject<{
|
|
599
|
+
providerId: _$zod.ZodString;
|
|
600
|
+
model: _$zod.ZodString;
|
|
601
|
+
}, _$zod_v4_core0.$strip>;
|
|
602
|
+
response: _$zod.ZodObject<{
|
|
603
|
+
model: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
604
|
+
name: _$zod.ZodString;
|
|
605
|
+
friendlyName: _$zod.ZodOptional<_$zod.ZodString>;
|
|
606
|
+
family: _$zod.ZodOptional<_$zod.ZodString>;
|
|
607
|
+
contextWindowSize: _$zod.ZodNumber;
|
|
608
|
+
labId: _$zod.ZodString;
|
|
609
|
+
supportedReasoningLevels: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
610
|
+
none: _$zod.ZodOptional<_$zod.ZodUnion<readonly [_$zod.ZodNumber, _$zod.ZodString]>>;
|
|
611
|
+
low: _$zod.ZodOptional<_$zod.ZodUnion<readonly [_$zod.ZodNumber, _$zod.ZodString]>>;
|
|
612
|
+
medium: _$zod.ZodOptional<_$zod.ZodUnion<readonly [_$zod.ZodNumber, _$zod.ZodString]>>;
|
|
613
|
+
high: _$zod.ZodOptional<_$zod.ZodUnion<readonly [_$zod.ZodNumber, _$zod.ZodString]>>;
|
|
614
|
+
'extra-high': _$zod.ZodOptional<_$zod.ZodUnion<readonly [_$zod.ZodNumber, _$zod.ZodString]>>;
|
|
615
|
+
}, _$zod_v4_core0.$strip>>;
|
|
616
|
+
metadata: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
617
|
+
maxOutputTokens: _$zod.ZodOptional<_$zod.ZodNumber>;
|
|
618
|
+
capabilities: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
619
|
+
vision: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
620
|
+
toolCalling: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
621
|
+
parallelToolCalls: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
622
|
+
structuredOutput: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
623
|
+
pdfUpload: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
624
|
+
speechToText: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
625
|
+
modes: _$zod.ZodArray<_$zod.ZodEnum<{
|
|
626
|
+
batch: "batch";
|
|
627
|
+
streaming: "streaming";
|
|
628
|
+
}>>;
|
|
629
|
+
vocabularyBiasing: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
630
|
+
}, _$zod_v4_core0.$strip>>;
|
|
631
|
+
textToSpeech: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
632
|
+
modes: _$zod.ZodArray<_$zod.ZodEnum<{
|
|
633
|
+
streaming: "streaming";
|
|
634
|
+
buffered: "buffered";
|
|
635
|
+
}>>;
|
|
636
|
+
voiceSelection: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
637
|
+
voiceInstructions: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
638
|
+
outputFormats: _$zod.ZodOptional<_$zod.ZodArray<_$zod.ZodString>>;
|
|
639
|
+
}, _$zod_v4_core0.$strip>>;
|
|
640
|
+
}, _$zod_v4_core0.$strip>>;
|
|
641
|
+
pricing: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
642
|
+
token: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
643
|
+
inputPerMillion: _$zod.ZodNumber;
|
|
644
|
+
inputCachedPerMillion: _$zod.ZodOptional<_$zod.ZodNumber>;
|
|
645
|
+
cacheWritePerMillion: _$zod.ZodOptional<_$zod.ZodNumber>;
|
|
646
|
+
outputPerMillion: _$zod.ZodNumber;
|
|
647
|
+
}, _$zod_v4_core0.$strip>>;
|
|
648
|
+
request: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
649
|
+
multiplier: _$zod.ZodNumber;
|
|
650
|
+
}, _$zod_v4_core0.$strip>>;
|
|
651
|
+
}, _$zod_v4_core0.$strip>>;
|
|
652
|
+
includedInSubscription: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
653
|
+
description: _$zod.ZodOptional<_$zod.ZodString>;
|
|
654
|
+
}, _$zod_v4_core0.$strip>>;
|
|
655
|
+
}, _$zod_v4_core0.$strip>>;
|
|
656
|
+
}, _$zod_v4_core0.$strip>;
|
|
657
|
+
};
|
|
658
|
+
getLabModels: {
|
|
659
|
+
request: _$zod.ZodObject<{
|
|
660
|
+
labId: _$zod.ZodString;
|
|
661
|
+
}, _$zod_v4_core0.$strip>;
|
|
662
|
+
response: _$zod.ZodObject<{
|
|
663
|
+
models: _$zod.ZodArray<_$zod.ZodObject<{
|
|
664
|
+
name: _$zod.ZodString;
|
|
665
|
+
friendlyName: _$zod.ZodOptional<_$zod.ZodString>;
|
|
666
|
+
family: _$zod.ZodOptional<_$zod.ZodString>;
|
|
667
|
+
contextWindowSize: _$zod.ZodNumber;
|
|
668
|
+
labId: _$zod.ZodString;
|
|
669
|
+
supportedReasoningLevels: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
670
|
+
none: _$zod.ZodOptional<_$zod.ZodUnion<readonly [_$zod.ZodNumber, _$zod.ZodString]>>;
|
|
671
|
+
low: _$zod.ZodOptional<_$zod.ZodUnion<readonly [_$zod.ZodNumber, _$zod.ZodString]>>;
|
|
672
|
+
medium: _$zod.ZodOptional<_$zod.ZodUnion<readonly [_$zod.ZodNumber, _$zod.ZodString]>>;
|
|
673
|
+
high: _$zod.ZodOptional<_$zod.ZodUnion<readonly [_$zod.ZodNumber, _$zod.ZodString]>>;
|
|
674
|
+
'extra-high': _$zod.ZodOptional<_$zod.ZodUnion<readonly [_$zod.ZodNumber, _$zod.ZodString]>>;
|
|
675
|
+
}, _$zod_v4_core0.$strip>>;
|
|
676
|
+
metadata: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
677
|
+
maxOutputTokens: _$zod.ZodOptional<_$zod.ZodNumber>;
|
|
678
|
+
capabilities: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
679
|
+
vision: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
680
|
+
toolCalling: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
681
|
+
parallelToolCalls: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
682
|
+
structuredOutput: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
683
|
+
pdfUpload: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
684
|
+
speechToText: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
685
|
+
modes: _$zod.ZodArray<_$zod.ZodEnum<{
|
|
686
|
+
batch: "batch";
|
|
687
|
+
streaming: "streaming";
|
|
688
|
+
}>>;
|
|
689
|
+
vocabularyBiasing: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
690
|
+
}, _$zod_v4_core0.$strip>>;
|
|
691
|
+
textToSpeech: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
692
|
+
modes: _$zod.ZodArray<_$zod.ZodEnum<{
|
|
693
|
+
streaming: "streaming";
|
|
694
|
+
buffered: "buffered";
|
|
695
|
+
}>>;
|
|
696
|
+
voiceSelection: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
697
|
+
voiceInstructions: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
698
|
+
outputFormats: _$zod.ZodOptional<_$zod.ZodArray<_$zod.ZodString>>;
|
|
699
|
+
}, _$zod_v4_core0.$strip>>;
|
|
700
|
+
}, _$zod_v4_core0.$strip>>;
|
|
701
|
+
pricing: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
702
|
+
token: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
703
|
+
inputPerMillion: _$zod.ZodNumber;
|
|
704
|
+
inputCachedPerMillion: _$zod.ZodOptional<_$zod.ZodNumber>;
|
|
705
|
+
cacheWritePerMillion: _$zod.ZodOptional<_$zod.ZodNumber>;
|
|
706
|
+
outputPerMillion: _$zod.ZodNumber;
|
|
707
|
+
}, _$zod_v4_core0.$strip>>;
|
|
708
|
+
request: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
709
|
+
multiplier: _$zod.ZodNumber;
|
|
710
|
+
}, _$zod_v4_core0.$strip>>;
|
|
711
|
+
}, _$zod_v4_core0.$strip>>;
|
|
712
|
+
includedInSubscription: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
713
|
+
description: _$zod.ZodOptional<_$zod.ZodString>;
|
|
714
|
+
}, _$zod_v4_core0.$strip>>;
|
|
715
|
+
}, _$zod_v4_core0.$strip>>;
|
|
716
|
+
}, _$zod_v4_core0.$strip>;
|
|
717
|
+
};
|
|
718
|
+
getProviderModels: {
|
|
719
|
+
request: _$zod.ZodObject<{
|
|
720
|
+
providerId: _$zod.ZodString;
|
|
721
|
+
}, _$zod_v4_core0.$strip>;
|
|
722
|
+
response: _$zod.ZodObject<{
|
|
723
|
+
models: _$zod.ZodArray<_$zod.ZodObject<{
|
|
724
|
+
name: _$zod.ZodString;
|
|
725
|
+
friendlyName: _$zod.ZodOptional<_$zod.ZodString>;
|
|
726
|
+
family: _$zod.ZodOptional<_$zod.ZodString>;
|
|
727
|
+
contextWindowSize: _$zod.ZodNumber;
|
|
728
|
+
labId: _$zod.ZodString;
|
|
729
|
+
supportedReasoningLevels: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
730
|
+
none: _$zod.ZodOptional<_$zod.ZodUnion<readonly [_$zod.ZodNumber, _$zod.ZodString]>>;
|
|
731
|
+
low: _$zod.ZodOptional<_$zod.ZodUnion<readonly [_$zod.ZodNumber, _$zod.ZodString]>>;
|
|
732
|
+
medium: _$zod.ZodOptional<_$zod.ZodUnion<readonly [_$zod.ZodNumber, _$zod.ZodString]>>;
|
|
733
|
+
high: _$zod.ZodOptional<_$zod.ZodUnion<readonly [_$zod.ZodNumber, _$zod.ZodString]>>;
|
|
734
|
+
'extra-high': _$zod.ZodOptional<_$zod.ZodUnion<readonly [_$zod.ZodNumber, _$zod.ZodString]>>;
|
|
735
|
+
}, _$zod_v4_core0.$strip>>;
|
|
736
|
+
metadata: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
737
|
+
maxOutputTokens: _$zod.ZodOptional<_$zod.ZodNumber>;
|
|
738
|
+
capabilities: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
739
|
+
vision: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
740
|
+
toolCalling: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
741
|
+
parallelToolCalls: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
742
|
+
structuredOutput: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
743
|
+
pdfUpload: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
744
|
+
speechToText: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
745
|
+
modes: _$zod.ZodArray<_$zod.ZodEnum<{
|
|
746
|
+
batch: "batch";
|
|
747
|
+
streaming: "streaming";
|
|
748
|
+
}>>;
|
|
749
|
+
vocabularyBiasing: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
750
|
+
}, _$zod_v4_core0.$strip>>;
|
|
751
|
+
textToSpeech: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
752
|
+
modes: _$zod.ZodArray<_$zod.ZodEnum<{
|
|
753
|
+
streaming: "streaming";
|
|
754
|
+
buffered: "buffered";
|
|
755
|
+
}>>;
|
|
756
|
+
voiceSelection: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
757
|
+
voiceInstructions: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
758
|
+
outputFormats: _$zod.ZodOptional<_$zod.ZodArray<_$zod.ZodString>>;
|
|
759
|
+
}, _$zod_v4_core0.$strip>>;
|
|
760
|
+
}, _$zod_v4_core0.$strip>>;
|
|
761
|
+
pricing: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
762
|
+
token: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
763
|
+
inputPerMillion: _$zod.ZodNumber;
|
|
764
|
+
inputCachedPerMillion: _$zod.ZodOptional<_$zod.ZodNumber>;
|
|
765
|
+
cacheWritePerMillion: _$zod.ZodOptional<_$zod.ZodNumber>;
|
|
766
|
+
outputPerMillion: _$zod.ZodNumber;
|
|
767
|
+
}, _$zod_v4_core0.$strip>>;
|
|
768
|
+
request: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
769
|
+
multiplier: _$zod.ZodNumber;
|
|
770
|
+
}, _$zod_v4_core0.$strip>>;
|
|
771
|
+
}, _$zod_v4_core0.$strip>>;
|
|
772
|
+
includedInSubscription: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
773
|
+
description: _$zod.ZodOptional<_$zod.ZodString>;
|
|
774
|
+
}, _$zod_v4_core0.$strip>>;
|
|
775
|
+
}, _$zod_v4_core0.$strip>>;
|
|
776
|
+
}, _$zod_v4_core0.$strip>;
|
|
777
|
+
};
|
|
778
|
+
refresh: {
|
|
779
|
+
request: _$zod.ZodObject<{}, _$zod_v4_core0.$strip>;
|
|
780
|
+
response: _$zod.ZodObject<{
|
|
781
|
+
success: _$zod.ZodBoolean;
|
|
782
|
+
error: _$zod.ZodOptional<_$zod.ZodString>;
|
|
783
|
+
}, _$zod_v4_core0.$strip>;
|
|
784
|
+
};
|
|
785
|
+
checkModelInProviders: {
|
|
786
|
+
request: _$zod.ZodObject<{
|
|
787
|
+
providerIds: _$zod.ZodArray<_$zod.ZodString>;
|
|
788
|
+
model: _$zod.ZodString;
|
|
789
|
+
}, _$zod_v4_core0.$strip>;
|
|
790
|
+
response: _$zod.ZodObject<{
|
|
791
|
+
matches: _$zod.ZodRecord<_$zod.ZodString, _$zod.ZodObject<{
|
|
792
|
+
name: _$zod.ZodString;
|
|
793
|
+
friendlyName: _$zod.ZodOptional<_$zod.ZodString>;
|
|
794
|
+
family: _$zod.ZodOptional<_$zod.ZodString>;
|
|
795
|
+
contextWindowSize: _$zod.ZodNumber;
|
|
796
|
+
labId: _$zod.ZodString;
|
|
797
|
+
supportedReasoningLevels: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
798
|
+
none: _$zod.ZodOptional<_$zod.ZodUnion<readonly [_$zod.ZodNumber, _$zod.ZodString]>>;
|
|
799
|
+
low: _$zod.ZodOptional<_$zod.ZodUnion<readonly [_$zod.ZodNumber, _$zod.ZodString]>>;
|
|
800
|
+
medium: _$zod.ZodOptional<_$zod.ZodUnion<readonly [_$zod.ZodNumber, _$zod.ZodString]>>;
|
|
801
|
+
high: _$zod.ZodOptional<_$zod.ZodUnion<readonly [_$zod.ZodNumber, _$zod.ZodString]>>;
|
|
802
|
+
'extra-high': _$zod.ZodOptional<_$zod.ZodUnion<readonly [_$zod.ZodNumber, _$zod.ZodString]>>;
|
|
803
|
+
}, _$zod_v4_core0.$strip>>;
|
|
804
|
+
metadata: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
805
|
+
maxOutputTokens: _$zod.ZodOptional<_$zod.ZodNumber>;
|
|
806
|
+
capabilities: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
807
|
+
vision: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
808
|
+
toolCalling: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
809
|
+
parallelToolCalls: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
810
|
+
structuredOutput: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
811
|
+
pdfUpload: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
812
|
+
speechToText: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
813
|
+
modes: _$zod.ZodArray<_$zod.ZodEnum<{
|
|
814
|
+
batch: "batch";
|
|
815
|
+
streaming: "streaming";
|
|
816
|
+
}>>;
|
|
817
|
+
vocabularyBiasing: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
818
|
+
}, _$zod_v4_core0.$strip>>;
|
|
819
|
+
textToSpeech: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
820
|
+
modes: _$zod.ZodArray<_$zod.ZodEnum<{
|
|
821
|
+
streaming: "streaming";
|
|
822
|
+
buffered: "buffered";
|
|
823
|
+
}>>;
|
|
824
|
+
voiceSelection: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
825
|
+
voiceInstructions: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
826
|
+
outputFormats: _$zod.ZodOptional<_$zod.ZodArray<_$zod.ZodString>>;
|
|
827
|
+
}, _$zod_v4_core0.$strip>>;
|
|
828
|
+
}, _$zod_v4_core0.$strip>>;
|
|
829
|
+
pricing: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
830
|
+
token: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
831
|
+
inputPerMillion: _$zod.ZodNumber;
|
|
832
|
+
inputCachedPerMillion: _$zod.ZodOptional<_$zod.ZodNumber>;
|
|
833
|
+
cacheWritePerMillion: _$zod.ZodOptional<_$zod.ZodNumber>;
|
|
834
|
+
outputPerMillion: _$zod.ZodNumber;
|
|
835
|
+
}, _$zod_v4_core0.$strip>>;
|
|
836
|
+
request: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
837
|
+
multiplier: _$zod.ZodNumber;
|
|
838
|
+
}, _$zod_v4_core0.$strip>>;
|
|
839
|
+
}, _$zod_v4_core0.$strip>>;
|
|
840
|
+
includedInSubscription: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
841
|
+
description: _$zod.ZodOptional<_$zod.ZodString>;
|
|
842
|
+
}, _$zod_v4_core0.$strip>>;
|
|
843
|
+
}, _$zod_v4_core0.$strip>>;
|
|
844
|
+
}, _$zod_v4_core0.$strip>;
|
|
845
|
+
};
|
|
846
|
+
changed: _$zod.ZodObject<{}, _$zod_v4_core0.$strip>;
|
|
847
|
+
}>;
|
|
848
|
+
/**
|
|
849
|
+
* Pre-extracted subjects for direct import.
|
|
850
|
+
* @example
|
|
851
|
+
* ```typescript
|
|
852
|
+
* import { ModelRegistrySubjects } from '@makaio/framework/services/model-registry';
|
|
853
|
+
*
|
|
854
|
+
* bus.on(ModelRegistrySubjects.getProviderModels, (ctx) => {
|
|
855
|
+
* ctx.setResult({ models: resolveModels(ctx.payload.providerId) });
|
|
856
|
+
* });
|
|
857
|
+
* ```
|
|
858
|
+
*/
|
|
859
|
+
declare const ModelRegistrySubjects: _$_makaio_core0.BusSubjects<_$_makaio_core0.FlatSubjectDefinitions<"modelRegistry", {
|
|
860
|
+
getForProvider: {
|
|
861
|
+
request: _$zod.ZodObject<{
|
|
862
|
+
providerId: _$zod.ZodString;
|
|
863
|
+
model: _$zod.ZodString;
|
|
864
|
+
}, _$zod_v4_core0.$strip>;
|
|
865
|
+
response: _$zod.ZodObject<{
|
|
866
|
+
model: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
867
|
+
name: _$zod.ZodString;
|
|
868
|
+
friendlyName: _$zod.ZodOptional<_$zod.ZodString>;
|
|
869
|
+
family: _$zod.ZodOptional<_$zod.ZodString>;
|
|
870
|
+
contextWindowSize: _$zod.ZodNumber;
|
|
871
|
+
labId: _$zod.ZodString;
|
|
872
|
+
supportedReasoningLevels: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
873
|
+
none: _$zod.ZodOptional<_$zod.ZodUnion<readonly [_$zod.ZodNumber, _$zod.ZodString]>>;
|
|
874
|
+
low: _$zod.ZodOptional<_$zod.ZodUnion<readonly [_$zod.ZodNumber, _$zod.ZodString]>>;
|
|
875
|
+
medium: _$zod.ZodOptional<_$zod.ZodUnion<readonly [_$zod.ZodNumber, _$zod.ZodString]>>;
|
|
876
|
+
high: _$zod.ZodOptional<_$zod.ZodUnion<readonly [_$zod.ZodNumber, _$zod.ZodString]>>;
|
|
877
|
+
'extra-high': _$zod.ZodOptional<_$zod.ZodUnion<readonly [_$zod.ZodNumber, _$zod.ZodString]>>;
|
|
878
|
+
}, _$zod_v4_core0.$strip>>;
|
|
879
|
+
metadata: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
880
|
+
maxOutputTokens: _$zod.ZodOptional<_$zod.ZodNumber>;
|
|
881
|
+
capabilities: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
882
|
+
vision: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
883
|
+
toolCalling: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
884
|
+
parallelToolCalls: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
885
|
+
structuredOutput: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
886
|
+
pdfUpload: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
887
|
+
speechToText: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
888
|
+
modes: _$zod.ZodArray<_$zod.ZodEnum<{
|
|
889
|
+
batch: "batch";
|
|
890
|
+
streaming: "streaming";
|
|
891
|
+
}>>;
|
|
892
|
+
vocabularyBiasing: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
893
|
+
}, _$zod_v4_core0.$strip>>;
|
|
894
|
+
textToSpeech: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
895
|
+
modes: _$zod.ZodArray<_$zod.ZodEnum<{
|
|
896
|
+
streaming: "streaming";
|
|
897
|
+
buffered: "buffered";
|
|
898
|
+
}>>;
|
|
899
|
+
voiceSelection: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
900
|
+
voiceInstructions: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
901
|
+
outputFormats: _$zod.ZodOptional<_$zod.ZodArray<_$zod.ZodString>>;
|
|
902
|
+
}, _$zod_v4_core0.$strip>>;
|
|
903
|
+
}, _$zod_v4_core0.$strip>>;
|
|
904
|
+
pricing: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
905
|
+
token: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
906
|
+
inputPerMillion: _$zod.ZodNumber;
|
|
907
|
+
inputCachedPerMillion: _$zod.ZodOptional<_$zod.ZodNumber>;
|
|
908
|
+
cacheWritePerMillion: _$zod.ZodOptional<_$zod.ZodNumber>;
|
|
909
|
+
outputPerMillion: _$zod.ZodNumber;
|
|
910
|
+
}, _$zod_v4_core0.$strip>>;
|
|
911
|
+
request: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
912
|
+
multiplier: _$zod.ZodNumber;
|
|
913
|
+
}, _$zod_v4_core0.$strip>>;
|
|
914
|
+
}, _$zod_v4_core0.$strip>>;
|
|
915
|
+
includedInSubscription: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
916
|
+
description: _$zod.ZodOptional<_$zod.ZodString>;
|
|
917
|
+
}, _$zod_v4_core0.$strip>>;
|
|
918
|
+
}, _$zod_v4_core0.$strip>>;
|
|
919
|
+
}, _$zod_v4_core0.$strip>;
|
|
920
|
+
};
|
|
921
|
+
getLabModels: {
|
|
922
|
+
request: _$zod.ZodObject<{
|
|
923
|
+
labId: _$zod.ZodString;
|
|
924
|
+
}, _$zod_v4_core0.$strip>;
|
|
925
|
+
response: _$zod.ZodObject<{
|
|
926
|
+
models: _$zod.ZodArray<_$zod.ZodObject<{
|
|
927
|
+
name: _$zod.ZodString;
|
|
928
|
+
friendlyName: _$zod.ZodOptional<_$zod.ZodString>;
|
|
929
|
+
family: _$zod.ZodOptional<_$zod.ZodString>;
|
|
930
|
+
contextWindowSize: _$zod.ZodNumber;
|
|
931
|
+
labId: _$zod.ZodString;
|
|
932
|
+
supportedReasoningLevels: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
933
|
+
none: _$zod.ZodOptional<_$zod.ZodUnion<readonly [_$zod.ZodNumber, _$zod.ZodString]>>;
|
|
934
|
+
low: _$zod.ZodOptional<_$zod.ZodUnion<readonly [_$zod.ZodNumber, _$zod.ZodString]>>;
|
|
935
|
+
medium: _$zod.ZodOptional<_$zod.ZodUnion<readonly [_$zod.ZodNumber, _$zod.ZodString]>>;
|
|
936
|
+
high: _$zod.ZodOptional<_$zod.ZodUnion<readonly [_$zod.ZodNumber, _$zod.ZodString]>>;
|
|
937
|
+
'extra-high': _$zod.ZodOptional<_$zod.ZodUnion<readonly [_$zod.ZodNumber, _$zod.ZodString]>>;
|
|
938
|
+
}, _$zod_v4_core0.$strip>>;
|
|
939
|
+
metadata: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
940
|
+
maxOutputTokens: _$zod.ZodOptional<_$zod.ZodNumber>;
|
|
941
|
+
capabilities: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
942
|
+
vision: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
943
|
+
toolCalling: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
944
|
+
parallelToolCalls: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
945
|
+
structuredOutput: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
946
|
+
pdfUpload: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
947
|
+
speechToText: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
948
|
+
modes: _$zod.ZodArray<_$zod.ZodEnum<{
|
|
949
|
+
batch: "batch";
|
|
950
|
+
streaming: "streaming";
|
|
951
|
+
}>>;
|
|
952
|
+
vocabularyBiasing: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
953
|
+
}, _$zod_v4_core0.$strip>>;
|
|
954
|
+
textToSpeech: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
955
|
+
modes: _$zod.ZodArray<_$zod.ZodEnum<{
|
|
956
|
+
streaming: "streaming";
|
|
957
|
+
buffered: "buffered";
|
|
958
|
+
}>>;
|
|
959
|
+
voiceSelection: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
960
|
+
voiceInstructions: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
961
|
+
outputFormats: _$zod.ZodOptional<_$zod.ZodArray<_$zod.ZodString>>;
|
|
962
|
+
}, _$zod_v4_core0.$strip>>;
|
|
963
|
+
}, _$zod_v4_core0.$strip>>;
|
|
964
|
+
pricing: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
965
|
+
token: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
966
|
+
inputPerMillion: _$zod.ZodNumber;
|
|
967
|
+
inputCachedPerMillion: _$zod.ZodOptional<_$zod.ZodNumber>;
|
|
968
|
+
cacheWritePerMillion: _$zod.ZodOptional<_$zod.ZodNumber>;
|
|
969
|
+
outputPerMillion: _$zod.ZodNumber;
|
|
970
|
+
}, _$zod_v4_core0.$strip>>;
|
|
971
|
+
request: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
972
|
+
multiplier: _$zod.ZodNumber;
|
|
973
|
+
}, _$zod_v4_core0.$strip>>;
|
|
974
|
+
}, _$zod_v4_core0.$strip>>;
|
|
975
|
+
includedInSubscription: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
976
|
+
description: _$zod.ZodOptional<_$zod.ZodString>;
|
|
977
|
+
}, _$zod_v4_core0.$strip>>;
|
|
978
|
+
}, _$zod_v4_core0.$strip>>;
|
|
979
|
+
}, _$zod_v4_core0.$strip>;
|
|
980
|
+
};
|
|
981
|
+
getProviderModels: {
|
|
982
|
+
request: _$zod.ZodObject<{
|
|
983
|
+
providerId: _$zod.ZodString;
|
|
984
|
+
}, _$zod_v4_core0.$strip>;
|
|
985
|
+
response: _$zod.ZodObject<{
|
|
986
|
+
models: _$zod.ZodArray<_$zod.ZodObject<{
|
|
987
|
+
name: _$zod.ZodString;
|
|
988
|
+
friendlyName: _$zod.ZodOptional<_$zod.ZodString>;
|
|
989
|
+
family: _$zod.ZodOptional<_$zod.ZodString>;
|
|
990
|
+
contextWindowSize: _$zod.ZodNumber;
|
|
991
|
+
labId: _$zod.ZodString;
|
|
992
|
+
supportedReasoningLevels: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
993
|
+
none: _$zod.ZodOptional<_$zod.ZodUnion<readonly [_$zod.ZodNumber, _$zod.ZodString]>>;
|
|
994
|
+
low: _$zod.ZodOptional<_$zod.ZodUnion<readonly [_$zod.ZodNumber, _$zod.ZodString]>>;
|
|
995
|
+
medium: _$zod.ZodOptional<_$zod.ZodUnion<readonly [_$zod.ZodNumber, _$zod.ZodString]>>;
|
|
996
|
+
high: _$zod.ZodOptional<_$zod.ZodUnion<readonly [_$zod.ZodNumber, _$zod.ZodString]>>;
|
|
997
|
+
'extra-high': _$zod.ZodOptional<_$zod.ZodUnion<readonly [_$zod.ZodNumber, _$zod.ZodString]>>;
|
|
998
|
+
}, _$zod_v4_core0.$strip>>;
|
|
999
|
+
metadata: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
1000
|
+
maxOutputTokens: _$zod.ZodOptional<_$zod.ZodNumber>;
|
|
1001
|
+
capabilities: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
1002
|
+
vision: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
1003
|
+
toolCalling: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
1004
|
+
parallelToolCalls: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
1005
|
+
structuredOutput: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
1006
|
+
pdfUpload: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
1007
|
+
speechToText: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
1008
|
+
modes: _$zod.ZodArray<_$zod.ZodEnum<{
|
|
1009
|
+
batch: "batch";
|
|
1010
|
+
streaming: "streaming";
|
|
1011
|
+
}>>;
|
|
1012
|
+
vocabularyBiasing: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
1013
|
+
}, _$zod_v4_core0.$strip>>;
|
|
1014
|
+
textToSpeech: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
1015
|
+
modes: _$zod.ZodArray<_$zod.ZodEnum<{
|
|
1016
|
+
streaming: "streaming";
|
|
1017
|
+
buffered: "buffered";
|
|
1018
|
+
}>>;
|
|
1019
|
+
voiceSelection: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
1020
|
+
voiceInstructions: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
1021
|
+
outputFormats: _$zod.ZodOptional<_$zod.ZodArray<_$zod.ZodString>>;
|
|
1022
|
+
}, _$zod_v4_core0.$strip>>;
|
|
1023
|
+
}, _$zod_v4_core0.$strip>>;
|
|
1024
|
+
pricing: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
1025
|
+
token: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
1026
|
+
inputPerMillion: _$zod.ZodNumber;
|
|
1027
|
+
inputCachedPerMillion: _$zod.ZodOptional<_$zod.ZodNumber>;
|
|
1028
|
+
cacheWritePerMillion: _$zod.ZodOptional<_$zod.ZodNumber>;
|
|
1029
|
+
outputPerMillion: _$zod.ZodNumber;
|
|
1030
|
+
}, _$zod_v4_core0.$strip>>;
|
|
1031
|
+
request: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
1032
|
+
multiplier: _$zod.ZodNumber;
|
|
1033
|
+
}, _$zod_v4_core0.$strip>>;
|
|
1034
|
+
}, _$zod_v4_core0.$strip>>;
|
|
1035
|
+
includedInSubscription: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
1036
|
+
description: _$zod.ZodOptional<_$zod.ZodString>;
|
|
1037
|
+
}, _$zod_v4_core0.$strip>>;
|
|
1038
|
+
}, _$zod_v4_core0.$strip>>;
|
|
1039
|
+
}, _$zod_v4_core0.$strip>;
|
|
1040
|
+
};
|
|
1041
|
+
refresh: {
|
|
1042
|
+
request: _$zod.ZodObject<{}, _$zod_v4_core0.$strip>;
|
|
1043
|
+
response: _$zod.ZodObject<{
|
|
1044
|
+
success: _$zod.ZodBoolean;
|
|
1045
|
+
error: _$zod.ZodOptional<_$zod.ZodString>;
|
|
1046
|
+
}, _$zod_v4_core0.$strip>;
|
|
1047
|
+
};
|
|
1048
|
+
checkModelInProviders: {
|
|
1049
|
+
request: _$zod.ZodObject<{
|
|
1050
|
+
providerIds: _$zod.ZodArray<_$zod.ZodString>;
|
|
1051
|
+
model: _$zod.ZodString;
|
|
1052
|
+
}, _$zod_v4_core0.$strip>;
|
|
1053
|
+
response: _$zod.ZodObject<{
|
|
1054
|
+
matches: _$zod.ZodRecord<_$zod.ZodString, _$zod.ZodObject<{
|
|
1055
|
+
name: _$zod.ZodString;
|
|
1056
|
+
friendlyName: _$zod.ZodOptional<_$zod.ZodString>;
|
|
1057
|
+
family: _$zod.ZodOptional<_$zod.ZodString>;
|
|
1058
|
+
contextWindowSize: _$zod.ZodNumber;
|
|
1059
|
+
labId: _$zod.ZodString;
|
|
1060
|
+
supportedReasoningLevels: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
1061
|
+
none: _$zod.ZodOptional<_$zod.ZodUnion<readonly [_$zod.ZodNumber, _$zod.ZodString]>>;
|
|
1062
|
+
low: _$zod.ZodOptional<_$zod.ZodUnion<readonly [_$zod.ZodNumber, _$zod.ZodString]>>;
|
|
1063
|
+
medium: _$zod.ZodOptional<_$zod.ZodUnion<readonly [_$zod.ZodNumber, _$zod.ZodString]>>;
|
|
1064
|
+
high: _$zod.ZodOptional<_$zod.ZodUnion<readonly [_$zod.ZodNumber, _$zod.ZodString]>>;
|
|
1065
|
+
'extra-high': _$zod.ZodOptional<_$zod.ZodUnion<readonly [_$zod.ZodNumber, _$zod.ZodString]>>;
|
|
1066
|
+
}, _$zod_v4_core0.$strip>>;
|
|
1067
|
+
metadata: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
1068
|
+
maxOutputTokens: _$zod.ZodOptional<_$zod.ZodNumber>;
|
|
1069
|
+
capabilities: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
1070
|
+
vision: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
1071
|
+
toolCalling: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
1072
|
+
parallelToolCalls: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
1073
|
+
structuredOutput: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
1074
|
+
pdfUpload: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
1075
|
+
speechToText: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
1076
|
+
modes: _$zod.ZodArray<_$zod.ZodEnum<{
|
|
1077
|
+
batch: "batch";
|
|
1078
|
+
streaming: "streaming";
|
|
1079
|
+
}>>;
|
|
1080
|
+
vocabularyBiasing: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
1081
|
+
}, _$zod_v4_core0.$strip>>;
|
|
1082
|
+
textToSpeech: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
1083
|
+
modes: _$zod.ZodArray<_$zod.ZodEnum<{
|
|
1084
|
+
streaming: "streaming";
|
|
1085
|
+
buffered: "buffered";
|
|
1086
|
+
}>>;
|
|
1087
|
+
voiceSelection: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
1088
|
+
voiceInstructions: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
1089
|
+
outputFormats: _$zod.ZodOptional<_$zod.ZodArray<_$zod.ZodString>>;
|
|
1090
|
+
}, _$zod_v4_core0.$strip>>;
|
|
1091
|
+
}, _$zod_v4_core0.$strip>>;
|
|
1092
|
+
pricing: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
1093
|
+
token: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
1094
|
+
inputPerMillion: _$zod.ZodNumber;
|
|
1095
|
+
inputCachedPerMillion: _$zod.ZodOptional<_$zod.ZodNumber>;
|
|
1096
|
+
cacheWritePerMillion: _$zod.ZodOptional<_$zod.ZodNumber>;
|
|
1097
|
+
outputPerMillion: _$zod.ZodNumber;
|
|
1098
|
+
}, _$zod_v4_core0.$strip>>;
|
|
1099
|
+
request: _$zod.ZodOptional<_$zod.ZodObject<{
|
|
1100
|
+
multiplier: _$zod.ZodNumber;
|
|
1101
|
+
}, _$zod_v4_core0.$strip>>;
|
|
1102
|
+
}, _$zod_v4_core0.$strip>>;
|
|
1103
|
+
includedInSubscription: _$zod.ZodOptional<_$zod.ZodBoolean>;
|
|
1104
|
+
description: _$zod.ZodOptional<_$zod.ZodString>;
|
|
1105
|
+
}, _$zod_v4_core0.$strip>>;
|
|
1106
|
+
}, _$zod_v4_core0.$strip>>;
|
|
1107
|
+
}, _$zod_v4_core0.$strip>;
|
|
1108
|
+
};
|
|
1109
|
+
changed: _$zod.ZodObject<{}, _$zod_v4_core0.$strip>;
|
|
1110
|
+
}>, "modelRegistry">;
|
|
1111
|
+
//#endregion
|
|
1112
|
+
//#region services/core/src/model-registry/types.d.ts
|
|
1113
|
+
/**
|
|
1114
|
+
* Storage interface for model registry cache persistence.
|
|
1115
|
+
*
|
|
1116
|
+
* Allows for different implementations across environments:
|
|
1117
|
+
* - Browser: localStorage
|
|
1118
|
+
* - Node.js: File system cache
|
|
1119
|
+
* - Testing: In-memory cache
|
|
1120
|
+
* @example Browser localStorage implementation
|
|
1121
|
+
* ```typescript
|
|
1122
|
+
* class LocalStorageRegistryCache implements IModelRegistryCache {
|
|
1123
|
+
* async get(): Promise<ModelRegistry | null> {
|
|
1124
|
+
* const data = localStorage.getItem('makaio:model-registry');
|
|
1125
|
+
* return data ? JSON.parse(data) : null;
|
|
1126
|
+
* }
|
|
1127
|
+
*
|
|
1128
|
+
* async set(registry: ModelRegistry): Promise<void> {
|
|
1129
|
+
* localStorage.setItem('makaio:model-registry', JSON.stringify(registry));
|
|
1130
|
+
* }
|
|
1131
|
+
* }
|
|
1132
|
+
* ```
|
|
1133
|
+
* @example Node.js file-based implementation
|
|
1134
|
+
* ```typescript
|
|
1135
|
+
* class FileRegistryCache implements IModelRegistryCache {
|
|
1136
|
+
* async get(): Promise<ModelRegistry | null> {
|
|
1137
|
+
* try {
|
|
1138
|
+
* const content = await fs.readFile('~/.makaio/cache/model-registry.json', 'utf-8');
|
|
1139
|
+
* return JSON.parse(content);
|
|
1140
|
+
* } catch {
|
|
1141
|
+
* return null;
|
|
1142
|
+
* }
|
|
1143
|
+
* }
|
|
1144
|
+
*
|
|
1145
|
+
* async set(registry: ModelRegistry): Promise<void> {
|
|
1146
|
+
* await fs.writeFile('~/.makaio/cache/model-registry.json', JSON.stringify(registry));
|
|
1147
|
+
* }
|
|
1148
|
+
* }
|
|
1149
|
+
* ```
|
|
1150
|
+
*/
|
|
1151
|
+
interface IModelRegistryCache {
|
|
1152
|
+
/**
|
|
1153
|
+
* Get the cached model registry.
|
|
1154
|
+
* @returns The cached registry, or null if not cached
|
|
1155
|
+
*/
|
|
1156
|
+
get(): Promise<ModelRegistry | null>;
|
|
1157
|
+
/**
|
|
1158
|
+
* Save the model registry to cache.
|
|
1159
|
+
* @param registry - The registry to cache
|
|
1160
|
+
*/
|
|
1161
|
+
set(registry: ModelRegistry): Promise<void>;
|
|
1162
|
+
}
|
|
1163
|
+
/**
|
|
1164
|
+
* Interface for fetching the model registry from a source.
|
|
1165
|
+
*
|
|
1166
|
+
* Allows for different fetch implementations:
|
|
1167
|
+
* - CDN/HTTP fetch (browser/Node)
|
|
1168
|
+
* - Local YAML files
|
|
1169
|
+
* - Bundled seed
|
|
1170
|
+
* - Testing: Mock fetch
|
|
1171
|
+
* @example CDN fetch implementation
|
|
1172
|
+
* ```typescript
|
|
1173
|
+
* class CdnRegistryFetcher implements IModelRegistryFetcher {
|
|
1174
|
+
* constructor(private readonly registryUrl: string) {}
|
|
1175
|
+
*
|
|
1176
|
+
* async fetch(): Promise<ModelRegistry> {
|
|
1177
|
+
* const response = await fetch(this.registryUrl);
|
|
1178
|
+
* if (!response.ok) {
|
|
1179
|
+
* throw new Error(`Failed to fetch registry: ${response.statusText}`);
|
|
1180
|
+
* }
|
|
1181
|
+
* return parseYaml(await response.text()) as ModelRegistry;
|
|
1182
|
+
* }
|
|
1183
|
+
* }
|
|
1184
|
+
* ```
|
|
1185
|
+
*/
|
|
1186
|
+
interface IModelRegistryFetcher {
|
|
1187
|
+
/**
|
|
1188
|
+
* Fetch the model registry from a source.
|
|
1189
|
+
*
|
|
1190
|
+
* Implementations MUST return the result of `ModelRegistrySchema.parse()` —
|
|
1191
|
+
* i.e., a fully validated {@link ModelRegistry}. The service layer trusts
|
|
1192
|
+
* the returned value directly and does not re-validate it, so schema
|
|
1193
|
+
* validation (including the `superRefine` cross-validation) is the
|
|
1194
|
+
* responsibility of the fetcher implementation.
|
|
1195
|
+
* @returns The validated model registry
|
|
1196
|
+
* @throws Error if fetch fails or schema validation fails
|
|
1197
|
+
*/
|
|
1198
|
+
fetch(): Promise<ModelRegistry>;
|
|
1199
|
+
}
|
|
1200
|
+
//#endregion
|
|
1201
|
+
//#region services/core/src/model-registry/model-registry-service.d.ts
|
|
1202
|
+
/**
|
|
1203
|
+
* Options for creating a ModelRegistryService instance.
|
|
1204
|
+
*/
|
|
1205
|
+
interface ModelRegistryServiceOptions {
|
|
1206
|
+
/**
|
|
1207
|
+
* The bus instance for registering handlers.
|
|
1208
|
+
*/
|
|
1209
|
+
bus: IMakaioBus;
|
|
1210
|
+
/**
|
|
1211
|
+
* Fetcher implementation for retrieving the registry.
|
|
1212
|
+
*
|
|
1213
|
+
* Typically a {@link FallbackRegistryFetcher} chain that composes
|
|
1214
|
+
* user overrides, cached CDN, and bundled static sources.
|
|
1215
|
+
*/
|
|
1216
|
+
fetcher: IModelRegistryFetcher;
|
|
1217
|
+
}
|
|
1218
|
+
/** Error thrown when a provider definition is absent from the loaded model registry. */
|
|
1219
|
+
declare class ModelRegistryProviderNotFoundError extends Error {
|
|
1220
|
+
/** Stable provider definition identifier requested from the registry. */
|
|
1221
|
+
readonly providerId: string;
|
|
1222
|
+
/**
|
|
1223
|
+
* Create a provider-not-found registry error.
|
|
1224
|
+
* @param providerId - Stable provider definition identifier that was missing.
|
|
1225
|
+
*/
|
|
1226
|
+
constructor(providerId: string);
|
|
1227
|
+
}
|
|
1228
|
+
/**
|
|
1229
|
+
* Service for managing model registry operations via bus handlers.
|
|
1230
|
+
*
|
|
1231
|
+
* Responsibilities:
|
|
1232
|
+
* - Resolve model registry through the injected fetcher (chain)
|
|
1233
|
+
* - Hold in-memory cache, deduplicate concurrent requests
|
|
1234
|
+
* - Register bus handlers for getForProvider, getLabModels, getProviderModels,
|
|
1235
|
+
* checkModelInProviders, and refresh
|
|
1236
|
+
* - Emit modelRegistry.changed after a committed refresh
|
|
1237
|
+
* - Follow init/destroy lifecycle pattern with idempotent guards
|
|
1238
|
+
*
|
|
1239
|
+
* Schema validation (including `superRefine` cross-validation) is delegated to
|
|
1240
|
+
* the fetcher chain. The service trusts the registry returned by the fetcher.
|
|
1241
|
+
*
|
|
1242
|
+
* Caching and fallback logic lives in the fetcher chain, not here.
|
|
1243
|
+
* This service only manages in-memory state and bus wiring.
|
|
1244
|
+
* @example
|
|
1245
|
+
* ```typescript
|
|
1246
|
+
* const service = new ModelRegistryService({
|
|
1247
|
+
* bus: MakaioBus,
|
|
1248
|
+
* fetcher: new UserOverlayFetcher(
|
|
1249
|
+
* userModelsDir,
|
|
1250
|
+
* new FallbackRegistryFetcher([
|
|
1251
|
+
* new CachedRegistryFetcher(new CdnRegistryFetcher(registryUrl), fileCache),
|
|
1252
|
+
* new BundledSeedFetcher(seedPath),
|
|
1253
|
+
* ]),
|
|
1254
|
+
* ),
|
|
1255
|
+
* });
|
|
1256
|
+
* await service.init();
|
|
1257
|
+
* ```
|
|
1258
|
+
*/
|
|
1259
|
+
declare class ModelRegistryService extends BaseService {
|
|
1260
|
+
private readonly fetcher;
|
|
1261
|
+
private registry;
|
|
1262
|
+
private labModelIndex;
|
|
1263
|
+
private fetchPromise;
|
|
1264
|
+
private refreshPromise;
|
|
1265
|
+
private fetchGeneration;
|
|
1266
|
+
/**
|
|
1267
|
+
* Creates a new ModelRegistryService instance.
|
|
1268
|
+
* @param options - Service configuration options
|
|
1269
|
+
*/
|
|
1270
|
+
constructor(options: ModelRegistryServiceOptions);
|
|
1271
|
+
/**
|
|
1272
|
+
* Register bus handlers for model registry operations.
|
|
1273
|
+
*/
|
|
1274
|
+
protected onInit(): void;
|
|
1275
|
+
/**
|
|
1276
|
+
* Clear in-memory registry cache on destroy.
|
|
1277
|
+
*/
|
|
1278
|
+
protected onDestroy(): void;
|
|
1279
|
+
/**
|
|
1280
|
+
* Ensure registry is loaded, fetching if necessary.
|
|
1281
|
+
*
|
|
1282
|
+
* Resolution order:
|
|
1283
|
+
* 1. In-memory (this.registry) — instant
|
|
1284
|
+
* 2. Fetcher chain — delegates all source resolution and caching
|
|
1285
|
+
*
|
|
1286
|
+
* Concurrent requests share a single fetch promise to avoid redundant work.
|
|
1287
|
+
* Returns both the registry and a lab model index that is coherent with it.
|
|
1288
|
+
* When the registry was committed (the common case), the cached index is
|
|
1289
|
+
* returned directly. For in-flight stale fetches that committed to a
|
|
1290
|
+
* different generation, the index is built on-demand from the returned
|
|
1291
|
+
* registry so callers always receive a consistent pair.
|
|
1292
|
+
* @returns Registry and coherent lab model index.
|
|
1293
|
+
* @throws Error when the registry cannot be loaded from any configured source.
|
|
1294
|
+
*/
|
|
1295
|
+
private ensureRegistryWithIndex;
|
|
1296
|
+
/**
|
|
1297
|
+
* Refresh the registry from the fetcher chain.
|
|
1298
|
+
*
|
|
1299
|
+
* If a registry fetch is already active, refresh joins that fetch instead
|
|
1300
|
+
* of starting a competing one. Otherwise it clears in-memory state so the
|
|
1301
|
+
* full fetcher chain is re-evaluated.
|
|
1302
|
+
* @throws Error if the fetcher chain fails
|
|
1303
|
+
*/
|
|
1304
|
+
private refreshRegistry;
|
|
1305
|
+
/**
|
|
1306
|
+
* Await an active registry fetch on behalf of a refresh request.
|
|
1307
|
+
* @param fetchPromise - Active registry fetch to share with the refresh.
|
|
1308
|
+
* @throws Error if the fetcher chain fails or the shared fetch cannot commit.
|
|
1309
|
+
*/
|
|
1310
|
+
private awaitActiveFetchForRefresh;
|
|
1311
|
+
/**
|
|
1312
|
+
* Run the single active forced refresh when no registry fetch is in flight.
|
|
1313
|
+
* @throws Error if the fetcher chain fails or the refresh cannot commit.
|
|
1314
|
+
*/
|
|
1315
|
+
private runRefresh;
|
|
1316
|
+
/**
|
|
1317
|
+
* Notify subscribers that the committed model registry changed.
|
|
1318
|
+
*/
|
|
1319
|
+
private emitRegistryChanged;
|
|
1320
|
+
/**
|
|
1321
|
+
* Start the single active fetch for a registry generation.
|
|
1322
|
+
*
|
|
1323
|
+
* Both initial loads and forced refreshes install the promise returned here
|
|
1324
|
+
* as {@link fetchPromise}. That keeps one owner per generation: concurrent
|
|
1325
|
+
* requests await the same fetch and stale generations cannot clear a newer
|
|
1326
|
+
* active fetch.
|
|
1327
|
+
* @param generation - The generation captured at fetch start.
|
|
1328
|
+
* @returns Parsed model registry and whether it committed for the requested generation.
|
|
1329
|
+
*/
|
|
1330
|
+
private startRegistryFetch;
|
|
1331
|
+
/**
|
|
1332
|
+
* Commit a freshly parsed registry if the service generation is still current.
|
|
1333
|
+
*
|
|
1334
|
+
* Generation bumps on destroy() invalidate in-flight fetches and prevent
|
|
1335
|
+
* stale data from repopulating the cache after teardown. Also builds and
|
|
1336
|
+
* caches the lab model index so per-request calls to `getProviderModels` and
|
|
1337
|
+
* `getForProvider` avoid redundant iteration over the full lab list.
|
|
1338
|
+
* @param generation - The generation captured at fetch start.
|
|
1339
|
+
* @param registry - The parsed registry to commit.
|
|
1340
|
+
* @returns True when the registry was committed, false when the result was stale.
|
|
1341
|
+
*/
|
|
1342
|
+
private commitRegistry;
|
|
1343
|
+
/**
|
|
1344
|
+
* Resolve a single model for a provider by merging lab definition with provider overrides.
|
|
1345
|
+
* @param registry - The current model registry.
|
|
1346
|
+
* @param index - Lab model index coherent with the registry.
|
|
1347
|
+
* @param providerId - The provider identifier.
|
|
1348
|
+
* @param providerModelId - The provider-native model identifier to resolve.
|
|
1349
|
+
* @returns The merged model descriptor, or `undefined` if not found.
|
|
1350
|
+
*/
|
|
1351
|
+
private resolveProviderModel;
|
|
1352
|
+
/**
|
|
1353
|
+
* Resolve the provider offering that corresponds to a canonical lab model name.
|
|
1354
|
+
* @param registry - The current model registry.
|
|
1355
|
+
* @param index - Lab model index coherent with the registry.
|
|
1356
|
+
* @param providerId - The provider identifier.
|
|
1357
|
+
* @param canonicalModelName - Canonical lab model name to check.
|
|
1358
|
+
* @returns The merged provider model descriptor, or `undefined` if not found.
|
|
1359
|
+
*/
|
|
1360
|
+
private resolveProviderModelByCanonicalName;
|
|
1361
|
+
/**
|
|
1362
|
+
* Resolve all models for a provider, each merged with its lab definition.
|
|
1363
|
+
* @param registry - The current model registry.
|
|
1364
|
+
* @param index - Lab model index coherent with the registry.
|
|
1365
|
+
* @param providerId - The provider identifier.
|
|
1366
|
+
* @returns Array of merged model descriptors for the provider.
|
|
1367
|
+
* @throws Error when the provider is not present in the registry.
|
|
1368
|
+
*/
|
|
1369
|
+
private resolveAllProviderModels;
|
|
1370
|
+
/**
|
|
1371
|
+
* Resolve SDK-safe model descriptors across every provider.
|
|
1372
|
+
* @param registry - The current model registry.
|
|
1373
|
+
* @param index - Lab model index coherent with the registry.
|
|
1374
|
+
* @returns Provider-tagged model descriptors for SDK introspection.
|
|
1375
|
+
*/
|
|
1376
|
+
private resolveSupportedModels;
|
|
1377
|
+
/**
|
|
1378
|
+
* Build an index of all lab models keyed by name for efficient lookup.
|
|
1379
|
+
* @param registry - The current model registry.
|
|
1380
|
+
* @returns Map of model name to lab model descriptor.
|
|
1381
|
+
*/
|
|
1382
|
+
private buildLabModelIndex;
|
|
1383
|
+
/**
|
|
1384
|
+
* Merge a lab model with provider-specific overrides.
|
|
1385
|
+
*
|
|
1386
|
+
* Provider overrides replace lab values field-by-field.
|
|
1387
|
+
* Metadata merges at the top level, while provider `capabilities`
|
|
1388
|
+
* and `pricing` metadata replace the corresponding lab block whole.
|
|
1389
|
+
* The returned `name` is the provider-native model ID because that is the
|
|
1390
|
+
* identifier callers must send back to the provider API.
|
|
1391
|
+
* @param providerModelId - Provider-native model identifier.
|
|
1392
|
+
* @param labModel - The canonical model definition from the lab.
|
|
1393
|
+
* @param overrides - Provider-specific field overrides.
|
|
1394
|
+
* @returns The merged model descriptor.
|
|
1395
|
+
*/
|
|
1396
|
+
private mergeModel;
|
|
1397
|
+
/**
|
|
1398
|
+
* Clone a provider-resolved model descriptor (with required `labId`).
|
|
1399
|
+
*
|
|
1400
|
+
* Delegates structural cloning to {@link cloneModel} and re-spreads `labId`
|
|
1401
|
+
* so TypeScript knows the result is a `ProviderAIModel`.
|
|
1402
|
+
* @param model - Cached provider model descriptor to clone.
|
|
1403
|
+
* @returns A structurally independent provider model descriptor.
|
|
1404
|
+
*/
|
|
1405
|
+
private cloneProviderModel;
|
|
1406
|
+
/**
|
|
1407
|
+
* Clone a model descriptor before returning it through in-process bus APIs.
|
|
1408
|
+
* @param model - Cached model descriptor to clone.
|
|
1409
|
+
* @returns A structurally independent model descriptor.
|
|
1410
|
+
*/
|
|
1411
|
+
private cloneModel;
|
|
1412
|
+
}
|
|
1413
|
+
//#endregion
|
|
1414
|
+
//#region services/core/src/model-registry/fallback-registry-fetcher.d.ts
|
|
1415
|
+
/**
|
|
1416
|
+
* Tries multiple fetchers in order, returning the first successful result.
|
|
1417
|
+
*
|
|
1418
|
+
* Each fetcher is attempted sequentially. On success, returns immediately.
|
|
1419
|
+
* On failure, moves to the next fetcher. If all fetchers fail, throws the
|
|
1420
|
+
* last error encountered.
|
|
1421
|
+
* @example
|
|
1422
|
+
* ```typescript
|
|
1423
|
+
* const fetcher = new FallbackRegistryFetcher([
|
|
1424
|
+
* new CachedRegistryFetcher(new CdnRegistryFetcher(cdnUrl), fileCache),
|
|
1425
|
+
* new BundledSeedFetcher(seedPath),
|
|
1426
|
+
* ]);
|
|
1427
|
+
* ```
|
|
1428
|
+
*/
|
|
1429
|
+
declare class FallbackRegistryFetcher implements IModelRegistryFetcher {
|
|
1430
|
+
private readonly fetchers;
|
|
1431
|
+
/**
|
|
1432
|
+
* Creates a new FallbackRegistryFetcher.
|
|
1433
|
+
* @param fetchers - Ordered list of fetchers to try (first match wins)
|
|
1434
|
+
* @throws Error if fetchers array is empty
|
|
1435
|
+
*/
|
|
1436
|
+
constructor(fetchers: IModelRegistryFetcher[]);
|
|
1437
|
+
/**
|
|
1438
|
+
* Try each fetcher in order, returning the first successful result.
|
|
1439
|
+
* @returns The model registry from the first successful fetcher
|
|
1440
|
+
* @throws The last error if all fetchers fail
|
|
1441
|
+
*/
|
|
1442
|
+
fetch(): Promise<ModelRegistry>;
|
|
1443
|
+
}
|
|
1444
|
+
//#endregion
|
|
1445
|
+
//#region services/core/src/model-registry/cached-registry-fetcher.d.ts
|
|
1446
|
+
/**
|
|
1447
|
+
* Decorator that adds disk/persistent caching around a fetcher.
|
|
1448
|
+
*
|
|
1449
|
+
* On success: caches the result for future use.
|
|
1450
|
+
* On failure: returns cached data if available, otherwise rethrows
|
|
1451
|
+
* so the next fetcher in a fallback chain can be tried.
|
|
1452
|
+
* @example
|
|
1453
|
+
* ```typescript
|
|
1454
|
+
* const cached = new CachedRegistryFetcher(
|
|
1455
|
+
* new CdnRegistryFetcher('https://example.com/model-registry.yaml'),
|
|
1456
|
+
* new FileRegistryCache(path.join(makaioHome, 'cache', 'model-registry.json')),
|
|
1457
|
+
* );
|
|
1458
|
+
* ```
|
|
1459
|
+
*/
|
|
1460
|
+
declare class CachedRegistryFetcher implements IModelRegistryFetcher {
|
|
1461
|
+
private readonly inner;
|
|
1462
|
+
private readonly cache;
|
|
1463
|
+
/**
|
|
1464
|
+
* Creates a new CachedRegistryFetcher.
|
|
1465
|
+
* @param inner - The fetcher to wrap with caching
|
|
1466
|
+
* @param cache - The cache implementation for persistence
|
|
1467
|
+
*/
|
|
1468
|
+
constructor(inner: IModelRegistryFetcher, cache: IModelRegistryCache);
|
|
1469
|
+
/**
|
|
1470
|
+
* Fetch from the inner fetcher with cache fallback.
|
|
1471
|
+
* @returns Registry from inner fetcher (fresh) or cache (stale fallback)
|
|
1472
|
+
* @throws Error if inner fetch fails and no cached data exists
|
|
1473
|
+
*/
|
|
1474
|
+
fetch(): Promise<ModelRegistry>;
|
|
1475
|
+
}
|
|
1476
|
+
//#endregion
|
|
1477
|
+
//#region services/core/src/model-registry/merge-utils.d.ts
|
|
1478
|
+
/**
|
|
1479
|
+
* Merge model metadata with block-level replacement and defensive clone semantics.
|
|
1480
|
+
*
|
|
1481
|
+
* Top-level metadata fields merge field-by-field. When an overlay supplies
|
|
1482
|
+
* `capabilities` or `pricing`, that whole block replaces the base block.
|
|
1483
|
+
* Returned metadata is structurally independent from both inputs.
|
|
1484
|
+
* @param baseMetadata - Metadata supplied by the base model.
|
|
1485
|
+
* @param overlayMetadata - Metadata supplied by the overlay model.
|
|
1486
|
+
* @returns Merged metadata, or undefined when neither side supplies metadata.
|
|
1487
|
+
*/
|
|
1488
|
+
declare function mergeModelMetadata(baseMetadata: AIModelMetadata | undefined, overlayMetadata: AIModelMetadata | undefined): AIModelMetadata | undefined;
|
|
1489
|
+
//#endregion
|
|
1490
|
+
export { ModelRegistrySchemas as C, ModelRegistrySchema as S, ProviderModelOverrideSchema as T, ModelRegistryGetLabModelsResponse as _, ModelRegistryService as a, ModelRegistryRefreshRequest as b, IModelRegistryFetcher as c, ModelRegistry as d, ModelRegistryCheckModelInProvidersRequest as f, ModelRegistryGetLabModelsRequest as g, ModelRegistryGetForProviderResponse as h, ModelRegistryProviderNotFoundError as i, ModelRegistryNamespace as l, ModelRegistryGetForProviderRequest as m, CachedRegistryFetcher as n, ModelRegistryServiceOptions as o, ModelRegistryCheckModelInProvidersResponse as p, FallbackRegistryFetcher as r, IModelRegistryCache as s, mergeModelMetadata as t, ModelRegistrySubjects as u, ModelRegistryGetProviderModelsRequest as v, ProviderModelOverride as w, ModelRegistryRefreshResponse as x, ModelRegistryGetProviderModelsResponse as y };
|