@mastra/core 0.0.0-commonjs-20250227130920

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 (137) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +180 -0
  3. package/dist/agent/index.cjs +1865 -0
  4. package/dist/agent/index.d.cts +15 -0
  5. package/dist/agent/index.d.ts +15 -0
  6. package/dist/agent/index.js +1 -0
  7. package/dist/base-D90KQ4XI.d.ts +139 -0
  8. package/dist/base-hs9NDAZ2.d.cts +139 -0
  9. package/dist/base-nKCMCNrM.d.ts +920 -0
  10. package/dist/base-nhesrHv3.d.cts +920 -0
  11. package/dist/base.cjs +138 -0
  12. package/dist/base.d.cts +6 -0
  13. package/dist/base.d.ts +6 -0
  14. package/dist/base.js +1 -0
  15. package/dist/bundler/index.cjs +158 -0
  16. package/dist/bundler/index.d.cts +28 -0
  17. package/dist/bundler/index.d.ts +28 -0
  18. package/dist/bundler/index.js +1 -0
  19. package/dist/chunk-33GSTUNK.js +620 -0
  20. package/dist/chunk-4YRYBCOZ.js +10 -0
  21. package/dist/chunk-55NFNRKO.js +10 -0
  22. package/dist/chunk-5XPCMNGW.js +215 -0
  23. package/dist/chunk-B3M27AMP.js +1479 -0
  24. package/dist/chunk-BB4KXGBU.js +83 -0
  25. package/dist/chunk-C6A6W6XS.js +77 -0
  26. package/dist/chunk-HQ55LN2U.js +318 -0
  27. package/dist/chunk-KNVTCZW7.js +416 -0
  28. package/dist/chunk-LH47WVJL.js +61 -0
  29. package/dist/chunk-NGD2HQYW.js +346 -0
  30. package/dist/chunk-NUDAZEOG.js +35 -0
  31. package/dist/chunk-OZ4XVJ6F.js +49 -0
  32. package/dist/chunk-PHMSPCTC.js +145 -0
  33. package/dist/chunk-PNZK456O.js +88 -0
  34. package/dist/chunk-QAAJAHDB.js +37 -0
  35. package/dist/chunk-RG66XEJT.js +8 -0
  36. package/dist/chunk-SIFBBGY6.js +190 -0
  37. package/dist/chunk-SVEAENO7.js +22 -0
  38. package/dist/chunk-SY5244IR.js +1499 -0
  39. package/dist/chunk-W5HVJX45.js +402 -0
  40. package/dist/chunk-WIBGG4X6.js +173 -0
  41. package/dist/chunk-ZDWFBE5L.js +1 -0
  42. package/dist/chunk-ZINPRHAN.js +22 -0
  43. package/dist/deployer/index.cjs +165 -0
  44. package/dist/deployer/index.d.cts +19 -0
  45. package/dist/deployer/index.d.ts +19 -0
  46. package/dist/deployer/index.js +1 -0
  47. package/dist/eval/index.cjs +110 -0
  48. package/dist/eval/index.d.cts +28 -0
  49. package/dist/eval/index.d.ts +28 -0
  50. package/dist/eval/index.js +1 -0
  51. package/dist/filter/index.cjs +192 -0
  52. package/dist/filter/index.d.cts +90 -0
  53. package/dist/filter/index.d.ts +90 -0
  54. package/dist/filter/index.js +1 -0
  55. package/dist/hooks/index.cjs +87 -0
  56. package/dist/hooks/index.d.cts +33 -0
  57. package/dist/hooks/index.d.ts +33 -0
  58. package/dist/hooks/index.js +1 -0
  59. package/dist/index-mKY1XrpK.d.cts +90 -0
  60. package/dist/index-mKY1XrpK.d.ts +90 -0
  61. package/dist/index.cjs +6844 -0
  62. package/dist/index.d.cts +97 -0
  63. package/dist/index.d.ts +97 -0
  64. package/dist/index.js +119 -0
  65. package/dist/integration/index.cjs +113 -0
  66. package/dist/integration/index.d.cts +52 -0
  67. package/dist/integration/index.d.ts +52 -0
  68. package/dist/integration/index.js +1 -0
  69. package/dist/llm/index.cjs +2 -0
  70. package/dist/llm/index.d.cts +15 -0
  71. package/dist/llm/index.d.ts +15 -0
  72. package/dist/llm/index.js +1 -0
  73. package/dist/logger/index.cjs +159 -0
  74. package/dist/logger/index.d.cts +3 -0
  75. package/dist/logger/index.d.ts +3 -0
  76. package/dist/logger/index.js +1 -0
  77. package/dist/mastra/index.cjs +1741 -0
  78. package/dist/mastra/index.d.cts +67 -0
  79. package/dist/mastra/index.d.ts +67 -0
  80. package/dist/mastra/index.js +1 -0
  81. package/dist/memory/index.cjs +1907 -0
  82. package/dist/memory/index.d.cts +15 -0
  83. package/dist/memory/index.d.ts +15 -0
  84. package/dist/memory/index.js +1 -0
  85. package/dist/relevance/index.cjs +1927 -0
  86. package/dist/relevance/index.d.cts +21 -0
  87. package/dist/relevance/index.d.ts +21 -0
  88. package/dist/relevance/index.js +1 -0
  89. package/dist/storage/index.cjs +361 -0
  90. package/dist/storage/index.d.cts +15 -0
  91. package/dist/storage/index.d.ts +15 -0
  92. package/dist/storage/index.js +2 -0
  93. package/dist/storage/libsql/index.cjs +770 -0
  94. package/dist/storage/libsql/index.d.cts +81 -0
  95. package/dist/storage/libsql/index.d.ts +81 -0
  96. package/dist/storage/libsql/index.js +1 -0
  97. package/dist/telemetry/index.cjs +413 -0
  98. package/dist/telemetry/index.d.cts +51 -0
  99. package/dist/telemetry/index.d.ts +51 -0
  100. package/dist/telemetry/index.js +1 -0
  101. package/dist/telemetry/otel-vendor.cjs +52 -0
  102. package/dist/telemetry/otel-vendor.d.cts +7 -0
  103. package/dist/telemetry/otel-vendor.d.ts +7 -0
  104. package/dist/telemetry/otel-vendor.js +7 -0
  105. package/dist/tools/index.cjs +25 -0
  106. package/dist/tools/index.d.cts +29 -0
  107. package/dist/tools/index.d.ts +29 -0
  108. package/dist/tools/index.js +1 -0
  109. package/dist/tts/index.cjs +328 -0
  110. package/dist/tts/index.d.cts +28 -0
  111. package/dist/tts/index.d.ts +28 -0
  112. package/dist/tts/index.js +1 -0
  113. package/dist/types-m9RryK9a.d.cts +14 -0
  114. package/dist/types-m9RryK9a.d.ts +14 -0
  115. package/dist/utils.cjs +179 -0
  116. package/dist/utils.d.cts +26 -0
  117. package/dist/utils.d.ts +26 -0
  118. package/dist/utils.js +1 -0
  119. package/dist/vector/index.cjs +145 -0
  120. package/dist/vector/index.d.cts +30 -0
  121. package/dist/vector/index.d.ts +30 -0
  122. package/dist/vector/index.js +1 -0
  123. package/dist/vector/libsql/index.cjs +951 -0
  124. package/dist/vector/libsql/index.d.cts +29 -0
  125. package/dist/vector/libsql/index.d.ts +29 -0
  126. package/dist/vector/libsql/index.js +1 -0
  127. package/dist/voice/index.cjs +369 -0
  128. package/dist/voice/index.d.cts +67 -0
  129. package/dist/voice/index.d.ts +67 -0
  130. package/dist/voice/index.js +76 -0
  131. package/dist/workflow-DqQ4pON_.d.cts +84 -0
  132. package/dist/workflow-Ng_F_Zaf.d.ts +84 -0
  133. package/dist/workflows/index.cjs +1628 -0
  134. package/dist/workflows/index.d.cts +48 -0
  135. package/dist/workflows/index.d.ts +48 -0
  136. package/dist/workflows/index.js +1 -0
  137. package/package.json +162 -0
