pub struct StreamToolCall {
pub index: u32,
pub id: Option<String>,
pub tool_type: Option<String>,
pub function: Option<StreamFunctionCall>,
}Expand description
Streaming tool call fragment.
During streaming, tool calls are sent incrementally across multiple chunks.
The index field identifies which tool call each fragment belongs to.
§Fields
index- Tool call index for reassemblyid- Tool call ID (first chunk only)tool_type- Tool type (first chunk only)function- Function call fragment
Fields§
§index: u32Index to identify which tool call this fragment belongs to
id: Option<String>Tool call ID (only present in the first chunk)
tool_type: Option<String>Tool type (only present in the first chunk)
function: Option<StreamFunctionCall>Function call data (may be partial)
Trait Implementations§
Source§impl Clone for StreamToolCall
impl Clone for StreamToolCall
Source§fn clone(&self) -> StreamToolCall
fn clone(&self) -> StreamToolCall
Returns a duplicate of the value. Read more
1.0.0 · 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 StreamToolCall
impl Debug for StreamToolCall
Source§impl<'de> Deserialize<'de> for StreamToolCall
impl<'de> Deserialize<'de> for StreamToolCall
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
Source§impl PartialEq for StreamToolCall
impl PartialEq for StreamToolCall
Source§impl Serialize for StreamToolCall
impl Serialize for StreamToolCall
impl StructuralPartialEq for StreamToolCall
Auto Trait Implementations§
impl Freeze for StreamToolCall
impl RefUnwindSafe for StreamToolCall
impl Send for StreamToolCall
impl Sync for StreamToolCall
impl Unpin for StreamToolCall
impl UnsafeUnpin for StreamToolCall
impl UnwindSafe for StreamToolCall
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