@mastra/server 0.0.0-message-list-update-20250715150321 → 0.0.0-monorepo-binary-20251013210052
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 +4009 -0
- package/README.md +0 -5
- package/dist/chunk-2PLXW4ZX.cjs +2777 -0
- package/dist/chunk-2PLXW4ZX.cjs.map +1 -0
- package/dist/chunk-2S4IMB6E.cjs +130 -0
- package/dist/chunk-2S4IMB6E.cjs.map +1 -0
- package/dist/chunk-3LGGSMCC.cjs +256 -0
- package/dist/chunk-3LGGSMCC.cjs.map +1 -0
- package/dist/chunk-3LTO44EP.cjs +570 -0
- package/dist/chunk-3LTO44EP.cjs.map +1 -0
- package/dist/chunk-3SNGNFUJ.cjs +128 -0
- package/dist/chunk-3SNGNFUJ.cjs.map +1 -0
- package/dist/{chunk-RSEO4XPX.js → chunk-4QCXUEAT.js} +11 -2
- package/dist/chunk-4QCXUEAT.js.map +1 -0
- package/dist/chunk-5BNQIYQN.js +189 -0
- package/dist/chunk-5BNQIYQN.js.map +1 -0
- package/dist/{chunk-RG473F6Y.js → chunk-67GYDFSB.js} +24 -5
- package/dist/chunk-67GYDFSB.js.map +1 -0
- package/dist/chunk-6BMOC6SA.cjs +48 -0
- package/dist/chunk-6BMOC6SA.cjs.map +1 -0
- package/dist/{chunk-G7KH752Y.cjs → chunk-6ZR275MD.cjs} +28 -8
- package/dist/chunk-6ZR275MD.cjs.map +1 -0
- package/dist/{chunk-2KZFMI6P.cjs → chunk-7NADHFD2.cjs} +2 -0
- package/dist/chunk-7NADHFD2.cjs.map +1 -0
- package/dist/{chunk-4D66QEKC.js → chunk-ABRFV4XP.js} +5 -3
- package/dist/chunk-ABRFV4XP.js.map +1 -0
- package/dist/{chunk-LRCAAFUA.js → chunk-AHB4JCIQ.js} +50 -12
- package/dist/chunk-AHB4JCIQ.js.map +1 -0
- package/dist/chunk-BATEJLED.js +124 -0
- package/dist/chunk-BATEJLED.js.map +1 -0
- package/dist/chunk-BZLZFHAT.cjs +682 -0
- package/dist/chunk-BZLZFHAT.cjs.map +1 -0
- package/dist/{chunk-LF7P5PLR.js → chunk-CY4TP3FK.js} +3 -1
- package/dist/chunk-CY4TP3FK.js.map +1 -0
- package/dist/{chunk-H7DMHBKY.js → chunk-DB63UMTV.js} +249 -87
- package/dist/chunk-DB63UMTV.js.map +1 -0
- package/dist/chunk-DTBJ3D22.js +19480 -0
- package/dist/chunk-DTBJ3D22.js.map +1 -0
- package/dist/{chunk-7TP2LX5L.cjs → chunk-EP3JQDPD.cjs} +20 -18
- package/dist/chunk-EP3JQDPD.cjs.map +1 -0
- package/dist/chunk-G4PUALCE.cjs +28 -0
- package/dist/chunk-G4PUALCE.cjs.map +1 -0
- package/dist/chunk-GU4EWMZB.cjs +769 -0
- package/dist/chunk-GU4EWMZB.cjs.map +1 -0
- package/dist/chunk-H2CO44WB.js +46 -0
- package/dist/chunk-H2CO44WB.js.map +1 -0
- package/dist/{chunk-GHC4YV6R.js → chunk-HPXAM2PG.js} +109 -136
- package/dist/chunk-HPXAM2PG.js.map +1 -0
- package/dist/{chunk-JMLYCXMK.cjs → chunk-I3C4ODGV.cjs} +48 -45
- package/dist/chunk-I3C4ODGV.cjs.map +1 -0
- package/dist/chunk-JSLAYFEW.js +662 -0
- package/dist/chunk-JSLAYFEW.js.map +1 -0
- package/dist/chunk-KQZPT7AO.js +254 -0
- package/dist/chunk-KQZPT7AO.js.map +1 -0
- package/dist/chunk-LF2ZLOFP.js +767 -0
- package/dist/chunk-LF2ZLOFP.js.map +1 -0
- package/dist/{chunk-5PQQ42EZ.js → chunk-LLUOPR3J.js} +13 -10
- package/dist/chunk-LLUOPR3J.js.map +1 -0
- package/dist/chunk-LNT5N7XW.cjs +197 -0
- package/dist/chunk-LNT5N7XW.cjs.map +1 -0
- package/dist/chunk-LPM6BBAX.cjs +1043 -0
- package/dist/chunk-LPM6BBAX.cjs.map +1 -0
- package/dist/{chunk-LCM566I4.js → chunk-MMROOK5J.js} +2 -0
- package/dist/chunk-MMROOK5J.js.map +1 -0
- package/dist/chunk-MQDBNHBT.cjs +680 -0
- package/dist/chunk-MQDBNHBT.cjs.map +1 -0
- package/dist/{chunk-WNVFNNWN.js → chunk-MYR4PVGN.js} +5 -3
- package/dist/chunk-MYR4PVGN.js.map +1 -0
- package/dist/chunk-O7I5CWRX.cjs +44 -0
- package/dist/chunk-O7I5CWRX.cjs.map +1 -0
- package/dist/chunk-OEOGYAQC.js +553 -0
- package/dist/chunk-OEOGYAQC.js.map +1 -0
- package/dist/chunk-PR4QN5HX.js +39 -0
- package/dist/chunk-PR4QN5HX.js.map +1 -0
- package/dist/{chunk-KHZKYUNR.js → chunk-QQXMIP6C.js} +23 -13
- package/dist/chunk-QQXMIP6C.js.map +1 -0
- package/dist/{chunk-PZQDCRPV.cjs → chunk-RE4RPXT2.cjs} +4 -2
- package/dist/chunk-RE4RPXT2.cjs.map +1 -0
- package/dist/chunk-RQK4FQUD.js +1012 -0
- package/dist/chunk-RQK4FQUD.js.map +1 -0
- package/dist/chunk-SBWOUCO3.cjs +19516 -0
- package/dist/chunk-SBWOUCO3.cjs.map +1 -0
- package/dist/{chunk-SDPGVWQJ.cjs → chunk-TOP25AIO.cjs} +110 -137
- package/dist/chunk-TOP25AIO.cjs.map +1 -0
- package/dist/chunk-TRGAMKHX.cjs +167 -0
- package/dist/chunk-TRGAMKHX.cjs.map +1 -0
- package/dist/chunk-VY4ENABS.cjs +135 -0
- package/dist/chunk-VY4ENABS.cjs.map +1 -0
- package/dist/{chunk-QGX47B5D.cjs → chunk-XN74I6VW.cjs} +11 -9
- package/dist/chunk-XN74I6VW.cjs.map +1 -0
- package/dist/chunk-YWOK4F5A.js +131 -0
- package/dist/chunk-YWOK4F5A.js.map +1 -0
- package/dist/chunk-ZULZ2752.js +2774 -0
- package/dist/chunk-ZULZ2752.js.map +1 -0
- package/dist/dist-4MVGNSRL.cjs +1150 -0
- package/dist/dist-4MVGNSRL.cjs.map +1 -0
- package/dist/dist-FZYCV3VB.cjs +940 -0
- package/dist/dist-FZYCV3VB.cjs.map +1 -0
- package/dist/dist-G2BYZJOC.cjs +928 -0
- package/dist/dist-G2BYZJOC.cjs.map +1 -0
- package/dist/dist-P4MXBQ3U.cjs +16 -0
- package/dist/dist-P4MXBQ3U.cjs.map +1 -0
- package/dist/dist-PQZUVLPC.js +937 -0
- package/dist/dist-PQZUVLPC.js.map +1 -0
- package/dist/dist-R7WYX6LC.js +925 -0
- package/dist/dist-R7WYX6LC.js.map +1 -0
- package/dist/dist-RFMYFILX.cjs +764 -0
- package/dist/dist-RFMYFILX.cjs.map +1 -0
- package/dist/dist-X7XR3M3Z.js +1147 -0
- package/dist/dist-X7XR3M3Z.js.map +1 -0
- package/dist/dist-XVBSOGFK.js +761 -0
- package/dist/dist-XVBSOGFK.js.map +1 -0
- package/dist/dist-YREX2TJT.js +3 -0
- package/dist/dist-YREX2TJT.js.map +1 -0
- package/dist/index.cjs +6 -0
- package/dist/index.cjs.map +1 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +5 -0
- package/dist/index.js.map +1 -0
- package/dist/server/a2a/protocol.d.ts +8 -0
- package/dist/server/a2a/protocol.d.ts.map +1 -0
- package/dist/server/a2a/store.cjs +25 -0
- package/dist/server/a2a/store.cjs.map +1 -0
- package/dist/server/a2a/store.d.ts +14 -0
- package/dist/server/a2a/store.d.ts.map +1 -0
- package/dist/server/a2a/store.js +23 -0
- package/dist/server/a2a/store.js.map +1 -0
- package/dist/server/a2a/tasks.d.ts +20 -0
- package/dist/server/a2a/tasks.d.ts.map +1 -0
- package/dist/server/handlers/a2a.cjs +13 -11
- package/dist/server/handlers/a2a.cjs.map +1 -0
- package/dist/server/handlers/a2a.d.ts +68 -6
- package/dist/server/handlers/a2a.d.ts.map +1 -0
- package/dist/server/handlers/a2a.js +3 -1
- package/dist/server/handlers/a2a.js.map +1 -0
- package/dist/server/handlers/agent-builder.cjs +68 -0
- package/dist/server/handlers/agent-builder.cjs.map +1 -0
- package/dist/server/handlers/agent-builder.d.ts +94 -0
- package/dist/server/handlers/agent-builder.d.ts.map +1 -0
- package/dist/server/handlers/agent-builder.js +3 -0
- package/dist/server/handlers/agent-builder.js.map +1 -0
- package/dist/server/handlers/agents.cjs +57 -7
- package/dist/server/handlers/agents.cjs.map +1 -0
- package/dist/server/handlers/agents.d.ts +204 -6
- package/dist/server/handlers/agents.d.ts.map +1 -0
- package/dist/server/handlers/agents.js +3 -1
- package/dist/server/handlers/agents.js.map +1 -0
- package/dist/server/handlers/error.cjs +4 -2
- package/dist/server/handlers/error.cjs.map +1 -0
- package/dist/server/handlers/error.d.ts +2 -1
- package/dist/server/handlers/error.d.ts.map +1 -0
- package/dist/server/handlers/error.js +3 -1
- package/dist/server/handlers/error.js.map +1 -0
- package/dist/server/handlers/legacyWorkflows.cjs +13 -11
- package/dist/server/handlers/legacyWorkflows.cjs.map +1 -0
- package/dist/server/handlers/legacyWorkflows.d.ts +59 -10
- package/dist/server/handlers/legacyWorkflows.d.ts.map +1 -0
- package/dist/server/handlers/legacyWorkflows.js +3 -1
- package/dist/server/handlers/legacyWorkflows.js.map +1 -0
- package/dist/server/handlers/logs.cjs +6 -4
- package/dist/server/handlers/logs.cjs.map +1 -0
- package/dist/server/handlers/logs.d.ts +34 -3
- package/dist/server/handlers/logs.d.ts.map +1 -0
- package/dist/server/handlers/logs.js +3 -1
- package/dist/server/handlers/logs.js.map +1 -0
- package/dist/server/handlers/memory.cjs +33 -11
- package/dist/server/handlers/memory.cjs.map +1 -0
- package/dist/server/handlers/memory.d.ts +118 -10
- package/dist/server/handlers/memory.d.ts.map +1 -0
- package/dist/server/handlers/memory.js +3 -1
- package/dist/server/handlers/memory.js.map +1 -0
- package/dist/server/handlers/observability.cjs +24 -0
- package/dist/server/handlers/observability.cjs.map +1 -0
- package/dist/server/handlers/observability.d.ts +49 -0
- package/dist/server/handlers/observability.d.ts.map +1 -0
- package/dist/server/handlers/observability.js +3 -0
- package/dist/server/handlers/observability.js.map +1 -0
- package/dist/server/handlers/scores.cjs +32 -0
- package/dist/server/handlers/scores.cjs.map +1 -0
- package/dist/server/handlers/scores.d.ts +251 -0
- package/dist/server/handlers/scores.d.ts.map +1 -0
- package/dist/server/handlers/scores.js +3 -0
- package/dist/server/handlers/scores.js.map +1 -0
- package/dist/server/handlers/telemetry.cjs +9 -3
- package/dist/server/handlers/telemetry.cjs.map +1 -0
- package/dist/server/handlers/telemetry.d.ts +33 -2
- package/dist/server/handlers/telemetry.d.ts.map +1 -0
- package/dist/server/handlers/telemetry.js +3 -1
- package/dist/server/handlers/telemetry.js.map +1 -0
- package/dist/server/handlers/tools.cjs +11 -5
- package/dist/server/handlers/tools.cjs.map +1 -0
- package/dist/server/handlers/tools.d.ts +25 -4
- package/dist/server/handlers/tools.d.ts.map +1 -0
- package/dist/server/handlers/tools.js +3 -1
- package/dist/server/handlers/tools.js.map +1 -0
- package/dist/server/handlers/utils.cjs +8 -2
- package/dist/server/handlers/utils.cjs.map +1 -0
- package/dist/server/handlers/utils.d.ts +8 -1
- package/dist/server/handlers/utils.d.ts.map +1 -0
- package/dist/server/handlers/utils.js +3 -1
- package/dist/server/handlers/utils.js.map +1 -0
- package/dist/server/handlers/vector.cjs +9 -7
- package/dist/server/handlers/vector.cjs.map +1 -0
- package/dist/server/handlers/vector.d.ts +51 -6
- package/dist/server/handlers/vector.d.ts.map +1 -0
- package/dist/server/handlers/vector.js +3 -1
- package/dist/server/handlers/vector.js.map +1 -0
- package/dist/server/handlers/voice.cjs +7 -5
- package/dist/server/handlers/voice.cjs.map +1 -0
- package/dist/server/handlers/voice.d.ts +41 -4
- package/dist/server/handlers/voice.d.ts.map +1 -0
- package/dist/server/handlers/voice.js +3 -1
- package/dist/server/handlers/voice.js.map +1 -0
- package/dist/server/handlers/workflows.cjs +33 -15
- package/dist/server/handlers/workflows.cjs.map +1 -0
- package/dist/server/handlers/workflows.d.ts +91 -14
- package/dist/server/handlers/workflows.d.ts.map +1 -0
- package/dist/server/handlers/workflows.js +3 -1
- package/dist/server/handlers/workflows.js.map +1 -0
- package/dist/server/handlers.cjs +44 -32
- package/dist/server/handlers.cjs.map +1 -0
- package/dist/server/handlers.d.ts +14 -11
- package/dist/server/handlers.d.ts.map +1 -0
- package/dist/server/handlers.js +15 -11
- package/dist/server/handlers.js.map +1 -0
- package/dist/server/http-exception.d.ts +87 -0
- package/dist/server/http-exception.d.ts.map +1 -0
- package/dist/server/types.d.ts +10 -0
- package/dist/server/types.d.ts.map +1 -0
- package/dist/server/utils.d.ts +44 -0
- package/dist/server/utils.d.ts.map +1 -0
- package/dist/token-352SFL4N.js +62 -0
- package/dist/token-352SFL4N.js.map +1 -0
- package/dist/token-JT637FZG.cjs +64 -0
- package/dist/token-JT637FZG.cjs.map +1 -0
- package/dist/token-util-75OQWZ4W.js +7 -0
- package/dist/token-util-75OQWZ4W.js.map +1 -0
- package/dist/token-util-WGALAXWM.cjs +9 -0
- package/dist/token-util-WGALAXWM.cjs.map +1 -0
- package/package.json +37 -14
- package/dist/_tsup-dts-rollup.d.cts +0 -1107
- package/dist/_tsup-dts-rollup.d.ts +0 -1107
- package/dist/chunk-2SLFAFTR.cjs +0 -148
- package/dist/chunk-3CNDE7QY.cjs +0 -308
- package/dist/chunk-75ZPJI57.cjs +0 -9
- package/dist/chunk-B2PAS2IB.cjs +0 -514
- package/dist/chunk-BK4XT6EG.js +0 -270
- package/dist/chunk-CCGRCYWJ.cjs +0 -18
- package/dist/chunk-CRCR3ZUK.js +0 -142
- package/dist/chunk-FRVBFMO2.cjs +0 -128
- package/dist/chunk-KOHWJYJT.js +0 -296
- package/dist/chunk-LI436ITD.cjs +0 -2042
- package/dist/chunk-LZ3VJXSO.cjs +0 -278
- package/dist/chunk-MEGCYGBU.js +0 -2039
- package/dist/chunk-MLKGABMK.js +0 -7
- package/dist/chunk-RHSWAXKB.cjs +0 -118
- package/dist/index.d.cts +0 -1
- package/dist/server/handlers/a2a.d.cts +0 -6
- package/dist/server/handlers/agents.d.cts +0 -6
- package/dist/server/handlers/error.d.cts +0 -1
- package/dist/server/handlers/legacyWorkflows.d.cts +0 -10
- package/dist/server/handlers/logs.d.cts +0 -3
- package/dist/server/handlers/memory.d.cts +0 -10
- package/dist/server/handlers/network.cjs +0 -22
- package/dist/server/handlers/network.d.cts +0 -4
- package/dist/server/handlers/network.d.ts +0 -4
- package/dist/server/handlers/network.js +0 -1
- package/dist/server/handlers/telemetry.d.cts +0 -2
- package/dist/server/handlers/tools.d.cts +0 -4
- package/dist/server/handlers/utils.d.cts +0 -1
- package/dist/server/handlers/vNextNetwork.cjs +0 -218
- package/dist/server/handlers/vNextNetwork.d.cts +0 -6
- package/dist/server/handlers/vNextNetwork.d.ts +0 -6
- package/dist/server/handlers/vNextNetwork.js +0 -211
- package/dist/server/handlers/vector.d.cts +0 -6
- package/dist/server/handlers/voice.d.cts +0 -4
- package/dist/server/handlers/workflows.d.cts +0 -14
- package/dist/server/handlers.d.cts +0 -11
|
@@ -1,46 +1,68 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var chunk3LTO44EP_cjs = require('../../chunk-3LTO44EP.cjs');
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
|
|
7
7
|
Object.defineProperty(exports, "createThreadHandler", {
|
|
8
8
|
enumerable: true,
|
|
9
|
-
get: function () { return
|
|
9
|
+
get: function () { return chunk3LTO44EP_cjs.createThreadHandler; }
|
|
10
|
+
});
|
|
11
|
+
Object.defineProperty(exports, "deleteMessagesHandler", {
|
|
12
|
+
enumerable: true,
|
|
13
|
+
get: function () { return chunk3LTO44EP_cjs.deleteMessagesHandler; }
|
|
10
14
|
});
|
|
11
15
|
Object.defineProperty(exports, "deleteThreadHandler", {
|
|
12
16
|
enumerable: true,
|
|
13
|
-
get: function () { return
|
|
17
|
+
get: function () { return chunk3LTO44EP_cjs.deleteThreadHandler; }
|
|
18
|
+
});
|
|
19
|
+
Object.defineProperty(exports, "getMemoryConfigHandler", {
|
|
20
|
+
enumerable: true,
|
|
21
|
+
get: function () { return chunk3LTO44EP_cjs.getMemoryConfigHandler; }
|
|
14
22
|
});
|
|
15
23
|
Object.defineProperty(exports, "getMemoryStatusHandler", {
|
|
16
24
|
enumerable: true,
|
|
17
|
-
get: function () { return
|
|
25
|
+
get: function () { return chunk3LTO44EP_cjs.getMemoryStatusHandler; }
|
|
18
26
|
});
|
|
19
27
|
Object.defineProperty(exports, "getMessagesHandler", {
|
|
20
28
|
enumerable: true,
|
|
21
|
-
get: function () { return
|
|
29
|
+
get: function () { return chunk3LTO44EP_cjs.getMessagesHandler; }
|
|
30
|
+
});
|
|
31
|
+
Object.defineProperty(exports, "getMessagesPaginatedHandler", {
|
|
32
|
+
enumerable: true,
|
|
33
|
+
get: function () { return chunk3LTO44EP_cjs.getMessagesPaginatedHandler; }
|
|
22
34
|
});
|
|
23
35
|
Object.defineProperty(exports, "getThreadByIdHandler", {
|
|
24
36
|
enumerable: true,
|
|
25
|
-
get: function () { return
|
|
37
|
+
get: function () { return chunk3LTO44EP_cjs.getThreadByIdHandler; }
|
|
26
38
|
});
|
|
27
39
|
Object.defineProperty(exports, "getThreadsHandler", {
|
|
28
40
|
enumerable: true,
|
|
29
|
-
get: function () { return
|
|
41
|
+
get: function () { return chunk3LTO44EP_cjs.getThreadsHandler; }
|
|
42
|
+
});
|
|
43
|
+
Object.defineProperty(exports, "getThreadsPaginatedHandler", {
|
|
44
|
+
enumerable: true,
|
|
45
|
+
get: function () { return chunk3LTO44EP_cjs.getThreadsPaginatedHandler; }
|
|
30
46
|
});
|
|
31
47
|
Object.defineProperty(exports, "getWorkingMemoryHandler", {
|
|
32
48
|
enumerable: true,
|
|
33
|
-
get: function () { return
|
|
49
|
+
get: function () { return chunk3LTO44EP_cjs.getWorkingMemoryHandler; }
|
|
34
50
|
});
|
|
35
51
|
Object.defineProperty(exports, "saveMessagesHandler", {
|
|
36
52
|
enumerable: true,
|
|
37
|
-
get: function () { return
|
|
53
|
+
get: function () { return chunk3LTO44EP_cjs.saveMessagesHandler; }
|
|
54
|
+
});
|
|
55
|
+
Object.defineProperty(exports, "searchMemoryHandler", {
|
|
56
|
+
enumerable: true,
|
|
57
|
+
get: function () { return chunk3LTO44EP_cjs.searchMemoryHandler; }
|
|
38
58
|
});
|
|
39
59
|
Object.defineProperty(exports, "updateThreadHandler", {
|
|
40
60
|
enumerable: true,
|
|
41
|
-
get: function () { return
|
|
61
|
+
get: function () { return chunk3LTO44EP_cjs.updateThreadHandler; }
|
|
42
62
|
});
|
|
43
63
|
Object.defineProperty(exports, "updateWorkingMemoryHandler", {
|
|
44
64
|
enumerable: true,
|
|
45
|
-
get: function () { return
|
|
65
|
+
get: function () { return chunk3LTO44EP_cjs.updateWorkingMemoryHandler; }
|
|
46
66
|
});
|
|
67
|
+
//# sourceMappingURL=memory.cjs.map
|
|
68
|
+
//# sourceMappingURL=memory.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"names":[],"mappings":"","file":"memory.cjs"}
|
|
@@ -1,10 +1,118 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
1
|
+
import type { RuntimeContext } from '@mastra/core/di';
|
|
2
|
+
import type { MastraMemory } from '@mastra/core/memory';
|
|
3
|
+
import type { StorageGetMessagesArg, ThreadSortOptions } from '@mastra/core/storage';
|
|
4
|
+
import type { Context } from '../types.js';
|
|
5
|
+
import { handleError } from './error.js';
|
|
6
|
+
interface MemoryContext extends Context {
|
|
7
|
+
agentId?: string;
|
|
8
|
+
resourceId?: string;
|
|
9
|
+
threadId?: string;
|
|
10
|
+
runtimeContext?: RuntimeContext;
|
|
11
|
+
}
|
|
12
|
+
export declare function getMemoryStatusHandler({ mastra, agentId, runtimeContext, }: Pick<MemoryContext, 'mastra' | 'agentId' | 'runtimeContext'>): Promise<{
|
|
13
|
+
result: boolean;
|
|
14
|
+
}>;
|
|
15
|
+
export declare function getMemoryConfigHandler({ mastra, agentId, runtimeContext, }: Pick<MemoryContext, 'mastra' | 'agentId' | 'runtimeContext'>): Promise<{
|
|
16
|
+
config: import("@mastra/core").MemoryConfig;
|
|
17
|
+
}>;
|
|
18
|
+
export declare function getThreadsHandler({ mastra, agentId, resourceId, runtimeContext, orderBy, sortDirection, }: Pick<MemoryContext, 'mastra' | 'agentId' | 'resourceId' | 'runtimeContext'> & ThreadSortOptions): Promise<import("@mastra/core").StorageThreadType[]>;
|
|
19
|
+
export declare function getThreadsPaginatedHandler({ mastra, agentId, resourceId, runtimeContext, page, perPage, orderBy, sortDirection, }: Pick<MemoryContext, 'mastra' | 'agentId' | 'resourceId' | 'runtimeContext'> & {
|
|
20
|
+
page: number;
|
|
21
|
+
perPage: number;
|
|
22
|
+
} & ThreadSortOptions): Promise<import("@mastra/core").PaginationInfo & {
|
|
23
|
+
threads: import("@mastra/core").StorageThreadType[];
|
|
24
|
+
}>;
|
|
25
|
+
export declare function getThreadByIdHandler({ mastra, agentId, threadId, runtimeContext, }: Pick<MemoryContext, 'mastra' | 'agentId' | 'threadId' | 'runtimeContext'>): Promise<import("@mastra/core").StorageThreadType>;
|
|
26
|
+
export declare function saveMessagesHandler({ mastra, agentId, body, runtimeContext, }: Pick<MemoryContext, 'mastra' | 'agentId' | 'runtimeContext'> & {
|
|
27
|
+
body: {
|
|
28
|
+
messages: Parameters<MastraMemory['saveMessages']>[0]['messages'];
|
|
29
|
+
};
|
|
30
|
+
}): Promise<import("@mastra/core").MastraMessageV1[]>;
|
|
31
|
+
export declare function createThreadHandler({ mastra, agentId, body, runtimeContext, }: Pick<MemoryContext, 'mastra' | 'agentId' | 'runtimeContext'> & {
|
|
32
|
+
body?: Omit<Parameters<MastraMemory['createThread']>[0], 'resourceId'> & {
|
|
33
|
+
resourceId?: string;
|
|
34
|
+
};
|
|
35
|
+
}): Promise<import("@mastra/core").StorageThreadType>;
|
|
36
|
+
export declare function updateThreadHandler({ mastra, agentId, threadId, body, runtimeContext, }: Pick<MemoryContext, 'mastra' | 'agentId' | 'threadId' | 'runtimeContext'> & {
|
|
37
|
+
body?: Parameters<MastraMemory['saveThread']>[0]['thread'];
|
|
38
|
+
}): Promise<import("@mastra/core").StorageThreadType>;
|
|
39
|
+
export declare function deleteThreadHandler({ mastra, agentId, threadId, runtimeContext, }: Pick<MemoryContext, 'mastra' | 'agentId' | 'threadId' | 'runtimeContext'>): Promise<{
|
|
40
|
+
result: string;
|
|
41
|
+
}>;
|
|
42
|
+
export declare function getMessagesPaginatedHandler({ mastra, threadId, resourceId, selectBy, format, }: StorageGetMessagesArg & Pick<MemoryContext, 'mastra'>): Promise<import("@mastra/core").PaginationInfo & {
|
|
43
|
+
messages: import("@mastra/core").MastraMessageV1[] | import("@mastra/core").MastraMessageV2[];
|
|
44
|
+
}>;
|
|
45
|
+
export declare function getMessagesHandler({ mastra, agentId, threadId, limit, runtimeContext, }: Pick<MemoryContext, 'mastra' | 'agentId' | 'threadId' | 'runtimeContext'> & {
|
|
46
|
+
limit?: number;
|
|
47
|
+
}): Promise<{
|
|
48
|
+
messages: import("ai-v4").CoreMessage[];
|
|
49
|
+
uiMessages: import("ai").UIMessage<unknown, import("ai").UIDataTypes, import("ai").UITools>[];
|
|
50
|
+
legacyMessages: import("@mastra/core/agent").UIMessageWithMetadata[];
|
|
51
|
+
}>;
|
|
52
|
+
/**
|
|
53
|
+
* Handler to get the working memory for a thread (optionally resource-scoped).
|
|
54
|
+
* @returns workingMemory - the working memory for the thread
|
|
55
|
+
* @returns source - thread or resource
|
|
56
|
+
*/
|
|
57
|
+
export declare function getWorkingMemoryHandler({ mastra, agentId, threadId, resourceId, runtimeContext, memoryConfig, }: Pick<MemoryContext, 'mastra' | 'agentId' | 'threadId' | 'runtimeContext'> & {
|
|
58
|
+
resourceId?: Parameters<MastraMemory['getWorkingMemory']>[0]['resourceId'];
|
|
59
|
+
memoryConfig?: Parameters<MastraMemory['getWorkingMemory']>[0]['memoryConfig'];
|
|
60
|
+
}): Promise<{
|
|
61
|
+
workingMemory: string | null;
|
|
62
|
+
source: string;
|
|
63
|
+
workingMemoryTemplate: import("@mastra/core").WorkingMemoryTemplate | null;
|
|
64
|
+
threadExists: boolean;
|
|
65
|
+
}>;
|
|
66
|
+
/**
|
|
67
|
+
* Handler to update the working memory for a thread (optionally resource-scoped).
|
|
68
|
+
* @param threadId - the thread id
|
|
69
|
+
* @param body - the body containing the working memory to update and the resource id (optional)
|
|
70
|
+
*/
|
|
71
|
+
export declare function updateWorkingMemoryHandler({ mastra, agentId, threadId, body, runtimeContext, }: Pick<MemoryContext, 'mastra' | 'agentId' | 'threadId' | 'runtimeContext'> & {
|
|
72
|
+
body: Omit<Parameters<MastraMemory['updateWorkingMemory']>[0], 'threadId'>;
|
|
73
|
+
}): Promise<{
|
|
74
|
+
success: boolean;
|
|
75
|
+
}>;
|
|
76
|
+
interface SearchResult {
|
|
77
|
+
id: string;
|
|
78
|
+
role: string;
|
|
79
|
+
content: any;
|
|
80
|
+
createdAt: Date;
|
|
81
|
+
threadId?: string;
|
|
82
|
+
threadTitle?: string;
|
|
83
|
+
score?: number;
|
|
84
|
+
context?: {
|
|
85
|
+
before?: SearchResult[];
|
|
86
|
+
after?: SearchResult[];
|
|
87
|
+
};
|
|
88
|
+
}
|
|
89
|
+
interface SearchResponse {
|
|
90
|
+
results: SearchResult[];
|
|
91
|
+
count: number;
|
|
92
|
+
query: string;
|
|
93
|
+
searchScope?: string;
|
|
94
|
+
searchType?: string;
|
|
95
|
+
}
|
|
96
|
+
/**
|
|
97
|
+
* Handler to delete one or more messages.
|
|
98
|
+
* @param messageIds - Can be a single ID, array of IDs, or objects with ID property
|
|
99
|
+
*/
|
|
100
|
+
export declare function deleteMessagesHandler({ mastra, agentId, messageIds, runtimeContext, }: Pick<MemoryContext, 'mastra' | 'agentId' | 'runtimeContext'> & {
|
|
101
|
+
messageIds: string | string[] | {
|
|
102
|
+
id: string;
|
|
103
|
+
} | {
|
|
104
|
+
id: string;
|
|
105
|
+
}[];
|
|
106
|
+
}): Promise<{
|
|
107
|
+
success: boolean;
|
|
108
|
+
message: string;
|
|
109
|
+
}>;
|
|
110
|
+
export declare function searchMemoryHandler({ mastra, agentId, searchQuery, resourceId, threadId, limit, runtimeContext, memoryConfig, }: Pick<MemoryContext, 'mastra' | 'agentId' | 'runtimeContext'> & {
|
|
111
|
+
searchQuery: string;
|
|
112
|
+
resourceId: string;
|
|
113
|
+
threadId?: string;
|
|
114
|
+
limit?: number;
|
|
115
|
+
memoryConfig?: any;
|
|
116
|
+
}): Promise<SearchResponse | ReturnType<typeof handleError>>;
|
|
117
|
+
export {};
|
|
118
|
+
//# sourceMappingURL=memory.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"memory.d.ts","sourceRoot":"","sources":["../../../src/server/handlers/memory.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAC;AACtD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AACxD,OAAO,KAAK,EAAE,qBAAqB,EAAE,iBAAiB,EAAE,MAAM,sBAAsB,CAAC;AAGrF,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,UAAU,CAAC;AAExC,OAAO,EAAE,WAAW,EAAE,MAAM,SAAS,CAAC;AAGtC,UAAU,aAAc,SAAQ,OAAO;IACrC,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,cAAc,CAAC,EAAE,cAAc,CAAC;CACjC;AAwBD,wBAAsB,sBAAsB,CAAC,EAC3C,MAAM,EACN,OAAO,EACP,cAAc,GACf,EAAE,IAAI,CAAC,aAAa,EAAE,QAAQ,GAAG,SAAS,GAAG,gBAAgB,CAAC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C,EAC1C,MAAM,EACN,OAAO,EACP,UAAU,EACV,cAAc,GACf,EAAE,IAAI,CAAC,aAAa,EAAE,QAAQ,GAAG,SAAS,GAAG,gBAAgB,CAAC,GAAG;IAChE,UAAU,EAAE,MAAM,GAAG,MAAM,EAAE,GAAG;QAAE,EAAE,EAAE,MAAM,CAAA;KAAE,GAAG;QAAE,EAAE,EAAE,MAAM,CAAA;KAAE,EAAE,CAAC;CACnE;;;GAwBA;AAED,wBAAsB,mBAAmB,CAAC,EACxC,MAAM,EACN,OAAO,EACP,WAAW,EACX,UAAU,EACV,QAAQ,EACR,KAAU,EACV,cAAc,EACd,YAAY,GACb,EAAE,IAAI,CAAC,aAAa,EAAE,QAAQ,GAAG,SAAS,GAAG,gBAAgB,CAAC,GAAG;IAChE,WAAW,EAAE,MAAM,CAAC;IACpB,UAAU,EAAE,MAAM,CAAC;IACnB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,YAAY,CAAC,EAAE,GAAG,CAAC;CACpB,GAAG,OAAO,CAAC,cAAc,GAAG,UAAU,CAAC,OAAO,WAAW,CAAC,CAAC,CAwM3D"}
|
|
@@ -1 +1,3 @@
|
|
|
1
|
-
export { createThreadHandler, deleteThreadHandler, getMemoryStatusHandler, getMessagesHandler, getThreadByIdHandler, getThreadsHandler, getWorkingMemoryHandler, saveMessagesHandler, updateThreadHandler, updateWorkingMemoryHandler } from '../../chunk-
|
|
1
|
+
export { createThreadHandler, deleteMessagesHandler, deleteThreadHandler, getMemoryConfigHandler, getMemoryStatusHandler, getMessagesHandler, getMessagesPaginatedHandler, getThreadByIdHandler, getThreadsHandler, getThreadsPaginatedHandler, getWorkingMemoryHandler, saveMessagesHandler, searchMemoryHandler, updateThreadHandler, updateWorkingMemoryHandler } from '../../chunk-OEOGYAQC.js';
|
|
2
|
+
//# sourceMappingURL=memory.js.map
|
|
3
|
+
//# sourceMappingURL=memory.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"names":[],"mappings":"","file":"memory.js"}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var chunk2S4IMB6E_cjs = require('../../chunk-2S4IMB6E.cjs');
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
Object.defineProperty(exports, "getAITraceHandler", {
|
|
8
|
+
enumerable: true,
|
|
9
|
+
get: function () { return chunk2S4IMB6E_cjs.getAITraceHandler; }
|
|
10
|
+
});
|
|
11
|
+
Object.defineProperty(exports, "getAITracesPaginatedHandler", {
|
|
12
|
+
enumerable: true,
|
|
13
|
+
get: function () { return chunk2S4IMB6E_cjs.getAITracesPaginatedHandler; }
|
|
14
|
+
});
|
|
15
|
+
Object.defineProperty(exports, "getScoresBySpan", {
|
|
16
|
+
enumerable: true,
|
|
17
|
+
get: function () { return chunk2S4IMB6E_cjs.getScoresBySpan; }
|
|
18
|
+
});
|
|
19
|
+
Object.defineProperty(exports, "scoreTracesHandler", {
|
|
20
|
+
enumerable: true,
|
|
21
|
+
get: function () { return chunk2S4IMB6E_cjs.scoreTracesHandler; }
|
|
22
|
+
});
|
|
23
|
+
//# sourceMappingURL=observability.cjs.map
|
|
24
|
+
//# sourceMappingURL=observability.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"names":[],"mappings":"","file":"observability.cjs"}
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import type { AITracesPaginatedArg, StoragePagination } from '@mastra/core';
|
|
2
|
+
import type { Context } from '../types.js';
|
|
3
|
+
interface ObservabilityContext extends Context {
|
|
4
|
+
traceId?: string;
|
|
5
|
+
body?: AITracesPaginatedArg;
|
|
6
|
+
}
|
|
7
|
+
interface ScoreTracesContext extends Context {
|
|
8
|
+
body?: {
|
|
9
|
+
scorerName: string;
|
|
10
|
+
targets: Array<{
|
|
11
|
+
traceId: string;
|
|
12
|
+
spanId?: string;
|
|
13
|
+
}>;
|
|
14
|
+
};
|
|
15
|
+
}
|
|
16
|
+
/**
|
|
17
|
+
* Get a complete AI trace by trace ID
|
|
18
|
+
* Returns all spans in the trace with their parent-child relationships
|
|
19
|
+
*/
|
|
20
|
+
export declare function getAITraceHandler({ mastra, traceId }: ObservabilityContext & {
|
|
21
|
+
traceId: string;
|
|
22
|
+
}): Promise<import("@mastra/core").AITraceRecord>;
|
|
23
|
+
/**
|
|
24
|
+
* Get paginated AI traces with filtering and pagination
|
|
25
|
+
* Returns only root spans (parent spans) for pagination, not child spans
|
|
26
|
+
*/
|
|
27
|
+
export declare function getAITracesPaginatedHandler({ mastra, body }: ObservabilityContext): Promise<{
|
|
28
|
+
pagination: import("@mastra/core").PaginationInfo;
|
|
29
|
+
spans: import("@mastra/core").AISpanRecord[];
|
|
30
|
+
}>;
|
|
31
|
+
/**
|
|
32
|
+
* Score traces using a specified scorer
|
|
33
|
+
* Fire-and-forget approach - returns immediately while scoring runs in background
|
|
34
|
+
*/
|
|
35
|
+
export declare function scoreTracesHandler({ mastra, body }: ScoreTracesContext): Promise<{
|
|
36
|
+
status: string;
|
|
37
|
+
message: string;
|
|
38
|
+
traceCount: number;
|
|
39
|
+
}>;
|
|
40
|
+
export declare function getScoresBySpan({ mastra, traceId, spanId, pagination, }: Context & {
|
|
41
|
+
traceId: string;
|
|
42
|
+
spanId: string;
|
|
43
|
+
pagination: StoragePagination;
|
|
44
|
+
}): Promise<{
|
|
45
|
+
pagination: import("@mastra/core").PaginationInfo;
|
|
46
|
+
scores: import("@mastra/core/scores").ScoreRowData[];
|
|
47
|
+
}>;
|
|
48
|
+
export {};
|
|
49
|
+
//# sourceMappingURL=observability.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"observability.d.ts","sourceRoot":"","sources":["../../../src/server/handlers/observability.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,oBAAoB,EAAE,iBAAiB,EAAE,MAAM,cAAc,CAAC;AAG5E,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,UAAU,CAAC;AAGxC,UAAU,oBAAqB,SAAQ,OAAO;IAC5C,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,IAAI,CAAC,EAAE,oBAAoB,CAAC;CAC7B;AAED,UAAU,kBAAmB,SAAQ,OAAO;IAC1C,IAAI,CAAC,EAAE;QACL,UAAU,EAAE,MAAM,CAAC;QACnB,OAAO,EAAE,KAAK,CAAC;YACb,OAAO,EAAE,MAAM,CAAC;YAChB,MAAM,CAAC,EAAE,MAAM,CAAC;SACjB,CAAC,CAAC;KACJ,CAAC;CACH;AAED;;;GAGG;AACH,wBAAsB,iBAAiB,CAAC,EAAE,MAAM,EAAE,OAAO,EAAE,EAAE,oBAAoB,GAAG;IAAE,OAAO,EAAE,MAAM,CAAA;CAAE,iDAqBtG;AAED;;;GAGG;AACH,wBAAsB,2BAA2B,CAAC,EAAE,MAAM,EAAE,IAAI,EAAE,EAAE,oBAAoB;;;GAwCvF;AAED;;;GAGG;AACH,wBAAsB,kBAAkB,CAAC,EAAE,MAAM,EAAE,IAAI,EAAE,EAAE,kBAAkB;;;;GA4C5E;AAED,wBAAsB,eAAe,CAAC,EACpC,MAAM,EACN,OAAO,EACP,MAAM,EACN,UAAU,GACX,EAAE,OAAO,GAAG;IAAE,OAAO,EAAE,MAAM,CAAC;IAAC,MAAM,EAAE,MAAM,CAAC;IAAC,UAAU,EAAE,iBAAiB,CAAA;CAAE;;;GAe9E"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"names":[],"mappings":"","file":"observability.js"}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var chunkLNT5N7XW_cjs = require('../../chunk-LNT5N7XW.cjs');
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
Object.defineProperty(exports, "getScorerHandler", {
|
|
8
|
+
enumerable: true,
|
|
9
|
+
get: function () { return chunkLNT5N7XW_cjs.getScorerHandler; }
|
|
10
|
+
});
|
|
11
|
+
Object.defineProperty(exports, "getScorersHandler", {
|
|
12
|
+
enumerable: true,
|
|
13
|
+
get: function () { return chunkLNT5N7XW_cjs.getScorersHandler; }
|
|
14
|
+
});
|
|
15
|
+
Object.defineProperty(exports, "getScoresByEntityIdHandler", {
|
|
16
|
+
enumerable: true,
|
|
17
|
+
get: function () { return chunkLNT5N7XW_cjs.getScoresByEntityIdHandler; }
|
|
18
|
+
});
|
|
19
|
+
Object.defineProperty(exports, "getScoresByRunIdHandler", {
|
|
20
|
+
enumerable: true,
|
|
21
|
+
get: function () { return chunkLNT5N7XW_cjs.getScoresByRunIdHandler; }
|
|
22
|
+
});
|
|
23
|
+
Object.defineProperty(exports, "getScoresByScorerIdHandler", {
|
|
24
|
+
enumerable: true,
|
|
25
|
+
get: function () { return chunkLNT5N7XW_cjs.getScoresByScorerIdHandler; }
|
|
26
|
+
});
|
|
27
|
+
Object.defineProperty(exports, "saveScoreHandler", {
|
|
28
|
+
enumerable: true,
|
|
29
|
+
get: function () { return chunkLNT5N7XW_cjs.saveScoreHandler; }
|
|
30
|
+
});
|
|
31
|
+
//# sourceMappingURL=scores.cjs.map
|
|
32
|
+
//# sourceMappingURL=scores.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"names":[],"mappings":"","file":"scores.cjs"}
|
|
@@ -0,0 +1,251 @@
|
|
|
1
|
+
import type { RuntimeContext } from '@mastra/core/runtime-context';
|
|
2
|
+
import type { MastraScorerEntry, ScoreRowData } from '@mastra/core/scores';
|
|
3
|
+
import type { StoragePagination } from '@mastra/core/storage';
|
|
4
|
+
import type { Context } from '../types.js';
|
|
5
|
+
export declare function getScorersHandler({ mastra, runtimeContext }: Context & {
|
|
6
|
+
runtimeContext: RuntimeContext;
|
|
7
|
+
}): Promise<{
|
|
8
|
+
[k: string]: MastraScorerEntry & {
|
|
9
|
+
agentIds: string[];
|
|
10
|
+
agentNames: string[];
|
|
11
|
+
workflowIds: string[];
|
|
12
|
+
isRegistered: boolean;
|
|
13
|
+
};
|
|
14
|
+
}>;
|
|
15
|
+
export declare function getScorerHandler({ mastra, scorerId, runtimeContext, }: Context & {
|
|
16
|
+
scorerId: string;
|
|
17
|
+
runtimeContext: RuntimeContext;
|
|
18
|
+
}): Promise<(MastraScorerEntry & {
|
|
19
|
+
agentIds: string[];
|
|
20
|
+
agentNames: string[];
|
|
21
|
+
workflowIds: string[];
|
|
22
|
+
isRegistered: boolean;
|
|
23
|
+
}) | null>;
|
|
24
|
+
export declare function getScoresByRunIdHandler({ mastra, runId, pagination, }: Context & {
|
|
25
|
+
runId: string;
|
|
26
|
+
pagination: StoragePagination;
|
|
27
|
+
}): Promise<{
|
|
28
|
+
pagination: import("@mastra/core").PaginationInfo;
|
|
29
|
+
scores: ({
|
|
30
|
+
traceId?: string;
|
|
31
|
+
spanId?: string;
|
|
32
|
+
runId: string;
|
|
33
|
+
input: any;
|
|
34
|
+
output: any;
|
|
35
|
+
additionalContext?: Record<string, any>;
|
|
36
|
+
runtimeContext?: Record<string, any>;
|
|
37
|
+
tracingContext?: import("@mastra/core/ai-tracing").TracingContext;
|
|
38
|
+
extractStepResult?: any;
|
|
39
|
+
extractPrompt?: string;
|
|
40
|
+
score: number;
|
|
41
|
+
analyzeStepResult?: any;
|
|
42
|
+
analyzePrompt?: string;
|
|
43
|
+
reason?: string;
|
|
44
|
+
reasonPrompt?: string;
|
|
45
|
+
scorer: Record<string, any>;
|
|
46
|
+
metadata?: Record<string, any>;
|
|
47
|
+
source: import("@mastra/core/scores").ScoringSource;
|
|
48
|
+
entity: Record<string, any>;
|
|
49
|
+
entityType: import("@mastra/core/scores").ScoringEntityType;
|
|
50
|
+
structuredOutput?: boolean;
|
|
51
|
+
resourceId?: string;
|
|
52
|
+
threadId?: string;
|
|
53
|
+
id: string;
|
|
54
|
+
entityId: string;
|
|
55
|
+
scorerId: string;
|
|
56
|
+
createdAt: Date;
|
|
57
|
+
updatedAt: Date;
|
|
58
|
+
preprocessStepResult?: Record<string, any>;
|
|
59
|
+
preprocessPrompt?: string;
|
|
60
|
+
generateScorePrompt?: string;
|
|
61
|
+
generateReasonPrompt?: string;
|
|
62
|
+
} | {
|
|
63
|
+
traceId: string | undefined;
|
|
64
|
+
spanId: string | undefined;
|
|
65
|
+
runId: string;
|
|
66
|
+
input: any;
|
|
67
|
+
output: any;
|
|
68
|
+
additionalContext?: Record<string, any>;
|
|
69
|
+
runtimeContext?: Record<string, any>;
|
|
70
|
+
tracingContext?: import("@mastra/core/ai-tracing").TracingContext;
|
|
71
|
+
extractStepResult?: any;
|
|
72
|
+
extractPrompt?: string;
|
|
73
|
+
score: number;
|
|
74
|
+
analyzeStepResult?: any;
|
|
75
|
+
analyzePrompt?: string;
|
|
76
|
+
reason?: string;
|
|
77
|
+
reasonPrompt?: string;
|
|
78
|
+
scorer: Record<string, any>;
|
|
79
|
+
metadata?: Record<string, any>;
|
|
80
|
+
source: import("@mastra/core/scores").ScoringSource;
|
|
81
|
+
entity: Record<string, any>;
|
|
82
|
+
entityType: import("@mastra/core/scores").ScoringEntityType;
|
|
83
|
+
structuredOutput?: boolean;
|
|
84
|
+
resourceId?: string;
|
|
85
|
+
threadId?: string;
|
|
86
|
+
id: string;
|
|
87
|
+
entityId: string;
|
|
88
|
+
scorerId: string;
|
|
89
|
+
createdAt: Date;
|
|
90
|
+
updatedAt: Date;
|
|
91
|
+
preprocessStepResult?: Record<string, any>;
|
|
92
|
+
preprocessPrompt?: string;
|
|
93
|
+
generateScorePrompt?: string;
|
|
94
|
+
generateReasonPrompt?: string;
|
|
95
|
+
})[];
|
|
96
|
+
}>;
|
|
97
|
+
export declare function getScoresByScorerIdHandler({ mastra, scorerId, pagination, entityId, entityType, }: Context & {
|
|
98
|
+
scorerId: string;
|
|
99
|
+
pagination: StoragePagination;
|
|
100
|
+
entityId?: string;
|
|
101
|
+
entityType?: string;
|
|
102
|
+
}): Promise<{
|
|
103
|
+
pagination: import("@mastra/core").PaginationInfo;
|
|
104
|
+
scores: ({
|
|
105
|
+
traceId?: string;
|
|
106
|
+
spanId?: string;
|
|
107
|
+
runId: string;
|
|
108
|
+
input: any;
|
|
109
|
+
output: any;
|
|
110
|
+
additionalContext?: Record<string, any>;
|
|
111
|
+
runtimeContext?: Record<string, any>;
|
|
112
|
+
tracingContext?: import("@mastra/core/ai-tracing").TracingContext;
|
|
113
|
+
extractStepResult?: any;
|
|
114
|
+
extractPrompt?: string;
|
|
115
|
+
score: number;
|
|
116
|
+
analyzeStepResult?: any;
|
|
117
|
+
analyzePrompt?: string;
|
|
118
|
+
reason?: string;
|
|
119
|
+
reasonPrompt?: string;
|
|
120
|
+
scorer: Record<string, any>;
|
|
121
|
+
metadata?: Record<string, any>;
|
|
122
|
+
source: import("@mastra/core/scores").ScoringSource;
|
|
123
|
+
entity: Record<string, any>;
|
|
124
|
+
entityType: import("@mastra/core/scores").ScoringEntityType;
|
|
125
|
+
structuredOutput?: boolean;
|
|
126
|
+
resourceId?: string;
|
|
127
|
+
threadId?: string;
|
|
128
|
+
id: string;
|
|
129
|
+
entityId: string;
|
|
130
|
+
scorerId: string;
|
|
131
|
+
createdAt: Date;
|
|
132
|
+
updatedAt: Date;
|
|
133
|
+
preprocessStepResult?: Record<string, any>;
|
|
134
|
+
preprocessPrompt?: string;
|
|
135
|
+
generateScorePrompt?: string;
|
|
136
|
+
generateReasonPrompt?: string;
|
|
137
|
+
} | {
|
|
138
|
+
traceId: string | undefined;
|
|
139
|
+
spanId: string | undefined;
|
|
140
|
+
runId: string;
|
|
141
|
+
input: any;
|
|
142
|
+
output: any;
|
|
143
|
+
additionalContext?: Record<string, any>;
|
|
144
|
+
runtimeContext?: Record<string, any>;
|
|
145
|
+
tracingContext?: import("@mastra/core/ai-tracing").TracingContext;
|
|
146
|
+
extractStepResult?: any;
|
|
147
|
+
extractPrompt?: string;
|
|
148
|
+
score: number;
|
|
149
|
+
analyzeStepResult?: any;
|
|
150
|
+
analyzePrompt?: string;
|
|
151
|
+
reason?: string;
|
|
152
|
+
reasonPrompt?: string;
|
|
153
|
+
scorer: Record<string, any>;
|
|
154
|
+
metadata?: Record<string, any>;
|
|
155
|
+
source: import("@mastra/core/scores").ScoringSource;
|
|
156
|
+
entity: Record<string, any>;
|
|
157
|
+
entityType: import("@mastra/core/scores").ScoringEntityType;
|
|
158
|
+
structuredOutput?: boolean;
|
|
159
|
+
resourceId?: string;
|
|
160
|
+
threadId?: string;
|
|
161
|
+
id: string;
|
|
162
|
+
entityId: string;
|
|
163
|
+
scorerId: string;
|
|
164
|
+
createdAt: Date;
|
|
165
|
+
updatedAt: Date;
|
|
166
|
+
preprocessStepResult?: Record<string, any>;
|
|
167
|
+
preprocessPrompt?: string;
|
|
168
|
+
generateScorePrompt?: string;
|
|
169
|
+
generateReasonPrompt?: string;
|
|
170
|
+
})[];
|
|
171
|
+
}>;
|
|
172
|
+
export declare function getScoresByEntityIdHandler({ mastra, entityId, entityType, pagination, }: Context & {
|
|
173
|
+
entityId: string;
|
|
174
|
+
entityType: string;
|
|
175
|
+
pagination: StoragePagination;
|
|
176
|
+
}): Promise<{
|
|
177
|
+
pagination: import("@mastra/core").PaginationInfo;
|
|
178
|
+
scores: ({
|
|
179
|
+
traceId?: string;
|
|
180
|
+
spanId?: string;
|
|
181
|
+
runId: string;
|
|
182
|
+
input: any;
|
|
183
|
+
output: any;
|
|
184
|
+
additionalContext?: Record<string, any>;
|
|
185
|
+
runtimeContext?: Record<string, any>;
|
|
186
|
+
tracingContext?: import("@mastra/core/ai-tracing").TracingContext;
|
|
187
|
+
extractStepResult?: any;
|
|
188
|
+
extractPrompt?: string;
|
|
189
|
+
score: number;
|
|
190
|
+
analyzeStepResult?: any;
|
|
191
|
+
analyzePrompt?: string;
|
|
192
|
+
reason?: string;
|
|
193
|
+
reasonPrompt?: string;
|
|
194
|
+
scorer: Record<string, any>;
|
|
195
|
+
metadata?: Record<string, any>;
|
|
196
|
+
source: import("@mastra/core/scores").ScoringSource;
|
|
197
|
+
entity: Record<string, any>;
|
|
198
|
+
entityType: import("@mastra/core/scores").ScoringEntityType;
|
|
199
|
+
structuredOutput?: boolean;
|
|
200
|
+
resourceId?: string;
|
|
201
|
+
threadId?: string;
|
|
202
|
+
id: string;
|
|
203
|
+
entityId: string;
|
|
204
|
+
scorerId: string;
|
|
205
|
+
createdAt: Date;
|
|
206
|
+
updatedAt: Date;
|
|
207
|
+
preprocessStepResult?: Record<string, any>;
|
|
208
|
+
preprocessPrompt?: string;
|
|
209
|
+
generateScorePrompt?: string;
|
|
210
|
+
generateReasonPrompt?: string;
|
|
211
|
+
} | {
|
|
212
|
+
traceId: string | undefined;
|
|
213
|
+
spanId: string | undefined;
|
|
214
|
+
runId: string;
|
|
215
|
+
input: any;
|
|
216
|
+
output: any;
|
|
217
|
+
additionalContext?: Record<string, any>;
|
|
218
|
+
runtimeContext?: Record<string, any>;
|
|
219
|
+
tracingContext?: import("@mastra/core/ai-tracing").TracingContext;
|
|
220
|
+
extractStepResult?: any;
|
|
221
|
+
extractPrompt?: string;
|
|
222
|
+
score: number;
|
|
223
|
+
analyzeStepResult?: any;
|
|
224
|
+
analyzePrompt?: string;
|
|
225
|
+
reason?: string;
|
|
226
|
+
reasonPrompt?: string;
|
|
227
|
+
scorer: Record<string, any>;
|
|
228
|
+
metadata?: Record<string, any>;
|
|
229
|
+
source: import("@mastra/core/scores").ScoringSource;
|
|
230
|
+
entity: Record<string, any>;
|
|
231
|
+
entityType: import("@mastra/core/scores").ScoringEntityType;
|
|
232
|
+
structuredOutput?: boolean;
|
|
233
|
+
resourceId?: string;
|
|
234
|
+
threadId?: string;
|
|
235
|
+
id: string;
|
|
236
|
+
entityId: string;
|
|
237
|
+
scorerId: string;
|
|
238
|
+
createdAt: Date;
|
|
239
|
+
updatedAt: Date;
|
|
240
|
+
preprocessStepResult?: Record<string, any>;
|
|
241
|
+
preprocessPrompt?: string;
|
|
242
|
+
generateScorePrompt?: string;
|
|
243
|
+
generateReasonPrompt?: string;
|
|
244
|
+
})[];
|
|
245
|
+
}>;
|
|
246
|
+
export declare function saveScoreHandler({ mastra, score }: Context & {
|
|
247
|
+
score: ScoreRowData;
|
|
248
|
+
}): Promise<never[] | {
|
|
249
|
+
score: ScoreRowData;
|
|
250
|
+
}>;
|
|
251
|
+
//# sourceMappingURL=scores.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"scores.d.ts","sourceRoot":"","sources":["../../../src/server/handlers/scores.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AACnE,OAAO,KAAK,EAAE,iBAAiB,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AAC3E,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,sBAAsB,CAAC;AAC9D,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,UAAU,CAAC;AAqFxC,wBAAsB,iBAAiB,CAAC,EAAE,MAAM,EAAE,cAAc,EAAE,EAAE,OAAO,GAAG;IAAE,cAAc,EAAE,cAAc,CAAA;CAAE;;kBAvE5E,MAAM,EAAE;oBAAc,MAAM,EAAE;qBAAe,MAAM,EAAE;sBAAgB,OAAO;;GA8E/G;AAED,wBAAsB,gBAAgB,CAAC,EACrC,MAAM,EACN,QAAQ,EACR,cAAc,GACf,EAAE,OAAO,GAAG;IAAE,QAAQ,EAAE,MAAM,CAAC;IAAC,cAAc,EAAE,cAAc,CAAA;CAAE;cApF7B,MAAM,EAAE;gBAAc,MAAM,EAAE;iBAAe,MAAM,EAAE;kBAAgB,OAAO;WAiG/G;AAED,wBAAsB,uBAAuB,CAAC,EAC5C,MAAM,EACN,KAAK,EACL,UAAU,GACX,EAAE,OAAO,GAAG;IAAE,KAAK,EAAE,MAAM,CAAC;IAAC,UAAU,EAAE,iBAAiB,CAAA;CAAE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAa5D;AAED,wBAAsB,0BAA0B,CAAC,EAC/C,MAAM,EACN,QAAQ,EACR,UAAU,EACV,QAAQ,EACR,UAAU,GACX,EAAE,OAAO,GAAG;IAAE,QAAQ,EAAE,MAAM,CAAC;IAAC,UAAU,EAAE,iBAAiB,CAAC;IAAC,QAAQ,CAAC,EAAE,MAAM,CAAC;IAAC,UAAU,CAAC,EAAE,MAAM,CAAA;CAAE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAevG;AAED,wBAAsB,0BAA0B,CAAC,EAC/C,MAAM,EACN,QAAQ,EACR,UAAU,EACV,UAAU,GACX,EAAE,OAAO,GAAG;IAAE,QAAQ,EAAE,MAAM,CAAC;IAAC,UAAU,EAAE,MAAM,CAAC;IAAC,UAAU,EAAE,iBAAiB,CAAA;CAAE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAyBnF;AAYD,wBAAsB,gBAAgB,CAAC,EAAE,MAAM,EAAE,KAAK,EAAE,EAAE,OAAO,GAAG;IAAE,KAAK,EAAE,YAAY,CAAA;CAAE;;GAO1F"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"names":[],"mappings":"","file":"scores.js"}
|
|
@@ -1,14 +1,20 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var chunk6ZR275MD_cjs = require('../../chunk-6ZR275MD.cjs');
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
|
|
7
|
+
Object.defineProperty(exports, "collectParentSpanIds", {
|
|
8
|
+
enumerable: true,
|
|
9
|
+
get: function () { return chunk6ZR275MD_cjs.collectParentSpanIds; }
|
|
10
|
+
});
|
|
7
11
|
Object.defineProperty(exports, "getTelemetryHandler", {
|
|
8
12
|
enumerable: true,
|
|
9
|
-
get: function () { return
|
|
13
|
+
get: function () { return chunk6ZR275MD_cjs.getTelemetryHandler; }
|
|
10
14
|
});
|
|
11
15
|
Object.defineProperty(exports, "storeTelemetryHandler", {
|
|
12
16
|
enumerable: true,
|
|
13
|
-
get: function () { return
|
|
17
|
+
get: function () { return chunk6ZR275MD_cjs.storeTelemetryHandler; }
|
|
14
18
|
});
|
|
19
|
+
//# sourceMappingURL=telemetry.cjs.map
|
|
20
|
+
//# sourceMappingURL=telemetry.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"names":[],"mappings":"","file":"telemetry.cjs"}
|