I HAVE TO MAKE PPT ABOUT PHARYNGITIS FOR MY PADEATRICS CLASS, GIVE ME ALL THE INFO

Checking Date & Time
Reading File
Reading File
Reading File
Finding Sources
Finding Sources
Reading File
Reading File
Reading File
Searching Images

pharyngitis tonsillitis strep throat pediatric

Reading File
Reading File
Reading File
Reading File
Finding Sources
Reading File
Reading File
Reading File
Reading File
Reading File
Reading File
Running Command

ls /home/daytona/workspace/ 2>/dev/null || mkdir -p /home/daytona/workspace

Running Command

mkdir -p /home/daytona/workspace/pharyngitis-ppt && ls /home/daytona/workspace/pharyngitis-ppt

Writing File

~/pharyngitis-ppt/build.js

const pptxgen = require("pptxgenjs");
const { execSync } = require("child_process");

// ─── Color palette ───────────────────────────────────────────
const C = {
  navy:    "1A2E4A",  // dominant dark bg
  teal:    "0D7377",  // accent headers
  sky:     "14BDAC",  // highlight / bullets
  cream:   "F4F7F6",  // slide bg (light slides)
  white:   "FFFFFF",
  dark:    "1A2E4A",
  slate:   "4A5568",
  red:     "E53E3E",
  amber:   "D97706",
  green:   "276749",
};

const pres = new pptxgen();
pres.layout = "LAYOUT_16x9";
pres.author  = "Pediatrics Class";
pres.title   = "Pharyngitis in Pediatrics";

// ─── Helper – dark slide bg ──────────────────────────────────
function darkBg(slide) {
  slide.addShape(pres.shapes.RECTANGLE, { x:0, y:0, w:10, h:5.625, fill:{color: C.navy} });
}
function lightBg(slide) {
  slide.background = { color: C.cream };
}
function accentBar(slide, w=10) {
  slide.addShape(pres.shapes.RECTANGLE, { x:0, y:5.25, w, h:0.375, fill:{color: C.teal} });
}

// ─── Slide header helper ─────────────────────────────────────
function header(slide, txt, dark=true) {
  const bg = dark ? C.teal : C.navy;
  const fg = C.white;
  slide.addShape(pres.shapes.RECTANGLE, { x:0, y:0, w:10, h:0.9, fill:{color: bg} });
  slide.addText(txt, { x:0.35, y:0, w:9.3, h:0.9, fontSize:26, bold:true, color:fg, valign:"middle", margin:0 });
}

// ─── Fetch images ────────────────────────────────────────────
const IMG_URLS = [
  "https://cdn.orris.care/cdss_images/pmc_clinical_VQA_470e0e562fce5d66e77298905bb7405112ccc7a9c7636f8550c73d48c60e0f48.jpg",
  "https://cdn.orris.care/cdss_images/88e38964082c0b6bfc7599b333a9481c3321c64d34da8a744121ad901dbb53ce.png",
  "https://cdn.orris.care/cdss_images/GLGCA_4589369_1766504320521_c8c13015-f6b5-4a29-9ac9-a12abb92e4a4_7792d7c7-4fe2-4bdb-8a0f-a60991e413e4.png",
];
let imgData = [];
try {
  const raw = execSync(`node /home/daytona/skills/shared/scripts/fetch_images.js "${IMG_URLS[0]}" "${IMG_URLS[1]}" "${IMG_URLS[2]}"`, { timeout:30000 }).toString();
  imgData = JSON.parse(raw);
} catch(e) {
  console.error("Image fetch failed:", e.message);
  imgData = [{error:"fail"},{error:"fail"},{error:"fail"}];
}

// ────────────────────────────────────────────────────────────
//  SLIDE 1 – TITLE
// ────────────────────────────────────────────────────────────
{
  const s = pres.addSlide();
  darkBg(s);
  // Decorative accent strip
  s.addShape(pres.shapes.RECTANGLE, { x:0, y:0, w:0.18, h:5.625, fill:{color: C.sky} });
  s.addShape(pres.shapes.RECTANGLE, { x:0, y:4.8, w:10, h:0.825, fill:{color: C.teal} });

  s.addText("PHARYNGITIS", { x:0.5, y:1.0, w:9, h:1.2, fontSize:54, bold:true, color:C.white, align:"center", charSpacing:4 });
  s.addText("IN PEDIATRICS", { x:0.5, y:2.1, w:9, h:0.7, fontSize:28, bold:false, color:C.sky, align:"center", charSpacing:6 });
  s.addShape(pres.shapes.RECTANGLE, { x:3, y:2.95, w:4, h:0.06, fill:{color: C.sky} });
  s.addText("A Comprehensive Review for the Pediatrics Classroom", { x:0.5, y:3.15, w:9, h:0.5, fontSize:14, italic:true, color:"AECFCF", align:"center" });
  s.addText("April 2026", { x:0.5, y:5.0, w:9, h:0.4, fontSize:11, color:C.white, align:"center" });
}

