pub struct Receipt {Show 13 fields
pub run_id: RunId,
pub call_id: String,
pub tool: String,
pub arguments: Value,
pub turn: u32,
pub stage: InvocationStage,
pub status: ReceiptStatus,
pub read_only: bool,
pub duration_ms: u64,
pub reason: Option<String>,
pub details: Value,
pub source: SourceTrust,
pub after_untrusted: bool,
}Expand description
The durable record of one tool call. Every call produces exactly one, refusals included, so “what actually happened” never depends on what the model says happened.
Fields§
§run_id: RunIdThe run that made the call. Sessions continued with
crate::RunState::with_user_message hold receipts of several runs,
and turn numbers restart in each run.
call_id: String§tool: String§arguments: Value§turn: u32§stage: InvocationStage§status: ReceiptStatus§read_only: bool§duration_ms: u64§reason: Option<String>Why it was denied or failed, when known.
details: ValueStructured evidence from crate::ToolOutput::details.
source: SourceTrustWho authored the content this call returned. Kernel-generated text
(refusals, timeouts, cancellations) is Trusted.
after_untrusted: boolThe run had already read untrusted content when this call was made.
Implementations§
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Receipt
impl<'de> Deserialize<'de> for Receipt
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<Receipt, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<Receipt, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Serialize for Receipt
impl Serialize for Receipt
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 Receipt
Auto Trait Implementations§
impl Forget for Receipt
impl Freeze for Receiptwhere
*const u8 is !null: Freeze,
PhantomData<u8>: Freeze,
PhantomData<Value>: Freeze,
*const LeafNode<String, Value> is !null: Freeze,
PhantomData<(Owned, LeafOrInternal)>: Freeze,
PhantomData<Box<(String, Value)>>: Freeze,
impl Move for Receipt
impl RefUnwindSafe for Receipt
impl Send for Receipt
impl Sync for Receipt
impl Unpin for Receipt
impl UnsafeUnpin for Receiptwhere
*const u8 is !null: UnsafeUnpin,
PhantomData<u8>: UnsafeUnpin,
PhantomData<Value>: UnsafeUnpin,
*const LeafNode<String, Value> is !null: UnsafeUnpin,
PhantomData<(Owned, LeafOrInternal)>: UnsafeUnpin,
PhantomData<Box<(String, Value)>>: UnsafeUnpin,
impl UnwindSafe for Receipt
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
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> ⓘ
Converts
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> ⓘ
Converts
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