export type WorkspaceMutationKind = 'add' | 'update' | 'delete' | 'move' | 'rewrite' | 'unknown'; export interface TurnFileChange { kind: WorkspaceMutationKind; path: string; moveTo?: string; added?: number; removed?: number; diff?: string; toolName: string; at: number; } export interface TurnVerificationRecord { toolName: string; command?: string; success: boolean; status?: string; exitCode?: number | null; timedOut?: boolean; } export interface TurnDiffState { sessionKey: string; turnId: string; changedFiles: string[]; changes: TurnFileChange[]; cumulativeDiff: string; added: number; removed: number; dirty: boolean; dirtyReason?: string; diffReviewed: boolean; verificationAttempted: boolean; lastVerification?: TurnVerificationRecord; } export declare class TurnDiffTracker { private readonly states; beginTurn(sessionKey: string, turnId?: string): void; getState(sessionKey: string): TurnDiffState; reset(sessionKey: string): void; recordToolResult(input: { sessionKey: string; toolName: string; args?: unknown; result?: unknown; isError?: boolean; }): void; recordMutation(input: { sessionKey: string; toolName: string; changes: TurnFileChange[]; }): void; recordDiffReviewed(sessionKey: string): void; recordVerification(input: { sessionKey: string; toolName: string; command?: string; success: boolean; status?: string; exitCode?: number | null; timedOut?: boolean; }): void; markDirty(sessionKey: string, reason: string): void; buildFinalGuardContext(sessionKey: string): string; private mutableState; private recordApplyPatch; private recordWriteFile; private recordExecCommand; }