import { Interrupt, ModelMessage, RunAgentResumeItem, RunStore, StreamChunk, SubagentWireInfo, UIMessage } from '@tanstack/ai';
import { InterruptStore, MessageStore } from './types.js';
/**
 * Card data for a stored child transcript. It rides on the first message, in
 * `metadata.tanstack.subagent`, the same shape the wire uses.
 */
export declare function storedSubagentInfo(messages: ReadonlyArray<ModelMessage>): SubagentWireInfo | undefined;
export declare function createSubagentRunRecorder(stores: {
    messages: MessageStore;
    runs?: RunStore;
    interrupts?: InterruptStore;
    /** Minimum milliseconds between writes while a child streams. */
    intervalMs?: number;
}): {
    start(input: {
        threadId: string;
        runId: string;
        messages: ReadonlyArray<UIMessage | ModelMessage>;
        resume?: ReadonlyArray<RunAgentResumeItem>;
    }): Promise<void>;
    chunk(input: {
        threadId: string;
        runId: string;
        chunk: StreamChunk;
    }): Promise<void>;
    suspend(input: {
        threadId: string;
        runId: string;
        interrupts: ReadonlyArray<Interrupt>;
    }): Promise<void>;
    finish(input: {
        threadId: string;
        runId: string;
    }): Promise<void>;
    abort(input: {
        threadId: string;
        runId: string;
        error?: unknown;
    }): Promise<void>;
};
