@mastra/core 0.2.0-alpha.98 → 0.2.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.
Files changed (84) hide show
  1. package/dist/agent/index.d.ts +6 -8
  2. package/dist/agent/index.js +15 -7
  3. package/dist/{telemetry-oCUM52DG.d.ts → base-BbtPAA6f.d.ts} +50 -8
  4. package/dist/{index-Cwb-5AzX.d.ts → base-Bpb7Dmwe.d.ts} +367 -320
  5. package/dist/base.d.ts +3 -43
  6. package/dist/base.js +3 -3
  7. package/dist/bundler/index.d.ts +3 -4
  8. package/dist/bundler/index.js +4 -4
  9. package/dist/{chunk-MCB4M5W4.js → chunk-22LC46YN.js} +3 -9
  10. package/dist/{chunk-MG3WAQV7.js → chunk-2JL6DQMZ.js} +20 -28
  11. package/dist/chunk-2SAHBQEF.js +3 -0
  12. package/dist/chunk-3HBFW3Q7.js +24 -0
  13. package/dist/{chunk-KNPBNSJ7.js → chunk-55GTEVHJ.js} +12 -13
  14. package/dist/chunk-65VPTVVP.js +218 -0
  15. package/dist/chunk-AWEACB2T.js +66 -0
  16. package/dist/chunk-C6A6W6XS.js +49 -0
  17. package/dist/chunk-FGZVE4CM.js +404 -0
  18. package/dist/{chunk-TYIBRZOY.js → chunk-J3W3IHDO.js} +120 -87
  19. package/dist/chunk-K36NSQWH.js +10 -0
  20. package/dist/{chunk-QXH6EK72.js → chunk-K4DFI76V.js} +382 -370
  21. package/dist/{chunk-42DYOLDV.js → chunk-MEISIZMP.js} +13 -21
  22. package/dist/chunk-MLWGYRJR.js +87 -0
  23. package/dist/{chunk-ICMEXHKD.js → chunk-O2VP5JBC.js} +48 -55
  24. package/dist/{chunk-ZJOMHCWE.js → chunk-OJ26F3J4.js} +98 -153
  25. package/dist/chunk-RG66XEJT.js +8 -0
  26. package/dist/chunk-SB37QG7O.js +1203 -0
  27. package/dist/chunk-SDBM53G4.js +32 -0
  28. package/dist/{chunk-4LJFWC2Q.js → chunk-SIFBBGY6.js} +59 -85
  29. package/dist/chunk-U6J2FOU4.js +624 -0
  30. package/dist/chunk-VB7CO5ND.js +31 -0
  31. package/dist/{chunk-C55JWGDU.js → chunk-ZJOXJFJI.js} +43 -15
  32. package/dist/deployer/index.d.ts +2 -4
  33. package/dist/deployer/index.js +5 -5
  34. package/dist/eval/index.d.ts +8 -13
  35. package/dist/eval/index.js +3 -3
  36. package/dist/filter/index.js +2 -2
  37. package/dist/hooks/index.d.ts +13 -18
  38. package/dist/hooks/index.js +2 -2
  39. package/dist/{index-CBZ2mk2H.d.ts → index-B2JCcAQt.d.ts} +1 -1
  40. package/dist/index.d.ts +15 -15
  41. package/dist/index.js +43 -69
  42. package/dist/integration/index.d.ts +8 -10
  43. package/dist/integration/index.js +6 -3
  44. package/dist/llm/index.d.ts +6 -8
  45. package/dist/llm/index.js +1 -1
  46. package/dist/logger/index.d.ts +1 -1
  47. package/dist/logger/index.js +2 -2
  48. package/dist/mastra/index.d.ts +10 -13
  49. package/dist/mastra/index.js +20 -4
  50. package/dist/memory/index.d.ts +8 -10
  51. package/dist/memory/index.js +11 -9
  52. package/dist/relevance/index.js +16 -8
  53. package/dist/storage/index.d.ts +21 -10
  54. package/dist/storage/index.js +8 -7
  55. package/dist/telemetry/index.d.ts +35 -5
  56. package/dist/telemetry/index.js +3 -2
  57. package/dist/telemetry/otel-vendor.d.ts +7 -0
  58. package/dist/telemetry/otel-vendor.js +8 -0
  59. package/dist/tools/index.d.ts +6 -8
  60. package/dist/tools/index.js +2 -2
  61. package/dist/tts/index.d.ts +2 -4
  62. package/dist/tts/index.js +6 -5
  63. package/dist/{metric-BWeQNZt6.d.ts → types-m9RryK9a.d.ts} +6 -1
  64. package/dist/utils.js +2 -2
  65. package/dist/vector/index.d.ts +4 -6
  66. package/dist/vector/index.js +4 -4
  67. package/dist/vector/libsql/index.d.ts +2 -4
  68. package/dist/vector/libsql/index.js +6 -6
  69. package/dist/{workflow-DTtv7_Eq.d.ts → workflow-Cy8UTGCt.d.ts} +3 -6
  70. package/dist/workflows/index.d.ts +7 -9
  71. package/dist/workflows/index.js +4 -4
  72. package/package.json +14 -10
  73. package/dist/chunk-4ZUSEHLH.js +0 -285
  74. package/dist/chunk-AJJZUHB4.js +0 -14
  75. package/dist/chunk-G4MCO7XF.js +0 -70
  76. package/dist/chunk-HBTQNIAX.js +0 -90
  77. package/dist/chunk-HPXWJBQK.js +0 -222
  78. package/dist/chunk-JJ57BXQR.js +0 -16
  79. package/dist/chunk-JP37ODNX.js +0 -36
  80. package/dist/chunk-K3N7KJHH.js +0 -52
  81. package/dist/chunk-MDM2JS2U.js +0 -1288
  82. package/dist/chunk-VOUPGVRD.js +0 -27
  83. package/dist/chunk-Z7JFMQZZ.js +0 -551
  84. /package/dist/{chunk-AE3H2QEY.js → chunk-VDOJTUYY.js} +0 -0
