import { type RunAgentFn, type RunAgentHooks, type WorkflowMode } from "./hooks.js"; import { type WorkflowParticipant } from "./participant.js"; export interface WorkflowStage { id: string; participant: string; prompt?: string; mode?: WorkflowMode; skills?: string[]; hooks?: RunAgentHooks; onFailure?: "stop" | "continue"; } export interface StageContext { cwd: string; participants: Record; runAgent: RunAgentFn; signal?: AbortSignal; iteration: number; } export declare function runWorkflowStage(stage: WorkflowStage, context: StageContext): Promise<{ success: boolean; error?: Error; }>;