अ, मुझे एक presentation देनी है। कोई भी medical topic पे, कोई भी बीमारी के ऊपर, as a general physician. वो तकरीबन ऐसे हो कि मेरे पास एक 10 slide से ज्यादा नहीं हों, PowerPoint पे। और वो तकरीबन 10 मिनट के लिए हो। क्या मैं उसको पाँच मिनट में cover कर सकती हूँ? Topi बहुत अच्छा होना चाहिए और एक तो वो बहुत अच्छा होना चाहिए और exact मुझे PPT PowerPoint चाहिए। मुझे topic बताएं आप किस पे दे रहे हैं और PowerPoint चाहिए।

Reading File
Reading File
Running Command

mkdir -p /tmp/workspace/hypertension-ppt && ls /tmp/workspace/

Writing File

~/hypertension-ppt/create_ppt.py

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.util import Inches, Pt
import copy
from lxml import etree

# ── Colour palette ────────────────────────────────────────────────
NAVY      = RGBColor(0x0D, 0x2B, 0x55)   # deep navy (header/accents)
TEAL      = RGBColor(0x00, 0x7B, 0x8A)   # teal accent
LIGHT_BG  = RGBColor(0xF0, 0xF6, 0xFA)   # slide background
WHITE     = RGBColor(0xFF, 0xFF, 0xFF)
RED       = RGBColor(0xC0, 0x39, 0x2B)
ORANGE    = RGBColor(0xE6, 0x7E, 0x22)
GREEN     = RGBColor(0x1A, 0x85, 0x54)
DARK_GRAY = RGBColor(0x2C, 0x3E, 0x50)
MID_GRAY  = RGBColor(0x55, 0x6B, 0x82)
YELLOW_BG = RGBColor(0xFF, 0xF3, 0xCD)
YELLOW_BD = RGBColor(0xFF, 0xC1, 0x07)

W = Inches(13.333)
H = Inches(7.5)

prs = Presentation()
prs.slide_width  = W
prs.slide_height = H
blank = prs.slide_layouts[6]

# ── helpers ──────────────────────────────────────────────────────

def add_rect(slide, x, y, w, h, fill_rgb=None, alpha=None):
    shape = slide.shapes.add_shape(1, x, y, w, h)  # MSO_SHAPE_TYPE.RECTANGLE = 1
    shape.line.fill.background()                    # no border by default
    if fill_rgb:
        shape.fill.solid()
        shape.fill.fore_color.rgb = fill_rgb
    else:
        shape.fill.background()
    return shape

def add_text(slide, text, x, y, w, h,
             font_name="Calibri", size=18, bold=False, italic=False,
             color=DARK_GRAY, align=PP_ALIGN.LEFT, wrap=True, anchor=MSO_ANCHOR.TOP):
    tb = slide.shapes.add_textbox(x, y, w, h)
    tf = tb.text_frame
    tf.word_wrap = wrap
    tf.vertical_anchor = anchor
    tf.margin_left   = Pt(2)
    tf.margin_right  = Pt(2)
    tf.margin_top    = Pt(2)
    tf.margin_bottom = Pt(2)
    p = tf.paragraphs[0]
    p.alignment = align
    run = p.add_run()
    run.text = text
    run.font.name  = font_name
    run.font.size  = Pt(size)
    run.font.bold  = bold
    run.font.italic = italic
    run.font.color.rgb = color
    return tf

def set_bg(slide, color):
    bg = slide.background
    fill = bg.fill
    fill.solid()
    fill.fore_color.rgb = color

def bullet_tf(slide, items, x, y, w, h,
              font_name="Calibri", size=16, color=DARK_GRAY,
              bullet_color=TEAL, line_spacing_pt=None):
    """Add a text box with bullet items (• prefix)."""
    tb = slide.shapes.add_textbox(x, y, w, h)
    tf = tb.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)
    first = True
    for item in items:
        if first:
            p = tf.paragraphs[0]
            first = False
        else:
            p = tf.add_paragraph()
        p.alignment = PP_ALIGN.LEFT
        if line_spacing_pt:
            p.line_spacing = Pt(line_spacing_pt)
        # bullet dot
        r0 = p.add_run()
        r0.text = "  •  "
        r0.font.name = font_name
        r0.font.size = Pt(size)
        r0.font.bold = True
        r0.font.color.rgb = bullet_color
        # content
        r1 = p.add_run()
        r1.text = item
        r1.font.name = font_name
        r1.font.size = Pt(size)
        r1.font.color.rgb = color
    return tf


# ═══════════════════════════════════════════════════════════════
# SLIDE 1 – Title Slide
# ═══════════════════════════════════════════════════════════════
slide = prs.slides.add_slide(blank)
set_bg(slide, NAVY)

# Full-width bottom stripe
add_rect(slide, 0, Inches(6.2), W, Inches(1.3), TEAL)

# Decorative circle accent
circle = slide.shapes.add_shape(9, Inches(10.5), Inches(-0.5), Inches(3.5), Inches(3.5))  # oval
circle.fill.solid()
circle.fill.fore_color.rgb = RGBColor(0x00, 0x5F, 0x6E)
circle.line.fill.background()

# Title
add_text(slide, "HYPERTENSION", Inches(0.8), Inches(1.8), Inches(10), Inches(1.5),
         font_name="Calibri", size=54, bold=True, color=WHITE, align=PP_ALIGN.LEFT)

# Subtitle
add_text(slide, "The Silent Killer — A Clinical Overview for General Physicians",
         Inches(0.8), Inches(3.3), Inches(9), Inches(0.9),
         font_name="Calibri", size=22, bold=False, italic=True,
         color=RGBColor(0xAD, 0xD8, 0xE6), align=PP_ALIGN.LEFT)

# Bottom bar text
add_text(slide, "Presenter: Dr. _____________          Date: ____________          CME Session",
         Inches(0.5), Inches(6.25), Inches(12), Inches(0.7),
         font_name="Calibri", size=15, bold=False, color=WHITE, align=PP_ALIGN.LEFT)

# Red heart icon as text
add_text(slide, "♥", Inches(11.8), Inches(1.6), Inches(1.2), Inches(1.2),
         size=70, color=RGBColor(0xC0, 0x39, 0x2B), align=PP_ALIGN.CENTER)


# ═══════════════════════════════════════════════════════════════
# SLIDE 2 – Epidemiology & Definition
# ═══════════════════════════════════════════════════════════════
slide = prs.slides.add_slide(blank)
set_bg(slide, LIGHT_BG)

# Header bar
add_rect(slide, 0, 0, W, Inches(1.1), NAVY)
add_text(slide, "Hypertension: Definition & Global Burden",
         Inches(0.4), Inches(0.12), Inches(12), Inches(0.85),
         size=28, bold=True, color=WHITE, align=PP_ALIGN.LEFT)

# Definition box
add_rect(slide, Inches(0.4), Inches(1.25), Inches(7.5), Inches(1.5), RGBColor(0x00, 0x5F, 0x6E))
add_text(slide, "DEFINITION  —  BP ≥ 140/90 mmHg on ≥ 2 separate readings\n"
               "(JNC 8 / WHO) or ≥ 130/80 mmHg (ACC/AHA 2017)",
         Inches(0.5), Inches(1.3), Inches(7.3), Inches(1.4),
         size=17, bold=False, color=WHITE, wrap=True, anchor=MSO_ANCHOR.MIDDLE)

