@mastra/core 1.87.0 → 1.88.0-alpha.1
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/_types/@internal_ai-v6@0.0.100/dist/index.d.ts +97 -2049
- package/dist/_types/@internal_core@0.1.4/dist/knowledge-compat/index.d.ts +17 -1
- package/dist/agent/agent.d.ts +10 -2
- package/dist/agent/durable/create-evented-agent.d.ts +2 -1
- package/dist/agent/durable/execution-engine.d.ts +4 -2
- package/dist/agent/durable/index.cjs +3 -2
- package/dist/agent/durable/index.js +3 -2
- package/dist/agent/durable/segment-spans.d.ts +7 -0
- package/dist/agent/durable/stored-signal-drain.d.ts +1 -1
- package/dist/agent/durable/types.d.ts +6 -0
- package/dist/agent/index.cjs +2 -2
- package/dist/agent/index.js +2 -2
- package/dist/agent/request-context-snapshot.d.ts +5 -0
- package/dist/agent/thread-stream-runtime.d.ts +26 -4
- package/dist/agent-builder/ee/index.cjs +1 -1
- package/dist/agent-builder/ee/index.js +1 -1
- package/dist/agent-controller/index.cjs +1 -1
- package/dist/agent-controller/index.js +1 -1
- package/dist/agent-controller/model-catalog-cache.d.ts +9 -5
- package/dist/agent-controller/session.d.ts +17 -0
- package/dist/{agent-controller-DckvJ7bq.cjs → agent-controller-C-WK9bMA.cjs} +67 -57
- package/dist/{agent-controller-vUU_atR-.js → agent-controller-Wxbc6702.js} +67 -57
- package/dist/background-tasks/index.cjs +1 -1
- package/dist/background-tasks/index.js +1 -1
- package/dist/{background-tasks-HAzB0JtC.js → background-tasks-DSMkHpbu.js} +1 -1
- package/dist/{background-tasks-By_1e9Gf.cjs → background-tasks-DcKNctMR.cjs} +1 -1
- package/dist/browser/index.cjs +1 -1
- package/dist/browser/index.js +1 -1
- package/dist/{builder-Dx8GMhFn.cjs → builder-CybmqbZt.cjs} +2 -2
- package/dist/{builder-CmtDqFLe.js → builder-PXwZnGYe.js} +2 -2
- package/dist/capabilities/302ai.json +197 -197
- package/dist/capabilities/abliteratedllm.json +35 -35
- package/dist/capabilities/abliteration-ai.json +10 -10
- package/dist/capabilities/above.json +19 -19
- package/dist/capabilities/adaption.json +15 -15
- package/dist/capabilities/adzuki.json +19 -19
- package/dist/capabilities/agentrouter.json +6 -6
- package/dist/capabilities/agnes.json +4 -4
- package/dist/capabilities/ai-router.json +8 -8
- package/dist/capabilities/aiand.json +25 -17
- package/dist/capabilities/aigrow.json +14 -14
- package/dist/capabilities/aimlapi.json +153 -153
- package/dist/capabilities/aixy.json +20 -20
- package/dist/capabilities/aki-io.json +11 -11
- package/dist/capabilities/alibaba-cn.json +93 -93
- package/dist/capabilities/alibaba-coding-plan-cn.json +4 -4
- package/dist/capabilities/alibaba-coding-plan.json +4 -4
- package/dist/capabilities/alibaba-token-plan-cn.json +47 -47
- package/dist/capabilities/alibaba-token-plan.json +49 -49
- package/dist/capabilities/alibaba.json +72 -72
- package/dist/capabilities/ambient.json +9 -9
- package/dist/capabilities/amd-tokenlab.json +5 -5
- package/dist/capabilities/amd.json +11 -11
- package/dist/capabilities/anthropic.json +40 -40
- package/dist/capabilities/anyapi.json +48 -48
- package/dist/capabilities/apiko.json +5 -5
- package/dist/capabilities/arcee.json +10 -10
- package/dist/capabilities/augure.json +5 -5
- package/dist/capabilities/auriko.json +18 -18
- package/dist/capabilities/bailing.json +4 -4
- package/dist/capabilities/baseten.json +41 -32
- package/dist/capabilities/bee.json +4 -4
- package/dist/capabilities/bothub.json +10 -10
- package/dist/capabilities/boundless.json +33 -33
- package/dist/capabilities/bumo.json +48 -48
- package/dist/capabilities/byteplus.json +35 -35
- package/dist/capabilities/cerebras.json +4 -4
- package/dist/capabilities/cheapaimodel.json +3 -3
- package/dist/capabilities/cheapest-token.json +28 -28
- package/dist/capabilities/chutes.json +43 -41
- package/dist/capabilities/cline-pass.json +33 -33
- package/dist/capabilities/cloudcode.json +7 -7
- package/dist/capabilities/cloudferro-sherlock.json +4 -4
- package/dist/capabilities/cloudflare-workers-ai.json +18 -18
- package/dist/capabilities/commandcode.json +147 -147
- package/dist/capabilities/concentrate.json +288 -279
- package/dist/capabilities/cortecs.json +108 -108
- package/dist/capabilities/crossmodel.json +157 -157
- package/dist/capabilities/crusoe.json +16 -16
- package/dist/capabilities/daoxe.json +9 -9
- package/dist/capabilities/databricks.json +131 -123
- package/dist/capabilities/deepinfra.json +95 -95
- package/dist/capabilities/deepseek.json +2 -2
- package/dist/capabilities/digitalocean.json +114 -115
- package/dist/capabilities/dothoosh.json +32 -32
- package/dist/capabilities/doubleword.json +26 -26
- package/dist/capabilities/edenai.json +298 -280
- package/dist/capabilities/empiriolabs.json +164 -164
- package/dist/capabilities/engy.json +23 -17
- package/dist/capabilities/entrim.json +4 -4
- package/dist/capabilities/evroc.json +17 -17
- package/dist/capabilities/ezkielyna.json +8 -8
- package/dist/capabilities/fastrouter.json +94 -94
- package/dist/capabilities/fireworks-ai.json +106 -95
- package/dist/capabilities/freemodel.json +9 -9
- package/dist/capabilities/friendli.json +31 -10
- package/dist/capabilities/frogbot.json +100 -100
- package/dist/capabilities/gisoo.json +18 -18
- package/dist/capabilities/gmicloud.json +19 -19
- package/dist/capabilities/google.json +59 -59
- package/dist/capabilities/graphn.json +10 -10
- package/dist/capabilities/greenpt.json +31 -31
- package/dist/capabilities/groq.json +5 -5
- package/dist/capabilities/helicone.json +87 -87
- package/dist/capabilities/hostinger-router.json +5 -5
- package/dist/capabilities/hpc-ai.json +9 -9
- package/dist/capabilities/huawei-maas.json +11 -11
- package/dist/capabilities/hubris.json +31 -31
- package/dist/capabilities/huggingface.json +95 -85
- package/dist/capabilities/humain.json +2 -2
- package/dist/capabilities/hyper.json +23 -23
- package/dist/capabilities/impossibl.json +157 -157
- package/dist/capabilities/inception.json +2 -2
- package/dist/capabilities/inceptron.json +4 -4
- package/dist/capabilities/inco.json +2 -2
- package/dist/capabilities/infer.json +11 -11
- package/dist/capabilities/inferall.json +8 -8
- package/dist/capabilities/inference-coop.json +6 -6
- package/dist/capabilities/inferenceapis.json +25 -25
- package/dist/capabilities/inferris.json +4 -4
- package/dist/capabilities/infersia.json +12 -12
- package/dist/capabilities/inferx.json +2 -2
- package/dist/capabilities/io-net.json +5 -5
- package/dist/capabilities/isoquant.json +4 -4
- package/dist/capabilities/iteracompute.json +43 -43
- package/dist/capabilities/jalapeno.json +10 -10
- package/dist/capabilities/jiekou.json +34 -34
- package/dist/capabilities/jzstoken.json +43 -43
- package/dist/capabilities/keln.json +21 -21
- package/dist/capabilities/kenari.json +120 -135
- package/dist/capabilities/kilo.json +671 -630
- package/dist/capabilities/kimchi.json +16 -16
- package/dist/capabilities/kimi-code-plan-cn.json +7 -7
- package/dist/capabilities/kimi-code-plan-global.json +7 -7
- package/dist/capabilities/kitani.json +2 -2
- package/dist/capabilities/klavo.json +25 -25
- package/dist/capabilities/korouter.json +31 -31
- package/dist/capabilities/kunavo.json +9 -9
- package/dist/capabilities/liquid.json +10 -10
- package/dist/capabilities/lithosai.json +2 -2
- package/dist/capabilities/llmgateway-providers.json +944 -906
- package/dist/capabilities/llmgateway.json +359 -348
- package/dist/capabilities/llmtr.json +25 -25
- package/dist/capabilities/logits.json +2 -2
- package/dist/capabilities/longcat.json +2 -2
- package/dist/capabilities/lowrouter.json +64 -64
- package/dist/capabilities/lyceum.json +14 -14
- package/dist/capabilities/melious.json +10 -10
- package/dist/capabilities/merge-gateway.json +268 -260
- package/dist/capabilities/meta.json +10 -10
- package/dist/capabilities/minimax-cn-coding-plan.json +5 -5
- package/dist/capabilities/minimax-cn.json +5 -5
- package/dist/capabilities/minimax-coding-plan.json +5 -5
- package/dist/capabilities/minimax.json +5 -5
- package/dist/capabilities/mistral.json +23 -15
- package/dist/capabilities/mixlayer.json +5 -5
- package/dist/capabilities/modal.json +11 -11
- package/dist/capabilities/model-oracle-ai.json +22 -22
- package/dist/capabilities/modelis.json +21 -21
- package/dist/capabilities/modelscope.json +2 -2
- package/dist/capabilities/modular.json +15 -15
- package/dist/capabilities/moneo.json +7 -7
- package/dist/capabilities/moonshotai-cn.json +6 -6
- package/dist/capabilities/moonshotai.json +6 -6
- package/dist/capabilities/morph.json +19 -19
- package/dist/capabilities/munito-eu.json +4 -4
- package/dist/capabilities/munito.json +5 -5
- package/dist/capabilities/nan.json +21 -21
- package/dist/capabilities/nano-gpt.json +594 -598
- package/dist/capabilities/nearai.json +121 -121
- package/dist/capabilities/nebius.json +42 -34
- package/dist/capabilities/neon.json +125 -125
- package/dist/capabilities/neuralwatt.json +41 -41
- package/dist/capabilities/nokeep.json +4 -4
- package/dist/capabilities/novita-ai.json +136 -136
- package/dist/capabilities/nvidia.json +29 -29
- package/dist/capabilities/oathbreaker.json +4 -4
- package/dist/capabilities/obscurify.json +24 -24
- package/dist/capabilities/oci.json +7 -7
- package/dist/capabilities/ofox.json +251 -251
- package/dist/capabilities/ollama-cloud.json +57 -57
- package/dist/capabilities/openai.json +56 -59
- package/dist/capabilities/opencode-go.json +93 -84
- package/dist/capabilities/openreason.json +5 -5
- package/dist/capabilities/openrouter.json +534 -532
- package/dist/capabilities/opper.json +31 -31
- package/dist/capabilities/orcarouter.json +292 -276
- package/dist/capabilities/outerlabs.json +32 -32
- package/dist/capabilities/ovhcloud.json +23 -23
- package/dist/capabilities/perplexity-agent.json +64 -64
- package/dist/capabilities/phala.json +31 -31
- package/dist/capabilities/poe.json +139 -139
- package/dist/capabilities/poolside.json +2 -2
- package/dist/capabilities/powerspring.json +8 -8
- package/dist/capabilities/primalabs.json +8 -8
- package/dist/capabilities/prime.json +133 -125
- package/dist/capabilities/privatemode-ai.json +4 -4
- package/dist/capabilities/proxystacks.json +3 -3
- package/dist/capabilities/qiniu-ai.json +14 -14
- package/dist/capabilities/refuseless.json +6 -6
- package/dist/capabilities/regolo-ai.json +8 -8
- package/dist/capabilities/requesty.json +201 -201
- package/dist/capabilities/ruapi.json +24 -24
- package/dist/capabilities/runcrate.json +8 -8
- package/dist/capabilities/runinfra.json +13 -13
- package/dist/capabilities/sakana.json +2 -2
- package/dist/capabilities/sandbase.json +23 -23
- package/dist/capabilities/sarvam.json +11 -11
- package/dist/capabilities/scaleway.json +15 -15
- package/dist/capabilities/scnet-token-plan.json +13 -13
- package/dist/capabilities/scx-ai.json +23 -23
- package/dist/capabilities/sensenova.json +13 -13
- package/dist/capabilities/siliconflow-cn.json +46 -46
- package/dist/capabilities/siliconflow.json +57 -57
- package/dist/capabilities/snowflake-cortex.json +21 -21
- package/dist/capabilities/sokkan.json +6 -6
- package/dist/capabilities/sparrowcodes.json +19 -19
- package/dist/capabilities/standardcompute.json +69 -69
- package/dist/capabilities/steadyrouter.json +40 -40
- package/dist/capabilities/stepfun-ai-step-plan.json +6 -6
- package/dist/capabilities/stepfun-ai.json +6 -6
- package/dist/capabilities/stepfun-step-plan.json +6 -6
- package/dist/capabilities/stepfun.json +6 -6
- package/dist/capabilities/stepping-stone.json +21 -21
- package/dist/capabilities/superbot-gg.json +4 -4
- package/dist/capabilities/synthetic.json +10 -10
- package/dist/capabilities/synthorai.json +24 -24
- package/dist/capabilities/teamorouter.json +14 -14
- package/dist/capabilities/teapot-router.json +4 -4
- package/dist/capabilities/tencent-token-plan-intl.json +16 -16
- package/dist/capabilities/tencent-token-plan.json +35 -35
- package/dist/capabilities/tencent-tokenhub.json +44 -44
- package/dist/capabilities/tensorx.json +49 -49
- package/dist/capabilities/the-grid-ai.json +28 -28
- package/dist/capabilities/thinkingmachines.json +76 -76
- package/dist/capabilities/tinfoil.json +9 -9
- package/dist/capabilities/togetherai.json +55 -55
- package/dist/capabilities/tokengo.json +24 -24
- package/dist/capabilities/tokenharbor.json +214 -214
- package/dist/capabilities/tokenify.json +8 -8
- package/dist/capabilities/trustedrouter.json +6 -6
- package/dist/capabilities/trustedtokens.json +19 -19
- package/dist/capabilities/umans-ai-coding-plan.json +11 -11
- package/dist/capabilities/umans-ai.json +11 -11
- package/dist/capabilities/uncensuredai.json +5 -5
- package/dist/capabilities/unrestricted.json +6 -6
- package/dist/capabilities/uplinkswitch.json +18 -18
- package/dist/capabilities/upstage.json +2 -2
- package/dist/capabilities/vancine.json +12 -12
- package/dist/capabilities/vercel.json +562 -549
- package/dist/capabilities/verda.json +4 -4
- package/dist/capabilities/vivgrid.json +62 -62
- package/dist/capabilities/volcengine-coding-plan.json +24 -24
- package/dist/capabilities/volcengine.json +31 -31
- package/dist/capabilities/vultr.json +18 -18
- package/dist/capabilities/wafer.ai.json +18 -18
- package/dist/capabilities/wallaby.json +5 -5
- package/dist/capabilities/wally.json +9 -9
- package/dist/capabilities/wandb.json +20 -20
- package/dist/capabilities/watt.json +20 -20
- package/dist/capabilities/xai.json +6 -6
- package/dist/capabilities/xiaomi-token-plan-ams.json +2 -2
- package/dist/capabilities/xiaomi-token-plan-cn.json +2 -2
- package/dist/capabilities/xiaomi-token-plan-sgp.json +2 -2
- package/dist/capabilities/xiaomi.json +3 -3
- package/dist/capabilities/xpersona.json +13 -13
- package/dist/capabilities/xxapi.json +27 -27
- package/dist/capabilities/zai-coding-plan.json +15 -15
- package/dist/capabilities/zai.json +29 -29
- package/dist/capabilities/zenifra.json +22 -22
- package/dist/capabilities/zenmux.json +185 -185
- package/dist/capabilities/zerogpu.json +14 -14
- package/dist/capabilities/zhipuai-coding-plan.json +3 -3
- package/dist/capabilities/zhipuai.json +27 -27
- package/dist/capabilities/zro.json +4 -4
- package/dist/channels/index.cjs +2 -2
- package/dist/channels/index.js +2 -2
- package/dist/{channels-DChC1kXm.js → channels-Cxy4jW11.js} +1 -1
- package/dist/{channels-BamLzaJG.cjs → channels-DNOI029U.cjs} +1 -1
- package/dist/coding-agent/index.cjs +1 -1
- package/dist/coding-agent/index.js +1 -1
- package/dist/{constants-Dro9fuhk.js → constants-C2Q-ZI5d.js} +6 -0
- package/dist/{constants-B2FVV_2e.cjs → constants-DPHwzvan.cjs} +6 -0
- package/dist/datasets/index.cjs +2 -2
- package/dist/datasets/index.js +2 -2
- package/dist/docs/SKILL.md +1 -1
- package/dist/docs/assets/SOURCE_MAP.json +1158 -1153
- package/dist/docs/references/docs-agents-human-in-the-loop.md +1 -1
- package/dist/docs/references/docs-agents-resumable-streams.md +3 -3
- package/dist/docs/references/docs-channels.md +50 -3
- package/dist/docs/references/docs-deployment-workers.md +10 -4
- package/dist/docs/references/docs-develop.md +2 -0
- package/dist/docs/references/docs-evals-experiments.md +2 -0
- package/dist/docs/references/docs-guides-build-an-eval-loop.md +5 -1
- package/dist/docs/references/docs-guides-overview.md +2 -1
- package/dist/docs/references/docs-harness-durable-agents.md +17 -15
- package/dist/docs/references/docs-knowledge-importers.md +11 -1
- package/dist/docs/references/docs-knowledge-scopes-and-access.md +26 -0
- package/dist/docs/references/docs-memory-message-history.md +24 -16
- package/dist/docs/references/docs-memory-overview.md +21 -17
- package/dist/docs/references/docs-sandbox-overview.md +12 -10
- package/dist/docs/references/docs-server-mcp.md +68 -0
- package/dist/docs/references/docs-server-pubsub.md +25 -16
- package/dist/docs/references/docs-signals-running-across-processes.md +9 -3
- package/dist/docs/references/docs-signals-sending-signals.md +1 -1
- package/dist/docs/references/docs-workflows-control-flow.md +20 -0
- package/dist/docs/references/docs-workflows-overview.md +3 -3
- package/dist/docs/references/integrations-observability-arthur.md +1 -1
- package/dist/docs/references/reference-agent-controller-agent-controller-class.md +1 -1
- package/dist/docs/references/reference-agent-controller-session.md +9 -0
- package/dist/docs/references/reference-agents-agent.md +3 -1
- package/dist/docs/references/reference-agents-durable-agent.md +3 -3
- package/dist/docs/references/reference-configuration.md +60 -0
- package/dist/docs/references/reference-knowledge-knowledge-class.md +1 -1
- package/dist/docs/references/reference-knowledge-knowledge-tools.md +1 -1
- package/dist/docs/references/reference-observability-tracing-bridges-datadog.md +12 -11
- package/dist/docs/references/reference-processors-processor-interface.md +1 -1
- package/dist/docs/references/reference-pubsub-base.md +1 -1
- package/dist/docs/references/reference-pubsub-caching-pubsub.md +1 -1
- package/dist/docs/references/reference-pubsub-google-cloud-pubsub.md +13 -7
- package/dist/docs/references/reference-pubsub-lease-provider.md +4 -0
- package/dist/docs/references/reference-pubsub-redis-streams.md +18 -9
- package/dist/docs/references/reference-pubsub-valkey-streams.md +25 -7
- package/dist/docs/references/reference-storage-overview.md +1 -1
- package/dist/docs/references/reference-voice-overview.md +0 -27
- package/dist/docs/references/reference-workflows-step.md +1 -1
- package/dist/docs/references/reference-workspace-workspace-class.md +3 -1
- package/dist/evals/index.cjs +2 -2
- package/dist/evals/index.js +2 -2
- package/dist/evals/scoreTraces/index.cjs +2 -2
- package/dist/evals/scoreTraces/index.js +2 -2
- package/dist/events/caching-pubsub.d.ts +3 -11
- package/dist/events/index.cjs +1 -1
- package/dist/events/index.js +1 -1
- package/dist/events/pubsub.d.ts +2 -1
- package/dist/{execution-fence-BBKnrhWR.cjs → execution-fence-C1nozqra.cjs} +1118 -309
- package/dist/{execution-fence--VdnD7p4.js → execution-fence-pJB0qqFJ.js} +1107 -310
- package/dist/harness/index.cjs +1 -1
- package/dist/harness/index.js +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.js +1 -1
- package/dist/knowledge/importers/local-host.d.ts +2 -1
- package/dist/knowledge/importers/sink.d.ts +6 -0
- package/dist/knowledge/importers/types.d.ts +5 -0
- package/dist/knowledge/index.cjs +105 -20
- package/dist/knowledge/index.js +105 -21
- package/dist/knowledge/links.d.ts +19 -6
- package/dist/llm/index.cjs +3 -3
- package/dist/llm/index.js +3 -3
- package/dist/llm/model/gateways/mastra.d.ts +19 -0
- package/dist/llm/model/gateways/refreshing-cache.d.ts +52 -0
- package/dist/llm/model/provider-types.generated.d.ts +7574 -7544
- package/dist/llm/reasoning/account-switch.d.ts +50 -0
- package/dist/llm/reasoning/index.cjs +65 -0
- package/dist/llm/reasoning/index.d.ts +1 -0
- package/dist/llm/reasoning/index.js +61 -1
- package/dist/{llm-DknPJDW6.cjs → llm-VhPqyULU.cjs} +2 -2
- package/dist/{llm-ccA_1Q-H.js → llm-_z1lIfCN.js} +2 -2
- package/dist/loop/index.cjs +2 -2
- package/dist/loop/index.js +2 -2
- package/dist/loop/suspended-run-auto-resume.d.ts +15 -0
- package/dist/loop/workflows/agentic-execution/background-task-check-step.d.ts +4 -0
- package/dist/loop/workflows/agentic-execution/goal-step.d.ts +4 -0
- package/dist/loop/workflows/agentic-execution/is-task-complete-step.d.ts +4 -0
- package/dist/loop/workflows/agentic-execution/llm-execution-step.d.ts +4 -0
- package/dist/loop/workflows/agentic-execution/llm-mapping-step.d.ts +2 -0
- package/dist/loop/workflows/agentic-execution/tool-call-step.d.ts +1 -1
- package/dist/loop/workflows/schema.d.ts +13 -0
- package/dist/{manager-D9F0i7O2.cjs → manager-BT70SgFz.cjs} +3 -3
- package/dist/{manager-DWX6-Cx4.js → manager-C3Kx39p_.js} +3 -3
- package/dist/mastra/index.cjs +1 -1
- package/dist/mastra/index.d.ts +35 -11
- package/dist/mastra/index.js +1 -1
- package/dist/{mastra-BzWL4xI8.cjs → mastra-CQGD2RoN.cjs} +108 -20
- package/dist/{mastra-oUDN81l8.js → mastra-fJ0iKYGP.js} +108 -20
- package/dist/memory/index.cjs +2 -2
- package/dist/memory/index.js +2 -2
- package/dist/{model-BnD7SPlA.cjs → model-D9NDbf-e.cjs} +1 -1
- package/dist/{model-BwxfS6T_.js → model-DmBDBf-q.js} +1 -1
- package/dist/{netlify-CS0VDbb9.cjs → netlify-DNaNhels.cjs} +1 -1
- package/dist/{netlify-DcY9gHCJ.js → netlify-_yV5Nwud.js} +1 -1
- package/dist/notifications/index.cjs +1 -1
- package/dist/notifications/index.js +1 -1
- package/dist/{output-helpers-k2-48ssH.js → output-helpers-D-qplq22.js} +13 -15
- package/dist/{output-helpers-By5FbLpp.cjs → output-helpers-D4O_oFne.cjs} +12 -14
- package/dist/processor-provider/index.cjs +1 -1
- package/dist/processor-provider/index.js +1 -1
- package/dist/processors/index.cjs +2 -2
- package/dist/processors/index.js +2 -2
- package/dist/{provider-registry-BvbEoScB.js → provider-registry-C4tv__fr.js} +22203 -21980
- package/dist/{provider-registry-OggbU6OE.cjs → provider-registry-_BUQuSKb.cjs} +21869 -21628
- package/dist/provider-registry.json +22243 -22188
- package/dist/{registry-generator-BFOQQHyt.js → registry-generator-CenhQnEi.js} +1 -1
- package/dist/{registry-generator-CDaf48a6.cjs → registry-generator-D7lsLJC-.cjs} +1 -1
- package/dist/{rehydrate-CFoKaNlm.js → rehydrate-CuWN_5No.js} +2 -2
- package/dist/{rehydrate-QeS0NjGw.cjs → rehydrate-SpC_gJCY.cjs} +2 -2
- package/dist/relevance/index.cjs +2 -2
- package/dist/relevance/index.js +2 -2
- package/dist/{scheduler-0ShtMM1I.js → scheduler-D1qdie5k.js} +4 -2
- package/dist/{scheduler-CMjK0LoQ.cjs → scheduler-DE5lcHJA.cjs} +4 -2
- package/dist/server/index.d.ts +1 -1
- package/dist/server/types.d.ts +57 -0
- package/dist/storage/constants.cjs +1 -1
- package/dist/storage/constants.js +1 -1
- package/dist/storage/domains/knowledge/base.d.ts +11 -0
- package/dist/storage/domains/knowledge/inmemory.d.ts +1 -0
- package/dist/storage/domains/knowledge/pages-inmemory.d.ts +4 -0
- package/dist/storage/domains/knowledge/pages.d.ts +1 -1
- package/dist/storage/domains/memory/base.d.ts +6 -1
- package/dist/storage/domains/observability/tracing.d.ts +12 -0
- package/dist/storage/index.cjs +4 -3
- package/dist/storage/index.js +4 -4
- package/dist/stream/index.cjs +2 -2
- package/dist/stream/index.js +2 -2
- package/dist/{stream-D2rv1Ut1.js → stream-BfSwqzPi.js} +1 -1
- package/dist/{stream-CNqAlDJF.cjs → stream-CW3d1Xg6.cjs} +1 -1
- package/dist/test-utils/llm-mock.cjs +1 -1
- package/dist/test-utils/llm-mock.js +1 -1
- package/dist/tool-loop-agent/index.cjs +1 -1
- package/dist/tool-loop-agent/index.js +1 -1
- package/dist/{tool-loop-agent-CFsOjueT.js → tool-loop-agent-B4_o4-Me.js} +3 -3
- package/dist/{tool-loop-agent-Dusqj7-j.cjs → tool-loop-agent-JN_oKyfY.cjs} +3 -3
- package/dist/{utils-CIuOHPoS.cjs → utils-Bq606mC8.cjs} +1 -1
- package/dist/{utils-DLnCt6E9.js → utils-CnpMuTyD.js} +1 -1
- package/dist/utils.cjs +1 -1
- package/dist/utils.js +1 -1
- package/dist/{validate-1zReLtWc.cjs → validate-CFv6HWXx.cjs} +1 -1
- package/dist/{validate-ShLcQTA5.js → validate-Db2C7Sj_.js} +1 -1
- package/dist/vector/index.cjs +1 -1
- package/dist/vector/index.js +1 -1
- package/dist/worker/index.cjs +1 -1
- package/dist/worker/index.d.ts +1 -1
- package/dist/worker/index.js +1 -1
- package/dist/worker/workers/orchestration-worker.d.ts +13 -0
- package/dist/{worker-BPNrwCFs.cjs → worker-CNIBQPQy.cjs} +117 -32
- package/dist/{worker-CQ8rTJwQ.cjs → worker-IZeSOZjg.cjs} +2 -2
- package/dist/{worker-CKcQcPl8.js → worker-UXFAgWOK.js} +2 -2
- package/dist/{worker-ngt-F1Iv.js → worker-X0fAJfcx.js} +117 -32
- package/dist/{workflow-B_e5wMmz.cjs → workflow-CMLLlVDc.cjs} +4 -4
- package/dist/{workflow-XDIVRsu4.js → workflow-DfXq2p2f.js} +4 -4
- package/dist/workflows/builder/index.cjs +1 -1
- package/dist/workflows/builder/index.js +1 -1
- package/dist/workflows/evented/index.cjs +1 -1
- package/dist/workflows/evented/index.js +1 -1
- package/dist/workflows/evented/setup-warning.d.ts +20 -0
- package/dist/workflows/index.cjs +5 -5
- package/dist/workflows/index.js +5 -5
- package/dist/workflows/scheduler/types.d.ts +3 -0
- package/package.json +8 -8
- package/src/llm/model/provider-types.generated.d.ts +7574 -7544
|
@@ -15,38 +15,44 @@ Each topic maps to a Google Cloud topic. Subscriptions with a group share a subs
|
|
|
15
15
|
**npm**:
|
|
16
16
|
|
|
17
17
|
```bash
|
|
18
|
-
npm install @mastra/google-cloud-pubsub
|
|
18
|
+
npm install @mastra/google-cloud-pubsub @mastra/redis ioredis
|
|
19
19
|
```
|
|
20
20
|
|
|
21
21
|
**pnpm**:
|
|
22
22
|
|
|
23
23
|
```bash
|
|
24
|
-
pnpm add @mastra/google-cloud-pubsub
|
|
24
|
+
pnpm add @mastra/google-cloud-pubsub @mastra/redis ioredis
|
|
25
25
|
```
|
|
26
26
|
|
|
27
27
|
**Yarn**:
|
|
28
28
|
|
|
29
29
|
```bash
|
|
30
|
-
yarn add @mastra/google-cloud-pubsub
|
|
30
|
+
yarn add @mastra/google-cloud-pubsub @mastra/redis ioredis
|
|
31
31
|
```
|
|
32
32
|
|
|
33
33
|
**Bun**:
|
|
34
34
|
|
|
35
35
|
```bash
|
|
36
|
-
bun add @mastra/google-cloud-pubsub
|
|
36
|
+
bun add @mastra/google-cloud-pubsub @mastra/redis ioredis
|
|
37
37
|
```
|
|
38
38
|
|
|
39
|
+
`@mastra/redis` and `ioredis` provide the shared server cache in the usage example.
|
|
40
|
+
|
|
39
41
|
## Usage example
|
|
40
42
|
|
|
41
|
-
Pass a Google Cloud client configuration, such as a project ID.
|
|
43
|
+
Pass a Google Cloud client configuration, such as a project ID. Google Cloud Pub/Sub has no matching server cache, so use any cache that every process shares: `RedisServerCache` from `@mastra/redis` as below, `ValkeyServerCache` from `@mastra/valkey`, or `ConvexServerCache` from `@mastra/convex`. Agent runs keep their numbered stream events and ownership record in that cache, so observing and resuming a run from an offset work through any process.
|
|
42
44
|
|
|
43
45
|
```typescript
|
|
44
46
|
import { Mastra } from '@mastra/core'
|
|
45
47
|
import { GoogleCloudPubSub } from '@mastra/google-cloud-pubsub'
|
|
48
|
+
import { RedisServerCache } from '@mastra/redis'
|
|
49
|
+
import { Redis } from 'ioredis'
|
|
46
50
|
|
|
47
51
|
export const mastra = new Mastra({
|
|
48
|
-
|
|
49
|
-
|
|
52
|
+
// Without a project ID, the client reads it from Application Default Credentials.
|
|
53
|
+
pubsub: new GoogleCloudPubSub({ projectId: process.env.GCP_PROJECT_ID }),
|
|
54
|
+
cache: new RedisServerCache({
|
|
55
|
+
client: new Redis(process.env.REDIS_URL ?? 'redis://localhost:6379'),
|
|
50
56
|
}),
|
|
51
57
|
})
|
|
52
58
|
```
|
|
@@ -18,13 +18,17 @@ You don't construct a `LeaseProvider` directly. Configure a pub/sub backend that
|
|
|
18
18
|
|
|
19
19
|
```typescript
|
|
20
20
|
import { Mastra } from '@mastra/core'
|
|
21
|
+
import { RedisServerCache } from '@mastra/redis'
|
|
21
22
|
import { RedisStreamsPubSub } from '@mastra/redis-streams'
|
|
23
|
+
import { Redis } from 'ioredis'
|
|
22
24
|
|
|
23
25
|
export const mastra = new Mastra({
|
|
24
26
|
// RedisStreamsPubSub implements both PubSub and LeaseProvider
|
|
25
27
|
pubsub: new RedisStreamsPubSub({
|
|
26
28
|
url: process.env.REDIS_URL,
|
|
27
29
|
}),
|
|
30
|
+
// Every process shares the agent run streams it holds
|
|
31
|
+
cache: new RedisServerCache({ client: new Redis(process.env.REDIS_URL!) }),
|
|
28
32
|
})
|
|
29
33
|
```
|
|
30
34
|
|
|
@@ -17,41 +17,50 @@ Each topic maps to a Redis stream key. Subscriptions with a group use a Redis co
|
|
|
17
17
|
**npm**:
|
|
18
18
|
|
|
19
19
|
```bash
|
|
20
|
-
npm install @mastra/redis-streams
|
|
20
|
+
npm install @mastra/redis-streams @mastra/redis ioredis
|
|
21
21
|
```
|
|
22
22
|
|
|
23
23
|
**pnpm**:
|
|
24
24
|
|
|
25
25
|
```bash
|
|
26
|
-
pnpm add @mastra/redis-streams
|
|
26
|
+
pnpm add @mastra/redis-streams @mastra/redis ioredis
|
|
27
27
|
```
|
|
28
28
|
|
|
29
29
|
**Yarn**:
|
|
30
30
|
|
|
31
31
|
```bash
|
|
32
|
-
yarn add @mastra/redis-streams
|
|
32
|
+
yarn add @mastra/redis-streams @mastra/redis ioredis
|
|
33
33
|
```
|
|
34
34
|
|
|
35
35
|
**Bun**:
|
|
36
36
|
|
|
37
37
|
```bash
|
|
38
|
-
bun add @mastra/redis-streams
|
|
38
|
+
bun add @mastra/redis-streams @mastra/redis ioredis
|
|
39
39
|
```
|
|
40
40
|
|
|
41
|
+
`@mastra/redis` and `ioredis` provide the shared server cache in the usage example.
|
|
42
|
+
|
|
41
43
|
Requires Redis 7.0 or later. The reclaim loop relies on `XCLAIM` removing trimmed entries from the pending list, which earlier versions don't do.
|
|
42
44
|
|
|
43
45
|
## Usage example
|
|
44
46
|
|
|
45
|
-
|
|
47
|
+
Set a server cache that every process shares together with the pubsub: agent runs keep their numbered stream events and ownership record in it, so observing and resuming a run from an offset work through any process. Replicas of one deployment use the same `keyPrefix` values, and another deployment on the same Redis needs its own on both the pubsub and the cache.
|
|
46
48
|
|
|
47
49
|
```typescript
|
|
48
50
|
import { Mastra } from '@mastra/core'
|
|
51
|
+
import { RedisServerCache } from '@mastra/redis'
|
|
49
52
|
import { RedisStreamsPubSub } from '@mastra/redis-streams'
|
|
53
|
+
import { Redis } from 'ioredis'
|
|
54
|
+
|
|
55
|
+
// One URL for the pubsub and the cache, so both reach the same Redis.
|
|
56
|
+
const redisUrl = process.env.REDIS_URL ?? 'redis://localhost:6379'
|
|
50
57
|
|
|
51
58
|
export const mastra = new Mastra({
|
|
52
|
-
pubsub: new RedisStreamsPubSub({
|
|
53
|
-
|
|
54
|
-
|
|
59
|
+
pubsub: new RedisStreamsPubSub({ url: redisUrl, keyPrefix: 'mastra:my-app' }),
|
|
60
|
+
cache: new RedisServerCache(
|
|
61
|
+
{ client: new Redis(redisUrl) },
|
|
62
|
+
{ keyPrefix: 'mastra:my-app:cache:' },
|
|
63
|
+
),
|
|
55
64
|
})
|
|
56
65
|
```
|
|
57
66
|
|
|
@@ -228,7 +237,7 @@ A subscription never reclaims an event its own handler is still processing, so a
|
|
|
228
237
|
|
|
229
238
|
### Evented agent worker takeover
|
|
230
239
|
|
|
231
|
-
With Postgres or libSQL storage, distributed evented agents publish worker orchestration events through Redis. If a worker exits before acknowledging an event, another worker can reclaim it and finish the run while the original API process stays alive. Configure the API process with `MASTRA_WORKERS=false` and worker processes with `MASTRA_WORKERS=orchestration`. All processes must share the same database, Redis connection settings,
|
|
240
|
+
With Postgres or libSQL storage, distributed evented agents publish worker orchestration events through Redis. If a worker exits before acknowledging an event, another worker can reclaim it and finish the run while the original API process stays alive. Configure the API process with `MASTRA_WORKERS=false` and worker processes with `MASTRA_WORKERS=orchestration`. All processes must share the same database, Redis connection settings, `keyPrefix`, and server cache. With libSQL, use a libSQL server such as sqld or Turso when processes run on more than one machine. A database file only works when every process runs on the same machine, because the step guards depend on SQLite file locking, which isn't reliable on network filesystems. An in-memory (`:memory:`) database isn't shared between processes.
|
|
232
241
|
|
|
233
242
|
Runs started on older versions can finish after upgrading, but don't have guaranteed crash recovery. An evented workflow run, including a nested workflow run, that was already running with `shouldPersistSnapshot` returning `false` has no stored record, so it fails at its next step after the upgrade. Let those runs finish before upgrading. Saved steps without occurrence identifiers keep their existing unguarded behavior. Other storage adapters keep distributed internal orchestration on the worker process. Worker takeover isn't verified with libSQL embedded replicas (`syncUrl`) shared by several workers.
|
|
234
243
|
|
|
@@ -13,40 +13,58 @@ Use it for Valkey deployments. Use [`RedisStreamsPubSub`](https://mastra.ai/refe
|
|
|
13
13
|
**npm**:
|
|
14
14
|
|
|
15
15
|
```bash
|
|
16
|
-
npm install @mastra/valkey-streams
|
|
16
|
+
npm install @mastra/valkey-streams @mastra/valkey @valkey/valkey-glide@2.5.2
|
|
17
17
|
```
|
|
18
18
|
|
|
19
19
|
**pnpm**:
|
|
20
20
|
|
|
21
21
|
```bash
|
|
22
|
-
pnpm add @mastra/valkey-streams
|
|
22
|
+
pnpm add @mastra/valkey-streams @mastra/valkey @valkey/valkey-glide@2.5.2
|
|
23
23
|
```
|
|
24
24
|
|
|
25
25
|
**Yarn**:
|
|
26
26
|
|
|
27
27
|
```bash
|
|
28
|
-
yarn add @mastra/valkey-streams
|
|
28
|
+
yarn add @mastra/valkey-streams @mastra/valkey @valkey/valkey-glide@2.5.2
|
|
29
29
|
```
|
|
30
30
|
|
|
31
31
|
**Bun**:
|
|
32
32
|
|
|
33
33
|
```bash
|
|
34
|
-
bun add @mastra/valkey-streams
|
|
34
|
+
bun add @mastra/valkey-streams @mastra/valkey @valkey/valkey-glide@2.5.2
|
|
35
35
|
```
|
|
36
36
|
|
|
37
|
+
`@mastra/valkey` and `@valkey/valkey-glide` provide the shared server cache in the usage example. The GLIDE version must match the one `@mastra/valkey` uses, or the client types don't match.
|
|
38
|
+
|
|
37
39
|
## Usage example
|
|
38
40
|
|
|
41
|
+
Set a server cache that every process shares together with the pubsub: agent runs keep their numbered stream events and ownership record in it, so observing and resuming a run from an offset work through any process. Replicas of one deployment use the same `keyPrefix` values, and another deployment on the same Valkey needs its own on both the pubsub and the cache.
|
|
42
|
+
|
|
39
43
|
```typescript
|
|
40
44
|
import { Mastra } from '@mastra/core'
|
|
45
|
+
import { ValkeyServerCache } from '@mastra/valkey'
|
|
41
46
|
import { ValkeyStreamsPubSub } from '@mastra/valkey-streams'
|
|
47
|
+
import { GlideClient } from '@valkey/valkey-glide'
|
|
48
|
+
|
|
49
|
+
// One GLIDE configuration for the pubsub and the cache, so both reach the same Valkey.
|
|
50
|
+
// The top-level await below needs an ES module entry point, as in projects created with create-mastra.
|
|
51
|
+
const valkey = {
|
|
52
|
+
addresses: [
|
|
53
|
+
{ host: process.env.VALKEY_HOST ?? 'localhost', port: Number(process.env.VALKEY_PORT ?? 6379) },
|
|
54
|
+
],
|
|
55
|
+
}
|
|
42
56
|
|
|
43
57
|
export const mastra = new Mastra({
|
|
44
|
-
pubsub: new ValkeyStreamsPubSub({
|
|
45
|
-
|
|
46
|
-
|
|
58
|
+
pubsub: new ValkeyStreamsPubSub({ valkeyOptions: valkey, keyPrefix: 'mastra:my-app' }),
|
|
59
|
+
cache: new ValkeyServerCache(
|
|
60
|
+
{ client: await GlideClient.createClient(valkey) },
|
|
61
|
+
{ keyPrefix: 'mastra:my-app:cache:' },
|
|
62
|
+
),
|
|
47
63
|
})
|
|
48
64
|
```
|
|
49
65
|
|
|
66
|
+
Add `credentials` or `useTLS` to that configuration when the server needs them.
|
|
67
|
+
|
|
50
68
|
## Constructor parameters
|
|
51
69
|
|
|
52
70
|
**url** (`string`): Valkey connection URL. Falls back to valkeyOptions.url. rediss\:// and valkeys\:// URLs enable TLS unless valkeyOptions.useTLS is set. (Default: `valkey://localhost:6379`)
|
|
@@ -47,7 +47,7 @@ The schema definitions below cover the built-in database-backed tables documente
|
|
|
47
47
|
|
|
48
48
|
Stores conversation messages and their metadata. Each message belongs to a thread and contains the actual content along with metadata about the sender role and message type.
|
|
49
49
|
|
|
50
|
-
idtextPRIMARYKEYNOT NULLUnique identifier for the messagethread_idtextNOT NULLParent thread reference (`threads.id`). Postgres and libSQL store `mastra-queue:pending:<threadId>` or `mastra-queue:taken:<threadId>` instead while the row is a queued \[pending signal]\(/docs/server/pubsub#signals-sent-to-a-running-evented-agent), which no read by thread or resource returns, so that value matches no thread.resourceIdtextCAN BE NULLID of the resource that owns this message. Postgres and libSQL store `NULL` while the row is a pending signal.contenttextNOT NULLJSON of the message content in V2 format. Example: `{ format: 2, parts: [...] }`roletextNOT NULLEnum of `user | assistant`createdAttimestampNOT NULLUsed for thread message ordering
|
|
50
|
+
idtextPRIMARYKEYNOT NULLUnique identifier for the messagethread_idtextNOT NULLParent thread reference (`threads.id`). Postgres and libSQL store `mastra-queue:pending:<threadId>` or `mastra-queue:taken:<threadId>` instead while the row is a queued \[pending signal]\(/docs/server/pubsub#signals-sent-to-a-running-evented-agent), which no read by thread or resource returns, so that value matches no thread.resourceIdtextCAN BE NULLID of the resource that owns this message. Postgres and libSQL store `NULL` while the row is a pending signal.contenttextNOT NULLJSON of the message content in V2 format. Example: `{ format: 2, parts: [...] }`roletextNOT NULLEnum of `user | assistant | system | signal`createdAttimestampNOT NULLUsed for thread message ordering
|
|
51
51
|
|
|
52
52
|
The message `content` column contains a JSON object conforming to the `MastraMessageContentV2` type, which is designed to align with the AI SDK `UIMessage` message shape.
|
|
53
53
|
|
|
@@ -142,33 +142,6 @@ playAudio(audioStream)
|
|
|
142
142
|
|
|
143
143
|
Visit the [Google Voice Reference](https://mastra.ai/integrations/voice/google) for more information on the Google voice provider.
|
|
144
144
|
|
|
145
|
-
**Cloudflare**:
|
|
146
|
-
|
|
147
|
-
```typescript
|
|
148
|
-
import { Agent } from '@mastra/core/agent'
|
|
149
|
-
import { CloudflareVoice } from '@mastra/voice-cloudflare'
|
|
150
|
-
import { playAudio } from '@mastra/node-audio'
|
|
151
|
-
|
|
152
|
-
const voiceAgent = new Agent({
|
|
153
|
-
id: 'voice-agent',
|
|
154
|
-
name: 'Voice Agent',
|
|
155
|
-
instructions: 'You are a voice assistant that can help users with their tasks.',
|
|
156
|
-
model: 'openai/gpt-6.2-sol',
|
|
157
|
-
voice: new CloudflareVoice(),
|
|
158
|
-
})
|
|
159
|
-
|
|
160
|
-
const { text } = await voiceAgent.generate('What color is the sky?')
|
|
161
|
-
|
|
162
|
-
// Convert text to speech to an Audio Stream
|
|
163
|
-
const audioStream = await voiceAgent.voice.speak(text, {
|
|
164
|
-
speaker: 'default', // Optional: specify a speaker
|
|
165
|
-
})
|
|
166
|
-
|
|
167
|
-
playAudio(audioStream)
|
|
168
|
-
```
|
|
169
|
-
|
|
170
|
-
Visit the [Cloudflare Voice Reference](https://mastra.ai/integrations/voice/cloudflare) for more information on the Cloudflare voice provider.
|
|
171
|
-
|
|
172
145
|
**Deepgram**:
|
|
173
146
|
|
|
174
147
|
```typescript
|
|
@@ -234,7 +234,7 @@ A classifier without constructor-configured questions can't be used as a workflo
|
|
|
234
234
|
|
|
235
235
|
**execute.state** (`z.infer<TState>`): The current workflow state. Contains shared values that persist across all steps and suspend/resume cycles. The structure is defined by the step's stateSchema. Reading it in a run stored with storageVersion: 2 throws; use await getState() instead.
|
|
236
236
|
|
|
237
|
-
**execute.getState** (`(keys
|
|
237
|
+
**execute.getState** (`{ (): Promise<z.infer<TState>>; <K extends keyof z.infer<TState>>(keys: readonly K[]): Promise<Pick<z.infer<TState>, K>> }`): Resolves to the current workflow state, including this step's own setState changes. Pass top-level keys to get a Pick of the state containing only those keys. When the step has no state schema, both forms resolve to Record\<string, any>. Works on every engine and storage version.
|
|
238
238
|
|
|
239
239
|
**execute.setState** (`(state: z.infer<TState>) => Promise<void>`): Replaces the step's pending state with the value you pass, which is validated on its own against the step's stateSchema, so it must contain every field that schema requires. Top-level keys you leave out keep their current value. A second call in the same step replaces the first. On the evented engine, setState instead merges the keys you pass into the state without validating them, and a second call adds to the first. Await it, so the update is applied before the step returns and a validation error fails the step.
|
|
240
240
|
|
|
@@ -25,6 +25,8 @@ const workspace = new Workspace({
|
|
|
25
25
|
bm25: true,
|
|
26
26
|
autoIndexPaths: ['docs'],
|
|
27
27
|
})
|
|
28
|
+
|
|
29
|
+
await workspace.init()
|
|
28
30
|
```
|
|
29
31
|
|
|
30
32
|
## Constructor parameters
|
|
@@ -47,7 +49,7 @@ const workspace = new Workspace({
|
|
|
47
49
|
|
|
48
50
|
**embedder** (`Embedder`): Function that turns text into vectors. Required when vectorStore is set, unless the store generates embeddings itself (see Server-side embeddings). Accepts either a single-text function (text: string) => Promise\<number\[]> or a batch-capable function (texts: string\[]) => Promise\<number\[]\[]> that has a batch: true property and an optional maxBatchSize. See Batch embedding.
|
|
49
51
|
|
|
50
|
-
**autoIndexPaths** (`string[]`): Paths or glob patterns to
|
|
52
|
+
**autoIndexPaths** (`string[]`): Paths or glob patterns such as '\*\*/\*.md' to index when you await workspace.init(). See auto-indexing.
|
|
51
53
|
|
|
52
54
|
**skills** (`string[] | ((context: SkillsContext) => string[] | Promise<string[]>)`): Paths where SKILL.md files are located. This can be a static array or an async function that resolves paths dynamically. Supports glob patterns like './\*\*/skills' for discovery. Skills are read from skillSource when set, otherwise from the workspace filesystem — including a resolver-backed filesystem, which is resolved per request. With a resolver, use workspace.skills.getScoped({ requestContext }) so the filesystem is chosen from the request; direct calls such as workspace.skills.list() resolve with an empty RequestContext. Only when no filesystem is configured are skills read from the local disk.
|
|
53
55
|
|
package/dist/evals/index.cjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
-
const require_execution_fence = require("../execution-fence-
|
|
3
|
-
const require_constants = require("../constants-
|
|
2
|
+
const require_execution_fence = require("../execution-fence-C1nozqra.cjs");
|
|
3
|
+
const require_constants = require("../constants-DPHwzvan.cjs");
|
|
4
4
|
const require_collect_tool_mocks = require("../collect-tool-mocks-k9fM6oDl.cjs");
|
|
5
5
|
exports.MastraScorer = require_execution_fence.MastraScorer;
|
|
6
6
|
exports.SCORING_PREDICATE_ROOTS = require_execution_fence.SCORING_PREDICATE_ROOTS;
|
package/dist/evals/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { Ar as scoringEntityTypeSchema, Cr as extractTrajectory, Dr as saveScorePayloadSchema, Er as listScoresResponseSchema, Fr as scoringInputWithExtractStepResultAndScoreAndReasonSchema, Ir as scoringInputWithExtractStepResultSchema, Lr as scoringPromptsSchema, Mr as scoringHookInputSchema, Nr as scoringInputSchema, Or as scoreResultSchema, Pr as scoringInputWithExtractStepResultAndAnalyzeStepResultSchema, Rr as scoringSourceSchema, Tr as extractWorkflowTrajectory, jr as scoringExtractStepResultSchema, kr as scoreRowDataSchema, wr as extractTrajectoryFromTrace, zr as scoringValueSchema } from "../constants-
|
|
1
|
+
import { Jc as evaluateScoringPredicate, Yc as validateScoringPredicate, _ as isNotScorable, c as runEvals, f as createClassifierScorer, g as filterRun, h as createScorer, m as ScorerRunError, p as MastraScorer, qc as SCORING_PREDICATE_ROOTS, v as notScorable } from "../execution-fence-pJB0qqFJ.js";
|
|
2
|
+
import { Ar as scoringEntityTypeSchema, Cr as extractTrajectory, Dr as saveScorePayloadSchema, Er as listScoresResponseSchema, Fr as scoringInputWithExtractStepResultAndScoreAndReasonSchema, Ir as scoringInputWithExtractStepResultSchema, Lr as scoringPromptsSchema, Mr as scoringHookInputSchema, Nr as scoringInputSchema, Or as scoreResultSchema, Pr as scoringInputWithExtractStepResultAndAnalyzeStepResultSchema, Rr as scoringSourceSchema, Tr as extractWorkflowTrajectory, jr as scoringExtractStepResultSchema, kr as scoreRowDataSchema, wr as extractTrajectoryFromTrace, zr as scoringValueSchema } from "../constants-C2Q-ZI5d.js";
|
|
3
3
|
import { t as collectToolMocks } from "../collect-tool-mocks-3s2BN8o7.js";
|
|
4
4
|
export { MastraScorer, SCORING_PREDICATE_ROOTS, ScorerRunError, collectToolMocks, createClassifierScorer, createScorer, evaluateScoringPredicate, extractTrajectory, extractTrajectoryFromTrace, extractWorkflowTrajectory, filterRun, isNotScorable, listScoresResponseSchema, notScorable, runEvals, saveScorePayloadSchema, scoreResultSchema, scoreRowDataSchema, scoringEntityTypeSchema, scoringExtractStepResultSchema, scoringHookInputSchema, scoringInputSchema, scoringInputWithExtractStepResultAndAnalyzeStepResultSchema, scoringInputWithExtractStepResultAndScoreAndReasonSchema, scoringInputWithExtractStepResultSchema, scoringPromptsSchema, scoringSourceSchema, scoringValueSchema, validateScoringPredicate };
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
2
|
const require_error = require("../../error-D90lJ6M7.cjs");
|
|
3
3
|
const require_utils = require("../../utils-D-eNsgDM.cjs");
|
|
4
|
-
const require_execution_fence = require("../../execution-fence-
|
|
5
|
-
const require_constants = require("../../constants-
|
|
4
|
+
const require_execution_fence = require("../../execution-fence-C1nozqra.cjs");
|
|
5
|
+
const require_constants = require("../../constants-DPHwzvan.cjs");
|
|
6
6
|
let zod_v4 = require("zod/v4");
|
|
7
7
|
// src/evals/scoreTraces/scoreTraces.ts
|
|
8
8
|
async function scoreTraces({ scorerId, targets, mastra }) {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { i as MastraError, n as ErrorDomain, t as ErrorCategory } from "../../error-oh2DLsP2.js";
|
|
2
2
|
import { i as getEntityTypeForSpan } from "../../utils-DU_pU5SK.js";
|
|
3
|
-
import {
|
|
4
|
-
import { Dr as saveScorePayloadSchema } from "../../constants-
|
|
3
|
+
import { Fs as createStep, Is as createWorkflow } from "../../execution-fence-pJB0qqFJ.js";
|
|
4
|
+
import { Dr as saveScorePayloadSchema } from "../../constants-C2Q-ZI5d.js";
|
|
5
5
|
import { z } from "zod/v4";
|
|
6
6
|
// src/evals/scoreTraces/scoreTraces.ts
|
|
7
7
|
async function scoreTraces({ scorerId, targets, mastra }) {
|
|
@@ -37,8 +37,7 @@ export interface CachingPubSubOptions {
|
|
|
37
37
|
shouldCache?: (topic: string) => boolean;
|
|
38
38
|
/**
|
|
39
39
|
* Only append to topics whose log this cache already holds. A publish to a
|
|
40
|
-
* topic with no log is delivered live and unnumbered
|
|
41
|
-
* called with the topic.
|
|
40
|
+
* topic with no log is delivered live and unnumbered.
|
|
42
41
|
*
|
|
43
42
|
* A process-local cache can only number a topic's frames consistently in the
|
|
44
43
|
* process that started its log. Another process numbering the same topic
|
|
@@ -48,12 +47,6 @@ export interface CachingPubSubOptions {
|
|
|
48
47
|
* @internal
|
|
49
48
|
*/
|
|
50
49
|
extendExistingLogsOnly?: boolean;
|
|
51
|
-
/**
|
|
52
|
-
* Called when `extendExistingLogsOnly` leaves a publish unnumbered.
|
|
53
|
-
*
|
|
54
|
-
* @internal
|
|
55
|
-
*/
|
|
56
|
-
onUnlogged?: (topic: string) => void;
|
|
57
50
|
/**
|
|
58
51
|
* @deprecated No longer used. Evented steps now cache their frames when they
|
|
59
52
|
* publish, so nothing needs to be copied in from another PubSub. Accepted and
|
|
@@ -140,7 +133,6 @@ export declare class CachingPubSub extends PubSub {
|
|
|
140
133
|
private readonly logger?;
|
|
141
134
|
private readonly shouldCache?;
|
|
142
135
|
private readonly extendExistingLogsOnly;
|
|
143
|
-
private readonly onUnlogged?;
|
|
144
136
|
private readonly logTtls;
|
|
145
137
|
/** Maps original callbacks to their wrapped versions for proper unsubscribe */
|
|
146
138
|
private callbackMap;
|
|
@@ -166,8 +158,8 @@ export declare class CachingPubSub extends PubSub {
|
|
|
166
158
|
/**
|
|
167
159
|
* Topics `shouldCache` leaves out only reach the inner transport. With
|
|
168
160
|
* `extendExistingLogsOnly`, a process that doesn't hold a run's log
|
|
169
|
-
* publishes it live only; that setup
|
|
170
|
-
*
|
|
161
|
+
* publishes it live only; Mastra warns about that setup at startup, and its
|
|
162
|
+
* replays miss those frames whatever they carry, so it still counts
|
|
171
163
|
* as kept.
|
|
172
164
|
*/
|
|
173
165
|
__replaysTopic(topic: string): boolean;
|
package/dist/events/index.cjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
2
|
const require_rolldown_runtime = require("../rolldown-runtime-BrhgMLW6.cjs");
|
|
3
|
-
const require_output_helpers = require("../output-helpers-
|
|
3
|
+
const require_output_helpers = require("../output-helpers-D4O_oFne.cjs");
|
|
4
4
|
const require_file = require("../file-BEndQUN1.cjs");
|
|
5
5
|
let crypto = require("crypto");
|
|
6
6
|
let path = require("path");
|
package/dist/events/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { S as isLeaseProvider,
|
|
1
|
+
import { S as isLeaseProvider, a as CachingPubSub, b as NoopLeaseProvider, c as DEFAULT_THREAD_STREAM_LOG_TTL_MS, d as cachedLogTtlMs, f as isRunLocalTopic, i as PublisherQueueLimitError, l as RUN_LOCAL_TOPIC_PREFIXES, m as toCachedLogFrame, n as rehydrateError, o as withCaching, p as streamTopicIdleTtlMs, r as serializeError, s as DEFAULT_RUN_LOG_TTL_MS, t as DefaultStepResult, u as RUN_LOG_TTL_MS, v as EventEmitterPubSub, x as PubSub, y as withAck } from "../output-helpers-D-qplq22.js";
|
|
2
2
|
import { n as DefaultGeneratedFileWithType, t as DefaultGeneratedFile } from "../file-DGZrR5f7.js";
|
|
3
3
|
import { createHash } from "crypto";
|
|
4
4
|
import { basename, dirname, join, sep } from "path";
|
package/dist/events/pubsub.d.ts
CHANGED
|
@@ -25,7 +25,8 @@ export type PubSubDeliveryMode = 'pull' | 'push';
|
|
|
25
25
|
*
|
|
26
26
|
* Evented workflows and evented agents can run on any implementation inside one
|
|
27
27
|
* process. Running them on several processes needs a pubsub that redelivers
|
|
28
|
-
* unacknowledged events and a workflows store with step guards.
|
|
28
|
+
* unacknowledged events and a workflows store with step guards. Evented agents
|
|
29
|
+
* also need a server cache that every process shares.
|
|
29
30
|
*
|
|
30
31
|
* @see https://mastra.ai/docs/server/pubsub#evented-workflows-and-agents
|
|
31
32
|
*/
|