Vitamin k biochemistry
| Form | Name | Source |
|---|---|---|
| Vitamin K1 | Phylloquinone (phytomenadione) | Green leafy vegetables; role in photosynthesis |
| Vitamin K2 | Menaquinone (MK-4 to MK-13) | Synthesized by colonic bacteria; found in animal tissues |
| Vitamin K3 | Menadione | Synthetic; no longer used therapeutically due to toxicity |



| Source | Notes |
|---|---|
| Green leafy vegetables (kale, spinach, cabbage) | Primary source of K1 |
| Vegetable/canola/soybean/olive oil | Appreciable K1 content |
| Liver, egg yolk | Both K1 and K2 |
| Intestinal bacteria (gut microbiome) | Synthesize K2 (menaquinones) |
DIET (K1)
↓
Intestinal absorption (fat-soluble)
↓
Vitamin K quinone (inactive)
↓ NADH-quinone reductase
Vitamin K hydroquinone KH₂ (active)
↓ γ-Glutamyl carboxylase + O₂ + CO₂
Glu residues → Gla residues (in clotting factors, osteocalcin, etc.)
↑ ↓
VKOR ← Vitamin K epoxide (KO) [Warfarin blocks VKOR here]
Create a flowchart or summary document on vitamin K biochemistry
ls /home/daytona/workspace/ 2>/dev/null && echo "---" && node --version
mkdir -p /home/daytona/workspace/vitaminK-pptx && node -e "require('pptxgenjs')"…
~/vitaminK-pptx/build.js
const pptxgen = require("pptxgenjs");
const pres = new pptxgen();
pres.layout = "LAYOUT_16x9";
pres.title = "Vitamin K Biochemistry";
pres.author = "Orris Medical";
// ── Palette ──────────────────────────────────────────────
const C = {
darkGreen: "1A4731", // dominant dark bg
midGreen: "2E7D52", // section headers
limeAccent: "A8D5B5", // highlight accent
lightGreen: "D6EFE1", // light panel bg
white: "FFFFFF",
offWhite: "F4FAF7",
amber: "E8A020", // warning / warfarin
red: "C0392B", // deficiency
blue: "2471A3", // calcium / coagulation
charcoal: "2C3E50",
lightGray: "ECF0F1",
};
// ── Helper: slide background ─────────────────────────────
function darkSlide(slide) {
slide.background = { color: C.darkGreen };
}
function lightSlide(slide) {
slide.background = { color: C.offWhite };
}
// ── Helper: section header bar ───────────────────────────
function addHeaderBar(slide, title, subtitle) {
slide.addShape(pres.shapes.RECTANGLE, {
x: 0, y: 0, w: 10, h: 1.0,
fill: { color: C.midGreen }, line: { color: C.midGreen }
});
slide.addShape(pres.shapes.RECTANGLE, {
x: 0, y: 1.0, w: 10, h: 0.07,
fill: { color: C.limeAccent }, line: { color: C.limeAccent }
});
slide.addText(title, {
x: 0.3, y: 0.05, w: 9.4, h: 0.9,
fontSize: 24, bold: true, color: C.white, valign: "middle", margin: 0
});
if (subtitle) {
slide.addText(subtitle, {
x: 0.3, y: 0.62, w: 9.4, h: 0.35,
fontSize: 12, color: C.limeAccent, italic: true, margin: 0
});
}
}
// ── Helper: small section pill ───────────────────────────
function pill(slide, label, x, y, w, h, fillColor, textColor) {
slide.addShape(pres.shapes.ROUNDED_RECTANGLE, {
x, y, w, h, rectRadius: 0.08,
fill: { color: fillColor }, line: { color: fillColor }
});
slide.addText(label, {
x, y, w, h,
fontSize: 11, bold: true, color: textColor,
align: "center", valign: "middle", margin: 0
});
}
// ── Helper: info card ────────────────────────────────────
function card(slide, x, y, w, h, title, bullets, titleBg, titleFg, cardBg) {
slide.addShape(pres.shapes.RECTANGLE, {
x, y, w, h,
fill: { color: cardBg || C.white },
line: { color: titleBg, pt: 1.5 },
shadow: { type: "outer", color: "000000", blur: 4, offset: 2, angle: 135, opacity: 0.1 }
});
slide.addShape(pres.shapes.RECTANGLE, {
x, y, w, h: 0.38,
fill: { color: titleBg }, line: { color: titleBg }
});
slide.addText(title, {
x: x + 0.08, y: y, w: w - 0.16, h: 0.38,
fontSize: 11, bold: true, color: titleFg || C.white,
valign: "middle", margin: 0
});
const items = bullets.map((b, i) => ({
text: b,
options: { bullet: { code: "2022" }, fontSize: 10, color: C.charcoal, breakLine: i < bullets.length - 1 }
}));
slide.addText(items, {
x: x + 0.1, y: y + 0.42, w: w - 0.2, h: h - 0.5,
valign: "top"
});
}
// ── Helper: arrow (right) ────────────────────────────────
function arrowRight(slide, x, y, w, h, color) {
slide.addShape(pres.shapes.RIGHT_ARROW, {
x, y, w, h,
fill: { color: color || C.limeAccent },
line: { color: color || C.limeAccent }
});
}
// ── Helper: arrow (down) ─────────────────────────────────
function arrowDown(slide, x, y, w, h, color) {
slide.addShape(pres.shapes.DOWN_ARROW, {
x, y, w, h,
fill: { color: color || C.limeAccent },
line: { color: color || C.limeAccent }
});
}
// ═══════════════════════════════════════════════════════
// SLIDE 1 — Title
// ═══════════════════════════════════════════════════════
{
const s = pres.addSlide();
darkSlide(s);
// Big green accent block left
s.addShape(pres.shapes.RECTANGLE, {
x: 0, y: 0, w: 0.18, h: 5.625,
fill: { color: C.limeAccent }, line: { color: C.limeAccent }
});
s.addText("VITAMIN K", {
x: 0.5, y: 0.9, w: 9, h: 1.1,
fontSize: 64, bold: true, color: C.white,
charSpacing: 8, align: "left", margin: 0
});
s.addText("Biochemistry", {
x: 0.5, y: 1.95, w: 7, h: 0.7,
fontSize: 36, bold: false, color: C.limeAccent,
italic: true, align: "left", margin: 0
});
// Horizontal divider
s.addShape(pres.shapes.RECTANGLE, {
x: 0.5, y: 2.75, w: 5.5, h: 0.06,
fill: { color: C.midGreen }, line: { color: C.midGreen }
});
s.addText([
{ text: "Structure • ", options: { color: C.limeAccent } },
{ text: "γ-Carboxylation Cycle • ", options: { color: C.white } },
{ text: "Gla Proteins • ", options: { color: C.limeAccent } },
{ text: "Deficiency • ", options: { color: C.white } },
{ text: "Warfarin Pharmacology", options: { color: C.limeAccent } }
], {
x: 0.5, y: 2.9, w: 9, h: 0.55,
fontSize: 13, align: "left", margin: 0
});
s.addText("Sources: Tietz Lab Medicine 7e · Lippincott Biochemistry 8e · Harrison's 22e · Basic Medical Biochemistry 6e", {
x: 0.5, y: 5.15, w: 9, h: 0.3,
fontSize: 9, color: "7FB89A", italic: true, align: "left", margin: 0
});
}
// ═══════════════════════════════════════════════════════
// SLIDE 2 — Overview: Forms & Sources
// ═══════════════════════════════════════════════════════
{
const s = pres.addSlide();
lightSlide(s);
addHeaderBar(s, "Vitamin K — Forms, Sources & Properties", "Fat-soluble naphthoquinone vitamin");
// Three form cards
const forms = [
{
name: "Vitamin K₁",
sub: "Phylloquinone\n(Phytomenadione)",
color: C.midGreen,
source: "Green leafy vegetables\n(kale, spinach, cabbage)",
note: "Role in plant photosynthesis"
},
{
name: "Vitamin K₂",
sub: "Menaquinone\n(MK-4 to MK-13)",
color: C.blue,
source: "Gut bacteria synthesis\nHepatic tissue, fermented foods",
note: "Major animal form; n = 4-13 isoprene units"
},
{
name: "Vitamin K₃",
sub: "Menadione\n(Synthetic)",
color: C.amber,
source: "No dietary source\n(synthetic only)",
note: "No longer therapeutic — causes hemolytic anemia in neonates"
}
];
forms.forEach((f, i) => {
const x = 0.25 + i * 3.22;
const y = 1.35;
const w = 3.0;
const h = 3.7;
s.addShape(pres.shapes.RECTANGLE, {
x, y, w, h,
fill: { color: C.white },
line: { color: f.color, pt: 2 },
shadow: { type: "outer", color: "000000", blur: 5, offset: 2, angle: 135, opacity: 0.12 }
});
// Color top band
s.addShape(pres.shapes.RECTANGLE, {
x, y, w, h: 0.75,
fill: { color: f.color }, line: { color: f.color }
});
s.addText(f.name, {
x: x + 0.1, y: y + 0.05, w: w - 0.2, h: 0.35,
fontSize: 18, bold: true, color: C.white, align: "center", margin: 0
});
s.addText(f.sub, {
x: x + 0.1, y: y + 0.38, w: w - 0.2, h: 0.38,
fontSize: 10, color: C.limeAccent, align: "center", italic: true, margin: 0
});
// Source
s.addText("Source", {
x: x + 0.1, y: y + 0.85, w: w - 0.2, h: 0.28,
fontSize: 10, bold: true, color: f.color, margin: 0
});
s.addText(f.source, {
x: x + 0.1, y: y + 1.12, w: w - 0.2, h: 0.65,
fontSize: 10, color: C.charcoal, margin: 0
});
// Note
s.addShape(pres.shapes.RECTANGLE, {
x: x + 0.1, y: y + 1.85, w: w - 0.2, h: 0.04,
fill: { color: C.lightGray }, line: { color: C.lightGray }
});
s.addText("Key Note", {
x: x + 0.1, y: y + 1.95, w: w - 0.2, h: 0.28,
fontSize: 10, bold: true, color: f.color, margin: 0
});
s.addText(f.note, {
x: x + 0.1, y: y + 2.22, w: w - 0.2, h: 1.0,
fontSize: 10, color: C.charcoal, margin: 0
});
});
// Bottom bar: requirements
s.addShape(pres.shapes.RECTANGLE, {
x: 0, y: 5.1, w: 10, h: 0.52,
fill: { color: C.darkGreen }, line: { color: C.darkGreen }
});
s.addText([
{ text: "Dietary Requirements: ", options: { bold: true, color: C.limeAccent } },
{ text: "Adult Males 120 μg/day ", options: { color: C.white } },
{ text: "• ", options: { color: C.limeAccent } },
{ text: "Adult Females 90 μg/day ", options: { color: C.white } },
{ text: "• ", options: { color: C.limeAccent } },
{ text: "K1 converts to K2 in some organs ", options: { color: C.white } },
{ text: "• ", options: { color: C.limeAccent } },
{ text: "Fat-soluble → needs bile salts for absorption", options: { color: C.white } }
], {
x: 0.3, y: 5.1, w: 9.5, h: 0.52,
fontSize: 11, valign: "middle", margin: 0
});
}
// ═══════════════════════════════════════════════════════
// SLIDE 3 — Chemical Structure (naphthoquinone core)
// ═══════════════════════════════════════════════════════
{
const s = pres.addSlide();
lightSlide(s);
addHeaderBar(s, "Chemical Structure — Naphthoquinone Core", "All forms share the 2-methyl-1,4-naphthoquinone ring system");
// Central core box
s.addShape(pres.shapes.RECTANGLE, {
x: 3.2, y: 1.3, w: 3.6, h: 1.3,
fill: { color: C.lightGreen }, line: { color: C.midGreen, pt: 2 },
shadow: { type: "outer", color: "000000", blur: 5, offset: 2, angle: 135, opacity: 0.15 }
});
s.addText("2-Methyl-1,4-naphthoquinone", {
x: 3.2, y: 1.3, w: 3.6, h: 0.45,
fontSize: 13, bold: true, color: C.midGreen, align: "center", valign: "middle", margin: 0
});
s.addText("• Bicyclic aromatic ring (naphthalene)\n• Two ketone groups at C1 & C4\n• Methyl group at C2\n• Active nucleus common to ALL forms", {
x: 3.3, y: 1.75, w: 3.4, h: 0.85,
fontSize: 9.5, color: C.charcoal, margin: 0
});
// K1 side chain
s.addShape(pres.shapes.RECTANGLE, {
x: 0.2, y: 1.4, w: 2.6, h: 1.1,
fill: { color: C.white }, line: { color: C.midGreen, pt: 1.5 }
});
s.addText("K₁ Side Chain", {
x: 0.2, y: 1.4, w: 2.6, h: 0.35,
fontSize: 11, bold: true, color: C.white,
fill: { color: C.midGreen }, align: "center", valign: "middle", margin: 0
});
s.addShape(pres.shapes.RECTANGLE, {
x: 0.2, y: 1.4, w: 2.6, h: 0.35,
fill: { color: C.midGreen }, line: { color: C.midGreen }
});
s.addText("K₁ Side Chain", {
x: 0.2, y: 1.4, w: 2.6, h: 0.35,
fontSize: 11, bold: true, color: C.white, align: "center", valign: "middle", margin: 0
});
s.addText("Phytyl group\n(saturated except Δ2')\nC20 chain from C3 position", {
x: 0.3, y: 1.78, w: 2.4, h: 0.75,
fontSize: 9.5, color: C.charcoal, margin: 0
});
// Arrow K1 → core
s.addShape(pres.shapes.RIGHT_ARROW, {
x: 2.85, y: 1.7, w: 0.32, h: 0.35,
fill: { color: C.midGreen }, line: { color: C.midGreen }
});
// K2 side chain
s.addShape(pres.shapes.RECTANGLE, {
x: 7.2, y: 1.4, w: 2.6, h: 1.1,
fill: { color: C.white }, line: { color: C.blue, pt: 1.5 }
});
s.addShape(pres.shapes.RECTANGLE, {
x: 7.2, y: 1.4, w: 2.6, h: 0.35,
fill: { color: C.blue }, line: { color: C.blue }
});
s.addText("K₂ Side Chain", {
x: 7.2, y: 1.4, w: 2.6, h: 0.35,
fontSize: 11, bold: true, color: C.white, align: "center", valign: "middle", margin: 0
});
s.addText("Polyisoprenyl group\nn = 4–13 isoprene units\n(MK-4 to MK-13)", {
x: 7.3, y: 1.78, w: 2.4, h: 0.75,
fontSize: 9.5, color: C.charcoal, margin: 0
});
// Arrow core → K2
s.addShape(pres.shapes.RIGHT_ARROW, {
x: 6.82, y: 1.7, w: 0.35, h: 0.35,
fill: { color: C.blue }, line: { color: C.blue }
});
// Warfarin / Dicoumarol structural analogy box
s.addShape(pres.shapes.RECTANGLE, {
x: 0.2, y: 3.0, w: 9.6, h: 2.3,
fill: { color: C.white },
line: { color: C.amber, pt: 2 },
shadow: { type: "outer", color: "000000", blur: 5, offset: 2, angle: 135, opacity: 0.1 }
});
s.addShape(pres.shapes.RECTANGLE, {
x: 0.2, y: 3.0, w: 9.6, h: 0.38,
fill: { color: C.amber }, line: { color: C.amber }
});
s.addText("Vitamin K Antagonists — Structural Analogy", {
x: 0.3, y: 3.0, w: 9.5, h: 0.38,
fontSize: 13, bold: true, color: C.white, valign: "middle", margin: 0
});
// Two sub-boxes inside
const analogs = [
{
name: "Warfarin",
desc: "4-hydroxycoumarin derivative\nSingle coumarin ring + asymmetric carbon\nEnhanced oral bioavailability",
mech: "Inhibits VKOR → blocks KO→KH₂ recycling"
},
{
name: "Dicoumarol",
desc: "Bis-coumarin (two coumarin rings linked by CH₂)\nFound in spoiled sweet clover\n(historical: caused cattle hemorrhage)",
mech: "Same VKOR inhibition; parent compound of warfarin class"
}
];
analogs.forEach((a, i) => {
const x = 0.4 + i * 4.8;
s.addShape(pres.shapes.RECTANGLE, {
x, y: 3.45, w: 4.6, h: 1.75,
fill: { color: C.lightGreen }, line: { color: C.amber, pt: 1 }
});
s.addText(a.name, {
x: x + 0.1, y: 3.47, w: 4.4, h: 0.3,
fontSize: 12, bold: true, color: C.amber, margin: 0
});
s.addText(a.desc, {
x: x + 0.1, y: 3.78, w: 4.4, h: 0.7,
fontSize: 9.5, color: C.charcoal, margin: 0
});
s.addText("⚠ " + a.mech, {
x: x + 0.1, y: 4.48, w: 4.4, h: 0.65,
fontSize: 9.5, color: C.red, bold: true, margin: 0
});
});
}
// ═══════════════════════════════════════════════════════
// SLIDE 4 — The γ-Carboxylation Cycle (flowchart)
// ═══════════════════════════════════════════════════════
{
const s = pres.addSlide();
lightSlide(s);
addHeaderBar(s, "The Vitamin K γ-Carboxylation Cycle", "Posttranslational modification of Glu residues → Gla residues in the ER");
// ─────── Flow boxes ───────
// Box 1: Dietary K1 / Bacterial K2
s.addShape(pres.shapes.RECTANGLE, {
x: 0.2, y: 1.25, w: 2.1, h: 1.0,
fill: { color: C.lightGreen }, line: { color: C.midGreen, pt: 1.5 }
});
s.addText("Dietary K₁\nBacterial K₂", {
x: 0.2, y: 1.25, w: 2.1, h: 1.0,
fontSize: 11, bold: true, color: C.midGreen, align: "center", valign: "middle", margin: 0
});
arrowRight(s, 2.35, 1.6, 0.45, 0.3, C.midGreen);
// Box 2: Vitamin K Quinone
s.addShape(pres.shapes.RECTANGLE, {
x: 2.82, y: 1.25, w: 1.9, h: 1.0,
fill: { color: C.white }, line: { color: C.midGreen, pt: 1.5 }
});
s.addText("Vitamin K\nQuinone (K)", {
x: 2.82, y: 1.25, w: 1.9, h: 1.0,
fontSize: 10, bold: true, color: C.charcoal, align: "center", valign: "middle", margin: 0
});
// Arrow down from Quinone to KH2 (NADH reductase)
arrowDown(s, 3.52, 2.28, 0.3, 0.4, C.midGreen);
s.addText("NADH-quinone\nreductase", {
x: 3.86, y: 2.3, w: 1.5, h: 0.4,
fontSize: 8.5, color: C.midGreen, italic: true, margin: 0
});
// Box 3: KH2 (active hydroquinone)
s.addShape(pres.shapes.RECTANGLE, {
x: 2.82, y: 2.72, w: 1.9, h: 1.0,
fill: { color: C.midGreen }, line: { color: C.midGreen }
});
s.addText("Vitamin KH₂\n(Hydroquinone)\nACTIVE FORM", {
x: 2.82, y: 2.72, w: 1.9, h: 1.0,
fontSize: 10, bold: true, color: C.white, align: "center", valign: "middle", margin: 0
});
arrowRight(s, 4.75, 3.07, 0.45, 0.3, C.midGreen);
// Box 4: γ-Glutamyl Carboxylase reaction (centre)
s.addShape(pres.shapes.RECTANGLE, {
x: 5.22, y: 2.72, w: 2.5, h: 1.0,
fill: { color: C.darkGreen }, line: { color: C.darkGreen }
});
s.addText([
{ text: "γ-Glutamyl Carboxylase\n", options: { bold: true, color: C.limeAccent } },
{ text: "Glu → Gla residues\n", options: { color: C.white } },
{ text: "+ CO₂ + O₂", options: { color: C.limeAccent } }
], {
x: 5.22, y: 2.72, w: 2.5, h: 1.0,
fontSize: 10, align: "center", valign: "middle", margin: 0
});
arrowRight(s, 7.75, 3.07, 0.45, 0.3, C.amber);
// Box 5: K Epoxide
s.addShape(pres.shapes.RECTANGLE, {
x: 8.22, y: 2.72, w: 1.6, h: 1.0,
fill: { color: C.white }, line: { color: C.amber, pt: 2 }
});
s.addText("Vitamin K\nEpoxide (KO)", {
x: 8.22, y: 2.72, w: 1.6, h: 1.0,
fontSize: 10, bold: true, color: C.amber, align: "center", valign: "middle", margin: 0
});
// Arrow up from KO back to Quinone (recycling arc - use two arrows)
arrowDown(s, 8.72, 1.9, 0.3, 0.78, C.amber); // down means toward K
s.addShape(pres.shapes.RIGHT_ARROW, {
x: 8.72, y: 1.25, w: 0.3, h: 0.65, // placeholder
fill: { color: C.amber }, line: { color: C.amber }
});
// Recycling arrow from KO → K (up)
s.addShape(pres.shapes.UP_ARROW, {
x: 8.72, y: 1.25, w: 0.3, h: 1.43,
fill: { color: C.amber }, line: { color: C.amber }
});
// VKOR label
s.addShape(pres.shapes.RECTANGLE, {
x: 8.35, y: 1.18, w: 1.4, h: 0.55,
fill: { color: C.lightGreen }, line: { color: C.amber, pt: 1.5 }
});
s.addText("VKOR\n(Epoxide Reductase)", {
x: 8.35, y: 1.18, w: 1.4, h: 0.55,
fontSize: 8.5, bold: true, color: C.amber, align: "center", valign: "middle", margin: 0
});
// Warfarin inhibition marker
s.addShape(pres.shapes.RECTANGLE, {
x: 7.5, y: 1.22, w: 0.8, h: 0.48,
fill: { color: C.red }, line: { color: C.red }
});
s.addText("⛔ Warfarin\nblocks VKOR", {
x: 7.5, y: 1.22, w: 0.8, h: 0.48,
fontSize: 8, bold: true, color: C.white, align: "center", valign: "middle", margin: 0
});
// KO → K arrow (horizontal left from KO to K position)
s.addShape(pres.shapes.LEFT_ARROW, {
x: 4.78, y: 1.58, w: 3.4, h: 0.28,
fill: { color: C.amber }, line: { color: C.amber }
});
s.addText("VKOR", {
x: 5.5, y: 1.28, w: 1.5, h: 0.3,
fontSize: 8.5, italic: true, color: C.amber, align: "center", margin: 0
});
// Arrow from carboxylase product down to Gla proteins
arrowDown(s, 6.12, 3.76, 0.3, 0.5, C.midGreen);
s.addShape(pres.shapes.RECTANGLE, {
x: 5.22, y: 4.3, w: 2.5, h: 0.8,
fill: { color: C.blue }, line: { color: C.blue }
});
s.addText("Gla Proteins\n(Ca²⁺-binding active proteins)", {
x: 5.22, y: 4.3, w: 2.5, h: 0.8,
fontSize: 10, bold: true, color: C.white, align: "center", valign: "middle", margin: 0
});
// Note: reaction site
s.addShape(pres.shapes.RECTANGLE, {
x: 0.2, y: 4.3, w: 4.6, h: 1.0,
fill: { color: C.lightGreen }, line: { color: C.midGreen, pt: 1 }
});
s.addText([
{ text: "Reaction Site: ", options: { bold: true, color: C.midGreen } },
{ text: "Rough ER membrane\n", options: { color: C.charcoal } },
{ text: "Substrates: ", options: { bold: true, color: C.midGreen } },
{ text: "O₂, CO₂, KH₂, Glu residues\n", options: { color: C.charcoal } },
{ text: "Product: ", options: { bold: true, color: C.midGreen } },
{ text: "γ-carboxyglutamate (Gla) + KO", options: { color: C.charcoal } }
], {
x: 0.35, y: 4.32, w: 4.4, h: 0.95,
fontSize: 10, valign: "middle", margin: 0
});
}
// ═══════════════════════════════════════════════════════
// SLIDE 5 — Gla Proteins
// ═══════════════════════════════════════════════════════
{
const s = pres.addSlide();
lightSlide(s);
addHeaderBar(s, "Vitamin K-Dependent Proteins (Gla Proteins)", "γ-Carboxyglutamate (Gla) residues enable Ca²⁺ binding and phospholipid membrane anchoring");
// Mechanism box at top
s.addShape(pres.shapes.RECTANGLE, {
x: 0.2, y: 1.2, w: 9.6, h: 0.72,
fill: { color: C.darkGreen }, line: { color: C.darkGreen }
});
s.addText([
{ text: "Glu residue ", options: { color: C.limeAccent } },
{ text: "──[γ-carboxylase + Vitamin KH₂]──► ", options: { color: C.white } },
{ text: "Gla residue ", options: { color: C.limeAccent } },
{ text: "──[Ca²⁺]──► ", options: { color: C.amber } },
{ text: "Binds phospholipid membrane ", options: { color: C.white } },
{ text: "──► ", options: { color: C.amber } },
{ text: "Active coagulation complex", options: { color: C.limeAccent } }
], {
x: 0.3, y: 1.2, w: 9.4, h: 0.72,
fontSize: 11, valign: "middle", align: "center", margin: 0
});
// Three category cards
const cats = [
{
title: "Procoagulant Factors", color: C.blue,
items: [
"Factor II (Prothrombin) — 10+ Gla residues",
"Factor VII — extrinsic pathway",
"Factor IX — intrinsic/common pathway",
"Factor X — final common pathway"
],
note: "Without γ-carboxylation → cannot bind Ca²⁺ → cannot assemble on platelet phospholipid surface → coagulation fails"
},
{
title: "Anticoagulant Proteins", color: C.midGreen,
items: [
"Protein C — inactivates Va & VIIIa",
"Protein S — cofactor for Protein C",
"Protein Z — cofactor for Z-dependent protease inhibitor"
],
note: "Warfarin reduces BOTH procoagulant AND anticoagulant factors; net effect is anticoagulation (Protein C drops first — shortest half-life)"
},
{
title: "Non-Hemostatic Gla Proteins", color: C.amber,
items: [
"Osteocalcin — most abundant Gla protein; osteoblasts; bone mineralization",
"Matrix Gla Protein (MGP) — inhibits vascular calcification",
"Periostin — extracellular matrix",
"Gla-rich protein (GRP)"
],
note: "Defective bone mineralization is NOT a feature of even severe Vit K deficiency; K supplementation for osteoporosis not routinely recommended"
}
];
cats.forEach((c, i) => {
const x = 0.2 + i * 3.28;
const y = 2.08;
const w = 3.1;
const h = 3.35;
s.addShape(pres.shapes.RECTANGLE, {
x, y, w, h,
fill: { color: C.white },
line: { color: c.color, pt: 2 },
shadow: { type: "outer", color: "000000", blur: 4, offset: 2, angle: 135, opacity: 0.1 }
});
s.addShape(pres.shapes.RECTANGLE, {
x, y, w, h: 0.38,
fill: { color: c.color }, line: { color: c.color }
});
s.addText(c.title, {
x: x + 0.08, y, w: w - 0.16, h: 0.38,
fontSize: 11, bold: true, color: C.white, valign: "middle", margin: 0
});
const items = c.items.map((it, j) => ({
text: it,
options: { bullet: { code: "2022" }, fontSize: 9.5, color: C.charcoal, breakLine: true }
}));
s.addText(items, {
x: x + 0.1, y: y + 0.42, w: w - 0.2, h: 1.85,
valign: "top"
});
// Note area
s.addShape(pres.shapes.RECTANGLE, {
x: x + 0.05, y: y + 2.3, w: w - 0.1, h: 0.98,
fill: { color: c.color + "22" }, line: { color: c.color, pt: 0.75 }
});
s.addText(c.note, {
x: x + 0.12, y: y + 2.34, w: w - 0.25, h: 0.9,
fontSize: 9, color: C.charcoal, italic: true, margin: 0
});
});
}
// ═══════════════════════════════════════════════════════
// SLIDE 6 — Warfarin Pharmacology
// ═══════════════════════════════════════════════════════
{
const s = pres.addSlide();
lightSlide(s);
addHeaderBar(s, "Warfarin — Mechanism, VKOR, and Clinical Impact", "Competitive vitamin K antagonist acting on VKOR (VKORC1 gene product)");
// Left: mechanism steps
const steps = [
{ n: "1", text: "Warfarin (coumarin derivative) is structurally similar to vitamin K", color: C.amber },
{ n: "2", text: "Inhibits VKOR (vitamin K epoxide reductase, VKORC1)", color: C.amber },
{ n: "3", text: "KO (epoxide) cannot be recycled → KH₂ (active form) depleted", color: C.red },
{ n: "4", text: "γ-Glutamyl carboxylase starved of KH₂ cofactor", color: C.red },
{ n: "5", text: "New clotting factor precursors synthesized but under-carboxylated", color: C.red },
{ n: "6", text: "PIVKA proteins: can't bind Ca²⁺ → can't anchor to platelet membrane", color: C.charcoal },
{ n: "7", text: "Coagulation cascade blocked → therapeutic anticoagulation", color: C.midGreen }
];
steps.forEach((st, i) => {
const y = 1.2 + i * 0.56;
s.addShape(pres.shapes.ELLIPSE, {
x: 0.2, y: y, w: 0.38, h: 0.38,
fill: { color: st.color }, line: { color: st.color }
});
s.addText(st.n, {
x: 0.2, y: y, w: 0.38, h: 0.38,
fontSize: 12, bold: true, color: C.white, align: "center", valign: "middle", margin: 0
});
s.addText(st.text, {
x: 0.7, y: y + 0.02, w: 4.5, h: 0.36,
fontSize: 10, color: C.charcoal, valign: "middle", margin: 0
});
if (i < steps.length - 1) {
s.addShape(pres.shapes.LINE, {
x: 0.38, y: y + 0.38, w: 0, h: 0.18,
line: { color: st.color, pt: 1.5, dashType: "dash" }
});
}
});
// Right: affected factors table
const tableData = [
[
{ text: "Factor", options: { bold: true, color: C.white, fill: C.darkGreen } },
{ text: "Half-Life", options: { bold: true, color: C.white, fill: C.darkGreen } },
{ text: "Role", options: { bold: true, color: C.white, fill: C.darkGreen } }
],
["Protein C", "6–8 h", "Anticoagulant (drops first!)"],
["Factor VII", "4–6 h", "Extrinsic → PT prolonged first"],
["Protein S", "30 h", "Anticoagulant cofactor"],
["Factor IX", "18–24 h", "Intrinsic pathway"],
["Factor X", "24–48 h", "Common pathway"],
["Factor II", "50–80 h", "Prothrombin → drops last"]
];
s.addTable(tableData, {
x: 5.5, y: 1.2, w: 4.3, h: 3.5,
colW: [1.3, 1.1, 1.9],
rowH: 0.45,
border: { type: "solid", color: C.midGreen, pt: 1 },
fill: C.white,
fontFace: "Arial",
fontSize: 9.5,
align: "center",
valign: "middle",
color: C.charcoal
});
s.addText("⚠ Transient hypercoagulable state at warfarin initiation", {
x: 5.5, y: 4.78, w: 4.3, h: 0.38,
fontSize: 9.5, bold: true, color: C.red,
fill: { color: C.lightGreen },
align: "center", valign: "middle", margin: 0
});
s.addShape(pres.shapes.RECTANGLE, {
x: 5.5, y: 4.78, w: 4.3, h: 0.38,
fill: { color: "FFF4E0" }, line: { color: C.amber, pt: 1.5 }
});
s.addText("⚠ Protein C drops before II/IX/X → transient hypercoagulable state at warfarin initiation", {
x: 5.55, y: 4.8, w: 4.2, h: 0.36,
fontSize: 9, bold: true, color: C.red, align: "center", valign: "middle", margin: 0
});
// Reversal
s.addShape(pres.shapes.RECTANGLE, {
x: 0.2, y: 5.1, w: 9.6, h: 0.45,
fill: { color: C.midGreen }, line: { color: C.midGreen }
});
s.addText([
{ text: "Reversal: ", options: { bold: true, color: C.limeAccent } },
{ text: "Vitamin K1 (phytonadione) IV/PO ", options: { color: C.white } },
{ text: "• 4-Factor PCC (urgent) ", options: { color: C.white } },
{ text: "• FFP ", options: { color: C.white } },
{ text: "• VKORC1 mutations → warfarin resistance", options: { color: C.limeAccent } }
], {
x: 0.3, y: 5.1, w: 9.4, h: 0.45,
fontSize: 10, valign: "middle", margin: 0
});
}
// ═══════════════════════════════════════════════════════
// SLIDE 7 — Deficiency
// ═══════════════════════════════════════════════════════
{
const s = pres.addSlide();
lightSlide(s);
addHeaderBar(s, "Vitamin K Deficiency", "Clinical causes, at-risk populations, diagnosis & treatment");
// Causes (left)
s.addShape(pres.shapes.RECTANGLE, {
x: 0.2, y: 1.2, w: 3.1, h: 4.2,
fill: { color: C.white }, line: { color: C.red, pt: 2 },
shadow: { type: "outer", color: "000000", blur: 4, offset: 2, angle: 135, opacity: 0.1 }
});
s.addShape(pres.shapes.RECTANGLE, {
x: 0.2, y: 1.2, w: 3.1, h: 0.38,
fill: { color: C.red }, line: { color: C.red }
});
s.addText("Causes & Risk Groups", {
x: 0.28, y: 1.2, w: 2.94, h: 0.38,
fontSize: 11, bold: true, color: C.white, valign: "middle", margin: 0
});
const causes = [
"Newborns — sterile gut, no K2 synthesis; poor placental transfer; low breast milk K",
"Broad-spectrum antibiotics — reduce gut flora",
"Fat malabsorption (celiac, Crohn's, biliary obstruction, bariatric surgery)",
"Prolonged parenteral nutrition without K supplementation",
"Warfarin / anticoagulant therapy",
"Cephalosporins (e.g. cefamandole) — VKOR inhibition",
"Orlistat — impairs fat-soluble vitamin absorption",
"Alcoholism / severe liver disease",
"Neonates of mothers on anticonvulsants (enzyme inducers → ↑K metabolism)"
];
const causeItems = causes.map((c, i) => ({
text: c,
options: { bullet: { code: "25CF" }, fontSize: 9, color: C.charcoal, breakLine: i < causes.length - 1 }
}));
s.addText(causeItems, {
x: 0.3, y: 1.62, w: 2.95, h: 3.7, valign: "top"
});
// Clinical features (centre)
s.addShape(pres.shapes.RECTANGLE, {
x: 3.55, y: 1.2, w: 2.9, h: 2.05,
fill: { color: C.white }, line: { color: C.amber, pt: 2 },
shadow: { type: "outer", color: "000000", blur: 4, offset: 2, angle: 135, opacity: 0.1 }
});
s.addShape(pres.shapes.RECTANGLE, {
x: 3.55, y: 1.2, w: 2.9, h: 0.38,
fill: { color: C.amber }, line: { color: C.amber }
});
s.addText("Clinical Features", {
x: 3.63, y: 1.2, w: 2.74, h: 0.38,
fontSize: 11, bold: true, color: C.white, valign: "middle", margin: 0
});
const feats = [
"Ecchymoses, petechiae",
"GI bleeding",
"Intracranial hemorrhage (especially neonates)",
"Prolonged PT/INR (VII drops first)",
"Prolonged APTT",
"Normal platelet count & function"
];
const featItems = feats.map((f, i) => ({
text: f,
options: { bullet: { code: "2022" }, fontSize: 9.5, color: C.charcoal, breakLine: i < feats.length - 1 }
}));
s.addText(featItems, {
x: 3.63, y: 1.62, w: 2.75, h: 1.55, valign: "top"
});
// Diagnosis
s.addShape(pres.shapes.RECTANGLE, {
x: 3.55, y: 3.32, w: 2.9, h: 2.08,
fill: { color: C.white }, line: { color: C.blue, pt: 2 },
shadow: { type: "outer", color: "000000", blur: 4, offset: 2, angle: 135, opacity: 0.1 }
});
s.addShape(pres.shapes.RECTANGLE, {
x: 3.55, y: 3.32, w: 2.9, h: 0.38,
fill: { color: C.blue }, line: { color: C.blue }
});
s.addText("Diagnosis / Assessment", {
x: 3.63, y: 3.32, w: 2.74, h: 0.38,
fontSize: 11, bold: true, color: C.white, valign: "middle", margin: 0
});
const diag = [
"Serum phylloquinone (K1) < 0.15 μg/L",
"PIVKA-II (undercarboxylated prothrombin) — most sensitive",
"PT/INR — nonspecific but useful in severe deficiency",
"APTT prolonged",
"Clotting factor levels (II, VII, IX, X)"
];
const diagItems = diag.map((d, i) => ({
text: d,
options: { bullet: { code: "2022" }, fontSize: 9.5, color: C.charcoal, breakLine: i < diag.length - 1 }
}));
s.addText(diagItems, {
x: 3.63, y: 3.74, w: 2.75, h: 1.58, valign: "top"
});
// Treatment (right)
s.addShape(pres.shapes.RECTANGLE, {
x: 6.7, y: 1.2, w: 3.1, h: 4.2,
fill: { color: C.white }, line: { color: C.midGreen, pt: 2 },
shadow: { type: "outer", color: "000000", blur: 4, offset: 2, angle: 135, opacity: 0.1 }
});
s.addShape(pres.shapes.RECTANGLE, {
x: 6.7, y: 1.2, w: 3.1, h: 0.38,
fill: { color: C.midGreen }, line: { color: C.midGreen }
});
s.addText("Treatment / Prophylaxis", {
x: 6.78, y: 1.2, w: 2.94, h: 0.38,
fontSize: 11, bold: true, color: C.white, valign: "middle", margin: 0
});
const txItems = [
{ h: "Neonatal prophylaxis", b: "0.5–1 mg IM at birth (prevents VKDB)" },
{ h: "Acute adult deficiency", b: "10 mg IV in 25–50 mL NS over 15–30 min; onset 2–4 h" },
{ h: "Chronic malabsorption", b: "1–2 mg/day PO or 1–2 mg/week parenterally" },
{ h: "Warfarin reversal", b: "Oral K1 for non-urgent; IV K1 + 4-factor PCC for bleeding" },
{ h: "Diagnosis by therapy", b: "IV K normalizes PT within 2–4 h if deficiency is the cause; if PT unchanged → hepatocellular disease" }
];
let ty = 1.65;
txItems.forEach(it => {
s.addText(it.h, {
x: 6.82, y: ty, w: 2.88, h: 0.28,
fontSize: 10, bold: true, color: C.midGreen, margin: 0
});
ty += 0.28;
s.addText(it.b, {
x: 6.9, y: ty, w: 2.78, h: 0.5,
fontSize: 9.5, color: C.charcoal, margin: 0
});
ty += 0.54;
});
}
// ═══════════════════════════════════════════════════════
// SLIDE 8 — Summary Flowchart (one-page overview)
// ═══════════════════════════════════════════════════════
{
const s = pres.addSlide();
darkSlide(s);
s.addShape(pres.shapes.RECTANGLE, {
x: 0, y: 0, w: 10, h: 0.75,
fill: { color: C.midGreen }, line: { color: C.midGreen }
});
s.addText("Vitamin K Biochemistry — Summary Overview", {
x: 0.3, y: 0, w: 9.4, h: 0.75,
fontSize: 20, bold: true, color: C.white, valign: "middle", margin: 0
});
// Row 1: Sources
const boxW = 1.75, boxH = 0.72;
const row1y = 0.9, row2y = 2.0, row3y = 3.15, row4y = 4.32;
// SOURCES
[[C.midGreen, "K₁ (diet)", 0.15], [C.blue, "K₂ (bacteria)", 2.05], [C.amber, "K₃ (synthetic)", 4.0]].forEach(([col, label, x]) => {
s.addShape(pres.shapes.ROUNDED_RECTANGLE, {
x, y: row1y, w: boxW, h: boxH, rectRadius: 0.07,
fill: { color: col }, line: { color: col }
});
s.addText(label, {
x, y: row1y, w: boxW, h: boxH,
fontSize: 12, bold: true, color: C.white, align: "center", valign: "middle", margin: 0
});
});
s.addShape(pres.shapes.RIGHT_ARROW, {
x: 5.9, y: row1y + 0.2, w: 0.7, h: 0.32,
fill: { color: C.limeAccent }, line: { color: C.limeAccent }
});
// Absorption
s.addShape(pres.shapes.ROUNDED_RECTANGLE, {
x: 6.65, y: row1y, w: 3.2, h: boxH, rectRadius: 0.07,
fill: { color: C.charcoal }, line: { color: C.limeAccent, pt: 1.5 }
});
s.addText("Intestinal Absorption\n(requires bile salts / dietary fat)", {
x: 6.65, y: row1y, w: 3.2, h: boxH,
fontSize: 10, color: C.limeAccent, align: "center", valign: "middle", margin: 0
});
// Row 2 arrows down + label
arrowDown(s, 1.0, row1y + boxH, 0.28, 0.3, C.midGreen);
arrowDown(s, 2.9, row1y + boxH, 0.28, 0.3, C.midGreen);
arrowDown(s, 4.87, row1y + boxH, 0.28, 0.3, C.midGreen);
arrowDown(s, 8.1, row1y + boxH, 0.28, 0.3, C.midGreen);
// Vitamin K Cycle row
[[C.charcoal, "Vitamin K\nQuinone (K)", 0.15],
[C.midGreen, "KH₂ Active\n(Hydroquinone)", 2.05],
[C.darkGreen + "00", "γ-Glutamyl\nCarboxylase", 3.95],
[C.amber + "BB", "Vitamin K\nEpoxide (KO)", 5.85]].forEach(([col, label, x]) => {
s.addShape(pres.shapes.ROUNDED_RECTANGLE, {
x, y: row2y, w: boxW, h: boxH, rectRadius: 0.07,
fill: { color: col === C.darkGreen + "00" ? "1E5C3A" : col },
line: { color: C.limeAccent, pt: 1 }
});
s.addText(label, {
x, y: row2y, w: boxW, h: boxH,
fontSize: 10, bold: true, color: C.white, align: "center", valign: "middle", margin: 0
});
});
// Arrows in cycle (right)
[0.15 + boxW, 2.05 + boxW, 3.95 + boxW].forEach(x => {
arrowRight(s, x, row2y + 0.22, 0.25, 0.28, C.limeAccent);
});
// VKOR arrow back (from KO to K - going left, upper arc)
s.addShape(pres.shapes.LEFT_ARROW, {
x: 0.15, y: row2y - 0.4, w: 5.9, h: 0.25,
fill: { color: C.amber }, line: { color: C.amber }
});
s.addText("VKOR ⛔Warfarin", {
x: 2.4, y: row2y - 0.5, w: 2.5, h: 0.28,
fontSize: 8.5, color: C.amber, bold: true, align: "center", margin: 0
});
// NADH reductase label
s.addText("NADH\nreductase", {
x: 0.15 + boxW - 0.2, y: row2y + boxH, w: 0.9, h: 0.35,
fontSize: 7.5, color: C.limeAccent, italic: true, align: "center", margin: 0
});
// Row 3: Gla proteins
arrowDown(s, 4.7, row2y + boxH, 0.28, 0.38, C.midGreen);
s.addText("Gla residues\n+ Ca²⁺ + phospholipid", {
x: 3.95, y: row2y + boxH + 0.04, w: 1.9, h: 0.4,
fontSize: 8, color: C.limeAccent, italic: true, align: "center", margin: 0
});
const glaProts = [
[C.blue, "Factors\nII·VII·IX·X", 0.15],
[C.midGreen, "Protein C\nProtein S · Z", 2.05],
[C.amber, "Osteocalcin\nMGP", 3.95],
[C.charcoal, "Periostin\nGla-rich protein", 5.85]
];
glaProts.forEach(([col, label, x]) => {
s.addShape(pres.shapes.ROUNDED_RECTANGLE, {
x, y: row3y, w: boxW, h: boxH, rectRadius: 0.07,
fill: { color: col }, line: { color: col }
});
s.addText(label, {
x, y: row3y, w: boxW, h: boxH,
fontSize: 10, bold: true, color: C.white, align: "center", valign: "middle", margin: 0
});
});
// Right side: PIVKA box
s.addShape(pres.shapes.ROUNDED_RECTANGLE, {
x: 7.7, y: row2y, w: 2.1, h: 1.85, rectRadius: 0.07,
fill: { color: C.red + "22" }, line: { color: C.red, pt: 1.5 }
});
s.addShape(pres.shapes.RECTANGLE, {
x: 7.7, y: row2y, w: 2.1, h: 0.32,
fill: { color: C.red }, line: { color: C.red }
});
s.addText("Deficiency / PIVKA", {
x: 7.72, y: row2y, w: 2.07, h: 0.32,
fontSize: 9, bold: true, color: C.white, valign: "middle", margin: 0
});
s.addText("No KH₂ → No Gla →\nFactors inactive\n\nPIVKA-II: undercarboxylated prothrombin\n(sensitive biomarker)", {
x: 7.78, y: row2y + 0.35, w: 1.96, h: 1.45,
fontSize: 9, color: C.white, margin: 0
});
// Row 4: Deficiency effects / VKDB
s.addShape(pres.shapes.RECTANGLE, {
x: 0.15, y: row4y, w: 7.55, h: 0.9,
fill: { color: C.charcoal }, line: { color: C.red, pt: 1.5 }
});
s.addText([
{ text: "DEFICIENCY: ", options: { bold: true, color: C.red } },
{ text: "Bleeding · prolonged PT/INR ", options: { color: C.white } },
{ text: "│ VKDB (newborns) ", options: { color: C.amber } },
{ text: "│ Causes: antibiotics, malabsorption, warfarin, parenteral nutrition ", options: { color: C.limeAccent } },
{ text: "│ Rx: 10 mg IV K1; neonates 0.5–1 mg IM", options: { color: C.white } }
], {
x: 0.25, y: row4y, w: 7.35, h: 0.9,
fontSize: 9.5, valign: "middle", margin: 0
});
s.addShape(pres.shapes.RECTANGLE, {
x: 7.75, y: row4y, w: 2.1, h: 0.9,
fill: { color: C.midGreen }, line: { color: C.midGreen }
});
s.addText("Toxicity: Natural\nforms — none\nK3 (menadione)\n— hemolytic anemia", {
x: 7.8, y: row4y + 0.02, w: 2.0, h: 0.86,
fontSize: 8.5, color: C.white, valign: "middle", margin: 0
});
}
// ── Write file ───────────────────────────────────────────
pres.writeFile({ fileName: "/home/daytona/workspace/vitaminK-pptx/VitaminK_Biochemistry.pptx" })
.then(() => console.log("DONE: VitaminK_Biochemistry.pptx"))
.catch(e => { console.error(e); process.exit(1); });
cd /home/daytona/workspace/vitaminK-pptx && node build.js 2>&1
node -e "const p = require('pptxgenjs'); const pr = new p(); console.log(Object.…
~/vitaminK-pptx/build.js
Successfully replaced 1 instance(s) of the string in '/home/daytona/workspace/vitaminK-pptx/build.js'
cd /home/daytona/workspace/vitaminK-pptx && node build.js 2>&1
node -e "const p = require('pptxgenjs'); const pr = new p(); console.log(Object.…
grep -n "pres\.shapes\." /home/daytona/workspace/vitaminK-pptx/build.js | grep -…
sed -i 's/pres\.shapes\.ELLIPSE/pres.shapes.OVAL/g' /home/daytona/workspace/vita…
~/vitaminK-pptx/build.js
Successfully replaced 1 instance(s) of the string in '/home/daytona/workspace/vitaminK-pptx/build.js'
cd /home/daytona/workspace/vitaminK-pptx && node build.js 2>&1
VitaminK Biochemistry
Presentation · PPTX
| Slide | Content |
|---|---|
| 1 | Title slide with topic overview |
| 2 | Forms, Sources & Properties - K1 / K2 / K3 comparison cards |
| 3 | Chemical Structure - naphthoquinone core, side chain differences, warfarin/dicoumarol structural analogy |
| 4 | The γ-Carboxylation Cycle - full flowchart: KH₂ → carboxylase → KO → VKOR → K → KH₂, with warfarin block shown |
| 5 | Gla Proteins - procoagulant (II, VII, IX, X), anticoagulant (C, S, Z), and non-hemostatic (osteocalcin, MGP) |
| 6 | Warfarin Pharmacology - 7-step mechanism, half-life table of affected factors, transient hypercoagulable state warning |
| 7 | Deficiency - causes, clinical features, diagnosis (PIVKA-II), treatment doses |
| 8 | Summary overview flowchart - entire biochemistry pathway on one dark slide |