# Stat boxes
stats = [
    ("1.28 B", "Adults worldwide affected", RED),
    ("46 %",   "Unaware of their diagnosis", ORANGE),
    ("< 1 in 5", "Have BP under control", TEAL),
]
for i, (val, lbl, col) in enumerate(stats):
    bx = Inches(0.4 + i * 3.1)
    add_rect(slide, bx, Inches(3.0), Inches(2.8), Inches(2.2), col)
    add_text(slide, val, bx, Inches(3.1), Inches(2.8), Inches(1.0),
             size=34, bold=True, color=WHITE, align=PP_ALIGN.CENTER)
    add_text(slide, lbl, bx, Inches(4.0), Inches(2.8), Inches(0.9),
             size=13, bold=False, color=WHITE, align=PP_ALIGN.CENTER, wrap=True)

# Classification table (right side)
add_rect(slide, Inches(8.2), Inches(1.2), Inches(4.8), Inches(4.1), WHITE)
headers = ["Category", "Systolic", "Diastolic"]
rows = [
    ("Normal",        "< 120",  "< 80"),
    ("Elevated",      "120–129","< 80"),
    ("Stage 1 HTN",   "130–139","80–89"),
    ("Stage 2 HTN",   "≥ 140",  "≥ 90"),
    ("HTN Crisis",    "> 180",  "> 120"),
]
row_colors = [TEAL, RGBColor(0x5D, 0xAD, 0xE8), ORANGE, RED, RGBColor(0x7D, 0x00, 0x00)]
col_widths = [Inches(1.8), Inches(1.4), Inches(1.4)]
col_xs     = [Inches(8.25), Inches(10.1), Inches(11.55)]

# header row
add_rect(slide, Inches(8.2), Inches(1.2), Inches(4.8), Inches(0.45), NAVY)
for ci, (hdr, cx) in enumerate(zip(headers, col_xs)):
    add_text(slide, hdr, cx, Inches(1.22), col_widths[ci], Inches(0.4),
             size=13, bold=True, color=WHITE, align=PP_ALIGN.CENTER)

for ri, (row, rc) in enumerate(zip(rows, row_colors)):
    ry = Inches(1.65 + ri * 0.49)
    add_rect(slide, Inches(8.2), ry, Inches(0.06), Inches(0.47), rc)  # color stripe
    bg = WHITE if ri % 2 == 0 else RGBColor(0xE8, 0xF4, 0xF8)
    add_rect(slide, Inches(8.26), ry, Inches(4.72), Inches(0.47), bg)
    for ci, (cell, cx) in enumerate(zip(row, col_xs)):
        add_text(slide, cell, cx, ry, col_widths[ci], Inches(0.46),
                 size=12, bold=(ci == 0), color=DARK_GRAY, align=PP_ALIGN.CENTER,
                 anchor=MSO_ANCHOR.MIDDLE)

add_text(slide, "Source: WHO 2023 | ACC/AHA Guidelines",
         Inches(0.4), Inches(5.4), Inches(6), Inches(0.4),
         size=11, italic=True, color=MID_GRAY)


# ═══════════════════════════════════════════════════════════════
# SLIDE 3 – Risk Factors
# ═══════════════════════════════════════════════════════════════
slide = prs.slides.add_slide(blank)
set_bg(slide, LIGHT_BG)
add_rect(slide, 0, 0, W, Inches(1.1), NAVY)
add_text(slide, "Risk Factors", Inches(0.4), Inches(0.12), Inches(12), Inches(0.85),
         size=28, bold=True, color=WHITE)

# Two columns
# Non-modifiable
add_rect(slide, Inches(0.4), Inches(1.2), Inches(5.8), Inches(5.5), WHITE)
add_rect(slide, Inches(0.4), Inches(1.2), Inches(5.8), Inches(0.55), RED)
add_text(slide, "🚫  NON-MODIFIABLE", Inches(0.5), Inches(1.23), Inches(5.6), Inches(0.5),
         size=15, bold=True, color=WHITE)
non_mod = [
    "Age (> 55 in men, > 65 in women)",
    "Family history / Genetics",
    "Race (higher prevalence in African descent)",
    "Chronic Kidney Disease (CKD)",
    "Diabetes Mellitus",
]
bullet_tf(slide, non_mod, Inches(0.45), Inches(1.85), Inches(5.6), Inches(4.5),
          size=15, color=DARK_GRAY, bullet_color=RED, line_spacing_pt=20)

# Modifiable
add_rect(slide, Inches(6.8), Inches(1.2), Inches(6.1), Inches(5.5), WHITE)
add_rect(slide, Inches(6.8), Inches(1.2), Inches(6.1), Inches(0.55), GREEN)
add_text(slide, "✅  MODIFIABLE (Actionable)", Inches(6.9), Inches(1.23), Inches(5.9), Inches(0.5),
         size=15, bold=True, color=WHITE)
mod = [
    "Obesity / Overweight (BMI > 25)",
    "High sodium diet (> 5 g/day)",
    "Physical inactivity / Sedentary lifestyle",
    "Excessive alcohol consumption",
    "Smoking & tobacco use",
    "Stress / Poor sleep",
    "Dyslipidaemia",
]
bullet_tf(slide, mod, Inches(6.85), Inches(1.85), Inches(5.9), Inches(4.5),
          size=15, color=DARK_GRAY, bullet_color=GREEN, line_spacing_pt=20)


# ═══════════════════════════════════════════════════════════════
# SLIDE 4 – Pathophysiology
# ═══════════════════════════════════════════════════════════════
slide = prs.slides.add_slide(blank)
set_bg(slide, LIGHT_BG)
add_rect(slide, 0, 0, W, Inches(1.1), NAVY)
add_text(slide, "Pathophysiology at a Glance", Inches(0.4), Inches(0.12), Inches(12), Inches(0.85),
         size=28, bold=True, color=WHITE)

add_text(slide, "BP = Cardiac Output (CO) × Total Peripheral Resistance (TPR)",
         Inches(0.5), Inches(1.2), Inches(12.3), Inches(0.7),
         size=20, bold=True, color=TEAL, align=PP_ALIGN.CENTER)

# 4 mechanism boxes
mechs = [
    ("RAAS Activation", "Angiotensin II → vasoconstriction + aldosterone → Na⁺/H₂O retention → ↑ BP", TEAL),
    ("SNS Overactivity", "↑ Catecholamines → ↑ HR, ↑ contractility, ↑ vasoconstriction → ↑ CO & TPR", NAVY),
    ("Endothelial Dysfunction", "↓ Nitric Oxide → impaired vasodilation → sustained↑ TPR", RED),
    ("Insulin Resistance", "Hyperinsulinemia → renal Na⁺ retention + SNS stimulation → ↑ BP", ORANGE),
]
for i, (title, body, col) in enumerate(mechs):
    col_i  = i % 2
    row_i  = i // 2
    bx = Inches(0.4 + col_i * 6.5)
    by = Inches(2.1 + row_i * 2.3)
    add_rect(slide, bx, by, Inches(6.0), Inches(2.1), col)
    add_text(slide, title, bx + Inches(0.15), by + Inches(0.1), Inches(5.7), Inches(0.55),
             size=17, bold=True, color=WHITE)
    add_text(slide, body, bx + Inches(0.15), by + Inches(0.6), Inches(5.7), Inches(1.3),
             size=14, color=WHITE, wrap=True)

