How spidey6978/neoagrinext works
AgriNext combines an Android farming app with a FastAPI agriculture backend. The principal workflow is farmer input and farm selection, followed by crop recommendations or analysis, then actionable weather, market, satellite, AI, and schedule information presented in the app. The README also describes marketplace and authentication capabilities. Backend excerpts establish several service calls; Android implementation details and some backend wiring were not sampled, so uncertain connections are omitted.
Main entry points: main.py API endpoints · screens Farm screens · earth_engine.py Earth Engine · FarmRepository.kt Farm repository
Components 19
Android app
- Farm screens
app/src/main/java/com/example/agrinext/ui/screens - Farm repository
app/src/main/java/com/example/agrinext/data/FarmRepository.kt - API client
app/src/main/java/com/example/agrinext/data/AgriNextApi.kt
Backend API
- API endpoints
app/main.py - Request and response schemas
app/schemas/input_schema.py
Farm insights
- Crop recommendations
app/services/crop_recommender.py - Weather insights
app/services/weather_service.py - Market analysis
app/services/market_service.py - AI advice
app/services/gemini_service.py - Satellite vegetation
app/services/ndvi_service.py - Crop schedule
app/services/schedule_service.py - Agriculture news
app/services/news_service.py
Data and integrations
- Response cache
app/services/cache_service.py - Earth Engine
app/services/earth_engine.py - Gemini AI
- Weather provider
- Market data sources
- Firebase services
Other components
- Farmer
Connections 19
- Farmer → Farm screens: uses
- Farm screens → Farm repository: requests farm data
- Farm repository → API client: delegates API calls
- API client → API endpoints: sends requests
- API endpoints → Request and response schemas: validates data
- API endpoints → Crop recommendations: requests crops
- API endpoints → Weather insights: gets weather
- API endpoints → Market analysis: gets market analysis
- API endpoints → AI advice: requests advice
- API endpoints → Satellite vegetation: requests satellite data
- API endpoints → Agriculture news: requests news
- Weather insights → Weather provider: fetches conditions
- Market analysis → Market data sources: fetches prices and markets
- AI advice → Gemini AI: generates advice
- Agriculture news → Gemini AI: generates headlines
- Satellite vegetation → Earth Engine: requests imagery
- Earth Engine → Earth Engine: reads Sentinel imagery
- Response cache → Response cache: stores cached data
- Farm screens → Firebase services: uses authentication and database