PHI detection
How Sentinel detects protected health information in a prompt and redacts it before the prompt is sent
The SUPERWISE® Sentinel PHI guardrail detects protected health information (PHI) in a prompt — patient names, clinical details, and health identifiers — and redacts each value before the prompt goes to the model provider. The request still proceeds, and the third-party model never sees the health information.
Unlike PII redaction, which matches structured identifiers with patterns, PHI detection uses a machine-learning model that reads the surrounding context. That lets it catch health information that has no fixed format — a patient's name, a diagnosis, a medication, a hospital — which pattern matching misses.
Action: By default this guardrail remediates: each matched value is replaced with the guardrail's replacement text, REDACTED by default, which appears in the prompt as {{REDACTED}}. You can change the replacement text, switch the guardrail to block matching requests, or flag them to record a finding and forward the request unchanged. See Manage guardrails.
What does PHI detection cover?
Detection is grouped into categories you can turn on or off per Sentinel:
| Group | Examples |
|---|---|
| Personal identity & demographics | Patient and medical-professional names, date of birth, age, Social Security number, license, driver's license, and passport numbers |
| Location, contact & network data | Street address, city, state, country, ZIP code, phone, email, URL, IP address |
| Administrative, financial & health plan numbers | Medical record number, healthcare / national health number, insurance or policy number, medical codes, account, bank account, routing number, credit card |
| Physical, biometric & device serial numbers | Medical device IDs, serial numbers, vehicle identification numbers (VIN), biometric identifiers |
| Clinical & medical context | Conditions and diagnoses, injuries, blood type, drugs and dosages, procedures, and medical facilities |
Parameters
- Categories — choose which of the groups above to detect. Leave them all on to cover everything, or narrow the scan to the categories that matter for a Sentinel. See Manage guardrails.
- Confidence threshold — the lowest model confidence, from 0 to 1 (default
0.5), for a span to count as PHI. Raise it to redact only high-confidence matches; lower it to catch more.
Example interception
Inbound prompt from application:
"Summarize the chart for patient Jane Doe (DOB 1975-03-12, MRN 884-221), seen at Mercy General for hypertension and started on lisinopril 10 mg."
What the upstream LLM actually sees:
"Summarize the chart for patient {{REDACTED}} (DOB {{REDACTED}}, MRN {{REDACTED}}), seen at {{REDACTED}} for {{REDACTED}} and started on {{REDACTED}} {{REDACTED}}."
Because detection is model-based, matches vary with context and confidence rather than a fixed pattern. Use the confidence threshold to tune sensitivity, and the Test sandbox to see how your settings behave before you publish.
See also
- PII redaction: pattern-based detection of emails, phone numbers, and government and financial IDs.
- Secret & credential detection: keep API keys and tokens out of prompts.
- Manage guardrails: choose categories, set the action, and test before publishing.
Updated 5 days ago