pub struct ChatChunkDelta {
pub role: Option<Role>,
pub content: Option<String>,
pub reasoning_content: Option<String>,
pub refusal: Option<String>,
pub tool_calls: Option<Vec<ChunkToolCall>>,
}Expand description
Streaming chunk delta for a message.
Fields§
§role: Option<Role>Author role if emitted on first chunk.
content: Option<String>Generated text content increment.
reasoning_content: Option<String>Incremental reasoning or thinking tokens emitted by reasoning models.
refusal: Option<String>Incremental refusal message if model refused to answer.
tool_calls: Option<Vec<ChunkToolCall>>Incremental tool calls data.
Trait Implementations§
Source§impl Clone for ChatChunkDelta
impl Clone for ChatChunkDelta
Source§fn clone(&self) -> ChatChunkDelta
fn clone(&self) -> ChatChunkDelta
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ChatChunkDelta
impl Debug for ChatChunkDelta
Source§impl Default for ChatChunkDelta
impl Default for ChatChunkDelta
Source§fn default() -> ChatChunkDelta
fn default() -> ChatChunkDelta
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for ChatChunkDelta
impl<'de> Deserialize<'de> for ChatChunkDelta
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for ChatChunkDelta
Source§impl PartialEq for ChatChunkDelta
impl PartialEq for ChatChunkDelta
Source§impl Serialize for ChatChunkDelta
impl Serialize for ChatChunkDelta
impl StructuralPartialEq for ChatChunkDelta
Auto Trait Implementations§
impl Freeze for ChatChunkDelta
impl RefUnwindSafe for ChatChunkDelta
impl Send for ChatChunkDelta
impl Sync for ChatChunkDelta
impl Unpin for ChatChunkDelta
impl UnsafeUnpin for ChatChunkDelta
impl UnwindSafe for ChatChunkDelta
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more