/**
 * HITL (Human-in-the-Loop) Manager
 *
 * Central orchestrator for all HITL confirmation workflows.
 * Manages user confirmation requests, timeouts, and argument modifications
 * for enterprise-grade AI safety.
 */
import { EventEmitter } from "events";
import type { HITLConfig, ConfirmationResult, HITLStatistics } from "../types/hitlTypes.js";
/**
 * HITLManager - Central orchestrator for Human-in-the-Loop safety mechanisms
 *
 * Features:
 * - Real-time user confirmation via events
 * - Configurable dangerous action detection
 * - Custom rule engine for complex scenarios
 * - Argument modification support
 * - Comprehensive audit logging
 * - Timeout handling with cleanup
 */
export declare class HITLManager extends EventEmitter {
    private config;
    private pendingConfirmations;
    private statistics;
    constructor(config: HITLConfig);
    /**
     * Validate HITL configuration and apply defaults
     */
    private validateConfig;
    /**
     * Check if a tool requires confirmation based on configuration
     */
    requiresConfirmation(toolName: string, args?: unknown): boolean;
    /**
     * Request confirmation for a tool execution
     */
    requestConfirmation(toolName: string, arguments_: unknown, context?: {
        serverId?: string;
        sessionId?: string;
        userId?: string;
    }): Promise<ConfirmationResult>;
    /**
     * Process user response to confirmation request
     */
    processUserResponse(confirmationId: string, response: {
        approved: boolean;
        reason?: string;
        modifiedArguments?: unknown;
        responseTime?: number;
        userId?: string;
    }): void;
    /**
     * Handle confirmation timeout
     */
    private handleTimeout;
    /**
     * Set up event handlers for processing responses
     */
    private setupEventHandlers;
    /**
     * Generate unique confirmation ID
     */
    private generateConfirmationId;
    /**
     * Generate human-readable action description
     */
    private generateActionDescription;
    /**
     * Get keywords that triggered HITL
     */
    private getTriggeredKeywords;
    /**
     * Log audit events for compliance and debugging
     */
    private logAuditEvent;
    /**
     * Get current HITL usage statistics
     */
    getStatistics(): HITLStatistics;
    /**
     * Get current configuration
     */
    getConfig(): HITLConfig;
    /**
     * Update configuration (for dynamic reconfiguration)
     */
    updateConfig(newConfig: Partial<HITLConfig>): void;
    /**
     * Clean up resources and reject pending confirmations
     */
    cleanup(): void;
    /**
     * Check if manager is currently enabled
     */
    isEnabled(): boolean;
    /**
     * Get count of pending confirmations
     */
    getPendingCount(): number;
}
