export type RuntimeExitMarker = { kind: string; code: number | null; signal?: string; message?: string; recordedAt: string; }; export type RuntimeLifecycleState = { runId: string; pid: number; port: number; startedAt: string; buildVersion?: string; buildMode?: string; exit?: RuntimeExitMarker; }; export type UngracefulInference = { shouldReport: boolean; reason: string; }; export declare function resolveRuntimeLifecyclePath(port: number, routeCodexHomeDir?: string): string; export declare function safeReadRuntimeLifecycle(filePath: string): RuntimeLifecycleState | null; export declare function safeWriteRuntimeLifecycle(filePath: string, state: RuntimeLifecycleState): Promise; export declare function safeMarkRuntimeExit(filePath: string, marker: RuntimeExitMarker): Promise; export declare function isPidAliveForForensics(pid: number): boolean; export declare function inferUngracefulPreviousExit(args: { previous: RuntimeLifecycleState | null; currentPid: number; isPidAlive?: (pid: number) => boolean; }): UngracefulInference;