add_text(slide, "Primary (Essential) HTN: 90–95% | Secondary HTN: 5–10% (CKD, RAS, phaeochromocytoma, Conn's)",
         Inches(0.5), Inches(6.75), Inches(12.3), Inches(0.55),
         size=12, italic=True, color=MID_GRAY, align=PP_ALIGN.CENTER)


# ═══════════════════════════════════════════════════════════════
# SLIDE 5 – Clinical Presentation & Diagnosis
# ═══════════════════════════════════════════════════════════════
slide = prs.slides.add_slide(blank)
set_bg(slide, LIGHT_BG)
add_rect(slide, 0, 0, W, Inches(1.1), NAVY)
add_text(slide, "Clinical Presentation & Diagnosis", Inches(0.4), Inches(0.12), Inches(12), Inches(0.85),
         size=28, bold=True, color=WHITE)

# "Silent Killer" callout
add_rect(slide, Inches(0.4), Inches(1.2), Inches(5.5), Inches(1.1), YELLOW_BG)
add_rect(slide, Inches(0.4), Inches(1.2), Inches(0.18), Inches(1.1), YELLOW_BD)
add_text(slide, "⚠  Often ASYMPTOMATIC — detected only on routine BP check.\nSymptoms appear when BP is severely elevated or complications arise.",
         Inches(0.65), Inches(1.25), Inches(5.1), Inches(1.0),
         size=13, bold=False, color=RGBColor(0x7D, 0x60, 0x08), wrap=True)

# Symptoms
add_rect(slide, Inches(0.4), Inches(2.5), Inches(5.5), Inches(3.7), WHITE)
add_rect(slide, Inches(0.4), Inches(2.5), Inches(5.5), Inches(0.5), RED)
add_text(slide, "Possible Symptoms", Inches(0.5), Inches(2.52), Inches(5.3), Inches(0.45),
         size=15, bold=True, color=WHITE)
syms = ["Headache (occipital, early morning)","Dizziness / Vertigo","Visual disturbances","Epistaxis (nose bleed)","Palpitations","Chest pain / dyspnoea (hypertensive urgency)"]
bullet_tf(slide, syms, Inches(0.45), Inches(3.1), Inches(5.3), Inches(3.0),
          size=14, color=DARK_GRAY, bullet_color=RED, line_spacing_pt=19)

# Diagnosis box
add_rect(slide, Inches(6.3), Inches(1.2), Inches(6.6), Inches(5.0), WHITE)
add_rect(slide, Inches(6.3), Inches(1.2), Inches(6.6), Inches(0.5), TEAL)
add_text(slide, "Diagnosis Workup", Inches(6.4), Inches(1.22), Inches(6.4), Inches(0.46),
         size=15, bold=True, color=WHITE)
diag = [
    "BP measurement: 2+ readings, both arms, ≥ 2 visits",
    "ABPM / Home BP monitoring to exclude white-coat HTN",
    "Urine: dipstick, ACR (albumin:creatinine)",
    "Blood: FBC, U&E, Creatinine, eGFR, Glucose, Lipids",
    "ECG: LVH, ischaemia",
    "Fundoscopy: Keith–Wagener grading",
    "Echo: if LVH / cardiac involvement suspected",
    "Secondary HTN screen if age < 30, resistant HTN",
]
bullet_tf(slide, diag, Inches(6.35), Inches(1.8), Inches(6.4), Inches(4.2),
          size=13, color=DARK_GRAY, bullet_color=TEAL, line_spacing_pt=18)


# ═══════════════════════════════════════════════════════════════
# SLIDE 6 – Complications (Target Organ Damage)
# ═══════════════════════════════════════════════════════════════
slide = prs.slides.add_slide(blank)
set_bg(slide, LIGHT_BG)
add_rect(slide, 0, 0, W, Inches(1.1), NAVY)
add_text(slide, "Target Organ Damage", Inches(0.4), Inches(0.12), Inches(12), Inches(0.85),
         size=28, bold=True, color=WHITE)

organs = [
    ("♥ HEART",    ["Left Ventricular Hypertrophy","Heart Failure (HFpEF)","Coronary Artery Disease","Atrial Fibrillation"], RED),
    ("🧠 BRAIN",   ["Ischaemic Stroke","Haemorrhagic Stroke","Hypertensive Encephalopathy","Vascular Dementia"], NAVY),
    ("🫘 KIDNEY",  ["Hypertensive Nephropathy","Proteinuria / CKD","End-Stage Renal Disease"], TEAL),
    ("👁 EYES",    ["Hypertensive Retinopathy (Grade 1-4)","Cotton-wool spots, AV nipping","Papilloedema (Grade 4 — emergency)"], ORANGE),
    ("🩸 VESSELS", ["Aortic Aneurysm / Dissection","Peripheral Arterial Disease","Accelerated Atherosclerosis"], RGBColor(0x6C, 0x35, 0x7A)),
]
for i, (organ, comps, col) in enumerate(organs):
    col_i = i % 3
    row_i = i // 3
    bx = Inches(0.35 + col_i * 4.33)
    by = Inches(1.25 + row_i * 2.8)
    bw = Inches(4.0)
    bh = Inches(2.55)
    add_rect(slide, bx, by, bw, bh, WHITE)
    add_rect(slide, bx, by, bw, Inches(0.52), col)
    add_text(slide, organ, bx + Inches(0.1), by + Inches(0.05), bw - Inches(0.2), Inches(0.44),
             size=15, bold=True, color=WHITE)
    bullet_tf(slide, comps, bx + Inches(0.05), by + Inches(0.58), bw - Inches(0.15), bh - Inches(0.65),
              size=12, color=DARK_GRAY, bullet_color=col, line_spacing_pt=17)


# ═══════════════════════════════════════════════════════════════
# SLIDE 7 – Management: Non-Pharmacological
# ═══════════════════════════════════════════════════════════════
slide = prs.slides.add_slide(blank)
set_bg(slide, LIGHT_BG)
add_rect(slide, 0, 0, W, Inches(1.1), NAVY)
add_text(slide, "Management — Lifestyle Modifications (Non-Pharmacological)",
         Inches(0.4), Inches(0.12), Inches(12.5), Inches(0.85),
         size=26, bold=True, color=WHITE)

