import type { CoreMessage } from '../../_types/@internal_ai-sdk-v4/dist/index.js'; import type { Agent, AgentExecutionOptions, AiMessageType, UIMessageWithMetadata } from '../../agent/index.js'; import type { ObservabilityContext } from '../../observability/index.js'; import type { RequestContext } from '../../request-context/index.js'; import { Workflow } from '../../workflows/index.js'; import type { AnyWorkflow, WorkflowResult, WorkflowRunStartOptions } from '../../workflows/index.js'; import type { MastraScorer } from '../base.js'; type WorkflowRunOptions = WorkflowRunStartOptions & { initialState?: any; }; type RunEvalsDataItem = { input: TTarget extends Workflow ? any : TTarget extends Agent ? string | string[] | CoreMessage[] | AiMessageType[] | UIMessageWithMetadata[] : unknown; groundTruth?: any; expectedTrajectory?: any; requestContext?: RequestContext; startOptions?: WorkflowRunOptions; } & Partial; export type WorkflowScorerConfig = { /** Scorers that evaluate the overall workflow input/output */ workflow?: MastraScorer[]; /** Scorers that evaluate individual workflow steps by step ID */ steps?: Record[]>; /** Scorers that evaluate the workflow's step execution trajectory */ trajectory?: MastraScorer[]; }; export type AgentScorerConfig = { /** Scorers that evaluate the full agent input/output */ agent?: MastraScorer[]; /** Scorers that evaluate the agent's tool call trajectory */ trajectory?: MastraScorer[]; }; type RunEvalsResult = { scores: Record; summary: { totalItems: number; }; }; export declare function runEvals(config: { data: RunEvalsDataItem[]; scorers: MastraScorer[]; target: TAgent; targetOptions?: Omit, 'scorers' | 'returnScorerData' | 'requestContext'>; onItemComplete?: (params: { item: RunEvalsDataItem; targetResult: Awaited>; scorerResults: Record; }) => void | Promise; concurrency?: number; }): Promise; export declare function runEvals(config: { data: RunEvalsDataItem[]; scorers: MastraScorer[]; target: TWorkflow; targetOptions?: WorkflowRunOptions; onItemComplete?: (params: { item: RunEvalsDataItem; targetResult: WorkflowResult; scorerResults: Record; }) => void | Promise; concurrency?: number; }): Promise; export declare function runEvals(config: { data: RunEvalsDataItem[]; scorers: WorkflowScorerConfig; target: TWorkflow; targetOptions?: WorkflowRunOptions; onItemComplete?: (params: { item: RunEvalsDataItem; targetResult: WorkflowResult; scorerResults: { workflow?: Record; steps?: Record>; trajectory?: Record; }; }) => void | Promise; concurrency?: number; }): Promise; export declare function runEvals(config: { data: RunEvalsDataItem[]; scorers: AgentScorerConfig; target: TAgent; targetOptions?: Omit, 'scorers' | 'returnScorerData' | 'requestContext'>; onItemComplete?: (params: { item: RunEvalsDataItem; targetResult: Awaited>; scorerResults: { agent?: Record; trajectory?: Record; }; }) => void | Promise; concurrency?: number; }): Promise; export {}; //# sourceMappingURL=index.d.ts.map