Tokenmaxxing BERT: how skipping ASCII normalization made tokenization 50x faster
tomaarsen · x · 2026-10-15
Hugging Face is reviving its tokenizers library toward v1.0.0: classic BPE tokenizers now encode up to 30x faster than v0.23, but BERT's WordPiece path lagged at 8.6x. Simon Brandeis's new post explains how BERT tokenization got another 5.7x faster — about 50x total (still in PR stage). Benchmarks show bert-base-uncased English encoding jumping from 2.6 to 132 MB/s (50.8x).
Key points:
- BERT-like encoders power embeddings, search/RAG, rerankers and classifiers; the three most-downloaded Hub models all run BERT's normalizer (all-MiniLM-L6-v2 at 218M monthly downloads, ms-marco-MiniLM-L6-v2 at 79M, bge-small-en-v1.5 at 59M).
- Across the top 10,000 Hub models, BPE tokenizers account for 842M monthly downloads and WordPiece 627M — all passing through BERT's normalizer, making normalization the key bottleneck.
- The post details how the tokenizers work, where the implementation was bottlenecked, and includes a browser demo to measure speed before/after the refactor.
Related event: Hugging Face tokenizers v1.0 push: BERT tokenizer gets ~50x faster(7 posts)→
More from Infra
- SpaceX and Nvidia unveil orbital AI supercomputer Kyber Galaxy: 72 chips, first launch 2027 — r0ck3t23 · 2026-12-02
- SpaceX's orbital data centers face a looming space debris threat — krishnan · 2026-12-02
- Nearly a third of WordPress sites run PHP with no security fixes; half by January 1 — JeremyCMorgan · 2026-12-02
- Data center water panic traced to botched numbers: key figure off by 1,000x — ATTlKA · 2026-12-02
- NVIDIA and SpaceX unveil Kyber Galaxy, a space-based AI supercomputer with 72 Rubin GPUs — elonmusk · 2026-12-02
- Export controls may widen US-China AI gap by only 2-3 months, argues analyst — kevinnbass · 2026-12-02