Case Study

Engineering a zero-hallucination agentic RAG system for clinical triage guidelines

Vstorm built a HIPAA-compliant agentic RAG system for Schmitt-Thompson Clinical Content, translating proprietary clinical triage guidelines into a zero-hallucination AI pipeline.

  • Healthcare
The outcome

Clinical triage where a wrong answer is a patient-safety event

STCC guidelines are decision trees, not prose. A fluent LLM that invents a disposition is a clinical risk. The pipeline treats the guidelines as the exclusive source of truth, introduces no external inference, and reports when it cannot find an answer rather than generating one.

The figures are from the STCC × Vstorm test suite: 329 nurse-validated scenarios across 16 adult after-hours telehealth guidelines. Zero hallucination events. Gaps that remain are deterministic retrieval and matching misses, in active development.

0%

Hallucinations across the full scenario set

Strict prompts and yes/no TAQ format leave no path to unsupported content.

329+

Nurse-validated scenarios used to test accuracy

Sixteen adult after-hours telehealth guidelines. Scenarios below a 95% expert CRD gate were discarded.

13 / 16

Guidelines within five percentage points of their benchmark

Two exceeded the expert benchmark outright. Three fell short on deterministic matching gaps, not hallucination.

About the client

Schmitt-Thompson Clinical Content (STCC) is one of the most widely deployed clinical decision-support publishers in North America. Its triage guidelines, structured clinical frameworks that determine urgency and route patients to the appropriate level of care, are in active use across more than 400 health systems and health plans, and in an additional 10,000 physician practices.

STCC provides the most comprehensive triage and advice content across the continuum of delivery: After Hours, used by call center nurses, and Office Hours, used in practices and clinics. Patty Maynard, Chief Operating Officer at STCC: “The STCC telehealth triage guidelines are used by thousands of nurses at hundreds of healthcare facilities around the world, marking STCC as the gold standard in the industry.”

Vstorm's impact

Vstorm's impact, the TL;DR

  • HIPAA-compliant agentic RAG that treats STCC guidelines as the exclusive source of truth — zero hallucination events on the test suite
  • Four-stage pipeline on PydanticAI, with Logfire tracing every stage
  • Relational database retrieval replaced pre-parsed PDF after nine Proof of Value iterations
  • 329 nurse-validated scenarios across 16 adult after-hours guidelines
  • 13 of 16 guidelines within five percentage points of their expert benchmark
  • Two deterministic failure modes (TAQ match and guideline selection) remain in active development

The challenge

Logic-based guidelines in a language-model world

STCC recognised that content built over decades and validated against expert clinical benchmarks had to be made machine-accessible. Competitors building AI-native tools would fill the gap, and public LLMs were already at risk of absorbing proprietary guideline content through uncontrolled data exposure. STCC came to Vstorm for a controlled, validated, HIPAA-compliant agentic system that could operate at clinical accuracy without any chance of hallucination.

The first challenge was not architecture. It was data. STCC guidelines are not written in natural language. They are structured as decision trees: sequential yes/no questions arranged in descending order of urgency, each linked to a recommended disposition such as “Go to ED Now” or “Home Care.”

That format is efficient for human practitioners and a specific failure risk for large language models. Standard LLMs are trained to interpret natural prose. When presented with branching conditionals, tabular urgency tiers, or Boolean qualifiers, they can misread the logic and produce confident but incorrect outputs. In a clinical setting, a misread is not an edge case to tolerate. It is a patient-safety risk.

The engineering brief was therefore precise: treat the guidelines as the exclusive source of truth, introduce no external inference, and report clearly when the system cannot find an answer rather than generating one.

How we delivered

TriStorm on content nurses already trust

The agent had to quote STCC guidelines, not a plausible-sounding disposition from the open web. Delivery ran against 329 nurse-validated scenarios, not a lab prompt set.

Lock the safety brief

Workshops aligned the technical roadmap with STCC clinical and compliance requirements. Guidelines stay the exclusive source of truth. No external inference. When the system cannot find an answer, it reports the absence.

  • Clinical and HIPAA brief
  • Exclusive-source rule
  • No-answer reporting

Proof of Value on real guidelines

