Downloads · 30 days
0
japathak/tirona-distilbert-ner-int8
tirona-distilbert-ner-int8 is a machine learning model from japathak. Use it for the machine learning task on the model card, and read the license before you ship it in a product.
These are the artefacts the Android app downloads for Better name detection. They are not published yet; until they are, the app falls back to HeuristicNameRecogniser and nothing is broken.
Downloads · 30 days
0
Access
Public
Updated Aug 26, 2026
Repo size
65.6 MB
Likes
0
Public
Click a slice to open those files.
.onnx65.6 MB · 100%
From the Hugging Face model README
These are the artefacts the Android app downloads for Better name
detection. They are not published yet; until they are, the app falls back
to HeuristicNameRecogniser and nothing is broken.
Upload these two files so they are reachable at the URLs below, then delete
nothing here — quantise.py is how they were produced and is the only record
of it.
| File | Size | SHA-256 |
|---|---|---|
model.int8.onnx | 65,609,669 | 0b0a5658d5e8205a5da372b7cff40b31b6fc3871e1475bdd3b8dd5f7a79781ff |
vocab.txt | 213,450 | eeaa9875b23b04b4c54ef759d03db9d1ba1554838f8fb26c5d96fa551df93d02 |
Expected URLs, from NerModelDownloader.BASE_URL:
https://tirona.app/models/distilbert-ner-int8/model.int8.onnx
https://tirona.app/models/distilbert-ner-int8/vocab.txt
Hosting them somewhere else (a HuggingFace repo, say) is fine — change
BASE_URL in NerModelDownloader.kt to match. The size and hash are pinned in
that file and verified on download, so a mismatch fails loudly instead of
installing a model that quietly produces different names.
Do not re-quantise and re-upload without updating those pins. The check exists because a swapped model changes transcripts rather than crashing.
dslim/distilbert-NER,
onnx/model.onnx and onnx/vocab.txt.distilbert-base-cased, fine-tuned on
CoNLL-2003 (Reuters newswire).O, B/I-PER, B/I-ORG, B/I-LOC, B/I-MISC. Tirona uses
PER, ORG and LOC — the three schemes macOS asks NLTagger for — and drops
MISC.quantize_dynamic, QuantType.QInt8,
MatMulConstBOnly. 249 MB float32 → 63 MB int8.Upstream publishes only the 249 MB float export, which is not a reasonable
thing to ask for on top of the 630 MB speech model. The one ready-made int8
export found (Xenova/bert-base-NER, 104 MB) declares no licence on its
repo, and "the base model is MIT so it's probably fine" is not a licence
position worth shipping on.
quantise.py re-runs it and checks the int8 model against the float one on
note-like text:
python -m venv venv && ./venv/bin/pip install onnx onnxruntime numpy
curl -L -o model.onnx https://huggingface.co/dslim/distilbert-NER/resolve/main/onnx/model.onnx
./venv/bin/python quantise.py
Result on 2026-08-24: 10/11 samples identical, and the one difference was
int8 being better — it dropped a spurious PER: "-" that float32 emitted on
a bullet list.
The script's WordPiece is deliberately hand-written rather than using
transformers, because WordPiece.kt has to do exactly the same thing and
WordPieceTest pins the Kotlin against these reference values.
It is not strictly better than the capitalisation heuristic. On the same
fixtures it tags RFC and API as ORG and Ship (in a bullet list) as PER.
OnnxNameRecogniser.isPlausibleName keeps the heuristic's rules — no
acronyms, no digits, minimum length — on top of the model's output for exactly
that reason.