@mastra/core 1.26.0 → 1.26.1-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 (120) hide show
  1. package/CHANGELOG.md +17 -0
  2. package/dist/agent/index.cjs +8 -8
  3. package/dist/agent/index.js +1 -1
  4. package/dist/browser/index.cjs +2 -2
  5. package/dist/browser/index.js +1 -1
  6. package/dist/channels/index.cjs +4 -4
  7. package/dist/channels/index.js +1 -1
  8. package/dist/{chunk-CXW3Z2OL.js → chunk-4QTY73BW.js} +4 -4
  9. package/dist/chunk-4QTY73BW.js.map +1 -0
  10. package/dist/{chunk-VOP4TUHG.cjs → chunk-5HLY6ZVZ.cjs} +17 -17
  11. package/dist/{chunk-VOP4TUHG.cjs.map → chunk-5HLY6ZVZ.cjs.map} +1 -1
  12. package/dist/{chunk-GSVFJAVS.js → chunk-65IATTED.js} +3 -3
  13. package/dist/{chunk-GSVFJAVS.js.map → chunk-65IATTED.js.map} +1 -1
  14. package/dist/{chunk-PBGNXXU5.cjs → chunk-7432OHPH.cjs} +13 -13
  15. package/dist/chunk-7432OHPH.cjs.map +1 -0
  16. package/dist/{chunk-PLCLLPJL.js → chunk-BDGDMJRC.js} +9 -9
  17. package/dist/{chunk-PLCLLPJL.js.map → chunk-BDGDMJRC.js.map} +1 -1
  18. package/dist/{chunk-VYRRGSYO.cjs → chunk-BQN2KODN.cjs} +292 -292
  19. package/dist/{chunk-VYRRGSYO.cjs.map → chunk-BQN2KODN.cjs.map} +1 -1
  20. package/dist/{chunk-ZOCCZPSK.js → chunk-BVXKM2NV.js} +6 -6
  21. package/dist/{chunk-ZOCCZPSK.js.map → chunk-BVXKM2NV.js.map} +1 -1
  22. package/dist/{chunk-FFZJH35S.js → chunk-D4VTONCA.js} +3 -3
  23. package/dist/{chunk-FFZJH35S.js.map → chunk-D4VTONCA.js.map} +1 -1
  24. package/dist/{chunk-YZH6VQAS.cjs → chunk-DUJPIL2U.cjs} +5 -5
  25. package/dist/{chunk-YZH6VQAS.cjs.map → chunk-DUJPIL2U.cjs.map} +1 -1
  26. package/dist/{chunk-QNSBW2X4.js → chunk-EB7MYCTO.js} +3 -3
  27. package/dist/chunk-EB7MYCTO.js.map +1 -0
  28. package/dist/{chunk-HEAKZCPY.cjs → chunk-F3DC3HPB.cjs} +224 -224
  29. package/dist/{chunk-HEAKZCPY.cjs.map → chunk-F3DC3HPB.cjs.map} +1 -1
  30. package/dist/{chunk-PHQEKA3K.cjs → chunk-FKRKSEDS.cjs} +57 -57
  31. package/dist/{chunk-PHQEKA3K.cjs.map → chunk-FKRKSEDS.cjs.map} +1 -1
  32. package/dist/{chunk-2KWFY2Z4.cjs → chunk-IIV77JRY.cjs} +24 -30
  33. package/dist/chunk-IIV77JRY.cjs.map +1 -0
  34. package/dist/{chunk-EK2NCPVI.cjs → chunk-JZ4NE7PC.cjs} +7 -7
  35. package/dist/{chunk-EK2NCPVI.cjs.map → chunk-JZ4NE7PC.cjs.map} +1 -1
  36. package/dist/{chunk-Q5JACXBM.cjs → chunk-L24YAW4G.cjs} +3 -3
  37. package/dist/chunk-L24YAW4G.cjs.map +1 -0
  38. package/dist/{chunk-YHKM3BEY.cjs → chunk-MM7USNIY.cjs} +6 -6
  39. package/dist/{chunk-YHKM3BEY.cjs.map → chunk-MM7USNIY.cjs.map} +1 -1
  40. package/dist/{chunk-USTQPLUM.js → chunk-MZPEIW2H.js} +4 -4
  41. package/dist/{chunk-USTQPLUM.js.map → chunk-MZPEIW2H.js.map} +1 -1
  42. package/dist/{chunk-OUAM366B.cjs → chunk-NC4C5XMF.cjs} +9 -9
  43. package/dist/{chunk-OUAM366B.cjs.map → chunk-NC4C5XMF.cjs.map} +1 -1
  44. package/dist/{chunk-42ZT2Z2G.js → chunk-NQGCZAEB.js} +12 -18
  45. package/dist/chunk-NQGCZAEB.js.map +1 -0
  46. package/dist/{chunk-5L2Z472N.js → chunk-NYMU25CS.js} +3 -3
  47. package/dist/{chunk-5L2Z472N.js.map → chunk-NYMU25CS.js.map} +1 -1
  48. package/dist/{chunk-AW2NDGPK.js → chunk-QRZI6IPG.js} +3 -3
  49. package/dist/{chunk-AW2NDGPK.js.map → chunk-QRZI6IPG.js.map} +1 -1
  50. package/dist/{chunk-PKJJATBP.js → chunk-ZIURHKSV.js} +4 -4
  51. package/dist/{chunk-PKJJATBP.js.map → chunk-ZIURHKSV.js.map} +1 -1
  52. package/dist/datasets/index.cjs +11 -11
  53. package/dist/datasets/index.js +1 -1
  54. package/dist/docs/SKILL.md +1 -1
  55. package/dist/docs/assets/SOURCE_MAP.json +134 -134
  56. package/dist/evals/index.cjs +5 -5
  57. package/dist/evals/index.js +2 -2
  58. package/dist/evals/scoreTraces/index.cjs +3 -3
  59. package/dist/evals/scoreTraces/index.js +1 -1
  60. package/dist/harness/index.cjs +7 -7
  61. package/dist/harness/index.js +5 -5
  62. package/dist/index.cjs +2 -2
  63. package/dist/index.js +1 -1
  64. package/dist/llm/index.cjs +20 -20
  65. package/dist/llm/index.js +5 -5
  66. package/dist/llm/model/provider-types.generated.d.ts +2 -1
  67. package/dist/loop/index.cjs +14 -14
  68. package/dist/loop/index.js +1 -1
  69. package/dist/mastra/index.cjs +2 -2
  70. package/dist/mastra/index.js +1 -1
  71. package/dist/mastra-4PNTYVGX.js +3 -0
  72. package/dist/{mastra-GNYYE3LZ.js.map → mastra-4PNTYVGX.js.map} +1 -1
  73. package/dist/mastra-GD4IDWX2.cjs +12 -0
  74. package/dist/{mastra-TDQOUJVC.cjs.map → mastra-GD4IDWX2.cjs.map} +1 -1
  75. package/dist/memory/index.cjs +19 -19
  76. package/dist/memory/index.js +1 -1
  77. package/dist/models-dev-3XJMRBHD.js +3 -0
  78. package/dist/{models-dev-SWQOXATZ.js.map → models-dev-3XJMRBHD.js.map} +1 -1
  79. package/dist/models-dev-MO5D6ABH.cjs +12 -0
  80. package/dist/{models-dev-F44ZVNMB.cjs.map → models-dev-MO5D6ABH.cjs.map} +1 -1
  81. package/dist/netlify-7GWUCWBI.cjs +12 -0
  82. package/dist/{netlify-SM6JU5OO.cjs.map → netlify-7GWUCWBI.cjs.map} +1 -1
  83. package/dist/netlify-KWFGDMNK.js +3 -0
  84. package/dist/{netlify-CTXSBLLU.js.map → netlify-KWFGDMNK.js.map} +1 -1
  85. package/dist/processor-provider/index.cjs +10 -10
  86. package/dist/processor-provider/index.js +1 -1
  87. package/dist/processors/index.cjs +45 -45
  88. package/dist/processors/index.js +1 -1
  89. package/dist/provider-registry-IVDLHER6.js +3 -0
  90. package/dist/{provider-registry-CPP455MT.js.map → provider-registry-IVDLHER6.js.map} +1 -1
  91. package/dist/provider-registry-IXCOQD3Z.cjs +44 -0
  92. package/dist/{provider-registry-OKP5HT5E.cjs.map → provider-registry-IXCOQD3Z.cjs.map} +1 -1
  93. package/dist/provider-registry.json +4 -10
  94. package/dist/relevance/index.cjs +3 -3
  95. package/dist/relevance/index.js +1 -1
  96. package/dist/stream/index.cjs +8 -8
  97. package/dist/stream/index.js +1 -1
  98. package/dist/tool-loop-agent/index.cjs +4 -4
  99. package/dist/tool-loop-agent/index.js +1 -1
  100. package/dist/workflows/evented/index.cjs +10 -10
  101. package/dist/workflows/evented/index.js +1 -1
  102. package/dist/workflows/handlers/control-flow.d.ts.map +1 -1
  103. package/dist/workflows/index.cjs +24 -24
  104. package/dist/workflows/index.js +1 -1
  105. package/package.json +6 -6
  106. package/src/llm/model/provider-types.generated.d.ts +2 -1
  107. package/dist/chunk-2KWFY2Z4.cjs.map +0 -1
  108. package/dist/chunk-42ZT2Z2G.js.map +0 -1
  109. package/dist/chunk-CXW3Z2OL.js.map +0 -1
  110. package/dist/chunk-PBGNXXU5.cjs.map +0 -1
  111. package/dist/chunk-Q5JACXBM.cjs.map +0 -1
  112. package/dist/chunk-QNSBW2X4.js.map +0 -1
  113. package/dist/mastra-GNYYE3LZ.js +0 -3
  114. package/dist/mastra-TDQOUJVC.cjs +0 -12
  115. package/dist/models-dev-F44ZVNMB.cjs +0 -12
  116. package/dist/models-dev-SWQOXATZ.js +0 -3
  117. package/dist/netlify-CTXSBLLU.js +0 -3
  118. package/dist/netlify-SM6JU5OO.cjs +0 -12
  119. package/dist/provider-registry-CPP455MT.js +0 -3
  120. package/dist/provider-registry-OKP5HT5E.cjs +0 -44
