import { type Span } from '@opentelemetry/api';
import type { PlanManager } from '../../manager/plan/lifecycle.js';
import type { RunPersistence } from '../../manager/run/persistence.js';
import type { ActivityStore } from '../../store/activity/memory.js';
import type { Run, RunEvent } from '../../types/run/index.js';
import type { Logger } from '../../utils/logger.js';
import type { EmitEvent } from './events.js';
export interface ResultAssemblerConfig {
    runMgr: RunPersistence;
    planManager: PlanManager;
    activityStore: ActivityStore;
    log: Logger;
    emitEvent: EmitEvent;
    drainPending: () => Generator<RunEvent>;
}
export declare class ResultAssembler {
    private config;
    constructor(config: ResultAssemblerConfig);
    completeRun(rootSpan: Span): AsyncGenerator<RunEvent>;
    completeSession(rootSpan: Span): AsyncGenerator<RunEvent>;
    handleError(err: unknown, rootSpan: Span): AsyncGenerator<RunEvent>;
    finalize(): Promise<Run>;
}
//# sourceMappingURL=result.d.ts.map