// ────────────────────────────────────────────────────────────
//  SLIDE 2 – OUTLINE
// ────────────────────────────────────────────────────────────
{
  const s = pres.addSlide();
  lightBg(s);
  header(s, "Outline", false);
  accentBar(s);
  const items = [
    "Definition & Overview",
    "Epidemiology",
    "Etiology – Viral vs Bacterial",
    "Clinical Presentation",
    "Diagnostic Approach",
    "Modified Centor Score",
    "Management & Treatment",
    "Complications",
    "Scarlet Fever",
    "Special Topics (EBV, PFAPA, PANDAS)",
  ];
  const rows = items.map((t, i) => [
    { text: `${i+1}.`, options:{ bold:true, color:C.teal } },
    { text: `  ${t}`, options:{ color:C.dark } },
  ]);
  s.addTable(rows, {
    x:1.2, y:1.05, w:7.6,
    colW:[0.5, 7.1],
    rowH: 0.38,
    border:{pt:0, color: C.cream},
    fontSize: 16,
  });
}

// ────────────────────────────────────────────────────────────
//  SLIDE 3 – DEFINITION & OVERVIEW
// ────────────────────────────────────────────────────────────
{
  const s = pres.addSlide();
  lightBg(s);
  header(s, "Definition & Overview");
  accentBar(s);
  const bullets = [
    "Pharyngitis = inflammation of the pharynx; tonsillopharyngitis when tonsils are involved",
    "Accounts for 6% of all pediatric office visits → >7 million primary care visits/year in the US",
    "50–80% of pediatric acute pharyngitis cases are viral in etiology",
    "Most viral infections are self-limited; 85% resolve spontaneously within 1 week",
    "Distinguishing viral from bacterial causes on clinical exam alone is unreliable",
    "Peak incidence of bacterial (GAS) pharyngitis: school-aged children 5–15 years",
  ];
  s.addText(bullets.map((b,i) => [
    { text:"▸  ", options:{color:C.sky, bold:true} },
    { text:b + (i<bullets.length-1 ? "\n" : ""), options:{color:C.dark} }
  ]).flat(), { x:0.5, y:1.05, w:9, h:4, fontSize:15.5, paraSpaceAfter:4 });
}

// ────────────────────────────────────────────────────────────
//  SLIDE 4 – EPIDEMIOLOGY
// ────────────────────────────────────────────────────────────
{
  const s = pres.addSlide();
  darkBg(s);
  header(s, "Epidemiology");
  accentBar(s);
  const stats = [
    ["Age", "GAS peaks at 7–8 years; rare <3 years; less common in adults"],
    ["Seasonality", "Late autumn, winter, spring (temperate climates) — school contact"],
    ["Prevalence", "GAS carriage up to 25% in healthy school children during outbreaks"],
    ["GAS Incidence", "20–40% of pediatric pharyngitis cases; 5–15% of adult cases"],
    ["Incubation", "2–5 days for streptococcal pharyngitis"],
    ["Transmission", "Respiratory droplets; peaks during acute infection when untreated"],
  ];
  s.addTable(stats.map(([k,v]) => [
    { text: k, options:{ bold:true, color:C.sky, fill:{color:"243A52"} } },
    { text: v, options:{ color:C.white, fill:{color:"1E3347"} } },
  ]), {
    x:0.5, y:1.05, w:9, colW:[2.2,6.8],
    rowH:0.62,
    border:{ pt:1, color:"2D4D68" },
    fontSize:14,
  });
}

