make a case presentation on the case foreign body in the esophagus (chicken bone )

Asking for Preferences
Reading File
Finding Sources
Finding Sources
Searching PubMed

esophageal foreign body management

Searching the Web

esophageal foreign body chicken bone management case presentation guidelines

Finding Sources
Reading File
Let me read the rest of this Foreign Bodies section in Rosen's for full clinical detail.
Reading File
Reading File
Continuing to the Management/Disposition sections for the full protocol.
Reading File
Reading File
Searching Images

chicken bone foreign body esophagus X-ray CT scan

Searching Images

esophageal foreign body impaction radiograph

This diagnostic image is a posterior-anterior (PA) plain chest radiograph demonstrating an ingested foreign body. A highly radiopaque, 'U'-shaped object is clearly visible in the midline, localized to the upper mediastinum/cervical esophagus region, just superior to the level of the aortic arch. The object features distinct lateral radiopaque projections consistent with metallic clasps of a partial denture. The long axis of the foreign body is oriented vertically within the esophageal lumen. Anatomical landmarks include the trachea, bilateral lung fields with normal vascular markings, the cardiac silhouette, and bony structures including the clavicles, ribs, and cervical-thoracic vertebrae. The image illustrates the clinical challenge of esophageal foreign body impaction, where sharp components like denture clasps increase the risk of mucosal injury or perforation. This visual material is relevant for gastroenterology and emergency medicine education focusing on diagnostic radiology and foreign body management.

This diagnostic image is a posterior-anterior (PA) plain chest radiograph demonstrating an ingested foreign body. A highly radiopaque, 'U'-shaped object is clearly visible in the midline, localized to the upper mediastinum/cervical esophagus region, just superior to the level of the aortic arch. The object features distinct lateral radiopaque projections consistent with metallic clasps of a partial denture. The long axis of the foreign body is oriented vertically within the esophageal lumen. Anatomical landmarks include the trachea, bilateral lung fields with normal vascular markings, the cardiac silhouette, and bony structures including the clavicles, ribs, and cervical-thoracic vertebrae. The image illustrates the clinical challenge of esophageal foreign body impaction, where sharp components like denture clasps increase the risk of mucosal injury or perforation. This visual material is relevant for gastroenterology and emergency medicine education focusing on diagnostic radiology and foreign body management.

Anteroposterior (AP) chest radiograph of a pediatric patient demonstrating significant pulmonary and esophageal pathology. The right lung field exhibits extensive opacification and increased density with visible loculation, consistent with a complex empyema secondary to esophageal perforation. In contrast, the left lung field shows relatively normal aeration with preserved lung markings. Centrally, located slightly to the right of the midline at the level of the mid-thoracic spine, is a distinct, highly radiopaque, circular foreign body. The morphology and location of the object are characteristic of an ingested coin impacted in the esophagus. The mediastinal structures appear obscured by the adjacent right-sided pleural disease. This image serves as a critical diagnostic example of the secondary complications of esophageal foreign body impaction, specifically mediastinitis and loculated empyema in a clinical setting.

Anteroposterior (AP) chest radiograph of a pediatric patient demonstrating significant pulmonary and esophageal pathology. The right lung field exhibits extensive opacification and increased density with visible loculation, consistent with a complex empyema secondary to esophageal perforation. In contrast, the left lung field shows relatively normal aeration with preserved lung markings. Centrally, located slightly to the right of the midline at the level of the mid-thoracic spine, is a distinct, highly radiopaque, circular foreign body. The morphology and location of the object are characteristic of an ingested coin impacted in the esophagus. The mediastinal structures appear obscured by the adjacent right-sided pleural disease. This image serves as a critical diagnostic example of the secondary complications of esophageal foreign body impaction, specifically mediastinitis and loculated empyema in a clinical setting.

This diagnostic image is a posteroanterior (PA) chest radiograph illustrating an accidental foreign body ingestion. Centered in the upper cervical and thoracic inlet region, projecting over the esophagus, is a large, radio-opaque, crucifix-shaped foreign object. The object exhibits high density, consistent with metal, and is oriented with its longitudinal axis slightly oblique to the midline. In addition to the foreign body, the radiograph shows several medical devices: a dual-chamber cardiac pacemaker or implantable cardioverter-defibrillator (ICD) is visible in the left infraclavicular region with leads extending into the cardiac silhouette. Multiple external monitoring leads and a right-sided vascular access device (likely a PICC line or central venous catheter) are also present. The image serves as a clinical example of esophageal foreign body impaction in an adult patient with comorbid cardiovascular conditions. Educational focus includes the recognition of dense radio-opaque objects on X-ray and the anatomical relationships between the esophagus, airway, and mediastinum.

This diagnostic image is a posteroanterior (PA) chest radiograph illustrating an accidental foreign body ingestion. Centered in the upper cervical and thoracic inlet region, projecting over the esophagus, is a large, radio-opaque, crucifix-shaped foreign object. The object exhibits high density, consistent with metal, and is oriented with its longitudinal axis slightly oblique to the midline. In addition to the foreign body, the radiograph shows several medical devices: a dual-chamber cardiac pacemaker or implantable cardioverter-defibrillator (ICD) is visible in the left infraclavicular region with leads extending into the cardiac silhouette. Multiple external monitoring leads and a right-sided vascular access device (likely a PICC line or central venous catheter) are also present. The image serves as a clinical example of esophageal foreign body impaction in an adult patient with comorbid cardiovascular conditions. Educational focus includes the recognition of dense radio-opaque objects on X-ray and the anatomical relationships between the esophagus, airway, and mediastinum.

