Language Model Tokenizers Introduce Unfairness Between Languages

Aleksandar Petrov, Emanuele La Malfa, Philip Torr, Adel Bibi

Recent large language models (LLMs) have demonstrated impressive multilingual capabilities, often performing well in languages they weren't explicitly trained to handle. However, beneath this apparent versatility lies a systemic bias rooted at the very first stage of text processing: tokenization.

Because most tokenizers are heavily optimized for English, the same underlying meaning expressed in other languages can require up to 15 times more tokens to process. This disparity leads to significantly higher costs, slower processing times, and shorter effective memory (context windows) for non-English speakers, raising serious concerns about the equitable access and quality of commercial language services.

The Root of the Problem: The Tokenization Premium

Before an LLM can "read" text, a tokenizer must break that text down into smaller, digestible chunks called tokens—which can be whole words, sub-words, or individual characters. Most state-of-the-art models utilize subword tokenization (such as Byte-Pair Encoding or SentencePiece), where frequently occurring sequences of characters are grouped into a single token to save computational space.

The fundamental issue is that these tokenizers are typically trained on datasets overwhelmingly dominated by English. Consequently, common English words are efficiently assigned their own single tokens. In contrast, common words in other languages—especially those utilizing non-Latin scripts—are fragmented into many tiny, inefficient pieces.

This inefficiency creates a "tokenization premium" that imposes three major penalties on specific language communities:

  1. Cost: Commercial APIs (like OpenAI's) charge users per token. Users querying models in "expensive" languages literally pay more money for the exact same task.
  2. Latency: The computational cost of Transformer models scales with sequence length. More tokens inherently mean slower response times.
  3. Context Window: Models have a strict, fixed limit on how many tokens they can process simultaneously. If a language is highly token-inefficient, the user can provide significantly less background information or context to the model before hitting that limit.

The Cost of Inefficiency: Latency and Context

To systematically evaluate this issue, researchers measured "tokenizer parity"—the ratio of tokenized lengths for equivalent sentences across different languages. Using the FLORES-200 parallel corpus (which contains 2,000 Wikipedia sentences translated into 200 languages), they established a baseline where a premium of 1.0 means parity with English, and a premium of 15.0 means the language requires 15 times as many tokens.

Execution time vs. Tokenization length

As the data shows, processing time scales linearly with tokenization length. A 2x tokenization premium literally means the model takes twice as long to "think." Furthermore, users of languages like Burmese or Dzongkha can effectively provide less than one-tenth of the context to an LLM compared to an English user.

Key Findings and The "Glitch Token" Paradox

The researchers tested a massive array of models, including English-centric models (GPT-2, RoBERTa, GPT-4), targeted non-English models (ArabicBERT, PhoBERT), multilingual models (XLM-R, BLOOM), and byte-level models (ByT5). Their analysis revealed several surprising insights:

  • The "Glitch Token" Paradox: Tokenizers like GPT-2 have dedicated, single tokens for obscure English strings (e.g., BuyableInstoreAndOnline or specific Reddit usernames), yet they lack single tokens for incredibly common words in Arabic or Bulgarian. These languages are forced to be spelled out letter-by-letter or byte-by-byte.
  • Script Complexity Matters: Languages with complex scripts and diacritics suffer the most.
  • Byte-Level is Not a Silver Bullet: Many assume moving to byte-level models (like ByT5) solves the subword vocabulary bias. However, because UTF-8 encoding uses more bytes for non-Latin characters (1 byte for ASCII vs. 3-4 bytes for many Asian scripts), a ~4x disparity persists even without a subword vocabulary.
  • English as the "Universal" Efficiency: Surprisingly, even models specifically trained for other languages (like PhoBERT for Vietnamese) are often more token-efficient at processing English than their own target language. English data is so prevalent in pre-training that it effectively "colonizes" the vocabulary of almost every model.

Key Results: Quantifying the Disparity

The tokenization premium is not a minor statistical anomaly; it is a massive functional disparity that impacts the daily use of LLMs.

Tokenization premiums across models

Looking at state-of-the-art models like GPT-4, the disparity is stark. Compared to English, GPT-4 requires roughly 1.6x more tokens for Italian, 2.6x for Bulgarian, and over 3x for Standard Arabic. For languages with complex scripts like Shan, this premium skyrockets to over 15x. While multilingual models like NLLB (designed specifically for 200 languages) help reduce the gap, they do not eliminate it, still showing premiums of over 2.5x for many languages.

Toward Multilingually Fair Tokenizers

While diagnosing the problem is a crucial first step, the authors acknowledge that retrofitting existing models is difficult. The only true solution is to train future language models from scratch using "multilingually fair" tokenizers.

They propose a two-stage training process for future tokenizers:

  1. Train individual monolingual tokenizers for all target languages to capture their unique morphological structures.
  2. Merge these vocabularies while strictly maintaining parity, ensuring that the most frequent tokens for every language are represented equitably in the final model.

Until the AI community addresses the fundamental "alphabet" of LLMs, the promise of truly equitable, global artificial intelligence will remain unfulfilled.

Summary updated

BibTeX
@inproceedings{petrov2023language,
  author = {Aleksandar Petrov and Emanuele La Malfa and Philip Torr and Adel Bibi},
  title = {{Language Model Tokenizers Introduce Unfairness Between Languages}},
  booktitle = {Advances in Neural Information Processing Systems},
  year = {2023},
  url = {https://openreview.net/forum?id=78yDLKi95p},
}
Figure