Logo Lanfrica

Madu39627/Hausa-model

Domaine:

natural language processing

Type de record:

modelsoftware
Créateur:
Mad
Hôte:
# English-Hausa Translation & Learning App A web-based English-Hausa translation and language learning application powered by a fine-tuned NLLB-200 model with LoRA adapters. ## Overview This project combines machine translation with an interactive language-learning experience for Hausa, one of the most widely spoken languages in West Africa. It pairs a fine-tuned neural translation model with a Flask web app offering translation, flashcards, and quizzes — designed to support both casual translation needs and structured language learning. ## Features - **Translate** — Real-time English-Hausa and Hausa-English translation - **Flashcards** — Vocabulary review for common words and phrases - **Quiz** — Interactive quizzes to test retention and comprehension - **Home** — Landing page with app navigation and overview ## Model - **Base model:** Meta's NLLB-200 (No Language Left Behind), fine-tuned for English-Hausa translation - **Fine-tuning method:** PEFT (Parameter-Efficient Fine-Tuning) with LoRA (Low-Rank Adaptation) adapters - **Why LoRA:** Enables efficient fine-tuning of a large multilingual model on a low-resource language pair without the computational cost of full fine-tuning ## Tech Stack - **Backend:** Python, Flask - **ML/NLP:** Hugging Face Transformers, PEFT - **Frontend:** HTML, CSS, JavaScript - **Model storage:** Git LFS ## Project Structure ``` . ├── app.py # Flask application entry point ├── hausa.html # Translate interface ├── index.html # Home page ├── models/ │ └── English-Hausa_NLLB_FT_model/ │ ├── adapter_model.safetensors │ ├── adapter_config.json │ ├── tokenizer.json │ ├── sentencepiece.bpe.model │ └── ... ├── requirements.txt └── .gitattributes # Git LFS tracking rules ``` ## Running Locally 1. **Clone the repository** ```bash git clone github.com cd Hausa-model ``` 2. **Install dependencies** ```bash pip install …