@mastra/core 1.0.0-beta.4 → 1.0.0-beta.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +598 -0
- package/dist/agent/agent-legacy.d.ts +17 -20
- package/dist/agent/agent-legacy.d.ts.map +1 -1
- package/dist/agent/agent-types.test-d.d.ts +2 -0
- package/dist/agent/agent-types.test-d.d.ts.map +1 -0
- package/dist/agent/agent.d.ts +6 -6
- package/dist/agent/agent.d.ts.map +1 -1
- package/dist/agent/agent.types.d.ts +3 -1
- package/dist/agent/agent.types.d.ts.map +1 -1
- package/dist/agent/index.cjs +9 -9
- package/dist/agent/index.js +2 -2
- package/dist/agent/message-list/index.cjs +3 -3
- package/dist/agent/message-list/index.d.ts +49 -0
- package/dist/agent/message-list/index.d.ts.map +1 -1
- package/dist/agent/message-list/index.js +1 -1
- package/dist/agent/message-list/prompt/attachments-to-parts.d.ts.map +1 -1
- package/dist/agent/save-queue/index.d.ts +3 -1
- package/dist/agent/save-queue/index.d.ts.map +1 -1
- package/dist/agent/test-utils.d.ts +37 -0
- package/dist/agent/test-utils.d.ts.map +1 -1
- package/dist/agent/trip-wire.d.ts.map +1 -1
- package/dist/agent/types.d.ts +20 -6
- package/dist/agent/types.d.ts.map +1 -1
- package/dist/agent/utils.d.ts.map +1 -1
- package/dist/agent/workflows/prepare-stream/index.d.ts +10 -10
- package/dist/agent/workflows/prepare-stream/index.d.ts.map +1 -1
- package/dist/agent/workflows/prepare-stream/map-results-step.d.ts +1 -3
- package/dist/agent/workflows/prepare-stream/map-results-step.d.ts.map +1 -1
- package/dist/agent/workflows/prepare-stream/prepare-memory-step.d.ts +4 -4
- package/dist/agent/workflows/prepare-stream/prepare-memory-step.d.ts.map +1 -1
- package/dist/agent/workflows/prepare-stream/prepare-tools-step.d.ts +4 -4
- package/dist/agent/workflows/prepare-stream/prepare-tools-step.d.ts.map +1 -1
- package/dist/agent/workflows/prepare-stream/schema.d.ts +12 -13
- package/dist/agent/workflows/prepare-stream/schema.d.ts.map +1 -1
- package/dist/agent/workflows/prepare-stream/stream-step.d.ts +8 -1
- package/dist/agent/workflows/prepare-stream/stream-step.d.ts.map +1 -1
- package/dist/base.cjs +2 -2
- package/dist/base.js +1 -1
- package/dist/bundler/index.cjs +2 -2
- package/dist/bundler/index.js +1 -1
- package/dist/cache/index.cjs +3 -3
- package/dist/cache/index.js +1 -1
- package/dist/{chunk-OJNJA5ZI.js → chunk-3CKZSDTQ.js} +3 -3
- package/dist/{chunk-OJNJA5ZI.js.map → chunk-3CKZSDTQ.js.map} +1 -1
- package/dist/{chunk-TQTAMPSC.js → chunk-3N3QE4ZK.js} +3 -3
- package/dist/chunk-3N3QE4ZK.js.map +1 -0
- package/dist/{chunk-WQSGX6XA.cjs → chunk-3TKNXJES.cjs} +56 -15
- package/dist/chunk-3TKNXJES.cjs.map +1 -0
- package/dist/{chunk-XXBWX7DT.js → chunk-45NA5ZD3.js} +11673 -9468
- package/dist/chunk-45NA5ZD3.js.map +1 -0
- package/dist/{chunk-KEURQGCQ.js → chunk-4F6RAJFU.js} +105 -21
- package/dist/chunk-4F6RAJFU.js.map +1 -0
- package/dist/{chunk-ISMGVGUM.cjs → chunk-4JKEUSCC.cjs} +4 -4
- package/dist/{chunk-ISMGVGUM.cjs.map → chunk-4JKEUSCC.cjs.map} +1 -1
- package/dist/{chunk-CYVNOIXS.cjs → chunk-4KUOSXJ7.cjs} +30 -16
- package/dist/chunk-4KUOSXJ7.cjs.map +1 -0
- package/dist/{chunk-CBAB7GOD.cjs → chunk-6BJ7XHRH.cjs} +2 -2
- package/dist/{chunk-CBAB7GOD.cjs.map → chunk-6BJ7XHRH.cjs.map} +1 -1
- package/dist/{chunk-3RW5EMSB.js → chunk-6GOLI2EY.js} +22 -9
- package/dist/chunk-6GOLI2EY.js.map +1 -0
- package/dist/{chunk-4RXG622P.cjs → chunk-6J4NRNT2.cjs} +600 -37
- package/dist/chunk-6J4NRNT2.cjs.map +1 -0
- package/dist/{chunk-J7O6WENZ.cjs → chunk-6TBWJV35.js} +5 -5
- package/dist/chunk-6TBWJV35.js.map +1 -0
- package/dist/chunk-6XCINXZ7.cjs +194 -0
- package/dist/chunk-6XCINXZ7.cjs.map +1 -0
- package/dist/{chunk-MDKPL2R2.js → chunk-7ZADRRDW.js} +5 -4
- package/dist/chunk-7ZADRRDW.js.map +1 -0
- package/dist/{chunk-DSNPWVIG.cjs → chunk-AF74UXR5.cjs} +4 -3
- package/dist/chunk-AF74UXR5.cjs.map +1 -0
- package/dist/{chunk-W3DD3XP5.js → chunk-APMPOYPI.js} +334 -138
- package/dist/chunk-APMPOYPI.js.map +1 -0
- package/dist/{chunk-LRSB62Z6.cjs → chunk-AQAIS7FH.cjs} +15 -8
- package/dist/chunk-AQAIS7FH.cjs.map +1 -0
- package/dist/chunk-BWYU7D33.js +192 -0
- package/dist/chunk-BWYU7D33.js.map +1 -0
- package/dist/{chunk-KEXGB7FK.cjs → chunk-DGV2FWB4.cjs} +7 -7
- package/dist/{chunk-KEXGB7FK.cjs.map → chunk-DGV2FWB4.cjs.map} +1 -1
- package/dist/{chunk-WTYNK7Q4.js → chunk-DXMSVGJ6.js} +599 -36
- package/dist/chunk-DXMSVGJ6.js.map +1 -0
- package/dist/{chunk-Y63IFHEZ.cjs → chunk-EOPEDKLG.cjs} +4 -4
- package/dist/chunk-EOPEDKLG.cjs.map +1 -0
- package/dist/{chunk-NZAXAFI3.js → chunk-F2GAJSBI.js} +3 -3
- package/dist/{chunk-NZAXAFI3.js.map → chunk-F2GAJSBI.js.map} +1 -1
- package/dist/{chunk-KIZIOFZC.js → chunk-FYP3AT6W.js} +17 -3
- package/dist/chunk-FYP3AT6W.js.map +1 -0
- package/dist/{chunk-ZCVTH3CH.cjs → chunk-HNHZGFZY.cjs} +5 -4
- package/dist/chunk-HNHZGFZY.cjs.map +1 -0
- package/dist/{chunk-BMAFVZ2D.cjs → chunk-IWTMMUQY.cjs} +4 -4
- package/dist/{chunk-BMAFVZ2D.cjs.map → chunk-IWTMMUQY.cjs.map} +1 -1
- package/dist/{chunk-D6EDHNGV.js → chunk-KZLP6TPJ.js} +69 -28
- package/dist/chunk-KZLP6TPJ.js.map +1 -0
- package/dist/{chunk-5WXEYDFI.cjs → chunk-LDWBLENZ.cjs} +51 -38
- package/dist/chunk-LDWBLENZ.cjs.map +1 -0
- package/dist/{chunk-HGNRQ3OG.js → chunk-LEZIKVRQ.js} +15 -8
- package/dist/chunk-LEZIKVRQ.js.map +1 -0
- package/dist/{chunk-S6URFGCZ.js → chunk-LSHPJWM5.js} +3 -3
- package/dist/{chunk-S6URFGCZ.js.map → chunk-LSHPJWM5.js.map} +1 -1
- package/dist/{chunk-E7K4FTLN.cjs → chunk-NHNXIYDG.cjs} +18 -2
- package/dist/chunk-NHNXIYDG.cjs.map +1 -0
- package/dist/{chunk-U7VECK2G.js → chunk-NIUEWICQ.js} +145 -19
- package/dist/chunk-NIUEWICQ.js.map +1 -0
- package/dist/{chunk-2NVBZKZI.cjs → chunk-NN3NOFRU.cjs} +11744 -9526
- package/dist/chunk-NN3NOFRU.cjs.map +1 -0
- package/dist/{chunk-KJ2SW6VA.js → chunk-NRUZYMHE.js} +4 -3
- package/dist/chunk-NRUZYMHE.js.map +1 -0
- package/dist/{chunk-IWB65P37.cjs → chunk-OIMB2SNZ.cjs} +155 -29
- package/dist/chunk-OIMB2SNZ.cjs.map +1 -0
- package/dist/{chunk-IWQDBVJK.js → chunk-OPALPWAM.js} +47 -8
- package/dist/chunk-OPALPWAM.js.map +1 -0
- package/dist/{chunk-X7JMA3IY.js → chunk-PSCMWPLC.js} +2 -2
- package/dist/{chunk-X7JMA3IY.js.map → chunk-PSCMWPLC.js.map} +1 -1
- package/dist/{chunk-S6OEQHEI.cjs → chunk-QGWNF2QJ.cjs} +59 -50
- package/dist/chunk-QGWNF2QJ.cjs.map +1 -0
- package/dist/{chunk-VZC4BWWH.cjs → chunk-RHTV5C5D.cjs} +19 -19
- package/dist/chunk-RHTV5C5D.cjs.map +1 -0
- package/dist/{chunk-HBJPYQRN.cjs → chunk-RTROJFEU.cjs} +78 -41
- package/dist/chunk-RTROJFEU.cjs.map +1 -0
- package/dist/chunk-S5FPOCQF.cjs +518 -0
- package/dist/chunk-S5FPOCQF.cjs.map +1 -0
- package/dist/{chunk-O6NA3Z43.cjs → chunk-SQAX4OW6.cjs} +167 -12
- package/dist/chunk-SQAX4OW6.cjs.map +1 -0
- package/dist/{chunk-IHJDOC3A.js → chunk-T2UNO766.js} +16 -7
- package/dist/chunk-T2UNO766.js.map +1 -0
- package/dist/{chunk-FVNT7VTO.js → chunk-TARWUQG6.js} +243 -166
- package/dist/chunk-TARWUQG6.js.map +1 -0
- package/dist/{chunk-76K3IYWM.js → chunk-TS7B26US.js} +3 -3
- package/dist/{chunk-76K3IYWM.js.map → chunk-TS7B26US.js.map} +1 -1
- package/dist/{chunk-Y6ROD72V.cjs → chunk-UIGRFDO6.cjs} +4 -4
- package/dist/{chunk-Y6ROD72V.cjs.map → chunk-UIGRFDO6.cjs.map} +1 -1
- package/dist/{chunk-GRBGQ2GE.js → chunk-UVHSM2GU.cjs} +9 -3
- package/dist/chunk-UVHSM2GU.cjs.map +1 -0
- package/dist/{chunk-VSM3NLUX.cjs → chunk-VRFSEZBA.cjs} +334 -138
- package/dist/chunk-VRFSEZBA.cjs.map +1 -0
- package/dist/{chunk-JXESKY4A.js → chunk-WDRA4WKG.js} +163 -9
- package/dist/chunk-WDRA4WKG.js.map +1 -0
- package/dist/{chunk-RXDJL5QT.js → chunk-WMAMOYRR.js} +14 -14
- package/dist/chunk-WMAMOYRR.js.map +1 -0
- package/dist/{chunk-2OTDXX73.js → chunk-XY337TTF.js} +24 -10
- package/dist/chunk-XY337TTF.js.map +1 -0
- package/dist/{chunk-4IKJAKCD.cjs → chunk-Y24HI6ND.cjs} +108 -23
- package/dist/chunk-Y24HI6ND.cjs.map +1 -0
- package/dist/deployer/index.cjs +2 -2
- package/dist/deployer/index.js +1 -1
- package/dist/di/index.cjs +10 -2
- package/dist/di/index.d.ts +1 -1
- package/dist/di/index.d.ts.map +1 -1
- package/dist/di/index.js +1 -1
- package/dist/evals/base.d.ts +10 -2
- package/dist/evals/base.d.ts.map +1 -1
- package/dist/evals/base.test-utils.d.ts +25 -25
- package/dist/evals/index.cjs +9 -9
- package/dist/evals/index.js +2 -2
- package/dist/evals/scoreTraces/index.cjs +5 -5
- package/dist/evals/scoreTraces/index.js +2 -2
- package/dist/evals/types.d.ts +8 -8
- package/dist/index.cjs +2 -2
- package/dist/index.js +1 -1
- package/dist/integration/index.cjs +2 -2
- package/dist/integration/index.js +1 -1
- package/dist/llm/index.cjs +18 -14
- package/dist/llm/index.d.ts +2 -1
- package/dist/llm/index.d.ts.map +1 -1
- package/dist/llm/index.js +5 -5
- package/dist/llm/model/aisdk/v5/model.d.ts.map +1 -1
- package/dist/llm/model/gateway-resolver.d.ts.map +1 -1
- package/dist/llm/model/gateways/azure.d.ts +36 -0
- package/dist/llm/model/gateways/azure.d.ts.map +1 -0
- package/dist/llm/model/gateways/base.d.ts +3 -6
- package/dist/llm/model/gateways/base.d.ts.map +1 -1
- package/dist/llm/model/gateways/index.d.ts +4 -1
- package/dist/llm/model/gateways/index.d.ts.map +1 -1
- package/dist/llm/model/gateways/models-dev.d.ts +2 -2
- package/dist/llm/model/gateways/models-dev.d.ts.map +1 -1
- package/dist/llm/model/gateways/netlify.d.ts +2 -2
- package/dist/llm/model/gateways/netlify.d.ts.map +1 -1
- package/dist/llm/model/model.d.ts.map +1 -1
- package/dist/llm/model/model.loop.d.ts +1 -1
- package/dist/llm/model/model.loop.d.ts.map +1 -1
- package/dist/llm/model/provider-registry.d.ts.map +1 -1
- package/dist/llm/model/provider-types.generated.d.ts +245 -12
- package/dist/llm/model/registry-generator.d.ts +12 -0
- package/dist/llm/model/registry-generator.d.ts.map +1 -1
- package/dist/llm/model/router.d.ts.map +1 -1
- package/dist/logger/constants.d.ts +1 -0
- package/dist/logger/constants.d.ts.map +1 -1
- package/dist/logger/index.cjs +11 -11
- package/dist/logger/index.js +2 -2
- package/dist/logger/transport.d.ts +1 -1
- package/dist/logger/transport.d.ts.map +1 -1
- package/dist/loop/index.cjs +2 -2
- package/dist/loop/index.js +1 -1
- package/dist/loop/loop.d.ts.map +1 -1
- package/dist/loop/network/index.d.ts +2 -2
- package/dist/loop/network/index.d.ts.map +1 -1
- package/dist/loop/test-utils/fullStream.d.ts.map +1 -1
- package/dist/loop/test-utils/generateText.d.ts.map +1 -1
- package/dist/loop/test-utils/resultObject.d.ts.map +1 -1
- package/dist/loop/test-utils/streamObject.d.ts.map +1 -1
- package/dist/loop/types.d.ts +13 -2
- package/dist/loop/types.d.ts.map +1 -1
- package/dist/loop/workflows/agentic-execution/index.d.ts +96 -96
- package/dist/loop/workflows/agentic-execution/index.d.ts.map +1 -1
- package/dist/loop/workflows/agentic-execution/llm-execution-step.d.ts +65 -65
- package/dist/loop/workflows/agentic-execution/llm-execution-step.d.ts.map +1 -1
- package/dist/loop/workflows/agentic-execution/llm-mapping-step.d.ts +32 -32
- package/dist/loop/workflows/agentic-execution/llm-mapping-step.d.ts.map +1 -1
- package/dist/loop/workflows/agentic-execution/tool-call-step.d.ts +1 -1
- package/dist/loop/workflows/agentic-execution/tool-call-step.d.ts.map +1 -1
- package/dist/loop/workflows/agentic-loop/index.d.ts +97 -97
- package/dist/loop/workflows/agentic-loop/index.d.ts.map +1 -1
- package/dist/loop/workflows/schema.d.ts +32 -32
- package/dist/loop/workflows/stream.d.ts +1 -1
- package/dist/loop/workflows/stream.d.ts.map +1 -1
- package/dist/mastra/index.cjs +2 -2
- package/dist/mastra/index.d.ts +64 -9
- package/dist/mastra/index.d.ts.map +1 -1
- package/dist/mastra/index.js +1 -1
- package/dist/mcp/index.cjs +4 -4
- package/dist/mcp/index.cjs.map +1 -1
- package/dist/mcp/index.d.ts +4 -4
- package/dist/mcp/index.d.ts.map +1 -1
- package/dist/mcp/index.js +2 -2
- package/dist/mcp/index.js.map +1 -1
- package/dist/mcp/types.d.ts +2 -2
- package/dist/mcp/types.d.ts.map +1 -1
- package/dist/memory/index.cjs +21 -327
- package/dist/memory/index.cjs.map +1 -1
- package/dist/memory/index.js +1 -327
- package/dist/memory/index.js.map +1 -1
- package/dist/memory/memory.d.ts +22 -18
- package/dist/memory/memory.d.ts.map +1 -1
- package/dist/memory/mock.d.ts +15 -14
- package/dist/memory/mock.d.ts.map +1 -1
- package/dist/memory/types.d.ts +69 -11
- package/dist/memory/types.d.ts.map +1 -1
- package/dist/models-dev-F6MTIYTO.js +3 -0
- package/dist/{models-dev-6PRLJKVZ.js.map → models-dev-F6MTIYTO.js.map} +1 -1
- package/dist/models-dev-XIVR5EJV.cjs +12 -0
- package/dist/{models-dev-WHMI5G6Y.cjs.map → models-dev-XIVR5EJV.cjs.map} +1 -1
- package/dist/netlify-C2YBIK7A.js +3 -0
- package/dist/{netlify-EBQ6YUC6.js.map → netlify-C2YBIK7A.js.map} +1 -1
- package/dist/netlify-XWROOTP4.cjs +12 -0
- package/dist/{netlify-46I3SNNV.cjs.map → netlify-XWROOTP4.cjs.map} +1 -1
- package/dist/observability/index.cjs +16 -8
- package/dist/observability/index.js +1 -1
- package/dist/observability/types/tracing.d.ts +165 -3
- package/dist/observability/types/tracing.d.ts.map +1 -1
- package/dist/observability/utils.d.ts +47 -1
- package/dist/observability/utils.d.ts.map +1 -1
- package/dist/processors/index.cjs +35 -11
- package/dist/processors/index.d.ts +101 -23
- package/dist/processors/index.d.ts.map +1 -1
- package/dist/processors/index.js +1 -1
- package/dist/processors/memory/index.d.ts +7 -0
- package/dist/processors/memory/index.d.ts.map +1 -0
- package/dist/processors/memory/message-history.d.ts +43 -0
- package/dist/processors/memory/message-history.d.ts.map +1 -0
- package/dist/processors/memory/semantic-recall.d.ts +152 -0
- package/dist/processors/memory/semantic-recall.d.ts.map +1 -0
- package/dist/processors/memory/working-memory.d.ts +65 -0
- package/dist/processors/memory/working-memory.d.ts.map +1 -0
- package/dist/processors/processors/batch-parts.d.ts +1 -1
- package/dist/processors/processors/batch-parts.d.ts.map +1 -1
- package/dist/processors/processors/index.d.ts +2 -1
- package/dist/processors/processors/index.d.ts.map +1 -1
- package/dist/processors/processors/language-detector.d.ts +15 -1
- package/dist/processors/processors/language-detector.d.ts.map +1 -1
- package/dist/processors/processors/moderation.d.ts +15 -1
- package/dist/processors/processors/moderation.d.ts.map +1 -1
- package/dist/processors/processors/pii-detector.d.ts +15 -1
- package/dist/processors/processors/pii-detector.d.ts.map +1 -1
- package/dist/processors/processors/prompt-injection-detector.d.ts +15 -1
- package/dist/processors/processors/prompt-injection-detector.d.ts.map +1 -1
- package/dist/processors/processors/structured-output.d.ts +3 -2
- package/dist/processors/processors/structured-output.d.ts.map +1 -1
- package/dist/processors/processors/system-prompt-scrubber.d.ts +1 -1
- package/dist/processors/processors/system-prompt-scrubber.d.ts.map +1 -1
- package/dist/processors/processors/token-limiter.d.ts +22 -12
- package/dist/processors/processors/token-limiter.d.ts.map +1 -1
- package/dist/processors/processors/tool-call-filter.d.ts +28 -0
- package/dist/processors/processors/tool-call-filter.d.ts.map +1 -0
- package/dist/processors/processors/unicode-normalizer.d.ts +1 -1
- package/dist/processors/processors/unicode-normalizer.d.ts.map +1 -1
- package/dist/processors/runner.d.ts +35 -4
- package/dist/processors/runner.d.ts.map +1 -1
- package/dist/provider-registry-BXX7CA3H.cjs +40 -0
- package/dist/{provider-registry-RP2W4B24.cjs.map → provider-registry-BXX7CA3H.cjs.map} +1 -1
- package/dist/provider-registry-GRYJWVEM.js +3 -0
- package/dist/{provider-registry-HDG6UMUC.js.map → provider-registry-GRYJWVEM.js.map} +1 -1
- package/dist/provider-registry.json +547 -25
- package/dist/{registry-generator-JPCV47SC.cjs → registry-generator-34SC4TAU.cjs} +21 -6
- package/dist/registry-generator-34SC4TAU.cjs.map +1 -0
- package/dist/{registry-generator-XD4FPZTU.js → registry-generator-UMTNPBJX.js} +21 -7
- package/dist/registry-generator-UMTNPBJX.js.map +1 -0
- package/dist/relevance/index.cjs +2 -2
- package/dist/relevance/index.js +1 -1
- package/dist/request-context/index.cjs +10 -2
- package/dist/request-context/index.d.ts +26 -0
- package/dist/request-context/index.d.ts.map +1 -1
- package/dist/request-context/index.js +1 -1
- package/dist/server/base.d.ts +51 -0
- package/dist/server/base.d.ts.map +1 -0
- package/dist/server/composite-auth.d.ts +9 -0
- package/dist/server/composite-auth.d.ts.map +1 -0
- package/dist/server/index.cjs +112 -2
- package/dist/server/index.cjs.map +1 -1
- package/dist/server/index.d.ts +4 -0
- package/dist/server/index.d.ts.map +1 -1
- package/dist/server/index.js +109 -2
- package/dist/server/index.js.map +1 -1
- package/dist/server/simple-auth.d.ts +27 -0
- package/dist/server/simple-auth.d.ts.map +1 -0
- package/dist/storage/domains/memory/inmemory.d.ts.map +1 -1
- package/dist/storage/index.cjs +37 -29
- package/dist/storage/index.js +1 -1
- package/dist/storage/types.d.ts +1 -1
- package/dist/storage/types.d.ts.map +1 -1
- package/dist/storage/utils.d.ts +44 -0
- package/dist/storage/utils.d.ts.map +1 -1
- package/dist/stream/MastraAgentNetworkStream.d.ts +1 -1
- package/dist/stream/MastraAgentNetworkStream.d.ts.map +1 -1
- package/dist/stream/MastraWorkflowStream.d.ts +1 -1
- package/dist/stream/MastraWorkflowStream.d.ts.map +1 -1
- package/dist/stream/RunOutput.d.ts +2 -2
- package/dist/stream/RunOutput.d.ts.map +1 -1
- package/dist/stream/aisdk/v5/output.d.ts +1 -1
- package/dist/stream/aisdk/v5/output.d.ts.map +1 -1
- package/dist/stream/aisdk/v5/transform.d.ts.map +1 -1
- package/dist/stream/base/base.d.ts +1 -1
- package/dist/stream/base/base.d.ts.map +1 -1
- package/dist/stream/base/output-format-handlers.d.ts +1 -1
- package/dist/stream/base/output-format-handlers.d.ts.map +1 -1
- package/dist/stream/base/output.d.ts +1 -1
- package/dist/stream/base/output.d.ts.map +1 -1
- package/dist/stream/index.cjs +11 -11
- package/dist/stream/index.js +2 -2
- package/dist/stream/types.d.ts +9 -2
- package/dist/stream/types.d.ts.map +1 -1
- package/dist/test-utils/llm-mock.cjs +36 -2
- package/dist/test-utils/llm-mock.cjs.map +1 -1
- package/dist/test-utils/llm-mock.d.ts +3 -0
- package/dist/test-utils/llm-mock.d.ts.map +1 -1
- package/dist/test-utils/llm-mock.js +32 -2
- package/dist/test-utils/llm-mock.js.map +1 -1
- package/dist/tools/index.cjs +6 -6
- package/dist/tools/index.js +2 -2
- package/dist/tools/is-vercel-tool.cjs +2 -2
- package/dist/tools/is-vercel-tool.js +1 -1
- package/dist/tools/stream.d.ts +2 -1
- package/dist/tools/stream.d.ts.map +1 -1
- package/dist/tools/tool-builder/builder.d.ts +2 -0
- package/dist/tools/tool-builder/builder.d.ts.map +1 -1
- package/dist/tools/tool.d.ts +19 -6
- package/dist/tools/tool.d.ts.map +1 -1
- package/dist/tools/types.d.ts +28 -3
- package/dist/tools/types.d.ts.map +1 -1
- package/dist/tools/validation.d.ts +14 -2
- package/dist/tools/validation.d.ts.map +1 -1
- package/dist/tts/index.cjs +2 -2
- package/dist/tts/index.js +1 -1
- package/dist/utils.cjs +22 -22
- package/dist/utils.d.ts +2 -2
- package/dist/utils.d.ts.map +1 -1
- package/dist/utils.js +1 -1
- package/dist/vector/filter/index.cjs +7 -189
- package/dist/vector/filter/index.cjs.map +1 -1
- package/dist/vector/filter/index.js +1 -190
- package/dist/vector/filter/index.js.map +1 -1
- package/dist/vector/index.cjs +7 -2
- package/dist/vector/index.cjs.map +1 -1
- package/dist/vector/index.d.ts +1 -0
- package/dist/vector/index.d.ts.map +1 -1
- package/dist/vector/index.js +2 -1
- package/dist/vector/index.js.map +1 -1
- package/dist/vector/types.d.ts +86 -3
- package/dist/vector/types.d.ts.map +1 -1
- package/dist/vector/vector.d.ts +39 -2
- package/dist/vector/vector.d.ts.map +1 -1
- package/dist/voice/index.cjs +6 -6
- package/dist/voice/index.js +1 -1
- package/dist/workflows/default.d.ts +176 -281
- package/dist/workflows/default.d.ts.map +1 -1
- package/dist/workflows/evented/index.cjs +10 -10
- package/dist/workflows/evented/index.js +1 -1
- package/dist/workflows/evented/step-executor.d.ts +1 -1
- package/dist/workflows/evented/step-executor.d.ts.map +1 -1
- package/dist/workflows/execution-engine.d.ts +4 -2
- package/dist/workflows/execution-engine.d.ts.map +1 -1
- package/dist/workflows/handlers/control-flow.d.ts +135 -0
- package/dist/workflows/handlers/control-flow.d.ts.map +1 -0
- package/dist/workflows/handlers/entry.d.ts +45 -0
- package/dist/workflows/handlers/entry.d.ts.map +1 -0
- package/dist/workflows/handlers/sleep.d.ts +62 -0
- package/dist/workflows/handlers/sleep.d.ts.map +1 -0
- package/dist/workflows/handlers/step.d.ts +60 -0
- package/dist/workflows/handlers/step.d.ts.map +1 -0
- package/dist/workflows/index.cjs +23 -19
- package/dist/workflows/index.js +1 -1
- package/dist/workflows/step.d.ts +1 -0
- package/dist/workflows/step.d.ts.map +1 -1
- package/dist/workflows/types.d.ts +159 -5
- package/dist/workflows/types.d.ts.map +1 -1
- package/dist/workflows/utils.d.ts +7 -0
- package/dist/workflows/utils.d.ts.map +1 -1
- package/dist/workflows/workflow.d.ts +12 -8
- package/dist/workflows/workflow.d.ts.map +1 -1
- package/package.json +12 -10
- package/src/llm/model/provider-types.generated.d.ts +245 -12
- package/dist/chunk-2NVBZKZI.cjs.map +0 -1
- package/dist/chunk-2OTDXX73.js.map +0 -1
- package/dist/chunk-3PSWNGBF.js +0 -3
- package/dist/chunk-3PSWNGBF.js.map +0 -1
- package/dist/chunk-3RW5EMSB.js.map +0 -1
- package/dist/chunk-3W5RQCCY.cjs +0 -440
- package/dist/chunk-3W5RQCCY.cjs.map +0 -1
- package/dist/chunk-436FFEF6.js +0 -34
- package/dist/chunk-436FFEF6.js.map +0 -1
- package/dist/chunk-4IKJAKCD.cjs.map +0 -1
- package/dist/chunk-4RXG622P.cjs.map +0 -1
- package/dist/chunk-5WXEYDFI.cjs.map +0 -1
- package/dist/chunk-CYVNOIXS.cjs.map +0 -1
- package/dist/chunk-D6EDHNGV.js.map +0 -1
- package/dist/chunk-DSNPWVIG.cjs.map +0 -1
- package/dist/chunk-E7K4FTLN.cjs.map +0 -1
- package/dist/chunk-FVNT7VTO.js.map +0 -1
- package/dist/chunk-GRBGQ2GE.js.map +0 -1
- package/dist/chunk-HBJPYQRN.cjs.map +0 -1
- package/dist/chunk-HGNRQ3OG.js.map +0 -1
- package/dist/chunk-IHJDOC3A.js.map +0 -1
- package/dist/chunk-IWB65P37.cjs.map +0 -1
- package/dist/chunk-IWQDBVJK.js.map +0 -1
- package/dist/chunk-J7O6WENZ.cjs.map +0 -1
- package/dist/chunk-JXESKY4A.js.map +0 -1
- package/dist/chunk-KEURQGCQ.js.map +0 -1
- package/dist/chunk-KIZIOFZC.js.map +0 -1
- package/dist/chunk-KJ2SW6VA.js.map +0 -1
- package/dist/chunk-LRSB62Z6.cjs.map +0 -1
- package/dist/chunk-MDKPL2R2.js.map +0 -1
- package/dist/chunk-O6NA3Z43.cjs.map +0 -1
- package/dist/chunk-PE3V7GUL.cjs +0 -4
- package/dist/chunk-PE3V7GUL.cjs.map +0 -1
- package/dist/chunk-RXDJL5QT.js.map +0 -1
- package/dist/chunk-S6OEQHEI.cjs.map +0 -1
- package/dist/chunk-TQTAMPSC.js.map +0 -1
- package/dist/chunk-U7VECK2G.js.map +0 -1
- package/dist/chunk-V3VLOOSW.cjs +0 -36
- package/dist/chunk-V3VLOOSW.cjs.map +0 -1
- package/dist/chunk-VSM3NLUX.cjs.map +0 -1
- package/dist/chunk-VZC4BWWH.cjs.map +0 -1
- package/dist/chunk-W3DD3XP5.js.map +0 -1
- package/dist/chunk-WQSGX6XA.cjs.map +0 -1
- package/dist/chunk-WTYNK7Q4.js.map +0 -1
- package/dist/chunk-XXBWX7DT.js.map +0 -1
- package/dist/chunk-Y63IFHEZ.cjs.map +0 -1
- package/dist/chunk-ZCVTH3CH.cjs.map +0 -1
- package/dist/models-dev-6PRLJKVZ.js +0 -3
- package/dist/models-dev-WHMI5G6Y.cjs +0 -12
- package/dist/netlify-46I3SNNV.cjs +0 -12
- package/dist/netlify-EBQ6YUC6.js +0 -3
- package/dist/provider-registry-HDG6UMUC.js +0 -3
- package/dist/provider-registry-RP2W4B24.cjs +0 -40
- package/dist/registry-generator-JPCV47SC.cjs.map +0 -1
- package/dist/registry-generator-XD4FPZTU.js.map +0 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { WritableStream } from 'stream/web';
|
|
1
|
+
import type { WritableStream } from 'node:stream/web';
|
|
2
2
|
import type { ToolSet } from 'ai-v5';
|
|
3
3
|
import type { OutputSchema } from '../../../stream/base/schema.js';
|
|
4
4
|
import type { ChunkType } from '../../../stream/types.js';
|
|
@@ -69,8 +69,8 @@ export declare function createAgenticLoopWorkflow<Tools extends ToolSet = ToolSe
|
|
|
69
69
|
steps: any[];
|
|
70
70
|
text?: string | undefined;
|
|
71
71
|
reasoning?: any[] | undefined;
|
|
72
|
-
files?: any[] | undefined;
|
|
73
72
|
sources?: any[] | undefined;
|
|
73
|
+
files?: any[] | undefined;
|
|
74
74
|
toolCalls?: any[] | undefined;
|
|
75
75
|
toolResults?: any[] | undefined;
|
|
76
76
|
reasoningText?: string | undefined;
|
|
@@ -89,8 +89,8 @@ export declare function createAgenticLoopWorkflow<Tools extends ToolSet = ToolSe
|
|
|
89
89
|
steps: any[];
|
|
90
90
|
text?: string | undefined;
|
|
91
91
|
reasoning?: any[] | undefined;
|
|
92
|
-
files?: any[] | undefined;
|
|
93
92
|
sources?: any[] | undefined;
|
|
93
|
+
files?: any[] | undefined;
|
|
94
94
|
toolCalls?: any[] | undefined;
|
|
95
95
|
toolResults?: any[] | undefined;
|
|
96
96
|
reasoningText?: string | undefined;
|
|
@@ -206,6 +206,20 @@ export declare function createAgenticLoopWorkflow<Tools extends ToolSet = ToolSe
|
|
|
206
206
|
} | undefined;
|
|
207
207
|
}>;
|
|
208
208
|
}, "strip", import("zod").ZodTypeAny, {
|
|
209
|
+
metadata: {
|
|
210
|
+
id?: string | undefined;
|
|
211
|
+
providerMetadata?: Record<string, any> | undefined;
|
|
212
|
+
modelId?: string | undefined;
|
|
213
|
+
model?: string | undefined;
|
|
214
|
+
headers?: Record<string, string> | undefined;
|
|
215
|
+
request?: Record<string, any> | undefined;
|
|
216
|
+
timestamp?: Date | undefined;
|
|
217
|
+
modelMetadata?: {
|
|
218
|
+
modelId: string;
|
|
219
|
+
modelVersion: string;
|
|
220
|
+
modelProvider: string;
|
|
221
|
+
} | undefined;
|
|
222
|
+
};
|
|
209
223
|
output: {
|
|
210
224
|
usage: {
|
|
211
225
|
inputTokens: number;
|
|
@@ -217,8 +231,8 @@ export declare function createAgenticLoopWorkflow<Tools extends ToolSet = ToolSe
|
|
|
217
231
|
steps: any[];
|
|
218
232
|
text?: string | undefined;
|
|
219
233
|
reasoning?: any[] | undefined;
|
|
220
|
-
files?: any[] | undefined;
|
|
221
234
|
sources?: any[] | undefined;
|
|
235
|
+
files?: any[] | undefined;
|
|
222
236
|
toolCalls?: any[] | undefined;
|
|
223
237
|
toolResults?: any[] | undefined;
|
|
224
238
|
reasoningText?: string | undefined;
|
|
@@ -233,20 +247,6 @@ export declare function createAgenticLoopWorkflow<Tools extends ToolSet = ToolSe
|
|
|
233
247
|
all: any[];
|
|
234
248
|
nonUser: any[];
|
|
235
249
|
};
|
|
236
|
-
metadata: {
|
|
237
|
-
id?: string | undefined;
|
|
238
|
-
providerMetadata?: Record<string, any> | undefined;
|
|
239
|
-
modelId?: string | undefined;
|
|
240
|
-
model?: string | undefined;
|
|
241
|
-
headers?: Record<string, string> | undefined;
|
|
242
|
-
request?: Record<string, any> | undefined;
|
|
243
|
-
timestamp?: Date | undefined;
|
|
244
|
-
modelMetadata?: {
|
|
245
|
-
modelId: string;
|
|
246
|
-
modelVersion: string;
|
|
247
|
-
modelProvider: string;
|
|
248
|
-
} | undefined;
|
|
249
|
-
};
|
|
250
250
|
stepResult: {
|
|
251
251
|
reason: string;
|
|
252
252
|
isContinued: boolean;
|
|
@@ -264,6 +264,20 @@ export declare function createAgenticLoopWorkflow<Tools extends ToolSet = ToolSe
|
|
|
264
264
|
} | undefined;
|
|
265
265
|
};
|
|
266
266
|
}, {
|
|
267
|
+
metadata: {
|
|
268
|
+
id?: string | undefined;
|
|
269
|
+
providerMetadata?: Record<string, any> | undefined;
|
|
270
|
+
modelId?: string | undefined;
|
|
271
|
+
model?: string | undefined;
|
|
272
|
+
headers?: Record<string, string> | undefined;
|
|
273
|
+
request?: Record<string, any> | undefined;
|
|
274
|
+
timestamp?: Date | undefined;
|
|
275
|
+
modelMetadata?: {
|
|
276
|
+
modelId: string;
|
|
277
|
+
modelVersion: string;
|
|
278
|
+
modelProvider: string;
|
|
279
|
+
} | undefined;
|
|
280
|
+
};
|
|
267
281
|
output: {
|
|
268
282
|
usage: {
|
|
269
283
|
inputTokens: number;
|
|
@@ -275,8 +289,8 @@ export declare function createAgenticLoopWorkflow<Tools extends ToolSet = ToolSe
|
|
|
275
289
|
steps: any[];
|
|
276
290
|
text?: string | undefined;
|
|
277
291
|
reasoning?: any[] | undefined;
|
|
278
|
-
files?: any[] | undefined;
|
|
279
292
|
sources?: any[] | undefined;
|
|
293
|
+
files?: any[] | undefined;
|
|
280
294
|
toolCalls?: any[] | undefined;
|
|
281
295
|
toolResults?: any[] | undefined;
|
|
282
296
|
reasoningText?: string | undefined;
|
|
@@ -291,20 +305,6 @@ export declare function createAgenticLoopWorkflow<Tools extends ToolSet = ToolSe
|
|
|
291
305
|
all: any[];
|
|
292
306
|
nonUser: any[];
|
|
293
307
|
};
|
|
294
|
-
metadata: {
|
|
295
|
-
id?: string | undefined;
|
|
296
|
-
providerMetadata?: Record<string, any> | undefined;
|
|
297
|
-
modelId?: string | undefined;
|
|
298
|
-
model?: string | undefined;
|
|
299
|
-
headers?: Record<string, string> | undefined;
|
|
300
|
-
request?: Record<string, any> | undefined;
|
|
301
|
-
timestamp?: Date | undefined;
|
|
302
|
-
modelMetadata?: {
|
|
303
|
-
modelId: string;
|
|
304
|
-
modelVersion: string;
|
|
305
|
-
modelProvider: string;
|
|
306
|
-
} | undefined;
|
|
307
|
-
};
|
|
308
308
|
stepResult: {
|
|
309
309
|
reason: string;
|
|
310
310
|
isContinued: boolean;
|
|
@@ -379,8 +379,8 @@ export declare function createAgenticLoopWorkflow<Tools extends ToolSet = ToolSe
|
|
|
379
379
|
steps: any[];
|
|
380
380
|
text?: string | undefined;
|
|
381
381
|
reasoning?: any[] | undefined;
|
|
382
|
-
files?: any[] | undefined;
|
|
383
382
|
sources?: any[] | undefined;
|
|
383
|
+
files?: any[] | undefined;
|
|
384
384
|
toolCalls?: any[] | undefined;
|
|
385
385
|
toolResults?: any[] | undefined;
|
|
386
386
|
reasoningText?: string | undefined;
|
|
@@ -399,8 +399,8 @@ export declare function createAgenticLoopWorkflow<Tools extends ToolSet = ToolSe
|
|
|
399
399
|
steps: any[];
|
|
400
400
|
text?: string | undefined;
|
|
401
401
|
reasoning?: any[] | undefined;
|
|
402
|
-
files?: any[] | undefined;
|
|
403
402
|
sources?: any[] | undefined;
|
|
403
|
+
files?: any[] | undefined;
|
|
404
404
|
toolCalls?: any[] | undefined;
|
|
405
405
|
toolResults?: any[] | undefined;
|
|
406
406
|
reasoningText?: string | undefined;
|
|
@@ -516,6 +516,20 @@ export declare function createAgenticLoopWorkflow<Tools extends ToolSet = ToolSe
|
|
|
516
516
|
} | undefined;
|
|
517
517
|
}>;
|
|
518
518
|
}, "strip", import("zod").ZodTypeAny, {
|
|
519
|
+
metadata: {
|
|
520
|
+
id?: string | undefined;
|
|
521
|
+
providerMetadata?: Record<string, any> | undefined;
|
|
522
|
+
modelId?: string | undefined;
|
|
523
|
+
model?: string | undefined;
|
|
524
|
+
headers?: Record<string, string> | undefined;
|
|
525
|
+
request?: Record<string, any> | undefined;
|
|
526
|
+
timestamp?: Date | undefined;
|
|
527
|
+
modelMetadata?: {
|
|
528
|
+
modelId: string;
|
|
529
|
+
modelVersion: string;
|
|
530
|
+
modelProvider: string;
|
|
531
|
+
} | undefined;
|
|
532
|
+
};
|
|
519
533
|
output: {
|
|
520
534
|
usage: {
|
|
521
535
|
inputTokens: number;
|
|
@@ -527,8 +541,8 @@ export declare function createAgenticLoopWorkflow<Tools extends ToolSet = ToolSe
|
|
|
527
541
|
steps: any[];
|
|
528
542
|
text?: string | undefined;
|
|
529
543
|
reasoning?: any[] | undefined;
|
|
530
|
-
files?: any[] | undefined;
|
|
531
544
|
sources?: any[] | undefined;
|
|
545
|
+
files?: any[] | undefined;
|
|
532
546
|
toolCalls?: any[] | undefined;
|
|
533
547
|
toolResults?: any[] | undefined;
|
|
534
548
|
reasoningText?: string | undefined;
|
|
@@ -543,20 +557,6 @@ export declare function createAgenticLoopWorkflow<Tools extends ToolSet = ToolSe
|
|
|
543
557
|
all: any[];
|
|
544
558
|
nonUser: any[];
|
|
545
559
|
};
|
|
546
|
-
metadata: {
|
|
547
|
-
id?: string | undefined;
|
|
548
|
-
providerMetadata?: Record<string, any> | undefined;
|
|
549
|
-
modelId?: string | undefined;
|
|
550
|
-
model?: string | undefined;
|
|
551
|
-
headers?: Record<string, string> | undefined;
|
|
552
|
-
request?: Record<string, any> | undefined;
|
|
553
|
-
timestamp?: Date | undefined;
|
|
554
|
-
modelMetadata?: {
|
|
555
|
-
modelId: string;
|
|
556
|
-
modelVersion: string;
|
|
557
|
-
modelProvider: string;
|
|
558
|
-
} | undefined;
|
|
559
|
-
};
|
|
560
560
|
stepResult: {
|
|
561
561
|
reason: string;
|
|
562
562
|
isContinued: boolean;
|
|
@@ -574,6 +574,20 @@ export declare function createAgenticLoopWorkflow<Tools extends ToolSet = ToolSe
|
|
|
574
574
|
} | undefined;
|
|
575
575
|
};
|
|
576
576
|
}, {
|
|
577
|
+
metadata: {
|
|
578
|
+
id?: string | undefined;
|
|
579
|
+
providerMetadata?: Record<string, any> | undefined;
|
|
580
|
+
modelId?: string | undefined;
|
|
581
|
+
model?: string | undefined;
|
|
582
|
+
headers?: Record<string, string> | undefined;
|
|
583
|
+
request?: Record<string, any> | undefined;
|
|
584
|
+
timestamp?: Date | undefined;
|
|
585
|
+
modelMetadata?: {
|
|
586
|
+
modelId: string;
|
|
587
|
+
modelVersion: string;
|
|
588
|
+
modelProvider: string;
|
|
589
|
+
} | undefined;
|
|
590
|
+
};
|
|
577
591
|
output: {
|
|
578
592
|
usage: {
|
|
579
593
|
inputTokens: number;
|
|
@@ -585,8 +599,8 @@ export declare function createAgenticLoopWorkflow<Tools extends ToolSet = ToolSe
|
|
|
585
599
|
steps: any[];
|
|
586
600
|
text?: string | undefined;
|
|
587
601
|
reasoning?: any[] | undefined;
|
|
588
|
-
files?: any[] | undefined;
|
|
589
602
|
sources?: any[] | undefined;
|
|
603
|
+
files?: any[] | undefined;
|
|
590
604
|
toolCalls?: any[] | undefined;
|
|
591
605
|
toolResults?: any[] | undefined;
|
|
592
606
|
reasoningText?: string | undefined;
|
|
@@ -601,20 +615,6 @@ export declare function createAgenticLoopWorkflow<Tools extends ToolSet = ToolSe
|
|
|
601
615
|
all: any[];
|
|
602
616
|
nonUser: any[];
|
|
603
617
|
};
|
|
604
|
-
metadata: {
|
|
605
|
-
id?: string | undefined;
|
|
606
|
-
providerMetadata?: Record<string, any> | undefined;
|
|
607
|
-
modelId?: string | undefined;
|
|
608
|
-
model?: string | undefined;
|
|
609
|
-
headers?: Record<string, string> | undefined;
|
|
610
|
-
request?: Record<string, any> | undefined;
|
|
611
|
-
timestamp?: Date | undefined;
|
|
612
|
-
modelMetadata?: {
|
|
613
|
-
modelId: string;
|
|
614
|
-
modelVersion: string;
|
|
615
|
-
modelProvider: string;
|
|
616
|
-
} | undefined;
|
|
617
|
-
};
|
|
618
618
|
stepResult: {
|
|
619
619
|
reason: string;
|
|
620
620
|
isContinued: boolean;
|
|
@@ -689,8 +689,8 @@ export declare function createAgenticLoopWorkflow<Tools extends ToolSet = ToolSe
|
|
|
689
689
|
steps: any[];
|
|
690
690
|
text?: string | undefined;
|
|
691
691
|
reasoning?: any[] | undefined;
|
|
692
|
-
files?: any[] | undefined;
|
|
693
692
|
sources?: any[] | undefined;
|
|
693
|
+
files?: any[] | undefined;
|
|
694
694
|
toolCalls?: any[] | undefined;
|
|
695
695
|
toolResults?: any[] | undefined;
|
|
696
696
|
reasoningText?: string | undefined;
|
|
@@ -709,8 +709,8 @@ export declare function createAgenticLoopWorkflow<Tools extends ToolSet = ToolSe
|
|
|
709
709
|
steps: any[];
|
|
710
710
|
text?: string | undefined;
|
|
711
711
|
reasoning?: any[] | undefined;
|
|
712
|
-
files?: any[] | undefined;
|
|
713
712
|
sources?: any[] | undefined;
|
|
713
|
+
files?: any[] | undefined;
|
|
714
714
|
toolCalls?: any[] | undefined;
|
|
715
715
|
toolResults?: any[] | undefined;
|
|
716
716
|
reasoningText?: string | undefined;
|
|
@@ -826,6 +826,20 @@ export declare function createAgenticLoopWorkflow<Tools extends ToolSet = ToolSe
|
|
|
826
826
|
} | undefined;
|
|
827
827
|
}>;
|
|
828
828
|
}, "strip", import("zod").ZodTypeAny, {
|
|
829
|
+
metadata: {
|
|
830
|
+
id?: string | undefined;
|
|
831
|
+
providerMetadata?: Record<string, any> | undefined;
|
|
832
|
+
modelId?: string | undefined;
|
|
833
|
+
model?: string | undefined;
|
|
834
|
+
headers?: Record<string, string> | undefined;
|
|
835
|
+
request?: Record<string, any> | undefined;
|
|
836
|
+
timestamp?: Date | undefined;
|
|
837
|
+
modelMetadata?: {
|
|
838
|
+
modelId: string;
|
|
839
|
+
modelVersion: string;
|
|
840
|
+
modelProvider: string;
|
|
841
|
+
} | undefined;
|
|
842
|
+
};
|
|
829
843
|
output: {
|
|
830
844
|
usage: {
|
|
831
845
|
inputTokens: number;
|
|
@@ -837,8 +851,8 @@ export declare function createAgenticLoopWorkflow<Tools extends ToolSet = ToolSe
|
|
|
837
851
|
steps: any[];
|
|
838
852
|
text?: string | undefined;
|
|
839
853
|
reasoning?: any[] | undefined;
|
|
840
|
-
files?: any[] | undefined;
|
|
841
854
|
sources?: any[] | undefined;
|
|
855
|
+
files?: any[] | undefined;
|
|
842
856
|
toolCalls?: any[] | undefined;
|
|
843
857
|
toolResults?: any[] | undefined;
|
|
844
858
|
reasoningText?: string | undefined;
|
|
@@ -853,20 +867,6 @@ export declare function createAgenticLoopWorkflow<Tools extends ToolSet = ToolSe
|
|
|
853
867
|
all: any[];
|
|
854
868
|
nonUser: any[];
|
|
855
869
|
};
|
|
856
|
-
metadata: {
|
|
857
|
-
id?: string | undefined;
|
|
858
|
-
providerMetadata?: Record<string, any> | undefined;
|
|
859
|
-
modelId?: string | undefined;
|
|
860
|
-
model?: string | undefined;
|
|
861
|
-
headers?: Record<string, string> | undefined;
|
|
862
|
-
request?: Record<string, any> | undefined;
|
|
863
|
-
timestamp?: Date | undefined;
|
|
864
|
-
modelMetadata?: {
|
|
865
|
-
modelId: string;
|
|
866
|
-
modelVersion: string;
|
|
867
|
-
modelProvider: string;
|
|
868
|
-
} | undefined;
|
|
869
|
-
};
|
|
870
870
|
stepResult: {
|
|
871
871
|
reason: string;
|
|
872
872
|
isContinued: boolean;
|
|
@@ -884,6 +884,20 @@ export declare function createAgenticLoopWorkflow<Tools extends ToolSet = ToolSe
|
|
|
884
884
|
} | undefined;
|
|
885
885
|
};
|
|
886
886
|
}, {
|
|
887
|
+
metadata: {
|
|
888
|
+
id?: string | undefined;
|
|
889
|
+
providerMetadata?: Record<string, any> | undefined;
|
|
890
|
+
modelId?: string | undefined;
|
|
891
|
+
model?: string | undefined;
|
|
892
|
+
headers?: Record<string, string> | undefined;
|
|
893
|
+
request?: Record<string, any> | undefined;
|
|
894
|
+
timestamp?: Date | undefined;
|
|
895
|
+
modelMetadata?: {
|
|
896
|
+
modelId: string;
|
|
897
|
+
modelVersion: string;
|
|
898
|
+
modelProvider: string;
|
|
899
|
+
} | undefined;
|
|
900
|
+
};
|
|
887
901
|
output: {
|
|
888
902
|
usage: {
|
|
889
903
|
inputTokens: number;
|
|
@@ -895,8 +909,8 @@ export declare function createAgenticLoopWorkflow<Tools extends ToolSet = ToolSe
|
|
|
895
909
|
steps: any[];
|
|
896
910
|
text?: string | undefined;
|
|
897
911
|
reasoning?: any[] | undefined;
|
|
898
|
-
files?: any[] | undefined;
|
|
899
912
|
sources?: any[] | undefined;
|
|
913
|
+
files?: any[] | undefined;
|
|
900
914
|
toolCalls?: any[] | undefined;
|
|
901
915
|
toolResults?: any[] | undefined;
|
|
902
916
|
reasoningText?: string | undefined;
|
|
@@ -911,20 +925,6 @@ export declare function createAgenticLoopWorkflow<Tools extends ToolSet = ToolSe
|
|
|
911
925
|
all: any[];
|
|
912
926
|
nonUser: any[];
|
|
913
927
|
};
|
|
914
|
-
metadata: {
|
|
915
|
-
id?: string | undefined;
|
|
916
|
-
providerMetadata?: Record<string, any> | undefined;
|
|
917
|
-
modelId?: string | undefined;
|
|
918
|
-
model?: string | undefined;
|
|
919
|
-
headers?: Record<string, string> | undefined;
|
|
920
|
-
request?: Record<string, any> | undefined;
|
|
921
|
-
timestamp?: Date | undefined;
|
|
922
|
-
modelMetadata?: {
|
|
923
|
-
modelId: string;
|
|
924
|
-
modelVersion: string;
|
|
925
|
-
modelProvider: string;
|
|
926
|
-
} | undefined;
|
|
927
|
-
};
|
|
928
928
|
stepResult: {
|
|
929
929
|
reason: string;
|
|
930
930
|
isContinued: boolean;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/loop/workflows/agentic-loop/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/loop/workflows/agentic-loop/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAC;AACtD,OAAO,KAAK,EAAc,OAAO,EAAE,MAAM,OAAO,CAAC;AAEjD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,6BAA6B,CAAC;AAChE,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,uBAAuB,CAAC;AAGvD,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,aAAa,CAAC;AAM3C,UAAU,iBAAiB,CAAC,KAAK,SAAS,OAAO,GAAG,OAAO,EAAE,MAAM,SAAS,YAAY,GAAG,SAAS,CAClG,SAAQ,OAAO,CAAC,KAAK,EAAE,MAAM,CAAC;IAC9B,UAAU,EAAE,+BAA+B,CAAC,SAAS,CAAC,MAAM,CAAC,CAAC,CAAC;IAC/D,MAAM,EAAE,cAAc,CAAC,SAAS,CAAC,MAAM,CAAC,CAAC,CAAC;CAC3C;AAED,wBAAgB,yBAAyB,CAAC,KAAK,SAAS,OAAO,GAAG,OAAO,EAAE,MAAM,SAAS,YAAY,GAAG,SAAS,EAChH,MAAM,EAAE,iBAAiB,CAAC,KAAK,EAAE,MAAM,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAuHzC"}
|
|
@@ -171,8 +171,8 @@ export declare const llmIterationOutputSchema: z.ZodObject<{
|
|
|
171
171
|
steps: any[];
|
|
172
172
|
text?: string | undefined;
|
|
173
173
|
reasoning?: any[] | undefined;
|
|
174
|
-
files?: any[] | undefined;
|
|
175
174
|
sources?: any[] | undefined;
|
|
175
|
+
files?: any[] | undefined;
|
|
176
176
|
toolCalls?: any[] | undefined;
|
|
177
177
|
toolResults?: any[] | undefined;
|
|
178
178
|
reasoningText?: string | undefined;
|
|
@@ -191,8 +191,8 @@ export declare const llmIterationOutputSchema: z.ZodObject<{
|
|
|
191
191
|
steps: any[];
|
|
192
192
|
text?: string | undefined;
|
|
193
193
|
reasoning?: any[] | undefined;
|
|
194
|
-
files?: any[] | undefined;
|
|
195
194
|
sources?: any[] | undefined;
|
|
195
|
+
files?: any[] | undefined;
|
|
196
196
|
toolCalls?: any[] | undefined;
|
|
197
197
|
toolResults?: any[] | undefined;
|
|
198
198
|
reasoningText?: string | undefined;
|
|
@@ -308,6 +308,20 @@ export declare const llmIterationOutputSchema: z.ZodObject<{
|
|
|
308
308
|
} | undefined;
|
|
309
309
|
}>;
|
|
310
310
|
}, "strip", z.ZodTypeAny, {
|
|
311
|
+
metadata: {
|
|
312
|
+
id?: string | undefined;
|
|
313
|
+
providerMetadata?: Record<string, any> | undefined;
|
|
314
|
+
modelId?: string | undefined;
|
|
315
|
+
model?: string | undefined;
|
|
316
|
+
headers?: Record<string, string> | undefined;
|
|
317
|
+
request?: Record<string, any> | undefined;
|
|
318
|
+
timestamp?: Date | undefined;
|
|
319
|
+
modelMetadata?: {
|
|
320
|
+
modelId: string;
|
|
321
|
+
modelVersion: string;
|
|
322
|
+
modelProvider: string;
|
|
323
|
+
} | undefined;
|
|
324
|
+
};
|
|
311
325
|
output: {
|
|
312
326
|
usage: {
|
|
313
327
|
inputTokens: number;
|
|
@@ -319,8 +333,8 @@ export declare const llmIterationOutputSchema: z.ZodObject<{
|
|
|
319
333
|
steps: any[];
|
|
320
334
|
text?: string | undefined;
|
|
321
335
|
reasoning?: any[] | undefined;
|
|
322
|
-
files?: any[] | undefined;
|
|
323
336
|
sources?: any[] | undefined;
|
|
337
|
+
files?: any[] | undefined;
|
|
324
338
|
toolCalls?: any[] | undefined;
|
|
325
339
|
toolResults?: any[] | undefined;
|
|
326
340
|
reasoningText?: string | undefined;
|
|
@@ -335,20 +349,6 @@ export declare const llmIterationOutputSchema: z.ZodObject<{
|
|
|
335
349
|
all: any[];
|
|
336
350
|
nonUser: any[];
|
|
337
351
|
};
|
|
338
|
-
metadata: {
|
|
339
|
-
id?: string | undefined;
|
|
340
|
-
providerMetadata?: Record<string, any> | undefined;
|
|
341
|
-
modelId?: string | undefined;
|
|
342
|
-
model?: string | undefined;
|
|
343
|
-
headers?: Record<string, string> | undefined;
|
|
344
|
-
request?: Record<string, any> | undefined;
|
|
345
|
-
timestamp?: Date | undefined;
|
|
346
|
-
modelMetadata?: {
|
|
347
|
-
modelId: string;
|
|
348
|
-
modelVersion: string;
|
|
349
|
-
modelProvider: string;
|
|
350
|
-
} | undefined;
|
|
351
|
-
};
|
|
352
352
|
stepResult: {
|
|
353
353
|
reason: string;
|
|
354
354
|
isContinued: boolean;
|
|
@@ -366,6 +366,20 @@ export declare const llmIterationOutputSchema: z.ZodObject<{
|
|
|
366
366
|
} | undefined;
|
|
367
367
|
};
|
|
368
368
|
}, {
|
|
369
|
+
metadata: {
|
|
370
|
+
id?: string | undefined;
|
|
371
|
+
providerMetadata?: Record<string, any> | undefined;
|
|
372
|
+
modelId?: string | undefined;
|
|
373
|
+
model?: string | undefined;
|
|
374
|
+
headers?: Record<string, string> | undefined;
|
|
375
|
+
request?: Record<string, any> | undefined;
|
|
376
|
+
timestamp?: Date | undefined;
|
|
377
|
+
modelMetadata?: {
|
|
378
|
+
modelId: string;
|
|
379
|
+
modelVersion: string;
|
|
380
|
+
modelProvider: string;
|
|
381
|
+
} | undefined;
|
|
382
|
+
};
|
|
369
383
|
output: {
|
|
370
384
|
usage: {
|
|
371
385
|
inputTokens: number;
|
|
@@ -377,8 +391,8 @@ export declare const llmIterationOutputSchema: z.ZodObject<{
|
|
|
377
391
|
steps: any[];
|
|
378
392
|
text?: string | undefined;
|
|
379
393
|
reasoning?: any[] | undefined;
|
|
380
|
-
files?: any[] | undefined;
|
|
381
394
|
sources?: any[] | undefined;
|
|
395
|
+
files?: any[] | undefined;
|
|
382
396
|
toolCalls?: any[] | undefined;
|
|
383
397
|
toolResults?: any[] | undefined;
|
|
384
398
|
reasoningText?: string | undefined;
|
|
@@ -393,20 +407,6 @@ export declare const llmIterationOutputSchema: z.ZodObject<{
|
|
|
393
407
|
all: any[];
|
|
394
408
|
nonUser: any[];
|
|
395
409
|
};
|
|
396
|
-
metadata: {
|
|
397
|
-
id?: string | undefined;
|
|
398
|
-
providerMetadata?: Record<string, any> | undefined;
|
|
399
|
-
modelId?: string | undefined;
|
|
400
|
-
model?: string | undefined;
|
|
401
|
-
headers?: Record<string, string> | undefined;
|
|
402
|
-
request?: Record<string, any> | undefined;
|
|
403
|
-
timestamp?: Date | undefined;
|
|
404
|
-
modelMetadata?: {
|
|
405
|
-
modelId: string;
|
|
406
|
-
modelVersion: string;
|
|
407
|
-
modelProvider: string;
|
|
408
|
-
} | undefined;
|
|
409
|
-
};
|
|
410
410
|
stepResult: {
|
|
411
411
|
reason: string;
|
|
412
412
|
isContinued: boolean;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"stream.d.ts","sourceRoot":"","sources":["../../../src/loop/workflows/stream.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAkB,MAAM,
|
|
1
|
+
{"version":3,"file":"stream.d.ts","sourceRoot":"","sources":["../../../src/loop/workflows/stream.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAkB,MAAM,iBAAiB,CAAC;AACjE,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,OAAO,CAAC;AAErC,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,0BAA0B,CAAC;AAC7D,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAC;AAEpD,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,UAAU,CAAC;AAGxC;;;;;;;;;;;GAWG;AACH,wBAAgB,gBAAgB,CAAC,UAAU,EAAE,+BAA+B,CAAC,GAAG,CAAC,GAAG,OAAO,CAE1F;AAED,wBAAgB,kBAAkB,CAChC,KAAK,SAAS,OAAO,GAAG,OAAO,EAC/B,MAAM,SAAS,YAAY,GAAG,SAAS,GAAG,SAAS,EACnD,EACA,aAAa,EACb,mBAAmB,EACnB,MAAM,EACN,UAAU,EACV,aAAa,EACb,SAAS,EACT,SAAS,EACT,KAAK,EACL,WAAW,EACX,cAAc,EACd,WAAW,EACX,OAAO,EACP,UAAU,EACV,GAAG,IAAI,EACR,EAAE,OAAO,CAAC,KAAK,EAAE,MAAM,CAAC,qCA8GxB"}
|
package/dist/mastra/index.cjs
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var chunkOIMB2SNZ_cjs = require('../chunk-OIMB2SNZ.cjs');
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
|
|
7
7
|
Object.defineProperty(exports, "Mastra", {
|
|
8
8
|
enumerable: true,
|
|
9
|
-
get: function () { return
|
|
9
|
+
get: function () { return chunkOIMB2SNZ_cjs.Mastra; }
|
|
10
10
|
});
|
|
11
11
|
//# sourceMappingURL=index.cjs.map
|
|
12
12
|
//# sourceMappingURL=index.cjs.map
|
package/dist/mastra/index.d.ts
CHANGED
|
@@ -11,6 +11,7 @@ import type { IMastraLogger } from '../logger/index.js';
|
|
|
11
11
|
import type { MCPServerBase } from '../mcp/index.js';
|
|
12
12
|
import type { ObservabilityEntrypoint } from '../observability/index.js';
|
|
13
13
|
import type { Processor } from '../processors/index.js';
|
|
14
|
+
import type { MastraServerBase } from '../server/base.js';
|
|
14
15
|
import type { Middleware, ServerConfig } from '../server/types.js';
|
|
15
16
|
import type { MastraStorage, WorkflowRuns } from '../storage/index.js';
|
|
16
17
|
import type { ToolAction } from '../tools/index.js';
|
|
@@ -49,7 +50,7 @@ import type { Workflow } from '../workflows/index.js';
|
|
|
49
50
|
* });
|
|
50
51
|
* ```
|
|
51
52
|
*/
|
|
52
|
-
export interface Config<TAgents extends Record<string, Agent<any>> = Record<string, Agent<any>>, TWorkflows extends Record<string, Workflow<any, any, any, any, any, any>> = Record<string, Workflow<any, any, any, any, any, any>>, TVectors extends Record<string, MastraVector<any>> = Record<string, MastraVector<any>>, TTTS extends Record<string, MastraTTS> = Record<string, MastraTTS>, TLogger extends IMastraLogger = IMastraLogger, TMCPServers extends Record<string, MCPServerBase
|
|
53
|
+
export interface Config<TAgents extends Record<string, Agent<any>> = Record<string, Agent<any>>, TWorkflows extends Record<string, Workflow<any, any, any, any, any, any>> = Record<string, Workflow<any, any, any, any, any, any>>, TVectors extends Record<string, MastraVector<any>> = Record<string, MastraVector<any>>, TTTS extends Record<string, MastraTTS> = Record<string, MastraTTS>, TLogger extends IMastraLogger = IMastraLogger, TMCPServers extends Record<string, MCPServerBase<any>> = Record<string, MCPServerBase<any>>, TScorers extends Record<string, MastraScorer<any, any, any, any>> = Record<string, MastraScorer<any, any, any, any>>, TTools extends Record<string, ToolAction<any, any, any, any, any, any>> = Record<string, ToolAction<any, any, any, any, any, any>>, TProcessors extends Record<string, Processor<any>> = Record<string, Processor<any>>> {
|
|
53
54
|
/**
|
|
54
55
|
* Agents are autonomous systems that can make decisions and take actions.
|
|
55
56
|
*/
|
|
@@ -178,7 +179,7 @@ export interface Config<TAgents extends Record<string, Agent<any>> = Record<stri
|
|
|
178
179
|
* });
|
|
179
180
|
* ```
|
|
180
181
|
*/
|
|
181
|
-
export declare class Mastra<TAgents extends Record<string, Agent<any>> = Record<string, Agent<any>>, TWorkflows extends Record<string, Workflow<any, any, any, any, any, any>> = Record<string, Workflow<any, any, any, any, any, any>>, TVectors extends Record<string, MastraVector<any>> = Record<string, MastraVector<any>>, TTTS extends Record<string, MastraTTS> = Record<string, MastraTTS>, TLogger extends IMastraLogger = IMastraLogger, TMCPServers extends Record<string, MCPServerBase
|
|
182
|
+
export declare class Mastra<TAgents extends Record<string, Agent<any>> = Record<string, Agent<any>>, TWorkflows extends Record<string, Workflow<any, any, any, any, any, any>> = Record<string, Workflow<any, any, any, any, any, any>>, TVectors extends Record<string, MastraVector<any>> = Record<string, MastraVector<any>>, TTTS extends Record<string, MastraTTS> = Record<string, MastraTTS>, TLogger extends IMastraLogger = IMastraLogger, TMCPServers extends Record<string, MCPServerBase<any>> = Record<string, MCPServerBase<any>>, TScorers extends Record<string, MastraScorer<any, any, any, any>> = Record<string, MastraScorer<any, any, any, any>>, TTools extends Record<string, ToolAction<any, any, any, any, any, any>> = Record<string, ToolAction<any, any, any, any, any, any>>, TProcessors extends Record<string, Processor<any>> = Record<string, Processor<any>>> {
|
|
182
183
|
#private;
|
|
183
184
|
get pubsub(): PubSub;
|
|
184
185
|
/**
|
|
@@ -301,7 +302,7 @@ export declare class Mastra<TAgents extends Record<string, Agent<any>> = Record<
|
|
|
301
302
|
* const sameAgent = mastra.getAgentById(assistant.id);
|
|
302
303
|
* ```
|
|
303
304
|
*/
|
|
304
|
-
getAgentById(id:
|
|
305
|
+
getAgentById<TAgentName extends keyof TAgents>(id: TAgents[TAgentName]['id']): TAgents[TAgentName];
|
|
305
306
|
/**
|
|
306
307
|
* Returns all registered agents as a record keyed by their names.
|
|
307
308
|
*
|
|
@@ -402,7 +403,7 @@ export declare class Mastra<TAgents extends Record<string, Agent<any>> = Record<
|
|
|
402
403
|
* const vectorStore = mastra.getVectorById('chroma-123');
|
|
403
404
|
* ```
|
|
404
405
|
*/
|
|
405
|
-
getVectorById(id:
|
|
406
|
+
getVectorById<TVectorName extends keyof TVectors>(id: TVectors[TVectorName]['id']): TVectors[TVectorName];
|
|
406
407
|
/**
|
|
407
408
|
* Returns all registered vector stores as a record keyed by their names.
|
|
408
409
|
*
|
|
@@ -532,7 +533,7 @@ export declare class Mastra<TAgents extends Record<string, Agent<any>> = Record<
|
|
|
532
533
|
* console.log(sameWorkflow.name); // "process-data"
|
|
533
534
|
* ```
|
|
534
535
|
*/
|
|
535
|
-
getWorkflowById(id:
|
|
536
|
+
getWorkflowById<TWorkflowName extends keyof TWorkflows>(id: TWorkflows[TWorkflowName]['id']): TWorkflows[TWorkflowName];
|
|
536
537
|
listActiveWorkflowRuns(): Promise<WorkflowRuns>;
|
|
537
538
|
restartAllActiveWorkflowRuns(): Promise<void>;
|
|
538
539
|
/**
|
|
@@ -645,7 +646,7 @@ export declare class Mastra<TAgents extends Record<string, Agent<any>> = Record<
|
|
|
645
646
|
* });
|
|
646
647
|
* ```
|
|
647
648
|
*/
|
|
648
|
-
getScorerById(id:
|
|
649
|
+
getScorerById<TScorerName extends keyof TScorers>(id: TScorers[TScorerName]['id']): TScorers[TScorerName];
|
|
649
650
|
/**
|
|
650
651
|
* Retrieves a specific tool by registration key.
|
|
651
652
|
*
|
|
@@ -680,7 +681,7 @@ export declare class Mastra<TAgents extends Record<string, Agent<any>> = Record<
|
|
|
680
681
|
* const tool = mastra.getToolById('calculator-tool-id');
|
|
681
682
|
* ```
|
|
682
683
|
*/
|
|
683
|
-
getToolById(id:
|
|
684
|
+
getToolById<TToolName extends keyof TTools>(id: TTools[TToolName]['id']): TTools[TToolName];
|
|
684
685
|
/**
|
|
685
686
|
* Lists all configured tools.
|
|
686
687
|
*
|
|
@@ -755,7 +756,7 @@ export declare class Mastra<TAgents extends Record<string, Agent<any>> = Record<
|
|
|
755
756
|
* const processor = mastra.getProcessorById('validator-processor-id');
|
|
756
757
|
* ```
|
|
757
758
|
*/
|
|
758
|
-
getProcessorById(id:
|
|
759
|
+
getProcessorById<TProcessorName extends keyof TProcessors>(id: TProcessors[TProcessorName]['id']): TProcessors[TProcessorName];
|
|
759
760
|
/**
|
|
760
761
|
* Lists all configured processors.
|
|
761
762
|
*
|
|
@@ -935,6 +936,60 @@ export declare class Mastra<TAgents extends Record<string, Agent<any>> = Record<
|
|
|
935
936
|
getServerCache(): MastraServerCache;
|
|
936
937
|
setServerMiddleware(serverMiddleware: Middleware | Middleware[]): void;
|
|
937
938
|
getServer(): ServerConfig | undefined;
|
|
939
|
+
/**
|
|
940
|
+
* Sets the server adapter for this Mastra instance.
|
|
941
|
+
*
|
|
942
|
+
* The server adapter provides access to the underlying server app (e.g., Hono, Express)
|
|
943
|
+
* and allows users to call routes directly via `app.fetch()` instead of making HTTP requests.
|
|
944
|
+
*
|
|
945
|
+
* This is typically called by `createHonoServer` or similar factory functions during
|
|
946
|
+
* server initialization.
|
|
947
|
+
*
|
|
948
|
+
* @param adapter - The server adapter instance (e.g., MastraServer from @mastra/hono or @mastra/express)
|
|
949
|
+
*
|
|
950
|
+
* @example
|
|
951
|
+
* ```typescript
|
|
952
|
+
* const app = new Hono();
|
|
953
|
+
* const adapter = new MastraServer({ app, mastra });
|
|
954
|
+
* mastra.setMastraServer(adapter);
|
|
955
|
+
* ```
|
|
956
|
+
*/
|
|
957
|
+
setMastraServer(adapter: MastraServerBase): void;
|
|
958
|
+
/**
|
|
959
|
+
* Gets the server adapter for this Mastra instance.
|
|
960
|
+
*
|
|
961
|
+
* @returns The server adapter, or undefined if not set
|
|
962
|
+
*
|
|
963
|
+
* @example
|
|
964
|
+
* ```typescript
|
|
965
|
+
* const adapter = mastra.getMastraServer();
|
|
966
|
+
* if (adapter) {
|
|
967
|
+
* const app = adapter.getApp<Hono>();
|
|
968
|
+
* }
|
|
969
|
+
* ```
|
|
970
|
+
*/
|
|
971
|
+
getMastraServer(): MastraServerBase | undefined;
|
|
972
|
+
/**
|
|
973
|
+
* Gets the server app from the server adapter.
|
|
974
|
+
*
|
|
975
|
+
* This is a convenience method that calls `getMastraServer()?.getApp<T>()`.
|
|
976
|
+
* Use this to access the underlying server framework's app instance (e.g., Hono, Express)
|
|
977
|
+
* for direct operations like calling routes via `app.fetch()`.
|
|
978
|
+
*
|
|
979
|
+
* @template T - The expected type of the app (e.g., Hono, Express Application)
|
|
980
|
+
* @returns The server app, or undefined if no adapter is set
|
|
981
|
+
*
|
|
982
|
+
* @example
|
|
983
|
+
* ```typescript
|
|
984
|
+
* // After createHonoServer() is called:
|
|
985
|
+
* const app = mastra.getServerApp<Hono>();
|
|
986
|
+
*
|
|
987
|
+
* // Call routes directly without HTTP overhead
|
|
988
|
+
* const response = await app?.fetch(new Request('http://localhost/health'));
|
|
989
|
+
* const data = await response?.json();
|
|
990
|
+
* ```
|
|
991
|
+
*/
|
|
992
|
+
getServerApp<T = unknown>(): T | undefined;
|
|
938
993
|
getBundlerConfig(): BundlerConfig | undefined;
|
|
939
994
|
listLogsByRunId({ runId, transportId, fromDate, toDate, logLevel, filters, page, perPage, }: {
|
|
940
995
|
runId: string;
|
|
@@ -1050,7 +1105,7 @@ export declare class Mastra<TAgents extends Record<string, Agent<any>> = Record<
|
|
|
1050
1105
|
* }
|
|
1051
1106
|
* ```
|
|
1052
1107
|
*/
|
|
1053
|
-
getMCPServerById(serverId:
|
|
1108
|
+
getMCPServerById<TMCPServerName extends keyof TMCPServers>(serverId: TMCPServers[TMCPServerName]['id'], version?: string): TMCPServers[TMCPServerName] | undefined;
|
|
1054
1109
|
addTopicListener(topic: string, listener: (event: any) => Promise<void>): Promise<void>;
|
|
1055
1110
|
removeTopicListener(topic: string, listener: (event: any) => Promise<void>): Promise<void>;
|
|
1056
1111
|
startEventEngine(): Promise<void>;
|