// ────────────────────────────────────────────────────────────
//  SLIDE 5 – ETIOLOGY
// ────────────────────────────────────────────────────────────
{
  const s = pres.addSlide();
  lightBg(s);
  header(s, "Etiology – Viral vs Bacterial", false);
  accentBar(s);

  // Two columns
  s.addShape(pres.shapes.RECTANGLE, { x:0.3, y:1.05, w:4.4, h:3.9, fill:{color:"E8F4F8"}, shadow:{type:"outer",color:"000000",blur:4,offset:2,angle:135,opacity:0.1} });
  s.addShape(pres.shapes.RECTANGLE, { x:5.3, y:1.05, w:4.4, h:3.9, fill:{color:"FFF5F5"}, shadow:{type:"outer",color:"000000",blur:4,offset:2,angle:135,opacity:0.1} });

  s.addText("🦠  VIRAL (50–80%)", { x:0.3, y:1.05, w:4.4, h:0.5, fontSize:14, bold:true, color:C.teal, align:"center" });
  const viral = ["Adenovirus","Rhinovirus","Enterovirus (Coxsackie)","Epstein-Barr Virus (EBV)","Influenza A & B","Parainfluenza","RSV","Herpes Simplex (HSV)","Coronavirus","CMV / HIV"];
  s.addText(viral.map(v=>({ text:"• "+v+"\n", options:{color:C.dark} })), { x:0.45, y:1.6, w:4.1, h:3.2, fontSize:13, paraSpaceAfter:1 });

  s.addText("🧫  BACTERIAL (20–50%)", { x:5.3, y:1.05, w:4.4, h:0.5, fontSize:14, bold:true, color:C.red, align:"center" });
  const bact = ["Group A Strep (GAS) – most common","Group C & G Streptococci","Mycoplasma pneumoniae","Arcanobacterium haemolyticum","Fusobacterium necrophorum","Neisseria gonorrhoeae (adolescents)","Corynebacterium diphtheriae (rare)"];
  s.addText(bact.map(v=>({ text:"• "+v+"\n", options:{color:C.dark} })), { x:5.45, y:1.6, w:4.1, h:3.2, fontSize:13, paraSpaceAfter:1 });
}

// ────────────────────────────────────────────────────────────
//  SLIDE 6 – CLINICAL PRESENTATION
// ────────────────────────────────────────────────────────────
{
  const s = pres.addSlide();
  lightBg(s);
  header(s, "Clinical Presentation", false);
  accentBar(s);

  // Left column – symptoms
  s.addShape(pres.shapes.RECTANGLE, { x:0.3, y:1.0, w:4.5, h:4.0, fill:{color:C.navy} });
  s.addText("Symptoms", { x:0.3, y:1.0, w:4.5, h:0.45, fontSize:15, bold:true, color:C.sky, align:"center" });
  const syms = ["Sore throat / odynophagia","Fever","Headache","Abdominal pain, nausea, vomiting","Cough, hoarseness, coryza (viral)","Diarrhea","Arthralgias / myalgias","Lethargy"];
  s.addText(syms.map(v=>({ text:"▸ "+v+"\n", options:{color:C.white} })), { x:0.45, y:1.5, w:4.2, h:3.3, fontSize:13, paraSpaceAfter:3 });

  // Right column – signs
  s.addShape(pres.shapes.RECTANGLE, { x:5.2, y:1.0, w:4.5, h:4.0, fill:{color:"243A52"} });
  s.addText("Physical Findings", { x:5.2, y:1.0, w:4.5, h:0.45, fontSize:15, bold:true, color:C.sky, align:"center" });
  const signs = ["Tonsillopharyngeal erythema ± exudates","Soft palate petechiae","Uvulitis / uvula edema","Anterior cervical lymphadenitis","Scarlatiniform rash (GAS)","Conjunctivitis (adenovirus)","Anterior stomatitis / ulcers","Posterior cervical LAD (EBV)"];
  s.addText(signs.map(v=>({ text:"▸ "+v+"\n", options:{color:C.white} })), { x:5.35, y:1.5, w:4.2, h:3.3, fontSize:13, paraSpaceAfter:3 });
}