A frontal (anteroposterior) pediatric chest radiograph demonstrating an impacted foreign body. A highly radiopaque, circular, well-defined object, approximately 1.9 cm in diameter and consistent with a coin, is located centrally in the upper mediastinum at the level of the thoracic inlet. The coronal orientation of the coin on this AP view is characteristic of an esophageal location, specifically at the cricopharyngeal area (the first physiological constriction of the esophagus). The surrounding skeletal structures, including the ribs, clavicles, and scapulae, appear intact with normal alignment and no signs of acute fracture. The pulmonary parenchyma is clear, and the cardiomediastinal silhouette is within normal limits for age. This diagnostic image illustrates a common pediatric emergency involving foreign body ingestion and highlights the radiographic features used to differentiate esophageal versus tracheal impaction based on the orientation of the object.

A frontal (anteroposterior) pediatric chest radiograph demonstrating an impacted foreign body. A highly radiopaque, circular, well-defined object, approximately 1.9 cm in diameter and consistent with a coin, is located centrally in the upper mediastinum at the level of the thoracic inlet. The coronal orientation of the coin on this AP view is characteristic of an esophageal location, specifically at the cricopharyngeal area (the first physiological constriction of the esophagus). The surrounding skeletal structures, including the ribs, clavicles, and scapulae, appear intact with normal alignment and no signs of acute fracture. The pulmonary parenchyma is clear, and the cardiomediastinal silhouette is within normal limits for age. This diagnostic image illustrates a common pediatric emergency involving foreign body ingestion and highlights the radiographic features used to differentiate esophageal versus tracheal impaction based on the orientation of the object.

This anterior-posterior (AP) chest radiograph demonstrates a prominent, irregularly shaped radiopaque foreign body in the upper mediastinum, indicated by a black arrow. The structure is located centrally, extending from the level of the thoracic inlet down to the upper thoracic vertebrae (approximately T1-T4), overlying the anatomical path of the esophagus. The foreign body exhibits a complex morphology, consisting of a denser, molded base and thin, curvilinear metallic wires or hooks typical of a dental prosthesis (dentures). Key landmarks include the clavicles and the tracheal air column, which the object partially superimposes. This diagnostic image illustrates a case of accidental foreign body ingestion, highlighting the high radiopacity and sharp features of the prosthetic wires, which pose a clinical risk of esophageal perforation or impaction. The image is a critical tool for medical students and clinicians in identifying non-biological objects and assessing their size and position relative to vital mediastinal structures.

This anterior-posterior (AP) chest radiograph demonstrates a prominent, irregularly shaped radiopaque foreign body in the upper mediastinum, indicated by a black arrow. The structure is located centrally, extending from the level of the thoracic inlet down to the upper thoracic vertebrae (approximately T1-T4), overlying the anatomical path of the esophagus. The foreign body exhibits a complex morphology, consisting of a denser, molded base and thin, curvilinear metallic wires or hooks typical of a dental prosthesis (dentures). Key landmarks include the clavicles and the tracheal air column, which the object partially superimposes. This diagnostic image illustrates a case of accidental foreign body ingestion, highlighting the high radiopacity and sharp features of the prosthetic wires, which pose a clinical risk of esophageal perforation or impaction. The image is a critical tool for medical students and clinicians in identifying non-biological objects and assessing their size and position relative to vital mediastinal structures.

Case Presentation: Foreign Body in the Esophagus — Chicken Bone Impaction

1. Patient Identification & Chief Complaint

Patient: Mr. X, 52-year-old male Chief Complaint: "I feel something stuck in my throat" — onset immediately after eating chicken curry ~3 hours prior to presentation.

2. History of Presenting Illness

The patient was eating chicken at dinner when he suddenly felt a sharp, sticking sensation in the throat/retrosternal region while swallowing. Since then he has had:
  • Odynophagia (painful swallowing) — worse with solids
  • Dysphagia to solids, able to tolerate liquids
  • Sensation of a foreign body "stuck" at the suprasternal notch level (patients can usually localize a foreign body fairly accurately when it is lodged in the upper esophagus, because this region has somatic innervation; lower esophageal impactions instead cause vague, visceral retrosternal/epigastric discomfort)
  • Mild drooling / excess salivation
  • No stridor, no respiratory distress, no hematemesis
  • Denies previous episodes of dysphagia, no known esophageal stricture, no history of psychiatric illness or intentional ingestion
Red flags actively screened for: inability to handle secretions, stridor/wheeze (airway compromise), chest pain out of proportion, subcutaneous emphysema/crepitus, fever — all absent in this patient, but their presence would indicate perforation or airway involvement and change the urgency of management.

3. Past Medical / Surgical History

  • No known esophageal disease, no prior GI surgery
  • No dentures (edentulous adults are a recognized risk group because they lose the tactile/proprioceptive feedback from teeth that normally helps detect bone fragments while chewing)
  • Not a psychiatric patient or prisoner (the other classic high-risk group for intentional foreign body ingestion)

4. Examination

  • Vitals stable, no fever, SpO2 normal
  • Airway patent, no stridor
  • Neck: no crepitus/subcutaneous emphysema (would suggest perforation), no swelling
  • Chest: clear air entry bilaterally
  • Abdomen: soft, non-tender
  • Oropharynx: no visible foreign body

