@mastra/core 1.87.0 → 1.88.0-alpha.0

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.
Files changed (404) hide show
  1. package/dist/_types/@internal_ai-v6@0.0.100/dist/index.d.ts +97 -2049
  2. package/dist/agent/agent.d.ts +10 -2
  3. package/dist/agent/durable/create-evented-agent.d.ts +2 -1
  4. package/dist/agent/durable/execution-engine.d.ts +4 -2
  5. package/dist/agent/durable/index.cjs +3 -2
  6. package/dist/agent/durable/index.js +3 -2
  7. package/dist/agent/durable/segment-spans.d.ts +7 -0
  8. package/dist/agent/durable/stored-signal-drain.d.ts +1 -1
  9. package/dist/agent/durable/types.d.ts +6 -0
  10. package/dist/agent/index.cjs +2 -2
  11. package/dist/agent/index.js +2 -2
  12. package/dist/agent/request-context-snapshot.d.ts +5 -0
  13. package/dist/agent/thread-stream-runtime.d.ts +26 -4
  14. package/dist/agent-builder/ee/index.cjs +1 -1
  15. package/dist/agent-builder/ee/index.js +1 -1
  16. package/dist/agent-controller/index.cjs +1 -1
  17. package/dist/agent-controller/index.js +1 -1
  18. package/dist/{agent-controller-vUU_atR-.js → agent-controller-CQDCmsFD.js} +15 -9
  19. package/dist/{agent-controller-DckvJ7bq.cjs → agent-controller-NQKYmY0W.cjs} +15 -9
  20. package/dist/background-tasks/index.cjs +1 -1
  21. package/dist/background-tasks/index.js +1 -1
  22. package/dist/{background-tasks-HAzB0JtC.js → background-tasks-B7UygDdO.js} +1 -1
  23. package/dist/{background-tasks-By_1e9Gf.cjs → background-tasks-CeARf1DK.cjs} +1 -1
  24. package/dist/browser/index.cjs +1 -1
  25. package/dist/browser/index.js +1 -1
  26. package/dist/{builder-CmtDqFLe.js → builder-CpAEmMdR.js} +2 -2
  27. package/dist/{builder-Dx8GMhFn.cjs → builder-Dmf04g9P.cjs} +2 -2
  28. package/dist/capabilities/302ai.json +196 -196
  29. package/dist/capabilities/abliteratedllm.json +33 -33
  30. package/dist/capabilities/abliteration-ai.json +9 -9
  31. package/dist/capabilities/above.json +13 -13
  32. package/dist/capabilities/adaption.json +7 -7
  33. package/dist/capabilities/adzuki.json +20 -20
  34. package/dist/capabilities/agentrouter.json +10 -10
  35. package/dist/capabilities/agnes.json +2 -2
  36. package/dist/capabilities/ai-router.json +6 -6
  37. package/dist/capabilities/aiand.json +27 -18
  38. package/dist/capabilities/aigrow.json +14 -14
  39. package/dist/capabilities/aimlapi.json +146 -146
  40. package/dist/capabilities/aipg.json +2 -2
  41. package/dist/capabilities/aixy.json +17 -17
  42. package/dist/capabilities/aki-io.json +14 -14
  43. package/dist/capabilities/alibaba-cn.json +94 -94
  44. package/dist/capabilities/alibaba-coding-plan-cn.json +5 -5
  45. package/dist/capabilities/alibaba-coding-plan.json +5 -5
  46. package/dist/capabilities/alibaba-token-plan-cn.json +50 -50
  47. package/dist/capabilities/alibaba-token-plan.json +53 -53
  48. package/dist/capabilities/alibaba.json +71 -71
  49. package/dist/capabilities/ambient.json +8 -8
  50. package/dist/capabilities/amd-tokenlab.json +4 -4
  51. package/dist/capabilities/amd.json +11 -11
  52. package/dist/capabilities/anthropic.json +36 -36
  53. package/dist/capabilities/anyapi.json +18 -18
  54. package/dist/capabilities/apiko.json +2 -2
  55. package/dist/capabilities/arcee.json +9 -9
  56. package/dist/capabilities/augure.json +5 -5
  57. package/dist/capabilities/auriko.json +23 -23
  58. package/dist/capabilities/bailing.json +5 -5
  59. package/dist/capabilities/baseten.json +47 -38
  60. package/dist/capabilities/bee.json +5 -5
  61. package/dist/capabilities/bothub.json +14 -14
  62. package/dist/capabilities/boundless.json +37 -37
  63. package/dist/capabilities/bumo.json +40 -40
  64. package/dist/capabilities/byteplus.json +22 -22
  65. package/dist/capabilities/cerebras.json +4 -4
  66. package/dist/capabilities/cheapaimodel.json +10 -10
  67. package/dist/capabilities/cheapest-token.json +25 -25
  68. package/dist/capabilities/chutes.json +34 -32
  69. package/dist/capabilities/cline-pass.json +29 -29
  70. package/dist/capabilities/cloudcode.json +7 -7
  71. package/dist/capabilities/cloudflare-workers-ai.json +15 -15
  72. package/dist/capabilities/commandcode.json +146 -146
  73. package/dist/capabilities/concentrate.json +286 -277
  74. package/dist/capabilities/cortecs.json +109 -109
  75. package/dist/capabilities/crossmodel.json +194 -194
  76. package/dist/capabilities/crusoe.json +13 -13
  77. package/dist/capabilities/daoxe.json +7 -7
  78. package/dist/capabilities/databricks.json +128 -120
  79. package/dist/capabilities/deepinfra.json +102 -102
  80. package/dist/capabilities/deepseek.json +4 -4
  81. package/dist/capabilities/digitalocean.json +113 -114
  82. package/dist/capabilities/dothoosh.json +29 -29
  83. package/dist/capabilities/doubleword.json +26 -26
  84. package/dist/capabilities/edenai.json +287 -278
  85. package/dist/capabilities/empiriolabs.json +169 -169
  86. package/dist/capabilities/engy.json +24 -18
  87. package/dist/capabilities/entrim.json +6 -6
  88. package/dist/capabilities/evroc.json +13 -13
  89. package/dist/capabilities/ezkielyna.json +9 -9
  90. package/dist/capabilities/fastrouter.json +79 -79
  91. package/dist/capabilities/fireworks-ai.json +92 -92
  92. package/dist/capabilities/freemodel.json +10 -10
  93. package/dist/capabilities/friendli.json +26 -5
  94. package/dist/capabilities/frogbot.json +97 -97
  95. package/dist/capabilities/gisoo.json +19 -19
  96. package/dist/capabilities/gmicloud.json +7 -7
  97. package/dist/capabilities/google.json +53 -53
  98. package/dist/capabilities/graphn.json +14 -14
  99. package/dist/capabilities/greenpt.json +34 -34
  100. package/dist/capabilities/groq.json +4 -4
  101. package/dist/capabilities/helicone.json +88 -88
  102. package/dist/capabilities/hetzner.json +4 -4
  103. package/dist/capabilities/hostinger-router.json +10 -10
  104. package/dist/capabilities/hpc-ai.json +2 -2
  105. package/dist/capabilities/huawei-maas.json +15 -15
  106. package/dist/capabilities/hubris.json +28 -28
  107. package/dist/capabilities/huggingface.json +87 -85
  108. package/dist/capabilities/hyper.json +24 -24
  109. package/dist/capabilities/impossibl.json +114 -114
  110. package/dist/capabilities/inception.json +3 -3
  111. package/dist/capabilities/inceptron.json +8 -8
  112. package/dist/capabilities/inco.json +2 -2
  113. package/dist/capabilities/infer.json +17 -17
  114. package/dist/capabilities/inferall.json +5 -5
  115. package/dist/capabilities/inference-coop.json +2 -2
  116. package/dist/capabilities/inferenceapis.json +27 -27
  117. package/dist/capabilities/inferris.json +3 -3
  118. package/dist/capabilities/infersia.json +11 -11
  119. package/dist/capabilities/infomaniak.json +2 -2
  120. package/dist/capabilities/io-net.json +2 -2
  121. package/dist/capabilities/iteracompute.json +38 -38
  122. package/dist/capabilities/jalapeno.json +10 -10
  123. package/dist/capabilities/jiekou.json +34 -34
  124. package/dist/capabilities/joingonka.json +4 -4
  125. package/dist/capabilities/jzstoken.json +49 -49
  126. package/dist/capabilities/keln.json +24 -24
  127. package/dist/capabilities/kenari.json +122 -137
  128. package/dist/capabilities/kilo.json +615 -614
  129. package/dist/capabilities/kimchi.json +14 -14
  130. package/dist/capabilities/kimi-code-plan-cn.json +9 -9
  131. package/dist/capabilities/kimi-code-plan-global.json +9 -9
  132. package/dist/capabilities/kitani.json +6 -6
  133. package/dist/capabilities/klavo.json +20 -20
  134. package/dist/capabilities/korouter.json +35 -35
  135. package/dist/capabilities/kunavo.json +10 -10
  136. package/dist/capabilities/liquid.json +9 -9
  137. package/dist/capabilities/lithosai.json +2 -2
  138. package/dist/capabilities/llmgateway-providers.json +959 -923
  139. package/dist/capabilities/llmgateway.json +349 -340
  140. package/dist/capabilities/llmtr.json +29 -29
  141. package/dist/capabilities/logits.json +2 -2
  142. package/dist/capabilities/lowrouter.json +53 -53
  143. package/dist/capabilities/lyceum.json +12 -12
  144. package/dist/capabilities/melious.json +9 -9
  145. package/dist/capabilities/merge-gateway.json +271 -263
  146. package/dist/capabilities/meta.json +11 -11
  147. package/dist/capabilities/minimax-cn-coding-plan.json +5 -5
  148. package/dist/capabilities/minimax-cn.json +5 -5
  149. package/dist/capabilities/minimax-coding-plan.json +5 -5
  150. package/dist/capabilities/minimax.json +5 -5
  151. package/dist/capabilities/mistral.json +16 -16
  152. package/dist/capabilities/mixlayer.json +4 -4
  153. package/dist/capabilities/modal.json +11 -11
  154. package/dist/capabilities/model-oracle-ai.json +19 -19
  155. package/dist/capabilities/modelis.json +16 -16
  156. package/dist/capabilities/modular.json +5 -5
  157. package/dist/capabilities/moneo.json +10 -10
  158. package/dist/capabilities/moonshotai-cn.json +6 -6
  159. package/dist/capabilities/moonshotai.json +6 -6
  160. package/dist/capabilities/morph.json +18 -18
  161. package/dist/capabilities/munito-eu.json +8 -8
  162. package/dist/capabilities/munito.json +10 -10
  163. package/dist/capabilities/nan.json +33 -33
  164. package/dist/capabilities/nano-gpt.json +557 -567
  165. package/dist/capabilities/nearai.json +77 -77
  166. package/dist/capabilities/nebius.json +42 -34
  167. package/dist/capabilities/neon.json +127 -127
  168. package/dist/capabilities/neuralwatt.json +37 -37
  169. package/dist/capabilities/nokeep.json +4 -4
  170. package/dist/capabilities/novita-ai.json +115 -115
  171. package/dist/capabilities/nvidia.json +17 -17
  172. package/dist/capabilities/oathbreaker.json +5 -5
  173. package/dist/capabilities/obscurify.json +29 -29
  174. package/dist/capabilities/oci.json +6 -6
  175. package/dist/capabilities/ofox.json +265 -265
  176. package/dist/capabilities/ollama-cloud.json +52 -52
  177. package/dist/capabilities/openai.json +58 -61
  178. package/dist/capabilities/opencode-go.json +90 -90
  179. package/dist/capabilities/openreason.json +6 -6
  180. package/dist/capabilities/openrouter.json +550 -548
  181. package/dist/capabilities/opper.json +26 -26
  182. package/dist/capabilities/orcarouter.json +310 -294
  183. package/dist/capabilities/outerlabs.json +29 -29
  184. package/dist/capabilities/ovhcloud.json +22 -22
  185. package/dist/capabilities/pareto.json +4 -4
  186. package/dist/capabilities/perplexity-agent.json +69 -69
  187. package/dist/capabilities/perplexity.json +2 -2
  188. package/dist/capabilities/phala.json +30 -30
  189. package/dist/capabilities/poe.json +111 -111
  190. package/dist/capabilities/poolside.json +2 -2
  191. package/dist/capabilities/powerspring.json +9 -9
  192. package/dist/capabilities/primalabs.json +11 -11
  193. package/dist/capabilities/prime.json +127 -119
  194. package/dist/capabilities/privatemode-ai.json +6 -6
  195. package/dist/capabilities/proxystacks.json +3 -3
  196. package/dist/capabilities/qiniu-ai.json +13 -13
  197. package/dist/capabilities/refuseless.json +5 -5
  198. package/dist/capabilities/regolo-ai.json +10 -10
  199. package/dist/capabilities/requesty.json +200 -200
  200. package/dist/capabilities/ruapi.json +20 -20
  201. package/dist/capabilities/runcrate.json +13 -13
  202. package/dist/capabilities/runinfra.json +19 -19
  203. package/dist/capabilities/sakana.json +5 -5
  204. package/dist/capabilities/sambanova.json +9 -9
  205. package/dist/capabilities/sandbase.json +22 -22
  206. package/dist/capabilities/sarvam.json +14 -14
  207. package/dist/capabilities/scaleway.json +17 -17
  208. package/dist/capabilities/scnet-token-plan.json +8 -8
  209. package/dist/capabilities/scx-ai.json +22 -22
  210. package/dist/capabilities/sensenova.json +11 -11
  211. package/dist/capabilities/siliconflow-cn.json +59 -59
  212. package/dist/capabilities/siliconflow.json +57 -57
  213. package/dist/capabilities/snowflake-cortex.json +19 -19
  214. package/dist/capabilities/sokkan.json +10 -10
  215. package/dist/capabilities/sparrowcodes.json +20 -20
  216. package/dist/capabilities/standardcompute.json +85 -85
  217. package/dist/capabilities/steadyrouter.json +40 -40
  218. package/dist/capabilities/stepfun-ai-step-plan.json +5 -5
  219. package/dist/capabilities/stepfun-ai.json +5 -5
  220. package/dist/capabilities/stepfun-step-plan.json +5 -5
  221. package/dist/capabilities/stepfun.json +5 -5
  222. package/dist/capabilities/stepping-stone.json +18 -18
  223. package/dist/capabilities/superbot-gg.json +4 -4
  224. package/dist/capabilities/synthetic.json +12 -12
  225. package/dist/capabilities/synthorai.json +21 -21
  226. package/dist/capabilities/teamorouter.json +17 -17
  227. package/dist/capabilities/teapot-router.json +13 -13
  228. package/dist/capabilities/tencent-token-plan-intl.json +22 -22
  229. package/dist/capabilities/tencent-token-plan.json +42 -42
  230. package/dist/capabilities/tencent-tokenhub.json +44 -44
  231. package/dist/capabilities/tensorx.json +43 -43
  232. package/dist/capabilities/tenstorrent.json +2 -2
  233. package/dist/capabilities/the-grid-ai.json +30 -30
  234. package/dist/capabilities/thinkingmachines.json +78 -78
  235. package/dist/capabilities/tinfoil.json +13 -13
  236. package/dist/capabilities/toapis.json +2 -2
  237. package/dist/capabilities/togetherai.json +54 -54
  238. package/dist/capabilities/tokengo.json +23 -23
  239. package/dist/capabilities/tokenharbor.json +217 -217
  240. package/dist/capabilities/tokenify.json +9 -9
  241. package/dist/capabilities/trustedrouter.json +6 -6
  242. package/dist/capabilities/trustedtokens.json +12 -12
  243. package/dist/capabilities/umans-ai-coding-plan.json +17 -17
  244. package/dist/capabilities/umans-ai.json +11 -11
  245. package/dist/capabilities/uncensuredai.json +5 -5
  246. package/dist/capabilities/unrestricted.json +4 -4
  247. package/dist/capabilities/uplinkswitch.json +20 -20
  248. package/dist/capabilities/upstage.json +2 -2
  249. package/dist/capabilities/vancine.json +20 -20
  250. package/dist/capabilities/vercel.json +580 -571
  251. package/dist/capabilities/vivgrid.json +61 -61
  252. package/dist/capabilities/volcengine-coding-plan.json +26 -26
  253. package/dist/capabilities/volcengine.json +24 -24
  254. package/dist/capabilities/vultr.json +15 -15
  255. package/dist/capabilities/wafer.ai.json +19 -19
  256. package/dist/capabilities/wallaby.json +5 -5
  257. package/dist/capabilities/wally.json +11 -11
  258. package/dist/capabilities/wandb.json +21 -21
  259. package/dist/capabilities/watt.json +19 -19
  260. package/dist/capabilities/xai.json +2 -2
  261. package/dist/capabilities/xpersona.json +13 -13
  262. package/dist/capabilities/xxapi.json +27 -27
  263. package/dist/capabilities/zai-coding-plan.json +11 -11
  264. package/dist/capabilities/zai.json +32 -32
  265. package/dist/capabilities/zenifra.json +27 -27
  266. package/dist/capabilities/zenmux.json +178 -178
  267. package/dist/capabilities/zerogpu.json +12 -12
  268. package/dist/capabilities/zhipuai-coding-plan.json +3 -3
  269. package/dist/capabilities/zhipuai.json +28 -28
  270. package/dist/capabilities/zro.json +7 -7
  271. package/dist/channels/index.cjs +2 -2
  272. package/dist/channels/index.js +2 -2
  273. package/dist/{channels-DChC1kXm.js → channels-BQ--aLCA.js} +1 -1
  274. package/dist/{channels-BamLzaJG.cjs → channels-CTCBsS5M.cjs} +1 -1
  275. package/dist/coding-agent/index.cjs +1 -1
  276. package/dist/coding-agent/index.js +1 -1
  277. package/dist/datasets/index.cjs +2 -2
  278. package/dist/datasets/index.js +2 -2
  279. package/dist/docs/SKILL.md +1 -1
  280. package/dist/docs/assets/SOURCE_MAP.json +804 -804
  281. package/dist/docs/references/docs-agents-human-in-the-loop.md +1 -1
  282. package/dist/docs/references/docs-agents-resumable-streams.md +3 -3
  283. package/dist/docs/references/docs-channels.md +8 -2
  284. package/dist/docs/references/docs-deployment-workers.md +10 -4
  285. package/dist/docs/references/docs-harness-durable-agents.md +17 -15
  286. package/dist/docs/references/docs-server-mcp.md +68 -0
  287. package/dist/docs/references/docs-server-pubsub.md +25 -16
  288. package/dist/docs/references/docs-signals-running-across-processes.md +9 -3
  289. package/dist/docs/references/docs-signals-sending-signals.md +1 -1
  290. package/dist/docs/references/docs-workflows-overview.md +3 -3
  291. package/dist/docs/references/reference-agents-agent.md +3 -1
  292. package/dist/docs/references/reference-agents-durable-agent.md +3 -3
  293. package/dist/docs/references/reference-configuration.md +60 -0
  294. package/dist/docs/references/reference-pubsub-base.md +1 -1
  295. package/dist/docs/references/reference-pubsub-caching-pubsub.md +1 -1
  296. package/dist/docs/references/reference-pubsub-google-cloud-pubsub.md +13 -7
  297. package/dist/docs/references/reference-pubsub-lease-provider.md +4 -0
  298. package/dist/docs/references/reference-pubsub-redis-streams.md +18 -9
  299. package/dist/docs/references/reference-pubsub-valkey-streams.md +25 -7
  300. package/dist/evals/index.cjs +1 -1
  301. package/dist/evals/index.js +1 -1
  302. package/dist/evals/scoreTraces/index.cjs +1 -1
  303. package/dist/evals/scoreTraces/index.js +1 -1
  304. package/dist/events/caching-pubsub.d.ts +3 -11
  305. package/dist/events/index.cjs +1 -1
  306. package/dist/events/index.js +1 -1
  307. package/dist/events/pubsub.d.ts +2 -1
  308. package/dist/{execution-fence-BBKnrhWR.cjs → execution-fence-C8Q0wWkG.cjs} +841 -219
  309. package/dist/{execution-fence--VdnD7p4.js → execution-fence-DGFyUV5h.js} +841 -219
  310. package/dist/harness/index.cjs +1 -1
  311. package/dist/harness/index.js +1 -1
  312. package/dist/index.cjs +1 -1
  313. package/dist/index.js +1 -1
  314. package/dist/knowledge/index.cjs +1 -1
  315. package/dist/knowledge/index.js +1 -1
  316. package/dist/llm/index.cjs +3 -3
  317. package/dist/llm/index.js +3 -3
  318. package/dist/llm/model/provider-types.generated.d.ts +7689 -7673
  319. package/dist/llm/reasoning/account-switch.d.ts +50 -0
  320. package/dist/llm/reasoning/index.cjs +65 -0
  321. package/dist/llm/reasoning/index.d.ts +1 -0
  322. package/dist/llm/reasoning/index.js +61 -1
  323. package/dist/{llm-DknPJDW6.cjs → llm-RIAYOAtD.cjs} +2 -2
  324. package/dist/{llm-ccA_1Q-H.js → llm-YNjDFSui.js} +2 -2
  325. package/dist/loop/index.cjs +2 -2
  326. package/dist/loop/index.js +2 -2
  327. package/dist/loop/suspended-run-auto-resume.d.ts +15 -0
  328. package/dist/loop/workflows/agentic-execution/tool-call-step.d.ts +1 -1
  329. package/dist/{manager-DWX6-Cx4.js → manager-DZhtdV6Q.js} +2 -2
  330. package/dist/{manager-D9F0i7O2.cjs → manager-Y-jYcS7T.cjs} +2 -2
  331. package/dist/mastra/index.cjs +1 -1
  332. package/dist/mastra/index.d.ts +35 -11
  333. package/dist/mastra/index.js +1 -1
  334. package/dist/{mastra-BzWL4xI8.cjs → mastra-B2-HBq1-.cjs} +108 -20
  335. package/dist/{mastra-oUDN81l8.js → mastra-BJ54VxOO.js} +108 -20
  336. package/dist/memory/index.cjs +2 -2
  337. package/dist/memory/index.js +2 -2
  338. package/dist/{model-BwxfS6T_.js → model-cS3d5rmF.js} +1 -1
  339. package/dist/{model-BnD7SPlA.cjs → model-lzZPXaEV.cjs} +1 -1
  340. package/dist/{netlify-CS0VDbb9.cjs → netlify-1lti1j4Z.cjs} +1 -1
  341. package/dist/{netlify-DcY9gHCJ.js → netlify-ClBjc0Xg.js} +1 -1
  342. package/dist/notifications/index.cjs +1 -1
  343. package/dist/notifications/index.js +1 -1
  344. package/dist/{output-helpers-k2-48ssH.js → output-helpers-D-qplq22.js} +13 -15
  345. package/dist/{output-helpers-By5FbLpp.cjs → output-helpers-D4O_oFne.cjs} +12 -14
  346. package/dist/processor-provider/index.cjs +1 -1
  347. package/dist/processor-provider/index.js +1 -1
  348. package/dist/processors/index.cjs +2 -2
  349. package/dist/processors/index.js +2 -2
  350. package/dist/{provider-registry-OggbU6OE.cjs → provider-registry-C6jd3Uxi.cjs} +21565 -21544
  351. package/dist/{provider-registry-BvbEoScB.js → provider-registry-C_XQJvu2.js} +21565 -21544
  352. package/dist/provider-registry.json +22006 -21980
  353. package/dist/{registry-generator-CDaf48a6.cjs → registry-generator-BYdAlox6.cjs} +1 -1
  354. package/dist/{registry-generator-BFOQQHyt.js → registry-generator-DBrTbThj.js} +1 -1
  355. package/dist/{rehydrate-CFoKaNlm.js → rehydrate-4xHubfOY.js} +2 -2
  356. package/dist/{rehydrate-QeS0NjGw.cjs → rehydrate-BtwY0ima.cjs} +2 -2
  357. package/dist/relevance/index.cjs +2 -2
  358. package/dist/relevance/index.js +2 -2
  359. package/dist/{scheduler-0ShtMM1I.js → scheduler-D1qdie5k.js} +4 -2
  360. package/dist/{scheduler-CMjK0LoQ.cjs → scheduler-DE5lcHJA.cjs} +4 -2
  361. package/dist/server/index.d.ts +1 -1
  362. package/dist/server/types.d.ts +57 -0
  363. package/dist/storage/domains/memory/base.d.ts +6 -1
  364. package/dist/storage/index.cjs +2 -2
  365. package/dist/storage/index.js +2 -2
  366. package/dist/stream/index.cjs +2 -2
  367. package/dist/stream/index.js +2 -2
  368. package/dist/{stream-CNqAlDJF.cjs → stream-DqKDB3nL.cjs} +1 -1
  369. package/dist/{stream-D2rv1Ut1.js → stream-H_wVxqdK.js} +1 -1
  370. package/dist/test-utils/llm-mock.cjs +1 -1
  371. package/dist/test-utils/llm-mock.js +1 -1
  372. package/dist/tool-loop-agent/index.cjs +1 -1
  373. package/dist/tool-loop-agent/index.js +1 -1
  374. package/dist/{tool-loop-agent-Dusqj7-j.cjs → tool-loop-agent-D4gSdYuN.cjs} +3 -3
  375. package/dist/{tool-loop-agent-CFsOjueT.js → tool-loop-agent-DvZcOxWe.js} +3 -3
  376. package/dist/{utils-CIuOHPoS.cjs → utils-Dd4m7z13.cjs} +1 -1
  377. package/dist/{utils-DLnCt6E9.js → utils-h5k_ChdS.js} +1 -1
  378. package/dist/utils.cjs +1 -1
  379. package/dist/utils.js +1 -1
  380. package/dist/{validate-ShLcQTA5.js → validate-DQB9spZ1.js} +1 -1
  381. package/dist/{validate-1zReLtWc.cjs → validate-u6_TUYSo.cjs} +1 -1
  382. package/dist/vector/index.cjs +1 -1
  383. package/dist/vector/index.js +1 -1
  384. package/dist/worker/index.cjs +1 -1
  385. package/dist/worker/index.d.ts +1 -1
  386. package/dist/worker/index.js +1 -1
  387. package/dist/worker/workers/orchestration-worker.d.ts +13 -0
  388. package/dist/{worker-CQ8rTJwQ.cjs → worker-0F7Nukyf.cjs} +2 -2
  389. package/dist/{worker-BPNrwCFs.cjs → worker-D-cq8McN.cjs} +117 -32
  390. package/dist/{worker-ngt-F1Iv.js → worker-DWOK2M_5.js} +117 -32
  391. package/dist/{worker-CKcQcPl8.js → worker-DmUkyJY_.js} +2 -2
  392. package/dist/{workflow-B_e5wMmz.cjs → workflow-DXE15e-w.cjs} +4 -4
  393. package/dist/{workflow-XDIVRsu4.js → workflow-DamOke3z.js} +4 -4
  394. package/dist/workflows/builder/index.cjs +1 -1
  395. package/dist/workflows/builder/index.js +1 -1
  396. package/dist/workflows/evented/index.cjs +1 -1
  397. package/dist/workflows/evented/index.js +1 -1
  398. package/dist/workflows/evented/setup-warning.d.ts +20 -0
  399. package/dist/workflows/index.cjs +5 -5
  400. package/dist/workflows/index.js +5 -5
  401. package/dist/workflows/scheduler/types.d.ts +3 -0
  402. package/dist/workspace/tools/media.d.ts +2 -2
  403. package/package.json +7 -7
  404. package/src/llm/model/provider-types.generated.d.ts +7689 -7673
