export interface AgentEvent { type: 'agent-start' | 'output' | 'agent-end' | 'build-complete' | 'phase-complete' | 'input-needed' | 'input-response'; id: string; role?: string; taskId?: string; title?: string; chunk?: string; success?: boolean; promptText?: string; requestId?: string; response?: string; ts: number; } export declare function getLogPath(sessionId: string): string; export declare function clearLog(sessionId: string): void; export declare function writeEvent(sessionId: string, event: Omit): void; export interface LogWatcher { stop(): void; } /** * Watch a session's agent log file for new events. Replays existing events * from the beginning, then polls for new content every 200ms. */ /** * Check whether a session's log file has recent activity, indicating a build * is actively running (not a stale leftover from a crashed build). */ export declare function isLogActive(sessionId: string, staleThresholdMs?: number): boolean; export declare function watchLog(sessionId: string, onEvent: (event: AgentEvent) => void): LogWatcher; /** * Wait for an `input-response` event matching the given requestId. * Polls the log file every 200ms. Times out after `timeoutMs` (default 5 min). */ export declare function waitForResponse(sessionId: string, requestId: string, timeoutMs?: number): Promise; //# sourceMappingURL=agent-log.d.ts.map