lifestyle = [
    ("🧂 Sodium Restriction",    "Reduce to < 2 g/day (5 g salt)\nDASH diet: ↓ SBP by 8–14 mmHg", GREEN),
    ("🏃 Physical Activity",     "≥ 150 min/week moderate aerobic\n↓ SBP by 4–9 mmHg", TEAL),
    ("⚖ Weight Loss",           "Every 1 kg loss → ↓ 1 mmHg BP\nTarget BMI 18.5–24.9", ORANGE),
    ("🚭 Stop Smoking",          "Immediate cardiovascular benefit\nReduces overall CV risk by 50%", RED),
    ("🍷 Limit Alcohol",         "Men ≤ 2 units/day, Women ≤ 1 unit\n↓ SBP up to 4 mmHg", RGBColor(0x6C, 0x35, 0x7A)),
    ("😴 Stress & Sleep",       "Mindfulness, yoga, adequate sleep\n↓ Sympathetic overactivity", NAVY),
]
for i, (title, body, col) in enumerate(lifestyle):
    ci = i % 3
    ri = i // 3
    bx = Inches(0.35 + ci * 4.33)
    by = Inches(1.25 + ri * 2.8)
    add_rect(slide, bx, by, Inches(4.0), Inches(2.55), WHITE)
    add_rect(slide, bx, by, Inches(0.18), Inches(2.55), col)
    add_text(slide, title, bx + Inches(0.3), by + Inches(0.15), Inches(3.55), Inches(0.55),
             size=15, bold=True, color=col)
    add_text(slide, body, bx + Inches(0.3), by + Inches(0.72), Inches(3.55), Inches(1.65),
             size=13, color=DARK_GRAY, wrap=True)


# ═══════════════════════════════════════════════════════════════
# SLIDE 8 – Management: Pharmacological
# ═══════════════════════════════════════════════════════════════
slide = prs.slides.add_slide(blank)
set_bg(slide, LIGHT_BG)
add_rect(slide, 0, 0, W, Inches(1.1), NAVY)
add_text(slide, "Management — Pharmacological Treatment",
         Inches(0.4), Inches(0.12), Inches(12.5), Inches(0.85),
         size=28, bold=True, color=WHITE)

# Treatment algorithm box
add_rect(slide, Inches(0.35), Inches(1.2), Inches(5.0), Inches(5.6), WHITE)
add_rect(slide, Inches(0.35), Inches(1.2), Inches(5.0), Inches(0.5), TEAL)
add_text(slide, "Treatment Algorithm", Inches(0.45), Inches(1.22), Inches(4.8), Inches(0.46),
         size=15, bold=True, color=WHITE)
algo = [
    "Step 1: Lifestyle modification (all patients)",
    "Step 2: Stage 1 HTN + high CV risk → Start drug",
    "Step 3: First-line monotherapy (any of 5 classes)",
    "Step 4: 2-drug combo if BP not controlled in 1 month",
    "Step 5: 3-drug combo (ACEi/ARB + CCB + Thiazide)",
    "Step 6: Resistant HTN → Add spironolactone or α-blocker",
    "TARGET: < 130/80 mmHg (ACC/AHA) / < 140/90 (WHO)",
]
bullet_tf(slide, algo, Inches(0.4), Inches(1.8), Inches(4.8), Inches(4.8),
          size=13, color=DARK_GRAY, bullet_color=TEAL, line_spacing_pt=18)

# Drug classes table
drugs = [
    ("ACE Inhibitors", "Enalapril, Ramipril", "DM nephropathy, HF, post-MI", RED),
    ("ARBs", "Losartan, Valsartan", "ACEi intolerance, DM, HF", ORANGE),
    ("CCBs", "Amlodipine, Nifedipine", "Elderly, ISH, Angina", TEAL),
    ("Thiazide Diuretics", "HCTZ, Chlorthalidone", "Elderly, Heart Failure, ISH", NAVY),
    ("Beta-Blockers", "Atenolol, Bisoprolol", "Post-MI, AF, HFrEF", RGBColor(0x6C, 0x35, 0x7A)),
]
tx = Inches(5.6)
add_rect(slide, tx, Inches(1.2), Inches(7.4), Inches(5.6), NAVY)
for ci, hdr in enumerate(["Drug Class", "Examples", "Preferred In"]):
    cw = [Inches(2.1), Inches(2.3), Inches(2.8)]
    cx = [tx, tx + Inches(2.15), tx + Inches(4.5)]
    add_text(slide, hdr, cx[ci], Inches(1.22), cw[ci], Inches(0.48),
             size=13, bold=True, color=WHITE, align=PP_ALIGN.CENTER)

for ri, (cls, ex, pref, col) in enumerate(drugs):
    ry = Inches(1.7 + ri * 0.84)
    bg = WHITE if ri % 2 == 0 else RGBColor(0xE8, 0xF4, 0xF8)
    add_rect(slide, tx, ry, Inches(7.4), Inches(0.82), bg)
    add_rect(slide, tx, ry, Inches(0.18), Inches(0.82), col)
    for ci, cell in enumerate([cls, ex, pref]):
        cw = [Inches(1.9), Inches(2.3), Inches(2.8)]
        cx = [tx + Inches(0.22), tx + Inches(2.15), tx + Inches(4.5)]
        add_text(slide, cell, cx[ci], ry + Inches(0.05), cw[ci], Inches(0.7),
                 size=12, bold=(ci == 0), color=DARK_GRAY, wrap=True, anchor=MSO_ANCHOR.MIDDLE)


# ═══════════════════════════════════════════════════════════════
# SLIDE 9 – Hypertensive Emergency & Special Populations
# ═══════════════════════════════════════════════════════════════
slide = prs.slides.add_slide(blank)
set_bg(slide, LIGHT_BG)
add_rect(slide, 0, 0, W, Inches(1.1), NAVY)
add_text(slide, "Hypertensive Emergency & Special Populations",
         Inches(0.4), Inches(0.12), Inches(12.5), Inches(0.85),
         size=26, bold=True, color=WHITE)

# Emergency box
add_rect(slide, Inches(0.35), Inches(1.2), Inches(6.0), Inches(5.6), RGBColor(0xFD, 0xED, 0xEC))
add_rect(slide, Inches(0.35), Inches(1.2), Inches(6.0), Inches(0.55), RED)
add_text(slide, "🚨 Hypertensive Emergency (BP > 180/120 + TOD)",
         Inches(0.45), Inches(1.23), Inches(5.8), Inches(0.5),
         size=14, bold=True, color=WHITE)
emerg = [
    "ICU admission — IV antihypertensives",
    "IV Labetalol / Nicardipine / Nitroprusside",
    "Reduce MAP by no more than 25% in first hour",
    "Further reduction to 160/100 over 2–6 hours",
    "Identify underlying cause (ACS, aortic dissection, eclampsia)",
    "Urgency (no TOD): Oral agents — Amlodipine, Captopril",
    "Do NOT lower BP too rapidly — risk of ischaemia",
]
bullet_tf(slide, emerg, Inches(0.4), Inches(1.85), Inches(5.8), Inches(4.7),
          size=13, color=DARK_GRAY, bullet_color=RED, line_spacing_pt=19)

# Special populations
add_rect(slide, Inches(6.65), Inches(1.2), Inches(6.3), Inches(5.6), WHITE)
add_rect(slide, Inches(6.65), Inches(1.2), Inches(6.3), Inches(0.55), TEAL)
add_text(slide, "Special Populations", Inches(6.75), Inches(1.23), Inches(6.1), Inches(0.5),
         size=14, bold=True, color=WHITE)
