Downloads · 30 days
2
9% of all-time downloads
marlonbino/sw-en-opus-finetuned
sw-en-opus-finetuned is a machine learning model from marlonbino. Use it for the machine learning task on the model card, and read the license before you ship it in a product.
This model is a fine-tuned version of Helsinki-NLP/opus-mt-mul-en on a large corpus of general Swahili-English translations while maintaining helpline translation quality.
Downloads · 30 days
2
9% of all-time downloads
All-time downloads
22
Public
Parameters
77.1M
310 MB on disk
Likes
0
Public
Click a slice to open those files.
.safetensors308 MB · 99%
From the Hugging Face model README
This model is a fine-tuned version of Helsinki-NLP/opus-mt-mul-en on a large corpus of general Swahili-English translations while maintaining helpline translation quality.
<HELPLINE> and <GENERAL> tags| Domain | BLEU | chrF |
|---|---|---|
| Helpline | X.XX | XX.X |
| General | X.XX | XX.X |
(Replace with actual metrics from training)
from transformers import MarianMTModel, MarianTokenizer
# Load model and tokenizer
model_name = "marlonbino/sw-en-opus-finetuned"
tokenizer = MarianTokenizer.from_pretrained(model_name)
model = MarianMTModel.from_pretrained(model_name)
# For general translations
text = "<GENERAL> Habari za asubuhi"
inputs = tokenizer(text, return_tensors="pt", padding=True)
outputs = model.generate(**inputs)
translation = tokenizer.decode(outputs[0], skip_special_tokens=True)
print(translation) # "Good morning"
# For helpline translations
text = "<HELPLINE> Ninahitaji msaada wa haraka"
inputs = tokenizer(text, return_tensors="pt", padding=True)
outputs = model.generate(**inputs)
translation = tokenizer.decode(outputs[0], skip_special_tokens=True)
print(translation) # "I need urgent help"
If you use this model, please cite:
@misc{{sw-en-general-expanded,
author = {{Your Name/Organization}},
title = {{Swahili-English General Domain Translation Model}},
year = {{2025}},
publisher = {{HuggingFace}},
url = {{https://huggingface.co/marlonbino/sw-en-opus-finetuned}}
}}
This model inherits the license from Helsinki-NLP/opus-mt-mul-en.
For questions or issues, please open an issue on the model repository.