CoolFace
Modelpublic

JamesQuartz/qt-v4.1-64k-ultralingo

sourceHugging Faceapache-2.0updated 4mo agoView on Hugging Face
0likes
Model Card

QT V.4.1 64K UltraLingo — SuperBPE Tokenizer

Quartz Data Infrastructure — [quartz.host](https://quartz.host) | AENEA Global — [aeneaglobal.com](https://aeneaglobal.com)

A 64,000-vocabulary multilingual BPE tokenizer covering 71 languages across 27 scripts, designed for the AENEA Overture model series (500M–2B parameters). Part of the QuartzTokenizer (QT) family.

Key Results

Benchmarked on FLORES-200 (204 languages, 1,012 parallel sentences each):

MetricQT V.4.1 64KLlama 3 (128K)
Vocabulary size64,000128,256
Mean fertility (tokens/word)3.9175.716
Median fertility2.5932.700
Equity ratio (max/min fertility)32.3x118.6x
Total tokens (204 langs)12,979,33016,764,198
Languages won (head-to-head)126/20478/204
Token savings−22.6%baseline

QT V.4.1 64K achieves lower mean fertility with half the vocabulary, 3.7x better cross-lingual equity, and 22.6% fewer total tokens than Llama 3.

Architecture

QT V.4.1 is a two-stage SuperBPE tokenizer with three innovations over standard BPE:

1. Two-Stage SuperBPE Training

  • —Stage 1 (57,600 tokens, 90%): Standard BPE with Llama 3 / GPT-4 style whitespace pre-tokenization. Learns subword units — roots, affixes, morphemes, character sequences.
  • —Stage 2 (6,400 tokens, 10%): SuperBPE — lifts the whitespace boundary constraint, allowing merges to span across word boundaries. Learns high-frequency multi-word superword tokens (e.g., of the, in order to). Sentence boundary protection prevents cross-sentence tokens.

Based on Liu et al., COLM 2025 — "SuperBPE: Space Travel for Language Models" (+4.0% downstream, +8.2% MMLU, −27% inference compute).

2. Script-Aware Pre-Tokenization (Indic Only)

  • —Virama-aware character segmentation for Indic scripts (Devanagari, Bengali, Tamil, Telugu, Kannada, Malayalam, Gujarati, Gurmukhi, Odia, Sinhala)
  • —Preserves conjunct consonants by not breaking across virama (halant) marks
  • —CJK, Thai, Khmer, Myanmar, and Tibetan are left as raw text to enable proper multi-character merge learning

3. Streaming Sharded Training

  • —Corpus sharded to disk for RAM-bounded training
  • —Separate sample ratios and minimum frequencies for Stage 1 and Stage 2
  • —Enables SuperBPE training on consumer hardware (16 GB RAM)

Training Data

Trained on a balanced multilingual corpus (~5 GB target, 0.35 effective sample ratio):

CategoryShareDescription
Wikipedia70.7%71 languages, 27 scripts — sqrt-proportional sampling with 0.3% floor per language
Stack Exchange21.7%English reasoning, STEM, humanities, multilingual Q&A
Code8.0%Python, JavaScript, Java, C/C++, Go/Rust, Shell

Corpus design follows "The Art of Breaking Words" (arXiv 2508.06533) iterative fertility balancing and "One Tokenizer to Rule Them All" script/family bucket approach.

Per-Script Performance

FLORES-200 benchmark — mean tokens per word (lower is better):

ScriptQT V.4.1 64KLlama 3 (128K)Languages
Latin2.292.3937
Arabic2.102.702
Cyrillic2.472.595
Devanagari2.583.523
Hebrew2.455.761
Gurmukhi2.358.231
Armenian2.8612.231
Bengali2.958.071
Sinhala3.0011.371
Tamil3.1612.451
Odia3.2516.901
Gujarati3.2610.021
Georgian3.6515.471
Telugu3.7113.361
Kannada3.7615.011
Ethiopic3.7711.951
Malayalam4.0016.331
Myanmar6.0529.771
Greek2.902.581
Thai11.7414.031
Khmer13.2940.911
CJK18.8019.754
Tibetan33.89149.791
Lao42.9039.601

Special Tokens

14 structural tokens + 71 language tags = 86 special tokens total.

IDTokenPurpose
0`<\padding\>`Padding
1`<\bos\>`Beginning of sequence
2`<\endoftext\>`End of text
3`<\unk\>`Unknown
4`<\sep\>`Separator
5`<\system\>`System prompt
6`<\user\>`User turn
7`<\assistant\>`Assistant turn
8`<\tool_call\>`Tool invocation
9`<\tool_result\>`Tool response
10`<\thinking\>`Thinking open
11`<\/thinking\>`Thinking close
12`<\code\>`Code open
13`<\/code\>`Code close
14–85`<\lang:xx\>`Language tags (71 languages)

Usage

python
from tokenizers import Tokenizer

tok = Tokenizer.from_file("tokenizer.json")

# Encode
encoded = tok.encode("The history of the Roman Empire spans centuries.")
print(encoded.ids)      # Token IDs
print(encoded.tokens)   # Token strings

# Decode
text = tok.decode(encoded.ids)
print(text)

Intended Use

QT V.4.1 64K is designed as the tokenizer for the AENEA Overture model series (500M–2B parameters). It is optimised for:

  • —Multilingual language modelling across 71 languages
  • —Cross-lingual transfer with equitable compression across scripts
  • —Code generation (Python, JavaScript, Java, C/C++, Go, Rust)
  • —Mathematical and scientific text
  • —Instruction-following with dedicated chat tokens

Recommended Pairing

Model SizeTokenizerVocab
Sub-500M (Prelude series)QT V.4.1 32K32,000
500M–2B (Overture series)QT V.4.1 64K (this model)64,000

Training Configuration

Algorithm:            SuperBPE (two-stage)
Stage 1 vocab:        57,600 (90% — subword with whitespace boundaries)
Stage 2 vocab:        6,400 (10% — superword, no whitespace constraint)
Min frequency:        Stage 1: 2, Stage 2: 50
Sample ratio:         Stage 1: 0.35, Stage 2: 0.08
Pre-tokenization:     Script-aware (Indic virama segmentation)
Training mode:        Streaming sharded (500 MB shards)
Seed:                 42
Training time:        ~111 minutes (RTX 4060, 16 GB RAM)

Limitations

  • —Tibetan (33.9 TPW) has improved significantly over previous versions but is still high due to the lack of whitespace delimiters. Future versions will increase the Tibetan corpus weight.
  • —Scripts without whitespace (Thai, Khmer, Tibetan, CJK) inherently require more tokens per word under BPE with whitespace pre-tokenization.
  • —The tokenizer is trained for tokenization quality, not for any specific downstream task. Model performance depends on the language model trained on top.

References

  • —Liu et al., COLM 2025 — "SuperBPE: Space Travel for Language Models"
  • —arXiv 2511.03237 — IndicSuperTokenizer: SOTA fertility on 22 Indic languages
  • —arXiv 2508.06533 — "The Art of Breaking Words": iterative fertility-driven reweighting
  • —Tao et al., NeurIPS 2024 — Scaling Laws with Vocabulary
  • —arXiv 2601.20994 — "The Depth Delusion": width > depth, 32K optimal for sub-500M
  • —NeurIPS 2025 Workshop — "From Bias to Balance": balanced tokenizer datasets
  • —Arnett et al. 2025 — Crosslingual Tokenizer Inequities

Citation

bibtex
@misc{downey2026qt,
  title={QT V.4.1 UltraLingo: A Streaming Script-Aware SuperBPE Tokenizer for Equitable Multilingual Language Modelling},
  author={Downey, James},
  year={2026},
  publisher={AENEA Global Ltd},
  url={https://huggingface.co/JamesQuartz/qt-v4.1-64k-ultralingo}
}

About

Built by James Downey at AENEA Global Ltd (Company No. 16743851, Manchester).

  • —Quartz — Open-source data pipelines and tokenizers (quartz.host)
  • —AENEA — Language model laboratory (aenea.app)
  • —Crassus — Institutional credit intelligence (crassus.info)