/** * In-session scheduler service. A 30s tick checks due tasks and fires them * by enqueueing the prompt into the session's input multiplexer — firings * always land at turn boundaries, never mid-turn. * * Catch-up semantics: on service start, durable tasks whose nextFireAt * passed while no session was running fire once (a slept-through task * fires once, not once per missed interval — see markFired). * * Firing when NO session is running is out of scope here: the launchd * agent hosts the payment proxy, not an agent loop. Durable tasks simply * wait for the next session. */ export interface SchedulerService { stop: () => void; /** Immediate due-check — used by tests and session-start catch-up. */ tick: () => number; } export declare function startSchedulerService(opts: { sessionId: string; enqueue: (text: string) => void; /** Visibility line pushed to the transcript when a task fires. */ notify?: (line: string) => void; }): SchedulerService;