ClinicOS
Full-stack therapy operations platform for session scheduling, treatment plans, therapist workflows, and progress tracking.
1. The Problem
Therapy practices need structured ways to schedule sessions, record attendance and notes, maintain treatment plans with goals, and give therapists a clear operational view of their caseload. Spreadsheet- or paper-based workflows fragment this information and make progress hard to track consistently.
ClinicOS was built as a software-engineering / portfolio project to model these operational workflows in a full-stack web application — authentication, role-aware access, session lifecycle, treatment plans, and dashboard views — without claiming clinical validation or production healthcare deployment.
2. The Solution
Verified capabilities supported by the repository models, routes, and frontend components:
- JWT authentication with protected routes and role-aware access
- Roles — therapist, admin, caregiver, patient (defined on TherapistProfile)
- Therapy sessions — create/list/update sessions with type (individual, group, assessment, consultation), status (scheduled → completed/cancelled), attendance, duration, and notes
- Treatment plans — patient-linked plans with goals (status + progress percentage), interventions, and plan status (draft → active → completed/archived)
- Therapist profiles — name, specialization, license, experience, availability
- Dashboard-oriented UI — therapist dashboard, session scheduling/list/details, treatment-plan forms, goal tracking, login, protected routes
- RESTful backend — session, treatment-plan, and therapist route modules
No public live deployment is listed. Local setup is the intended review path.
3. System Architecture
Monolithic full-stack design — no microservices or external AI services.
┌──────────────────────────────┐
│ ClinicOS Frontend │
│ React 18 + Vite │
│ React Router · Context API │
│ CSS custom properties │
└──────────────┬───────────────┘
│ REST API
▼
┌──────────────────────────────┐
│ Express.js Backend │
│ Node.js · JWT · RBAC │
│ Session / Plan / Therapist │
│ route modules │
└──────────────┬───────────────┘
│
▼
┌────────────────┐
│ MongoDB │
│ + Mongoose │
│ Session │
│ TreatmentPlan │
│ TherapistProfile│
└────────────────┘
Core models: Session, TreatmentPlan (with embedded goals), TherapistProfile.
4. My Contribution
ClinicOS is presented as an individual portfolio / academic software project. Unlike AutiSmart (documented team FYP), there is no separate team-contribution table in the repository. The public codebase and documentation reflect full-stack work across:
- Backend API design (session, treatment-plan, therapist routes)
- MongoDB/Mongoose data modelling
- JWT authentication and role middleware
- React frontend with role-aware dashboards and workflow screens
- Project documentation (API reference, setup guides, completion notes)
5. Key Technical Decisions
React + Vite + Context API
Why: Fast SPA development for multi-screen operational UIs; Context API sufficient for auth state without heavier state libraries.
Trade-off: Client-side rendering; full experience requires a running backend.
Express REST API + route modules
Why: Clear separation of session, treatment-plan, and therapist concerns; straightforward middleware chain for auth.
Trade-off: Monolithic process; scaling would require further modularisation or service extraction.
MongoDB + Mongoose with embedded goals
Why: Flexible documents for treatment plans whose goals and interventions evolve; indexes on therapistId + date for common list queries.
Trade-off: Patient identity is stored as names/IDs in documents rather than a full normalised Patient collection in the current models — simpler for a prototype, less ideal for complex multi-patient reporting.
JWT + role checks
Why: Stateless auth suitable for SPA + API; roles (therapist, admin, caregiver, patient) enable protected dashboards and actions.
Trade-off: Token lifecycle and revocation need careful handling; demo/setup still depends on a correctly configured JWT secret.
6. How the System Works
Authentication
Login → JWT issued → AuthContext stores token/role → ProtectedRoute guards pages → API requests send Bearer token → therapistAuthMiddleware validates
Session lifecycle
Therapist creates session (patient, date, type, duration) → Status: scheduled → Update attendance / notes / status (in-progress → completed | cancelled) → List/filter by therapist and date
Treatment plan flow
Create plan (draft) with goals + interventions → Activate plan → Update goal progress percentages and status → Complete or archive
7. Current Limitations
- Portfolio / academic project — not a clinically validated or production healthcare system.
- No public live deployment — repository and local execution are the proof path.
- Simplified patient modelling — current models lean on patientName / therapistId rather than a full multi-entity patient registry.
- Documentation vs code — some secondary docs use optimistic language (“production ready”, large LOC counts, performance metrics). Public claims on this page are limited to what the models, routes, and components support.
- Testing evidence — primarily manual and documentation-driven rather than comprehensive automated test suites.
8. Repository & Demo Status
No public live deployment is currently listed. Clone and run locally using the README setup instructions.
Scope & Disclaimer
ClinicOS is an academic/software engineering project. It should not be represented as a clinically validated medical system, medical device, or evidence of production healthcare deployment.