--- language: - yo - ha - en license: llama4 base_model: meta-llama/Llama-4-Scout-17B-16E-Instruct tags: - agriculture - nigerian-languages - yoruba - hausa - lora - peft - multilingual - autoscientist - together-ai datasets: - Professor/agronomy-qa-pairs - Professor/naija-agri-dataset-yoruba-hausa --- # Naija Agri LLM — Yoruba & Hausa Agricultural Assistant A LoRA adapter for [Llama 4 Scout 17B 16E Instruct](https://huggingface.co/meta-llama/Llama-4-Scout-17B-16E-Instruct) (109B total parameters, MoE) fine-tuned on Nigerian agricultural Q&A data in Yoruba and Hausa using [AutoScientist by Adaption Labs](https://adaption.ai). Built for the **Adaption Labs AutoScientist Challenge** (Agriculture category, 2026) — powering a crosslingual RAG-based agricultural assistant for Nigerian smallholder farmers. ## What It Does Nigerian farmers and agricultural extension workers can ask questions in **Yoruba**, **Hausa**, or **English** and receive accurate, actionable answers grounded in Nigerian farming context — referencing institutions like IITA, NAERLS, and state ADP offices, and Nigerian crop varieties (cassava, yam, maize, cowpea, cocoa, plantain, tomatoes). This model is the generative backbone of a RAG pipeline that supports crosslingual retrieval: a farmer's question in Yoruba retrieves relevant document chunks, which are passed as context to this model for answer generation in the farmer's language. ## Training | Parameter | Value | |-----------|-------| | Base model | `meta-llama/Llama-4-Scout-17B-16E-Instruct` (109B total params) | | Training infrastructure | Together AI (via AutoScientist) | | Training method | SFT + LoRA | | LoRA rank | 16 | | LoRA alpha | 32 | | LoRA dropout | 0.0 | | Target modules | All linear layers | | Epochs | 2 | | Batch size | Max | | Learning rate | 2e-4 (cosine decay, min ratio 0.1) | | Warmup ratio | 0.05 | | Max grad norm | 1 | | Evaluations | 5 checkpoints | ### Training Metrics | Metric | Value | |--------|-------| | Starting train loss | ~1.93 | | Final train loss | ~0.94 | | AutoScientist Win Rate (adapted) | **64%** | | AutoScientist Win Rate (base) | 36% | The adapted model wins 64 out of 100 head-to-head comparisons against the base Llama 4 Scout on agricultural Q&A in Yoruba and Hausa, per AutoScientist's internal preference evaluation. Train and validation loss converge smoothly with no signs of overfitting across 94 steps. ## Dataset Trained on [`Professor/agronomy-qa-pairs`](https://huggingface.co/datasets/Professor/agronomy-qa-pairs) (~35,900 rows), localized from [KisanVaani/agriculture-qa-english-only](https://huggingface.co/datasets/KisanVaani/agriculture-qa-english-only) using Adaption Labs Data Adaption with a Nigerian context blueprint (IITA, NAERLS, ADP). **Language distribution:** - Yoruba (`yo`): ~30,900 rows - Hausa (`ha`): ~4,600 rows - Nigerian English (`en`): ~360 rows ## Intended Use - Yoruba and Hausa speaking smallholder farmers in Nigeria - Agricultural extension workers providing guidance in local languages - RAG pipelines for crosslingual agricultural document retrieval - Research on multilingual LLM adaptation for low-resource African languages ## Languages This model responds in **Yoruba** (with full tone marks: ọ, ẹ, ṣ, etc.), **Hausa** (standard orthography), and **English**. The English capability comes from both the base model and Nigeria-specific English training rows, so English responses reflect Nigerian agricultural context rather than generic advice. It deflects out-of-scope questions in the user's language. ## Deployment This adapter was trained on Together AI infrastructure. The trained model name on Together AI is `adaption_agronomy_qa_pairs`. It is compatible with Together AI's fine-tuned model serving — the base Llama 4 Scout 17B is hosted on Together AI and can be served with this LoRA. ## Limitations - Fine-tuned on agriculture domain only; will deflect general queries - Hausa coverage is smaller (~13% of training data) — may be less robust than Yoruba - Quality of Yoruba tone marks depends on the localization pipeline used ## License Built on Llama 4 — subject to [Meta's Llama 4 Community License Agreement](https://llama.com/llama4/license).