Research project · AI and sustainable agriculture
Better crop decisions.
Healthier farming futures.
AgroExpert is being developed to connect crop-health analysis, trustworthy agricultural knowledge and sustainability-aware decision support - so that farmers can understand what is happening in their field and respond with what the situation actually needs.
A research prototype under active development. Nothing here has been field-validated, and it does not give agronomic advice. See current status.

Good advice is specific to a field, a crop, a season and a farmer’s means. Technology should respect that.
Ploughing hillside farmland with a pair of oxen in Nepal. Photo: Mithunkunwar9 (opens in a new tab), CC BY-SA 4.0.
Rooted in Nepal
From the Terai to the Himalaya.
Within a short distance, Nepal’s farmland climbs from subtropical plains to terraced hills and high mountain valleys. The right decision in one belt can be the wrong one in another, which is why AgroExpert treats local context as part of the evidence.

Carrying straw home after the harvest in the Terai, Nepal. Photo: Nirmal Dulal (opens in a new tab), CC BY-SA 4.0. Terai
तराईThe flat, fertile southern plains along the border with India, often called Nepal’s grain basket.
- Typical crops
- Rice, wheat, maize, lentils, mustard and vegetables, often in intensive rice–wheat rotations.
- Decisions that matter
- Fertilizer and pesticide use, irrigation timing, and stress from heat and flooding.

Mustard fields among terraced farmland at Raniban, Gandaki Province, Nepal. Photo: Timothy A. Gonsalves (opens in a new tab), CC BY-SA 4.0. Hills
पहाडTerraced mid-hill slopes and valleys, farmed in small, often rain-fed holdings.
- Typical crops
- Rice on irrigated terraces, maize and millet on drier slopes, vegetables, and fruit.
- Decisions that matter
- Soil erosion on steep terraces, the effort of carrying inputs uphill, and making the most of compost and manure.

Green fields at Kagbeni, Mustang district, in Nepal’s Himalaya. Photo: Mohan K. Duwal (opens in a new tab), CC BY-SA 4.0. Himalaya
हिमालHigh mountain valleys with short growing seasons and cold, dry conditions.
- Typical crops
- Barley, buckwheat and potato, with apples and other fruit in valleys such as Mustang.
- Decisions that matter
- Scarce water and short seasons that leave little room for a wrong decision, and the distance to advice and supplies.
01The problem
The same symptom can have very different causes.
Pale, stunted plants might need nitrogen - or limed soil, better drainage, or nothing at all. Spotted leaves might be a fungal disease, a bacterial one, or sun scorch. When the cause is unclear, it is understandable to apply something “to be safe.”
But an input that does not address the real cause costs money, adds to environmental load and leaves the problem in place. Better information at the moment of decision could change that.

