Universal Byte-Level Encoding: UTF-8/UTF-16 Routing to Reduce Cross-Script Token-Budget Disparities
TL;DR - Universal Byte-Level Encoding (UBE) routes characters between UTF-8 and UTF-16 representations to reduce multilingual token-count disparities without sacrificing exact decoding or language-model quality. This can provide more usable context and faster prompt processing for scripts that are inefficient under standard UTF-8 byte-level tokenization.
- Uses UTF-8 for 1–2-byte characters and UTF-16 for characters requiring 3–4 UTF-8 bytes.
- Lowers worst-case pre-merge tokenization costs for many Basic Multilingual Plane scripts while preserving efficient English and mixed-script spans.
- Exactly round-trips Unicode scalar values and passes official normalization, grapheme-break, and emoji test suites.
- Matches BBPE language-model quality while reducing token counts most for high-premium scripts in the main multilingual experiments.