5. Clinical Reasoning — Why This Presentation Fits an Esophageal (not Airway) Foreign Body

Esophageal foreign bodies must be distinguished from airway foreign bodies, which is a critical branch point:
FeatureEsophageal FBAirway FB
SymptomsDysphagia, odynophagia, drooling, retrosternal painCough, wheeze, stridor, respiratory distress
OnsetImmediate after swallowingImmediate, often with choking episode
DangerPerforation, mediastinitisAirway obstruction (acute emergency)
This patient's pattern (dysphagia/odynophagia without respiratory symptoms) points to esophageal, not tracheobronchial, lodgement (Rosen's Emergency Medicine).

6. Anatomy Relevant to the Case

The esophagus has four natural anatomic narrowings where foreign bodies most commonly lodge:
  1. Cricopharyngeus muscle (upper esophageal sphincter) — most common site in adults and children
  2. Aortic arch crossing
  3. Left mainstem bronchus crossing
  4. Lower esophageal sphincter at the diaphragmatic hiatus
Adult bone impactions most often occur at the cricopharyngeus/UES level or in patients with an underlying stricture; nearly 90% of adults with true esophageal obstruction have an underlying structural abnormality (peptic stricture, malignant stricture, Schatzki ring, or eosinophilic esophagitis), so a search for one is part of the workup even after the bone is removed - Rosen's Emergency Medicine, p. 1219-1220.

7. Differential Diagnosis

  • Esophageal foreign body impaction (chicken bone) — most likely given history
  • Esophageal mucosal abrasion/laceration without a retained foreign body (up to a majority of patients who feel a "fish/chicken bone stuck" actually have only a mucosal scratch with no retained object)
  • Esophageal perforation (must be actively excluded)
  • Acute coronary syndrome (esophageal chest pain can mimic ACS and should never be dismissed without consideration, especially in older patients with retrosternal pain)
  • Food bolus impaction on a pre-existing stricture

8. Investigations

  1. Plain radiographs (AP + lateral neck, chest, abdomen) — first-line if a radiopaque object is suspected. Coins and button batteries show up reliably (coins orient in the coronal plane and appear round on AP view). Bones (chicken or fish) are frequently radiolucent or poorly visualized on plain film — a normal X-ray does NOT rule out a bone foreign body.
  2. CT scan (neck/chest) — the investigation of choice when a bone is suspected and plain films are negative or equivocal. CT sensitivity for bones is 90-100%, far superior to plain radiography, and also detects early signs of perforation (soft tissue stranding, air) - Rosen's Emergency Medicine, p. 1220-1221.
  3. Barium/contrast swallow — generally avoided; risks aspiration and coats the object/mucosa, degrading subsequent endoscopic visualization.
  4. Nasopharyngoscopy/laryngoscopy — useful to look for a foreign body lodged at or above the cricopharyngeus and to distinguish a retained object from a simple mucosal abrasion.
  5. Upper GI endoscopy — both diagnostic (definitive visualization) and therapeutic (allows immediate retrieval).
For this patient: CT neck/chest was obtained after an inconclusive plain film and confirmed a linear radiopaque/faintly radiopaque structure lodged at the cricopharyngeus level, without evidence of surrounding free air or perforation.

9. Diagnosis

Esophageal foreign body — impacted chicken bone at the level of the cricopharyngeus (upper esophageal sphincter), uncomplicated (no perforation).

10. Management

General principle: treatment depends on the object's shape/sharpness, its location, duration of impaction, and the patient's clinical status.
  • Urgent endoscopic removal (within 2-6 hours) is indicated because sharp/pointed objects such as bones carry a substantial risk of mucosal injury or perforation if left in situ - up to a third of sharp objects can perforate if not promptly removed. Bones and impactions of longer duration are specifically flagged as risk factors for complications.
  • Flexible endoscopy under procedural sedation is the preferred modality over rigid endoscopy in most cases (lower complication rate, no need for general anesthesia), consistent with the European Society of Gastrointestinal Endoscopy (ESGE) guideline on removal of upper GI foreign bodies in adults.
  • Airway protection should be considered in any patient at aspiration risk; if in doubt, intubation and general anesthesia are the safer route for retrieval.
  • Do not attempt blind techniques (Foley catheter balloon extraction, bougienage, or "push technique") for sharp/pointed objects like bones — these are reserved for smooth objects such as coins. Attempting them with a bone risks perforation.
  • After removal: observe until fully awake from sedation and able to tolerate oral intake; start a proton pump inhibitor; arrange follow-up/repeat endoscopy to evaluate for an underlying structural esophageal abnormality (identifiable in up to 25% of patients after an esophageal obstruction event) - Rosen's Emergency Medicine, p. 1221-1222.
  • If perforation had been present, management would shift toward broad-spectrum antibiotics, surgical/thoracic consultation, and possible operative repair or drainage depending on size and location of the perforation and degree of contamination.

11. Complications to Monitor For

  • Esophageal perforation (the most feared complication with sharp bones) - can present with neck/chest pain, subcutaneous emphysema, fever, or signs of mediastinitis, sometimes delayed by hours to days
  • Mediastinitis / mediastinal abscess
  • Tracheoesophageal fistula
  • Aorto-esophageal fistula (rare but catastrophic, especially with prolonged impaction near the aortic arch)
  • Any foreign body retained beyond 24 hours carries meaningfully higher complication risk, and complications may manifest even years after the ingestion in rare case reports.

