#[non_exhaustive]pub struct ToolCallDraft {
pub tool_name: String,
pub arguments: Value,
pub provider_call_id: Option<String>,
}Expand description
A tool call as the model proposed it, before the caller assigns its declaration BlockId. Exactly what the gateway parsed off the wire.
Serializable for logs and tests; the serialized form is not part of the stable set and may change in any release.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.tool_name: StringName of the tool the model asked to invoke.
arguments: ValueTool arguments as a JSON object; validated by the kernel before commit.
provider_call_id: Option<String>Provider-issued identifier for this tool call, if the upstream model
API assigned one. The kernel records it verbatim (on the envelope
BlockMeta) and pairs tool results by the declaration BlockId, never by this field.
ToolCallId remains a borrowed content key for concurrent deduplication.
Implementations§
Trait Implementations§
Source§impl Clone for ToolCallDraft
impl Clone for ToolCallDraft
Source§impl Debug for ToolCallDraft
impl Debug for ToolCallDraft
Source§impl Default for ToolCallDraft
impl Default for ToolCallDraft
Source§impl<'de> Deserialize<'de> for ToolCallDraft
impl<'de> Deserialize<'de> for ToolCallDraft
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 ToolCallDraft
impl Freeze for ToolCallDraft
impl Move for ToolCallDraft
impl RefUnwindSafe for ToolCallDraft
impl Send for ToolCallDraft
impl Sync for ToolCallDraft
impl Unpin for ToolCallDraft
impl UnsafeUnpin for ToolCallDraft
impl UnwindSafe for ToolCallDraft
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