// ────────────────────────────────────────────────────────────
//  SLIDE 7 – CLINICAL PHOTO
// ────────────────────────────────────────────────────────────
{
  const s = pres.addSlide();
  darkBg(s);
  header(s, "Clinical Appearance");
  accentBar(s);

  if (!imgData[0]?.error) {
    s.addImage({ data: imgData[0].base64, x:0.4, y:1.0, w:5.5, h:3.9 });
  }
  if (!imgData[1]?.error) {
    s.addImage({ data: imgData[1].base64, x:6.2, y:1.0, w:3.5, h:3.9 });
  }
  s.addText([
    { text:"Left: ", options:{bold:true, color:C.sky} },
    { text:"Normal throat (a) vs Strep pharyngitis (b). Note erythema, tonsillar exudates, uvular edema.", options:{color:C.white} }
  ], { x:0.4, y:4.95, w:9.2, h:0.25, fontSize:10, italic:true });
}

// ────────────────────────────────────────────────────────────
//  SLIDE 8 – DIAGNOSIS
// ────────────────────────────────────────────────────────────
{
  const s = pres.addSlide();
  lightBg(s);
  header(s, "Diagnostic Approach", false);
  accentBar(s);

  const steps = [
    ["1", "Test children with pharyngitis + no obvious viral features (no rhinorrhea, cough, oral ulcers)"],
    ["2", "Do NOT test children <3 years (low risk for GAS complications)"],
    ["3", "Swab both tonsils and posterior pharynx vigorously"],
    ["4", "Rapid Antigen Detection Test (RADT):\n   Sensitivity 80–85%; Specificity high\n   A positive result does not need confirmation"],
    ["5", "If RADT negative in a child → send backup throat culture on sheep blood agar\n   (Gold standard; false-negative <10% with adequate swab)"],
    ["6", "Nucleic Acid Amplification Tests (NAAT / PCR):\n   Sensitivity 97.5%, Specificity 95% — preferred when available"],
    ["7", "In adults: negative RADT does not need culture (low GAS risk)"],
  ];
  s.addTable(steps.map(([n,v]) => [
    { text:n, options:{ bold:true, fontSize:16, color:C.white, fill:{color:C.teal}, align:"center" } },
    { text:v, options:{ fontSize:13, color:C.dark, fill:{color: C.white} } }
  ]), {
    x:0.35, y:1.05, w:9.3, colW:[0.5, 8.8],
    rowH:0.54,
    border:{pt:1, color:"C8D8D8"},
    fontSize:13,
  });
}

// ────────────────────────────────────────────────────────────
//  SLIDE 9 – CENTOR SCORE
// ────────────────────────────────────────────────────────────
{
  const s = pres.addSlide();
  darkBg(s);
  header(s, "Modified Centor Score (McIsaac Criteria)");
  accentBar(s);

  // Criteria table
  const criteria = [
    ["Criterion","Points"],
    ["Temperature >38°C", "+1"],
    ["Absence of cough", "+1"],
    ["Swollen tender anterior cervical lymph nodes", "+1"],
    ["Tonsillar swelling or exudate", "+1"],
    ["Age 3–14 years", "+1"],
    ["Age >44 years", "−1"],
  ];
  s.addTable(criteria.map((row,i) => row.map(cell => ({
    text: cell,
    options: {
      bold: i===0,
      color: i===0 ? C.navy : (cell.startsWith("+") ? C.sky : C.red),
      fill: { color: i===0 ? C.sky : (i%2===0 ? "1E3347" : "243A52") },
      fontSize: i===0 ? 13 : 14,
      align: i===0 ? "center" : (cell.startsWith("+") || cell.startsWith("−") ? "center" : "left"),
    }
  }))), { x:0.4, y:1.0, w:5.8, colW:[4.5,1.3], rowH:0.49, border:{pt:1, color:"2D4D68"} });

  // Management table
  const mgmt = [
    ["Score","Risk","Action"],
    ["≤0","1–2.5%","No test, no antibiotics"],
    ["1","5–10%","No test, no antibiotics"],
    ["2","11–17%","Test → treat if positive"],
    ["3","28–35%","Test → treat if positive"],
    ["≥4","51–53%","Empirical antibiotics"],
  ];
  s.addText("Suggested Management", { x:6.4, y:0.95, w:3.4, h:0.4, fontSize:13, bold:true, color:C.sky });
  s.addTable(mgmt.map((row,i) => row.map((cell,j) => ({
    text: cell,
    options: {
      bold: i===0,
      color: i===0 ? C.navy : (j===1 ? C.amber : C.white),
      fill: { color: i===0 ? C.sky : (i%2===0 ? "1E3347" : "243A52") },
      fontSize: 12,
      align: "center",
    }
  }))), { x:6.3, y:1.35, w:3.5, colW:[0.7,1.0,1.8], rowH:0.54, border:{pt:1, color:"2D4D68"} });

  s.addText("Score ≤1 → avoid testing in children <3 yrs; Score ≥4 → treat empirically without waiting for results", {
    x:0.4, y:4.8, w:9.2, h:0.3, fontSize:11, italic:true, color:"AECFCF"
  });
}

