S
AI/ML2026CompletedFeatured Project

Jalsakhi Ai Powered Precision Agriculture Platform

Village Water Allocation Optimization API Distributes limited village reservoir water across farms using: - Crop Water Requirement from CropWaterModel (Model 1) - Optional predicte...

RoleSole Developer
Classificationhigh
Client / ContextOpen Source Project
Development TimelineCompleted

Technical Architecture & Engineering Overview

Detailed system design and core implementation

Frontend built with React. Backend API powered by FastAPI, Express. AI/ML capabilities powered by LangChain. Persistence managed by MongoDB.

System Diagrams & Flow Visualizations

Interactive Mermaid architecture & execution flows

Architectural Visualizer · System Architecture

Core System Features

Key capabilities & architectural features

FEATURE 01

- OTP‑based email verification for secure sign‑up.

- OTP‑based email verification for secure sign‑up.

FEATURE 02

- Role‑based JWT authentication (farmer & admin).

- Role‑based JWT authentication (farmer & admin).

FEATURE 03

- CRUD operations for farm entities with geo‑location support.

- CRUD operations for farm entities with geo‑location support.

FEATURE 04

- AI‑driven crop water requirement prediction (Random Forest).

- AI‑driven crop water requirement prediction (Random Forest).

FEATURE 05

- 7‑day soil moisture forecasting using Prophet and LSTM.

- 7‑day soil moisture forecasting using Prophet and LSTM.

FEATURE 06

- Village‑level water allocation optimizer integrating farmer demand.

- Village‑level water allocation optimizer integrating farmer demand.

FEATURE 07

- Real‑time AI chatbot powered by LangChain and Llama 3.1.

- Real‑time AI chatbot powered by LangChain and Llama 3.1.

FEATURE 08

- Centralized ML gateway with rate limiting and health checks.

- Centralized ML gateway with rate limiting and health checks.

FEATURE 09

- Exportable data endpoints for analytics dashboards.

- Exportable data endpoints for analytics dashboards.

FEATURE 010

- Environment‑agnostic configuration via `.env` files.

- Environment‑agnostic configuration via `.env` files.

Engineering Challenges & Solutions

Problem statements & resolution strategies

Challenge #1

- Balancing latency between mobile requests and Python FastAPI models; introduced async proxying in the gateway.

- Balancing latency between mobile requests and Python FastAPI models; introduced async proxying in the gateway.

Challenge #2

- Managing consistent schema versions across MongoDB and FastAPI input validation.

- Managing consistent schema versions across MongoDB and FastAPI input validation.

Challenge #3

- Securing inter‑service communication without a full service mesh; used API keys and JWT propagation.

- Securing inter‑service communication without a full service mesh; used API keys and JWT propagation.

Challenge #4

- Handling large payloads for sensor‑based soil data while respecting the 1 MB body size limit.

- Handling large payloads for sensor‑based soil data while respecting the 1 MB body size limit.

Challenge #5

- Coordinating deployment of heterogeneous runtimes (Node.js vs Python) on Azure.

- Coordinating deployment of heterogeneous runtimes (Node.js vs Python) on Azure.

API Reference & Endpoints

REST API surface & route documentation

