How chocle254/civcare works
CivTech Care is an AI-assisted healthcare platform with patient and doctor experiences. Patients register, describe symptoms to AI triage, choose a hospital, and enter an in-person or remote-care flow; clinicians use a live queue, review patient context, and submit a verdict. The backend also supports medication scanning, records, prescriptions and adherence reminders, payments, messaging, analytics, and AI feedback. The graph follows documented routes and indexed module references; several feature implementations were not sampled, so uncertain internal links are omitted or marked unverified.
Main entry points: triage.py Triage and arrival · orchestrator.py AI triage orchestration · App.jsx Web app routes · client.js Frontend API client
Components 27
User experiences
- Web app routes
frontend/src/App.jsx - Patient symptom chat
frontend/src/pages/patient/Chat.jsx - Doctor queue dashboard
frontend/src/pages/doctor/Dashboard.jsx - Frontend API client
frontend/src/api/client.js - Triage API client
frontend/src/api/triage.js
Clinical workflows
- Patient and doctor auth
backend/app/routers/auth.py - Triage and arrival
backend/app/routers/triage.py - AI triage orchestration
backend/app/agents/orchestrator.py - Clinical triage agent
backend/app/agents/triage_agent.py - Medication safety scan
backend/app/agents/medscan_agent.py - Hospital directory
backend/app/routers/hospitals.py - Doctor and queue APIs
backend/app/routers/doctors.py - Remote consultation
backend/app/routers/consultation.py
Ongoing care
- Patient records
backend/app/routers/records.py - Prescriptions and reminders
backend/app/routers/reminders.py - Payments
backend/app/routers/payment.py - SMS and notifications
backend/app/services/africastalking.py - Care analytics
backend/app/routers/analytics.py - Medication outcomes and support
backend/app/services/carer.py
Backend platform
- Groq model client
backend/app/services/ai_client.py - Live queue updates
backend/app/websocket/queue.py
Data and learning
- SQL database access
backend/app/database.py - Patient and clinical records
backend/app/models - Doctor verdicts
backend/app/models/verdict.py - AI feedback learning
backend/app/services/rlhf.py
Other components
- Patient
- Doctor
Connections 33
- Patient → Web app routes: uses
- Doctor → Web app routes: uses
- Web app routes → Patient symptom chat: routes to
frontend/src/App.jsx - Web app routes → Doctor queue dashboard: routes to
frontend/src/App.jsx - Patient symptom chat → Triage API client: requests triage
frontend/src/pages/patient/Chat.jsx - Doctor queue dashboard → Frontend API client: requests data
frontend/src/pages/doctor/Dashboard.jsx - Triage API client → Frontend API client: uses client
- Frontend API client → Patient and doctor auth: calls backend
- Frontend API client → Triage and arrival: calls backend
- Patient → Patient and doctor auth: registers
- Triage and arrival → AI triage orchestration: runs triage
backend/app/routers/triage.py - AI triage orchestration → Clinical triage agent: delegates triage
backend/app/agents/orchestrator.py - AI triage orchestration → Medication safety scan: runs scan
backend/app/agents/orchestrator.py - Clinical triage agent → Groq model client: requests inference
backend/app/agents/triage_agent.py - AI triage orchestration → Groq model client: requests inference
backend/app/agents/orchestrator.py - Triage and arrival → Hospital directory: uses hospitals
backend/app/routers/triage.py - Patient → Hospital directory: selects hospital
- Doctor → Doctor and queue APIs: reviews queue
- Doctor queue dashboard → Live queue updates: receives updates
frontend/src/pages/doctor/Dashboard.jsx - Triage and arrival → Live queue updates: broadcasts queue
backend/main.py - Doctor → Remote consultation: consults remotely
- Patient → Patient records: views records
- Patient → Prescriptions and reminders: tracks treatment
backend/app/routers/reminders.py - Prescriptions and reminders → Medication outcomes and support: reviews outcomes
backend/app/routers/reminders.py - Patient → Payments: pays
- Prescriptions and reminders → SMS and notifications: sends reminders
backend/app/routers/reminders.py - Doctor → Doctor verdicts: submits verdict
backend/app/models/verdict.py - Doctor verdicts → AI feedback learning: feeds ratings
backend/app/models/verdict.py - Patient → Care analytics: views analytics
- Triage and arrival → Patient and clinical records: reads and writes
backend/app/routers/triage.py - Patient and doctor auth → Patient and clinical records: reads and writes
backend/app/routers/auth.py - Patient and clinical records → SQL database access: persists records
backend/app/models/session.py - AI feedback learning → Groq model client: requests inference
backend/app/services/rlhf.py