How bluehorizon65/metro_sphere_web works
Metro Sphere is a document-management and AI analysis platform: employees upload or receive metro documents, which can be digitized/translated, analyzed for actionable details, searched, and tracked. The graph captures the evidenced frontend routing, Express API, and translation/analysis handoffs, plus README-described capabilities whose implementation links were not sampled. The AI server and semantic-search service are represented by their exact paths, but their internal behavior and several UI/API connections were not inspected.
Main entry points: App.jsx App routes · index.js Express API · kmrl_api_server.py LLM document analysis · email.js Email analysis route
Components 22
Employee web app
- App routes
Frontend/src/App.jsx - Login and registration
Frontend/src/pages/LoginRegister.jsx - Dashboard
Frontend/src/pages/DashboardLayout.jsx - Document upload
Frontend/src/pages/UploadDocument.jsx - PDF analysis
Frontend/src/pages/PdfAnalysisPage.jsx - Semantic search UI
Frontend/src/pages/SemanticSearch.jsx - Email uploads UI
Frontend/src/pages/EmailUploads.jsx - WhatsApp uploads UI
Frontend/src/pages/WhatsAppUploads.jsx
Application API
- Express API
Backend/index.js - User and admin accounts
Backend/routes/user.js - PostgreSQL database
Backend/db.js - Document analysis routes
Backend/routes/user.js - Email analysis route
Backend/routes/email.js - WhatsApp analysis route
Backend/routes/whatsapp.js - Semantic API routes
Backend/routes/semantic.js - Admin routes
Backend/routes/admin.js
Document processing
- OCR and translation
pipeline/full_pipeline.py - LLM document analysis
AI/kmrl_api_server.py - Vector search service
Semantic-search/merged_api.py
External ingestion
- Gmail attachment ingest
twilio/twilio_gmail/backend.py - WhatsApp file ingest
twilio/twilio_whtspp/backend.py
Other components
- Employee
Connections 30
- Employee → App routes: uses
README.md - App routes → Login and registration: routes to
Frontend/src/App.jsx - App routes → Dashboard: routes to
Frontend/src/App.jsx - App routes → Document upload: routes to
Frontend/src/App.jsx - App routes → PDF analysis: routes to
Frontend/src/App.jsx - App routes → Semantic search UI: routes to
Frontend/src/App.jsx - App routes → Email uploads UI: routes to
Frontend/src/App.jsx - App routes → WhatsApp uploads UI: routes to
Frontend/src/App.jsx - App routes → Express API: calls
- Express API → User and admin accounts: mounts
Backend/index.js - Express API → Document analysis routes: mounts
Backend/index.js - Express API → Email analysis route: mounts
Backend/index.js - Express API → WhatsApp analysis route: mounts
Backend/index.js - Express API → Semantic API routes: mounts
Backend/index.js - Express API → Admin routes: mounts
Backend/index.js - User and admin accounts → PostgreSQL database: queries
Backend/routes/user.js - Admin routes → PostgreSQL database: queries
Backend/routes/admin.js - Document analysis routes → OCR and translation: translates via
Backend/routes/user.js - Document analysis routes → LLM document analysis: requests analysis
Backend/routes/user.js - Email analysis route → OCR and translation: translates via
Backend/routes/email.js - Email analysis route → LLM document analysis: requests analysis
Backend/routes/email.js - WhatsApp analysis route → OCR and translation: translates via
Backend/routes/whatsapp.js - WhatsApp analysis route → LLM document analysis: requests analysis
Backend/routes/whatsapp.js - Semantic API routes → Vector search service: forwards search
Backend/routes/semantic.js - Gmail attachment ingest → Email analysis route: provides attachments
- WhatsApp file ingest → WhatsApp analysis route: provides files
- Employee → Vector search service: searches documents
README.md - LLM document analysis → Employee: returns extracted details
README.md - LLM document analysis → Employee: suggests team sharing
README.md - Employee → PostgreSQL database: tracks documents
README.md