// ────────────────────────────────────────────────────────────
//  SLIDE 10 – TREATMENT
// ────────────────────────────────────────────────────────────
{
  const s = pres.addSlide();
  lightBg(s);
  header(s, "Management & Treatment", false);
  accentBar(s);

  // Cols
  s.addShape(pres.shapes.RECTANGLE, {x:0.3,y:1.0,w:9.4,h:0.45, fill:{color:C.teal}});
  s.addText("GAS Pharyngitis – Antibiotic Therapy", {x:0.3,y:1.0,w:9.4,h:0.45, fontSize:14, bold:true, color:C.white, align:"center"});

  const rows = [
    ["Drug","Regimen","Notes"],
    ["Amoxicillin\n(1st line, preferred)","50 mg/kg/day (max 1000–1200 mg)\nOnce daily × 10 days","Endorsed by AHA & IDSA; palatable suspension"],
    ["Penicillin V","250 mg 2–3×/day (<27 kg)\n500 mg 2–3×/day (≥27 kg) × 10 days","GAS never penicillin-resistant"],
    ["Penicillin G benzathine","Single IM injection (dose by weight)","Ensures adherence; painful"],
    ["Cephalexin (PCN allergy, non-anaphylactic)","First-gen cephalosporin × 10 days","Avoid if type-I PCN hypersensitivity"],
    ["Clindamycin (anaphylactic PCN allergy)","20 mg/kg/day in 3 doses (max 900 mg/day) × 10 days","Check susceptibility"],
    ["Azithromycin (PCN allergy)","× 5 days","20–30% macrolide resistance in some areas"],
    ["DO NOT USE","Tetracyclines, sulfonamides, fluoroquinolones","Ineffective / inappropriate for GAS"],
  ];
  s.addTable(rows.map((row,i) => row.map((cell,j) => ({
    text: cell,
    options: {
      bold: i===0 || j===0,
      color: i===0 ? C.white : (row[0].includes("NOT") ? C.red : C.dark),
      fill: { color: i===0 ? C.navy : (i%2===0 ? "EAF3F3" : C.white) },
      fontSize: i===0 ? 12 : 11.5,
      align: j===2 ? "left" : "left",
    }
  }))), {
    x:0.3, y:1.5, w:9.4, colW:[2.4,3.3,3.7],
    rowH:0.48,
    border:{pt:1, color:"C8D8D8"},
  });

  s.addText("Full 10-day course essential to prevent acute rheumatic fever (ARF)", {
    x:0.4, y:5.05, w:9.2, h:0.3, fontSize:12, bold:true, color:C.teal
  });
}

// ────────────────────────────────────────────────────────────
//  SLIDE 11 – VIRAL TREATMENT
// ────────────────────────────────────────────────────────────
{
  const s = pres.addSlide();
  darkBg(s);
  header(s, "Viral Pharyngitis – Management");
  accentBar(s);

  s.addText("Treatment is supportive — antibiotics are NOT indicated", {
    x:0.5, y:1.0, w:9, h:0.5, fontSize:18, bold:true, color:C.sky, align:"center"
  });

  const items = [
    ["Analgesia / Antipyretics","NSAIDs (ibuprofen) or acetaminophen for pain and fever relief"],
    ["Hydration","Encourage oral fluids; IV fluids if unable to swallow"],
    ["Throat lozenges","May provide symptomatic relief in older children"],
    ["Corticosteroids (EBV)","Single dose oral/IV steroid may reduce tonsillar swelling — no proven efficacy, but considered if airway compromise"],
    ["Avoid amoxicillin/ampicillin","In EBV: causes characteristic pruritic maculopapular rash in up to 90% of patients"],
    ["EBV / Mono — restrict contact sports","Risk of splenic rupture if splenomegaly confirmed"],
    ["No antivirals routinely indicated","Exception: influenza in high-risk patients (oseltamivir)"],
  ];
  s.addTable(items.map(([k,v],i) => [
    { text:k, options:{bold:true, color:C.sky, fill:{color: i%2===0?"1E3347":"243A52"}, fontSize:13} },
    { text:v, options:{color:C.white, fill:{color: i%2===0?"1E3347":"243A52"}, fontSize:13} }
  ]), { x:0.4, y:1.6, w:9.2, colW:[3.0,6.2], rowH:0.47, border:{pt:1,color:"2D4D68"} });
}

