MSR Logo
Two Years of Intensive R&D

The AI Brain Behind Every Hospital Decision

MedAI Platform โ€” 7 integrated microservices, 8 trained ML models, 260M+ clinical records. From OPD to Emergency to ICU to Discharge โ€” one unified AI system built by Lattice Consulting for MSR Ramaiah Group.

MedAI LLM Platform

7 Microservices

8 ML Models

260M+ Records

<5ms Inference

๐ŸŽฌ Platform Demo

MedAI Platform Technical Documentation & Clinical Decision Support System

A full walk-through of the MedAI decision support system, the 7-microservice LLM architecture, and the clinical insights dashboard tailored for India's hospital workflows.

๐Ÿฅ The Core Problem

Why India's Hospitals Need an AI Brain

Operating a full-scale hospital โ€” from OPD to emergency to surgery to ICU to discharge โ€” generates millions of data points daily. Yet critical decisions are still made on intuition, not intelligence.

๐Ÿšจ

ED Overcrowding

Average wait time 42 minutes. ESI mis-triage rate ~18% nationally. Every misclassification risks lives โ€” or wastes critical resources on non-urgent cases.

โš ๏ธ

Late Sepsis Recognition

6-hour delay in detection โ†’ 7.6% increase in mortality per hour. The difference between life and death is measured in hours, not days.

๐Ÿ›๏ธ

Bed Misallocation

15โ€“25% of hospital beds occupied by patients in wrong acuity level. Resources wasted while critical patients wait.

๐Ÿ”ฌ

Cancer Readmission Crisis

26% 30-day readmission rate in oncology โ€” entirely preventable with AI-powered risk stratification. Each readmission costs the hospital โ‚น2โ€“5 lakhs and the patient immeasurable suffering.

๐Ÿง  The Architecture

7 Microservices. 1 Unified Brain.

A monorepo architecture with seven specialized AI services, a real-time simulation engine, and a unified React dashboard โ€” powered by 260M+ clinical records from MIMIC-IV.

MedAI 7-Microservice Architecture
๐Ÿš‘

ED Triage

5-class ESI prediction from 59 features. XGBoost + Neural Network dual-model.

๐Ÿซ€

Sepsis ICU

Continuous sepsis monitoring with Bi-LSTM temporal attention. 6-hour sliding windows.

๐Ÿฅ

Hospital Ops

Multi-Agent RL (MADDPG) for staffing optimization. 8 departments as autonomous agents.

๐Ÿ”ฌ

Oncology AI

TabTransformer + XGBoost for readmission/mortality prediction. Treatment pathway engine for 8 cancer types.

๐Ÿ“‹

Patient Journey

Unified clinical timeline explorer. Vitals, labs, meds, transfers โ€” cohort comparison across 5 patients.

๐Ÿ’ฌ

Clinical Chat

Local LLM via Ollama. Natural language clinical queries with smart routing to ED/Oncology/Journey APIs.

โšก

Simulation Engine

Real-time replay of MIMIC patient journeys. WebSocket event streaming. ~30 patients/sim-day.

โš›๏ธ React 19 โšก Vite 6.3 ๐Ÿ FastAPI ๐Ÿƒ MongoDB 7.x ๐Ÿ”ฅ PyTorch ๐ŸŒฒ XGBoost ๐Ÿ’ก LightGBM ๐Ÿฆ™ Ollama LLM ๐ŸŽฎ NVIDIA CUDA 12.8
๐Ÿค– AI Model Portfolio

8 Trained ML Models Across 4 Clinical Domains

Every model trained on real de-identified clinical data from MIMIC-IV (260M+ documents). Not synthetic benchmarks โ€” real patient journeys.

TriageXGBoost

ED Triage ยท 5-Class Classification ยท 300 Estimators

0.653 Weighted F1
0.728 AUROC

59-feature vector with missingness flags. GPU-accelerated training on RTX 4060. Stratified 70/15/15 split across 299K ED admissions.

SepsisLGBM

ICU Sepsis ยท Binary Classification ยท 1000 Estimators

0.994 AUROC
1.000 Sensitivity

114 features from 6-hour sliding windows. 19 vitals ร— 6 statistical aggregations. Cost-sensitive learning for class imbalance.

SepsisLSTM

ICU Sepsis ยท Bidirectional LSTM + Temporal Attention

0.998 AUROC

Input shape: (batch, 6 timesteps, 19 features). Temporal attention identifies which hours are most predictive. Clinically interpretable.

OncologyRiskXGB

Oncology ยท Multi-Task Binary ยท 16 Features

0.734 Readmission
0.897 Mortality

Dual XGBoost models for 30-day readmission and in-hospital mortality. 67K admissions, 29K unique patients, 30+ cancer categories.

OncologyTransformer

TabTransformer ยท d_model=64 ยท 4 Attention Heads

