# AI Patient Care Platform

A comprehensive AI-powered digital platform focused on the patient care pathway for Lymphoproliferative Disorders, specifically targeting Diffuse Large B-Cell Lymphoma (DLBCL). The platform consolidates patient data, generates AI-assisted clinical decision reports, and automates administrative tasks.

## 🎯 Project Overview

This platform is designed to support three distinct user roles with specific workflows and access levels:

- **Consultant/Lead Clinician**: Full clinical access with ability to approve MDT reports
- **Junior Doctor**: Limited access with ability to draft reports and add clinical notes
- **Super Admin**: System administration with user management capabilities

## ✨ Key Features

### 🔐 Role-Based Authentication
- Secure login system with role-based access control
- Three distinct user interfaces based on user permissions
- Session management with persistent login

### 👥 Patient Management
- Comprehensive patient profiles with detailed medical information
- Search and filter functionality for patient records
- Add new patients with complete demographic and clinical data
- Side panel with patient basic details and contact information

### 📋 Clinical Data Management
- **Clinical Notes**: Structured note-taking with editor and list view
- **Imaging Reports**: Upload and manage medical imaging files
- **MDT Reports**: AI-generated reports with approval workflow
- **Consent Forms**: Digital consent form management
- **Appointments**: Automated appointment scheduling

### 📊 Role-Specific Dashboards
- **Consultant Dashboard**: Overview of active cases, pending reviews, and appointments
- **Junior Doctor Dashboard**: Assigned patients, draft reports, and pending tasks
- **Super Admin Dashboard**: System statistics, user management, and activity monitoring

### 🤖 AI-Powered Features
- AI-assisted MDT report generation
- Clinical decision support recommendations
- Automated administrative task handling

## 🛠️ Technology Stack

- **Frontend**: React 18 with TypeScript
- **Styling**: Tailwind CSS with custom medical theme
- **Routing**: React Router v6
- **Icons**: Lucide React
- **State Management**: React Context API
- **Build Tool**: Create React App

## 🚀 Getting Started

### Prerequisites
- Node.js (v16 or higher)
- npm or yarn package manager

### Installation

1. **Clone the repository**
   ```bash
   git clone <repository-url>
   cd ai-patient-care-platform
   ```

2. **Install dependencies**
   ```bash
   npm install
   ```

3. **Start the development server**
   ```bash
   npm start
   ```

4. **Open your browser**
   Navigate to `http://localhost:3000`

### Demo Credentials

The application includes demo accounts for testing different user roles:

| Role | Email | Password |
|------|-------|----------|
| Consultant | dr.smith@hospital.com | password |
| Junior Doctor | dr.jones@hospital.com | password |
| Super Admin | admin@hospital.com | password |

## 📱 Responsive Design

The platform is fully responsive and optimized for:
- **Desktop**: Full-featured interface with side panels and detailed views
- **Tablet**: Adapted layout with collapsible navigation
- **Mobile**: Touch-friendly interface (basic support)

## 🏗️ Project Structure

```
src/
├── components/          # Reusable UI components
│   ├── Dashboard/      # Role-specific dashboard components
│   └── Layout/         # Layout and navigation components
├── contexts/           # React Context providers
├── data/              # Mock data and sample content
├── pages/             # Main application pages
├── types/             # TypeScript type definitions
└── App.tsx            # Main application component
```

## 🎨 Design System

The platform uses a medical-focused design system with:
- **Primary Colors**: Blue tones for trust and professionalism
- **Medical Colors**: Green accents for health-related elements
- **Typography**: Inter font family for readability
- **Components**: Consistent button styles, cards, and form elements

## 🔧 Available Scripts

- `npm start` - Start development server
- `npm build` - Build for production
- `npm test` - Run test suite
- `npm eject` - Eject from Create React App

## 📋 Key Features Implemented

### ✅ Authentication & Authorization
- Role-based login system
- Protected routes
- Session persistence

### ✅ Patient Management
- Patient list with search and filtering
- Detailed patient profiles
- Add new patient functionality
- Comprehensive patient information display

### ✅ Clinical Data Management
- Clinical notes with editor
- Imaging report upload and management
- MDT report generation and approval workflow
- Consent form management
- Appointment scheduling

### ✅ Role-Specific Workflows
- Consultant: Full access with approval capabilities
- Junior Doctor: Limited access with drafting capabilities
- Super Admin: User and system management

### ✅ Responsive Design
- Mobile-first approach
- Tablet and desktop optimizations
- Touch-friendly interface elements

## 🚧 Future Enhancements

- Real-time notifications
- Advanced AI integration
- Electronic health record (EHR) integration
- Mobile app development
- Advanced reporting and analytics
- Multi-language support

## 📄 License

This project is developed for educational and demonstration purposes.

## 🤝 Contributing

This is a demonstration project. For production use, additional security measures, testing, and compliance features would be required.

---

**Note**: This is a high-fidelity frontend mockup with dummy data. In a production environment, this would be connected to a backend API and real patient data systems with appropriate security and compliance measures.
