/**
 * @fileoverview Transcript Watcher - Real-time monitoring of Claude Code session transcripts
 *
 * Watches the main session transcript JSONL file and emits structured events for:
 * - Assistant message completion
 * - Tool execution state
 * - Error conditions
 * - Plan mode prompts
 *
 * The transcript path is provided by Claude Code hooks in the `transcript_path` field.
 */
import { EventEmitter } from 'node:events';
/**
 * Detected state from transcript analysis
 */
export interface TranscriptState {
    /** Whether the last entry indicates completion */
    isComplete: boolean;
    /** Whether a tool is currently executing */
    toolExecuting: boolean;
    /** Current tool name if executing */
    currentTool: string | null;
    /** Whether an error was detected */
    hasError: boolean;
    /** Error message if any */
    errorMessage: string | null;
    /** Whether a plan mode prompt was detected */
    planModeDetected: boolean;
    /** Last assistant message (truncated) */
    lastAssistantMessage: string | null;
    /** Total entries processed */
    entryCount: number;
    /** Last update timestamp */
    lastUpdateAt: string | null;
}
export declare class TranscriptWatcher extends EventEmitter {
    private transcriptPath;
    private fileWatcher;
    private pollInterval;
    private filePosition;
    private _isRunning;
    private _isProcessing;
    private state;
    constructor();
    private getInitialState;
    /**
     * Start watching a transcript file
     * @param transcriptPath - Path to the JSONL transcript file
     */
    start(transcriptPath: string): void;
    /**
     * Stop watching
     */
    stop(): void;
    /**
     * Check if watcher is running
     */
    isRunning(): boolean;
    /**
     * Get current state
     */
    getState(): TranscriptState;
    /**
     * Update the transcript path (e.g., from a new hook event)
     */
    updatePath(transcriptPath: string): void;
    private startPolling;
    private setupFileWatcher;
    private processNewContent;
    private readNewEntries;
    private processEntry;
    private handleAssistantEntry;
    private handleResultEntry;
    private checkPlanMode;
}
//# sourceMappingURL=transcript-watcher.d.ts.map