@mastra/core 0.9.4-alpha.4 → 0.9.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/agent/index.cjs +2 -2
- package/dist/agent/index.js +1 -1
- package/dist/{chunk-HAENAPIH.cjs → chunk-5JUWUTPJ.cjs} +2 -2
- package/dist/{chunk-KZGB62K2.cjs → chunk-66GQROSI.cjs} +15 -15
- package/dist/{chunk-WKFKO3Q2.js → chunk-CIEPFV6B.js} +1 -1
- package/dist/{chunk-MX6P7USA.js → chunk-FW5RS6WV.js} +4 -4
- package/dist/{chunk-M4EDS6EW.js → chunk-H4CEZSRM.js} +1 -1
- package/dist/{chunk-XR75VNNH.js → chunk-PEK4TY3P.js} +1 -1
- package/dist/{chunk-24TNYZQE.cjs → chunk-QHDPLMHB.cjs} +2 -2
- package/dist/{chunk-V4SPAVHV.cjs → chunk-WE36CRQV.cjs} +2 -2
- package/dist/{chunk-6DIL4BTD.js → chunk-WIKOYZ63.js} +1 -1
- package/dist/{chunk-JA7Y3KJH.cjs → chunk-XRGDVLM4.cjs} +5 -5
- package/dist/index.cjs +70 -70
- package/dist/index.js +10 -10
- package/dist/integration/index.cjs +3 -3
- package/dist/integration/index.js +1 -1
- package/dist/memory/index.cjs +4 -4
- package/dist/memory/index.js +1 -1
- package/dist/network/index.cjs +4 -4
- package/dist/network/index.js +2 -2
- package/dist/relevance/index.cjs +4 -4
- package/dist/relevance/index.js +1 -1
- package/dist/tools/index.cjs +4 -4
- package/dist/tools/index.js +1 -1
- package/dist/utils.cjs +12 -12
- package/dist/utils.js +1 -1
- package/dist/workflows/index.cjs +22 -22
- package/dist/workflows/index.js +1 -1
- package/dist/workflows/vNext/index.cjs +5 -5
- package/dist/workflows/vNext/index.js +3 -3
- package/package.json +2 -2
- package/dist/{chunk-3CTNBAF2.cjs → chunk-EJITEVAB.cjs} +1 -1
- package/dist/{chunk-D5PCSVU5.js → chunk-S34QVMKE.js} +1 -1
package/dist/agent/index.cjs
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var chunk66GQROSI_cjs = require('../chunk-66GQROSI.cjs');
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
|
|
7
7
|
Object.defineProperty(exports, "Agent", {
|
|
8
8
|
enumerable: true,
|
|
9
|
-
get: function () { return
|
|
9
|
+
get: function () { return chunk66GQROSI_cjs.Agent; }
|
|
10
10
|
});
|
package/dist/agent/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export { Agent } from '../chunk-
|
|
1
|
+
export { Agent } from '../chunk-FW5RS6WV.js';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var chunkEJITEVAB_cjs = require('./chunk-EJITEVAB.cjs');
|
|
4
4
|
var zod = require('zod');
|
|
5
5
|
|
|
6
6
|
// src/integration/integration.ts
|
|
@@ -68,7 +68,7 @@ var OpenAPIToolset = class {
|
|
|
68
68
|
const tools = Object.keys(clientMethods).reduce((acc, key) => {
|
|
69
69
|
const comment = documentations[key]?.comment;
|
|
70
70
|
const fallbackComment = `Execute ${key}`;
|
|
71
|
-
const tool =
|
|
71
|
+
const tool = chunkEJITEVAB_cjs.createTool({
|
|
72
72
|
id: key,
|
|
73
73
|
inputSchema: schemas[key] || zod.z.object({}),
|
|
74
74
|
description: comment || fallbackComment,
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
var chunkS7J63JOG_cjs = require('./chunk-S7J63JOG.cjs');
|
|
4
|
-
var
|
|
5
|
-
var chunkJA7Y3KJH_cjs = require('./chunk-JA7Y3KJH.cjs');
|
|
4
|
+
var chunkXRGDVLM4_cjs = require('./chunk-XRGDVLM4.cjs');
|
|
6
5
|
var chunkUVRGQEMD_cjs = require('./chunk-UVRGQEMD.cjs');
|
|
7
|
-
var
|
|
6
|
+
var chunkEJITEVAB_cjs = require('./chunk-EJITEVAB.cjs');
|
|
7
|
+
var chunkLABUWBKX_cjs = require('./chunk-LABUWBKX.cjs');
|
|
8
|
+
var chunkST5RMVLG_cjs = require('./chunk-ST5RMVLG.cjs');
|
|
8
9
|
var chunkEG74VBSP_cjs = require('./chunk-EG74VBSP.cjs');
|
|
9
10
|
var chunkO44MSFMZ_cjs = require('./chunk-O44MSFMZ.cjs');
|
|
10
|
-
var chunkLABUWBKX_cjs = require('./chunk-LABUWBKX.cjs');
|
|
11
11
|
var chunkRWTSGWWL_cjs = require('./chunk-RWTSGWWL.cjs');
|
|
12
12
|
var api = require('@opentelemetry/api');
|
|
13
13
|
var zod = require('zod');
|
|
@@ -209,13 +209,13 @@ exports.Agent = class Agent extends (_a = chunkEG74VBSP_cjs.MastraBase) {
|
|
|
209
209
|
if (typeof this.#tools === "function") {
|
|
210
210
|
throw new Error("Tools are not compatible when tools are a function. Please use getTools() instead.");
|
|
211
211
|
}
|
|
212
|
-
return
|
|
212
|
+
return chunkEJITEVAB_cjs.ensureToolProperties(this.#tools);
|
|
213
213
|
}
|
|
214
214
|
getTools({
|
|
215
215
|
runtimeContext = new chunkLABUWBKX_cjs.RuntimeContext()
|
|
216
216
|
} = {}) {
|
|
217
217
|
if (typeof this.#tools !== "function") {
|
|
218
|
-
return
|
|
218
|
+
return chunkEJITEVAB_cjs.ensureToolProperties(this.#tools);
|
|
219
219
|
}
|
|
220
220
|
const result = this.#tools({
|
|
221
221
|
runtimeContext
|
|
@@ -225,7 +225,7 @@ exports.Agent = class Agent extends (_a = chunkEG74VBSP_cjs.MastraBase) {
|
|
|
225
225
|
this.logger.error(`[Agent:${this.name}] - Function-based tools returned empty value`);
|
|
226
226
|
throw new Error("Tools are required when using a function to provide them. The function returned an empty value.");
|
|
227
227
|
}
|
|
228
|
-
return
|
|
228
|
+
return chunkEJITEVAB_cjs.ensureToolProperties(tools);
|
|
229
229
|
});
|
|
230
230
|
}
|
|
231
231
|
get llm() {
|
|
@@ -247,7 +247,7 @@ exports.Agent = class Agent extends (_a = chunkEG74VBSP_cjs.MastraBase) {
|
|
|
247
247
|
runtimeContext
|
|
248
248
|
});
|
|
249
249
|
return resolveMaybePromise(model, model2 => {
|
|
250
|
-
const llm = new
|
|
250
|
+
const llm = new chunkXRGDVLM4_cjs.MastraLLM({
|
|
251
251
|
model: model2,
|
|
252
252
|
mastra: this.#mastra
|
|
253
253
|
});
|
|
@@ -386,7 +386,7 @@ exports.Agent = class Agent extends (_a = chunkEG74VBSP_cjs.MastraBase) {
|
|
|
386
386
|
messages: userMessages
|
|
387
387
|
};
|
|
388
388
|
}
|
|
389
|
-
const newMessages =
|
|
389
|
+
const newMessages = chunkEJITEVAB_cjs.ensureAllMessagesAreCoreMessages(userMessages);
|
|
390
390
|
const now = Date.now();
|
|
391
391
|
const messages = newMessages.map((u, index) => {
|
|
392
392
|
return {
|
|
@@ -638,7 +638,7 @@ exports.Agent = class Agent extends (_a = chunkEG74VBSP_cjs.MastraBase) {
|
|
|
638
638
|
runtimeContext
|
|
639
639
|
}) : this.model
|
|
640
640
|
};
|
|
641
|
-
return [k,
|
|
641
|
+
return [k, chunkEJITEVAB_cjs.makeCoreTool(tool, options)];
|
|
642
642
|
}));
|
|
643
643
|
const assignedToolEntriesConverted = Object.fromEntries(assignedCoreToolEntries.filter(entry => Boolean(entry)));
|
|
644
644
|
toolsForRequest = {
|
|
@@ -678,7 +678,7 @@ exports.Agent = class Agent extends (_a = chunkEG74VBSP_cjs.MastraBase) {
|
|
|
678
678
|
runtimeContext
|
|
679
679
|
}) : this.model
|
|
680
680
|
};
|
|
681
|
-
const convertedToCoreTool =
|
|
681
|
+
const convertedToCoreTool = chunkEJITEVAB_cjs.makeCoreTool(toolObj, options, "toolset");
|
|
682
682
|
toolsForRequest[toolName] = convertedToCoreTool;
|
|
683
683
|
}
|
|
684
684
|
}
|
|
@@ -719,7 +719,7 @@ exports.Agent = class Agent extends (_a = chunkEG74VBSP_cjs.MastraBase) {
|
|
|
719
719
|
runtimeContext
|
|
720
720
|
}) : this.model
|
|
721
721
|
};
|
|
722
|
-
const convertedToCoreTool =
|
|
722
|
+
const convertedToCoreTool = chunkEJITEVAB_cjs.makeCoreTool(rest, options, "client-tool");
|
|
723
723
|
toolsForRequest[toolName] = convertedToCoreTool;
|
|
724
724
|
}
|
|
725
725
|
}
|
|
@@ -786,7 +786,7 @@ exports.Agent = class Agent extends (_a = chunkEG74VBSP_cjs.MastraBase) {
|
|
|
786
786
|
let mastraProxy = void 0;
|
|
787
787
|
const logger = this.logger;
|
|
788
788
|
if (this.#mastra) {
|
|
789
|
-
mastraProxy =
|
|
789
|
+
mastraProxy = chunkEJITEVAB_cjs.createMastraProxy({
|
|
790
790
|
mastra: this.#mastra,
|
|
791
791
|
logger
|
|
792
792
|
});
|
|
@@ -994,7 +994,7 @@ exports.Agent = class Agent extends (_a = chunkEG74VBSP_cjs.MastraBase) {
|
|
|
994
994
|
try {
|
|
995
995
|
const userMessage = this.getMostRecentUserMessage(messages);
|
|
996
996
|
const now = Date.now();
|
|
997
|
-
const threadMessages = this.sanitizeResponseMessages(
|
|
997
|
+
const threadMessages = this.sanitizeResponseMessages(chunkEJITEVAB_cjs.ensureAllMessagesAreCoreMessages(messages)).map((u, index) => {
|
|
998
998
|
return {
|
|
999
999
|
id: `id` in u && u.id || experimental_generateMessageId ? experimental_generateMessageId() : this.getMemory()?.generateId(),
|
|
1000
1000
|
createdAt: new Date(now + index),
|
|
@@ -2078,7 +2078,7 @@ var Machine = class extends EventEmitter__default.default {
|
|
|
2078
2078
|
const logger = this.logger;
|
|
2079
2079
|
let mastraProxy = void 0;
|
|
2080
2080
|
if (this.#mastra) {
|
|
2081
|
-
mastraProxy =
|
|
2081
|
+
mastraProxy = chunkEJITEVAB_cjs.createMastraProxy({
|
|
2082
2082
|
mastra: this.#mastra,
|
|
2083
2083
|
logger
|
|
2084
2084
|
});
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { LibSQLVector } from './chunk-4WABQORE.js';
|
|
2
2
|
import { DefaultProxyStorage, augmentWithInit } from './chunk-CTKNWYK2.js';
|
|
3
|
-
import { deepMerge } from './chunk-
|
|
3
|
+
import { deepMerge } from './chunk-S34QVMKE.js';
|
|
4
4
|
import { MastraBase } from './chunk-235X76GC.js';
|
|
5
5
|
import { existsSync } from 'fs';
|
|
6
6
|
import { join } from 'path';
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { DefaultVoice } from './chunk-NOPY74PV.js';
|
|
2
|
-
import {
|
|
3
|
-
import { MastraLLM } from './chunk-6DIL4BTD.js';
|
|
2
|
+
import { MastraLLM } from './chunk-WIKOYZ63.js';
|
|
4
3
|
import { InstrumentClass } from './chunk-BFNYQFG2.js';
|
|
5
|
-
import { ensureToolProperties, ensureAllMessagesAreCoreMessages, makeCoreTool, createMastraProxy } from './chunk-
|
|
4
|
+
import { ensureToolProperties, ensureAllMessagesAreCoreMessages, makeCoreTool, createMastraProxy } from './chunk-S34QVMKE.js';
|
|
5
|
+
import { RuntimeContext } from './chunk-SGGPJWRQ.js';
|
|
6
|
+
import { executeHook } from './chunk-BB4KXGBU.js';
|
|
6
7
|
import { MastraBase } from './chunk-235X76GC.js';
|
|
7
8
|
import { RegisteredLogger } from './chunk-CMPPXW4U.js';
|
|
8
|
-
import { RuntimeContext } from './chunk-SGGPJWRQ.js';
|
|
9
9
|
import { __decoratorStart, __decorateElement, __runInitializers } from './chunk-C6A6W6XS.js';
|
|
10
10
|
import { context, trace } from '@opentelemetry/api';
|
|
11
11
|
import { z } from 'zod';
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
var chunkQDAMIZY3_cjs = require('./chunk-QDAMIZY3.cjs');
|
|
4
4
|
var chunkRAQBTCIR_cjs = require('./chunk-RAQBTCIR.cjs');
|
|
5
|
-
var
|
|
5
|
+
var chunkEJITEVAB_cjs = require('./chunk-EJITEVAB.cjs');
|
|
6
6
|
var chunkEG74VBSP_cjs = require('./chunk-EG74VBSP.cjs');
|
|
7
7
|
var fs = require('fs');
|
|
8
8
|
var path = require('path');
|
|
@@ -472,7 +472,7 @@ Do:
|
|
|
472
472
|
return { indexName };
|
|
473
473
|
}
|
|
474
474
|
getMergedThreadConfig(config) {
|
|
475
|
-
return
|
|
475
|
+
return chunkEJITEVAB_cjs.deepMerge(this.threadConfig, config || {});
|
|
476
476
|
}
|
|
477
477
|
/**
|
|
478
478
|
* Apply all configured message processors to a list of messages.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var chunk66GQROSI_cjs = require('./chunk-66GQROSI.cjs');
|
|
4
4
|
var cohereAi = require('cohere-ai');
|
|
5
5
|
|
|
6
6
|
var CohereRelevanceScorer = class {
|
|
@@ -38,7 +38,7 @@ Relevance score (0-1):`;
|
|
|
38
38
|
var MastraAgentRelevanceScorer = class {
|
|
39
39
|
agent;
|
|
40
40
|
constructor(name, model) {
|
|
41
|
-
this.agent = new
|
|
41
|
+
this.agent = new chunk66GQROSI_cjs.Agent({
|
|
42
42
|
name: `Relevance Scorer ${name}`,
|
|
43
43
|
instructions: `You are a specialized agent for evaluating the relevance of text to queries.
|
|
44
44
|
Your task is to rate how well a text passage answers a given query.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { delay } from './chunk-
|
|
1
|
+
import { delay } from './chunk-S34QVMKE.js';
|
|
2
2
|
import { MastraBase } from './chunk-235X76GC.js';
|
|
3
3
|
import { RegisteredLogger } from './chunk-CMPPXW4U.js';
|
|
4
4
|
import { jsonSchema, generateText, Output, generateObject, streamText, streamObject } from 'ai';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var chunkEJITEVAB_cjs = require('./chunk-EJITEVAB.cjs');
|
|
4
4
|
var chunkEG74VBSP_cjs = require('./chunk-EG74VBSP.cjs');
|
|
5
5
|
var chunkO44MSFMZ_cjs = require('./chunk-O44MSFMZ.cjs');
|
|
6
6
|
var ai = require('ai');
|
|
@@ -162,7 +162,7 @@ var MastraLLM = class extends MastraLLMBase {
|
|
|
162
162
|
});
|
|
163
163
|
if (props?.response?.headers?.["x-ratelimit-remaining-tokens"] && parseInt(props?.response?.headers?.["x-ratelimit-remaining-tokens"], 10) < 2e3) {
|
|
164
164
|
this.logger.warn("Rate limit approaching, waiting 10 seconds", { runId });
|
|
165
|
-
await
|
|
165
|
+
await chunkEJITEVAB_cjs.delay(10 * 1e3);
|
|
166
166
|
}
|
|
167
167
|
},
|
|
168
168
|
...rest
|
|
@@ -231,7 +231,7 @@ var MastraLLM = class extends MastraLLMBase {
|
|
|
231
231
|
});
|
|
232
232
|
if (props?.response?.headers?.["x-ratelimit-remaining-tokens"] && parseInt(props?.response?.headers?.["x-ratelimit-remaining-tokens"], 10) < 2e3) {
|
|
233
233
|
this.logger.warn("Rate limit approaching, waiting 10 seconds", { runId });
|
|
234
|
-
await
|
|
234
|
+
await chunkEJITEVAB_cjs.delay(10 * 1e3);
|
|
235
235
|
}
|
|
236
236
|
},
|
|
237
237
|
...rest
|
|
@@ -304,7 +304,7 @@ var MastraLLM = class extends MastraLLMBase {
|
|
|
304
304
|
});
|
|
305
305
|
if (props?.response?.headers?.["x-ratelimit-remaining-tokens"] && parseInt(props?.response?.headers?.["x-ratelimit-remaining-tokens"], 10) < 2e3) {
|
|
306
306
|
this.logger.warn("Rate limit approaching, waiting 10 seconds", { runId });
|
|
307
|
-
await
|
|
307
|
+
await chunkEJITEVAB_cjs.delay(10 * 1e3);
|
|
308
308
|
}
|
|
309
309
|
},
|
|
310
310
|
onFinish: async (props) => {
|
|
@@ -395,7 +395,7 @@ var MastraLLM = class extends MastraLLMBase {
|
|
|
395
395
|
});
|
|
396
396
|
if (props?.response?.headers?.["x-ratelimit-remaining-tokens"] && parseInt(props?.response?.headers?.["x-ratelimit-remaining-tokens"], 10) < 2e3) {
|
|
397
397
|
this.logger.warn("Rate limit approaching, waiting 10 seconds", { runId });
|
|
398
|
-
await
|
|
398
|
+
await chunkEJITEVAB_cjs.delay(10 * 1e3);
|
|
399
399
|
}
|
|
400
400
|
},
|
|
401
401
|
onFinish: async (props) => {
|
package/dist/index.cjs
CHANGED
|
@@ -1,24 +1,24 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
+
var chunkWE36CRQV_cjs = require('./chunk-WE36CRQV.cjs');
|
|
3
4
|
var chunkV2Q2FEVO_cjs = require('./chunk-V2Q2FEVO.cjs');
|
|
4
|
-
var
|
|
5
|
-
var chunk3C6V2FEP_cjs = require('./chunk-3C6V2FEP.cjs');
|
|
6
|
-
var chunkHAENAPIH_cjs = require('./chunk-HAENAPIH.cjs');
|
|
5
|
+
var chunk5JUWUTPJ_cjs = require('./chunk-5JUWUTPJ.cjs');
|
|
7
6
|
var chunkMUNFCOMB_cjs = require('./chunk-MUNFCOMB.cjs');
|
|
8
7
|
var chunkGXKODTLA_cjs = require('./chunk-GXKODTLA.cjs');
|
|
9
|
-
var
|
|
8
|
+
var chunkQHDPLMHB_cjs = require('./chunk-QHDPLMHB.cjs');
|
|
10
9
|
var chunkWQKOM7XM_cjs = require('./chunk-WQKOM7XM.cjs');
|
|
11
10
|
var chunk5DUFC7TV_cjs = require('./chunk-5DUFC7TV.cjs');
|
|
12
|
-
var
|
|
13
|
-
var chunkST5RMVLG_cjs = require('./chunk-ST5RMVLG.cjs');
|
|
11
|
+
var chunk66GQROSI_cjs = require('./chunk-66GQROSI.cjs');
|
|
14
12
|
var chunkUVRGQEMD_cjs = require('./chunk-UVRGQEMD.cjs');
|
|
15
|
-
var
|
|
13
|
+
var chunkEJITEVAB_cjs = require('./chunk-EJITEVAB.cjs');
|
|
14
|
+
var chunk3C6V2FEP_cjs = require('./chunk-3C6V2FEP.cjs');
|
|
15
|
+
var chunkST5RMVLG_cjs = require('./chunk-ST5RMVLG.cjs');
|
|
16
16
|
var chunkE4FAXBUV_cjs = require('./chunk-E4FAXBUV.cjs');
|
|
17
17
|
var chunkEG74VBSP_cjs = require('./chunk-EG74VBSP.cjs');
|
|
18
18
|
var chunkO44MSFMZ_cjs = require('./chunk-O44MSFMZ.cjs');
|
|
19
19
|
|
|
20
20
|
// src/agent/index.warning.ts
|
|
21
|
-
var Agent2 = class extends
|
|
21
|
+
var Agent2 = class extends chunk66GQROSI_cjs.Agent {
|
|
22
22
|
constructor(config) {
|
|
23
23
|
super(config);
|
|
24
24
|
this.logger.warn('Please import "Agent from "@mastra/core/agent" instead of "@mastra/core"');
|
|
@@ -52,7 +52,7 @@ var MastraStorage2 = class extends chunk5DUFC7TV_cjs.MastraStorage {
|
|
|
52
52
|
};
|
|
53
53
|
|
|
54
54
|
// src/integration/integration.warning.ts
|
|
55
|
-
var Integration2 = class extends
|
|
55
|
+
var Integration2 = class extends chunk5JUWUTPJ_cjs.Integration {
|
|
56
56
|
constructor() {
|
|
57
57
|
super();
|
|
58
58
|
console.warn('Please import "Integration" from "@mastra/core/integration" instead of "@mastra/core"');
|
|
@@ -60,7 +60,7 @@ var Integration2 = class extends chunkHAENAPIH_cjs.Integration {
|
|
|
60
60
|
};
|
|
61
61
|
|
|
62
62
|
// src/integration/openapi-toolset.warning.ts
|
|
63
|
-
var OpenAPIToolset2 = class extends
|
|
63
|
+
var OpenAPIToolset2 = class extends chunk5JUWUTPJ_cjs.OpenAPIToolset {
|
|
64
64
|
constructor() {
|
|
65
65
|
super();
|
|
66
66
|
console.warn('Please import "OpenAPIToolset" from "@mastra/core/integration" instead of "@mastra/core"');
|
|
@@ -74,7 +74,7 @@ function createLogger2(options) {
|
|
|
74
74
|
}
|
|
75
75
|
|
|
76
76
|
// src/memory/index.warning.ts
|
|
77
|
-
var MastraMemory2 = class extends
|
|
77
|
+
var MastraMemory2 = class extends chunkQHDPLMHB_cjs.MastraMemory {
|
|
78
78
|
constructor(_arg) {
|
|
79
79
|
super({ name: `Deprecated memory` });
|
|
80
80
|
this.logger.warn('Please import "MastraMemory" from "@mastra/core/memory" instead of "@mastra/core"');
|
|
@@ -82,7 +82,7 @@ var MastraMemory2 = class extends chunk24TNYZQE_cjs.MastraMemory {
|
|
|
82
82
|
};
|
|
83
83
|
|
|
84
84
|
// src/tools/index.warning.ts
|
|
85
|
-
var Tool2 = class extends
|
|
85
|
+
var Tool2 = class extends chunkEJITEVAB_cjs.Tool {
|
|
86
86
|
constructor(opts) {
|
|
87
87
|
super(opts);
|
|
88
88
|
console.warn('Please import "Tool" from "@mastra/core/tools" instead of "@mastra/core"');
|
|
@@ -106,7 +106,7 @@ var MastraVector2 = class extends chunkWQKOM7XM_cjs.MastraVector {
|
|
|
106
106
|
};
|
|
107
107
|
|
|
108
108
|
// src/workflows/workflow.warning.ts
|
|
109
|
-
var Workflow2 = class extends
|
|
109
|
+
var Workflow2 = class extends chunk66GQROSI_cjs.Workflow {
|
|
110
110
|
constructor(args) {
|
|
111
111
|
super(args);
|
|
112
112
|
this.logger.warn('Please import "Workflow" from "@mastra/core/workflows" instead of "@mastra/core"');
|
|
@@ -115,23 +115,15 @@ var Workflow2 = class extends chunkKZGB62K2_cjs.Workflow {
|
|
|
115
115
|
|
|
116
116
|
Object.defineProperty(exports, "CohereRelevanceScorer", {
|
|
117
117
|
enumerable: true,
|
|
118
|
-
get: function () { return
|
|
118
|
+
get: function () { return chunkWE36CRQV_cjs.CohereRelevanceScorer; }
|
|
119
119
|
});
|
|
120
120
|
Object.defineProperty(exports, "MastraAgentRelevanceScorer", {
|
|
121
121
|
enumerable: true,
|
|
122
|
-
get: function () { return
|
|
122
|
+
get: function () { return chunkWE36CRQV_cjs.MastraAgentRelevanceScorer; }
|
|
123
123
|
});
|
|
124
124
|
Object.defineProperty(exports, "createSimilarityPrompt", {
|
|
125
125
|
enumerable: true,
|
|
126
|
-
get: function () { return
|
|
127
|
-
});
|
|
128
|
-
Object.defineProperty(exports, "Metric", {
|
|
129
|
-
enumerable: true,
|
|
130
|
-
get: function () { return chunk3C6V2FEP_cjs.Metric; }
|
|
131
|
-
});
|
|
132
|
-
Object.defineProperty(exports, "evaluate", {
|
|
133
|
-
enumerable: true,
|
|
134
|
-
get: function () { return chunk3C6V2FEP_cjs.evaluate; }
|
|
126
|
+
get: function () { return chunkWE36CRQV_cjs.createSimilarityPrompt; }
|
|
135
127
|
});
|
|
136
128
|
Object.defineProperty(exports, "createMockModel", {
|
|
137
129
|
enumerable: true,
|
|
@@ -143,103 +135,91 @@ Object.defineProperty(exports, "Mastra", {
|
|
|
143
135
|
});
|
|
144
136
|
Object.defineProperty(exports, "MemoryProcessor", {
|
|
145
137
|
enumerable: true,
|
|
146
|
-
get: function () { return
|
|
138
|
+
get: function () { return chunkQHDPLMHB_cjs.MemoryProcessor; }
|
|
147
139
|
});
|
|
148
140
|
Object.defineProperty(exports, "memoryDefaultOptions", {
|
|
149
141
|
enumerable: true,
|
|
150
|
-
get: function () { return
|
|
142
|
+
get: function () { return chunkQHDPLMHB_cjs.memoryDefaultOptions; }
|
|
151
143
|
});
|
|
152
144
|
Object.defineProperty(exports, "Step", {
|
|
153
145
|
enumerable: true,
|
|
154
|
-
get: function () { return
|
|
146
|
+
get: function () { return chunk66GQROSI_cjs.Step; }
|
|
155
147
|
});
|
|
156
148
|
Object.defineProperty(exports, "WhenConditionReturnValue", {
|
|
157
149
|
enumerable: true,
|
|
158
|
-
get: function () { return
|
|
150
|
+
get: function () { return chunk66GQROSI_cjs.WhenConditionReturnValue; }
|
|
159
151
|
});
|
|
160
152
|
Object.defineProperty(exports, "agentToStep", {
|
|
161
153
|
enumerable: true,
|
|
162
|
-
get: function () { return
|
|
154
|
+
get: function () { return chunk66GQROSI_cjs.agentToStep; }
|
|
163
155
|
});
|
|
164
156
|
Object.defineProperty(exports, "getActivePathsAndStatus", {
|
|
165
157
|
enumerable: true,
|
|
166
|
-
get: function () { return
|
|
158
|
+
get: function () { return chunk66GQROSI_cjs.getActivePathsAndStatus; }
|
|
167
159
|
});
|
|
168
160
|
Object.defineProperty(exports, "getResultActivePaths", {
|
|
169
161
|
enumerable: true,
|
|
170
|
-
get: function () { return
|
|
162
|
+
get: function () { return chunk66GQROSI_cjs.getResultActivePaths; }
|
|
171
163
|
});
|
|
172
164
|
Object.defineProperty(exports, "getStepResult", {
|
|
173
165
|
enumerable: true,
|
|
174
|
-
get: function () { return
|
|
166
|
+
get: function () { return chunk66GQROSI_cjs.getStepResult; }
|
|
175
167
|
});
|
|
176
168
|
Object.defineProperty(exports, "getSuspendedPaths", {
|
|
177
169
|
enumerable: true,
|
|
178
|
-
get: function () { return
|
|
170
|
+
get: function () { return chunk66GQROSI_cjs.getSuspendedPaths; }
|
|
179
171
|
});
|
|
180
172
|
Object.defineProperty(exports, "isAgent", {
|
|
181
173
|
enumerable: true,
|
|
182
|
-
get: function () { return
|
|
174
|
+
get: function () { return chunk66GQROSI_cjs.isAgent; }
|
|
183
175
|
});
|
|
184
176
|
Object.defineProperty(exports, "isConditionalKey", {
|
|
185
177
|
enumerable: true,
|
|
186
|
-
get: function () { return
|
|
178
|
+
get: function () { return chunk66GQROSI_cjs.isConditionalKey; }
|
|
187
179
|
});
|
|
188
180
|
Object.defineProperty(exports, "isErrorEvent", {
|
|
189
181
|
enumerable: true,
|
|
190
|
-
get: function () { return
|
|
182
|
+
get: function () { return chunk66GQROSI_cjs.isErrorEvent; }
|
|
191
183
|
});
|
|
192
184
|
Object.defineProperty(exports, "isFinalState", {
|
|
193
185
|
enumerable: true,
|
|
194
|
-
get: function () { return
|
|
186
|
+
get: function () { return chunk66GQROSI_cjs.isFinalState; }
|
|
195
187
|
});
|
|
196
188
|
Object.defineProperty(exports, "isLimboState", {
|
|
197
189
|
enumerable: true,
|
|
198
|
-
get: function () { return
|
|
190
|
+
get: function () { return chunk66GQROSI_cjs.isLimboState; }
|
|
199
191
|
});
|
|
200
192
|
Object.defineProperty(exports, "isTransitionEvent", {
|
|
201
193
|
enumerable: true,
|
|
202
|
-
get: function () { return
|
|
194
|
+
get: function () { return chunk66GQROSI_cjs.isTransitionEvent; }
|
|
203
195
|
});
|
|
204
196
|
Object.defineProperty(exports, "isVariableReference", {
|
|
205
197
|
enumerable: true,
|
|
206
|
-
get: function () { return
|
|
198
|
+
get: function () { return chunk66GQROSI_cjs.isVariableReference; }
|
|
207
199
|
});
|
|
208
200
|
Object.defineProperty(exports, "isWorkflow", {
|
|
209
201
|
enumerable: true,
|
|
210
|
-
get: function () { return
|
|
202
|
+
get: function () { return chunk66GQROSI_cjs.isWorkflow; }
|
|
211
203
|
});
|
|
212
204
|
Object.defineProperty(exports, "mergeChildValue", {
|
|
213
205
|
enumerable: true,
|
|
214
|
-
get: function () { return
|
|
206
|
+
get: function () { return chunk66GQROSI_cjs.mergeChildValue; }
|
|
215
207
|
});
|
|
216
208
|
Object.defineProperty(exports, "recursivelyCheckForFinalState", {
|
|
217
209
|
enumerable: true,
|
|
218
|
-
get: function () { return
|
|
210
|
+
get: function () { return chunk66GQROSI_cjs.recursivelyCheckForFinalState; }
|
|
219
211
|
});
|
|
220
212
|
Object.defineProperty(exports, "resolveVariables", {
|
|
221
213
|
enumerable: true,
|
|
222
|
-
get: function () { return
|
|
214
|
+
get: function () { return chunk66GQROSI_cjs.resolveVariables; }
|
|
223
215
|
});
|
|
224
216
|
Object.defineProperty(exports, "updateStepInHierarchy", {
|
|
225
217
|
enumerable: true,
|
|
226
|
-
get: function () { return
|
|
218
|
+
get: function () { return chunk66GQROSI_cjs.updateStepInHierarchy; }
|
|
227
219
|
});
|
|
228
220
|
Object.defineProperty(exports, "workflowToStep", {
|
|
229
221
|
enumerable: true,
|
|
230
|
-
get: function () { return
|
|
231
|
-
});
|
|
232
|
-
Object.defineProperty(exports, "AvailableHooks", {
|
|
233
|
-
enumerable: true,
|
|
234
|
-
get: function () { return chunkST5RMVLG_cjs.AvailableHooks; }
|
|
235
|
-
});
|
|
236
|
-
Object.defineProperty(exports, "executeHook", {
|
|
237
|
-
enumerable: true,
|
|
238
|
-
get: function () { return chunkST5RMVLG_cjs.executeHook; }
|
|
239
|
-
});
|
|
240
|
-
Object.defineProperty(exports, "registerHook", {
|
|
241
|
-
enumerable: true,
|
|
242
|
-
get: function () { return chunkST5RMVLG_cjs.registerHook; }
|
|
222
|
+
get: function () { return chunk66GQROSI_cjs.workflowToStep; }
|
|
243
223
|
});
|
|
244
224
|
Object.defineProperty(exports, "InstrumentClass", {
|
|
245
225
|
enumerable: true,
|
|
@@ -267,51 +247,71 @@ Object.defineProperty(exports, "withSpan", {
|
|
|
267
247
|
});
|
|
268
248
|
Object.defineProperty(exports, "checkEvalStorageFields", {
|
|
269
249
|
enumerable: true,
|
|
270
|
-
get: function () { return
|
|
250
|
+
get: function () { return chunkEJITEVAB_cjs.checkEvalStorageFields; }
|
|
271
251
|
});
|
|
272
252
|
Object.defineProperty(exports, "createMastraProxy", {
|
|
273
253
|
enumerable: true,
|
|
274
|
-
get: function () { return
|
|
254
|
+
get: function () { return chunkEJITEVAB_cjs.createMastraProxy; }
|
|
275
255
|
});
|
|
276
256
|
Object.defineProperty(exports, "createTool", {
|
|
277
257
|
enumerable: true,
|
|
278
|
-
get: function () { return
|
|
258
|
+
get: function () { return chunkEJITEVAB_cjs.createTool; }
|
|
279
259
|
});
|
|
280
260
|
Object.defineProperty(exports, "deepMerge", {
|
|
281
261
|
enumerable: true,
|
|
282
|
-
get: function () { return
|
|
262
|
+
get: function () { return chunkEJITEVAB_cjs.deepMerge; }
|
|
283
263
|
});
|
|
284
264
|
Object.defineProperty(exports, "delay", {
|
|
285
265
|
enumerable: true,
|
|
286
|
-
get: function () { return
|
|
266
|
+
get: function () { return chunkEJITEVAB_cjs.delay; }
|
|
287
267
|
});
|
|
288
268
|
Object.defineProperty(exports, "ensureAllMessagesAreCoreMessages", {
|
|
289
269
|
enumerable: true,
|
|
290
|
-
get: function () { return
|
|
270
|
+
get: function () { return chunkEJITEVAB_cjs.ensureAllMessagesAreCoreMessages; }
|
|
291
271
|
});
|
|
292
272
|
Object.defineProperty(exports, "ensureToolProperties", {
|
|
293
273
|
enumerable: true,
|
|
294
|
-
get: function () { return
|
|
274
|
+
get: function () { return chunkEJITEVAB_cjs.ensureToolProperties; }
|
|
295
275
|
});
|
|
296
276
|
Object.defineProperty(exports, "isVercelTool", {
|
|
297
277
|
enumerable: true,
|
|
298
|
-
get: function () { return
|
|
278
|
+
get: function () { return chunkEJITEVAB_cjs.isVercelTool; }
|
|
299
279
|
});
|
|
300
280
|
Object.defineProperty(exports, "isZodType", {
|
|
301
281
|
enumerable: true,
|
|
302
|
-
get: function () { return
|
|
282
|
+
get: function () { return chunkEJITEVAB_cjs.isZodType; }
|
|
303
283
|
});
|
|
304
284
|
Object.defineProperty(exports, "makeCoreTool", {
|
|
305
285
|
enumerable: true,
|
|
306
|
-
get: function () { return
|
|
286
|
+
get: function () { return chunkEJITEVAB_cjs.makeCoreTool; }
|
|
307
287
|
});
|
|
308
288
|
Object.defineProperty(exports, "maskStreamTags", {
|
|
309
289
|
enumerable: true,
|
|
310
|
-
get: function () { return
|
|
290
|
+
get: function () { return chunkEJITEVAB_cjs.maskStreamTags; }
|
|
311
291
|
});
|
|
312
292
|
Object.defineProperty(exports, "resolveSerializedZodOutput", {
|
|
313
293
|
enumerable: true,
|
|
314
|
-
get: function () { return
|
|
294
|
+
get: function () { return chunkEJITEVAB_cjs.resolveSerializedZodOutput; }
|
|
295
|
+
});
|
|
296
|
+
Object.defineProperty(exports, "Metric", {
|
|
297
|
+
enumerable: true,
|
|
298
|
+
get: function () { return chunk3C6V2FEP_cjs.Metric; }
|
|
299
|
+
});
|
|
300
|
+
Object.defineProperty(exports, "evaluate", {
|
|
301
|
+
enumerable: true,
|
|
302
|
+
get: function () { return chunk3C6V2FEP_cjs.evaluate; }
|
|
303
|
+
});
|
|
304
|
+
Object.defineProperty(exports, "AvailableHooks", {
|
|
305
|
+
enumerable: true,
|
|
306
|
+
get: function () { return chunkST5RMVLG_cjs.AvailableHooks; }
|
|
307
|
+
});
|
|
308
|
+
Object.defineProperty(exports, "executeHook", {
|
|
309
|
+
enumerable: true,
|
|
310
|
+
get: function () { return chunkST5RMVLG_cjs.executeHook; }
|
|
311
|
+
});
|
|
312
|
+
Object.defineProperty(exports, "registerHook", {
|
|
313
|
+
enumerable: true,
|
|
314
|
+
get: function () { return chunkST5RMVLG_cjs.registerHook; }
|
|
315
315
|
});
|
|
316
316
|
Object.defineProperty(exports, "LogLevel", {
|
|
317
317
|
enumerable: true,
|
package/dist/index.js
CHANGED
|
@@ -1,19 +1,19 @@
|
|
|
1
|
+
export { CohereRelevanceScorer, MastraAgentRelevanceScorer, createSimilarityPrompt } from './chunk-H4CEZSRM.js';
|
|
1
2
|
import { MastraTTS } from './chunk-JBJ7KXN5.js';
|
|
2
|
-
|
|
3
|
-
export { Metric, evaluate } from './chunk-PK5QRKSG.js';
|
|
4
|
-
import { Integration, OpenAPIToolset } from './chunk-XR75VNNH.js';
|
|
3
|
+
import { Integration, OpenAPIToolset } from './chunk-PEK4TY3P.js';
|
|
5
4
|
export { createMockModel } from './chunk-HNEE7IF4.js';
|
|
6
5
|
export { Mastra } from './chunk-SOLXHDNQ.js';
|
|
7
|
-
import { MastraMemory } from './chunk-
|
|
8
|
-
export { MemoryProcessor, memoryDefaultOptions } from './chunk-
|
|
6
|
+
import { MastraMemory } from './chunk-CIEPFV6B.js';
|
|
7
|
+
export { MemoryProcessor, memoryDefaultOptions } from './chunk-CIEPFV6B.js';
|
|
9
8
|
import { MastraVector } from './chunk-NZV4OA6P.js';
|
|
10
9
|
import { MastraStorage } from './chunk-TAFOICHR.js';
|
|
11
|
-
import { Agent, Workflow } from './chunk-
|
|
12
|
-
export { Step, WhenConditionReturnValue, agentToStep, getActivePathsAndStatus, getResultActivePaths, getStepResult, getSuspendedPaths, isAgent, isConditionalKey, isErrorEvent, isFinalState, isLimboState, isTransitionEvent, isVariableReference, isWorkflow, mergeChildValue, recursivelyCheckForFinalState, resolveVariables, updateStepInHierarchy, workflowToStep } from './chunk-
|
|
13
|
-
export { AvailableHooks, executeHook, registerHook } from './chunk-BB4KXGBU.js';
|
|
10
|
+
import { Agent, Workflow } from './chunk-FW5RS6WV.js';
|
|
11
|
+
export { Step, WhenConditionReturnValue, agentToStep, getActivePathsAndStatus, getResultActivePaths, getStepResult, getSuspendedPaths, isAgent, isConditionalKey, isErrorEvent, isFinalState, isLimboState, isTransitionEvent, isVariableReference, isWorkflow, mergeChildValue, recursivelyCheckForFinalState, resolveVariables, updateStepInHierarchy, workflowToStep } from './chunk-FW5RS6WV.js';
|
|
14
12
|
export { InstrumentClass, OTLPTraceExporter as OTLPStorageExporter, Telemetry, getBaggageValues, hasActiveTelemetry, withSpan } from './chunk-BFNYQFG2.js';
|
|
15
|
-
import { Tool } from './chunk-
|
|
16
|
-
export { checkEvalStorageFields, createMastraProxy, createTool, deepMerge, delay, ensureAllMessagesAreCoreMessages, ensureToolProperties, isVercelTool, isZodType, makeCoreTool, maskStreamTags, resolveSerializedZodOutput } from './chunk-
|
|
13
|
+
import { Tool } from './chunk-S34QVMKE.js';
|
|
14
|
+
export { checkEvalStorageFields, createMastraProxy, createTool, deepMerge, delay, ensureAllMessagesAreCoreMessages, ensureToolProperties, isVercelTool, isZodType, makeCoreTool, maskStreamTags, resolveSerializedZodOutput } from './chunk-S34QVMKE.js';
|
|
15
|
+
export { Metric, evaluate } from './chunk-PK5QRKSG.js';
|
|
16
|
+
export { AvailableHooks, executeHook, registerHook } from './chunk-BB4KXGBU.js';
|
|
17
17
|
import { MastraDeployer } from './chunk-W4BSLENO.js';
|
|
18
18
|
import { MastraBase } from './chunk-235X76GC.js';
|
|
19
19
|
import { createLogger } from './chunk-CMPPXW4U.js';
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var chunk5JUWUTPJ_cjs = require('../chunk-5JUWUTPJ.cjs');
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
|
|
7
7
|
Object.defineProperty(exports, "Integration", {
|
|
8
8
|
enumerable: true,
|
|
9
|
-
get: function () { return
|
|
9
|
+
get: function () { return chunk5JUWUTPJ_cjs.Integration; }
|
|
10
10
|
});
|
|
11
11
|
Object.defineProperty(exports, "OpenAPIToolset", {
|
|
12
12
|
enumerable: true,
|
|
13
|
-
get: function () { return
|
|
13
|
+
get: function () { return chunk5JUWUTPJ_cjs.OpenAPIToolset; }
|
|
14
14
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { Integration, OpenAPIToolset } from '../chunk-
|
|
1
|
+
export { Integration, OpenAPIToolset } from '../chunk-PEK4TY3P.js';
|
package/dist/memory/index.cjs
CHANGED
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var chunkQHDPLMHB_cjs = require('../chunk-QHDPLMHB.cjs');
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
|
|
7
7
|
Object.defineProperty(exports, "MastraMemory", {
|
|
8
8
|
enumerable: true,
|
|
9
|
-
get: function () { return
|
|
9
|
+
get: function () { return chunkQHDPLMHB_cjs.MastraMemory; }
|
|
10
10
|
});
|
|
11
11
|
Object.defineProperty(exports, "MemoryProcessor", {
|
|
12
12
|
enumerable: true,
|
|
13
|
-
get: function () { return
|
|
13
|
+
get: function () { return chunkQHDPLMHB_cjs.MemoryProcessor; }
|
|
14
14
|
});
|
|
15
15
|
Object.defineProperty(exports, "memoryDefaultOptions", {
|
|
16
16
|
enumerable: true,
|
|
17
|
-
get: function () { return
|
|
17
|
+
get: function () { return chunkQHDPLMHB_cjs.memoryDefaultOptions; }
|
|
18
18
|
});
|
package/dist/memory/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export { MastraMemory, MemoryProcessor, memoryDefaultOptions } from '../chunk-
|
|
1
|
+
export { MastraMemory, MemoryProcessor, memoryDefaultOptions } from '../chunk-CIEPFV6B.js';
|
package/dist/network/index.cjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
4
|
-
var
|
|
3
|
+
var chunk66GQROSI_cjs = require('../chunk-66GQROSI.cjs');
|
|
4
|
+
var chunkEJITEVAB_cjs = require('../chunk-EJITEVAB.cjs');
|
|
5
5
|
var chunkEG74VBSP_cjs = require('../chunk-EG74VBSP.cjs');
|
|
6
6
|
var chunkO44MSFMZ_cjs = require('../chunk-O44MSFMZ.cjs');
|
|
7
7
|
var zod = require('zod');
|
|
@@ -17,7 +17,7 @@ var AgentNetwork = class extends chunkEG74VBSP_cjs.MastraBase {
|
|
|
17
17
|
this.#instructions = config.instructions;
|
|
18
18
|
this.#agents = config.agents;
|
|
19
19
|
this.#model = config.model;
|
|
20
|
-
this.#routingAgent = new
|
|
20
|
+
this.#routingAgent = new chunk66GQROSI_cjs.Agent({
|
|
21
21
|
name: config.name,
|
|
22
22
|
instructions: this.getInstructions(),
|
|
23
23
|
model: this.#model,
|
|
@@ -29,7 +29,7 @@ var AgentNetwork = class extends chunkEG74VBSP_cjs.MastraBase {
|
|
|
29
29
|
}
|
|
30
30
|
getTools() {
|
|
31
31
|
return {
|
|
32
|
-
transmit:
|
|
32
|
+
transmit: chunkEJITEVAB_cjs.createTool({
|
|
33
33
|
id: "transmit",
|
|
34
34
|
description: "Call one or more specialized agents to handle specific tasks",
|
|
35
35
|
inputSchema: zod.z.object({
|
package/dist/network/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { Agent } from '../chunk-
|
|
2
|
-
import { createTool } from '../chunk-
|
|
1
|
+
import { Agent } from '../chunk-FW5RS6WV.js';
|
|
2
|
+
import { createTool } from '../chunk-S34QVMKE.js';
|
|
3
3
|
import { MastraBase } from '../chunk-235X76GC.js';
|
|
4
4
|
import { RegisteredLogger } from '../chunk-CMPPXW4U.js';
|
|
5
5
|
import { z } from 'zod';
|
package/dist/relevance/index.cjs
CHANGED
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var chunkWE36CRQV_cjs = require('../chunk-WE36CRQV.cjs');
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
|
|
7
7
|
Object.defineProperty(exports, "CohereRelevanceScorer", {
|
|
8
8
|
enumerable: true,
|
|
9
|
-
get: function () { return
|
|
9
|
+
get: function () { return chunkWE36CRQV_cjs.CohereRelevanceScorer; }
|
|
10
10
|
});
|
|
11
11
|
Object.defineProperty(exports, "MastraAgentRelevanceScorer", {
|
|
12
12
|
enumerable: true,
|
|
13
|
-
get: function () { return
|
|
13
|
+
get: function () { return chunkWE36CRQV_cjs.MastraAgentRelevanceScorer; }
|
|
14
14
|
});
|
|
15
15
|
Object.defineProperty(exports, "createSimilarityPrompt", {
|
|
16
16
|
enumerable: true,
|
|
17
|
-
get: function () { return
|
|
17
|
+
get: function () { return chunkWE36CRQV_cjs.createSimilarityPrompt; }
|
|
18
18
|
});
|
package/dist/relevance/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export { CohereRelevanceScorer, MastraAgentRelevanceScorer, createSimilarityPrompt } from '../chunk-
|
|
1
|
+
export { CohereRelevanceScorer, MastraAgentRelevanceScorer, createSimilarityPrompt } from '../chunk-H4CEZSRM.js';
|
package/dist/tools/index.cjs
CHANGED
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var chunkEJITEVAB_cjs = require('../chunk-EJITEVAB.cjs');
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
|
|
7
7
|
Object.defineProperty(exports, "Tool", {
|
|
8
8
|
enumerable: true,
|
|
9
|
-
get: function () { return
|
|
9
|
+
get: function () { return chunkEJITEVAB_cjs.Tool; }
|
|
10
10
|
});
|
|
11
11
|
Object.defineProperty(exports, "createTool", {
|
|
12
12
|
enumerable: true,
|
|
13
|
-
get: function () { return
|
|
13
|
+
get: function () { return chunkEJITEVAB_cjs.createTool; }
|
|
14
14
|
});
|
|
15
15
|
Object.defineProperty(exports, "isVercelTool", {
|
|
16
16
|
enumerable: true,
|
|
17
|
-
get: function () { return
|
|
17
|
+
get: function () { return chunkEJITEVAB_cjs.isVercelTool; }
|
|
18
18
|
});
|
package/dist/tools/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export { Tool, createTool, isVercelTool } from '../chunk-
|
|
1
|
+
export { Tool, createTool, isVercelTool } from '../chunk-S34QVMKE.js';
|
package/dist/utils.cjs
CHANGED
|
@@ -1,50 +1,50 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var chunkEJITEVAB_cjs = require('./chunk-EJITEVAB.cjs');
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
|
|
7
7
|
Object.defineProperty(exports, "checkEvalStorageFields", {
|
|
8
8
|
enumerable: true,
|
|
9
|
-
get: function () { return
|
|
9
|
+
get: function () { return chunkEJITEVAB_cjs.checkEvalStorageFields; }
|
|
10
10
|
});
|
|
11
11
|
Object.defineProperty(exports, "createMastraProxy", {
|
|
12
12
|
enumerable: true,
|
|
13
|
-
get: function () { return
|
|
13
|
+
get: function () { return chunkEJITEVAB_cjs.createMastraProxy; }
|
|
14
14
|
});
|
|
15
15
|
Object.defineProperty(exports, "deepMerge", {
|
|
16
16
|
enumerable: true,
|
|
17
|
-
get: function () { return
|
|
17
|
+
get: function () { return chunkEJITEVAB_cjs.deepMerge; }
|
|
18
18
|
});
|
|
19
19
|
Object.defineProperty(exports, "delay", {
|
|
20
20
|
enumerable: true,
|
|
21
|
-
get: function () { return
|
|
21
|
+
get: function () { return chunkEJITEVAB_cjs.delay; }
|
|
22
22
|
});
|
|
23
23
|
Object.defineProperty(exports, "ensureAllMessagesAreCoreMessages", {
|
|
24
24
|
enumerable: true,
|
|
25
|
-
get: function () { return
|
|
25
|
+
get: function () { return chunkEJITEVAB_cjs.ensureAllMessagesAreCoreMessages; }
|
|
26
26
|
});
|
|
27
27
|
Object.defineProperty(exports, "ensureToolProperties", {
|
|
28
28
|
enumerable: true,
|
|
29
|
-
get: function () { return
|
|
29
|
+
get: function () { return chunkEJITEVAB_cjs.ensureToolProperties; }
|
|
30
30
|
});
|
|
31
31
|
Object.defineProperty(exports, "isVercelTool", {
|
|
32
32
|
enumerable: true,
|
|
33
|
-
get: function () { return
|
|
33
|
+
get: function () { return chunkEJITEVAB_cjs.isVercelTool; }
|
|
34
34
|
});
|
|
35
35
|
Object.defineProperty(exports, "isZodType", {
|
|
36
36
|
enumerable: true,
|
|
37
|
-
get: function () { return
|
|
37
|
+
get: function () { return chunkEJITEVAB_cjs.isZodType; }
|
|
38
38
|
});
|
|
39
39
|
Object.defineProperty(exports, "makeCoreTool", {
|
|
40
40
|
enumerable: true,
|
|
41
|
-
get: function () { return
|
|
41
|
+
get: function () { return chunkEJITEVAB_cjs.makeCoreTool; }
|
|
42
42
|
});
|
|
43
43
|
Object.defineProperty(exports, "maskStreamTags", {
|
|
44
44
|
enumerable: true,
|
|
45
|
-
get: function () { return
|
|
45
|
+
get: function () { return chunkEJITEVAB_cjs.maskStreamTags; }
|
|
46
46
|
});
|
|
47
47
|
Object.defineProperty(exports, "resolveSerializedZodOutput", {
|
|
48
48
|
enumerable: true,
|
|
49
|
-
get: function () { return
|
|
49
|
+
get: function () { return chunkEJITEVAB_cjs.resolveSerializedZodOutput; }
|
|
50
50
|
});
|
package/dist/utils.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export { checkEvalStorageFields, createMastraProxy, deepMerge, delay, ensureAllMessagesAreCoreMessages, ensureToolProperties, isVercelTool, isZodType, makeCoreTool, maskStreamTags, resolveSerializedZodOutput } from './chunk-
|
|
1
|
+
export { checkEvalStorageFields, createMastraProxy, deepMerge, delay, ensureAllMessagesAreCoreMessages, ensureToolProperties, isVercelTool, isZodType, makeCoreTool, maskStreamTags, resolveSerializedZodOutput } from './chunk-S34QVMKE.js';
|
package/dist/workflows/index.cjs
CHANGED
|
@@ -1,90 +1,90 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var chunk66GQROSI_cjs = require('../chunk-66GQROSI.cjs');
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
|
|
7
7
|
Object.defineProperty(exports, "Step", {
|
|
8
8
|
enumerable: true,
|
|
9
|
-
get: function () { return
|
|
9
|
+
get: function () { return chunk66GQROSI_cjs.Step; }
|
|
10
10
|
});
|
|
11
11
|
Object.defineProperty(exports, "WhenConditionReturnValue", {
|
|
12
12
|
enumerable: true,
|
|
13
|
-
get: function () { return
|
|
13
|
+
get: function () { return chunk66GQROSI_cjs.WhenConditionReturnValue; }
|
|
14
14
|
});
|
|
15
15
|
Object.defineProperty(exports, "Workflow", {
|
|
16
16
|
enumerable: true,
|
|
17
|
-
get: function () { return
|
|
17
|
+
get: function () { return chunk66GQROSI_cjs.Workflow; }
|
|
18
18
|
});
|
|
19
19
|
Object.defineProperty(exports, "agentToStep", {
|
|
20
20
|
enumerable: true,
|
|
21
|
-
get: function () { return
|
|
21
|
+
get: function () { return chunk66GQROSI_cjs.agentToStep; }
|
|
22
22
|
});
|
|
23
23
|
Object.defineProperty(exports, "getActivePathsAndStatus", {
|
|
24
24
|
enumerable: true,
|
|
25
|
-
get: function () { return
|
|
25
|
+
get: function () { return chunk66GQROSI_cjs.getActivePathsAndStatus; }
|
|
26
26
|
});
|
|
27
27
|
Object.defineProperty(exports, "getResultActivePaths", {
|
|
28
28
|
enumerable: true,
|
|
29
|
-
get: function () { return
|
|
29
|
+
get: function () { return chunk66GQROSI_cjs.getResultActivePaths; }
|
|
30
30
|
});
|
|
31
31
|
Object.defineProperty(exports, "getStepResult", {
|
|
32
32
|
enumerable: true,
|
|
33
|
-
get: function () { return
|
|
33
|
+
get: function () { return chunk66GQROSI_cjs.getStepResult; }
|
|
34
34
|
});
|
|
35
35
|
Object.defineProperty(exports, "getSuspendedPaths", {
|
|
36
36
|
enumerable: true,
|
|
37
|
-
get: function () { return
|
|
37
|
+
get: function () { return chunk66GQROSI_cjs.getSuspendedPaths; }
|
|
38
38
|
});
|
|
39
39
|
Object.defineProperty(exports, "isAgent", {
|
|
40
40
|
enumerable: true,
|
|
41
|
-
get: function () { return
|
|
41
|
+
get: function () { return chunk66GQROSI_cjs.isAgent; }
|
|
42
42
|
});
|
|
43
43
|
Object.defineProperty(exports, "isConditionalKey", {
|
|
44
44
|
enumerable: true,
|
|
45
|
-
get: function () { return
|
|
45
|
+
get: function () { return chunk66GQROSI_cjs.isConditionalKey; }
|
|
46
46
|
});
|
|
47
47
|
Object.defineProperty(exports, "isErrorEvent", {
|
|
48
48
|
enumerable: true,
|
|
49
|
-
get: function () { return
|
|
49
|
+
get: function () { return chunk66GQROSI_cjs.isErrorEvent; }
|
|
50
50
|
});
|
|
51
51
|
Object.defineProperty(exports, "isFinalState", {
|
|
52
52
|
enumerable: true,
|
|
53
|
-
get: function () { return
|
|
53
|
+
get: function () { return chunk66GQROSI_cjs.isFinalState; }
|
|
54
54
|
});
|
|
55
55
|
Object.defineProperty(exports, "isLimboState", {
|
|
56
56
|
enumerable: true,
|
|
57
|
-
get: function () { return
|
|
57
|
+
get: function () { return chunk66GQROSI_cjs.isLimboState; }
|
|
58
58
|
});
|
|
59
59
|
Object.defineProperty(exports, "isTransitionEvent", {
|
|
60
60
|
enumerable: true,
|
|
61
|
-
get: function () { return
|
|
61
|
+
get: function () { return chunk66GQROSI_cjs.isTransitionEvent; }
|
|
62
62
|
});
|
|
63
63
|
Object.defineProperty(exports, "isVariableReference", {
|
|
64
64
|
enumerable: true,
|
|
65
|
-
get: function () { return
|
|
65
|
+
get: function () { return chunk66GQROSI_cjs.isVariableReference; }
|
|
66
66
|
});
|
|
67
67
|
Object.defineProperty(exports, "isWorkflow", {
|
|
68
68
|
enumerable: true,
|
|
69
|
-
get: function () { return
|
|
69
|
+
get: function () { return chunk66GQROSI_cjs.isWorkflow; }
|
|
70
70
|
});
|
|
71
71
|
Object.defineProperty(exports, "mergeChildValue", {
|
|
72
72
|
enumerable: true,
|
|
73
|
-
get: function () { return
|
|
73
|
+
get: function () { return chunk66GQROSI_cjs.mergeChildValue; }
|
|
74
74
|
});
|
|
75
75
|
Object.defineProperty(exports, "recursivelyCheckForFinalState", {
|
|
76
76
|
enumerable: true,
|
|
77
|
-
get: function () { return
|
|
77
|
+
get: function () { return chunk66GQROSI_cjs.recursivelyCheckForFinalState; }
|
|
78
78
|
});
|
|
79
79
|
Object.defineProperty(exports, "resolveVariables", {
|
|
80
80
|
enumerable: true,
|
|
81
|
-
get: function () { return
|
|
81
|
+
get: function () { return chunk66GQROSI_cjs.resolveVariables; }
|
|
82
82
|
});
|
|
83
83
|
Object.defineProperty(exports, "updateStepInHierarchy", {
|
|
84
84
|
enumerable: true,
|
|
85
|
-
get: function () { return
|
|
85
|
+
get: function () { return chunk66GQROSI_cjs.updateStepInHierarchy; }
|
|
86
86
|
});
|
|
87
87
|
Object.defineProperty(exports, "workflowToStep", {
|
|
88
88
|
enumerable: true,
|
|
89
|
-
get: function () { return
|
|
89
|
+
get: function () { return chunk66GQROSI_cjs.workflowToStep; }
|
|
90
90
|
});
|
package/dist/workflows/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export { Step, WhenConditionReturnValue, Workflow, agentToStep, getActivePathsAndStatus, getResultActivePaths, getStepResult, getSuspendedPaths, isAgent, isConditionalKey, isErrorEvent, isFinalState, isLimboState, isTransitionEvent, isVariableReference, isWorkflow, mergeChildValue, recursivelyCheckForFinalState, resolveVariables, updateStepInHierarchy, workflowToStep } from '../chunk-
|
|
1
|
+
export { Step, WhenConditionReturnValue, Workflow, agentToStep, getActivePathsAndStatus, getResultActivePaths, getStepResult, getSuspendedPaths, isAgent, isConditionalKey, isErrorEvent, isFinalState, isLimboState, isTransitionEvent, isVariableReference, isWorkflow, mergeChildValue, recursivelyCheckForFinalState, resolveVariables, updateStepInHierarchy, workflowToStep } from '../chunk-FW5RS6WV.js';
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
4
|
-
var
|
|
3
|
+
var chunk66GQROSI_cjs = require('../../chunk-66GQROSI.cjs');
|
|
4
|
+
var chunkEJITEVAB_cjs = require('../../chunk-EJITEVAB.cjs');
|
|
5
|
+
var chunkLABUWBKX_cjs = require('../../chunk-LABUWBKX.cjs');
|
|
5
6
|
var chunkEG74VBSP_cjs = require('../../chunk-EG74VBSP.cjs');
|
|
6
7
|
var chunkO44MSFMZ_cjs = require('../../chunk-O44MSFMZ.cjs');
|
|
7
|
-
var chunkLABUWBKX_cjs = require('../../chunk-LABUWBKX.cjs');
|
|
8
8
|
var crypto = require('crypto');
|
|
9
9
|
var EventEmitter = require('events');
|
|
10
10
|
var zod = require('zod');
|
|
@@ -649,7 +649,7 @@ var DefaultExecutionEngine = class extends ExecutionEngine {
|
|
|
649
649
|
|
|
650
650
|
// src/workflows/vNext/workflow.ts
|
|
651
651
|
function createStep(params) {
|
|
652
|
-
if (params instanceof
|
|
652
|
+
if (params instanceof chunk66GQROSI_cjs.Agent) {
|
|
653
653
|
return {
|
|
654
654
|
id: params.name,
|
|
655
655
|
// @ts-ignore
|
|
@@ -673,7 +673,7 @@ function createStep(params) {
|
|
|
673
673
|
}
|
|
674
674
|
};
|
|
675
675
|
}
|
|
676
|
-
if (params instanceof
|
|
676
|
+
if (params instanceof chunkEJITEVAB_cjs.Tool) {
|
|
677
677
|
if (!params.inputSchema || !params.outputSchema) {
|
|
678
678
|
throw new Error("Tool must have input and output schemas defined");
|
|
679
679
|
}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { Agent } from '../../chunk-
|
|
2
|
-
import { Tool } from '../../chunk-
|
|
1
|
+
import { Agent } from '../../chunk-FW5RS6WV.js';
|
|
2
|
+
import { Tool } from '../../chunk-S34QVMKE.js';
|
|
3
|
+
import { RuntimeContext } from '../../chunk-SGGPJWRQ.js';
|
|
3
4
|
import { MastraBase } from '../../chunk-235X76GC.js';
|
|
4
5
|
import { RegisteredLogger } from '../../chunk-CMPPXW4U.js';
|
|
5
|
-
import { RuntimeContext } from '../../chunk-SGGPJWRQ.js';
|
|
6
6
|
import { randomUUID } from 'crypto';
|
|
7
7
|
import EventEmitter from 'events';
|
|
8
8
|
import { z } from 'zod';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mastra/core",
|
|
3
|
-
"version": "0.9.4
|
|
3
|
+
"version": "0.9.4",
|
|
4
4
|
"license": "Elastic-2.0",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -158,7 +158,7 @@
|
|
|
158
158
|
"typescript": "^5.8.2",
|
|
159
159
|
"vitest": "^3.1.2",
|
|
160
160
|
"zod": "^3.24.3",
|
|
161
|
-
"@internal/lint": "0.0.
|
|
161
|
+
"@internal/lint": "0.0.5"
|
|
162
162
|
},
|
|
163
163
|
"engines": {
|
|
164
164
|
"node": ">=20"
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var chunkEG74VBSP_cjs = require('./chunk-EG74VBSP.cjs');
|
|
4
3
|
var chunkLABUWBKX_cjs = require('./chunk-LABUWBKX.cjs');
|
|
4
|
+
var chunkEG74VBSP_cjs = require('./chunk-EG74VBSP.cjs');
|
|
5
5
|
var crypto = require('crypto');
|
|
6
6
|
var ai = require('ai');
|
|
7
7
|
var jsonSchemaToZod = require('json-schema-to-zod');
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { MastraBase } from './chunk-235X76GC.js';
|
|
2
1
|
import { RuntimeContext } from './chunk-SGGPJWRQ.js';
|
|
2
|
+
import { MastraBase } from './chunk-235X76GC.js';
|
|
3
3
|
import { createHash } from 'crypto';
|
|
4
4
|
import { convertToCoreMessages, jsonSchema, zodSchema } from 'ai';
|
|
5
5
|
import jsonSchemaToZod from 'json-schema-to-zod';
|