02The approach
Evidence first. Context always. Uncertainty stated.
- 01
Look closely
Start from what the farmer can show: photos checked for quality first, then examined for visible symptoms - or for the text on a product label.
- 02
Ground it in knowledge
Retrieve agronomic guidance, check each claim against it, and cite it. An answer the farmer cannot trace is an answer they should not have to trust.
- 03
Decide with context and care
Weigh the crop, its stage and the plot’s history; prefer prevention and low-risk options; state uncertainty plainly; never invent a dose.
03The platform
Four ways AgroExpert is designed to help.
- 01Quick crop analysisPhotograph a leaf, root, fruit or soil sample and get a possible explanation - with its uncertainty stated plainly.5 of 8 steps implementedRead more about Quick crop analysis
- 02Persistent plot managementEach plot keeps its own story, so the next decision starts with what already happened there.5 of 7 steps implementedRead more about Persistent plot management
- 03Product and document understandingMake the small print on fertilizer, pesticide and seed packaging readable - and keep it separate from advice.0 of 7 steps implementedRead more about Product and document understanding
- 04Sustainability-aware decision supportPresent the full range of responses - prevention, cultural, biological and, when justified, chemical - in context.2 of 6 steps implementedRead more about Sustainability-aware decision support
04The crop lifecycle
Every stage asks a different question.
Example crop · Tomato (transplanted)
Use ← → to move between stages
Stage 05 · First weeks after transplanting
Vegetative growth
Rapid leaf and stem growth. Staking, weeding and nutrient management matter most here, and many foliar problems first appear.
Focus
- Split nutrient applications
- Staking and pruning
- Weed control
- Scouting lower leaves
Watch for
Leaf spots, yellowing patterns, curling, insect presence on leaf undersides.
Where AgroExpert fits: The stage at which a scan is taken is part of the context: the same symptom means different things at different stages.
Timings are rough, typical ranges for a transplanted tomato crop. Actual stages and durations vary with cultivar, season, temperature, location and management - use local guidance for real decisions.
05Responsible intervention
Start broad and preventive. Narrow toward chemicals only when justified.
This is not anti-chemical. Synthetic fertilizers and pesticides have a legitimate place, and organic inputs are not automatically safe or sufficient. The aim is the right intervention: grounded in a diagnosis, matched to the severity, and consistent with local guidance.
- 01PreventionReduce the chance that a problem develops at all.
- 02Cultural practicesChange how the crop is grown to make conditions less favourable for the problem.
- 03Biological optionsUse living organisms or naturally derived products to suppress the problem.
- 04Other targeted measuresPhysical, mechanical or lower-risk products targeted at the problem.
- 05Chemical treatment, when justifiedA registered product applied according to its label when evidence shows it is needed.
Not a rigid sequence - the right choice depends on the diagnosis, severity, crop, location and established guidance.
06How it reasons
From a photograph to a grounded, cautious answer.
Evidence → decision
Image. A farmer photographs the affected plant.
07Architecture
Three independently deployable layers.
- L1Implemented
Mobile app
What the farmer touches. Mobile-first, designed for low-end Android devices and unreliable connectivity.
Expo SDK 56 · React Native 0.85 · TypeScript (strict) · NativeWind · i18n - 9 locales
- L2Implemented
Backend API
The system of record and the only caller of the AI service. Enforces ownership, stores history, runs background jobs.
FastAPI · PostgreSQL + pgvector · Redis · Celery workers · Alembic migrations
- L3In validation
AI service
All model inference, the knowledge base, agent orchestration and evaluation - deployed independently and never called by the app directly.
FastAPI · LangGraph · Qdrant · bge-m3 / bge-reranker-v2-m3 · PaddleOCR · Ollama-served models · MLflow
08Research objectives
Questions worth answering carefully.
- RQ1
Can multimodal evidence improve crop-health assessment compared with image-only or text-only approaches?
- RQ2
Can agricultural retrieval-augmented generation improve the factual grounding and traceability of recommendations?
- RQ3
Can crop, plot and environmental context improve how appropriate a recommendation is?
- RQ4
Can sustainability-aware decision support reduce unnecessary agrochemical recommendations?
- RQ5
Can the system identify feasible, locally appropriate alternatives without compromising responsible crop management?
09Development status
What is built, what is connected, and what is not yet.
Statuses come from reading the code, tests and the services’ own status documents - not from intentions. A folder or a stub never counts as done.
| Component | Detail | Status |
|---|---|---|
| Mobile app (Expo / React Native, TypeScript) Onboarding, phone sign-in, plots, crop timeline, activity and harvest logging, scan capture, chat, weather, notifications, search and settings, localized into nine languages (English, Hindi, Bengali, Gujarati, Kannada, Marathi, Punjabi, Tamil and Telugu). | Onboarding, phone sign-in, plots, crop timeline, activity and harvest logging, scan capture, chat, weather, notifications, search and settings, localized into nine languages (English, Hindi, Bengali, Gujarati, Kannada, Marathi, Punjabi, Tamil and Telugu). | Implemented |
| Backend API (FastAPI modular monolith) Domain modules for identity, farms, plots, crop cycles, timeline, media, analysis, recommendations, chat, knowledge base, weather, notifications, reports and administration, with PostgreSQL + pgvector, Redis and Celery workers. | Domain modules for identity, farms, plots, crop cycles, timeline, media, analysis, recommendations, chat, knowledge base, weather, notifications, reports and administration, with PostgreSQL + pgvector, Redis and Celery workers. | Implemented |
| Backend ↔ AI service The backend’s AI client and the AI service’s endpoints match field for field, and the AI service’s call back into the backend for crop-cycle context was live-verified. The backend still defaults to its mock AI mode in development, so the full farmer-to-AI loop has not been validated end to end. | The backend’s AI client and the AI service’s endpoints match field for field, and the AI service’s call back into the backend for crop-cycle context was live-verified. The backend still defaults to its mock AI mode in development, so the full farmer-to-AI loop has not been validated end to end. | In validation |
| Image validation and quality assessment Classical, deterministic computer vision: format and size validation, blur and lighting checks, moiré-based screen-photo detection and lighting enhancement. | Classical, deterministic computer vision: format and size validation, blur and lighting checks, moiré-based screen-photo detection and lighting enhancement. | Implemented |
| OCR and label extraction PaddleOCR (PP-OCRv5) text extraction, QR/barcode decoding, structured label fields and a vision-model cross-check are implemented in the AI service. No backend or app caller exists yet. | PaddleOCR (PP-OCRv5) text extraction, QR/barcode decoding, structured label fields and a vision-model cross-check are implemented in the AI service. No backend or app caller exists yet. | Partial |
| Retrieval-augmented knowledge base PDF/DOCX ingestion with OCR fallback, cleaning, de-duplication, chunking, bge-m3 hybrid embeddings, Qdrant retrieval, cross-encoder reranking and Redis caching. The corpus is a small seed set, not a reviewed agronomic library. | PDF/DOCX ingestion with OCR fallback, cleaning, de-duplication, chunking, bge-m3 hybrid embeddings, Qdrant retrieval, cross-encoder reranking and Redis caching. The corpus is a small seed set, not a reviewed agronomic library. | Implemented |
| Canary and rollback Cohort assignment, non-regression gates and rollback decisions are implemented as tested logic, but nothing routes live traffic or executes a rollback. | Cohort assignment, non-regression gates and rollback decisions are implemented as tested logic, but nothing routes live traffic or executes a rollback. | Designed |
| Field validation with agricultural experts No pilot, field study or expert review has taken place yet. | No pilot, field study or expert review has taken place yet. | Research direction |
10Technology
Chosen for clarity, not novelty.
Open models that can run locally, a vector store built for hybrid search, and a graph framework that keeps every reasoning step small, inspectable and testable.
- Mobile
- Expo SDK 56
- React Native 0.85
- TypeScript
- 9 locales
- Backend
- FastAPI
- PostgreSQL + pgvector
- Redis
- Celery
- AI service
- LangGraph
- Qdrant
- bge-m3
- bge-reranker-v2-m3
- PaddleOCR
- Ollama
- MLflow
11Roadmap
Engineering is the first half. Validation is the second.
- 01
Product discovery and architecture
Completed
- 02
Mobile frontend
Completed
- 03
Backend and data model
Completed
- 04
AI service and model integration
In progress
- 05
Agricultural knowledge base
In progress
- 06
Safety and evaluation
In progress
- 07
End-to-end integration testing
In validation
- 08
Pilot validation with agricultural experts
Planned
- 09
Sustainability-impact evaluation
Research direction
- 10
Field studies
Research direction
See the reasoning for yourself.
The concept demo walks through four illustrative scenarios step by step - including the ones where the honest answer is “test before you treat.”