How rohithkannas/tourist-safety-dashboard works
SafeGuard is an authority-facing tourist safety dashboard. The main workflow is officers signing in, monitoring tourist locations and SOS alerts, and taking follow-up actions; parallel capabilities cover zones, analytics, emergency services, audit, and e-FIR. The backend exposes authenticated Firebase-backed APIs, while a separate Flask/LSTM service provides risk predictions. Frontend implementation was not sampled, so its feature links rely on README documentation; the ML service-to-predictor and backend-to-Firestore links are supported by excerpts.
Main entry points: api.js API client · dashboard.html Tourist dashboard · analytics.html Risk analytics · login.html Sign-in
Components 18
Safety dashboard
- Sign-in
frontend/login.html - Tourist dashboard
frontend/dashboard.html - Live map
frontend/assets/js/map.js - SOS alerts
frontend/alerts.html - Geofence tools
frontend/geofence.html - Risk analytics
frontend/analytics.html - E-FIR filing
frontend/efir.html - Audit logs
frontend/audit.html - Language support
frontend/assets/js/i18n.js - API client
frontend/assets/js/api.js - Authentication
frontend/assets/js/auth.js
Application backend
- REST API
backend/index.js
Risk prediction
- Prediction API
ml-service/api_server.py - LSTM predictor
ml-service/lstm_predictor.py
External services
- Application records
- Firebase Auth
- Mapbox maps
Other components
- Safety officer
Connections 18
- Safety officer → Sign-in: signs in
README.md - Safety officer → Tourist dashboard: monitors
README.md - Tourist dashboard → Live map: views locations
README.md - Tourist dashboard → API client: requests data
- SOS alerts → API client: manages alerts
- Geofence tools → API client: manages zones
- Risk analytics → API client: requests metrics
- Audit logs → API client: requests logs
- Sign-in → Authentication: authenticates
- Authentication → Firebase Auth: uses
README.md - API client → REST API: calls
- REST API → Application records: reads and writes
backend/index.js - Prediction API → LSTM predictor: calls
ml-service/api_server.py - LSTM predictor → Application records: fetches training data
ml-service/lstm_predictor.py - Risk analytics → Prediction API: requests predictions
- Tourist dashboard → Mapbox maps: renders maps
README.md - Language support → Tourist dashboard: localizes interface
README.md - E-FIR filing → Safety officer: supports filing
README.md