@mastra/core 1.86.0-alpha.8 → 1.86.0-alpha.9

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 (459) hide show
  1. package/dist/_types/@internal_core@0.1.4/dist/knowledge-compat/index.d.ts +363 -0
  2. package/dist/a2a/index.cjs +1 -1
  3. package/dist/a2a/index.js +1 -1
  4. package/dist/agent/agent.d.ts +12 -0
  5. package/dist/agent/durable/index.cjs +1 -13
  6. package/dist/agent/durable/index.js +1 -13
  7. package/dist/agent/durable/preparation.d.ts +2 -0
  8. package/dist/agent/durable/utils/resolve-runtime.d.ts +9 -0
  9. package/dist/agent/durable/workflows/durable-loop-builder.d.ts +4 -0
  10. package/dist/agent/durable/workflows/finalize-run.d.ts +3 -1
  11. package/dist/agent/durable/workflows/steps/llm-execution.d.ts +1 -0
  12. package/dist/agent/index.cjs +3 -3
  13. package/dist/agent/index.js +3 -3
  14. package/dist/agent/message-list/index.cjs +1 -1
  15. package/dist/agent/message-list/index.js +1 -1
  16. package/dist/agent/message-list/message-list.d.ts +11 -0
  17. package/dist/agent/message-list/utils/provider-compat.d.ts +1 -0
  18. package/dist/agent/request-context-snapshot.d.ts +1 -1
  19. package/dist/agent/streams/types.d.ts +10 -0
  20. package/dist/agent/thread-stream-runtime.d.ts +5 -0
  21. package/dist/agent-builder/ee/index.cjs +1 -1
  22. package/dist/agent-builder/ee/index.js +1 -1
  23. package/dist/agent-controller/index.cjs +1 -1
  24. package/dist/agent-controller/index.js +1 -1
  25. package/dist/{agent-controller-DEPayioq.cjs → agent-controller-CrQ9OF80.cjs} +7 -7
  26. package/dist/{agent-controller-B7POPub5.js → agent-controller-SSlKzE6A.js} +7 -7
  27. package/dist/background-tasks/index.cjs +1 -1
  28. package/dist/background-tasks/index.js +1 -1
  29. package/dist/{background-tasks-7iftnRK_.cjs → background-tasks-BDrYBis-.cjs} +5 -3
  30. package/dist/{background-tasks-Cv1ecD6S.js → background-tasks-BnJfNLFo.js} +5 -3
  31. package/dist/browser/index.cjs +2 -2
  32. package/dist/browser/index.js +2 -2
  33. package/dist/{builder-Gg-xnX_E.js → builder-Cl-0BWkh.js} +2 -2
  34. package/dist/{builder-DuJBbQDH.cjs → builder-Cw8u3pPl.cjs} +2 -2
  35. package/dist/capabilities/302ai.json +204 -204
  36. package/dist/capabilities/abliteratedllm.json +30 -30
  37. package/dist/capabilities/above.json +21 -21
  38. package/dist/capabilities/adaption.json +15 -15
  39. package/dist/capabilities/adzuki.json +24 -24
  40. package/dist/capabilities/agentrouter.json +9 -9
  41. package/dist/capabilities/agnes.json +3 -3
  42. package/dist/capabilities/ai-router.json +8 -8
  43. package/dist/capabilities/aiand.json +31 -23
  44. package/dist/capabilities/aigrow.json +14 -14
  45. package/dist/capabilities/aimlapi.json +144 -147
  46. package/dist/capabilities/aipg.json +2 -2
  47. package/dist/capabilities/aixy.json +21 -21
  48. package/dist/capabilities/aki-io.json +10 -10
  49. package/dist/capabilities/alibaba-cn.json +136 -117
  50. package/dist/capabilities/alibaba-coding-plan-cn.json +7 -19
  51. package/dist/capabilities/alibaba-coding-plan.json +7 -19
  52. package/dist/capabilities/alibaba-token-plan-cn.json +49 -67
  53. package/dist/capabilities/alibaba-token-plan.json +50 -68
  54. package/dist/capabilities/alibaba.json +72 -119
  55. package/dist/capabilities/ambient.json +8 -8
  56. package/dist/capabilities/amd.json +10 -10
  57. package/dist/capabilities/anthropic.json +47 -47
  58. package/dist/capabilities/anyapi.json +19 -19
  59. package/dist/capabilities/apiko.json +5 -5
  60. package/dist/capabilities/arcee.json +11 -11
  61. package/dist/capabilities/augure.json +2 -2
  62. package/dist/capabilities/auriko.json +23 -23
  63. package/dist/capabilities/bailing.json +4 -4
  64. package/dist/capabilities/baseten.json +55 -25
  65. package/dist/capabilities/bee.json +4 -4
  66. package/dist/capabilities/berget.json +5 -5
  67. package/dist/capabilities/bothub.json +17 -17
  68. package/dist/capabilities/boundless.json +37 -37
  69. package/dist/capabilities/bumo.json +41 -41
  70. package/dist/capabilities/byteplus.json +26 -26
  71. package/dist/capabilities/cerebras.json +4 -4
  72. package/dist/capabilities/cheapaimodel.json +3 -3
  73. package/dist/capabilities/cheapest-token.json +30 -30
  74. package/dist/capabilities/chutes.json +10 -10
  75. package/dist/capabilities/cline-pass.json +39 -39
  76. package/dist/capabilities/cloudcode.json +9 -9
  77. package/dist/capabilities/cloudferro-sherlock.json +4 -4
  78. package/dist/capabilities/cloudflare-workers-ai.json +33 -33
  79. package/dist/capabilities/commandcode.json +139 -139
  80. package/dist/capabilities/concentrate.json +274 -274
  81. package/dist/capabilities/cortecs.json +108 -108
  82. package/dist/capabilities/crossmodel.json +189 -189
  83. package/dist/capabilities/crusoe.json +10 -10
  84. package/dist/capabilities/daoxe.json +9 -9
  85. package/dist/capabilities/databricks.json +315 -59
  86. package/dist/capabilities/deepinfra.json +90 -155
  87. package/dist/capabilities/deepseek.json +2 -2
  88. package/dist/capabilities/digitalocean.json +114 -114
  89. package/dist/capabilities/dothoosh.json +34 -34
  90. package/dist/capabilities/doubleword.json +28 -28
  91. package/dist/capabilities/edenai.json +433 -433
  92. package/dist/capabilities/empiriolabs.json +176 -176
  93. package/dist/capabilities/engy.json +17 -17
  94. package/dist/capabilities/entrim.json +6 -6
  95. package/dist/capabilities/evroc.json +13 -13
  96. package/dist/capabilities/ezkielyna.json +12 -12
  97. package/dist/capabilities/fastrouter.json +88 -88
  98. package/dist/capabilities/fireworks-ai.json +104 -41
  99. package/dist/capabilities/freemodel.json +20 -20
  100. package/dist/capabilities/friendli.json +9 -9
  101. package/dist/capabilities/frogbot.json +93 -93
  102. package/dist/capabilities/gisoo.json +19 -19
  103. package/dist/capabilities/gmicloud.json +21 -21
  104. package/dist/capabilities/google.json +55 -55
  105. package/dist/capabilities/graphn.json +11 -11
  106. package/dist/capabilities/greenpt.json +36 -36
  107. package/dist/capabilities/groq.json +9 -9
  108. package/dist/capabilities/helicone.json +83 -83
  109. package/dist/capabilities/hostinger-router.json +13 -13
  110. package/dist/capabilities/hpc-ai.json +8 -8
  111. package/dist/capabilities/huawei-maas.json +17 -17
  112. package/dist/capabilities/hubris.json +28 -28
  113. package/dist/capabilities/huggingface.json +200 -53
  114. package/dist/capabilities/humain.json +2 -2
  115. package/dist/capabilities/hyper.json +26 -26
  116. package/dist/capabilities/impossibl.json +127 -127
  117. package/dist/capabilities/inception.json +2 -2
  118. package/dist/capabilities/inceptron.json +8 -8
  119. package/dist/capabilities/inco.json +4 -4
  120. package/dist/capabilities/infer.json +14 -14
  121. package/dist/capabilities/inference-coop.json +15 -15
  122. package/dist/capabilities/inferenceapis.json +22 -22
  123. package/dist/capabilities/inferris.json +3 -3
  124. package/dist/capabilities/infersia.json +9 -9
  125. package/dist/capabilities/inferx.json +3 -3
  126. package/dist/capabilities/infomaniak.json +4 -4
  127. package/dist/capabilities/io-net.json +5 -5
  128. package/dist/capabilities/isoquant.json +4 -4
  129. package/dist/capabilities/iteracompute.json +51 -51
  130. package/dist/capabilities/jalapeno.json +12 -12
  131. package/dist/capabilities/jiekou.json +65 -65
  132. package/dist/capabilities/joingonka.json +4 -4
  133. package/dist/capabilities/jzstoken.json +54 -54
  134. package/dist/capabilities/keln.json +21 -28
  135. package/dist/capabilities/kenari.json +124 -121
  136. package/dist/capabilities/kilo.json +635 -636
  137. package/dist/capabilities/kimi-code-plan-cn.json +6 -6
  138. package/dist/capabilities/kimi-code-plan-global.json +6 -6
  139. package/dist/capabilities/kitani.json +4 -4
  140. package/dist/capabilities/klavo.json +13 -13
  141. package/dist/capabilities/korouter.json +31 -31
  142. package/dist/capabilities/kunavo.json +9 -9
  143. package/dist/capabilities/liquid.json +10 -10
  144. package/dist/capabilities/llmgateway-providers.json +909 -909
  145. package/dist/capabilities/llmgateway.json +333 -333
  146. package/dist/capabilities/llmtr.json +19 -19
  147. package/dist/capabilities/logits.json +2 -2
  148. package/dist/capabilities/longcat.json +1 -6
  149. package/dist/capabilities/lowrouter.json +52 -52
  150. package/dist/capabilities/lyceum.json +7 -7
  151. package/dist/capabilities/melious.json +16 -16
  152. package/dist/capabilities/merge-gateway.json +275 -275
  153. package/dist/capabilities/meta.json +9 -9
  154. package/dist/capabilities/minimax-cn-coding-plan.json +6 -6
  155. package/dist/capabilities/minimax-coding-plan.json +6 -6
  156. package/dist/capabilities/mistral.json +18 -18
  157. package/dist/capabilities/mixlayer.json +5 -5
  158. package/dist/capabilities/modal.json +13 -13
  159. package/dist/capabilities/model-oracle-ai.json +26 -26
  160. package/dist/capabilities/modelis.json +24 -24
  161. package/dist/capabilities/modelscope.json +2 -2
  162. package/dist/capabilities/modular.json +9 -9
  163. package/dist/capabilities/moneo.json +14 -14
  164. package/dist/capabilities/moonshotai-cn.json +6 -6
  165. package/dist/capabilities/moonshotai.json +6 -6
  166. package/dist/capabilities/morph.json +13 -13
  167. package/dist/capabilities/munito-eu.json +6 -6
  168. package/dist/capabilities/munito.json +10 -10
  169. package/dist/capabilities/nan.json +24 -24
  170. package/dist/capabilities/nano-gpt.json +577 -577
  171. package/dist/capabilities/nearai.json +82 -82
  172. package/dist/capabilities/nebius.json +29 -29
  173. package/dist/capabilities/neon.json +134 -134
  174. package/dist/capabilities/neuralwatt.json +43 -43
  175. package/dist/capabilities/nokeep.json +4 -4
  176. package/dist/capabilities/novita-ai.json +135 -135
  177. package/dist/capabilities/nvidia.json +38 -38
  178. package/dist/capabilities/oathbreaker.json +2 -2
  179. package/dist/capabilities/obscurify.json +26 -26
  180. package/dist/capabilities/oci.json +5 -5
  181. package/dist/capabilities/ofox.json +338 -338
  182. package/dist/capabilities/ollama-cloud.json +55 -55
  183. package/dist/capabilities/openai.json +48 -48
  184. package/dist/capabilities/opencode-go.json +81 -81
  185. package/dist/capabilities/openreason.json +5 -5
  186. package/dist/capabilities/openrouter.json +548 -563
  187. package/dist/capabilities/opper.json +23 -23
  188. package/dist/capabilities/orcarouter.json +212 -212
  189. package/dist/capabilities/outerlabs.json +30 -30
  190. package/dist/capabilities/ovhcloud.json +8 -8
  191. package/dist/capabilities/pareto.json +5 -5
  192. package/dist/capabilities/pendra.json +4 -4
  193. package/dist/capabilities/perplexity-agent.json +59 -59
  194. package/dist/capabilities/perplexity.json +2 -2
  195. package/dist/capabilities/phala.json +27 -27
  196. package/dist/capabilities/pioneer.json +24 -24
  197. package/dist/capabilities/poe.json +136 -136
  198. package/dist/capabilities/powerspring.json +14 -14
  199. package/dist/capabilities/primalabs.json +7 -7
  200. package/dist/capabilities/prime.json +108 -108
  201. package/dist/capabilities/privatemode-ai.json +12 -12
  202. package/dist/capabilities/proxystacks.json +6 -6
  203. package/dist/capabilities/qiniu-ai.json +15 -15
  204. package/dist/capabilities/refuseless.json +9 -9
  205. package/dist/capabilities/regolo-ai.json +6 -6
  206. package/dist/capabilities/requesty.json +171 -171
  207. package/dist/capabilities/ruapi.json +20 -20
  208. package/dist/capabilities/runcrate.json +16 -16
  209. package/dist/capabilities/runinfra.json +17 -17
  210. package/dist/capabilities/sakana.json +6 -6
  211. package/dist/capabilities/sambanova.json +6 -6
  212. package/dist/capabilities/sandbase.json +16 -16
  213. package/dist/capabilities/sarvam.json +12 -12
  214. package/dist/capabilities/scaleway.json +17 -17
  215. package/dist/capabilities/scnet-token-plan.json +8 -8
  216. package/dist/capabilities/scx-ai.json +29 -29
  217. package/dist/capabilities/sensenova.json +14 -14
  218. package/dist/capabilities/siliconflow-cn.json +61 -61
  219. package/dist/capabilities/siliconflow.json +57 -57
  220. package/dist/capabilities/snowflake-cortex.json +24 -24
  221. package/dist/capabilities/sokkan.json +10 -10
  222. package/dist/capabilities/sparrowcodes.json +24 -24
  223. package/dist/capabilities/standardcompute.json +89 -89
  224. package/dist/capabilities/steadyrouter.json +38 -38
  225. package/dist/capabilities/stepfun-ai-step-plan.json +7 -7
  226. package/dist/capabilities/stepfun-ai.json +16 -9
  227. package/dist/capabilities/stepfun-step-plan.json +16 -9
  228. package/dist/capabilities/stepfun.json +16 -9
  229. package/dist/capabilities/stepping-stone.json +18 -18
  230. package/dist/capabilities/subconscious.json +2 -2
  231. package/dist/capabilities/synthetic.json +12 -12
  232. package/dist/capabilities/synthorai.json +26 -26
  233. package/dist/capabilities/teamorouter.json +21 -21
  234. package/dist/capabilities/teapot-router.json +9 -9
  235. package/dist/capabilities/tencent-coding-plan.json +1 -23
  236. package/dist/capabilities/tencent-token-plan.json +57 -20
  237. package/dist/capabilities/tencent-tokenhub.json +182 -7
  238. package/dist/capabilities/tensorx.json +36 -36
  239. package/dist/capabilities/the-grid-ai.json +29 -29
  240. package/dist/capabilities/thinkingmachines.json +73 -56
  241. package/dist/capabilities/tinfoil.json +9 -9
  242. package/dist/capabilities/toapis.json +3 -3
  243. package/dist/capabilities/togetherai.json +61 -90
  244. package/dist/capabilities/tokengo.json +21 -21
  245. package/dist/capabilities/tokenify.json +9 -9
  246. package/dist/capabilities/trustedrouter.json +7 -7
  247. package/dist/capabilities/trustedtokens.json +14 -14
  248. package/dist/capabilities/umans-ai-coding-plan.json +13 -13
  249. package/dist/capabilities/umans-ai.json +10 -10
  250. package/dist/capabilities/uncensuredai.json +4 -4
  251. package/dist/capabilities/unrestricted.json +4 -4
  252. package/dist/capabilities/uplinkswitch.json +19 -19
  253. package/dist/capabilities/upstage.json +6 -6
  254. package/dist/capabilities/vancine.json +19 -19
  255. package/dist/capabilities/vercel.json +558 -537
  256. package/dist/capabilities/vivgrid.json +78 -78
  257. package/dist/capabilities/volcengine-coding-plan.json +26 -56
  258. package/dist/capabilities/volcengine.json +57 -62
  259. package/dist/capabilities/vultr.json +28 -28
  260. package/dist/capabilities/wafer.ai.json +18 -18
  261. package/dist/capabilities/wallaby.json +5 -5
  262. package/dist/capabilities/wally.json +14 -14
  263. package/dist/capabilities/wandb.json +20 -20
  264. package/dist/capabilities/watt.json +22 -22
  265. package/dist/capabilities/xai.json +4 -4
  266. package/dist/capabilities/xiaomi-token-plan-ams.json +2 -12
  267. package/dist/capabilities/xiaomi-token-plan-cn.json +2 -12
  268. package/dist/capabilities/xiaomi-token-plan-sgp.json +2 -12
  269. package/dist/capabilities/xiaomi.json +3 -25
  270. package/dist/capabilities/xpersona.json +11 -11
  271. package/dist/capabilities/xxapi.json +27 -27
  272. package/dist/capabilities/zai-coding-plan.json +14 -14
  273. package/dist/capabilities/zai.json +47 -24
  274. package/dist/capabilities/zenifra.json +24 -24
  275. package/dist/capabilities/zenmux.json +185 -185
  276. package/dist/capabilities/zerogpu.json +12 -12
  277. package/dist/capabilities/zhipuai-coding-plan.json +8 -8
  278. package/dist/capabilities/zhipuai.json +35 -20
  279. package/dist/capabilities/zro.json +7 -7
  280. package/dist/channels/index.cjs +2 -2
  281. package/dist/channels/index.js +2 -2
  282. package/dist/{channels-BRVCOutx.js → channels-Cz1y3W6u.js} +1 -1
  283. package/dist/{channels-MjTA9bFp.cjs → channels-DQg4v_gm.cjs} +1 -1
  284. package/dist/coding-agent/index.cjs +2 -2
  285. package/dist/coding-agent/index.js +2 -2
  286. package/dist/datasets/index.cjs +2 -2
  287. package/dist/datasets/index.js +2 -2
  288. package/dist/docs/SKILL.md +3 -2
  289. package/dist/docs/assets/SOURCE_MAP.json +895 -870
  290. package/dist/docs/references/docs-harness-background-tasks.md +4 -1
  291. package/dist/docs/references/docs-knowledge-importers.md +195 -0
  292. package/dist/docs/references/docs-knowledge-load-your-content.md +1 -1
  293. package/dist/docs/references/docs-knowledge-overview.md +1 -1
  294. package/dist/docs/references/docs-sandbox-filesystem.md +1 -1
  295. package/dist/docs/references/docs-signals-thread-streams.md +1 -1
  296. package/dist/docs/references/docs-studio-auth.md +54 -7
  297. package/dist/docs/references/integrations-auth-clerk.md +48 -4
  298. package/dist/docs/references/reference-agents-agent.md +1 -1
  299. package/dist/docs/references/reference-agents-durable-agent.md +10 -4
  300. package/dist/docs/references/reference-auth-clerk.md +21 -1
  301. package/dist/docs/references/reference-knowledge-knowledge-class.md +11 -4
  302. package/dist/docs/references/reference-memory-observational-memory.md +2 -2
  303. package/dist/docs/references/reference-streaming-ChunkType.md +2 -2
  304. package/dist/docs/references/reference-workspace-local-sandbox.md +2 -0
  305. package/dist/error/index.cjs +1 -1
  306. package/dist/error/index.js +1 -1
  307. package/dist/{error-C9d_24w-.js → error-BLwEXqOK.js} +2 -2
  308. package/dist/{error-BRQf2ku0.cjs → error-BdEvO8za.cjs} +2 -2
  309. package/dist/evals/index.cjs +1 -1
  310. package/dist/evals/index.js +1 -1
  311. package/dist/evals/scoreTraces/index.cjs +1 -1
  312. package/dist/evals/scoreTraces/index.js +1 -1
  313. package/dist/features/index.cjs +1 -0
  314. package/dist/features/index.js +1 -0
  315. package/dist/{filesystem-B5X-5G0x.js → filesystem-B8ad6kAW.js} +1 -1
  316. package/dist/{filesystem-BDSpwBke.cjs → filesystem-BB5YWXH-.cjs} +1 -1
  317. package/dist/{filesystem-DzM9pcQ8.js → filesystem-BDHUxbHn.js} +1 -1
  318. package/dist/{filesystem-B0AZrbj8.cjs → filesystem-BP5yz5LG.cjs} +1 -1
  319. package/dist/{filesystem-BsdkC311.js → filesystem-B_afSgYk.js} +1 -1
  320. package/dist/{filesystem-C-cyJfi1.cjs → filesystem-BaOJOc-V.cjs} +1 -1
  321. package/dist/{filesystem-B3s0WRud.js → filesystem-BhYgU8qg.js} +1 -1
  322. package/dist/{filesystem-DzfqVTO_.js → filesystem-CLBVmR5j.js} +1 -1
  323. package/dist/{filesystem-CEbD_77-.cjs → filesystem-Cgxc2a_-.cjs} +1 -1
  324. package/dist/{filesystem-Cv79mHRk.js → filesystem-ClBOBoDc.js} +1 -1
  325. package/dist/{filesystem-DsCQiBl2.cjs → filesystem-DVVecqZt.cjs} +1 -1
  326. package/dist/{filesystem-CUAgLugE.cjs → filesystem-Fpsu7e24.cjs} +1 -1
  327. package/dist/{filesystem-versioned-Bijb_p9l.js → filesystem-versioned-BL1ojJLo.js} +1 -1
  328. package/dist/{filesystem-versioned-DZGyPbNC.cjs → filesystem-versioned-BavRtYWJ.cjs} +1 -1
  329. package/dist/harness/index.cjs +1 -1
  330. package/dist/harness/index.js +1 -1
  331. package/dist/index.cjs +1 -1
  332. package/dist/index.js +1 -1
  333. package/dist/knowledge/config.d.ts +10 -0
  334. package/dist/knowledge/host-writes.d.ts +10 -0
  335. package/dist/knowledge/importers/conformance.d.ts +25 -0
  336. package/dist/knowledge/importers/define.d.ts +204 -0
  337. package/dist/knowledge/importers/host.d.ts +143 -0
  338. package/dist/knowledge/importers/index.d.ts +12 -0
  339. package/dist/knowledge/importers/local-host.d.ts +106 -0
  340. package/dist/knowledge/importers/manifest.d.ts +25 -0
  341. package/dist/knowledge/importers/runner.d.ts +61 -0
  342. package/dist/knowledge/importers/sink.d.ts +105 -0
  343. package/dist/knowledge/importers/types.d.ts +144 -0
  344. package/dist/knowledge/index.cjs +2715 -8
  345. package/dist/knowledge/index.d.ts +54 -4
  346. package/dist/knowledge/index.js +2692 -9
  347. package/dist/knowledge/instructions.d.ts +1 -1
  348. package/dist/knowledge/links.d.ts +8 -0
  349. package/dist/knowledge/pinned-state-processor.d.ts +5 -0
  350. package/dist/knowledge/pinned.d.ts +4 -1
  351. package/dist/knowledge/scope-runtime.d.ts +10 -0
  352. package/dist/llm/index.cjs +3 -3
  353. package/dist/llm/index.js +3 -3
  354. package/dist/llm/model/provider-types.generated.d.ts +7705 -7727
  355. package/dist/{llm-DmUucguC.cjs → llm-8Av3mSjD.cjs} +2 -2
  356. package/dist/{llm-Djd8Qzi0.js → llm-B5A5cwJr.js} +2 -2
  357. package/dist/loop/index.cjs +2 -2
  358. package/dist/loop/index.js +2 -2
  359. package/dist/{manager-CO_Xz2zR.js → manager-DfWQCJUK.js} +2 -2
  360. package/dist/{manager-D27PkIPo.cjs → manager-sv35JY-z.cjs} +2 -2
  361. package/dist/mastra/index.cjs +1 -1
  362. package/dist/mastra/index.js +1 -1
  363. package/dist/mastra/resolve-agent.d.ts +3 -1
  364. package/dist/{mastra-Ch00nEAJ.js → mastra-CigBrT7X.js} +17 -23
  365. package/dist/{mastra-qsVWpOTi.cjs → mastra-D4hvfuxX.cjs} +19 -25
  366. package/dist/memory/index.cjs +3 -3
  367. package/dist/memory/index.js +3 -3
  368. package/dist/{message-list-DPXPXvin.cjs → message-list-Cj0Sq_JP.cjs} +63 -8
  369. package/dist/{message-list-DEuRl82K.js → message-list-KRbg-TnI.js} +63 -8
  370. package/dist/{model-Do6DTJoj.cjs → model-BK93CMtl.cjs} +1 -1
  371. package/dist/{model-CW-mfGYA.js → model-CYtXw861.js} +1 -1
  372. package/dist/{netlify-DU32SDT6.cjs → netlify-BAnn3ouY.cjs} +1 -1
  373. package/dist/{netlify-DZSAbdve.js → netlify-CuI1ZrwR.js} +1 -1
  374. package/dist/notifications/index.cjs +1 -1
  375. package/dist/notifications/index.js +1 -1
  376. package/dist/processor-provider/index.cjs +1 -1
  377. package/dist/processor-provider/index.js +1 -1
  378. package/dist/processors/abort-signal-scope.d.ts +6 -0
  379. package/dist/processors/index.cjs +2 -2
  380. package/dist/processors/index.js +2 -2
  381. package/dist/{provider-registry-zGezZVsL.cjs → provider-registry-BwuI_IpT.cjs} +21696 -21828
  382. package/dist/{provider-registry-deA0x-Gd.js → provider-registry-CmQLzLF_.js} +21696 -21828
  383. package/dist/provider-registry.json +22300 -22417
  384. package/dist/{registry-generator-VvBfOKAD.js → registry-generator-C17V4WfG.js} +1 -1
  385. package/dist/{registry-generator-BkQ1AxZn.cjs → registry-generator-C_0ae7Ce.cjs} +1 -1
  386. package/dist/{rehydrate-DDYFpQsV.cjs → rehydrate-CDQ4dOYj.cjs} +2 -2
  387. package/dist/{rehydrate-BjLV643n.js → rehydrate-PnaVawGX.js} +2 -2
  388. package/dist/relevance/index.cjs +2 -2
  389. package/dist/relevance/index.js +2 -2
  390. package/dist/{run-registry-5Suldxz3.cjs → run-registry-BmckDVBk.cjs} +1156 -403
  391. package/dist/{run-registry-CGRPldLH.js → run-registry-BwEcwYlU.js} +1103 -404
  392. package/dist/{source-DDwx-87N.cjs → source-BVOi8Xhp.cjs} +1 -1
  393. package/dist/{source-Did_2XQc.js → source-fNa6u1kH.js} +1 -1
  394. package/dist/storage/domains/agents/index.cjs +1 -1
  395. package/dist/storage/domains/agents/index.js +1 -1
  396. package/dist/storage/domains/knowledge/base.d.ts +67 -0
  397. package/dist/storage/domains/knowledge/importers-inmemory.d.ts +146 -0
  398. package/dist/storage/domains/knowledge/importers.d.ts +287 -0
  399. package/dist/storage/domains/knowledge/index.d.ts +1 -0
  400. package/dist/storage/domains/knowledge/inmemory.d.ts +11 -0
  401. package/dist/storage/domains/knowledge/pages-inmemory.d.ts +12 -1
  402. package/dist/storage/domains/knowledge/pages.d.ts +1 -0
  403. package/dist/storage/domains/mcp-clients/index.cjs +1 -1
  404. package/dist/storage/domains/mcp-clients/index.js +1 -1
  405. package/dist/storage/domains/mcp-servers/index.cjs +1 -1
  406. package/dist/storage/domains/mcp-servers/index.js +1 -1
  407. package/dist/storage/domains/prompt-blocks/index.cjs +1 -1
  408. package/dist/storage/domains/prompt-blocks/index.js +1 -1
  409. package/dist/storage/domains/scorer-definitions/index.cjs +1 -1
  410. package/dist/storage/domains/scorer-definitions/index.js +1 -1
  411. package/dist/storage/domains/skills/index.cjs +1 -1
  412. package/dist/storage/domains/skills/index.js +1 -1
  413. package/dist/storage/domains/workspaces/index.cjs +1 -1
  414. package/dist/storage/domains/workspaces/index.js +1 -1
  415. package/dist/storage/index.cjs +15 -10
  416. package/dist/storage/index.js +11 -11
  417. package/dist/stream/base/output.d.ts +17 -0
  418. package/dist/stream/index.cjs +2 -2
  419. package/dist/stream/index.js +2 -2
  420. package/dist/stream/types.d.ts +5 -2
  421. package/dist/{stream-Dvy_0o14.cjs → stream-0kdqBOOn.cjs} +64 -9
  422. package/dist/{stream-Dpwx0whf.js → stream-D1y9GzoD.js} +29 -10
  423. package/dist/test-utils/llm-mock.cjs +1 -1
  424. package/dist/test-utils/llm-mock.js +1 -1
  425. package/dist/tool-loop-agent/index.cjs +1 -1
  426. package/dist/tool-loop-agent/index.js +1 -1
  427. package/dist/{tool-loop-agent-PbWrEj1k.js → tool-loop-agent-BdjWGVIb.js} +4 -4
  428. package/dist/{tool-loop-agent-UxOv3FoK.cjs → tool-loop-agent-kWaZAT6Q.cjs} +4 -4
  429. package/dist/{utils-BbMTlyBO.cjs → utils-BKUCaZ12.cjs} +1 -1
  430. package/dist/{utils-BnNi1BYM.js → utils-GHY3hmLx.js} +1 -1
  431. package/dist/utils.cjs +1 -1
  432. package/dist/utils.js +1 -1
  433. package/dist/{validate-HSBcm96b.js → validate-CB-q-R2F.js} +1 -1
  434. package/dist/{validate-Skps-cM3.cjs → validate-De92squ7.cjs} +1 -1
  435. package/dist/vector/index.cjs +2 -2
  436. package/dist/vector/index.js +2 -2
  437. package/dist/worker/index.cjs +1 -1
  438. package/dist/worker/index.js +1 -1
  439. package/dist/{worker-BNS5A3qP.cjs → worker-BbWPQuPR.cjs} +2 -2
  440. package/dist/{worker-DehaD4qD.js → worker-C3u_xzY2.js} +2 -2
  441. package/dist/{worker-BE-0DyKL.cjs → worker-CAKvQj9_.cjs} +2 -2
  442. package/dist/{worker-BKrKHZzU.js → worker-Kwm8EKcj.js} +2 -2
  443. package/dist/{workflow-BjUTwaK9.cjs → workflow-CSjXeNcR.cjs} +3 -3
  444. package/dist/{workflow-Bvw6yDjc.js → workflow-CVmI1Sw-.js} +3 -3
  445. package/dist/workflows/builder/index.cjs +1 -1
  446. package/dist/workflows/builder/index.js +1 -1
  447. package/dist/workflows/evented/index.cjs +1 -1
  448. package/dist/workflows/evented/index.js +1 -1
  449. package/dist/workflows/index.cjs +4 -4
  450. package/dist/workflows/index.js +4 -4
  451. package/dist/workspace/filesystem/filesystem.d.ts +5 -0
  452. package/dist/workspace/index.cjs +1 -1
  453. package/dist/workspace/index.js +1 -1
  454. package/dist/workspace/sandbox/local-sandbox.d.ts +16 -7
  455. package/dist/workspace/sandbox/native-sandbox/types.d.ts +11 -1
  456. package/dist/{workspace-C05xDH60.js → workspace-DY2Nxiyi.js} +75 -27
  457. package/dist/{workspace-D1OzzlLw.cjs → workspace-X2RHJZU9.cjs} +75 -27
  458. package/package.json +3 -3
  459. package/src/llm/model/provider-types.generated.d.ts +7705 -7727
