NyayaSetu

Offline-First AI Governance Platform for Rural India

RoleFull-Stack AI Engineering, Agentic Systems Design, NLP Architecture & Academic Research
Built byShaurya Punj
LocationIndia
Year2025 – 2026
NyayaSetu hero
Overview

NyayaSetu (न्यायसेतु — "Bridge to Justice") is a production-grade, multilingual AI governance platform designed for rural Indian citizens and government officers with limited or no internet connectivity. It provides voice-native, Hindi/English/Hinglish access to government schemes, grievance routing, and notice management through local LLM inference — no cloud dependency required.

Links
The Problem

Over 833 million rural Indians lack reliable internet access, yet the delivery of government welfare schemes, grievance redressal, and public notices has moved almost entirely online. Approximately 313 million adults in India cannot read or write, making text-only digital portals effectively inaccessible. Fewer than 30% of eligible beneficiaries successfully access entitlements they qualify for, due to language barriers, connectivity gaps, and complex bureaucratic interfaces.

The Solution

NyayaSetu deploys entirely on-device using Ollama-managed local LLMs (Qwen2.5-14B for structured reasoning, Sarvam-optimized models for Indic language understanding), a FAISS vector store for semantic scheme search, and Helsinki-NLP multilingual embeddings — all without requiring internet. Citizens interact via voice in Hindi, English, or Hinglish; NyayaVaani transcribes speech with faster-whisper, routes queries through a RAG pipeline, generates contextual answers, and responds via Coqui TTS — completing the full loop offline.

Project Walkthrough
Agent Architecture
01

NyayaVaani — Voice Intelligence Engine

Input: Spoken query in Hindi / English / Hinglish
Engine: faster-whisper → Qwen2.5-14B / Sarvam 24B → Coqui TTS
Output: Spoken answer in user's language + structured text
Speed: ~3–6s offline
02

RAG Scheme Intelligence Engine

Input: Natural language query (text or transcribed speech)
Engine: Helsinki-NLP embeddings → FAISS vector search → Qwen2.5-14B
Output: Grounded scheme answer with source attribution
Speed: ~1.5–4s
03

Grievance Router

Input: Citizen grievance text / voice submission
Engine: Qwen2.5-14B classification → SLA assignment → SQLite
Output: Categorized ticket routed to correct department
Speed: < 2s
04

Scheme Summarizer

Input: Raw government scheme document (PDF / text)
Engine: Qwen2.5-14B structured summarization with JSON output
Output: Citizen-friendly summary with eligibility & steps
Speed: ~5–10s
05

Notice Drafter

Input: Officer intent / template + auto-filled credentials
Engine: Qwen2.5-14B generation with role context injection
Output: Formal government notice draft ready for review
Speed: ~3–7s
System Architecture
NyayaSetu architecture flowchart
Technology Stack

client

  • React 18
  • TypeScript
  • Electron (Desktop)
  • HashRouter (Offline SPA)

server

  • FastAPI (Python)
  • SQLite (Offline-First)
  • REST API + OpenAPI Docs

ai

  • Ollama (Local LLM Runtime)
  • Qwen2.5-14B
  • Sarvam 24B (Indic Intelligence)
  • faster-whisper (Offline ASR)
  • Coqui TTS (Offline Synthesis)
  • FAISS Vector Search

data

  • SQLite (All Persistence)
  • FAISS Vector Index
  • Government Scheme PDFs
  • In-Memory Cache (280x Speedup)
Key Features
01

Fully offline — all LLM inference runs locally via Ollama, zero cloud dependency

02

Voice-native multilingual interface: Hindi, English & Hinglish supported

03

RAG-powered scheme discovery grounded in real government documents

04

Role-based access: citizen self-service vs officer admin panel

05

Grievance routing with department assignment and SLA monitoring

06

AI-assisted notice drafting with officer credential auto-fill

Screenshots
NyayaSetu - Scheme Search & RAG Answer
NyayaSetu - Officer Admin Panel
NyayaSetu - Grievance Routing Dashboard