Features of contralateral and ipsilateral hemiplegia
corticospinal tract pyramidal decussation hemiplegia diagram
| Location | Weakness Pattern | Distinguishing Features |
|---|---|---|
| Cerebral cortex | Contralateral face + arm + leg (all together only if extensive) | Focal deficits possible (just leg or arm/face); seizures; aphasia (dominant hemisphere); anosognosia; homonymous hemianopia; astereognosis |
| Internal capsule | Contralateral face + arm + leg (dense, all equal) | "Pure motor hemiplegia" (capsular lacune); no cortical signs |
| Midbrain | Contralateral arm + leg + lower face | Weber syndrome: ipsilateral CN III palsy + contralateral hemiplegia (crossed!) |
| Upper pons | Contralateral arm + leg + lower face | Associated CN V, VI, VII palsies ipsilateral |
| Lower pons | Contralateral arm + leg | Millard-Gubler syndrome: ipsilateral CN VI + VII palsy + contralateral hemiplegia |
| Medulla (medial) | Contralateral arm + leg, spares face | Dejerine (medial medullary) syndrome: ipsilateral tongue weakness + contralateral hemiplegia + contralateral hemisensory loss |
| Syndrome | Level | Ipsilateral CN | Contralateral Body |
|---|---|---|---|
| Weber | Midbrain | CN III palsy (ptosis, fixed dilated pupil, down-and-out eye) | Hemiplegia |
| Claude | Midbrain tegmentum | CN III palsy + ataxia | Hemiplegia |
| Millard-Gubler | Lower pons | CN VI + VII palsy | Hemiplegia |
| Foville | Pons | CN VI + ipsilateral conjugate gaze palsy + CN VII | Contralateral hemiplegia |
| Dejerine (medial medullary) | Medulla | Hypoglossal (CN XII) tongue weakness | Hemiplegia + hemisensory loss |
| Raymond | Pons | CN VI palsy | Contralateral hemiplegia |
| Type | Side of Lesion vs. Weakness | Level | Key Clue |
|---|---|---|---|
| Contralateral (cortex/capsule) | Opposite | Supratentorial | Cortical signs, aphasia, seizures |
| Contralateral (brainstem) | Opposite body, same-side CN palsy | Brainstem | Crossed signs |
| Ipsilateral (cervical cord) | Same side, no face | Below decussation | Brown-Sequard pattern |
| Ipsilateral (Kernohan's) | Same side as mass | Uncal herniation | False localizing sign |
Brown Sequard syndrome
Brown Sequard syndrome spinal cord hemisection diagram ipsilateral contralateral deficits
| Tract | Location in cord | Crosses at | Effect of hemisection |
|---|---|---|---|
| Lateral corticospinal tract | Lateral funiculus (ipsilateral) | Already crossed at pyramidal decussation | Ipsilateral UMN weakness below lesion |
| Posterior (dorsal) columns | Posterior funiculus (ipsilateral) | Crosses in medulla (nucleus gracilis/cuneatus) | Ipsilateral loss of proprioception, vibration, 2-point discrimination, tactile localization |
| Spinothalamic tract (anterolateral system) | Anterior/lateral funiculus (contralateral - already crossed) | Crosses at the same spinal cord level (ventral commissure), 2-3 segments above entry | Contralateral loss of pain and temperature, 2-6 segments below lesion |
| Feature | Brown-Séquard | Central Cord | Anterior Cord |
|---|---|---|---|
| Motor loss | Ipsilateral UMN | Arms > legs bilaterally | Bilateral (UMN) |
| Pain/temp loss | Contralateral | Bilateral "suspended" (cape/vest) | Bilateral below lesion |
| Proprioception/vibration | Ipsilateral loss | Preserved | Preserved |
| Cause | Penetrating trauma, MS | Hyperextension in elderly | Anterior spinal artery infarct |
Simple diagram to explain Brown Sequard syndrome
A clean medical educational diagram explaining Brown-Séquard Syndrome (spinal cord hemisection). The diagram shows: 1. At the top: a cross-section of the spinal cord with the LEFT half shaded/lesioned (labeled "Lesion - Left hemisection"). Three tracts are labeled inside: "Lateral Corticospinal Tract (ipsilateral)", "Posterior Columns (ipsilateral)", and "Spinothalamic Tract (already crossed - contralateral)". 2. In the middle: a simple human body outline (front view), split down the middle, with color-coded deficit zones: - LEFT side of body: Red shading labeled "Ipsilateral (LEFT) side: UMN weakness (spasticity, hyperreflexia, Babinski), Loss of proprioception & vibration" - RIGHT side of body: Blue shading labeled "Contralateral (RIGHT) side: Loss of pain & temperature (1-2 dermatomes below lesion)" 3. At the level of lesion: a small yellow band across both sides labeled "At lesion level: LMN signs ipsilaterally + narrow band of ipsilateral pain/temp loss" 4. A small legend box in the corner: Red = Ipsilateral motor + dorsal column loss, Blue = Contralateral spinothalamic loss 5. Title at top: "Brown-Séquard Syndrome" with subtitle "Spinal Cord Hemisection" Clean white background, medical textbook style, clear labels, simple arrows showing tract pathways.

Create a downloadable PDF summary of Brown-Séquard Syndrome for reference
ls -la /tmp/workspace/ 2>/dev/null || mkdir -p /tmp/workspace && echo "workspace ready"
mkdir -p /tmp/workspace/bss-pdf && python3 << 'EOF' from reportlab.lib.pagesizes import A4 from reportlab.lib import colors from reportlab.lib.styles import getSampleStyleSheet, ParagraphStyle from reportlab.lib.units import cm, mm from reportlab.platypus import SimpleDocTemplate, Paragraph, Spacer, Table, TableStyle, HRFlowable, KeepTogether from reportlab.lib.enums import TA_CENTER, TA_LEFT, TA_JUSTIFY from reportlab.platypus import Image import urllib.request, os # Download the diagram image img_url = "https://cdn.orris.care/image-gen/d72a506e8ccb4f67a9d37049f9922a8a.png" img_path = "/tmp/workspace/bss-pdf/bss_diagram.png" urllib.request.urlretrieve(img_url, img_path) print("Image downloaded:", os.path.exists(img_path)) EOF
~/bss-pdf/generate_bss_pdf.py
from reportlab.lib.pagesizes import A4
from reportlab.lib import colors
from reportlab.lib.styles import getSampleStyleSheet, ParagraphStyle
from reportlab.lib.units import cm, mm
from reportlab.platypus import (SimpleDocTemplate, Paragraph, Spacer, Table,
TableStyle, HRFlowable, KeepTogether, Image)
from reportlab.lib.enums import TA_CENTER, TA_LEFT, TA_JUSTIFY
from reportlab.pdfbase import pdfmetrics
from reportlab.pdfbase.ttfonts import TTFont
OUTPUT = "/tmp/workspace/bss-pdf/Brown_Sequard_Syndrome.pdf"
IMG_PATH = "/tmp/workspace/bss-pdf/bss_diagram.png"
# ── Colours ──────────────────────────────────────────────────────────────────
NAVY = colors.HexColor("#1a3a5c")
TEAL = colors.HexColor("#0f7173")
RED = colors.HexColor("#c0392b")
BLUE = colors.HexColor("#2471a3")
ORANGE = colors.HexColor("#d35400")
LBLUE = colors.HexColor("#d6eaf8")
LRED = colors.HexColor("#fadbd8")
LYELLOW = colors.HexColor("#fef9e7")
LGREY = colors.HexColor("#f2f3f4")
WHITE = colors.white
BLACK = colors.black
doc = SimpleDocTemplate(
OUTPUT,
pagesize=A4,
leftMargin=1.8*cm, rightMargin=1.8*cm,
topMargin=1.5*cm, bottomMargin=1.8*cm,
title="Brown-Séquard Syndrome – Clinical Reference",
author="Orris Medical AI"
)
W, H = A4
CW = W - 3.6*cm # content width
styles = getSampleStyleSheet()
# ── Custom styles ─────────────────────────────────────────────────────────────
def S(name, **kw):
return ParagraphStyle(name, **kw)
title_style = S("Title2", fontSize=20, textColor=WHITE,
alignment=TA_CENTER, fontName="Helvetica-Bold",
spaceAfter=2, leading=24)
subtitle_style = S("Sub", fontSize=11, textColor=colors.HexColor("#d0e8f5"),
alignment=TA_CENTER, fontName="Helvetica", spaceAfter=0)
h1 = S("H1", fontSize=13, textColor=WHITE, fontName="Helvetica-Bold",
spaceAfter=3, leading=16, leftIndent=6)
h2 = S("H2", fontSize=11, textColor=NAVY, fontName="Helvetica-Bold",
spaceBefore=8, spaceAfter=3, leading=14)
body = S("Body2", fontSize=9.5, textColor=BLACK, fontName="Helvetica",
leading=14, spaceAfter=3, alignment=TA_JUSTIFY)
bullet = S("Bullet2", fontSize=9.5, textColor=BLACK, fontName="Helvetica",
leading=14, spaceAfter=2, leftIndent=14, firstLineIndent=-10)
small = S("Small", fontSize=8.5, textColor=colors.HexColor("#555555"),
fontName="Helvetica-Oblique", leading=12, alignment=TA_CENTER)
note_style = S("Note", fontSize=8.5, textColor=colors.HexColor("#444444"),
fontName="Helvetica-Oblique", leading=12, spaceAfter=2)
def bull(text, color=BLACK):
return Paragraph(f"• {text}", bullet)
def section_header(title, bg=TEAL):
data = [[Paragraph(title, h1)]]
t = Table(data, colWidths=[CW])
t.setStyle(TableStyle([
("BACKGROUND", (0,0), (-1,-1), bg),
("TOPPADDING", (0,0), (-1,-1), 5),
("BOTTOMPADDING", (0,0), (-1,-1), 5),
("LEFTPADDING", (0,0), (-1,-1), 8),
("ROUNDEDCORNERS", [4]),
]))
return t
# ── Build story ───────────────────────────────────────────────────────────────
story = []
# ── Title block ───────────────────────────────────────────────────────────────
title_data = [[Paragraph("Brown-Séquard Syndrome", title_style)],
[Paragraph("Spinal Cord Hemisection | Clinical Reference Summary", subtitle_style)]]
title_tbl = Table(title_data, colWidths=[CW])
title_tbl.setStyle(TableStyle([
("BACKGROUND", (0,0), (-1,-1), NAVY),
("TOPPADDING", (0,0), (-1,-1), 12),
("BOTTOMPADDING", (0,0), (-1,-1), 12),
("ROUNDEDCORNERS", [6]),
]))
story.append(title_tbl)
story.append(Spacer(1, 10))
# ── Definition ────────────────────────────────────────────────────────────────
story.append(section_header("Definition"))
story.append(Spacer(1, 4))
story.append(Paragraph(
"Brown-Séquard Syndrome (BSS) results from <b>hemisection (damage to one lateral half) of the "
"spinal cord</b>. It produces a characteristic <b>dissociated sensorimotor deficit</b>: "
"motor loss and one class of sensory loss <b>ipsilateral</b> to the lesion, "
"and a different sensory modality lost <b>contralaterally</b>.",
body))
story.append(Paragraph(
"BSS accounts for <b>1–4%</b> of all traumatic spinal cord injuries and most commonly "
"occurs at the <b>cervical spine</b>.",
body))
story.append(Spacer(1, 6))
# ── Diagram ───────────────────────────────────────────────────────────────────
story.append(section_header("Diagram – Tract Deficits in BSS"))
story.append(Spacer(1, 4))
img = Image(IMG_PATH, width=CW*0.88, height=CW*0.62)
img.hAlign = "CENTER"
story.append(img)
story.append(Paragraph("Figure: Cross-section of cord (left hemisection) showing ipsilateral vs. contralateral deficits.", small))
story.append(Spacer(1, 6))
# ── Anatomical basis ──────────────────────────────────────────────────────────
story.append(section_header("Anatomical Basis – Three Key Tracts"))
story.append(Spacer(1, 4))
tract_data = [
[Paragraph("<b>Tract</b>", S("th", fontSize=9, textColor=WHITE, fontName="Helvetica-Bold", leading=12)),
Paragraph("<b>Location</b>", S("th", fontSize=9, textColor=WHITE, fontName="Helvetica-Bold", leading=12)),
Paragraph("<b>Where it crosses</b>", S("th", fontSize=9, textColor=WHITE, fontName="Helvetica-Bold", leading=12)),
Paragraph("<b>Deficit after hemisection</b>", S("th", fontSize=9, textColor=WHITE, fontName="Helvetica-Bold", leading=12))],
[Paragraph("Lateral Corticospinal", S("tc", fontSize=8.5, fontName="Helvetica", leading=12)),
Paragraph("Lateral funiculus (ipsilateral)", S("tc", fontSize=8.5, fontName="Helvetica", leading=12)),
Paragraph("Pyramidal decussation (medulla) – already crossed", S("tc", fontSize=8.5, fontName="Helvetica", leading=12)),
Paragraph("<b>Ipsilateral</b> UMN weakness", S("tc", fontSize=8.5, fontName="Helvetica-Bold", textColor=RED, leading=12))],
[Paragraph("Posterior Columns", S("tc", fontSize=8.5, fontName="Helvetica", leading=12)),
Paragraph("Posterior funiculus (ipsilateral)", S("tc", fontSize=8.5, fontName="Helvetica", leading=12)),
Paragraph("Nucleus gracilis/cuneatus in medulla – already crossed", S("tc", fontSize=8.5, fontName="Helvetica", leading=12)),
Paragraph("<b>Ipsilateral</b> loss of proprioception, vibration, 2-point discrimination", S("tc", fontSize=8.5, fontName="Helvetica-Bold", textColor=RED, leading=12))],
[Paragraph("Spinothalamic Tract", S("tc", fontSize=8.5, fontName="Helvetica", leading=12)),
Paragraph("Anterolateral funiculus (contralateral – already crossed)", S("tc", fontSize=8.5, fontName="Helvetica", leading=12)),
Paragraph("Crosses within cord at same/adjacent level via ventral commissure", S("tc", fontSize=8.5, fontName="Helvetica", leading=12)),
Paragraph("<b>Contralateral</b> loss of pain & temperature (1–2 dermatomes below)", S("tc", fontSize=8.5, fontName="Helvetica-Bold", textColor=BLUE, leading=12))],
]
col_w = [CW*0.18, CW*0.22, CW*0.32, CW*0.28]
tract_tbl = Table(tract_data, colWidths=col_w, repeatRows=1)
tract_tbl.setStyle(TableStyle([
("BACKGROUND", (0,0), (-1,0), TEAL),
("BACKGROUND", (0,1), (-1,1), LRED),
("BACKGROUND", (0,2), (-1,2), LRED),
("BACKGROUND", (0,3), (-1,3), LBLUE),
("GRID", (0,0), (-1,-1), 0.4, colors.HexColor("#cccccc")),
("VALIGN", (0,0), (-1,-1), "TOP"),
("TOPPADDING", (0,0), (-1,-1), 5),
("BOTTOMPADDING", (0,0), (-1,-1), 5),
("LEFTPADDING", (0,0), (-1,-1), 5),
("RIGHTPADDING", (0,0), (-1,-1), 5),
]))
story.append(tract_tbl)
story.append(Spacer(1, 6))
# ── Clinical features two-column ──────────────────────────────────────────────
story.append(section_header("Clinical Features"))
story.append(Spacer(1, 4))
ipsi_items = [
"<b>UMN hemiplegia/hemiparesis</b> – spasticity, hyperreflexia, Babinski sign",
"Loss of <b>proprioception</b> (joint position sense)",
"Loss of <b>vibration sense</b>",
"Loss of <b>2-point discrimination</b> and tactile localisation",
"Partial loss of crude light touch",
"(At C8–T2) <b>Ipsilateral Horner syndrome</b> – ptosis, miosis, anhidrosis",
]
contra_items = [
"Loss of <b>pain sensation</b>",
"Loss of <b>temperature sensation</b>",
"Onset <b>1–2 dermatomes below</b> the lesion level",
"Crude touch largely <b>preserved</b>",
]
at_level_items = [
"<b>LMN signs ipsilaterally</b> – flaccid weakness, wasting, areflexia (anterior horn)",
"Narrow ipsilateral band of <b>pain/temp loss</b> (posterior horn damage before fibres cross)",
"Zone of <b>hyperalgesia</b> just above lesion (dorsal root zone irritation)",
]
def feature_box(title, items, bg, tc):
content = [Paragraph(f"<b>{title}</b>", S("bh", fontSize=9.5, textColor=WHITE,
fontName="Helvetica-Bold", leading=13, alignment=TA_CENTER))]
for i in items:
content.append(Paragraph(f"• {i}", S("bi", fontSize=8.5, textColor=BLACK,
fontName="Helvetica", leading=13, leftIndent=6, spaceAfter=2)))
tbl = Table([[c] for c in content], colWidths=[(CW-10)/2])
tbl.setStyle(TableStyle([
("BACKGROUND", (0,0), (-1,0), tc),
("BACKGROUND", (0,1), (-1,-1), bg),
("TOPPADDING", (0,0), (-1,-1), 5),
("BOTTOMPADDING", (0,0), (-1,-1), 4),
("LEFTPADDING", (0,0), (-1,-1), 7),
("RIGHTPADDING", (0,0), (-1,-1), 7),
("BOX", (0,0), (-1,-1), 0.6, tc),
]))
return tbl
ipsi_box = feature_box("IPSILATERAL (same side as lesion) – below lesion", ipsi_items, LRED, RED)
contra_box = feature_box("CONTRALATERAL (opposite side) – below lesion", contra_items, LBLUE, BLUE)
side_tbl = Table([[ipsi_box, Spacer(10, 1), contra_box]],
colWidths=[(CW-10)/2, 10, (CW-10)/2])
side_tbl.setStyle(TableStyle([
("VALIGN", (0,0), (-1,-1), "TOP"),
("TOPPADDING", (0,0), (-1,-1), 0),
("BOTTOMPADDING", (0,0), (-1,-1), 0),
("LEFTPADDING", (0,0), (-1,-1), 0),
("RIGHTPADDING", (0,0), (-1,-1), 0),
]))
story.append(side_tbl)
story.append(Spacer(1, 5))
# At-level box
at_level_box = feature_box("AT THE LEVEL OF LESION (ipsilateral)", at_level_items,
LYELLOW, ORANGE)
story.append(at_level_box)
story.append(Spacer(1, 6))
# ── Causes ────────────────────────────────────────────────────────────────────
story.append(section_header("Causes / Aetiology"))
story.append(Spacer(1, 4))
cause_data = [
[Paragraph("<b>Traumatic (most common)</b>", S("ch", fontSize=9.5, textColor=WHITE,
fontName="Helvetica-Bold", leading=12)),
Paragraph("<b>Non-traumatic</b>", S("ch", fontSize=9.5, textColor=WHITE,
fontName="Helvetica-Bold", leading=12))],
[Paragraph(
"• Penetrating injury – stab wounds (most common overall)\n"
"• Blunt trauma – hyperextension > flexion injuries\n"
"• Herniated cervical disc (lateral)\n"
"• Vertebral fracture-dislocation\n"
"• Compression injuries",
S("cb", fontSize=8.5, fontName="Helvetica", leading=14)),
Paragraph(
"• Multiple sclerosis (demyelinating plaques)\n"
"• Spinal cord tumours – primary or metastatic\n"
"• Spinal cord ischaemia / epidural haematoma\n"
"• Hematomyelia\n"
"• Posttraumatic / infectious arachnoiditis\n"
"• Spinal subdural haematoma\n"
"• Spinal cord herniation",
S("cb", fontSize=8.5, fontName="Helvetica", leading=14))],
]
cause_tbl = Table(cause_data, colWidths=[CW/2, CW/2])
cause_tbl.setStyle(TableStyle([
("BACKGROUND", (0,0), (-1,0), NAVY),
("BACKGROUND", (0,1), (0,1), LGREY),
("BACKGROUND", (1,1), (1,1), colors.HexColor("#eafaf1")),
("GRID", (0,0), (-1,-1), 0.4, colors.HexColor("#aaaaaa")),
("VALIGN", (0,0), (-1,-1), "TOP"),
("TOPPADDING", (0,0), (-1,-1), 6),
("BOTTOMPADDING", (0,0), (-1,-1), 6),
("LEFTPADDING", (0,0), (-1,-1), 8),
]))
story.append(cause_tbl)
story.append(Spacer(1, 6))
# ── BSS Plus ──────────────────────────────────────────────────────────────────
story.append(section_header("Brown-Séquard Plus Syndrome", bg=colors.HexColor("#6c3483")))
story.append(Spacer(1, 4))
story.append(Paragraph(
"The <b>pure classic</b> form is rarely encountered clinically. More commonly, "
"patients present with <b>Brown-Séquard Plus</b> (Taylor & Gleave, 1957):",
body))
story.append(bull("Asymmetrical hemiplegia rather than complete unilateral paralysis"))
story.append(bull("Hypoalgesia more prominent on the <i>less</i> paretic side"))
story.append(bull("Mixed/incomplete pattern of deficits"))
story.append(Paragraph(
"<b>Prognosis note:</b> Paradoxically, pure BSS carries a <i>worse prognosis</i> than "
"BSS Plus. Overall, BSS has the <b>best functional motor recovery</b> of all incomplete "
"spinal cord syndromes. Most patients regain ambulatory function and bowel/bladder "
"continence.",
body))
story.append(Spacer(1, 6))
# ── Comparison table ──────────────────────────────────────────────────────────
story.append(section_header("Comparison with Other Incomplete Cord Syndromes"))
story.append(Spacer(1, 4))
comp_data = [
[Paragraph("<b>Feature</b>", S("t", fontSize=9, textColor=WHITE, fontName="Helvetica-Bold")),
Paragraph("<b>Brown-Séquard</b>", S("t", fontSize=9, textColor=WHITE, fontName="Helvetica-Bold")),
Paragraph("<b>Central Cord</b>", S("t", fontSize=9, textColor=WHITE, fontName="Helvetica-Bold")),
Paragraph("<b>Anterior Cord</b>", S("t", fontSize=9, textColor=WHITE, fontName="Helvetica-Bold")),
Paragraph("<b>Posterior Cord</b>", S("t", fontSize=9, textColor=WHITE, fontName="Helvetica-Bold"))],
["Motor loss",
"Ipsilateral UMN",
"Arms > legs bilaterally",
"Bilateral UMN (below)",
"Mild or none"],
["Pain/Temp",
"Contralateral loss",
"Bilateral suspended 'cape'",
"Bilateral loss below",
"Preserved"],
["Proprioception/Vibration",
"Ipsilateral loss",
"Preserved",
"Preserved",
"Bilateral loss"],
["Common cause",
"Penetrating trauma, MS",
"Hyperextension (elderly)",
"Anterior spinal artery infarct",
"Posterior cord ischaemia"],
["Prognosis",
"Best of all incomplete",
"Good – arms worse than legs",
"Variable",
"Good"],
]
cw2 = [CW*0.16, CW*0.20, CW*0.20, CW*0.22, CW*0.22]
comp_tbl = Table(comp_data, colWidths=cw2)
comp_tbl.setStyle(TableStyle([
("BACKGROUND", (0,0), (-1,0), TEAL),
("ROWBACKGROUNDS",(0,1), (-1,-1), [WHITE, LGREY]),
("GRID", (0,0), (-1,-1), 0.4, colors.HexColor("#bbbbbb")),
("FONTNAME", (0,0), (-1,0), "Helvetica-Bold"),
("FONTSIZE", (0,0), (-1,-1), 8.5),
("VALIGN", (0,0), (-1,-1), "TOP"),
("TOPPADDING", (0,0), (-1,-1), 5),
("BOTTOMPADDING", (0,0), (-1,-1), 5),
("LEFTPADDING", (0,0), (-1,-1), 5),
("FONTNAME", (0,1), (0,-1), "Helvetica-Bold"),
]))
story.append(comp_tbl)
story.append(Spacer(1, 8))
# ── Memory Aid ────────────────────────────────────────────────────────────────
story.append(section_header("Memory Aid", bg=colors.HexColor("#1a6b3a")))
story.append(Spacer(1, 4))
mem_data = [[
Paragraph(
"<b>\"Same side – Motor and Posterior column loss\"</b><br/>"
"Motor weakness + proprioception/vibration → <b>IPSILATERAL</b>",
S("m", fontSize=9.5, textColor=BLACK, fontName="Helvetica", leading=14)),
Paragraph(
"<b>\"Opposite side – Pain and Temperature\"</b><br/>"
"Pain and temperature loss → <b>CONTRALATERAL</b> (1–2 levels below)",
S("m", fontSize=9.5, textColor=BLACK, fontName="Helvetica", leading=14)),
]]
mem_tbl = Table(mem_data, colWidths=[CW/2, CW/2])
mem_tbl.setStyle(TableStyle([
("BACKGROUND", (0,0), (0,0), colors.HexColor("#d5f5e3")),
("BACKGROUND", (1,0), (1,0), colors.HexColor("#d6eaf8")),
("BOX", (0,0), (-1,-1), 0.6, colors.HexColor("#1a6b3a")),
("GRID", (0,0), (-1,-1), 0.4, colors.HexColor("#aaaaaa")),
("TOPPADDING", (0,0), (-1,-1), 8),
("BOTTOMPADDING", (0,0), (-1,-1), 8),
("LEFTPADDING", (0,0), (-1,-1), 10),
]))
story.append(mem_tbl)
story.append(Spacer(1, 8))
# ── Footer ────────────────────────────────────────────────────────────────────
story.append(HRFlowable(width=CW, thickness=0.5, color=colors.HexColor("#aaaaaa")))
story.append(Spacer(1, 3))
story.append(Paragraph(
"Sources: Adams & Victor's Principles of Neurology 12e · Bradley and Daroff's Neurology in Clinical Practice · "
"Neuroanatomy through Clinical Cases 3e · Guyton & Hall Medical Physiology · "
"Localization in Clinical Neurology 8e · Tintinalli's Emergency Medicine | "
"Generated by Orris Medical AI · August 2026",
S("foot", fontSize=7, textColor=colors.HexColor("#888888"), fontName="Helvetica-Oblique",
alignment=TA_CENTER, leading=10)))
# ── Build ─────────────────────────────────────────────────────────────────────
doc.build(story)
print("PDF created successfully at", OUTPUT)
python3 /tmp/workspace/bss-pdf/generate_bss_pdf.py
ls -lh /tmp/workspace/bss-pdf/Brown_Sequard_Syndrome.pdf
Brown Sequard Syndrome
PDF Document · PDF