@mastra/core 1.32.1 → 1.33.0-alpha.1
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 +12 -0
- package/dist/agent/agent.d.ts.map +1 -1
- package/dist/agent/durable/index.cjs +22 -22
- package/dist/agent/durable/index.js +4 -4
- package/dist/agent/index.cjs +9 -9
- package/dist/agent/index.js +1 -1
- package/dist/browser/index.cjs +2 -2
- package/dist/browser/index.js +1 -1
- package/dist/channels/index.cjs +4 -4
- package/dist/channels/index.js +1 -1
- package/dist/{chunk-6CFOTCM4.cjs → chunk-2YN2GWML.cjs} +3 -3
- package/dist/chunk-2YN2GWML.cjs.map +1 -0
- package/dist/{chunk-3TIWEIPL.js → chunk-3OIXD6QZ.js} +3 -3
- package/dist/{chunk-3TIWEIPL.js.map → chunk-3OIXD6QZ.js.map} +1 -1
- package/dist/{chunk-Y6XZGGCP.js → chunk-5AFWTTES.js} +4 -4
- package/dist/{chunk-Y6XZGGCP.js.map → chunk-5AFWTTES.js.map} +1 -1
- package/dist/{chunk-DDFT2H3T.js → chunk-5LXIX7FZ.js} +4 -7
- package/dist/chunk-5LXIX7FZ.js.map +1 -0
- package/dist/{chunk-STUBLKUI.js → chunk-7M65H4UA.js} +4 -4
- package/dist/{chunk-STUBLKUI.js.map → chunk-7M65H4UA.js.map} +1 -1
- package/dist/{chunk-XXKOQCB4.cjs → chunk-AU4KVBT6.cjs} +9 -3
- package/dist/chunk-AU4KVBT6.cjs.map +1 -0
- package/dist/{chunk-TLJ4XI7U.cjs → chunk-BSC4D3AA.cjs} +22 -22
- package/dist/{chunk-TLJ4XI7U.cjs.map → chunk-BSC4D3AA.cjs.map} +1 -1
- package/dist/{chunk-SAI37VFF.cjs → chunk-C6M5HBBX.cjs} +28 -20
- package/dist/chunk-C6M5HBBX.cjs.map +1 -0
- package/dist/{chunk-LUS5VPK2.cjs → chunk-CHGGDYI6.cjs} +389 -389
- package/dist/{chunk-LUS5VPK2.cjs.map → chunk-CHGGDYI6.cjs.map} +1 -1
- package/dist/{chunk-6HX3NKCA.js → chunk-CJHHPVVU.js} +9 -3
- package/dist/chunk-CJHHPVVU.js.map +1 -0
- package/dist/{chunk-B7CR6B45.cjs → chunk-DV3G5TZJ.cjs} +16 -16
- package/dist/{chunk-B7CR6B45.cjs.map → chunk-DV3G5TZJ.cjs.map} +1 -1
- package/dist/{chunk-S7NPAUFJ.cjs → chunk-GB2CQKRS.cjs} +9 -9
- package/dist/{chunk-S7NPAUFJ.cjs.map → chunk-GB2CQKRS.cjs.map} +1 -1
- package/dist/{chunk-RNFNMSYF.js → chunk-GQDJFBVF.js} +6 -6
- package/dist/{chunk-RNFNMSYF.js.map → chunk-GQDJFBVF.js.map} +1 -1
- package/dist/{chunk-MT42UWQD.cjs → chunk-GVVA4JRD.cjs} +10 -10
- package/dist/{chunk-MT42UWQD.cjs.map → chunk-GVVA4JRD.cjs.map} +1 -1
- package/dist/{chunk-IX34UNHY.cjs → chunk-IFWVHG2M.cjs} +61 -61
- package/dist/{chunk-IX34UNHY.cjs.map → chunk-IFWVHG2M.cjs.map} +1 -1
- package/dist/{chunk-3K2UXV2P.js → chunk-JOA5YBHN.js} +3 -3
- package/dist/chunk-JOA5YBHN.js.map +1 -0
- package/dist/{chunk-ECN5FG7P.cjs → chunk-KE7K677R.cjs} +7 -7
- package/dist/{chunk-ECN5FG7P.cjs.map → chunk-KE7K677R.cjs.map} +1 -1
- package/dist/{chunk-IIBNQYG5.js → chunk-L4Q63LCX.js} +16 -8
- package/dist/chunk-L4Q63LCX.js.map +1 -0
- package/dist/{chunk-3I3AIY75.js → chunk-OPMKAUNT.js} +4 -4
- package/dist/{chunk-3I3AIY75.js.map → chunk-OPMKAUNT.js.map} +1 -1
- package/dist/{chunk-QPZ35KK2.cjs → chunk-PA73DY5B.cjs} +14 -17
- package/dist/chunk-PA73DY5B.cjs.map +1 -0
- package/dist/{chunk-GMS24LXF.js → chunk-PBD75KII.js} +5 -5
- package/dist/{chunk-GMS24LXF.js.map → chunk-PBD75KII.js.map} +1 -1
- package/dist/{chunk-YQ4V5JQE.cjs → chunk-QBT4WKAU.cjs} +10 -10
- package/dist/{chunk-YQ4V5JQE.cjs.map → chunk-QBT4WKAU.cjs.map} +1 -1
- package/dist/{chunk-PUHQJIU3.js → chunk-UGRXTMCT.js} +3 -3
- package/dist/{chunk-PUHQJIU3.js.map → chunk-UGRXTMCT.js.map} +1 -1
- package/dist/{chunk-52OXJLBQ.js → chunk-V3AXABKC.js} +3 -3
- package/dist/{chunk-52OXJLBQ.js.map → chunk-V3AXABKC.js.map} +1 -1
- package/dist/{chunk-S32LFLPN.cjs → chunk-VUY4QAW4.cjs} +224 -224
- package/dist/{chunk-S32LFLPN.cjs.map → chunk-VUY4QAW4.cjs.map} +1 -1
- package/dist/{chunk-4F7PQPW4.js → chunk-YXEOBUUH.js} +9 -9
- package/dist/{chunk-4F7PQPW4.js.map → chunk-YXEOBUUH.js.map} +1 -1
- package/dist/datasets/index.cjs +17 -17
- package/dist/datasets/index.js +2 -2
- package/dist/docs/SKILL.md +1 -1
- package/dist/docs/assets/SOURCE_MAP.json +337 -337
- package/dist/docs/references/docs-memory-observational-memory.md +2 -1
- package/dist/docs/references/docs-memory-overview.md +2 -1
- package/dist/docs/references/reference-harness-harness-class.md +2 -0
- package/dist/docs/references/reference-tools-mcp-client.md +47 -0
- package/dist/evals/index.cjs +24 -24
- package/dist/evals/index.js +3 -3
- package/dist/evals/scoreTraces/index.cjs +5 -5
- package/dist/evals/scoreTraces/index.js +2 -2
- package/dist/evals/types.d.ts.map +1 -1
- package/dist/harness/index.cjs +7 -7
- package/dist/harness/index.js +5 -5
- package/dist/index.cjs +2 -2
- package/dist/index.js +1 -1
- package/dist/llm/index.cjs +20 -20
- package/dist/llm/index.js +5 -5
- package/dist/llm/model/provider-types.generated.d.ts +4 -0
- package/dist/loop/index.cjs +14 -14
- package/dist/loop/index.js +1 -1
- package/dist/mastra/index.cjs +2 -2
- package/dist/mastra/index.js +1 -1
- package/dist/mastra-TBJEDBDE.js +3 -0
- package/dist/{mastra-QKQ7ZTQH.js.map → mastra-TBJEDBDE.js.map} +1 -1
- package/dist/mastra-XZZ5PGRE.cjs +12 -0
- package/dist/{mastra-BC32LUTX.cjs.map → mastra-XZZ5PGRE.cjs.map} +1 -1
- package/dist/memory/index.cjs +19 -19
- package/dist/memory/index.js +1 -1
- package/dist/models-dev-NBPBZGNU.js +3 -0
- package/dist/{models-dev-72IOTTPQ.js.map → models-dev-NBPBZGNU.js.map} +1 -1
- package/dist/models-dev-VYQYBTPH.cjs +12 -0
- package/dist/{models-dev-4IKKAR6E.cjs.map → models-dev-VYQYBTPH.cjs.map} +1 -1
- package/dist/netlify-AHTOWHQ3.js +3 -0
- package/dist/{netlify-OBBPI7AA.js.map → netlify-AHTOWHQ3.js.map} +1 -1
- package/dist/netlify-B4ALATN2.cjs +12 -0
- package/dist/{netlify-W7FYJBAT.cjs.map → netlify-B4ALATN2.cjs.map} +1 -1
- package/dist/processor-provider/index.cjs +10 -10
- package/dist/processor-provider/index.js +1 -1
- package/dist/processors/index.cjs +51 -51
- package/dist/processors/index.js +1 -1
- package/dist/provider-registry-5MSQZY5O.cjs +44 -0
- package/dist/{provider-registry-UM6NWWSW.cjs.map → provider-registry-5MSQZY5O.cjs.map} +1 -1
- package/dist/provider-registry-GPH6SHFV.js +3 -0
- package/dist/{provider-registry-IHIZF4QH.js.map → provider-registry-GPH6SHFV.js.map} +1 -1
- package/dist/provider-registry.json +8 -0
- package/dist/relevance/index.cjs +3 -3
- package/dist/relevance/index.js +1 -1
- package/dist/runner-HODGJLIH.cjs +16 -0
- package/dist/{runner-2AOFRABN.cjs.map → runner-HODGJLIH.cjs.map} +1 -1
- package/dist/runner-LF2L47BX.js +3 -0
- package/dist/{runner-MXS4JFWL.js.map → runner-LF2L47BX.js.map} +1 -1
- package/dist/storage/constants.cjs +61 -61
- package/dist/storage/constants.js +1 -1
- package/dist/storage/index.cjs +156 -156
- package/dist/storage/index.js +2 -2
- package/dist/stream/index.cjs +11 -11
- package/dist/stream/index.js +1 -1
- package/dist/tool-loop-agent/index.cjs +4 -4
- package/dist/tool-loop-agent/index.js +1 -1
- package/dist/vector/index.cjs +7 -7
- package/dist/vector/index.js +1 -1
- package/dist/workflows/evented/index.cjs +10 -10
- package/dist/workflows/evented/index.js +1 -1
- package/dist/workflows/index.cjs +28 -28
- package/dist/workflows/index.js +1 -1
- package/package.json +5 -5
- package/src/llm/model/provider-types.generated.d.ts +4 -0
- package/dist/chunk-3K2UXV2P.js.map +0 -1
- package/dist/chunk-6CFOTCM4.cjs.map +0 -1
- package/dist/chunk-6HX3NKCA.js.map +0 -1
- package/dist/chunk-DDFT2H3T.js.map +0 -1
- package/dist/chunk-IIBNQYG5.js.map +0 -1
- package/dist/chunk-QPZ35KK2.cjs.map +0 -1
- package/dist/chunk-SAI37VFF.cjs.map +0 -1
- package/dist/chunk-XXKOQCB4.cjs.map +0 -1
- package/dist/mastra-BC32LUTX.cjs +0 -12
- package/dist/mastra-QKQ7ZTQH.js +0 -3
- package/dist/models-dev-4IKKAR6E.cjs +0 -12
- package/dist/models-dev-72IOTTPQ.js +0 -3
- package/dist/netlify-OBBPI7AA.js +0 -3
- package/dist/netlify-W7FYJBAT.cjs +0 -12
- package/dist/provider-registry-IHIZF4QH.js +0 -3
- package/dist/provider-registry-UM6NWWSW.cjs +0 -44
- package/dist/runner-2AOFRABN.cjs +0 -16
- package/dist/runner-MXS4JFWL.js +0 -3
|
@@ -458,4 +458,5 @@ In practical terms, OM replaces both working memory and message history, and has
|
|
|
458
458
|
- [Observational Memory Reference](https://mastra.ai/reference/memory/observational-memory)
|
|
459
459
|
- [Memory Overview](https://mastra.ai/docs/memory/overview)
|
|
460
460
|
- [Message History](https://mastra.ai/docs/memory/message-history)
|
|
461
|
-
- [Memory Processors](https://mastra.ai/docs/memory/memory-processors)
|
|
461
|
+
- [Memory Processors](https://mastra.ai/docs/memory/memory-processors)
|
|
462
|
+
- [Mastra Code](https://code.mastra.ai/): A coding agent using Observational Memory
|
|
@@ -237,4 +237,5 @@ export const memoryAgent = new Agent({
|
|
|
237
237
|
|
|
238
238
|
- [`Memory` reference](https://mastra.ai/reference/memory/memory-class)
|
|
239
239
|
- [Tracing](https://mastra.ai/docs/observability/tracing/overview)
|
|
240
|
-
- [Request Context](https://mastra.ai/docs/server/request-context)
|
|
240
|
+
- [Request Context](https://mastra.ai/docs/server/request-context)
|
|
241
|
+
- [Mastra Code](https://code.mastra.ai/): A coding agent using Mastra's memory system
|
|
@@ -3,6 +3,8 @@
|
|
|
3
3
|
**Added in:** `@mastra/core@1.5.0`
|
|
4
4
|
|
|
5
5
|
> **Warning:** The `Harness` class is in alpha stage and subject to change. It won't follow semantic versioning guarantees until it graduates from experimental status. Use with caution and expect breaking changes in minor versions.
|
|
6
|
+
>
|
|
7
|
+
> [Mastra Code](https://code.mastra.ai/) is the flagship implementation of the `Harness` class, showcasing how it can be used to build a powerful terminal-based coding agent with multi-model support, persistent conversations, and built-in tools.
|
|
6
8
|
|
|
7
9
|
The `Harness` class orchestrates multiple agent modes, shared state, memory, and storage. It provides a control layer that a TUI or other UI can drive to manage threads, switch models and modes, send messages, handle tool approvals, and track events.
|
|
8
10
|
|
|
@@ -987,6 +987,53 @@ await agent.generate('Hello!', {
|
|
|
987
987
|
})
|
|
988
988
|
```
|
|
989
989
|
|
|
990
|
+
## Handling auth failures inside custom fetch
|
|
991
|
+
|
|
992
|
+
A custom `fetch` should not `throw` when authentication is unavailable. The Streamable HTTP transport in the MCP SDK opens a long-lived `GET /mcp` "standalone listener" stream in the background to receive server-pushed notifications. Errors on that stream are retried with exponential backoff, and a thrown `fetch` or a cleanly-closed stream can produce an indefinite reconnect loop at roughly one attempt per second.
|
|
993
|
+
|
|
994
|
+
Return a synthetic `Response` instead. The [MCP Streamable HTTP specification](https://modelcontextprotocol.io/specification/2025-03-26/basic/transports) defines `405 Method Not Allowed` as the signal a server returns when it does not offer the GET SSE stream, and the SDK honors it as a terminal status that stops the listener cleanly. Use this to disable the listener when your server does not push notifications.
|
|
995
|
+
|
|
996
|
+
The following pattern waits for an auth token on POST requests, attaches it to outgoing headers, and short-circuits the GET listener with a synthetic 405:
|
|
997
|
+
|
|
998
|
+
```typescript
|
|
999
|
+
async function waitForToken(timeoutMs = 5000): Promise<string | null> {
|
|
1000
|
+
// Replace with your token lookup. Return null if no token is available.
|
|
1001
|
+
return getAuthToken({ timeoutMs })
|
|
1002
|
+
}
|
|
1003
|
+
|
|
1004
|
+
const mcpClient = new MCPClient({
|
|
1005
|
+
servers: {
|
|
1006
|
+
apiServer: {
|
|
1007
|
+
url: new URL('https://api.example.com/mcp'),
|
|
1008
|
+
fetch: async (url, init) => {
|
|
1009
|
+
const method = (init?.method || 'GET').toUpperCase()
|
|
1010
|
+
|
|
1011
|
+
// The SDK opens a background GET stream for server-pushed notifications.
|
|
1012
|
+
// If your server does not use it, short-circuit with 405 to stop reconnect attempts.
|
|
1013
|
+
if (method === 'GET') {
|
|
1014
|
+
return new Response(null, { status: 405, statusText: 'Method Not Allowed' })
|
|
1015
|
+
}
|
|
1016
|
+
|
|
1017
|
+
// POST: wait for the token, then forward the request with an Authorization header.
|
|
1018
|
+
const token = await waitForToken()
|
|
1019
|
+
if (!token) {
|
|
1020
|
+
// Forward the request without a token and let the server reject it.
|
|
1021
|
+
// The SDK surfaces non-2xx POST responses as errors to the caller of
|
|
1022
|
+
// tools/list, tools/call, etc., which is the desired behavior here.
|
|
1023
|
+
return fetch(url, init)
|
|
1024
|
+
}
|
|
1025
|
+
|
|
1026
|
+
const headers = new Headers(init?.headers)
|
|
1027
|
+
headers.set('authorization', `Bearer ${token}`)
|
|
1028
|
+
return fetch(url, { ...init, headers })
|
|
1029
|
+
},
|
|
1030
|
+
},
|
|
1031
|
+
},
|
|
1032
|
+
})
|
|
1033
|
+
```
|
|
1034
|
+
|
|
1035
|
+
Return `405` for the GET listener only when your server does not push notifications back to the client. If your server uses the standalone GET stream, attach the auth token on `GET` requests as well and let the request through.
|
|
1036
|
+
|
|
990
1037
|
## Using SSE request headers
|
|
991
1038
|
|
|
992
1039
|
When using the legacy SSE MCP transport, you must configure both `requestInit` and `eventSourceInit` due to a bug in the MCP SDK. Alternatively, you can use a custom `fetch` function which will be automatically used for both POST requests and SSE connections:
|
package/dist/evals/index.cjs
CHANGED
|
@@ -1,94 +1,94 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
4
|
-
var
|
|
5
|
-
var
|
|
3
|
+
var chunkGVVA4JRD_cjs = require('../chunk-GVVA4JRD.cjs');
|
|
4
|
+
var chunkPA73DY5B_cjs = require('../chunk-PA73DY5B.cjs');
|
|
5
|
+
var chunkAU4KVBT6_cjs = require('../chunk-AU4KVBT6.cjs');
|
|
6
6
|
|
|
7
7
|
|
|
8
8
|
|
|
9
9
|
Object.defineProperty(exports, "runEvals", {
|
|
10
10
|
enumerable: true,
|
|
11
|
-
get: function () { return
|
|
11
|
+
get: function () { return chunkGVVA4JRD_cjs.runEvals; }
|
|
12
12
|
});
|
|
13
13
|
Object.defineProperty(exports, "MastraScorer", {
|
|
14
14
|
enumerable: true,
|
|
15
|
-
get: function () { return
|
|
15
|
+
get: function () { return chunkPA73DY5B_cjs.MastraScorer; }
|
|
16
16
|
});
|
|
17
17
|
Object.defineProperty(exports, "createScorer", {
|
|
18
18
|
enumerable: true,
|
|
19
|
-
get: function () { return
|
|
19
|
+
get: function () { return chunkPA73DY5B_cjs.createScorer; }
|
|
20
20
|
});
|
|
21
21
|
Object.defineProperty(exports, "filterRun", {
|
|
22
22
|
enumerable: true,
|
|
23
|
-
get: function () { return
|
|
23
|
+
get: function () { return chunkPA73DY5B_cjs.filterRun; }
|
|
24
24
|
});
|
|
25
25
|
Object.defineProperty(exports, "extractTrajectory", {
|
|
26
26
|
enumerable: true,
|
|
27
|
-
get: function () { return
|
|
27
|
+
get: function () { return chunkAU4KVBT6_cjs.extractTrajectory; }
|
|
28
28
|
});
|
|
29
29
|
Object.defineProperty(exports, "extractTrajectoryFromTrace", {
|
|
30
30
|
enumerable: true,
|
|
31
|
-
get: function () { return
|
|
31
|
+
get: function () { return chunkAU4KVBT6_cjs.extractTrajectoryFromTrace; }
|
|
32
32
|
});
|
|
33
33
|
Object.defineProperty(exports, "extractWorkflowTrajectory", {
|
|
34
34
|
enumerable: true,
|
|
35
|
-
get: function () { return
|
|
35
|
+
get: function () { return chunkAU4KVBT6_cjs.extractWorkflowTrajectory; }
|
|
36
36
|
});
|
|
37
37
|
Object.defineProperty(exports, "listScoresResponseSchema", {
|
|
38
38
|
enumerable: true,
|
|
39
|
-
get: function () { return
|
|
39
|
+
get: function () { return chunkAU4KVBT6_cjs.listScoresResponseSchema; }
|
|
40
40
|
});
|
|
41
41
|
Object.defineProperty(exports, "saveScorePayloadSchema", {
|
|
42
42
|
enumerable: true,
|
|
43
|
-
get: function () { return
|
|
43
|
+
get: function () { return chunkAU4KVBT6_cjs.saveScorePayloadSchema; }
|
|
44
44
|
});
|
|
45
45
|
Object.defineProperty(exports, "scoreResultSchema", {
|
|
46
46
|
enumerable: true,
|
|
47
|
-
get: function () { return
|
|
47
|
+
get: function () { return chunkAU4KVBT6_cjs.scoreResultSchema; }
|
|
48
48
|
});
|
|
49
49
|
Object.defineProperty(exports, "scoreRowDataSchema", {
|
|
50
50
|
enumerable: true,
|
|
51
|
-
get: function () { return
|
|
51
|
+
get: function () { return chunkAU4KVBT6_cjs.scoreRowDataSchema; }
|
|
52
52
|
});
|
|
53
53
|
Object.defineProperty(exports, "scoringEntityTypeSchema", {
|
|
54
54
|
enumerable: true,
|
|
55
|
-
get: function () { return
|
|
55
|
+
get: function () { return chunkAU4KVBT6_cjs.scoringEntityTypeSchema; }
|
|
56
56
|
});
|
|
57
57
|
Object.defineProperty(exports, "scoringExtractStepResultSchema", {
|
|
58
58
|
enumerable: true,
|
|
59
|
-
get: function () { return
|
|
59
|
+
get: function () { return chunkAU4KVBT6_cjs.scoringExtractStepResultSchema; }
|
|
60
60
|
});
|
|
61
61
|
Object.defineProperty(exports, "scoringHookInputSchema", {
|
|
62
62
|
enumerable: true,
|
|
63
|
-
get: function () { return
|
|
63
|
+
get: function () { return chunkAU4KVBT6_cjs.scoringHookInputSchema; }
|
|
64
64
|
});
|
|
65
65
|
Object.defineProperty(exports, "scoringInputSchema", {
|
|
66
66
|
enumerable: true,
|
|
67
|
-
get: function () { return
|
|
67
|
+
get: function () { return chunkAU4KVBT6_cjs.scoringInputSchema; }
|
|
68
68
|
});
|
|
69
69
|
Object.defineProperty(exports, "scoringInputWithExtractStepResultAndAnalyzeStepResultSchema", {
|
|
70
70
|
enumerable: true,
|
|
71
|
-
get: function () { return
|
|
71
|
+
get: function () { return chunkAU4KVBT6_cjs.scoringInputWithExtractStepResultAndAnalyzeStepResultSchema; }
|
|
72
72
|
});
|
|
73
73
|
Object.defineProperty(exports, "scoringInputWithExtractStepResultAndScoreAndReasonSchema", {
|
|
74
74
|
enumerable: true,
|
|
75
|
-
get: function () { return
|
|
75
|
+
get: function () { return chunkAU4KVBT6_cjs.scoringInputWithExtractStepResultAndScoreAndReasonSchema; }
|
|
76
76
|
});
|
|
77
77
|
Object.defineProperty(exports, "scoringInputWithExtractStepResultSchema", {
|
|
78
78
|
enumerable: true,
|
|
79
|
-
get: function () { return
|
|
79
|
+
get: function () { return chunkAU4KVBT6_cjs.scoringInputWithExtractStepResultSchema; }
|
|
80
80
|
});
|
|
81
81
|
Object.defineProperty(exports, "scoringPromptsSchema", {
|
|
82
82
|
enumerable: true,
|
|
83
|
-
get: function () { return
|
|
83
|
+
get: function () { return chunkAU4KVBT6_cjs.scoringPromptsSchema; }
|
|
84
84
|
});
|
|
85
85
|
Object.defineProperty(exports, "scoringSourceSchema", {
|
|
86
86
|
enumerable: true,
|
|
87
|
-
get: function () { return
|
|
87
|
+
get: function () { return chunkAU4KVBT6_cjs.scoringSourceSchema; }
|
|
88
88
|
});
|
|
89
89
|
Object.defineProperty(exports, "scoringValueSchema", {
|
|
90
90
|
enumerable: true,
|
|
91
|
-
get: function () { return
|
|
91
|
+
get: function () { return chunkAU4KVBT6_cjs.scoringValueSchema; }
|
|
92
92
|
});
|
|
93
93
|
//# sourceMappingURL=index.cjs.map
|
|
94
94
|
//# sourceMappingURL=index.cjs.map
|
package/dist/evals/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
export { runEvals } from '../chunk-
|
|
2
|
-
export { MastraScorer, createScorer, filterRun } from '../chunk-
|
|
3
|
-
export { extractTrajectory, extractTrajectoryFromTrace, extractWorkflowTrajectory, listScoresResponseSchema, saveScorePayloadSchema, scoreResultSchema, scoreRowDataSchema, scoringEntityTypeSchema, scoringExtractStepResultSchema, scoringHookInputSchema, scoringInputSchema, scoringInputWithExtractStepResultAndAnalyzeStepResultSchema, scoringInputWithExtractStepResultAndScoreAndReasonSchema, scoringInputWithExtractStepResultSchema, scoringPromptsSchema, scoringSourceSchema, scoringValueSchema } from '../chunk-
|
|
1
|
+
export { runEvals } from '../chunk-7M65H4UA.js';
|
|
2
|
+
export { MastraScorer, createScorer, filterRun } from '../chunk-5LXIX7FZ.js';
|
|
3
|
+
export { extractTrajectory, extractTrajectoryFromTrace, extractWorkflowTrajectory, listScoresResponseSchema, saveScorePayloadSchema, scoreResultSchema, scoreRowDataSchema, scoringEntityTypeSchema, scoringExtractStepResultSchema, scoringHookInputSchema, scoringInputSchema, scoringInputWithExtractStepResultAndAnalyzeStepResultSchema, scoringInputWithExtractStepResultAndScoreAndReasonSchema, scoringInputWithExtractStepResultSchema, scoringPromptsSchema, scoringSourceSchema, scoringValueSchema } from '../chunk-CJHHPVVU.js';
|
|
4
4
|
//# sourceMappingURL=index.js.map
|
|
5
5
|
//# sourceMappingURL=index.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
4
|
-
var
|
|
3
|
+
var chunkIFWVHG2M_cjs = require('../../chunk-IFWVHG2M.cjs');
|
|
4
|
+
var chunkAU4KVBT6_cjs = require('../../chunk-AU4KVBT6.cjs');
|
|
5
5
|
var chunk5IS5R433_cjs = require('../../chunk-5IS5R433.cjs');
|
|
6
6
|
var chunk4U7ZLI36_cjs = require('../../chunk-4U7ZLI36.cjs');
|
|
7
7
|
var pMap = require('p-map');
|
|
@@ -234,7 +234,7 @@ function transformTraceToScorerInputAndOutput(trace) {
|
|
|
234
234
|
}
|
|
235
235
|
|
|
236
236
|
// src/evals/scoreTraces/scoreTracesWorkflow.ts
|
|
237
|
-
var getTraceStep =
|
|
237
|
+
var getTraceStep = chunkIFWVHG2M_cjs.createStep({
|
|
238
238
|
id: "__process-trace-scoring",
|
|
239
239
|
inputSchema: v4.z.object({
|
|
240
240
|
targets: v4.z.array(
|
|
@@ -383,7 +383,7 @@ async function validateAndSaveScore({ storage, scorerResult }) {
|
|
|
383
383
|
text: "Scores storage domain is not available"
|
|
384
384
|
});
|
|
385
385
|
}
|
|
386
|
-
const payloadToSave =
|
|
386
|
+
const payloadToSave = chunkAU4KVBT6_cjs.saveScorePayloadSchema.parse(scorerResult);
|
|
387
387
|
const result = await scoresStore.saveScore(payloadToSave);
|
|
388
388
|
return result.score;
|
|
389
389
|
}
|
|
@@ -429,7 +429,7 @@ async function attachScoreToSpan({
|
|
|
429
429
|
} catch {
|
|
430
430
|
}
|
|
431
431
|
}
|
|
432
|
-
var scoreTracesWorkflow =
|
|
432
|
+
var scoreTracesWorkflow = chunkIFWVHG2M_cjs.createWorkflow({
|
|
433
433
|
id: "__batch-scoring-traces",
|
|
434
434
|
inputSchema: v4.z.object({
|
|
435
435
|
targets: v4.z.array(
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { createStep, createWorkflow } from '../../chunk-
|
|
2
|
-
import { saveScorePayloadSchema } from '../../chunk-
|
|
1
|
+
import { createStep, createWorkflow } from '../../chunk-OPMKAUNT.js';
|
|
2
|
+
import { saveScorePayloadSchema } from '../../chunk-CJHHPVVU.js';
|
|
3
3
|
import { getEntityTypeForSpan } from '../../chunk-DCLOP22D.js';
|
|
4
4
|
import { MastraError } from '../../chunk-FJEVLHJT.js';
|
|
5
5
|
import pMap from 'p-map';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/evals/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,iBAAiB,EAAE,MAAM,qBAAqB,CAAC;AAC1E,OAAO,EAAE,CAAC,EAAE,MAAM,QAAQ,CAAC;AAC3B,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,UAAU,CAAC;AAEhD,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,kBAAkB,CAAC;AAC7D,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,0CAA0C,CAAC;AAE3E,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAC;AAMrD,MAAM,MAAM,qBAAqB,GAAG;IAAE,IAAI,EAAE,MAAM,CAAA;CAAE,GAAG;IAAE,IAAI,EAAE,OAAO,CAAC;IAAC,IAAI,EAAE,MAAM,CAAA;CAAE,CAAC;AAMvF,eAAO,MAAM,mBAAmB;;;EAA2B,CAAC;AAE5D,MAAM,MAAM,aAAa,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC;AAEhE,eAAO,MAAM,uBAAuB;;
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/evals/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,iBAAiB,EAAE,MAAM,qBAAqB,CAAC;AAC1E,OAAO,EAAE,CAAC,EAAE,MAAM,QAAQ,CAAC;AAC3B,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,UAAU,CAAC;AAEhD,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,kBAAkB,CAAC;AAC7D,OAAO,KAAK,EAAE,UAAU,E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var chunkAX6D722J_cjs = require('../chunk-AX6D722J.cjs');
|
|
7
7
|
var chunkM4KUR53T_cjs = require('../chunk-M4KUR53T.cjs');
|
|
@@ -610,7 +610,7 @@ ${FORKED_SUBAGENT_NESTING_NOTICE}`;
|
|
|
610
610
|
isError: true
|
|
611
611
|
};
|
|
612
612
|
}
|
|
613
|
-
subagentToRun = new
|
|
613
|
+
subagentToRun = new chunkPA73DY5B_cjs.Agent({
|
|
614
614
|
id: `subagent-${definition.id}`,
|
|
615
615
|
name: `${definition.name} Subagent`,
|
|
616
616
|
instructions: definition.instructions,
|
|
@@ -907,7 +907,7 @@ var Harness = class {
|
|
|
907
907
|
*/
|
|
908
908
|
async init() {
|
|
909
909
|
if (this.config.storage) {
|
|
910
|
-
this.#internalMastra = new
|
|
910
|
+
this.#internalMastra = new chunkBSC4D3AA_cjs.Mastra({
|
|
911
911
|
logger: false,
|
|
912
912
|
storage: this.config.storage,
|
|
913
913
|
...this.config.observability ? { observability: this.config.observability } : {}
|
|
@@ -1167,7 +1167,7 @@ var Harness = class {
|
|
|
1167
1167
|
}
|
|
1168
1168
|
}
|
|
1169
1169
|
try {
|
|
1170
|
-
const { PROVIDER_REGISTRY } = await import('../provider-registry-
|
|
1170
|
+
const { PROVIDER_REGISTRY } = await import('../provider-registry-5MSQZY5O.cjs');
|
|
1171
1171
|
const registry = PROVIDER_REGISTRY;
|
|
1172
1172
|
const providerConfig = registry[provider];
|
|
1173
1173
|
const envVars = providerConfig?.apiKeyEnvVar;
|
|
@@ -1187,7 +1187,7 @@ var Harness = class {
|
|
|
1187
1187
|
*/
|
|
1188
1188
|
async listAvailableModels() {
|
|
1189
1189
|
try {
|
|
1190
|
-
const { PROVIDER_REGISTRY } = await import('../provider-registry-
|
|
1190
|
+
const { PROVIDER_REGISTRY } = await import('../provider-registry-5MSQZY5O.cjs');
|
|
1191
1191
|
if (!PROVIDER_REGISTRY) return [];
|
|
1192
1192
|
const registry = PROVIDER_REGISTRY;
|
|
1193
1193
|
const providers = Object.keys(registry);
|
|
@@ -1246,7 +1246,7 @@ var Harness = class {
|
|
|
1246
1246
|
}
|
|
1247
1247
|
async getProviderApiKeyEnvVar(provider) {
|
|
1248
1248
|
try {
|
|
1249
|
-
const { PROVIDER_REGISTRY } = await import('../provider-registry-
|
|
1249
|
+
const { PROVIDER_REGISTRY } = await import('../provider-registry-5MSQZY5O.cjs');
|
|
1250
1250
|
const registry = PROVIDER_REGISTRY;
|
|
1251
1251
|
const envVars = registry[provider]?.apiKeyEnvVar;
|
|
1252
1252
|
return Array.isArray(envVars) ? envVars[0] : envVars;
|
package/dist/harness/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { Mastra } from '../chunk-
|
|
2
|
-
import { Agent } from '../chunk-
|
|
1
|
+
import { Mastra } from '../chunk-YXEOBUUH.js';
|
|
2
|
+
import { Agent } from '../chunk-5LXIX7FZ.js';
|
|
3
3
|
import { Workspace, createWorkspaceTools } from '../chunk-F4PWGVHW.js';
|
|
4
4
|
import { safeStringify } from '../chunk-O5LXE6TX.js';
|
|
5
5
|
import { createTool } from '../chunk-PXOIM2JE.js';
|
|
@@ -1165,7 +1165,7 @@ var Harness = class {
|
|
|
1165
1165
|
}
|
|
1166
1166
|
}
|
|
1167
1167
|
try {
|
|
1168
|
-
const { PROVIDER_REGISTRY } = await import('../provider-registry-
|
|
1168
|
+
const { PROVIDER_REGISTRY } = await import('../provider-registry-GPH6SHFV.js');
|
|
1169
1169
|
const registry = PROVIDER_REGISTRY;
|
|
1170
1170
|
const providerConfig = registry[provider];
|
|
1171
1171
|
const envVars = providerConfig?.apiKeyEnvVar;
|
|
@@ -1185,7 +1185,7 @@ var Harness = class {
|
|
|
1185
1185
|
*/
|
|
1186
1186
|
async listAvailableModels() {
|
|
1187
1187
|
try {
|
|
1188
|
-
const { PROVIDER_REGISTRY } = await import('../provider-registry-
|
|
1188
|
+
const { PROVIDER_REGISTRY } = await import('../provider-registry-GPH6SHFV.js');
|
|
1189
1189
|
if (!PROVIDER_REGISTRY) return [];
|
|
1190
1190
|
const registry = PROVIDER_REGISTRY;
|
|
1191
1191
|
const providers = Object.keys(registry);
|
|
@@ -1244,7 +1244,7 @@ var Harness = class {
|
|
|
1244
1244
|
}
|
|
1245
1245
|
async getProviderApiKeyEnvVar(provider) {
|
|
1246
1246
|
try {
|
|
1247
|
-
const { PROVIDER_REGISTRY } = await import('../provider-registry-
|
|
1247
|
+
const { PROVIDER_REGISTRY } = await import('../provider-registry-GPH6SHFV.js');
|
|
1248
1248
|
const registry = PROVIDER_REGISTRY;
|
|
1249
1249
|
const envVars = registry[provider]?.apiKeyEnvVar;
|
|
1250
1250
|
return Array.isArray(envVars) ? envVars[0] : envVars;
|
package/dist/index.cjs
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var chunkBSC4D3AA_cjs = require('./chunk-BSC4D3AA.cjs');
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
|
|
7
7
|
Object.defineProperty(exports, "Mastra", {
|
|
8
8
|
enumerable: true,
|
|
9
|
-
get: function () { return
|
|
9
|
+
get: function () { return chunkBSC4D3AA_cjs.Mastra; }
|
|
10
10
|
});
|
|
11
11
|
//# sourceMappingURL=index.cjs.map
|
|
12
12
|
//# sourceMappingURL=index.cjs.map
|
package/dist/index.js
CHANGED
package/dist/llm/index.cjs
CHANGED
|
@@ -1,72 +1,72 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
4
|
-
var
|
|
5
|
-
var
|
|
6
|
-
var
|
|
7
|
-
var
|
|
3
|
+
var chunkCHGGDYI6_cjs = require('../chunk-CHGGDYI6.cjs');
|
|
4
|
+
var chunkC6M5HBBX_cjs = require('../chunk-C6M5HBBX.cjs');
|
|
5
|
+
var chunkVUY4QAW4_cjs = require('../chunk-VUY4QAW4.cjs');
|
|
6
|
+
var chunkGB2CQKRS_cjs = require('../chunk-GB2CQKRS.cjs');
|
|
7
|
+
var chunk2YN2GWML_cjs = require('../chunk-2YN2GWML.cjs');
|
|
8
8
|
|
|
9
9
|
|
|
10
10
|
|
|
11
11
|
Object.defineProperty(exports, "AzureOpenAIGateway", {
|
|
12
12
|
enumerable: true,
|
|
13
|
-
get: function () { return
|
|
13
|
+
get: function () { return chunkCHGGDYI6_cjs.AzureOpenAIGateway; }
|
|
14
14
|
});
|
|
15
15
|
Object.defineProperty(exports, "EMBEDDING_MODELS", {
|
|
16
16
|
enumerable: true,
|
|
17
|
-
get: function () { return
|
|
17
|
+
get: function () { return chunkCHGGDYI6_cjs.EMBEDDING_MODELS; }
|
|
18
18
|
});
|
|
19
19
|
Object.defineProperty(exports, "ModelRouterEmbeddingModel", {
|
|
20
20
|
enumerable: true,
|
|
21
|
-
get: function () { return
|
|
21
|
+
get: function () { return chunkCHGGDYI6_cjs.ModelRouterEmbeddingModel; }
|
|
22
22
|
});
|
|
23
23
|
Object.defineProperty(exports, "ModelRouterLanguageModel", {
|
|
24
24
|
enumerable: true,
|
|
25
|
-
get: function () { return
|
|
25
|
+
get: function () { return chunkCHGGDYI6_cjs.ModelRouterLanguageModel; }
|
|
26
26
|
});
|
|
27
27
|
Object.defineProperty(exports, "defaultGateways", {
|
|
28
28
|
enumerable: true,
|
|
29
|
-
get: function () { return
|
|
29
|
+
get: function () { return chunkCHGGDYI6_cjs.defaultGateways; }
|
|
30
30
|
});
|
|
31
31
|
Object.defineProperty(exports, "resolveModelConfig", {
|
|
32
32
|
enumerable: true,
|
|
33
|
-
get: function () { return
|
|
33
|
+
get: function () { return chunkCHGGDYI6_cjs.resolveModelConfig; }
|
|
34
34
|
});
|
|
35
35
|
Object.defineProperty(exports, "GatewayRegistry", {
|
|
36
36
|
enumerable: true,
|
|
37
|
-
get: function () { return
|
|
37
|
+
get: function () { return chunkC6M5HBBX_cjs.GatewayRegistry; }
|
|
38
38
|
});
|
|
39
39
|
Object.defineProperty(exports, "MastraGateway", {
|
|
40
40
|
enumerable: true,
|
|
41
|
-
get: function () { return
|
|
41
|
+
get: function () { return chunkC6M5HBBX_cjs.MastraGateway; }
|
|
42
42
|
});
|
|
43
43
|
Object.defineProperty(exports, "PROVIDER_REGISTRY", {
|
|
44
44
|
enumerable: true,
|
|
45
|
-
get: function () { return
|
|
45
|
+
get: function () { return chunkC6M5HBBX_cjs.PROVIDER_REGISTRY; }
|
|
46
46
|
});
|
|
47
47
|
Object.defineProperty(exports, "getProviderConfig", {
|
|
48
48
|
enumerable: true,
|
|
49
|
-
get: function () { return
|
|
49
|
+
get: function () { return chunkC6M5HBBX_cjs.getProviderConfig; }
|
|
50
50
|
});
|
|
51
51
|
Object.defineProperty(exports, "parseModelString", {
|
|
52
52
|
enumerable: true,
|
|
53
|
-
get: function () { return
|
|
53
|
+
get: function () { return chunkC6M5HBBX_cjs.parseModelString; }
|
|
54
54
|
});
|
|
55
55
|
Object.defineProperty(exports, "ModelsDevGateway", {
|
|
56
56
|
enumerable: true,
|
|
57
|
-
get: function () { return
|
|
57
|
+
get: function () { return chunkVUY4QAW4_cjs.ModelsDevGateway; }
|
|
58
58
|
});
|
|
59
59
|
Object.defineProperty(exports, "NetlifyGateway", {
|
|
60
60
|
enumerable: true,
|
|
61
|
-
get: function () { return
|
|
61
|
+
get: function () { return chunkGB2CQKRS_cjs.NetlifyGateway; }
|
|
62
62
|
});
|
|
63
63
|
Object.defineProperty(exports, "GATEWAY_AUTH_HEADER", {
|
|
64
64
|
enumerable: true,
|
|
65
|
-
get: function () { return
|
|
65
|
+
get: function () { return chunk2YN2GWML_cjs.GATEWAY_AUTH_HEADER; }
|
|
66
66
|
});
|
|
67
67
|
Object.defineProperty(exports, "MastraModelGateway", {
|
|
68
68
|
enumerable: true,
|
|
69
|
-
get: function () { return
|
|
69
|
+
get: function () { return chunk2YN2GWML_cjs.MastraModelGateway; }
|
|
70
70
|
});
|
|
71
71
|
//# sourceMappingURL=index.cjs.map
|
|
72
72
|
//# sourceMappingURL=index.cjs.map
|
package/dist/llm/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
export { AzureOpenAIGateway, EMBEDDING_MODELS, ModelRouterEmbeddingModel, ModelRouterLanguageModel, defaultGateways, resolveModelConfig } from '../chunk-
|
|
2
|
-
export { GatewayRegistry, MastraGateway, PROVIDER_REGISTRY, getProviderConfig, parseModelString } from '../chunk-
|
|
3
|
-
export { ModelsDevGateway } from '../chunk-
|
|
4
|
-
export { NetlifyGateway } from '../chunk-
|
|
5
|
-
export { GATEWAY_AUTH_HEADER, MastraModelGateway } from '../chunk-
|
|
1
|
+
export { AzureOpenAIGateway, EMBEDDING_MODELS, ModelRouterEmbeddingModel, ModelRouterLanguageModel, defaultGateways, resolveModelConfig } from '../chunk-GQDJFBVF.js';
|
|
2
|
+
export { GatewayRegistry, MastraGateway, PROVIDER_REGISTRY, getProviderConfig, parseModelString } from '../chunk-L4Q63LCX.js';
|
|
3
|
+
export { ModelsDevGateway } from '../chunk-3OIXD6QZ.js';
|
|
4
|
+
export { NetlifyGateway } from '../chunk-UGRXTMCT.js';
|
|
5
|
+
export { GATEWAY_AUTH_HEADER, MastraModelGateway } from '../chunk-JOA5YBHN.js';
|
|
6
6
|
//# sourceMappingURL=index.js.map
|
|
7
7
|
//# sourceMappingURL=index.js.map
|
|
@@ -1041,6 +1041,7 @@ export type ProviderModelsMap = {
|
|
|
1041
1041
|
'poolside/laguna-xs.2:free',
|
|
1042
1042
|
'prime-intellect/intellect-3',
|
|
1043
1043
|
'qwen/qwen-2.5-coder-32b-instruct',
|
|
1044
|
+
'qwen/qwen-3.6-27b',
|
|
1044
1045
|
'qwen/qwen2.5-vl-72b-instruct',
|
|
1045
1046
|
'qwen/qwen3-235b-a22b-07-25',
|
|
1046
1047
|
'qwen/qwen3-235b-a22b-thinking-2507',
|
|
@@ -1671,6 +1672,7 @@ export type ProviderModelsMap = {
|
|
|
1671
1672
|
'anthropic/claude-4-opus',
|
|
1672
1673
|
'deepseek-ai/DeepSeek-R1-0528',
|
|
1673
1674
|
'deepseek-ai/DeepSeek-V3.2',
|
|
1675
|
+
'deepseek-ai/DeepSeek-V4-Flash',
|
|
1674
1676
|
'deepseek-ai/DeepSeek-V4-Pro',
|
|
1675
1677
|
'google/gemma-4-26B-A4B-it',
|
|
1676
1678
|
'google/gemma-4-31B-it',
|
|
@@ -2917,6 +2919,7 @@ export type ProviderModelsMap = {
|
|
|
2917
2919
|
'glm-5',
|
|
2918
2920
|
'gte-large-en-v1.5',
|
|
2919
2921
|
'kimi-k2.5',
|
|
2922
|
+
'kimi-k2.6',
|
|
2920
2923
|
'llama-4-maverick',
|
|
2921
2924
|
'llama-guard-4-12b',
|
|
2922
2925
|
'llama3.3-70b-instruct',
|
|
@@ -3950,6 +3953,7 @@ export type ProviderModelsMap = {
|
|
|
3950
3953
|
'gemini/gemini-3.1-pro-preview-customtools',
|
|
3951
3954
|
'gemini/gemini-flash-latest',
|
|
3952
3955
|
'gemini/gemini-flash-lite-latest',
|
|
3956
|
+
'openai/chat-latest',
|
|
3953
3957
|
'openai/gpt-4.1',
|
|
3954
3958
|
'openai/gpt-4.1-mini',
|
|
3955
3959
|
'openai/gpt-4.1-nano',
|
package/dist/loop/index.cjs
CHANGED
|
@@ -1,60 +1,60 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var chunkPA73DY5B_cjs = require('../chunk-PA73DY5B.cjs');
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
|
|
7
7
|
Object.defineProperty(exports, "createScorer", {
|
|
8
8
|
enumerable: true,
|
|
9
|
-
get: function () { return
|
|
9
|
+
get: function () { return chunkPA73DY5B_cjs.createScorer; }
|
|
10
10
|
});
|
|
11
11
|
Object.defineProperty(exports, "formatCheckFeedback", {
|
|
12
12
|
enumerable: true,
|
|
13
|
-
get: function () { return
|
|
13
|
+
get: function () { return chunkPA73DY5B_cjs.formatCheckFeedback; }
|
|
14
14
|
});
|
|
15
15
|
Object.defineProperty(exports, "formatCompletionFeedback", {
|
|
16
16
|
enumerable: true,
|
|
17
|
-
get: function () { return
|
|
17
|
+
get: function () { return chunkPA73DY5B_cjs.formatCompletionFeedback; }
|
|
18
18
|
});
|
|
19
19
|
Object.defineProperty(exports, "formatStreamCompletionFeedback", {
|
|
20
20
|
enumerable: true,
|
|
21
|
-
get: function () { return
|
|
21
|
+
get: function () { return chunkPA73DY5B_cjs.formatStreamCompletionFeedback; }
|
|
22
22
|
});
|
|
23
23
|
Object.defineProperty(exports, "formatValidationFeedback", {
|
|
24
24
|
enumerable: true,
|
|
25
|
-
get: function () { return
|
|
25
|
+
get: function () { return chunkPA73DY5B_cjs.formatValidationFeedback; }
|
|
26
26
|
});
|
|
27
27
|
Object.defineProperty(exports, "generateFinalResult", {
|
|
28
28
|
enumerable: true,
|
|
29
|
-
get: function () { return
|
|
29
|
+
get: function () { return chunkPA73DY5B_cjs.generateFinalResult; }
|
|
30
30
|
});
|
|
31
31
|
Object.defineProperty(exports, "generateStructuredFinalResult", {
|
|
32
32
|
enumerable: true,
|
|
33
|
-
get: function () { return
|
|
33
|
+
get: function () { return chunkPA73DY5B_cjs.generateStructuredFinalResult; }
|
|
34
34
|
});
|
|
35
35
|
Object.defineProperty(exports, "loop", {
|
|
36
36
|
enumerable: true,
|
|
37
|
-
get: function () { return
|
|
37
|
+
get: function () { return chunkPA73DY5B_cjs.loop; }
|
|
38
38
|
});
|
|
39
39
|
Object.defineProperty(exports, "runChecks", {
|
|
40
40
|
enumerable: true,
|
|
41
|
-
get: function () { return
|
|
41
|
+
get: function () { return chunkPA73DY5B_cjs.runChecks; }
|
|
42
42
|
});
|
|
43
43
|
Object.defineProperty(exports, "runCompletionScorers", {
|
|
44
44
|
enumerable: true,
|
|
45
|
-
get: function () { return
|
|
45
|
+
get: function () { return chunkPA73DY5B_cjs.runCompletionScorers; }
|
|
46
46
|
});
|
|
47
47
|
Object.defineProperty(exports, "runDefaultCompletionCheck", {
|
|
48
48
|
enumerable: true,
|
|
49
|
-
get: function () { return
|
|
49
|
+
get: function () { return chunkPA73DY5B_cjs.runDefaultCompletionCheck; }
|
|
50
50
|
});
|
|
51
51
|
Object.defineProperty(exports, "runStreamCompletionScorers", {
|
|
52
52
|
enumerable: true,
|
|
53
|
-
get: function () { return
|
|
53
|
+
get: function () { return chunkPA73DY5B_cjs.runStreamCompletionScorers; }
|
|
54
54
|
});
|
|
55
55
|
Object.defineProperty(exports, "runValidation", {
|
|
56
56
|
enumerable: true,
|
|
57
|
-
get: function () { return
|
|
57
|
+
get: function () { return chunkPA73DY5B_cjs.runValidation; }
|
|
58
58
|
});
|
|
59
59
|
//# sourceMappingURL=index.cjs.map
|
|
60
60
|
//# sourceMappingURL=index.cjs.map
|
package/dist/loop/index.js
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export { createScorer, formatCheckFeedback, formatCompletionFeedback, formatStreamCompletionFeedback, formatValidationFeedback, generateFinalResult, generateStructuredFinalResult, loop, runChecks, runCompletionScorers, runDefaultCompletionCheck, runStreamCompletionScorers, runValidation } from '../chunk-
|
|
1
|
+
export { createScorer, formatCheckFeedback, formatCompletionFeedback, formatStreamCompletionFeedback, formatValidationFeedback, generateFinalResult, generateStructuredFinalResult, loop, runChecks, runCompletionScorers, runDefaultCompletionCheck, runStreamCompletionScorers, runValidation } from '../chunk-5LXIX7FZ.js';
|
|
2
2
|
//# sourceMappingURL=index.js.map
|
|
3
3
|
//# sourceMappingURL=index.js.map
|