specials = [
    "Pregnancy: Methyldopa, Labetalol, Nifedipine (NO ACEi/ARB)",
    "Elderly (> 65): Target < 150/90; avoid postural hypotension",
    "Diabetes: Target < 130/80; prefer ACEi or ARB",
    "CKD: ACEi/ARB first-line; monitor K⁺ & creatinine",
    "Heart Failure: ACEi + Beta-blocker + diuretic combination",
    "Post-MI: Beta-blocker + ACEi/ARB mandatory",
    "Asthma: Avoid Beta-blockers; prefer ACEi/ARB + CCB",
]
bullet_tf(slide, specials, Inches(6.7), Inches(1.85), Inches(6.1), Inches(4.7),
          size=13, color=DARK_GRAY, bullet_color=TEAL, line_spacing_pt=19)


# ═══════════════════════════════════════════════════════════════
# SLIDE 10 (but 9+1) – Key Take-Aways & Summary
# ═══════════════════════════════════════════════════════════════
slide = prs.slides.add_slide(blank)
set_bg(slide, NAVY)

# decorative circle
circ = slide.shapes.add_shape(9, Inches(-1), Inches(5.5), Inches(4), Inches(4))
circ.fill.solid()
circ.fill.fore_color.rgb = RGBColor(0x00, 0x5F, 0x6E)
circ.line.fill.background()

add_text(slide, "KEY TAKE-AWAYS", Inches(0.5), Inches(0.3), Inches(12.3), Inches(0.9),
         size=36, bold=True, color=WHITE, align=PP_ALIGN.CENTER)
add_rect(slide, Inches(1.5), Inches(1.15), Inches(10.3), Inches(0.08), TEAL)

takeaways = [
    "Hypertension is the #1 modifiable cardiovascular risk factor globally.",
    "Most patients are asymptomatic — proactive BP screening is essential.",
    "Lifestyle modification is the foundation of treatment for all patients.",
    "First-line drugs: ACEi/ARB, CCB, or Thiazide — tailor to comorbidities.",
    "Hypertensive emergency: reduce MAP by ≤ 25% in the first hour (IV route).",
    "Special populations require individualised targets and drug selection.",
    "Regular follow-up every 1–3 months until BP is controlled.",
]

for i, item in enumerate(takeaways):
    by = Inches(1.4 + i * 0.74)
    add_rect(slide, Inches(0.5), by, Inches(0.6), Inches(0.55),
             TEAL if i % 2 == 0 else RED)
    add_text(slide, str(i + 1), Inches(0.5), by, Inches(0.6), Inches(0.55),
             size=17, bold=True, color=WHITE, align=PP_ALIGN.CENTER, anchor=MSO_ANCHOR.MIDDLE)
    add_text(slide, item, Inches(1.25), by, Inches(11.5), Inches(0.55),
             size=15, color=WHITE, wrap=True, anchor=MSO_ANCHOR.MIDDLE)

add_text(slide, "♥  Treat the Patient, Not Just the Number  ♥",
         Inches(1), Inches(6.8), Inches(11.3), Inches(0.55),
         size=16, bold=True, italic=True, color=TEAL, align=PP_ALIGN.CENTER)

# ── Save ────────────────────────────────────────────────────────
out = "/tmp/workspace/hypertension-ppt/Hypertension_GP_Presentation.pptx"
prs.save(out)
print(f"Saved: {out}")
Running Command

python /tmp/workspace/hypertension-ppt/create_ppt.py

Running Command

python -c " from pptx import Presentation prs = Presentation('/tmp/workspace/hypertension-ppt/Hypertension_GP_Presentation.pptx') print(f'Total slides: {len(prs.slides)}') for i, slide in enumerate(prs.slides, 1): texts = [sh.text_frame.text.strip()[:60] for sh in slide.shapes if sh.has_text_frame and sh.text_frame.text.strip()] print(f' Slide {i}: {texts[0] if texts else \"(empty)\"}') "

आपकी PowerPoint तैयार है! 🎉 यहाँ download करें:

Hypertension GP Presentation

Presentation · PPTX


Topic: Hypertension — "The Silent Killer"

यह topic general physician के लिए सबसे perfect है क्योंकि:
  • हर 3 में से 1 adult को hypertension है
  • Real-world clinical relevance है
  • Audience को instantly connect होता है

Presentation Structure (10 Slides, ~10 minutes):

SlideTopicTime
1Title Slide — Dark navy design, bold~30 sec
2Definition & Epidemiology — WHO data, BP classification table~1 min
3Risk Factors — Modifiable vs Non-modifiable (2 color-coded columns)~1 min
4Pathophysiology — RAAS, SNS, Endothelial dysfunction, 4 boxes~1.5 min
5Clinical Presentation & Diagnosis — Workup checklist~1 min
6Target Organ Damage — Heart, Brain, Kidney, Eyes, Vessels~1.5 min
7Lifestyle Modifications — 6 pillars with evidence-based BP reduction~1 min
8Pharmacological Treatment — Algorithm + Drug class table (preferred indications)~1.5 min
9Hypertensive Emergency & Special Populations — Pregnancy, DM, CKD, Elderly~1 min
10Key Take-Aways — 7 numbered points, navy theme~30 sec

Design Highlights:

  • Color scheme: Deep navy + teal + white - professional medical look
  • Classification table (slide 2) - ACC/AHA & WHO both covered
  • Drug table (slide 8) - preferred indications clearly marked
  • Presenter name & date fields - slide 1 पर fill करें
  • 16:9 widescreen format - projector के लिए perfect
आप directly इसे PowerPoint में खोल सकती हैं और Presenter Name/Date भर सकती हैं।

मुझे exact PPT की form में PowerPoint दे ताकि वो download कर सकूँ। हाँ।

File already exists and is ready! Direct download link:

Hypertension GP Presentation

Presentation · PPTX

ऊपर दिए link पर click करें - file तुरंत download हो जाएगी। यह एक proper .pptx file है जो Microsoft PowerPoint, Google Slides, या LibreOffice Impress में directly खुलेगी।

अच्छा, ये जो आपने hypertension की मुझे presentation दी है ना, ये बहुत complicated हो रही है। मुझे थोड़ा simple version दें। इसी तरीके से खूबसूरत हो, लेकिन ये मैं पाँच minute में cover नहीं कर सकती। इसमें ज़्यादा time लेगा। तो मुझे इसमें material हल्का कर दें। एक risk factors का एक वो डाल दें। एक हल्का सा modification, lifestyle modification का डाल दें। एक classification कर दें। मतलब एक slide में एक बात हो, बहुत ज़्यादा ना हो। क्योंकि मैं पाँच minute में इतना ज़्यादा मैं cover...

Writing File

~/hypertension-ppt/create_simple_ppt.py

from pptx import Presentation
from pptx.util import Inches, Pt
from pptx.dml.color import RGBColor
from pptx.enum.text import PP_ALIGN, MSO_ANCHOR

