pub struct RawStreamingToolCall {
pub id: StreamPartId,
pub tool_id: Option<WireId>,
pub internal_call_id: String,
pub call_id: Option<String>,
pub name: String,
pub arguments: Value,
pub signature: Option<String>,
pub additional_params: Option<Value>,
}Expand description
Describes a streaming tool call response (in its entirety)
Fields§
§id: StreamPartIdAccumulation/reconciliation key of the tool call —
StreamPartId::Wire-derived when the provider supplied an id,
minted when the wire omitted one. A key only; the durable id is
RawStreamingToolCall::tool_id.
tool_id: Option<WireId>The provider-issued tool id, when one exists — the durable handle
that becomes ToolCall::id. Absent
means absent: serializers omit the field, and nothing fabricated can
take its place.
internal_call_id: StringRig-generated unique identifier for this tool call.
call_id: Option<String>Provider-specific call ID used by some APIs for tool result correlation.
name: StringTool/function name.
arguments: ValueParsed tool arguments.
signature: Option<String>Optional provider signature associated with the tool call.
additional_params: Option<Value>Additional provider-specific tool call metadata.
Implementations§
Source§impl RawStreamingToolCall
impl RawStreamingToolCall
Sourcepub fn new(id: impl Into<StreamPartId>, name: String, arguments: Value) -> Self
pub fn new(id: impl Into<StreamPartId>, name: String, arguments: Value) -> Self
Create a complete tool call with a generated internal call ID.
Sourcepub fn with_call_id(self, call_id: String) -> Self
pub fn with_call_id(self, call_id: String) -> Self
Attach a provider-specific call ID.
Sourcepub fn with_signature(self, signature: Option<String>) -> Self
pub fn with_signature(self, signature: Option<String>) -> Self
Attach or clear a provider signature.
Sourcepub fn with_additional_params(self, additional_params: Option<Value>) -> Self
pub fn with_additional_params(self, additional_params: Option<Value>) -> Self
Attach provider-specific metadata.
Trait Implementations§
Source§impl Clone for RawStreamingToolCall
impl Clone for RawStreamingToolCall
Source§fn clone(&self) -> RawStreamingToolCall
fn clone(&self) -> RawStreamingToolCall
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for RawStreamingToolCall
impl Debug for RawStreamingToolCall
Source§impl From<RawStreamingToolCall> for ToolCall
impl From<RawStreamingToolCall> for ToolCall
Source§fn from(tool_call: RawStreamingToolCall) -> Self
fn from(tool_call: RawStreamingToolCall) -> Self
Auto Trait Implementations§
impl Freeze for RawStreamingToolCall
impl RefUnwindSafe for RawStreamingToolCall
impl Send for RawStreamingToolCall
impl Sync for RawStreamingToolCall
impl Unpin for RawStreamingToolCall
impl UnsafeUnpin for RawStreamingToolCall
impl UnwindSafe for RawStreamingToolCall
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more