An English-to-Kashmiri translation model, fine-tuned from IndicTrans2 En-Indic 200M for the KATHE 2026 English-to-Kashmiri translation challenge organised by Gaash Research Lab, NIT Srinagar, where it placed 3rd.
| Test set | Metric | Score |
|---|---|---|
| KATHE 2026 held-out test set (provided by organisers) | Geometric mean of BLEU and chrF | 15.55 |
pip install transformers sentencepiece IndicTransToolkit
import torch
from transformers import AutoModelForSeq2SeqLM, AutoTokenizer
from IndicTransToolkit.processor import IndicProcessor
repo = "babarzargar/indictrans2-en-kashmiri"
tokenizer = AutoTokenizer.from_pretrained(repo, trust_remote_code=True)
model = AutoModelForSeq2SeqLM.from_pretrained(repo, trust_remote_code=True)
ip = IndicProcessor(inference=True)
sentences = ["The weather in Srinagar is cold today."]
batch = ip.preprocess_batch(sentences, src_lang="eng_Latn", tgt_lang="kas_Arab")
inputs = tokenizer(batch, padding="longest", truncation=True, return_tensors="pt")
with torch.no_grad():
out = model.generate(**inputs, num_beams=5, max_length=256)
decoded = tokenizer.batch_decode(out, skip_special_tokens=True)
print(ip.postprocess_batch(decoded, lang="kas_Arab"))
Kashmiri is a low-resource language, and this model was trained on a small corpus. Expect errors on long sentences, rare vocabulary, and domains unlike the training data. Output has not been human-evaluated.
Built for KATHE 2026 by:
ai4bharat/indictrans2-en-indic-dist-200M