# Colours
NAVY    = RGBColor(0x0D, 0x2B, 0x55)
TEAL    = RGBColor(0x00, 0x7B, 0x8A)
LIGHT   = RGBColor(0xF0, 0xF6, 0xFA)
WHITE   = RGBColor(0xFF, 0xFF, 0xFF)
RED     = RGBColor(0xC0, 0x39, 0x2B)
ORANGE  = RGBColor(0xE6, 0x7E, 0x22)
GREEN   = RGBColor(0x1A, 0x85, 0x54)
DGRAY   = RGBColor(0x2C, 0x3E, 0x50)
MGRAY   = RGBColor(0x55, 0x6B, 0x82)

W = Inches(13.333)
H = Inches(7.5)

prs = Presentation()
prs.slide_width  = W
prs.slide_height = H
blank = prs.slide_layouts[6]

# ── helpers ──────────────────────────────────────────────────────
def bg(slide, col):
    f = slide.background.fill
    f.solid(); f.fore_color.rgb = col

def rect(slide, x, y, w, h, col=None):
    s = slide.shapes.add_shape(1, x, y, w, h)
    s.line.fill.background()
    if col: s.fill.solid(); s.fill.fore_color.rgb = col
    else:   s.fill.background()
    return s

def txt(slide, text, x, y, w, h, size=18, bold=False, italic=False,
        color=DGRAY, align=PP_ALIGN.LEFT, wrap=True, anchor=MSO_ANCHOR.TOP):
    tb = slide.shapes.add_textbox(x, y, w, h)
    tf = tb.text_frame
    tf.word_wrap = wrap
    tf.vertical_anchor = anchor
    tf.margin_left = tf.margin_right = tf.margin_top = tf.margin_bottom = Pt(3)
    p = tf.paragraphs[0]
    p.alignment = align
    r = p.add_run()
    r.text = text
    r.font.name  = "Calibri"
    r.font.size  = Pt(size)
    r.font.bold  = bold
    r.font.italic = italic
    r.font.color.rgb = color
    return tf

def header(slide, title, accent=TEAL):
    rect(slide, 0, 0, W, Inches(1.0), NAVY)
    rect(slide, 0, Inches(1.0), W, Inches(0.06), accent)
    txt(slide, title, Inches(0.5), Inches(0.1), Inches(12.3), Inches(0.85),
        size=30, bold=True, color=WHITE, anchor=MSO_ANCHOR.MIDDLE)

def bullets(slide, items, x, y, w, h, size=20, bcol=TEAL, tcol=DGRAY, spacing=26):
    tb = slide.shapes.add_textbox(x, y, w, h)
    tf = tb.text_frame
    tf.word_wrap = True
    tf.margin_left = tf.margin_right = Pt(4)
    tf.margin_top  = tf.margin_bottom = Pt(4)
    first = True
    for item in items:
        p = tf.paragraphs[0] if first else tf.add_paragraph()
        first = False
        p.line_spacing = Pt(spacing)
        r0 = p.add_run(); r0.text = "  ●  "
        r0.font.name = "Calibri"; r0.font.size = Pt(size)
        r0.font.bold = True; r0.font.color.rgb = bcol
        r1 = p.add_run(); r1.text = item
        r1.font.name = "Calibri"; r1.font.size = Pt(size)
        r1.font.color.rgb = tcol


# ════════════════════════════════════════════════════════════════
# SLIDE 1 – Title
# ════════════════════════════════════════════════════════════════
s = prs.slides.add_slide(blank)
bg(s, NAVY)
# accent circle
c = s.shapes.add_shape(9, Inches(10.2), Inches(-0.8), Inches(4.2), Inches(4.2))
c.fill.solid(); c.fill.fore_color.rgb = RGBColor(0x00, 0x5F, 0x6E)
c.line.fill.background()
# bottom bar
rect(s, 0, Inches(6.3), W, Inches(1.2), TEAL)

txt(s, "HYPERTENSION",
    Inches(0.8), Inches(1.5), Inches(10), Inches(1.6),
    size=58, bold=True, color=WHITE)
txt(s, "The Silent Killer",
    Inches(0.8), Inches(3.1), Inches(9), Inches(0.8),
    size=26, italic=True, color=RGBColor(0xAD, 0xD8, 0xE6))
txt(s, "A 5-Minute Clinical Overview  |  General Physician",
    Inches(0.8), Inches(3.9), Inches(9), Inches(0.6),
    size=18, color=RGBColor(0xAD, 0xD8, 0xE6))
txt(s, "♥", Inches(11.5), Inches(1.4), Inches(1.4), Inches(1.4),
    size=72, color=RED, align=PP_ALIGN.CENTER)
txt(s, "Dr. _______________          Date: ___________",
    Inches(0.8), Inches(6.38), Inches(11), Inches(0.7),
    size=16, color=WHITE)


# ════════════════════════════════════════════════════════════════
# SLIDE 2 – What is Hypertension? (Definition + Classification)
# ════════════════════════════════════════════════════════════════
s = prs.slides.add_slide(blank)
bg(s, LIGHT)
header(s, "What is Hypertension?", TEAL)

# Definition banner
rect(s, Inches(0.5), Inches(1.3), Inches(12.3), Inches(1.1), TEAL)
txt(s, "Blood Pressure  ≥  140 / 90 mmHg  on  2 or more separate readings",
    Inches(0.6), Inches(1.35), Inches(12.1), Inches(1.0),
    size=22, bold=True, color=WHITE, align=PP_ALIGN.CENTER, anchor=MSO_ANCHOR.MIDDLE)

# Classification table (simple, big font)
headers_row = ["Category", "Systolic (mmHg)", "Diastolic (mmHg)"]
rows = [
    ("Normal",       "< 120",    "< 80",   GREEN),
    ("Elevated",     "120–129",  "< 80",   ORANGE),
    ("Stage 1 HTN",  "130–139",  "80–89",  RGBColor(0xE6, 0x7E, 0x22)),
    ("Stage 2 HTN",  "≥ 140",    "≥ 90",   RED),
    ("HTN Crisis",   "> 180",    "> 120",  RGBColor(0x7D, 0x00, 0x00)),
]
col_w = [Inches(3.8), Inches(3.8), Inches(3.8)]
col_x = [Inches(0.5), Inches(4.35), Inches(8.2)]
# header row
rect(s, Inches(0.5), Inches(2.6), Inches(11.5), Inches(0.55), NAVY)
for ci, h in enumerate(headers_row):
    txt(s, h, col_x[ci], Inches(2.62), col_w[ci], Inches(0.5),
        size=15, bold=True, color=WHITE, align=PP_ALIGN.CENTER, anchor=MSO_ANCHOR.MIDDLE)
for ri, (cat, sys, dia, col) in enumerate(rows):
    ry = Inches(3.17 + ri * 0.65)
    bg_c = WHITE if ri % 2 == 0 else RGBColor(0xE8, 0xF4, 0xF8)
    rect(s, Inches(0.5), ry, Inches(11.5), Inches(0.63), bg_c)
    rect(s, Inches(0.5), ry, Inches(0.18), Inches(0.63), col)
    for ci, cell in enumerate([cat, sys, dia]):
        txt(s, cell, col_x[ci] + Inches(0.1), ry, col_w[ci], Inches(0.63),
            size=16, bold=(ci == 0), color=DGRAY,
            align=PP_ALIGN.CENTER, anchor=MSO_ANCHOR.MIDDLE)


