How to take history in gyne and obs

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

History Taking in Obstetrics and Gynecology

History taking in O&G follows the general medical history framework but with specific reproductive, menstrual, and obstetric elements woven in. Here's a structured approach:

1. Biodata

Name, age, marital status, occupation, religion (relevant for some cultural/consanguinity practices), and address.

2. Chief Complaint(s)

In the patient's own words, with duration (e.g., "bleeding per vagina x 3 days", "amenorrhea x 2 months", "labor pains x 6 hours").

3. Menstrual History

  • Age at menarche
  • Cycle length and regularity (e.g., 28-30 days, regular/irregular)
  • Duration and amount of flow (number of pads/day, presence of clots)
  • Dysmenorrhea (pain with periods)
  • Date of Last Menstrual Period (LMP) - critical for calculating gestational age and Expected Date of Delivery (EDD) using Naegele's rule: LMP + 7 days - 3 months (+1 year)
  • Age at menopause if applicable, and method (natural, surgical, drug-induced)
  • Intermenstrual or postmenopausal bleeding/spotting
According to Schwartz's Principles of Surgery, the key elements of a focused gynecologic history include date of LMP, contraceptive/hormone use history, obstetric history, age at menarche/menopause, menstrual bleeding pattern, cervical screening history, history of pelvic infections, sexual history, and prior gynecologic surgeries - Schwartz's Principles of Surgery, p. 1815.

4. Obstetric History

This is documented using the Gravida-Para (GPA) formula:
  • Gravida (G): total number of pregnancies, including the current one
  • Para (P): often expanded as a 4-digit formula - TPAL
    • T = Term deliveries
    • P = Preterm deliveries
    • A = Abortions (spontaneous or induced) / ectopic pregnancies
    • L = Living children
For each previous pregnancy, record:
  • Year and place of delivery
  • Mode of delivery (vaginal, instrumental, cesarean - and indication if cesarean)
  • Gestational age at delivery
  • Birth weight and sex of baby, and current status of the child
  • Antenatal, intranatal, or postnatal complications (pre-eclampsia, gestational diabetes, PPH, etc.)
  • Any pregnancy losses (miscarriage, stillbirth, ectopic, termination) with gestational age and management
For the current pregnancy (if applicable):
  • LMP and calculated EDD/gestational age
  • Confirmation of pregnancy (urine/serum bCG, ultrasound dating - especially first-trimester dating scan)
  • Booking visit details, antenatal visits, and investigations done
  • Symptoms: nausea/vomiting, fetal movements (quickening), bleeding, leaking, contractions
  • Any high-risk factors identified (hypertension, diabetes, anemia, previous cesarean, etc.)
  • Immunizations (tetanus, Rh status if Rh-negative - anti-D given?)

5. Contraceptive History

Current and past methods used, duration, side effects, reason for discontinuation, and pregnancy intention.

6. Sexual History

Age at first intercourse, number of partners, dyspareunia, protection use - handled sensitively and non-judgmentally, as it guides STI risk assessment and testing.

7. Past Gynecological History

  • History of vaginal discharge, pelvic pain, or infections (including HPV/HIV status)
  • Cervical cytology (Pap smear) history - frequency and results
  • Prior gynecological surgeries (D&C, myomectomy, hysterectomy, tubal surgery, etc.)
  • History of infertility and any treatment

8. Past Medical and Surgical History

Chronic illnesses (diabetes, hypertension, thyroid disease, cardiac disease, epilepsy, thromboembolic disease), previous surgeries, hospitalizations, and blood transfusions.

9. Drug and Allergy History

Current medications (including herbal/OTC), known drug allergies, and any teratogenic exposures if pregnant.

10. Family History

Twin pregnancies, congenital anomalies, hereditary conditions, hypertension, diabetes, and any familial cancers (breast, ovarian, endometrial - relevant to gynecologic oncology risk).

11. Personal and Social History

Diet, smoking, alcohol, substance use, occupation (exposure risks), and psychosocial support - important for both general health and issues like domestic violence screening, which should be asked about privately.

