Inspiration
The inspiration behind FarmGuard came from the growing challenges in agriculture—farmers facing crop diseases, livestock illnesses, and unsustainable chemical use without accessible, data-driven solutions. With climate change increasing outbreaks, small-scale farmers struggle to diagnose issues early, often relying on expensive or harmful treatments. Inspired by AI advancements and the need for sustainable farming, FarmGuard was created to empower farmers with instant disease detection and eco-friendly solutions, ensuring healthier farms, higher yields, and a greener future ensuring minimal use of chemicals and harmful fertilizers.
What it does
FarmGuard is an AI-powered web app that helps farmers detect diseases in crops and livestock by simply uploading an image. How It Works: 1️⃣ Upload a photo of your plant or animal. 2️⃣ AI detects the disease using advanced image recognition. 3️⃣ Get eco-friendly solutions—organic treatments, natural remedies, and prevention tips.
🌱 For Crops: Detects plant diseases and recommends sustainable treatments (e.g., biological pest control, organic sprays). 🐄 For Livestock: Identifies common animal illnesses and suggests non-invasive, chemical-free care methods.
FarmGuard reduces reliance on harmful chemicals, improves yields, and protects farm health, making sustainable farming easier and smarter! 🌍🚜
How we built it
This web app was made using a combination of Vite, React and Python. Tech Stack:
1️⃣ AI Model:
- Trained on thousands of images of crops and livestock using PyTorch and ResNet-50 for image classification.
- Separate models for plant diseases (model.pth) and animal illnesses (animal_model.pth).
- Deployed on GPU-powered cloud servers for real-time inference.
2️⃣ Backend:
- Flask (Python) handles image processing, model inference, and API requests.
- OpenAI API provides eco-friendly disease management solutions.
- FastAPI (optional upgrade) for high-performance API routing.
3️⃣ Frontend:
- React.js & Vite for a modern, user-friendly UI.
- Simple image upload feature.
- Results displayed instantly with disease info & treatment suggestions.
Challenges we ran into
1️⃣ 📊 Data Collection & Quality
Finding high-quality, diverse images of diseased crops and livestock was difficult. Ensuring balanced datasets to prevent bias in AI predictions.
2️⃣ 🤖 AI Model Accuracy & Performance
Some diseases look similar, causing misclassifications. Required extensive model tuning, augmentation, and retraining for better accuracy. Optimizing inference speed on limited compute resources.
3️⃣ 🌱 Sustainable Treatment Recommendations
Generating reliable, organic solutions for disease management. Ensuring AI-generated recommendations were scientifically valid and not misleading.
Accomplishments that we're proud of
The overall biggest hurdle throughout the development of FarmGuard is definitely the creation and validity of the AI models. With all our members having close to zero experience prior with Machine Learning, it was looking bleak. However, we persevered and were able to come up with not just one but two working and trained AI models to help detect anomalies in plants and animals.
Overall, as a team we can all say that FarmGuard is something that we are all really proud of and definitely something worth the sleepless nights.
What we learned
1️⃣ 🤖 AI Model Training is Iterative
Data quality matters more than data quantity—balancing healthy vs. diseased samples improved accuracy. Fine-tuning ResNet-50 and using data augmentation helped reduce misclassifications.
2️⃣ 🌱 Sustainability Requires Research
AI alone isn’t enough—we needed verified, eco-friendly solutions for disease treatment. Cross-referencing agriculture best practices ensured that recommendations were practical & reliable.
What's next for FarmGuard
1️⃣ 📈 Expanding Disease Detection
Train AI models on more crops & livestock to cover a wider range of diseases. Add early-stage disease detection to help farmers take action sooner.
2️⃣ 📡 Offline & Low-Internet Mode
Develop an offline feature or SMS-based diagnosis for farmers with limited internet access. Lightweight mobile app version for on-the-go disease detection.
3️⃣ 🌍 Regional & Language Support
Translate FarmGuard into multiple languages to reach global farming communities. Customize disease recommendations based on local climate & farming practices.
4️⃣ 🔬 AI-Powered Predictive Analysis
Integrate weather & soil data to predict disease outbreaks before they happen. Use AI to recommend preventive measures based on farm conditions.
5️⃣ 💡 Smart Marketplace for Farmers
Connect farmers to organic treatment suppliers, veterinarians, and agriculture experts. Build a community forum where farmers can share experiences & solutions.
Built With
- flask
- openai
- python
- pytorch
- react
- react-native
- vite
Log in or sign up for Devpost to join the conversation.