Crop-diagnosis and verified-product assistant for Rwandan farmers, with agronomist and admin workspaces.
# AgriCoach
A crop-diagnosis and verified-product assistant for Rwandan farmers, with real agronomist review
and admin management workspaces.
Three separate apps sharing one design system and one client-side data layer:
- **`/farmer/`** — landing, home, a guided crop-check wizard, product verification, and consultation
history. Fully translated (English / Kinyarwanda / French).
- **`/agronomist/`** — a review queue of real farmer submissions the system wasn't confident about,
with case detail and a confirm-and-send-advice workflow.
- **`/admin/`** — a dashboard plus CRUD screens for the crops, symptoms, diagnoses, products, and
retailers that power the farmer app's diagnosis engine, and a Users & Roles screen for
provisioning accounts.
## Architecture
```
index.html role picker (links into the three apps)
farmer/index.html farmer app
agronomist/index.html agronomist app
admin/index.html admin app
shared/
tokens.css design tokens + component classes, responsive
icons.js inline SVG icon set + the AgriCoach logo mark
engine.js normalize / Levenshtein / diagnosis-scoring — generic, scores
against whatever diagnoses the DB currently holds
data.js the shared "database" — a localStorage-backed store (crops,
symptoms, products, retailers, diagnoses, consultations, users)
auth.js salted/hashed login & signup, per-role sessions
i18n.js en/rw/fr translation dictionary + t(key, vars)
```
No backend — `localStorage` is genuinely shared across the three apps because they're served
from the same origin, the same way three tabs of one site would share it. That's enough for one
browser to demonstrate the real cross-role flow (a farmer's submission really does show up in the
agronomist queue, admin's CRUD really does feed the diagnosis engine), but it won't sync across
devices, and the auth here is real client-side hashing/session logic rather than a
server-verified sy …