Downloads · 30 days
9
3% of all-time downloads
Maxime-Bakunzi/twigane-en-kin-translation
twigane-en-kin-translation is a translation model from Maxime-Bakunzi. Use it when you need text moved from one language to another. The card lists the license as mit.
This is an English to Kinyarwanda translation model fine-tuned from the NLLB (No Language Left Behind) model family. It's specifically optimized for translating English text to Kinyarwanda with high accuracy and cultu…
Downloads · 30 days
9
3% of all-time downloads
All-time downloads
308
Public
Parameters
1.4B
5.5 GB on disk
Likes
1
Trending 1
Click a slice to open those files.
.safetensors5.5 GB · 100%
From the Hugging Face model README
This is an English to Kinyarwanda translation model fine-tuned from the NLLB (No Language Left Behind) model family. It's specifically optimized for translating English text to Kinyarwanda with high accuracy and cultural appropriateness.
from transformers import AutoTokenizer, AutoModelForSeq2SeqLM
tokenizer = AutoTokenizer.from_pretrained("Maxime-Bakunzi/twigane-en-kin-translation")
model = AutoModelForSeq2SeqLM.from_pretrained("Maxime-Bakunzi/twigane-en-kin-translation")
def translate_en_to_rw(text):
inputs = tokenizer(text, return_tensors="pt", padding=True, truncation=True, max_length=512)
outputs = model.generate(**inputs, max_length=512, num_beams=4, early_stopping=True)
translation = tokenizer.decode(outputs[0], skip_special_tokens=True)
return translation
# Example usage
english_text = "Hello, how are you today?"
kinyarwanda_translation = translate_en_to_rw(english_text)
print(kinyarwanda_translation) # Expected: "Muraho, amakuru yawe?"
If you use this model, please cite:
@misc{twigane-translation-model,
author = {Twigane Project},
title = {English to Kinyarwanda Translation Model},
year = {2025},
publisher = {Hugging Face},
url = {https://huggingface.co/Maxime-Bakunzi/twigane-en-kin-translation}
}