import type { Context } from '@deepseek-ai/cordis'; import type { PartnerStore } from '../store.js'; import type { ExecutionRun } from './domain.js'; type CleanupRecord = { version: 1; childId: string; runId: string; ownerCompanionId: string; }; declare module '@deepseek-ai/dsh-session/types' { interface PluginRecordMap { 'plugin:dsh-partner/subagent-cleaned': CleanupRecord; } } /** Delete only a proven partner work log after its result has left the child. Artifacts stay. */ export declare function cleanupWorkSession(ctx: Context, store: PartnerStore, run: ExecutionRun): Promise; /** Track native descendants only when their creation ancestry belongs to a partner. */ export declare class PartnerWorkSessionCleanup { private ctx; private store; private readonly pending; private sweeping?; private closed; private readonly dispose; constructor(ctx: Context, store: PartnerStore); schedule(parent: string | undefined): void; sweep(parent?: string): Promise; private drain; private sweepRuns; close(): void; } export {}; //# sourceMappingURL=session-cleanup.d.ts.map