Anuvaad-Large

Anuvaad ("translation" in Sanskrit/Hindi) is a family of English↔Hindi translation models built via GRPO reinforcement learning fine-tuning. Anuvaad-Large is fine-tuned from google/gemma-4-E4B-it, and is the best-performing model in the family — both in absolute terms and relative to its own base model.

Why GRPO instead of supervised fine-tuning

Earlier attempts to improve Hindi translation quality via standard supervised fine-tuning (multiple rounds, capped and full-dataset variants) consistently caused catastrophic forgetting — Hindi quality regressed relative to the untouched base model in every SFT variant tried. GRPO's KL-divergence penalty against the reference (base) model directly constrains how far the policy can drift while still optimizing for reward, which SFT has no equivalent of. This is the first approach that improved both translation directions simultaneously, with zero regression relative to base — and Anuvaad-Large shows the cleanest, most consistent improvement curve of any model or method tried in its development.

Training details

  • Base model: google/gemma-4-E4B-it
  • Method: GRPO (via TRL's GRPOTrainer), LoRA adapters (r=16, alpha=16, scoped to the text-decoder attention/MLP layers only)
  • Reward function: chrF++ (sacrebleu, word_order=2) between each sampled completion and the reference translation
  • Dataset: approx. 88.9M sentence pairs (44.4M English→Hindi + 44.4M Hindi→English), derived from BPCC, sampled via reservoir sampling from the full uncapped corpus
  • Hyperparameters: learning_rate=1e-5, beta=0.04 (KL penalty coefficient), temperature=0.8, top_p=0.95, num_generations=32, max_completion_length=256
  • Hardware: 4x H200 GPUs (SkyPilot-managed), DDP with ddp_find_unused_parameters=True (the base model's vision/audio towers are unused for this text-only task)
  • Training extent: this checkpoint represents approx. 11,500 real cumulative optimizer steps into GRPO training. Unlike the smaller Anuvaad-Small (which plateaued after approx. 2,500 steps), this model showed a steady, near-monotonic climb across all four benchmark/direction combinations with no plateau observed, alongside a much lower and more stable KL divergence (approx. 0.15-0.25 vs. Anuvaad-Small's 0.6-0.9) throughout training.

Prompt format

Uses the standard Gemma-4 chat template with a system + user turn:

System: You are a professional machine translation system. Your sole purpose is to translate
text accurately from one language to another.

CRITICAL INSTRUCTIONS:
1. Output ONLY the translation of the provided text.
2. Do NOT include any explanations, notes, alternatives, or commentary.
3. Do NOT include phrases like "Here is the translation:", "Translation:", or similar prefixes.
4. Do NOT include any meta-commentary about the translation quality or choices.
5. Do NOT wrap the translation in quotes or any formatting.
6. Preserve the original formatting, punctuation style, and structure.
7. If the source text is a single sentence, output only a single translated sentence.
8. Begin your response directly with the translated text.

User: Translate the following text to {Hindi|English}:

{source_text}

Benchmark results (chrF++)

Evaluated on FLORES-200 devtest (approx. 1,012 sentence pairs) and IN22-Gen (approx. 1,024 sentence pairs), both directions, greedy decoding.

English → Hindi

Rank Model FLORES IN22-Gen
1 Bodhan-ai/indic-translate 57.63 55.29
2 Sarvam-Translate 57.21 56.43
3 Anuvaad-Large (this model) 56.76 54.13
4 Anuvaad-Small 56.12 53.45
5 Base google/gemma-4-E4B-it 55.48 53.80
6 Base google/gemma-4-E2B-it 54.89 50.39

Hindi → English

Rank Model FLORES IN22-Gen
1 Bodhan-ai/indic-translate 65.50 64.01
2 Anuvaad-Large (this model) 64.68 63.55
3 Base google/gemma-4-E4B-it 63.75 62.83
4 Anuvaad-Small 62.97 61.57
5 Base google/gemma-4-E2B-it 61.78 60.24
6 Sarvam-Translate 55.45 56.03

Summary: this model beats its own base (google/gemma-4-E4B-it) on every single benchmark/direction combination (8/8), averaging 98.6% of the Bodhan-ai/indic-translate reference score — a dedicated, purpose-built translation model — across both benchmarks and directions, and comes within 0.7% of it on IN22-Gen Hindi→English specifically.

Limitations

  • Only Hindi↔English translation is supported; other Indic languages are not covered.
  • Trained and evaluated on formal/written register text (news, government documents); performance on informal or code-mixed text is untested.
  • Training was stopped at approx. 11,500 steps (a small fraction of one full epoch over the 88.9M-pair dataset) while the model was still actively improving — further training may yield additional gains, but was not pursued further.

Usage

from transformers import AutoTokenizer, Gemma4ForConditionalGeneration

model_id = "PVKREDDY0808/Anuvaad-Large"
tok = AutoTokenizer.from_pretrained(model_id)
model = Gemma4ForConditionalGeneration.from_pretrained(model_id, dtype="bfloat16", device_map="cuda")

messages = [
    {"role": "system", "content": "You are a professional machine translation system. Your sole purpose is to translate text accurately from one language to another.\n\nCRITICAL INSTRUCTIONS:\n1. Output ONLY the translation of the provided text.\n2. Do NOT include any explanations, notes, alternatives, or commentary.\n3. Do NOT include phrases like \"Here is the translation:\", \"Translation:\", or similar prefixes.\n4. Do NOT include any meta-commentary about the translation quality or choices.\n5. Do NOT wrap the translation in quotes or any formatting.\n6. Preserve the original formatting, punctuation style, and structure.\n7. If the source text is a single sentence, output only a single translated sentence.\n8. Begin your response directly with the translated text."},
    {"role": "user", "content": "Translate the following text to Hindi:\n\nThe economy grew steadily over the past year."},
]
prompt = tok.apply_chat_template(messages, tokenize=False, add_generation_prompt=True)
inputs = tok(prompt, return_tensors="pt").to(model.device)
out = model.generate(**inputs, max_new_tokens=200, do_sample=False)
print(tok.decode(out[0, inputs.input_ids.shape[1]:], skip_special_tokens=True))
Downloads last month
41
Safetensors
Model size
8B params
Tensor type
BF16
·
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support

Model tree for PVKREDDY0808/Anuvaad-Large

Adapter
(390)
this model