import type { PatchLimits, PatchValidation } from "@oscharko-dev/keiko-tools";
import { type BugEventEmitter } from "./emit.js";
import { type BugInvestigationDeps, type BugInvestigationInput, type BugWorkflowLimits, type Hypothesis } from "./types.js";
import type { BugWorkflowEventSink } from "./events.js";
export declare const NO_OP_SINK: BugWorkflowEventSink;
export interface BugWorkflowProgress {
    modelCallCount: number;
    patchRetryCount: number;
}
export interface BugRunState {
    readonly input: BugInvestigationInput;
    readonly deps: BugInvestigationDeps;
    readonly limits: BugWorkflowLimits;
    readonly signal: AbortSignal;
    readonly now: () => number;
    readonly emitter: BugEventEmitter;
    readonly startedAt: number;
    readonly progress: BugWorkflowProgress;
    memoryPromptText: string | undefined;
}
export interface AcceptedBugPatch {
    readonly diff: string;
    readonly validation: PatchValidation;
    readonly hypothesis: Hypothesis;
}
export interface BugModelLoopResult {
    readonly accepted: AcceptedBugPatch | undefined;
    readonly investigationOnly: Hypothesis | undefined;
    readonly modelCallCount: number;
    readonly patchRetryCount: number;
    readonly lastRejectionCode: string | undefined;
}
export declare const EMPTY_BUG_LOOP: BugModelLoopResult;
export declare function resolveBugLimits(input: BugInvestigationInput): BugWorkflowLimits;
export declare function patchLimitsFrom(limits: BugWorkflowLimits): PatchLimits;
export declare function buildBugRunState(input: BugInvestigationInput, deps: BugInvestigationDeps, fingerprint: string): BugRunState;
export declare function nextActionsFor(applied: boolean, files: readonly string[], elevated: readonly string[]): readonly string[];
export declare function investigationNextActions(): readonly string[];
//# sourceMappingURL=internal.d.ts.map