Nine iterations (v0.3.x through v9.1) compared three GPT versions and PDF versus database retrieval, then settled on a four-stage agentic pipeline. Database retrieval won on disposition accuracy and operational scale. GPT-5.1 became the production model.

  • Four-stage pipeline
  • Database-backed RAG
  • GPT-5.1 under HIPAA config

Validate, then keep going

The suite: 329 scenarios across 16 guidelines. Thirteen landed within five percentage points of their benchmark. Two deterministic gaps — TAQ matching and ambiguous guideline selection — are in active development, including a locally deployable variant for stricter data residency.

  • 329-scenario eval suite
  • Failure-mode log
  • Local-deploy track

How it works

A four-stage pipeline, then a database instead of a PDF

Vstorm designed a four-stage agentic pipeline to handle the full scenario-to-disposition workflow. The pipeline runs on the PydanticAI framework, with Logfire providing observability across every stage. Every decision is traceable. Every step is auditable.

Incoming clinical scenario Free-text presentation
Stage 1 — patient context Extract age and gender; filter the guideline set
Stage 2 — reason for visit Primary and secondary reason, structured — not raw prose
Stage 3 — guideline selection via RAG Match the reason against the guideline vector store, then classify
Stage 4 — parallel TAQ evaluation Triage Assessment Questions across disposition levels, Boolean on multi-part TAQs
Recommended disposition
SOAP clinical note
LLM rationale Optional

STCC × Vstorm — four-stage agentic pipeline

Stage 1 extracts patient age and gender so the applicable guideline set is filtered before any clinical reasoning begins. Stage 2 identifies the primary and secondary reasons for the visit, so retrieval receives clean inputs rather than raw prose. Stage 3 matches that reason against a pre-indexed guideline vector store using retrieval-augmented generation, then classifies the most appropriate guideline — the stage where selection errors concentrate on clinically ambiguous presentations. Stage 4 evaluates Triage Assessment Questions concurrently across disposition levels. Multi-part TAQs are parsed with Boolean logic so a partial match cannot produce a disposition.

In earlier Proof of Value builds, guideline content reached retrieval as a pre-parsed PDF. That was fast to prototype and introduced structural noise: fragmented chunks broke the logical continuity of individual guidelines, particularly around multi-step TAQ sequences. The team moved to a relational database. Guidelines were indexed as structured records with explicit relationships between questions, urgency tiers, and disposition outcomes. Database retrieval outperformed PDF delivery in both disposition accuracy and operational scalability across the full test suite.

Retrieval method

Why the team left pre-parsed PDF behind

PDF retrieval
Pre-parsed PDF
  • Fast to prototype
  • Fragmented chunks
  • Broken TAQ sequences
  • Logic continuity lost
  • Lower disposition accuracy
Database retrieval
Relational database
  • Structured records indexed
  • Logic preserved
  • Questions, tiers, outcomes linked
  • Clean context on every call
  • Higher accuracy, scalable

Model selection across three GPT versions

The team evaluated three GPT model versions across Proof of Value builds v0.3.x through v9.1: GPT-4.1, GPT-5, and GPT-5.1. All models ran with HIPAA compliance configurations, a non-negotiable requirement given the sensitivity of patient scenario data.

GPT-5 and GPT-5.1 consistently outperformed GPT-4.1 across the guideline test suite. The gap was most pronounced in clinically complex scenarios that require multi-step reasoning across branching TAQ sequences. GPT-5.1 was selected as the production model, offering the strongest balance of disposition accuracy and reasoning reliability within the compliance constraints.

Testing and validation: 329 scenarios, 16 guidelines

Clinical scenarios used to evaluate the system were developed through a 14-step validation process managed jointly by STCC and Vstorm. STCC Nurse Editors drafted scenarios for each guideline. Scenarios were revised or discarded where editorial agreement could not be reached. Remaining scenarios went to a panel of five expert telehealth triage nurses. Only scenarios where the panel's aggregate Correct Recommended Disposition (CRD) rate reached 95% or higher were retained and reviewed by the Senior Medical Editor.

The final test set comprised 329 validated clinical scenarios across 16 adult after-hours telehealth guidelines. Chatbot disposition accuracy was measured against this expert-validated benchmark — not against theoretical correctness, but against the standard established by practising clinicians.