@@ -1,6 +1,6 @@
1
1
  import { n as __exportAll } from "./rolldown-runtime-tIEjjQTE.js";
2
- import { d as attachModelStreamTransport, f as isDataChunk, i as resolveModelConfig, p as readModelStreamTransport } from "./llm-Djd8Qzi0.js";
3
- import { B as getResponseProviderItemIdFromPart, G as RESPONSE_ITEM_ID_PROVIDERS, K as RESPONSE_RESULT_ITEM_ID_KEY, f as coreContentToString, n as MessageList, p as messagesAreEqual, t as convertMessages } from "./message-list-DEuRl82K.js";
2
+ import { d as attachModelStreamTransport, f as isDataChunk, i as resolveModelConfig, p as readModelStreamTransport } from "./llm-B5A5cwJr.js";
3
+ import { B as getResponseProviderItemIdFromPart, G as RESPONSE_ITEM_ID_PROVIDERS, K as RESPONSE_RESULT_ITEM_ID_KEY, f as coreContentToString, n as MessageList, p as messagesAreEqual, t as convertMessages } from "./message-list-KRbg-TnI.js";
4
4
  import { S as resolveObservabilityContext, x as createObservabilityContext } from "./observability-D7RNOAPx.js";
5
5
  import { t as MastraBase } from "./base-CKLWBhDo.js";
