/**
 * Watch Mode - IDE Comment Triggers (Aider inspired)
 *
 * Watches files for special comments and triggers AI actions:
 * - AI! = Make changes to the code
 * - AI? = Answer a question about the code
 *
 * Example:
 * ```python
 * # AI! Add validation for email format
 * def create_user(email: str):
 *     pass
 * ```
 */
import { EventEmitter } from 'events';
/**
 * Represents an AI trigger comment found in the code.
 */
export interface AIComment {
    /** The type of trigger: action (!) or question (?). */
    type: 'action' | 'question';
    /** The content of the comment (instruction). */
    content: string;
    /** File where the comment was found. */
    filePath: string;
    /** Line number where the comment starts. */
    lineNumber: number;
    /** Surrounding code context. */
    context: string;
}
/**
 * Configuration for Watch Mode.
 */
export interface WatchConfig {
    /** Directories to watch. */
    paths: string[];
    /** File patterns to include (optional). */
    include?: string[];
    /** File patterns to exclude (optional). */
    exclude?: string[];
    /** Debounce delay in ms (default: 500). */
    debounce?: number;
    /** Process existing comments on start (default: false). */
    processExisting?: boolean;
}
/**
 * Extracts AI comments from file content.
 * Scans for patterns like `# AI!`, `// AI?`, etc.
 *
 * @param content - File content.
 * @param filePath - File path (for location info).
 * @returns Array of found AI comments.
 */
export declare function extractAIComments(content: string, filePath: string): AIComment[];
/**
 * Removes a processed AI comment from the file.
 * Preserves the rest of the line if the comment was inline.
 *
 * @param filePath - Path to the file.
 * @param lineNumber - Line number of the comment.
 */
export declare function removeAIComment(filePath: string, lineNumber: number): Promise<void>;
/**
 * Manages watching files for AI triggers.
 * Emits 'comment' events when AI instructions are found.
 */
export declare class WatchModeManager extends EventEmitter {
    private watchers;
    private config;
    private debounceTimers;
    private processedComments;
    constructor(config: WatchConfig);
    /**
     * Starts watching configured paths.
     */
    start(): Promise<void>;
    /**
     * Checks if a file path should be watched (not ignored).
     */
    private shouldWatch;
    /**
     * Stops watching all paths and clears timers.
     */
    stop(): Promise<void>;
    /**
     * Handles a file change event with debouncing.
     */
    private handleFileChange;
    /**
     * Processes a modified file to find and emit new AI comments.
     */
    private processFile;
    /**
     * Marks a comment as complete and optionally removes it from the file.
     *
     * @param comment - The processed comment.
     * @param removeComment - Whether to remove it from source (default: true).
     */
    completeComment(comment: AIComment, removeComment?: boolean): Promise<void>;
}
/**
 * Formats an AI comment for display in the chat.
 *
 * @param comment - The AI comment.
 * @returns Formatted string.
 */
export declare function formatAIComment(comment: AIComment): string;
/**
 * Creates a WatchModeManager instance with default settings.
 *
 * @param paths - Directories to watch.
 * @returns New WatchModeManager instance.
 */
export declare function createWatchMode(paths?: string[]): WatchModeManager;