12. Outcome

Following prompt flexible endoscopic retrieval of the bone, the patient tolerated oral intake, had no evidence of perforation on follow-up, was discharged on a short course of PPI, and was scheduled for outpatient upper GI endoscopy to exclude an underlying stricture or motility disorder.

13. Teaching Points for Discussion

  1. Esophageal foreign bodies cluster into four groups: children (most common overall, coins), psychiatric/incarcerated patients (intentional ingestion), patients with underlying esophageal disease, and edentulous adults — this patient fits the last group.
  2. Bone impactions (chicken or fish) are a classic adult food-related foreign body, distinct from the pediatric coin-swallowing pattern.
  3. A normal plain X-ray never excludes a bone foreign body — maintain a low threshold for CT if symptoms persist.
  4. Sharp objects (bones, pins, toothpicks) mandate urgent endoscopic removal, unlike smooth objects (coins), which may sometimes be observed or removed with simpler techniques.
  5. Always look for and treat any underlying esophageal pathology after the acute event — the foreign body is often a marker of a stricture, ring, or motility disorder rather than a purely mechanical accident.
  6. Glucagon, sometimes used empirically for lower-esophageal food bolus impaction to relax the LES, has not shown clear benefit over placebo in recent meta-analysis and carries side effects — it is not a substitute for definitive endoscopy, and is not relevant for sharp bone impactions in any case (Ismail et al., 2024, Glucagon for Esophageal Foreign Body Impaction: A Systematic Review and Meta-analysis, PMID 39292844).
  7. Cap-assisted flexible endoscopy has recently been shown to be a safe and effective alternative to conventional endoscopic retrieval methods for esophageal foreign bodies (Ahmed et al., 2023, PMID 36350475) — relevant if the standard forceps/snare approach fails.
Representative radiographic appearance of an impacted esophageal foreign body (denture fragment) at the cervical esophagus, illustrating how sharp radiopaque objects appear on plain film — note that fish/chicken bones are often far less radiopaque than this and may be missed on X-ray, which is why CT is preferred when a bone is suspected:
Radiopaque sharp foreign body (denture clasp) in the cervical esophagus on PA chest radiograph
Sources: ROSEN's Emergency Medicine: Concepts and Clinical Practice, "Foreign Bodies," p. 1219-1222; ESGE Clinical Guideline on removal of foreign bodies in the upper GI tract (Birk et al., 2016); recent evidence check via PubMed (PMID 39292844, PMID 36350475) showed no findings that contradict this management approach, only refinements (glucagon limited efficacy; cap-assisted endoscopy as a safe adjunct technique).

Create a PDF quick-reference card: Esophageal Foreign Body management algorithm

Reading File
Reading File
Browsing Directory

/tmp/skills/pdf

Running Command

mkdir -p /tmp/workspace/esophageal-fb-card && ls -la /tmp/workspace/

Writing File

~/esophageal-fb-card/build_card.py

# -*- coding: utf-8 -*-
"""
Esophageal Foreign Body Management - Quick Reference Card
Single-page A4 clinical algorithm card using ReportLab.
"""
from reportlab.lib.pagesizes import A4
from reportlab.lib.units import mm
from reportlab.lib import colors
from reportlab.platypus import (
    SimpleDocTemplate, Table, TableStyle, Paragraph, Spacer, KeepTogether
)
from reportlab.lib.styles import getSampleStyleSheet, ParagraphStyle
from reportlab.lib.enums import TA_CENTER, TA_LEFT

PAGE_W, PAGE_H = A4

# ---------- Colors ----------
NAVY      = colors.HexColor("#0B3954")
RED       = colors.HexColor("#C0392B")
RED_BG    = colors.HexColor("#FDEDEC")
ORANGE    = colors.HexColor("#D68910")
ORANGE_BG = colors.HexColor("#FEF5E7")
GREEN     = colors.HexColor("#1E8449")
GREEN_BG  = colors.HexColor("#EAFAF1")
BLUE_BG   = colors.HexColor("#EBF5FB")
GREY_BG   = colors.HexColor("#F4F6F6")
WHITE     = colors.white
DARK      = colors.HexColor("#212F3D")

styles = getSampleStyleSheet()

def pstyle(name, size=8.3, leading=10.2, color=DARK, bold=False, align=TA_LEFT, spaceAfter=0):
    return ParagraphStyle(
        name, parent=styles["Normal"], fontSize=size, leading=leading,
        textColor=color, fontName="Helvetica-Bold" if bold else "Helvetica",
        alignment=align, spaceAfter=spaceAfter,
    )

P_TITLE   = pstyle("title", 17, 20, WHITE, True, TA_CENTER)
P_SUB     = pstyle("sub", 9.5, 12, WHITE, False, TA_CENTER)
P_HEAD    = pstyle("head", 10.5, 13, WHITE, True, TA_LEFT)
P_HEAD_D  = pstyle("headd", 10, 12.5, DARK, True, TA_LEFT)
P_BODY    = pstyle("body", 8.2, 10.2, DARK, False, TA_LEFT)
P_BODY_B  = pstyle("bodyb", 8.2, 10.2, DARK, True, TA_LEFT)
P_SMALL   = pstyle("small", 7.3, 9.2, DARK, False, TA_LEFT)
P_SMALL_W = pstyle("smallw", 7.6, 9.6, WHITE, False, TA_LEFT)
P_SMALL_WB= pstyle("smallwb", 7.8, 9.8, WHITE, True, TA_LEFT)
P_FOOT    = pstyle("foot", 6.6, 8.4, colors.HexColor("#5D6D7E"), False, TA_LEFT)
P_STEP_NUM= pstyle("stepnum", 11, 13, WHITE, True, TA_CENTER)

