AI / ML · 2026
PreTriage
PreTriage guides patients through a voice-assisted intake before their appointment — so clinicians start every consult with full context, not blank questions.
Overview
PreTriage guides patients through a voice-assisted intake before their appointment — so clinicians start every consult with full context, not blank questions.
Stack
AI · Next.js 16 · FastAPI · ElevenLabs · Anthropic · Groq · PostgreSQL · Redis · Socket.io
What I Built
Problem
Every consult starts the same way: a clinician walks in, sits down, and spends the first five minutes asking basic questions the patient has answered a dozen times before. What brings you in? How long has this been going on? Any relevant history? It's not inefficient because clinicians are bad at their jobs — it's inefficient because the information was never collected before they walked through the door.
Solution
Before the appointment, patients complete a short voice-guided intake through PreTriage — tap-based, no typing, no app download required. ElevenLabs reads each question aloud; patients respond with a single tap. By the time the clinician enters the room, an AI-generated summary is already waiting: chief complaint, urgency tier (P1–P4), clinical flags, duration, relevant history, and a suggested focus for the consult.
Architecture
Frontend — Next.js 16 (App Router), React 19, TypeScript, Tailwind CSS v4, Zustand for client state, shadcn/ui components — Voice layer — ElevenLabs SDK for text-to-speech question delivery; fully tap-driven, zero keyboard interaction — Backend — FastAPI + uvicorn, Python; real-time push via python-socketio + socket.io-client — AI layer — Anthropic SDK for structured triage summary generation; Groq (llama-3.1-8b-instant) as a low-latency fallback — Data — PostgreSQL via asyncpg / SQLAlchemy / Alembic; Redis for session state and queue management
Key Features
Voice-guided questions via ElevenLabs — no typing required for patients — Branching question logic adapts in real time based on patient responses (up to 10 questions) — AI triage summary with urgency tier (P1–P4), clinical flags, and suggested focus — Real-time clinician dashboard updated over WebSockets the moment intake completes — Urgency detection — Critical, High, Moderate, and Low with non-negotiable overrides for cardiac/respiratory — Demo mode for portfolio visitors — no account required
Outcome
Deployed and live at pretriage.vercel.app. Demonstrates production-grade voice + LLM integration within a clinical workflow, with a real-time full-stack architecture spanning WebSockets, PostgreSQL, and Redis.