METHODENDPOINT PATHDESCRIPTIONCOPY
GET/healthEndpoint defined in ml-services/chatbot/api.py
POST/chatEndpoint defined in ml-services/chatbot/api.py
POST/model1Endpoint defined in ml-services/gateway/server.js
POST/model2Endpoint defined in ml-services/gateway/server.js
POST/model3Endpoint defined in ml-services/gateway/server.js
POST/predictEndpoint defined in ml-services/models/Crop_Water_Model/main.py
GET/configEndpoint defined in ml-services/models/Crop_Water_Model/main.py
GET/Endpoint defined in ml-services/models/soil_moisture_model/api.py
GET/uiEndpoint defined in ml-services/models/soil_moisture_model/api.py
POST/predict/sensorEndpoint defined in ml-services/models/soil_moisture_model/api.py
POST/predict/locationEndpoint defined in ml-services/models/soil_moisture_model/api.py
POST/optimizeEndpoint defined in ml-services/models/village_water_allocation/api.py
POST/registerEndpoint defined in server/routes/authRoutes.js
POST/loginEndpoint defined in server/routes/authRoutes.js
POST/logoutEndpoint defined in server/routes/authRoutes.js
POST/send-verify-otpEndpoint defined in server/routes/authRoutes.js
POST/verify-accountEndpoint defined in server/routes/authRoutes.js
GET/is-authEndpoint defined in server/routes/authRoutes.js
POST/send-reset-otpEndpoint defined in server/routes/authRoutes.js
POST/reset-passwordEndpoint defined in server/routes/authRoutes.js
GET/:idEndpoint defined in server/routes/farmRoutes.js
POST/Endpoint defined in server/routes/farmRoutes.js
PUT/:idEndpoint defined in server/routes/farmRoutes.js
DELETE/:idEndpoint defined in server/routes/farmRoutes.js
POST/:id/irrigationEndpoint defined in server/routes/farmRoutes.js
GET/:id/irrigationEndpoint defined in server/routes/farmRoutes.js
POST/crop-waterEndpoint defined in server/routes/mlRoutes.js
POST/soil-moistureEndpoint defined in server/routes/mlRoutes.js
POST/village-waterEndpoint defined in server/routes/mlRoutes.js
GET/dataEndpoint defined in server/routes/userRoutes.js

Key Code Modules & Architecture

Core file entrypoints and service responsibilities

AppMODULE 01
app/app

Module component managing app source logic

ComponentsMODULE 02
app/components

Module component managing components source logic

UiMODULE 03
app/components/ui

Module component managing ui source logic

ScriptsMODULE 04
app/scripts

Module component managing scripts source logic

ServicesMODULE 05
app/services

Module component managing services source logic

UtilsMODULE 06
app/utils

Module component managing utils source logic

DocsMODULE 07
docs

Module component managing docs source logic

ModelsMODULE 08
server/models

Module component managing models source logic

ServerMODULE 09
server

Module component managing server source logic

ConfigMODULE 010
server/config

Module component managing config source logic

ControllersMODULE 011
server/controllers

Module component managing controllers source logic

MiddlewareMODULE 012
server/middleware

Module component managing middleware source logic

RoutesMODULE 013
server/routes

Module component managing routes source logic

User Journey Pipeline

  1. 1User accesses application user interface via browser
  2. 2User triggers action invoking HTTP/WebSocket API endpoints
  3. 3Payload processed through AI/ML pipeline or local inference model
  4. 4Data persisted or retrieved from database storage layer

Execution Code Flow

  1. 1Client or caller initiates request to application entrypoint
  2. 2Backend router validates request parameters and applies middleware
  3. 3Service layer delegates task to ML runtime or LLM API worker
  4. 4Database ORM/client executes storage query
  5. 5Application serializes JSON/audio/data response back to client

System FAQ & Technical Specifications

Frequently asked questions and core architecture details

Q: What technologies are used in Jalsakhi Ai Powered Precision Agriculture Platform?

Jalsakhi Ai Powered Precision Agriculture Platform is engineered using modern full-stack frameworks.

Q: What core engineering problem does Jalsakhi Ai Powered Precision Agriculture Platform solve?

Village Water Allocation Optimization API Distributes limited village reservoir water across farms using: - Crop Water Requirement from CropWaterModel (Model 1) - Optional predicte...

Q: How is '- Balancing latency between mobile requests and Python FastAPI models; introduced async proxying in the gateway.' resolved in Jalsakhi Ai Powered Precision Agriculture Platform?

Resolved through specialized system architecture and resilient state handling.

Related Systems & Case Studies

Explore similar technical architectures and projects

View All Systems