# ════════════════════════════════════════════════════════════════
# SLIDE 3 – Risk Factors
# ════════════════════════════════════════════════════════════════
s = prs.slides.add_slide(blank)
bg(s, LIGHT)
header(s, "Risk Factors", RED)

# Left: Non-modifiable
rect(s, Inches(0.5), Inches(1.25), Inches(5.8), Inches(5.5), WHITE)
rect(s, Inches(0.5), Inches(1.25), Inches(5.8), Inches(0.6), RED)
txt(s, "🚫  Cannot Change",
    Inches(0.6), Inches(1.28), Inches(5.6), Inches(0.55),
    size=18, bold=True, color=WHITE)
bullets(s,
    ["Age  (Men > 55 yrs,  Women > 65 yrs)",
     "Family history / Genetics",
     "Male sex",
     "Chronic Kidney Disease",
     "Diabetes Mellitus"],
    Inches(0.55), Inches(1.95), Inches(5.6), Inches(4.5),
    size=17, bcol=RED, spacing=28)

# Right: Modifiable
rect(s, Inches(7.0), Inches(1.25), Inches(5.8), Inches(5.5), WHITE)
rect(s, Inches(7.0), Inches(1.25), Inches(5.8), Inches(0.6), GREEN)
txt(s, "✅  Can Change",
    Inches(7.1), Inches(1.28), Inches(5.6), Inches(0.55),
    size=18, bold=True, color=WHITE)
bullets(s,
    ["Obesity  (BMI > 25)",
     "High salt diet",
     "Physical inactivity",
     "Smoking / Tobacco",
     "Excess alcohol",
     "Stress & poor sleep"],
    Inches(7.05), Inches(1.95), Inches(5.6), Inches(4.5),
    size=17, bcol=GREEN, spacing=28)

# divider arrow
txt(s, "→", Inches(6.0), Inches(3.6), Inches(1.0), Inches(0.8),
    size=38, bold=True, color=TEAL, align=PP_ALIGN.CENTER)


# ════════════════════════════════════════════════════════════════
# SLIDE 4 – Symptoms (Clinical Presentation)
# ════════════════════════════════════════════════════════════════
s = prs.slides.add_slide(blank)
bg(s, LIGHT)
header(s, "How Does it Present?", ORANGE)

# Big callout box
rect(s, Inches(0.5), Inches(1.3), Inches(12.3), Inches(1.3), RGBColor(0xFF, 0xF3, 0xCD))
rect(s, Inches(0.5), Inches(1.3), Inches(0.25), Inches(1.3), RGBColor(0xFF, 0xC1, 0x07))
txt(s, "⚠   Usually SILENT — Most patients have NO symptoms.\n     Detected only on routine BP check.",
    Inches(0.85), Inches(1.38), Inches(11.8), Inches(1.15),
    size=18, bold=True, color=RGBColor(0x7D, 0x60, 0x08), wrap=True)

# 4 symptom cards
syms = [
    ("🤕", "Headache",     "Occipital,\nearly morning",          RED),
    ("😵", "Dizziness",    "Vertigo,\nlightheadedness",          ORANGE),
    ("👁", "Visual\nBlurring", "Blurred or\ndouble vision",      TEAL),
    ("💓", "Palpitations", "Awareness of\nheart beating",        NAVY),
]
for i, (icon, title, sub, col) in enumerate(syms):
    bx = Inches(0.5 + i * 3.2)
    rect(s, bx, Inches(2.9), Inches(2.9), Inches(3.5), WHITE)
    rect(s, bx, Inches(2.9), Inches(2.9), Inches(0.6), col)
    txt(s, icon, bx, Inches(3.5), Inches(2.9), Inches(1.1),
        size=38, align=PP_ALIGN.CENTER)
    txt(s, title, bx, Inches(4.55), Inches(2.9), Inches(0.65),
        size=18, bold=True, color=col, align=PP_ALIGN.CENTER)
    txt(s, sub, bx, Inches(5.2), Inches(2.9), Inches(0.9),
        size=14, color=MGRAY, align=PP_ALIGN.CENTER, wrap=True)

txt(s, "When severe: Chest pain  |  Shortness of breath  |  Nose bleed  |  Visual loss",
    Inches(0.5), Inches(6.65), Inches(12.3), Inches(0.6),
    size=14, italic=True, color=MGRAY, align=PP_ALIGN.CENTER)


# ════════════════════════════════════════════════════════════════
# SLIDE 5 – Complications (Target Organ Damage)
# ════════════════════════════════════════════════════════════════
s = prs.slides.add_slide(blank)
bg(s, LIGHT)
header(s, "Why Does It Matter?  —  Complications", RED)

organs = [
    ("♥", "Heart",   "Heart attack, Heart failure, LV Hypertrophy",    RED),
    ("🧠", "Brain",  "Stroke, TIA, Vascular Dementia",                  NAVY),
    ("🫘", "Kidneys","CKD, Proteinuria, Renal Failure",                 TEAL),
    ("👁", "Eyes",   "Hypertensive Retinopathy, Vision Loss",           ORANGE),
    ("🩸", "Vessels","Aortic Aneurysm, Peripheral Artery Disease",      RGBColor(0x6C, 0x35, 0x7A)),
]
for i, (icon, organ, comp, col) in enumerate(organs):
    ci = i % 3
    ri = i // 3
    # 3 on top row, 2 centred below
    if ri == 0:
        bx = Inches(0.4 + ci * 4.3)
    else:
        bx = Inches(2.55 + ci * 4.3)
    by = Inches(1.25 + ri * 2.85)
    rect(s, bx, by, Inches(3.8), Inches(2.6), WHITE)
    rect(s, bx, by, Inches(3.8), Inches(0.65), col)
    txt(s, icon + "  " + organ, bx + Inches(0.1), by + Inches(0.08),
        Inches(3.6), Inches(0.55), size=19, bold=True, color=WHITE)
    txt(s, comp, bx + Inches(0.15), by + Inches(0.8),
        Inches(3.5), Inches(1.6), size=15, color=DGRAY, wrap=True)


# ════════════════════════════════════════════════════════════════
# SLIDE 6 – Lifestyle Modifications
# ════════════════════════════════════════════════════════════════
s = prs.slides.add_slide(blank)
bg(s, LIGHT)
header(s, "Lifestyle Modifications — First Line Treatment", GREEN)

tips = [
    ("🧂", "Reduce Salt",       "< 5 g/day\n↓ BP by 8–14 mmHg",      GREEN),
    ("🏃", "Exercise",          "30 min/day, 5 days/week\n↓ BP by 4–9 mmHg", TEAL),
    ("⚖", "Lose Weight",       "Every 1 kg lost\n↓ BP by ~1 mmHg",   ORANGE),
    ("🚭", "Quit Smoking",      "Cuts CV risk\nby 50% in 1 year",      RED),
    ("🍷", "Limit Alcohol",     "Max 1–2 units/day\n↓ BP by 4 mmHg",  RGBColor(0x6C, 0x35, 0x7A)),
    ("😴", "Sleep & De-stress", "7–8 hrs sleep\nReduce SNS activity",  NAVY),
]
for i, (icon, title, body, col) in enumerate(tips):
    ci = i % 3
    ri = i // 3
    bx = Inches(0.4 + ci * 4.3)
    by = Inches(1.25 + ri * 2.85)
    rect(s, bx, by, Inches(3.8), Inches(2.6), WHITE)
    rect(s, bx, by, Inches(0.2), Inches(2.6), col)
    txt(s, icon + "  " + title, bx + Inches(0.35), by + Inches(0.2),
        Inches(3.3), Inches(0.65), size=19, bold=True, color=col)
    txt(s, body, bx + Inches(0.35), by + Inches(0.9),
        Inches(3.3), Inches(1.5), size=16, color=DGRAY, wrap=True)


