Module tokenizers::models::unigram
source · Expand description
Unigram model.
Structs§
- Structure to implement Viterbi algorithm to find the best encoding, or sample from all possible encodings of a given sentence.
- A node from the lattice, that helps reconstruct the underlying
String
- A
Unigram
model to encode sentences. - Iterator to iterate of vocabulary of the model, and their relative score.
- A
UnigramTrainer
can train aUnigram
model fromword_counts
. - Builder for
UnigramTrainer
.
Enums§
- Error type for UnigramTrainerBuilder