import { TaskIntrinsicContext } from "./intrinsics/task"; import { ProcessContext, SubprocessSupportMode } from "./types"; export interface ProcessContextInit extends Omit { processId: string; now?: () => Date; /** * Set of PROCESS_LOG sequence numbers already recorded in the journal. * Built from journal PROCESS_LOG events during replay engine init. * Used to deduplicate ctx.log across iterations. */ recordedLogSeqs?: Set; /** When true, breakpoints are auto-approved without human interaction. */ nonInteractive?: boolean; /** Internal-only gate for subprocess orchestration support. */ subprocessSupport?: SubprocessSupportMode; } export interface InternalProcessContext extends TaskIntrinsicContext { processId: string; now: () => Date; /** Counter for ctx.log calls — incremented on each invocation. */ logSeq: number; /** Log seqs already in journal — skipped during replay. */ recordedLogSeqs: Set; /** When true, breakpoints are auto-approved without human interaction. */ nonInteractive: boolean; subprocessSupport: SubprocessSupportMode; cleanupCallbacks: Array<() => void | Promise>; cleanupFlushed: boolean; } export interface CreateProcessContextResult { context: ProcessContext; internalContext: InternalProcessContext; } export declare function createProcessContext(init: ProcessContextInit): CreateProcessContextResult; export declare function flushProcessCleanup(internal: InternalProcessContext, phase: string): Promise; export declare function withProcessContext(internal: InternalProcessContext, fn: () => Promise | T): Promise; export declare function getActiveProcessContext(): InternalProcessContext | undefined; export declare function requireProcessContext(): InternalProcessContext; //# sourceMappingURL=processContext.d.ts.map