How sajid-ally/jaldrishti works
JalDrishti is a citizen and municipal-response platform for water hazards. Citizens submit location-tagged incidents or SOS requests; the backend analyzes and records reports, while authorities review, verify, assign response teams, and update status for citizen tracking. The product also includes maps and hotspot evidence, alerts, and social-media reporting. The graph combines documented capabilities with relationships visible in the excerpts and source index; unsampled internals are represented at their known module paths, without assuming their call details.
Main entry points: routes.py Report endpoints · main.py API application · AppRoutes.tsx Portal routing · service.py Report lifecycle
Components 26
Portals and clients
- Web application
frontend/src/App.tsx - Portal routing
frontend/src/routes/AppRoutes.tsx - Incident reporting
frontend/src/pages/Citizen/ReportHazard.tsx - SOS and relief
frontend/src/pages/Citizen/RescueRelief.tsx - Authority review
frontend/src/pages/Government/ReviewReports.tsx - Incident tracking
frontend/src/pages/Citizen/TrackReport.tsx
Incident management
- Report API client
frontend/src/services/reportService.ts - Report endpoints
Backend/app/reports/routes.py - Report lifecycle
Backend/app/reports/service.py
Response and evidence
- Relief endpoints
Backend/app/relief/routes.py - Rescue dispatch
Backend/app/relief/service.py - Incident validation
Backend/app/validation/service.py - Social reports
Backend/app/social_reports/service.py - Social detection bridge
Backend/app/social_bridge/service.py - Government alerts
Backend/app/validation/routes.py - Notifications
Backend/app/notifications/service.py
Platform services
- MongoDB
Backend/app/database.py - Authentication
Backend/app/auth/service.py - Auth endpoints
Backend/app/auth/routes.py - API application
Backend/app/main.py
AI analysis
- Gemini verification
Backend/app/gemini/service.py - ML service client
Backend/app/ml_client.py - ML inference API
ml-service/app/main.py - Hotspot clustering
Backend/app/models/hotspot_clustering.py
Other components
- Citizen
- Municipal authority
Connections 35
- Citizen → Web application: uses
- Municipal authority → Web application: uses
- Web application → Portal routing: renders
frontend/src/App.tsx - Portal routing → Incident reporting: routes to
frontend/src/routes/AppRoutes.tsx - Portal routing → Authority review: routes to
frontend/src/routes/AppRoutes.tsx - Portal routing → Incident tracking: routes to
frontend/src/routes/AppRoutes.tsx - Incident reporting → Report API client: submits
- Report API client → Report endpoints: HTTP requests
frontend/src/services/reportService.ts - Report endpoints → Report lifecycle: delegates
Backend/app/reports/routes.py - Report lifecycle → MongoDB: reads and writes
Backend/app/reports/service.py - Report endpoints → Gemini verification: verifies with
Backend/app/reports/routes.py - Report endpoints → ML service client: requests analysis
Backend/app/reports/routes.py - ML service client → ML inference API: calls
- ML inference API → Hotspot clustering: uses
- Authority review → Report API client: loads reports
frontend/src/pages/Government/ReviewReports.tsx - Report lifecycle → Municipal authority: supports dispatch
- Citizen → SOS and relief: requests rescue
- SOS and relief → Relief endpoints: submits request
- Relief endpoints → Rescue dispatch: delegates
Backend/app/relief/routes.py - Rescue dispatch → MongoDB: stores requests
- Municipal authority → Rescue dispatch: assigns teams
- Report endpoints → Incident validation: validates evidence
- Incident validation → MongoDB: queries incidents
Backend/app/validation/service.py - Incident validation → Government alerts: serves alert data
Backend/app/validation/routes.py - Social reports → Notifications: uses
Backend/app/social_reports/service.py - Social detection bridge → Social reports: forwards reports
- API application → Report endpoints: registers
Backend/app/main.py - API application → Auth endpoints: registers
Backend/app/main.py - API application → Relief endpoints: registers
Backend/app/main.py - API application → Government alerts: registers
Backend/app/main.py - Auth endpoints → Authentication: delegates
Backend/app/auth/routes.py - Authentication → MongoDB: reads and writes
Backend/app/auth/service.py - Web application → Report API client: syncs offline reports
frontend/src/App.tsx - Citizen → Incident tracking: tracks status
- Report lifecycle → Hotspot clustering: clusters hazards
Backend/app/reports/service.py