// ────────────────────────────────────────────────────────────
//  SLIDE 12 – COMPLICATIONS
// ────────────────────────────────────────────────────────────
{
  const s = pres.addSlide();
  lightBg(s);
  header(s, "Complications", false);
  accentBar(s);

  // Suppurative
  s.addShape(pres.shapes.RECTANGLE, {x:0.3,y:1.0,w:4.5,h:0.45,fill:{color:C.red}});
  s.addText("Suppurative (Local Spread)", {x:0.3,y:1.0,w:4.5,h:0.45,fontSize:14,bold:true,color:C.white,align:"center"});
  const supp = ["Peritonsillar abscess","Retropharyngeal abscess","Cervical lymphadenitis","Sinusitis","Otitis media","Mastoiditis","Meningitis / Bacteremia / Endocarditis","Pneumonia"];
  s.addText(supp.map(v=>({text:"❗ "+v+"\n",options:{color:C.dark}})), {x:0.45,y:1.5,w:4.2,h:3.5,fontSize:13,paraSpaceAfter:3});

  // Non-suppurative
  s.addShape(pres.shapes.RECTANGLE, {x:5.2,y:1.0,w:4.5,h:0.45,fill:{color:C.amber}});
  s.addText("Non-Suppurative (Immune-Mediated)", {x:5.2,y:1.0,w:4.5,h:0.45,fontSize:14,bold:true,color:C.white,align:"center"});
  const nonsupp = [
    "Acute Rheumatic Fever (ARF)\n  – PCN prevents ARF; start within 9 days",
    "Post-Streptococcal Glomerulonephritis (PSGN)\n  – NOT prevented by antibiotics",
    "PANDAS / PANS\n  – GAS association proposed; evidence limited",
    "Streptococcal Toxic Shock Syndrome (STSS)\n  – Rare but life-threatening",
  ];
  s.addText(nonsupp.map(v=>({text:"⚠ "+v+"\n",options:{color:C.dark}})), {x:5.35,y:1.5,w:4.2,h:3.5,fontSize:12.5,paraSpaceAfter:6});
}

// ────────────────────────────────────────────────────────────
//  SLIDE 13 – SCARLET FEVER
// ────────────────────────────────────────────────────────────
{
  const s = pres.addSlide();
  darkBg(s);
  header(s, "Scarlet Fever");
  accentBar(s);

  s.addText([
    {text:"Definition: ", options:{bold:true,color:C.sky}},
    {text:"GAS pharyngitis + fever + characteristic rash\n", options:{color:C.white}},
    {text:"90% occur in children aged 2–8 years; peak in winter (temperate climates)\n\n", options:{color:"AECFCF",italic:true}},
  ], {x:0.5,y:1.05,w:9,h:0.9,fontSize:14});

  const feat = [
    ["Rash","Begins day 1–2 on trunk → limbs; minute papules = 'sandpaper' texture; spares palms & soles"],
    ["Pastia Lines","Petechiae in skin folds / flexion creases (elbow)"],
    ["Face","Flushed cheeks, circumoral pallor"],
    ["Tongue","'Strawberry tongue' — enlarged papillae"],
    ["Resolution","Rash fades 6–9 days → desquamation of palms and soles"],
    ["Mechanism","Erythrogenic exotoxins (superantigens) produced by GAS — pyrogenic exotoxins A/B/C"],
    ["Treatment","Same as GAS pharyngitis — penicillin × 10 days"],
    ["DDx","Measles, viral exanthem, Kawasaki, TSS, drug reaction"],
  ];
  s.addTable(feat.map(([k,v],i) => [
    {text:k, options:{bold:true, color:C.sky, fill:{color: i%2===0?"1E3347":"243A52"}, fontSize:13}},
    {text:v, options:{color:C.white, fill:{color: i%2===0?"1E3347":"243A52"}, fontSize:13}},
  ]), {x:0.4,y:2.0,w:9.2,colW:[2.2,7.0],rowH:0.42,border:{pt:1,color:"2D4D68"}});
}

