pub struct ChoiceAnswer<'a> {
pub choice: &'a str,
pub confidence: f64,
pub probabilities: &'a IndexMap<String, f64>,
pub evidence: &'a [EvidenceSpan],
pub raw: &'a Answer,
}Expand description
Checked choice answer.
Fields§
§choice: &'a strSelected criterion (never optional).
confidence: f64Native confidence.
probabilities: &'a IndexMap<String, f64>Native probabilities.
evidence: &'a [EvidenceSpan]Supporting spans, empty if none were returned.
raw: &'a AnswerOriginal answer, including evidence/extensions.
Trait Implementations§
Source§impl<'a> Clone for ChoiceAnswer<'a>
impl<'a> Clone for ChoiceAnswer<'a>
impl<'a> Copy for ChoiceAnswer<'a>
Auto Trait Implementations§
impl<'a> Freeze for ChoiceAnswer<'a>
impl<'a> RefUnwindSafe for ChoiceAnswer<'a>
impl<'a> Send for ChoiceAnswer<'a>
impl<'a> Sync for ChoiceAnswer<'a>
impl<'a> Unpin for ChoiceAnswer<'a>
impl<'a> UnsafeUnpin for ChoiceAnswer<'a>
impl<'a> UnwindSafe for ChoiceAnswer<'a>
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