# ════════════════════════════════════════════════════════════════
# SLIDE 7 – Drug Treatment (simple table)
# ════════════════════════════════════════════════════════════════
s = prs.slides.add_slide(blank)
bg(s, LIGHT)
header(s, "Drug Treatment — When Lifestyle Is Not Enough", TEAL)

# Simple rule box
rect(s, Inches(0.5), Inches(1.25), Inches(12.3), Inches(0.85), TEAL)
txt(s, "Start drug if:  Stage 2 HTN  OR  Stage 1 + high CV risk  OR  BP not controlled after 3 months",
    Inches(0.6), Inches(1.28), Inches(12.1), Inches(0.8),
    size=16, bold=True, color=WHITE, align=PP_ALIGN.CENTER, anchor=MSO_ANCHOR.MIDDLE)

# 5 drug cards
drugs = [
    ("ACE Inhibitors",    "Enalapril\nRamipril",    "DM, CKD, Heart Failure",    RED),
    ("ARBs",              "Losartan\nValsartan",    "ACEi cough, DM",            ORANGE),
    ("CCBs",              "Amlodipine",             "Elderly, Angina",           TEAL),
    ("Thiazide Diuretics","HCTZ\nChlorthalidone",  "Elderly, Heart Failure",    NAVY),
    ("Beta-Blockers",     "Atenolol\nBisoprolol",   "Post-MI, AF, HF",           RGBColor(0x6C, 0x35, 0x7A)),
]
for i, (cls, ex, use, col) in enumerate(drugs):
    bx = Inches(0.4 + i * 2.5)
    by = Inches(2.3)
    bw = Inches(2.3)
    bh = Inches(4.5)
    rect(s, bx, by, bw, bh, WHITE)
    rect(s, bx, by, bw, Inches(0.5), col)
    txt(s, cls, bx + Inches(0.05), by + Inches(0.04), bw - Inches(0.1), Inches(0.48),
        size=13, bold=True, color=WHITE, align=PP_ALIGN.CENTER, anchor=MSO_ANCHOR.MIDDLE, wrap=True)
    txt(s, ex, bx + Inches(0.1), by + Inches(0.65), bw - Inches(0.15), Inches(1.1),
        size=15, bold=True, color=col, align=PP_ALIGN.CENTER, wrap=True)
    txt(s, "Best for:", bx + Inches(0.1), by + Inches(1.85), bw - Inches(0.15), Inches(0.45),
        size=12, bold=True, color=MGRAY, align=PP_ALIGN.CENTER)
    txt(s, use, bx + Inches(0.1), by + Inches(2.25), bw - Inches(0.15), Inches(1.9),
        size=13, color=DGRAY, align=PP_ALIGN.CENTER, wrap=True)

txt(s, "TARGET:  BP < 140 / 90 mmHg  (< 130/80 in diabetics & CKD)",
    Inches(0.5), Inches(7.05), Inches(12.3), Inches(0.35),
    size=14, bold=True, italic=True, color=RED, align=PP_ALIGN.CENTER)


# ════════════════════════════════════════════════════════════════
# SLIDE 8 – Key Take-Aways
# ════════════════════════════════════════════════════════════════
s = prs.slides.add_slide(blank)
bg(s, NAVY)

# circle decoration
c = s.shapes.add_shape(9, Inches(-1.2), Inches(5.0), Inches(4.5), Inches(4.5))
c.fill.solid(); c.fill.fore_color.rgb = RGBColor(0x00, 0x5F, 0x6E)
c.line.fill.background()

txt(s, "KEY TAKE-AWAYS", Inches(0.5), Inches(0.25), Inches(12.3), Inches(0.9),
    size=38, bold=True, color=WHITE, align=PP_ALIGN.CENTER)
rect(s, Inches(1.8), Inches(1.1), Inches(9.7), Inches(0.08), TEAL)

points = [
    ("1", "Hypertension is the #1 modifiable CV risk factor worldwide.",        TEAL),
    ("2", "Most patients are ASYMPTOMATIC — routine screening is key.",          RED),
    ("3", "Lifestyle changes alone can control Stage 1 HTN.",                    GREEN),
    ("4", "If drugs needed: tailor choice to patient's comorbidities.",          ORANGE),
    ("5", "Target BP < 140/90 mmHg (or < 130/80 in high-risk patients).",       TEAL),
    ("6", "Regular follow-up every 1–3 months until BP is controlled.",          RED),
]
for i, (num, point, col) in enumerate(points):
    by = Inches(1.3 + i * 0.88)
    rect(s, Inches(0.5), by, Inches(0.7), Inches(0.72), col)
    txt(s, num, Inches(0.5), by, Inches(0.7), Inches(0.72),
        size=22, bold=True, color=WHITE, align=PP_ALIGN.CENTER, anchor=MSO_ANCHOR.MIDDLE)
    txt(s, point, Inches(1.35), by + Inches(0.08), Inches(11.4), Inches(0.65),
        size=18, color=WHITE, wrap=True, anchor=MSO_ANCHOR.MIDDLE)

txt(s, "♥   Treat the Patient, Not Just the Number   ♥",
    Inches(1), Inches(6.7), Inches(11.3), Inches(0.6),
    size=17, bold=True, italic=True, color=TEAL, align=PP_ALIGN.CENTER)


# ── Save ────────────────────────────────────────────────────────
out = "/tmp/workspace/hypertension-ppt/Hypertension_Simple_5min.pptx"
prs.save(out)
print(f"Saved → {out}")
print(f"Total slides: {len(prs.slides)}")
Running Command

python /tmp/workspace/hypertension-ppt/create_simple_ppt.py

तैयार है! Download करें:

Hypertension Simple 5min

Presentation · PPTX


नई Simple Version — 8 Slides, 5 Minutes:

SlideTopicTime
1Title Slide20 sec
2Definition + Classification table45 sec
3Risk Factors (2 columns: Change / Can't Change)45 sec
4Symptoms — 4 simple cards + Silent Killer warning45 sec
5Complications — 5 organ cards (Heart, Brain, Kidney, Eyes, Vessels)45 sec
6Lifestyle Modifications — 6 tiles, minimal text45 sec
7Drug Treatment — 5 drug cards, simple45 sec
8Key Take-Aways — 6 numbered points20 sec
क्या बदला:
  • हर slide पर बहुत कम text, बड़े fonts (16-22 pt)
  • Bullet points कम, visual cards ज़्यादा
  • Pathophysiology और Emergency slides हटा दिए
  • हर slide ~30-45 seconds में cover होगी
This is a shared conversation. Sign in to Orris to start your own chat.