Upper GI Bleeding
Manifest is full and current (ACG 2021 + ESGE 2021 + Baveno VII 2022 + NICE NG141 2024 + TRIGGER + HALT-IT + ABOVE 2024 + PLACE 2024) with 10 phenotypes (peptic-ulcer Forrest, variceal, Mallory-Weiss, Dieulafoy, Cameron, erosive, malignancy, on-anticoag, massive hemodynamic, obscure recurrent) and full medication/dosing tables. Problem-package at assessment-of-upper-gastrointestinal-bleeding/ has all atoms; design brief lives at sibling gi.gi_bleed.acute/_design-brief.md (shared with LGIB). Workup `ugib` is registered in clinical-tools-registry. GBS, AIMS-65, MELD-Na, shock index, qSOFA calculators wired. Gaps for PRODUCTION: evidence.pmids array empty (manifest cites guideline labels but no numeric PMIDs); no engine-specific test_files; manifest LOINC array contains a placeholder line (14647-2 marked as not needed — clean up before promoting). No regimen_axes — pantoprazole/esomeprazole/omeprazole, octreotide, terlipressin, ceftriaxone variceal prophylaxis, carvedilol secondary prophylaxis, vitamin K, 4F-PCC, idarucizumab, andexanet alfa, PRBC, norepinephrine, erythromycin prokinetic all in manifest.medications without RxCUI verification through regimen-builder.
Entry points (4)
- symptomHematemesis (red blood or coffee-ground)hematemesis
- symptomMelena (black tarry stools)melena
- symptomSyncope / presyncope with GI blood losssyncope_with_blood_loss
- lab_abnormalityAcute drop in hemoglobin / elevated BUN:Cracute_drop_in_hgb
Required inputs (18)
- agerequireddemographic • used at CONTEXTAIMS-65 age >65 component; mortality stratification (Saltzman 2011)
- sbprequiredvital • used at CONTEXTSBP <90 hemodynamically unstable; AIMS-65 component (ACG 2021 Laine)
- hrrequiredvital • used at CONTEXTTachycardia / shock index; GBS component (ACG 2021 Laine)
- hemoglobinrequiredlab • used at INITIAL_WORKUPGBS component; transfusion threshold (Hgb 7 per ACG 2021 / TRIGGER)
- plateletsrequiredlab • used at INITIAL_WORKUPCoagulopathy management (ACG 2021 Laine)
- inrrequiredlab • used at INITIAL_WORKUPAIMS-65 INR >1.5; warfarin reversal threshold
- bunrequiredlab • used at INITIAL_WORKUPGBS component; elevated BUN:Cr suggests upper source (ACG 2021 Laine)
- creatininerequiredlab • used at INITIAL_WORKUPRenal function; contrast safety; medication dosing (ACG 2021)
- albuminrequiredlab • used at INITIAL_WORKUPAIMS-65 albumin <3
- lactatelab • used at RED_FLAGSPerfusion marker for shock (ESGE 2021)
- lft_for_cirrhosislab • used at BRANCHING_WORKUPMELD if variceal source; cirrhosis severity (Baveno VII 2022)
- egd_within_24hrequiredimaging • used at INITIAL_WORKUPDiagnostic + therapeutic; Forrest classification
- cta_abdomen_if_massiveimaging • used at BRANCHING_WORKUPLocalize bleed if EGD non-diagnostic / massive (ACG 2021 Laine)
- cirrhosis_or_varicesrequiredhistory • used at CONTEXTVariceal pathway — Baveno VII vasoactive + abx prophylaxis
- nsaid_aspirin_userequiredhistory • used at CONTEXTPUD pathway; PPI co-prescription (ACG 2021 Laine)
- anticoag_antiplateletrequiredhistory • used at CONTEXTReversal decision; aspirin continuation for secondary CV prevention (ACG 2021 Laine)
- aortic_grafthistory • used at CONTEXTAortoenteric fistula — emergent vascular surgery (ACG 2021)
- retching_vomiting_precedinghistory • used at CONTEXTMallory-Weiss tear pattern (ACG 2021)
12-phase flow (12)
- 1FRAMEConfirm UGIB scope; remember some apparent UGIB is actually nasal/oropharyngeal swallowed blood — and ~15% of melena can be lower source (ACG 2021 Laine)inputs: ageadvance: upper source plausible
- 2ENTRYRecognize hematemesis, coffee-ground emesis, melena, syncope with blood loss, acute Hgb dropadvance: one entry trigger present
- 3CONTEXTVitals, cirrhosis/varices history, NSAID/aspirin, anticoag/antiplatelet, retching, alcohol, prior PUD/HP, aortic graft, malignancy symptomsinputs: sbp, hr, cirrhosis_or_varices, nsaid_aspirin_use, anticoag_antiplatelet, aortic_graft, retching_vomiting_precedingadvance: context captured
- 4RED_FLAGSMassive hematemesis, hemodynamic instability, syncope, AMS, ongoing hematemesis despite resuscitation, anticoagulation with active bleed, known varices/cirrhosis, anemia-induced ACS, suspected aortoenteric fistulainputs: sbp, hr, hemoglobin, lactateadvance: unstable patient routed to ICU/airway protection or stabilized
- 5INITIAL_WORKUPCBC, type and crossmatch, BMP (BUN/Cr), coags (INR/aPTT), lactate, LFTs+albumin+bilirubin, ECG/troponin in anemia, GBS calculation, EGD within 24hinputs: hemoglobin, platelets, inr, bun, creatinine, albumin, egd_within_24hactions: panel.cbc, panel.lft, panel.renal, ugibadvance: baseline labs + EGD plan / GBS computed
- 6BRANCHING_WORKUPCTA if massive / EGD non-diagnostic; liver US + MELD if cirrhosis; capsule endoscopy if obscure recurrent; H. pylori biopsy at EGDinputs: cta_abdomen_if_massive, lft_for_cirrhosisadvance: phenotype identified (peptic-ulcer-Forrest / variceal / Mallory-Weiss / Dieulafoy / Cameron / erosive / malignancy / on-anticoag / massive / obscure)
- 7DIFFERENTIALPUD > varices > Mallory-Weiss > erosive esophagitis/gastritis > Dieulafoy > Cameron lesion > malignancy > angiodysplasia > aortoenteric fistula > hemobilia > epistaxis swallowed bloodadvance: etiology + Forrest stage identified
- 8RISK_STRATIFICATIONGlasgow-Blatchford pre-EGD (GBS 0-1 → outpatient), AIMS-65 mortality, shock index, MELD if variceal, Rockall post-EGD, Forrest classificationinputs: hemoglobin, bun, sbp, inr, albuminactions: calc.glasgow_blatchford, calc.aims65, calc.meld_na, calc.shock_indexadvance: risk score documented; outpatient eligibility decided
- 9TREATMENTABC resuscitation, restrictive transfusion (Hgb 7; 8-9 ACS), pre-EGD IV PPI (note: ABOVE 2024 — PPI no benefit pre-EGD), EGD within 24h with hemostasis, post-EGD high-dose IV PPI x 72h for high-risk Forrest (PLACE 2024); variceal: octreotide + ceftriaxone prophylaxis + band ligation + TIPS for refractory; HALT-IT 2020: NO tranexamic acid; anticoag reversal (vit K + 4F-PCC for warfarin; idarucizumab for dabigatran; andexanet for Xa)inputs: hemoglobin, inradvance: hemostasis achieved or escalated to IR/surgery
- 10DISPOSITIONICU for hemodynamic instability / variceal bleed / massive transfusion / airway concern; floor for stable; outpatient discharge if GBS 0-1inputs: sbpadvance: destination set
- 11MONITORINGSerial Hgb q6-8h, vitals q1-4h, hourly UOP if shock, lactate clearance q6h, stool color/output, coags post-reversal, rebleeding watch 48-72h, hepatic encephalopathy watch in varicealinputs: hemoglobinadvance: stable for 24h or escalated
- 12FOLLOWUPRepeat EGD 6-8w for ulcer/malignancy; HP eradication confirmation 4w; variceal band ligation series q2-4w + secondary NSBB prophylaxis; anticoag resumption with cardiology; GI clinic 2-4w; iron studiesadvance: follow-up scheduled