import { type AgUiEncodedEvent, type AgUiEncoderState, type AgUiEncoderStateOptions, type AgUiRuntimeStreamEvent } from "./encoder.js"; import type { AgentResponse } from "../types.js"; /** Public API contract for AG-UI chunk encoder bridge. */ export interface AgUiChunkEncoderBridge { encode: (chunk: TChunk) => AgUiEncodedEvent[]; finalize: (response: AgentResponse | null) => AgUiEncodedEvent[]; state: AgUiEncoderState; /** Timing anchor consumed by the response composition root. */ timingState: AgUiEncoderState; } /** Options accepted by create AG-UI chunk encoder bridge. */ export interface CreateAgUiChunkEncoderBridgeOptions { getRuntimeEvents: (chunk: TChunk) => readonly AgUiRuntimeStreamEvent[]; /** * Timing clocks forwarded verbatim to the encoder state. A single object so * that adding a clock is one edit in `AgUiEncoderStateOptions`, not a * sweep through every wrapper that happens to sit in between. */ timing?: AgUiEncoderStateOptions; } /** Create AG-UI chunk encoder bridge. */ export declare function createAgUiChunkEncoderBridge(options: CreateAgUiChunkEncoderBridgeOptions): AgUiChunkEncoderBridge; //# sourceMappingURL=chunk-encoder-bridge.d.ts.map