@mastra/core
Version:
28 lines • 957 B
TypeScript
import type { MastraLanguageModel } from '../../llm/model/shared.types.js';
import type { StreamInternal } from '../types.js';
type State = {
stepResult: Record<string, any> | undefined;
responseMetadata: Record<string, any> | undefined;
modelMetadata: {
modelId: string;
modelVersion: string;
modelProvider: string;
};
hasErrored: boolean;
apiError: unknown | undefined;
deferredErrorChunk: any | undefined;
providerOptions: Record<string, any> | undefined;
/** Assistant text emitted so far for the in-flight step. Surfaced to `onAbort` when a run is cancelled mid-stream. */
partialText: string;
};
export declare class AgenticRunState {
#private;
constructor({ _internal, model }: {
_internal: StreamInternal;
model: MastraLanguageModel;
});
setState(state: Partial<State>): void;
get state(): State;
}
export {};
//# sourceMappingURL=run-state.d.ts.map