pub struct CanonicalMapping {
pub lemma: &'static str,
pub polarity: Polarity,
}Expand description
Canonical mapping for verb synonyms and antonyms.
Maps a verb to its canonical form for semantic normalization. Antonyms are mapped with negative polarity, synonyms with positive. Example: “despise” → (“hate”, Positive), “love” → (“hate”, Negative).
Fields§
§lemma: &'static strThe canonical verb lemma this word maps to.
polarity: PolarityWhether the mapping preserves (Positive) or inverts (Negative) polarity.
Trait Implementations§
Source§impl Clone for CanonicalMapping
impl Clone for CanonicalMapping
Source§fn clone(&self) -> CanonicalMapping
fn clone(&self) -> CanonicalMapping
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 CanonicalMapping
impl Debug for CanonicalMapping
Source§impl PartialEq for CanonicalMapping
impl PartialEq for CanonicalMapping
impl Copy for CanonicalMapping
impl Eq for CanonicalMapping
impl StructuralPartialEq for CanonicalMapping
Auto Trait Implementations§
impl Freeze for CanonicalMapping
impl RefUnwindSafe for CanonicalMapping
impl Send for CanonicalMapping
impl Sync for CanonicalMapping
impl Unpin for CanonicalMapping
impl UnwindSafe for CanonicalMapping
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