A voice first RAG and IR for farmers in Nigeria in Pidgin and Yoruba
# AgriAssist — AI Crop Advisory for Nigerian Farmers 🟢 v1 · Terminal · Working 🟡 v2 · WhatsApp · In Development
AgriAssist is a voice and text-based AI system that gives Nigerian smallholder cassava farmers instant, localised crop disease advice — in their own language, spoken back to them as audio. A farmer can ask why their cassava leaves are turning yellow and receive a spoken response grounded in real agricultural research, tailored to their state's climate and agro-ecological zone.
### Why it matters
Nigeria is the world's largest cassava producer, yet most smallholder farmers have no affordable access to agronomists. Crop disease can wipe out an entire harvest before help arrives. AgriAssist bridges that gap — it works with voice (no typing required), supports Nigerian Pidgin and local languages, and gives grounded advice backed by a knowledge base rather than hallucinated recommendations.
---
## Demo
> Coming soon — link will be added here when deployed.
To run locally, see How to Run below.
### Versions
**v1 (current)** — Terminal-based. Ask questions interactively via the command line or send audio files through the full pipeline. Designed for testing and evaluation of the core pipeline.
**v2 (planned)** — WhatsApp integration. Farmers will be able to send voice notes directly via WhatsApp and receive spoken advisory responses — no app download required.
---
## Agent Architecture (LangGraph)
The core advisory pipeline runs as a LangGraph state machine. Each node receives the full `AgriAssistState` and returns updated fields only.
```
Farmer's Question
│
▼
┌─────────────────────┐
│ classify_query │ Classifies into: disease_diagnosis /
│ (agent.py) │ pest_management / farming_advice /
└──────────┬──────────┘ variety_selection / post_harvest / general
│
▼
┌─────────────────────┐
│ enrich_query │ Attaches: Nigerian state, agro-ecological
│ (agent.py) │ zone, season (wet/dry), climate data
└──────────┬───────── …