pub struct Decision {
pub id: String,
pub timestamp: SystemTime,
pub options: Vec<String>,
pub chosen: String,
pub rationale: String,
pub outcome: Option<String>,
pub meta: Value,
}Expand description
A single decision point in an agent run.
The shape is intentionally wide so different agent frameworks can map onto the same record without inventing new schemas.
Fields§
§id: StringStable unique id, used by DecisionLog::set_outcome to find the record.
timestamp: SystemTimeWhen the decision was recorded.
options: Vec<String>Candidate options the model considered at this branch.
chosen: StringThe option the model actually picked. May or may not be in options.
rationale: StringFree or structured text explaining the pick.
outcome: Option<String>Post-hoc observation of what happened. None until
DecisionLog::set_outcome is called.
meta: ValueFree-form metadata. Stored verbatim.
Implementations§
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Decision
impl<'de> Deserialize<'de> for Decision
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
impl StructuralPartialEq for Decision
Auto Trait Implementations§
impl Freeze for Decision
impl RefUnwindSafe for Decision
impl Send for Decision
impl Sync for Decision
impl Unpin for Decision
impl UnsafeUnpin for Decision
impl UnwindSafe for Decision
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