Tokenization

Wiki chapters and blog posts about Tokenization.

Wiki

Tokenizers and Embeddings: BPE, Vocabulary Size and the Embedding Table

An LLM only processes integers: a tokenizer splits text into tokens with a subword algorithm such as BPE and maps them to ids, then each id is looked up in a vocabulary-size by hidden-size embedding table. Vocabulary size trades off sequence length, parameters and long-tail coverage.

Beginner 33 min read

Blog posts

Topics