Struct tokenizers::pre_tokenizers::digits::Digits
source · #[non_exhaustive]pub struct Digits {
pub individual_digits: bool,
}
Expand description
Pre tokenizes the numbers into single tokens. If individual_digits is set to true, then all digits are splitted into individual tokens.
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.individual_digits: bool
Implementations§
Trait Implementations§
source§impl<'de> Deserialize<'de> for Digits
impl<'de> Deserialize<'de> for Digits
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 From<Digits> for PreTokenizerWrapper
impl From<Digits> for PreTokenizerWrapper
source§impl PartialEq for Digits
impl PartialEq for Digits
source§impl PreTokenizer for Digits
impl PreTokenizer for Digits
fn pre_tokenize(&self, pretokenized: &mut PreTokenizedString) -> Result<()>
impl Eq for Digits
impl StructuralPartialEq for Digits
Auto Trait Implementations§
impl Freeze for Digits
impl RefUnwindSafe for Digits
impl Send for Digits
impl Sync for Digits
impl Unpin for Digits
impl UnwindSafe for Digits
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