AI-Powered Government Guidance Assistant with Multi-Source Verification
Get instant, verified guidance on Indian government services. Zen Citizen AI combines internal databases, official government websites, verified sources, community forums, and ChatGPT synthesis to provide reliable information with confidence scores.
- Multi-Source Verification: Fetches data from 5+ sources simultaneously
- Confidence Scoring: Shows reliability of each answer (High/Medium/Low)
- AI Synthesis: ChatGPT verifies and synthesizes information
- State Awareness: Get guidance specific to your state
- Beautiful Interface: Modern, responsive design
- Internal Database (95% confidence) - Pre-verified guides
- Official Government Sites (85% confidence) - .gov.in domains
- Verified Websites (75% confidence) - Trusted organizations
- Community Forums (40-60% confidence) - Reddit & YouTube
- AI Verification (Variable) - ChatGPT synthesis
- Backend: Node.js, Express, MongoDB
- Frontend: HTML5, CSS3, Vanilla JavaScript
- AI: OpenAI GPT-4o-mini
- Data: Axios, Cheerio, MongoDB
- Deployment: Ready for Heroku, Railway, Vercel, etc.
- Node.js 14+
- MongoDB (local or Atlas)
- Python 3 (for frontend development)
- OpenAI API key
cd Zencitizen-backend
# Install dependencies
npm install
# Create .env file
cp .env.example .env
# Edit .env and add your OpenAI API key and MongoDB URI
# Start server
npm startBackend runs on http://localhost:8000
cd Zencitizen-frontend
# Start HTTP server
python3 -m http.server 8888Frontend accessible at http://localhost:8888
Visit http://localhost:8888 and ask:
- "How do I apply for passport?"
- "Voter ID requirements in Maharashtra?"
- "Driving license process"
Zencitizen-AI/
βββ Zencitizen-backend/ # Backend API
β βββ server.js # Main server
β βββ models/Guide.js # MongoDB schema
β βββ services/
β β βββ guidanceEngine.js # Core orchestrator
β β βββ serviceRegistry.js # Service definitions
β β βββ confidenceScorer.js # Scoring system
β β βββ chatgptSynthesis.js # AI synthesis
β β βββ mcpSources.js # Reddit/YouTube
β β βββ verifiedWebsites.js # Official sources
β βββ config/services.js # Service mappings
β βββ package.json
β βββ .env.example
β βββ SETUP_GUIDE.md
β βββ README.md
β
βββ Zencitizen-frontend/ # Frontend UI
β βββ index.html
β βββ css/
β β βββ styles.css
β β βββ components.css
β βββ js/main.js
β βββ README.md
β βββ QUICK_START.md
β βββ ARCHITECTURE.md
β βββ .gitignore
β
βββ README.md # This file
βββ LICENSE
βββ .gitignore
- Indian Passport - Travel documents
- Voter ID - Electoral card
- Driving License - Vehicle license
- Aadhaar - National ID
- PAN Card - Tax identification
- Ration Card - Food security
- Property Registration - Land registry
User Question
β
Service Identification (Search Registry)
β
Internal Database Check (MongoDB)
β
Official Sites Fetch (.gov.in domains) ββ Parallel
Community Sources (Reddit/YouTube) β
Verified Websites β
β
Confidence Scoring & AI Synthesis (ChatGPT)
β
Structured JSON Response
β
Beautiful Results Display
- High (85-100%): Internal DB or official government
- Medium (60-84%): Verified sources with some consensus
- Low (1-59%): Community-only sources, verify directly
Get guidance on any government service.
Request:
{
"question": "How do I apply for passport?",
"state": "Maharashtra"
}Response:
{
"source": "hybrid+verified_websites+community",
"confidenceLevel": "High",
"service": "Indian Passport",
"state": "Maharashtra",
"answer": "...",
"steps": [...],
"requiredDocuments": [...],
"fees": "βΉ1500",
"processingTime": "7-14 days",
"eligibility": "...",
"officialLinks": [...],
"confidenceScore": 0.95
}Add a new guide (admin).
Fetch raw content from URL.
Structure raw content with ChatGPT.
Remove a guide.
- Hero Section - Eye-catching landing page
- Service Browser - Browse 7+ government services
- Chat Interface - Real-time guidance
- Results Modal - Detailed information display
- Source Tracking - View all sources used
- Search History - Recent searches saved locally
- Responsive Design - Works on all devices
- Chrome 90+
- Firefox 88+
- Safari 14+
- Edge 90+
- Mobile browsers
- No personal data collection
- All API keys stored server-side (.env)
- Source domain verification
- Community sources weighted lower
- External page verification
- CORS enabled for safety
- Netlify:
netlify deploy --prod - Vercel:
vercel --prod - GitHub Pages: Push to gh-pages branch
- AWS S3:
aws s3 sync . s3://bucket
- Heroku:
git push heroku main - Railway:
railway up - Render: Connect GitHub repo
- AWS EC2, DigitalOcean, or custom VPS
- Create
.envfile with secrets - Set MongoDB Atlas connection
- Add OpenAI API key
- Configure CORS for frontend domain
# Chat endpoint
curl -X POST http://localhost:8000/api/chat \
-H "Content-Type: application/json" \
-d '{"question":"How to get passport?"}'
# Add guide
curl -X POST http://localhost:8000/api/add-guide \
-H "Content-Type: application/json" \
-d '{
"title": "Test",
"category": "passport",
"overview": "Test",
"sourceUrl": "https://test.gov.in"
}'
# View database
curl http://localhost:8000/debug-guides- Open http://localhost:8888
- Search different services
- Check browser console (F12)
- Test on mobile devices
# Check MongoDB connection
# Verify OPENAI_API_KEY is set
# Check port 8000 is available
lsof -i :8000
# View logs
npm start# Check port 8888 is available
lsof -i :8888
# Clear browser cache
# Check DevTools Network/Console tabs- Verify both servers running
- Check API base URL in frontend code
- Inspect network requests
- Review error messages in console
- Backend: 5-15s (includes synthesis)
- Frontend: <100ms render
- Database: <100ms queries
- Bundle: ~50KB assets
- Lightweight & optimized
- Dark mode
- Multi-language support
- Offline mode
- Service comparison
- Voice search
- PDF export
- Real-time updates
- User bookmarks
We welcome contributions!
- Fork the repository
- Create feature branch (
git checkout -b feature/amazing) - Commit changes (
git commit -am 'Add amazing feature') - Push to branch (
git push origin feature/amazing) - Open Pull Request
MIT License - see LICENSE file for details
- Built with Node.js, Express, MongoDB
- AI powered by OpenAI
- Community data from Reddit & YouTube
- Government data from official sources
- Open issues for bugs
- Discussions for feature requests
- Email: support@zencitizen.ai (coming soon)
- π 7+ Government Services
- π 5+ Data Sources
- π§ AI-Powered Verification
- π¨ Modern Web Interface
- β‘ Fast & Lightweight
πΏ Zen Citizen AI - Making Government Guidance Simple & Reliable
Built with β€οΈ using modern web technologies. Designed to help Indians navigate government services effortlessly.
Last Updated: February 2026