Benchmark preparation Nurse editors draft scenarios — one set per guideline
Editorial review Revised or discarded if no agreement
Expert nurse panel Five telehealth triage nurses
95% CRD threshold Below threshold discarded
Senior medical editor 329 validated scenarios ready
System under test Agentic RAG pipeline, GPT-5.1 + database retrieval

STCC × Vstorm — scenario validation process

Results

What the 329-scenario suite showed

Full-scenario disposition accuracy was strong across the majority of guidelines tested. Thirteen of 16 guidelines demonstrated chatbot accuracy within five percentage points of their respective benchmarks. Two guidelines exceeded the benchmark: Abdominal Pain — Male (100% vs. 96.2%) and Headache (100% vs. 97.4%).

Three guidelines underperformed the benchmark: Neurologic Deficit (85.0% vs. 96.0%), Cough — Acute Productive (84.0% vs. 98.3%), and Urinary Symptoms (84.0% vs. 98.4%).

FIG. 1 · RESULTS
Chatbot accuracy against the expert benchmark, by guideline

Bar = measured chatbot accuracy. The tick on each track is that guideline's own expert benchmark. Every guideline is judged against its own benchmark, not a single shared target.

Hover a bar for the measured value, the benchmark, and the gap in percentage points
Abdominal Pain — Male 100% +3.8pp
Headache 100% +2.6pp
Neurologic Deficit 85.0% −11.0pp
Cough — Acute Productive 84.0% −14.3pp
Urinary Symptoms 84.0% −14.4pp
Measured accuracy Below its benchmark Expert benchmark
Data table
Chatbot accuracy against the expert benchmark, by guideline
GuidelineChatbotExpert benchmarkGap
Abdominal Pain — Male100%96.2%+3.8pp
Headache100%97.4%+2.6pp
Neurologic Deficit85.0%96.0%−11.0pp
Cough — Acute Productive84.0%98.3%−14.3pp
Urinary Symptoms84.0%98.4%−14.4pp
STCC × Vstorm test suite — 329 nurse-validated scenarios across 16 adult after-hours telehealth guidelines. Five named guidelines shown; benchmarks are the expert panel's Correct Recommended Disposition rates.
STCC × Vstorm — disposition accuracy vs expert benchmark
ResultGuidelinesNotes
Within benchmark13 / 16Chatbot accuracy within 5 percentage points of benchmark
Exceeded benchmark2 / 16Abdominal Pain — Male (100% vs. 96.2%), Headache (100% vs. 97.4%)
Below benchmark3 / 16Neurologic Deficit (85.0% vs. 96.0%), Cough — Acute Productive (84.0% vs. 98.3%), Urinary Symptoms (84.0% vs. 98.4%)

Post-analysis identified two primary failure modes. The most frequent was no positive TAQ identified: the system correctly selected the guideline but failed to match any TAQ to the clinical scenario, producing an incomplete disposition. The second was incorrect guideline selection on overlapping or ambiguous chief complaints, where two or more guidelines were plausible matches at retrieval.

Both failure modes are deterministic. They do not arise from hallucination or fabricated reasoning. They come from retrieval and matching gaps that targeted engineering can close. The testing also confirmed zero hallucination events across the full scenario set. When the system could not identify an answer, it reported the absence of a match and provided traceable source references, or the explicit absence of them.

What is still in flight

The system remains in active development. TAQ matching logic is being extended to handle scenarios where no positive TAQ is present: a condition the current pipeline flags but does not yet resolve. Guideline selection is being improved for ambiguous chief-complaint presentations through enhanced retrieval ranking and disambiguation logic.

In parallel, Vstorm is developing a locally deployable model variant designed to run on client-owned infrastructure. That addresses healthcare environments with stricter data residency constraints, where patient history and treatment records cannot leave the organisation's perimeter. The local model is being engineered with reinforced anti-hallucination constraints and explicit data boundary controls, so a higher degree of patient context can be passed into the system safely.

Work with us

Ready to see how agentic AI transforms clinical triage workflows?

Meet directly with our founders and PhD AI engineers. We will walk through real implementations from 30+ agentic projects and the practical steps to integrate them into your workflows.