/**
 * Structured telemetry event for a single gate decision.
 *
 * One event is emitted per scan — Gates 1-4 each produce one GateDecision
 * per invocation. Written as JSONL (one JSON object per line, append-only).
 */
export interface GateDecision {
    ts: string;
    gate: 1 | 2 | 3 | 4;
    gate_name: "input" | "rag" | "toolCall" | "output";
    mode: "block" | "warn" | "log";
    sensitivity: "low" | "medium" | "high";
    threshold: number;
    request_id?: string;
    session_id?: string;
    agent_id?: string;
    message_id?: string;
    tool_name?: string;
    provider?: string;
    channel?: string;
    text_length: number;
    text_hash: string;
    text_preview?: string;
    parse_outcome?: "exact" | "heuristic" | "fallback" | "raw";
    safe: boolean;
    threat_type: string;
    confidence: number;
    latency_ms: number;
    tier_reached: number;
    signals: string[];
    posterior_prob?: number;
    effective_lr?: number;
    disposition?: string;
    severity?: string;
    is_threat: boolean;
    action: "passed" | "blocked" | "quarantined" | "cancelled" | "warned" | "logged" | "skipped";
    reason_code?: string;
}
/**
 * Append-only JSONL telemetry writer with daily file rotation.
 *
 * File pattern: `${basePath}/telemetry-YYYY-MM-DD.jsonl`
 *
 * No npm dependencies — uses only Node.js built-ins.
 */
export declare class TelemetryWriter {
    private readonly basePath;
    private initialized;
    constructor(basePath: string);
    /**
     * Sync append — used by synchronous gates (Gate 1, Gate 2).
     */
    record(decision: GateDecision): void;
    /**
     * Async append — used by async gates (Gate 3, Gate 4).
     */
    recordAsync(decision: GateDecision): Promise<void>;
    /**
     * Returns the file path for today's telemetry file.
     */
    getFilePath(date?: Date): string;
    /**
     * Read the last N decisions from today's file.
     * Returns empty array if file doesn't exist or is empty.
     */
    readRecent(n: number, date?: Date): GateDecision[];
    /**
     * Quick stats from today's file.
     */
    countToday(date?: Date): {
        total: number;
        threats: number;
        blocked: number;
    };
    private ensureDir;
}
