kotoshu/grammar-ru v11
Fully local Russian grammar correction for the weight class (run anywhere, CPU real-time, no network).
- Architecture: GECToR-style token tagger (closed-label vocab) with
iterative apply-and-retag decoding, on a
microsoft/mdeberta-v3-baseencoder, trained bf16 with two-stage differential LR and KEEP-weighted cross-entropy (keep 0.3, stage-1 0.6), three rounds. - Vocab pruning: weight-truth-verified remap β int8 ONNX 457.2 MB.
- Training: 182,031 rows = 112,567 corruption-gold pairs (Wikipedia 20231101.ru base, attested-form swaps) + 69,464 GLM-5.3-Flash-verified corrections (teacher pass over the ru v10 generation pack; exact-restore gate). Training-data provenance: corruption pairs are synthetic derived from the public Wikipedia dump; teacher corrections were machine-generated and exact-restore-filtered.
- Runtime: pure-Ruby tokenization (SpmBpe, fixture-frozen) + ONNX Runtime.
Evaluation (ru held-out gold, 812 pairs, GectorDecoder ROUNDS=4,
MIN_CONFIDENCE=0.0, MARGIN=1.0 β the measured serving law: decoder confidence is anti-correlated with correctness for this encoder, so the zero-confidence gate with the margin rule is the shipped configuration)
| Measure | grammar-ru v11 | previous published-lineage best (v8) |
|---|---|---|
| Precision | 0.856 | 0.708 |
| Recall | 0.139 | 0.134 |
| F0.5 | 0.4216 | 0.3854 |
Parity gate: pruned-ONNX vs torch-fp32 row agreement 1.00 (max abs diff 0.003) over the held-out corpus sample; int8 decode equals the packaged fp32 within the gate tolerance.
License: CC BY-NC-SA 4.0 (model weights). The training corpus derives from the public Wikipedia dump; teacher annotations are machine-generated (GLM-5.3-Flash), exact-restore filtered.
Inference Providers NEW
This model isn't deployed by any Inference Provider. π Ask for provider support