parag050701/VishwaSena_Ignisia2026_HC01

0

stars

20

commits

Python

primary language

Apr 4, 2026

updated

README

HC01 — ICU Clinical Decision Support System

Team VishwaSena · Ignisia 2026 · Healthcare Track

HC01 is a real-time AI clinical decision support system for ICU wards. It ingests patient vitals, labs, medications, and clinical notes, runs a multi-agent diagnostic pipeline powered by NVIDIA NIM, and delivers a full clinical report with voice output in under 60 seconds.


What It Does

  • 8-agent parallel pipeline — note parsing, outlier detection, medication safety, trajectory forecasting, RAG guideline retrieval, SOFA/NEWS2 scoring, and Nemotron 120B synthesis — all streaming live to the UI
  • Statistical outlier detection — Z-score over temporal lab series; triggers a diagnosis hold and flags lab values for redraw before acting on them
  • SOFA v2 + NEWS2 — implemented from scratch, medication-aware (detects vasopressors from the medication list), maps to MIMIC-IV mortality percentages
  • RAG clinical guidelines — NVIDIA nv-embedqa-e5-v5 embeddings + ChromaDB, retrieves top-5 relevant guidelines per patient and explains their relevance in context
  • Voice I/O — NVIDIA Riva gRPC for STT (Whisper Large v3), Microsoft Neural edge-tts for TTS; auto-speaks clinical summary when analysis completes
  • Ward assistant — natural language queries over all 120 patients ("how many critical patients?", "show me sepsis cases"), uses live diagnostic context for patient-specific answers
  • 270 patients — 150 real de-identified patients from MIMIC-III + 120 synthetic FHIR R4 patients covering sepsis, ARDS, cardiac, renal, neurological, and trauma cases

Stack

LayerTechnology
BackendPython 3.11, FastAPI, Uvicorn
FrontendVanilla JS + Chart.js (single HTML, no build step)
LLM — SynthesisNemotron 3-Super 120B (NVIDIA NIM)
LLM — AssistantLlama 3 8B (NVIDIA NIM)
LLM — VoiceQwen 2.5 7B (NVIDIA NIM)
Embeddingsnv-embedqa-e5-v5 (NVIDIA NIM)
STTNVIDIA Riva gRPC — Whisper Large v3
TTSMicrosoft Neural edge-tts (MP3)
RAG storeChromaDB + sentence-transformers
DataMIMIC-III CSVs + FHIR R4 JSON bundle
ValidationPydantic v2 (physiological range checks)

Architecture

PatientData (unified object)
     │
     ├── PHASE 1 [parallel]
     │   NOTE_PARSER · OUTLIER_DETECTOR · TREND_CLASSIFIER · TEMPORAL_LAB_MAPPER
     │
     ├── PHASE 2 [safety, parallel]
     │   MED_SAFETY · ALERT_ESCALATION
     │
     ├── PHASE 3 [parallel]
     │   TRAJECTORY_PREDICTOR · SEMANTIC_RETRIEVER · FAMILY_COMMUNICATOR
     │
     ├── PHASE 4  SOFA_NEWS2 scoring
     │
     └── PHASE 5  CHIEF_AGENT (Nemotron 120B) — streams token-by-token

Results stream over WebSocket as each agent completes. The UI updates live — no waiting for the full pipeline.


Running Locally

Requirements: conda, NVIDIA NIM API key

# 1. Create environment
conda create -n hc01 python=3.11
conda activate hc01
pip install -r requirements.txt
pip install edge-tts

# 2. Configure keys
cp .env.example .env
# Edit .env — add your NIM API key(s)

# 3. Add MIMIC-III data (requires PhysioNet access)
# Place CSVs in data/mimic/

# 4. Start server
uvicorn app.main:app --port 8000

# 5. Open frontend
# Open hc01-icu-assistant.html in a browser

API Endpoints

EndpointMethodDescription
/api/fhir-local/patientsGETList all 120 FHIR patients
/api/fhir-local/patient/{id}GETFull patient record
/api/fhir-local/diagnose/{id}POSTRun full analysis (blocking)
/ws/diagnoseWebSocketRun full analysis (streaming)
/api/priority-queueGETAll patients ranked by SOFA
/api/assistant/queryPOSTWard chatbot
/api/voice/synthesizePOSTText → MP3 speech
/api/voice/transcribePOSTAudio → transcript
/api/healthGETSystem status

Key Design Decisions

Diagnosis hold on outliers — if the latest lab value is a statistical outlier (Z > 2.5 vs prior readings), the system explicitly defers the working diagnosis and requires a confirmed redraw. This prevents acting on transcription errors or mislabeled samples.

Medication-aware SOFA — the cardiovascular component reads the medication list for vasopressors (norepinephrine, vasopressin, dopamine) rather than relying on a separate pressor flag field, making it robust to varied input formats.

No frontend build step — the entire UI is one HTML file. Intentional for demo reliability — no npm, no bundler, no broken deps at crunch time.

Async agents with shared context — agents communicate through a single AgentContext object passed by reference. No message queues, no inter-process communication. Results are available to downstream agents immediately.


Data Model

See HC01_DATA_MODEL_SIMPLE.md for a concise overview. See HC01_DATA_MODEL.md for full field-level schemas and protocol details.


Team

VishwaSena — Ignisia 2026 Hackathon

Contributors

sarvadnya2030

18 commits

parag050701

2 commits

parag050701/VishwaSena_Ignisia2026_HC01