0.733 Readmission
0.876 Mortality

Treats tabular features as a sequence with positional encoding. Learns feature interactions without manual feature crosses.

MADDPG Agent

Hospital Ops ยท Multi-Agent RL ยท Continuous Control

15% Wait โ†“
18% Throughput โ†‘

Curriculum learning: Stage 1 (ED only) โ†’ Stage 2 (ED+ICU+Medicine) โ†’ Stage 3 (all 8 departments). Ornstein-Uhlenbeck exploration.

๐Ÿฉบ The Patient Journey

From OPD to Discharge โ€” Every Step AI-Augmented

One fully integrated web stack application delivering cutting-edge AI at every clinical touchpoint. No gaps, no blind spots, no manual workarounds.

AI-Augmented Hospital Patient Journey
1

OPD Registration

Patient arrives. ABHA ID linked. Demographics captured. History retrieved from MongoDB.

2

ED Triage

AI predicts ESI level in <2 seconds. 94% confidence. Auto-disposition recommendation.

3

ICU Monitoring

Continuous sepsis surveillance. SOFA scoring. 4-6 hour early warning before clinical deterioration.

4

Treatment Planning

Oncology pathway generation. Risk stratification. NCCN-aligned treatment protocols for 8 cancer types.

5

Discharge

AI-optimized staffing via MADDPG. Readmission risk assessed. Follow-up automatically scheduled.

๐Ÿ“Š Clinical Advantages

Performance That Changes Outcomes

Measured improvements over traditional hospital systems โ€” backed by MIMIC-IV validation data.

Metric Traditional System MedAI Platform Improvement
Sepsis Detection Lead TimeAt clinical recognition4-6 hours BEFORE recognitionAUROC 0.994
ED Triage ConsistencyInter-rater ฮบ = 0.62F1 = 0.653 (eliminates variability)Zero human bias
Oncology Risk AssessmentManual chart review (30 min)Instant prediction (<5ms)360ร— faster
Staffing OptimizationManual schedulingMARL-optimized15% wait โ†“
Patient Data ExplorationSeparate EHR screensUnified timeline + cohortSingle interface
๐Ÿš€ Two Years of R&D

โ‚น6.5 Crore Invested. Platform Built. Clinical Trial Ready.

From concept to 7-microservice production system โ€” a rigorous journey of research, development, and validation by Lattice Consulting Worldwide.

Q1 2024 โ€” Foundation

Deep research into hospital operations challenges. MIMIC-IV data acquisition and MongoDB ingestion pipeline. 260M+ documents across 30+ collections.

Q2-Q3 2024 โ€” Model Development

ED Triage XGBoost + Neural Network training (299K admissions). Sepsis LSTM with temporal attention. GPU-accelerated training on RTX 4060.

Q4 2024 โ€” Advanced AI

Oncology TabTransformer + Risk XGB. MADDPG multi-agent RL for hospital ops. HospitalEventEngine for real-time simulation.

Q1 2025 โ€” Integration

React 19 dashboard unification. 7 FastAPI services. Clinical Chat with local Ollama LLM. WebSocket real-time streaming.

Q2-Q4 2025 โ€” Validation

Performance benchmarking. AUROC 0.994 sepsis detection. Clinical validation protocol design for MS Ramaiah. CDSCO SaMD documentation.

2026 โ€” Clinical Deployment

Clinical pilot at M.S. Ramaiah ED (500+ patients). ABDM Health ID integration. Production Docker deployment. Pan-India & global expansion planning.

๐ŸŒ India & Global Expansion

Setting the Global Benchmark for Hospital AI

After clinical trial approval at MSR Ramaiah, MedAI becomes the benchmark application for the hospital industry โ€” first across India, then ASEAN, Middle East & Africa.

India and Global Expansion Strategy

Three-Phase Global Strategy

Phase 1 โ€” Karnataka (2026)

Clinical validation pilot at M.S. Ramaiah hospitals. 500+ patient study. CDSCO SaMD Class B submission. ABDM integration.

Phase 2 โ€” Pan-India (2027-28)

Multi-hospital deployment via federated learning. FHIR R4 EHR interoperability. Edge deployment on NVIDIA Jetson for rural clinics. ISO 13485 + 27001 certification.

Phase 3 โ€” Global Export (2028-29)

Full Make in India (80-85% local content). CE recertification for export markets. Expansion to ASEAN, Middle East & Africa โ€” addressing the $2.7B global telehealth kiosk market. PLI scheme incentives (5% on incremental sales).

๐Ÿ“‹ Real-World Case Studies

AI in Action โ€” Clinical Scenarios

Four validated clinical scenarios demonstrating measurable impact at every stage of the hospital journey.

๐Ÿš‘

ED Triage โ€” Chest Pain

55-year-old male, ambulance arrival, diaphoresis