def header_bar(text, bg=NAVY, style=P_HEAD, pad=(4,4,4,4)):
    t = Table([[Paragraph(text, style)]], colWidths=[None])
    t.setStyle(TableStyle([
        ("BACKGROUND", (0,0), (-1,-1), bg),
        ("LEFTPADDING", (0,0), (-1,-1), pad[0]*mm/mm if False else 6),
        ("TOPPADDING", (0,0), (-1,-1), 4),
        ("BOTTOMPADDING", (0,0), (-1,-1), 4),
        ("RIGHTPADDING", (0,0), (-1,-1), 6),
    ]))
    return t

def box(rows_html, bg=GREY_BG, border=colors.HexColor("#BDC3C7"), col_widths=None, pads=3):
    """rows_html: list of [Paragraph,...] rows"""
    t = Table(rows_html, colWidths=col_widths)
    t.setStyle(TableStyle([
        ("BACKGROUND", (0,0), (-1,-1), bg),
        ("BOX", (0,0), (-1,-1), 0.6, border),
        ("INNERGRID", (0,0), (-1,-1), 0.4, border),
        ("LEFTPADDING", (0,0), (-1,-1), pads+2),
        ("RIGHTPADDING", (0,0), (-1,-1), pads+2),
        ("TOPPADDING", (0,0), (-1,-1), pads),
        ("BOTTOMPADDING", (0,0), (-1,-1), pads),
        ("VALIGN", (0,0), (-1,-1), "TOP"),
    ]))
    return t

story = []

# ============ TITLE BLOCK ============
title_tbl = Table(
    [[Paragraph("ESOPHAGEAL FOREIGN BODY", P_TITLE)],
     [Paragraph("Management Algorithm  |  Quick Reference Card  |  ED / GI / ENT", P_SUB)]],
    colWidths=[PAGE_W - 30*mm]
)
title_tbl.setStyle(TableStyle([
    ("BACKGROUND", (0,0), (-1,-1), NAVY),
    ("TOPPADDING", (0,0), (0,0), 8),
    ("BOTTOMPADDING", (0,0), (0,0), 2),
    ("TOPPADDING", (0,1), (0,1), 1),
    ("BOTTOMPADDING", (0,1), (0,1), 7),
]))
story.append(title_tbl)
story.append(Spacer(1, 5))

# ============ STEP 1: RECOGNIZE ============
step1_head = Table([[Paragraph("STEP 1", P_STEP_NUM), Paragraph("RECOGNIZE & TRIAGE — History and Exam", P_HEAD)]],
                    colWidths=[16*mm, None])
step1_head.setStyle(TableStyle([
    ("BACKGROUND", (0,0), (0,0), RED),
    ("BACKGROUND", (1,0), (1,0), NAVY),
    ("VALIGN", (0,0), (-1,-1), "MIDDLE"),
    ("TOPPADDING", (0,0), (-1,-1), 4), ("BOTTOMPADDING", (0,0), (-1,-1), 4),
]))
story.append(step1_head)

typical = Paragraph(
    "<b>Typical Sx:</b> dysphagia, odynophagia, drooling/excess salivation, retrosternal or "
    "neck pain, foreign-body sensation, sudden onset while eating (esp. fish/chicken bone, meat).",
    P_BODY)

redflag = Paragraph(
    "<b><font color='#C0392B'>RED FLAGS \u2192 EMERGENT (act now, do not delay for imaging):</font></b> "
    "stridor / airway compromise \u00b7 respiratory distress \u00b7 inability to handle secretions "
    "\u00b7 active hematemesis \u00b7 subcutaneous emphysema / neck crepitus \u00b7 severe/worsening chest pain "
    "\u00b7 fever with chest pain (\u2192 think perforation / mediastinitis).",
    P_BODY)

recog_box = box(
    [[typical], [redflag]],
    bg=WHITE, border=colors.HexColor("#BDC3C7")
)
recog_box.setStyle(TableStyle([
    ("BACKGROUND", (0,1), (0,1), RED_BG),
]))
story.append(recog_box)
story.append(Spacer(1, 4))

# ============ STEP 2: IMAGING ============
step2_head = Table([[Paragraph("STEP 2", P_STEP_NUM), Paragraph("IMAGING — Localize the object", P_HEAD)]],
                    colWidths=[16*mm, None])
step2_head.setStyle(TableStyle([
    ("BACKGROUND", (0,0), (0,0), ORANGE),
    ("BACKGROUND", (1,0), (1,0), NAVY),
    ("VALIGN", (0,0), (-1,-1), "MIDDLE"),
    ("TOPPADDING", (0,0), (-1,-1), 4), ("BOTTOMPADDING", (0,0), (-1,-1), 4),
]))
story.append(step2_head)

