# Two-stage AI triage: Claude on Bedrock plus a conformal ML ensemble, on DynamoDB and Vercel

> Source: <https://dev.to/dhruv_jain_8b924cc8f63fb8/two-stage-ai-triage-claude-on-bedrock-plus-a-conformal-ml-ensemble-on-dynamodb-and-vercel-50a>
> Published: 2026-06-29 06:02:05+00:00

Solace assigns an emergency-department acuity level (ESI) from a patient's own words and then refines it at the bedside. I wanted a model that helps a clinician without ever pretending to make the call. Here is how the triage brain works, and how it sits on DynamoDB and Vercel.

A patient describes what is wrong by voice or text, in any of 20+ languages (speech runs through Amazon Transcribe and Polly). Amazon Bedrock (Claude) reads that narrative and produces a provisional ESI before any vitals exist. This is what powers the calm spoken result the patient hears and the first sort of the live clinician queue.

Everything runs inside AWS managed services covered by the Business Associate Agreement, so patient text never leaves the BAA boundary.

When vitals are entered, a stacked ensemble (LightGBM, XGBoost, CatBoost, and an MLP) refines the ESI. Two things make it usable in a real department:

A deterministic safety floor sits on top: the system never down-triages a life threat, regardless of what the model thinks.

The refined ESI, the conformal set, and the top features are written back onto the patient record in DynamoDB, so the clinician cockpit reads a single, current source of truth in milliseconds. The cockpit and the patient app both deploy on Vercel and call the FastAPI-on-Lambda backend that fronts DynamoDB.

The model never overrides the clinician. It hands them a defensible starting point, shows its work, and gets out of the way.

I created this content for the purposes of entering the H0: Hack the Zero Stack hackathon. #H0Hackathon
