Gemma 4 E4B - Uzbek <-> English translation LoRA
LoRA adapters for google/gemma-4-E4B-it, trained in stages on Muhammadaziz3101/translate (Uzbek text from the Digital.uz open corpus, English by machine translation).
| Folder | Data | Recommended |
|---|---|---|
stage2-bidir-20k/ | 9,999 pairs in both directions (19,998 examples) | yes, LoRA scale 0.5 |
stage1-uz-en-10k/ | 9,999 UZ->EN pairs only | UZ->EN only |
Training (both stages): QLoRA 4-bit NF4, bf16 compute, LoRA r16 / alpha 32 / dropout 0.05 on language-model attention+MLP, completion-only loss, 1 epoch, eff. batch 16, lr 2e-4 cosine, max 768 tokens, single NVIDIA L4. Stage 2: 1,243 steps, eval loss 1.89 -> 0.660.
FLEURS (345 sentences, greedy, Q4_K_XL base GGUF + LoRA)
Apostrophes normalized (the adapters write official Uzbek orthography with U+02BB/U+02BC, FLEURS references use ASCII).
| Model | UZ->EN chrF / BLEU | EN->UZ chrF / BLEU |
|---|---|---|
| Base Gemma 4 E4B | 59.0 / 31.2 | 55.5 / 17.1 |
| Stage 1 (UZ->EN 10k) | 60.2 / 31.9 | 25.3 / 4.3 |
| Stage 2, scale 1.0 | 60.1 / 32.0 | 52.7 / 15.1 |
| Stage 2, scale 0.5 | 60.5 / 32.5 | 55.7 / 17.1 |
Stage 1 loses EN->UZ (answers in English). Stage 2 at scale 0.5 keeps EN->UZ at base level and gives the best UZ->EN.
Prompts: Translate from Uzbek to English:\n\n<text> and Translate from English to Uzbek:\n\n<text> (Gemma 4 chat template, thinking off).
llama.cpp: llama-server -hf unsloth/gemma-4-E4B-it-GGUF:UD-Q4_K_XL --lora-scaled stage2-bidir-20k/gemma4-e4b-uz-en-bidir-20k-lora-f16.gguf 0.5 --jinja