An end-to-end, mobile-first platform that helps farmers diagnose crop diseases, get intelligent recommendations, and interact using voice or chat — even in low-connectivity environments.
👉 https://crop-ai-one.vercel.app/
Crop AI is a full-stack, AI-driven agriculture platform designed to assist farmers with:
- 🌱 Plant disease detection from leaf images
- 💬 Conversational AI chat assistant
- 🌾 Crop recommendation & yield prediction
- 🌍 Region-aware agricultural guidance
- 🗣 Multilingual + Speech-based interaction
- 📱 Offline-friendly mobile experience
The project is built as a TurboRepo monorepo, combining mobile, web, backend, and ML services into a single, scalable codebase.
┌──────────────┐
│ Mobile App │ (React Native + Expo)
└──────┬───────┘
│
┌──────────▼─────────┐
│ Backend Server │ (Node.js + Express)
│ Auth • Chat • API │
└──────┬───────┬─────┘
│ │
┌─────────▼───┐ ▼
│ ML Server │ MongoDB
│ (FastAPI) │ (Mongoose)
└─────────────┘
- Conversational assistant powered by Ollama
- Custom tool calling system (not LangChain-based)
- Supports reasoning, structured responses, and agriculture-focused queries
- Designed to later plug into LangChain.js if needed
- Dedicated ML server (FastAPI)
- Image-based disease detection
- Model evolution:
- ResNet9 → ResNet18 → ResNet50 (current)
- Optimized for mobile image inputs
- Multiple classical ML models trained and evaluated
- Speech-to-Text and Text-to-Speech using (On Device using APIopenai/whisper)
- Multilingual support for farmer accessibility
- Clerk for secure, scalable authentication
- Works across mobile
- React Native + Expo
- React + Vite (Web)
- Clerk Authentication
- Node.js + Express
- MongoDB + Mongoose
- Ollama (LLM runtime)
- FastAPI
- PyTorch
- Scikit-learn
- XGBoost
- TurboRepo
- Docker & Docker Compose
- pnpm
Install all project dependencies:
pnpm installIf you face issues with Expo Go:
cd apps/native
pnpm installSet up the ML server:
cd apps/ml-server
uv venv
uv syncOptional setups:
cd apps/server
pnpm install
cd apps/web
pnpm installThis project uses MongoDB with Mongoose.
- Ensure MongoDB is installed and running.
- Update
apps/server/.envwith your MongoDB connection URI.
Get API Keys from
Start the development servers:
pnpm dev- The mobile app can be run via Expo Go.
- Backend API is available at: http://localhost:3000.
crop-ai/
├── apps/
│ ├── native/ # Mobile app (React Native + Expo)
│ ├── ml-server/ # Machine Learning server (FastAPI)
│ ├── server/ # Backend API (Express)
│ └── web/ # Web app (React + Vite)
| Script | Description |
|---|---|
pnpm dev |
Start all applications in development mode |
pnpm build |
Build all applications |
pnpm dev:native |
Start the React Native/Expo development server |
pnpm dev:web |
Start only the web application |
pnpm dev:ml-server |
Start only the ML FastAPI server |
pnpm dev:server |
Start only the backend server |
pnpm check-types |
Check TypeScript types across all apps |
- AI-powered disease detection from leaf images
- Crop Recommendation (XGBoost)
- Crop Yield Prediction (XGBoost)
- RealTime Mandi Market Analysis
- Speech to Text and vice-versa supported
- Multilingual chat assistant for farmers
- Crop and rotation guidance tailored to local regions
- Works offline and on mobile devices
- Easy-to-use mobile applications
Image-based classification
- Backbone: ResNet50
- Input: Leaf images
- Output: Disease class + confidence
Available Models
- Disease Recommendation Models: 3
- Evolution: ResNet9 → ResNet18 → ResNet50