pub struct ScoreAnswer {
pub score: f64,
pub legend: HashMap<String, String>,
pub probabilities: HashMap<String, f64>,
pub confidence: f64,
}Expand description
Answer to a Question::Score.
Fields§
§score: f64Probability-weighted position across the levels; may fall between levels.
legend: HashMap<String, String>Level index (as a string key) → level description.
probabilities: HashMap<String, f64>Level index (as a string key) → probability; sums to 1.
confidence: f64Certainty derived from the shape of probabilities, from 0 to 1.
Trait Implementations§
Source§impl Clone for ScoreAnswer
impl Clone for ScoreAnswer
Source§fn clone(&self) -> ScoreAnswer
fn clone(&self) -> ScoreAnswer
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ScoreAnswer
impl Debug for ScoreAnswer
Source§impl<'de> Deserialize<'de> for ScoreAnswer
impl<'de> Deserialize<'de> for ScoreAnswer
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
Source§impl PartialEq for ScoreAnswer
impl PartialEq for ScoreAnswer
impl StructuralPartialEq for ScoreAnswer
Auto Trait Implementations§
impl Freeze for ScoreAnswer
impl RefUnwindSafe for ScoreAnswer
impl Send for ScoreAnswer
impl Sync for ScoreAnswer
impl Unpin for ScoreAnswer
impl UnsafeUnpin for ScoreAnswer
impl UnwindSafe for ScoreAnswer
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