FarmMate AI
Inspiration
Agriculture has always been the backbone of Punjab’s economy. However, many farmers still struggle with limited access to expert guidance, especially in rural regions where literacy and language barriers prevent them from benefiting from modern agricultural knowledge. I was inspired to build FarmMate AI after noticing how difficult it was for farmers to access crop-specific advice in their own language. With the rise of AI models, I realized I could build a multilingual, low-cost tool that delivers farming guidance instantly. My primary goal was to make agricultural knowledge accessible to everyone — especially Urdu-speaking farmers.
What it does
FarmMate AI allows farmers to:
- Ask questions about crops, fertilizers, pests, or weather in Urdu, English, or Punjabi
- Speak instead of typing using Speech-to-Text (STT)
- Hear responses from the AI using Text-to-Speech (TTS) in their language
How we built it
Frontend — React User interface with multilingual text inputs Integrated STT & TTS Communication via Axios Backend — FastAPI Handles question processing Routes input to Google Gemini API Cleans & formats AI responses Integration details .env used for Gemini API keys Axios → POST → http://localhost:8000/ask Response displayed instantly in UI Version Control Git + GitHub for project management Managed branches, merges, and deletions
Challenges we ran into
- Google Gemini API version confusion (v1beta vs v1)
- Fixing CORS issues between React & FastAPI
- Managing .env securely
- Ensuring language consistency in AI responses
- Managing STT and TTS timing
Accomplishments that we're proud of
- Built a fully functional AI farming assistant with multilingual + voice features
- Successfully connected FastAPI backend to Google Gemini API
- Bi-directional communication → voice → AI → voice
- Clean project structure utilizing Git efficiently
- Made AI accessible to farmers in regional languages
- Improved debugging + deployment workflow
What we learned
- Real-world AI integration
- Practical FastAPI + React communication
- Web Speech recognition usage
- Async requests + error handling
- Secure environment configuration
What’s next for FarmMate AI
- Daily market price updates
- Weather forecasting
- Crop-disease image detection (via image upload)
- WhatsApp message automation
- Database for storing user history
Built With
- api
- axios
- fastapi
- gpt-based
- javascript
- python
- react
Log in or sign up for Devpost to join the conversation.