@voltagent/core 2.1.2 → 2.1.4
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/dist/index.d.mts +189 -25
- package/dist/index.d.ts +189 -25
- package/dist/index.js +1823 -755
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +1810 -744
- package/dist/index.mjs.map +1 -1
- package/package.json +2 -2
package/dist/index.d.mts
CHANGED
|
@@ -3276,6 +3276,22 @@ declare class VoltAgentError extends Error {
|
|
|
3276
3276
|
constructor(message: string, options?: VoltAgentErrorOptions);
|
|
3277
3277
|
}
|
|
3278
3278
|
|
|
3279
|
+
type MiddlewareAbortOptions<TMetadata = unknown> = {
|
|
3280
|
+
retry?: boolean;
|
|
3281
|
+
metadata?: TMetadata;
|
|
3282
|
+
};
|
|
3283
|
+
/**
|
|
3284
|
+
* Error thrown by middleware abort() calls.
|
|
3285
|
+
*/
|
|
3286
|
+
declare class MiddlewareAbortError<TMetadata = unknown> extends Error {
|
|
3287
|
+
name: "MiddlewareAbortError";
|
|
3288
|
+
retry?: boolean;
|
|
3289
|
+
metadata?: TMetadata;
|
|
3290
|
+
middlewareId?: string;
|
|
3291
|
+
constructor(reason: string, options?: MiddlewareAbortOptions<TMetadata>, middlewareId?: string);
|
|
3292
|
+
}
|
|
3293
|
+
declare function isMiddlewareAbortError(error: unknown): error is MiddlewareAbortError;
|
|
3294
|
+
|
|
3279
3295
|
type CancellationError = AbortError | ClientHTTPError;
|
|
3280
3296
|
|
|
3281
3297
|
/**
|
|
@@ -6855,6 +6871,47 @@ interface OnStepFinishHookArgs {
|
|
|
6855
6871
|
step: any;
|
|
6856
6872
|
context: OperationContext;
|
|
6857
6873
|
}
|
|
6874
|
+
type RetrySource = "llm" | "middleware";
|
|
6875
|
+
interface OnRetryHookArgsBase {
|
|
6876
|
+
agent: Agent;
|
|
6877
|
+
context: OperationContext;
|
|
6878
|
+
operation: AgentEvalOperationType;
|
|
6879
|
+
source: RetrySource;
|
|
6880
|
+
}
|
|
6881
|
+
interface OnRetryLLMHookArgs extends OnRetryHookArgsBase {
|
|
6882
|
+
source: "llm";
|
|
6883
|
+
modelName: string;
|
|
6884
|
+
modelIndex: number;
|
|
6885
|
+
attempt: number;
|
|
6886
|
+
nextAttempt: number;
|
|
6887
|
+
maxRetries: number;
|
|
6888
|
+
error: unknown;
|
|
6889
|
+
isRetryable?: boolean;
|
|
6890
|
+
statusCode?: number;
|
|
6891
|
+
}
|
|
6892
|
+
interface OnRetryMiddlewareHookArgs extends OnRetryHookArgsBase {
|
|
6893
|
+
source: "middleware";
|
|
6894
|
+
middlewareId?: string | null;
|
|
6895
|
+
retryCount: number;
|
|
6896
|
+
maxRetries: number;
|
|
6897
|
+
reason?: string;
|
|
6898
|
+
metadata?: unknown;
|
|
6899
|
+
}
|
|
6900
|
+
type OnRetryHookArgs = OnRetryLLMHookArgs | OnRetryMiddlewareHookArgs;
|
|
6901
|
+
type FallbackStage = "resolve" | "execute";
|
|
6902
|
+
interface OnFallbackHookArgs {
|
|
6903
|
+
agent: Agent;
|
|
6904
|
+
context: OperationContext;
|
|
6905
|
+
operation: AgentEvalOperationType;
|
|
6906
|
+
stage: FallbackStage;
|
|
6907
|
+
fromModel: string;
|
|
6908
|
+
fromModelIndex: number;
|
|
6909
|
+
maxRetries: number;
|
|
6910
|
+
attempt?: number;
|
|
6911
|
+
error: unknown;
|
|
6912
|
+
nextModel?: string | null;
|
|
6913
|
+
nextModelIndex?: number;
|
|
6914
|
+
}
|
|
6858
6915
|
type AgentHookOnStart = (args: OnStartHookArgs) => Promise<void> | void;
|
|
6859
6916
|
type AgentHookOnEnd = (args: OnEndHookArgs) => Promise<void> | void;
|
|
6860
6917
|
type AgentHookOnHandoff = (args: OnHandoffHookArgs) => Promise<void> | void;
|
|
@@ -6865,6 +6922,8 @@ type AgentHookOnPrepareMessages = (args: OnPrepareMessagesHookArgs) => Promise<O
|
|
|
6865
6922
|
type AgentHookOnPrepareModelMessages = (args: OnPrepareModelMessagesHookArgs) => Promise<OnPrepareModelMessagesHookResult> | OnPrepareModelMessagesHookResult;
|
|
6866
6923
|
type AgentHookOnError = (args: OnErrorHookArgs) => Promise<void> | void;
|
|
6867
6924
|
type AgentHookOnStepFinish = (args: OnStepFinishHookArgs) => Promise<void> | void;
|
|
6925
|
+
type AgentHookOnRetry = (args: OnRetryHookArgs) => Promise<void> | void;
|
|
6926
|
+
type AgentHookOnFallback = (args: OnFallbackHookArgs) => Promise<void> | void;
|
|
6868
6927
|
/**
|
|
6869
6928
|
* Type definition for agent hooks using single argument objects.
|
|
6870
6929
|
*/
|
|
@@ -6879,6 +6938,8 @@ type AgentHooks = {
|
|
|
6879
6938
|
onPrepareModelMessages?: AgentHookOnPrepareModelMessages;
|
|
6880
6939
|
onError?: AgentHookOnError;
|
|
6881
6940
|
onStepFinish?: AgentHookOnStepFinish;
|
|
6941
|
+
onRetry?: AgentHookOnRetry;
|
|
6942
|
+
onFallback?: AgentHookOnFallback;
|
|
6882
6943
|
};
|
|
6883
6944
|
/**
|
|
6884
6945
|
* Create hooks from an object literal.
|
|
@@ -6914,7 +6975,7 @@ declare class AgentTraceContext {
|
|
|
6914
6975
|
/**
|
|
6915
6976
|
* Create a child span with automatic parent context and attribute inheritance
|
|
6916
6977
|
*/
|
|
6917
|
-
createChildSpan(name: string, type: "tool" | "memory" | "retriever" | "embedding" | "vector" | "agent" | "guardrail" | "llm" | "summary", options?: {
|
|
6978
|
+
createChildSpan(name: string, type: "tool" | "memory" | "retriever" | "embedding" | "vector" | "agent" | "guardrail" | "middleware" | "llm" | "summary", options?: {
|
|
6918
6979
|
label?: string;
|
|
6919
6980
|
attributes?: Record<string, any>;
|
|
6920
6981
|
kind?: SpanKind$1;
|
|
@@ -6922,7 +6983,7 @@ declare class AgentTraceContext {
|
|
|
6922
6983
|
/**
|
|
6923
6984
|
* Create a child span with a specific parent span
|
|
6924
6985
|
*/
|
|
6925
|
-
createChildSpanWithParent(parentSpan: Span, name: string, type: "tool" | "memory" | "retriever" | "embedding" | "vector" | "agent" | "guardrail" | "llm" | "summary", options?: {
|
|
6986
|
+
createChildSpanWithParent(parentSpan: Span, name: string, type: "tool" | "memory" | "retriever" | "embedding" | "vector" | "agent" | "guardrail" | "middleware" | "llm" | "summary", options?: {
|
|
6926
6987
|
label?: string;
|
|
6927
6988
|
attributes?: Record<string, any>;
|
|
6928
6989
|
kind?: SpanKind$1;
|
|
@@ -7113,9 +7174,32 @@ type ModelDynamicValue<T> = T | DynamicValue<T>;
|
|
|
7113
7174
|
*/
|
|
7114
7175
|
type AgentModelReference = LanguageModel | ModelRouterModelId;
|
|
7115
7176
|
/**
|
|
7116
|
-
*
|
|
7177
|
+
* Model fallback configuration for agents.
|
|
7117
7178
|
*/
|
|
7118
|
-
type
|
|
7179
|
+
type AgentModelConfig = {
|
|
7180
|
+
/**
|
|
7181
|
+
* Optional stable identifier for the model entry (useful for logging).
|
|
7182
|
+
*/
|
|
7183
|
+
id?: string;
|
|
7184
|
+
/**
|
|
7185
|
+
* Model reference (static or dynamic).
|
|
7186
|
+
*/
|
|
7187
|
+
model: ModelDynamicValue<AgentModelReference>;
|
|
7188
|
+
/**
|
|
7189
|
+
* Maximum number of retries for this model before falling back.
|
|
7190
|
+
* Defaults to the agent's maxRetries.
|
|
7191
|
+
*/
|
|
7192
|
+
maxRetries?: number;
|
|
7193
|
+
/**
|
|
7194
|
+
* Whether this model is enabled for fallback selection.
|
|
7195
|
+
* @default true
|
|
7196
|
+
*/
|
|
7197
|
+
enabled?: boolean;
|
|
7198
|
+
};
|
|
7199
|
+
/**
|
|
7200
|
+
* Agent model value that can be static, dynamic, or a fallback list.
|
|
7201
|
+
*/
|
|
7202
|
+
type AgentModelValue = ModelDynamicValue<AgentModelReference> | AgentModelConfig[];
|
|
7119
7203
|
/**
|
|
7120
7204
|
* Provider options type for LLM configurations
|
|
7121
7205
|
*/
|
|
@@ -7312,6 +7396,45 @@ interface OutputGuardrailDefinition<TOutput = unknown> extends GuardrailDefiniti
|
|
|
7312
7396
|
streamHandler?: OutputGuardrailStreamHandler;
|
|
7313
7397
|
}
|
|
7314
7398
|
type OutputGuardrail<TOutput = unknown> = OutputGuardrailFunction<TOutput> | OutputGuardrailDefinition<TOutput>;
|
|
7399
|
+
type MiddlewareDirection = "input" | "output";
|
|
7400
|
+
type MiddlewareFunctionMetadata = {
|
|
7401
|
+
middlewareId?: string;
|
|
7402
|
+
middlewareName?: string;
|
|
7403
|
+
middlewareDescription?: string;
|
|
7404
|
+
middlewareTags?: string[];
|
|
7405
|
+
};
|
|
7406
|
+
type MiddlewareFunction<TArgs, TResult> = ((args: TArgs) => TResult | Promise<TResult>) & MiddlewareFunctionMetadata;
|
|
7407
|
+
interface MiddlewareDefinition<TArgs, TResult> {
|
|
7408
|
+
id?: string;
|
|
7409
|
+
name?: string;
|
|
7410
|
+
description?: string;
|
|
7411
|
+
tags?: string[];
|
|
7412
|
+
metadata?: Record<string, unknown>;
|
|
7413
|
+
handler: MiddlewareFunction<TArgs, TResult>;
|
|
7414
|
+
}
|
|
7415
|
+
interface MiddlewareContext {
|
|
7416
|
+
agent: Agent;
|
|
7417
|
+
context: OperationContext;
|
|
7418
|
+
operation: AgentEvalOperationType;
|
|
7419
|
+
retryCount: number;
|
|
7420
|
+
}
|
|
7421
|
+
interface InputMiddlewareArgs extends MiddlewareContext {
|
|
7422
|
+
input: string | UIMessage[] | BaseMessage[];
|
|
7423
|
+
originalInput: string | UIMessage[] | BaseMessage[];
|
|
7424
|
+
abort: <TMetadata = unknown>(reason?: string, options?: MiddlewareAbortOptions<TMetadata>) => never;
|
|
7425
|
+
}
|
|
7426
|
+
type InputMiddlewareResult = string | UIMessage[] | BaseMessage[] | undefined;
|
|
7427
|
+
interface OutputMiddlewareArgs<TOutput = unknown> extends MiddlewareContext {
|
|
7428
|
+
output: TOutput;
|
|
7429
|
+
originalOutput: TOutput;
|
|
7430
|
+
usage?: UsageInfo;
|
|
7431
|
+
finishReason?: string | null;
|
|
7432
|
+
warnings?: unknown[] | null;
|
|
7433
|
+
abort: <TMetadata = unknown>(reason?: string, options?: MiddlewareAbortOptions<TMetadata>) => never;
|
|
7434
|
+
}
|
|
7435
|
+
type OutputMiddlewareResult<TOutput = unknown> = TOutput | undefined;
|
|
7436
|
+
type InputMiddleware = MiddlewareDefinition<InputMiddlewareArgs, InputMiddlewareResult> | MiddlewareFunction<InputMiddlewareArgs, InputMiddlewareResult>;
|
|
7437
|
+
type OutputMiddleware<TOutput = unknown> = MiddlewareDefinition<OutputMiddlewareArgs<TOutput>, OutputMiddlewareResult<TOutput>> | MiddlewareFunction<OutputMiddlewareArgs<TOutput>, OutputMiddlewareResult<TOutput>>;
|
|
7315
7438
|
type AgentSummarizationOptions = {
|
|
7316
7439
|
enabled?: boolean;
|
|
7317
7440
|
triggerTokens?: number;
|
|
@@ -7340,9 +7463,21 @@ type AgentOptions = {
|
|
|
7340
7463
|
hooks?: AgentHooks;
|
|
7341
7464
|
inputGuardrails?: InputGuardrail[];
|
|
7342
7465
|
outputGuardrails?: OutputGuardrail<any>[];
|
|
7466
|
+
inputMiddlewares?: InputMiddleware[];
|
|
7467
|
+
outputMiddlewares?: OutputMiddleware<any>[];
|
|
7468
|
+
/**
|
|
7469
|
+
* Default retry count for middleware-triggered retries.
|
|
7470
|
+
* Per-call maxMiddlewareRetries overrides this value.
|
|
7471
|
+
*/
|
|
7472
|
+
maxMiddlewareRetries?: number;
|
|
7343
7473
|
temperature?: number;
|
|
7344
7474
|
maxOutputTokens?: number;
|
|
7345
7475
|
maxSteps?: number;
|
|
7476
|
+
/**
|
|
7477
|
+
* Default retry count for model calls before falling back.
|
|
7478
|
+
* Overridden by per-model maxRetries or per-call maxRetries.
|
|
7479
|
+
*/
|
|
7480
|
+
maxRetries?: number;
|
|
7346
7481
|
feedback?: AgentFeedbackOptions | boolean;
|
|
7347
7482
|
/**
|
|
7348
7483
|
* Default stop condition for step execution (ai-sdk `stopWhen`).
|
|
@@ -7794,8 +7929,8 @@ declare class MemoryManager {
|
|
|
7794
7929
|
shutdown(): Promise<void>;
|
|
7795
7930
|
}
|
|
7796
7931
|
|
|
7797
|
-
type OutputSpec = Output.Output<unknown, unknown>;
|
|
7798
|
-
type OutputValue<OUTPUT extends OutputSpec> = InferGenerateOutput<OUTPUT>;
|
|
7932
|
+
type OutputSpec$1 = Output.Output<unknown, unknown>;
|
|
7933
|
+
type OutputValue<OUTPUT extends OutputSpec$1> = InferGenerateOutput<OUTPUT>;
|
|
7799
7934
|
/**
|
|
7800
7935
|
* Context input type that accepts both Map and plain object
|
|
7801
7936
|
*/
|
|
@@ -7842,7 +7977,7 @@ type BaseGenerateTextResult<TOOLS extends ToolSet = Record<string, any>> = Omit<
|
|
|
7842
7977
|
experimental_output: unknown;
|
|
7843
7978
|
output: unknown;
|
|
7844
7979
|
};
|
|
7845
|
-
interface GenerateTextResultWithContext<TOOLS extends ToolSet = Record<string, any>, OUTPUT extends OutputSpec = OutputSpec> extends BaseGenerateTextResult<TOOLS> {
|
|
7980
|
+
interface GenerateTextResultWithContext<TOOLS extends ToolSet = Record<string, any>, OUTPUT extends OutputSpec$1 = OutputSpec$1> extends BaseGenerateTextResult<TOOLS> {
|
|
7846
7981
|
context: Map<string | symbol, unknown>;
|
|
7847
7982
|
experimental_output: OutputValue<OUTPUT>;
|
|
7848
7983
|
output: OutputValue<OUTPUT>;
|
|
@@ -7886,8 +8021,11 @@ interface BaseGenerationOptions extends Partial<CallSettings> {
|
|
|
7886
8021
|
hooks?: AgentHooks;
|
|
7887
8022
|
inputGuardrails?: InputGuardrail[];
|
|
7888
8023
|
outputGuardrails?: OutputGuardrail<any>[];
|
|
8024
|
+
inputMiddlewares?: InputMiddleware[];
|
|
8025
|
+
outputMiddlewares?: OutputMiddleware<any>[];
|
|
8026
|
+
maxMiddlewareRetries?: number;
|
|
7889
8027
|
providerOptions?: ProviderOptions$1;
|
|
7890
|
-
output?: OutputSpec;
|
|
8028
|
+
output?: OutputSpec$1;
|
|
7891
8029
|
/**
|
|
7892
8030
|
* Optional explicit stop sequences to pass through to the underlying provider.
|
|
7893
8031
|
* Mirrors the `stop` option supported by ai-sdk `generateText/streamText`.
|
|
@@ -7898,7 +8036,7 @@ interface BaseGenerationOptions extends Partial<CallSettings> {
|
|
|
7898
8036
|
*/
|
|
7899
8037
|
toolChoice?: ToolChoice<Record<string, unknown>>;
|
|
7900
8038
|
}
|
|
7901
|
-
type GenerateTextOptions<OUTPUT extends OutputSpec = OutputSpec> = Omit<BaseGenerationOptions, "output"> & {
|
|
8039
|
+
type GenerateTextOptions<OUTPUT extends OutputSpec$1 = OutputSpec$1> = Omit<BaseGenerationOptions, "output"> & {
|
|
7902
8040
|
output?: OUTPUT;
|
|
7903
8041
|
};
|
|
7904
8042
|
type StreamTextOptions = BaseGenerationOptions & {
|
|
@@ -7924,6 +8062,7 @@ declare class Agent {
|
|
|
7924
8062
|
readonly temperature?: number;
|
|
7925
8063
|
readonly maxOutputTokens?: number;
|
|
7926
8064
|
readonly maxSteps: number;
|
|
8065
|
+
readonly maxRetries: number;
|
|
7927
8066
|
readonly stopWhen?: StopWhen;
|
|
7928
8067
|
readonly markdown: boolean;
|
|
7929
8068
|
readonly voice?: Voice;
|
|
@@ -7943,27 +8082,35 @@ declare class Agent {
|
|
|
7943
8082
|
private readonly feedbackOptions?;
|
|
7944
8083
|
private readonly inputGuardrails;
|
|
7945
8084
|
private readonly outputGuardrails;
|
|
8085
|
+
private readonly inputMiddlewares;
|
|
8086
|
+
private readonly outputMiddlewares;
|
|
8087
|
+
private readonly maxMiddlewareRetries;
|
|
7946
8088
|
private readonly observabilityAuthWarningState;
|
|
7947
8089
|
constructor(options: AgentOptions);
|
|
7948
8090
|
/**
|
|
7949
8091
|
* Generate text response
|
|
7950
8092
|
*/
|
|
7951
|
-
generateText<OUTPUT extends OutputSpec = OutputSpec>(input: string | UIMessage[] | BaseMessage[], options?: GenerateTextOptions<OUTPUT>): Promise<GenerateTextResultWithContext<ToolSet, OUTPUT>>;
|
|
8093
|
+
generateText<OUTPUT extends OutputSpec$1 = OutputSpec$1>(input: string | UIMessage[] | BaseMessage[], options?: GenerateTextOptions<OUTPUT>): Promise<GenerateTextResultWithContext<ToolSet, OUTPUT>>;
|
|
7952
8094
|
/**
|
|
7953
8095
|
* Stream text response
|
|
7954
8096
|
*/
|
|
7955
8097
|
streamText(input: string | UIMessage[] | BaseMessage[], options?: StreamTextOptions): Promise<StreamTextResultWithContext>;
|
|
7956
8098
|
/**
|
|
7957
8099
|
* Generate structured object
|
|
7958
|
-
* @deprecated Use generateText with
|
|
8100
|
+
* @deprecated — Use generateText with an output setting instead.
|
|
7959
8101
|
*/
|
|
7960
8102
|
generateObject<T extends z.ZodType>(input: string | UIMessage[] | BaseMessage[], schema: T, options?: GenerateObjectOptions): Promise<GenerateObjectResultWithContext<z.infer<T>>>;
|
|
7961
8103
|
/**
|
|
7962
8104
|
* Stream structured object
|
|
7963
|
-
* @deprecated Use streamText with
|
|
8105
|
+
* @deprecated — Use streamText with an output setting instead.
|
|
7964
8106
|
*/
|
|
7965
8107
|
streamObject<T extends z.ZodType>(input: string | UIMessage[] | BaseMessage[], schema: T, options?: StreamObjectOptions): Promise<StreamObjectResultWithContext<z.infer<T>>>;
|
|
7966
8108
|
private resolveGuardrailSets;
|
|
8109
|
+
private resolveMiddlewareSets;
|
|
8110
|
+
private resolveMiddlewareRetries;
|
|
8111
|
+
private storeMiddlewareRetryFeedback;
|
|
8112
|
+
private consumeMiddlewareRetryFeedback;
|
|
8113
|
+
private shouldRetryMiddleware;
|
|
7967
8114
|
/**
|
|
7968
8115
|
* Common preparation for all execution methods
|
|
7969
8116
|
*/
|
|
@@ -7977,6 +8124,7 @@ declare class Agent {
|
|
|
7977
8124
|
* Transitional helper to gradually adopt OperationContext across methods
|
|
7978
8125
|
*/
|
|
7979
8126
|
private createOperationContext;
|
|
8127
|
+
private resetOperationAttemptState;
|
|
7980
8128
|
private getConversationBuffer;
|
|
7981
8129
|
private getMemoryPersistQueue;
|
|
7982
8130
|
private flushPendingMessagesOnError;
|
|
@@ -8044,10 +8192,18 @@ declare class Agent {
|
|
|
8044
8192
|
* Resolve dynamic value
|
|
8045
8193
|
*/
|
|
8046
8194
|
private resolveValue;
|
|
8195
|
+
private getModelCandidates;
|
|
8196
|
+
private resolveModelReference;
|
|
8047
8197
|
/**
|
|
8048
8198
|
* Resolve agent model value (LanguageModel or provider/model string)
|
|
8049
8199
|
*/
|
|
8050
8200
|
private resolveModel;
|
|
8201
|
+
private resolveCallMaxRetries;
|
|
8202
|
+
private shouldFallbackOnError;
|
|
8203
|
+
private isRetryableError;
|
|
8204
|
+
private executeWithModelFallback;
|
|
8205
|
+
private probeStreamStart;
|
|
8206
|
+
private discardStream;
|
|
8051
8207
|
/**
|
|
8052
8208
|
* Prepare tools with execution context
|
|
8053
8209
|
*/
|
|
@@ -9214,10 +9370,13 @@ type ExtractExecuteResult<T> = T extends {
|
|
|
9214
9370
|
execute: (...args: any[]) => infer R;
|
|
9215
9371
|
} ? R extends Promise<infer U> ? U : R : never;
|
|
9216
9372
|
|
|
9217
|
-
type
|
|
9373
|
+
type OutputSpec = Output.Output<unknown, unknown>;
|
|
9374
|
+
type AgentOutputSchema = OutputSpec | z.ZodTypeAny;
|
|
9375
|
+
type InferAgentOutput<SCHEMA extends AgentOutputSchema> = SCHEMA extends OutputSpec ? InferGenerateOutput<SCHEMA> : SCHEMA extends z.ZodTypeAny ? z.infer<SCHEMA> : never;
|
|
9376
|
+
type AgentConfig<SCHEMA extends AgentOutputSchema, INPUT, DATA> = Omit<BaseGenerationOptions, "output"> & {
|
|
9218
9377
|
schema: SCHEMA | ((context: Omit<WorkflowExecuteContext<INPUT, DATA, any, any>, "suspend" | "writer">) => SCHEMA | Promise<SCHEMA>);
|
|
9219
9378
|
};
|
|
9220
|
-
type AgentResultMapper<INPUT, DATA, SCHEMA extends
|
|
9379
|
+
type AgentResultMapper<INPUT, DATA, SCHEMA extends AgentOutputSchema, RESULT> = (output: InferAgentOutput<SCHEMA>, context: WorkflowExecuteContext<INPUT, DATA, any, any>) => Promise<RESULT> | RESULT;
|
|
9221
9380
|
/**
|
|
9222
9381
|
* Creates an agent step for a workflow
|
|
9223
9382
|
*
|
|
@@ -9238,11 +9397,11 @@ type AgentResultMapper<INPUT, DATA, SCHEMA extends z.ZodTypeAny, RESULT> = (outp
|
|
|
9238
9397
|
*
|
|
9239
9398
|
* @param task - The task (prompt) to execute for the agent, can be a string or a function that returns a string
|
|
9240
9399
|
* @param agent - The agent to execute the task using `generateText`
|
|
9241
|
-
* @param config - The config for the agent (schema) `generateText` call
|
|
9400
|
+
* @param config - The config for the agent (schema/output) `generateText` call
|
|
9242
9401
|
* @param map - Optional mapper to shape or merge the agent output with existing data
|
|
9243
9402
|
* @returns A workflow step that executes the agent with the task
|
|
9244
9403
|
*/
|
|
9245
|
-
declare function andAgent<INPUT, DATA, SCHEMA extends
|
|
9404
|
+
declare function andAgent<INPUT, DATA, SCHEMA extends AgentOutputSchema, RESULT = InferAgentOutput<SCHEMA>>(task: UIMessage[] | ModelMessage[] | string | InternalWorkflowFunc<INPUT, DATA, UIMessage[] | ModelMessage[] | string, any, any>, agent: Agent, config: AgentConfig<SCHEMA, INPUT, DATA>, map?: AgentResultMapper<INPUT, DATA, SCHEMA, RESULT>): {
|
|
9246
9405
|
type: "agent";
|
|
9247
9406
|
id: string;
|
|
9248
9407
|
name: string;
|
|
@@ -9890,12 +10049,6 @@ interface SerializedWorkflowStep {
|
|
|
9890
10049
|
subStepsCount?: number;
|
|
9891
10050
|
}
|
|
9892
10051
|
|
|
9893
|
-
/**
|
|
9894
|
-
* Agent configuration for the chain
|
|
9895
|
-
*/
|
|
9896
|
-
type AgentConfig<SCHEMA extends z.ZodTypeAny, INPUT_SCHEMA extends InternalBaseWorkflowInputSchema, CURRENT_DATA> = BaseGenerationOptions & {
|
|
9897
|
-
schema: SCHEMA | ((context: Omit<WorkflowExecuteContext<WorkflowInput<INPUT_SCHEMA>, CURRENT_DATA, any, any>, "suspend" | "writer">) => SCHEMA | Promise<SCHEMA>);
|
|
9898
|
-
};
|
|
9899
10052
|
/**
|
|
9900
10053
|
* A workflow chain that provides a fluent API for building workflows
|
|
9901
10054
|
*
|
|
@@ -9972,8 +10125,8 @@ declare class WorkflowChain<INPUT_SCHEMA extends InternalBaseWorkflowInputSchema
|
|
|
9972
10125
|
* @param map - Optional mapper to shape or merge the agent output with existing data
|
|
9973
10126
|
* @returns A workflow step that executes the agent with the task
|
|
9974
10127
|
*/
|
|
9975
|
-
andAgent<SCHEMA extends
|
|
9976
|
-
andAgent<SCHEMA extends
|
|
10128
|
+
andAgent<SCHEMA extends AgentOutputSchema>(task: string | UIMessage[] | ModelMessage[] | InternalWorkflowFunc<WorkflowInput<INPUT_SCHEMA>, CURRENT_DATA, string | UIMessage[] | ModelMessage[], any, any>, agent: Agent, config: AgentConfig<SCHEMA, WorkflowInput<INPUT_SCHEMA>, CURRENT_DATA>): WorkflowChain<INPUT_SCHEMA, RESULT_SCHEMA, InferAgentOutput<SCHEMA>, SUSPEND_SCHEMA, RESUME_SCHEMA>;
|
|
10129
|
+
andAgent<SCHEMA extends AgentOutputSchema, NEW_DATA>(task: string | UIMessage[] | ModelMessage[] | InternalWorkflowFunc<WorkflowInput<INPUT_SCHEMA>, CURRENT_DATA, string | UIMessage[] | ModelMessage[], any, any>, agent: Agent, config: AgentConfig<SCHEMA, WorkflowInput<INPUT_SCHEMA>, CURRENT_DATA>, map: (output: InferAgentOutput<SCHEMA>, context: WorkflowExecuteContext<WorkflowInput<INPUT_SCHEMA>, CURRENT_DATA, any, any>) => Promise<NEW_DATA> | NEW_DATA): WorkflowChain<INPUT_SCHEMA, RESULT_SCHEMA, NEW_DATA, SUSPEND_SCHEMA, RESUME_SCHEMA>;
|
|
9977
10130
|
/**
|
|
9978
10131
|
* Add a function step to the workflow with both input and output schemas
|
|
9979
10132
|
* @param config - Step configuration with schemas
|
|
@@ -10717,6 +10870,7 @@ type TaskToolOptions = {
|
|
|
10717
10870
|
systemPrompt?: string | null;
|
|
10718
10871
|
taskDescription?: string | null;
|
|
10719
10872
|
maxSteps?: number;
|
|
10873
|
+
supervisorConfig?: SupervisorConfig;
|
|
10720
10874
|
};
|
|
10721
10875
|
type PlanAgentOptions = Omit<AgentOptions, "instructions" | "tools" | "toolkits" | "subAgents" | "supervisorConfig"> & {
|
|
10722
10876
|
systemPrompt?: InstructionsDynamicValue;
|
|
@@ -10940,6 +11094,15 @@ type CreateOutputGuardrailOptions<TOutput = unknown> = CreateGuardrailDefinition
|
|
|
10940
11094
|
declare function createInputGuardrail(options: CreateInputGuardrailOptions): InputGuardrail;
|
|
10941
11095
|
declare function createOutputGuardrail<TOutput = unknown>(options: CreateOutputGuardrailOptions<TOutput>): OutputGuardrail<TOutput>;
|
|
10942
11096
|
|
|
11097
|
+
type EmptyMiddlewareExtras = Record<never, never>;
|
|
11098
|
+
type CreateMiddlewareDefinition<TArgs, TResult, TExtra extends Record<PropertyKey, unknown> = EmptyMiddlewareExtras> = Omit<MiddlewareDefinition<TArgs, TResult>, keyof TExtra | "handler"> & TExtra & {
|
|
11099
|
+
handler: MiddlewareFunction<TArgs, TResult>;
|
|
11100
|
+
};
|
|
11101
|
+
type CreateInputMiddlewareOptions = CreateMiddlewareDefinition<InputMiddlewareArgs, InputMiddlewareResult>;
|
|
11102
|
+
type CreateOutputMiddlewareOptions<TOutput = unknown> = CreateMiddlewareDefinition<OutputMiddlewareArgs<TOutput>, OutputMiddlewareResult<TOutput>>;
|
|
11103
|
+
declare function createInputMiddleware(options: CreateInputMiddlewareOptions): InputMiddleware;
|
|
11104
|
+
declare function createOutputMiddleware<TOutput = unknown>(options: CreateOutputMiddlewareOptions<TOutput>): OutputMiddleware<TOutput>;
|
|
11105
|
+
|
|
10943
11106
|
declare const TRIGGER_CONTEXT_KEY: unique symbol;
|
|
10944
11107
|
|
|
10945
11108
|
declare const SERVERLESS_ENV_CONTEXT_KEY: unique symbol;
|
|
@@ -13556,6 +13719,7 @@ declare enum NodeType {
|
|
|
13556
13719
|
MESSAGE = "message",
|
|
13557
13720
|
OUTPUT = "output",
|
|
13558
13721
|
GUARDRAIL = "guardrail",
|
|
13722
|
+
MIDDLEWARE = "middleware",
|
|
13559
13723
|
RETRIEVER = "retriever",
|
|
13560
13724
|
VECTOR = "vector",
|
|
13561
13725
|
EMBEDDING = "embedding",
|
|
@@ -14315,4 +14479,4 @@ declare class VoltAgent {
|
|
|
14315
14479
|
*/
|
|
14316
14480
|
declare function convertUsage(usage: LanguageModelUsage | undefined): UsageInfo | undefined;
|
|
14317
14481
|
|
|
14318
|
-
export { A2AServerRegistry, AbortError, Agent, type AgentEvalConfig, type AgentEvalContext, type AgentEvalFeedbackHelper, type AgentEvalFeedbackSaveInput, type AgentEvalOperationType, type AgentEvalPayload, type AgentEvalResult, type AgentEvalResultCallbackArgs, type AgentEvalSamplingPolicy, type AgentEvalScorerConfig, type AgentEvalScorerFactory, type AgentEvalScorerReference, type AgentFeedbackMetadata, type AgentFeedbackOptions, type AgentFullState, type AgentHookOnEnd, type AgentHookOnError, type AgentHookOnHandoff, type AgentHookOnHandoffComplete, type AgentHookOnPrepareMessages, type AgentHookOnPrepareModelMessages, type AgentHookOnStart, type AgentHookOnStepFinish, type AgentHookOnToolEnd, type AgentHookOnToolStart, type AgentHooks, type AgentModelReference, type AgentModelValue, type AgentOptions, AgentRegistry, type AgentResponse, type AgentScorerState, type AgentStatus, type AgentSummarizationOptions, type AgentTool, AiSdkEmbeddingAdapter, type AllowedVariableValue, type ApiToolInfo, type BaseEventMetadata, type BaseGenerationOptions, type BaseLLMOptions, type BaseMessage, BaseRetriever, type BaseTool, type BaseToolCall, type BuildScorerOptions, type BuildScorerRunArgs, type BuildScorerRunResult, type BuilderAnalyzeContext, type BuilderPrepareContext, type BuilderReasonContext, type BuilderScoreContext, type CachedPrompt, type ChatMessage, ClientHTTPError, type ClientSideToolResult, type CloudflareFetchHandler, CompositeFilesystemBackend, type Conversation, ConversationAlreadyExistsError, ConversationNotFoundError, type ConversationQueryOptions, type ConversationQueryOptions as ConversationQueryOptionsV2, type ConversationStepRecord, type ConversationStepType, ConversationTodoBackend, type Conversation as ConversationV2, type CreateConversationInput, type CreateConversationInput as CreateConversationInputV2, type CreateInputGuardrailOptions, type CreateOutputGuardrailOptions, type CreateReasoningToolsOptions, type CreateScorerOptions, DEFAULT_INSTRUCTIONS, type DataContent, type Document, type DynamicValue, type DynamicValueOptions, EDIT_FILE_TOOL_DESCRIPTION, type EditResult, type EmbeddingAdapter$1 as EmbeddingAdapter, EmbeddingAdapterNotConfiguredError, EmbeddingError, type ExtractVariableNames, FEW_SHOT_EXAMPLES, FILESYSTEM_SYSTEM_PROMPT, type FileData, type FileInfo, type FilesystemBackend, type FilesystemBackendContext, type FilesystemBackendFactory, type FilesystemToolkitOptions, GLOB_TOOL_DESCRIPTION, GREP_TOOL_DESCRIPTION, type GenerateObjectOptions, type GenerateObjectResultWithContext, type GenerateObjectSubAgentConfig, type GenerateReasonResult, type GenerateScoreResult, type GenerateScoreStep, type GenerateTextOptions, type GenerateTextResultWithContext, type GenerateTextSubAgentConfig, type GetConversationStepsOptions, type GetMessagesOptions, type GrepMatch, type GuardrailAction, type GuardrailContext, type GuardrailDefinition, type GuardrailFunction, type GuardrailSeverity, type IServerProvider, type IServerlessProvider, type VoltOpsClient$1 as IVoltOpsClient, InMemoryFilesystemBackend, InMemoryStorageAdapter$1 as InMemoryObservabilityAdapter, InMemoryStorageAdapter, InMemoryVectorAdapter, type InferGenerateObjectResponse, type InferGenerateTextResponse, type InferMessage, type InferModel, type InferProviderParams, type InferStreamResponse, type InferTool, type InputGuardrail, type InputGuardrailArgs, type InputGuardrailResult, type KnowledgeBaseTagFilter, type LLMProvider, LS_TOOL_DESCRIPTION, type LanguageModelFactory, LazyRemoteExportProcessor, type LocalScorerDefinition, type LocalScorerExecutionResult, LocalStorageSpanProcessor, type LogFilter, LoggerProxy, type MCPAuthorizationAction, type MCPAuthorizationConfig, type MCPAuthorizationContext, MCPAuthorizationError, type MCPCanFunction, type MCPCanParams, type MCPCanResult, MCPClient, type MCPClientCallOptions, type MCPClientConfig, MCPConfiguration, type MCPConfigurationOptions, type MCPElicitationAdapter, type MCPElicitationHandler, type MCPLoggingAdapter, type MCPPromptsAdapter, type MCPResourcesAdapter, MCPServerRegistry, type ManagedMemoryAddMessageInput, type ManagedMemoryAddMessagesInput, type ManagedMemoryClearMessagesInput, type ManagedMemoryConnectionInfo, type ManagedMemoryConversationsClient, type ManagedMemoryCredentialCreateResult, type ManagedMemoryCredentialListResult, type ManagedMemoryCredentialSummary, type ManagedMemoryDatabaseSummary, type ManagedMemoryGetMessagesInput, type ManagedMemoryMessagesClient, type ManagedMemoryQueryWorkflowRunsInput, type ManagedMemorySetWorkingMemoryInput, type ManagedMemoryStatus, type ManagedMemoryUpdateConversationInput, type ManagedMemoryVoltOpsClient, type ManagedMemoryWorkflowStateUpdateInput, type ManagedMemoryWorkflowStatesClient, type ManagedMemoryWorkingMemoryClient, type ManagedMemoryWorkingMemoryInput, Memory, type MemoryConfig, type MemoryOptions, type MemoryStorageMetadata, type MemoryUpdateMode, Memory as MemoryV2, MemoryV2Error, type MessageContent, MessageContentBuilder, type MessageRole, type ModelForProvider, type ModelProvider, type ModelProviderEntry, type ModelProviderLoader, ModelProviderRegistry, type ModelRouterModelId, type ModelToolCall, NextAction, NodeFilesystemBackend, NodeType, VoltAgentObservability$1 as NodeVoltAgentObservability, type ObservabilityConfig, type ObservabilityLogRecord, type ObservabilitySpan, type ObservabilityStorageAdapter, type ObservabilityWebSocketEvent, type OnEndHookArgs, type OnErrorHookArgs, type OnHandoffCompleteHookArgs, type OnHandoffHookArgs, type OnPrepareMessagesHookArgs, type OnPrepareMessagesHookResult, type OnPrepareModelMessagesHookArgs, type OnPrepareModelMessagesHookResult, type OnStartHookArgs, type OnStepFinishHookArgs, type OnToolEndHookArgs, type OnToolStartHookArgs, type OperationContext, type OutputGuardrail, type OutputGuardrailArgs, type OutputGuardrailResult, type OutputSpec, type PackageUpdateInfo, PlanAgent, type PlanAgentExtension, type PlanAgentExtensionContext, type PlanAgentExtensionResult, type PlanAgentFileData, type PlanAgentOptions, type PlanAgentState, type PlanAgentSubagentDefinition, type PlanAgentTodoItem, type PlanAgentTodoStatus, type PlanningToolkitOptions, type PromptApiClient, type PromptApiResponse, type PromptContent, type PromptCreator, type PromptHelper, type PromptReference, type PromptTemplate, type ProviderId, type ProviderModelsMap, type ProviderObjectResponse, type ProviderObjectStreamResponse, type ProviderParams, type ProviderResponse, type ProviderTextResponse, type ProviderTextStreamResponse, type ProviderTool, READ_FILE_TOOL_DESCRIPTION, type RagKnowledgeBaseSummary, type RagSearchKnowledgeBaseChildChunk, type RagSearchKnowledgeBaseRequest, type RagSearchKnowledgeBaseResponse, type RagSearchKnowledgeBaseResult, type ReadableStreamType, type ReasoningStep, ReasoningStepSchema, type RegisterOptions, type RegisteredTrigger, type RegisteredWorkflow, type RemoteLogExportConfig, RemoteLogProcessor, type ResumableStreamAdapter, type ResumableStreamContext, type RetrieveOptions, type Retriever, type RetrieverOptions, type RunLocalScorersArgs, type RunLocalScorersResult, SERVERLESS_ENV_CONTEXT_KEY, type SamplingMetadata, type SamplingPolicy, type ScorerBuilder, type ScorerContext, type ScorerLifecycleScope, type ScorerPipelineContext, type ScorerReasonContext, type ScorerResult, type SearchOptions, type SearchResult, type ServerAgentResponse, type ServerApiResponse, type ServerProviderDeps, type ServerProviderFactory, type ServerWorkflowResponse, type ServerlessProviderFactory, type ServerlessRemoteEndpointConfig, type ServerlessRemoteExportConfig, type ServerlessRequestHandler, ServerlessVoltAgentObservability, type SpanAttributes, type SpanEvent, type SpanFilterConfig, SpanFilterProcessor, SpanKind, type SpanLink, type SpanStatus, SpanStatusCode, type SpanTreeNode, type StepChunkCallback, type StepFinishCallback, type StepWithContent, type StopWhen, type StorageAdapter, StorageError, StorageLogProcessor, type StoredUIMessage, type StreamObjectFinishResult, type StreamObjectOnFinishCallback, type StreamObjectOptions, type StreamObjectResultWithContext, type StreamObjectSubAgentConfig, type StreamPart, type StreamTextFinishResult, type StreamTextOnFinishCallback, type StreamTextOptions, type StreamTextResultWithContext, type StreamTextSubAgentConfig, type SubAgentConfig, type SubAgentMethod, type SubAgentStateData, type SupervisorConfig, TRIGGER_CONTEXT_KEY, type TaskToolOptions, type TemplateVariables, type TimelineEventCoreLevel, type TimelineEventCoreStatus, type TimelineEventCoreType, type TodoBackend, type TodoBackendFactory, Tool, type ToolCall, type ToolContext, ToolDeniedError, type ToolErrorInfo, type ToolExecuteOptions, type ToolExecutionResult, ToolManager, type ToolOptions, type ToolResultOutput, type ToolSchema, type ToolStatus, type ToolStatusInfo, type ToolWithNodeId, type Toolkit, type TriggerHandler, type TriggerHandlerBody, type TriggerHandlerContext, type TriggerHandlerResponse, type TriggerHandlerResult, type TriggerHandlerReturn, type TriggerHttpMethod, TriggerRegistry, type Usage, type UsageInfo, UserInputBridge, type UserInputHandler, type VectorAdapter, VectorAdapterNotConfiguredError, VectorError, type VectorItem, type VectorSearchOptions, type Voice, type VoiceEventData, type VoiceEventType, type VoiceMetadata, type VoiceOptions, VoltAgent, VoltAgentError, VoltAgentObservability, type VoltAgentOptions, VoltAgentRagRetriever, type VoltAgentRagRetrieverOptions, type VoltAgentStreamTextResult, type VoltAgentTextStreamPart, type VoltAgentTriggerConfig, type VoltAgentTriggersConfig, type VoltOpsActionExecutionResult, type VoltOpsActionsApi, VoltOpsActionsClient, type VoltOpsActionsTransport, type VoltOpsAirtableCreateRecordParams, type VoltOpsAirtableCredential, type VoltOpsAirtableDeleteRecordParams, type VoltOpsAirtableGetRecordParams, type VoltOpsAirtableListRecordsParams, type VoltOpsAirtableUpdateRecordParams, type VoltOpsAppendEvalRunResultPayload, type VoltOpsAppendEvalRunResultsRequest, VoltOpsClient, type VoltOpsClientOptions, type VoltOpsCompleteEvalRunRequest, type VoltOpsCreateEvalRunRequest, type VoltOpsCreateScorerRequest, type VoltOpsDiscordChannelMessageParams, type VoltOpsDiscordChannelType, type VoltOpsDiscordConfig, type VoltOpsDiscordCreateChannelParams, type VoltOpsDiscordCredential, type VoltOpsDiscordDeleteChannelParams, type VoltOpsDiscordGetChannelParams, type VoltOpsDiscordListChannelsParams, type VoltOpsDiscordListMembersParams, type VoltOpsDiscordListMessagesParams, type VoltOpsDiscordMemberRoleParams, type VoltOpsDiscordReactionParams, type VoltOpsDiscordSendMessageParams, type VoltOpsDiscordSendWebhookMessageParams, type VoltOpsDiscordUpdateChannelParams, type VoltOpsEvalResultStatus, type VoltOpsEvalRunCompletionSummaryPayload, type VoltOpsEvalRunErrorPayload, type VoltOpsEvalRunResultLiveMetadata, type VoltOpsEvalRunResultScorePayload, type VoltOpsEvalRunStatus, type VoltOpsEvalRunSummary, type VoltOpsFeedback, type VoltOpsFeedbackConfig, type VoltOpsFeedbackCreateInput, type VoltOpsFeedbackExpiresIn, type VoltOpsFeedbackToken, type VoltOpsFeedbackTokenCreateInput, VoltOpsPromptApiClient, type VoltOpsPromptManager, VoltOpsPromptManagerImpl, type VoltOpsScorerSummary, type VoltOpsSlackCredential, type VoltOpsSlackDeleteMessageParams, type VoltOpsSlackPostMessageParams, type VoltOpsSlackSearchMessagesParams, type VoltOpsTerminalEvalRunStatus, type VoltOpsTriggerDefinition, VoltOpsTriggerDefinitions, type VoltOpsTriggerEnvelope, type VoltOpsTriggerGroupMap, type VoltOpsTriggerName, VoltOpsTriggerNames, WRITE_FILE_TOOL_DESCRIPTION, WRITE_TODOS_TOOL_DESCRIPTION, WRITE_TODOS_TOOL_NAME, WebSocketEventEmitter, WebSocketLogProcessor, WebSocketSpanProcessor, type WeightedBlendComponent, type WeightedBlendOptions, type Workflow, type WorkflowConfig, type WorkflowExecutionContext, type WorkflowHookContext, type WorkflowHookStatus, type WorkflowHooks, WorkflowRegistry, type WorkflowRunQuery, type WorkflowStateEntry, type WorkflowStats, type WorkflowStepContext, type WorkflowStepData, type WorkflowStepStatus, type WorkflowStepType, type WorkflowTimelineEvent, type WorkingMemoryConfig, type WorkingMemoryScope, type WorkingMemorySummary, type WorkingMemoryUpdateOptions, type WriteResult, addTimestampToMessage, andAgent, andAll, andBranch, andDoUntil, andDoWhile, andForEach, andGuardrail, andMap, andRace, andSleep, andSleepUntil, andTap, andThen, andWhen, andWorkflow, appendToMessage, buildRetrieverLogMessage, buildSamplingMetadata, buildScorer, buildSpanTree, checkForUpdates, convertUsage, cosineSimilarity, createDefaultInputSafetyGuardrails, createDefaultPIIGuardrails, createDefaultSafetyGuardrails, createEmailRedactorGuardrail, createFilesystemToolkit, createHTMLSanitizerInputGuardrail, createHooks, createInputGuardrail, createInputLengthGuardrail, createMaxLengthGuardrail, createNodeId, createOutputGuardrail, createPIIInputGuardrail, createPhoneNumberGuardrail, createPlanningToolkit, createProfanityGuardrail, createProfanityInputGuardrail, createPrompt, createPromptInjectionGuardrail, createReasoningTools, createRetrieverTool, createScorer, createSensitiveNumberGuardrail, createSimpleTemplateEngine, createSubagent, createSuspendController, createTool, createToolResultEvictor, createToolkit, createTriggers, createVoltAgentObservability, createVoltOpsClient, createWorkflow, createWorkflowChain, createWorkflowStepNodeId, VoltAgent as default, defineVoltOpsTrigger, extractFileParts, extractImageParts, extractText, extractTextParts, extractWorkflowStepInfo, filterContentParts, getContentLength, getEnvVar, getGlobalLogBuffer, getGlobalLogger, getGlobalVoltOpsClient, getNodeTypeFromNodeId, getVoltOpsTriggerDefinition, getWorkflowStepNodeType, hasContent, hasFilePart, hasImagePart, hasTextPart, isAbortError, isNodeRuntime, isServerlessRuntime, isStructuredContent, isTextContent, isVoltAgentError, mapMessageContent, messageHelpers, normalizeContent, normalizeScorerResult, normalizeToArray, prependToMessage, readableLogRecordToObservabilityLog, readableSpanToObservabilitySpan, runLocalScorers, safeJsonParse, serializeValueForDebug, setWaitUntil, shouldSample, tool, transformTextContent, updateAllPackages, updateSinglePackage, weightedBlend, zodSchemaToJsonUI };
|
|
14482
|
+
export { A2AServerRegistry, AbortError, Agent, type AgentEvalConfig, type AgentEvalContext, type AgentEvalFeedbackHelper, type AgentEvalFeedbackSaveInput, type AgentEvalOperationType, type AgentEvalPayload, type AgentEvalResult, type AgentEvalResultCallbackArgs, type AgentEvalSamplingPolicy, type AgentEvalScorerConfig, type AgentEvalScorerFactory, type AgentEvalScorerReference, type AgentFeedbackMetadata, type AgentFeedbackOptions, type AgentFullState, type AgentHookOnEnd, type AgentHookOnError, type AgentHookOnFallback, type AgentHookOnHandoff, type AgentHookOnHandoffComplete, type AgentHookOnPrepareMessages, type AgentHookOnPrepareModelMessages, type AgentHookOnRetry, type AgentHookOnStart, type AgentHookOnStepFinish, type AgentHookOnToolEnd, type AgentHookOnToolStart, type AgentHooks, type AgentModelConfig, type AgentModelReference, type AgentModelValue, type AgentOptions, AgentRegistry, type AgentResponse, type AgentScorerState, type AgentStatus, type AgentSummarizationOptions, type AgentTool, AiSdkEmbeddingAdapter, type AllowedVariableValue, type ApiToolInfo, type BaseEventMetadata, type BaseGenerationOptions, type BaseLLMOptions, type BaseMessage, BaseRetriever, type BaseTool, type BaseToolCall, type BuildScorerOptions, type BuildScorerRunArgs, type BuildScorerRunResult, type BuilderAnalyzeContext, type BuilderPrepareContext, type BuilderReasonContext, type BuilderScoreContext, type CachedPrompt, type ChatMessage, ClientHTTPError, type ClientSideToolResult, type CloudflareFetchHandler, CompositeFilesystemBackend, type Conversation, ConversationAlreadyExistsError, ConversationNotFoundError, type ConversationQueryOptions, type ConversationQueryOptions as ConversationQueryOptionsV2, type ConversationStepRecord, type ConversationStepType, ConversationTodoBackend, type Conversation as ConversationV2, type CreateConversationInput, type CreateConversationInput as CreateConversationInputV2, type CreateInputGuardrailOptions, type CreateInputMiddlewareOptions, type CreateOutputGuardrailOptions, type CreateOutputMiddlewareOptions, type CreateReasoningToolsOptions, type CreateScorerOptions, DEFAULT_INSTRUCTIONS, type DataContent, type Document, type DynamicValue, type DynamicValueOptions, EDIT_FILE_TOOL_DESCRIPTION, type EditResult, type EmbeddingAdapter$1 as EmbeddingAdapter, EmbeddingAdapterNotConfiguredError, EmbeddingError, type ExtractVariableNames, FEW_SHOT_EXAMPLES, FILESYSTEM_SYSTEM_PROMPT, type FallbackStage, type FileData, type FileInfo, type FilesystemBackend, type FilesystemBackendContext, type FilesystemBackendFactory, type FilesystemToolkitOptions, GLOB_TOOL_DESCRIPTION, GREP_TOOL_DESCRIPTION, type GenerateObjectOptions, type GenerateObjectResultWithContext, type GenerateObjectSubAgentConfig, type GenerateReasonResult, type GenerateScoreResult, type GenerateScoreStep, type GenerateTextOptions, type GenerateTextResultWithContext, type GenerateTextSubAgentConfig, type GetConversationStepsOptions, type GetMessagesOptions, type GrepMatch, type GuardrailAction, type GuardrailContext, type GuardrailDefinition, type GuardrailFunction, type GuardrailSeverity, type IServerProvider, type IServerlessProvider, type VoltOpsClient$1 as IVoltOpsClient, InMemoryFilesystemBackend, InMemoryStorageAdapter$1 as InMemoryObservabilityAdapter, InMemoryStorageAdapter, InMemoryVectorAdapter, type InferGenerateObjectResponse, type InferGenerateTextResponse, type InferMessage, type InferModel, type InferProviderParams, type InferStreamResponse, type InferTool, type InputGuardrail, type InputGuardrailArgs, type InputGuardrailResult, type InputMiddleware, type InputMiddlewareArgs, type InputMiddlewareResult, type KnowledgeBaseTagFilter, type LLMProvider, LS_TOOL_DESCRIPTION, type LanguageModelFactory, LazyRemoteExportProcessor, type LocalScorerDefinition, type LocalScorerExecutionResult, LocalStorageSpanProcessor, type LogFilter, LoggerProxy, type MCPAuthorizationAction, type MCPAuthorizationConfig, type MCPAuthorizationContext, MCPAuthorizationError, type MCPCanFunction, type MCPCanParams, type MCPCanResult, MCPClient, type MCPClientCallOptions, type MCPClientConfig, MCPConfiguration, type MCPConfigurationOptions, type MCPElicitationAdapter, type MCPElicitationHandler, type MCPLoggingAdapter, type MCPPromptsAdapter, type MCPResourcesAdapter, MCPServerRegistry, type ManagedMemoryAddMessageInput, type ManagedMemoryAddMessagesInput, type ManagedMemoryClearMessagesInput, type ManagedMemoryConnectionInfo, type ManagedMemoryConversationsClient, type ManagedMemoryCredentialCreateResult, type ManagedMemoryCredentialListResult, type ManagedMemoryCredentialSummary, type ManagedMemoryDatabaseSummary, type ManagedMemoryGetMessagesInput, type ManagedMemoryMessagesClient, type ManagedMemoryQueryWorkflowRunsInput, type ManagedMemorySetWorkingMemoryInput, type ManagedMemoryStatus, type ManagedMemoryUpdateConversationInput, type ManagedMemoryVoltOpsClient, type ManagedMemoryWorkflowStateUpdateInput, type ManagedMemoryWorkflowStatesClient, type ManagedMemoryWorkingMemoryClient, type ManagedMemoryWorkingMemoryInput, Memory, type MemoryConfig, type MemoryOptions, type MemoryStorageMetadata, type MemoryUpdateMode, Memory as MemoryV2, MemoryV2Error, type MessageContent, MessageContentBuilder, type MessageRole, MiddlewareAbortError, type MiddlewareAbortOptions, type MiddlewareContext, type MiddlewareDefinition, type MiddlewareDirection, type MiddlewareFunction, type ModelForProvider, type ModelProvider, type ModelProviderEntry, type ModelProviderLoader, ModelProviderRegistry, type ModelRouterModelId, type ModelToolCall, NextAction, NodeFilesystemBackend, NodeType, VoltAgentObservability$1 as NodeVoltAgentObservability, type ObservabilityConfig, type ObservabilityLogRecord, type ObservabilitySpan, type ObservabilityStorageAdapter, type ObservabilityWebSocketEvent, type OnEndHookArgs, type OnErrorHookArgs, type OnFallbackHookArgs, type OnHandoffCompleteHookArgs, type OnHandoffHookArgs, type OnPrepareMessagesHookArgs, type OnPrepareMessagesHookResult, type OnPrepareModelMessagesHookArgs, type OnPrepareModelMessagesHookResult, type OnRetryHookArgs, type OnRetryHookArgsBase, type OnRetryLLMHookArgs, type OnRetryMiddlewareHookArgs, type OnStartHookArgs, type OnStepFinishHookArgs, type OnToolEndHookArgs, type OnToolStartHookArgs, type OperationContext, type OutputGuardrail, type OutputGuardrailArgs, type OutputGuardrailResult, type OutputMiddleware, type OutputMiddlewareArgs, type OutputMiddlewareResult, type OutputSpec$1 as OutputSpec, type PackageUpdateInfo, PlanAgent, type PlanAgentExtension, type PlanAgentExtensionContext, type PlanAgentExtensionResult, type PlanAgentFileData, type PlanAgentOptions, type PlanAgentState, type PlanAgentSubagentDefinition, type PlanAgentTodoItem, type PlanAgentTodoStatus, type PlanningToolkitOptions, type PromptApiClient, type PromptApiResponse, type PromptContent, type PromptCreator, type PromptHelper, type PromptReference, type PromptTemplate, type ProviderId, type ProviderModelsMap, type ProviderObjectResponse, type ProviderObjectStreamResponse, type ProviderParams, type ProviderResponse, type ProviderTextResponse, type ProviderTextStreamResponse, type ProviderTool, READ_FILE_TOOL_DESCRIPTION, type RagKnowledgeBaseSummary, type RagSearchKnowledgeBaseChildChunk, type RagSearchKnowledgeBaseRequest, type RagSearchKnowledgeBaseResponse, type RagSearchKnowledgeBaseResult, type ReadableStreamType, type ReasoningStep, ReasoningStepSchema, type RegisterOptions, type RegisteredTrigger, type RegisteredWorkflow, type RemoteLogExportConfig, RemoteLogProcessor, type ResumableStreamAdapter, type ResumableStreamContext, type RetrieveOptions, type Retriever, type RetrieverOptions, type RetrySource, type RunLocalScorersArgs, type RunLocalScorersResult, SERVERLESS_ENV_CONTEXT_KEY, type SamplingMetadata, type SamplingPolicy, type ScorerBuilder, type ScorerContext, type ScorerLifecycleScope, type ScorerPipelineContext, type ScorerReasonContext, type ScorerResult, type SearchOptions, type SearchResult, type ServerAgentResponse, type ServerApiResponse, type ServerProviderDeps, type ServerProviderFactory, type ServerWorkflowResponse, type ServerlessProviderFactory, type ServerlessRemoteEndpointConfig, type ServerlessRemoteExportConfig, type ServerlessRequestHandler, ServerlessVoltAgentObservability, type SpanAttributes, type SpanEvent, type SpanFilterConfig, SpanFilterProcessor, SpanKind, type SpanLink, type SpanStatus, SpanStatusCode, type SpanTreeNode, type StepChunkCallback, type StepFinishCallback, type StepWithContent, type StopWhen, type StorageAdapter, StorageError, StorageLogProcessor, type StoredUIMessage, type StreamObjectFinishResult, type StreamObjectOnFinishCallback, type StreamObjectOptions, type StreamObjectResultWithContext, type StreamObjectSubAgentConfig, type StreamPart, type StreamTextFinishResult, type StreamTextOnFinishCallback, type StreamTextOptions, type StreamTextResultWithContext, type StreamTextSubAgentConfig, type SubAgentConfig, type SubAgentMethod, type SubAgentStateData, type SupervisorConfig, TRIGGER_CONTEXT_KEY, type TaskToolOptions, type TemplateVariables, type TimelineEventCoreLevel, type TimelineEventCoreStatus, type TimelineEventCoreType, type TodoBackend, type TodoBackendFactory, Tool, type ToolCall, type ToolContext, ToolDeniedError, type ToolErrorInfo, type ToolExecuteOptions, type ToolExecutionResult, ToolManager, type ToolOptions, type ToolResultOutput, type ToolSchema, type ToolStatus, type ToolStatusInfo, type ToolWithNodeId, type Toolkit, type TriggerHandler, type TriggerHandlerBody, type TriggerHandlerContext, type TriggerHandlerResponse, type TriggerHandlerResult, type TriggerHandlerReturn, type TriggerHttpMethod, TriggerRegistry, type Usage, type UsageInfo, UserInputBridge, type UserInputHandler, type VectorAdapter, VectorAdapterNotConfiguredError, VectorError, type VectorItem, type VectorSearchOptions, type Voice, type VoiceEventData, type VoiceEventType, type VoiceMetadata, type VoiceOptions, VoltAgent, VoltAgentError, VoltAgentObservability, type VoltAgentOptions, VoltAgentRagRetriever, type VoltAgentRagRetrieverOptions, type VoltAgentStreamTextResult, type VoltAgentTextStreamPart, type VoltAgentTriggerConfig, type VoltAgentTriggersConfig, type VoltOpsActionExecutionResult, type VoltOpsActionsApi, VoltOpsActionsClient, type VoltOpsActionsTransport, type VoltOpsAirtableCreateRecordParams, type VoltOpsAirtableCredential, type VoltOpsAirtableDeleteRecordParams, type VoltOpsAirtableGetRecordParams, type VoltOpsAirtableListRecordsParams, type VoltOpsAirtableUpdateRecordParams, type VoltOpsAppendEvalRunResultPayload, type VoltOpsAppendEvalRunResultsRequest, VoltOpsClient, type VoltOpsClientOptions, type VoltOpsCompleteEvalRunRequest, type VoltOpsCreateEvalRunRequest, type VoltOpsCreateScorerRequest, type VoltOpsDiscordChannelMessageParams, type VoltOpsDiscordChannelType, type VoltOpsDiscordConfig, type VoltOpsDiscordCreateChannelParams, type VoltOpsDiscordCredential, type VoltOpsDiscordDeleteChannelParams, type VoltOpsDiscordGetChannelParams, type VoltOpsDiscordListChannelsParams, type VoltOpsDiscordListMembersParams, type VoltOpsDiscordListMessagesParams, type VoltOpsDiscordMemberRoleParams, type VoltOpsDiscordReactionParams, type VoltOpsDiscordSendMessageParams, type VoltOpsDiscordSendWebhookMessageParams, type VoltOpsDiscordUpdateChannelParams, type VoltOpsEvalResultStatus, type VoltOpsEvalRunCompletionSummaryPayload, type VoltOpsEvalRunErrorPayload, type VoltOpsEvalRunResultLiveMetadata, type VoltOpsEvalRunResultScorePayload, type VoltOpsEvalRunStatus, type VoltOpsEvalRunSummary, type VoltOpsFeedback, type VoltOpsFeedbackConfig, type VoltOpsFeedbackCreateInput, type VoltOpsFeedbackExpiresIn, type VoltOpsFeedbackToken, type VoltOpsFeedbackTokenCreateInput, VoltOpsPromptApiClient, type VoltOpsPromptManager, VoltOpsPromptManagerImpl, type VoltOpsScorerSummary, type VoltOpsSlackCredential, type VoltOpsSlackDeleteMessageParams, type VoltOpsSlackPostMessageParams, type VoltOpsSlackSearchMessagesParams, type VoltOpsTerminalEvalRunStatus, type VoltOpsTriggerDefinition, VoltOpsTriggerDefinitions, type VoltOpsTriggerEnvelope, type VoltOpsTriggerGroupMap, type VoltOpsTriggerName, VoltOpsTriggerNames, WRITE_FILE_TOOL_DESCRIPTION, WRITE_TODOS_TOOL_DESCRIPTION, WRITE_TODOS_TOOL_NAME, WebSocketEventEmitter, WebSocketLogProcessor, WebSocketSpanProcessor, type WeightedBlendComponent, type WeightedBlendOptions, type Workflow, type WorkflowConfig, type WorkflowExecutionContext, type WorkflowHookContext, type WorkflowHookStatus, type WorkflowHooks, WorkflowRegistry, type WorkflowRunQuery, type WorkflowStateEntry, type WorkflowStats, type WorkflowStepContext, type WorkflowStepData, type WorkflowStepStatus, type WorkflowStepType, type WorkflowTimelineEvent, type WorkingMemoryConfig, type WorkingMemoryScope, type WorkingMemorySummary, type WorkingMemoryUpdateOptions, type WriteResult, addTimestampToMessage, andAgent, andAll, andBranch, andDoUntil, andDoWhile, andForEach, andGuardrail, andMap, andRace, andSleep, andSleepUntil, andTap, andThen, andWhen, andWorkflow, appendToMessage, buildRetrieverLogMessage, buildSamplingMetadata, buildScorer, buildSpanTree, checkForUpdates, convertUsage, cosineSimilarity, createDefaultInputSafetyGuardrails, createDefaultPIIGuardrails, createDefaultSafetyGuardrails, createEmailRedactorGuardrail, createFilesystemToolkit, createHTMLSanitizerInputGuardrail, createHooks, createInputGuardrail, createInputLengthGuardrail, createInputMiddleware, createMaxLengthGuardrail, createNodeId, createOutputGuardrail, createOutputMiddleware, createPIIInputGuardrail, createPhoneNumberGuardrail, createPlanningToolkit, createProfanityGuardrail, createProfanityInputGuardrail, createPrompt, createPromptInjectionGuardrail, createReasoningTools, createRetrieverTool, createScorer, createSensitiveNumberGuardrail, createSimpleTemplateEngine, createSubagent, createSuspendController, createTool, createToolResultEvictor, createToolkit, createTriggers, createVoltAgentObservability, createVoltOpsClient, createWorkflow, createWorkflowChain, createWorkflowStepNodeId, VoltAgent as default, defineVoltOpsTrigger, extractFileParts, extractImageParts, extractText, extractTextParts, extractWorkflowStepInfo, filterContentParts, getContentLength, getEnvVar, getGlobalLogBuffer, getGlobalLogger, getGlobalVoltOpsClient, getNodeTypeFromNodeId, getVoltOpsTriggerDefinition, getWorkflowStepNodeType, hasContent, hasFilePart, hasImagePart, hasTextPart, isAbortError, isMiddlewareAbortError, isNodeRuntime, isServerlessRuntime, isStructuredContent, isTextContent, isVoltAgentError, mapMessageContent, messageHelpers, normalizeContent, normalizeScorerResult, normalizeToArray, prependToMessage, readableLogRecordToObservabilityLog, readableSpanToObservabilitySpan, runLocalScorers, safeJsonParse, serializeValueForDebug, setWaitUntil, shouldSample, tool, transformTextContent, updateAllPackages, updateSinglePackage, weightedBlend, zodSchemaToJsonUI };
|