critical-value-alert-generator — independently scanned and version-tracked by SaferSkills.
SaferSkills independently audited critical-value-alert-generator (Agent Skill) and scored it 100/100 (green). The audit ran 55 deterministic rules across Security, Supply Chain, Maintenance, Transparency, and Community; it found 0 high-severity and 0 lower-severity findings. The full rule-by-rule trace and per-finding evidence are below. Free, methodology-open.
Findings & checks · 0 flagged
Every scanned point with the score it earned and what moved between them.
First recorded scan — no prior version to compare against.
The primary manifest — the file an agent reads to learn what this artifact does.
Scan recent laboratory Observation resources for values exceeding critical thresholds defined by CAP (College of American Pathologists) and CLIA guidelines. Generate structured alerts containing: the critical value, threshold exceeded, clinical significance, and recommended immediate action. Support read-back verification workflow for clinical notification compliance. Prioritize alerts by clinical urgency.
| Resource | Purpose | Key Fields |
|---|---|---|
| Observation | Lab results to evaluate | code, valueQuantity, interpretation, effectiveDateTime, status |
| Patient | Demographics for context | birthDate, gender, name |
| MedicationStatement | Drug context for critical values | medicationCodeableConcept, status |
| Condition | Clinical context | code, clinicalStatus |
Tool: fhir_read
resourceType: "Patient"
id: "[patient-id]"Extract name (for alert addressee), age (pediatric thresholds differ), gender.
Tool: fhir_search
resourceType: "Observation"
queryParams: "patient=[patient-id]&category=laboratory&date=ge[24-hours-ago]&_sort=-date&_count=200"Default scan window: 24 hours. Expand to 48 or 72 hours if user requests or if investigating missed alerts.
For each Observation, compare valueQuantity.value against critical thresholds.
Priority 1 -- Immediately Life-Threatening:
| Analyte | LOINC | Critical Low | Critical High | Unit |
|---|---|---|---|---|
| Potassium | 2823-3 | < 2.5 | > 6.5 | mEq/L |
| Sodium | 2951-2 | < 120 | > 160 | mEq/L |
| Glucose | 2345-7 | < 40 | > 500 | mg/dL |
| Calcium (total) | 17861-6 | < 6.0 | > 13.0 | mg/dL |
| Ionized Calcium | 1994-3 | < 0.78 | > 1.58 | mmol/L |
| pH (arterial) | 2744-1 | < 7.20 | > 7.60 | -- |
| pCO2 | 2019-8 | < 20 | > 70 | mmHg |
| pO2 | 2703-7 | < 40 | -- | mmHg |
| Lactate | 2524-7 | -- | > 4.0 | mmol/L |
| Troponin I | 10839-9 | -- | > 0.04 | ng/mL |
| Troponin T | 6598-7 | -- | > 0.10 | ng/mL |
Priority 2 -- Urgent (within 1 hour):
| Analyte | LOINC | Critical Low | Critical High | Unit |
|---|---|---|---|---|
| Hemoglobin | 718-7 | < 7.0 | > 20.0 | g/dL |
| WBC | 26464-8 | < 1.5 | > 30.0 | x10^3/uL |
| Platelets | 777-3 | < 20 | > 1000 | x10^3/uL |
| INR | 6301-6 | -- | > 5.0 | -- |
| aPTT | 3173-2 | -- | > 100 | seconds |
| Fibrinogen | 3255-7 | < 100 | -- | mg/dL |
| Magnesium | 19123-9 | < 1.0 | > 4.0 | mg/dL |
| Phosphorus | 2777-1 | < 1.0 | > 8.0 | mg/dL |
| Ammonia | 1925-7 | -- | > 100 | umol/L |
| Bilirubin (neonatal) | 58941-6 | -- | > 15.0 | mg/dL |
Priority 3 -- Urgent Drug Levels:
| Drug | LOINC | Critical Low | Critical High | Unit |
|---|---|---|---|---|
| Digoxin | 10535-3 | -- | > 2.0 | ng/mL |
| Lithium | 14334-7 | -- | > 1.5 | mEq/L |
| Phenytoin | 3968-5 | -- | > 30.0 | ug/mL |
| Vancomycin (trough) | 4090-7 | -- | > 30.0 | ug/mL |
| Theophylline | 4049-3 | -- | > 20.0 | ug/mL |
| Carbamazepine | 3432-2 | -- | > 15.0 | ug/mL |
| Valproic Acid | 4086-5 | -- | > 120.0 | ug/mL |
| Methotrexate (24h) | 14836-1 | -- | > 5.0 | umol/L |
See references/critical-value-table.md for complete thresholds with pediatric adjustments.
Also check the interpretation field: codes HH (critical high) or LL (critical low) from the FHIR server itself may flag values the threshold table does not cover.
For each critical value found:
Tool: fhir_search
resourceType: "MedicationStatement"
queryParams: "patient=[patient-id]&status=active"Tool: fhir_search
resourceType: "Condition"
queryParams: "patient=[patient-id]&clinical-status=active"Correlate:
Tool: fhir_search
resourceType: "Observation"
queryParams: "patient=[patient-id]&code=[loinc-code]&_sort=-date&_count=2"Compare current critical value to the most recent prior result. Note whether the value is newly critical or has been trending toward critical.
For each critical value, produce an alert block:
=====================================================
CRITICAL VALUE ALERT -- PRIORITY [1/2/3]
=====================================================
Patient: [Name] (MRN: [id])
Test: [Analyte name]
Value: [result] [unit]
Threshold: [critical low/high threshold]
Collected: [effectiveDateTime]
Prior: [prior value] on [prior date] (delta: [change])
CLINICAL SIGNIFICANCE:
[1-2 sentence explanation of the clinical risk]
RECOMMENDED IMMEDIATE ACTIONS:
1. [First action -- most urgent]
2. [Second action]
3. [Third action]
MEDICATION CONTEXT:
- [Relevant active medication and its relationship to the critical value]
READ-BACK VERIFICATION:
"The critical value for [Patient Name] is [analyte] of [value] [unit],
collected at [time]. The critical threshold is [threshold]. Please
read back the patient name, test name, and value to confirm receipt."
=====================================================Sort alerts by:
If no critical values found, report: "No critical values detected in laboratory results from [date range]. [N] total observations reviewed."
User says: "Check for critical labs on patient 33201"
Actions:
fhir_read Patient/33201 -- returns 58-year-old male, John Martinezfhir_search Observation?patient=33201&category=laboratory&date=ge[24-hours-ago]&_sort=-date&_count=200 -- returns 12 results; potassium 6.8 mEq/L (HH), glucose 38 mg/dL (LL), hemoglobin 6.2 g/dL (L)fhir_search MedicationStatement?patient=33201&status=active -- returns spironolactone, insulin glargine, aspirinfhir_search Condition?patient=33201&clinical-status=active -- returns CKD stage 4, Type 2 DM, CHFfhir_search Observation?patient=33201&code=2823-3&_sort=-date&_count=2 -- prior potassium 5.8 two days agofhir_search Observation?patient=33201&code=2345-7&_sort=-date&_count=2 -- prior glucose 95 yesterdayfhir_search Observation?patient=33201&code=718-7&_sort=-date&_count=2 -- prior hemoglobin 7.1 one week agoResult: Three alerts generated:
User says: "Any critical labs for patient abc-100 in the last 48 hours?"
Actions:
fhir_read Patient/abc-100 -- returns 34-year-old femalefhir_search Observation?patient=abc-100&category=laboratory&date=ge[48-hours-ago]&_sort=-date&_count=200 -- returns 8 results; all within normal limits or mildly abnormal (e.g., LDL 142 mg/dL flagged H)Result: "No critical values detected in laboratory results from the past 48 hours. 8 total observations reviewed. Note: 1 non-critical abnormality -- LDL 142 mg/dL (above reference 0-130). No immediate action required."
interpretation field entirely. Rely on threshold comparison against valueQuantity.value using the critical value table.valueQuantity is also absent, check valueString -- some results are reported as text (e.g., "> 500" for troponin). Parse the numeric value from the string.valueQuantity.unit or valueQuantity.code before comparing to thresholds.lab-result-interpreter -- for comprehensive lab interpretation beyond critical valuesrenal-function-dashboard -- for critical electrolytes in the context of renal function stagingdiabetes-panel-review -- for critical glucose values in the context of diabetes management~30 seconds. Free. No account. Every finding cites a rule and a line of evidence.