View Source ExOpenAI.Components.ChatCompletionStreamResponseDelta (ex_openai.ex v2.0.0-beta2)
A chat completion delta generated by streamed model responses.
Fields
:content- optional -String.t() | any():function_call- optional -{:%{}, [], [{{:optional, [], [:arguments]}, {{:., [], [{:__aliases__, [alias: false], [:String]}, :t]}, [], []}}, {{:optional, [], [:name]}, {{:., [], [{:__aliases__, [alias: false], [:String]}, :t]}, [], []}}]}
Deprecated and replaced bytool_calls. The name and arguments of a function that should be called, as generated by the model.:refusal- optional -String.t() | any():role- optional -:developer | :system | :user | :assistant | :tool
The role of the author of this message.
Allowed values:"developer","system","user","assistant","tool":tool_calls- optional -[ExOpenAI.Components.ChatCompletionMessageToolCallChunk.t()]
Summary
Types
@type t() :: %ExOpenAI.Components.ChatCompletionStreamResponseDelta{ content: (String.t() | any()) | nil, function_call: %{optional(:arguments) => String.t(), optional(:name) => String.t()} | nil, refusal: (String.t() | any()) | nil, role: ((((:developer | :system) | :user) | :assistant) | :tool) | nil, tool_calls: [ExOpenAI.Components.ChatCompletionMessageToolCallChunk.t()] | nil }