UNPKG

@mastra/core

Version:

Mastra is a framework for building AI-powered applications and agents with a modern TypeScript stack.

45 lines 2.43 kB
import type { BackgroundTaskManager } from '../../../background-tasks/index.js'; import type { AgentBackgroundConfig } from '../../../background-tasks/types.js'; import type { MastraMemory } from '../../../memory/memory.js'; import type { MemoryConfigInternal } from '../../../memory/types.js'; import { MastraModelOutput } from '../../../stream/index.js'; import type { ToolPayloadTransformPolicy } from '../../../tools/index.js'; import type { Workspace } from '../../../workspace/workspace.js'; import type { SaveQueueManager } from '../../save-queue/index.js'; import type { CreatedAgentSignal } from '../../signals.js'; import type { AgentMethodType } from '../../types.js'; import type { AgentCapabilities } from './schema.js'; interface StreamStepOptions { capabilities: AgentCapabilities; runId: string; returnScorerData?: boolean; requireToolApproval?: boolean; toolCallConcurrency?: number; resumeContext?: { resumeData: any; snapshot: any; }; agentId: string; agentName?: string; toolCallId?: string; methodType: AgentMethodType; saveQueueManager?: SaveQueueManager; memoryConfig?: MemoryConfigInternal; memory?: MastraMemory; resourceId?: string; autoResumeSuspendedTools?: boolean; workspace?: Workspace; backgroundTaskManager?: BackgroundTaskManager; agentBackgroundConfig?: AgentBackgroundConfig; toolPayloadTransform?: ToolPayloadTransformPolicy; /** * When true, the in-loop `backgroundTaskCheckStep` skips its wait for * running tasks. Used when an outer caller (e.g. `agent.streamUntilIdle`) * drives continuation from outside the loop. */ skipBgTaskWait?: boolean; drainPendingSignals?: (runId: string) => CreatedAgentSignal[]; } export declare function createStreamStep<OUTPUT = undefined>({ capabilities, runId: _runId, returnScorerData, requireToolApproval, toolCallConcurrency, resumeContext, agentId, agentName, toolCallId, methodType, saveQueueManager, memoryConfig, memory, resourceId, autoResumeSuspendedTools, workspace, backgroundTaskManager, agentBackgroundConfig, toolPayloadTransform, skipBgTaskWait, drainPendingSignals, }: StreamStepOptions): import("../../../workflows").Step<"stream-text-step", unknown, any, MastraModelOutput<OUTPUT>, unknown, unknown, import("../../../workflows").DefaultEngineType, unknown>; export {}; //# sourceMappingURL=stream-step.d.ts.map