Precision agriculture decision support system. Analyses soil nutrient levels, predicts crop yield with uncertainty quantification, and prescribes exact fertiliser quantities — all backed by 244,000+ global soil samples and real-time market data.
- Soil analysis — Assesses N, P, K, Ca, Mg, pH, organic carbon and gives an overall quality score
- Yield prediction — Monte Carlo forecasting using Liebig's Law (limiting factor) with 90% confidence intervals
- Fertiliser recommendations — Exact product quantities (DAP, Urea, MOP) with cost and ROI
- Regional benchmarking — Compares your soil against 49k real African + 195k global reference samples
- Risk assessment — Probability statements ("82% chance of positive ROI") with LOW/MODERATE/HIGH tiers
Soil test results or GPS coordinates
↓
Nutrient analysis + quality scoring
↓
Monte Carlo yield prediction (1000 simulations, 90% CI)
↓
Fertiliser prescription + ROI calculation
↓
PDF report for farmer
| Source | Coverage | Size |
|---|---|---|
| iSDA Africa | 49,225 field samples with measured nutrients | 10 MB |
| WoSIS Global | 195,000+ modelled samples worldwide | 14 MB |
| SoilGrids API | 250m resolution soil properties (ISRIC) | Live |
| Open-Meteo | Weather forecasts and soil moisture | Live |
| FAO GIEWS | Crop price data | Live |
| World Bank | Fertiliser commodity prices | Live |
pip install -r requirements.txt
python web.pyOpen http://127.0.0.1:8080.
- Backend: Flask, pandas, numpy, scipy
- Frontend: HTML/CSS/JS, Leaflet.js maps
- ML: Random forest benchmarking, Liebig's Law yield model, Monte Carlo uncertainty
- Reports: fpdf for PDF generation
MIT