pub struct Output {
pub name: String,
pub value: Value,
pub data_type: String,
pub confidence: Option<f64>,
pub schema_version: String,
}Expand description
Output result from an AI decision point
Represents the result produced by an AI function or model. Outputs can include confidence scores and are captured with type information for analysis and replay.
§Examples
use briefcase_core::models::Output;
use serde_json::json;
let output = Output::new("response", json!("Hello back!"), "string")
.with_confidence(0.95);
assert_eq!(output.confidence, Some(0.95));Fields§
§name: String§value: Value§data_type: String§confidence: Option<f64>§schema_version: StringImplementations§
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Output
impl<'de> Deserialize<'de> for Output
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 Output
Auto Trait Implementations§
impl Freeze for Output
impl RefUnwindSafe for Output
impl Send for Output
impl Sync for Output
impl Unpin for Output
impl UnwindSafe for Output
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