Run this model with HF Jobs
Run TriusAI/TriusLD-32k on Hugging Face's managed compute, monitor its progress, and retrieve the results when it's done.
Paste one of these prompts into your coding agent:
Fine-tune on my dataset
Use HF Jobs to fine-tune https://huggingface.co/TriusAI/TriusLD-32k. Ask me which dataset to train on, then push the fine-tuned model to a new model repo. Run `hf jobs --help` first to learn the CLI.
Run batch inference
Use HF Jobs to run batch inference with https://huggingface.co/TriusAI/TriusLD-32k on the inputs in a mounted HF Bucket. Ask me which Bucket to use, then write the outputs back to it and keep each input ID. Run `hf jobs --help` first to learn the CLI.
Instructions to use TriusAI/TriusLD-32k with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use TriusAI/TriusLD-32k with Transformers:
# pip install -U transformers accelerate # Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("TriusAI/TriusLD-32k", device_map="auto") - Notebooks
- Google Colab
- Kaggle
TriusLD 32k
Trius's Little Dictionary, 32k build β a byte-level BPE tokenizer with 32,750 tokens and native coverage of 19 writing systems across 58 languages.
Part of the TriusLD family. The larger build is at https://huggingface.co/TriusAI/TriusLD.
DO NOTE THAT while the vocabulary of TriusLD-32k is fully included in TriusLD, their token IDs are not the same, and one must convert data tokenized in TriusLD-32k to ones in TriusLD:
vocab65 = json.load(open("tokenizer_out/tokenizer.json"))["model"]["vocab"]
vocab32 = json.load(open("tokenizer_out_32k/tokenizer.json"))["model"]["vocab"]
id32_to_id65 = {i: vocab65[t] for t, i in vocab32.items()}
| Vocabulary | 32,750 (256 bytes + 14 special + 32,483 merges) |
| Type | byte-level BPE, NFC normalisation |
| Scripts | Latin, Cyrillic, Greek, Hebrew, Arabic, Thai, Devanagari, Bengali, Tamil, Telugu, Malayalam, Gujarati, Kannada, Odia, Gurmukhi, Sinhala, Han, Kana, Hangul |
| Languages | 58 |
Special tokens:
<|pad|> <|bos|> <|eos|> <|unk|> <|system|>
<|user|> <|assistant|> <|end|> <|fim_prefix|> <|fim_middle|>
<|fim_suffix|> <|tool_call|> <|tool_result|> <|image|>
Usage
from transformers import AutoTokenizer
tok = AutoTokenizer.from_pretrained("TriusAI/TriusLD-32k")
ids = tok("The quick brown fox β ζζ·ηζ£θ²ηηΈ β λΉ λ₯Έ κ°μ μ¬μ°")
print(tok.decode(ids["input_ids"]))
Without transformers:
from tokenizers import Tokenizer
tok = Tokenizer.from_file("tokenizer.json")
print(tok.encode("Hello, δΈη!").tokens)
Behaviour
- Lossless. The 256-token byte alphabet means any UTF-8 input encodes and decodes exactly, including scripts this vocabulary was not trained on.
- NFC is applied for you. Composed and decomposed forms of the same text produce the same ids. NFKC is deliberately not used: it would fold fullwidth punctuation and ligatures and destroy information.
- No automatic BOS/EOS. Add them explicitly;
<|bos|>and<|eos|>exist but are not inserted byencode. - Chinese, both standards. Simplified and Traditional are distinct code
points rather than normalisation variants, and both inventories are carried.
The card's
languagefield can only hold an ISO 639 code, so it sayszh; the tables below list the two separately. add_prefix_space=False, matching training; decoding is exact.
Compression
Tokens per character on held-out text, lower is better.
| family | tpc |
|---|---|
| Latin | 0.337 |
| Cyrillic | 0.506 |
| Arabic script | 0.543 |
| Indic | 0.851 |
| CJK | 0.793 |
| Greek + Hebrew | 0.625 |
| Thai | 0.675 |
Selected languages:
| language | tpc | language | tpc |
|---|---|---|---|
| English | 0.292 | Hindi | 0.678 |
| Vietnamese | 0.303 | Japanese | 0.739 |
| Spanish | 0.312 | Chinese (S) | 0.777 |
| German | 0.330 | Bengali | 0.829 |
| Russian | 0.473 | Korean | 0.791 |
| Arabic | 0.552 | Tamil | 0.836 |
| Hebrew | 0.633 | Chinese (T) | 0.866 |
Average over all 58 languages: 0.576; weighted by a rough web mix: 0.467.
Against other tokenizers
The same held-out text, encoded by the tokenizers of several well-known models. "Average" is the unweighted mean over 58 languages; "web-weighted" applies a rough share of web text (English 40%, CJK 18%, Indic 13%, and so on).
| tokenizer | vocab | average | web-weighted |
|---|---|---|---|
| this build | 32,750 | 0.576 | 0.467 |
| GPT-2 | 50,257 | 1.264 | 0.859 |
| cl100k (GPT-4) | 100,277 | 0.842 | 0.564 |
| Llama 3 | 128,256 | 0.699 | 0.446 |
| Qwen3 | 151,643 | 0.675 | 0.443 |
| o200k (GPT-4o) | 200,019 | 0.394 | 0.338 |
| Gemma 3 | 262,144 | 0.392 | 0.319 |
How it was built
Per-script BPE trained with explicit quotas, then composed by a
dependency-respecting union; the top characters of each script are forced to be
single tokens by a coverage pass. The quota table for this build is in
profiles/32k.json.
Limitations
- The Indic scripts keep their character inventories but very few word merges, so they run at about one token per character against roughly 0.7 for a 200k-token vocabulary. They are usable, not competitive.
- Chinese has enough characters for both standards at one token per character but few bigrams, so word-level compression is well behind the larger build.
- Korean uses the 1,900 most frequent Hangul syllables plus jamo; the remaining syllables compose at two or three tokens.
- Any character outside the inventory costs two or three byte-level tokens.
- Code is served by the Latin inventory: adequate, not tuned.
Training data: FineWeb (English) and FineWeb-2 (everything else). No training text is redistributed here; this repository contains only tokenizer statistics β a vocabulary and a list of merge pairs.
Licence
Apache License 2.0. Copyright 2026 TriusAI. The full text is in LICENSE, and
a NOTICE file records the data provenance.
A tokenizer's merges are frequency statistics over text rather than a copy of it,
and no source text is redistributed here. The training data β FineWeb and
FineWeb-2, both published under ODC-By 1.0 β is credited in NOTICE, because the
debt is real even where the law is silent.
Citation
@misc{triusld32k2026,
title = {TriusLD 32k: a compact multilingual byte-level BPE tokenizer},
author = {TriusAI},
year = {2026},
howpublished = {\url{https://huggingface.co/TriusAI/TriusLD-32k}}
}