CoolFace
Modelpublic

sinhala-nlp/gemma-4-31B-it-TamSiPara-Ta2Si-en

sourceHugging Facegemmaupdated 2mo agoView on Hugging Face
0likes6downloads
Model Card

gemma-4-31B-it-TamSiPara-Ta2Si-en

A LoRA adapter for Tamil to Sinhala machine translation, trained on the TamSiPara Tamil-Sinhala parallel corpus (Pushpananda et al., 2024) as part of the SinGen Sinhala text generation benchmark.

The adapter is trained on top of google/gemma-4-31B-it using the model's own chat template, with the same instruction wording as the SinGen zero-shot and few-shot prompting runs.

Usage

python
from transformers import AutoProcessor, AutoModelForImageTextToText
from peft import PeftModel

processor = AutoProcessor.from_pretrained("google/gemma-4-31B-it")
model = AutoModelForImageTextToText.from_pretrained("google/gemma-4-31B-it", dtype="auto", device_map="auto")
model = PeftModel.from_pretrained(model, "sinhala-nlp/gemma-4-31B-it-TamSiPara-Ta2Si-en")

(Use AutoTokenizer / AutoModelForCausalLM for text-only checkpoints.)

The model continues from the Translation: prefix inside the assistant turn.

Training

Training pairs21624
Instruction languageen
Epochs3.0
Effective batch size16
Learning rate0.0002
Max sequence length768
LoRA r / alpha / dropout16 / 32 / 0.05
Target moduleslanguage-model linear layers (vision tower excluded)

Evaluation

Held-out tail of TamSiPara (999 sentence pairs), whitespace-tokenized (sacreBLEU's default 13a tokenizer splits Sinhala conjuncts and vowel signs):

MetricScore
Corpus sacreBLEU17.91
Sentence-level BLEU mean9.74

Licence

Derived from Gemma and governed by the Gemma Terms of Use.