pub enum Delta {
TextDelta {
text: String,
},
ThinkingDelta {
thinking: String,
},
InputJsonDelta {
partial_json: String,
},
ToolCallIdDelta {
id: String,
},
SignatureDelta {
signature: String,
},
ThoughtSignatureDelta {
thought_signature: String,
},
ReasoningStateDelta {
state: OpaqueReasoningState,
},
CitationsDelta {
citation: Value,
},
RefusalDelta {
refusal: String,
},
WebSearchCallDelta {
status: Option<String>,
kind: Option<String>,
action: Option<Value>,
sources: Option<Value>,
page: Option<Value>,
signature: Option<String>,
error: Option<Value>,
},
ServerToolCallsDelta {
steps: Vec<Value>,
},
}Expand description
Delta events emitted during streaming responses.
Variants§
TextDelta
ThinkingDelta
InputJsonDelta
ToolCallIdDelta
SignatureDelta
Anthropic signed-thinking signature delta (#3014); arrives at the end of a thinking block on the native Messages stream.
ThoughtSignatureDelta
ReasoningStateDelta
Opaque Responses reasoning continuity, attached only when the provider returns an encrypted item on the exact originating route.
Fields
§
state: OpaqueReasoningStateCitationsDelta
RefusalDelta
WebSearchCallDelta
Fields
ServerToolCallsDelta
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Delta
impl<'de> Deserialize<'de> for Delta
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
Auto Trait Implementations§
impl Forget for Delta
impl Freeze for Delta
impl Move for Delta
impl RefUnwindSafe for Delta
impl Send for Delta
impl Sync for Delta
impl Unpin for Delta
impl UnsafeUnpin for Delta
impl UnwindSafe for Delta
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