import type { ChannelInstrumentationProjection, SessionTraceContext } from "#channel/types.js";
import type { RuntimeSubagentResult } from "#shared/action-types.js";
import type { SessionStateMap } from "#harness/types.js";
import { type ChannelAudience } from "#shared/channel-audience.js";
export interface AgentChildTraceDispatch {
    readonly conversationId?: string;
    readonly originAudience: ChannelAudience;
    readonly parentTraceContext?: SessionTraceContext;
}
export declare function prepareAgentInvocationTrace(input: {
    readonly channelMetadata?: ChannelInstrumentationProjection;
    readonly invocation: {
        readonly callId: string;
        readonly kind: "remote-agent-call" | "subagent-call";
        readonly name: string;
    };
    readonly ownerId: string;
    readonly serializedContext: Record<string, unknown>;
    readonly sessionId: string;
    readonly sessionState?: SessionStateMap;
    readonly startTimeMs: number;
    readonly taskId?: string;
    readonly turnId: string;
}): {
    readonly dispatch: AgentChildTraceDispatch;
    fail(result: RuntimeSubagentResult): Record<string, unknown>;
    readonly serializedContext: Record<string, unknown>;
};
