pub struct ToolExecutionRecord {Show 21 fields
pub call_id: String,
pub requested_name: String,
pub canonical_id: String,
pub source: ToolCallSource,
pub arguments: Value,
pub executed_arguments: Value,
pub policy_version: u64,
pub registry_version: u64,
pub runtime_config_version: u64,
pub executed: bool,
pub success: bool,
pub output: String,
pub metadata: HashMap<String, Value>,
pub policy: ToolPolicyDecisionRecord,
pub approval: Option<ToolApprovalRecord>,
pub started_at: DateTime<Utc>,
pub duration_ms: u64,
pub timed_out: bool,
pub cancelled: bool,
pub cancellation_reason: Option<String>,
pub output_truncated: bool,
}Expand description
Structured internal result for a tool request.
Fields§
§call_id: StringStable call ID copied from the request.
requested_name: StringOriginal name, display name, or alias requested by the caller.
canonical_id: StringCanonical registry ID used for policy and evidence.
source: ToolCallSourceRuntime path that requested this call.
arguments: ValueOriginal call arguments.
executed_arguments: ValueArguments actually used after approval changes.
policy_version: u64Policy snapshot version used for the decision.
registry_version: u64Registry snapshot version used for canonical resolution.
runtime_config_version: u64Runtime-control snapshot version used for execution.
executed: boolTrue only when the tool implementation was invoked.
success: boolTrue when the model-facing result is successful.
output: StringModel-facing output or structured error text.
metadata: HashMap<String, Value>Preserved tool metadata and executor annotations.
policy: ToolPolicyDecisionRecordPermission decision for this call.
approval: Option<ToolApprovalRecord>Approval evidence when approval was checked.
started_at: DateTime<Utc>Start timestamp for observability and eval evidence.
duration_ms: u64Wall-clock duration in milliseconds.
timed_out: boolTrue when execution exceeded the configured timeout.
cancelled: boolTrue when execution was cancelled by runtime control.
cancellation_reason: Option<String>Human-readable cancellation reason.
output_truncated: boolTrue when model-facing output was truncated.
Implementations§
Source§impl ToolExecutionRecord
impl ToolExecutionRecord
Sourcepub fn model_output_value(&self) -> Value
pub fn model_output_value(&self) -> Value
Returns the value that should be appended to model-visible tool history.
Sourcepub fn model_output_string(&self) -> String
pub fn model_output_string(&self) -> String
Returns the string form delivered to existing runtime callers.
Trait Implementations§
Source§impl Clone for ToolExecutionRecord
impl Clone for ToolExecutionRecord
Source§fn clone(&self) -> ToolExecutionRecord
fn clone(&self) -> ToolExecutionRecord
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 ToolExecutionRecord
impl Debug for ToolExecutionRecord
Source§impl<'de> Deserialize<'de> for ToolExecutionRecord
impl<'de> Deserialize<'de> for ToolExecutionRecord
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<ToolExecutionRecord, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<ToolExecutionRecord, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Source§impl Serialize for ToolExecutionRecord
impl Serialize for ToolExecutionRecord
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,
Auto Trait Implementations§
impl Freeze for ToolExecutionRecord
impl RefUnwindSafe for ToolExecutionRecord
impl Send for ToolExecutionRecord
impl Sync for ToolExecutionRecord
impl Unpin for ToolExecutionRecord
impl UnsafeUnpin for ToolExecutionRecord
impl UnwindSafe for ToolExecutionRecord
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,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
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