Find the medicine
ffmpeg -i /home/daytona/workspace/attachments/17992b05-127c-43a2-83c2-dd61966c29f4/20260518_193601.mp4 -vf "fps=1" /home/daytona/workspace/attachments/17992b05-127c-43a2-83c2-dd61966c29f4/frame_%03d.jpg 2>&1 | tail -20
| # | Medicine | Details |
|---|---|---|
| — | Dysona / Thyrox 50mcg | (likely Thyrox 50 – levothyroxine) |
| — | Bric pris | DM — Glimepiride 0.5g (or similar) |
| — | No surgery | (note/instruction) |
| 1 | Tab. Voglibose (Vomaloy?) | 1-0-1 × 10 days |
| ① | Tab. Ecospin AV 75/10 | OD (once daily) |
| ② | Tab. Nitsat SR 2gr | 1-2-0 × 20 days (likely Nicorandil SR or Nitroglycerin SR) |
| ③ | Tab. Thyrox 75mcg | 1-2-0 |
| ④ | Tab. Dytor Plus 5mg (Dytor Plus 10?) | ½ × 2 × 15 days (likely Torsemide + Spironolactone) |
⚠️ Note: Doctor's handwriting is difficult to read precisely. Please verify each medicine name with your pharmacist or the prescribing doctor (Dr. Arun More, MBBS PGDCC MBA) before dispensing.
Create a medicine schedule/reminder document for patient
ls /home/daytona/workspace/ && ls /home/daytona/skills/docx/scripts/office/ 2>/dev/null || echo "no scripts dir"
mkdir -p /home/daytona/workspace/medicine-schedule && cat > /home/daytona/workspace/medicine-schedule/create_schedule.js << 'EOF' const { Document, Packer, Paragraph, TextRun, Table, TableRow, TableCell, AlignmentType, HeadingLevel, BorderStyle, WidthType, ShadingType, VerticalAlign, Header, Footer, PageNumber, NumberFormat } = require('docx'); const fs = require('fs'); // Color palette const DARK_BLUE = "1B3A6B"; const LIGHT_BLUE = "D6E4F7"; const MED_BLUE = "2E6DB4"; const HEADER_BG = "1B3A6B"; const TABLE_HEADER_BG = "2E6DB4"; const ALT_ROW = "EBF3FD"; const WHITE = "FFFFFF"; const DARK_TEXT = "1A1A2E"; const ACCENT_GREEN = "27AE60"; const ACCENT_ORANGE = "E67E22"; const ACCENT_RED = "C0392B"; const LIGHT_GRAY = "F5F5F5"; function cell(text, opts = {}) { const { bold = false, color = DARK_TEXT, bg = WHITE, size = 20, align = AlignmentType.LEFT, vAlign = VerticalAlign.CENTER, italic = false, colspan = 1 } = opts; return new TableCell({ columnSpan: colspan, verticalAlign: vAlign, shading: { fill: bg, type: ShadingType.CLEAR, color: "auto" }, margins: { top: 80, bottom: 80, left: 120, right: 120 }, children: [new Paragraph({ alignment: align, children: [new TextRun({ text, bold, color, size, italics: italic, font: "Calibri" })] })] }); } function headerCell(text, opts = {}) { return cell(text, { bold: true, color: WHITE, bg: TABLE_HEADER_BG, size: 20, align: AlignmentType.CENTER, ...opts }); } function sectionHeading(text, color = MED_BLUE) { return new Paragraph({ spacing: { before: 240, after: 100 }, children: [new TextRun({ text, bold: true, color, size: 26, font: "Calibri" })] }); } function spacer(lines = 1) { return new Paragraph({ spacing: { before: lines * 60, after: lines * 60 }, children: [new TextRun("")] }); } function bullet(text, subtext = null) { const runs = [new TextRun({ text: "• " + text, size: 20, font: "Calibri", color: DARK_TEXT })]; if (subtext) runs.push(new TextRun({ text: " " + subtext, size: 18, font: "Calibri", color: "555555", italics: true })); return new Paragraph({ spacing: { before: 40, after: 40 }, children: runs }); } // ─── MEDICINE DATA ─────────────────────────────────────────────────────────── const medicines = [ { no: "1", name: "Tab. Voglibose", brandNote: "(Vomaloy / Voglibose 0.2mg)", use: "Controls blood sugar after meals", morning: "1", afternoon: "1", evening: "—", night: "—", timing: "Just before meals", duration: "10 days", notes: "Do not skip meals when taking this" }, { no: "2", name: "Tab. Ecospin AV 75/10", brandNote: "(Aspirin 75mg + Atorvastatin 10mg)", use: "Heart protection & cholesterol control", morning: "1", afternoon: "—", evening: "—", night: "—", timing: "Once daily – morning, after food", duration: "Ongoing", notes: "Do not take on empty stomach" }, { no: "3", name: "Tab. Nitsat SR 2.6mg", brandNote: "(Isosorbide Dinitrate / Nicorandil SR)", use: "Relieves chest tightness & breathlessness", morning: "1", afternoon: "2", evening: "—", night: "—", timing: "Morning 1 tablet, Noon 2 tablets", duration: "20 days", notes: "May cause mild headache – normal" }, { no: "4", name: "Tab. Thyrox 75mcg", brandNote: "(Levothyroxine 75 mcg)", use: "Thyroid hormone replacement", morning: "1", afternoon: "—", evening: "—", night: "—", timing: "Early morning – EMPTY STOMACH", duration: "Ongoing", notes: "Take 30–45 min before breakfast; do not miss" }, { no: "5", name: "Tab. Dytor Plus 5mg", brandNote: "(Torsemide + Spironolactone)", use: "Reduces fluid retention / swelling", morning: "½", afternoon: "½", evening: "—", night: "—", timing: "½ tablet twice daily – morning & noon", duration: "15 days", notes: "Avoid late evening – may cause frequent urination" }, ]; // ─── DAILY REMINDER SCHEDULE ───────────────────────────────────────────────── const schedule = [ { time: "Early Morning\n(6:00 – 7:00 AM)", bg: "FFF3CD", icon: "🌅", items: [ "Tab. Thyrox 75mcg ×1 — EMPTY STOMACH", "Wait 30–45 minutes before eating breakfast" ] }, { time: "Morning\n(After Breakfast)", bg: "D4EDDA", icon: "☀️", items: [ "Tab. Voglibose ×1 — just before/with breakfast", "Tab. Ecospin AV 75/10 ×1 — after food", "Tab. Nitsat SR 2.6mg ×1 — after food", "Tab. Dytor Plus 5mg ×½ — after food" ] }, { time: "Noon / Lunch\n(Before / With Lunch)", bg: "D1ECF1", icon: "🌞", items: [ "Tab. Voglibose ×1 — just before lunch", "Tab. Nitsat SR 2.6mg ×2 — after lunch", "Tab. Dytor Plus 5mg ×½ — after lunch" ] }, { time: "Evening / Dinner\n(No medicines)", bg: "F8D7DA", icon: "🌙", items: [ "No scheduled medicines in the evening", "Ensure adequate fluid intake during the day" ] } ]; // ─── BUILD SCHEDULE TABLE ───────────────────────────────────────────────────── function buildScheduleTable() { const headerRow = new TableRow({ tableHeader: true, children: [ headerCell("Time of Day", { size: 20 }), headerCell("Medicines to Take", { size: 20 }), ] }); const rows = schedule.map(s => new TableRow({ children: [ cell(s.time, { bold: true, bg: s.bg, size: 20, align: AlignmentType.CENTER, vAlign: VerticalAlign.CENTER }), new TableCell({ shading: { fill: WHITE, type: ShadingType.CLEAR, color: "auto" }, margins: { top: 80, bottom: 80, left: 150, right: 150 }, children: s.items.map(item => new Paragraph({ spacing: { before: 40, after: 40 }, children: [new TextRun({ text: "✔ " + item, size: 20, font: "Calibri", color: DARK_TEXT })] })) }) ] })); return new Table({ width: { size: 100, type: WidthType.PERCENTAGE }, columnWidths: [2500, 7500], rows: [headerRow, ...rows] }); } // ─── BUILD MEDICINE DETAILS TABLE ──────────────────────────────────────────── function buildMedTable() { const headerRow = new TableRow({ tableHeader: true, children: [ headerCell("#", { size: 18 }), headerCell("Medicine", { size: 18 }), headerCell("Purpose", { size: 18 }), headerCell("Morning", { size: 18 }), headerCell("Noon", { size: 18 }), headerCell("Night", { size: 18 }), headerCell("Duration", { size: 18 }), ] }); const dataRows = medicines.map((m, i) => { const bg = i % 2 === 0 ? WHITE : ALT_ROW; return new TableRow({ children: [ cell(m.no, { bold: true, bg, align: AlignmentType.CENTER, size: 19 }), new TableCell({ shading: { fill: bg, type: ShadingType.CLEAR, color: "auto" }, margins: { top: 80, bottom: 80, left: 120, right: 120 }, children: [ new Paragraph({ children: [new TextRun({ text: m.name, bold: true, size: 19, font: "Calibri", color: MED_BLUE })] }), new Paragraph({ children: [new TextRun({ text: m.brandNote, size: 16, font: "Calibri", color: "666666", italics: true })] }) ] }), cell(m.use, { bg, size: 18 }), cell(m.morning, { bg, align: AlignmentType.CENTER, size: 19, bold: m.morning !== "—", color: m.morning !== "—" ? ACCENT_GREEN : "AAAAAA" }), cell(m.afternoon, { bg, align: AlignmentType.CENTER, size: 19, bold: m.afternoon !== "—", color: m.afternoon !== "—" ? ACCENT_GREEN : "AAAAAA" }), cell(m.night, { bg, align: AlignmentType.CENTER, size: 19, bold: m.night !== "—", color: m.night !== "—" ? ACCENT_GREEN : "AAAAAA" }), cell(m.duration, { bg, align: AlignmentType.CENTER, size: 18, color: m.duration === "Ongoing" ? ACCENT_ORANGE : DARK_TEXT, bold: m.duration === "Ongoing" }), ] }); }); return new Table({ width: { size: 100, type: WidthType.PERCENTAGE }, columnWidths: [500, 2800, 2200, 900, 900, 900, 1300], rows: [headerRow, ...dataRows] }); } // ─── NOTES TABLE ───────────────────────────────────────────────────────────── function buildNotesTable() { const notesData = [ { icon: "⚠", label: "Thyrox – CRITICAL", detail: "Must be taken on EMPTY STOMACH, 30–45 min before breakfast. Missing doses affects thyroid control.", color: ACCENT_RED }, { icon: "🍽", label: "Voglibose – Meal Timing", detail: "Take just before meals (not after). Works only when taken with carbohydrate-containing food.", color: ACCENT_ORANGE }, { icon: "💊", label: "Ecospin AV – After Food", detail: "Always take after eating. Taking on empty stomach may irritate the stomach lining.", color: MED_BLUE }, { icon: "🚿", label: "Dytor Plus – Morning Only", detail: "Take in morning/noon only. Avoid late evening to prevent sleep disruption from frequent urination.", color: "8E44AD" }, { icon: "🩺", label: "Follow-up Tests", detail: "CBC, TSH, ECG, RBS/HbA1c, Urine Microalbumin – complete before next visit.", color: ACCENT_GREEN }, { icon: "⛔", label: "Do NOT Self-Stop", detail: "Do not discontinue any medicine without consulting Dr. Arun More, even if feeling better.", color: ACCENT_RED }, ]; const headerRow = new TableRow({ tableHeader: true, children: [headerCell("Important Reminders & Notes", { colspan: 3, size: 21 })] }); const rows = notesData.map((n, i) => new TableRow({ children: [ cell(n.icon, { bg: i % 2 === 0 ? WHITE : ALT_ROW, align: AlignmentType.CENTER, size: 22 }), cell(n.label, { bold: true, bg: i % 2 === 0 ? WHITE : ALT_ROW, color: n.color, size: 19 }), cell(n.detail, { bg: i % 2 === 0 ? WHITE : ALT_ROW, size: 18 }), ] })); return new Table({ width: { size: 100, type: WidthType.PERCENTAGE }, columnWidths: [600, 2500, 6900], rows: [headerRow, ...rows] }); } // ─── DOCUMENT ──────────────────────────────────────────────────────────────── const doc = new Document({ styles: { default: { document: { run: { font: "Calibri", size: 20, color: DARK_TEXT } } } }, sections: [{ properties: { page: { margin: { top: 720, bottom: 720, left: 900, right: 900 } } }, headers: { default: new Header({ children: [ new Table({ width: { size: 100, type: WidthType.PERCENTAGE }, borders: { top: { style: BorderStyle.NONE }, bottom: { style: BorderStyle.SINGLE, size: 6, color: MED_BLUE }, left: { style: BorderStyle.NONE }, right: { style: BorderStyle.NONE }, insideH: { style: BorderStyle.NONE }, insideV: { style: BorderStyle.NONE } }, rows: [new TableRow({ children: [ new TableCell({ shading: { fill: HEADER_BG, type: ShadingType.CLEAR }, margins: { top: 120, bottom: 120, left: 200, right: 200 }, children: [ new Paragraph({ children: [new TextRun({ text: "MEDICINE SCHEDULE & REMINDER", bold: true, color: WHITE, size: 28, font: "Calibri" })] }), new Paragraph({ children: [new TextRun({ text: "Aalekhya Multispeciality Hospital & Heart Care Center, Dharmabad", color: "AADDFF", size: 18, font: "Calibri" })] }) ] }), new TableCell({ shading: { fill: HEADER_BG, type: ShadingType.CLEAR }, margins: { top: 120, bottom: 120, left: 200, right: 200 }, verticalAlign: VerticalAlign.CENTER, children: [ new Paragraph({ alignment: AlignmentType.RIGHT, children: [new TextRun({ text: "Patient: KANEEZ FATIMA AYYUB", bold: true, color: WHITE, size: 20, font: "Calibri" })] }), new Paragraph({ alignment: AlignmentType.RIGHT, children: [new TextRun({ text: "Age: 46 yrs | F | MHC/39865", color: "CCDDEE", size: 18, font: "Calibri" })] }), new Paragraph({ alignment: AlignmentType.RIGHT, children: [new TextRun({ text: "Date: 19-04-2026 | Diagnosis: DM-Type II", color: "CCDDEE", size: 18, font: "Calibri" })] }), new Paragraph({ alignment: AlignmentType.RIGHT, children: [new TextRun({ text: "Dr. Arun More (MBBS, PGDCC, MBA)", color: "AADDFF", size: 17, font: "Calibri" })] }), ] }) ] })] }) ] }) }, footers: { default: new Footer({ children: [new Paragraph({ alignment: AlignmentType.CENTER, spacing: { before: 80 }, children: [ new TextRun({ text: "Mo: 9960516956 | arunmoregsa@gmail.com | Beside Khoja Masjid, Devi Road, Dharmabad, Dist. Nanded – 431809 (MH) | Page ", size: 16, color: "888888", font: "Calibri" }), new TextRun({ children: [PageNumber.CURRENT], size: 16, color: "888888", font: "Calibri" }) ] })] }) }, children: [ spacer(1), // ── Daily Schedule ── sectionHeading("📅 Daily Medicine Schedule", MED_BLUE), buildScheduleTable(), spacer(1), // ── Medicine Details ── sectionHeading("💊 Medicine Details", MED_BLUE), buildMedTable(), spacer(1), // ── Per-medicine timing notes ── sectionHeading("⏰ Specific Timing Instructions", MED_BLUE), ...medicines.map(m => new Paragraph({ spacing: { before: 50, after: 50 }, children: [ new TextRun({ text: `${m.no}. ${m.name} `, bold: true, size: 20, font: "Calibri", color: MED_BLUE }), new TextRun({ text: `${m.timing} `, size: 20, font: "Calibri", color: DARK_TEXT }), new TextRun({ text: `[${m.duration}] `, size: 18, font: "Calibri", color: ACCENT_ORANGE, bold: true }), new TextRun({ text: `→ ${m.notes}`, size: 18, font: "Calibri", color: "666666", italics: true }), ] })), spacer(1), // ── Important Notes ── sectionHeading("📋 Important Notes & Reminders", MED_BLUE), buildNotesTable(), spacer(1), // ── Tests Required ── sectionHeading("🔬 Investigations Ordered", MED_BLUE), new Table({ width: { size: 100, type: WidthType.PERCENTAGE }, rows: [ new TableRow({ tableHeader: true, children: [headerCell("Test"), headerCell("Purpose"), headerCell("Status")] }), new TableRow({ children: [cell("CBC (Complete Blood Count)", { bg: WHITE }), cell("Check blood cells & infection", { bg: WHITE }), cell("Pending ☐", { bg: WHITE, align: AlignmentType.CENTER })] }), new TableRow({ children: [cell("TSH (Thyroid)", { bg: ALT_ROW }), cell("Monitor thyroid function", { bg: ALT_ROW }), cell("Pending ☐", { bg: ALT_ROW, align: AlignmentType.CENTER })] }), new TableRow({ children: [cell("ECG", { bg: WHITE }), cell("Heart rhythm & function", { bg: WHITE }), cell("Pending ☐", { bg: WHITE, align: AlignmentType.CENTER })] }), new TableRow({ children: [cell("RBS / HbA1c", { bg: ALT_ROW }), cell("Blood sugar control (diabetes)", { bg: ALT_ROW }), cell("Pending ☐", { bg: ALT_ROW, align: AlignmentType.CENTER })] }), new TableRow({ children: [cell("Urine Microalbumin", { bg: WHITE }), cell("Kidney function check", { bg: WHITE }), cell("Pending ☐", { bg: WHITE, align: AlignmentType.CENTER })] }), ] }), spacer(2), // ── Final reminder ── new Paragraph({ alignment: AlignmentType.CENTER, spacing: { before: 200, after: 100 }, children: [new TextRun({ text: "⚕ Please carry this document and your prescription on your next visit ⚕", bold: true, size: 20, color: MED_BLUE, font: "Calibri" })] }), new Paragraph({ alignment: AlignmentType.CENTER, children: [new TextRun({ text: "Next visit date: _______________ Doctor's signature: _______________", size: 18, color: "888888", font: "Calibri" })] }), ] }] }); Packer.toBuffer(doc).then(buf => { fs.writeFileSync("/home/daytona/workspace/medicine-schedule/Kaneez_Fatima_Medicine_Schedule.docx", buf); console.log("✅ Document created successfully."); }).catch(err => { console.error("Error:", err); process.exit(1); }); EOF echo "Script written."
cd /home/daytona/workspace/medicine-schedule && node create_schedule.js
python /home/daytona/skills/docx/scripts/office/validate.py /home/daytona/workspace/medicine-schedule/Kaneez_Fatima_Medicine_Schedule.docx
# Verify the file exists and check its size ls -lh /home/daytona/workspace/medicine-schedule/Kaneez_Fatima_Medicine_Schedule.docx # Quick sanity check - unzip and look at main document parts python3 -c " import zipfile with zipfile.ZipFile('/home/daytona/workspace/medicine-schedule/Kaneez_Fatima_Medicine_Schedule.docx') as z: names = z.namelist() print('Files in docx:', names[:10]) print('Total parts:', len(names)) "
Kaneez Fatima Medicine Schedule
Word Document · DOCX