@@ -1,36 +0,0 @@
1
- import { executeHook, AvailableHooks } from './chunk-HBTQNIAX.js';
2
- import { __name } from './chunk-AJJZUHB4.js';
3
-
4
- // src/eval/metric.ts
5
- var _Metric = class _Metric {
6
- };
7
- __name(_Metric, "Metric");
8
- var Metric = _Metric;
9
-
10
- // src/eval/evaluation.ts
11
- async function evaluate({ agentName, input, metric, output, runId, globalRunId, testInfo, instructions }) {
12
- const runIdToUse = runId || crypto.randomUUID();
13
- const metricResult = await metric.measure(input.toString(), output);
14
- const traceObject = {
15
- input: input.toString(),
16
- output,
17
- result: metricResult,
18
- meta: {
19
- ...testInfo && {
20
- testName: testInfo.testName,
21
- testPath: testInfo.testPath
22
- },
23
- globalRunId,
24
- runId: runIdToUse,
25
- agentName,
26
- timestamp: (/* @__PURE__ */ new Date()).toISOString(),
27
- metricName: metric.constructor.name,
28
- instructions
29
- }
30
- };
31
- executeHook(AvailableHooks.ON_EVALUATION, traceObject);
32
- return metricResult;
33
- }
34
- __name(evaluate, "evaluate");
35
-
36
- export { Metric, evaluate };
@@ -1,52 +0,0 @@
1
- import { InstrumentClass } from './chunk-4ZUSEHLH.js';
2
- import { MastraBase } from './chunk-G4MCO7XF.js';
3
- import { __name, __publicField } from './chunk-AJJZUHB4.js';
4
-
5
- // src/tts/index.ts
6
- function _ts_decorate(decorators, target, key, desc) {
7
- var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
8
- if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
9
- else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
10
- return c > 3 && r && Object.defineProperty(target, key, r), r;
11
- }
12
- __name(_ts_decorate, "_ts_decorate");
13
- function _ts_metadata(k, v) {
14
- if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
15
- }
16
- __name(_ts_metadata, "_ts_metadata");
17
- var _MastraTTS = class _MastraTTS extends MastraBase {
18
- constructor({ model }) {
19
- super({
20
- component: "TTS"
21
- });
22
- __publicField(this, "model");
23
- this.model = model;
24
- }
25
- traced(method, methodName) {
26
- return this.telemetry?.traceMethod(method, {
27
- spanName: `${this.model.name}-tts.${methodName}`,
28
- attributes: {
29
- "tts.type": `${this.model.name}`
30
- }
31
- }) ?? method;
32
- }
33
- };
34
- __name(_MastraTTS, "MastraTTS");
35
- var MastraTTS = _MastraTTS;
36
- MastraTTS = _ts_decorate([
37
- InstrumentClass({
38
- prefix: "tts",
39
- excludeMethods: [
40
- "__setTools",
41
- "__setLogger",
42
- "__setTelemetry",
43
- "#log"
44
- ]
45
- }),
46
- _ts_metadata("design:type", Function),
47
- _ts_metadata("design:paramtypes", [
48
- typeof TTSConfig === "undefined" ? Object : TTSConfig
49
- ])
50
- ], MastraTTS);
51
-
52
- export { MastraTTS };