// ────────────────────────────────────────────────────────────
//  SLIDE 14 – EBV / MONO
// ────────────────────────────────────────────────────────────
{
  const s = pres.addSlide();
  lightBg(s);
  header(s, "Special Focus: EBV Infectious Mononucleosis", false);
  accentBar(s);

  const left = [
    "Most common serious viral pharyngitis in pediatrics",
    "Classic triad: exudative pharyngitis, posterior cervical lymphadenopathy, splenomegaly/hepatomegaly",
    "Prodrome: malaise, headache, fever → then exudative pharyngitis",
    "Monospot (heterophile antibody):\n  – Only 25% positive age 10–24 months\n  – 75% positive age 24–28 months\n  – Negative early (<1 week) — does NOT exclude EBV",
    "Atypical lymphocytes on CBC",
    "EBV-specific IgM/IgG: sensitive & specific but not rapid",
  ];
  s.addText(left.map(v=>({text:"▸ "+v+"\n",options:{color:C.dark}})), {x:0.4,y:1.05,w:5.6,h:4.3,fontSize:13,paraSpaceAfter:4});

  // Photo
  if (!imgData[2]?.error) {
    s.addImage({ data: imgData[2].base64, x:6.2, y:1.05, w:3.4, h:2.8 });
  }
  s.addShape(pres.shapes.RECTANGLE, {x:6.2,y:3.9,w:3.4,h:1.35,fill:{color:C.navy}});
  s.addText([
    {text:"⚠ AVOID amoxicillin/ampicillin\n",options:{bold:true,color:C.red}},
    {text:"→ Causes widespread maculopapular rash in EBV patients\n\n",options:{color:C.white}},
    {text:"Restrict contact sports if splenomegaly (splenic rupture risk)",options:{color:C.sky}},
  ], {x:6.2,y:3.9,w:3.4,h:1.35,fontSize:11.5,margin:8});
}

// ────────────────────────────────────────────────────────────
//  SLIDE 15 – PFAPA & PANDAS
// ────────────────────────────────────────────────────────────
{
  const s = pres.addSlide();
  darkBg(s);
  header(s, "Special Topics: PFAPA & PANDAS/PANS");
  accentBar(s);

  s.addShape(pres.shapes.RECTANGLE, {x:0.3,y:1.0,w:4.6,h:4.35,fill:{color:"1E3347"}});
  s.addText("PFAPA Syndrome", {x:0.3,y:1.0,w:4.6,h:0.45,fontSize:15,bold:true,color:C.sky,align:"center"});
  const pfapa = [
    "Most common cause of pediatric recurrent fever",
    "Periodic Fever, Aphthous ulcers, Pharyngitis, Adenopathy",
    "Prodrome: malaise, irritability, fatigue",
    "Episodes every 3–8 weeks; self-resolving",
    "NOT streptococcal in origin",
    "Corticosteroids (single dose) abort episodes",
    "Tonsillectomy may be curative in refractory cases",
  ];
  s.addText(pfapa.map(v=>({text:"▸ "+v+"\n",options:{color:C.white}})), {x:0.45,y:1.55,w:4.3,h:3.65,fontSize:12.5,paraSpaceAfter:4});

  s.addShape(pres.shapes.RECTANGLE, {x:5.1,y:1.0,w:4.6,h:4.35,fill:{color:"2B3A2A"}});
  s.addText("PANDAS / PANS", {x:5.1,y:1.0,w:4.6,h:0.45,fontSize:15,bold:true,color:C.sky,align:"center"});
  const pandas = [
    "PANDAS = Pediatric Autoimmune Neuropsychiatric Disorders Associated with Streptococcal Infections",
    "PANS = Pediatric Acute-onset Neuropsychiatric Syndrome (broader)",
    "Proposed: GAS infection → sudden OCD, tic disorders, neuropsychiatric changes",
    "Evidence based on small, unduplicated studies",
    "GAS testing NOT recommended without clinical pharyngitis",
    "No proven benefit of antibiotics, IVIG, or plasmapheresis",
    "Refer to child psychiatry / neurology",
  ];
  s.addText(pandas.map(v=>({text:"▸ "+v+"\n",options:{color:C.white}})), {x:5.25,y:1.55,w:4.3,h:3.65,fontSize:12,paraSpaceAfter:4});
}

