Kusaal ↔ English translation (NLLB-200-distilled-600M fine-tune)
Author: Prince Nasamu Alhassan · GhanaNLP · University of Ghana, Legon
A Kusaal (kus) ↔ English sentence translator, fine-tuned from facebook/nllb-200-distilled-600M. Both directions are in one model. It is a translation model, not a general language model: it does not follow instructions, answer questions or hold a conversation.
Corrected November 2026. Earlier versions of this card described the wrong training data and compute and had no usage instructions.
⚠️ How to use it (mandatory — plain src_lang silently fails)
kus_Latn was added as a new token (id 256204). With transformers 5.x, tokenizer.src_lang = "kus_Latn" does not raise an error: it silently encodes your input with the eng_Latn prefix, so Kusaal is read as English and translations quietly degrade. Build the language prefix by hand:
import json, torch
from transformers import AutoTokenizer, AutoModelForSeq2SeqLM
from huggingface_hub import hf_hub_download
MODEL_ID = "PrinceAlhassanNasamu/kusaal-nllb-600M"
tokenizer = AutoTokenizer.from_pretrained(MODEL_ID)
model = AutoModelForSeq2SeqLM.from_pretrained(MODEL_ID).eval()
lang_codes = json.load(open(hf_hub_download(MODEL_ID, "kusaal_lang_codes.json")))
# {"kus_Latn": 256204, "eng_Latn": 256047}
EOS = tokenizer.eos_token_id # 2
def translate(text, direction="kus-eng", num_beams=4):
src_id = lang_codes["kus_Latn" if direction == "kus-eng" else "eng_Latn"]
tgt_id = lang_codes["eng_Latn" if direction == "kus-eng" else "kus_Latn"]
ids = tokenizer(text.strip(), add_special_tokens=False, return_tensors="pt")["input_ids"]
ids = torch.cat([torch.tensor([[src_id]]), ids, torch.tensor([[EOS]])], dim=1)
with torch.no_grad():
out = model.generate(ids, attention_mask=torch.ones_like(ids),
forced_bos_token_id=tgt_id, decoder_start_token_id=EOS,
max_new_tokens=192, num_beams=num_beams)
return tokenizer.decode(out[0], skip_special_tokens=True).strip()
print(translate("Laafi bɛ?", "kus-eng"))
Sanity check: the first token id of an encoded Kusaal source must be 256204. The sibling model tekyerema-nllb600m-v1 registers the codes as special tokens, so the standard src_lang API works there.
Input conventions: Ghana (Agolle) spelling with ɛ ɔ ʋ ŋ; apostrophes written as the straight ' (U+0027) — fold ꞌ (U+A78C), ’, ʼ to ' first. The model was trained on single sentences up to 192 tokens; split long text into sentences.
Training
| Base | facebook/nllb-200-distilled-600M, kus_Latn added as one new token |
| June 2026 | Continued fine-tuning on the 34,568-pair kusaal-english-parallel-corpus (train split 27,724, of which 1,979 are machine back-translated; 62.7% of the corpus is Bible text). Original training code not recovered. |
| August 2026 (current weights) | 4,000 steps from the June checkpoint on 86,683 examples: 12,159 Wikipedia pairs × 2 directions (24,318) + the 27,724 June training rows × 2 directions (55,448) + a 6,917-sentence back-translation pool (eng→kus only). LR 3e-5 linear, 250 warm-up, effective batch 32, max length 192, Adafactor, fp16, best checkpoint by validation loss. Kaggle T4 (one GPU), 139.7 min. |
| Wikipedia data | 13,659 sentence pairs mined from Kusaal and English Wikipedia (github.com/NasamuAlhassan/kusaal-mt, CC BY-SA 4.0); 1,000 frozen as the test benchmark and 500 as validation. |
The "Dagbani-seeded embedding" claim made on earlier cards is unverified: NLLB has no dag_Latn token and the seeding code was not recovered. It is not claimed here.
Results (beam 4, n = 1,000 sentences per cell, sacreBLEU defaults / chrF++ word_order=2)
| Test set | Direction | Before Aug. fine-tune | Current weights |
|---|---|---|---|
| Kusaal Wikipedia Benchmark | kus→eng | 42.17 / 59.92 | 47.73 / 64.09 |
| same | eng→kus | 19.43 / 43.58 | 32.26 / 54.09 |
Original test set (1,000-row sample of the 1,956-row test.csv) | kus→eng | 31.12 / 49.78 | 30.59 / 50.11 |
| same | eng→kus | 19.96 / 42.32 | 20.21 / 42.96 |
(BLEU / chrF++.) The older figures BLEU 27.57 / 13.72 published on earlier versions of this card were computed under a different decoding setup on 200 validation rows; do not compare them with the table above.
Independent re-evaluation on broader test sets (November 2026 audit harness)
Same model weights, beam 4, sacreBLEU with the signature logged (test sets built from sources outside the training data wherever possible; per-set results with signatures are kept in the maintainer's audit records and will be published with the evaluation suite). The benchmark reproduces the table above (47.77 / 31.60 BLEU), which validates the harness.
| Test set | n | kus→eng BLEU / chrF++ | eng→kus BLEU / chrF++ |
|---|---|---|---|
| Wikipedia benchmark | 1,000 | 47.77 / 64.10 | 31.60 / 53.99 |
Original in-house test (full test.csv) | 1,956 | 32.00 / 50.08 | 20.06 / 42.75 |
| GhanaNLP everyday sentences | 600 | 22.18 / 42.42 | 14.85 / 37.60 |
| Multi-domain (proverbs, dictionary examples, grammar examples, UI strings, folk-song lines; mixed Ghana/Burkina spelling) | 600 | 5.59 / 20.70 | 3.57 / 18.75 |
| Numbers and names (Wikipedia-derived) | 398 | 43.49 / 61.72 | 27.81 / 49.71 |
| Robustness (same text typed without special letters, with typos, in the other orthography) | 2,754 | 26.73 / 42.39 | — |
| Paragraphs (3–10 sentences) translated directly | 100 | 4.22 / 22.87 | 1.89 / 17.83 |
| Same paragraphs, split into sentences and rejoined | 100 | 52.80 / 70.29 | 37.72 / 60.69 |
What this shows: performance is strong on Wikipedia-style and Bible-style text and drops sharply on other registers (the multi-domain set includes Toende/Burkina-orthography proverbs and dictionary examples, which this Agolle-trained model was not tuned for, so part of that gap is dialect). Do not feed it paragraphs: split into sentences first. The paragraph and numbers sets are built from Wikipedia sentences that overlap the training split, so their absolute values are inflated; the direct-versus-split comparison on the same set remains valid. Digit preservation (share of references with digits whose digits survive) ranged from 40% to 93% across sets and directions (lowest on the original in-house test, 40–46%); always verify numbers.
Read these caveats before quoting any number
- The benchmark is easier than real text and partly seen. It was mined with machine-translation assistance, so it favours sentences MT handles well; and 246–277 rows of the training Wikipedia split near-match benchmark items (114 share the exact English sentence). Absolute benchmark scores are optimistic, especially eng→kus. Same-data deltas are the reliable signal.
- No significance tests were run; the changes on the original test set (−0.53 to +0.25 BLEU) are within sampling noise.
- Contaminated external benchmarks. About 62% of NSANKU's 1,000 kus→eng Bible verses appear in this model's June training data, so NSANKU scores for it are not clean.
- Scores measure n-gram overlap, not understanding, and there has been no native-speaker evaluation yet.
Known weaknesses
- Register: roughly half the training signal is scripture; everyday conversational Kusaal is the weakest area.
- The pronoun
ois gender-neutral in Kusaal, but the model tends to translate it as "he" even when context indicates a woman. (tekyerema-nllb600m-v1passes this probe.) - Numbers: in an independent head-to-head, 17–37% of reference sentences containing digits lost or changed a number; check amounts, dates and phone numbers.
- Heavily over-segmented Kusaal (NLLB's tokenizer never saw it); sentences only, not paragraphs.
- Synthetic back-translated English in 6,917 + 1,979 training pairs introduces noise.
Licence
Declared licence: CC BY-NC 4.0 (unchanged). Reasons to treat it as non-commercial: the training data includes Bible text whose redistribution rights are unresolved (GILLBT/FCBH-family sources), the GhanaNLP-derived rows have contradictory upstream licence wording, and the Wikipedia pairs are CC BY-SA 4.0. An earlier version of this card attributed the licence to the terms of a compute grant; that rationale does not apply to the August fine-tune, which ran on Kaggle. The label is retained pending a rights review.
Related
- Data:
kusaal-english-parallel-corpus,kusaal-wikipedia-benchmark, github.com/NasamuAlhassan/kusaal-mt - Demo: Space
kusaal-mt - Sibling MT:
tekyerema-nllb600m-v1 - Speech:
kusaal-whisper-small-lora,tekyerema-asr-ctc-kus-v2,tekyerema-tts-kus,kusaal-asr-dataset
Citation
@misc{alhassan2026kusaal,
author = {Alhassan, Prince Nasamu},
title = {Kusaal-English Machine Translation: An Open Model and Corpus},
year = {2026},
publisher = {HuggingFace},
url = {https://huggingface.co/PrinceAlhassanNasamu/kusaal-nllb-600M}
}
Research work, not a supported product.