Vitals: HR 118 ยท RR 24 ยท SpO2 91% ยท SBP 92/58
AI Output: ESI-2 (Emergent) ยท 94.1% confidence
Flags: Tachycardia, Hypoxia, Hypotension, Elevated lactate

Impact: Consistent triage in <30 seconds vs. 3-5 minutes manually. Eliminates inter-rater variability.

๐Ÿซ€

Sepsis โ€” Post-Surgery ICU

68-year-old, post-cholecystectomy, SICU Day 2

6-Hour Window: HR 88โ†’108 ยท RR 18โ†’24 ยท Temp 37.2โ†’38.4
AI Output: Risk 0.72 โ†’ ORANGE alert ยท SOFA 4โ†’6
Action: Blood cultures + empiric antibiotics started

Impact: 4-6 hour early detection. Each hour of early treatment reduces mortality by ~7.6%.

๐Ÿ”ฌ

Oncology โ€” Treatment Planning

62-year-old, Stage III NSCLC, Charlson 4

Risk: Readmission 48.2% ยท Mortality 22.7%
Pathway: 100-day plan ยท Urgency 78/100
Steps: Staging โ†’ Neoadjuvant Chemo โ†’ VATS โ†’ Radiation

Impact: Instant risk stratification + complete treatment pathway vs. 30-minute manual chart review.

๐Ÿฅ

Hospital Ops โ€” MADDPG

7-day simulation, 8 departments, MIMIC arrival patterns

Wait Time: -15% vs. baseline
Throughput: +18% vs. baseline
Efficiency: 85% (up from 72%)

Impact: 42 shift cells ร— 8 departments automatically optimized. No manual scheduling needed.

๐Ÿ›ก๏ธ Regulatory & Compliance

Clinical Trial Ready. Standards Compliant.

Positioned as a CDSS (Clinical Decision Support System) โ€” not autonomous diagnosis. Designed for CDSCO SaMD Class B/C compliance.

๐Ÿ›๏ธ

CDSCO SaMD Classification

Class B (medium risk). Non-autonomous โ€” clinician makes final decision. All outputs include: "AI-assisted assessment โ€” final clinical decision rests with the treating physician."

๐Ÿ“‹

Clinical Validation Protocol

Prospective observational study at MS Ramaiah ED. 500+ patients. AI accuracy vs. nurse accuracy (attending as gold standard). IRB approved.

๐Ÿ‡ฎ๐Ÿ‡ณ

ABDM Integration

ABHA Health Account linkage. Consent-based data sharing via Health Information Exchange. FHIR R4 DiagnosticReport resources.

Regulatory Compliance Framework
ISO 13485Medical Device QMS
ISO 27001InfoSec Management
HIPAADe-identified by Source
GDPR ReadyConsent + Deletion
DPDP Act 2023India Data Protection
๐Ÿ”’ Security & Data Privacy

Zero External Dependencies. Zero Data Leakage.

Every byte of patient data stays within the hospital network. The LLM runs locally via Ollama โ€” no API calls to external providers. Ever.

๐Ÿ”

Local LLM Inference

Clinical Chat runs entirely on hospital hardware via Ollama. Supports Llama 3.1 (128K context) and Mistral (32K). No patient data ever leaves the network perimeter.

๐Ÿ›ก๏ธ

MIMIC-IV Pre-De-identified

All training data is pre-de-identified by PhysioNet. Dates shifted, PHI removed. No re-identification possible.

๐Ÿ”‘

Role-Based Access

5-tier RBAC: Admin, Physician, Nurse, Resident, IT Support. Each role sees only what they need.

๐Ÿ“Š

Complete Audit Trail

Every API request, prediction, and simulation event is logged with timestamp, endpoint, user_id, request hash, and response status. TLS 1.3 encryption in transit. MongoDB WiredTiger encryption at rest.

๐ŸŒ Competitive Benchmark

How MedAI LLM Leads the Industry

FeatureMedAIEpic SepsisGoogle Health AIViz.ai
Multi-Domain Coverageโœ… 7 modulesSepsis onlyImaging focusedStroke only
Local LLMโœ… OllamaโŒCloud-dependentโŒ
Simulation Engineโœ… Real-timeโŒโŒโŒ
India CDSCO/ABDMโœ… ReadyUS onlyLimitedUS only
Cost Modelโœ… Infra onlyLicense feePer-APIPer-case

Ready to Deploy AI Across Your Hospital?

Partner with M.S. Ramaiah Group & Lattice Consulting to bring MedAI's 7-microservice AI platform to your healthcare institution.

๐Ÿ“ž +91-6360248176
๐Ÿ‘ค Dr. Lokesh Sadasivan (Director)
๐Ÿข Lattice Consulting Worldwide
๐Ÿ“ง info@latticec.com
๐Ÿ’ฌ