img_data = [
    [Paragraph("<b>Plain XR</b> (AP + lateral, neck/chest/abd)", P_BODY_B),
     Paragraph("1st line. Reliably shows coins &amp; button batteries (coronal orientation on AP view). "
               "<b>Bones (fish/chicken) are often radiolucent \u2014 a normal X-ray does NOT exclude a bone.</b>", P_BODY)],
    [Paragraph("<b>CT neck/chest (\u00b1 contrast)</b>", P_BODY_B),
     Paragraph("Investigation of choice when a bone is suspected or XR is negative/equivocal with persistent symptoms. "
               "Sensitivity 90\u2013100% for bone/organic FB; also detects early perforation (air, stranding).", P_BODY)],
    [Paragraph("<b>Barium / Gastrografin swallow</b>", P_BODY_B),
     Paragraph("<font color='#C0392B'><b>Avoid</b></font> \u2014 aspiration risk and coats mucosa, degrading subsequent endoscopic view.", P_BODY)],
    [Paragraph("<b>Nasopharyngoscopy / laryngoscopy</b>", P_BODY_B),
     Paragraph("Useful for FB at or above the cricopharyngeus; differentiates retained FB from mucosal abrasion.", P_BODY)],
]
img_tbl = box(img_data, bg=WHITE, col_widths=[52*mm, None])
img_tbl.setStyle(TableStyle([("BACKGROUND", (0,0), (0,-1), ORANGE_BG)]))
story.append(img_tbl)
story.append(Spacer(1, 4))

# ============ STEP 3: TRIAGE BY OBJECT / URGENCY ============
step3_head = Table([[Paragraph("STEP 3", P_STEP_NUM), Paragraph("TIMING — Urgency by object type", P_HEAD)]],
                    colWidths=[16*mm, None])
step3_head.setStyle(TableStyle([
    ("BACKGROUND", (0,0), (0,0), RED),
    ("BACKGROUND", (1,0), (1,0), NAVY),
    ("VALIGN", (0,0), (-1,-1), "MIDDLE"),
    ("TOPPADDING", (0,0), (-1,-1), 4), ("BOTTOMPADDING", (0,0), (-1,-1), 4),
]))
story.append(step3_head)

urg_header = [Paragraph("<b>Object / Situation</b>", P_SMALL_WB), Paragraph("<b>Urgency</b>", P_SMALL_WB), Paragraph("<b>Key point</b>", P_SMALL_WB)]
urg_rows = [
    urg_header,
    [Paragraph("Button battery in esophagus", P_SMALL), Paragraph("<b><font color='#C0392B'>EMERGENT &lt;2 h</font></b>", P_SMALL),
     Paragraph("Risk of liquefactive necrosis / perforation within hours.", P_SMALL)],
    [Paragraph("Sharp / pointed object \u2014 <b>fish or chicken bone</b>, pin, toothpick", P_SMALL), Paragraph("<b><font color='#D68910'>URGENT 2\u20136 h</font></b>", P_SMALL),
     Paragraph("High perforation risk (up to ~35% if retained). Never observe.", P_SMALL)],
    [Paragraph("Multiple magnets / long object &gt;5 cm / disk battery", P_SMALL), Paragraph("<b><font color='#D68910'>URGENT 2\u20136 h</font></b>", P_SMALL),
     Paragraph("Magnet pairs can trap tissue \u2192 pressure necrosis.", P_SMALL)],
    [Paragraph("Coin, proximal esophagus, symptomatic", P_SMALL), Paragraph("<b><font color='#D68910'>URGENT 2\u20136 h</font></b>", P_SMALL),
     Paragraph("Smooth \u2014 may also suit Foley/bougienage (see Step 4).", P_SMALL)],
    [Paragraph("Food bolus, incomplete obstruction, tolerating secretions", P_SMALL), Paragraph("<b><font color='#1E8449'>Within 24 h</font></b>", P_SMALL),
     Paragraph("Brief trial of spontaneous passage acceptable if stable; glucagon evidence is weak (no benefit vs placebo, more AEs).", P_SMALL)],
    [Paragraph("Blunt object already passed into stomach, asymptomatic", P_SMALL), Paragraph("<b><font color='#1E8449'>Elective / conservative</font></b>", P_SMALL),
     Paragraph("Serial X-ray / stool check. Endoscopic retrieval if &gt;2.5 cm wide, &gt;5 cm long, or sharp.", P_SMALL)],
]
urg_tbl = Table(urg_rows, colWidths=[62*mm, 30*mm, None])
urg_tbl.setStyle(TableStyle([
    ("BACKGROUND", (0,0), (-1,0), NAVY),
    ("BOX", (0,0), (-1,-1), 0.6, colors.HexColor("#BDC3C7")),
    ("INNERGRID", (0,0), (-1,-1), 0.4, colors.HexColor("#BDC3C7")),
    ("ROWBACKGROUNDS", (0,1), (-1,-1), [WHITE, GREY_BG]),
    ("BACKGROUND", (0,1), (-1,1), RED_BG),
    ("VALIGN", (0,0), (-1,-1), "TOP"),
    ("LEFTPADDING", (0,0), (-1,-1), 5), ("RIGHTPADDING", (0,0), (-1,-1), 5),
    ("TOPPADDING", (0,0), (-1,-1), 3), ("BOTTOMPADDING", (0,0), (-1,-1), 3),
]))
story.append(urg_tbl)
story.append(Spacer(1, 4))

# ============ STEP 4: TECHNIQUE ============
step4_head = Table([[Paragraph("STEP 4", P_STEP_NUM), Paragraph("REMOVAL TECHNIQUE", P_HEAD)]],
                    colWidths=[16*mm, None])
