kotoshu/pos-ur β Urdu POS tagger (CLE tagset)
Urdu part-of-speech tagging weights for the Kotoshu spell checker: a single
ONNX token-classification graph (mdeberta-v3-base, 35 CLE tags, fp16 weight
storage with fp32 compute, 183MB) in the Kotoshu grammar-tagger layout. It is
the model backend of UrPosTagger in the kotoshu gem (>= 1.0.11) and of
Tagger in kotoshu-rs: one label per word, returned for every covered word;
the stable closed classes answer the rest.
Measured (held-out 40 files / 12,952 tokens of the training split)
| measurement | token accuracy | macro-F1 |
|---|---|---|
| training eval | 96.2% | 0.899 |
| serving path through the gem, this package (x86-64) | 96.93% | 0.9015 |
Per-label F1: every tag with at least 190 supporting tokens scores >= 0.87 (NN 0.970, PSP 0.995, VBF 0.976, PU 1.000, JJ 0.932); PRE (13 tokens) and QM (10 tokens) stay at zero. The CLE paper's own auto-tagger figure on the 100K subset is 96.8%.
Recipe
mdeberta-v3-base token classification; labels assigned to every subtoken of a
word during training, first-subtoken prediction per word at serving. 8 epochs,
bf16, cosine schedule with 10% warm-up, best checkpoint by macro-F1. Export:
vocabulary pruned to the 6,999 pieces the serving paths reach, fp16 weight
storage with Cast nodes, ONNX; ORT-vs-PyTorch row agreement 1.0 on the parity
gate (parity.json).
Clause 16(e) gate (measured 2026-12-03)
Run on HF Jobs (cle-pos-16e-fp16) with scripts/license_16e_pos.py
(kotoshu/kotoshu); record retained to 2028-12-03 β PASS:
- Output surface: the graph emits one of the 35 labels per word; text reproduction is structurally impossible (0 reproductions). Token accuracy 98.6% held-in vs 96.6% held-out.
- Membership inference (mean per-word max-softmax, 172 held-in vs 172 held-out rows of the file-stratified split): AUC 0.58 (tolerance 0.60); held-in self-control AUC 0.47; mean confidence 0.9823 vs 0.9822 β the separation is in the distribution's shape rather than its mean, and attack success is 0.77 at a 0.67 false-positive rate, i.e. close to chance.
- Extraction surface: inputs
input_ids+attention_mask, onelogitsoutput, no completion mode. - WordNet leakage: 4,333 glosses checked against the tokenizer assets, 0 verbatim hits.
Training data attribution (Schedule D, verbatim)
This model's training made use of the following licensed linguistic resources:
CLE Urdu Digest Corpus 1M (International Package), Catalogue No. CLE12T003; CLE Urdu WordNet (International Package), Catalogue No. CLE12L001; CLE Urdu Digest IOB Tagged Corpus (International Package), Catalogue No. CLE17T015. Center for Language Engineering, Al-Khawarizmi Institute of Computer Science, University of Engineering and Technology, Lahore, Pakistan.
The weights are a Permitted Derivative Artifact under the CLE β Ribose Linguistic Resource License Agreement (2026-10-29) and Addendum no. 1. The repository ships the graph and its tokenizer assets only β no corpus text, no word lists, no tag-frequency tables, no auto-tagged data. CLE-KICS, UET's name is used only to give credit and not in a way that suggests endorsement.
Serving files
gec-tagger.int8.onnx (the graph; fp16 storage), labels.json (id β tag),
pieces.json + spm.model + charsmap.json + tokenizer.json +
tokenizer_config.json + added_tokens.json + special_tokens_map.json
(the tokenizer), keep_ids.json (original-id β pruned-row mapping),
parity.json, SHA256SUMS.
Ruby: KOTOSHU_UR_POS_MODEL=/path/to/this/directory β PosTagger and
Checker pick the model up for ur (no implicit download). Rust:
Tagger::from_dir on this directory.