import { type GoalRun, type GoalTask } from "./goal-store.js";
export declare const DEFAULT_GOAL_TASK_ATTEMPT_LIMIT = 5;
export declare const DEFAULT_GOAL_VERIFIER_FIX_LIMIT = 5;
export declare const DEFAULT_GOAL_EVIDENCE_RECONCILIATION_LIMIT = 2;
export type GoalControllerDecision = {
    kind: "blocked";
    reason: string;
} | {
    kind: "create_task";
    title: string;
    prompt: string;
    reason: string;
} | {
    kind: "terminal";
    reason: string;
    status: "blocked" | "failed" | "passed" | "paused";
} | {
    kind: "wait";
    reason: string;
    workerId?: string;
} | {
    kind: "start_worker";
    task: GoalTask;
    attempts: number;
    reason: string;
} | {
    kind: "pause";
    task: GoalTask;
    attempts: number;
    reason: string;
} | {
    kind: "run_verifier";
    command: string;
    reason: string;
} | {
    kind: "complete";
    reason: string;
};
export interface GoalCompletionCheck {
    ok: boolean;
    reason: string;
}
export interface GoalControllerOptions {
    taskAttemptLimit?: number;
    verifierFixLimit?: number;
    evidenceReconciliationLimit?: number;
}
export declare function unsatisfiedGoalEvidencePlanItems(run: GoalRun): GoalRun["evidencePlan"];
export declare function hasRequiredGoalEvidence(run: GoalRun): GoalCompletionCheck;
export declare function hasFreshGoalCompletionAudit(run: GoalRun): GoalCompletionCheck;
export declare function canCompleteGoalRun(run: GoalRun): GoalCompletionCheck;
export declare function shouldClearGoalContinuation(decision: GoalControllerDecision): boolean;
export declare function shouldCreateVerifierFixTask(run: GoalRun, limit?: number): boolean;
export declare function verifierFixTaskCount(run: GoalRun): number;
export declare function hasRepeatedVerifierFailure(run: GoalRun, repeatLimit?: number): boolean;
export declare function formatGoalControllerDecision(decision: GoalControllerDecision): {
    label: string;
    content: string;
};
export declare function decideGoalNextAction(run: GoalRun, options?: GoalControllerOptions): GoalControllerDecision;
//# sourceMappingURL=goal-controller.d.ts.map