Create a 20-slide academic PowerPoint presentation on “SKIN IMMUNOLOGY” for a 1st-year Dermatology postgraduate (PGT-1) presenting in the Dermatology Department in front of the HOD, Professors, Senior Residents (SRs), and postgraduate trainees. PRIMARY OBJECTIVE The presentation should demonstrate: * Strong understanding of the fundamentals of cutaneous immunology * Ability to connect basic immunology → skin biology → immunopathogenesis → clinical dermatology * Appropriate depth for a 1st-year Dermatology postgraduate * Good preparation for faculty questions and viva * Clinically relevant examples rather than purely theoretical immunology Use Bolognia Dermatology and Rook’s Textbook of Dermatology as the major textbook references/frameworks. Supplement with standard dermatology/immunology literature where necessary, but do not make the presentation unnecessarily broad. Do NOT simply copy textbook paragraphs. Synthesize and teach the concepts. ⸻ SLIDE STRUCTURE — EXACTLY 20 SLIDES Slide 1 — Title SKIN IMMUNOLOGY * Name * Dermatology PGT-1 * Department of Dermatology * Institution * Presented before HOD / Professors / SRs Keep it professional and minimal. Slide 2 — Why is Skin an Immune Organ? Explain: * Skin as a physical barrier * Skin as an immunological barrier * Keratinocytes as immune-active cells * Resident immune cells * Skin-associated lymphoid functions * Innate + adaptive immunity * Why dermatologists need to understand cutaneous immunology Include a simple conceptual diagram: Barrier → Recognition → Innate response → Adaptive response → Resolution / Memory Slide 3 — Components of the Cutaneous Immune System Organize into: 1. Physical/chemical barrier 2. Innate immune system 3. Adaptive immune system 4. Resident immune cells 5. Cytokines and chemokines 6. Antimicrobial peptides 7. Complement 8. Neuroimmune interactions 9. Microbiome Create a high-yield overview diagram. Slide 4 — Epidermis as an Immune Barrier Cover: * Keratinocytes * Tight junctions * Stratum corneum * Lipids * Filaggrin and barrier function * Pattern-recognition receptors * Cytokine production * Chemokine production * Antimicrobial peptides * Role of keratinocytes in inflammation Explain the concept: Keratinocyte ≠ passive structural cell; it is an active immunological participant. Slide 5 — Innate Immunity of Skin Cover: * Pattern recognition receptors (PRRs) * PAMPs * DAMPs * TLRs * NOD-like receptors * Inflammasomes * Complement * Antimicrobial peptides * Neutrophils * Macrophages * NK cells Explain: Recognition → signaling → cytokines → recruitment → elimination Include clinically relevant examples. Slide 6 — Antimicrobial Peptides Discuss: * Defensins * Cathelicidin LL-37 * Dermcidin * RNases and other important AMPs For each important AMP: * Source * Trigger * Major function * Clinical relevance Clinical correlations: * Atopic dermatitis * Psoriasis * Acne * Rosacea * Skin infections Include the LL-37–psoriasis connection. Slide 7 — Dendritic Cells and Antigen Presentation Cover: * Langerhans cells * Dermal dendritic cells * Antigen uptake * Processing * MHC I and MHC II * Migration to lymph nodes * T-cell activation Clearly explain: Antigen capture → migration → antigen presentation → T-cell priming Mention the role of Langerhans cells in contact dermatitis and cutaneous immune surveillance. Slide 8 — T Cells in Skin Cover: * CD4+ T cells * CD8+ T cells * Regulatory T cells * Tissue-resident memory T cells (TRM) Explain: * T-cell trafficking to skin * Cutaneous lymphocyte antigen (CLA) * Chemokine receptors * Tissue residence * Immunological memory Include a table comparing: Th1 | Th2 | Th17 | Th22 | Treg | CD8+ For each: * Signature cytokines * Main function * Important dermatological diseases Slide 9 — T-Helper Cell Polarization Create a clear pathway diagram: Naïve CD4+ T cell ↓ Th1 / Th2 / Th17 / Th22 / Treg Include: * Differentiating cytokines * Master transcription factors * Signature cytokines * Major dermatological diseases High-yield molecules: * T-bet * GATA-3 * RORγt * AHR * FOXP3 Slide 10 — Cytokines and Chemokines Explain the cytokine network in dermatology. Cover major cytokines: * IL-1 * IL-4 * IL-5 * IL-6 * IL-10 * IL-12 * IL-13 * IL-17 * IL-22 * TNF-α * IFN-γ * TGF-β * IL-23 Create a clinically oriented table: Cytokine → Source → Major action → Dermatological relevance → Targeted therapy Highlight therapeutic targets: * TNF * IL-4/IL-13 * IL-17 * IL-23 * IL-31 Slide 11 — Skin Immune Cell Network Explain the interaction between: * Keratinocytes * Langerhans cells * Dermal dendritic cells * Macrophages * Mast cells * Neutrophils * T cells * B cells * NK cells Create a single integrated diagram showing cellular cross-talk. Slide 12 — Cutaneous Immune Surveillance and Trafficking Cover: * Skin-homing T cells * CLA * E-selectin * Chemokine receptors * CCL17 * CCL27 * CXCL9/CXCL10 * Leukocyte adhesion * Extravasation Explain the sequence: Rolling → Adhesion → Diapedesis → Chemotaxis → Tissue localization Connect to inflammatory dermatoses. Slide 13 — Adaptive Immunity: Humoral Immunity and B Cells Cover: * B cells * Plasma cells * Antibody production * IgG * IgA * IgE * IgM * Autoantibodies Clinical correlations: * Pemphigus * Bullous pemphigoid * Atopic dermatitis * Urticaria * Autoimmune connective tissue diseases Explain why antibodies can cause blistering diseases. Slide 14 — Immunological Tolerance and Autoimmunity Cover: * Central tolerance * Peripheral tolerance * Regulatory T cells * Anergy * Immune checkpoints * Loss of tolerance * Autoantibody formation * Autoreactive T cells Clinical examples: * Pemphigus vulgaris * Bullous pemphigoid * Cutaneous lupus * Dermatomyositis * Vitiligo Include a simple: Tolerance → Breakdown → Autoimmunity → Tissue damage Slide 15 — Hypersensitivity Reactions in Dermatology Explain Gell and Coombs classification: Type Mechanism Key mediators Dermatological examples I IgE-mediated Mast cells Urticaria, atopy II Antibody-mediated IgG/IgM Pemphigus, BP III Immune-complex Immune complexes Vasculitis IV T-cell mediated T cells Contact dermatitis, TB/leprosy reactions For Type IV, explain: * IVa * IVb * IVc * IVd Give dermatology examples. Slide 16 — Immunopathogenesis of Major Inflammatory Dermatoses Use 4–5 high-yield examples: Psoriasis IL-23 → Th17 → IL-17/IL-22 → keratinocyte activation Atopic dermatitis Barrier dysfunction → epithelial alarmins → Th2 → IL-4/IL-13 Allergic contact dermatitis Sensitization → T-cell response → elicitation Urticaria Mast cell activation → histamine and mediators Acne Cutibacterium acnes → innate immune activation → IL-1/TLR pathways → inflammation Keep this slide diagram-based. Slide 17 — Immunology of Infection and Leprosy Explain: * Host-pathogen interaction * Innate recognition * Cell-mediated immunity * Humoral immunity Use leprosy as the key dermatological example. Explain the immunological spectrum: Tuberculoid → Borderline → Lepromatous Correlate: * Th1/Th2 response * Cell-mediated immunity * Bacillary load * Granuloma formation * Clinical spectrum Also briefly mention immunological reactions: * Type 1 reaction * Type 2 reaction Slide 18 — Immunology and Modern Dermatological Therapeutics Show how understanding immunology has transformed dermatology. Create a table: Pathway → Drug class → Example → Disease Include: * TNF-α inhibitors * IL-17 inhibitors * IL-23 inhibitors * IL-4/IL-13 pathway inhibitors * JAK inhibitors * PDE4 inhibition * Calcineurin inhibition * CD20-directed therapy where relevant Emphasize: “From understanding the pathway to targeting the pathway.” Slide 19 — High-Yield Integration + Viva Questions Create a rapid-review slide with approximately 10–12 high-yield concepts, such as: * Why is skin considered an immune organ? * Why are keratinocytes immunologically important? * Difference between Langerhans cells and dermal dendritic cells * What is CLA? * What are TRM cells? * Th1 vs Th2 vs Th17 * Role of IL-23/IL-17 axis * Why is LL-37 important? * Type IV hypersensitivity subtypes * Immunological basis of psoriasis * Immunological basis of atopic dermatitis * Immunological basis of leprosy spectrum Slide 20 — Take-Home Messages + References Include 8–10 concise take-home messages. Then provide key references. Primary textbooks: * Bolognia Dermatology * Rook’s Textbook of Dermatology Also include selected high-quality review articles from: * Journal of Investigative Dermatology * Nature Reviews Immunology * New England Journal of Medicine where appropriate * British Journal of Dermatology * Journal of the American Academy of Dermatology * Indian Journal of Dermatology, Venereology and Leprology where relevant Use the latest available editions of Bolognia and Rook’s and provide edition/year information accurately. ⸻ DEPTH AND ACADEMIC STANDARD The presentation should be pitched at: PGT-1 level + one level above, so that it is appropriate for discussion with senior faculty. Avoid: * Overly basic undergraduate immunology * Excessive molecular biology with no dermatological relevance * Long paragraphs * Unnecessary rare pathways * Excessive text per slide Prioritize: Concept → mechanism → pathway → skin manifestation → clinical application ⸻ VISUAL DESIGN Use a professional academic dermatology/medical presentation style. For every slide: * Maximum 5–7 major bullets * Prefer diagrams, flowcharts, tables and pathway illustrations * Highlight important cytokines and immune cells * Use consistent terminology * Avoid decorative stock images * Avoid overcrowding * Use readable font sizes * Maintain consistent typography and spacing Use high-quality schematic immunology diagrams rather than random clinical images. ⸻ FACULTY-LEVEL QUALITY CONTROL Before finalizing the PPT, critically check: 1. Is the immunology scientifically accurate? 2. Is every major concept relevant to dermatology? 3. Are Bolognia and Rook’s adequately represented? 4. Are innate and adaptive immunity both covered? 5. Are Langerhans cells, dendritic cells, keratinocytes, T cells, B cells, mast cells and macrophages covered? 6. Are PRRs, TLRs, inflammasomes and AMPs covered? 7. Are Th1/Th2/Th17/Th22/Treg pathways clearly explained? 8. Are cytokines clinically connected to diseases and biologics? 9. Is hypersensitivity adequately covered? 10. Is autoimmunity covered? 11. Is leprosy immunology included? 12. Are modern biologic/JAK-targeted therapies connected to immunological pathways? 13. Are there obvious gaps that a Dermatology Professor could question? ⸻ IMPORTANT PRESENTATION REQUIREMENT After preparing the 20 slides, provide a separate section titled: “POSSIBLE QUESTIONS FROM HOD / PROFESSORS” Generate at least 25 likely viva/presentation questions, ranging from basic to advanced. For each question provide: * Question * Ideal 30–60 second answer * One high-yield point to remember Include questions such as: * Why is skin considered an immune organ? * What is the role of keratinocytes in immunity? * Langerhans cell vs dermal dendritic cell? * What is CLA? * What are tissue-resident memory T cells? * Explain Th17 differentiation. * Why is IL-23 important in psoriasis? * Why does IL-17 blockade predispose to candidiasis? * Difference between IL-17 and IL-23 targeting? * Explain the immunology of atopic dermatitis. * Explain Type IV hypersensitivity. * What are the four subtypes of Type IV hypersensitivity? * Explain the immunological spectrum of leprosy. * What is the role of LL-37? * What are alarmins? * What is the role of TLRs in skin? * What is inflammasome activation? * Why are JAK inhibitors effective in multiple inflammatory dermatoses? Finally provide: “1-MINUTE REVISION BEFORE PRESENTATION” Give a compact one-page/high-yield revision framework covering the entire topic from barrier → innate immunity → antigen presentation → T cells → cytokines → hypersensitivity → autoimmunity → disease pathways → targeted therapy. The final output must contain: 20 slides + speaker notes for every slide + 25+ faculty questions with answers + 1-minute revision sheet + references.

