Skip to content

Krishi Guide is a React Native app that use to recommend the best crops for farmers based on their soil, weather, and environmental data. The goal is to help farmers boost yields and make smarter decisions quickly and easily.๐ŸŒฑ

Notifications You must be signed in to change notification settings

MOHITKOURAV01/Krishi_Guide

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

24 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

KrishiGuide - React Native Mobile App ๐ŸŒพ

A comprehensive farming companion app built with React Native and Expo for the Mobile Application Development (MAD) end-semester project.

Demo_Video_Link

https://drive.google.com/file/d/1_YktUFf91kjLU2BodZJYp2_nq5OoahC4/view?usp=sharing

๐Ÿ“ฑ Overview

KrishiGuide is a bilingual (English/Hindi) mobile application designed to assist farmers with:

  • Crop Recommendations: AI-powered crop suggestions based on soil NPK values, pH, temperature, and rainfall
  • Weather Updates: Real-time weather information with location detection and farming advice
  • Market Prices: Latest commodity prices with search and filter functionality
  • Government Schemes: Information about agricultural schemes with direct application links
  • Profile Management: User authentication, profile editing, and language preferences

โœจ Key Features

๐Ÿ” Authentication

  • User login with email/password
  • Profile creation and management
  • Secure session handling

๐Ÿ  Home Screen

  • Location-based weather summary
  • Quick access cards to all features
  • Personalized greeting with user name
  • Beautiful UI with custom splash screen

๐ŸŒฑ Crop Recommendation

  • Beautiful banner image
  • Input form for soil parameters (N, P, K, pH)
  • Climate data (temperature, rainfall)
  • Multiple crop suggestions with detailed reasoning
  • Visual crop cards with emojis and explanations

๐ŸŒค๏ธ Weather

  • Current location detection using GPS
  • Real-time weather conditions
  • Temperature, humidity, wind speed, visibility
  • Sunrise/sunset times
  • Weather-based farming advice
  • Fallback to mock data when API rate-limited

๐Ÿ’ฐ Market Prices

  • Real-time commodity prices
  • Search functionality
  • Filter by crop category
  • Price trend indicators (up/down)
  • Market location information

๐Ÿ›๏ธ Government Schemes

  • Comprehensive list of schemes
  • Detailed benefits for each scheme
  • "Apply Now" buttons with direct links
  • Beautiful banner image
  • Scrollable content

๐Ÿ‘ค Profile

  • User information display
  • Profile picture upload
  • Edit profile functionality
  • Language toggle (English/Hindi)
  • Settings and preferences
  • Logout functionality

๐Ÿ› ๏ธ Tech Stack

  • Framework: React Native with Expo SDK 54
  • Language: JavaScript (JSX)
  • Navigation: React Navigation (Bottom Tabs)
  • Icons: Expo Vector Icons (Ionicons)
  • Location: expo-location
  • Image Handling: expo-image-picker
  • Styling: React Native StyleSheet
  • State Management: React Context API
  • APIs:
    • OpenWeatherMap for weather data
    • Custom services for crop, market, and scheme data

๐Ÿ“ Project Structure

KrishiGuide/
โ”œโ”€โ”€ app/
โ”‚   โ”œโ”€โ”€ components/          # Reusable UI components
โ”‚   โ”‚   โ”œโ”€โ”€ CommonButton.jsx
โ”‚   โ”‚   โ”œโ”€โ”€ InputField.jsx
โ”‚   โ”‚   โ””โ”€โ”€ WeatherCard.jsx
โ”‚   โ”œโ”€โ”€ context/            # Context providers
โ”‚   โ”‚   โ”œโ”€โ”€ AuthContext.js
โ”‚   โ”‚   โ””โ”€โ”€ LanguageContext.js
โ”‚   โ”œโ”€โ”€ navigation/         # Navigation setup
โ”‚   โ”‚   โ””โ”€โ”€ TabNavigator.jsx
โ”‚   โ”œโ”€โ”€ screens/            # All screen components
โ”‚   โ”‚   โ”œโ”€โ”€ HomeScreen.jsx
โ”‚   โ”‚   โ”œโ”€โ”€ LoginScreen.jsx
โ”‚   โ”‚   โ”œโ”€โ”€ CropRecommendationScreen.jsx
โ”‚   โ”‚   โ”œโ”€โ”€ WeatherScreen.jsx
โ”‚   โ”‚   โ”œโ”€โ”€ MarketPriceScreen.jsx
โ”‚   โ”‚   โ”œโ”€โ”€ GovtSchemesScreen.jsx
โ”‚   โ”‚   โ””โ”€โ”€ ProfileScreen.jsx
โ”‚   โ”œโ”€โ”€ services/           # Business logic and API calls
โ”‚   โ”‚   โ”œโ”€โ”€ cropService.js
โ”‚   โ”‚   โ”œโ”€โ”€ weatherService.js
โ”‚   โ”‚   โ”œโ”€โ”€ marketService.js
โ”‚   โ”‚   โ””โ”€โ”€ schemeService.js
โ”‚   โ””โ”€โ”€ utils/              # Constants and utilities
โ”‚       โ”œโ”€โ”€ constants.js
โ”‚       โ””โ”€โ”€ translations.js
โ”œโ”€โ”€ assets/                 # Images and static files
โ”‚   โ”œโ”€โ”€ crop_banner.png
โ”‚   โ”œโ”€โ”€ govt_banner.png
โ”‚   โ”œโ”€โ”€ splash_logo.png
โ”‚   โ”œโ”€โ”€ login_image.jpg
โ”‚   โ””โ”€โ”€ profile_bg.jpg
โ”œโ”€โ”€ App.js                  # Main app entry point
โ”œโ”€โ”€ app.json               # Expo configuration
โ””โ”€โ”€ package.json           # Dependencies