Quick reference table (adapted from Schwartz's Principles of Surgery, p. 1815)

ElementWhat to exploreWhy it matters
Menstrual historyMenarche, menopause, bleeding pattern, meds affecting bleedingEndocrine, structural, infectious, oncologic clues
Obstetric historyNumber of pregnancies, dates, delivery type, losses, complicationsPredisposes to certain conditions (e.g., gestational trophoblastic disease), surgical risk
Sexual historyPartners, practices, protection, pregnancy intentionSTI risk, testing sites, counseling
Contraceptive historyCurrent/past use, type, durationPregnancy risk during procedures, side effects
Cytologic screeningFrequency, resultsCervical cancer screening status
This structure applies whether the setting is a routine antenatal visit, a gynecology outpatient consult, or an emergency presentation (labor, bleeding, pain) - though in acute/emergency settings you prioritize the presenting complaint and focused relevant history first, then fill in the rest once the patient is stable.
Would you like me to go deeper into any specific part - for example, a detailed antenatal history-taking checklist, how to calculate the obstetric score (GPA/TPAL) with examples, or history taking for a specific complaint like abnormal uterine bleeding or infertility?

Can you provide me some hand writin pod notes to help me in documenting my version in opd

Finding Sources
No dedicated proforma sections came up in the library search, so here's a practical, standard shorthand template you can use for quick OPD documentation - based on conventional clinical charting practice.

Quick OPD Note Templates (Handwritten Shorthand)

A. Gynecology OPD Note

Name/Age:                    Date:
C/O (Chief complaint):       ______ x ___ days

MENSTRUAL Hx:
  Menarche: __yrs   LMP: __/__/__   Cycle: __/__ (regular/irreg)
  Flow: nl/exc/scanty   Clots: Y/N   Dysmenorrhea: Y/N
  Menopause: __yrs (if applicable)

OBS Hx:  G_P_L_A_   (Gravida/Para/Living/Abortion)
  Mode of delivery(s): ____   Last delivery: __ yrs ago

CONTRACEPTION:  current method: ____   duration: ____

SEXUAL Hx:  active/not active   partners: __   dyspareunia: Y/N

PAST GYNAE Hx:  Pap smear - date/result: ____
  Prior surgery: ____   Infections/STI: ____

P/M Hx (Past medical): DM/HTN/Thyroid/TB - circle if present
DRUG Hx: ____        ALLERGY: ____
FAMILY Hx: ____ (breast/ovarian ca, DM, HTN)

O/E:
  GC: ____  P: __  BP: __/__  Pallor: +/-
  P/A: soft/tender, mass ___, organomegaly
  P/S (speculum): cervix - healthy/erosion/discharge
  P/V (bimanual): uterus - size/pos/mobility, adnexa - free/tender/mass

Provisional Dx: ____
Plan: Investigations / Rx / Follow-up

B. Obstetric (Antenatal) OPD Note

Name/Age:                    Date:
G_P_L_A_    LMP: __/__/__    EDD: __/__/__ (Naegele's rule)
POG (period of gestation) today: __ wks __ days (by dates/USG)

C/O: ____ (fetal movements, pain, leaking, bleeding, swelling)

CURRENT PREGNANCY:
  Booking visit: __ wks    ANC visits: __
  USG dating: __ wks (if differs from LMP, use USG dates)
  Complications so far: PIH/GDM/Anemia/PROM/none
  Immunization: TT1/TT2 done   Anti-D given (if Rh-neg): Y/N

PAST OBS Hx (for each pregnancy):
  Yr | POG at delivery | Mode | Wt | Sex | Complication | Outcome
  ___|________________|______|____|_____|______________|________

PAST MEDICAL/SURGICAL Hx: ____
DRUG/ALLERGY Hx: ____
FAMILY Hx: ____

O/E:
  GC: ____  P: __  BP: __/__  Wt: __ kg  Ht: __ cm  Pallor/Edema: +/-
  P/A: FH (fundal height) = __ wks   FHS (fetal heart sounds): +/reg __ bpm
       Presentation: ceph/breech/transverse    Lie: long/oblique/transverse
       Engagement: __/5th   Liquor: adequate/reduced (clinical)

Investigations: Hb, urine R/M, BSL, USG, others: ____

Provisional Dx: ____ (e.g., G2P1L1 at __ wks with ____)
Plan: ____

Handy Abbreviation Key (for fast writing)

  • G/P/L/A = Gravida / Para / Living / Abortion
  • LMP / EDD = Last Menstrual Period / Expected Date of Delivery
  • POG = Period of Gestation
  • FH / FHS = Fundal Height / Fetal Heart Sounds
  • P/A, P/S, P/V = Per Abdomen, Per Speculum, Per Vaginum
  • PIH, GDM, PROM = Pregnancy-Induced HTN, Gestational Diabetes, Premature Rupture of Membranes
  • C/O = Complains of; O/E = On Examination
  • Ceph/Breech = Cephalic/Breech presentation
Tip for OPD speed: pre-print or stamp this skeleton on your case sheets so you only fill blanks instead of writing headers each time - most residents keep a rubber stamp or a printed proforma exactly in this G_P_L_A_ / LMP-EDD-POG format for obstetric OPD, and the menstrual/obstetric/contraceptive/sexual/past-gynae block for gynecology OPD.
Want me to generate this as a printable one-page PDF or Word template (with fill-in blanks) that you can physically print and use as a stamp/checklist in clinic?

All of above

Reading File
Reading File
Running Command

mkdir -p /tmp/workspace/opd-notes-template && ls -la /tmp/workspace/

Writing File

~/opd-notes-template/make_docx.py

from docx import Document
from docx.shared import Pt, Inches, RGBColor
from docx.enum.text import WD_ALIGN_PARAGRAPH
from docx.enum.table import WD_TABLE_ALIGNMENT
from docx.oxml.ns import qn
from docx.oxml import OxmlElement

def set_cell_border(cell):
    tc = cell._tc
    tcPr = tc.get_or_add_tcPr()
    tcBorders = OxmlElement('w:tcBorders')
    for edge in ('top', 'left', 'bottom', 'right'):
        el = OxmlElement(f'w:{edge}')
        el.set(qn('w:val'), 'single')
        el.set(qn('w:sz'), '4')
        el.set(qn('w:space'), '0')
        el.set(qn('w:color'), '999999')
        tcBorders.append(el)
    tcPr.append(tcBorders)

doc = Document()

# margins
section = doc.sections[0]
section.top_margin = Inches(0.5)
section.bottom_margin = Inches(0.5)
section.left_margin = Inches(0.6)
section.right_margin = Inches(0.6)

style = doc.styles["Normal"]
style.font.name = "Arial"
style.font.size = Pt(10.5)

def add_title(text, subtitle=None):
    h = doc.add_paragraph()
    h.alignment = WD_ALIGN_PARAGRAPH.CENTER
    run = h.add_run(text)
    run.bold = True
    run.font.size = Pt(16)
    if subtitle:
        s = doc.add_paragraph()
        s.alignment = WD_ALIGN_PARAGRAPH.CENTER
        r2 = s.add_run(subtitle)
        r2.italic = True
        r2.font.size = Pt(10)
        r2.font.color.rgb = RGBColor(0x55, 0x55, 0x55)

def add_section_heading(text):
    p = doc.add_paragraph()
    p.paragraph_format.space_before = Pt(8)
    p.paragraph_format.space_after = Pt(2)
    run = p.add_run(text)
    run.bold = True
    run.font.size = Pt(11.5)
    run.font.color.rgb = RGBColor(0x1F, 0x4E, 0x79)
    pPr = p._p.get_or_add_pPr()
    shd = OxmlElement('w:shd')
    shd.set(qn('w:val'), 'clear')
    shd.set(qn('w:fill'), 'DCE6F1')
    pPr.append(shd)

def blank_line(label, width_chars=28):
    p = doc.add_paragraph()
    p.paragraph_format.space_after = Pt(3)
    r1 = p.add_run(label + ": ")
    r1.bold = True
    r1.font.size = Pt(10.5)
    r2 = p.add_run("_" * width_chars)
    r2.font.size = Pt(10.5)
    return p

def two_col_blank(label1, w1, label2, w2):
    p = doc.add_paragraph()
    p.paragraph_format.space_after = Pt(3)
    r1 = p.add_run(label1 + ": ")
    r1.bold = True
    r2 = p.add_run("_" * w1 + "     ")
    r3 = p.add_run(label2 + ": ")
    r3.bold = True
    r4 = p.add_run("_" * w2)
    for r in (r1, r2, r3, r4):
        r.font.size = Pt(10.5)

def checkbox_line(label, options):
    p = doc.add_paragraph()
    p.paragraph_format.space_after = Pt(3)
    r1 = p.add_run(label + ": ")
    r1.bold = True
    r1.font.size = Pt(10.5)
    r2 = p.add_run("   ".join([f"\u2610 {o}" for o in options]))
    r2.font.size = Pt(10.5)

def add_table(headers, nrows, col_widths=None):
    t = doc.add_table(rows=nrows+1, cols=len(headers))
    t.alignment = WD_TABLE_ALIGNMENT.CENTER
    for j, htext in enumerate(headers):
        cell = t.rows[0].cells[j]
        cell.text = ""
        run = cell.paragraphs[0].add_run(htext)
        run.bold = True
        run.font.size = Pt(9.5)
        set_cell_border(cell)
        shd = OxmlElement('w:shd')
        shd.set(qn('w:val'), 'clear')
        shd.set(qn('w:fill'), 'F2F2F2')
        cell._tc.get_or_add_tcPr().append(shd)
    for i in range(1, nrows+1):
        for j in range(len(headers)):
            cell = t.rows[i].cells[j]
            cell.text = ""
            cell.paragraphs[0].add_run(" ")
            set_cell_border(cell)
    if col_widths:
        for row in t.rows:
            for j, w in enumerate(col_widths):
                row.cells[j].width = Inches(w)
    return t

def footer_note():
    p = doc.add_paragraph()
    p.paragraph_format.space_before = Pt(6)
    r = p.add_run("Provisional Diagnosis: " + "_"*55)
    r.bold = True
    r.font.size = Pt(10.5)
    p2 = doc.add_paragraph()
    r2 = p2.add_run("Plan / Advice / Rx: ")
    r2.bold = True
    r2.font.size = Pt(10.5)
    p2.add_run("_"*60).font.size = Pt(10.5)
    for _ in range(3):
        p3 = doc.add_paragraph("_" * 95)
        p3.paragraph_format.space_after = Pt(2)
    p4 = doc.add_paragraph()
    r4 = p4.add_run("Doctor's Signature: " + "_"*25 + "        Next visit: " + "_"*15)
    r4.font.size = Pt(10.5)

# ============ PAGE 1: GYNECOLOGY OPD NOTE ============
add_title("GYNECOLOGY OPD NOTE", "Quick documentation template")

p = doc.add_paragraph()
run = p.add_run("Name: " + "_"*30 + "   Age: " + "_"*6 + "   Date: " + "_"*15)
run.font.size = Pt(10.5)
p2 = doc.add_paragraph()
p2.add_run("Marital status: " + "_"*10 + "    Occupation: " + "_"*15 + "    Reg. No: " + "_"*12).font.size = Pt(10.5)

add_section_heading("Chief Complaint(s)")
for _ in range(2):
    doc.add_paragraph("_" * 100).paragraph_format.space_after = Pt(2)

add_section_heading("Menstrual History")
two_col_blank("Menarche (yrs)", 6, "LMP", 12)
two_col_blank("Cycle length/duration", 10, "Flow (nl/exc/scanty)", 10)
checkbox_line("Dysmenorrhea", ["Yes", "No"])
two_col_blank("Menopause (yrs, if any)", 10, "IMB/PMB", 12)

add_section_heading("Obstetric History")
p = doc.add_paragraph()
r1 = p.add_run("G ___ P ___ L ___ A ___   ")
r1.bold = True
r1.font.size = Pt(11)
r2 = p.add_run("(Gravida / Para / Living / Abortion)")
r2.italic = True
r2.font.size = Pt(9)
two_col_blank("Mode of last delivery", 15, "Last delivery (yrs ago)", 8)

add_section_heading("Contraception & Sexual History")
two_col_blank("Current method", 12, "Duration", 10)
checkbox_line("Sexually active", ["Yes", "No"])
blank_line("Dyspareunia / other complaints", 40)

add_section_heading("Past Gynecological History")
two_col_blank("Pap smear date/result", 20, "Prior gynae surgery", 20)
blank_line("Infections / STI history", 45)

add_section_heading("Past Medical / Surgical / Drug / Allergy History")
checkbox_line("Comorbidities", ["DM", "HTN", "Thyroid", "TB", "None"])
blank_line("Drug history", 35)
blank_line("Allergy history", 35)
blank_line("Family history", 45)

add_section_heading("On Examination")
two_col_blank("GC", 8, "Pallor", 8)
two_col_blank("Pulse", 8, "BP", 10)
add_table(["Exam", "Findings"], 4, col_widths=[1.6, 5.5])
p = doc.add_paragraph()
r = p.add_run("(P/A - per abdomen, P/S - per speculum, P/V - per vaginum, Breast)")
r.italic = True
r.font.size = Pt(8.5)

footer_note()

doc.add_page_break()

# ============ PAGE 2: OBSTETRIC (ANTENATAL) OPD NOTE ============
add_title("OBSTETRIC (ANTENATAL) OPD NOTE", "Quick documentation template")

p = doc.add_paragraph()
p.add_run("Name: " + "_"*30 + "   Age: " + "_"*6 + "   Date: " + "_"*15).font.size = Pt(10.5)

add_section_heading("Pregnancy Summary")
p = doc.add_paragraph()
r1 = p.add_run("G ___ P ___ L ___ A ___   ")
r1.bold = True
r1.font.size = Pt(11)
two_col_blank("LMP", 14, "EDD (Naegele's rule)", 14)
two_col_blank("POG today (by dates)", 12, "POG (by USG)", 12)

add_section_heading("Chief Complaint(s)")
checkbox_line("Symptoms", ["Fetal movements +", "Pain", "Leaking", "Bleeding", "Swelling", "None"])
doc.add_paragraph("_" * 100).paragraph_format.space_after = Pt(2)

add_section_heading("Current Pregnancy Details")
two_col_blank("Booking visit (wks)", 8, "No. of ANC visits", 8)
two_col_blank("USG dating scan (wks)", 10, "TT1 / TT2", 12)
checkbox_line("Complications", ["PIH", "GDM", "Anemia", "PROM", "None"])
checkbox_line("Rh status", ["Rh +ve", "Rh -ve -> Anti-D given: Yes/No"])

add_section_heading("Past Obstetric History")
add_table(["Yr", "POG at delivery", "Mode", "Birth wt", "Sex", "Complication", "Outcome"], 3,
          col_widths=[0.6, 1.1, 0.9, 0.8, 0.6, 1.4, 1.1])

add_section_heading("Past Medical / Surgical / Drug / Allergy / Family History")
blank_line("Past medical/surgical history", 45)
blank_line("Drug / Allergy history", 45)
blank_line("Family history", 45)

add_section_heading("On Examination")
two_col_blank("GC", 8, "Pallor / Edema", 10)
two_col_blank("Pulse", 8, "BP", 10)
two_col_blank("Weight (kg)", 8, "Height (cm)", 8)
two_col_blank("Fundal Height (wks)", 10, "FHS (bpm)", 10)
two_col_blank("Presentation", 12, "Lie", 10)
two_col_blank("Engagement (/5th)", 10, "Liquor (clinical)", 12)

add_section_heading("Investigations")
checkbox_line("Sent", ["Hb", "Urine R/M", "BSL", "USG", "Others:"])
doc.add_paragraph("_" * 60)

footer_note()

# ============ PAGE 3: ABBREVIATION KEY ============
doc.add_page_break()
add_title("QUICK ABBREVIATION KEY", "Common shorthand for O&G OPD notes")

abbrevs = [
    ("G / P / L / A", "Gravida / Para / Living / Abortion"),
    ("LMP / EDD", "Last Menstrual Period / Expected Date of Delivery"),
    ("POG", "Period of Gestation"),
    ("FH / FHS", "Fundal Height / Fetal Heart Sounds"),
    ("P/A, P/S, P/V", "Per Abdomen, Per Speculum, Per Vaginum"),
    ("PIH, GDM, PROM", "Pregnancy-Induced Hypertension, Gestational Diabetes, Premature Rupture of Membranes"),
    ("C/O", "Complains of"),
    ("O/E", "On Examination"),
    ("Ceph / Breech", "Cephalic / Breech presentation"),
    ("IMB / PMB", "Intermenstrual Bleeding / Postmenopausal Bleeding"),
    ("TT1 / TT2", "Tetanus Toxoid dose 1 / dose 2"),
    ("GC", "General Condition"),
]
t = add_table(["Abbreviation", "Meaning"], len(abbrevs), col_widths=[1.8, 5.3])
for i, (a, b) in enumerate(abbrevs, start=1):
    t.rows[i].cells[0].paragraphs[0].runs[0].text = a
    t.rows[i].cells[1].paragraphs[0].runs[0].text = b
    t.rows[i].cells[0].paragraphs[0].runs[0].bold = True

doc.save("/tmp/workspace/opd-notes-template/OG_OPD_Note_Templates.docx")
print("docx saved")
Running Command

cd /tmp/workspace/opd-notes-template && python3 make_docx.py

Quick answer

I've created the Word document with the OPD note templates. Here it is:

OG OPD Note Templates

Word Document · DOCX

It contains three pages:
  1. Gynecology OPD Note - chief complaint, menstrual history, obstetric history (G/P/L/A), contraception/sexual history, past gynae history, comorbidities, and an examination section with blank fill-in lines and a findings table.
  2. Obstetric (Antenatal) OPD Note - pregnancy summary (LMP/EDD/POG), current pregnancy details, a past obstetric history table (year, POG at delivery, mode, birth weight, sex, complication, outcome), and a full examination section (fundal height, FHS, presentation, lie, engagement, liquor).
  3. Quick Abbreviation Key - a reference table of all the shorthand (G/P/L/A, LMP/EDD, POG, FH/FHS, P/A-P/S-P/V, PIH/GDM/PROM, etc.) for fast charting.
I wasn't able to generate the matching PDF version in this session (ran out of tool budget before that step). If you'd like, just ask me to "make the PDF version too" in a follow-up and I'll finish it - I can either convert this same layout to PDF or generate it fresh with reportlab.

All 3

Running Command

ls -la /tmp/workspace/opd-notes-template/

Writing File

~/opd-notes-template/make_pdf.py

from reportlab.lib.pagesizes import A4
from reportlab.lib.units import inch
from reportlab.lib import colors
from reportlab.platypus import (SimpleDocTemplate, Paragraph, Spacer, Table, TableStyle,
                                 PageBreak, HRFlowable)
from reportlab.lib.styles import getSampleStyleSheet, ParagraphStyle
from reportlab.lib.enums import TA_CENTER

styles = getSampleStyleSheet()

title_style = ParagraphStyle("TitleC", parent=styles["Title"], fontSize=16, alignment=TA_CENTER, spaceAfter=2)
sub_style = ParagraphStyle("SubC", parent=styles["Normal"], fontSize=9, alignment=TA_CENTER,
                            textColor=colors.HexColor("#555555"), spaceAfter=10, fontName="Helvetica-Oblique")
sec_style = ParagraphStyle("Sec", parent=styles["Normal"], fontSize=11, fontName="Helvetica-Bold",
                            textColor=colors.HexColor("#1F4E79"), backColor=colors.HexColor("#DCE6F1"),
                            spaceBefore=8, spaceAfter=4, leftIndent=3, borderPadding=3)
body_style = ParagraphStyle("Body", parent=styles["Normal"], fontSize=10, spaceAfter=4, leading=14)
small_italic = ParagraphStyle("SmallItalic", parent=styles["Normal"], fontSize=8, fontName="Helvetica-Oblique",
                               textColor=colors.HexColor("#555555"))

def blank(label, n=30):
    return Paragraph(f"<b>{label}:</b> " + "_"*n, body_style)

def two_col(label1, n1, label2, n2):
    return Paragraph(f"<b>{label1}:</b> " + "_"*n1 + "&nbsp;&nbsp;&nbsp;&nbsp;<b>" + label2 + ":</b> " + "_"*n2, body_style)

def checkbox(label, options):
    boxes = "&nbsp;&nbsp;&nbsp;".join([f"&#9744; {o}" for o in options])
    return Paragraph(f"<b>{label}:</b> " + boxes, body_style)

def make_table(headers, nrows, col_widths, data=None):
    rows = [headers]
    if data:
        rows.extend(data)
        for _ in range(nrows - len(data)):
            rows.append([""] * len(headers))
    else:
        for _ in range(nrows):
            rows.append([""] * len(headers))
    t = Table(rows, colWidths=col_widths, rowHeights=[16] + [18]*nrows)
    t.setStyle(TableStyle([
        ("BACKGROUND", (0, 0), (-1, 0), colors.HexColor("#F2F2F2")),
        ("FONTNAME", (0, 0), (-1, 0), "Helvetica-Bold"),
        ("FONTSIZE", (0, 0), (-1, -1), 8.5),
        ("GRID", (0, 0), (-1, -1), 0.5, colors.HexColor("#999999")),
        ("VALIGN", (0, 0), (-1, -1), "MIDDLE"),
        ("ALIGN", (0, 0), (-1, 0), "CENTER"),
    ]))
    return t

def footer_block():
    elems = []
    elems.append(blank("Provisional Diagnosis", 55))
    elems.append(blank("Plan / Advice / Rx", 60))
    elems.append(Spacer(1, 4))
    for _ in range(3):
        elems.append(HRFlowable(width="100%", thickness=0.5, color=colors.HexColor("#AAAAAA")))
        elems.append(Spacer(1, 8))
    elems.append(Paragraph("Doctor's Signature: " + "_"*25 + "&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Next visit: " + "_"*15, body_style))
    return elems

elements = []

# ============ PAGE 1: GYNECOLOGY OPD NOTE ============
elements.append(Paragraph("GYNECOLOGY OPD NOTE", title_style))
elements.append(Paragraph("Quick documentation template", sub_style))

elements.append(Paragraph("Name: " + "_"*30 + "&nbsp;&nbsp;&nbsp;Age: " + "_"*6 + "&nbsp;&nbsp;&nbsp;Date: " + "_"*15, body_style))
elements.append(Paragraph("Marital status: " + "_"*10 + "&nbsp;&nbsp;&nbsp;Occupation: " + "_"*15 + "&nbsp;&nbsp;&nbsp;Reg. No: " + "_"*12, body_style))

elements.append(Paragraph("Chief Complaint(s)", sec_style))
elements.append(Paragraph("_"*100, body_style))
elements.append(Paragraph("_"*100, body_style))

elements.append(Paragraph("Menstrual History", sec_style))
elements.append(two_col("Menarche (yrs)", 6, "LMP", 12))
elements.append(two_col("Cycle length/duration", 10, "Flow (nl/exc/scanty)", 10))
elements.append(checkbox("Dysmenorrhea", ["Yes", "No"]))
elements.append(two_col("Menopause (yrs, if any)", 10, "IMB/PMB", 12))

elements.append(Paragraph("Obstetric History", sec_style))
elements.append(Paragraph("<b>G ___ P ___ L ___ A ___</b>&nbsp;&nbsp;<i>(Gravida / Para / Living / Abortion)</i>", body_style))
elements.append(two_col("Mode of last delivery", 15, "Last delivery (yrs ago)", 8))

elements.append(Paragraph("Contraception &amp; Sexual History", sec_style))
elements.append(two_col("Current method", 12, "Duration", 10))
elements.append(checkbox("Sexually active", ["Yes", "No"]))
elements.append(blank("Dyspareunia / other complaints", 40))

elements.append(Paragraph("Past Gynecological History", sec_style))
elements.append(two_col("Pap smear date/result", 20, "Prior gynae surgery", 20))
elements.append(blank("Infections / STI history", 45))

elements.append(Paragraph("Past Medical / Surgical / Drug / Allergy History", sec_style))
elements.append(checkbox("Comorbidities", ["DM", "HTN", "Thyroid", "TB", "None"]))
elements.append(blank("Drug history", 35))
elements.append(blank("Allergy history", 35))
elements.append(blank("Family history", 45))

elements.append(Paragraph("On Examination", sec_style))
elements.append(two_col("GC", 8, "Pallor", 8))
elements.append(two_col("Pulse", 8, "BP", 10))
elements.append(Spacer(1, 4))
elements.append(make_table(["Exam", "Findings"], 4, [1.6*inch, 5.0*inch]))
elements.append(Spacer(1, 3))
elements.append(Paragraph("(P/A - per abdomen, P/S - per speculum, P/V - per vaginum, Breast)", small_italic))

elements.append(Spacer(1, 6))
elements.extend(footer_block())

elements.append(PageBreak())

# ============ PAGE 2: OBSTETRIC (ANTENATAL) OPD NOTE ============
elements.append(Paragraph("OBSTETRIC (ANTENATAL) OPD NOTE", title_style))
elements.append(Paragraph("Quick documentation template", sub_style))

elements.append(Paragraph("Name: " + "_"*30 + "&nbsp;&nbsp;&nbsp;Age: " + "_"*6 + "&nbsp;&nbsp;&nbsp;Date: " + "_"*15, body_style))

elements.append(Paragraph("Pregnancy Summary", sec_style))
elements.append(Paragraph("<b>G ___ P ___ L ___ A ___</b>", body_style))
elements.append(two_col("LMP", 14, "EDD (Naegele's rule)", 14))
elements.append(two_col("POG today (by dates)", 12, "POG (by USG)", 12))

elements.append(Paragraph("Chief Complaint(s)", sec_style))
elements.append(checkbox("Symptoms", ["Fetal movements +", "Pain", "Leaking", "Bleeding", "Swelling", "None"]))
elements.append(Paragraph("_"*100, body_style))

elements.append(Paragraph("Current Pregnancy Details", sec_style))
elements.append(two_col("Booking visit (wks)", 8, "No. of ANC visits", 8))
elements.append(two_col("USG dating scan (wks)", 10, "TT1 / TT2", 12))
elements.append(checkbox("Complications", ["PIH", "GDM", "Anemia", "PROM", "None"]))
elements.append(checkbox("Rh status", ["Rh +ve", "Rh -ve -> Anti-D given: Yes/No"]))

elements.append(Paragraph("Past Obstetric History", sec_style))
elements.append(Spacer(1, 3))
elements.append(make_table(["Yr", "POG at delivery", "Mode", "Birth wt", "Sex", "Complication", "Outcome"], 3,
                            [0.5*inch, 1.0*inch, 0.8*inch, 0.75*inch, 0.55*inch, 1.3*inch, 1.1*inch]))

elements.append(Paragraph("Past Medical / Surgical / Drug / Allergy / Family History", sec_style))
elements.append(blank("Past medical/surgical history", 45))
elements.append(blank("Drug / Allergy history", 45))
elements.append(blank("Family history", 45))

elements.append(Paragraph("On Examination", sec_style))
elements.append(two_col("GC", 8, "Pallor / Edema", 10))
elements.append(two_col("Pulse", 8, "BP", 10))
elements.append(two_col("Weight (kg)", 8, "Height (cm)", 8))
elements.append(two_col("Fundal Height (wks)", 10, "FHS (bpm)", 10))
elements.append(two_col("Presentation", 12, "Lie", 10))
elements.append(two_col("Engagement (/5th)", 10, "Liquor (clinical)", 12))

elements.append(Paragraph("Investigations", sec_style))
elements.append(checkbox("Sent", ["Hb", "Urine R/M", "BSL", "USG", "Others:"]))
elements.append(Paragraph("_"*60, body_style))

elements.append(Spacer(1, 6))
elements.extend(footer_block())

elements.append(PageBreak())

# ============ PAGE 3: ABBREVIATION KEY ============
elements.append(Paragraph("QUICK ABBREVIATION KEY", title_style))
elements.append(Paragraph("Common shorthand for O&G OPD notes", sub_style))

abbrevs = [
    ("G / P / L / A", "Gravida / Para / Living / Abortion"),
    ("LMP / EDD", "Last Menstrual Period / Expected Date of Delivery"),
    ("POG", "Period of Gestation"),
    ("FH / FHS", "Fundal Height / Fetal Heart Sounds"),
    ("P/A, P/S, P/V", "Per Abdomen, Per Speculum, Per Vaginum"),
    ("PIH, GDM, PROM", "Pregnancy-Induced Hypertension, Gestational Diabetes, Premature Rupture of Membranes"),
    ("C/O", "Complains of"),
    ("O/E", "On Examination"),
    ("Ceph / Breech", "Cephalic / Breech presentation"),
    ("IMB / PMB", "Intermenstrual Bleeding / Postmenopausal Bleeding"),
    ("TT1 / TT2", "Tetanus Toxoid dose 1 / dose 2"),
    ("GC", "General Condition"),
]
data_rows = [[Paragraph(f"<b>{a}</b>", body_style), Paragraph(b, body_style)] for a, b in abbrevs]
t = Table([["Abbreviation", "Meaning"]] + data_rows, colWidths=[1.8*inch, 5.0*inch])
t.setStyle(TableStyle([
    ("BACKGROUND", (0, 0), (-1, 0), colors.HexColor("#F2F2F2")),
    ("FONTNAME", (0, 0), (-1, 0), "Helvetica-Bold"),
    ("FONTSIZE", (0, 0), (-1, -1), 9.5),
    ("GRID", (0, 0), (-1, -1), 0.5, colors.HexColor("#999999")),
    ("VALIGN", (0, 0), (-1, -1), "MIDDLE"),
    ("ALIGN", (0, 0), (-1, 0), "CENTER"),
    ("TOPPADDING", (0, 0), (-1, -1), 4),
    ("BOTTOMPADDING", (0, 0), (-1, -1), 4),
]))
elements.append(t)

doc = SimpleDocTemplate("/tmp/workspace/opd-notes-template/OG_OPD_Note_Templates.pdf",
                         pagesize=A4,
                         topMargin=0.5*inch, bottomMargin=0.5*inch,
                         leftMargin=0.6*inch, rightMargin=0.6*inch)
doc.build(elements)
print("pdf saved")
Running Command

cd /tmp/workspace/opd-notes-template && python3 make_pdf.py && ls -la

Both files are ready - PDF and Word versions of all 3 pages (Gynecology OPD Note, Obstetric/Antenatal OPD Note, and the Abbreviation Key):

OG OPD Note Templates

PDF Document · PDF

OG OPD Note Templates

Word Document · DOCX

Both contain the same 3-page layout:
  1. Gynecology OPD Note - biodata, chief complaint, menstrual/obstetric/contraceptive/sexual/past gynae history, comorbidities, and an exam section with a findings table.
  2. Obstetric (Antenatal) OPD Note - G/P/L/A, LMP/EDD/POG, current pregnancy details, a past obstetric history table (year, POG, mode, birth weight, sex, complication, outcome), and full antenatal exam fields (fundal height, FHS, presentation, lie, engagement, liquor).
  3. Quick Abbreviation Key - reference table of all shorthand used.
Print the PDF if you want a ready-to-use paper stamp/checklist for clinic, or use the DOCX if you want to edit/customize the fields (font, hospital letterhead, logo, etc.) before printing.

Can you give me the list of drugs suggestion for gyne and obs opd make a list of complains with drugs suggestions and doses

Reading File
Finding Sources
Finding Sources
Finding Sources
Finding Sources
Finding Sources
Finding Sources
Finding Sources
Finding Sources
Finding Sources
Finding Sources
Searching the Web

CDC 2021 PID treatment ceftriaxone doxycycline metronidazole dose

Searching the Web

WHO recommended uterotonic dose postpartum hemorrhage prevention oxytocin misoprostol

Gyne & Obs OPD: Complaint-wise Drug Reference

Important caveat before you use this: these are standard/common starting doses from major textbooks and guidelines (CDC, WHO, ACOG-referenced sources). Always adjust for the patient's renal/hepatic function, allergies, trimester of pregnancy, local antibiotic resistance patterns, and your institution's protocol. This is a quick-reference aid, not a substitute for clinical judgment on an individual patient.

A. GYNECOLOGY OPD

ComplaintDrug SuggestionDose
DysmenorrheaMefenamic acid500 mg PO TID, start at onset of pain/menses
Ibuprofen400 mg PO TID with food
Naproxen500 mg loading, then 250 mg q6-8h
Abnormal Uterine Bleeding (AUB) / MenorrhagiaTranexamic acid1000-1300 mg PO TID for up to 5 days during heavy flow (FDA-approved for ovulatory AUB)
NSAID (mefenamic acid)500 mg TID during bleeding days
Combined OCP (for hormonal control)1 tab OD as per pack cycle
Levonorgestrel IUDLong-term option - insertion, not oral dosing
Vulvovaginal CandidiasisFluconazole150 mg PO single dose
Clotrimazole vaginal1% cream/pessary OD x 6 days, or 500 mg pessary single dose
Bacterial VaginosisMetronidazole500 mg PO BID x 7 days, or vaginal gel 0.75% OD x 5 days
TrichomoniasisMetronidazole2 g PO single dose, or 500 mg BID x 7 days (treat partner too)
Pelvic Inflammatory Disease (PID)Ceftriaxone + Doxycycline + MetronidazoleCeftriaxone 500 mg IM single dose + Doxycycline 100 mg PO BID x14 days + Metronidazole 500 mg PO BID x14 days (current CDC 2021 regimen - metronidazole now routinely added)
Iron Deficiency Anemia (menorrhagia-related)Ferrous sulfate325 mg PO BID-TID (65 mg elemental iron/dose)
Recurrent Vulvovaginal Candidiasis (prophylaxis)Fluconazole150-200 mg PO weekly (maintenance)
Contraception - EmergencyLevonorgestrel1.5 mg PO single dose within 72 hrs (most effective <24 hrs)
Contraception - RegularCombined OCP1 tab OD, cyclical
Vaginal atrophy/menopausal vaginitisTopical estrogen creamLow-dose applicator, 2-3x/week per product instructions
Vasomotor symptoms (menopause)HRT (estrogen +/- progestin)Lowest effective dose, individualized

B. OBSTETRICS OPD (Antenatal)

ComplaintDrug SuggestionDose
Routine antenatal supplementationFerrous sulfate/fumarate + Folic acidElemental iron 30-60 mg/day (WHO) + Folic acid 400-800 mcg OD
Calcium + Vitamin D500-1000 mg elemental calcium OD-BID
Iron Deficiency Anemia in pregnancyFerrous sulfate325 mg PO OD-BID (ACOG/WHO: at least 30 mg elemental iron/day); consider IV iron if intolerant/severe
Nausea and Vomiting of Pregnancy (mild)Doxylamine + Pyridoxine (Vit B6)10 mg + 10 mg PO, 1-2 tabs at bedtime (first-line, safe in pregnancy)
Hyperemesis Gravidarum (moderate-severe)Ondansetron4 mg PO/IV every 8 hours
Metoclopramide10 mg PO/IV TID (alternative)
Threatened Miscarriage(No proven effective drug per evidence)Bed rest and progesterone are often used clinically but textbooks note no demonstrated efficacy (Berek & Novak's Gynecology) - counsel accordingly, avoid over-promising
Gestational Hypertension / Pre-eclampsia (non-severe, outpatient)Labetalol100-200 mg PO BID-TID (titrate)
Nifedipine (extended release)10-20 mg PO BID
Methyldopa250 mg PO BID-TID
Severe Pre-eclampsia / Eclampsia (seizure prophylaxis - inpatient/emergency, not routine OPD)Magnesium sulfateLoading 4-6 g IV over 15-20 min, then maintenance 1-2 g/hr IV infusion (or Pritchard IM regimen) - refer/admit immediately, do not manage in OPD
Urinary Tract Infection in pregnancyCephalexin500 mg PO BID-QID x 5-7 days
Nitrofurantoin (avoid near term)100 mg PO BID x 5-7 days
Postpartum Hemorrhage prevention (3rd stage)Oxytocin10 IU IM/IV after delivery of baby (WHO first-line)
Misoprostol (if oxytocin unavailable)600 mcg PO for prevention; 800-1000 mcg sublingual/rectal for treatment
PPH treatment (uterine atony, unresponsive to oxytocin)Methylergometrine0.2 mg IM (avoid in hypertensive patients)
Carboprost0.25 mg IM, repeat q15min, max 2 mg total
Vaginal candidiasis in pregnancyClotrimazole (topical only, avoid oral fluconazole in pregnancy)1% cream/pessary OD x 7 days
Threatened Preterm Labor (tocolysis - specialist referral)Nifedipine20 mg PO loading, then 10-20 mg q4-6h (short-term tocolysis)
Fetal lung maturity (preterm risk 24-34 wks)Betamethasone12 mg IM, 2 doses 24 hrs apart

Quick Safety Notes

  • Pregnancy category caution: avoid NSAIDs (mefenamic acid, ibuprofen) after 20 weeks gestation (fetal renal effects) and near term (premature ductus closure). Avoid oral fluconazole and doxycycline/tetracyclines in pregnancy.
  • MgSO4 and severe pre-eclampsia/eclampsia management belongs in an inpatient/emergency setting, not routine OPD - listed here for reference/counseling only.
  • PID and STI regimens should prompt partner treatment and STI screening (HIV, syphilis).
  • Always cross-check with your local antibiotic resistance data and formulary before prescribing.
Sources referenced: CDC STI Treatment Guidelines 2021 (PID regimen), WHO uterotonic recommendations (PPH prevention), Berek & Novak's Gynecology (AUB, threatened abortion), Harrison's Principles of Internal Medicine 22nd ed. (dysmenorrhea), Goldman-Cecil Medicine (hyperemesis, eclampsia), Rosen's Emergency Medicine (eclampsia management box).
Want me to add this as a 4th page to your existing OPD note templates (DOCX/PDF) so you have one combined file with the notes proforma plus this drug quick-reference?

Can you make a PDF for me

Running Command

ls -la /tmp/workspace/opd-notes-template/

Writing File

~/opd-notes-template/make_drug_pdf.py

from reportlab.lib.pagesizes import A4
from reportlab.lib.units import inch
from reportlab.lib import colors
from reportlab.platypus import (SimpleDocTemplate, Paragraph, Spacer, Table, TableStyle,
                                 PageBreak)
from reportlab.lib.styles import getSampleStyleSheet, ParagraphStyle
from reportlab.lib.enums import TA_CENTER, TA_LEFT

styles = getSampleStyleSheet()

title_style = ParagraphStyle("TitleC", parent=styles["Title"], fontSize=16, alignment=TA_CENTER, spaceAfter=2)
sub_style = ParagraphStyle("SubC", parent=styles["Normal"], fontSize=9, alignment=TA_CENTER,
                            textColor=colors.HexColor("#555555"), spaceAfter=10, fontName="Helvetica-Oblique")
sec_style = ParagraphStyle("Sec", parent=styles["Normal"], fontSize=12, fontName="Helvetica-Bold",
                            textColor=colors.white, backColor=colors.HexColor("#1F4E79"),
                            spaceBefore=10, spaceAfter=6, leftIndent=4, borderPadding=4)
cell_style = ParagraphStyle("Cell", parent=styles["Normal"], fontSize=8.5, leading=10.5)
cell_bold = ParagraphStyle("CellBold", parent=cell_style, fontName="Helvetica-Bold")
note_style = ParagraphStyle("Note", parent=styles["Normal"], fontSize=8.5, leading=11,
                             textColor=colors.HexColor("#333333"))
warn_style = ParagraphStyle("Warn", parent=styles["Normal"], fontSize=9, leading=12,
                             textColor=colors.HexColor("#7A1F1F"), fontName="Helvetica-Bold")
src_style = ParagraphStyle("Src", parent=styles["Normal"], fontSize=7.5, leading=9.5,
                            textColor=colors.HexColor("#666666"), fontName="Helvetica-Oblique")

def P(text, style=cell_style):
    return Paragraph(text, style)

def make_drug_table(rows):
    header = [P("Complaint", cell_bold), P("Drug Suggestion", cell_bold), P("Dose", cell_bold)]
    data = [header]
    for complaint, drug, dose in rows:
        data.append([P(complaint), P(drug), P(dose)])
    t = Table(data, colWidths=[1.7*inch, 2.0*inch, 3.1*inch], repeatRows=1)
    t.setStyle(TableStyle([
        ("BACKGROUND", (0, 0), (-1, 0), colors.HexColor("#DCE6F1")),
        ("GRID", (0, 0), (-1, -1), 0.5, colors.HexColor("#999999")),
        ("VALIGN", (0, 0), (-1, -1), "TOP"),
        ("TOPPADDING", (0, 0), (-1, -1), 4),
        ("BOTTOMPADDING", (0, 0), (-1, -1), 4),
        ("LEFTPADDING", (0, 0), (-1, -1), 5),
        ("ROWBACKGROUNDS", (0, 1), (-1, -1), [colors.white, colors.HexColor("#F7F9FC")]),
    ]))
    return t

elements = []

# ===== Title / Disclaimer =====
elements.append(Paragraph("GYNE &amp; OBS OPD DRUG QUICK-REFERENCE", title_style))
elements.append(Paragraph("Complaint-wise drug suggestions and doses", sub_style))

disclaimer = ("CAUTION: Standard/common starting doses from major textbooks and guidelines "
              "(CDC, WHO, ACOG-referenced sources). Always adjust for renal/hepatic function, "
              "allergies, trimester of pregnancy, local resistance patterns, and institutional protocol. "
              "This is a quick-reference aid, not a substitute for clinical judgment on an individual patient.")
elements.append(Paragraph(disclaimer, warn_style))
elements.append(Spacer(1, 8))

# ===== Section A: Gynecology =====
elements.append(Paragraph("A. GYNECOLOGY OPD", sec_style))

gyne_rows = [
    ("Dysmenorrhea", "Mefenamic acid", "500 mg PO TID, start at onset of pain/menses"),
    ("", "Ibuprofen", "400 mg PO TID with food"),
    ("", "Naproxen", "500 mg loading, then 250 mg q6-8h"),
    ("Abnormal Uterine Bleeding (AUB) / Menorrhagia", "Tranexamic acid", "1000-1300 mg PO TID for up to 5 days during heavy flow"),
    ("", "NSAID (mefenamic acid)", "500 mg TID during bleeding days"),
    ("", "Combined OCP", "1 tab OD as per pack cycle"),
    ("", "Levonorgestrel IUD", "Long-term option - insertion, not oral dosing"),
    ("Vulvovaginal Candidiasis", "Fluconazole", "150 mg PO single dose"),
    ("", "Clotrimazole vaginal", "1% cream/pessary OD x 6 days, or 500 mg pessary single dose"),
    ("Bacterial Vaginosis", "Metronidazole", "500 mg PO BID x 7 days, or vaginal gel 0.75% OD x 5 days"),
    ("Trichomoniasis", "Metronidazole", "2 g PO single dose, or 500 mg BID x 7 days (treat partner too)"),
    ("Pelvic Inflammatory Disease (PID)", "Ceftriaxone + Doxycycline + Metronidazole",
     "Ceftriaxone 500 mg IM single dose + Doxycycline 100 mg PO BID x14 days + Metronidazole 500 mg PO BID x14 days"),
    ("Iron Deficiency Anemia (menorrhagia-related)", "Ferrous sulfate", "325 mg PO BID-TID (65 mg elemental iron/dose)"),
    ("Recurrent Vulvovaginal Candidiasis (prophylaxis)", "Fluconazole", "150-200 mg PO weekly (maintenance)"),
    ("Emergency Contraception", "Levonorgestrel", "1.5 mg PO single dose within 72 hrs (most effective <24 hrs)"),
    ("Regular Contraception", "Combined OCP", "1 tab OD, cyclical"),
    ("Vaginal atrophy / menopausal vaginitis", "Topical estrogen cream", "Low-dose applicator, 2-3x/week per product instructions"),
    ("Vasomotor symptoms (menopause)", "HRT (estrogen +/- progestin)", "Lowest effective dose, individualized"),
]
elements.append(make_drug_table(gyne_rows))

elements.append(PageBreak())

# ===== Section B: Obstetrics =====
elements.append(Paragraph("B. OBSTETRICS OPD (ANTENATAL)", sec_style))

obs_rows = [
    ("Routine antenatal supplementation", "Ferrous sulfate/fumarate + Folic acid",
     "Elemental iron 30-60 mg/day (WHO) + Folic acid 400-800 mcg OD"),
    ("", "Calcium + Vitamin D", "500-1000 mg elemental calcium OD-BID"),
    ("Iron Deficiency Anemia in pregnancy", "Ferrous sulfate", "325 mg PO OD-BID; consider IV iron if intolerant/severe"),
    ("Nausea and Vomiting of Pregnancy (mild)", "Doxylamine + Pyridoxine (Vit B6)",
     "10 mg + 10 mg PO, 1-2 tabs at bedtime (first-line, safe in pregnancy)"),
    ("Hyperemesis Gravidarum (moderate-severe)", "Ondansetron", "4 mg PO/IV every 8 hours"),
    ("", "Metoclopramide", "10 mg PO/IV TID (alternative)"),
    ("Threatened Miscarriage", "(No proven effective drug per evidence)",
     "Bed rest/progesterone often used clinically but no demonstrated efficacy - counsel accordingly"),
    ("Gestational Hypertension / Pre-eclampsia (non-severe, outpatient)", "Labetalol", "100-200 mg PO BID-TID (titrate)"),
    ("", "Nifedipine (extended release)", "10-20 mg PO BID"),
    ("", "Methyldopa", "250 mg PO BID-TID"),
    ("Severe Pre-eclampsia / Eclampsia (seizure prophylaxis - admit, not OPD)", "Magnesium sulfate",
     "Loading 4-6 g IV over 15-20 min, then maintenance 1-2 g/hr IV (refer/admit immediately)"),
    ("Urinary Tract Infection in pregnancy", "Cephalexin", "500 mg PO BID-QID x 5-7 days"),
    ("", "Nitrofurantoin (avoid near term)", "100 mg PO BID x 5-7 days"),
    ("Postpartum Hemorrhage prevention (3rd stage)", "Oxytocin", "10 IU IM/IV after delivery of baby (WHO first-line)"),
    ("", "Misoprostol (if oxytocin unavailable)", "600 mcg PO for prevention; 800-1000 mcg sublingual/rectal for treatment"),
    ("PPH treatment (uterine atony, unresponsive to oxytocin)", "Methylergometrine",
     "0.2 mg IM (avoid in hypertensive patients)"),
    ("", "Carboprost", "0.25 mg IM, repeat q15min, max 2 mg total"),
    ("Vaginal candidiasis in pregnancy", "Clotrimazole (topical only, avoid oral fluconazole)", "1% cream/pessary OD x 7 days"),
    ("Threatened Preterm Labor (tocolysis - specialist referral)", "Nifedipine",
     "20 mg PO loading, then 10-20 mg q4-6h (short-term tocolysis)"),
    ("Fetal lung maturity (preterm risk 24-34 wks)", "Betamethasone", "12 mg IM, 2 doses 24 hrs apart"),
]
elements.append(make_drug_table(obs_rows))

elements.append(Spacer(1, 10))

# ===== Safety notes =====
elements.append(Paragraph("Quick Safety Notes", sec_style))
notes = [
    "Avoid NSAIDs (mefenamic acid, ibuprofen) after 20 weeks gestation (fetal renal effects) and near term (premature ductus closure).",
    "Avoid oral fluconazole and doxycycline/tetracyclines in pregnancy.",
    "MgSO4 and severe pre-eclampsia/eclampsia management belongs in an inpatient/emergency setting, not routine OPD - listed here for reference/counseling only.",
    "PID and STI regimens should prompt partner treatment and STI screening (HIV, syphilis).",
    "Always cross-check with local antibiotic resistance data and formulary before prescribing.",
]
for n in notes:
    elements.append(Paragraph("&#8226; " + n, note_style))
    elements.append(Spacer(1, 2))

elements.append(Spacer(1, 10))
elements.append(Paragraph(
    "Sources referenced: CDC STI Treatment Guidelines 2021 (PID regimen), WHO uterotonic recommendations "
    "(PPH prevention), Berek &amp; Novak's Gynecology (AUB, threatened abortion), Harrison's Principles of "
    "Internal Medicine 22nd ed. (dysmenorrhea), Goldman-Cecil Medicine (hyperemesis, eclampsia), Rosen's "
    "Emergency Medicine (eclampsia management box).", src_style))

doc = SimpleDocTemplate("/tmp/workspace/opd-notes-template/OG_OPD_Drug_Reference.pdf",
                         pagesize=A4,
                         topMargin=0.5*inch, bottomMargin=0.5*inch,
                         leftMargin=0.6*inch, rightMargin=0.6*inch)
doc.build(elements)
print("drug reference pdf saved")
Running Command

cd /tmp/workspace/opd-notes-template && python3 make_drug_pdf.py && ls -la

Your PDF is ready:

OG OPD Drug Reference

PDF Document · PDF

It contains:
  • Page 1 - Title/disclaimer + full Gynecology OPD drug table (dysmenorrhea, AUB/menorrhagia, candidiasis, bacterial vaginosis, trichomoniasis, PID, anemia, contraception, menopausal symptoms)
  • Page 2 - Obstetrics OPD drug table (antenatal supplementation, anemia, nausea/hyperemesis, threatened miscarriage, hypertension/pre-eclampsia, UTI, PPH prevention/treatment, candidiasis, preterm labor, fetal lung maturity) plus quick safety notes and source citations
You now have 3 files in /tmp/workspace/opd-notes-template/:
  • OG_OPD_Note_Templates.docx / .pdf - the history-taking OPD note proformas
  • OG_OPD_Drug_Reference.pdf - this new drug quick-reference
Let me know if you'd like a Word (.docx) version of the drug reference too, or want it merged into the same file as the note templates.

Drugs that are use in Pakistan

Searching the Web

Pakistan brand names mefenamic acid tranexamic acid fluconazole metronidazole gynecology

Searching the Web

Pakistan brand names oxytocin misoprostol methylergometrine obstetrics drugs

Searching the Web

Pakistan brand names doxylamine pyridoxine ferrous sulfate folic acid antenatal vitamins

Reading Web Page

https://pk.gsk.com/en-pk/products/products-a-z

Common Drug Brands Available in Pakistan (Gyne & Obs OPD)

Brand availability changes over time and multiple manufacturers often market the same generic in Pakistan, so always cross-check with a current local source (MIMS Pakistan, DRAP-approved list, or your hospital pharmacy) before prescribing. Below are well-known, commonly stocked brands for the drugs in your earlier list.

Gynecology

GenericCommon Pakistani Brand(s)Manufacturer
Mefenamic acidPonstan, MefacPfizer/Viatris, Various
Tranexamic acidTransamin, TrapicGetz Pharma, Various
IbuprofenBrufenAbbott
FluconazoleZolanix, Diflucan, FlucosGSK Pakistan, Pfizer, Various
Clotrimazole (vaginal)Candid-V, ClocipGlenmark, Various
MetronidazoleFlagyl, Metryl, AmrizoleSanofi, Various
DoxycyclineDoxef, VibramycinVarious, Pfizer
CeftriaxoneTraxon, RocephinGSK Pakistan, Roche
Ferrous sulfate/fumarate + Folic acidFefol Spansule, Fefol-VitGSK Pakistan
Levonorgestrel (emergency contraception)Postinor-2, i-PillVarious
Combined OCPYasmin, Diane-35, MarvelonBayer, Organon
Levonorgestrel IUDMirenaBayer

Obstetrics

GenericCommon Pakistani Brand(s)Manufacturer
Ferrous fumarate + Folic acid (antenatal)Fefol Spansule, Folart, ObiminGSK Pakistan, Various
Calcium + Vitamin DCalcium Sandoz, Caltrate, Os-CalNovartis, Various
Doxylamine + Pyridoxine (+ Dicyclomine, morning sickness)NavidoxineBarrett Hodgson Pakistan
OndansetronOnset, EmesetGetz Pharma, Various
MetoclopramideMaxolon, GastrolonSanofi, Various
MethyldopaAldomet, DopametOrganon/MSD legacy brands, Various
NifedipineAdalat, Adalat Retard, NifecardBayer, Various
LabetalolLess commonly stocked; Methyldopa/Nifedipine preferred first-line in most Pakistani obstetric units-
Magnesium sulfateMgSO4 injection (generic, hospital pharmacy stock)Various local manufacturers
CephalexinCeporex, SporidexGSK Pakistan, Various
NitrofurantoinFuradantin (limited availability - check local stock)Various
OxytocinSyntocinonNovartis
MisoprostolCytotec, MizotecPfizer (legacy), Various local
MethylergometrineMethergin, ErgometNovartis, Various
BetamethasoneBetnesol, CelestoneGSK Pakistan, Various

Notes

  • Fefol Spansule (ferrous sulfate 150 mg + folic acid 0.5 mg) is the standard GSK Pakistan antenatal iron/folate combination widely prescribed in Pakistani antenatal clinics.
  • Navidoxine is the go-to first-line brand for morning sickness in Pakistani obstetric practice (contains doxylamine + pyridoxine + dicyclomine, slightly different from the pure doxylamine-pyridoxine combination used in the West, but serves the same purpose).
  • Traxon (ceftriaxone, GSK Pakistan) is commonly used for PID and other indications requiring IM/IV ceftriaxone.
  • Carboprost is not as widely stocked in Pakistan outside major tertiary centers; oxytocin (Syntocinon) and misoprostol remain the mainstay for PPH management in most OPD/labor room settings.
  • Always verify current pricing, availability, and DRAP registration status at your local pharmacy, since brands get discontinued or replaced periodically.
Want me to add this Pakistan-brand table as a page in your existing drug reference PDF, so you have one consolidated file (generic + Pakistani brand + dose)?

Can you just make the presenting complain with drugs suggestions available in Pakistan and doses all in one place in pdf

Running Command

ls -la /tmp/workspace/opd-notes-template/

Writing File

~/opd-notes-template/make_pakistan_pdf.py

from reportlab.lib.pagesizes import A4
from reportlab.lib.units import inch
from reportlab.lib import colors
from reportlab.platypus import (SimpleDocTemplate, Paragraph, Spacer, Table, TableStyle,
                                 PageBreak)
from reportlab.lib.styles import getSampleStyleSheet, ParagraphStyle
from reportlab.lib.enums import TA_CENTER

styles = getSampleStyleSheet()

title_style = ParagraphStyle("TitleC", parent=styles["Title"], fontSize=15, alignment=TA_CENTER, spaceAfter=2)
sub_style = ParagraphStyle("SubC", parent=styles["Normal"], fontSize=9, alignment=TA_CENTER,
                            textColor=colors.HexColor("#555555"), spaceAfter=8, fontName="Helvetica-Oblique")
sec_style = ParagraphStyle("Sec", parent=styles["Normal"], fontSize=12, fontName="Helvetica-Bold",
                            textColor=colors.white, backColor=colors.HexColor("#1F4E79"),
                            spaceBefore=10, spaceAfter=6, leftIndent=4, borderPadding=4)
cell_style = ParagraphStyle("Cell", parent=styles["Normal"], fontSize=7.8, leading=9.6)
cell_bold = ParagraphStyle("CellBold", parent=cell_style, fontName="Helvetica-Bold")
note_style = ParagraphStyle("Note", parent=styles["Normal"], fontSize=8.3, leading=10.8,
                             textColor=colors.HexColor("#333333"))
warn_style = ParagraphStyle("Warn", parent=styles["Normal"], fontSize=8.8, leading=11.5,
                             textColor=colors.HexColor("#7A1F1F"), fontName="Helvetica-Bold")
src_style = ParagraphStyle("Src", parent=styles["Normal"], fontSize=7.2, leading=9,
                            textColor=colors.HexColor("#666666"), fontName="Helvetica-Oblique")

def P(text, style=cell_style):
    return Paragraph(text, style)

def make_table(rows):
    header = [P("Presenting Complaint", cell_bold), P("Drug (Generic)", cell_bold),
              P("Pakistan Brand", cell_bold), P("Dose", cell_bold)]
    data = [header]
    for complaint, drug, brand, dose in rows:
        data.append([P(complaint), P(drug), P(brand), P(dose)])
    t = Table(data, colWidths=[1.55*inch, 1.35*inch, 1.25*inch, 2.55*inch], repeatRows=1)
    t.setStyle(TableStyle([
        ("BACKGROUND", (0, 0), (-1, 0), colors.HexColor("#DCE6F1")),
        ("GRID", (0, 0), (-1, -1), 0.5, colors.HexColor("#999999")),
        ("VALIGN", (0, 0), (-1, -1), "TOP"),
        ("TOPPADDING", (0, 0), (-1, -1), 3.5),
        ("BOTTOMPADDING", (0, 0), (-1, -1), 3.5),
        ("LEFTPADDING", (0, 0), (-1, -1), 4),
        ("RIGHTPADDING", (0, 0), (-1, -1), 4),
        ("ROWBACKGROUNDS", (0, 1), (-1, -1), [colors.white, colors.HexColor("#F7F9FC")]),
    ]))
    return t

elements = []

elements.append(Paragraph("GYNE &amp; OBS OPD DRUG REFERENCE - PAKISTAN", title_style))
elements.append(Paragraph("Presenting complaint, generic drug, Pakistani brand, and dose - all in one place", sub_style))

disclaimer = ("CAUTION: Brand availability changes and multiple manufacturers may market the same generic in "
              "Pakistan. Verify current stock, DRAP registration, and price with your local pharmacy/MIMS Pakistan "
              "before prescribing. Always adjust for renal/hepatic function, allergy history, trimester of pregnancy, "
              "and institutional protocol. This is a quick-reference aid, not a substitute for clinical judgment.")
elements.append(Paragraph(disclaimer, warn_style))
elements.append(Spacer(1, 8))

# ===== GYNECOLOGY =====
elements.append(Paragraph("A. GYNECOLOGY OPD", sec_style))

gyne_rows = [
    ("Dysmenorrhea", "Mefenamic acid", "Ponstan, Mefac", "500 mg PO TID, start at onset of pain/menses"),
    ("", "Ibuprofen", "Brufen", "400 mg PO TID with food"),
    ("Abnormal Uterine Bleeding (AUB) / Menorrhagia", "Tranexamic acid", "Transamin, Trapic",
     "1000-1300 mg PO TID for up to 5 days during heavy flow"),
    ("", "Mefenamic acid (NSAID)", "Ponstan, Mefac", "500 mg TID during bleeding days"),
    ("", "Combined OCP", "Yasmin, Diane-35, Marvelon", "1 tab OD as per pack cycle"),
    ("", "Levonorgestrel IUD", "Mirena", "Long-term option - insertion, not oral dosing"),
    ("Vulvovaginal Candidiasis", "Fluconazole", "Zolanix, Diflucan, Flucos", "150 mg PO single dose"),
    ("", "Clotrimazole vaginal", "Candid-V, Clocip", "1% cream/pessary OD x 6 days, or 500 mg pessary single dose"),
    ("Bacterial Vaginosis", "Metronidazole", "Flagyl, Metryl, Amrizole", "500 mg PO BID x 7 days, or vaginal gel 0.75% OD x 5 days"),
    ("Trichomoniasis", "Metronidazole", "Flagyl, Metryl", "2 g PO single dose, or 500 mg BID x 7 days (treat partner too)"),
    ("Pelvic Inflammatory Disease (PID)", "Ceftriaxone", "Traxon, Rocephin", "500 mg IM single dose"),
    ("", "+ Doxycycline", "Doxef, Vibramycin", "100 mg PO BID x 14 days"),
    ("", "+ Metronidazole", "Flagyl, Metryl", "500 mg PO BID x 14 days"),
    ("Iron Deficiency Anemia (menorrhagia-related)", "Ferrous sulfate/fumarate + Folic acid", "Fefol Spansule, Fefol-Vit",
     "1 capsule OD-BID (150 mg iron + 0.5 mg folic acid per dose)"),
    ("Recurrent Vulvovaginal Candidiasis (prophylaxis)", "Fluconazole", "Zolanix, Diflucan", "150-200 mg PO weekly (maintenance)"),
    ("Emergency Contraception", "Levonorgestrel", "Postinor-2, i-Pill", "1.5 mg PO single dose within 72 hrs (best <24 hrs)"),
    ("Regular Contraception", "Combined OCP", "Yasmin, Diane-35, Marvelon", "1 tab OD, cyclical"),
    ("Vaginal atrophy / menopausal vaginitis", "Topical estrogen cream", "Premarin cream (where available)",
     "Low-dose applicator, 2-3x/week per product instructions"),
    ("Vasomotor symptoms (menopause)", "HRT (estrogen +/- progestin)", "Premarin, Angeliq (where available)",
     "Lowest effective dose, individualized"),
]
elements.append(make_table(gyne_rows))

elements.append(PageBreak())

# ===== OBSTETRICS =====
elements.append(Paragraph("B. OBSTETRICS OPD (ANTENATAL)", sec_style))

obs_rows = [
    ("Routine antenatal supplementation", "Ferrous fumarate + Folic acid", "Fefol Spansule, Folart, Obimin",
     "1 capsule/tablet OD (approx. 150 mg iron + 0.5 mg folic acid)"),
    ("", "Calcium + Vitamin D", "Calcium Sandoz, Caltrate, Os-Cal", "500-1000 mg elemental calcium OD-BID"),
    ("Iron Deficiency Anemia in pregnancy", "Ferrous sulfate", "Fefol Spansule", "1 capsule OD-BID; consider IV iron if intolerant/severe"),
    ("Nausea and Vomiting of Pregnancy (mild)", "Doxylamine + Pyridoxine (+ Dicyclomine)", "Navidoxine",
     "1 tab at bedtime, may increase to BID (first-line, safe in pregnancy)"),
    ("Hyperemesis Gravidarum (moderate-severe)", "Ondansetron", "Onset, Emeset", "4 mg PO/IV every 8 hours"),
    ("", "Metoclopramide", "Maxolon, Gastrolon", "10 mg PO/IV TID (alternative)"),
    ("Threatened Miscarriage", "(No proven effective drug per evidence)", "-",
     "Bed rest/progesterone often used clinically but no demonstrated efficacy - counsel accordingly"),
    ("Gestational Hypertension / Pre-eclampsia (non-severe, outpatient)", "Methyldopa", "Aldomet, Dopamet",
     "250 mg PO BID-TID"),
    ("", "Nifedipine (extended release)", "Adalat Retard, Nifecard", "10-20 mg PO BID"),
    ("", "Labetalol (less commonly stocked)", "-", "100-200 mg PO BID-TID if available"),
    ("Severe Pre-eclampsia / Eclampsia (admit, not OPD)", "Magnesium sulfate", "MgSO4 injection (generic)",
     "Loading 4-6 g IV over 15-20 min, then maintenance 1-2 g/hr IV - refer/admit immediately"),
    ("Urinary Tract Infection in pregnancy", "Cephalexin", "Ceporex, Sporidex", "500 mg PO BID-QID x 5-7 days"),
    ("", "Nitrofurantoin (avoid near term, limited stock)", "Furadantin", "100 mg PO BID x 5-7 days"),
    ("Postpartum Hemorrhage prevention (3rd stage)", "Oxytocin", "Syntocinon", "10 IU IM/IV after delivery of baby"),
    ("", "Misoprostol (if oxytocin unavailable)", "Cytotec, Mizotec", "600 mcg PO for prevention; 800-1000 mcg sublingual/rectal for treatment"),
    ("PPH treatment (uterine atony, unresponsive to oxytocin)", "Methylergometrine", "Methergin, Ergomet",
     "0.2 mg IM (avoid in hypertensive patients)"),
    ("Vaginal candidiasis in pregnancy", "Clotrimazole (topical only)", "Candid-V, Clocip", "1% cream/pessary OD x 7 days"),
    ("Threatened Preterm Labor (tocolysis - specialist referral)", "Nifedipine", "Adalat, Nifecard",
     "20 mg PO loading, then 10-20 mg q4-6h (short-term tocolysis)"),
    ("Fetal lung maturity (preterm risk 24-34 wks)", "Betamethasone", "Betnesol, Celestone", "12 mg IM, 2 doses 24 hrs apart"),
]
elements.append(make_table(obs_rows))

elements.append(Spacer(1, 8))
elements.append(Paragraph("Quick Safety Notes", sec_style))
notes = [
    "Avoid NSAIDs (mefenamic acid, ibuprofen) after 20 weeks gestation and near term.",
    "Avoid oral fluconazole and doxycycline/tetracyclines in pregnancy - use topical antifungals and alternative antibiotics.",
    "MgSO4 for severe pre-eclampsia/eclampsia is inpatient/emergency management only - refer, do not manage in OPD.",
    "PID and STI regimens should prompt partner treatment and STI screening.",
    "Multiple brands exist per generic in Pakistan - confirm current availability with your pharmacy before prescribing.",
]
for n in notes:
    elements.append(Paragraph("&#8226; " + n, note_style))
    elements.append(Spacer(1, 2))

elements.append(Spacer(1, 8))
elements.append(Paragraph(
    "Sources: CDC STI Treatment Guidelines 2021, WHO uterotonic recommendations, Berek &amp; Novak's Gynecology, "
    "Harrison's Principles of Internal Medicine 22nd ed., Goldman-Cecil Medicine, Rosen's Emergency Medicine, "
    "and GSK Pakistan product listings (Fefol, Zolanix, Traxon) cross-checked for local brand names.", src_style))

doc = SimpleDocTemplate("/tmp/workspace/opd-notes-template/OG_OPD_Drug_Reference_Pakistan.pdf",
                         pagesize=A4,
                         topMargin=0.5*inch, bottomMargin=0.5*inch,
                         leftMargin=0.5*inch, rightMargin=0.5*inch)
doc.build(elements)
print("combined Pakistan drug reference pdf saved")
Running Command

cd /tmp/workspace/opd-notes-template && python3 make_pakistan_pdf.py && ls -la

Your consolidated PDF is ready:

OG OPD Drug Reference Pakistan

PDF Document · PDF

It's a single 2-page table with four columns - Presenting Complaint | Drug (Generic) | Pakistan Brand | Dose - covering:
  • Page 1 - Gynecology: dysmenorrhea, AUB/menorrhagia, candidiasis, bacterial vaginosis, trichomoniasis, PID, anemia, contraception (emergency + regular), menopausal symptoms.
  • Page 2 - Obstetrics: antenatal supplementation, anemia, nausea/hyperemesis, threatened miscarriage, hypertension/pre-eclampsia, severe pre-eclampsia/eclampsia, UTI, PPH prevention/treatment, candidiasis in pregnancy, preterm labor, fetal lung maturity - plus quick safety notes and sources at the end.
Everything you asked for (complaint + drug + Pakistani brand + dose) is now in that one file. Let me know if you'd like it merged with your OPD note templates into a single combined booklet, or converted to an editable Word version too.

??

It looks like something's unclear — what would you like to know?
If you were expecting the PDF and it didn't come through, here it is again:

OG OPD Drug Reference Pakistan

PDF Document · PDF

If "??" was about something else (a typo, confusion about content, or a different question), let me know what you meant and I'll sort it out.

1

Asking for Preferences

You replied '1' - which option did you mean?

History Taking in Obstetrics and Gynecology

History taking in O&G follows the general medical history framework but with specific reproductive, menstrual, and obstetric elements woven in. Here's a structured approach:

1. Biodata

Name, age, marital status, occupation, religion (relevant for some cultural/consanguinity practices), and address.

2. Chief Complaint(s)

In the patient's own words, with duration (e.g., "bleeding per vagina x 3 days", "amenorrhea x 2 months", "labor pains x 6 hours").

3. Menstrual History

  • Age at menarche
  • Cycle length and regularity (e.g., 28-30 days, regular/irregular)
  • Duration and amount of flow (number of pads/day, presence of clots)
  • Dysmenorrhea (pain with periods)
  • Date of Last Menstrual Period (LMP) - critical for calculating gestational age and Expected Date of Delivery (EDD) using Naegele's rule: LMP + 7 days - 3 months (+1 year)
  • Age at menopause if applicable, and method (natural, surgical, drug-induced)
  • Intermenstrual or postmenopausal bleeding/spotting
According to Schwartz's Principles of Surgery, the key elements of a focused gynecologic history include date of LMP, contraceptive/hormone use history, obstetric history, age at menarche/menopause, menstrual bleeding pattern, cervical screening history, history of pelvic infections, sexual history, and prior gynecologic surgeries - Schwartz's Principles of Surgery, p. 1815.

4. Obstetric History

This is documented using the Gravida-Para (GPA) formula:
  • Gravida (G): total number of pregnancies, including the current one
  • Para (P): often expanded as a 4-digit formula - TPAL
    • T = Term deliveries
    • P = Preterm deliveries
    • A = Abortions (spontaneous or induced) / ectopic pregnancies
    • L = Living children
For each previous pregnancy, record:
  • Year and place of delivery
  • Mode of delivery (vaginal, instrumental, cesarean - and indication if cesarean)
  • Gestational age at delivery
  • Birth weight and sex of baby, and current status of the child
  • Antenatal, intranatal, or postnatal complications (pre-eclampsia, gestational diabetes, PPH, etc.)
  • Any pregnancy losses (miscarriage, stillbirth, ectopic, termination) with gestational age and management
For the current pregnancy (if applicable):
  • LMP and calculated EDD/gestational age
  • Confirmation of pregnancy (urine/serum bCG, ultrasound dating - especially first-trimester dating scan)
  • Booking visit details, antenatal visits, and investigations done
  • Symptoms: nausea/vomiting, fetal movements (quickening), bleeding, leaking, contractions
  • Any high-risk factors identified (hypertension, diabetes, anemia, previous cesarean, etc.)
  • Immunizations (tetanus, Rh status if Rh-negative - anti-D given?)

5. Contraceptive History

Current and past methods used, duration, side effects, reason for discontinuation, and pregnancy intention.

6. Sexual History

Age at first intercourse, number of partners, dyspareunia, protection use - handled sensitively and non-judgmentally, as it guides STI risk assessment and testing.

7. Past Gynecological History

  • History of vaginal discharge, pelvic pain, or infections (including HPV/HIV status)
  • Cervical cytology (Pap smear) history - frequency and results
  • Prior gynecological surgeries (D&C, myomectomy, hysterectomy, tubal surgery, etc.)
  • History of infertility and any treatment

8. Past Medical and Surgical History

Chronic illnesses (diabetes, hypertension, thyroid disease, cardiac disease, epilepsy, thromboembolic disease), previous surgeries, hospitalizations, and blood transfusions.

9. Drug and Allergy History

Current medications (including herbal/OTC), known drug allergies, and any teratogenic exposures if pregnant.

10. Family History

Twin pregnancies, congenital anomalies, hereditary conditions, hypertension, diabetes, and any familial cancers (breast, ovarian, endometrial - relevant to gynecologic oncology risk).

11. Personal and Social History

Diet, smoking, alcohol, substance use, occupation (exposure risks), and psychosocial support - important for both general health and issues like domestic violence screening, which should be asked about privately.

Quick reference table (adapted from Schwartz's Principles of Surgery, p. 1815)

ElementWhat to exploreWhy it matters
Menstrual historyMenarche, menopause, bleeding pattern, meds affecting bleedingEndocrine, structural, infectious, oncologic clues
Obstetric historyNumber of pregnancies, dates, delivery type, losses, complicationsPredisposes to certain conditions (e.g., gestational trophoblastic disease), surgical risk
Sexual historyPartners, practices, protection, pregnancy intentionSTI risk, testing sites, counseling
Contraceptive historyCurrent/past use, type, durationPregnancy risk during procedures, side effects
Cytologic screeningFrequency, resultsCervical cancer screening status
This structure applies whether the setting is a routine antenatal visit, a gynecology outpatient consult, or an emergency presentation (labor, bleeding, pain) - though in acute/emergency settings you prioritize the presenting complaint and focused relevant history first, then fill in the rest once the patient is stable.
Would you like me to go deeper into any specific part - for example, a detailed antenatal history-taking checklist, how to calculate the obstetric score (GPA/TPAL) with examples, or history taking for a specific complaint like abnormal uterine bleeding or infertility?No dedicated proforma sections came up in the library search, so here's a practical, standard shorthand template you can use for quick OPD documentation - based on conventional clinical charting practice.

Quick OPD Note Templates (Handwritten Shorthand)

A. Gynecology OPD Note

Name/Age:                    Date:
C/O (Chief complaint):       ______ x ___ days

MENSTRUAL Hx:
  Menarche: __yrs   LMP: __/__/__   Cycle: __/__ (regular/irreg)
  Flow: nl/exc/scanty   Clots: Y/N   Dysmenorrhea: Y/N
  Menopause: __yrs (if applicable)

OBS Hx:  G_P_L_A_   (Gravida/Para/Living/Abortion)
  Mode of delivery(s): ____   Last delivery: __ yrs ago

CONTRACEPTION:  current method: ____   duration: ____

SEXUAL Hx:  active/not active   partners: __   dyspareunia: Y/N

PAST GYNAE Hx:  Pap smear - date/result: ____
  Prior surgery: ____   Infections/STI: ____

P/M Hx (Past medical): DM/HTN/Thyroid/TB - circle if present
DRUG Hx: ____        ALLERGY: ____
FAMILY Hx: ____ (breast/ovarian ca, DM, HTN)

O/E:
  GC: ____  P: __  BP: __/__  Pallor: +/-
  P/A: soft/tender, mass ___, organomegaly
  P/S (speculum): cervix - healthy/erosion/discharge
  P/V (bimanual): uterus - size/pos/mobility, adnexa - free/tender/mass

Provisional Dx: ____
Plan: Investigations / Rx / Follow-up

B. Obstetric (Antenatal) OPD Note

Name/Age:                    Date:
G_P_L_A_    LMP: __/__/__    EDD: __/__/__ (Naegele's rule)
POG (period of gestation) today: __ wks __ days (by dates/USG)

C/O: ____ (fetal movements, pain, leaking, bleeding, swelling)

CURRENT PREGNANCY:
  Booking visit: __ wks    ANC visits: __
  USG dating: __ wks (if differs from LMP, use USG dates)
  Complications so far: PIH/GDM/Anemia/PROM/none
  Immunization: TT1/TT2 done   Anti-D given (if Rh-neg): Y/N

PAST OBS Hx (for each pregnancy):
  Yr | POG at delivery | Mode | Wt | Sex | Complication | Outcome
  ___|________________|______|____|_____|______________|________

PAST MEDICAL/SURGICAL Hx: ____
DRUG/ALLERGY Hx: ____
FAMILY Hx: ____

O/E:
  GC: ____  P: __  BP: __/__  Wt: __ kg  Ht: __ cm  Pallor/Edema: +/-
  P/A: FH (fundal height) = __ wks   FHS (fetal heart sounds): +/reg __ bpm
       Presentation: ceph/breech/transverse    Lie: long/oblique/transverse
       Engagement: __/5th   Liquor: adequate/reduced (clinical)

Investigations: Hb, urine R/M, BSL, USG, others: ____

Provisional Dx: ____ (e.g., G2P1L1 at __ wks with ____)
Plan: ____

Handy Abbreviation Key (for fast writing)

  • G/P/L/A = Gravida / Para / Living / Abortion
  • LMP / EDD = Last Menstrual Period / Expected Date of Delivery
  • POG = Period of Gestation
  • FH / FHS = Fundal Height / Fetal Heart Sounds
  • P/A, P/S, P/V = Per Abdomen, Per Speculum, Per Vaginum
  • PIH, GDM, PROM = Pregnancy-Induced HTN, Gestational Diabetes, Premature Rupture of Membranes
  • C/O = Complains of; O/E = On Examination
  • Ceph/Breech = Cephalic/Breech presentation
Tip for OPD speed: pre-print or stamp this skeleton on your case sheets so you only fill blanks instead of writing headers each time - most residents keep a rubber stamp or a printed proforma exactly in this G_P_L_A_ / LMP-EDD-POG format for obstetric OPD, and the menstrual/obstetric/contraceptive/sexual/past-gynae block for gynecology OPD.
Want me to generate this as a printable one-page PDF or Word template (with fill-in blanks) that you can physically print and use as a stamp/checklist in clinic?I've created the Word document with the OPD note templates. Here it is:

OG OPD Note Templates

Word Document · DOCX

It contains three pages:
  1. Gynecology OPD Note - chief complaint, menstrual history, obstetric history (G/P/L/A), contraception/sexual history, past gynae history, comorbidities, and an examination section with blank fill-in lines and a findings table.
  2. Obstetric (Antenatal) OPD Note - pregnancy summary (LMP/EDD/POG), current pregnancy details, a past obstetric history table (year, POG at delivery, mode, birth weight, sex, complication, outcome), and a full examination section (fundal height, FHS, presentation, lie, engagement, liquor).
  3. Quick Abbreviation Key - a reference table of all the shorthand (G/P/L/A, LMP/EDD, POG, FH/FHS, P/A-P/S-P/V, PIH/GDM/PROM, etc.) for fast charting.
I wasn't able to generate the matching PDF version in this session (ran out of tool budget before that step). If you'd like, just ask me to "make the PDF version too" in a follow-up and I'll finish it - I can either convert this same layout to PDF or generate it fresh with reportlab.Both files are ready - PDF and Word versions of all 3 pages (Gynecology OPD Note, Obstetric/Antenatal OPD Note, and the Abbreviation Key):

OG OPD Note Templates

PDF Document · PDF

OG OPD Note Templates

Word Document · DOCX

Both contain the same 3-page layout:
  1. Gynecology OPD Note - biodata, chief complaint, menstrual/obstetric/contraceptive/sexual/past gynae history, comorbidities, and an exam section with a findings table.
  2. Obstetric (Antenatal) OPD Note - G/P/L/A, LMP/EDD/POG, current pregnancy details, a past obstetric history table (year, POG, mode, birth weight, sex, complication, outcome), and full antenatal exam fields (fundal height, FHS, presentation, lie, engagement, liquor).
  3. Quick Abbreviation Key - reference table of all shorthand used.
Print the PDF if you want a ready-to-use paper stamp/checklist for clinic, or use the DOCX if you want to edit/customize the fields (font, hospital letterhead, logo, etc.) before printing.# Gyne & Obs OPD: Complaint-wise Drug Reference
Important caveat before you use this: these are standard/common starting doses from major textbooks and guidelines (CDC, WHO, ACOG-referenced sources). Always adjust for the patient's renal/hepatic function, allergies, trimester of pregnancy, local antibiotic resistance patterns, and your institution's protocol. This is a quick-reference aid, not a substitute for clinical judgment on an individual patient.

A. GYNECOLOGY OPD

ComplaintDrug SuggestionDose
DysmenorrheaMefenamic acid500 mg PO TID, start at onset of pain/menses
Ibuprofen400 mg PO TID with food
Naproxen500 mg loading, then 250 mg q6-8h
Abnormal Uterine Bleeding (AUB) / MenorrhagiaTranexamic acid1000-1300 mg PO TID for up to 5 days during heavy flow (FDA-approved for ovulatory AUB)
NSAID (mefenamic acid)500 mg TID during bleeding days
Combined OCP (for hormonal control)1 tab OD as per pack cycle
Levonorgestrel IUDLong-term option - insertion, not oral dosing
Vulvovaginal CandidiasisFluconazole150 mg PO single dose
Clotrimazole vaginal1% cream/pessary OD x 6 days, or 500 mg pessary single dose
Bacterial VaginosisMetronidazole500 mg PO BID x 7 days, or vaginal gel 0.75% OD x 5 days
TrichomoniasisMetronidazole2 g PO single dose, or 500 mg BID x 7 days (treat partner too)
Pelvic Inflammatory Disease (PID)Ceftriaxone + Doxycycline + MetronidazoleCeftriaxone 500 mg IM single dose + Doxycycline 100 mg PO BID x14 days + Metronidazole 500 mg PO BID x14 days (current CDC 2021 regimen - metronidazole now routinely added)
Iron Deficiency Anemia (menorrhagia-related)Ferrous sulfate325 mg PO BID-TID (65 mg elemental iron/dose)
Recurrent Vulvovaginal Candidiasis (prophylaxis)Fluconazole150-200 mg PO weekly (maintenance)
Contraception - EmergencyLevonorgestrel1.5 mg PO single dose within 72 hrs (most effective <24 hrs)
Contraception - RegularCombined OCP1 tab OD, cyclical
Vaginal atrophy/menopausal vaginitisTopical estrogen creamLow-dose applicator, 2-3x/week per product instructions
Vasomotor symptoms (menopause)HRT (estrogen +/- progestin)Lowest effective dose, individualized

B. OBSTETRICS OPD (Antenatal)

ComplaintDrug SuggestionDose
Routine antenatal supplementationFerrous sulfate/fumarate + Folic acidElemental iron 30-60 mg/day (WHO) + Folic acid 400-800 mcg OD
Calcium + Vitamin D500-1000 mg elemental calcium OD-BID
Iron Deficiency Anemia in pregnancyFerrous sulfate325 mg PO OD-BID (ACOG/WHO: at least 30 mg elemental iron/day); consider IV iron if intolerant/severe
Nausea and Vomiting of Pregnancy (mild)Doxylamine + Pyridoxine (Vit B6)10 mg + 10 mg PO, 1-2 tabs at bedtime (first-line, safe in pregnancy)
Hyperemesis Gravidarum (moderate-severe)Ondansetron4 mg PO/IV every 8 hours
Metoclopramide10 mg PO/IV TID (alternative)
Threatened Miscarriage(No proven effective drug per evidence)Bed rest and progesterone are often used clinically but textbooks note no demonstrated efficacy (Berek & Novak's Gynecology) - counsel accordingly, avoid over-promising
Gestational Hypertension / Pre-eclampsia (non-severe, outpatient)Labetalol100-200 mg PO BID-TID (titrate)
Nifedipine (extended release)10-20 mg PO BID
Methyldopa250 mg PO BID-TID
Severe Pre-eclampsia / Eclampsia (seizure prophylaxis - inpatient/emergency, not routine OPD)Magnesium sulfateLoading 4-6 g IV over 15-20 min, then maintenance 1-2 g/hr IV infusion (or Pritchard IM regimen) - refer/admit immediately, do not manage in OPD
Urinary Tract Infection in pregnancyCephalexin500 mg PO BID-QID x 5-7 days
Nitrofurantoin (avoid near term)100 mg PO BID x 5-7 days
Postpartum Hemorrhage prevention (3rd stage)Oxytocin10 IU IM/IV after delivery of baby (WHO first-line)
Misoprostol (if oxytocin unavailable)600 mcg PO for prevention; 800-1000 mcg sublingual/rectal for treatment
PPH treatment (uterine atony, unresponsive to oxytocin)Methylergometrine0.2 mg IM (avoid in hypertensive patients)
Carboprost0.25 mg IM, repeat q15min, max 2 mg total
Vaginal candidiasis in pregnancyClotrimazole (topical only, avoid oral fluconazole in pregnancy)1% cream/pessary OD x 7 days
Threatened Preterm Labor (tocolysis - specialist referral)Nifedipine20 mg PO loading, then 10-20 mg q4-6h (short-term tocolysis)
Fetal lung maturity (preterm risk 24-34 wks)Betamethasone12 mg IM, 2 doses 24 hrs apart

Quick Safety Notes

  • Pregnancy category caution: avoid NSAIDs (mefenamic acid, ibuprofen) after 20 weeks gestation (fetal renal effects) and near term (premature ductus closure). Avoid oral fluconazole and doxycycline/tetracyclines in pregnancy.
  • MgSO4 and severe pre-eclampsia/eclampsia management belongs in an inpatient/emergency setting, not routine OPD - listed here for reference/counseling only.
  • PID and STI regimens should prompt partner treatment and STI screening (HIV, syphilis).
  • Always cross-check with your local antibiotic resistance data and formulary before prescribing.
Sources referenced: CDC STI Treatment Guidelines 2021 (PID regimen), WHO uterotonic recommendations (PPH prevention), Berek & Novak's Gynecology (AUB, threatened abortion), Harrison's Principles of Internal Medicine 22nd ed. (dysmenorrhea), Goldman-Cecil Medicine (hyperemesis, eclampsia), Rosen's Emergency Medicine (eclampsia management box).
Want me to add this as a 4th page to your existing OPD note templates (DOCX/PDF) so you have one combined file with the notes proforma plus this drug quick-reference?Your PDF is ready:

OG OPD Drug Reference

PDF Document · PDF

It contains:
  • Page 1 - Title/disclaimer + full Gynecology OPD drug table (dysmenorrhea, AUB/menorrhagia, candidiasis, bacterial vaginosis, trichomoniasis, PID, anemia, contraception, menopausal symptoms)
  • Page 2 - Obstetrics OPD drug table (antenatal supplementation, anemia, nausea/hyperemesis, threatened miscarriage, hypertension/pre-eclampsia, UTI, PPH prevention/treatment, candidiasis, preterm labor, fetal lung maturity) plus quick safety notes and source citations
You now have 3 files in /tmp/workspace/opd-notes-template/:
  • OG_OPD_Note_Templates.docx / .pdf - the history-taking OPD note proformas
  • OG_OPD_Drug_Reference.pdf - this new drug quick-reference
Let me know if you'd like a Word (.docx) version of the drug reference too, or want it merged into the same file as the note templates.# Common Drug Brands Available in Pakistan (Gyne & Obs OPD)
Brand availability changes over time and multiple manufacturers often market the same generic in Pakistan, so always cross-check with a current local source (MIMS Pakistan, DRAP-approved list, or your hospital pharmacy) before prescribing. Below are well-known, commonly stocked brands for the drugs in your earlier list.

Gynecology

GenericCommon Pakistani Brand(s)Manufacturer
Mefenamic acidPonstan, MefacPfizer/Viatris, Various
Tranexamic acidTransamin, TrapicGetz Pharma, Various
IbuprofenBrufenAbbott
FluconazoleZolanix, Diflucan, FlucosGSK Pakistan, Pfizer, Various
Clotrimazole (vaginal)Candid-V, ClocipGlenmark, Various
MetronidazoleFlagyl, Metryl, AmrizoleSanofi, Various
DoxycyclineDoxef, VibramycinVarious, Pfizer
CeftriaxoneTraxon, RocephinGSK Pakistan, Roche
Ferrous sulfate/fumarate + Folic acidFefol Spansule, Fefol-VitGSK Pakistan
Levonorgestrel (emergency contraception)Postinor-2, i-PillVarious
Combined OCPYasmin, Diane-35, MarvelonBayer, Organon
Levonorgestrel IUDMirenaBayer

Obstetrics

GenericCommon Pakistani Brand(s)Manufacturer
Ferrous fumarate + Folic acid (antenatal)Fefol Spansule, Folart, ObiminGSK Pakistan, Various
Calcium + Vitamin DCalcium Sandoz, Caltrate, Os-CalNovartis, Various
Doxylamine + Pyridoxine (+ Dicyclomine, morning sickness)NavidoxineBarrett Hodgson Pakistan
OndansetronOnset, EmesetGetz Pharma, Various
MetoclopramideMaxolon, GastrolonSanofi, Various
MethyldopaAldomet, DopametOrganon/MSD legacy brands, Various
NifedipineAdalat, Adalat Retard, NifecardBayer, Various
LabetalolLess commonly stocked; Methyldopa/Nifedipine preferred first-line in most Pakistani obstetric units-
Magnesium sulfateMgSO4 injection (generic, hospital pharmacy stock)Various local manufacturers
CephalexinCeporex, SporidexGSK Pakistan, Various
NitrofurantoinFuradantin (limited availability - check local stock)Various
OxytocinSyntocinonNovartis
MisoprostolCytotec, MizotecPfizer (legacy), Various local
MethylergometrineMethergin, ErgometNovartis, Various
BetamethasoneBetnesol, CelestoneGSK Pakistan, Various

Notes

  • Fefol Spansule (ferrous sulfate 150 mg + folic acid 0.5 mg) is the standard GSK Pakistan antenatal iron/folate combination widely prescribed in Pakistani antenatal clinics.
  • Navidoxine is the go-to first-line brand for morning sickness in Pakistani obstetric practice (contains doxylamine + pyridoxine + dicyclomine, slightly different from the pure doxylamine-pyridoxine combination used in the West, but serves the same purpose).
  • Traxon (ceftriaxone, GSK Pakistan) is commonly used for PID and other indications requiring IM/IV ceftriaxone.
  • Carboprost is not as widely stocked in Pakistan outside major tertiary centers; oxytocin (Syntocinon) and misoprostol remain the mainstay for PPH management in most OPD/labor room settings.
  • Always verify current pricing, availability, and DRAP registration status at your local pharmacy, since brands get discontinued or replaced periodically.
Want me to add this Pakistan-brand table as a page in your existing drug reference PDF, so you have one consolidated file (generic + Pakistani brand + dose)?Your consolidated PDF is ready:

OG OPD Drug Reference Pakistan

PDF Document · PDF

It's a single 2-page table with four columns - Presenting Complaint | Drug (Generic) | Pakistan Brand | Dose - covering:
  • Page 1 - Gynecology: dysmenorrhea, AUB/menorrhagia, candidiasis, bacterial vaginosis, trichomoniasis, PID, anemia, contraception (emergency + regular), menopausal symptoms.
  • Page 2 - Obstetrics: antenatal supplementation, anemia, nausea/hyperemesis, threatened miscarriage, hypertension/pre-eclampsia, severe pre-eclampsia/eclampsia, UTI, PPH prevention/treatment, candidiasis in pregnancy, preterm labor, fetal lung maturity - plus quick safety notes and sources at the end.
Everything you asked for (complaint + drug + Pakistani brand + dose) is now in that one file. Let me know if you'd like it merged with your OPD note templates into a single combined booklet, or converted to an editable Word version too.It looks like something's unclear — what would you like to know?
If you were expecting the PDF and it didn't come through, here it is again:

OG OPD Drug Reference Pakistan

PDF Document · PDF

If "??" was about something else (a typo, confusion about content, or a different question), let me know what you meant and I'll sort it out.

The 1st one

Reading File
Reading File
Reading File
Reading File
Reading File
Reading File
Writing File

~/opd-notes-template/make_combined_pdf.py

from reportlab.lib.pagesizes import A4
from reportlab.lib.units import inch
from reportlab.lib import colors
from reportlab.platypus import (SimpleDocTemplate, Paragraph, Spacer, Table, TableStyle,
                                 PageBreak, HRFlowable)
from reportlab.lib.styles import getSampleStyleSheet, ParagraphStyle
from reportlab.lib.enums import TA_CENTER

styles = getSampleStyleSheet()

title_style = ParagraphStyle("TitleC", parent=styles["Title"], fontSize=16, alignment=TA_CENTER, spaceAfter=2)
sub_style = ParagraphStyle("SubC", parent=styles["Normal"], fontSize=9, alignment=TA_CENTER,
                            textColor=colors.HexColor("#555555"), spaceAfter=10, fontName="Helvetica-Oblique")
sec_style = ParagraphStyle("Sec", parent=styles["Normal"], fontSize=11, fontName="Helvetica-Bold",
                            textColor=colors.HexColor("#1F4E79"), backColor=colors.HexColor("#DCE6F1"),
                            spaceBefore=8, spaceAfter=4, leftIndent=3, borderPadding=3)
sec_style2 = ParagraphStyle("Sec2", parent=styles["Normal"], fontSize=12, fontName="Helvetica-Bold",
                             textColor=colors.white, backColor=colors.HexColor("#1F4E79"),
                             spaceBefore=10, spaceAfter=6, leftIndent=4, borderPadding=4)
body_style = ParagraphStyle("Body", parent=styles["Normal"], fontSize=10, spaceAfter=4, leading=14)
small_italic = ParagraphStyle("SmallItalic", parent=styles["Normal"], fontSize=8, fontName="Helvetica-Oblique",
                               textColor=colors.HexColor("#555555"))
cell_style = ParagraphStyle("Cell", parent=styles["Normal"], fontSize=7.8, leading=9.6)
cell_bold = ParagraphStyle("CellBold", parent=cell_style, fontName="Helvetica-Bold")
note_style = ParagraphStyle("Note", parent=styles["Normal"], fontSize=8.3, leading=10.8,
                             textColor=colors.HexColor("#333333"))
warn_style = ParagraphStyle("Warn", parent=styles["Normal"], fontSize=8.8, leading=11.5,
                             textColor=colors.HexColor("#7A1F1F"), fontName="Helvetica-Bold")
src_style = ParagraphStyle("Src", parent=styles["Normal"], fontSize=7.2, leading=9,
                            textColor=colors.HexColor("#666666"), fontName="Helvetica-Oblique")

def blank(label, n=30):
    return Paragraph(f"<b>{label}:</b> " + "_"*n, body_style)

def two_col(label1, n1, label2, n2):
    return Paragraph(f"<b>{label1}:</b> " + "_"*n1 + "&nbsp;&nbsp;&nbsp;&nbsp;<b>" + label2 + ":</b> " + "_"*n2, body_style)

def checkbox(label, options):
    boxes = "&nbsp;&nbsp;&nbsp;".join([f"&#9744; {o}" for o in options])
    return Paragraph(f"<b>{label}:</b> " + boxes, body_style)

def make_blank_table(headers, nrows, col_widths):
    rows = [headers]
    for _ in range(nrows):
        rows.append([""] * len(headers))
    t = Table(rows, colWidths=col_widths, rowHeights=[16] + [18]*nrows)
    t.setStyle(TableStyle([
        ("BACKGROUND", (0, 0), (-1, 0), colors.HexColor("#F2F2F2")),
        ("FONTNAME", (0, 0), (-1, 0), "Helvetica-Bold"),
        ("FONTSIZE", (0, 0), (-1, -1), 8.5),
        ("GRID", (0, 0), (-1, -1), 0.5, colors.HexColor("#999999")),
        ("VALIGN", (0, 0), (-1, -1), "MIDDLE"),
        ("ALIGN", (0, 0), (-1, 0), "CENTER"),
    ]))
    return t

def footer_block():
    elems = []
    elems.append(blank("Provisional Diagnosis", 55))
    elems.append(blank("Plan / Advice / Rx", 60))
    elems.append(Spacer(1, 4))
    for _ in range(3):
        elems.append(HRFlowable(width="100%", thickness=0.5, color=colors.HexColor("#AAAAAA")))
        elems.append(Spacer(1, 8))
    elems.append(Paragraph("Doctor's Signature: " + "_"*25 + "&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Next visit: " + "_"*15, body_style))
    return elems

def P(text, style=cell_style):
    return Paragraph(text, style)

def make_drug_table(rows):
    header = [P("Presenting Complaint", cell_bold), P("Drug (Generic)", cell_bold),
              P("Pakistan Brand", cell_bold), P("Dose", cell_bold)]
    data = [header]
    for complaint, drug, brand, dose in rows:
        data.append([P(complaint), P(drug), P(brand), P(dose)])
    t = Table(data, colWidths=[1.55*inch, 1.35*inch, 1.25*inch, 2.55*inch], repeatRows=1)
    t.setStyle(TableStyle([
        ("BACKGROUND", (0, 0), (-1, 0), colors.HexColor("#DCE6F1")),
        ("GRID", (0, 0), (-1, -1), 0.5, colors.HexColor("#999999")),
        ("VALIGN", (0, 0), (-1, -1), "TOP"),
        ("TOPPADDING", (0, 0), (-1, -1), 3.5),
        ("BOTTOMPADDING", (0, 0), (-1, -1), 3.5),
        ("LEFTPADDING", (0, 0), (-1, -1), 4),
        ("RIGHTPADDING", (0, 0), (-1, -1), 4),
        ("ROWBACKGROUNDS", (0, 1), (-1, -1), [colors.white, colors.HexColor("#F7F9FC")]),
    ]))
    return t

elements = []

# ============ PAGE 1: GYNECOLOGY OPD NOTE ============
elements.append(Paragraph("GYNECOLOGY OPD NOTE", title_style))
elements.append(Paragraph("Quick documentation template", sub_style))
elements.append(Paragraph("Name: " + "_"*30 + "&nbsp;&nbsp;&nbsp;Age: " + "_"*6 + "&nbsp;&nbsp;&nbsp;Date: " + "_"*15, body_style))
elements.append(Paragraph("Marital status: " + "_"*10 + "&nbsp;&nbsp;&nbsp;Occupation: " + "_"*15 + "&nbsp;&nbsp;&nbsp;Reg. No: " + "_"*12, body_style))

elements.append(Paragraph("Chief Complaint(s)", sec_style))
elements.append(Paragraph("_"*100, body_style))
elements.append(Paragraph("_"*100, body_style))

elements.append(Paragraph("Menstrual History", sec_style))
elements.append(two_col("Menarche (yrs)", 6, "LMP", 12))
elements.append(two_col("Cycle length/duration", 10, "Flow (nl/exc/scanty)", 10))
elements.append(checkbox("Dysmenorrhea", ["Yes", "No"]))
elements.append(two_col("Menopause (yrs, if any)", 10, "IMB/PMB", 12))

elements.append(Paragraph("Obstetric History", sec_style))
elements.append(Paragraph("<b>G ___ P ___ L ___ A ___</b>&nbsp;&nbsp;<i>(Gravida / Para / Living / Abortion)</i>", body_style))
elements.append(two_col("Mode of last delivery", 15, "Last delivery (yrs ago)", 8))

elements.append(Paragraph("Contraception &amp; Sexual History", sec_style))
elements.append(two_col("Current method", 12, "Duration", 10))
elements.append(checkbox("Sexually active", ["Yes", "No"]))
elements.append(blank("Dyspareunia / other complaints", 40))

elements.append(Paragraph("Past Gynecological History", sec_style))
elements.append(two_col("Pap smear date/result", 20, "Prior gynae surgery", 20))
elements.append(blank("Infections / STI history", 45))

elements.append(Paragraph("Past Medical / Surgical / Drug / Allergy History", sec_style))
elements.append(checkbox("Comorbidities", ["DM", "HTN", "Thyroid", "TB", "None"]))
elements.append(blank("Drug history", 35))
elements.append(blank("Allergy history", 35))
elements.append(blank("Family history", 45))

elements.append(Paragraph("On Examination", sec_style))
elements.append(two_col("GC", 8, "Pallor", 8))
elements.append(two_col("Pulse", 8, "BP", 10))
elements.append(Spacer(1, 4))
elements.append(make_blank_table(["Exam", "Findings"], 4, [1.6*inch, 5.0*inch]))
elements.append(Spacer(1, 3))
elements.append(Paragraph("(P/A - per abdomen, P/S - per speculum, P/V - per vaginum, Breast)", small_italic))
elements.append(Spacer(1, 6))
elements.extend(footer_block())

elements.append(PageBreak())

# ============ PAGE 2: OBSTETRIC (ANTENATAL) OPD NOTE ============
elements.append(Paragraph("OBSTETRIC (ANTENATAL) OPD NOTE", title_style))
elements.append(Paragraph("Quick documentation template", sub_style))
elements.append(Paragraph("Name: " + "_"*30 + "&nbsp;&nbsp;&nbsp;Age: " + "_"*6 + "&nbsp;&nbsp;&nbsp;Date: " + "_"*15, body_style))

elements.append(Paragraph("Pregnancy Summary", sec_style))
elements.append(Paragraph("<b>G ___ P ___ L ___ A ___</b>", body_style))
elements.append(two_col("LMP", 14, "EDD (Naegele's rule)", 14))
elements.append(two_col("POG today (by dates)", 12, "POG (by USG)", 12))

elements.append(Paragraph("Chief Complaint(s)", sec_style))
elements.append(checkbox("Symptoms", ["Fetal movements +", "Pain", "Leaking", "Bleeding", "Swelling", "None"]))
elements.append(Paragraph("_"*100, body_style))

elements.append(Paragraph("Current Pregnancy Details", sec_style))
elements.append(two_col("Booking visit (wks)", 8, "No. of ANC visits", 8))
elements.append(two_col("USG dating scan (wks)", 10, "TT1 / TT2", 12))
elements.append(checkbox("Complications", ["PIH", "GDM", "Anemia", "PROM", "None"]))
elements.append(checkbox("Rh status", ["Rh +ve", "Rh -ve -> Anti-D given: Yes/No"]))

elements.append(Paragraph("Past Obstetric History", sec_style))
elements.append(Spacer(1, 3))
elements.append(make_blank_table(["Yr", "POG at delivery", "Mode", "Birth wt", "Sex", "Complication", "Outcome"], 3,
                            [0.6*inch, 1.1*inch, 0.9*inch, 0.8*inch, 0.6*inch, 1.4*inch, 1.1*inch]))

elements.append(Paragraph("Past Medical / Surgical / Drug / Allergy / Family History", sec_style))
elements.append(blank("Past medical/surgical history", 45))
elements.append(blank("Drug / Allergy history", 45))
elements.append(blank("Family history", 45))

elements.append(Paragraph("On Examination", sec_style))
elements.append(two_col("GC", 8, "Pallor / Edema", 10))
elements.append(two_col("Pulse", 8, "BP", 10))
elements.append(two_col("Weight (kg)", 8, "Height (cm)", 8))
elements.append(two_col("Fundal Height (wks)", 10, "FHS (bpm)", 10))
elements.append(two_col("Presentation", 12, "Lie", 10))
elements.append(two_col("Engagement (/5th)", 10, "Liquor (clinical)", 12))

elements.append(Paragraph("Investigations", sec_style))
elements.append(checkbox("Sent", ["Hb", "Urine R/M", "BSL", "USG", "Others:"]))
elements.append(Paragraph("_"*60, body_style))
elements.append(Spacer(1, 6))
elements.extend(footer_block())

elements.append(PageBreak())

# ============ PAGE 3: ABBREVIATION KEY ============
elements.append(Paragraph("QUICK ABBREVIATION KEY", title_style))
elements.append(Paragraph("Common shorthand for O&G OPD notes", sub_style))

abbrevs = [
    ("G / P / L / A", "Gravida / Para / Living / Abortion"),
    ("LMP / EDD", "Last Menstrual Period / Expected Date of Delivery"),
    ("POG", "Period of Gestation"),
    ("FH / FHS", "Fundal Height / Fetal Heart Sounds"),
    ("P/A, P/S, P/V", "Per Abdomen, Per Speculum, Per Vaginum"),
    ("PIH, GDM, PROM", "Pregnancy-Induced Hypertension, Gestational Diabetes, Premature Rupture of Membranes"),
    ("C/O", "Complains of"),
    ("O/E", "On Examination"),
    ("Ceph / Breech", "Cephalic / Breech presentation"),
    ("IMB / PMB", "Intermenstrual Bleeding / Postmenopausal Bleeding"),
    ("TT1 / TT2", "Tetanus Toxoid dose 1 / dose 2"),
    ("GC", "General Condition"),
]
data_rows = [[Paragraph(f"<b>{a}</b>", body_style), Paragraph(b, body_style)] for a, b in abbrevs]
t = Table([["Abbreviation", "Meaning"]] + data_rows, colWidths=[1.8*inch, 5.0*inch])
t.setStyle(TableStyle([
    ("BACKGROUND", (0, 0), (-1, 0), colors.HexColor("#F2F2F2")),
    ("FONTNAME", (0, 0), (-1, 0), "Helvetica-Bold"),
    ("FONTSIZE", (0, 0), (-1, -1), 9.5),
    ("GRID", (0, 0), (-1, -1), 0.5, colors.HexColor("#999999")),
    ("VALIGN", (0, 0), (-1, -1), "MIDDLE"),
    ("ALIGN", (0, 0), (-1, 0), "CENTER"),
    ("TOPPADDING", (0, 0), (-1, -1), 4),
    ("BOTTOMPADDING", (0, 0), (-1, -1), 4),
]))
elements.append(t)

elements.append(PageBreak())

# ============ PAGE 4: DRUG REFERENCE - GYNECOLOGY ============
elements.append(Paragraph("GYNE &amp; OBS OPD DRUG REFERENCE - PAKISTAN", title_style))
elements.append(Paragraph("Presenting complaint, generic drug, Pakistani brand, and dose - all in one place", sub_style))

disclaimer = ("CAUTION: Brand availability changes and multiple manufacturers may market the same generic in "
              "Pakistan. Verify current stock, DRAP registration, and price with your local pharmacy/MIMS Pakistan "
              "before prescribing. Always adjust for renal/hepatic function, allergy history, trimester of pregnancy, "
              "and institutional protocol. This is a quick-reference aid, not a substitute for clinical judgment.")
elements.append(Paragraph(disclaimer, warn_style))
elements.append(Spacer(1, 8))

elements.append(Paragraph("A. GYNECOLOGY OPD", sec_style2))

gyne_rows = [
    ("Dysmenorrhea", "Mefenamic acid", "Ponstan, Mefac", "500 mg PO TID, start at onset of pain/menses"),
    ("", "Ibuprofen", "Brufen", "400 mg PO TID with food"),
    ("Abnormal Uterine Bleeding (AUB) / Menorrhagia", "Tranexamic acid", "Transamin, Trapic",
     "1000-1300 mg PO TID for up to 5 days during heavy flow"),
    ("", "Mefenamic acid (NSAID)", "Ponstan, Mefac", "500 mg TID during bleeding days"),
    ("", "Combined OCP", "Yasmin, Diane-35, Marvelon", "1 tab OD as per pack cycle"),
    ("", "Levonorgestrel IUD", "Mirena", "Long-term option - insertion, not oral dosing"),
    ("Vulvovaginal Candidiasis", "Fluconazole", "Zolanix, Diflucan, Flucos", "150 mg PO single dose"),
    ("", "Clotrimazole vaginal", "Candid-V, Clocip", "1% cream/pessary OD x 6 days, or 500 mg pessary single dose"),
    ("Bacterial Vaginosis", "Metronidazole", "Flagyl, Metryl, Amrizole", "500 mg PO BID x 7 days, or vaginal gel 0.75% OD x 5 days"),
    ("Trichomoniasis", "Metronidazole", "Flagyl, Metryl", "2 g PO single dose, or 500 mg BID x 7 days (treat partner too)"),
    ("Pelvic Inflammatory Disease (PID)", "Ceftriaxone", "Traxon, Rocephin", "500 mg IM single dose"),
    ("", "+ Doxycycline", "Doxef, Vibramycin", "100 mg PO BID x 14 days"),
    ("", "+ Metronidazole", "Flagyl, Metryl", "500 mg PO BID x 14 days"),
    ("Iron Deficiency Anemia (menorrhagia-related)", "Ferrous sulfate/fumarate + Folic acid", "Fefol Spansule, Fefol-Vit",
     "1 capsule OD-BID (150 mg iron + 0.5 mg folic acid per dose)"),
    ("Recurrent Vulvovaginal Candidiasis (prophylaxis)", "Fluconazole", "Zolanix, Diflucan", "150-200 mg PO weekly (maintenance)"),
    ("Emergency Contraception", "Levonorgestrel", "Postinor-2, i-Pill", "1.5 mg PO single dose within 72 hrs (best <24 hrs)"),
    ("Regular Contraception", "Combined OCP", "Yasmin, Diane-35, Marvelon", "1 tab OD, cyclical"),
    ("Vaginal atrophy / menopausal vaginitis", "Topical estrogen cream", "Premarin cream (where available)",
     "Low-dose applicator, 2-3x/week per product instructions"),
    ("Vasomotor symptoms (menopause)", "HRT (estrogen +/- progestin)", "Premarin, Angeliq (where available)",
     "Lowest effective dose, individualized"),
]
elements.append(make_drug_table(gyne_rows))

elements.append(PageBreak())

# ============ PAGE 5: DRUG REFERENCE - OBSTETRICS ============
elements.append(Paragraph("B. OBSTETRICS OPD (ANTENATAL)", sec_style2))

obs_rows = [
    ("Routine antenatal supplementation", "Ferrous fumarate + Folic acid", "Fefol Spansule, Folart, Obimin",
     "1 capsule/tablet OD (approx. 150 mg iron + 0.5 mg folic acid)"),
    ("", "Calcium + Vitamin D", "Calcium Sandoz, Caltrate, Os-Cal", "500-1000 mg elemental calcium OD-BID"),
    ("Iron Deficiency Anemia in pregnancy", "Ferrous sulfate", "Fefol Spansule", "1 capsule OD-BID; consider IV iron if intolerant/severe"),
    ("Nausea and Vomiting of Pregnancy (mild)", "Doxylamine + Pyridoxine (+ Dicyclomine)", "Navidoxine",
     "1 tab at bedtime, may increase to BID (first-line, safe in pregnancy)"),
    ("Hyperemesis Gravidarum (moderate-severe)", "Ondansetron", "Onset, Emeset", "4 mg PO/IV every 8 hours"),
    ("", "Metoclopramide", "Maxolon, Gastrolon", "10 mg PO/IV TID (alternative)"),
    ("Threatened Miscarriage", "(No proven effective drug per evidence)", "-",
     "Bed rest/progesterone often used clinically but no demonstrated efficacy - counsel accordingly"),
    ("Gestational Hypertension / Pre-eclampsia (non-severe, outpatient)", "Methyldopa", "Aldomet, Dopamet",
     "250 mg PO BID-TID"),
    ("", "Nifedipine (extended release)", "Adalat Retard, Nifecard", "10-20 mg PO BID"),
    ("", "Labetalol (less commonly stocked)", "-", "100-200 mg PO BID-TID if available"),
    ("Severe Pre-eclampsia / Eclampsia (admit, not OPD)", "Magnesium sulfate", "MgSO4 injection (generic)",
     "Loading 4-6 g IV over 15-20 min, then maintenance 1-2 g/hr IV - refer/admit immediately"),
    ("Urinary Tract Infection in pregnancy", "Cephalexin", "Ceporex, Sporidex", "500 mg PO BID-QID x 5-7 days"),
    ("", "Nitrofurantoin (avoid near term, limited stock)", "Furadantin", "100 mg PO BID x 5-7 days"),
    ("Postpartum Hemorrhage prevention (3rd stage)", "Oxytocin", "Syntocinon", "10 IU IM/IV after delivery of baby"),
    ("", "Misoprostol (if oxytocin unavailable)", "Cytotec, Mizotec", "600 mcg PO for prevention; 800-1000 mcg sublingual/rectal for treatment"),
    ("PPH treatment (uterine atony, unresponsive to oxytocin)", "Methylergometrine", "Methergin, Ergomet",
     "0.2 mg IM (avoid in hypertensive patients)"),
    ("Vaginal candidiasis in pregnancy", "Clotrimazole (topical only)", "Candid-V, Clocip", "1% cream/pessary OD x 7 days"),
    ("Threatened Preterm Labor (tocolysis - specialist referral)", "Nifedipine", "Adalat, Nifecard",
     "20 mg PO loading, then 10-20 mg q4-6h (short-term tocolysis)"),
    ("Fetal lung maturity (preterm risk 24-34 wks)", "Betamethasone", "Betnesol, Celestone", "12 mg IM, 2 doses 24 hrs apart"),
]
elements.append(make_drug_table(obs_rows))

elements.append(Spacer(1, 8))
elements.append(Paragraph("Quick Safety Notes", sec_style2))
notes = [
    "Avoid NSAIDs (mefenamic acid, ibuprofen) after 20 weeks gestation and near term.",
    "Avoid oral fluconazole and doxycycline/tetracyclines in pregnancy - use topical antifungals and alternative antibiotics.",
    "MgSO4 for severe pre-eclampsia/eclampsia is inpatient/emergency management only - refer, do not manage in OPD.",
    "PID and STI regimens should prompt partner treatment and STI screening.",
    "Multiple brands exist per generic in Pakistan - confirm current availability with your pharmacy before prescribing.",
]
for n in notes:
    elements.append(Paragraph("&#8226; " + n, note_style))
    elements.append(Spacer(1, 2))

elements.append(Spacer(1, 8))
elements.append(Paragraph(
    "Sources: CDC STI Treatment Guidelines 2021, WHO uterotonic recommendations, Berek &amp; Novak's Gynecology, "
    "Harrison's Principles of Internal Medicine 22nd ed., Goldman-Cecil Medicine, Rosen's Emergency Medicine, "
    "and GSK Pakistan product listings (Fefol, Zolanix, Traxon) cross-checked for local brand names.", src_style))

doc = SimpleDocTemplate("/tmp/workspace/opd-notes-template/OG_OPD_Complete_Booklet.pdf",
                         pagesize=A4,
                         topMargin=0.5*inch, bottomMargin=0.5*inch,
                         leftMargin=0.55*inch, rightMargin=0.55*inch)
doc.build(elements)
print("combined booklet pdf saved")
Running Command

cd /tmp/workspace/opd-notes-template && python3 make_combined_pdf.py && ls -la

Writing File

~/opd-notes-template/make_combined_docx.py

from docx import Document
from docx.shared import Pt, Inches, RGBColor
from docx.enum.text import WD_ALIGN_PARAGRAPH
from docx.enum.table import WD_TABLE_ALIGNMENT
from docx.oxml.ns import qn
from docx.oxml import OxmlElement

def set_cell_border(cell):
    tc = cell._tc
    tcPr = tc.get_or_add_tcPr()
    tcBorders = OxmlElement('w:tcBorders')
    for edge in ('top', 'left', 'bottom', 'right'):
        el = OxmlElement(f'w:{edge}')
        el.set(qn('w:val'), 'single')
        el.set(qn('w:sz'), '4')
        el.set(qn('w:space'), '0')
        el.set(qn('w:color'), '999999')
        tcBorders.append(el)
    tcPr.append(tcBorders)

def shade_cell(cell, hexcolor):
    shd = OxmlElement('w:shd')
    shd.set(qn('w:val'), 'clear')
    shd.set(qn('w:fill'), hexcolor)
    cell._tc.get_or_add_tcPr().append(shd)

doc = Document()
section = doc.sections[0]
section.top_margin = Inches(0.5)
section.bottom_margin = Inches(0.5)
section.left_margin = Inches(0.55)
section.right_margin = Inches(0.55)

style = doc.styles["Normal"]
style.font.name = "Arial"
style.font.size = Pt(10.5)

def add_title(text, subtitle=None):
    h = doc.add_paragraph()
    h.alignment = WD_ALIGN_PARAGRAPH.CENTER
    run = h.add_run(text)
    run.bold = True
    run.font.size = Pt(16)
    if subtitle:
        s = doc.add_paragraph()
        s.alignment = WD_ALIGN_PARAGRAPH.CENTER
        r2 = s.add_run(subtitle)
        r2.italic = True
        r2.font.size = Pt(10)
        r2.font.color.rgb = RGBColor(0x55, 0x55, 0x55)

def add_section_heading(text, dark=False):
    p = doc.add_paragraph()
    p.paragraph_format.space_before = Pt(8)
    p.paragraph_format.space_after = Pt(2)
    run = p.add_run(text)
    run.bold = True
    run.font.size = Pt(11.5) if not dark else Pt(13)
    run.font.color.rgb = RGBColor(0x1F, 0x4E, 0x79) if not dark else RGBColor(0xFF, 0xFF, 0xFF)
    pPr = p._p.get_or_add_pPr()
    shd = OxmlElement('w:shd')
    shd.set(qn('w:val'), 'clear')
    shd.set(qn('w:fill'), 'DCE6F1' if not dark else '1F4E79')
    pPr.append(shd)

def blank_line(label, width_chars=28):
    p = doc.add_paragraph()
    p.paragraph_format.space_after = Pt(3)
    r1 = p.add_run(label + ": ")
    r1.bold = True
    r1.font.size = Pt(10.5)
    r2 = p.add_run("_" * width_chars)
    r2.font.size = Pt(10.5)

def two_col_blank(label1, w1, label2, w2):
    p = doc.add_paragraph()
    p.paragraph_format.space_after = Pt(3)
    r1 = p.add_run(label1 + ": ")
    r1.bold = True
    r2 = p.add_run("_" * w1 + "     ")
    r3 = p.add_run(label2 + ": ")
    r3.bold = True
    r4 = p.add_run("_" * w2)
    for r in (r1, r2, r3, r4):
        r.font.size = Pt(10.5)

def checkbox_line(label, options):
    p = doc.add_paragraph()
    p.paragraph_format.space_after = Pt(3)
    r1 = p.add_run(label + ": ")
    r1.bold = True
    r1.font.size = Pt(10.5)
    r2 = p.add_run("   ".join([f"\u2610 {o}" for o in options]))
    r2.font.size = Pt(10.5)

def add_blank_table(headers, nrows, col_widths=None):
    t = doc.add_table(rows=nrows+1, cols=len(headers))
    t.alignment = WD_TABLE_ALIGNMENT.CENTER
    for j, htext in enumerate(headers):
        cell = t.rows[0].cells[j]
        cell.text = ""
        run = cell.paragraphs[0].add_run(htext)
        run.bold = True
        run.font.size = Pt(9.5)
        set_cell_border(cell)
        shade_cell(cell, 'F2F2F2')
    for i in range(1, nrows+1):
        for j in range(len(headers)):
            cell = t.rows[i].cells[j]
            cell.text = ""
            cell.paragraphs[0].add_run(" ")
            set_cell_border(cell)
    if col_widths:
        for row in t.rows:
            for j, w in enumerate(col_widths):
                row.cells[j].width = Inches(w)
    return t

def footer_note():
    p = doc.add_paragraph()
    p.paragraph_format.space_before = Pt(6)
    r = p.add_run("Provisional Diagnosis: " + "_"*55)
    r.bold = True
    r.font.size = Pt(10.5)
    p2 = doc.add_paragraph()
    r2 = p2.add_run("Plan / Advice / Rx: ")
    r2.bold = True
    r2.font.size = Pt(10.5)
    p2.add_run("_"*60).font.size = Pt(10.5)
    for _ in range(3):
        p3 = doc.add_paragraph("_" * 95)
        p3.paragraph_format.space_after = Pt(2)
    p4 = doc.add_paragraph()
    r4 = p4.add_run("Doctor's Signature: " + "_"*25 + "        Next visit: " + "_"*15)
    r4.font.size = Pt(10.5)

def add_drug_table(rows):
    headers = ["Presenting Complaint", "Drug (Generic)", "Pakistan Brand", "Dose"]
    t = doc.add_table(rows=len(rows)+1, cols=4)
    t.alignment = WD_TABLE_ALIGNMENT.CENTER
    widths = [1.7, 1.5, 1.4, 2.4]
    for j, htext in enumerate(headers):
        cell = t.rows[0].cells[j]
        cell.text = ""
        run = cell.paragraphs[0].add_run(htext)
        run.bold = True
        run.font.size = Pt(9)
        set_cell_border(cell)
        shade_cell(cell, 'DCE6F1')
    for i, row in enumerate(rows, start=1):
        for j, val in enumerate(row):
            cell = t.rows[i].cells[j]
            cell.text = ""
            run = cell.paragraphs[0].add_run(val)
            run.font.size = Pt(8.5)
            set_cell_border(cell)
            if i % 2 == 0:
                shade_cell(cell, 'F7F9FC')
    for row in t.rows:
        for j, w in enumerate(widths):
            row.cells[j].width = Inches(w)
    return t

# ============ PAGE 1: GYNECOLOGY OPD NOTE ============
add_title("GYNECOLOGY OPD NOTE", "Quick documentation template")
p = doc.add_paragraph()
p.add_run("Name: " + "_"*30 + "   Age: " + "_"*6 + "   Date: " + "_"*15).font.size = Pt(10.5)
p2 = doc.add_paragraph()
p2.add_run("Marital status: " + "_"*10 + "    Occupation: " + "_"*15 + "    Reg. No: " + "_"*12).font.size = Pt(10.5)

add_section_heading("Chief Complaint(s)")
for _ in range(2):
    doc.add_paragraph("_" * 100).paragraph_format.space_after = Pt(2)

add_section_heading("Menstrual History")
two_col_blank("Menarche (yrs)", 6, "LMP", 12)
two_col_blank("Cycle length/duration", 10, "Flow (nl/exc/scanty)", 10)
checkbox_line("Dysmenorrhea", ["Yes", "No"])
two_col_blank("Menopause (yrs, if any)", 10, "IMB/PMB", 12)

add_section_heading("Obstetric History")
p = doc.add_paragraph()
r1 = p.add_run("G ___ P ___ L ___ A ___   ")
r1.bold = True
r1.font.size = Pt(11)
r2 = p.add_run("(Gravida / Para / Living / Abortion)")
r2.italic = True
r2.font.size = Pt(9)
two_col_blank("Mode of last delivery", 15, "Last delivery (yrs ago)", 8)

add_section_heading("Contraception & Sexual History")
two_col_blank("Current method", 12, "Duration", 10)
checkbox_line("Sexually active", ["Yes", "No"])
blank_line("Dyspareunia / other complaints", 40)

add_section_heading("Past Gynecological History")
two_col_blank("Pap smear date/result", 20, "Prior gynae surgery", 20)
blank_line("Infections / STI history", 45)

add_section_heading("Past Medical / Surgical / Drug / Allergy History")
checkbox_line("Comorbidities", ["DM", "HTN", "Thyroid", "TB", "None"])
blank_line("Drug history", 35)
blank_line("Allergy history", 35)
blank_line("Family history", 45)

add_section_heading("On Examination")
two_col_blank("GC", 8, "Pallor", 8)
two_col_blank("Pulse", 8, "BP", 10)
add_blank_table(["Exam", "Findings"], 4, col_widths=[1.6, 5.5])
p = doc.add_paragraph()
r = p.add_run("(P/A - per abdomen, P/S - per speculum, P/V - per vaginum, Breast)")
r.italic = True
r.font.size = Pt(8.5)

footer_note()
doc.add_page_break()

# ============ PAGE 2: OBSTETRIC (ANTENATAL) OPD NOTE ============
add_title("OBSTETRIC (ANTENATAL) OPD NOTE", "Quick documentation template")
p = doc.add_paragraph()
p.add_run("Name: " + "_"*30 + "   Age: " + "_"*6 + "   Date: " + "_"*15).font.size = Pt(10.5)

add_section_heading("Pregnancy Summary")
p = doc.add_paragraph()
r1 = p.add_run("G ___ P ___ L ___ A ___   ")
r1.bold = True
r1.font.size = Pt(11)
two_col_blank("LMP", 14, "EDD (Naegele's rule)", 14)
two_col_blank("POG today (by dates)", 12, "POG (by USG)", 12)

add_section_heading("Chief Complaint(s)")
checkbox_line("Symptoms", ["Fetal movements +", "Pain", "Leaking", "Bleeding", "Swelling", "None"])
doc.add_paragraph("_" * 100).paragraph_format.space_after = Pt(2)

add_section_heading("Current Pregnancy Details")
two_col_blank("Booking visit (wks)", 8, "No. of ANC visits", 8)
two_col_blank("USG dating scan (wks)", 10, "TT1 / TT2", 12)
checkbox_line("Complications", ["PIH", "GDM", "Anemia", "PROM", "None"])
checkbox_line("Rh status", ["Rh +ve", "Rh -ve -> Anti-D given: Yes/No"])

add_section_heading("Past Obstetric History")
add_blank_table(["Yr", "POG at delivery", "Mode", "Birth wt", "Sex", "Complication", "Outcome"], 3,
          col_widths=[0.6, 1.1, 0.9, 0.8, 0.6, 1.4, 1.1])

add_section_heading("Past Medical / Surgical / Drug / Allergy / Family History")
blank_line("Past medical/surgical history", 45)
blank_line("Drug / Allergy history", 45)
blank_line("Family history", 45)

add_section_heading("On Examination")
two_col_blank("GC", 8, "Pallor / Edema", 10)
two_col_blank("Pulse", 8, "BP", 10)
two_col_blank("Weight (kg)", 8, "Height (cm)", 8)
two_col_blank("Fundal Height (wks)", 10, "FHS (bpm)", 10)
two_col_blank("Presentation", 12, "Lie", 10)
two_col_blank("Engagement (/5th)", 10, "Liquor (clinical)", 12)

add_section_heading("Investigations")
checkbox_line("Sent", ["Hb", "Urine R/M", "BSL", "USG", "Others:"])
doc.add_paragraph("_" * 60)

footer_note()
doc.add_page_break()

# ============ PAGE 3: ABBREVIATION KEY ============
add_title("QUICK ABBREVIATION KEY", "Common shorthand for O&G OPD notes")
abbrevs = [
    ("G / P / L / A", "Gravida / Para / Living / Abortion"),
    ("LMP / EDD", "Last Menstrual Period / Expected Date of Delivery"),
    ("POG", "Period of Gestation"),
    ("FH / FHS", "Fundal Height / Fetal Heart Sounds"),
    ("P/A, P/S, P/V", "Per Abdomen, Per Speculum, Per Vaginum"),
    ("PIH, GDM, PROM", "Pregnancy-Induced Hypertension, Gestational Diabetes, Premature Rupture of Membranes"),
    ("C/O", "Complains of"),
    ("O/E", "On Examination"),
    ("Ceph / Breech", "Cephalic / Breech presentation"),
    ("IMB / PMB", "Intermenstrual Bleeding / Postmenopausal Bleeding"),
    ("TT1 / TT2", "Tetanus Toxoid dose 1 / dose 2"),
    ("GC", "General Condition"),
]
t = doc.add_table(rows=len(abbrevs)+1, cols=2)
t.alignment = WD_TABLE_ALIGNMENT.CENTER
for j, htext in enumerate(["Abbreviation", "Meaning"]):
    cell = t.rows[0].cells[j]
    run = cell.paragraphs[0].add_run(htext)
    run.bold = True
    set_cell_border(cell)
    shade_cell(cell, 'F2F2F2')
for i, (a, b) in enumerate(abbrevs, start=1):
    c0 = t.rows[i].cells[0]
    r0 = c0.paragraphs[0].add_run(a)
    r0.bold = True
    set_cell_border(c0)
    c1 = t.rows[i].cells[1]
    c1.paragraphs[0].add_run(b)
    set_cell_border(c1)
for row in t.rows:
    row.cells[0].width = Inches(1.8)
    row.cells[1].width = Inches(5.3)

doc.add_page_break()

# ============ PAGE 4: DRUG REFERENCE INTRO + GYNECOLOGY ============
add_title("GYNE & OBS OPD DRUG REFERENCE - PAKISTAN", "Presenting complaint, generic drug, Pakistani brand, and dose - all in one place")

p = doc.add_paragraph()
r = p.add_run("CAUTION: Brand availability changes and multiple manufacturers may market the same generic in "
              "Pakistan. Verify current stock, DRAP registration, and price with your local pharmacy/MIMS Pakistan "
              "before prescribing. Always adjust for renal/hepatic function, allergy history, trimester of pregnancy, "
              "and institutional protocol. This is a quick-reference aid, not a substitute for clinical judgment.")
r.bold = True
r.font.size = Pt(9)
r.font.color.rgb = RGBColor(0x7A, 0x1F, 0x1F)

add_section_heading("A. GYNECOLOGY OPD", dark=True)

gyne_rows = [
    ("Dysmenorrhea", "Mefenamic acid", "Ponstan, Mefac", "500 mg PO TID, start at onset of pain/menses"),
    ("", "Ibuprofen", "Brufen", "400 mg PO TID with food"),
    ("Abnormal Uterine Bleeding (AUB) / Menorrhagia", "Tranexamic acid", "Transamin, Trapic",
     "1000-1300 mg PO TID for up to 5 days during heavy flow"),
    ("", "Mefenamic acid (NSAID)", "Ponstan, Mefac", "500 mg TID during bleeding days"),
    ("", "Combined OCP", "Yasmin, Diane-35, Marvelon", "1 tab OD as per pack cycle"),
    ("", "Levonorgestrel IUD", "Mirena", "Long-term option - insertion, not oral dosing"),
    ("Vulvovaginal Candidiasis", "Fluconazole", "Zolanix, Diflucan, Flucos", "150 mg PO single dose"),
    ("", "Clotrimazole vaginal", "Candid-V, Clocip", "1% cream/pessary OD x 6 days, or 500 mg pessary single dose"),
    ("Bacterial Vaginosis", "Metronidazole", "Flagyl, Metryl, Amrizole", "500 mg PO BID x 7 days, or vaginal gel 0.75% OD x 5 days"),
    ("Trichomoniasis", "Metronidazole", "Flagyl, Metryl", "2 g PO single dose, or 500 mg BID x 7 days (treat partner too)"),
    ("Pelvic Inflammatory Disease (PID)", "Ceftriaxone", "Traxon, Rocephin", "500 mg IM single dose"),
    ("", "+ Doxycycline", "Doxef, Vibramycin", "100 mg PO BID x 14 days"),
    ("", "+ Metronidazole", "Flagyl, Metryl", "500 mg PO BID x 14 days"),
    ("Iron Deficiency Anemia (menorrhagia-related)", "Ferrous sulfate/fumarate + Folic acid", "Fefol Spansule, Fefol-Vit",
     "1 capsule OD-BID (150 mg iron + 0.5 mg folic acid per dose)"),
    ("Recurrent Vulvovaginal Candidiasis (prophylaxis)", "Fluconazole", "Zolanix, Diflucan", "150-200 mg PO weekly (maintenance)"),
    ("Emergency Contraception", "Levonorgestrel", "Postinor-2, i-Pill", "1.5 mg PO single dose within 72 hrs (best <24 hrs)"),
    ("Regular Contraception", "Combined OCP", "Yasmin, Diane-35, Marvelon", "1 tab OD, cyclical"),
    ("Vaginal atrophy / menopausal vaginitis", "Topical estrogen cream", "Premarin cream (where available)",
     "Low-dose applicator, 2-3x/week per product instructions"),
    ("Vasomotor symptoms (menopause)", "HRT (estrogen +/- progestin)", "Premarin, Angeliq (where available)",
     "Lowest effective dose, individualized"),
]
add_drug_table(gyne_rows)

doc.add_page_break()

# ============ PAGE 5: DRUG REFERENCE - OBSTETRICS ============
add_section_heading("B. OBSTETRICS OPD (ANTENATAL)", dark=True)

obs_rows = [
    ("Routine antenatal supplementation", "Ferrous fumarate + Folic acid", "Fefol Spansule, Folart, Obimin",
     "1 capsule/tablet OD (approx. 150 mg iron + 0.5 mg folic acid)"),
    ("", "Calcium + Vitamin D", "Calcium Sandoz, Caltrate, Os-Cal", "500-1000 mg elemental calcium OD-BID"),
    ("Iron Deficiency Anemia in pregnancy", "Ferrous sulfate", "Fefol Spansule", "1 capsule OD-BID; consider IV iron if intolerant/severe"),
    ("Nausea and Vomiting of Pregnancy (mild)", "Doxylamine + Pyridoxine (+ Dicyclomine)", "Navidoxine",
     "1 tab at bedtime, may increase to BID (first-line, safe in pregnancy)"),
    ("Hyperemesis Gravidarum (moderate-severe)", "Ondansetron", "Onset, Emeset", "4 mg PO/IV every 8 hours"),
    ("", "Metoclopramide", "Maxolon, Gastrolon", "10 mg PO/IV TID (alternative)"),
    ("Threatened Miscarriage", "(No proven effective drug per evidence)", "-",
     "Bed rest/progesterone often used clinically but no demonstrated efficacy - counsel accordingly"),
    ("Gestational Hypertension / Pre-eclampsia (non-severe, outpatient)", "Methyldopa", "Aldomet, Dopamet",
     "250 mg PO BID-TID"),
    ("", "Nifedipine (extended release)", "Adalat Retard, Nifecard", "10-20 mg PO BID"),
    ("", "Labetalol (less commonly stocked)", "-", "100-200 mg PO BID-TID if available"),
    ("Severe Pre-eclampsia / Eclampsia (admit, not OPD)", "Magnesium sulfate", "MgSO4 injection (generic)",
     "Loading 4-6 g IV over 15-20 min, then maintenance 1-2 g/hr IV - refer/admit immediately"),
    ("Urinary Tract Infection in pregnancy", "Cephalexin", "Ceporex, Sporidex", "500 mg PO BID-QID x 5-7 days"),
    ("", "Nitrofurantoin (avoid near term, limited stock)", "Furadantin", "100 mg PO BID x 5-7 days"),
    ("Postpartum Hemorrhage prevention (3rd stage)", "Oxytocin", "Syntocinon", "10 IU IM/IV after delivery of baby"),
    ("", "Misoprostol (if oxytocin unavailable)", "Cytotec, Mizotec", "600 mcg PO for prevention; 800-1000 mcg sublingual/rectal for treatment"),
    ("PPH treatment (uterine atony, unresponsive to oxytocin)", "Methylergometrine", "Methergin, Ergomet",
     "0.2 mg IM (avoid in hypertensive patients)"),
    ("Vaginal candidiasis in pregnancy", "Clotrimazole (topical only)", "Candid-V, Clocip", "1% cream/pessary OD x 7 days"),
    ("Threatened Preterm Labor (tocolysis - specialist referral)", "Nifedipine", "Adalat, Nifecard",
     "20 mg PO loading, then 10-20 mg q4-6h (short-term tocolysis)"),
    ("Fetal lung maturity (preterm risk 24-34 wks)", "Betamethasone", "Betnesol, Celestone", "12 mg IM, 2 doses 24 hrs apart"),
]
add_drug_table(obs_rows)

add_section_heading("Quick Safety Notes", dark=True)
notes = [
    "Avoid NSAIDs (mefenamic acid, ibuprofen) after 20 weeks gestation and near term.",
    "Avoid oral fluconazole and doxycycline/tetracyclines in pregnancy - use topical antifungals and alternative antibiotics.",
    "MgSO4 for severe pre-eclampsia/eclampsia is inpatient/emergency management only - refer, do not manage in OPD.",
    "PID and STI regimens should prompt partner treatment and STI screening.",
    "Multiple brands exist per generic in Pakistan - confirm current availability with your pharmacy before prescribing.",
]
for n in notes:
    p = doc.add_paragraph("\u2022 " + n)
    p.paragraph_format.space_after = Pt(2)
    for run in p.runs:
        run.font.size = Pt(9.5)

p = doc.add_paragraph()
r = p.add_run("Sources: CDC STI Treatment Guidelines 2021, WHO uterotonic recommendations, Berek & Novak's "
              "Gynecology, Harrison's Principles of Internal Medicine 22nd ed., Goldman-Cecil Medicine, Rosen's "
              "Emergency Medicine, and GSK Pakistan product listings (Fefol, Zolanix, Traxon) cross-checked for "
              "local brand names.")
r.italic = True
r.font.size = Pt(7.5)
r.font.color.rgb = RGBColor(0x66, 0x66, 0x66)

doc.save("/tmp/workspace/opd-notes-template/OG_OPD_Complete_Booklet.docx")
print("combined booklet docx saved")
Running Command

cd /tmp/workspace/opd-notes-template && python3 make_combined_docx.py && ls -la

Both combined booklets are ready - everything merged into single files:

OG OPD Complete Booklet

PDF Document · PDF

OG OPD Complete Booklet

Word Document · DOCX

Each file now has 5 pages in one place:
  1. Gynecology OPD Note (history-taking template)
  2. Obstetric (Antenatal) OPD Note (history-taking template)
  3. Quick Abbreviation Key
  4. Gynecology Drug Reference - complaint, generic drug, Pakistan brand, dose
  5. Obstetrics Drug Reference - complaint, generic drug, Pakistan brand, dose + safety notes and sources
Use the PDF for printing/quick reference in clinic, or the DOCX if you want to edit/customize anything (add your clinic letterhead, tweak fields, etc.) before printing.
This is a shared conversation. Sign in to Orris to start your own chat.