@@ -0,0 +1,97 @@
1
+ import { a as Metric } from './types-m9RryK9a.cjs';
2
+ export { M as MetricResult, T as TestInfo } from './types-m9RryK9a.cjs';
3
+ import { m as ToolAction, A as Agent$1, n as AgentConfig, M as MastraStorage$1, a as MastraMemory$1, o as ToolExecutionContext, W as WorkflowOptions } from './base-nhesrHv3.cjs';
4
+ export { Z as ActionContext, Y as BaseCondition, B as BaseStructuredOutputType, r as CoreAssistantMessage, C as CoreMessage, q as CoreSystemMessage, U as CoreTool, t as CoreToolMessage, s as CoreUserMessage, a6 as DependencyCheckOutput, v as EmbedManyResult, u as EmbedResult, E as EvalRow, ac as ExtractSchemaFromStep, af as ExtractSchemaType, ad as ExtractStepResult, G as GenerateReturn, J as LLMInnerStreamOptions, K as LLMStreamObjectOptions, H as LLMStreamOptions, F as LLMTextObjectOptions, D as LLMTextOptions, L as LanguageModel, P as MemoryConfig, N as MessageResponse, c as MessageType, O as OutputType, ag as PathsToStringProps, a3 as ResolverFunctionInput, a4 as ResolverFunctionOutput, R as RetryConfig, Q as SharedMemoryConfig, f as StepAction, $ as StepCondition, j as StepConfig, _ as StepDef, e as StepExecutionContext, l as StepGraph, ab as StepId, ae as StepInputType, V as StepNode, h as StepResult, i as StepVariableType, S as StorageColumn, d as StorageGetMessagesArg, b as StorageThreadType, z as StreamReturn, y as StructuredOutput, x as StructuredOutputArrayItem, w as StructuredOutputType, a5 as SubscriberFunctionOutput, X as VariableReference, a8 as WorkflowActionParams, a9 as WorkflowActions, a7 as WorkflowActors, a0 as WorkflowContext, a2 as WorkflowEvent, a1 as WorkflowLogMessage, ah as WorkflowResumeResult, p as WorkflowRow, k as WorkflowRunState, aa as WorkflowState } from './base-nhesrHv3.cjs';
5
+ import { M as MastraBase$1 } from './base-hs9NDAZ2.cjs';
6
+ export { O as OtelConfig, S as SamplingStrategy, T as Telemetry } from './base-hs9NDAZ2.cjs';
7
+ import { R as RegisteredLogger, a as LogLevel, T as TransportMap, L as Logger } from './index-mKY1XrpK.cjs';
8
+ export { B as BaseLogMessage, b as LoggerTransport, M as MultiLogger, c as combineLoggers, n as noopLogger } from './index-mKY1XrpK.cjs';
9
+ import { MastraDeployer as MastraDeployer$1 } from './deployer/index.cjs';
10
+ export { evaluate } from './eval/index.cjs';
11
+ import { Integration as Integration$1, OpenAPIToolset as OpenAPIToolset$1 } from './integration/index.cjs';
12
+ export { Config, Mastra } from './mastra/index.cjs';
13
+ export { CohereRelevanceScorer, MastraAgentRelevanceScorer, RelevanceScoreProvider, createSimilarityPrompt } from './relevance/index.cjs';
14
+ export { InstrumentClass, OTLPStorageExporter, hasActiveTelemetry, withSpan } from './telemetry/index.cjs';
15
+ import { z } from 'zod';
16
+ import { Tool as Tool$1 } from './tools/index.cjs';
17
+ export { createTool } from './tools/index.cjs';
18
+ import { MastraTTS as MastraTTS$1, TTSConfig } from './tts/index.cjs';
19
+ export { TagMaskOptions, deepMerge, delay, jsonSchemaPropertiesToTSTypes, jsonSchemaToModel, maskStreamTags } from './utils.cjs';
20
+ import { MastraVector as MastraVector$1 } from './vector/index.cjs';
21
+ export { IndexStats, QueryResult } from './vector/index.cjs';
22
+ import { S as Step, W as Workflow$1 } from './workflow-DqQ4pON_.cjs';
23
+ export { c as createStep } from './workflow-DqQ4pON_.cjs';
24
+ export { getActivePathsAndStatus, getStepResult, getSuspendedPaths, isErrorEvent, isFinalState, isTransitionEvent, isVariableReference, mergeChildValue, recursivelyCheckForFinalState, updateStepInHierarchy } from './workflows/index.cjs';
25
+ export { AvailableHooks, executeHook, registerHook } from './hooks/index.cjs';
26
+ export { ArrayOperator, BaseFilterTranslator, BasicOperator, ElementOperator, FieldCondition, Filter, LogicalOperator, NumericOperator, OperatorCondition, OperatorSupport, QueryOperator, RegexOperator } from './filter/index.cjs';
27
+ export { Message as AiMessageType } from 'ai';
28
+ import 'sift';
29
+ import 'json-schema';
30
+ import './voice/index.cjs';
31
+ import '@opentelemetry/api';
32
+ import '@opentelemetry/sdk-trace-base';
33
+ import 'stream';
34
+ import 'pino';
35
+ import './bundler/index.cjs';
36
+ import '@opentelemetry/core';
37
+
38
+ declare class Agent<TTools extends Record<string, ToolAction<any, any, any, any>> = Record<string, ToolAction<any, any, any, any>>, TMetrics extends Record<string, Metric> = Record<string, Metric>> extends Agent$1<TTools, TMetrics> {
39
+ constructor(config: AgentConfig<TTools, TMetrics>);
40
+ }
41
+
42
+ declare class MastraBase extends MastraBase$1 {
43
+ constructor(args: {
44
+ component?: RegisteredLogger;
45
+ name?: string;
46
+ });
47
+ }
48
+
49
+ declare abstract class MastraDeployer extends MastraDeployer$1 {
50
+ constructor(args: {
51
+ name: string;
52
+ mastraDir: string;
53
+ outputDirectory: string;
54
+ });
55
+ }
56
+
57
+ declare abstract class MastraStorage extends MastraStorage$1 {
58
+ constructor({ name }: {
59
+ name: string;
60
+ });
61
+ }
62
+
63
+ declare class Integration<ToolsParams = void, ApiClient = void> extends Integration$1<ToolsParams, ApiClient> {
64
+ constructor();
65
+ }
66
+
67
+ declare abstract class OpenAPIToolset extends OpenAPIToolset$1 {
68
+ constructor();
69
+ }
70
+
71
+ declare function createLogger(options: {
72
+ name?: string;
73
+ level?: LogLevel;
74
+ transports?: TransportMap;
75
+ }): Logger;
76
+
77
+ declare abstract class MastraMemory extends MastraMemory$1 {
78
+ constructor(_arg?: any);
79
+ }
80
+
81
+ declare class Tool<TId extends string, TSchemaIn extends z.ZodSchema | undefined = undefined, TSchemaOut extends z.ZodSchema | undefined = undefined, TContext extends ToolExecutionContext<TSchemaIn> = ToolExecutionContext<TSchemaIn>> extends Tool$1<TId, TSchemaIn, TSchemaOut, TContext> {
82
+ constructor(opts: ToolAction<TId, TSchemaIn, TSchemaOut, TContext>);
83
+ }
84
+
85
+ declare abstract class MastraTTS extends MastraTTS$1 {
86
+ constructor(args: TTSConfig);
87
+ }
88
+
89
+ declare abstract class MastraVector extends MastraVector$1 {
90
+ constructor();
91
+ }
92
+
93
+ declare class Workflow<TSteps extends Step<any, any, any>[] = any, TTriggerSchema extends z.ZodType<any> = any> extends Workflow$1<TSteps, TTriggerSchema> {
94
+ constructor(args: WorkflowOptions<TTriggerSchema>);
95
+ }
96
+
97
+ export { Agent, Integration, LogLevel, Logger, MastraBase, MastraDeployer, MastraMemory, MastraStorage, MastraTTS, MastraVector, Metric, OpenAPIToolset, RegisteredLogger, Step, TTSConfig, Tool, ToolAction, ToolExecutionContext, TransportMap, Workflow, WorkflowOptions, createLogger };
@@ -0,0 +1,97 @@
1
+ import { a as Metric } from './types-m9RryK9a.js';
2
+ export { M as MetricResult, T as TestInfo } from './types-m9RryK9a.js';
3
+ import { m as ToolAction, A as Agent$1, n as AgentConfig, M as MastraStorage$1, a as MastraMemory$1, o as ToolExecutionContext, W as WorkflowOptions } from './base-nKCMCNrM.js';
4
+ export { Z as ActionContext, Y as BaseCondition, B as BaseStructuredOutputType, r as CoreAssistantMessage, C as CoreMessage, q as CoreSystemMessage, U as CoreTool, t as CoreToolMessage, s as CoreUserMessage, a6 as DependencyCheckOutput, v as EmbedManyResult, u as EmbedResult, E as EvalRow, ac as ExtractSchemaFromStep, af as ExtractSchemaType, ad as ExtractStepResult, G as GenerateReturn, J as LLMInnerStreamOptions, K as LLMStreamObjectOptions, H as LLMStreamOptions, F as LLMTextObjectOptions, D as LLMTextOptions, L as LanguageModel, P as MemoryConfig, N as MessageResponse, c as MessageType, O as OutputType, ag as PathsToStringProps, a3 as ResolverFunctionInput, a4 as ResolverFunctionOutput, R as RetryConfig, Q as SharedMemoryConfig, f as StepAction, $ as StepCondition, j as StepConfig, _ as StepDef, e as StepExecutionContext, l as StepGraph, ab as StepId, ae as StepInputType, V as StepNode, h as StepResult, i as StepVariableType, S as StorageColumn, d as StorageGetMessagesArg, b as StorageThreadType, z as StreamReturn, y as StructuredOutput, x as StructuredOutputArrayItem, w as StructuredOutputType, a5 as SubscriberFunctionOutput, X as VariableReference, a8 as WorkflowActionParams, a9 as WorkflowActions, a7 as WorkflowActors, a0 as WorkflowContext, a2 as WorkflowEvent, a1 as WorkflowLogMessage, ah as WorkflowResumeResult, p as WorkflowRow, k as WorkflowRunState, aa as WorkflowState } from './base-nKCMCNrM.js';
5
+ import { M as MastraBase$1 } from './base-D90KQ4XI.js';
6
+ export { O as OtelConfig, S as SamplingStrategy, T as Telemetry } from './base-D90KQ4XI.js';
7
+ import { R as RegisteredLogger, a as LogLevel, T as TransportMap, L as Logger } from './index-mKY1XrpK.js';
8
+ export { B as BaseLogMessage, b as LoggerTransport, M as MultiLogger, c as combineLoggers, n as noopLogger } from './index-mKY1XrpK.js';
9
+ import { MastraDeployer as MastraDeployer$1 } from './deployer/index.js';
10
+ export { evaluate } from './eval/index.js';
11
+ import { Integration as Integration$1, OpenAPIToolset as OpenAPIToolset$1 } from './integration/index.js';
12
+ export { Config, Mastra } from './mastra/index.js';
13
+ export { CohereRelevanceScorer, MastraAgentRelevanceScorer, RelevanceScoreProvider, createSimilarityPrompt } from './relevance/index.js';
14
+ export { InstrumentClass, OTLPStorageExporter, hasActiveTelemetry, withSpan } from './telemetry/index.js';
15
+ import { z } from 'zod';
16
+ import { Tool as Tool$1 } from './tools/index.js';
17
+ export { createTool } from './tools/index.js';
18
+ import { MastraTTS as MastraTTS$1, TTSConfig } from './tts/index.js';
19
+ export { TagMaskOptions, deepMerge, delay, jsonSchemaPropertiesToTSTypes, jsonSchemaToModel, maskStreamTags } from './utils.js';
20
+ import { MastraVector as MastraVector$1 } from './vector/index.js';
21
+ export { IndexStats, QueryResult } from './vector/index.js';
22
+ import { S as Step, W as Workflow$1 } from './workflow-Ng_F_Zaf.js';
23
+ export { c as createStep } from './workflow-Ng_F_Zaf.js';
24
+ export { getActivePathsAndStatus, getStepResult, getSuspendedPaths, isErrorEvent, isFinalState, isTransitionEvent, isVariableReference, mergeChildValue, recursivelyCheckForFinalState, updateStepInHierarchy } from './workflows/index.js';
25
+ export { AvailableHooks, executeHook, registerHook } from './hooks/index.js';
26
+ export { ArrayOperator, BaseFilterTranslator, BasicOperator, ElementOperator, FieldCondition, Filter, LogicalOperator, NumericOperator, OperatorCondition, OperatorSupport, QueryOperator, RegexOperator } from './filter/index.js';
27
+ export { Message as AiMessageType } from 'ai';
28
+ import 'sift';
29
+ import 'json-schema';
30
+ import './voice/index.js';
31
+ import '@opentelemetry/api';
32
+ import '@opentelemetry/sdk-trace-base';
33
+ import 'stream';
34
+ import 'pino';
35
+ import './bundler/index.js';
36
+ import '@opentelemetry/core';
37
+
38
+ declare class Agent<TTools extends Record<string, ToolAction<any, any, any, any>> = Record<string, ToolAction<any, any, any, any>>, TMetrics extends Record<string, Metric> = Record<string, Metric>> extends Agent$1<TTools, TMetrics> {
39
+ constructor(config: AgentConfig<TTools, TMetrics>);
40
+ }
41
+
42
+ declare class MastraBase extends MastraBase$1 {
43
+ constructor(args: {
44
+ component?: RegisteredLogger;
45
+ name?: string;
46
+ });
47
+ }
48
+
49
+ declare abstract class MastraDeployer extends MastraDeployer$1 {
50
+ constructor(args: {
51
+ name: string;
52
+ mastraDir: string;
53
+ outputDirectory: string;
54
+ });
55
+ }
56
+
57
+ declare abstract class MastraStorage extends MastraStorage$1 {
58
+ constructor({ name }: {
59
+ name: string;
60
+ });
61
+ }
62
+
63
+ declare class Integration<ToolsParams = void, ApiClient = void> extends Integration$1<ToolsParams, ApiClient> {
64
+ constructor();
65
+ }
66
+
67
+ declare abstract class OpenAPIToolset extends OpenAPIToolset$1 {
68
+ constructor();
69
+ }
70
+
71
+ declare function createLogger(options: {
72
+ name?: string;
73
+ level?: LogLevel;
74
+ transports?: TransportMap;
75
+ }): Logger;
76
+
77
+ declare abstract class MastraMemory extends MastraMemory$1 {
78
+ constructor(_arg?: any);
79
+ }
80
+
81
+ declare class Tool<TId extends string, TSchemaIn extends z.ZodSchema | undefined = undefined, TSchemaOut extends z.ZodSchema | undefined = undefined, TContext extends ToolExecutionContext<TSchemaIn> = ToolExecutionContext<TSchemaIn>> extends Tool$1<TId, TSchemaIn, TSchemaOut, TContext> {
82
+ constructor(opts: ToolAction<TId, TSchemaIn, TSchemaOut, TContext>);
83
+ }
84
+
85
+ declare abstract class MastraTTS extends MastraTTS$1 {
86
+ constructor(args: TTSConfig);
87
+ }
88
+
89
+ declare abstract class MastraVector extends MastraVector$1 {
90
+ constructor();
91
+ }
92
+
93
+ declare class Workflow<TSteps extends Step<any, any, any>[] = any, TTriggerSchema extends z.ZodType<any> = any> extends Workflow$1<TSteps, TTriggerSchema> {
94
+ constructor(args: WorkflowOptions<TTriggerSchema>);
95
+ }
96
+
97
+ export { Agent, Integration, LogLevel, Logger, MastraBase, MastraDeployer, MastraMemory, MastraStorage, MastraTTS, MastraVector, Metric, OpenAPIToolset, RegisteredLogger, Step, TTSConfig, Tool, ToolAction, ToolExecutionContext, TransportMap, Workflow, WorkflowOptions, createLogger };
package/dist/index.js ADDED
@@ -0,0 +1,119 @@
1
+ import { MastraTTS } from './chunk-QAAJAHDB.js';
2
+ import { Workflow } from './chunk-B3M27AMP.js';
3
+ export { Step, createStep, getActivePathsAndStatus, getStepResult, getSuspendedPaths, isErrorEvent, isFinalState, isTransitionEvent, isVariableReference, mergeChildValue, recursivelyCheckForFinalState, updateStepInHierarchy } from './chunk-B3M27AMP.js';
4
+ import { Integration, OpenAPIToolset } from './chunk-PNZK456O.js';
5
+ import { Tool } from './chunk-ZINPRHAN.js';
6
+ export { createTool } from './chunk-ZINPRHAN.js';
7
+ export { Mastra } from './chunk-NGD2HQYW.js';
8
+ import { MastraMemory } from './chunk-HQ55LN2U.js';
9
+ import { MastraVector } from './chunk-55NFNRKO.js';
10
+ export { CohereRelevanceScorer, MastraAgentRelevanceScorer, createSimilarityPrompt } from './chunk-LH47WVJL.js';
11
+ import { MastraStorage } from './chunk-5XPCMNGW.js';
12
+ import { Agent } from './chunk-SY5244IR.js';
13
+ export { InstrumentClass, OTLPTraceExporter as OTLPStorageExporter, Telemetry, hasActiveTelemetry, withSpan } from './chunk-W5HVJX45.js';
14
+ export { deepMerge, delay, jsonSchemaPropertiesToTSTypes, jsonSchemaToModel, maskStreamTags } from './chunk-WIBGG4X6.js';
15
+ import { MastraDeployer } from './chunk-4YRYBCOZ.js';
16
+ import { MastraBase } from './chunk-OZ4XVJ6F.js';
17
+ import { createLogger } from './chunk-PHMSPCTC.js';
18
+ export { LogLevel, Logger, LoggerTransport, MultiLogger, RegisteredLogger, combineLoggers, noopLogger } from './chunk-PHMSPCTC.js';
19
+ export { BaseFilterTranslator } from './chunk-SIFBBGY6.js';
20
+ export { Metric, evaluate } from './chunk-NUDAZEOG.js';
21
+ export { AvailableHooks, executeHook, registerHook } from './chunk-BB4KXGBU.js';
22
+
23
+ // src/agent/index.warning.ts
24
+ var Agent2 = class extends Agent {
25
+ constructor(config) {
26
+ super(config);
27
+ this.logger.warn('Please import "Agent from "@mastra/core/agent" instead of "@mastra/core"');
28
+ }
29
+ };
30
+
31
+ // src/base.warning.ts
32
+ var MastraBase2 = class extends MastraBase {
33
+ constructor(args) {
34
+ super(args);
35
+ this.logger.warn('Please import "MastraBase" from "@mastra/core/base" instead of "@mastra/core"');
36
+ }
37
+ };
38
+
39
+ // src/deployer/index.warning.ts
40
+ var MastraDeployer2 = class extends MastraDeployer {
41
+ constructor(args) {
42
+ super(args);
43
+ this.logger.warn('Please import "MastraDeployer" from "@mastra/core/deployer" instead of "@mastra/core"');
44
+ }
45
+ };
46
+
47
+ // src/storage/base.warning.ts
48
+ var MastraStorage2 = class extends MastraStorage {
49
+ constructor({ name }) {
50
+ super({
51
+ name
52
+ });
53
+ this.logger.warn('Please import "MastraStorage" from "@mastra/core/storage" instead of "@mastra/core"');
54
+ }
55
+ };
56
+
57
+ // src/integration/integration.warning.ts
58
+ var Integration2 = class extends Integration {
59
+ constructor() {
60
+ super();
61
+ console.warn('Please import "Integration" from "@mastra/core/integration" instead of "@mastra/core"');
62
+ }
63
+ };
64
+
65
+ // src/integration/openapi-toolset.warning.ts
66
+ var OpenAPIToolset2 = class extends OpenAPIToolset {
67
+ constructor() {
68
+ super();
69
+ console.warn('Please import "OpenAPIToolset" from "@mastra/core/integration" instead of "@mastra/core"');
70
+ }
71
+ };
72
+
73
+ // src/logger/index.warning.ts
74
+ function createLogger2(options) {
75
+ console.warn('Please import "createLogger" from "@mastra/core/logger" instead of "@mastra/core"');
76
+ return createLogger(options);
77
+ }
78
+
79
+ // src/memory/index.warning.ts
80
+ var MastraMemory2 = class extends MastraMemory {
81
+ constructor(_arg) {
82
+ super({ name: `Deprecated memory` });
83
+ this.logger.warn('Please import "MastraMemory" from "@mastra/core/memory" instead of "@mastra/core"');
84
+ }
85
+ };
86
+
87
+ // src/tools/index.warning.ts
88
+ var Tool2 = class extends Tool {
89
+ constructor(opts) {
90
+ super(opts);
91
+ console.warn('Please import "Tool" from "@mastra/core/tools" instead of "@mastra/core"');
92
+ }
93
+ };
94
+
95
+ // src/tts/index.warning.ts
96
+ var MastraTTS2 = class extends MastraTTS {
97
+ constructor(args) {
98
+ super(args);
99
+ this.logger.warn('Please import "MastraTTS" from "@mastra/core/tts" instead of "@mastra/core"');
100
+ }
101
+ };
102
+
103
+ // src/vector/index.warning.ts
104
+ var MastraVector2 = class extends MastraVector {
105
+ constructor() {
106
+ super();
107
+ this.logger.warn('Please import "MastraVector" from "@mastra/core/vector" instead of "@mastra/core"');
108
+ }
109
+ };
110
+
111
+ // src/workflows/workflow.warning.ts
112
+ var Workflow2 = class extends Workflow {
113
+ constructor(args) {
114
+ super(args);
115
+ this.logger.warn('Please import "Workflow" from "@mastra/core/workflows" instead of "@mastra/core"');
116
+ }
117
+ };
118
+
119
+ export { Agent2 as Agent, Integration2 as Integration, MastraBase2 as MastraBase, MastraDeployer2 as MastraDeployer, MastraMemory2 as MastraMemory, MastraStorage2 as MastraStorage, MastraTTS2 as MastraTTS, MastraVector2 as MastraVector, OpenAPIToolset2 as OpenAPIToolset, Tool2 as Tool, Workflow2 as Workflow, createLogger2 as createLogger };
@@ -0,0 +1,113 @@
1
+ 'use strict';
2
+
3
+ var zod = require('zod');
4
+
5
+ // src/integration/integration.ts
6
+ var Integration = class {
7
+ name = "Integration";
8
+ workflows;
9
+ constructor() {
10
+ this.workflows = {};
11
+ }
12
+ /**
13
+ * Workflows
14
+ */
15
+ registerWorkflow(name, fn) {
16
+ if (this.workflows[name]) {
17
+ throw new Error(`Sync function "${name}" already registered`);
18
+ }
19
+ this.workflows[name] = fn;
20
+ }
21
+ getWorkflows({ serialized }) {
22
+ if (serialized) {
23
+ return Object.entries(this.workflows).reduce((acc, [k, v]) => {
24
+ return {
25
+ ...acc,
26
+ [k]: {
27
+ name: v.name
28
+ }
29
+ };
30
+ }, {});
31
+ }
32
+ return this.workflows;
33
+ }
34
+ /**
35
+ * TOOLS
36
+ */
37
+ getStaticTools(_params) {
38
+ throw new Error("Method not implemented.");
39
+ }
40
+ async getTools(_params) {
41
+ throw new Error("Method not implemented.");
42
+ }
43
+ async getApiClient() {
44
+ throw new Error("Method not implemented");
45
+ }
46
+ };
47
+
48
+ // src/tools/tool.ts
49
+ var Tool = class {
50
+ id;
51
+ description;
52
+ inputSchema;
53
+ outputSchema;
54
+ execute;
55
+ mastra;
56
+ constructor(opts) {
57
+ this.id = opts.id;
58
+ this.description = opts.description;
59
+ this.inputSchema = opts.inputSchema;
60
+ this.outputSchema = opts.outputSchema;
61
+ this.execute = opts.execute;
62
+ this.mastra = opts.mastra;
63
+ }
64
+ };
65
+ function createTool(opts) {
66
+ return new Tool(opts);
67
+ }
68
+
69
+ // src/integration/openapi-toolset.ts
70
+ var OpenAPIToolset = class {
71
+ authType = "API_KEY";
72
+ constructor() {
73
+ }
74
+ get toolSchemas() {
75
+ return {};
76
+ }
77
+ get toolDocumentations() {
78
+ return {};
79
+ }
80
+ get baseClient() {
81
+ return {};
82
+ }
83
+ async getApiClient() {
84
+ throw new Error("API not implemented");
85
+ }
86
+ _generateIntegrationTools() {
87
+ const { client, ...clientMethods } = this.baseClient;
88
+ const schemas = this.toolSchemas;
89
+ const documentations = this.toolDocumentations;
90
+ const tools = Object.keys(clientMethods).reduce((acc, key) => {
91
+ const comment = documentations[key]?.comment;
92
+ const fallbackComment = `Execute ${key}`;
93
+ const tool = createTool({
94
+ id: key,
95
+ inputSchema: schemas[key] || zod.z.object({}),
96
+ description: comment || fallbackComment,
97
+ // documentation: doc || fallbackComment,
98
+ execute: async ({ context }) => {
99
+ const client2 = await this.getApiClient();
100
+ const value = client2[key];
101
+ return value({
102
+ ...context
103
+ });
104
+ }
105
+ });
106
+ return { ...acc, [key]: tool };
107
+ }, {});
108
+ return tools;
109
+ }
110
+ };
111
+
112
+ exports.Integration = Integration;
113
+ exports.OpenAPIToolset = OpenAPIToolset;
@@ -0,0 +1,52 @@
1
+ import { W as Workflow } from '../workflow-DqQ4pON_.cjs';
2
+ import '../base-hs9NDAZ2.cjs';
3
+ import { m as ToolAction } from '../base-nhesrHv3.cjs';
4
+ import '@opentelemetry/api';
5
+ import 'zod';
6
+ import '../index-mKY1XrpK.cjs';
7
+ import 'stream';
8
+ import 'pino';
9
+ import '@opentelemetry/sdk-trace-base';
10
+ import 'ai';
11
+ import 'sift';
12
+ import 'json-schema';
13
+ import '../types-m9RryK9a.cjs';
14
+ import '../vector/index.cjs';
15
+ import '../voice/index.cjs';
16
+ import '../tts/index.cjs';
17
+
18
+ declare class Integration<ToolsParams = void, ApiClient = void> {
19
+ name: string;
20
+ private workflows;
21
+ constructor();
22
+ /**
23
+ * Workflows
24
+ */
25
+ registerWorkflow(name: string, fn: Workflow): void;
26
+ getWorkflows({ serialized }: {
27
+ serialized?: boolean;
28
+ }): Record<string, Workflow>;
29
+ /**
30
+ * TOOLS
31
+ */
32
+ getStaticTools(_params?: ToolsParams): Record<string, ToolAction<any, any, any, any>>;
33
+ getTools(_params?: ToolsParams): Promise<Record<string, ToolAction<any, any, any, any>>>;
34
+ getApiClient(): Promise<ApiClient>;
35
+ }
36
+
37
+ declare abstract class OpenAPIToolset {
38
+ abstract readonly name: string;
39
+ abstract readonly tools: Record<string, ToolAction<any, any, any, any>>;
40
+ authType: string;
41
+ constructor();
42
+ protected get toolSchemas(): any;
43
+ protected get toolDocumentations(): Record<string, {
44
+ comment: string;
45
+ doc?: string;
46
+ }>;
47
+ protected get baseClient(): any;
48
+ getApiClient(): Promise<any>;
49
+ protected _generateIntegrationTools<T>(): T;
50
+ }
51
+
52
+ export { Integration, OpenAPIToolset };
@@ -0,0 +1,52 @@
1
+ import { W as Workflow } from '../workflow-Ng_F_Zaf.js';
2
+ import '../base-D90KQ4XI.js';
3
+ import { m as ToolAction } from '../base-nKCMCNrM.js';
4
+ import '@opentelemetry/api';
5
+ import 'zod';
6
+ import '../index-mKY1XrpK.js';
7
+ import 'stream';
8
+ import 'pino';
9
+ import '@opentelemetry/sdk-trace-base';
10
+ import 'ai';
11
+ import 'sift';
12
+ import 'json-schema';
13
+ import '../types-m9RryK9a.js';
14
+ import '../vector/index.js';
15
+ import '../voice/index.js';
16
+ import '../tts/index.js';
17
+
18
+ declare class Integration<ToolsParams = void, ApiClient = void> {
19
+ name: string;
20
+ private workflows;
21
+ constructor();
22
+ /**
23
+ * Workflows
24
+ */
25
+ registerWorkflow(name: string, fn: Workflow): void;
26
+ getWorkflows({ serialized }: {
27
+ serialized?: boolean;
28
+ }): Record<string, Workflow>;
29
+ /**
30
+ * TOOLS
31
+ */
32
+ getStaticTools(_params?: ToolsParams): Record<string, ToolAction<any, any, any, any>>;
33
+ getTools(_params?: ToolsParams): Promise<Record<string, ToolAction<any, any, any, any>>>;
34
+ getApiClient(): Promise<ApiClient>;
35
+ }
36
+
37
+ declare abstract class OpenAPIToolset {
38
+ abstract readonly name: string;
39
+ abstract readonly tools: Record<string, ToolAction<any, any, any, any>>;
40
+ authType: string;
41
+ constructor();
42
+ protected get toolSchemas(): any;
43
+ protected get toolDocumentations(): Record<string, {
44
+ comment: string;
45
+ doc?: string;
46
+ }>;
47
+ protected get baseClient(): any;
48
+ getApiClient(): Promise<any>;
49
+ protected _generateIntegrationTools<T>(): T;
50
+ }
51
+
52
+ export { Integration, OpenAPIToolset };
@@ -0,0 +1 @@
1
+ export { Integration, OpenAPIToolset } from '../chunk-PNZK456O.js';
@@ -0,0 +1,2 @@
1
+ 'use strict';
2
+
@@ -0,0 +1,15 @@
1
+ import 'ai';
2
+ import 'json-schema';
3
+ import 'zod';
4
+ export { B as BaseStructuredOutputType, r as CoreAssistantMessage, C as CoreMessage, q as CoreSystemMessage, t as CoreToolMessage, s as CoreUserMessage, v as EmbedManyResult, u as EmbedResult, G as GenerateReturn, J as LLMInnerStreamOptions, K as LLMStreamObjectOptions, H as LLMStreamOptions, F as LLMTextObjectOptions, D as LLMTextOptions, L as LanguageModel, O as OutputType, z as StreamReturn, y as StructuredOutput, x as StructuredOutputArrayItem, w as StructuredOutputType } from '../base-nhesrHv3.cjs';
5
+ import '../index-mKY1XrpK.cjs';
6
+ import '../base-hs9NDAZ2.cjs';
7
+ import '@opentelemetry/api';
8
+ import '@opentelemetry/sdk-trace-base';
9
+ import 'sift';
10
+ import '../types-m9RryK9a.cjs';
11
+ import '../vector/index.cjs';
12
+ import 'stream';
13
+ import 'pino';
14
+ import '../voice/index.cjs';
15
+ import '../tts/index.cjs';
@@ -0,0 +1,15 @@
1
+ import 'ai';
2
+ import 'json-schema';
3
+ import 'zod';
4
+ export { B as BaseStructuredOutputType, r as CoreAssistantMessage, C as CoreMessage, q as CoreSystemMessage, t as CoreToolMessage, s as CoreUserMessage, v as EmbedManyResult, u as EmbedResult, G as GenerateReturn, J as LLMInnerStreamOptions, K as LLMStreamObjectOptions, H as LLMStreamOptions, F as LLMTextObjectOptions, D as LLMTextOptions, L as LanguageModel, O as OutputType, z as StreamReturn, y as StructuredOutput, x as StructuredOutputArrayItem, w as StructuredOutputType } from '../base-nKCMCNrM.js';
5
+ import '../index-mKY1XrpK.js';
6
+ import '../base-D90KQ4XI.js';
7
+ import '@opentelemetry/api';
8
+ import '@opentelemetry/sdk-trace-base';
9
+ import 'sift';
10
+ import '../types-m9RryK9a.js';
11
+ import '../vector/index.js';
12
+ import 'stream';
13
+ import 'pino';
14
+ import '../voice/index.js';
15
+ import '../tts/index.js';
@@ -0,0 +1 @@
1
+