import { EventEmitter } from 'node:events';
import type { AgentResponse, WorkflowConfig, WorkflowResumePoint, WorkflowState } from '../../models/types.js';
import type { WorkflowEngineOptions } from '../types.js';
export type { WorkflowEvents, StepProviderInfo, UserInputRequest, IterationLimitRequest, SessionUpdateCallback, IterationLimitCallback, WorkflowEngineOptions, } from '../types.js';
export { COMPLETE_STEP, ABORT_STEP } from '../constants.js';
export declare class WorkflowEngine extends EventEmitter {
    private state;
    private config;
    private projectCwd;
    private cwd;
    private task;
    private options;
    private maxSteps;
    private loopDetector;
    private cycleDetector;
    private reportDir;
    private runPaths;
    private abortRequested;
    private readonly sharedRuntime;
    private readonly resumeStackPrefix;
    private readonly optionsBuilder;
    private readonly stepExecutor;
    private readonly parallelRunner;
    private readonly arpeggioRunner;
    private readonly teamLeaderRunner;
    private readonly systemStepExecutor;
    private readonly loopMonitorJudgeRunner;
    private readonly workflowCallRunner;
    private readonly stepCoordinator;
    private readonly detectRuleIndex;
    private readonly structuredCaller;
    constructor(config: WorkflowConfig, cwd: string, task: string, options: WorkflowEngineOptions);
    getState(): WorkflowState;
    private buildResumePoint;
    private setActiveResumePoint;
    getResumePoint(): WorkflowResumePoint | undefined;
    buildResumePointForStepName(stepName: string): WorkflowResumePoint | undefined;
    addUserInput(input: string): void;
    updateCwd(newCwd: string): void;
    getCwd(): string;
    getProjectCwd(): string;
    abort(): void;
    isAbortRequested(): boolean;
    private updatePersonaSession;
    private resolveNextStepFromDone;
    private finalizeSystemStepResources;
    private buildWorkflowSpanParams;
    private runWithSystemCleanup;
    run(): Promise<WorkflowState>;
    runSingleIteration(): Promise<{
        response: AgentResponse;
        nextStep: string;
        isComplete: boolean;
        loopDetected?: boolean;
    }>;
}
//# sourceMappingURL=WorkflowEngine.d.ts.map