@@ -1,6 +1,6 @@
1
1
  'use strict';
2
2
 
3
- var chunkPBGNXXU5_cjs = require('./chunk-PBGNXXU5.cjs');
3
+ var chunk7432OHPH_cjs = require('./chunk-7432OHPH.cjs');
4
4
  var chunkZCBG4ZQT_cjs = require('./chunk-ZCBG4ZQT.cjs');
5
5
  var chunkKXD2SHMK_cjs = require('./chunk-KXD2SHMK.cjs');
6
6
  var chunkUFKCK75F_cjs = require('./chunk-UFKCK75F.cjs');
@@ -62,7 +62,7 @@ var StepExecutor = class extends chunkFCQNDFEW_cjs.MastraBase {
62
62
  let suspended;
63
63
  let bailed;
64
64
  const startedAt = Date.now();
65
- const { inputData, validationError } = await chunkPBGNXXU5_cjs.validateStepInput({
65
+ const { inputData, validationError } = await chunk7432OHPH_cjs.validateStepInput({
66
66
  prevOutput: typeof params.foreachIdx === "number" ? params.input?.[params.foreachIdx] : params.input,
67
67
  step,
68
68
  validateInputs: params.validateInputs ?? true
@@ -95,7 +95,7 @@ var StepExecutor = class extends chunkFCQNDFEW_cjs.MastraBase {
95
95
  const stepOutput = await chunk2NAHFM32_cjs.executeWithContext({
96
96
  span: params.tracingContext?.currentSpan,
97
97
  fn: () => step.execute(
98
- chunkPBGNXXU5_cjs.createDeprecationProxy(
98
+ chunk7432OHPH_cjs.createDeprecationProxy(
99
99
  {
100
100
  workflowId: params.workflowId,
101
101
  runId,
@@ -110,9 +110,9 @@ var StepExecutor = class extends chunkFCQNDFEW_cjs.MastraBase {
110
110
  resumeData: params.resumeData,
111
111
  suspendData: suspendDataToUse,
112
112
  getInitData: () => stepResults?.input,
113
- getStepResult: chunkPBGNXXU5_cjs.getStepResult.bind(this, stepResults),
113
+ getStepResult: chunk7432OHPH_cjs.getStepResult.bind(this, stepResults),
114
114
  suspend: async (suspendPayload, suspendOptions) => {
115
- const { suspendData, validationError: validationError2 } = await chunkPBGNXXU5_cjs.validateStepSuspendData({
115
+ const { suspendData, validationError: validationError2 } = await chunk7432OHPH_cjs.validateStepSuspendData({
116
116
  suspendData: suspendPayload,
117
117
  step,
118
118
  validateInputs: params.validateInputs ?? true
@@ -165,7 +165,7 @@ var StepExecutor = class extends chunkFCQNDFEW_cjs.MastraBase {
165
165
  },
166
166
  {
167
167
  paramName: "runCount",
168
- deprecationMessage: chunkPBGNXXU5_cjs.runCountDeprecationMessage,
168
+ deprecationMessage: chunk7432OHPH_cjs.runCountDeprecationMessage,
169
169
  logger: this.logger
170
170
  }
171
171
  )
@@ -238,7 +238,7 @@ var StepExecutor = class extends chunkFCQNDFEW_cjs.MastraBase {
238
238
  // Preserve TripWire data as plain object for proper serialization
239
239
  // Important: Check `error` not `errorInstance` because getErrorFromUnknown
240
240
  // converts the error and loses the prototype chain
241
- tripwire: error instanceof chunkPBGNXXU5_cjs.TripWire ? {
241
+ tripwire: error instanceof chunk7432OHPH_cjs.TripWire ? {
242
242
  reason: error.message,
243
243
  retry: error.options?.retry,
244
244
  metadata: error.options?.metadata,
@@ -296,7 +296,7 @@ var StepExecutor = class extends chunkFCQNDFEW_cjs.MastraBase {
296
296
  const callId = crypto.randomUUID();
297
297
  const outputWriter = this.createOutputWriter(runId);
298
298
  return condition(
299
- chunkPBGNXXU5_cjs.createDeprecationProxy(
299
+ chunk7432OHPH_cjs.createDeprecationProxy(
300
300
  {
301
301
  workflowId,
302
302
  runId,
@@ -307,7 +307,7 @@ var StepExecutor = class extends chunkFCQNDFEW_cjs.MastraBase {
307
307
  retryCount,
308
308
  resumeData,
309
309
  getInitData: () => stepResults?.input,
310
- getStepResult: chunkPBGNXXU5_cjs.getStepResult.bind(this, stepResults),
310
+ getStepResult: chunk7432OHPH_cjs.getStepResult.bind(this, stepResults),
311
311
  bail: (_result) => {
312
312
  throw new Error("Not implemented");
313
313
  },
@@ -334,7 +334,7 @@ var StepExecutor = class extends chunkFCQNDFEW_cjs.MastraBase {
334
334
  },
335
335
  {
336
336
  paramName: "runCount",
337
- deprecationMessage: chunkPBGNXXU5_cjs.runCountDeprecationMessage,
337
+ deprecationMessage: chunk7432OHPH_cjs.runCountDeprecationMessage,
338
338
  logger: this.logger
339
339
  }
340
340
  )
@@ -354,7 +354,7 @@ var StepExecutor = class extends chunkFCQNDFEW_cjs.MastraBase {
354
354
  const callId = crypto.randomUUID();
355
355
  const outputWriter = this.createOutputWriter(runId);
356
356
  return await step.fn(
357
- chunkPBGNXXU5_cjs.createDeprecationProxy(
357
+ chunk7432OHPH_cjs.createDeprecationProxy(
358
358
  {
359
359
  workflowId: params.workflowId,
360
360
  runId,
@@ -368,7 +368,7 @@ var StepExecutor = class extends chunkFCQNDFEW_cjs.MastraBase {
368
368
  retryCount,
369
369
  resumeData: params.resumeData,
370
370
  getInitData: () => stepResults?.input,
371
- getStepResult: chunkPBGNXXU5_cjs.getStepResult.bind(this, stepResults),
371
+ getStepResult: chunk7432OHPH_cjs.getStepResult.bind(this, stepResults),
372
372
  suspend: async (_suspendPayload) => {
373
373
  throw new Error("Not implemented");
374
374
  },
@@ -397,7 +397,7 @@ var StepExecutor = class extends chunkFCQNDFEW_cjs.MastraBase {
397
397
  },
398
398
  {
399
399
  paramName: "runCount",
400
- deprecationMessage: chunkPBGNXXU5_cjs.runCountDeprecationMessage,
400
+ deprecationMessage: chunk7432OHPH_cjs.runCountDeprecationMessage,
401
401
  logger: this.logger
402
402
  }
403
403
  )
@@ -421,7 +421,7 @@ var StepExecutor = class extends chunkFCQNDFEW_cjs.MastraBase {
421
421
  const callId = crypto.randomUUID();
422
422
  const outputWriter = this.createOutputWriter(runId);
423
423
  const result = await step.fn(
424
- chunkPBGNXXU5_cjs.createDeprecationProxy(
424
+ chunk7432OHPH_cjs.createDeprecationProxy(
425
425
  {
426
426
  workflowId: params.workflowId,
427
427
  runId,
@@ -435,7 +435,7 @@ var StepExecutor = class extends chunkFCQNDFEW_cjs.MastraBase {
435
435
  retryCount,
436
436
  resumeData: params.resumeData,
437
437
  getInitData: () => stepResults?.input,
438
- getStepResult: chunkPBGNXXU5_cjs.getStepResult.bind(this, stepResults),
438
+ getStepResult: chunk7432OHPH_cjs.getStepResult.bind(this, stepResults),
439
439
  suspend: async (_suspendPayload) => {
440
440
  throw new Error("Not implemented");
441
441
  },
@@ -464,7 +464,7 @@ var StepExecutor = class extends chunkFCQNDFEW_cjs.MastraBase {
464
464
  },
465
465
  {
466
466
  paramName: "runCount",
467
- deprecationMessage: chunkPBGNXXU5_cjs.runCountDeprecationMessage,
467
+ deprecationMessage: chunk7432OHPH_cjs.runCountDeprecationMessage,
468
468
  logger: this.logger
469
469
  }
470
470
  )
@@ -483,7 +483,7 @@ function isTripwireChunk(chunk) {
483
483
  }
484
484
  function createTripWireFromChunk(chunk) {
485
485
  const { payload } = chunk;
486
- return new chunkPBGNXXU5_cjs.TripWire(
486
+ return new chunk7432OHPH_cjs.TripWire(
487
487
  payload.reason || "Agent tripwire triggered",
488
488
  {
489
489
  retry: payload.retry,
@@ -2102,7 +2102,7 @@ var WorkflowEventProcessor = class extends EventProcessor {
2102
2102
  runId
2103
2103
  }) ?? { context: {} };
2104
2104
  const nestedWorkflow = step.step;
2105
- const timeTravelParams = chunkPBGNXXU5_cjs.createTimeTravelExecutionParams({
2105
+ const timeTravelParams = chunk7432OHPH_cjs.createTimeTravelExecutionParams({
2106
2106
  steps: timeTravel.steps.slice(1),
2107
2107
  inputData: timeTravel.inputData,
2108
2108
  resumeData: timeTravel.resumeData,
@@ -2202,7 +2202,7 @@ var WorkflowEventProcessor = class extends EventProcessor {
2202
2202
  for (const [key, value] of Object.entries(requestContext)) {
2203
2203
  rc.set(key, value);
2204
2204
  }
2205
- const { resumeData: timeTravelResumeData, validationError: timeTravelResumeValidationError } = await chunkPBGNXXU5_cjs.validateStepResumeData({
2205
+ const { resumeData: timeTravelResumeData, validationError: timeTravelResumeValidationError } = await chunk7432OHPH_cjs.validateStepResumeData({
2206
2206
  resumeData: timeTravel?.stepResults[step.step.id]?.status === "suspended" ? timeTravel?.resumeData : void 0,
2207
2207
  step: step.step
2208
2208
  });
@@ -3023,7 +3023,7 @@ var WorkflowEventProcessor = class extends EventProcessor {
3023
3023
 
3024
3024
  // src/workflows/evented/workflow.ts
3025
3025
  function cloneWorkflow(workflow, opts) {
3026
- const wf = new chunkPBGNXXU5_cjs.Workflow({
3026
+ const wf = new chunk7432OHPH_cjs.Workflow({
3027
3027
  id: opts.id,
3028
3028
  inputSchema: workflow.inputSchema,
3029
3029
  outputSchema: workflow.outputSchema,
@@ -3052,16 +3052,16 @@ function cloneStep(step, opts) {
3052
3052
  };
3053
3053
  }
3054
3054
  function isAgent(input) {
3055
- return input instanceof chunkPBGNXXU5_cjs.Agent;
3055
+ return input instanceof chunk7432OHPH_cjs.Agent;
3056
3056
  }
3057
3057
  function isToolStep(input) {
3058
3058
  return input instanceof chunkU7Z7GCXY_cjs.Tool;
3059
3059
  }
3060
3060
  function isStepParams(input) {
3061
- return input !== null && typeof input === "object" && "id" in input && "execute" in input && !(input instanceof chunkPBGNXXU5_cjs.Agent) && !(input instanceof chunkU7Z7GCXY_cjs.Tool);
3061
+ return input !== null && typeof input === "object" && "id" in input && "execute" in input && !(input instanceof chunk7432OHPH_cjs.Agent) && !(input instanceof chunkU7Z7GCXY_cjs.Tool);
3062
3062
  }
3063
3063
  function isProcessor(obj) {
3064
- return obj !== null && typeof obj === "object" && "id" in obj && typeof obj.id === "string" && !(obj instanceof chunkPBGNXXU5_cjs.Agent) && !(obj instanceof chunkU7Z7GCXY_cjs.Tool) && (typeof obj.processInput === "function" || typeof obj.processInputStep === "function" || typeof obj.processOutputStream === "function" || typeof obj.processOutputResult === "function" || typeof obj.processOutputStep === "function");
3064
+ return obj !== null && typeof obj === "object" && "id" in obj && typeof obj.id === "string" && !(obj instanceof chunk7432OHPH_cjs.Agent) && !(obj instanceof chunkU7Z7GCXY_cjs.Tool) && (typeof obj.processInput === "function" || typeof obj.processInputStep === "function" || typeof obj.processOutputStream === "function" || typeof obj.processOutputResult === "function" || typeof obj.processOutputStep === "function");
3065
3065
  }
3066
3066
  function areProcessorMessageArraysEqual(before, after) {
3067
3067
  if (before === after) {
@@ -3135,7 +3135,7 @@ async function processAgentStream(params) {
3135
3135
  }
3136
3136
  }
3137
3137
  if (streamFormat !== "legacy") {
3138
- await chunkPBGNXXU5_cjs.forwardAgentStreamChunk({ writer, chunk });
3138
+ await chunk7432OHPH_cjs.forwardAgentStreamChunk({ writer, chunk });
3139
3139
  }
3140
3140
  }
3141
3141
  try {
@@ -3193,7 +3193,7 @@ function createStepFromAgent(params, agentOrToolOptions) {
3193
3193
  };
3194
3194
  const llm = await params.getLLM({ requestContext });
3195
3195
  const modelInfo = llm.getModel();
3196
- const isV2Model = chunkPBGNXXU5_cjs.isSupportedLanguageModel(modelInfo);
3196
+ const isV2Model = chunk7432OHPH_cjs.isSupportedLanguageModel(modelInfo);
3197
3197
  let structuredResult = null;
3198
3198
  const handleFinish = (result) => {
3199
3199
  const resultWithObject = result;
@@ -3360,8 +3360,8 @@ function createStepFromProcessor(processor) {
3360
3360
  return {
3361
3361
  id: `processor:${processor.id}`,
3362
3362
  description: processor.name ?? `Processor ${processor.id}`,
3363
- inputSchema: chunkXB4FLS7A_cjs.toStandardSchema(chunkPBGNXXU5_cjs.ProcessorStepSchema),
3364
- outputSchema: chunkXB4FLS7A_cjs.toStandardSchema(chunkPBGNXXU5_cjs.ProcessorStepOutputSchema),
3363
+ inputSchema: chunkXB4FLS7A_cjs.toStandardSchema(chunk7432OHPH_cjs.ProcessorStepSchema),
3364
+ outputSchema: chunkXB4FLS7A_cjs.toStandardSchema(chunk7432OHPH_cjs.ProcessorStepOutputSchema),
3365
3365
  execute: async ({ inputData, requestContext, ...obsFields }) => {
3366
3366
  const observabilityContext = chunkELRUKENZ_cjs.resolveObservabilityContext(obsFields);
3367
3367
  const input = inputData;
@@ -3397,7 +3397,7 @@ function createStepFromProcessor(processor) {
3397
3397
  abortSignal
3398
3398
  } = input;
3399
3399
  const abort = (reason, options) => {
3400
- throw new chunkPBGNXXU5_cjs.TripWire(reason || `Tripwire triggered by ${processor.id}`, options, processor.id);
3400
+ throw new chunk7432OHPH_cjs.TripWire(reason || `Tripwire triggered by ${processor.id}`, options, processor.id);
3401
3401
  };
3402
3402
  const initialMessageId = messageId;
3403
3403
  let currentMessageId = messageId;
@@ -3420,10 +3420,10 @@ function createStepFromProcessor(processor) {
3420
3420
  ...retryCount !== void 0 ? { retryCount } : {}
3421
3421
  };
3422
3422
  case "inputStep": {
3423
- const summarizedModel = chunkPBGNXXU5_cjs.summarizeProcessorModelForSpan(model);
3424
- const summarizedTools = chunkPBGNXXU5_cjs.summarizeProcessorToolsForSpan(tools);
3425
- const summarizedToolChoice = chunkPBGNXXU5_cjs.summarizeToolChoiceForSpan(toolChoice, tools);
3426
- const summarizedActiveTools = chunkPBGNXXU5_cjs.summarizeActiveToolsForSpan(activeTools, tools);
3423
+ const summarizedModel = chunk7432OHPH_cjs.summarizeProcessorModelForSpan(model);
3424
+ const summarizedTools = chunk7432OHPH_cjs.summarizeProcessorToolsForSpan(tools);
3425
+ const summarizedToolChoice = chunk7432OHPH_cjs.summarizeToolChoiceForSpan(toolChoice, tools);
3426
+ const summarizedActiveTools = chunk7432OHPH_cjs.summarizeActiveToolsForSpan(activeTools, tools);
3427
3427
  return {
3428
3428
  messages: messages ?? [],
3429
3429
  ...systemMessages ? { systemMessages } : {},
@@ -3437,7 +3437,7 @@ function createStepFromProcessor(processor) {
3437
3437
  };
3438
3438
  }
3439
3439
  case "outputResult": {
3440
- const summarizedResult = chunkPBGNXXU5_cjs.summarizeProcessorResultForSpan(outputResult ?? defaultOutputResult);
3440
+ const summarizedResult = chunk7432OHPH_cjs.summarizeProcessorResultForSpan(outputResult ?? defaultOutputResult);
3441
3441
  return {
3442
3442
  messages: messages ?? [],
3443
3443
  ...summarizedResult ? { result: summarizedResult } : {},
@@ -3481,25 +3481,25 @@ function createStepFromProcessor(processor) {
3481
3481
  output.messageId = payload.messageId;
3482
3482
  }
3483
3483
  if (payload.model !== void 0 && payload.model !== model) {
3484
- const summarizedModel = chunkPBGNXXU5_cjs.summarizeProcessorModelForSpan(payload.model);
3484
+ const summarizedModel = chunk7432OHPH_cjs.summarizeProcessorModelForSpan(payload.model);
3485
3485
  if (summarizedModel) {
3486
3486
  output.model = summarizedModel;
3487
3487
  }
3488
3488
  }
3489
3489
  if (payload.tools !== void 0 && payload.tools !== tools) {
3490
- const summarizedTools = chunkPBGNXXU5_cjs.summarizeProcessorToolsForSpan(payload.tools);
3490
+ const summarizedTools = chunk7432OHPH_cjs.summarizeProcessorToolsForSpan(payload.tools);
3491
3491
  if (summarizedTools) {
3492
3492
  output.tools = summarizedTools;
3493
3493
  }
3494
3494
  }
3495
3495
  if (payload.toolChoice !== void 0 && payload.toolChoice !== toolChoice) {
3496
- const summarizedToolChoice = chunkPBGNXXU5_cjs.summarizeToolChoiceForSpan(payload.toolChoice, payload.tools ?? tools);
3496
+ const summarizedToolChoice = chunk7432OHPH_cjs.summarizeToolChoiceForSpan(payload.toolChoice, payload.tools ?? tools);
3497
3497
  if (summarizedToolChoice) {
3498
3498
  output.toolChoice = summarizedToolChoice;
3499
3499
  }
3500
3500
  }
3501
3501
  if (payload.activeTools !== void 0 && payload.activeTools !== activeTools) {
3502
- const summarizedActiveTools = chunkPBGNXXU5_cjs.summarizeActiveToolsForSpan(payload.activeTools, payload.tools ?? tools);
3502
+ const summarizedActiveTools = chunk7432OHPH_cjs.summarizeActiveToolsForSpan(payload.activeTools, payload.tools ?? tools);
3503
3503
  if (summarizedActiveTools) {
3504
3504
  output.activeTools = summarizedActiveTools;
3505
3505
  }
@@ -3544,7 +3544,7 @@ function createStepFromProcessor(processor) {
3544
3544
  if (processorStates) {
3545
3545
  let ps = processorStates.get(processor.id);
3546
3546
  if (!ps) {
3547
- ps = new chunkPBGNXXU5_cjs.ProcessorState();
3547
+ ps = new chunk7432OHPH_cjs.ProcessorState();
3548
3548
  processorStates.set(processor.id, ps);
3549
3549
  }
3550
3550
  processorState = ps.customState;
@@ -3595,7 +3595,7 @@ function createStepFromProcessor(processor) {
3595
3595
  processorSpan?.end({ output: buildProcessorSpanOutput(result) });
3596
3596
  return result;
3597
3597
  } catch (error) {
3598
- if (error instanceof chunkPBGNXXU5_cjs.TripWire) {
3598
+ if (error instanceof chunk7432OHPH_cjs.TripWire) {
3599
3599
  processorSpan?.end({ output: { tripwire: error.message } });
3600
3600
  } else {
3601
3601
  processorSpan?.error({ error, endSpan: true });
@@ -3638,7 +3638,7 @@ function createStepFromProcessor(processor) {
3638
3638
  systemMessages: result.getAllSystemMessages()
3639
3639
  };
3640
3640
  } else if (Array.isArray(result)) {
3641
- chunkPBGNXXU5_cjs.ProcessorRunner.applyMessagesToMessageList(
3641
+ chunk7432OHPH_cjs.ProcessorRunner.applyMessagesToMessageList(
3642
3642
  result,
3643
3643
  passThrough.messageList,
3644
3644
  idsBeforeProcessing,
@@ -3648,7 +3648,7 @@ function createStepFromProcessor(processor) {
3648
3648
  return { ...passThrough, messages: result };
3649
3649
  } else if (result && "messages" in result && "systemMessages" in result) {
3650
3650
  const typedResult = result;
3651
- chunkPBGNXXU5_cjs.ProcessorRunner.applyMessagesToMessageList(
3651
+ chunk7432OHPH_cjs.ProcessorRunner.applyMessagesToMessageList(
3652
3652
  typedResult.messages,
3653
3653
  passThrough.messageList,
3654
3654
  idsBeforeProcessing,
@@ -3696,13 +3696,13 @@ function createStepFromProcessor(processor) {
3696
3696
  messageId: currentMessageId,
3697
3697
  rotateResponseMessageId: rotateCurrentResponseMessageId
3698
3698
  });
3699
- const validatedResult = await chunkPBGNXXU5_cjs.ProcessorRunner.validateAndFormatProcessInputStepResult(result, {
3699
+ const validatedResult = await chunk7432OHPH_cjs.ProcessorRunner.validateAndFormatProcessInputStepResult(result, {
3700
3700
  messageList: passThrough.messageList,
3701
3701
  processor,
3702
3702
  stepNumber: stepNumber ?? 0
3703
3703
  });
3704
3704
  if (validatedResult.messages) {
3705
- chunkPBGNXXU5_cjs.ProcessorRunner.applyMessagesToMessageList(
3705
+ chunk7432OHPH_cjs.ProcessorRunner.applyMessagesToMessageList(
3706
3706
  validatedResult.messages,
3707
3707
  passThrough.messageList,
3708
3708
  idsBeforeProcessing,
@@ -3759,7 +3759,7 @@ function createStepFromProcessor(processor) {
3759
3759
  delete mutableState[spanKey];
3760
3760
  }
3761
3761
  } catch (error) {
3762
- if (error instanceof chunkPBGNXXU5_cjs.TripWire) {
3762
+ if (error instanceof chunk7432OHPH_cjs.TripWire) {
3763
3763
  processorSpan2?.end({ output: { tripwire: error.message } });
3764
3764
  } else {
3765
3765
  processorSpan2?.error({ error, endSpan: true });
@@ -3810,7 +3810,7 @@ function createStepFromProcessor(processor) {
3810
3810
  systemMessages: result.getAllSystemMessages()
3811
3811
  };
3812
3812
  } else if (Array.isArray(result)) {
3813
- chunkPBGNXXU5_cjs.ProcessorRunner.applyMessagesToMessageList(
3813
+ chunk7432OHPH_cjs.ProcessorRunner.applyMessagesToMessageList(
3814
3814
  result,
3815
3815
  passThrough.messageList,
3816
3816
  idsBeforeProcessing,
@@ -3820,7 +3820,7 @@ function createStepFromProcessor(processor) {
3820
3820
  return { ...passThrough, messages: result };
3821
3821
  } else if (result && "messages" in result && "systemMessages" in result) {
3822
3822
  const typedResult = result;
3823
- chunkPBGNXXU5_cjs.ProcessorRunner.applyMessagesToMessageList(
3823
+ chunk7432OHPH_cjs.ProcessorRunner.applyMessagesToMessageList(
3824
3824
  typedResult.messages,
3825
3825
  passThrough.messageList,
3826
3826
  idsBeforeProcessing,
@@ -3882,7 +3882,7 @@ function createStepFromProcessor(processor) {
3882
3882
  systemMessages: result.getAllSystemMessages()
3883
3883
  };
3884
3884
  } else if (Array.isArray(result)) {
3885
- chunkPBGNXXU5_cjs.ProcessorRunner.applyMessagesToMessageList(
3885
+ chunk7432OHPH_cjs.ProcessorRunner.applyMessagesToMessageList(
3886
3886
  result,
3887
3887
  passThrough.messageList,
3888
3888
  idsBeforeProcessing,
@@ -3892,7 +3892,7 @@ function createStepFromProcessor(processor) {
3892
3892
  return { ...passThrough, messages: result };
3893
3893
  } else if (result && "messages" in result && "systemMessages" in result) {
3894
3894
  const typedResult = result;
3895
- chunkPBGNXXU5_cjs.ProcessorRunner.applyMessagesToMessageList(
3895
+ chunk7432OHPH_cjs.ProcessorRunner.applyMessagesToMessageList(
3896
3896
  typedResult.messages,
3897
3897
  passThrough.messageList,
3898
3898
  idsBeforeProcessing,
@@ -3936,7 +3936,7 @@ function createWorkflow(params) {
3936
3936
  executionEngine
3937
3937
  });
3938
3938
  }
3939
- var EventedWorkflow = class extends chunkPBGNXXU5_cjs.Workflow {
3939
+ var EventedWorkflow = class extends chunk7432OHPH_cjs.Workflow {
3940
3940
  constructor(params) {
3941
3941
  super(params);
3942
3942
  this.engineType = "evented";
@@ -4010,7 +4010,7 @@ var EventedWorkflow = class extends chunkPBGNXXU5_cjs.Workflow {
4010
4010
  return run;
4011
4011
  }
4012
4012
  };
4013
- var EventedRun = class extends chunkPBGNXXU5_cjs.Run {
4013
+ var EventedRun = class extends chunk7432OHPH_cjs.Run {
4014
4014
  constructor(params) {
4015
4015
  super(params);
4016
4016
  this.serializedStepGraph = params.serializedStepGraph;
@@ -4222,7 +4222,7 @@ var EventedRun = class extends chunkPBGNXXU5_cjs.Run {
4222
4222
  }
4223
4223
  }
4224
4224
  });
4225
- this.streamOutput = new chunkPBGNXXU5_cjs.WorkflowRunOutput({
4225
+ this.streamOutput = new chunk7432OHPH_cjs.WorkflowRunOutput({
4226
4226
  runId: this.runId,
4227
4227
  workflowId: this.workflowId,
4228
4228
  stream
@@ -4288,7 +4288,7 @@ var EventedRun = class extends chunkPBGNXXU5_cjs.Run {
4288
4288
  }
4289
4289
  }
4290
4290
  });
4291
- this.streamOutput = new chunkPBGNXXU5_cjs.WorkflowRunOutput({
4291
+ this.streamOutput = new chunk7432OHPH_cjs.WorkflowRunOutput({
4292
4292
  runId: this.runId,
4293
4293
  workflowId: this.workflowId,
4294
4294
  stream
@@ -4521,7 +4521,7 @@ function isExecutableStep(step) {
4521
4521
  }
4522
4522
 
4523
4523
  // src/workflows/evented/execution-engine.ts
4524
- var EventedExecutionEngine = class extends chunkPBGNXXU5_cjs.ExecutionEngine {
4524
+ var EventedExecutionEngine = class extends chunk7432OHPH_cjs.ExecutionEngine {
4525
4525
  eventProcessor;
4526
4526
  constructor({
4527
4527
  mastra,
@@ -4561,7 +4561,7 @@ var EventedExecutionEngine = class extends chunkPBGNXXU5_cjs.ExecutionEngine {
4561
4561
  await ack?.();
4562
4562
  await pubsub.unsubscribe("workflows-finish", finishCb);
4563
4563
  if (event.type === "workflow.fail" && event.data.stepResults) {
4564
- event.data.stepResults = chunkPBGNXXU5_cjs.hydrateSerializedStepErrors(event.data.stepResults);
4564
+ event.data.stepResults = chunk7432OHPH_cjs.hydrateSerializedStepErrors(event.data.stepResults);
4565
4565
  }
4566
4566
  resolveResult(event.data);
4567
4567
  return;
@@ -4643,7 +4643,7 @@ var EventedExecutionEngine = class extends chunkPBGNXXU5_cjs.ExecutionEngine {
4643
4643
  const { __state: _removedState, ...stepResultsWithoutTopLevelState } = resultData.stepResults ?? {};
4644
4644
  const cleanStepResults = {};
4645
4645
  for (const [stepId, stepResult] of Object.entries(stepResultsWithoutTopLevelState)) {
4646
- cleanStepResults[stepId] = chunkPBGNXXU5_cjs.cleanStepResult(stepResult);
4646
+ cleanStepResults[stepId] = chunk7432OHPH_cjs.cleanStepResult(stepResult);
4647
4647
  }
4648
4648
  let callbackArg;
4649
4649
  if (resultData.prevResult.status === "failed") {
@@ -4760,5 +4760,5 @@ exports.cloneStep = cloneStep;
4760
4760
  exports.cloneWorkflow = cloneWorkflow;
4761
4761
  exports.createStep = createStep;
4762
4762
  exports.createWorkflow = createWorkflow;
4763
- //# sourceMappingURL=chunk-PHQEKA3K.cjs.map
4764
- //# sourceMappingURL=chunk-PHQEKA3K.cjs.map
4763
+ //# sourceMappingURL=chunk-FKRKSEDS.cjs.map
4764
+ //# sourceMappingURL=chunk-FKRKSEDS.cjs.map