Agents Assemble Healthcare AI Hackathon 2026
ClinicalMem Logo

ClinicalMem

6-Layer Clinical Safety Pipeline

Persistent, Auditable, Contradiction-Safe Clinical Memory for Healthcare AI Agents

771 Tests · 100% Coverage MCP A2A FHIR R4 UMLS 6 Safety Layers
18
MCP Tools
13
A2A Tools
13
Engine Modules
4
Conflicts
2 Crit 2 High

Live Patient Scenario

SM

Sarah Mitchell

MRN: SM-2026-0847 • DOB: 1959-03-14

2 CRITICAL 2 HIGH

Demographics

Age67
SexFemale
Providers4 Active
Medications7 Active

Active Conditions

Type 2 Diabetes
Hypertension
CKD Stage 3b
Atrial Fibrillation

Active Medications

Warfarin 5mg
Ibuprofen 400mg
Metformin 1000mg
Lisinopril 20mg
Amlodipine 10mg
Amoxicillin 500mg
Atorvastatin 40mg
Allergies: Penicillin (anaphylaxis)

Safety Findings

Warfarin + Ibuprofen

CRITICAL

ER prescribed NSAID without checking anticoagulant. Massively increased bleeding risk.

Layer 1: Deterministic Layer 3: RxNorm

Penicillin Allergy + Amoxicillin

CRITICAL

Amoxicillin is a penicillin-class antibiotic. Cross-reactivity detected via SNOMED CT drug hierarchy.

SNOMED CT Layer 1: Deterministic

Declining GFR + Metformin

HIGH

eGFR declining over 6 months. Approaching metformin contraindication at <30.

Danger <30 50 40 30 45 38 32 6mo ago 3mo ago Now
Lab Trend Analysis Lab-Med Contraindication

Conflicting BP Targets

HIGH

Cardiologist targets <130/80 vs Nephrologist <140/90. Conflicting treatment plans.

Provider Disagreement Cross-Provider

Bonus: 2 additional findings discovered autonomously

  • INR 3.8 — above therapeutic range, correlated with ibuprofen addition
  • eGFR declining trajectory — 13-point drop over 6 months

What-If Drug Substitution Simulator

INTERACTIVE

What happens if we swap the dangerous NSAID for a safer alternative?

Ibuprofen 400mg NSAID
Acetaminophen 500mg Non-NSAID
-1
Critical Resolved
Warfarin+NSAID eliminated
Safe
INR Impact
No bleeding risk increase
3
Remaining Findings
1 critical, 2 high

6-Layer Safety Pipeline

Each layer adds confidence. Together they prevent hallucinations about patient safety.

1

Deterministic Table

Rule-based — never hallucinates

<1ms
2

OpenEvidence API

Mayo Clinic / Elsevier ClinicalKey AI

~2s
3

RxNorm API

Drug normalization + NIH interaction DB (Epic/Cerner standard)

~1s
4

Multi-LLM Consensus

6 US-based models must agree

~3s
6/6 AGREE
GPT-5.4 Gemini 3.1 Pro Grok 4.1 Claude Opus 4.6 Perplexity Sonar Gemini Flash
5

LLM Synthesis

Evidence-cited clinical explanations

~3s
6

Abstention Gate

"I don't know" when evidence insufficient — refuses to guess

0ms
Deterministic
Evidence APIs
LLM-Powered
Safety Gate

Clinical Terminology Integration

Three NIH/NLM vocabulary systems power coded clinical reasoning

RxNorm

Drug normalization + interaction detection. Resolves brand names to ingredients, checks NIH interaction DB.

Drug Normalize Interactions

SNOMED CT

Allergy cross-reactivity via drug class hierarchy. 8 drug classes with alias expansion.

8 Drug Classes Cross-Reactivity

UMLS Metathesaurus

Cross-vocabulary mapping: ICD-10 ↔ SNOMED CT ↔ LOINC ↔ RxNorm via CUI equivalence.

Crosswalk 6 Vocabularies

SHA-256 Audit Trail

Tamper-proof Merkle chain — every clinical decision is cryptographically linked

BLOCK #0 — GENESIS

Patient data ingested: Sarah Mitchell (47 FHIR R4 resources)

a3f8c2e1...d7b94e6f ← prev: 0000000000000000
BLOCK #1 — CRITICAL

Drug interaction: Warfarin + Ibuprofen (severity=CRITICAL)

7e2b5f91...c4a83d2e ← prev: a3f8c2e1...d7b94e6f
BLOCK #2 — CRITICAL

Allergy conflict: Penicillin allergy + Amoxicillin (SNOMED CT cross-reactivity)

b1d4e7a3...f82c6d19 ← prev: 7e2b5f91...c4a83d2e
BLOCK #3 — HIGH

Lab trend: eGFR declining 45→38→32, metformin contraindication approaching

c8f2a196...e3d7b4a5 ← prev: b1d4e7a3...f82c6d19

Every block's SHA-256 hash includes the previous block's hash — HIPAA-grade integrity

MCP Tools & A2A Skills

MCP Server

FastMCP 2.x • 18 Tools • SHARP-on-MCP

store_clinical_observation
recall_patient_context
check_medication_conflicts
check_allergy_conflicts
detect_belief_drift
explain_clinical_conflictGenAI
clinical_care_handoffGenAI

+ 5 more tools (audit trail, dependencies, summary, ingest, health)

A2A Agent

Google ADK • 13 Tools • A2A Protocol

medication-safety-review
clinical-context-recall
contradiction-assessment
care-transition-summary
explain-conflictGenAI

Engine Modules (13)

clinical_memory
clinical_scoring
fhir_client
llm_synthesizer
rxnorm_client
snomed_client
umls_mapper
consensus_engine
fda_client
trials_client
what_if
phi_detector
hallucination_detector

System Architecture

FHIR R4
Patient Data
Medical APIs
RxNorm, SNOMED, UMLS
LLM Consensus
6 US-based models

Shared Engine (13 modules)

Clinical Memory
BM25+Vector+RRF
MIND Kernels
Scoring
Drug Safety
4-Tier Pipeline
LLM Synthesis
Evidence-Cited
RxNorm
SNOMED CT
UMLS
SHA-256 Audit Trail (Merkle Chain)
MCP Server
18 Tools
A2A Agent
13 Tools
Audit Trail
Tamper-proof

Tech Stack

mind-mem
Hybrid Search Engine
MIND Lang
Clinical Scoring
FHIR R4
Patient Data Standard
FastMCP 2.x
MCP Protocol
Google ADK
A2A Protocol
RxNorm + SNOMED
NIH Terminology
UMLS
Cross-Vocabulary
Azure
Container Apps