step4_head.setStyle(TableStyle([
    ("BACKGROUND", (0,0), (0,0), GREEN),
    ("BACKGROUND", (1,0), (1,0), NAVY),
    ("VALIGN", (0,0), (-1,-1), "MIDDLE"),
    ("TOPPADDING", (0,0), (-1,-1), 4), ("BOTTOMPADDING", (0,0), (-1,-1), 4),
]))
story.append(step4_head)

tech_data = [
    [Paragraph("<b>Flexible endoscopy + sedation</b>", P_BODY_B),
     Paragraph("<b>Preferred, first-line for most objects</b> \u2014 direct visual control, lower complication rate than rigid scope, no GA required.", P_BODY)],
    [Paragraph("<b>Rigid endoscopy</b>", P_BODY_B),
     Paragraph("Select cases only (e.g. large/complex proximal objects). Requires general anesthesia; higher complication rate.", P_BODY)],
    [Paragraph("<b>Foley catheter balloon extraction / bougienage</b>", P_BODY_B),
     Paragraph("<font color='#1E8449'>ONLY for smooth objects (coins)</font> in proximal esophagus, impacted &lt;1 week, no perforation signs, no known stricture. "
               "<font color='#C0392B'><b>NEVER for sharp objects (bones, pins) or suspected perforation.</b></font>", P_BODY)],
    [Paragraph("<b>IV Glucagon 1 mg (up to 2 mg)</b>", P_BODY_B),
     Paragraph("May be trialed for distal food-bolus impaction only. Recent meta-analysis: no benefit over placebo, more adverse effects "
               "(PMID 39292844). <b>Not applicable to bone/sharp FB.</b>", P_BODY)],
]
tech_tbl = box(tech_data, bg=WHITE, col_widths=[58*mm, None])
tech_tbl.setStyle(TableStyle([("BACKGROUND", (0,0), (0,-1), GREEN_BG)]))
story.append(tech_tbl)
story.append(Spacer(1, 4))

# ============ STEP 5: POST-REMOVAL & COMPLICATIONS ============
step5_head = Table([[Paragraph("STEP 5", P_STEP_NUM), Paragraph("POST-REMOVAL CARE & COMPLICATIONS TO WATCH", P_HEAD)]],
                    colWidths=[16*mm, None])
step5_head.setStyle(TableStyle([
    ("BACKGROUND", (0,0), (0,0), NAVY),
    ("BACKGROUND", (1,0), (1,0), NAVY),
    ("VALIGN", (0,0), (-1,-1), "MIDDLE"),
    ("TOPPADDING", (0,0), (-1,-1), 4), ("BOTTOMPADDING", (0,0), (-1,-1), 4),
]))
story.append(step5_head)

post_left = Paragraph(
    "<b>After successful removal:</b><br/>"
    "\u2022 Observe until fully awake &amp; tolerating oral intake<br/>"
    "\u2022 Start a <b>PPI</b><br/>"
    "\u2022 Arrange outpatient <b>repeat endoscopy</b> \u2014 up to 25% have an underlying "
    "esophageal disorder (stricture, EoE, ring, malignancy)<br/>"
    "\u2022 Discharge advice: return if fever, worsening pain, or dysphagia",
    P_BODY)

post_right = Paragraph(
    "<b><font color='#C0392B'>Watch for perforation / complications</font></b> "
    "(may present hours\u2013days, rarely years, later):<br/>"
    "\u2022 Perforation \u2192 mediastinitis, abscess<br/>"
    "\u2022 Tracheoesophageal fistula<br/>"
    "\u2022 Aorto-esophageal fistula (catastrophic, esp. near aortic arch)<br/>"
    "\u2022 Risk \u2191 with impaction &gt;24 h, sharp/bone objects, delayed care",
    P_BODY)

post_tbl = Table([[post_left, post_right]], colWidths=[None, None])
post_tbl.setStyle(TableStyle([
    ("BACKGROUND", (0,0), (0,0), BLUE_BG),
    ("BACKGROUND", (1,0), (1,0), RED_BG),
    ("BOX", (0,0), (-1,-1), 0.6, colors.HexColor("#BDC3C7")),
    ("INNERGRID", (0,0), (-1,-1), 0.4, colors.HexColor("#BDC3C7")),
    ("VALIGN", (0,0), (-1,-1), "TOP"),
    ("LEFTPADDING", (0,0), (-1,-1), 6), ("RIGHTPADDING", (0,0), (-1,-1), 6),
    ("TOPPADDING", (0,0), (-1,-1), 5), ("BOTTOMPADDING", (0,0), (-1,-1), 5),
]))
story.append(post_tbl)
story.append(Spacer(1, 4))

# ============ ANATOMY STRIP ============
anat = Paragraph(
    "<b>4 anatomic narrowings where FBs lodge:</b> "
    "cricopharyngeus (UES) \u2014 most common site, esp. adults/children &nbsp;\u2192&nbsp; aortic arch crossing "
    "&nbsp;\u2192&nbsp; left mainstem bronchus crossing &nbsp;\u2192&nbsp; LES at diaphragmatic hiatus. "
    "~90% of true esophageal obstructions occur at a pre-existing structural abnormality (peptic/malignant stricture, Schatzki ring, eosinophilic esophagitis).",
    P_BODY)
anat_tbl = box([[anat]], bg=GREY_BG)
story.append(anat_tbl)
story.append(Spacer(1, 3))

