π Overview
Citizen development requests β roads, water, health, education β reach the government through scattered channels: phone calls, SMS, WhatsApp, in-person visits, in dozens of Indian languages. There's no unified way to understand demand at scale, correlate it with real infrastructure gaps, or decide where limited public funds should go first.
JanSetu is a Digital Public Good that fixes this:
- ποΈ Listens β citizens report issues by voice, text, or WhatsApp, in their own language. No app to install, no literacy barrier.
- π§ Understands β AI transcribes, translates, categorises, and scores the urgency of each request.
- π Correlates β requests are combined with demographic data, infrastructure indices, and existing public investment plans.
- π Recommends β policymakers see a ranked, explainable list of which areas need investment first, and why.
- π Closes the loop β citizens get status updates back, in their own language.
Built as an open, pluggable layer β designed to sit alongside existing systems like CPGRAMS and state grievance portals, not replace them.
β¨ Key Features
| ποΈ Multilingual intake | Voice, text & WhatsApp across 10+ Indian languages |
| π€ Smart categorisation | AI auto-tags requests β roads, water, health, education, electricity, sanitation |
| π Hotspot mapping | Geo-tagged visualisation of demand across wards & districts |
| π Explainable priority engine | Scores projects using demand + infrastructure gap + budget gap β never a black box |
| π₯οΈ Policymaker dashboard | Ranked recommendations with full reasoning, at a glance |
| π Feedback loop | Automatic status updates to citizens, in their own language |
| π Open architecture | API-first, easy to integrate with CPGRAMS, MyGov & state portals |
| πΈ Zero-cost deployable | Runs entirely on free-tier infrastructure β see Cost Philosophy |
ποΈ How It Works
Citizen Input (Voice / Text / WhatsApp)
β
βΌ
Speech-to-Text & Language Detection
β
βΌ
NLP: Translation & Categorisation
β
βΌ
Geo-tagging & Hotspot Clustering
β
βΌ
Correlation Engine (+ Demographic, Infra & Budget Data)
β
βΌ
Priority Scoring & Ranking
β
βΌ
Policymaker Dashboard βββΊ Approved Project & Status Update βββΊ back to Citizen
Clustering, in plain terms: complaints worded differently but meaning the same thing ("paani nahi aa raha" vs "water not coming") are grouped by AI into a single issue cluster per area. Complaint density is also clustered geographically to flag hotspot zones β areas needing combined, multi-issue investment rather than a single scheme.
Priority Scoring Formula
Priority Score = (Demand Score Γ 0.45) + (Infrastructure Gap Γ 0.30) + (Budget Gap Γ 0.25)
Every recommendation shown to a policymaker includes this breakdown β priorities are transparent, never a black box.
π οΈ Tech Stack
Designed to be deployable at zero cost, so any state or city government can adopt it β not just run it as a demo..
Frontend β Web Application| Purpose | Technology | |---|---| | Framework | React.js (Vite) | | Styling | Tailwind CSS | | Charts | Recharts | | Maps | Leaflet.js + OpenStreetMap *(free, no API key)* | | State management | React Context / Zustand | > Citizen intake is intentionally **app-less** β voice, WhatsApp, and a lightweight web form β so there's zero adoption barrier, even on basic phones or with low literacy. Backend
| Purpose | Technology | |---|---| | API server | FastAPI (Python) | | Auth | Firebase Auth / JWT | | API style | REST | AI / NLP Layer
| Purpose | Technology | Cost | |---|---|---| | Speech-to-Text & translation (Indian languages) | **Bhashini API** (Govt. of India) | Free | | Browser-side voice demo | Web Speech API | Free | | Classification, summarisation & explainable reasoning | **NVIDIA NIM** (build.nvidia.com β Llama 3.3 / Nemotron) | Free tier | | Geo-clustering of hotspots | Python (scikit-learn β DBSCAN) | Free | | Optional, higher-scale | Google Cloud Vertex AI / Gemini API | $300 free trial credit | Data Layer
| Purpose | Technology | |---|---| | Primary database | PostgreSQL + PostGIS (Supabase free tier) | | Large-scale correlation | BigQuery | | Real-time status updates | Firebase Firestore | Citizen Intake Channels
| Channel | Technology | Cost | |---|---|---| | WhatsApp | WhatsApp Cloud API (Meta, direct) | Free (service conversations) | | Voice call | Twilio Voice + Bhashini | Free tier | | Web form | React app route | Free | Deployment
| Purpose | Technology | |---|---| | Frontend hosting | Vercel / Netlify | | Backend hosting | Render / Google Cloud Run (free tier) | | Containerisation | Docker | | CI/CD | GitHub Actions |
π Project Structure
jansetu/
βββ frontend/ # React Web App (Policymaker Dashboard + Web intake)
β βββ src/
β β βββ components/ # Cards, Charts, WardList, ComplaintForm
β β βββ pages/
β β β βββ CitizenPortal.jsx
β β β βββ Dashboard.jsx
β β βββ services/ # API calls (axios/fetch wrapper)
β β βββ context/ # Global state
β β βββ App.jsx
β βββ package.json
β
βββ backend/ # FastAPI server
β βββ app/
β β βββ routes/
β β β βββ complaints.py # submit / fetch complaints
β β β βββ dashboard.py # priority scores, analytics
β β β βββ auth.py
β β βββ models/ # DB schemas (SQLAlchemy)
β β βββ services/
β β β βββ nlp_service.py # NVIDIA NIM / Bhashini calls
β β β βββ translation_service.py
β β β βββ priority_engine.py # scoring algorithm
β β βββ main.py
β βββ requirements.txt
β βββ Dockerfile
β
βββ ai-models/ # Classification & clustering logic
β βββ clustering.py
β
βββ whatsapp-bot/ # WhatsApp Cloud API webhook handler
β βββ webhook.py
β
βββ prototype/ # Standalone HTML/JS demo (no backend needed)
β βββ index.html
β
βββ docs/
βββ architecture-diagram.png
π Getting Started
Try the prototype (zero setup)
A self-contained, interactive demo is included at prototype/index.html β no server or dependencies required.
open prototype/index.html
It includes a citizen complaint form with a live "AI reasoning" trace, and a policymaker dashboard with priority ranking, category breakdown, and a live request feed.
Run the full stack locally
# clone the repo
git clone https://github.com/<your-username>/jansetu.git
cd jansetu
# backend
cd backend
pip install -r requirements.txt
uvicorn app.main:app --reload
# frontend (in a new terminal)
cd frontend
npm install
npm run dev
Add your API keys (Bhashini, NVIDIA NIM, WhatsApp Cloud API) to a .env file in backend/ β see .env.example.
πΈ Cost Philosophy
Every component in this stack has a genuinely free tier β Bhashini, NVIDIA NIM, WhatsApp Cloud API service conversations, Leaflet/OpenStreetMap, Supabase, Vercel/Netlify β with Google Cloud's $300 trial credit available for heavier workloads if needed.
This is a deliberate choice: a Digital Public Good should be deployable by any state or city government, regardless of budget.
πΊοΈ Roadmap
- [ ] Integration with CPGRAMS and state grievance portals via open APIs
- [ ] Predictive analytics to forecast infrastructure demand before complaints arise
- [ ] Public transparency ledger tracking project execution against citizen demand
- [ ] Expansion to all 22 scheduled Indian languages plus major regional dialects
- [ ] Offline-first IVR support for low-connectivity rural areas
- [ ] Integration with PM Gati Shakti / Smart City data for richer infrastructure indices
π€ Contributing
Contributions are welcome! Feel free to open an issue or submit a pull request.
- Fork the repo
- Create your feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add some amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
π License
This project is licensed under the MIT License β see the LICENSE file for details.
**Built as an open Digital Public Good β for citizens, by design.**
Built With
- batchfile
- css
- dockerfile
- html
- javascript
- mako
- python
- typescript
Log in or sign up for Devpost to join the conversation.