/** * Tool Stream Registry — Decoupled streaming for tool execution * * Allows tools to emit streaming output without knowing about the visual system. * The agent registers a callback before executing a tool; the tool emits chunks. * * Backpressure: maxToolOutputBytes prevents memory overflow from giant stdout. * * Usage: * registerToolStream(id, (chunk, isError, isFinal) => { ... }) * emitToolStream(id, chunk, isError, isFinal) * unregisterToolStream(id) */ interface StreamCallback { (chunk: string, isError: boolean, isFinal: boolean): void; } export declare function setMaxToolOutputBytes(bytes: number): void; export declare function getMaxToolOutputBytes(): number; export declare function registerToolStream(correlationId: string, callback: StreamCallback): void; export declare function unregisterToolStream(correlationId: string): void; export declare function emitToolStream(correlationId: string, chunk: string, isError?: boolean, isFinal?: boolean): boolean; export declare function hasToolStream(correlationId: string): boolean; export declare function getStreamStats(correlationId: string): { bytesEmitted: number; truncated: boolean; } | null; export {}; //# sourceMappingURL=tool-stream-registry.d.ts.map