pub enum ResponseBlock {
Text {
delta: String,
},
Thinking {
delta: String,
},
ToolUse {
tool_call_id: ToolCallId,
name: String,
input: Value,
},
}Expand description
Re-exports of the v2 wire types per ADR 0015. v2 is shipped as
part of inferd-client 0.2 so consumers building against v2 can
reach the proto types without a separate inferd-proto dep.
One streaming-output payload carried inside a frame response.
Variants:
Text { delta }— incremental token text. MultipleTextframes per request are normal; concatenating theirdeltas yields the full response text.Thinking { delta }— incremental reasoning-trace text. The daemon separates content emitted between Gemma 4’s<|think|>and<|/think|>tokens into this variant so middleware can choose to display, hide, or log it independently.ToolUse { ... }— a complete tool-call request from the model. Arrives whole, not streamed. Following aToolUseblock, the stream typically terminates withDone { stop_reason: ToolUse }.
Variants§
Text
Incremental user-visible text.
Thinking
Incremental reasoning-trace text.
ToolUse
Complete model-emitted tool-call request.
Trait Implementations§
Source§impl Clone for ResponseBlock
impl Clone for ResponseBlock
Source§fn clone(&self) -> ResponseBlock
fn clone(&self) -> ResponseBlock
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 ResponseBlock
impl Debug for ResponseBlock
Source§impl<'de> Deserialize<'de> for ResponseBlock
impl<'de> Deserialize<'de> for ResponseBlock
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<ResponseBlock, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<ResponseBlock, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for ResponseBlock
impl PartialEq for ResponseBlock
Source§fn eq(&self, other: &ResponseBlock) -> bool
fn eq(&self, other: &ResponseBlock) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl Serialize for ResponseBlock
impl Serialize for ResponseBlock
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
impl StructuralPartialEq for ResponseBlock
Auto Trait Implementations§
impl Freeze for ResponseBlock
impl RefUnwindSafe for ResponseBlock
impl Send for ResponseBlock
impl Sync for ResponseBlock
impl Unpin for ResponseBlock
impl UnsafeUnpin for ResponseBlock
impl UnwindSafe for ResponseBlock
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