/** * Durable prompt scheduler — recurring or one-shot prompts that fire as * synthetic user inputs at turn boundaries (via the input multiplexer). */ export interface ScheduledTask { id: string; prompt: string; /** Seconds between firings. Minimum 60. */ intervalSec: number; /** Recurring tasks re-arm after each firing; one-shots disable. */ recurring: boolean; /** * Durable tasks persist across sessions: if a firing was missed while no * session was running, the next session start fires it once (catch-up). * Non-durable tasks live only as long as the session that created them. */ durable: boolean; createdAt: number; /** Hard expiry — the task stops firing and is pruned after this. */ expiresAt: number; nextFireAt: number; lastFiredAt?: number; firedCount: number; enabled: boolean; /** Session that created the task — owner of non-durable tasks. */ sessionId: string; } export declare const MIN_INTERVAL_SEC = 60; export declare const MAX_LIVE_TASKS = 50; export declare const DEFAULT_TTL_MS: number; /** * Parse "90s" / "5m" / "2h" / "1d" into seconds. Bare numbers are seconds. * Returns null for unparseable input; callers surface usage help. */ export declare function parseInterval(text: string): number | null; export declare function formatInterval(sec: number): string;