6
6
  import { i as MastraError, n as ErrorDomain, o as getErrorFromUnknown, t as ErrorCategory } from "./error-oh2DLsP2.js";
@@ -2762,6 +2762,12 @@ function residentStepResults(steps) {
2762
2762
  async function loadStepResults(steps) {
2763
2763
  return typeof steps === "function" ? steps() : steps;
2764
2764
  }
2765
+ // src/processors/abort-signal-scope.ts
2766
+ /**
2767
+ * The caller's abort signal for a processor workflow run. Held in the run scope
2768
+ * rather than the step payload: a serializing pubsub would encode the signal as `{}`.
2769
+ */
2770
+ const PROCESSOR_ABORT_SIGNAL = createRunScopeKey("processor-abort-signal");
2765
2771
  // src/processors/send-signal.ts
2766
2772
  const PROCESSOR_LATE_SIGNAL_SINK = createRunScopeKey("processor-late-signal-sink");
2767
2773
  function createProcessorSendSignal(args) {
@@ -4439,8 +4445,9 @@ var ProcessorRunner = class ProcessorRunner {
4439
4445
  shouldPersistSnapshot: () => false,
4440
4446
  tracingPolicy: { internal: 1 }
4441
4447
  } : void 0);
4442
- const scope = this.lateSignalSink ? workflow.mastra?.__createRunScope(run.runId) : void 0;
4448
+ const scope = this.lateSignalSink || abortSignal ? workflow.mastra?.__createRunScope(run.runId) : void 0;
4443
4449
  if (this.lateSignalSink) scope?.set(PROCESSOR_LATE_SIGNAL_SINK, this.lateSignalSink);
4450
+ if (abortSignal) scope?.set(PROCESSOR_ABORT_SIGNAL, abortSignal);
4444
4451
  const result = await (async () => {
4445
4452
  try {
4446
4453
  return await run.start({
@@ -6967,6 +6974,7 @@ function partMatches(a, b) {
6967
6974
  if (a.type === "step-start") return Number(a.createdAt) === Number(b.createdAt);
6968
6975
  return true;
6969
6976
  }
6977
+ /** @internal */
6970
6978
  function findIterationOffsetInParts(parts, stepText) {
6971
6979
  if (!stepText) return void 0;
6972
6980
  let suffixText = "";
@@ -6991,12 +6999,14 @@ function findIterationPartOffset(messageList, message, stepText) {
6991
6999
  if (!stepText.endsWith(suffixText)) return void 0;
6992
7000
  }
6993
7001
  }
7002
+ /** @internal */
6994
7003
  function resolveMessageText(message) {
6995
7004
  const converted = convertMessages([message]).to("AIV4.Core");
6996
7005
  const convertedMessage = converted[converted.length - 1];
6997
7006
  return convertedMessage ? coreContentToString(convertedMessage.content) : "";
6998
7007
  }
6999
7008
  const stepPartIndex = Symbol("stepPartIndex");
7009
+ /** @internal */
7000
7010
  function findStepPartBoundaries(message, steps) {
7001
7011
  const parts = message?.content.parts;
7002
7012
  if (!parts) return void 0;
@@ -7016,9 +7026,11 @@ function findStepPartBoundaries(message, steps) {
7016
7026
  for (const [stepIndex] of steps.entries()) for (const part of parts.slice(offsets[stepIndex], offsets[stepIndex + 1])) if (part.type === "text") part[stepPartIndex] = stepIndex;
7017
7027
  return { offsets };
7018
7028
  }
7029
+ /** @internal */
7019
7030
  function clearStepPartIndexes(messages) {
7020
7031
  for (const message of messages) for (const part of message.content.parts) delete part[stepPartIndex];
7021
7032
  }
7033
+ /** @internal */
7022
7034
  function reconcileBufferedStepTexts(steps, processedText, processedMessage, stepPartBoundaries, originalText) {
7023
7035
  if (processedText === originalText) return;
7024
7036
  const processedParts = processedMessage?.content.parts;
@@ -7793,7 +7805,10 @@ var MastraModelOutput = class extends MastraBase {
7793
7805
  messages: messageList.get.response.aiV5.model(),
7794
7806
  uiMessages: messageList.get.response.aiV5.ui()
7795
7807
  };
7796
- } else if (self.#bufferedSteps.length > 0) response = { ...self.#bufferedSteps[self.#bufferedSteps.length - 1].response };
7808
+ } else if (self.#bufferedSteps.length > 0) {
7809
+ response = { ...self.#bufferedSteps[self.#bufferedSteps.length - 1].response };
7810
+ if (chunk.payload.messages?.nonUser) response.messages = chunk.payload.messages.nonUser;
7811
+ }
7797
7812
  if (self.#finishUsageIsTotal) {
7798
7813
  self.#usageCount.inputTokens = void 0;
7799
7814
  self.#usageCount.outputTokens = void 0;
@@ -7901,11 +7916,15 @@ var MastraModelOutput = class extends MastraBase {
7901
7916
  } else if (!self.#options.isLLMExecutionStep || self.#options.resolveFinalPromises) {
7902
7917
  let rewrittenText;
7903
7918
  if (chunk.payload.textRewritten === true && self.#status !== "canceled") {
7904
- const finalizedText = chunk.payload.output?.steps?.at(-1)?.text;
7905
- const lastStep = self.#bufferedSteps.at(-1);
7906
- if (lastStep && typeof finalizedText === "string") {
7907
- lastStep.text = finalizedText;
7908
- rewrittenText = finalizedText;
7919
+ const finalizedSteps = chunk.payload.output?.steps;
7920
+ if (finalizedSteps && self.#bufferedSteps.length && finalizedSteps.length >= self.#bufferedSteps.length) {
7921
+ const offset = finalizedSteps.length - self.#bufferedSteps.length;
7922
+ for (const [index, step] of self.#bufferedSteps.entries()) {
7923
+ const text = finalizedSteps[offset + index]?.text;
7924
+ if (typeof text === "string") step.text = text;
7925
+ }
7926
+ const output = chunk.payload.output;
7927
+ rewrittenText = "text" in output && typeof output.text === "string" ? output.text : finalizedSteps.at(-1)?.text;
7909
7928
  }
7910
7929
  }
7911
7930
  this.resolvePromises({
@@ -10258,4 +10277,4 @@ function smoothStream({ delayInMs = 10, chunking = "word" } = {}) {
10258
10277
  }
10259
10278
  });
10260
10279
  }
10261
- export { RunJournal as $, withAgentWorkflowToolMarker as $t, findOwnModelStepSpan as A, materializeWorkflowRun as At, REPROCESS_PART_KEY as B, TITLE_PINNED_THREAD_METADATA_KEY as Bt, getResponseFormat as C, safeEnqueue as Cn, getSnapshotMemoryInfo as Ct, ProcessorState as D, isStateCheckpointDue as Dt, ProcessorRunner as E, createRunScopeKey as En, applyStateColumnsWrite as Et, ProviderHistoryCompat as F, unusedStateEntries as Ft, summarizeProcessorResultForSpan as G, setThreadOMMetadata as Gt, withoutHeldContent as H, isObservationalMemoryEnabled as Ht, anthropicToolIdFormat as I, applyStatePatch as It, resolveProcessorSpanAttributes as J, hasToolResultProcessor as Jt, summarizeProcessorToolsForSpan as K, commitToolResult as Kt, cerebrasStripReasoningContent as L, diffState as Lt, isTrailingAssistantGuardContinuation as M, stateBaseOf as Mt, needsTrailingAssistantGuard as N, stateColumnsWrite as Nt, endOutputStreamSpanAtStepEnd as O, latestStepResults as Ot, removeTrailingAssistantGuardContinuations as P, summarizeStepResult as Pt, createProcessorSendSignal as Q, snapshotToolResult as Qt, openaiOrphanItemId as R, diffStateAsJson as Rt, asJsonSchema as S, safeClose as Sn, getStepResultAsync as St, OUTPUT_STREAM_HOOK_DURATION_KEY_PREFIX as T, createRunScope as Tn, STEP_RESULT_SUMMARY_FIELDS as Tt, summarizeActiveToolsForSpan as U, isThreadTitlePinned as Ut, takeHeldParts as V, getThreadOMMetadata as Vt, summarizeProcessorModelForSpan as W, parseMemoryRequestContext as Wt, toProcessorSpanPhase as X, readModelOutput as Xt, resolveProcessorSpanName as Y, latestProcessedModelOutput as Yt, PROCESSOR_LATE_SIGNAL_SINK as Z, resolveModelOutputAfterToolResultProcessors as Zt, stampChunkProducedAt as _, isMastraTimeoutError as _n, resolveTemplate as _t, convertFullStreamChunkToMastra as a, resolveThreadIdFromArgs as an, loadStepResults as at, escapeUnescapedControlCharsInJsonStrings as b, convertFullStreamChunkToUIMessageStream as bn, validateTemplate as bt, WorkflowRunOutput as c, tryStreamWithJsonFallback as cn, residentStepResultsLoader as ct, MastraModelOutput as d, DEADLINE_SAVE_WAIT_MS as dn, collectMappingStepRefs as dt, normalizeModelOutput as en, buildStepResultAccessors as et, createDestructurableOutput as f, MastraTimeoutError as fn, collectPredicateStepRefs as ft, getChunkProducedAt as g, guardStreamWithAbort as gn, collectTemplateStepIds as gt, resolveProcessorWriterMessageId as h, guardStreamUntilMatch as hn, stepRefId as ht, withStreamCaching as i, resolveSuspendedToolRunId as in, lazyStepResults as it, runner_exports as j, pickStateKeys as jt, endOutputStreamSpanOutsideStep as k, materializeState as kt, TripWire as l, applyStateSignal as ln, storageV2StepResultAccessors as lt, resolveOutputMessageSkippingCompletionChecks as m, getAbortReason as mn, resolveStepOutputs as mt, createCachingTransformStream as n, isProcessorWorkflow as nn, hydrateStepResults as nt, convertMastraChunkToAISDKv5 as o, supportedLanguageModelSpecifications as on, loadedStepResults as ot, persistProcessorDataChunk as p, createTimeoutAbortSignal as pn, predicateReadsState as pt, summarizeToolChoiceForSpan as q, computeModelOutputProviderMetadata as qt, createReplayStream as r, isSupportedLanguageModel as rn, isStepResultStub as rt, MastraAgentNetworkStream as s, tryGenerateWithJsonFallback as sn, residentStepResults as st, smoothStream as t, validationErrorModelOutput as tn, getHydratedStepResult as tt, getModelOutputForTripwire as u, DEADLINE_SAVE_CLAIM_HOLD_MS as un, stubStepResult as ut, markChunkOutputProcessed as v, raceAgainstAbort as vn, templateReadsState as vt, isSignalChunkExcluded as w, safeError as wn, STATE_CHECKPOINT_PATCHES as wt, isStructuredOutputError as x, MastraModelInput as xn, getStepResult as xt, createOutputHandler as y, settledOrElapsed as yn, traverseMappingPath as yt, FLUSH_HELD_PARTS_KEY as z, patchState as zt };
10280
+ export { resolveProcessorSpanAttributes as $, computeModelOutputProviderMetadata as $t, OUTPUT_STREAM_HOOK_DURATION_KEY_PREFIX as A, safeError as An, STATE_CHECKPOINT_PATCHES as At, ProviderHistoryCompat as B, summarizeStepResult as Bt, markChunkOutputProcessed as C, isMastraTimeoutError as Cn, resolveTemplate as Ct, asJsonSchema as D, MastraModelInput as Dn, getStepResult as Dt, isStructuredOutputError as E, convertFullStreamChunkToUIMessageStream as En, validateTemplate as Et, findOwnModelStepSpan as F, materializeState as Ft, REPROCESS_PART_KEY as G, patchState as Gt, cerebrasStripReasoningContent as H, applyStatePatch as Ht, runner_exports as I, materializeWorkflowRun as It, summarizeActiveToolsForSpan as J, isObservationalMemoryEnabled as Jt, takeHeldParts as K, TITLE_PINNED_THREAD_METADATA_KEY as Kt, isTrailingAssistantGuardContinuation as L, pickStateKeys as Lt, ProcessorState as M, createRunScopeKey as Mn, applyStateColumnsWrite as Mt, endOutputStreamSpanAtStepEnd as N, isStateCheckpointDue as Nt, getResponseFormat as O, safeClose as On, getStepResultAsync as Ot, endOutputStreamSpanOutsideStep as P, latestStepResults as Pt, summarizeToolChoiceForSpan as Q, commitToolResult as Qt, needsTrailingAssistantGuard as R, stateBaseOf as Rt, stampChunkProducedAt as S, guardStreamWithAbort as Sn, collectTemplateStepIds as St, escapeUnescapedControlCharsInJsonStrings as T, settledOrElapsed as Tn, traverseMappingPath as Tt, openaiOrphanItemId as U, diffState as Ut, anthropicToolIdFormat as V, unusedStateEntries as Vt, FLUSH_HELD_PARTS_KEY as W, diffStateAsJson as Wt, summarizeProcessorResultForSpan as X, parseMemoryRequestContext as Xt, summarizeProcessorModelForSpan as Y, isThreadTitlePinned as Yt, summarizeProcessorToolsForSpan as Z, setThreadOMMetadata as Zt, reconcileBufferedStepTexts as _, DEADLINE_SAVE_WAIT_MS as _n, collectMappingStepRefs as _t, convertFullStreamChunkToMastra as a, withAgentWorkflowToolMarker as an, RunJournal as at, resolveProcessorWriterMessageId as b, getAbortReason as bn, resolveStepOutputs as bt, WorkflowRunOutput as c, isProcessorWorkflow as cn, hydrateStepResults as ct, MastraModelOutput as d, resolveThreadIdFromArgs as dn, loadStepResults as dt, hasToolResultProcessor as en, resolveProcessorSpanName as et, clearStepPartIndexes as f, supportedLanguageModelSpecifications as fn, loadedStepResults as ft, persistProcessorDataChunk as g, DEADLINE_SAVE_CLAIM_HOLD_MS as gn, stubStepResult as gt, findStepPartBoundaries as h, applyStateSignal as hn, storageV2StepResultAccessors as ht, withStreamCaching as i, snapshotToolResult as in, PROCESSOR_ABORT_SIGNAL as it, ProcessorRunner as j, createRunScope as jn, STEP_RESULT_SUMMARY_FIELDS as jt, isSignalChunkExcluded as k, safeEnqueue as kn, getSnapshotMemoryInfo as kt, TripWire as l, isSupportedLanguageModel as ln, isStepResultStub as lt, findIterationOffsetInParts as m, tryStreamWithJsonFallback as mn, residentStepResultsLoader as mt, createCachingTransformStream as n, readModelOutput as nn, PROCESSOR_LATE_SIGNAL_SINK as nt, convertMastraChunkToAISDKv5 as o, normalizeModelOutput as on, buildStepResultAccessors as ot, createDestructurableOutput as p, tryGenerateWithJsonFallback as pn, residentStepResults as pt, withoutHeldContent as q, getThreadOMMetadata as qt, createReplayStream as r, resolveModelOutputAfterToolResultProcessors as rn, createProcessorSendSignal as rt, MastraAgentNetworkStream as s, validationErrorModelOutput as sn, getHydratedStepResult as st, smoothStream as t, latestProcessedModelOutput as tn, toProcessorSpanPhase as tt, getModelOutputForTripwire as u, resolveSuspendedToolRunId as un, lazyStepResults as ut, resolveMessageText as v, MastraTimeoutError as vn, collectPredicateStepRefs as vt, createOutputHandler as w, raceAgainstAbort as wn, templateReadsState as wt, getChunkProducedAt as x, guardStreamUntilMatch as xn, stepRefId as xt, resolveOutputMessageSkippingCompletionChecks as y, createTimeoutAbortSignal as yn, predicateReadsState as yt, removeTrailingAssistantGuardContinuations as z, stateColumnsWrite as zt };
@@ -1,7 +1,7 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
2
  const require_rolldown_runtime = require("../rolldown-runtime-BrhgMLW6.cjs");
3
3
  const require_dist = require("../dist-CXeCeeW7.cjs");
4
- const require_model = require("../model-Do6DTJoj.cjs");
4
+ const require_model = require("../model-BK93CMtl.cjs");
5
5
  const require_model$1 = require("../model-jBymoqGa.cjs");
6
6
  let stream = require("stream");
7
7
  let module$1 = require("module");
@@ -1,5 +1,5 @@
1
1
  import { o as simulateReadableStream } from "../dist-D3cKCUe-.js";
2
- import { t as MastraLLMV1 } from "../model-CW-mfGYA.js";
2
+ import { t as MastraLLMV1 } from "../model-CYtXw861.js";
3
3
  import { t as AISDKV5LanguageModel } from "../model-DS-b2R-R.js";
4
4
  import { createRequire } from "module";
5
5
  import { Readable } from "stream";
@@ -1,5 +1,5 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
- const require_tool_loop_agent = require("../tool-loop-agent-UxOv3FoK.cjs");
2
+ const require_tool_loop_agent = require("../tool-loop-agent-kWaZAT6Q.cjs");
3
3
  exports.getSettings = require_tool_loop_agent.getSettings;
4
4
  exports.isToolLoopAgentLike = require_tool_loop_agent.isToolLoopAgentLike;
5
5
  exports.toolLoopAgentToMastraAgent = require_tool_loop_agent.toolLoopAgentToMastraAgent;
@@ -1 +1 @@
1
- export { n as getSettings, r as isToolLoopAgentLike, t as toolLoopAgentToMastraAgent } from "../tool-loop-agent-PbWrEj1k.js";
1
+ export { n as getSettings, r as isToolLoopAgentLike, t as toolLoopAgentToMastraAgent } from "../tool-loop-agent-BdjWGVIb.js";
@@ -1,8 +1,8 @@
1
1
  import { m as generateId } from "./dist-TPVqg8oV.js";
2
- import { P as Agent } from "./run-registry-CGRPldLH.js";
3
- import { rn as isSupportedLanguageModel } from "./stream-Dpwx0whf.js";
4
- import { i as resolveModelConfig } from "./llm-Djd8Qzi0.js";
5
- import { N as ToolLoopAgent } from "./message-list-DEuRl82K.js";
2
+ import { N as Agent } from "./run-registry-BwEcwYlU.js";
3
+ import { ln as isSupportedLanguageModel } from "./stream-D1y9GzoD.js";
4
+ import { i as resolveModelConfig } from "./llm-B5A5cwJr.js";
5
+ import { N as ToolLoopAgent } from "./message-list-KRbg-TnI.js";
6
6
  // src/tool-loop-agent/utils.ts
7
7
  function isToolLoopAgentLike(obj) {
8
8
  if (!obj) return false;
@@ -1,8 +1,8 @@
1
1
  const require_dist = require("./dist-P2rjrlmj.cjs");
2
- const require_run_registry = require("./run-registry-5Suldxz3.cjs");
3
- const require_stream = require("./stream-Dvy_0o14.cjs");
4
- const require_llm = require("./llm-DmUucguC.cjs");
5
- const require_message_list = require("./message-list-DPXPXvin.cjs");
2
+ const require_run_registry = require("./run-registry-BmckDVBk.cjs");
3
+ const require_stream = require("./stream-0kdqBOOn.cjs");
4
+ const require_llm = require("./llm-8Av3mSjD.cjs");
5
+ const require_message_list = require("./message-list-Cj0Sq_JP.cjs");
6
6
  // src/tool-loop-agent/utils.ts
7
7
  function isToolLoopAgentLike(obj) {
8
8
  if (!obj) return false;
@@ -1,7 +1,7 @@
1
1
  const require_error = require("./error-D90lJ6M7.cjs");
2
2
  const require_tool = require("./tool-CYlT2UA-.cjs");
3
3
  const require_ee_iTj2bRDt = require("./ee-iTj2bRDt-D3-QLGDF.cjs");
4
- const require_background_tasks = require("./background-tasks-7iftnRK_.cjs");
4
+ const require_background_tasks = require("./background-tasks-BDrYBis-.cjs");
5
5
  const require_base = require("./base-BIzR1D3_.cjs");
6
6
  const require_observability = require("./observability-B0R_D1PZ.cjs");
7
7
  const require_utils = require("./utils-D-eNsgDM.cjs");
@@ -1,7 +1,7 @@
1
1
  import { i as MastraError, n as ErrorDomain, o as getErrorFromUnknown, t as ErrorCategory } from "./error-oh2DLsP2.js";
2
2
  import { c as registerToolOutputValidationSchema, d as validateToolOutput, f as validateToolSuspendData, h as markBuilderValidatedInput, i as createStandardSchemaIssuesError, n as Tool, o as getValidationIssuePaths, p as createToolObserve, s as isValidationError, u as validateToolInput } from "./tool-Z3bykc1m.js";
3
3
  import { i as MastraFGAPermissions } from "./ee-iTj2bRDt-By_B9ngH.js";
4
- import { i as isToolBackgroundEligible, n as backgroundOverrideJsonSchema, r as backgroundOverrideZodSchema } from "./background-tasks-Cv1ecD6S.js";
4
+ import { i as isToolBackgroundEligible, n as backgroundOverrideJsonSchema, r as backgroundOverrideZodSchema } from "./background-tasks-BnJfNLFo.js";
5
5
  import { t as MastraBase } from "./base-CKLWBhDo.js";
6
6
  import { O as executionFailureTermination, b as wrapMastra, x as createObservabilityContext } from "./observability-D7RNOAPx.js";
7
7
  import { a as getOrCreateSpan, t as executeWithContext } from "./utils-DU_pU5SK.js";
package/dist/utils.cjs CHANGED
@@ -4,7 +4,7 @@ const require_deep_equal = require("./deep-equal-TMDmByBC.cjs");
4
4
  const require_zod_utils = require("./zod-utils-Cl5jw5N_.cjs");
5
5
  const require_fetchWithRetry = require("./fetchWithRetry-f5k4p7_1.cjs");
6
6
  const require_dynamic_argument = require("./dynamic-argument-CUc1BBOS.cjs");
7
- const require_utils = require("./utils-BbMTlyBO.cjs");
7
+ const require_utils = require("./utils-BKUCaZ12.cjs");
8
8
  exports.boundedStringify = require_utils_safe_stringify.boundedStringify;
9
9
  exports.checkEvalStorageFields = require_utils.checkEvalStorageFields;
10
10
  exports.createMastraProxy = require_utils.createMastraProxy;
package/dist/utils.js CHANGED
@@ -3,5 +3,5 @@ import { t as deepEqual } from "./deep-equal-d1xU02ag.js";
3
3
  import { a as isZodObject, i as isZodArray, r as getZodTypeName, t as getZodDef } from "./zod-utils-BDDS_mxU.js";
4
4
  import { t as fetchWithRetry } from "./fetchWithRetry-DFSvpYDT.js";
5
5
  import { n as resolveDynamicArgument, t as getRequestUser } from "./dynamic-argument-BzPK3qPN.js";
6
- import { C as setNestedValue, S as selectFields, _ as parseSqlIdentifier, a as ensureToolProperties, b as removeUndefinedValues, c as isCoreMessage, d as makeCoreTool, f as makeCoreToolV5, g as parseFieldKey, h as omitKeys, i as delay, l as isUiMessage, m as maskStreamTags, n as createMastraProxy, o as generateEmptyFromSchema, p as makeProcessorCoreTool, r as deepMerge, s as getNestedValue, t as checkEvalStorageFields, u as isZodType, v as readPositiveIntEnv, x as resolveSerializedZodOutput, y as rebindProcessorTools } from "./utils-BnNi1BYM.js";
6
+ import { C as setNestedValue, S as selectFields, _ as parseSqlIdentifier, a as ensureToolProperties, b as removeUndefinedValues, c as isCoreMessage, d as makeCoreTool, f as makeCoreToolV5, g as parseFieldKey, h as omitKeys, i as delay, l as isUiMessage, m as maskStreamTags, n as createMastraProxy, o as generateEmptyFromSchema, p as makeProcessorCoreTool, r as deepMerge, s as getNestedValue, t as checkEvalStorageFields, u as isZodType, v as readPositiveIntEnv, x as resolveSerializedZodOutput, y as rebindProcessorTools } from "./utils-GHY3hmLx.js";
7
7
  export { boundedStringify, checkEvalStorageFields, createMastraProxy, deepEqual, deepMerge, delay, ensureSerializable, ensureToolProperties, fetchWithRetry, generateEmptyFromSchema, getNestedValue, getRequestUser, getZodDef, getZodTypeName, isBoundedSerializable, isCoreMessage, isUiMessage, isZodArray, isZodObject, isZodType, makeCoreTool, makeCoreToolV5, makeProcessorCoreTool, maskStreamTags, omitKeys, parseFieldKey, parseSqlIdentifier, readPositiveIntEnv, rebindProcessorTools, removeUndefinedValues, resolveDynamicArgument, resolveSerializedZodOutput, safeStringify, selectFields, setNestedValue };
@@ -1,5 +1,5 @@
1
1
  import { standardSchemaToJSONSchema, toStandardSchema } from "./schema/index.js";
2
- import { bt as validateTemplate, gt as collectTemplateStepIds } from "./stream-Dpwx0whf.js";
2
+ import { Et as validateTemplate, St as collectTemplateStepIds } from "./stream-D1y9GzoD.js";
3
3
  import { z } from "zod";
4
4
  // src/workflows/dynamic/graph.ts
5
5
  /**
@@ -1,4 +1,4 @@
1
- const require_stream = require("./stream-Dvy_0o14.cjs");
1
+ const require_stream = require("./stream-0kdqBOOn.cjs");
2
2
  let zod = require("zod");
3
3
  let _mastra_schema_compat_schema = require("@mastra/schema-compat/schema");
4
4
  // src/workflows/dynamic/graph.ts
@@ -1,8 +1,8 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
2
  const require_base = require("../base-BIzR1D3_.cjs");
3
3
  const require_error = require("../error-D90lJ6M7.cjs");
4
- const require_run_registry = require("../run-registry-5Suldxz3.cjs");
5
- const require_message_list = require("../message-list-DPXPXvin.cjs");
4
+ const require_run_registry = require("../run-registry-BmckDVBk.cjs");
5
+ const require_message_list = require("../message-list-Cj0Sq_JP.cjs");
6
6
  const require_dist = require("../dist-P2rjrlmj.cjs");
7
7
  const require_dist$1 = require("../dist-CXeCeeW7.cjs");
8
8
  const require_vector_filter_index = require("./filter/index.cjs");
@@ -1,7 +1,7 @@
1
1
  import { t as MastraBase } from "../base-CKLWBhDo.js";
2
2
  import { i as MastraError, n as ErrorDomain, t as ErrorCategory } from "../error-oh2DLsP2.js";
3
- import { ia as createVectorErrorId, un as embed$3 } from "../run-registry-CGRPldLH.js";
4
- import { P as embed$2 } from "../message-list-DEuRl82K.js";
3
+ import { fa as createVectorErrorId, un as embed$3 } from "../run-registry-BwEcwYlU.js";
4
+ import { P as embed$2 } from "../message-list-KRbg-TnI.js";
5
5
  import { r as embed$1 } from "../dist-TPVqg8oV.js";
6
6
  import { n as embed } from "../dist-D3cKCUe-.js";
7
7
  import { BaseFilterTranslator } from "./filter/index.js";
@@ -1,5 +1,5 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
- const require_worker = require("../worker-BE-0DyKL.cjs");
2
+ const require_worker = require("../worker-CAKvQj9_.cjs");
3
3
  exports.BackgroundTaskWorker = require_worker.BackgroundTaskWorker;
4
4
  exports.HttpRemoteStrategy = require_worker.HttpRemoteStrategy;
5
5
  exports.InProcessStrategy = require_worker.InProcessStrategy;
@@ -1 +1 @@
1
- export { n as BackgroundTaskWorker, o as HttpRemoteStrategy, t as InProcessStrategy, c as MastraWorker, i as OrchestrationWorker, a as PullTransport, r as SchedulerWorker, s as StepExecutionError } from "../worker-DehaD4qD.js";
1
+ export { n as BackgroundTaskWorker, o as HttpRemoteStrategy, t as InProcessStrategy, c as MastraWorker, i as OrchestrationWorker, a as PullTransport, r as SchedulerWorker, s as StepExecutionError } from "../worker-C3u_xzY2.js";
@@ -1,6 +1,6 @@
1
- const require_run_registry = require("./run-registry-5Suldxz3.cjs");
1
+ const require_run_registry = require("./run-registry-BmckDVBk.cjs");
2
2
  const require_request_context = require("./request-context-D9RXYCy8.cjs");
3
- const require_worker = require("./worker-BE-0DyKL.cjs");
3
+ const require_worker = require("./worker-CAKvQj9_.cjs");
4
4
  const require_schedules = require("./schedules-BZS8McF7.cjs");
5
5
  // src/schedules/worker.ts
6
6
  /** PubSub topic on which the scheduler publishes `agent-schedule.fire` events. */
@@ -1,6 +1,6 @@
1
- import { As as StepExecutor, cl as waitMs, ec as getNestedWorkflow, js as computeScheduleDefinitionHash, ks as WorkflowEventProcessor, sl as assertDrainTimeout, tc as getStepEntry, x as resolveAgentById } from "./run-registry-CGRPldLH.js";
1
+ import { Ls as WorkflowEventProcessor, Rs as StepExecutor, cc as getNestedWorkflow, gl as waitMs, hl as assertDrainTimeout, lc as getStepEntry, vt as resolveAgentById, zs as computeScheduleDefinitionHash } from "./run-registry-BwEcwYlU.js";
2
2
  import { t as Scheduler } from "./scheduler-B-VZUvv_.js";
3
- import { s as BackgroundTaskManager } from "./background-tasks-Cv1ecD6S.js";
3
+ import { s as BackgroundTaskManager } from "./background-tasks-BnJfNLFo.js";
4
4
  import { u as RequestContext } from "./request-context-COnZHt2-.js";
5
5
  // src/worker/worker.ts
6
6
  /**
@@ -1,6 +1,6 @@
1
- const require_run_registry = require("./run-registry-5Suldxz3.cjs");
1
+ const require_run_registry = require("./run-registry-BmckDVBk.cjs");
2
2
  const require_scheduler = require("./scheduler-D00X03jQ.cjs");
3
- const require_background_tasks = require("./background-tasks-7iftnRK_.cjs");
3
+ const require_background_tasks = require("./background-tasks-BDrYBis-.cjs");
4
4
  const require_request_context = require("./request-context-D9RXYCy8.cjs");
5
5
  // src/worker/worker.ts
6
6
  /**
@@ -1,6 +1,6 @@
1
- import { x as resolveAgentById } from "./run-registry-CGRPldLH.js";
1
+ import { vt as resolveAgentById } from "./run-registry-BwEcwYlU.js";
2
2
  import { u as RequestContext } from "./request-context-COnZHt2-.js";
3
- import { a as PullTransport, c as MastraWorker } from "./worker-DehaD4qD.js";
3
+ import { a as PullTransport, c as MastraWorker } from "./worker-C3u_xzY2.js";
4
4
  import { l as parseFsAgentScheduleRowId } from "./schedules-DZfSx-7P.js";
5
5
  // src/schedules/worker.ts
6
6
  /** PubSub topic on which the scheduler publishes `agent-schedule.fire` events. */
@@ -1,8 +1,8 @@
1
- const require_stream = require("./stream-Dvy_0o14.cjs");
1
+ const require_stream = require("./stream-0kdqBOOn.cjs");
2
2
  require("./utils-D-eNsgDM.cjs");
3
3
  const require_output_helpers = require("./output-helpers-1Zu4Vt9C.cjs");
4
- const require_run_registry = require("./run-registry-5Suldxz3.cjs");
5
- const require_background_tasks = require("./background-tasks-7iftnRK_.cjs");
4
+ const require_run_registry = require("./run-registry-BmckDVBk.cjs");
5
+ const require_background_tasks = require("./background-tasks-BDrYBis-.cjs");
6
6
  let zod = require("zod");
7
7
  // src/background-tasks/workflow.ts
8
8
  const inputSchema = zod.z.object({ taskId: zod.z.string() });
@@ -1,8 +1,8 @@
1
- import { in as resolveSuspendedToolRunId } from "./stream-Dpwx0whf.js";
1
+ import { un as resolveSuspendedToolRunId } from "./stream-D1y9GzoD.js";
2
2
  import "./utils-DU_pU5SK.js";
3
3
  import { p as slimProgressChunk } from "./output-helpers-CedRCE17.js";
4
- import { Ss as createWorkflow, ac as createStep } from "./run-registry-CGRPldLH.js";
5
- import { c as BACKGROUND_TASK_WORKFLOW_ID } from "./background-tasks-Cv1ecD6S.js";
4
+ import { As as createWorkflow, pc as createStep } from "./run-registry-BwEcwYlU.js";
5
+ import { c as BACKGROUND_TASK_WORKFLOW_ID } from "./background-tasks-BnJfNLFo.js";
6
6
  import { z } from "zod";
7
7
  // src/background-tasks/workflow.ts
8
8
  const inputSchema = z.object({ taskId: z.string() });
@@ -1,5 +1,5 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
- const require_builder = require("../../builder-DuJBbQDH.cjs");
2
+ const require_builder = require("../../builder-Cw8u3pPl.cjs");
3
3
  exports.WORKFLOW_BUILDER_AUTHORING_CONSTRAINTS = require_builder.WORKFLOW_BUILDER_AUTHORING_CONSTRAINTS;
4
4
  exports.WORKFLOW_BUILDER_AUTHORING_PLAYBOOK = require_builder.WORKFLOW_BUILDER_AUTHORING_PLAYBOOK;
5
5
  exports.WORKFLOW_BUILDER_MAPPING_CONFIG_DESCRIPTION = require_builder.WORKFLOW_BUILDER_MAPPING_CONFIG_DESCRIPTION;
@@ -1 +1 @@
1
- export { U as WORKFLOW_BUILDER_AUTHORING_CONSTRAINTS, W as WORKFLOW_BUILDER_AUTHORING_PLAYBOOK, i as WORKFLOW_BUILDER_MAPPING_CONFIG_DESCRIPTION, t as WORKFLOW_BUILDER_SUPPORTED_STEP_TYPES, B as compareWorkflowBuilderSchemas, r as createWorkflowBuilderAgent, a as deleteStoredWorkflowResponseSchema, V as inspectWorkflowBuilderSchemas, o as listStoredWorkflowsResponseSchema, n as normalizeWorkflowBuilderDefinition, H as preflightWorkflowDefinition, s as storedWorkflowDefinitionSchema, c as upsertStoredWorkflowResponseSchema, l as workflowBuilderAgentEntryInputSchema, u as workflowBuilderAgentEntrySchema, d as workflowBuilderClassifierEntryInputSchema, f as workflowBuilderClassifierEntrySchema, p as workflowBuilderConditionalEntryInputSchema, m as workflowBuilderConditionalEntrySchema, h as workflowBuilderDefinitionInputSchema, g as workflowBuilderDefinitionSchema, _ as workflowBuilderForeachEntryInputSchema, v as workflowBuilderForeachEntrySchema, y as workflowBuilderGraphEntryInputSchema, b as workflowBuilderGraphEntrySchema, x as workflowBuilderLoopEntryInputSchema, S as workflowBuilderLoopEntrySchema, C as workflowBuilderMappingConfigSchema, w as workflowBuilderMappingDescriptorSchema, T as workflowBuilderMappingEntryInputSchema, E as workflowBuilderMappingEntrySchema, D as workflowBuilderNestedWorkflowEntryInputSchema, O as workflowBuilderNestedWorkflowEntrySchema, k as workflowBuilderParallelEntryInputSchema, A as workflowBuilderParallelEntrySchema, j as workflowBuilderPredicateSchema, M as workflowBuilderScheduleConfigSchema, N as workflowBuilderScheduleSchema, P as workflowBuilderSleepEntryInputSchema, F as workflowBuilderSleepEntrySchema, I as workflowBuilderSleepUntilEntryInputSchema, L as workflowBuilderSleepUntilEntrySchema, R as workflowBuilderToolEntryInputSchema, z as workflowBuilderToolEntrySchema } from "../../builder-Gg-xnX_E.js";
1
+ export { U as WORKFLOW_BUILDER_AUTHORING_CONSTRAINTS, W as WORKFLOW_BUILDER_AUTHORING_PLAYBOOK, i as WORKFLOW_BUILDER_MAPPING_CONFIG_DESCRIPTION, t as WORKFLOW_BUILDER_SUPPORTED_STEP_TYPES, B as compareWorkflowBuilderSchemas, r as createWorkflowBuilderAgent, a as deleteStoredWorkflowResponseSchema, V as inspectWorkflowBuilderSchemas, o as listStoredWorkflowsResponseSchema, n as normalizeWorkflowBuilderDefinition, H as preflightWorkflowDefinition, s as storedWorkflowDefinitionSchema, c as upsertStoredWorkflowResponseSchema, l as workflowBuilderAgentEntryInputSchema, u as workflowBuilderAgentEntrySchema, d as workflowBuilderClassifierEntryInputSchema, f as workflowBuilderClassifierEntrySchema, p as workflowBuilderConditionalEntryInputSchema, m as workflowBuilderConditionalEntrySchema, h as workflowBuilderDefinitionInputSchema, g as workflowBuilderDefinitionSchema, _ as workflowBuilderForeachEntryInputSchema, v as workflowBuilderForeachEntrySchema, y as workflowBuilderGraphEntryInputSchema, b as workflowBuilderGraphEntrySchema, x as workflowBuilderLoopEntryInputSchema, S as workflowBuilderLoopEntrySchema, C as workflowBuilderMappingConfigSchema, w as workflowBuilderMappingDescriptorSchema, T as workflowBuilderMappingEntryInputSchema, E as workflowBuilderMappingEntrySchema, D as workflowBuilderNestedWorkflowEntryInputSchema, O as workflowBuilderNestedWorkflowEntrySchema, k as workflowBuilderParallelEntryInputSchema, A as workflowBuilderParallelEntrySchema, j as workflowBuilderPredicateSchema, M as workflowBuilderScheduleConfigSchema, N as workflowBuilderScheduleSchema, P as workflowBuilderSleepEntryInputSchema, F as workflowBuilderSleepEntrySchema, I as workflowBuilderSleepUntilEntryInputSchema, L as workflowBuilderSleepUntilEntrySchema, R as workflowBuilderToolEntryInputSchema, z as workflowBuilderToolEntrySchema } from "../../builder-Cl-0BWkh.js";
@@ -1,5 +1,5 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
- const require_run_registry = require("../../run-registry-5Suldxz3.cjs");
2
+ const require_run_registry = require("../../run-registry-BmckDVBk.cjs");
3
3
  exports.EventedExecutionEngine = require_run_registry.EventedExecutionEngine;
4
4
  exports.EventedRun = require_run_registry.EventedRun;
5
5
  exports.EventedWorkflow = require_run_registry.EventedWorkflow;
@@ -1 +1 @@
1
- export { $s as EventedExecutionEngine, Cs as EventedRun, ws as EventedWorkflow, As as StepExecutor, ks as WorkflowEventProcessor, Ts as cloneStep, Es as cloneWorkflow, Ds as createStep, Os as createWorkflow } from "../../run-registry-CGRPldLH.js";
1
+ export { sc as EventedExecutionEngine, js as EventedRun, Ms as EventedWorkflow, Rs as StepExecutor, Ls as WorkflowEventProcessor, Ns as cloneStep, Ps as cloneWorkflow, Fs as createStep, Is as createWorkflow } from "../../run-registry-BwEcwYlU.js";
@@ -1,11 +1,11 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
- const require_run_registry = require("../run-registry-5Suldxz3.cjs");
3
- const require_stream = require("../stream-Dvy_0o14.cjs");
2
+ const require_run_registry = require("../run-registry-BmckDVBk.cjs");
3
+ const require_stream = require("../stream-0kdqBOOn.cjs");
4
4
  const require_predicate_index = require("../predicate/index.cjs");
5
5
  const require_schedules = require("../schedules-BZS8McF7.cjs");
6
6
  const require_scheduler = require("../scheduler-D00X03jQ.cjs");
7
- const require_validate = require("../validate-Skps-cM3.cjs");
8
- const require_rehydrate = require("../rehydrate-DDYFpQsV.cjs");
7
+ const require_validate = require("../validate-De92squ7.cjs");
8
+ const require_rehydrate = require("../rehydrate-CDQ4dOYj.cjs");
9
9
  // src/workflows/state-reader.ts
10
10
  const getStep = (state, stepId) => state.steps?.[stepId];
11
11
  const getFirstStepResult = (step) => {
@@ -1,10 +1,10 @@
1
- import { $c as validateStepInput, Ac as RESUME_SNAPSHOT_POLL_INTERVAL_MS, Bc as defineStateAccessors, Dc as createStepFromAgent, Ec as createMappingStep, Fc as cleanStepResult, Gc as hydrateSerializedStepErrors, Hc as getResumeLabelsByStepId, Ic as createDeprecationProxy, Jc as omitPriorCompletionFields, Kc as isEntryFinished, Lc as createRestartExecutionParams, Mc as abortableSleep, Nc as applyStateDelta, Oc as createStepFromClassifier, Pc as assertTimeTravelGraphMatchesSnapshot, Qc as setLongTimeout, Rc as createTimeTravelExecutionParams, Sc as ExecutionEngine, Ss as createWorkflow, Uc as getSingleStepEntryId, Vc as getRestartStartIndex, Wc as getStepIds, Xc as resolveForeachConcurrency, Yc as omitPriorSuspensionFields, Zc as runCountDeprecationMessage, ac as createStep, al as getEntryId, bs as cloneWorkflow, cc as predicateToCondition, el as validateStepRequestContext, ic as cloneStep, il as waitForSuspendedSnapshot, jc as RESUME_SNAPSHOT_WAIT_STATUSES, js as computeScheduleDefinitionHash, kc as createStepFromTool, lc as evaluatePredicate, ll as workflowTermination, nc as Run, nl as validateStepStateData, oc as isProcessor, ol as getEntryWorkflow, qc as isSingleStepEntry, rc as Workflow, rl as validateStepSuspendData, sc as mapVariable, tl as validateStepResumeData, vc as DefaultExecutionEngine, xs as createEventedWorkflow, zc as defineLazyWriter } from "../run-registry-CGRPldLH.js";
2
- import { St as getStepResultAsync, xt as getStepResult } from "../stream-Dpwx0whf.js";
1
+ import { $c as hydrateSerializedStepErrors, Ac as ExecutionEngine, As as createWorkflow, Bc as abortableSleep, Ec as DefaultExecutionEngine, Fc as createStepFromAgent, Gc as createRestartExecutionParams, Hc as assertTimeTravelGraphMatchesSnapshot, Ic as createStepFromClassifier, Jc as defineStateAccessors, Kc as createTimeTravelExecutionParams, Lc as createStepFromTool, Os as cloneWorkflow, Pc as createMappingStep, Qc as getStepIds, Rc as RESUME_SNAPSHOT_POLL_INTERVAL_MS, Uc as cleanStepResult, Vc as applyStateDelta, Wc as createDeprecationProxy, Xc as getResumeLabelsByStepId, Yc as getRestartStartIndex, Zc as getSingleStepEntryId, _c as evaluatePredicate, _l as workflowTermination, al as runCountDeprecationMessage, cl as validateStepRequestContext, dc as Workflow, dl as validateStepSuspendData, el as isEntryFinished, fc as cloneStep, fl as waitForSuspendedSnapshot, gc as predicateToCondition, hc as mapVariable, il as resolveForeachConcurrency, ks as createEventedWorkflow, ll as validateStepResumeData, mc as isProcessor, ml as getEntryWorkflow, nl as omitPriorCompletionFields, ol as setLongTimeout, pc as createStep, pl as getEntryId, qc as defineLazyWriter, rl as omitPriorSuspensionFields, sl as validateStepInput, tl as isSingleStepEntry, uc as Run, ul as validateStepStateData, zc as RESUME_SNAPSHOT_WAIT_STATUSES, zs as computeScheduleDefinitionHash } from "../run-registry-BwEcwYlU.js";
2
+ import { Dt as getStepResult, Ot as getStepResultAsync } from "../stream-D1y9GzoD.js";
3
3
  import { derivePredicateLabel, predicateSchema } from "../predicate/index.js";
4
4
  import { _ as validateCron, h as computeNextFireAt } from "../schedules-DZfSx-7P.js";
5
5
  import { n as WorkflowScheduler, t as Scheduler } from "../scheduler-B-VZUvv_.js";
6
- import { a as jsonSchemaToZod, c as analyzeMapConfig, d as toJsonSchemaOrUndefined, f as validateWorkflowRefs, h as forEachSingleStepEntryWithPath, i as validateWorkflowSchemas, l as parseMapConfig, m as forEachSingleStepEntry, n as validateDynamicWorkflow, o as validateStorableJsonSchema, p as collectNestedWorkflowIds, r as validateWorkflowStructure, s as inferGraphSchemas, t as assertValidDynamicWorkflow, u as schemaCompatibility } from "../validate-HSBcm96b.js";
7
- import { n as entryOptionFields, r as toStorableGraph, t as rehydrateWorkflow } from "../rehydrate-BjLV643n.js";
6
+ import { a as jsonSchemaToZod, c as analyzeMapConfig, d as toJsonSchemaOrUndefined, f as validateWorkflowRefs, h as forEachSingleStepEntryWithPath, i as validateWorkflowSchemas, l as parseMapConfig, m as forEachSingleStepEntry, n as validateDynamicWorkflow, o as validateStorableJsonSchema, p as collectNestedWorkflowIds, r as validateWorkflowStructure, s as inferGraphSchemas, t as assertValidDynamicWorkflow, u as schemaCompatibility } from "../validate-CB-q-R2F.js";
7
+ import { n as entryOptionFields, r as toStorableGraph, t as rehydrateWorkflow } from "../rehydrate-PnaVawGX.js";
8
8
  // src/workflows/state-reader.ts
9
9
  const getStep = (state, stepId) => state.steps?.[stepId];
10
10
  const getFirstStepResult = (step) => {
@@ -203,6 +203,11 @@ export interface WorkspaceFilesystem extends FilesystemLifecycle<FilesystemInfo>
203
203
  * When true, all write operations to this filesystem are blocked.
204
204
  * Read operations are still allowed.
205
205
  *
206
+ * Applies to the filesystem API and file tools. When the filesystem is
207
+ * mounted into a `LocalSandbox` with native isolation, the mount is also
208
+ * made read-only for commands; without isolation, commands are not
209
+ * restricted.
210
+ *
206
211
  * @default false
207
212
  */
208
213
  readonly readOnly?: boolean;
@@ -1,5 +1,5 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
- const require_workspace = require("../workspace-D1OzzlLw.cjs");
2
+ const require_workspace = require("../workspace-X2RHJZU9.cjs");
3
3
  const require_errors = require("../errors-D5kMB1FQ.cjs");
4
4
  const require_workspace_skills = require("../workspace-skills-BcquhPDn.cjs");
5
5
  exports.CompositeFilesystem = require_workspace.CompositeFilesystem;
@@ -1,4 +1,4 @@
1
- import { $ as SandboxExecutionError, A as requireFilesystem, B as UnsupportedStdinCloseError, C as DEFAULT_TAIL_LINES, D as editFileTool, F as getRecommendedIsolation, G as validateSandboxFileMode, H as assertModesUnsupported, I as isIsolationAvailable, J as IsolationUnavailableError, K as MountManager, L as SandboxProcessManager, M as requireWorkspace, N as LocalSandbox, O as deleteFileTool, P as detectIsolation, Q as SandboxError, R as MastraSandbox, S as executeCommandTool, U as supportsComputer, V as MAX_SANDBOX_FILE_MODE, W as supportsNetworking, X as MountNotSupportedError, Y as MountError, Z as SandboxAbortError, _ as readFileTool, a as normalizeFactorySandboxSettings, at as LocalFilesystem, b as indexContentTool, c as formatSkillActivation, ct as callLifecycle, d as CompositeVersionedSkillSource, et as SandboxNotReadyError, f as VersionedSkillSource, g as searchTool, h as writeFileTool, i as isFactorySandbox, j as requireSandbox, k as applyPatchTool, l as collectSkillForPublish, lt as WORKSPACE_TOOLS, m as resolveToolConfig, n as FactorySandbox, nt as SandboxUnsupportedFeatureError, o as Workspace, ot as MastraFilesystem, p as createWorkspaceTools, q as FilesystemNotMountableError, r as describeFactorySandbox, s as createSkillTools, st as CompositeFilesystem, t as FACTORY_SANDBOX_BRAND, tt as SandboxTimeoutError, u as publishSkillFromSource, ut as WORKSPACE_TOOLS_PREFIX, v as mkdirTool, w as truncateOutput, x as fileStatTool, y as listFilesTool, z as ProcessHandle } from "../workspace-C05xDH60.js";
1
+ import { $ as SandboxExecutionError, A as requireFilesystem, B as UnsupportedStdinCloseError, C as DEFAULT_TAIL_LINES, D as editFileTool, F as getRecommendedIsolation, G as validateSandboxFileMode, H as assertModesUnsupported, I as isIsolationAvailable, J as IsolationUnavailableError, K as MountManager, L as SandboxProcessManager, M as requireWorkspace, N as LocalSandbox, O as deleteFileTool, P as detectIsolation, Q as SandboxError, R as MastraSandbox, S as executeCommandTool, U as supportsComputer, V as MAX_SANDBOX_FILE_MODE, W as supportsNetworking, X as MountNotSupportedError, Y as MountError, Z as SandboxAbortError, _ as readFileTool, a as normalizeFactorySandboxSettings, at as LocalFilesystem, b as indexContentTool, c as formatSkillActivation, ct as callLifecycle, d as CompositeVersionedSkillSource, et as SandboxNotReadyError, f as VersionedSkillSource, g as searchTool, h as writeFileTool, i as isFactorySandbox, j as requireSandbox, k as applyPatchTool, l as collectSkillForPublish, lt as WORKSPACE_TOOLS, m as resolveToolConfig, n as FactorySandbox, nt as SandboxUnsupportedFeatureError, o as Workspace, ot as MastraFilesystem, p as createWorkspaceTools, q as FilesystemNotMountableError, r as describeFactorySandbox, s as createSkillTools, st as CompositeFilesystem, t as FACTORY_SANDBOX_BRAND, tt as SandboxTimeoutError, u as publishSkillFromSource, ut as WORKSPACE_TOOLS_PREFIX, v as mkdirTool, w as truncateOutput, x as fileStatTool, y as listFilesTool, z as ProcessHandle } from "../workspace-DY2Nxiyi.js";
2
2
  import { _ as WorkspaceError, a as FileReadRequiredError, b as WorkspaceReadOnlyError, c as FilesystemNotReadyError, d as PermissionError, f as SandboxFeatureNotSupportedError, g as UnsupportedGrepPatternError, h as StaleFileError, i as FileNotFoundError, l as IsDirectoryError, m as SearchNotAvailableError, n as DirectoryNotFoundError, o as FilesystemError, p as SandboxNotAvailableError, r as FileExistsError, s as FilesystemNotAvailableError, t as DirectoryNotEmptyError, u as NotDirectoryError, v as WorkspaceNotAvailableError, y as WorkspaceNotReadyError } from "../errors-CzFYpCHw.js";
3
3
  import { b as getMimeType, f as createGlobMatcher, h as matchGlob, l as LocalSkillSource, m as isGlobPattern, p as extractGlobBase } from "../workspace-skills-38OY32_b.js";
4
4
  export { CompositeFilesystem, CompositeVersionedSkillSource, DEFAULT_TAIL_LINES, DirectoryNotEmptyError, DirectoryNotFoundError, FACTORY_SANDBOX_BRAND, FactorySandbox, FileExistsError, FileNotFoundError, FileReadRequiredError, FilesystemError, FilesystemNotAvailableError, FilesystemNotMountableError, FilesystemNotReadyError, IsDirectoryError, IsolationUnavailableError, LocalFilesystem, LocalSandbox, LocalSkillSource, MAX_SANDBOX_FILE_MODE, MastraFilesystem, MastraSandbox, MountError, MountManager, MountNotSupportedError, NotDirectoryError, PermissionError, ProcessHandle, SandboxAbortError, SandboxError, SandboxExecutionError, SandboxFeatureNotSupportedError, SandboxNotAvailableError, SandboxNotReadyError, SandboxProcessManager, SandboxTimeoutError, SandboxUnsupportedFeatureError, SearchNotAvailableError, StaleFileError, UnsupportedGrepPatternError, UnsupportedStdinCloseError, VersionedSkillSource, WORKSPACE_TOOLS, WORKSPACE_TOOLS_PREFIX, Workspace, WorkspaceError, WorkspaceNotAvailableError, WorkspaceNotReadyError, WorkspaceReadOnlyError, applyPatchTool, assertModesUnsupported, callLifecycle, collectSkillForPublish, createGlobMatcher, createSkillTools, createWorkspaceTools, deleteFileTool, describeFactorySandbox, detectIsolation, editFileTool, executeCommandTool, extractGlobBase, fileStatTool, formatSkillActivation, getMimeType, getRecommendedIsolation, indexContentTool, isFactorySandbox, isGlobPattern, isIsolationAvailable, listFilesTool, matchGlob, mkdirTool, normalizeFactorySandboxSettings, publishSkillFromSource, readFileTool, requireFilesystem, requireSandbox, requireWorkspace, resolveToolConfig, searchTool, supportsComputer, supportsNetworking, truncateOutput, validateSandboxFileMode, writeFileTool };
@@ -160,9 +160,11 @@ export declare class LocalSandbox extends MastraSandbox<string> {
160
160
  private _activeMountPaths;
161
161
  /** Snapshot of `readWritePaths` from ctor; entries here are never removed on unmount. */
162
162
  private readonly _initialReadWritePaths;
163
- /** Refcount for isolation paths added by mounts (not present in `_initialReadWritePaths`). */
163
+ /** Snapshot of `denyWritePaths` from ctor; entries here are never removed on unmount. */
164
+ private readonly _initialDenyWritePaths;
165
+ /** Refcount for isolation paths added by mounts, keyed by `<list>:<path>`. */
164
166
  private _mountIsolationRefCount;
165
- /** Normalized mount path → canonical isolation path recorded for that mount. */
167
+ /** Normalized mount path → canonical isolation path and the list it was added to. */
166
168
  private _mountPathToIsolationPath;
167
169
  /** Named checkpoint to seed from on start and persist to on snapshot. */
168
170
  private readonly _checkpointName?;
@@ -300,20 +302,27 @@ export declare class LocalSandbox extends MastraSandbox<string> {
300
302
  */
301
303
  private checkMarkerFile;
302
304
  /**
303
- * Dynamically add a mount path to the sandbox isolation allowlist.
305
+ * Dynamically add a mount path to the sandbox isolation config.
304
306
  *
305
- * - Seatbelt: pushes to readWritePaths (wrapCommand reads config each call)
306
- * - Bwrap: pushes to readWritePaths (buildBwrapCommand reads config each call)
307
+ * Read-write mounts go to `readWritePaths`; mounts whose filesystem is
308
+ * `readOnly` go to `denyWritePaths` so subprocesses can read but never write
309
+ * them, matching what file tools enforce. Both backends read the config on
310
+ * every wrapCommand() call, so the change takes effect immediately.
307
311
  *
308
312
  * Local mounts are symlinks under `workingDirectory`. Bubblewrap cannot
309
313
  * `--bind` a symlink (it fails with "Unable to mount source on destination"),
310
314
  * so we store the canonical path (`realpath`) of the mount point — the same
311
315
  * directory the symlink refers to.
316
+ *
317
+ * Returns an error when a read-only mount can't be resolved: a write denial on
318
+ * the unresolved symlink wouldn't cover the directory writes actually land in.
312
319
  */
313
320
  private addMountPathToIsolation;
321
+ /** Undo a mount whose isolation couldn't be applied and record it as failed. */
322
+ private failMountIsolation;
314
323
  /**
315
- * Reverse {@link addMountPathToIsolation}: drop refcounted paths from the allowlist on unmount
316
- * while preserving user-provided `readWritePaths` from construction.
324
+ * Reverse {@link addMountPathToIsolation}: drop refcounted paths from the isolation
325
+ * config on unmount while preserving user-provided paths from construction.
317
326
  */
318
327
  private removeMountIsolationForPath;
319
328
  /**
@@ -30,6 +30,15 @@ export interface NativeSandboxConfig {
30
30
  * By default, only the workspace directory has write access.
31
31
  */
32
32
  readWritePaths?: string[];
33
+ /**
34
+ * Paths that are readable but never writable, even when nested inside the
35
+ * workspace or a `readWritePaths` entry. Applied after every write grant so
36
+ * it always wins — including when the same directory is also mounted
37
+ * read-write elsewhere. Mounted filesystems with `readOnly: true` are added
38
+ * here automatically. Ignored when a custom `bwrapArgs` or user-written
39
+ * `seatbeltProfilePath` replaces the generated policy.
40
+ */
41
+ denyWritePaths?: string[];
33
42
  /**
34
43
  * Allow executing system binaries (node, python, etc.)
35
44
  * When false, only binaries within the workspace can be executed.
@@ -60,7 +69,8 @@ export interface NativeSandboxConfig {
60
69
  * Spawned processes can read but not write files in the working directory.
61
70
  * Enforced at the OS level (seatbelt profile / bwrap --ro-bind); ignored when isolation is 'none'.
62
71
  * Exceptions:
63
- * - Paths listed in `readWritePaths` and mounted filesystem targets remain writable.
72
+ * - Paths listed in `readWritePaths` and mounted filesystem targets remain writable,
73
+ * except mounts whose filesystem is `readOnly` (see `denyWritePaths`).
64
74
  * - Providing custom `bwrapArgs` or `seatbeltProfilePath` replaces the generated
65
75
  * sandbox policy and may bypass this read-only restriction entirely.
66
76
  *