/**
 * Audit Logger for Code Generation Operations
 *
 * Traces all validation decisions, tool executions, and security events
 * for code generation operations. Provides a persistent audit trail
 * that can be reviewed for compliance and debugging.
 */
export type AuditAction = 'code_validation' | 'command_validation' | 'file_write' | 'file_edit' | 'file_delete' | 'patch_apply' | 'bash_execute' | 'confirmation_requested' | 'confirmation_granted' | 'confirmation_denied' | 'checkpoint_created' | 'checkpoint_restored' | 'sandbox_execute' | 'pattern_matched' | 'tool_execution';
export type AuditDecision = 'allow' | 'block' | 'warn' | 'confirm';
export interface AuditEntry {
    /** Unique entry ID */
    id: string;
    /** ISO timestamp */
    timestamp: string;
    /** Action performed */
    action: AuditAction;
    /** Decision made */
    decision: AuditDecision;
    /** Tool or subsystem that produced this entry */
    source: string;
    /** Target file or command */
    target?: string;
    /** Details about findings or validation results */
    details?: string;
    /** Associated findings count (for validators) */
    findingsCount?: number;
    /** Session ID for correlation */
    sessionId?: string;
    /** Duration in ms */
    durationMs?: number;
}
declare class AuditLoggerImpl {
    private entries;
    private logFile;
    private maxEntries;
    private sessionId;
    private enabled;
    /**
     * Initialize the audit logger with a log file path.
     */
    init(options?: {
        logDir?: string;
        maxEntries?: number;
        sessionId?: string;
        enabled?: boolean;
    }): void;
    /**
     * Log an audit entry.
     */
    log(entry: Omit<AuditEntry, 'id' | 'timestamp' | 'sessionId'>): void;
    /**
     * Log a code validation result.
     */
    logCodeValidation(params: {
        target: string;
        safe: boolean;
        findingsCount: number;
        details?: string;
        durationMs?: number;
    }): void;
    /**
     * Log a command validation result.
     */
    logCommandValidation(params: {
        command: string;
        valid: boolean;
        reason?: string;
        source?: string;
    }): void;
    /**
     * Log a file operation.
     */
    logFileOperation(params: {
        action: 'file_write' | 'file_edit' | 'file_delete' | 'patch_apply';
        target: string;
        decision: AuditDecision;
        source: string;
        details?: string;
    }): void;
    /**
     * Log a confirmation event.
     */
    logConfirmation(params: {
        operation: string;
        target: string;
        granted: boolean;
    }): void;
    /**
     * Log a pattern match.
     */
    logPatternMatch(params: {
        patternName: string;
        severity: string;
        target: string;
        source: string;
    }): void;
    /**
     * Get recent audit entries.
     */
    getEntries(limit?: number): AuditEntry[];
    /**
     * Get entries filtered by action type.
     */
    getEntriesByAction(action: AuditAction, limit?: number): AuditEntry[];
    /**
     * Get summary statistics.
     */
    getSummary(): {
        total: number;
        byAction: Record<string, number>;
        byDecision: Record<string, number>;
        blocked: number;
        warnings: number;
    };
    /**
     * Format summary as human-readable text.
     */
    formatSummary(): string;
    /**
     * Clear in-memory entries.
     */
    clear(): void;
    private generateId;
}
/** Singleton audit logger instance */
export declare const auditLogger: AuditLoggerImpl;
export {};
