import { SessionObserverBandConfig } from './types.js';
import './index-1qIcnbG1.js';

interface SessionObservationInput {
    sessionKey: string;
    totalBytes: number;
    totalTokens: number;
    observedAt?: string;
}
interface SessionObservationDecision {
    triggered: boolean;
    deltaBytes: number;
    deltaTokens: number;
    band: SessionObserverBandConfig;
    reason?: "threshold" | "debounced" | "baseline";
}
declare function normalizeObserverBands(bands: SessionObserverBandConfig[]): SessionObserverBandConfig[];
declare class SessionObserverState {
    private readonly statePath;
    private readonly lockPath;
    private readonly lockStaleMs;
    private readonly debounceMs;
    private readonly bands;
    private sessions;
    private saveQueue;
    private readPersistedState;
    private normalizePersistedSessions;
    constructor(opts: {
        memoryDir: string;
        debounceMs: number;
        bands: SessionObserverBandConfig[];
    });
    private withSaveLock;
    load(): Promise<void>;
    save(): Promise<void>;
    private enqueueSave;
    private bandForTotalBytes;
    observe(input: SessionObservationInput): Promise<SessionObservationDecision>;
}

export { type SessionObservationDecision, type SessionObservationInput, SessionObserverState, normalizeObserverBands };
