How nimisha-lab/edge_case works
SyncCivic coordinates municipal infrastructure projects through department/project management, spatial clash detection, and joint-tender savings analysis, alongside citizen project transparency, complaint upvoting, and phase feedback. The backend is a FastAPI service backed by PostGIS; the React portal exposes citizen and official-facing screens. The README documents alerting and authentication capabilities, but the sampled backend routes do not establish their implementation or wiring, so those are not represented as confirmed runtime components.
Main entry points: main.py FastAPI application · database.py PostGIS database · CitizenPortal.jsx Citizen portal · clashes.py Clash routes
Components 23
Web portals
- Portal router
src/App.jsx - Citizen portal
src/pages/CitizenPortal.jsx - Project dashboard
src/components/citizen/ProjectDashboard.jsx - Phase feedback
src/components/citizen/PhaseStepperModal.jsx - Problem forum
src/components/citizen/ProblemForum.jsx - Grievance rankings
src/components/GrievanceRankings.jsx - Official login
src/components/common/LoginModal.jsx - Escalation view
AdminEscalationView.jsx - API client
src/api/client.js
Civic API
- FastAPI application
backend/app/main.py - Project routes
backend/app/routers/projects.py - Complaint routes
backend/app/routers/complaints.py - Department routes
backend/app/routers/departments.py - Feedback routes
backend/app/routers/feedback.py - Clash routes
backend/app/routers/clashes.py
Coordination analysis
- Clash detection
backend/app/services/clash_detector.py - Tender optimization
backend/app/services/optimization.py
Domain and storage
- API schemas
backend/app/schemas/schemas.py - Domain models
backend/app/models/models.py - PostGIS database
backend/app/database/database.py - Database settings
backend/app/core/config.py
Other components
- Citizens
- City officials
Connections 23
- Citizens → Citizen portal: view and report
README.md - City officials → Portal router: use portal
README.md - Portal router → Citizen portal: routes to
src/App.jsx - Citizen portal → API client: requests data
src/pages/CitizenPortal.jsx - Problem forum → API client: calls
src/components/citizen/ProblemForum.jsx - Citizen portal → Grievance rankings: renders
src/pages/CitizenPortal.jsx - Project dashboard → Phase feedback: opens
src/components/citizen/ProjectDashboard.jsx - API client → FastAPI application: calls API
- FastAPI application → Department routes: registers
backend/app/main.py - FastAPI application → Project routes: registers
backend/app/main.py - FastAPI application → Clash routes: registers
backend/app/main.py - FastAPI application → Complaint routes: registers
backend/app/main.py - FastAPI application → Feedback routes: registers
backend/app/main.py - Clash routes → Clash detection: invokes
backend/app/routers/clashes.py - Clash routes → Tender optimization: invokes
backend/app/routers/clashes.py - Project routes → PostGIS database: queries via session
backend/app/routers/projects.py - Complaint routes → PostGIS database: queries via session
backend/app/routers/complaints.py - Department routes → PostGIS database: queries via session
backend/app/routers/departments.py - Feedback routes → PostGIS database: queries via session
backend/app/routers/feedback.py - Clash detection → Domain models: reads and writes
backend/app/services/clash_detector.py - Tender optimization → Domain models: analyzes projects
backend/app/services/optimization.py - PostGIS database → Database settings: configures engine
backend/app/database/database.py - PostGIS database → Domain models: registers tables
backend/app/database/database.py