@mastra/core 1.0.0-beta.0 → 1.0.0-beta.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +17 -0
- package/dist/agent/index.cjs +6 -6
- package/dist/agent/index.js +1 -1
- package/dist/{chunk-QCQLOMJM.cjs → chunk-22443P6A.cjs} +22 -21
- package/dist/chunk-22443P6A.cjs.map +1 -0
- package/dist/{chunk-YIK3ASEG.cjs → chunk-2ZVKF4HP.cjs} +117 -42
- package/dist/chunk-2ZVKF4HP.cjs.map +1 -0
- package/dist/{chunk-26SQQNMU.js → chunk-7CBEP2ZQ.js} +36 -12
- package/dist/chunk-7CBEP2ZQ.js.map +1 -0
- package/dist/{chunk-7SKXKUYT.js → chunk-7PO6SEJF.js} +6 -3
- package/dist/chunk-7PO6SEJF.js.map +1 -0
- package/dist/{chunk-S5MJLXMG.cjs → chunk-CB575O6L.cjs} +10 -2
- package/dist/chunk-CB575O6L.cjs.map +1 -0
- package/dist/chunk-HDJFSJCK.js +2237 -0
- package/dist/chunk-HDJFSJCK.js.map +1 -0
- package/dist/{chunk-BU4IAJWF.js → chunk-I4CXL4SR.js} +3 -3
- package/dist/{chunk-BU4IAJWF.js.map → chunk-I4CXL4SR.js.map} +1 -1
- package/dist/{chunk-VV753WCB.cjs → chunk-IQO7ANVS.cjs} +8 -8
- package/dist/{chunk-VV753WCB.cjs.map → chunk-IQO7ANVS.cjs.map} +1 -1
- package/dist/{chunk-L7XKOKOW.js → chunk-JPGVRWWL.js} +3 -3
- package/dist/chunk-JPGVRWWL.js.map +1 -0
- package/dist/{chunk-BXOL277H.cjs → chunk-JYYQQEBH.cjs} +7 -4
- package/dist/chunk-JYYQQEBH.cjs.map +1 -0
- package/dist/chunk-LWBQ4P4N.cjs +2240 -0
- package/dist/chunk-LWBQ4P4N.cjs.map +1 -0
- package/dist/{chunk-VJUZZB2I.js → chunk-SNPVZPLB.js} +4 -4
- package/dist/{chunk-VJUZZB2I.js.map → chunk-SNPVZPLB.js.map} +1 -1
- package/dist/{chunk-32CTMD2C.js → chunk-W7UH2PWL.js} +108 -33
- package/dist/chunk-W7UH2PWL.js.map +1 -0
- package/dist/{chunk-FD734TPS.cjs → chunk-YCVEJ3UN.cjs} +37 -13
- package/dist/chunk-YCVEJ3UN.cjs.map +1 -0
- package/dist/{chunk-P6APHXPZ.js → chunk-ZGHTOYHW.js} +5 -4
- package/dist/chunk-ZGHTOYHW.js.map +1 -0
- package/dist/{chunk-QUZGDSWE.cjs → chunk-ZWNI5IWX.cjs} +11 -11
- package/dist/{chunk-QUZGDSWE.cjs.map → chunk-ZWNI5IWX.cjs.map} +1 -1
- package/dist/evals/index.cjs +4 -4
- package/dist/evals/index.js +1 -1
- package/dist/evals/scoreTraces/index.cjs +3 -3
- package/dist/evals/scoreTraces/index.js +1 -1
- package/dist/index.cjs +2 -2
- package/dist/index.js +1 -1
- package/dist/llm/index.cjs +7 -7
- package/dist/llm/index.js +1 -1
- package/dist/llm/model/gateways/constants.d.ts.map +1 -1
- package/dist/llm/model/gateways/models-dev.d.ts.map +1 -1
- package/dist/llm/model/provider-types.generated.d.ts +48 -10
- package/dist/loop/index.cjs +2 -2
- package/dist/loop/index.js +1 -1
- package/dist/mastra/index.cjs +2 -2
- package/dist/mastra/index.d.ts.map +1 -1
- package/dist/mastra/index.js +1 -1
- package/dist/memory/index.cjs +2 -2
- package/dist/memory/index.js +1 -1
- package/dist/models-dev-DNBKXHT4.js +3 -0
- package/dist/{models-dev-7U4NRMM3.js.map → models-dev-DNBKXHT4.js.map} +1 -1
- package/dist/models-dev-YBEEQIX6.cjs +12 -0
- package/dist/{models-dev-VKSAQPRK.cjs.map → models-dev-YBEEQIX6.cjs.map} +1 -1
- package/dist/netlify-7G2L5VSH.js +3 -0
- package/dist/{netlify-42ZNWIDQ.js.map → netlify-7G2L5VSH.js.map} +1 -1
- package/dist/netlify-GWNGSIRZ.cjs +12 -0
- package/dist/{netlify-2IDXTNFW.cjs.map → netlify-GWNGSIRZ.cjs.map} +1 -1
- package/dist/processors/index.cjs +11 -11
- package/dist/processors/index.js +1 -1
- package/dist/provider-registry.json +101 -26
- package/dist/relevance/index.cjs +2 -2
- package/dist/relevance/index.js +1 -1
- package/dist/stream/index.cjs +8 -8
- package/dist/stream/index.js +1 -1
- package/dist/workflows/default.d.ts.map +1 -1
- package/dist/workflows/evented/index.cjs +10 -10
- package/dist/workflows/evented/index.js +1 -1
- package/dist/workflows/evented/step-executor.d.ts.map +1 -1
- package/dist/workflows/index.cjs +16 -16
- package/dist/workflows/index.js +1 -1
- package/dist/workflows/step.d.ts +1 -1
- package/dist/workflows/step.d.ts.map +1 -1
- package/dist/workflows/types.d.ts +11 -5
- package/dist/workflows/types.d.ts.map +1 -1
- package/dist/workflows/workflow.d.ts +1 -0
- package/dist/workflows/workflow.d.ts.map +1 -1
- package/package.json +5 -4
- package/src/llm/model/provider-types.generated.d.ts +48 -10
- package/dist/chunk-26SQQNMU.js.map +0 -1
- package/dist/chunk-32CTMD2C.js.map +0 -1
- package/dist/chunk-7SKXKUYT.js.map +0 -1
- package/dist/chunk-BNBRQS7N.js +0 -910
- package/dist/chunk-BNBRQS7N.js.map +0 -1
- package/dist/chunk-BXOL277H.cjs.map +0 -1
- package/dist/chunk-FD734TPS.cjs.map +0 -1
- package/dist/chunk-IU2SZXJQ.cjs +0 -913
- package/dist/chunk-IU2SZXJQ.cjs.map +0 -1
- package/dist/chunk-L7XKOKOW.js.map +0 -1
- package/dist/chunk-P6APHXPZ.js.map +0 -1
- package/dist/chunk-QCQLOMJM.cjs.map +0 -1
- package/dist/chunk-S5MJLXMG.cjs.map +0 -1
- package/dist/chunk-YIK3ASEG.cjs.map +0 -1
- package/dist/models-dev-7U4NRMM3.js +0 -3
- package/dist/models-dev-VKSAQPRK.cjs +0 -12
- package/dist/netlify-2IDXTNFW.cjs +0 -12
- package/dist/netlify-42ZNWIDQ.js +0 -3
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { DefaultVoice } from './chunk-UIZSWUKP.js';
|
|
2
2
|
import { STREAM_FORMAT_SYMBOL, EMITTER_SYMBOL } from './chunk-NLNKQD2T.js';
|
|
3
3
|
import { MessageList, DefaultGeneratedFile, DefaultGeneratedFileWithType } from './chunk-JV2KH24V.js';
|
|
4
|
-
import { resolveModelConfig } from './chunk-
|
|
4
|
+
import { resolveModelConfig } from './chunk-W7UH2PWL.js';
|
|
5
5
|
import { MastraLLMV1 } from './chunk-XEVG546F.js';
|
|
6
6
|
import { executeHook } from './chunk-L54GIUCB.js';
|
|
7
7
|
import { selectFields, ensureToolProperties, makeCoreTool, createMastraProxy, delay } from './chunk-4CDL2QJT.js';
|
|
@@ -1544,7 +1544,12 @@ var DefaultExecutionEngine = class extends ExecutionEngine {
|
|
|
1544
1544
|
});
|
|
1545
1545
|
}
|
|
1546
1546
|
if (suspended) {
|
|
1547
|
-
execResults = {
|
|
1547
|
+
execResults = {
|
|
1548
|
+
status: "suspended",
|
|
1549
|
+
suspendPayload: suspended.payload,
|
|
1550
|
+
...result ? { suspendOutput: result } : {},
|
|
1551
|
+
suspendedAt: Date.now()
|
|
1552
|
+
};
|
|
1548
1553
|
} else if (bailed) {
|
|
1549
1554
|
execResults = { status: "bailed", output: bailed.payload, endedAt: Date.now() };
|
|
1550
1555
|
} else {
|
|
@@ -1753,7 +1758,11 @@ var DefaultExecutionEngine = class extends ExecutionEngine {
|
|
|
1753
1758
|
if (hasFailed) {
|
|
1754
1759
|
execResults = { status: "failed", error: hasFailed.error };
|
|
1755
1760
|
} else if (hasSuspended) {
|
|
1756
|
-
execResults = {
|
|
1761
|
+
execResults = {
|
|
1762
|
+
status: "suspended",
|
|
1763
|
+
suspendPayload: hasSuspended.suspendPayload,
|
|
1764
|
+
...hasSuspended.suspendOutput ? { suspendOutput: hasSuspended.suspendOutput } : {}
|
|
1765
|
+
};
|
|
1757
1766
|
} else if (abortController?.signal?.aborted) {
|
|
1758
1767
|
execResults = { status: "canceled" };
|
|
1759
1768
|
} else {
|
|
@@ -1941,7 +1950,12 @@ var DefaultExecutionEngine = class extends ExecutionEngine {
|
|
|
1941
1950
|
if (hasFailed) {
|
|
1942
1951
|
execResults = { status: "failed", error: hasFailed.error };
|
|
1943
1952
|
} else if (hasSuspended) {
|
|
1944
|
-
execResults = {
|
|
1953
|
+
execResults = {
|
|
1954
|
+
status: "suspended",
|
|
1955
|
+
suspendPayload: hasSuspended.suspendPayload,
|
|
1956
|
+
...hasSuspended.suspendOutput ? { suspendOutput: hasSuspended.suspendOutput } : {},
|
|
1957
|
+
suspendedAt: hasSuspended.suspendedAt
|
|
1958
|
+
};
|
|
1945
1959
|
} else if (abortController?.signal?.aborted) {
|
|
1946
1960
|
execResults = { status: "canceled" };
|
|
1947
1961
|
} else {
|
|
@@ -2240,6 +2254,7 @@ var DefaultExecutionEngine = class extends ExecutionEngine {
|
|
|
2240
2254
|
...stepInfo,
|
|
2241
2255
|
suspendedAt: Date.now(),
|
|
2242
2256
|
status: "suspended",
|
|
2257
|
+
...foreachIndexObj[foreachIndex].suspendOutput ? { suspendOutput: foreachIndexObj[foreachIndex].suspendOutput } : {},
|
|
2243
2258
|
suspendPayload: {
|
|
2244
2259
|
...foreachIndexObj[foreachIndex].suspendPayload,
|
|
2245
2260
|
__workflow_meta: {
|
|
@@ -2874,6 +2889,7 @@ var Workflow = class extends MastraBase {
|
|
|
2874
2889
|
stateSchema;
|
|
2875
2890
|
steps;
|
|
2876
2891
|
stepDefs;
|
|
2892
|
+
committed = false;
|
|
2877
2893
|
stepFlow;
|
|
2878
2894
|
serializedStepFlow;
|
|
2879
2895
|
executionEngine;
|
|
@@ -2956,7 +2972,8 @@ var Workflow = class extends MastraBase {
|
|
|
2956
2972
|
id: step.id,
|
|
2957
2973
|
description: step.description,
|
|
2958
2974
|
component: step.component,
|
|
2959
|
-
serializedStepFlow: step.serializedStepFlow
|
|
2975
|
+
serializedStepFlow: step.serializedStepFlow,
|
|
2976
|
+
canSuspend: Boolean(step.suspendSchema || step.resumeSchema)
|
|
2960
2977
|
}
|
|
2961
2978
|
});
|
|
2962
2979
|
this.steps[step.id] = step;
|
|
@@ -3116,7 +3133,8 @@ var Workflow = class extends MastraBase {
|
|
|
3116
3133
|
id: step.id,
|
|
3117
3134
|
description: step.description,
|
|
3118
3135
|
component: step.component,
|
|
3119
|
-
serializedStepFlow: step.serializedStepFlow
|
|
3136
|
+
serializedStepFlow: step.serializedStepFlow,
|
|
3137
|
+
canSuspend: Boolean(step.suspendSchema || step.resumeSchema)
|
|
3120
3138
|
}
|
|
3121
3139
|
}))
|
|
3122
3140
|
});
|
|
@@ -3143,7 +3161,8 @@ var Workflow = class extends MastraBase {
|
|
|
3143
3161
|
id: step.id,
|
|
3144
3162
|
description: step.description,
|
|
3145
3163
|
component: step.component,
|
|
3146
|
-
serializedStepFlow: step.serializedStepFlow
|
|
3164
|
+
serializedStepFlow: step.serializedStepFlow,
|
|
3165
|
+
canSuspend: Boolean(step.suspendSchema || step.resumeSchema)
|
|
3147
3166
|
}
|
|
3148
3167
|
})),
|
|
3149
3168
|
serializedConditions: steps.map(([cond, _step]) => ({ id: `${_step.id}-condition`, fn: cond.toString() }))
|
|
@@ -3168,7 +3187,8 @@ var Workflow = class extends MastraBase {
|
|
|
3168
3187
|
id: step.id,
|
|
3169
3188
|
description: step.description,
|
|
3170
3189
|
component: step.component,
|
|
3171
|
-
serializedStepFlow: step.serializedStepFlow
|
|
3190
|
+
serializedStepFlow: step.serializedStepFlow,
|
|
3191
|
+
canSuspend: Boolean(step.suspendSchema || step.resumeSchema)
|
|
3172
3192
|
},
|
|
3173
3193
|
serializedCondition: { id: `${step.id}-condition`, fn: condition.toString() },
|
|
3174
3194
|
loopType: "dowhile"
|
|
@@ -3191,7 +3211,8 @@ var Workflow = class extends MastraBase {
|
|
|
3191
3211
|
id: step.id,
|
|
3192
3212
|
description: step.description,
|
|
3193
3213
|
component: step.component,
|
|
3194
|
-
serializedStepFlow: step.serializedStepFlow
|
|
3214
|
+
serializedStepFlow: step.serializedStepFlow,
|
|
3215
|
+
canSuspend: Boolean(step.suspendSchema || step.resumeSchema)
|
|
3195
3216
|
},
|
|
3196
3217
|
serializedCondition: { id: `${step.id}-condition`, fn: condition.toString() },
|
|
3197
3218
|
loopType: "dountil"
|
|
@@ -3200,6 +3221,7 @@ var Workflow = class extends MastraBase {
|
|
|
3200
3221
|
return this;
|
|
3201
3222
|
}
|
|
3202
3223
|
foreach(step, opts) {
|
|
3224
|
+
const actualStep = step;
|
|
3203
3225
|
this.stepFlow.push({ type: "foreach", step, opts: opts ?? { concurrency: 1 } });
|
|
3204
3226
|
this.serializedStepFlow.push({
|
|
3205
3227
|
type: "foreach",
|
|
@@ -3207,7 +3229,8 @@ var Workflow = class extends MastraBase {
|
|
|
3207
3229
|
id: step.id,
|
|
3208
3230
|
description: step.description,
|
|
3209
3231
|
component: step.component,
|
|
3210
|
-
serializedStepFlow: step.serializedStepFlow
|
|
3232
|
+
serializedStepFlow: step.serializedStepFlow,
|
|
3233
|
+
canSuspend: Boolean(actualStep.suspendSchema || actualStep.resumeSchema)
|
|
3211
3234
|
},
|
|
3212
3235
|
opts: opts ?? { concurrency: 1 }
|
|
3213
3236
|
});
|
|
@@ -3231,6 +3254,7 @@ var Workflow = class extends MastraBase {
|
|
|
3231
3254
|
*/
|
|
3232
3255
|
commit() {
|
|
3233
3256
|
this.executionGraph = this.buildExecutionGraph();
|
|
3257
|
+
this.committed = true;
|
|
3234
3258
|
return this;
|
|
3235
3259
|
}
|
|
3236
3260
|
get stepGraph() {
|
|
@@ -15750,5 +15774,5 @@ var MastraModelOutput = class extends MastraBase {
|
|
|
15750
15774
|
};
|
|
15751
15775
|
|
|
15752
15776
|
export { AISDKV5OutputStream, Agent, BatchPartsProcessor, ChunkFrom, DefaultExecutionEngine, ExecutionEngine, LanguageDetector, MastraAgentNetworkStream, MastraModelOutput, ModerationProcessor, PIIDetector, ProcessorState, PromptInjectionDetector, Run, StructuredOutputProcessor, SystemPromptScrubber, TokenLimiterProcessor, TripWire, UnicodeNormalizer, Workflow, WorkflowRunOutput, cloneStep, cloneWorkflow, convertFullStreamChunkToUIMessageStream, convertMastraChunkToAISDKv5, createDeprecationProxy, createStep, createWorkflow, getResumeLabelsByStepId, getStepResult, getZodErrors, loop, mapVariable, resolveThreadIdFromArgs, runCountDeprecationMessage, tryGenerateWithJsonFallback, tryStreamWithJsonFallback, validateStepInput };
|
|
15753
|
-
//# sourceMappingURL=chunk-
|
|
15754
|
-
//# sourceMappingURL=chunk-
|
|
15777
|
+
//# sourceMappingURL=chunk-7CBEP2ZQ.js.map
|
|
15778
|
+
//# sourceMappingURL=chunk-7CBEP2ZQ.js.map
|