๐Ÿš€ Getting Started

Prerequisites

  • Node.js (v14 or higher)
  • npm or yarn
  • Expo CLI (npm install -g expo-cli)
  • Expo Go app on your mobile device

Installation

  1. Clone the repository:
git clone https://github.com/MOHITKOURAV01/Krishi_Guide.git
cd Krishi_Guide
  1. Install dependencies:
npm install
  1. Install additional required packages:
npx expo install expo-location expo-image-picker expo-linear-gradient
  1. Start the development server:
npx expo start
  1. Run on your device:
    • Scan the QR code with Expo Go (Android) or Camera app (iOS)
    • Or press a for Android emulator, i for iOS simulator

๐Ÿ“ฆ Dependencies

{
  "expo": "~54.0.0",
  "react": "18.3.1",
  "react-native": "0.76.5",
  "@react-navigation/native": "^6.1.18",
  "@react-navigation/bottom-tabs": "^6.6.1",
  "expo-location": "~18.0.4",
  "expo-image-picker": "~16.0.3",
  "expo-linear-gradient": "~14.0.1",
  "expo-vector-icons": "^14.0.4",
  "react-native-screens": "^4.4.0",
  "react-native-safe-area-context": "^4.14.0"
}

๐ŸŽจ UI/UX Features

  • Bilingual Support: Complete English and Hindi translations
  • Custom Splash Screen: Beautiful branded splash screen
  • Banner Images: Eye-catching banners for Crop and Scheme screens
  • Responsive Design: Optimized for various screen sizes
  • SafeAreaView: Proper handling of status bar and notches
  • Smooth Scrolling: Banner images scroll with content
  • Color Theme: Consistent green agricultural theme
  • Icons: Intuitive Ionicons throughout the app

๐Ÿ”‘ API Configuration

The app uses OpenWeatherMap API for weather data. The API key is configured in:

// app/services/weatherService.js
const API_KEYS = {
    OPENWEATHER: 'your_api_key_here'
};

Note: The current API key is rate-limited. For production use, obtain your own key from OpenWeatherMap.

๐ŸŒ Localization

The app supports two languages:

  • English (default)
  • Hindi (เคนเคฟเค‚เคฆเฅ€)

Language can be toggled from the Profile screen. All screens and components are fully translated.

๐Ÿ“ฑ Screens Overview

1. Login Screen

  • Email/password authentication
  • Beautiful login image
  • User-friendly form validation

2. Home Screen

  • Personalized greeting
  • Current location display
  • Weather summary card
  • Quick action buttons
  • Clean, modern design

3. Crop Recommendation

  • Banner image at top
  • Soil parameter inputs (N, P, K, pH)
  • Climate inputs (temperature, rainfall)
  • Multiple crop suggestions
  • Detailed reasoning for each crop
  • Scrollable results

4. Weather Screen

  • Location-based weather
  • Current conditions
  • Temperature, humidity, wind
  • Sunrise/sunset times
  • Farming advice based on weather
  • Mock data fallback

5. Market Prices

  • Commodity price list
  • Search functionality
  • Category filters
  • Price trends
  • Market locations

6. Government Schemes

  • Banner image at top
  • Scheme cards with details
  • Benefits list with checkmarks
  • "Apply Now" buttons
  • Direct links to official sites

7. Profile Screen

  • User information
  • Profile picture
  • Edit profile modal
  • Language toggle
  • Settings options
  • Logout button

๐Ÿšง Known Limitations

  • Weather API has rate limits (mock data used as fallback)
  • Market prices are simulated data
  • Government schemes are hardcoded
  • Crop recommendation uses rule-based logic (not ML)
  • No backend server (all data is local/mock)

๐Ÿ”ฎ Future Enhancements

  • Backend integration with real APIs
  • Machine Learning for crop prediction
  • Real-time market price feeds
  • Push notifications for weather alerts
  • Offline mode with data caching
  • More languages (Punjabi, Marathi, etc.)
  • Community forum
  • Crop disease detection using camera
  • Fertilizer calculator
  • Irrigation scheduler

๐ŸŽ“ Academic Context

This project is developed as part of the Mobile Application Development (MAD) course end-semester project. The app demonstrates:

  • โœ… React Native component architecture
  • โœ… Context API for state management
  • โœ… Navigation patterns (Tab + Stack)
  • โœ… API integration
  • โœ… Location services
  • โœ… Image handling
  • โœ… Internationalization (i18n)
  • โœ… Form handling and validation
  • โœ… UI/UX best practices
  • โœ… Git version control

๐Ÿ“„ License

This project is created for educational purposes as part of an academic assignment.

๐Ÿ‘จโ€๐Ÿ’ป Developer

Mohit Kourav

๐Ÿ™ Acknowledgments

  • Original web project: krishiguide
  • OpenWeatherMap for weather API
  • React Native and Expo communities
  • Course instructors and peers
  • All open-source contributors

๐Ÿ“ธ Screenshots


Note: This is an academic project developed for learning purposes. For production deployment, implement proper security measures, API key management, real data sources, and backend infrastructure.

Made with โค๏ธ for farmers

About

Krishi Guide is a React Native app that use to recommend the best crops for farmers based on their soil, weather, and environmental data. The goal is to help farmers boost yields and make smarter decisions quickly and easily.๐ŸŒฑ

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published