import { type DreamState } from "../agent/runtime-vars.js";
import type { AgentRpcRequest } from "../protocol/wire/index.js";
type TimerHandle = {
    unref?: () => void;
};
export interface IdleDreamTimers {
    setTimeout(callback: () => void, delayMs: number): TimerHandle;
    clearTimeout(timerId: TimerHandle): void;
}
export interface IdleDreamClient {
    model: string;
    apiKey: string;
}
export interface IdleDreamCoordinatorOptions {
    dreamState?: DreamState;
    now?: () => number;
    randomId?: () => string;
    timers?: IdleDreamTimers;
    log(message: string): void;
    sendNotification(method: string, params: Record<string, unknown>): void;
    getCurrentSessionId(): string;
    getCurrentTurnCount(): number;
    getActiveTurn(): AbortController | null;
    resolveDreamClient(): IdleDreamClient | null;
    resolveMemoryRoot(): string;
    resolveTranscriptDir(): string;
    listRecentSessions(): Promise<Array<{
        sessionId: string;
    }>>;
    runDream(message: AgentRpcRequest): Promise<void>;
}
export declare class IdleDreamCoordinator {
    private readonly options;
    private readonly dreamState;
    private readonly now;
    private readonly randomId;
    private readonly timers;
    private idleTimer;
    constructor(options: IdleDreamCoordinatorOptions);
    applyEnvOverrides(env: Record<string, string | undefined>): void;
    enable(minutes?: number): void;
    handleTurnNotification(method: string): void;
    cancelTimer(): void;
    resetTimer(): void;
    triggerIdleDream(): Promise<void>;
}
export {};
