CropProphEU
Provides access to NASA POWER data for weather variables (GDD, precipitation, solar radiation, soil moisture) used in crop yield forecasting and risk analysis.
πΎ crop-mcp
EU Crop Intelligence MCP Server β Yield forecasts, market values & risk analysis for 25 EU countries.
Get AI agents to answer: "How will wheat perform in Baden-WΓΌrttemberg this year? What's it worth at current market prices?"
pip install git+https://github.com/DasClown/CropProphEU.git
# or try it on Smithery: https://smithery.ai/servers/crop-mcp/CropProphEUFeatures (10 MCP Tools)
Tool | What it does |
| NEW β Combined yield + market value (β¬/ha) with plain-language summary in German or English (auto-detected via |
| Pan-European yield forecast (3 crops, 25 countries) with Yield-at-Risk |
| Current season status: temperature, rain, soil moisture, drought index |
| Compare this season to historical years |
| All crops for one region in a single call |
| 16-day weather forecast |
| What-if: +2Β°C, -20% rain? |
| Analog-year yield matching (DE-focused) |
| 120 NUTS2 regions |
| Crop parameters (GDD base, season, etc.) |
Quick Start
1. Install
pip install git+https://github.com/DasClown/CropProphEU.git2. Use as MCP Server
via CLI (stdio):
crop-mcpor via Python:
from crop_mcp import predict_europe_yield
result = predict_europe_yield("DE11", "DE", crop="wheat", gdd=3050, precip_mm=650)
print(f"Yield: {result['predicted_yield_t_ha']} t/ha")
print(f"Revenue: ~{result['predicted_yield_t_ha'] * 235:.0f} β¬/ha")3. Claude Desktop / Cursor / Any MCP Client
Add to your MCP config:
{
"mcpServers": {
"crop": {
"command": "python3",
"args": ["-m", "crop_mcp.server"]
}
}
}4. HTTP Server (for Remote Access / Smithery)
pip install crop-mcp[http]
crop-mcp --http --port 8080Connects via SSE: http://your-server:8080/sse
5. Docker
docker build -t crop-mcp .
docker run -p 8080:8080 crop-mcp crop-mcp --http --port 8080Verified Crops
Crop | Eurostat Code | Samples | Countries | MAE (LOYO) |
πΎ Wheat | C1100 | 1,483 | 25 | 11.2% |
π½ Corn (Maize) | C1500 | 1,648 | 20 | 11.6% |
πΏ Barley | C1300 | 1,841 | 25 | 11.3% |
Rapeseed & Sunflower: Not supported β no Eurostat yield data available. Tools reject these with a clear error (no silent hallucinations).
Example Output
German (default):
Weizen β Region DE11 (DE)
Ertrag: 7.68 t/ha (Spanne 6.67β8.63)
...English (with language="en"):
Wheat β Region DE11 (DE)
Yield: 7.68 t/ha (range 6.67β8.63)
Temperature: warm (3050Β°C GDD)
...All output is available in German (default) or English. Set language="en" when calling yield_and_value for English output. The JSON data is always returned in English field names; the summary field adapts to the requested language.
Data Sources
Source | Data | Access |
Eurostat | Crop yields ( | Free, no key |
NASA POWER | GDD, precip, solar, soil moisture | Free, no rate limits |
Open-Meteo | 16-day forecast | Free, no key |
SoilGrids v2 | SOC, pH, N, CEC, texture | Free REST API |
Yahoo Finance | Live CBOT wheat/corn futures + EUR/USD | Free, no key |
Model Accuracy
Metric | Value |
LOYO MAE (Wheat) | 0.598 t/ha (11.2%) |
Forward Validation (Train β€2022, Test 2023-24) | 0.794 t/ha (15.0%) |
RΒ² (LOYO) | 0.877 |
RΒ² (Forward) | 0.628 |
What this means: The LOYO metric is optimistic because it trains on data from all years including future ones. The Forward Validation (train on 2000-2022, predict 2023-2024) is the real-world benchmark: Β±15%.
The model is most accurate for core EU countries (DE, FR, BE, NL, AT, CZ) where training data is dense, and less accurate for outliers like NL/BE 2024 where unusual weather caused systematic overestimation.
Architecture
crop-mcp/
βββ crop_mcp/
β βββ server.py # 10 MCP tools
β βββ europe_model_api.py # Random Forest (200 trees) + Yield-at-Risk
β βββ market_prices.py # Live prices via Yahoo Finance + reference
β βββ core/regions.py # 120 NUTS2 regions
β βββ sources/ # Weather, soil, NDVI data fetchers
βββ models/ # .pkl files (download from Releases)
βββ data/ # Training data (generated by build)
βββ pyproject.toml
βββ README.mdKey design principles:
No hallucination β every yield prediction traces to verified Eurostat data
Live prices β CBOT wheat/corn via Yahoo Finance, updated hourly
Self-updating β monthly cron job rebuilds models with latest Eurostat data
Zero external API keys β all data sources are free and public
Commercialization
The tool is production-ready today for:
Agri-trading desks β "What's wheat worth in Picardie at current MATIF prices?"
Farm advisory β "How does this season compare to the last 5 years?"
Insurance / Risk β Yield-at-Risk (P10/P50/P90) per region
EU policy analysis β Climate scenario impact on national yields
Next commercial features: Market prices per country, historical price correlation, automated PDF reports, multi-year crop rotation planning.
Building & Training
# Build training data for a specific crop (25 min)
python3 build_europe.py --crop corn
# Train the model (2 min)
python3 train_europe_fast.py --crop corn
# Automatic monthly update (cron)
# Runs every 1st of the month at 06:00License
MIT β free to use, modify, and distribute.
Built with β€οΈ for AI agents that need real, verifiable crop intelligence.
This server cannot be installed
Maintenance
Latest Blog Posts
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/DasClown/CropProphEU'
If you have feedback or need assistance with the MCP directory API, please join our Discord server