Downloads · 30 days
0
mishbahul11/nerds-nits-indictrans2-en-ur-finetuned-wmt2026
nerds-nits-indictrans2-en-ur-finetuned-wmt2026 is a translation model from mishbahul11. Use it when you need text moved from one language to another. The card lists the license as mit.
This model is a LoRA fine-tuned version of ai4bharat/indictrans2-en-indic-dist-200M, adapted for English↔Urdu translation as part of the NERDS-NITS submission to the WMT 2026 Low-Resource Arabic–Asian Language Transla…
Downloads · 30 days
0
Access
Public
Updated Sep 7, 2026
Repo size
56 MB
Likes
0
Public
Click a slice to open those files.
.safetensors52 MB · 84%
From the Hugging Face model README
This model is a LoRA fine-tuned version of ai4bharat/indictrans2-en-indic-dist-200M, adapted for English↔Urdu translation as part of the NERDS-NITS submission to the WMT 2026 Low-Resource Arabic–Asian Language Translation Shared Task.
This model forms the English↔Urdu leg of the NERDS-NITS pivot-based translation framework:
It is the only IndicTrans2 leg that was fine-tuned in this submission — the English↔Hindi and English↔Bengali legs used pretrained IndicTrans2-200M checkpoints as-is, without fine-tuning, due to compute constraints.
r = 32, α = 64 (α = 2r)ai4bharat/indictrans2-en-indic-dist-200MSeq2SeqTrainer, minimizing sequence-to-sequence cross-entropy losseng_Latn, Urdu — urd_ArabNote: the paper explicitly names the fine-tuned
indictrans2-en-indic-dist-200M(English→Indic) checkpoint for this leg. The correspondingindic-en(Urdu→English) checkpoint used for the Urdu→Arabic direction is not separately confirmed as fine-tuned versus pretrained in the paper — treat the Urdu→English direction of this pipeline as unverified until confirmed against your own training logs.
Direct multilingual translation between Arabic and low-resource Indic languages such as Urdu is constrained by the scarcity of high-quality Arabic–Indic parallel corpora. Since strong dedicated resources exist for both Arabic↔English and English↔Indic translation independently, a pivot architecture was adopted instead of direct fine-tuning. Among the three Indic legs (Hindi, Bengali, Urdu), only the English↔Urdu leg was fine-tuned; the others were left at their pretrained IndicTrans2 checkpoints due to compute constraints.
Limitations:
| Hyperparameter | Value |
|---|---|
| Learning rate | 3e-5 |
| Epochs | 3 |
| Effective batch size | 64 |
| LoRA rank (r) | 32 |
| LoRA alpha (α) | 64 |
| Hardware | Single NVIDIA T4 (16GB VRAM) |
| Precision | fp16 / bf16 mixed precision |
| LR scheduler | Cosine |
| Early stopping | Patience = 2 (on validation loss) |
Fine-tuned on the WMT 2026 Arabic–Urdu-derived English–Urdu parallel data, drawn from the same training split used for the Arabic-Hindi, Arabic-Bangla, and Arabic-Urdu pairs: 20,493 training pairs, with 1,000 dev pairs and 500 devtest pairs.
import torch
from transformers import AutoModelForSeq2SeqLM, AutoTokenizer
from peft import PeftModel
base_model_name = "ai4bharat/indictrans2-en-indic-dist-200M"
adapter_name = "mishbahul11/nerds-nits-indictrans2-en-ur-finetuned-wmt2026"
tokenizer = AutoTokenizer.from_pretrained(adapter_name, trust_remote_code=True)
base_model = AutoModelForSeq2SeqLM.from_pretrained(base_model_name, trust_remote_code=True)
model = PeftModel.from_pretrained(base_model, adapter_name)
# English -> Urdu
inputs = tokenizer("Hello world", src_lang="eng_Latn", tgt_lang="urd_Arab", return_tensors="pt")
generated_tokens = model.generate(
**inputs,
num_beams=5,
max_new_tokens=192,
)
print(tokenizer.batch_decode(generated_tokens, skip_special_tokens=True))
# Example: Arabic -> English (NLLB-600M) -> Urdu (this model)
from transformers import AutoModelForSeq2SeqLM, AutoTokenizer
from peft import PeftModel
ar_en_model_name = "mishbahul11/nerds-nits-nllb600m-ar-en-x-finetuned-wmt2026"
en_ur_base_model_name = "ai4bharat/indictrans2-en-indic-dist-200M"
en_ur_adapter_name = "mishbahul11/nerds-nits-indictrans2-en-ur-finetuned-wmt2026"
# Step 1: Arabic -> English
tokenizer_ar_en = AutoTokenizer.from_pretrained(ar_en_model_name)
model_ar_en = AutoModelForSeq2SeqLM.from_pretrained(ar_en_model_name)
tokenizer_ar_en.src_lang = "arb_Arab"
inputs = tokenizer_ar_en("مرحبا بالعالم", return_tensors="pt")
tokens = model_ar_en.generate(
**inputs,
forced_bos_token_id=tokenizer_ar_en.convert_tokens_to_ids("eng_Latn"),
num_beams=5,
)
english_text = tokenizer_ar_en.batch_decode(tokens, skip_special_tokens=True)[0]
# Step 2: English -> Urdu (this model)
tokenizer_en_ur = AutoTokenizer.from_pretrained(en_ur_adapter_name, trust_remote_code=True)
base_model_en_ur = AutoModelForSeq2SeqLM.from_pretrained(en_ur_base_model_name, trust_remote_code=True)
model_en_ur = PeftModel.from_pretrained(base_model_en_ur, en_ur_adapter_name)
inputs = tokenizer_en_ur(english_text, src_lang="eng_Latn", tgt_lang="urd_Arab", return_tensors="pt")
tokens = model_en_ur.generate(**inputs, num_beams=5, max_new_tokens=192)
urdu_text = tokenizer_en_ur.batch_decode(tokens, skip_special_tokens=True)[0]
# Example: Urdu -> English (this model, indic-en direction) -> Arabic (NLLB-600M)
from transformers import AutoModelForSeq2SeqLM, AutoTokenizer
from peft import PeftModel
ur_en_base_model_name = "ai4bharat/indictrans2-indic-en-dist-200M"
ur_en_adapter_name = "mishbahul11/nerds-nits-indictrans2-en-ur-finetuned-wmt2026" # if fine-tuned indic-en adapter is available
en_ar_model_name = "mishbahul11/nerds-nits-nllb600m-x-en-ar-finetuned-wmt2026"
# Step 1: Urdu -> English
tokenizer_ur_en = AutoTokenizer.from_pretrained(ur_en_adapter_name, trust_remote_code=True)
base_model_ur_en = AutoModelForSeq2SeqLM.from_pretrained(ur_en_base_model_name, trust_remote_code=True)
model_ur_en = PeftModel.from_pretrained(base_model_ur_en, ur_en_adapter_name)
inputs = tokenizer_ur_en("ہیلو دنیا", src_lang="urd_Arab", tgt_lang="eng_Latn", return_tensors="pt")
tokens = model_ur_en.generate(**inputs, num_beams=5, max_new_tokens=192)
english_text = tokenizer_ur_en.batch_decode(tokens, skip_special_tokens=True)[0]
# Step 2: English -> Arabic (NLLB-600M)
tokenizer_en_ar = AutoTokenizer.from_pretrained(en_ar_model_name)
model_en_ar = AutoModelForSeq2SeqLM.from_pretrained(en_ar_model_name)
tokenizer_en_ar.src_lang = "eng_Latn"
inputs = tokenizer_en_ar(english_text, return_tensors="pt")
tokens = model_en_ar.generate(
**inputs,
forced_bos_token_id=tokenizer_en_ar.convert_tokens_to_ids("arb_Arab"),
num_beams=5,
)
arabic_text = tokenizer_en_ar.batch_decode(tokens, skip_special_tokens=True)[0]
This model serves as the English↔Urdu pivot leg; downstream pivot performance for both Arabic→Urdu (via Arabic→English NLLB-600M backbone) and Urdu→Arabic (via English→Arabic NLLB-600M backbone) is reported below.
| Direction | Best System | BLEU | chrF | COMET |
|---|---|---|---|---|
| AR→UR | NLLB + IndicTrans (pivot) | 26.73 | 50.32 | 0.7949 |
| UR→AR | NLLB + IndicTrans (pivot) | 14.91 | 43.27 | 0.8509 |
| Direction | Best System | BLEU | chrF2 | TER | COMET | mBERT |
|---|---|---|---|---|---|---|
| AR→UR | NLLB + IndicTrans (pivot) | 25.3846 | 50.9115 | 65.1215 | 75.1896 | 83.5103 |
| UR→AR | NLLB + IndicTrans (pivot) | 14.1150 | 45.8411 | 76.7996 | 80.5890 | 82.8330 |
Note: challenge test set COMET values are reported by the organizers on a 0–100 scale, while devtest COMET values use the standard 0–1 scale.
NERDS-NITS at WMT 2026: Pivot-Based and Direct Neural Machine Translation for Arabic–Asian Low-Resource Language Pairs
We thank the WMT 2026 shared task organizers for providing the datasets and evaluation infrastructure used in this work.