Larger vocab leads to shorter sequences but more parameters
Image: NOAA Photo Library, Public domain, via Wikimedia Commons
Larger vocab leads to shorter sequences but more parameters
In NLP, a larger vocabulary can reduce the length of sequences needed to express ideas, making models more efficient. However, this efficiency comes at the cost of increased model complexity due to more parameters.
Example
Consider a language model with a 10,000-word vocabulary versus one with 5,000 words. The larger vocabulary model can express the same concepts with fewer words, but it requires more parameters to handle the increased number of possible word combinations.
Remember this
Balancing vocabulary size and model complexity is crucial for efficient NLP systems.
Text adapted from Wikipedia, licensed under CC BY-SA 4.0.
WordPiece tokenization does: similar to BPE but uses likelihood instead of frequency
WordPiece tokenization splits words into subwords based on token likelihood rather than frequency
weight tying does in language models: shares embedding and output projection matrices
Ever wonder how machines understand the sequence of words in a sentence?
384-dim all-MiniLM-L6-v2 optimizes: fast sentence similarity with 6 layers
All-MiniLM-L6-v2 optimizes fast sentence similarity with 6 layers
[CLS] pooling does: uses the first token's embedding as the sentence representation
CLS pooling: uses the first token's embedding as the sentence representation
Unigram tokenization does: starts with large vocabulary and prunes using EM
Unigram tokenization starts with a large vocabulary and prunes using EM
Philosophy of language
Philosophy of language studies language's nature and its relationship with users and the world
Swipe through 100 ML concepts daily
Open Pocket Polymath