import { type ChatCompletionChunk, type ChatCompletionCreateParamsStreaming } from 'openai/resources/chat/completions'; import { RunnerOptions, type AbstractChatCompletionRunnerEvents } from "./AbstractChatCompletionRunner.js"; import { type ReadableStream } from 'openai/_shims/index'; import { RunnableTools, type BaseFunctionsArgs, type RunnableFunctions } from "./RunnableFunction.js"; import { ChatCompletionSnapshot, ChatCompletionStream } from "./ChatCompletionStream.js"; import OpenAI from 'openai/index'; import { AutoParseableTool } from 'openai/lib/parser'; export interface ChatCompletionStreamEvents extends AbstractChatCompletionRunnerEvents { content: (contentDelta: string, contentSnapshot: string) => void; chunk: (chunk: ChatCompletionChunk, snapshot: ChatCompletionSnapshot) => void; } export type ChatCompletionStreamingFunctionRunnerParams = Omit & { functions: RunnableFunctions; }; export type ChatCompletionStreamingToolRunnerParams = Omit & { tools: RunnableTools | AutoParseableTool[]; }; export declare class ChatCompletionStreamingRunner extends ChatCompletionStream implements AsyncIterable { static fromReadableStream(stream: ReadableStream): ChatCompletionStreamingRunner; /** @deprecated - please use `runTools` instead. */ static runFunctions(client: OpenAI, params: ChatCompletionStreamingFunctionRunnerParams, options?: RunnerOptions): ChatCompletionStreamingRunner; static runTools(client: OpenAI, params: ChatCompletionStreamingToolRunnerParams, options?: RunnerOptions): ChatCompletionStreamingRunner; } //# sourceMappingURL=ChatCompletionStreamingRunner.d.ts.map