@@ -746,6 +746,7 @@ Configures the [built-in MCP server](https://mastra.ai/docs/server/mcp) that exp
746
746
  | `exclude` | `{ agents?: string[]; workflows?: string[]; tools?: string[] }` | `undefined` | Never exposed. Each entry matches a primitive's `id` or its registration key. Takes precedence over `include`. |
747
747
  | `serverInfo` | `{ name?: string; version?: string; title?: string; instructions?: string }` | `undefined` | Server identity reported to MCP clients. |
748
748
  | `oauth` | `{ resource?: string; requireAudience?: boolean; authorizationServers?: string[]; scopesSupported?: string[] }` | `undefined` | OAuth discovery and token audience settings. See [`server.mcp.oauth`](#servermcpoauth). |
749
+ | `card` | `object \| false` | `{}` | The endpoint's public [MCP Server Card](https://mastra.ai/docs/server/mcp). `false` stops serving it. See [`server.mcp.card`](#servermcpcard). |
749
750
 
750
751
  ```typescript
751
752
  import { Mastra } from '@mastra/core'
@@ -791,6 +792,38 @@ export const mastra = new Mastra({
791
792
  })
792
793
  ```
793
794
 
795
+ ### `server.mcp.card`
796
+
797
+ **Type:** `object | false`\
798
+ **Default:** `{}`
799
+
800
+ Overrides for the [MCP Server Card](https://mastra.ai/docs/server/mcp) served at `<endpoint>/server-card`. Every field is optional. The card is experimental and its shape may change. Mastra checks `name`, `title`, `description`, `url`, and `websiteUrl` at startup, and an invalid value stops the server with an error naming the field. `repository` and `icons` are published as given.
801
+
802
+ | Property | Type | Default | Description | |
803
+ | ------------- | ----------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | - |
804
+ | `name` | `string` | `serverInfo.name` when it's already a valid card name, otherwise the endpoint host in reverse-DNS order, then `/mastra` | Reverse-DNS name with exactly one `/`, for example `com.example/assistant`. | |
805
+ | `title` | `string` | `serverInfo.title`, then `serverInfo.name`, skipping blank values | Display name, 1 to 100 characters. | |
806
+ | `description` | `string` | `'Mastra server exposing agents, workflows, and tools over MCP'` | 1 to 100 characters. | |
807
+ | `websiteUrl` | `string` | `undefined` | Homepage or documentation URL, as an absolute `http` or `https` URL that's a valid RFC 3986 URI as written. | |
808
+ | `repository` | `{ url: string; source: string; subfolder?: string; id?: string }` | `undefined` | Where the server's source code lives. | |
809
+ | `icons` | `{ src: string; mimeType?: string; sizes?: string[]; theme?: 'light' \| 'dark' }[]` | `undefined` | Icons clients can show for the server. | |
810
+ | `url` | `string` | `oauth.resource`, then the URL the card was requested under | Public URL of the MCP endpoint, as an absolute `http` or `https` URL without credentials. Templates such as `{baseUrl}/mcp` and URLs that aren't valid RFC 3986 URIs, such as ones with an invalid escape like `%zz`, aren't accepted. The card lists the URL in normalized form. Set it behind a proxy so the card names the public URL. | |
811
+
812
+ ```typescript
813
+ import { Mastra } from '@mastra/core'
814
+
815
+ export const mastra = new Mastra({
816
+ server: {
817
+ mcp: {
818
+ card: {
819
+ name: 'com.example/assistant',
820
+ url: 'https://my-app.example.com/api/mcp',
821
+ },
822
+ },
823
+ },
824
+ })
825
+ ```
826
+
794
827
  ### server.mcpOptions
795
828
 
796
829
  **Type:** `object`\
@@ -1079,6 +1112,33 @@ export const mastra = new Mastra({
1079
1112
 
1080
1113
  Sending either shutdown signal again during the drain bypasses it and terminates the process immediately.
1081
1114
 
1115
+ ### server.drain
1116
+
1117
+ **Type:** `'run' | 'step'`\
1118
+ **Default:** `'run'`
1119
+
1120
+ How `mastra.shutdown()` drains evented workflow runs (including durable agent runs) after the server receives `SIGINT` or `SIGTERM`. Both values share the [`server.drainTimeout`](#serverdraintimeout) window.
1121
+
1122
+ - `'run'`: The instance keeps taking workflow events while it waits for its in-flight runs to reach a finished or suspended state.
1123
+ - `'step'`: Once the HTTP drain is over, the instance stops taking workflow events and finishes the steps it's executing. Another instance on the same PubSub backend continues each run from its next step. The instance still waits, up to `drainTimeout`, for the runs it started to finish there, so it doesn't exit sooner.
1124
+
1125
+ Use `'step'` for rolling deploys, where another instance is running while this one shuts down. It's supported on Redis Streams and Valkey Streams, while a PubSub backend that doesn't redeliver unacknowledged events makes Mastra log a warning and behave as `'run'`. Don't use it with Google Cloud Pub/Sub, where a step still running when shutdown begins can run twice.
1126
+
1127
+ An agent run that outlives this instance keeps executing on the other one, but clients subscribed to its thread stop receiving its output and their stream ends with an error.
1128
+
1129
+ ```typescript
1130
+ import { Mastra } from '@mastra/core'
1131
+
1132
+ export const mastra = new Mastra({
1133
+ server: {
1134
+ drainTimeout: 60000,
1135
+ drain: 'step',
1136
+ },
1137
+ })
1138
+ ```
1139
+
1140
+ See [hand runs over during a rolling deploy](https://mastra.ai/docs/deployment/mastra-server) for the limits of `'step'`.
1141
+
1082
1142
  ### server.studioBase
1083
1143
 
1084
1144
  **Type:** `string`\
@@ -174,7 +174,7 @@ await pubsub.subscribeFromOffset('my-topic', 42, event => {
174
174
 
175
175
  **supportsOffsets** (`boolean`): Whether subscribeFromOffset() honors numeric offsets. Defaults to false. A non-zero offset on an unsupported implementation falls back to replay subscription and logs a warning with console.warn. Implementations can override onUnsupportedOffset() to use their own logger.
176
176
 
177
- **deliversAcrossProcesses** (`boolean`): Whether a published event can reach a subscriber in another process. Defaults to true, so Mastra coordinates runs with other processes unless the implementation says otherwise. Return false only when every subscriber lives in the publishing process, as EventEmitterPubSub does.
177
+ **deliversAcrossProcesses** (`boolean`): Whether a published event can reach a subscriber in another process. Defaults to true, so Mastra coordinates runs with other processes unless the implementation says otherwise. Return false only when every subscriber lives in the publishing process, as EventEmitterPubSub does. With true, set a server cache that every process shares on Mastra, because agent runs keep their stream events and ownership record there.
178
178
 
179
179
  **redeliversUnacked** (`boolean`): Whether an event delivered to a consumer that neither acks nor nacks it, for example because its process stopped, is delivered again to another consumer of the same group once the broker considers it abandoned. Defaults to false. Workflow recovery doesn't restart evented runs on a pubsub that returns true, so return true only when the broker does this. Evented workflows and agents that run on several processes need true. See evented workflows and agents.
180
180
 
@@ -6,7 +6,7 @@
6
6
 
7
7
  `CachingPubSub` wraps any [`PubSub`](https://mastra.ai/reference/pubsub/base) implementation and adds event caching and replay. It records published events per topic in a cache, so a subscriber that connects late or reconnects after a disconnect can replay the events it missed before continuing with live events.
8
8
 
9
- Use it to build resumable streams on top of a transport that doesn't keep history, such as [`EventEmitterPubSub`](https://mastra.ai/reference/pubsub/event-emitter). Transports that already persist events, such as [`RedisStreamsPubSub`](https://mastra.ai/reference/pubsub/redis-streams), don't need this wrapper.
9
+ Mastra already wraps agent run streams in `CachingPubSub` with the server cache of the `Mastra` instance. Use it yourself to add replay to other topics. Over a transport that reaches other processes, such as [`RedisStreamsPubSub`](https://mastra.ai/reference/pubsub/redis-streams), pass a cache that every process shares: each process otherwise records only the events it published itself.
10
10
 
11
11
  `CachingPubSub` is transparent to batching: `subscribe()` forwards `options.batch` to the inner pub/sub, and `supportsNativeBatching` mirrors the inner's value. Wrapping an inner that doesn't support batching results in unbatched delivery even when `options.batch` is passed.
12
12
 
@@ -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
- pubsub: new GoogleCloudPubSub({
49
- projectId: 'my-project',
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
- Provide a Redis connection URL.
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
- url: 'redis://localhost:6379',
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, and `keyPrefix`. 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.
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
- url: 'valkey://localhost:6379',
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`)
@@ -1,5 +1,5 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
- const require_execution_fence = require("../execution-fence-BBKnrhWR.cjs");
2
+ const require_execution_fence = require("../execution-fence-C8Q0wWkG.cjs");
3
3
  const require_constants = require("../constants-B2FVV_2e.cjs");
4
4
  const require_collect_tool_mocks = require("../collect-tool-mocks-k9fM6oDl.cjs");
5
5
  exports.MastraScorer = require_execution_fence.MastraScorer;
@@ -1,4 +1,4 @@
1
- import { Gc as SCORING_PREDICATE_ROOTS, Kc as evaluateScoringPredicate, _ as isNotScorable, c as runEvals, f as createClassifierScorer, g as filterRun, h as createScorer, m as ScorerRunError, p as MastraScorer, qc as validateScoringPredicate, v as notScorable } from "../execution-fence--VdnD7p4.js";
1
+ import { Gc as SCORING_PREDICATE_ROOTS, Kc as evaluateScoringPredicate, _ as isNotScorable, c as runEvals, f as createClassifierScorer, g as filterRun, h as createScorer, m as ScorerRunError, p as MastraScorer, qc as validateScoringPredicate, v as notScorable } from "../execution-fence-DGFyUV5h.js";
2
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-Dro9fuhk.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,7 +1,7 @@
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-BBKnrhWR.cjs");
4
+ const require_execution_fence = require("../../execution-fence-C8Q0wWkG.cjs");
5
5
  const require_constants = require("../../constants-B2FVV_2e.cjs");
6
6
  let zod_v4 = require("zod/v4");
7
7
  // src/evals/scoreTraces/scoreTraces.ts
@@ -1,6 +1,6 @@
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 { Ns as createStep, Ps as createWorkflow } from "../../execution-fence--VdnD7p4.js";
3
+ import { Ns as createStep, Ps as createWorkflow } from "../../execution-fence-DGFyUV5h.js";
4
4
  import { Dr as saveScorePayloadSchema } from "../../constants-Dro9fuhk.js";
5
5
  import { z } from "zod/v4";
6
6
  // src/evals/scoreTraces/scoreTraces.ts
@@ -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, and `onUnlogged` is
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 is already warned about (`onUnlogged`)
170
- * and its replays miss those frames whatever they carry, so it still counts
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;
@@ -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-By5FbLpp.cjs");
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");
@@ -1,4 +1,4 @@
1
- import { S as isLeaseProvider, _ as PublisherQueueLimitError, a as withCaching, b as NoopLeaseProvider, c as RUN_LOCAL_TOPIC_PREFIXES, d as isRunLocalTopic, f as streamTopicIdleTtlMs, i as CachingPubSub, l as RUN_LOG_TTL_MS, n as rehydrateError, o as DEFAULT_RUN_LOG_TTL_MS, p as toCachedLogFrame, r as serializeError, s as DEFAULT_THREAD_STREAM_LOG_TTL_MS, t as DefaultStepResult, u as cachedLogTtlMs, v as EventEmitterPubSub, x as PubSub, y as withAck } from "../output-helpers-k2-48ssH.js";
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";
@@ -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
  */