// ────────────────────────────────────────────────────────────
//  SLIDE 16 – WHEN TO WORRY / RED FLAGS
// ────────────────────────────────────────────────────────────
{
  const s = pres.addSlide();
  lightBg(s);
  header(s, "Red Flags – When to Worry", false);
  accentBar(s);

  s.addText("Distinguish superficial pharyngitis from deep space infections!", {
    x:0.5,y:1.0,w:9,h:0.4,fontSize:15,bold:true,color:C.red,align:"center"
  });

  const flags = [
    ["Toxic appearance / high fever","Possible deep space infection, bacteremia"],
    ["Drooling","Epiglottitis, retropharyngeal abscess"],
    ["Stridor","Airway compromise — EMERGENCY"],
    ["Trismus (jaw lock)","Peritonsillar / masseteric space abscess"],
    ["Torticollis","Retropharyngeal or parapharyngeal abscess"],
    ["Uvulitis + respiratory distress","H. influenzae — may need intubation"],
    ["Skin petechiae / shock","GAS toxic shock syndrome (STSS)"],
    ["Unilateral tonsillar swelling","Peritonsillar abscess — needs drainage"],
    ["Inability to swallow + splenomegaly","EBV with risk of splenic rupture"],
  ];
  s.addTable(flags.map(([sign,concern],i) => [
    {text:"🚨 "+sign, options:{bold:true,color:C.red,fill:{color:i%2===0?"FFF0F0":"FFEBE8"},fontSize:13}},
    {text:concern, options:{color:C.dark,fill:{color:i%2===0?"FFF0F0":"FFEBE8"},fontSize:13}},
  ]), {x:0.4,y:1.45,w:9.2,colW:[4.0,5.2],rowH:0.4,border:{pt:1,color:"F5C6CB"}});
}

// ────────────────────────────────────────────────────────────
//  SLIDE 17 – SUMMARY
// ────────────────────────────────────────────────────────────
{
  const s = pres.addSlide();
  darkBg(s);
  s.addShape(pres.shapes.RECTANGLE, {x:0,y:0,w:0.18,h:5.625,fill:{color:C.sky}});
  s.addShape(pres.shapes.RECTANGLE, {x:0,y:4.8,w:10,h:0.825,fill:{color:C.teal}});
  s.addText("Key Takeaways", {x:0.5,y:0.2,w:9,h:0.7,fontSize:28,bold:true,color:C.sky,align:"center",charSpacing:2});

  const pts = [
    "50–80% of pediatric pharyngitis is viral — most resolve in 1 week without antibiotics",
    "GAS is the most important bacterial cause: 20–40% of pediatric cases",
    "Clinical diagnosis alone is unreliable — always confirm GAS with RADT or culture",
    "Modified Centor score guides testing and treatment decisions",
    "First-line: Amoxicillin (once-daily × 10 days) or Penicillin V × 10 days",
    "Full 10-day course prevents Acute Rheumatic Fever",
    "EBV: avoid amoxicillin/ampicillin; restrict sports if splenomegaly",
    "Know red flags for deep space infection — these are emergencies",
    "ARF prevented by antibiotics; PSGN is NOT prevented by antibiotics",
  ];
  s.addText(pts.map((p,i)=>[
    {text:`${i+1}. `,options:{bold:true,color:C.sky}},
    {text:p+(i<pts.length-1?"\n":""),options:{color:C.white}},
  ]).flat(), {x:0.5,y:0.95,w:9,h:3.7,fontSize:13.5,paraSpaceAfter:4});

  s.addText("Sources: Red Book 2021 (AAP), Goldman-Cecil Medicine, Tintinalli's EM, Harrison's 22E", {
    x:0.5,y:5.0,w:9,h:0.3,fontSize:10,italic:true,color:C.white,align:"center"
  });
}

// ─── Write file ───────────────────────────────────────────────
pres.writeFile({ fileName: "/home/daytona/workspace/pharyngitis-ppt/Pharyngitis_Pediatrics.pptx" })
  .then(() => console.log("DONE: Pharyngitis_Pediatrics.pptx written"))
  .catch(e => { console.error(e); process.exit(1); });
Running Command

cd /home/daytona/workspace/pharyngitis-ppt && node build.js 2>&1

Your credits are exhausted. Your daily credits reset tomorrow, or you can purchase a top-up for more.
This is a shared conversation. Sign in to Orris to start your own chat.