# ============ FOOTER ============
foot = Paragraph(
    "<b>Sources:</b> ROSEN's Emergency Medicine: Concepts and Clinical Practice, \"Foreign Bodies\", p.1219\u20131222 &middot; "
    "ESGE Clinical Guideline \u2013 Removal of foreign bodies in the upper GI tract in adults (Birk et al., Endoscopy 2016) &middot; "
    "Ismail et al., Glucagon for Esophageal FB Impaction: Systematic Review &amp; Meta-analysis, PMID 39292844 (2024) &middot; "
    "Ahmed et al., Cap-Assisted Endoscopic Esophageal FB Removal, PMID 36350475 (2023).<br/>"
    "This card is an educational quick-reference for trainees; it does not replace local institutional protocols or specialist (GI/ENT/Surgery) judgment.",
    P_FOOT)
story.append(Spacer(1, 2))
story.append(foot)

doc = SimpleDocTemplate(
    "/tmp/workspace/esophageal-fb-card/Esophageal_Foreign_Body_Quick_Reference_Card.pdf",
    pagesize=A4,
    leftMargin=12*mm, rightMargin=12*mm, topMargin=10*mm, bottomMargin=10*mm,
    title="Esophageal Foreign Body - Management Algorithm Quick Reference Card",
)
doc.build(story)
print("PDF built successfully.")
Running Command

cd /tmp/workspace/esophageal-fb-card && python build_card.py

Running Command

cd /tmp/workspace/esophageal-fb-card && python -c " import pdfplumber with pdfplumber.open('Esophageal_Foreign_Body_Quick_Reference_Card.pdf') as pdf: print('pages:', len(pdf.pages)) for p in pdf.pages: print(p.width, p.height) " ls -la /tmp/workspace/esophageal-fb-card/

Running Command

cd /tmp/workspace/esophageal-fb-card && python -c " import pdfplumber with pdfplumber.open('Esophageal_Foreign_Body_Quick_Reference_Card.pdf') as pdf: print(repr(pdf.pages[1].extract_text())) "

Editing File

~/esophageal-fb-card/build_card.py

Successfully replaced 1 instance(s) of the string in '/tmp/workspace/esophageal-fb-card/build_card.py'
Now reduce spacers and margins, and table paddings slightly:
Editing File

~/esophageal-fb-card/build_card.py

Successfully replaced 1 instance(s) of the string in '/tmp/workspace/esophageal-fb-card/build_card.py'
Editing File

~/esophageal-fb-card/build_card.py

Successfully replaced 5 instance(s) of the string in '/tmp/workspace/esophageal-fb-card/build_card.py'
Editing File

~/esophageal-fb-card/build_card.py

Successfully replaced 1 instance(s) of the string in '/tmp/workspace/esophageal-fb-card/build_card.py'
Editing File

~/esophageal-fb-card/build_card.py

Successfully replaced 1 instance(s) of the string in '/tmp/workspace/esophageal-fb-card/build_card.py'
Also reduce header bar padding and title block padding slightly, and table cell padding in step tables:
Editing File

~/esophageal-fb-card/build_card.py

Successfully replaced 1 instance(s) of the string in '/tmp/workspace/esophageal-fb-card/build_card.py'
Editing File

~/esophageal-fb-card/build_card.py

Successfully replaced 5 instance(s) of the string in '/tmp/workspace/esophageal-fb-card/build_card.py'
Now rebuild and check page count:
Running Command

cd /tmp/workspace/esophageal-fb-card && python build_card.py && python -c " import pdfplumber with pdfplumber.open('Esophageal_Foreign_Body_Quick_Reference_Card.pdf') as pdf: print('pages:', len(pdf.pages)) "

Now fits on a single page. Let me convert a page preview to verify visual layout looks correct.
Running Command

cd /tmp/workspace/esophageal-fb-card && python -c " import pdfplumber with pdfplumber.open('Esophageal_Foreign_Body_Quick_Reference_Card.pdf') as pdf: p = pdf.pages[0] im = p.to_image(resolution=150) im.save('preview.png') print('saved') "

Reading File
This looks clean, well-organized, and fits on a single A4 page with clear color-coded urgency levels. The card is complete and ready.
Running Command

rm -f /tmp/workspace/esophageal-fb-card/preview.png; ls -la /tmp/workspace/esophageal-fb-card/

I've built a single-page, color-coded quick-reference card covering the full esophageal foreign body management algorithm:
  • Step 1 - Recognize & Triage: typical symptoms + red flags requiring immediate action
  • Step 2 - Imaging: plain X-ray vs CT vs when to avoid barium swallow
  • Step 3 - Timing table: urgency stratified by object type (button battery = emergent <2h, bones/sharp objects = urgent 2-6h, food bolus = within 24h, passed objects = conservative)
  • Step 4 - Removal technique: flexible vs rigid endoscopy, Foley/bougienage (only for smooth objects, never for bones), and the evidence on glucagon
  • Step 5 - Post-removal care & complications: PPI, follow-up endoscopy, and red-flag complications (perforation, TE fistula, aorto-esophageal fistula)
  • A footer strip on the 4 anatomic narrowings, plus full source citations (Rosen's Emergency Medicine, ESGE guideline, and the two recent PubMed meta-analyses/reviews used in the earlier case discussion)

Esophageal Foreign Body Quick Reference Card

PDF Document · PDF

This is a shared conversation. Sign in to Orris to start your own chat.