Reading File

Quick answer

Skin Immunology — Topic Map

This 20-slide brief spans a full cutaneous immunology syllabus. Here's the breakdown of what it covers:
  1. Skin as an immune organ — barrier concept, keratinocytes as immune cells, overall conceptual framework
  2. Components of cutaneous immune system — overview diagram (barrier, innate, adaptive, cells, cytokines, AMPs, complement, neuroimmune, microbiome)
  3. Epidermis/keratinocyte immunology — filaggrin, PRRs, tight junctions, barrier-immune crosstalk
  4. Innate immunity — PRRs, TLRs, NOD-like receptors, inflammasomes, complement, neutrophils, macrophages, NK cells
  5. Antimicrobial peptides — defensins, LL-37/cathelicidin, dermcidin, disease correlations (AD, psoriasis, rosacea)
  6. Dendritic cells/antigen presentation — Langerhans cells vs dermal DCs, MHC I/II, T-cell priming
  7. T cells in skin — CD4/CD8, Treg, TRM, CLA, trafficking; Th1/Th2/Th17/Th22/Treg comparison table
  8. Th polarization pathway — master transcription factors (T-bet, GATA-3, RORγt, AHR, FOXP3)
  9. Cytokine/chemokine network — IL-1 through IL-23, TNF-α, IFN-γ, TGF-β with disease + biologic targets
  10. Integrated immune cell cross-talk diagram
  11. Leukocyte trafficking/immune surveillance — rolling-adhesion-diapedesis-chemotaxis, CLA, selectins, chemokines
  12. Humoral immunity/B cells — pemphigus, bullous pemphigoid, autoantibody-mediated disease
  13. Tolerance and autoimmunity — central/peripheral tolerance, breakdown mechanisms, autoimmune dermatoses
  14. Hypersensitivity reactions — Gell-Coombs I-IV with Type IV subtypes (IVa-d) and dermatologic examples
  15. Immunopathogenesis of major dermatoses — psoriasis, AD, ACD, urticaria, acne pathways
  16. Leprosy immunology — Th1/Th2 spectrum, tuberculoid-lepromatous, Type 1/2 reactions
  17. Immunology-driven therapeutics — biologics/JAK inhibitors mapped to pathways
  18. High-yield viva integration — rapid review concepts
  19. Take-home messages + references (Bolognia, Rook's, key journals)
  20. Deliverable format — full PPTX file + speaker notes for all 20 slides + 25+ viva Q&A + 1-minute revision sheet
Given the scope (a full PPTX build with detailed speaker notes, tables, diagrams, and a 25+ question viva bank), building this properly requires deep, focused work per section rather than a shallow pass across all 20 slides at once.
Asking for Preferences

This is a large build (20 slides + notes + 25 viva Q&A + revision sheet). How would you like me to proceed?

Skin Immunology — Topic Map

This 20-slide brief spans a full cutaneous immunology syllabus. Here's the breakdown of what it covers:
  1. Skin as an immune organ — barrier concept, keratinocytes as immune cells, overall conceptual framework
  2. Components of cutaneous immune system — overview diagram (barrier, innate, adaptive, cells, cytokines, AMPs, complement, neuroimmune, microbiome)
  3. Epidermis/keratinocyte immunology — filaggrin, PRRs, tight junctions, barrier-immune crosstalk
  4. Innate immunity — PRRs, TLRs, NOD-like receptors, inflammasomes, complement, neutrophils, macrophages, NK cells
  5. Antimicrobial peptides — defensins, LL-37/cathelicidin, dermcidin, disease correlations (AD, psoriasis, rosacea)
  6. Dendritic cells/antigen presentation — Langerhans cells vs dermal DCs, MHC I/II, T-cell priming
  7. T cells in skin — CD4/CD8, Treg, TRM, CLA, trafficking; Th1/Th2/Th17/Th22/Treg comparison table
  8. Th polarization pathway — master transcription factors (T-bet, GATA-3, RORγt, AHR, FOXP3)
  9. Cytokine/chemokine network — IL-1 through IL-23, TNF-α, IFN-γ, TGF-β with disease + biologic targets
  10. Integrated immune cell cross-talk diagram
  11. Leukocyte trafficking/immune surveillance — rolling-adhesion-diapedesis-chemotaxis, CLA, selectins, chemokines
  12. Humoral immunity/B cells — pemphigus, bullous pemphigoid, autoantibody-mediated disease
  13. Tolerance and autoimmunity — central/peripheral tolerance, breakdown mechanisms, autoimmune dermatoses
  14. Hypersensitivity reactions — Gell-Coombs I-IV with Type IV subtypes (IVa-d) and dermatologic examples
  15. Immunopathogenesis of major dermatoses — psoriasis, AD, ACD, urticaria, acne pathways
  16. Leprosy immunology — Th1/Th2 spectrum, tuberculoid-lepromatous, Type 1/2 reactions
  17. Immunology-driven therapeutics — biologics/JAK inhibitors mapped to pathways
  18. High-yield viva integration — rapid review concepts
  19. Take-home messages + references (Bolognia, Rook's, key journals)
  20. Deliverable format — full PPTX file + speaker notes for all 20 slides + 25+ viva Q&A + 1-minute revision sheet
Given the scope (a full PPTX build with detailed speaker notes, tables, diagrams, and a 25+ question viva bank), building this properly requires deep, focused work per section rather than a shallow pass across all 20 slides at once.

Yes give one ppt

Reading File
Finding Sources
Finding Sources
Finding Sources
Finding Sources
Finding Sources
Writing File

~/skin-immunology-ppt/generate_ppt.py

# -*- coding: utf-8 -*-
"""
Generate: SKIN IMMUNOLOGY - 20-slide academic deck for Dermatology PGT-1
+ appendix: viva question bank + 1-minute revision sheet
"""
from pptx import Presentation
from pptx.util import Inches, Pt, Emu
from pptx.dml.color import RGBColor
from pptx.enum.text import PP_ALIGN, MSO_ANCHOR
from pptx.enum.shapes import MSO_SHAPE
import copy

prs = Presentation()
prs.slide_width = Inches(13.333)
prs.slide_height = Inches(7.5)
BLANK = prs.slide_layouts[6]
SW, SH = prs.slide_width, prs.slide_height

# ---------- palette ----------
NAVY   = RGBColor(0x0B, 0x2A, 0x4A)
ACCENT = RGBColor(0x1F, 0x6F, 0x8B)
GOLD   = RGBColor(0xB8, 0x86, 0x0B)
DARK   = RGBColor(0x22, 0x22, 0x22)
GREY   = RGBColor(0x5A, 0x5A, 0x5A)
WHITE  = RGBColor(0xFF, 0xFF, 0xFF)
BG     = RGBColor(0xFB, 0xFC, 0xFD)
BOX1   = RGBColor(0xE8, 0xF1, 0xF6)
BOX2   = RGBColor(0xDD, 0xEC, 0xE8)
BOX3   = RGBColor(0xF4, 0xE9, 0xD8)
BOX4   = RGBColor(0xEF, 0xE1, 0xEC)
BOX5   = RGBColor(0xE3, 0xE7, 0xF3)
ROWALT = RGBColor(0xF0, 0xF4, 0xF7)

def add_slide():
    s = prs.slides.add_slide(BLANK)
    s.background.fill.solid()
    s.background.fill.fore_color.rgb = BG
    return s

def txt(slide, left, top, width, height, text, size=16, color=DARK, bold=False,
        italic=False, align=PP_ALIGN.LEFT, font="Calibri", anchor=None, wrap=True):
    box = slide.shapes.add_textbox(Inches(left), Inches(top), Inches(width), Inches(height))
    tf = box.text_frame
    tf.word_wrap = wrap
    if anchor is not None:
        tf.vertical_anchor = anchor
    p = tf.paragraphs[0]
    p.text = text
    p.alignment = align
    p.font.size = Pt(size); p.font.bold = bold; p.font.italic = italic
    p.font.color.rgb = color; p.font.name = font
    return box

def header(slide, kicker, title, number):
    bar = slide.shapes.add_shape(MSO_SHAPE.RECTANGLE, 0, 0, SW, Inches(0.14))
    bar.fill.solid(); bar.fill.fore_color.rgb = ACCENT; bar.line.fill.background(); bar.shadow.inherit=False
    txt(slide, 0.55, 0.22, 8, 0.35, kicker.upper(), size=13, color=ACCENT, bold=True)
    txt(slide, 0.55, 0.52, 11.8, 0.65, title, size=27, color=NAVY, bold=True)
    ln = slide.shapes.add_shape(MSO_SHAPE.RECTANGLE, Inches(0.55), Inches(1.16), Inches(2.6), Pt(3))
    ln.fill.solid(); ln.fill.fore_color.rgb = GOLD; ln.line.fill.background(); ln.shadow.inherit=False
    txt(slide, 12.35, 0.22, 0.6, 0.35, str(number), size=13, color=GREY, align=PP_ALIGN.RIGHT)

def bullets(slide, items, left=0.65, top=1.4, width=12.0, height=5.55, size=17,
            title_color=NAVY, line_gap=6):
    box = slide.shapes.add_textbox(Inches(left), Inches(top), Inches(width), Inches(height))
    tf = box.text_frame; tf.word_wrap = True
    first = True
    for item in items:
        if isinstance(item, tuple):
            text, level = item[0], item[1]
            bold_head = item[2] if len(item) > 2 else None
        else:
            text, level, bold_head = item, 0, None
        p = tf.paragraphs[0] if first else tf.add_paragraph()
        first = False
        p.space_after = Pt(line_gap)
        p.level = 0
        marker = "●  " if level == 0 else ("–  " if level == 1 else "·  ")
        indent = 0.0 if level == 0 else (0.35 if level == 1 else 0.65)
        p.text = ""
        run = p.add_run(); run.text = " " * int(indent*4) + marker
        run.font.size = Pt(size); run.font.color.rgb = ACCENT if level == 0 else GREY
        run.font.bold = True
        run2 = p.add_run(); run2.text = text
        run2.font.size = Pt(size if level == 0 else size-1)
        run2.font.color.rgb = DARK
        run2.font.bold = bool(bold_head) if level == 0 and bold_head else False
    return box

def notes(slide, text):
    slide.notes_slide.notes_text_frame.text = text

def rounded_box(slide, left, top, width, height, text, fill=BOX1, tcolor=NAVY,
                 size=11, bold=True, line_color=None):
    shp = slide.shapes.add_shape(MSO_SHAPE.ROUNDED_RECTANGLE, Inches(left), Inches(top), Inches(width), Inches(height))
    shp.fill.solid(); shp.fill.fore_color.rgb = fill
    if line_color:
        shp.line.color.rgb = line_color; shp.line.width = Pt(1)
    else:
        shp.line.fill.background()
    shp.shadow.inherit = False
    tf = shp.text_frame; tf.word_wrap = True
    tf.margin_left = Pt(4); tf.margin_right = Pt(4); tf.margin_top = Pt(2); tf.margin_bottom = Pt(2)
    tf.vertical_anchor = MSO_ANCHOR.MIDDLE
    p = tf.paragraphs[0]; p.alignment = PP_ALIGN.CENTER
    p.text = text
    p.font.size = Pt(size); p.font.bold = bold; p.font.color.rgb = tcolor
    return shp

def arrow_label(slide, left, top, w=0.5, h=0.4, symbol="\u2192", color=ACCENT, size=20):
    txt(slide, left, top, w, h, symbol, size=size, color=color, bold=True, align=PP_ALIGN.CENTER)

def flow_row(slide, steps, top, left=0.55, total_width=12.2, box_h=0.85, size=11,
             colors=None, gap=0.42):
    n = len(steps)
    box_w = (total_width - gap*(n-1)) / n
    x = left
    for i, step in enumerate(steps):
        fill = colors[i % len(colors)] if colors else BOX1
        rounded_box(slide, x, top, box_w, box_h, step, fill=fill, size=size)
        if i < n-1:
            arrow_label(slide, x+box_w, top+box_h/2-0.22, gap, 0.4)
        x += box_w + gap
    return box_w

def table(slide, headers, rows, left=0.4, top=1.4, width=12.5, height=5.4,
          col_widths=None, header_size=13, body_size=11.5, header_fill=NAVY):
    n_rows = len(rows) + 1
    n_cols = len(headers)
    gshape = slide.shapes.add_table(n_rows, n_cols, Inches(left), Inches(top), Inches(width), Inches(height))
    tbl = gshape.table
    if col_widths:
        for i, w in enumerate(col_widths):
            tbl.columns[i].width = Inches(w)
    for j, htext in enumerate(headers):
        cell = tbl.cell(0, j)
        cell.text = htext
        cell.fill.solid(); cell.fill.fore_color.rgb = header_fill
        p = cell.text_frame.paragraphs[0]
        p.font.size = Pt(header_size); p.font.bold = True; p.font.color.rgb = WHITE
        p.alignment = PP_ALIGN.CENTER
        cell.vertical_anchor = MSO_ANCHOR.MIDDLE
    for i, row in enumerate(rows, start=1):
        for j, val in enumerate(row):
            cell = tbl.cell(i, j)
            cell.text = str(val)
            cell.fill.solid()
            cell.fill.fore_color.rgb = ROWALT if i % 2 == 0 else WHITE
            p = cell.text_frame.paragraphs[0]
            p.font.size = Pt(body_size); p.font.color.rgb = DARK
            p.alignment = PP_ALIGN.LEFT if j == 0 else PP_ALIGN.LEFT
            cell.vertical_anchor = MSO_ANCHOR.MIDDLE
            for para in cell.text_frame.paragraphs:
                para.font.size = Pt(body_size)
    return tbl

def footer(slide, text="Skin Immunology | Dermatology PGT-1 Seminar"):
    txt(slide, 0.55, 7.12, 9, 0.3, text, size=9, color=GREY)

# =====================================================================
# SLIDE 1 - TITLE
# =====================================================================
s = add_slide()
band = s.shapes.add_shape(MSO_SHAPE.RECTANGLE, 0, 0, SW, Inches(7.5))
band.fill.solid(); band.fill.fore_color.rgb = NAVY; band.line.fill.background(); band.shadow.inherit=False
band2 = s.shapes.add_shape(MSO_SHAPE.RECTANGLE, 0, Inches(4.6), SW, Inches(0.08))
band2.fill.solid(); band2.fill.fore_color.rgb = GOLD; band2.line.fill.background(); band2.shadow.inherit=False
txt(s, 1.0, 2.35, 11.3, 0.5, "DEPARTMENT OF DERMATOLOGY", size=18, color=RGBColor(0xB9,0xC9,0xDA), bold=True, align=PP_ALIGN.CENTER)
txt(s, 1.0, 2.85, 11.3, 1.3, "SKIN IMMUNOLOGY", size=54, color=WHITE, bold=True, align=PP_ALIGN.CENTER)
txt(s, 1.0, 3.95, 11.3, 0.5, "From Cutaneous Barrier to Clinical Dermatology", size=19, color=RGBColor(0xCF,0xDD,0xEA), italic=True, align=PP_ALIGN.CENTER)
txt(s, 1.0, 5.05, 11.3, 0.4, "Presenter: Dr. ______________  |  Dermatology PGT-1", size=17, color=WHITE, align=PP_ALIGN.CENTER)
txt(s, 1.0, 5.45, 11.3, 0.4, "Department of Dermatology, Venereology & Leprology", size=15, color=RGBColor(0xCF,0xDD,0xEA), align=PP_ALIGN.CENTER)
txt(s, 1.0, 5.8, 11.3, 0.4, "Institution: ______________________", size=15, color=RGBColor(0xCF,0xDD,0xEA), align=PP_ALIGN.CENTER)
txt(s, 1.0, 6.5, 11.3, 0.4, "Presented before HOD / Professors / Senior Residents / PG Trainees", size=13, color=GOLD, align=PP_ALIGN.CENTER, bold=True)
notes(s, "Good morning/afternoon Sir/Ma'am. Today I will present on Skin Immunology - the immunological "
          "framework that underlies almost every disease we see in dermatology OPD. My aim is to build a bridge "
          "from basic immunology to skin biology, to immunopathogenesis, and finally to clinical practice and "
          "current biologic therapeutics. I have used Bolognia's Dermatology and Rook's Textbook of Dermatology "
          "as the primary frameworks, supplemented by standard immunology texts and recent literature.")

# =====================================================================
# SLIDE 2
# =====================================================================
s = add_slide(); header(s, "Concept", "Why is Skin an Immune Organ?", 2)
bullets(s, [
    ("Physical barrier: stratum corneum + tight junctions + lipid lamellae limit pathogen entry", 0),
    ("Immunological barrier: keratinocytes, Langerhans cells, dermal DCs, T cells and mast cells are present at baseline, not only during disease", 0),
    ("Keratinocytes are active immune participants - they express PRRs, secrete cytokines/chemokines and AMPs (not just structural cells)", 0),
    ("Resident immune cell population: Langerhans cells, dermal dendritic cells, mast cells, macrophages, \u03b3\u03b4 T cells, TRM cells - the skin has more T cells than circulating blood (SALT - skin-associated lymphoid tissue)", 0),
    ("Both innate (immediate, non-specific) and adaptive (delayed, antigen-specific, memory-forming) arms operate together in skin", 0),
    ("Clinical importance: nearly every inflammatory, infective, autoimmune and neoplastic dermatosis has an immunological basis - understanding this drives rational diagnosis and targeted therapy", 0, True),
], size=16.5, height=4.35)
flow_row(s, ["BARRIER", "RECOGNITION\n(PRR-PAMP/DAMP)", "INNATE RESPONSE\n(AMPs, neutrophils, NK)", "ADAPTIVE RESPONSE\n(DC \u2192 T/B cells)", "RESOLUTION /\nMEMORY (TRM)"],
         top=5.95, colors=[BOX1,BOX2,BOX3,BOX4,BOX5], size=11, box_h=0.95)
footer(s)
notes(s, "Skin is the body's largest immune organ by surface area and cell number (SALT concept - "
      "skin-associated lymphoid tissue, Streilein). It performs three simultaneous jobs: physical exclusion, "
      "molecular sensing (PRRs sensing PAMPs/DAMPs), and generation of antigen-specific adaptive responses with "
      "durable memory (TRM cells). Keratinocytes are not bystanders - they are the first sensor and first "
      "responder. For a dermatologist this matters because psoriasis, atopic dermatitis, autoimmune bullous "
      "disease, drug reactions, leprosy and even acne are fundamentally immune-mediated processes playing out "
      "in this organ. Bolognia Ch. 'The Skin Immune System' frames this five-step conceptual flow: "
      "Barrier \u2192 Recognition \u2192 Innate response \u2192 Adaptive response \u2192 Resolution/Memory - which "
      "recurs throughout this talk.")

# =====================================================================
# SLIDE 3
# =====================================================================
s = add_slide(); header(s, "Framework", "Components of the Cutaneous Immune System", 3)
left_items = [
    ("1. Physical/chemical barrier - corneocytes, lipids, low pH, filaggrin", 0),
    ("2. Innate immune system - PRRs, complement, AMPs, neutrophils, NK cells", 0),
    ("3. Adaptive immune system - T cells, B cells, immunological memory (TRM)", 0),
    ("4. Resident immune cells - keratinocytes, LCs, dDCs, mast cells, macrophages", 0),
    ("5. Cytokines & chemokines - the signalling language between all cells", 0),
]
right_items = [
    ("6. Antimicrobial peptides - defensins, cathelicidin (LL-37), dermcidin", 0),
    ("7. Complement system - opsonisation, membrane attack, inflammation", 0),
    ("8. Neuroimmune interactions - sensory nerves, neuropeptides (SP, CGRP)", 0),
    ("9. Skin microbiome - commensals train and calibrate cutaneous immunity", 0),
]
bullets(s, left_items, left=0.65, top=1.45, width=6.0, height=4.0, size=15.5)
bullets(s, right_items, left=6.85, top=1.45, width=5.8, height=4.0, size=15.5)
txt(s, 0.65, 5.55, 11.7, 0.3, "High-yield concept: every dermatosis can be mapped onto a defect/exaggeration in one or more of these 9 components.", size=13.5, color=GOLD, bold=True, italic=True)
flow_row(s, ["Barrier", "Innate cells\n+ PRRs", "AMPs +\nComplement", "APCs\n(LC/dDC)", "T & B cells\n(adaptive)", "Cytokine\nnetwork"],
         top=6.0, colors=[BOX1,BOX2,BOX3,BOX4,BOX5,BOX1], size=10.5, box_h=0.9)
footer(s)
notes(s, "This is the master framework slide - Bolognia organizes cutaneous immunology under these nine "
      "pillars. Think of it as a checklist: barrier defects (filaggrin mutations) predispose to atopic "
      "dermatitis; AMP deficiency (LL-37) predisposes to infection but AMP excess drives psoriasis; microbiome "
      "dysbiosis (Staph aureus, Cutibacterium acnes, Malassezia) drives atopic dermatitis, acne and seborrhoeic "
      "dermatitis respectively. Neuroimmune crosstalk explains itch pathways (IL-31, substance P) which is why "
      "we now have neurokinin-1 antagonists in dermatology. Keeping this 9-point map in mind lets you answer "
      "almost any 'immunology of X disease' viva question systematically.")

# =====================================================================
# SLIDE 4
# =====================================================================
s = add_slide(); header(s, "Innate Barrier", "Epidermis as an Immune Barrier", 4)
bullets(s, [
    ("Keratinocytes are NOT passive structural cells - they are active immunological sentinels", 0, True),
    ("Physical layer: tight junctions (claudins) + stratum corneum + intercellular lipid lamellae (ceramides, cholesterol, free fatty acids) restrict pathogen and allergen penetration", 0),
    ("Filaggrin: aggregates keratin, maintains corneocyte integrity and skin pH; loss-of-function mutations \u2192 defective barrier \u2192 major genetic risk factor for atopic dermatitis and secondary allergic sensitisation", 0),
    ("Keratinocytes express pattern-recognition receptors (TLR1-6, 9; NOD1/2; inflammasome components) that sense microbial and danger signals", 0),
    ("On activation, keratinocytes secrete cytokines (IL-1\u03b1/\u03b2, TNF-\u03b1, TSLP, IL-33, IL-25 = epithelial \"alarmins\") and chemokines (CXCL9/10, CCL27) that recruit and instruct immune cells", 0),
    ("Keratinocytes produce antimicrobial peptides (\u03b2-defensins, LL-37) directly onto the skin surface", 0),
    ("Net concept: keratinocyte injury or barrier breach itself triggers an innate immune cascade, independent of true infection", 0, True),
], size=16, height=5.4)
footer(s)
notes(s, "This slide operationalises the exam favourite line: 'the keratinocyte is an immunocyte.' Barrier "
      "and immunity are inseparable in skin - a broken barrier (filaggrin mutation, mechanical trauma, soap "
      "surfactants) is itself a DAMP-generating event. TSLP, IL-33 and IL-25 are epithelial 'alarmins' released "
      "from stressed/damaged keratinocytes that directly activate dendritic cells, ILC2s and Th2 cells - central "
      "to the atopic march. This concept links directly to slide 16 (atopic dermatitis pathogenesis). Reference: "
      "Bolognia Dermatology, Section 1 'The Skin Immune System' and 'Structure and Function of the Skin.'")

# =====================================================================
# SLIDE 5
# =====================================================================
s = add_slide(); header(s, "Innate Arm", "Innate Immunity of Skin", 5)
bullets(s, [
    ("Pattern recognition receptors (PRRs) on keratinocytes, LCs, macrophages recognise PAMPs (microbial) and DAMPs (self, danger)", 0),
    ("Toll-like receptors (TLR2/6 - bacterial lipopeptides; TLR3 - viral dsRNA; TLR4 - LPS; TLR9 - CpG DNA/self-DNA complexes)", 0),
    ("NOD-like receptors and the inflammasome (NLRP3) \u2192 caspase-1 activation \u2192 cleave pro-IL-1\u03b2/pro-IL-18 to active forms", 0),
    ("Complement system - alternative pathway activation, opsonisation, C5a-driven chemotaxis (relevant in urticarial vasculitis, bullous disease)", 0),
    ("Effector cells: neutrophils (pustular psoriasis, Sweet syndrome), macrophages (granulomatous disease, leprosy), NK cells (viral surveillance, some drug reactions)", 0),
    ("Clinical hooks: NLRP3 mutations \u2192 cryopyrin-associated periodic syndromes (urticarial rash); TLR9-LL-37-DNA complexes \u2192 plasmacytoid DC activation in psoriasis", 0, True),
], size=15.5, height=4.1)
flow_row(s, ["Recognition\n(PRR binds PAMP/DAMP)", "Signalling\n(NF-\u03baB, inflammasome)", "Cytokine release\n(IL-1, TNF, type I IFN)", "Cell recruitment\n(neutrophils, monocytes)", "Pathogen\nelimination"],
         top=5.75, colors=[BOX1,BOX2,BOX3,BOX4,BOX5], size=10.5, box_h=0.95)
footer(s)
notes(s, "Frame this as a five-step logical sequence that faculty love to hear stated explicitly: Recognition "
      "\u2192 Signalling \u2192 Cytokine release \u2192 Recruitment \u2192 Elimination. Emphasise that innate immunity is "
      "fast (minutes-hours) and non-specific, buying time for adaptive immunity to develop. Clinically: TLR2 "
      "recognises Propionibacterium/Cutibacterium acnes and Mycobacterium leprae lipoproteins; NLRP3 "
      "inflammasome activation by UV, ATP and cholesterol crystals is implicated in photoaging and some "
      "autoinflammatory dermatoses. Reference: Bolognia, 'Innate Immunity'; Rook's, Ch. on cutaneous immunology.")

# =====================================================================
# SLIDE 6 - AMP TABLE
# =====================================================================
s = add_slide(); header(s, "Innate Effectors", "Antimicrobial Peptides (AMPs)", 6)
table(s, ["AMP", "Source", "Key Trigger", "Major Function", "Clinical Relevance"],
      [
        ["\u03b2-Defensins (hBD2, hBD3)", "Keratinocytes", "TLR activation, IL-17/IL-22, injury", "Broad antimicrobial; chemotactic for immune cells", "\u2191 in psoriasis (thick, less-infected plaques); \u2193 relative response in AD"],
        ["Cathelicidin (LL-37)", "Keratinocytes, neutrophils", "Vitamin D pathway, injury, TLR9", "Antimicrobial; forms complexes with self-DNA/RNA", "Activates pDCs via TLR9 \u2192 IFN-\u03b1 \u2192 drives psoriasis; \u2193 in AD (\u2191 infection risk); \u2191 in rosacea (vascular/inflammatory effects)"],
        ["Dermcidin", "Eccrine sweat glands", "Constitutive secretion in sweat", "Antimicrobial independent of injury/inflammation", "Reduced in atopic dermatitis sweat, contributing to S. aureus colonisation"],
        ["RNase 7", "Keratinocytes", "Cytokines, microbial contact", "Broad-spectrum antimicrobial (esp. antiviral)", "Contributes to baseline skin sterility despite constant exposure"],
      ],
      col_widths=[2.3,1.7,2.3,3.0,3.2], header_size=13, body_size=11.2)
txt(s, 0.4, 6.35, 12.5, 0.55, "Key clinical thread - LL-37: self-DNA/LL-37 complexes trigger TLR9 on plasmacytoid dendritic cells \u2192 type I interferon \u2192 myeloid DC activation \u2192 Th17 priming = an initiating event in psoriasis pathogenesis.", size=12.5, color=GOLD, bold=True, italic=True)
footer(s)
notes(s, "AMPs illustrate a unifying dermatology teaching point: too little AMP activity predisposes to "
      "infection (atopic dermatitis - low LL-37/defensins, recurrent S. aureus and eczema herpeticum), while "
      "too much/inappropriately activated AMP activity drives autoinflammation (psoriasis - LL-37-DNA complexes "
      "trigger TLR9 on plasmacytoid dendritic cells, an early event upstream of the IL-23/Th17 axis; Lande et al., "
      "Nature 2007, is the key paper). Rosacea shows abnormal cathelicidin processing (elevated serine protease "
      "activity/kallikrein-5) producing pro-inflammatory LL-37 fragments. Acne involves innate activation by "
      "C. acnes via TLR2. Mention this LL-37-psoriasis link explicitly - it is a favourite viva question.")

# =====================================================================
# SLIDE 7
# =====================================================================
s = add_slide(); header(s, "Antigen Presentation", "Dendritic Cells and Antigen Presentation", 7)
bullets(s, [
    ("Langerhans cells (LC): reside in the epidermis (suprabasal), extend dendrites between keratinocytes via tight-junction proteins to sample antigen without breaching the barrier", 0),
    ("Dermal dendritic cells (dDC): reside in the dermis; subsets include CD1a+ dDCs and CD14+ dDCs with distinct T-cell polarising abilities", 0),
    ("Both capture antigen \u2192 process it \u2192 load peptides onto MHC II (exogenous antigen, for CD4+ T cells) or cross-present on MHC I (for CD8+ T cells)", 0),
    ("On activation, DCs upregulate CCR7, migrate via afferent lymphatics to draining lymph nodes", 0),
    ("In the lymph node, DCs present antigen to naive T cells with co-stimulation (CD80/86-CD28) \u2192 T-cell priming and polarisation", 0),
], size=16, height=3.6)
flow_row(s, ["Antigen\ncapture (skin)", "Processing +\nMHC loading", "Maturation\n(CCR7 up)", "Migration to\nlymph node", "Presentation to\nnaive T cell", "T-cell priming\n& polarisation"],
         top=5.1, colors=[BOX1,BOX2,BOX3,BOX4,BOX5,BOX1], size=10, box_h=0.95)
txt(s, 0.65, 6.25, 11.9, 0.9, "Clinical correlation: Langerhans cells are the key sensitising APC in allergic contact dermatitis "
    "(hapten capture \u2192 lymph node priming) and central to cutaneous immune surveillance against early cutaneous malignancy/infection.", size=13.5, color=GOLD, italic=True, bold=True)
footer(s)
notes(s, "Distinguish LC (epidermal, Langerin/CD207+, self-renewing from embryonic precursors, radio-resistant) "
      "from dermal DCs (dermis, more heterogeneous, replenished from blood monocytes/precursors). Functionally, "
      "LCs were classically considered pro-inflammatory sensitisers in contact dermatitis, but current data shows "
      "they can also promote tolerance in some contexts - a nuance faculty may probe. dDCs are important sources "
      "of IL-23/IL-12 driving Th17/Th1 responses in psoriasis. The antigen capture \u2192 migration \u2192 presentation "
      "\u2192 priming sequence is the bridge from innate sensing to adaptive, antigen-specific immunity. Reference: "
      "Bolognia 'The Skin Immune System', Rook's Ch. on Langerhans cells and dendritic cells.")

# =====================================================================
# SLIDE 8
# =====================================================================
s = add_slide(); header(s, "Adaptive Arm", "T Cells in Skin", 8)
bullets(s, [
    ("T-cell subsets present in skin: CD4+ helper, CD8+ cytotoxic, regulatory T cells (Treg), and tissue-resident memory T cells (TRM)", 0),
    ("Skin homing: naive T cells primed in lymph node acquire cutaneous lymphocyte-associated antigen (CLA) + chemokine receptors (CCR4, CCR10) \u2192 bind E-selectin/CCL17/CCL27 on dermal venules \u2192 enter skin", 0),
    ("TRM cells remain in skin long-term without recirculating \u2192 rapid local recall response \u2192 explain fixed-site recurrence (e.g., fixed drug eruption, herpes recurrence, psoriasis plaque recurrence at same site)", 0, True),
], size=15.5, height=2.1, top=1.35)
table(s, ["Subset","Signature cytokine(s)","Main function","Key dermatoses"],
      [
        ["Th1","IFN-\u03b3, TNF-\u03b1","Macrophage activation, intracellular pathogen clearance","Tuberculoid leprosy, lichen planus, vitiligo"],
        ["Th2","IL-4, IL-5, IL-13","B-cell/IgE help, eosinophil recruitment","Atopic dermatitis, allergic disease"],
        ["Th17","IL-17A/F, IL-22","Neutrophil recruitment, AMP induction","Psoriasis, psoriatic arthritis"],
        ["Th22","IL-22","Keratinocyte proliferation, barrier genes","Psoriasis (co-driver), AD (co-driver)"],
        ["Treg","IL-10, TGF-\u03b2 (FOXP3+)","Peripheral tolerance, suppression","Loss \u2192 autoimmunity; deficient in AD/psoriasis lesions"],
        ["CD8+ CTL","IFN-\u03b3, perforin, granzyme","Cytotoxicity vs. infected/self keratinocytes","Lichen planus, vitiligo, GVHD, SJS/TEN, lepromatous reactions"],
      ], top=3.6, height=3.35, col_widths=[1.3,2.6,3.7,4.6], header_size=13, body_size=11)
footer(s)
notes(s, "CLA (cutaneous lymphocyte-associated antigen) is a carbohydrate modification of PSGL-1 that binds "
      "E-selectin on inflamed dermal endothelium - this is the classic viva definition. TRM cells (CD69+, CD103+) "
      "are the mechanistic explanation for why psoriasis and fixed drug eruptions recur at exactly the same skin "
      "site after apparent clearance - a genuinely high-yield modern concept (Clark lab data). The Th-subset table "
      "is the single most examined table in cutaneous immunology - be fluent in cytokine \u2192 disease mapping in "
      "both directions. SJS/TEN is CD8+ cytotoxic T-cell/NK mediated via granulysin and Fas-FasL.")

# =====================================================================
# SLIDE 9 - Th polarization
# =====================================================================
s = add_slide(); header(s, "Adaptive Arm", "T-Helper Cell Polarisation", 9)
rounded_box(s, 5.1, 1.5, 3.1, 0.7, "NAIVE CD4+ T CELL", fill=NAVY, tcolor=WHITE, size=15)
for i,(x) in enumerate([0.5,2.9,5.3,7.7,10.1]):
    arrow_label(s, x+1.0, 2.25, 0.35, 0.35, "\u2193", size=16)
cols = [
    ("Th1", "IL-12, IFN-\u03b3", "T-bet", "IFN-\u03b3, TNF-\u03b1", "Vitiligo, tuberculoid leprosy, lichen planus", BOX1),
    ("Th2", "IL-4", "GATA-3", "IL-4, IL-5, IL-13", "Atopic dermatitis, allergic conditions", BOX2),
    ("Th17", "IL-6, IL-23, TGF-\u03b2", "ROR\u03b3t", "IL-17A/F, IL-22", "Psoriasis, psoriatic arthritis", BOX3),
    ("Th22", "IL-6, TNF-\u03b1", "AHR", "IL-22", "Psoriasis (co-driver), AD (co-driver)", BOX4),
    ("Treg", "TGF-\u03b2, IL-2", "FOXP3", "IL-10, TGF-\u03b2", "Deficiency \u2192 autoimmunity/atopy", BOX5),
]
x = 0.5
w = 2.4
for name, diffcyto, tf_, sigcyto, disease, color in cols:
    rounded_box(s, x, 2.65, w, 0.55, name, fill=color, tcolor=NAVY, size=15)
    txt(s, x, 3.25, w, 1.7,
        "Induced by: " + diffcyto + "\n\nTF: " + tf_ + "\n\nSecretes: " + sigcyto,
        size=10.5, color=DARK)
    b = s.shapes.add_shape(MSO_SHAPE.ROUNDED_RECTANGLE, Inches(x), Inches(5.15), Inches(w), Inches(1.55))
    b.fill.solid(); b.fill.fore_color.rgb = WHITE; b.line.color.rgb = color; b.line.width = Pt(1.25); b.shadow.inherit=False
    tf2 = b.text_frame; tf2.word_wrap = True; tf2.vertical_anchor = MSO_ANCHOR.MIDDLE
    tf2.margin_left=Pt(4); tf2.margin_right=Pt(4)
    p = tf2.paragraphs[0]; p.alignment = PP_ALIGN.CENTER
    p.text = disease; p.font.size = Pt(10.5); p.font.bold = True; p.font.color.rgb = NAVY
    x += w + 0.13
footer(s)
notes(s, "This is the master differentiation slide - be able to draw it from memory. Naive CD4+ T cells "
      "polarise depending on the local cytokine milieu set up by innate cells/keratinocytes: IL-12 \u2192 Th1 "
      "(T-bet); IL-4 \u2192 Th2 (GATA-3); IL-6+IL-23+TGF-\u03b2 \u2192 Th17 (ROR\u03b3t), maintained/expanded by IL-23; "
      "AHR-driven signals \u2192 Th22; TGF-\u03b2+IL-2 (without inflammatory cytokines) \u2192 Treg (FOXP3). "
      "IL-23 does not initiate Th17 differentiation but is essential for Th17 survival, expansion and "
      "pathogenic function - this nuance is commonly tested. Each axis maps to a therapeutic target discussed "
      "in slide 18 (e.g., anti-IL-23, anti-IL-17, anti-IL-4R\u03b1, JAK inhibitors affecting multiple axes downstream).")

# =====================================================================
# SLIDE 10 - Cytokine table
# =====================================================================
s = add_slide(); header(s, "Signalling", "Cytokines and Chemokines in Dermatology", 10)
table(s, ["Cytokine","Source","Major Action","Dermatological Relevance","Targeted Therapy"],
      [
        ["TNF-\u03b1","Macrophages, DCs, T cells","Pro-inflammatory, endothelial activation","Psoriasis, HS, pyoderma gangrenosum","Adalimumab, infliximab, etanercept"],
        ["IL-23","Dermal DCs, macrophages","Maintains/expands Th17","Psoriasis, PsA","Ustekinumab (p40), guselkumab/risankizumab (p19)"],
        ["IL-17A/F","Th17, \u03b3\u03b4T, ILC3","Neutrophil recruitment, keratinocyte activation","Psoriasis","Secukinumab, ixekizumab, bimekizumab"],
        ["IL-4 / IL-13","Th2, ILC2, mast cells","IgE class switching, barrier suppression","Atopic dermatitis, allergy","Dupilumab (IL-4R\u03b1), tralokinumab (IL-13)"],
        ["IL-31","Th2 cells","Direct pruritogen via sensory neurons","Atopic dermatitis, prurigo nodularis","Nemolizumab"],
        ["IL-5","Th2 cells","Eosinophil maturation/survival","Eosinophilic dermatoses","Mepolizumab"],
        ["IL-1/IL-1\u03b2","Keratinocytes, macrophages","Inflammasome output, fever, acute inflammation","Acne, autoinflammatory syndromes","Anakinra, canakinumab"],
        ["IFN-\u03b3","Th1, CD8+, NK cells","Macrophage activation","Vitiligo, lichen planus, GVHD","JAK1/2 inhibitors (indirect)"],
        ["TGF-\u03b2","Treg, keratinocytes","Immunosuppression, fibrosis","Scleroderma/fibrosis, wound healing","-"],
      ], top=1.4, height=5.55, col_widths=[1.5,2.1,3.1,3.0,2.8], header_size=12.5, body_size=10.3)
footer(s)
notes(s, "This slide is the conceptual pivot of the entire talk: cytokines are the shared language linking "
      "immunopathogenesis to modern targeted therapeutics. Group cytokines into functional families: TNF-\u03b1 "
      "(broad pro-inflammatory, oldest biologic target), IL-23/IL-17 axis (psoriasis), IL-4/IL-13/IL-31 (Th2/atopic "
      "axis), IL-1 family (innate/autoinflammatory), IFN-\u03b3 (Th1/cytotoxic diseases). When asked 'why does drug X "
      "work in disease Y', trace back through this table to the pathway. Note IL-23 inhibitors spare IL-12 (only "
      "block p19), reducing effects on Th1/anti-mycobacterial immunity compared with older anti-p40 agents like "
      "ustekinumab.")

# =====================================================================
# SLIDE 11 - cell network
# =====================================================================
s = add_slide(); header(s, "Integration", "Skin Immune Cell Network", 11)
center = rounded_box(s, 5.35, 3.35, 2.6, 0.9, "KERATINOCYTE\n(central hub)", fill=NAVY, tcolor=WHITE, size=13)
outer = [
    ("Langerhans cell\n(antigen capture)", 0.55, 1.4, BOX1),
    ("Dermal DC\n(IL-23/IL-12 source)", 5.35, 1.4, BOX2),
    ("Mast cell\n(histamine, IL-31 axis)", 10.1, 1.4, BOX3),
    ("Macrophage\n(phagocytosis, granuloma)", 0.55, 5.6, BOX4),
    ("T cell (Th1/2/17/22/Treg,\nTRM, CD8+)", 5.35, 5.6, BOX5),
    ("B cell / Plasma cell\n(antibody production)", 10.1, 5.6, BOX1),
]
for text, x, y, color in outer:
    rounded_box(s, x, y, 2.7, 0.9, text, fill=color, size=11.5)
# connecting lines
from pptx.enum.shapes import MSO_CONNECTOR
def connect(x1,y1,x2,y2):
    conn = s.shapes.add_connector(MSO_CONNECTOR.STRAIGHT, Inches(x1), Inches(y1), Inches(x2), Inches(y2))
    conn.line.color.rgb = ACCENT; conn.line.width = Pt(1.25)
connect(1.9,2.3,6.0,3.5); connect(6.6,2.3,6.6,3.35); connect(11.45,2.3,7.2,3.6)
connect(1.9,5.6,6.0,4.3); connect(6.7,5.6,6.7,4.25); connect(11.45,5.6,7.4,4.1)
txt(s, 0.55, 6.75, 11.9, 0.5, "Keratinocytes both respond to and instruct every resident immune cell - true bidirectional cross-talk, not a one-way cascade.", size=13, color=GOLD, bold=True, italic=True)
notes(s, "Use this slide to narrate cross-talk rather than reading it: keratinocytes release alarmins/AMPs that "
      "activate LCs, dDCs, mast cells and macrophages; dDCs produce IL-23/IL-12 to polarise T cells; T cells "
      "release IL-17/IL-22/IFN-\u03b3/IL-4 that act back on keratinocytes, closing the loop and amplifying disease "
      "(e.g., the psoriasis 'vicious cycle' between keratinocytes and Th17 cells). Mast cells bridge innate and "
      "adaptive responses in urticaria/atopic disease. B cells/plasma cells contribute antibody-mediated disease "
      "(pemphigus, bullous pemphigoid) discussed in slide 13. This integrated view is what faculty expect you to "
      "reproduce verbally, even without the diagram.")

# =====================================================================
# SLIDE 12 - trafficking
# =====================================================================
s = add_slide(); header(s, "Trafficking", "Cutaneous Immune Surveillance and Trafficking", 12)
bullets(s, [
    ("Skin-homing memory T cells express cutaneous lymphocyte-associated antigen (CLA), a carbohydrate ligand for E-selectin", 0),
    ("Chemokine receptor-ligand pairs direct organ-specific homing: CCR4-CCL17(TARC), CCR10-CCL27(CTACK) for skin homing; CXCR3-CXCL9/10/11 for Th1/CD8 recruitment into inflamed skin", 0),
    ("Sequence of extravasation: selectin-mediated rolling \u2192 chemokine-triggered integrin activation \u2192 firm adhesion (LFA-1/ICAM-1) \u2192 diapedesis \u2192 chemotactic migration into dermis/epidermis", 0),
], size=15.5, top=1.35, height=2.4)
flow_row(s, ["Rolling\n(selectins, CLA)", "Activation\n(chemokines)", "Firm adhesion\n(LFA-1-ICAM-1)", "Diapedesis\n(transmigration)", "Chemotaxis /\ntissue localisation"],
         top=3.9, colors=[BOX1,BOX2,BOX3,BOX4,BOX5], size=11, box_h=0.95)
txt(s, 0.65, 5.15, 11.9, 1.6,
    "Clinical connections: elevated serum CCL17/TARC correlates with atopic dermatitis severity; CXCL9/10 (IFN-\u03b3 "
    "induced) recruit cytotoxic lymphocytes in vitiligo and lichen planus; alefacept (historic) and efalizumab "
    "targeted LFA-1/CD2 adhesion pathways in psoriasis. Understanding this cascade explains why blocking a single "
    "adhesion/chemokine step can abort an entire inflammatory dermatosis.", size=14, color=DARK)
footer(s)
notes(s, "This is the mechanistic explanation for how circulating, antigen-primed T cells find their way "
      "specifically back to skin rather than gut or lung - the organ-specific homing concept (Butcher's "
      "'multistep paradigm', adapted to skin by Michael Girardi/Clark). Emphasise CLA and CCR4-CCL17 as the two "
      "highest yield molecules. CXCL9/10-CXCR3 is particularly important in interferon-driven diseases (vitiligo, "
      "lichen planus, dermatomyositis) and is now a JAK-inhibitor-relevant pathway since JAK1/2 inhibition blocks "
      "IFN-\u03b3-CXCL9/10 signalling - explaining efficacy of ruxolitinib/tofacitinib in vitiligo repigmentation.")

# =====================================================================
# SLIDE 13
# =====================================================================
s = add_slide(); header(s, "Adaptive Arm", "Humoral Immunity: B Cells and Antibodies", 13)
bullets(s, [
    ("B cells recognise antigen via BCR, receive T-cell help (Th2/Tfh), undergo class switching \u2192 differentiate into antibody-secreting plasma cells", 0),
    ("Immunoglobulin classes in skin disease: IgG (pemphigus, bullous pemphigoid, lupus), IgA (dermatitis herpetiformis, linear IgA disease), IgE (atopic disease, urticaria), IgM (early/acute immune complex disease)", 0),
    ("Autoantibodies directly cause disease by binding structural skin proteins \u2192 loss of cell adhesion or complement/Fc-receptor-mediated tissue injury", 0, True),
], size=16, top=1.35, height=2.3)
table(s, ["Disease","Target Antigen","Antibody","Mechanism of Damage"],
      [
        ["Pemphigus vulgaris/foliaceus","Desmoglein 3 / Desmoglein 1","IgG4/IgG1","Steric hindrance + signalling \u2192 loss of keratinocyte adhesion (acantholysis)"],
        ["Bullous pemphigoid","BP180 (COL17A1), BP230","IgG (+ IgE)","Complement activation, Fc-receptor-mediated neutrophil/eosinophil recruitment at BMZ"],
        ["Dermatitis herpetiformis","Epidermal transglutaminase","IgA","Granular IgA deposits at dermal papillae, neutrophil recruitment"],
        ["Chronic spontaneous urticaria","IgE receptor (FcεRI) / IgE itself","IgG (autoimmune subtype)","Mast cell activation via autoantibody or IgE cross-linking"],
      ], top=3.9, height=2.9, col_widths=[3.0,2.9,2.0,4.6], header_size=12.5, body_size=10.8)
footer(s)
notes(s, "Key teaching point for viva: pemphigus antibodies bind desmosomal cadherins directly disrupting "
      "cell-cell adhesion (largely complement-independent, direct steric/signalling effect - p38 MAPK pathway), "
      "producing intraepidermal blisters; bullous pemphigoid antibodies bind hemidesmosomal BP180/BP230 at the "
      "basement membrane zone and act mainly via complement activation and Fc-receptor-mediated inflammatory "
      "cell recruitment, producing subepidermal blisters. This mechanistic difference explains why pemphigus "
      "blisters are flaccid/intraepidermal (Nikolsky positive) while BP blisters are tense/subepidermal. "
      "Reference: Bolognia, Chapters on Pemphigus and Pemphigoid.")

# =====================================================================
# SLIDE 14 - tolerance
# =====================================================================
s = add_slide(); header(s, "Autoimmunity", "Immunological Tolerance and Autoimmunity", 14)
bullets(s, [
    ("Central tolerance: autoreactive T/B cell clones deleted or edited during development (thymus/bone marrow)", 0),
    ("Peripheral tolerance: anergy (signal 1 without co-stimulation), Treg-mediated suppression, immune checkpoints (CTLA-4, PD-1/PD-L1), and regulated apoptosis of autoreactive cells", 0),
    ("Breakdown mechanisms: molecular mimicry, epitope spreading, defective Treg number/function, checkpoint dysregulation (e.g., checkpoint-inhibitor drugs unmasking autoimmunity), aberrant antigen exposure after tissue damage", 0),
], size=15.5, top=1.35, height=2.5)
flow_row(s, ["Normal tolerance\n(central + peripheral)", "Breakdown\n(Treg loss, mimicry,\ncheckpoint failure)", "Autoreactive T/B\ncell activation", "Autoantibody /\nautoreactive T-cell", "Tissue damage\n(clinical disease)"],
         top=4.0, colors=[BOX5,BOX3,BOX2,BOX1,BOX4], size=10.5, box_h=1.0)
txt(s, 0.65, 5.35, 11.9, 1.4,
    "Dermatological examples: Pemphigus vulgaris (anti-desmoglein 3), Bullous pemphigoid (anti-BP180), Cutaneous "
    "lupus (anti-Ro/La, immune complex + interferon-driven), Dermatomyositis (anti-Mi-2/MDA5/TIF1-\u03b3, type I "
    "IFN signature), Vitiligo (CD8+ cytotoxic T cells destroy melanocytes, loss of Treg control).", size=14, color=DARK)
footer(s)
notes(s, "Anchor concept: autoimmunity = loss of self-tolerance with subsequent tissue-specific damage. Bring in "
      "checkpoint inhibitor-induced dermatological adverse events (vitiligo-like depigmentation, lichenoid "
      "eruptions, bullous pemphigoid) as a topical, high-yield modern example connecting immune checkpoints to "
      "real clinical practice - a favourite current-affairs question. Vitiligo is increasingly viewed as an "
      "autoimmune/autoinflammatory disease with CD8+ T cells producing IFN-\u03b3 that signals through keratinocyte "
      "CXCR3 ligands, recruiting more CTLs - hence JAK inhibitor efficacy.")

# =====================================================================
# SLIDE 15 - hypersensitivity
# =====================================================================
s = add_slide(); header(s, "Classification", "Hypersensitivity Reactions in Dermatology", 15)
table(s, ["Type","Mechanism","Key Mediators","Dermatological Examples"],
      [
        ["I","IgE-mediated mast cell degranulation","Histamine, tryptase, leukotrienes","Urticaria, angioedema, atopic dermatitis flares, anaphylaxis"],
        ["II","Antibody directed against cell/tissue antigen","IgG/IgM + complement","Pemphigus, bullous pemphigoid, some drug-induced cytopenias"],
        ["III","Immune complex deposition","Complement, immune complexes","Cutaneous small-vessel vasculitis, serum sickness, urticarial vasculitis"],
        ["IV","T-cell mediated (delayed-type)","T cells (see subtypes below)","Allergic contact dermatitis, morbilliform drug eruption, TB/leprosy reactions, SJS/TEN"],
      ], top=1.4, height=2.9, col_widths=[0.9,3.4,2.9,5.3], header_size=13, body_size=11.5)
table(s, ["Type IV subtype","Cells / Cytokines","Clinical example"],
      [
        ["IVa","Th1, IFN-\u03b3, macrophage activation","Tuberculin reaction, allergic contact dermatitis (early)"],
        ["IVb","Th2, IL-4/5/13, eosinophils","Maculopapular drug eruption with eosinophilia (DRESS-spectrum)"],
        ["IVc","Cytotoxic CD8+ T cells, perforin/granzyme, FasL","SJS/TEN, fixed drug eruption, lichenoid drug eruption"],
        ["IVd","T cells, IL-8/CXCL8, neutrophils","Acute generalised exanthematous pustulosis (AGEP)"],
      ], top=4.65, height=2.4, col_widths=[1.6,4.6,6.3], header_size=12.5, body_size=11)
footer(s)
notes(s, "Gell and Coombs classification remains a core viva topic. Be fluent reciting all four types with a "
      "dermatological example for each, then subdivide Type IV (Pichler's classification) with a severe cutaneous "
      "adverse reaction (SCAR) example for each subtype - IVa granulomatous/contact, IVb eosinophilic (DRESS-like), "
      "IVc cytotoxic (SJS/TEN, fixed drug eruption), IVd neutrophilic (AGEP). This framework directly explains "
      "the drug reaction spectrum, a frequently tested clinical topic. Reference: Bolognia Ch. on Cutaneous Drug "
      "Reactions; Rook's Ch. on Adverse Cutaneous Drug Reactions.")

# =====================================================================
# SLIDE 16 - disease pathogenesis diagrams
# =====================================================================
s = add_slide(); header(s, "Synthesis", "Immunopathogenesis of Major Inflammatory Dermatoses", 16)
rows = [
    ("Psoriasis", ["Trigger/injury\n(Koebner, strep)", "Keratinocyte\nDAMPs + LL-37", "Dermal DC:\nIL-23/IL-12", "Th17/Th22\nIL-17, IL-22", "Keratinocyte\nhyperproliferation"], 1.5),
    ("Atopic dermatitis", ["Barrier defect\n(filaggrin)", "Alarmins\nTSLP, IL-33, IL-25", "DC/ILC2\nactivation", "Th2\nIL-4, IL-13, IL-31", "Pruritus + further\nbarrier breakdown"], 2.55),
    ("Allergic contact dermatitis", ["Hapten penetrates\nbarrier", "LC/dDC uptake\n+ migration", "Sensitisation:\nT-cell priming (LN)", "Re-exposure:\nelicitation", "Th1/CD8+ mediated\neczematous reaction"], 3.6),
    ("Urticaria", ["Trigger (allergen,\nautoantibody, physical)", "Mast cell/basophil\nactivation", "Histamine,\nleukotrienes, PAF", "Vasodilation +\nvascular leak", "Wheal & flare,\nangioedema"], 4.65),
    ("Acne", ["C. acnes +\nsebum/comedone", "TLR2 activation\n(keratinocyte/monocyte)", "IL-1\u03b2, inflammasome", "Neutrophil\nrecruitment", "Inflammatory\npapule/pustule"], 5.7),
]
for name, steps, top in rows:
    txt(s, 0.4, top, 1.55, 0.85, name, size=12.5, color=NAVY, bold=True)
    flow_row(s, steps, top=top, left=2.05, total_width=10.75, box_h=0.85, size=9.3, colors=[BOX1,BOX2,BOX3,BOX4,BOX5], gap=0.25)
footer(s)
notes(s, "Use this slide as a rapid visual recap connecting mechanism directly to five classic dermatoses. "
      "Psoriasis: LL-37-DNA/keratin17 self-antigens \u2192 dermal DC IL-23 \u2192 Th17/Th22 \u2192 IL-17/IL-22 act on "
      "keratinocyte IL-17RA/IL-22R1 \u2192 hyperproliferation, parakeratosis, Munro microabscesses. Atopic "
      "dermatitis: barrier defect \u2192 alarmins \u2192 Th2 skewing \u2192 IL-4/13 further suppress barrier genes "
      "(filaggrin, loricrin) - a self-amplifying loop, plus IL-31 driving itch. Allergic contact dermatitis: "
      "classic Type IV hypersensitivity with sensitisation and elicitation phases. Urticaria: mast-cell centred, "
      "IgE or non-IgE (autoimmune anti-FcεRI, physical, complement-mediated). Acne: innate-immune driven "
      "inflammatory disease, not purely a follicular/bacterial problem - explains why anti-inflammatory therapy "
      "(not just antibacterial) matters.")

# =====================================================================
# SLIDE 17 - leprosy
# =====================================================================
s = add_slide(); header(s, "Infection Immunology", "Immunology of Infection and the Leprosy Spectrum", 17)
bullets(s, [
    ("Host-pathogen interaction determines clinical phenotype far more than organism virulence alone - leprosy is the classic dermatological teaching model", 0, True),
    ("Innate recognition of M. leprae lipoproteins via TLR2/1; downstream cell-mediated (Th1) vs. humoral/Th2-skewed response determines disease pole", 0),
], size=15.5, top=1.35, height=1.5)
flow_row(s, ["TT\nTuberculoid", "BT", "BB\nMid-borderline", "BL", "LL\nLepromatous"], top=3.0,
         colors=[BOX1,BOX2,BOX3,BOX4,BOX5], size=13, box_h=0.75)
table(s, ["Feature","TT pole","LL pole"],
      [
        ["Immune response","Strong Th1/CMI, IFN-\u03b3, TNF-\u03b1","Weak CMI, Th2-skewed, T-cell anergy to M. leprae"],
        ["Bacillary load","Paucibacillary (few/absent bacilli)","Multibacillary (numerous bacilli, high antibody titres)"],
        ["Histology","Well-formed epithelioid granulomas, few lymphocytes at margin","Diffuse macrophage (foamy/Virchow cell) infiltrate, no granuloma"],
        ["Clinical lesions","Few, well-defined, hypoaesthetic plaques","Numerous, symmetric, poorly-defined nodules/infiltration"],
      ], top=4.0, height=2.35, col_widths=[2.3,5.0,5.2], header_size=12.5, body_size=11)
txt(s, 0.55, 6.55, 12.2, 0.75,
    "Immunological reactions: Type 1 (reversal) reaction - shift toward Th1/TT pole, delayed hypersensitivity flare in borderline disease; "
    "Type 2 reaction (ENL) - immune-complex (Type III-like) mediated, seen in BL/LL with high antigen load.", size=12.5, color=GOLD, bold=True, italic=True)
footer(s)
notes(s, "Leprosy is the single best clinical model of a Th1-Th2 immunological spectrum disease and is almost "
      "guaranteed to be asked in a dermatology viva. The Ridley-Jopling classification maps directly onto host "
      "immune polarity: strong cell-mediated (Th1/IFN-\u03b3) immunity contains the organism at the tuberculoid pole "
      "with granuloma formation and low bacillary index; weak CMI with T-cell anergy and a Th2-skewed/humoral "
      "response allows uncontrolled bacillary multiplication at the lepromatous pole. Type 1 (reversal) reactions "
      "reflect abrupt improvement in cell-mediated immunity (a delayed hypersensitivity-like flare) and occur in "
      "borderline patients, sometimes precipitated by treatment. Type 2 reactions (erythema nodosum leprosum) are "
      "immune-complex/Th2-cytokine driven (TNF-\u03b1 surge), occurring in BL/LL disease with high antigen load. "
      "Reference: Bolognia Ch. on Leprosy; Rook's Ch. on Leprosy; IJDVL reviews.")

# =====================================================================
# SLIDE 18 - therapeutics table
# =====================================================================
s = add_slide(); header(s, "Translational Immunology", "Immunology and Modern Dermatological Therapeutics", 18)
table(s, ["Pathway","Drug Class","Example(s)","Disease(s)"],
      [
        ["TNF-\u03b1","TNF inhibitor","Adalimumab, infliximab, etanercept","Psoriasis, PsA, HS, pyoderma gangrenosum"],
        ["IL-17A","IL-17 inhibitor","Secukinumab, ixekizumab, bimekizumab (IL-17A/F)","Psoriasis, PsA, axial spondyloarthritis"],
        ["IL-23 (p19)","IL-23 inhibitor","Guselkumab, risankizumab, tildrakizumab","Psoriasis, PsA"],
        ["IL-12/23 (p40)","IL-12/23 inhibitor","Ustekinumab","Psoriasis, PsA, Crohn's disease"],
        ["IL-4R\u03b1 (IL-4/IL-13)","Biologic (mAb)","Dupilumab","Atopic dermatitis, CRSwNP, asthma"],
        ["IL-13","Biologic (mAb)","Tralokinumab, lebrikizumab","Atopic dermatitis"],
        ["IL-31RA","Biologic (mAb)","Nemolizumab","Prurigo nodularis, AD (itch)"],
        ["JAK1/JAK2/JAK3","JAK inhibitor (oral/topical)","Tofacitinib, upadacitinib, abrocitinib, ruxolitinib (topical)","Atopic dermatitis, alopecia areata, vitiligo, PsA"],
        ["PDE4","PDE4 inhibitor","Apremilast, roflumilast (topical)","Psoriasis, PsA, oral ulcers of Beh\u00e7et"],
        ["Calcineurin/NFAT (T-cell)","Calcineurin inhibitor","Tacrolimus, pimecrolimus (topical); ciclosporin (systemic)","Atopic dermatitis, psoriasis (ciclosporin)"],
        ["CD20 (B cells)","B-cell depletion","Rituximab","Pemphigus vulgaris/foliaceus"],
      ], top=1.4, height=5.55, col_widths=[2.1,2.4,3.9,3.6], header_size=12, body_size=10)
footer(s)
notes(s, "This slide operationalises the talk's core message: 'from understanding the pathway to targeting the "
      "pathway.' Walk through it top-down following the same cytokine order as slide 10/9, so the story is "
      "coherent: TNF was the first major biologic target; the IL-23/Th17 axis then refined psoriasis therapy "
      "(IL-23 blockers now preferred for durability and safety over IL-12/23 blockade); the Th2 axis transformed "
      "atopic dermatitis treatment (dupilumab); JAK inhibitors act downstream of many cytokine receptors "
      "(cytokines signal via JAK-STAT) explaining their broad efficacy across atopic dermatitis, alopecia areata "
      "and vitiligo; rituximab depletes CD20+ B cells, reducing pathogenic anti-desmoglein antibody production in "
      "pemphigus. Be ready to explain why anti-IL-17 can unmask/worsen mucocutaneous candidiasis (IL-17 is "
      "essential for anti-fungal mucosal immunity) - classic viva question.")

# =====================================================================
# SLIDE 19 - integration/viva quick review
# =====================================================================
s = add_slide(); header(s, "Rapid Review", "High-Yield Integration + Quick-Fire Concepts", 19)
items = [
    "Skin = immune organ: barrier + innate + adaptive + SALT, resident memory T cells outnumber those in circulation",
    "Keratinocytes: express PRRs, secrete alarmins/cytokines/AMPs - active immunocytes, not passive structure",
    "Langerhans cell (epidermal, antigen capture) vs. dermal DC (dermal, major IL-23/IL-12 source)",
    "CLA + CCR4/CCR10 = skin-homing code; E-selectin/CCL17/CCL27 are the vascular address",
    "TRM cells = long-term local memory \u2192 explains fixed-site disease recurrence",
    "Th1 (IFN-\u03b3) vs Th2 (IL-4/13) vs Th17 (IL-17/22, IL-23-dependent) - map cytokine to disease instantly",
    "IL-23/IL-17 axis = backbone of psoriasis pathogenesis and the most successful biologic target class",
    "LL-37 (cathelicidin): antimicrobial + self-DNA complex \u2192 TLR9 \u2192 pDC activation \u2192 early psoriasis trigger",
    "Type IV hypersensitivity subtypes: IVa (Th1/macrophage), IVb (Th2/eosinophil), IVc (CD8 cytotoxic), IVd (neutrophilic/AGEP)",
    "Psoriasis = Th17-driven; Atopic dermatitis = barrier defect + Th2-driven (two ends of one spectrum concept)",
    "Leprosy spectrum = clinical readout of host Th1 (tuberculoid) vs. Th2/anergic (lepromatous) immune polarity",
    "Modern biologics/JAKi = direct pharmacological translation of the cytokine pathways discussed today",
]
box = s.shapes.add_textbox(Inches(0.55), Inches(1.4), Inches(12.3), Inches(5.6))
tf = box.text_frame; tf.word_wrap = True
for i, it in enumerate(items):
    p = tf.paragraphs[0] if i == 0 else tf.add_paragraph()
    p.space_after = Pt(8)
    r1 = p.add_run(); r1.text = f"{i+1}.  "; r1.font.bold = True; r1.font.color.rgb = GOLD; r1.font.size = Pt(14.5)
    r2 = p.add_run(); r2.text = it; r2.font.size = Pt(14.5); r2.font.color.rgb = DARK
footer(s)
notes(s, "Use this slide as your final rapid-fire recap before opening the floor to questions - each line is "
      "phrased as a ready-made 30-second answer. This is also effectively a preview of the viva question bank "
      "that follows in the appendix, so faculty questions asked from this slide should feel already anticipated.")

# =====================================================================
# SLIDE 20 - take home + references
# =====================================================================
s = add_slide(); header(s, "Summary", "Take-Home Messages and References", 20)
th = [
    "Skin is a complete immune organ - barrier, innate and adaptive arms act together, not in isolation",
    "Keratinocytes are active immune participants, not passive bystanders",
    "Langerhans cells and dermal DCs bridge innate sensing to adaptive, antigen-specific T-cell responses",
    "CLA-dependent trafficking and TRM cells explain skin-specific and site-specific immune memory",
    "The Th1/Th2/Th17/Th22/Treg framework explains the majority of inflammatory dermatoses",
    "The IL-23/Th17 axis is central to psoriasis; barrier defect + Th2 skewing is central to atopic dermatitis",
    "Hypersensitivity classification (Gell-Coombs, Type IV subtypes) explains most drug eruptions",
    "Loss of tolerance underlies pemphigus, pemphigoid, lupus, dermatomyositis and vitiligo",
    "Leprosy remains the best clinical model of the Th1-Th2 immunological spectrum in dermatology",
    "Modern biologics/JAK inhibitors are direct translations of cytokine pathway science into targeted therapy",
]
bullets(s, [(t,0) for t in th], top=1.4, height=3.55, size=14.5)
txt(s, 0.55, 5.05, 12.2, 0.3, "Primary References", size=15, color=NAVY, bold=True)
refs = [
    "Bolognia JL, Schaffer JV, Cerroni L. Dermatology, 5th Edition. Elsevier, 2024.",
    "Griffiths CEM, Barker J, Bleiker T, Chalmers R, Creamer D (eds). Rook's Textbook of Dermatology, 9th Edition. Wiley-Blackwell, 2016 (with ongoing online updates).",
    "Kabashima K, Honda T, Ginhoux F, Egawa G. The immunological anatomy of the skin. Nat Rev Immunol. 2019;19:19-30.",
    "Lande R, et al. Plasmacytoid dendritic cells sense self-DNA coupled with antimicrobial peptide. Nature. 2007;449:564-9.",
    "Nograles KE, et al. Th17 cytokines interleukin (IL)-17 and IL-22 modulate distinct inflammatory and keratinocyte-response pathways. Br J Dermatol. 2008.",
    "Indian Journal of Dermatology, Venereology and Leprology - relevant reviews on leprosy immunology and psoriasis therapeutics (IJDVL, various years).",
]
box = s.shapes.add_textbox(Inches(0.55), Inches(5.4), Inches(12.3), Inches(1.9))
tf = box.text_frame; tf.word_wrap = True
for i, r in enumerate(refs):
    p = tf.paragraphs[0] if i == 0 else tf.add_paragraph()
    p.space_after = Pt(3)
    p.text = f"{i+1}. {r}"
    p.font.size = Pt(11); p.font.color.rgb = DARK
footer(s)
notes(s, "Close by reiterating the arc of the talk: barrier \u2192 innate \u2192 antigen presentation \u2192 T-cell "
      "polarisation \u2192 cytokine networks \u2192 clinical disease \u2192 targeted therapy. State clearly that Bolognia "
      "5th edition (2024) and Rook's 9th edition (Wiley-Blackwell, with online updates) were used as the primary "
      "frameworks, supplemented by key primary literature (Nature Reviews Immunology, Journal of Investigative "
      "Dermatology, British Journal of Dermatology) for mechanistic depth and IJDVL for regional relevance "
      "(leprosy). Thank the panel and invite questions.")

prs.save("/tmp/workspace/skin-immunology-ppt/Skin_Immunology_PGT1.pptx")
print("CORE_20_SAVED", len(prs.slides.__iter__.__self__._sldIdLst))
Editing File

~/skin-immunology-ppt/generate_ppt.py

Successfully replaced 1 instance(s) of the string in '/tmp/workspace/skin-immunology-ppt/generate_ppt.py'
Running Command

mkdir -p /tmp/workspace/skin-immunology-ppt && cd /tmp/workspace/skin-immunology-ppt && python generate_ppt.py

Running Command

cd /tmp/workspace/skin-immunology-ppt && python3 -c " from pptx import Presentation prs = Presentation('Skin_Immunology_PGT1.pptx') print('Total slides:', len(prs.slides)) for i, slide in enumerate(prs.slides, 1): title = '' for shape in slide.shapes: if shape.has_text_frame and shape.text_frame.text.strip(): title = shape.text_frame.text.strip().split(chr(10))[0] break has_notes = bool(slide.notes_slide.notes_text_frame.text.strip()) if slide.has_notes_slide else False print(i, '|', title[:70], '| notes:', has_notes) " && ls -la /tmp/workspace/skin-immunology-ppt/

The presentation is complete: 27 total slides (20 core academic slides + 5 viva Q&A slides covering 26 questions + a 1-minute revision slide), all with detailed speaker notes.

Skin Immunology PGT1

Presentation · PPTX

Structure delivered:
SlidesContent
1Title slide
2-20Exactly the 20 core slides you specified — barrier immunity → innate immunity → AMPs (LL-37/psoriasis link) → dendritic cells → T-cell subsets/Th polarization → cytokine network → immune cell cross-talk → trafficking → humoral immunity → tolerance/autoimmunity → hypersensitivity (Gell-Coombs + Type IV subtypes) → psoriasis/AD/ACD/urticaria/acne pathogenesis diagrams → leprosy spectrum → biologics/JAK inhibitors table → high-yield rapid review → take-home messages + references
21-26Appendix: 26 "Possible Questions from HOD/Professors" with 30-60s model answers + one high-yield point each
271-Minute Revision Sheet (Barrier → Innate → Antigen presentation → T cells → Cytokines → Hypersensitivity → Autoimmunity → Disease pathways → Targeted therapy)
Design notes:
  • Every content slide keeps 3-7 concise bullets/table rows on-slide; the depth (mechanisms, viva-ready explanations, textbook cross-references) lives in the speaker notes for all 27 slides, so the visible deck stays uncluttered while you have full talking points.
  • Flow diagrams (rounded boxes + arrows) were used for: barrier→resolution cascade, innate signalling sequence, antigen presentation sequence, Th-polarization branching (with T-bet/GATA-3/RORγt/AHR/FOXP3), leukocyte trafficking (rolling→adhesion→diapedesis→chemotaxis), tolerance breakdown, the 5 disease-pathogenesis mini-pathways, and the leprosy TT→BT→BB→BL→LL spectrum.
  • Tables used for: AMPs, Th-subset comparison, cytokine-to-biologic mapping, hypersensitivity types I-IV + IVa-d, leprosy TT vs LL features, and pathway→drug→disease therapeutics.
  • Content is grounded in Bolognia (5th ed., 2024) and Rook's (9th ed., Wiley-Blackwell) frameworks, cross-checked against library extracts (LL-37/TLR9/psoriasis mechanism, TRM cell biology, leprosy Th1/Th2 spectrum, IL-23/Th17 psoriasis pathway).
One thing to flag as a presenter: replace the placeholder name/institution fields on slide 1 before presenting, and feel free to trim the viva-answer slides (22-26) if your allotted time is short — they're designed as a private prep appendix you can skip live and use only for your own revision.
This is a shared conversation. Sign in to Orris to start your own chat.