@mastra/core 1.16.1-alpha.1 → 1.17.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +85 -0
- package/dist/agent/index.cjs +8 -8
- package/dist/agent/index.js +1 -1
- package/dist/{chunk-OEOHECI4.cjs → chunk-3H34KWBU.cjs} +9 -9
- package/dist/{chunk-OEOHECI4.cjs.map → chunk-3H34KWBU.cjs.map} +1 -1
- package/dist/{chunk-Y5EGGY3M.js → chunk-62GLEYP6.js} +3 -3
- package/dist/{chunk-Y5EGGY3M.js.map → chunk-62GLEYP6.js.map} +1 -1
- package/dist/{chunk-J3NJXIJ4.js → chunk-ABA3KD3X.js} +524 -246
- package/dist/chunk-ABA3KD3X.js.map +1 -0
- package/dist/{chunk-NHYQRELK.cjs → chunk-BKXCVT72.cjs} +3 -3
- package/dist/chunk-BKXCVT72.cjs.map +1 -0
- package/dist/{chunk-P7HTEQ33.js → chunk-CVG4K4O3.js} +4 -4
- package/dist/{chunk-P7HTEQ33.js.map → chunk-CVG4K4O3.js.map} +1 -1
- package/dist/{chunk-RGOEP34Y.js → chunk-CYQ2TNSK.js} +3 -3
- package/dist/{chunk-RGOEP34Y.js.map → chunk-CYQ2TNSK.js.map} +1 -1
- package/dist/{chunk-4DFZ553O.js → chunk-DGBPIUTG.js} +3 -3
- package/dist/{chunk-4DFZ553O.js.map → chunk-DGBPIUTG.js.map} +1 -1
- package/dist/{chunk-PSJRMLRB.js → chunk-DIWGRQZT.js} +3 -3
- package/dist/chunk-DIWGRQZT.js.map +1 -0
- package/dist/{chunk-EBPV22NT.cjs → chunk-EWGUU5QC.cjs} +6 -6
- package/dist/{chunk-EBPV22NT.cjs.map → chunk-EWGUU5QC.cjs.map} +1 -1
- package/dist/{chunk-6ZT4MY74.cjs → chunk-FQMFXIUQ.cjs} +185 -185
- package/dist/{chunk-6ZT4MY74.cjs.map → chunk-FQMFXIUQ.cjs.map} +1 -1
- package/dist/{chunk-ZJMETLCP.js → chunk-FWDG2WUV.js} +29 -27
- package/dist/chunk-FWDG2WUV.js.map +1 -0
- package/dist/{chunk-KDT3Y3ME.cjs → chunk-I7S3ZFOU.cjs} +82 -82
- package/dist/{chunk-KDT3Y3ME.cjs.map → chunk-I7S3ZFOU.cjs.map} +1 -1
- package/dist/{chunk-TOPTRKIX.js → chunk-IOKPS5RD.js} +14 -4
- package/dist/chunk-IOKPS5RD.js.map +1 -0
- package/dist/{chunk-YB77ED7R.js → chunk-IPINMJOH.js} +3 -3
- package/dist/{chunk-YB77ED7R.js.map → chunk-IPINMJOH.js.map} +1 -1
- package/dist/{chunk-WJWWFBKT.js → chunk-IYSW4VN7.js} +476 -27
- package/dist/chunk-IYSW4VN7.js.map +1 -0
- package/dist/{chunk-ESKXIAWT.js → chunk-J2BSGWLR.js} +9 -9
- package/dist/{chunk-ESKXIAWT.js.map → chunk-J2BSGWLR.js.map} +1 -1
- package/dist/{chunk-X672Z4KM.js → chunk-KFYDUUVH.js} +7 -7
- package/dist/{chunk-X672Z4KM.js.map → chunk-KFYDUUVH.js.map} +1 -1
- package/dist/{chunk-7L2ICIDI.cjs → chunk-MBJ6IAKF.cjs} +6 -6
- package/dist/{chunk-7L2ICIDI.cjs.map → chunk-MBJ6IAKF.cjs.map} +1 -1
- package/dist/{chunk-7O2GO5ZA.cjs → chunk-O2BVR6WC.cjs} +16 -16
- package/dist/{chunk-7O2GO5ZA.cjs.map → chunk-O2BVR6WC.cjs.map} +1 -1
- package/dist/{chunk-GKUIFIWB.cjs → chunk-OXH67SS4.cjs} +9 -9
- package/dist/{chunk-GKUIFIWB.cjs.map → chunk-OXH67SS4.cjs.map} +1 -1
- package/dist/{chunk-JWTPUJWM.cjs → chunk-QLC3UBDY.cjs} +512 -61
- package/dist/chunk-QLC3UBDY.cjs.map +1 -0
- package/dist/{chunk-XW4B2RAG.cjs → chunk-QVVWKMFM.cjs} +525 -248
- package/dist/chunk-QVVWKMFM.cjs.map +1 -0
- package/dist/{chunk-RQBBPR64.cjs → chunk-R2V6BCYX.cjs} +29 -27
- package/dist/chunk-R2V6BCYX.cjs.map +1 -0
- package/dist/{chunk-YKW2LXON.js → chunk-RUUHBB7U.js} +4 -4
- package/dist/{chunk-YKW2LXON.js.map → chunk-RUUHBB7U.js.map} +1 -1
- package/dist/{chunk-HFGULJ4Q.js → chunk-RX5ZKTWD.js} +4 -4
- package/dist/{chunk-HFGULJ4Q.js.map → chunk-RX5ZKTWD.js.map} +1 -1
- package/dist/{chunk-UCKOC22J.cjs → chunk-TPJSYHLC.cjs} +15 -5
- package/dist/chunk-TPJSYHLC.cjs.map +1 -0
- package/dist/{chunk-AM2AF362.cjs → chunk-XWGZAY4F.cjs} +5 -5
- package/dist/{chunk-AM2AF362.cjs.map → chunk-XWGZAY4F.cjs.map} +1 -1
- package/dist/{chunk-LPCQ6RYF.cjs → chunk-YE2NPWVL.cjs} +50 -50
- package/dist/{chunk-LPCQ6RYF.cjs.map → chunk-YE2NPWVL.cjs.map} +1 -1
- package/dist/{chunk-XKOCRXCP.js → chunk-ZOJZL62I.js} +3 -3
- package/dist/{chunk-XKOCRXCP.js.map → chunk-ZOJZL62I.js.map} +1 -1
- package/dist/{chunk-QJGJEX2X.cjs → chunk-ZOZHH547.cjs} +7 -7
- package/dist/{chunk-QJGJEX2X.cjs.map → chunk-ZOZHH547.cjs.map} +1 -1
- package/dist/datasets/index.cjs +17 -17
- package/dist/datasets/index.js +2 -2
- package/dist/docs/SKILL.md +3 -1
- package/dist/docs/assets/SOURCE_MAP.json +265 -255
- package/dist/docs/references/docs-workspace-lsp.md +116 -0
- package/dist/docs/references/docs-workspace-overview.md +15 -1
- package/dist/docs/references/reference-harness-harness-class.md +2 -0
- package/dist/docs/references/reference-processors-skill-search-processor.md +93 -0
- package/dist/docs/references/reference.md +1 -0
- package/dist/evals/index.cjs +5 -5
- package/dist/evals/index.js +2 -2
- package/dist/evals/scoreTraces/index.cjs +3 -3
- package/dist/evals/scoreTraces/index.js +1 -1
- package/dist/harness/harness.d.ts +4 -5
- package/dist/harness/harness.d.ts.map +1 -1
- package/dist/harness/index.cjs +44 -12
- package/dist/harness/index.cjs.map +1 -1
- package/dist/harness/index.d.ts +1 -1
- package/dist/harness/index.d.ts.map +1 -1
- package/dist/harness/index.js +39 -7
- package/dist/harness/index.js.map +1 -1
- package/dist/harness/types.d.ts +18 -4
- package/dist/harness/types.d.ts.map +1 -1
- package/dist/index.cjs +2 -2
- package/dist/index.js +1 -1
- package/dist/llm/index.cjs +16 -16
- package/dist/llm/index.js +5 -5
- package/dist/llm/model/provider-types.generated.d.ts +5 -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/memory/index.cjs +14 -14
- package/dist/memory/index.js +1 -1
- package/dist/models-dev-3UNU47HO.cjs +12 -0
- package/dist/{models-dev-KMQOE3SL.cjs.map → models-dev-3UNU47HO.cjs.map} +1 -1
- package/dist/models-dev-U3LBEE4O.js +3 -0
- package/dist/{models-dev-7F53M5Y6.js.map → models-dev-U3LBEE4O.js.map} +1 -1
- package/dist/netlify-ET5JT5FX.cjs +12 -0
- package/dist/{netlify-MBDMAHGO.cjs.map → netlify-ET5JT5FX.cjs.map} +1 -1
- package/dist/netlify-QVXFSZJQ.js +3 -0
- package/dist/{netlify-KUZQYG5K.js.map → netlify-QVXFSZJQ.js.map} +1 -1
- package/dist/processor-provider/index.cjs +10 -10
- package/dist/processor-provider/index.js +1 -1
- package/dist/processors/index.cjs +50 -42
- package/dist/processors/index.js +1 -1
- package/dist/processors/processors/index.d.ts +2 -0
- package/dist/processors/processors/index.d.ts.map +1 -1
- package/dist/processors/processors/skill-search.d.ts +111 -0
- package/dist/processors/processors/skill-search.d.ts.map +1 -0
- package/dist/processors/tool-result-reminder.d.ts +32 -0
- package/dist/processors/tool-result-reminder.d.ts.map +1 -0
- package/dist/provider-registry-IP3K4FE4.js +3 -0
- package/dist/{provider-registry-EB75EFT7.js.map → provider-registry-IP3K4FE4.js.map} +1 -1
- package/dist/provider-registry-S6VYJ3GX.cjs +40 -0
- package/dist/{provider-registry-3B6CFW7R.cjs.map → provider-registry-S6VYJ3GX.cjs.map} +1 -1
- package/dist/provider-registry.json +10 -0
- package/dist/relevance/index.cjs +3 -3
- package/dist/relevance/index.js +1 -1
- package/dist/storage/index.cjs +74 -74
- package/dist/storage/index.js +1 -1
- package/dist/stream/index.cjs +8 -8
- package/dist/stream/index.js +1 -1
- package/dist/test-utils/llm-mock.cjs +4 -4
- package/dist/test-utils/llm-mock.js +1 -1
- package/dist/tool-loop-agent/index.cjs +4 -4
- package/dist/tool-loop-agent/index.js +1 -1
- package/dist/tools/tool-builder/builder.d.ts.map +1 -1
- package/dist/utils.cjs +23 -23
- package/dist/utils.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 +24 -24
- package/dist/workflows/index.js +1 -1
- package/dist/workspace/constants/index.d.ts +4 -1
- package/dist/workspace/constants/index.d.ts.map +1 -1
- package/dist/workspace/index.cjs +68 -68
- package/dist/workspace/index.js +1 -1
- package/dist/workspace/lsp/client.d.ts +30 -0
- package/dist/workspace/lsp/client.d.ts.map +1 -1
- package/dist/workspace/lsp/manager.d.ts +11 -0
- package/dist/workspace/lsp/manager.d.ts.map +1 -1
- package/dist/workspace/tools/index.d.ts +1 -0
- package/dist/workspace/tools/index.d.ts.map +1 -1
- package/dist/workspace/tools/lsp-inspect.d.ts +13 -0
- package/dist/workspace/tools/lsp-inspect.d.ts.map +1 -0
- package/dist/workspace/tools/tools.d.ts.map +1 -1
- package/package.json +5 -5
- package/src/llm/model/provider-types.generated.d.ts +5 -0
- package/test-utils/llm-mock.d.ts +1 -0
- package/dist/chunk-J3NJXIJ4.js.map +0 -1
- package/dist/chunk-JWTPUJWM.cjs.map +0 -1
- package/dist/chunk-NHYQRELK.cjs.map +0 -1
- package/dist/chunk-PSJRMLRB.js.map +0 -1
- package/dist/chunk-RQBBPR64.cjs.map +0 -1
- package/dist/chunk-TOPTRKIX.js.map +0 -1
- package/dist/chunk-UCKOC22J.cjs.map +0 -1
- package/dist/chunk-WJWWFBKT.js.map +0 -1
- package/dist/chunk-XW4B2RAG.cjs.map +0 -1
- package/dist/chunk-ZJMETLCP.js.map +0 -1
- package/dist/models-dev-7F53M5Y6.js +0 -3
- package/dist/models-dev-KMQOE3SL.cjs +0 -12
- package/dist/netlify-KUZQYG5K.js +0 -3
- package/dist/netlify-MBDMAHGO.cjs +0 -12
- package/dist/provider-registry-3B6CFW7R.cjs +0 -40
- package/dist/provider-registry-EB75EFT7.js +0 -3
|
@@ -1,172 +1,180 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var chunkQLC3UBDY_cjs = require('../chunk-QLC3UBDY.cjs');
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
|
|
7
|
+
Object.defineProperty(exports, "AgentsMDInjector", {
|
|
8
|
+
enumerable: true,
|
|
9
|
+
get: function () { return chunkQLC3UBDY_cjs.AgentsMDInjector; }
|
|
10
|
+
});
|
|
7
11
|
Object.defineProperty(exports, "BaseProcessor", {
|
|
8
12
|
enumerable: true,
|
|
9
|
-
get: function () { return
|
|
13
|
+
get: function () { return chunkQLC3UBDY_cjs.BaseProcessor; }
|
|
10
14
|
});
|
|
11
15
|
Object.defineProperty(exports, "BatchPartsProcessor", {
|
|
12
16
|
enumerable: true,
|
|
13
|
-
get: function () { return
|
|
17
|
+
get: function () { return chunkQLC3UBDY_cjs.BatchPartsProcessor; }
|
|
14
18
|
});
|
|
15
19
|
Object.defineProperty(exports, "FilePartSchema", {
|
|
16
20
|
enumerable: true,
|
|
17
|
-
get: function () { return
|
|
21
|
+
get: function () { return chunkQLC3UBDY_cjs.FilePartSchema; }
|
|
18
22
|
});
|
|
19
23
|
Object.defineProperty(exports, "ImagePartSchema", {
|
|
20
24
|
enumerable: true,
|
|
21
|
-
get: function () { return
|
|
25
|
+
get: function () { return chunkQLC3UBDY_cjs.ImagePartSchema; }
|
|
22
26
|
});
|
|
23
27
|
Object.defineProperty(exports, "LanguageDetector", {
|
|
24
28
|
enumerable: true,
|
|
25
|
-
get: function () { return
|
|
29
|
+
get: function () { return chunkQLC3UBDY_cjs.LanguageDetector; }
|
|
26
30
|
});
|
|
27
31
|
Object.defineProperty(exports, "MessageContentSchema", {
|
|
28
32
|
enumerable: true,
|
|
29
|
-
get: function () { return
|
|
33
|
+
get: function () { return chunkQLC3UBDY_cjs.MessageContentSchema; }
|
|
30
34
|
});
|
|
31
35
|
Object.defineProperty(exports, "MessageHistory", {
|
|
32
36
|
enumerable: true,
|
|
33
|
-
get: function () { return
|
|
37
|
+
get: function () { return chunkQLC3UBDY_cjs.MessageHistory; }
|
|
34
38
|
});
|
|
35
39
|
Object.defineProperty(exports, "MessagePartSchema", {
|
|
36
40
|
enumerable: true,
|
|
37
|
-
get: function () { return
|
|
41
|
+
get: function () { return chunkQLC3UBDY_cjs.MessagePartSchema; }
|
|
38
42
|
});
|
|
39
43
|
Object.defineProperty(exports, "ModerationProcessor", {
|
|
40
44
|
enumerable: true,
|
|
41
|
-
get: function () { return
|
|
45
|
+
get: function () { return chunkQLC3UBDY_cjs.ModerationProcessor; }
|
|
42
46
|
});
|
|
43
47
|
Object.defineProperty(exports, "PIIDetector", {
|
|
44
48
|
enumerable: true,
|
|
45
|
-
get: function () { return
|
|
49
|
+
get: function () { return chunkQLC3UBDY_cjs.PIIDetector; }
|
|
46
50
|
});
|
|
47
51
|
Object.defineProperty(exports, "ProcessorInputPhaseSchema", {
|
|
48
52
|
enumerable: true,
|
|
49
|
-
get: function () { return
|
|
53
|
+
get: function () { return chunkQLC3UBDY_cjs.ProcessorInputPhaseSchema; }
|
|
50
54
|
});
|
|
51
55
|
Object.defineProperty(exports, "ProcessorInputStepPhaseSchema", {
|
|
52
56
|
enumerable: true,
|
|
53
|
-
get: function () { return
|
|
57
|
+
get: function () { return chunkQLC3UBDY_cjs.ProcessorInputStepPhaseSchema; }
|
|
54
58
|
});
|
|
55
59
|
Object.defineProperty(exports, "ProcessorMessageContentSchema", {
|
|
56
60
|
enumerable: true,
|
|
57
|
-
get: function () { return
|
|
61
|
+
get: function () { return chunkQLC3UBDY_cjs.ProcessorMessageContentSchema; }
|
|
58
62
|
});
|
|
59
63
|
Object.defineProperty(exports, "ProcessorMessageSchema", {
|
|
60
64
|
enumerable: true,
|
|
61
|
-
get: function () { return
|
|
65
|
+
get: function () { return chunkQLC3UBDY_cjs.ProcessorMessageSchema; }
|
|
62
66
|
});
|
|
63
67
|
Object.defineProperty(exports, "ProcessorOutputResultPhaseSchema", {
|
|
64
68
|
enumerable: true,
|
|
65
|
-
get: function () { return
|
|
69
|
+
get: function () { return chunkQLC3UBDY_cjs.ProcessorOutputResultPhaseSchema; }
|
|
66
70
|
});
|
|
67
71
|
Object.defineProperty(exports, "ProcessorOutputStepPhaseSchema", {
|
|
68
72
|
enumerable: true,
|
|
69
|
-
get: function () { return
|
|
73
|
+
get: function () { return chunkQLC3UBDY_cjs.ProcessorOutputStepPhaseSchema; }
|
|
70
74
|
});
|
|
71
75
|
Object.defineProperty(exports, "ProcessorOutputStreamPhaseSchema", {
|
|
72
76
|
enumerable: true,
|
|
73
|
-
get: function () { return
|
|
77
|
+
get: function () { return chunkQLC3UBDY_cjs.ProcessorOutputStreamPhaseSchema; }
|
|
74
78
|
});
|
|
75
79
|
Object.defineProperty(exports, "ProcessorRunner", {
|
|
76
80
|
enumerable: true,
|
|
77
|
-
get: function () { return
|
|
81
|
+
get: function () { return chunkQLC3UBDY_cjs.ProcessorRunner; }
|
|
78
82
|
});
|
|
79
83
|
Object.defineProperty(exports, "ProcessorState", {
|
|
80
84
|
enumerable: true,
|
|
81
|
-
get: function () { return
|
|
85
|
+
get: function () { return chunkQLC3UBDY_cjs.ProcessorState; }
|
|
82
86
|
});
|
|
83
87
|
Object.defineProperty(exports, "ProcessorStepInputSchema", {
|
|
84
88
|
enumerable: true,
|
|
85
|
-
get: function () { return
|
|
89
|
+
get: function () { return chunkQLC3UBDY_cjs.ProcessorStepInputSchema; }
|
|
86
90
|
});
|
|
87
91
|
Object.defineProperty(exports, "ProcessorStepOutputSchema", {
|
|
88
92
|
enumerable: true,
|
|
89
|
-
get: function () { return
|
|
93
|
+
get: function () { return chunkQLC3UBDY_cjs.ProcessorStepOutputSchema; }
|
|
90
94
|
});
|
|
91
95
|
Object.defineProperty(exports, "ProcessorStepSchema", {
|
|
92
96
|
enumerable: true,
|
|
93
|
-
get: function () { return
|
|
97
|
+
get: function () { return chunkQLC3UBDY_cjs.ProcessorStepSchema; }
|
|
94
98
|
});
|
|
95
99
|
Object.defineProperty(exports, "PromptInjectionDetector", {
|
|
96
100
|
enumerable: true,
|
|
97
|
-
get: function () { return
|
|
101
|
+
get: function () { return chunkQLC3UBDY_cjs.PromptInjectionDetector; }
|
|
98
102
|
});
|
|
99
103
|
Object.defineProperty(exports, "ReasoningPartSchema", {
|
|
100
104
|
enumerable: true,
|
|
101
|
-
get: function () { return
|
|
105
|
+
get: function () { return chunkQLC3UBDY_cjs.ReasoningPartSchema; }
|
|
102
106
|
});
|
|
103
107
|
Object.defineProperty(exports, "SemanticRecall", {
|
|
104
108
|
enumerable: true,
|
|
105
|
-
get: function () { return
|
|
109
|
+
get: function () { return chunkQLC3UBDY_cjs.SemanticRecall; }
|
|
110
|
+
});
|
|
111
|
+
Object.defineProperty(exports, "SkillSearchProcessor", {
|
|
112
|
+
enumerable: true,
|
|
113
|
+
get: function () { return chunkQLC3UBDY_cjs.SkillSearchProcessor; }
|
|
106
114
|
});
|
|
107
115
|
Object.defineProperty(exports, "SkillsProcessor", {
|
|
108
116
|
enumerable: true,
|
|
109
|
-
get: function () { return
|
|
117
|
+
get: function () { return chunkQLC3UBDY_cjs.SkillsProcessor; }
|
|
110
118
|
});
|
|
111
119
|
Object.defineProperty(exports, "SourcePartSchema", {
|
|
112
120
|
enumerable: true,
|
|
113
|
-
get: function () { return
|
|
121
|
+
get: function () { return chunkQLC3UBDY_cjs.SourcePartSchema; }
|
|
114
122
|
});
|
|
115
123
|
Object.defineProperty(exports, "StepStartPartSchema", {
|
|
116
124
|
enumerable: true,
|
|
117
|
-
get: function () { return
|
|
125
|
+
get: function () { return chunkQLC3UBDY_cjs.StepStartPartSchema; }
|
|
118
126
|
});
|
|
119
127
|
Object.defineProperty(exports, "StructuredOutputProcessor", {
|
|
120
128
|
enumerable: true,
|
|
121
|
-
get: function () { return
|
|
129
|
+
get: function () { return chunkQLC3UBDY_cjs.StructuredOutputProcessor; }
|
|
122
130
|
});
|
|
123
131
|
Object.defineProperty(exports, "SystemPromptScrubber", {
|
|
124
132
|
enumerable: true,
|
|
125
|
-
get: function () { return
|
|
133
|
+
get: function () { return chunkQLC3UBDY_cjs.SystemPromptScrubber; }
|
|
126
134
|
});
|
|
127
135
|
Object.defineProperty(exports, "TextPartSchema", {
|
|
128
136
|
enumerable: true,
|
|
129
|
-
get: function () { return
|
|
137
|
+
get: function () { return chunkQLC3UBDY_cjs.TextPartSchema; }
|
|
130
138
|
});
|
|
131
139
|
Object.defineProperty(exports, "TokenLimiter", {
|
|
132
140
|
enumerable: true,
|
|
133
|
-
get: function () { return
|
|
141
|
+
get: function () { return chunkQLC3UBDY_cjs.TokenLimiterProcessor; }
|
|
134
142
|
});
|
|
135
143
|
Object.defineProperty(exports, "TokenLimiterProcessor", {
|
|
136
144
|
enumerable: true,
|
|
137
|
-
get: function () { return
|
|
145
|
+
get: function () { return chunkQLC3UBDY_cjs.TokenLimiterProcessor; }
|
|
138
146
|
});
|
|
139
147
|
Object.defineProperty(exports, "ToolCallFilter", {
|
|
140
148
|
enumerable: true,
|
|
141
|
-
get: function () { return
|
|
149
|
+
get: function () { return chunkQLC3UBDY_cjs.ToolCallFilter; }
|
|
142
150
|
});
|
|
143
151
|
Object.defineProperty(exports, "ToolInvocationPartSchema", {
|
|
144
152
|
enumerable: true,
|
|
145
|
-
get: function () { return
|
|
153
|
+
get: function () { return chunkQLC3UBDY_cjs.ToolInvocationPartSchema; }
|
|
146
154
|
});
|
|
147
155
|
Object.defineProperty(exports, "ToolSearchProcessor", {
|
|
148
156
|
enumerable: true,
|
|
149
|
-
get: function () { return
|
|
157
|
+
get: function () { return chunkQLC3UBDY_cjs.ToolSearchProcessor; }
|
|
150
158
|
});
|
|
151
159
|
Object.defineProperty(exports, "UnicodeNormalizer", {
|
|
152
160
|
enumerable: true,
|
|
153
|
-
get: function () { return
|
|
161
|
+
get: function () { return chunkQLC3UBDY_cjs.UnicodeNormalizer; }
|
|
154
162
|
});
|
|
155
163
|
Object.defineProperty(exports, "WorkingMemory", {
|
|
156
164
|
enumerable: true,
|
|
157
|
-
get: function () { return
|
|
165
|
+
get: function () { return chunkQLC3UBDY_cjs.WorkingMemory; }
|
|
158
166
|
});
|
|
159
167
|
Object.defineProperty(exports, "WorkspaceInstructionsProcessor", {
|
|
160
168
|
enumerable: true,
|
|
161
|
-
get: function () { return
|
|
169
|
+
get: function () { return chunkQLC3UBDY_cjs.WorkspaceInstructionsProcessor; }
|
|
162
170
|
});
|
|
163
171
|
Object.defineProperty(exports, "globalEmbeddingCache", {
|
|
164
172
|
enumerable: true,
|
|
165
|
-
get: function () { return
|
|
173
|
+
get: function () { return chunkQLC3UBDY_cjs.globalEmbeddingCache; }
|
|
166
174
|
});
|
|
167
175
|
Object.defineProperty(exports, "isProcessorWorkflow", {
|
|
168
176
|
enumerable: true,
|
|
169
|
-
get: function () { return
|
|
177
|
+
get: function () { return chunkQLC3UBDY_cjs.isProcessorWorkflow; }
|
|
170
178
|
});
|
|
171
179
|
//# sourceMappingURL=index.cjs.map
|
|
172
180
|
//# sourceMappingURL=index.cjs.map
|
package/dist/processors/index.js
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export { BaseProcessor, BatchPartsProcessor, FilePartSchema, ImagePartSchema, LanguageDetector, MessageContentSchema, MessageHistory, MessagePartSchema, ModerationProcessor, PIIDetector, ProcessorInputPhaseSchema, ProcessorInputStepPhaseSchema, ProcessorMessageContentSchema, ProcessorMessageSchema, ProcessorOutputResultPhaseSchema, ProcessorOutputStepPhaseSchema, ProcessorOutputStreamPhaseSchema, ProcessorRunner, ProcessorState, ProcessorStepInputSchema, ProcessorStepOutputSchema, ProcessorStepSchema, PromptInjectionDetector, ReasoningPartSchema, SemanticRecall, SkillsProcessor, SourcePartSchema, StepStartPartSchema, StructuredOutputProcessor, SystemPromptScrubber, TextPartSchema, TokenLimiterProcessor as TokenLimiter, TokenLimiterProcessor, ToolCallFilter, ToolInvocationPartSchema, ToolSearchProcessor, UnicodeNormalizer, WorkingMemory, WorkspaceInstructionsProcessor, globalEmbeddingCache, isProcessorWorkflow } from '../chunk-
|
|
1
|
+
export { AgentsMDInjector, BaseProcessor, BatchPartsProcessor, FilePartSchema, ImagePartSchema, LanguageDetector, MessageContentSchema, MessageHistory, MessagePartSchema, ModerationProcessor, PIIDetector, ProcessorInputPhaseSchema, ProcessorInputStepPhaseSchema, ProcessorMessageContentSchema, ProcessorMessageSchema, ProcessorOutputResultPhaseSchema, ProcessorOutputStepPhaseSchema, ProcessorOutputStreamPhaseSchema, ProcessorRunner, ProcessorState, ProcessorStepInputSchema, ProcessorStepOutputSchema, ProcessorStepSchema, PromptInjectionDetector, ReasoningPartSchema, SemanticRecall, SkillSearchProcessor, SkillsProcessor, SourcePartSchema, StepStartPartSchema, StructuredOutputProcessor, SystemPromptScrubber, TextPartSchema, TokenLimiterProcessor as TokenLimiter, TokenLimiterProcessor, ToolCallFilter, ToolInvocationPartSchema, ToolSearchProcessor, UnicodeNormalizer, WorkingMemory, WorkspaceInstructionsProcessor, globalEmbeddingCache, isProcessorWorkflow } from '../chunk-IYSW4VN7.js';
|
|
2
2
|
//# sourceMappingURL=index.js.map
|
|
3
3
|
//# sourceMappingURL=index.js.map
|
|
@@ -8,7 +8,9 @@ export { BatchPartsProcessor, type BatchPartsOptions, type BatchPartsState } fro
|
|
|
8
8
|
export { TokenLimiterProcessor, TokenLimiterProcessor as TokenLimiter, type TokenLimiterOptions, } from './token-limiter.js';
|
|
9
9
|
export { SystemPromptScrubber, type SystemPromptScrubberOptions, type SystemPromptDetectionResult, type SystemPromptDetection, } from './system-prompt-scrubber.js';
|
|
10
10
|
export { ToolCallFilter } from './tool-call-filter.js';
|
|
11
|
+
export { AgentsMDInjector, type ToolResultReminderOptions } from '../tool-result-reminder.js';
|
|
11
12
|
export { ToolSearchProcessor, type ToolSearchProcessorOptions } from './tool-search.js';
|
|
12
13
|
export { SkillsProcessor, type SkillsProcessorOptions } from './skills.js';
|
|
14
|
+
export { SkillSearchProcessor, type SkillSearchProcessorOptions } from './skill-search.js';
|
|
13
15
|
export { WorkspaceInstructionsProcessor, type WorkspaceInstructionsProcessorOptions } from './workspace-instructions.js';
|
|
14
16
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/processors/processors/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,KAAK,wBAAwB,EAAE,MAAM,sBAAsB,CAAC;AACxF,OAAO,EACL,mBAAmB,EACnB,KAAK,iBAAiB,EACtB,KAAK,gBAAgB,EACrB,KAAK,wBAAwB,GAC9B,MAAM,cAAc,CAAC;AACtB,OAAO,EACL,uBAAuB,EACvB,KAAK,sBAAsB,EAC3B,KAAK,qBAAqB,EAC1B,KAAK,6BAA6B,GACnC,MAAM,6BAA6B,CAAC;AACrC,OAAO,EACL,WAAW,EACX,KAAK,kBAAkB,EACvB,KAAK,kBAAkB,EACvB,KAAK,aAAa,EAClB,KAAK,iBAAiB,EACtB,KAAK,YAAY,GAClB,MAAM,gBAAgB,CAAC;AACxB,OAAO,EACL,gBAAgB,EAChB,KAAK,uBAAuB,EAC5B,KAAK,uBAAuB,EAC5B,KAAK,iBAAiB,EACtB,KAAK,iBAAiB,GACvB,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EAAE,yBAAyB,EAAE,KAAK,uBAAuB,EAAE,MAAM,qBAAqB,CAAC;AAC9F,OAAO,EAAE,mBAAmB,EAAE,KAAK,iBAAiB,EAAE,KAAK,eAAe,EAAE,MAAM,eAAe,CAAC;AAClG,OAAO,EACL,qBAAqB,EACrB,qBAAqB,IAAI,YAAY,EACrC,KAAK,mBAAmB,GACzB,MAAM,iBAAiB,CAAC;AACzB,OAAO,EACL,oBAAoB,EACpB,KAAK,2BAA2B,EAChC,KAAK,2BAA2B,EAChC,KAAK,qBAAqB,GAC3B,MAAM,0BAA0B,CAAC;AAElC,OAAO,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AAEpD,OAAO,EAAE,mBAAmB,EAAE,KAAK,0BAA0B,EAAE,MAAM,eAAe,CAAC;AACrF,OAAO,EAAE,eAAe,EAAE,KAAK,sBAAsB,EAAE,MAAM,UAAU,CAAC;AACxE,OAAO,EAAE,8BAA8B,EAAE,KAAK,qCAAqC,EAAE,MAAM,0BAA0B,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/processors/processors/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,KAAK,wBAAwB,EAAE,MAAM,sBAAsB,CAAC;AACxF,OAAO,EACL,mBAAmB,EACnB,KAAK,iBAAiB,EACtB,KAAK,gBAAgB,EACrB,KAAK,wBAAwB,GAC9B,MAAM,cAAc,CAAC;AACtB,OAAO,EACL,uBAAuB,EACvB,KAAK,sBAAsB,EAC3B,KAAK,qBAAqB,EAC1B,KAAK,6BAA6B,GACnC,MAAM,6BAA6B,CAAC;AACrC,OAAO,EACL,WAAW,EACX,KAAK,kBAAkB,EACvB,KAAK,kBAAkB,EACvB,KAAK,aAAa,EAClB,KAAK,iBAAiB,EACtB,KAAK,YAAY,GAClB,MAAM,gBAAgB,CAAC;AACxB,OAAO,EACL,gBAAgB,EAChB,KAAK,uBAAuB,EAC5B,KAAK,uBAAuB,EAC5B,KAAK,iBAAiB,EACtB,KAAK,iBAAiB,GACvB,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EAAE,yBAAyB,EAAE,KAAK,uBAAuB,EAAE,MAAM,qBAAqB,CAAC;AAC9F,OAAO,EAAE,mBAAmB,EAAE,KAAK,iBAAiB,EAAE,KAAK,eAAe,EAAE,MAAM,eAAe,CAAC;AAClG,OAAO,EACL,qBAAqB,EACrB,qBAAqB,IAAI,YAAY,EACrC,KAAK,mBAAmB,GACzB,MAAM,iBAAiB,CAAC;AACzB,OAAO,EACL,oBAAoB,EACpB,KAAK,2BAA2B,EAChC,KAAK,2BAA2B,EAChC,KAAK,qBAAqB,GAC3B,MAAM,0BAA0B,CAAC;AAElC,OAAO,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AAEpD,OAAO,EAAE,gBAAgB,EAAE,KAAK,yBAAyB,EAAE,MAAM,yBAAyB,CAAC;AAE3F,OAAO,EAAE,mBAAmB,EAAE,KAAK,0BAA0B,EAAE,MAAM,eAAe,CAAC;AACrF,OAAO,EAAE,eAAe,EAAE,KAAK,sBAAsB,EAAE,MAAM,UAAU,CAAC;AACxE,OAAO,EAAE,oBAAoB,EAAE,KAAK,2BAA2B,EAAE,MAAM,gBAAgB,CAAC;AACxF,OAAO,EAAE,8BAA8B,EAAE,KAAK,qCAAqC,EAAE,MAAM,0BAA0B,CAAC"}
|
|
@@ -0,0 +1,111 @@
|
|
|
1
|
+
import type { Workspace } from '../../workspace/workspace.js';
|
|
2
|
+
import type { ProcessInputStepArgs, Processor } from '../index.js';
|
|
3
|
+
/**
|
|
4
|
+
* Configuration options for SkillSearchProcessor
|
|
5
|
+
*/
|
|
6
|
+
export interface SkillSearchProcessorOptions {
|
|
7
|
+
/**
|
|
8
|
+
* Workspace instance containing skills.
|
|
9
|
+
* Skills are accessed via workspace.skills.
|
|
10
|
+
*/
|
|
11
|
+
workspace: Workspace;
|
|
12
|
+
/**
|
|
13
|
+
* Configuration for the search behavior
|
|
14
|
+
*/
|
|
15
|
+
search?: {
|
|
16
|
+
/**
|
|
17
|
+
* Maximum number of skills to return in search results
|
|
18
|
+
* @default 5
|
|
19
|
+
*/
|
|
20
|
+
topK?: number;
|
|
21
|
+
/**
|
|
22
|
+
* Minimum relevance score for including a skill in search results
|
|
23
|
+
* @default 0
|
|
24
|
+
*/
|
|
25
|
+
minScore?: number;
|
|
26
|
+
};
|
|
27
|
+
/**
|
|
28
|
+
* Time-to-live for thread state in milliseconds.
|
|
29
|
+
* After this duration of inactivity, thread state will be eligible for cleanup.
|
|
30
|
+
* Set to 0 to disable TTL cleanup.
|
|
31
|
+
* @default 3600000 (1 hour)
|
|
32
|
+
*/
|
|
33
|
+
ttl?: number;
|
|
34
|
+
}
|
|
35
|
+
/**
|
|
36
|
+
* Processor that enables on-demand skill discovery and loading.
|
|
37
|
+
*
|
|
38
|
+
* Instead of injecting all skill metadata upfront, this processor:
|
|
39
|
+
* 1. Gives the agent two meta-tools: search_skills and load_skill
|
|
40
|
+
* 2. Agent searches for relevant skills using keywords
|
|
41
|
+
* 3. Agent loads specific skills into the conversation on demand
|
|
42
|
+
* 4. Loaded skill instructions appear as system messages
|
|
43
|
+
*
|
|
44
|
+
* This pattern reduces context usage when workspaces have many skills.
|
|
45
|
+
*/
|
|
46
|
+
export declare class SkillSearchProcessor implements Processor<'skill-search'> {
|
|
47
|
+
readonly id = "skill-search";
|
|
48
|
+
readonly name = "Skill Search Processor";
|
|
49
|
+
readonly description = "Enables on-demand skill discovery and loading via search";
|
|
50
|
+
private readonly workspace;
|
|
51
|
+
private readonly searchConfig;
|
|
52
|
+
private readonly ttl;
|
|
53
|
+
private cleanupIntervalId?;
|
|
54
|
+
/**
|
|
55
|
+
* Thread-scoped state management for loaded skills with TTL support.
|
|
56
|
+
* Maps threadId -> ThreadState (skills + timestamp)
|
|
57
|
+
*/
|
|
58
|
+
private threadLoadedSkills;
|
|
59
|
+
constructor(options: SkillSearchProcessorOptions);
|
|
60
|
+
/**
|
|
61
|
+
* Dispose of this processor, clearing the cleanup interval and all thread state.
|
|
62
|
+
* Call this when the processor is no longer needed to prevent timer leaks.
|
|
63
|
+
*/
|
|
64
|
+
dispose(): void;
|
|
65
|
+
/**
|
|
66
|
+
* Get the workspace skills interface
|
|
67
|
+
*/
|
|
68
|
+
private get skills();
|
|
69
|
+
/**
|
|
70
|
+
* Get the thread ID from the request context, or use 'default' as fallback.
|
|
71
|
+
*/
|
|
72
|
+
private getThreadId;
|
|
73
|
+
/**
|
|
74
|
+
* Get or create thread state for the given thread.
|
|
75
|
+
* Updates the lastAccessed timestamp for TTL management.
|
|
76
|
+
*/
|
|
77
|
+
private getThreadState;
|
|
78
|
+
/**
|
|
79
|
+
* Clear loaded skills for a specific thread.
|
|
80
|
+
*/
|
|
81
|
+
clearState(threadId?: string): void;
|
|
82
|
+
/**
|
|
83
|
+
* Clear all thread state for this processor instance.
|
|
84
|
+
*/
|
|
85
|
+
clearAllState(): void;
|
|
86
|
+
/**
|
|
87
|
+
* Clean up stale thread state based on TTL.
|
|
88
|
+
* @returns Number of threads cleaned up
|
|
89
|
+
*/
|
|
90
|
+
private cleanupStaleState;
|
|
91
|
+
/**
|
|
92
|
+
* Schedule periodic cleanup of stale thread state.
|
|
93
|
+
*/
|
|
94
|
+
private scheduleCleanup;
|
|
95
|
+
/**
|
|
96
|
+
* Get statistics about current thread state.
|
|
97
|
+
*/
|
|
98
|
+
getStateStats(): {
|
|
99
|
+
threadCount: number;
|
|
100
|
+
oldestAccessTime: number | null;
|
|
101
|
+
};
|
|
102
|
+
/**
|
|
103
|
+
* Manually trigger cleanup of stale state.
|
|
104
|
+
* @returns Number of threads cleaned up
|
|
105
|
+
*/
|
|
106
|
+
cleanupNow(): number;
|
|
107
|
+
processInputStep(args: ProcessInputStepArgs): Promise<{
|
|
108
|
+
tools: Record<string, unknown> | undefined;
|
|
109
|
+
}>;
|
|
110
|
+
}
|
|
111
|
+
//# sourceMappingURL=skill-search.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"skill-search.d.ts","sourceRoot":"","sources":["../../../src/processors/processors/skill-search.ts"],"names":[],"mappings":"AA2BA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,2BAA2B,CAAC;AAC3D,OAAO,KAAK,EAAE,oBAAoB,EAAE,SAAS,EAAE,MAAM,UAAU,CAAC;AAWhE;;GAEG;AACH,MAAM,WAAW,2BAA2B;IAC1C;;;OAGG;IACH,SAAS,EAAE,SAAS,CAAC;IAErB;;OAEG;IACH,MAAM,CAAC,EAAE;QACP;;;WAGG;QACH,IAAI,CAAC,EAAE,MAAM,CAAC;QAEd;;;WAGG;QACH,QAAQ,CAAC,EAAE,MAAM,CAAC;KACnB,CAAC;IAEF;;;;;OAKG;IACH,GAAG,CAAC,EAAE,MAAM,CAAC;CACd;AAED;;;;;;;;;;GAUG;AACH,qBAAa,oBAAqB,YAAW,SAAS,CAAC,cAAc,CAAC;IACpE,QAAQ,CAAC,EAAE,kBAAkB;IAC7B,QAAQ,CAAC,IAAI,4BAA4B;IACzC,QAAQ,CAAC,WAAW,8DAA8D;IAElF,OAAO,CAAC,QAAQ,CAAC,SAAS,CAAY;IACtC,OAAO,CAAC,QAAQ,CAAC,YAAY,CAAqC;IAClE,OAAO,CAAC,QAAQ,CAAC,GAAG,CAAS;IAC7B,OAAO,CAAC,iBAAiB,CAAC,CAAiC;IAE3D;;;OAGG;IACH,OAAO,CAAC,kBAAkB,CAAkC;gBAEhD,OAAO,EAAE,2BAA2B;IAahD;;;OAGG;IACI,OAAO,IAAI,IAAI;IAQtB;;OAEG;IACH,OAAO,KAAK,MAAM,GAEjB;IAED;;OAEG;IACH,OAAO,CAAC,WAAW;IAInB;;;OAGG;IACH,OAAO,CAAC,cAAc;IAYtB;;OAEG;IACI,UAAU,CAAC,QAAQ,GAAE,MAAkB,GAAG,IAAI;IAIrD;;OAEG;IACI,aAAa,IAAI,IAAI;IAI5B;;;OAGG;IACH,OAAO,CAAC,iBAAiB;IAgBzB;;OAEG;IACH,OAAO,CAAC,eAAe;IAWvB;;OAEG;IACI,aAAa,IAAI;QAAE,WAAW,EAAE,MAAM,CAAC;QAAC,gBAAgB,EAAE,MAAM,GAAG,IAAI,CAAA;KAAE;IAkBhF;;;OAGG;IACI,UAAU,IAAI,MAAM;IAIrB,gBAAgB,CAAC,IAAI,EAAE,oBAAoB;;;CAoKlD"}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import type { MessageList, MastraDBMessage } from '../agent/message-list/index.js';
|
|
2
|
+
import type { ProcessInputStepArgs, Processor } from './index.js';
|
|
3
|
+
export interface ToolResultReminderOptions {
|
|
4
|
+
reminderText?: string;
|
|
5
|
+
pathExists?: (path: string) => boolean;
|
|
6
|
+
isDirectory?: (path: string) => boolean;
|
|
7
|
+
readFile?: (path: string) => string;
|
|
8
|
+
getIgnoredInstructionPaths?: (args: ProcessInputStepArgs) => string[];
|
|
9
|
+
}
|
|
10
|
+
/**
|
|
11
|
+
* Injects a persisted UI-visible reminder when the agent just interacted with
|
|
12
|
+
* a path whose directory ancestry contains an instruction file such as AGENTS.md.
|
|
13
|
+
*/
|
|
14
|
+
export declare class AgentsMDInjector implements Processor<'agents-md-injector'> {
|
|
15
|
+
id: "agents-md-injector";
|
|
16
|
+
name: string;
|
|
17
|
+
description: string;
|
|
18
|
+
processorIndex: number;
|
|
19
|
+
private readonly reminderText?;
|
|
20
|
+
private readonly pathExists;
|
|
21
|
+
private readonly isDirectory;
|
|
22
|
+
private readonly readFile;
|
|
23
|
+
private readonly getIgnoredInstructionPaths?;
|
|
24
|
+
constructor(options: ToolResultReminderOptions);
|
|
25
|
+
processInputStep(args: ProcessInputStepArgs): Promise<MessageList | MastraDBMessage[]>;
|
|
26
|
+
private getReminderText;
|
|
27
|
+
private isIgnoredInstructionPath;
|
|
28
|
+
private findReferencedInstructionPath;
|
|
29
|
+
private findInstructionPathInInvocation;
|
|
30
|
+
private hasReminderAlready;
|
|
31
|
+
}
|
|
32
|
+
//# sourceMappingURL=tool-result-reminder.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tool-result-reminder.d.ts","sourceRoot":"","sources":["../../src/processors/tool-result-reminder.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,WAAW,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AAE1E,OAAO,KAAK,EAAE,oBAAoB,EAAE,SAAS,EAAgB,MAAM,SAAS,CAAC;AA8B7E,MAAM,WAAW,yBAAyB;IACxC,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,UAAU,CAAC,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,OAAO,CAAC;IACvC,WAAW,CAAC,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,OAAO,CAAC;IACxC,QAAQ,CAAC,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,MAAM,CAAC;IACpC,0BAA0B,CAAC,EAAE,CAAC,IAAI,EAAE,oBAAoB,KAAK,MAAM,EAAE,CAAC;CACvE;AAuHD;;;GAGG;AACH,qBAAa,gBAAiB,YAAW,SAAS,CAAC,oBAAoB,CAAC;IACtE,EAAE,EAAG,oBAAoB,CAAU;IACnC,IAAI,SAAwB;IAC5B,WAAW,SAA+E;IAC1F,cAAc,SAAK;IAEnB,OAAO,CAAC,QAAQ,CAAC,YAAY,CAAC,CAAS;IACvC,OAAO,CAAC,QAAQ,CAAC,UAAU,CAA4B;IACvD,OAAO,CAAC,QAAQ,CAAC,WAAW,CAA4B;IACxD,OAAO,CAAC,QAAQ,CAAC,QAAQ,CAA2B;IACpD,OAAO,CAAC,QAAQ,CAAC,0BAA0B,CAAC,CAA2C;gBAE3E,OAAO,EAAE,yBAAyB;IAgBxC,gBAAgB,CAAC,IAAI,EAAE,oBAAoB,GAAG,OAAO,CAAC,WAAW,GAAG,eAAe,EAAE,CAAC;IAsC5F,OAAO,CAAC,eAAe;IAavB,OAAO,CAAC,wBAAwB;IAMhC,OAAO,CAAC,6BAA6B;IAerC,OAAO,CAAC,+BAA+B;IAyBvC,OAAO,CAAC,kBAAkB;CAG3B"}
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
export { GatewayRegistry, PROVIDER_MODELS, PROVIDER_REGISTRY, getProviderConfig, getRegisteredProviders, isProviderRegistered, isValidModelId, parseModelString } from './chunk-IOKPS5RD.js';
|
|
2
|
+
//# sourceMappingURL=provider-registry-IP3K4FE4.js.map
|
|
3
|
+
//# sourceMappingURL=provider-registry-IP3K4FE4.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":[],"names":[],"mappings":"","file":"provider-registry-
|
|
1
|
+
{"version":3,"sources":[],"names":[],"mappings":"","file":"provider-registry-IP3K4FE4.js"}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var chunkTPJSYHLC_cjs = require('./chunk-TPJSYHLC.cjs');
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
Object.defineProperty(exports, "GatewayRegistry", {
|
|
8
|
+
enumerable: true,
|
|
9
|
+
get: function () { return chunkTPJSYHLC_cjs.GatewayRegistry; }
|
|
10
|
+
});
|
|
11
|
+
Object.defineProperty(exports, "PROVIDER_MODELS", {
|
|
12
|
+
enumerable: true,
|
|
13
|
+
get: function () { return chunkTPJSYHLC_cjs.PROVIDER_MODELS; }
|
|
14
|
+
});
|
|
15
|
+
Object.defineProperty(exports, "PROVIDER_REGISTRY", {
|
|
16
|
+
enumerable: true,
|
|
17
|
+
get: function () { return chunkTPJSYHLC_cjs.PROVIDER_REGISTRY; }
|
|
18
|
+
});
|
|
19
|
+
Object.defineProperty(exports, "getProviderConfig", {
|
|
20
|
+
enumerable: true,
|
|
21
|
+
get: function () { return chunkTPJSYHLC_cjs.getProviderConfig; }
|
|
22
|
+
});
|
|
23
|
+
Object.defineProperty(exports, "getRegisteredProviders", {
|
|
24
|
+
enumerable: true,
|
|
25
|
+
get: function () { return chunkTPJSYHLC_cjs.getRegisteredProviders; }
|
|
26
|
+
});
|
|
27
|
+
Object.defineProperty(exports, "isProviderRegistered", {
|
|
28
|
+
enumerable: true,
|
|
29
|
+
get: function () { return chunkTPJSYHLC_cjs.isProviderRegistered; }
|
|
30
|
+
});
|
|
31
|
+
Object.defineProperty(exports, "isValidModelId", {
|
|
32
|
+
enumerable: true,
|
|
33
|
+
get: function () { return chunkTPJSYHLC_cjs.isValidModelId; }
|
|
34
|
+
});
|
|
35
|
+
Object.defineProperty(exports, "parseModelString", {
|
|
36
|
+
enumerable: true,
|
|
37
|
+
get: function () { return chunkTPJSYHLC_cjs.parseModelString; }
|
|
38
|
+
});
|
|
39
|
+
//# sourceMappingURL=provider-registry-S6VYJ3GX.cjs.map
|
|
40
|
+
//# sourceMappingURL=provider-registry-S6VYJ3GX.cjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":[],"names":[],"mappings":"","file":"provider-registry-
|
|
1
|
+
{"version":3,"sources":[],"names":[],"mappings":"","file":"provider-registry-S6VYJ3GX.cjs"}
|
|
@@ -37,6 +37,7 @@
|
|
|
37
37
|
"glm-4.6v",
|
|
38
38
|
"glm-4.7",
|
|
39
39
|
"glm-4.7-flash",
|
|
40
|
+
"glm-4.7-flashx",
|
|
40
41
|
"glm-5",
|
|
41
42
|
"glm-5-turbo"
|
|
42
43
|
],
|
|
@@ -1643,6 +1644,8 @@
|
|
|
1643
1644
|
"glm-4.6v",
|
|
1644
1645
|
"glm-4.6v-flash",
|
|
1645
1646
|
"glm-4.7",
|
|
1647
|
+
"glm-4.7-flash",
|
|
1648
|
+
"glm-4.7-flashx",
|
|
1646
1649
|
"glm-5",
|
|
1647
1650
|
"glm-5-turbo"
|
|
1648
1651
|
],
|
|
@@ -1740,6 +1743,7 @@
|
|
|
1740
1743
|
"mistralai/devstral-small-2507",
|
|
1741
1744
|
"mistralai/mistral-medium-3",
|
|
1742
1745
|
"mistralai/mistral-medium-3.1",
|
|
1746
|
+
"mistralai/mistral-small-2603",
|
|
1743
1747
|
"mistralai/mistral-small-3.1-24b-instruct",
|
|
1744
1748
|
"mistralai/mistral-small-3.2-24b-instruct",
|
|
1745
1749
|
"moonshotai/kimi-k2",
|
|
@@ -2095,6 +2099,7 @@
|
|
|
2095
2099
|
"glm-4.6v",
|
|
2096
2100
|
"glm-4.7",
|
|
2097
2101
|
"glm-4.7-flash",
|
|
2102
|
+
"glm-4.7-flashx",
|
|
2098
2103
|
"glm-5"
|
|
2099
2104
|
],
|
|
2100
2105
|
"docUrl": "https://docs.z.ai/guides/overview/pricing",
|
|
@@ -4271,6 +4276,7 @@
|
|
|
4271
4276
|
"glm-4.6v",
|
|
4272
4277
|
"glm-4.7",
|
|
4273
4278
|
"glm-4.7-flash",
|
|
4279
|
+
"glm-4.7-flashx",
|
|
4274
4280
|
"glm-5",
|
|
4275
4281
|
"glm-5-turbo"
|
|
4276
4282
|
],
|
|
@@ -5505,6 +5511,8 @@
|
|
|
5505
5511
|
"glm-4.6v",
|
|
5506
5512
|
"glm-4.6v-flash",
|
|
5507
5513
|
"glm-4.7",
|
|
5514
|
+
"glm-4.7-flash",
|
|
5515
|
+
"glm-4.7-flashx",
|
|
5508
5516
|
"glm-5",
|
|
5509
5517
|
"glm-5-turbo"
|
|
5510
5518
|
],
|
|
@@ -5580,6 +5588,7 @@
|
|
|
5580
5588
|
"mistralai/devstral-small-2507",
|
|
5581
5589
|
"mistralai/mistral-medium-3",
|
|
5582
5590
|
"mistralai/mistral-medium-3.1",
|
|
5591
|
+
"mistralai/mistral-small-2603",
|
|
5583
5592
|
"mistralai/mistral-small-3.1-24b-instruct",
|
|
5584
5593
|
"mistralai/mistral-small-3.2-24b-instruct",
|
|
5585
5594
|
"moonshotai/kimi-k2",
|
|
@@ -5868,6 +5877,7 @@
|
|
|
5868
5877
|
"glm-4.6v",
|
|
5869
5878
|
"glm-4.7",
|
|
5870
5879
|
"glm-4.7-flash",
|
|
5880
|
+
"glm-4.7-flashx",
|
|
5871
5881
|
"glm-5"
|
|
5872
5882
|
],
|
|
5873
5883
|
"nova": ["nova-2-lite-v1", "nova-2-pro-v1"],
|
package/dist/relevance/index.cjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var chunkQLC3UBDY_cjs = require('../chunk-QLC3UBDY.cjs');
|
|
4
4
|
|
|
5
5
|
// src/relevance/relevance-score-provider.ts
|
|
6
6
|
function createSimilarityPrompt(query, text) {
|
|
@@ -17,7 +17,7 @@ Relevance score (0-1):`;
|
|
|
17
17
|
var MastraAgentRelevanceScorer = class {
|
|
18
18
|
agent;
|
|
19
19
|
constructor(name, model) {
|
|
20
|
-
this.agent = new
|
|
20
|
+
this.agent = new chunkQLC3UBDY_cjs.Agent({
|
|
21
21
|
id: `relevance-scorer-${name}`,
|
|
22
22
|
name: `Relevance Scorer ${name}`,
|
|
23
23
|
instructions: `You are a specialized agent for evaluating the relevance of text to queries.
|
|
@@ -37,7 +37,7 @@ Always return just the number, no explanation.`,
|
|
|
37
37
|
const prompt = createSimilarityPrompt(query, text);
|
|
38
38
|
const model = await this.agent.getModel();
|
|
39
39
|
let response;
|
|
40
|
-
if (
|
|
40
|
+
if (chunkQLC3UBDY_cjs.isSupportedLanguageModel(model)) {
|
|
41
41
|
const responseText = await this.agent.generate(prompt);
|
|
42
42
|
response = responseText.text;
|
|
43
43
|
} else {
|
package/dist/relevance/index.js
CHANGED