0

stars

20

commits

Python

primary language

Apr 4, 2026

updated

README

HC01 — ICU Clinical Decision Support System

Team VishwaSena · Ignisia 2026 · Healthcare Track

HC01 is a real-time AI clinical decision support system for ICU wards. It ingests patient vitals, labs, medications, and clinical notes, runs a multi-agent diagnostic pipeline powered by NVIDIA NIM, and delivers a full clinical report with voice output in under 60 seconds.


What It Does

  • 8-agent parallel pipeline — note parsing, outlier detection, medication safety, trajectory forecasting, RAG guideline retrieval, SOFA/NEWS2 scoring, and Nemotron 120B synthesis — all streaming live to the UI
  • Statistical outlier detection — Z-score over temporal lab series; triggers a diagnosis hold and flags lab values for redraw before acting on them
  • SOFA v2 + NEWS2 — implemented from scratch, medication-aware (detects vasopressors from the medication list), maps to MIMIC-IV mortality percentages
  • RAG clinical guidelines — NVIDIA nv-embedqa-e5-v5 embeddings + ChromaDB, retrieves top-5 relevant guidelines per patient and explains their relevance in context
  • Voice I/O — NVIDIA Riva gRPC for STT (Whisper Large v3), Microsoft Neural edge-tts for TTS; auto-speaks clinical summary when analysis completes
  • Ward assistant — natural language queries over all 120 patients ("how many critical patients?", "show me sepsis cases"), uses live diagnostic context for patient-specific answers
  • 270 patients — 150 real de-identified patients from MIMIC-III + 120 synthetic FHIR R4 patients covering sepsis, ARDS, cardiac, renal, neurological, and trauma cases

Stack

LayerTechnology
BackendPython 3.11, FastAPI, Uvicorn
FrontendVanilla JS + Chart.js (single HTML, no build step)
LLM — SynthesisNemotron 3-Super 120B (NVIDIA NIM)
LLM — AssistantLlama 3 8B (NVIDIA NIM)
LLM — VoiceQwen 2.5 7B (NVIDIA NIM)
Embeddingsnv-embedqa-e5-v5 (NVIDIA NIM)
STTNVIDIA Riva gRPC — Whisper Large v3
TTSMicrosoft Neural edge-tts (MP3)
RAG storeChromaDB + sentence-transformers
DataMIMIC-III CSVs + FHIR R4 JSON bundle
ValidationPydantic v2 (physiological range checks)

Architecture

PatientData (unified object)
     │
     ├── PHASE 1 [parallel]
     │   NOTE_PARSER · OUTLIER_DETECTOR · TREND_CLASSIFIER · TEMPORAL_LAB_MAPPER
     │
     ├── PHASE 2 [safety, parallel]
     │   MED_SAFETY · ALERT_ESCALATION
     │
     ├── PHASE 3 [parallel]
     │   TRAJECTORY_PREDICTOR · SEMANTIC_RETRIEVER · FAMILY_COMMUNICATOR
     │
     ├── PHASE 4  SOFA_NEWS2 scoring
     │
     └── PHASE 5  CHIEF_AGENT (Nemotron 120B) — streams token-by-token

Results stream over WebSocket as each agent completes. The UI updates live — no waiting for the full pipeline.


Running Locally

Requirements: conda, NVIDIA NIM API key

# 1. Create environment
conda create -n hc01 python=3.11
conda activate hc01
pip install -r requirements.txt
pip install edge-tts

# 2. Configure keys
cp .env.example .env
# Edit .env — add your NIM API key(s)

# 3. Add MIMIC-III data (requires PhysioNet access)
# Place CSVs in data/mimic/

# 4. Start server
uvicorn app.main:app --port 8000

# 5. Open frontend
# Open hc01-icu-assistant.html in a browser

API Endpoints

EndpointMethodDescription
/api/fhir-local/patientsGETList all 120 FHIR patients
/api/fhir-local/patient/{id}GETFull patient record
/api/fhir-local/diagnose/{id}POSTRun full analysis (blocking)
/ws/diagnoseWebSocketRun full analysis (streaming)
/api/priority-queueGETAll patients ranked by SOFA
/api/assistant/queryPOSTWard chatbot
/api/voice/synthesizePOSTText → MP3 speech
/api/voice/transcribePOSTAudio → transcript
/api/healthGETSystem status

Key Design Decisions

Diagnosis hold on outliers — if the latest lab value is a statistical outlier (Z > 2.5 vs prior readings), the system explicitly defers the working diagnosis and requires a confirmed redraw. This prevents acting on transcription errors or mislabeled samples.

Medication-aware SOFA — the cardiovascular component reads the medication list for vasopressors (norepinephrine, vasopressin, dopamine) rather than relying on a separate pressor flag field, making it robust to varied input formats.

No frontend build step — the entire UI is one HTML file. Intentional for demo reliability — no npm, no bundler, no broken deps at crunch time.

Async agents with shared context — agents communicate through a single AgentContext object passed by reference. No message queues, no inter-process communication. Results are available to downstream agents immediately.


Data Model

See HC01_DATA_MODEL_SIMPLE.md for a concise overview. See HC01_DATA_MODEL.md for full field-level schemas and protocol details.


Team

VishwaSena — Ignisia 2026 Hackathon

Contributors

sarvadnya2030

18 commits

parag050701

2 commits

Languages

Python

78.1%

HTML

20.5%

Shell

1.4%