NPPCS (National Predictive Patient Care System) is an advanced, AI driven command center dashboard designed to enhance national medical resilience. The system utilizes machine learning algorithms to forecast Emergency Department (ED) loads, optimize hospital resource allocation in real time, and coordinate disaster response across regional health networks.
Currently in version v3.3 Enterprise, NPPCS features a fully localized bilingual interface (English/Arabic), multi region support (Riyadh & Jeddah), and an integrated AI Voice Assistant for hands free critical alerts. It fuses data from seven distinct operational streams including live traffic, weather hazards, and CAD (Computer Aided Dispatch) feeds to transform reactive medical operations into proactive, data driven strategies.
- Key Features
- System Architecture
- Technical Stack
- Prerequisites
- Installation and Deployment
- Usage Guide
- License
- Multi-Region Support: Simultaneous monitoring of critical sectors (e.g., Central Region/Riyadh and Western Region/Jeddah) with auto-centering geospatial visualization.
- Inter-Agency Integration: A unified status panel linking Health sectors with Civil Defense (Fire), Red Crescent (EMS), and National Center for Meteorology (NCM).
- Live Ticker Feed: A real-time, scrolling news ticker displaying operational updates, weather warnings, and system status without cluttering the map.
- 7-Point Data Fusion: Synthesizes inputs from Weather, Traffic, Major Events, Bed Capacity, Historical Trends, Live CAD, and Seasonal Patterns to calculate Risk Scores (0-100).
- Hospital-Specific Modeling: Deploys distinct regression models trained on individual facility patterns (e.g., Trauma Centers vs. General Hospitals).
- Predictive Quality Score (PQS): Forecasts critical metrics including Time-to-Assessment (TTA) and Ambulance Offload Times up to 90 minutes in advance.
- AI Voice Assistant: An integrated Text-to-Speech (TTS) engine that audibly announces critical alerts (e.g., "Critical Status Detected at King Fahad Hospital") to ensure operator attention.
- Timed Alert Logic: Generates graduated alerts at T-90 (Advisory), T-45 (Warning), and T-15 (Critical) intervals.
- Inter-facility Transfer Logic: Algorithms analyze network-wide capacity to recommend load-balancing transfers during saturation events.
The solution is architected as a containerized microservices application:
- Frontend Service: A React 19 application built with Vite and Tailwind CSS, featuring a darker, high-contrast "Dark Mode" UI optimized for 24/7 command centers.
- Backend Service: A Python FastAPI application acting as the orchestration layer and hosting the NumPy-based inference engine.
- Data Simulation: A built-in engine generating realistic synthetic streams for load testing and demonstration.
- Framework: React 19 with TypeScript
- Build Tool: Vite
- Styling: Tailwind CSS (with PostCSS & Autoprefixer)
- Mapping: Leaflet & React-Leaflet (CartoDB Dark Matter tiles)
- Visualization: Recharts (Radar & Area Charts)
- Runtime: Python 3.9
- API: FastAPI (Uvicorn ASGI)
- Data Processing: NumPy, Pandas
- Logic: Weighted Linear Regression & Normal Distribution Simulation
- Containerization: Docker
- Orchestration: Docker Compose
- Optimization: .dockerignore implementation for clean builds
Ensure the following tools are installed on the host machine:
- Docker Engine (v20.10+)
- Docker Compose (v2.0+)
The project is configured for rapid local deployment using Docker.
-
Clone the Repository
git clone https://github.com/f9-o/NPPCS.git
cd NPPCS -
Clean Build & Run Execute the following command to remove any cached layers and build the enterprise version:
docker-compose down --rmi all
docker-compose build --no-cache
docker-compose up
-
Verify Deployment The terminal will display:
NPPCS SYSTEM ONLINEACCESS DASHBOARD: http://localhost:8000
- Fullscreen Mode: Click the maximize icon in the navbar to enter immersive command center mode.
- Voice Assistant: Toggle the speaker icon to enable/disable audible alerts.
- Region Selection: Use the sidebar to instantly navigate between hospital facilities.
- Language: Toggle between English (LTR) and Arabic (RTL) for full localization.
This project is distributed under the MIT License. See the LICENSE file for more details.
Disclaimer: This software is a prototype developed for Hackathon demonstration purposes. It utilizes simulated data streams and is intended to showcase architectural capabilities for national medical resilience.