#[non_exhaustive]pub struct SmartReplyMetrics {
pub allowlist_coverage: f32,
pub top_n_metrics: Vec<TopNMetrics>,
pub conversation_count: i64,
/* private fields */
}Available on crate feature
conversation-models only.Expand description
The evaluation metrics for smart reply model.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.allowlist_coverage: f32Percentage of target participant messages in the evaluation dataset for which similar messages have appeared at least once in the allowlist. Should be [0, 1].
top_n_metrics: Vec<TopNMetrics>Metrics of top n smart replies, sorted by [TopNMetric.n][].
conversation_count: i64Total number of conversations used to generate this metric.
Implementations§
Source§impl SmartReplyMetrics
impl SmartReplyMetrics
pub fn new() -> Self
Sourcepub fn set_allowlist_coverage<T: Into<f32>>(self, v: T) -> Self
pub fn set_allowlist_coverage<T: Into<f32>>(self, v: T) -> Self
Sets the value of allowlist_coverage.
§Example
ⓘ
let x = SmartReplyMetrics::new().set_allowlist_coverage(42.0);Sourcepub fn set_top_n_metrics<T, V>(self, v: T) -> Self
pub fn set_top_n_metrics<T, V>(self, v: T) -> Self
Sets the value of top_n_metrics.
§Example
ⓘ
use google_cloud_dialogflow_v2::model::smart_reply_metrics::TopNMetrics;
let x = SmartReplyMetrics::new()
.set_top_n_metrics([
TopNMetrics::default()/* use setters */,
TopNMetrics::default()/* use (different) setters */,
]);Sourcepub fn set_conversation_count<T: Into<i64>>(self, v: T) -> Self
pub fn set_conversation_count<T: Into<i64>>(self, v: T) -> Self
Sets the value of conversation_count.
§Example
ⓘ
let x = SmartReplyMetrics::new().set_conversation_count(42);Trait Implementations§
Source§impl Clone for SmartReplyMetrics
impl Clone for SmartReplyMetrics
Source§fn clone(&self) -> SmartReplyMetrics
fn clone(&self) -> SmartReplyMetrics
Returns a duplicate of the value. Read more
1.0.0 · 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 SmartReplyMetrics
impl Debug for SmartReplyMetrics
Source§impl Default for SmartReplyMetrics
impl Default for SmartReplyMetrics
Source§fn default() -> SmartReplyMetrics
fn default() -> SmartReplyMetrics
Returns the “default value” for a type. Read more
Source§impl Message for SmartReplyMetrics
impl Message for SmartReplyMetrics
Source§impl PartialEq for SmartReplyMetrics
impl PartialEq for SmartReplyMetrics
impl StructuralPartialEq for SmartReplyMetrics
Auto Trait Implementations§
impl Freeze for SmartReplyMetrics
impl RefUnwindSafe for SmartReplyMetrics
impl Send for SmartReplyMetrics
impl Sync for SmartReplyMetrics
impl Unpin for SmartReplyMetrics
impl UnwindSafe for SmartReplyMetrics
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