PowerPoint

PowerPoint (.pptx) creation, editing, and reading skill built on PptxGenJS (Node.js) for new decks and direct OOXML manipulation in Python for existing ones. This guide covers using the skill through an AI agent (CoDev Code, OpenCode, Claude Code, Codex, Cursor, or any Agent Skills–compatible agent).

Table of contents

1. How it works with an AI agent

User: "Build a 12-slide product launch deck for the Q4 review,
       corporate blue, English"
  |
  v
AI Agent (CoDev Code / OpenCode / Claude Code / Codex / Cursor / ...)
  | 1. Sees trigger signals (PowerPoint, PPT, .pptx, presentation,
  |    slide, deck...) -> loads SKILL.md
  | 2. Routes the task: no input file -> CREATE from scratch
  |    (existing file -> READ, or EDIT via the XML workflow)
  | 3. Picks a color palette, font pairing and style recipe from
  |    the skill's design system; classifies every slide as one of
  |    5 page types (Cover, TOC, Section Divider, Content, Summary)
  | 4. Writes one JS module per slide (slides/slide-01.js ...)
  |    against the PptxGenJS API and a fixed theme contract
  | 5. Compiles: node compile.js -> output/presentation.pptx
  | 6. QA: python -m markitdown output.pptx -> re-reads its own
  |    deck, greps for placeholder leftovers, fixes and re-compiles
  | 7. Delivers the file + extraction report
  v
Finished .pptx + QA report

The key point: steps 2–6 are orchestrated by the LLM following SKILL.md. The user is involved only at the start (describe the request) and the end (acceptance).

The skill routes every task down one of three paths:

RouteWhenHow the agent works
READextract or analyze deck contentpython -m markitdown presentation.pptx — text extraction, never modifies the source
CREATEnew deck from scratchplans an outline over the 5 page types, generates one PptxGenJS module per slide, compiles with Node.js
EDITmodify an existing deck / fill a templateunpacks the .pptx with Python's zipfile, edits the slide XML surgically (reorder, duplicate, retext), repacks — no PowerPoint needed

Two rules the skill enforces on itself are worth knowing as a user:

  • Every slide is one of 5 page types (Cover, Table of Contents, Section Divider, Content, Summary) with layout variety enforced — no monotonous title-plus-bullets decks.
  • Template edits never round-trip through a library: existing decks are edited as raw OOXML, so the template's design, masters and media survive untouched.

2. Prerequisites

Set these up first — Install skills walks through the install on Windows, macOS and Ubuntu step by step; its Install the skills into an agent section covers installing the skill into each agent (CoDev Code, OpenCode, Claude Code, Codex, Cursor) by hand.

The machine running the agent needs:

  • Python 3.10–3.14 (required) with markitdown[pptx] — the READ path, the QA step, and the EDIT path: template analysis runs markitdown, and the XML edits use its defusedxml dependency (installed automatically with the markitdown wheels).
  • Node.js ≥ 18 + the PptxGenJS module (the CREATE path). The offline install ships PptxGenJS as a prebuilt module tree; no npm or internet access is needed.
  • On macOS: the markitdown stack runs on macOS 13+ only (its native onnxruntime dependency ships no older wheels), Intel Macs are limited to Python 3.10–3.13, and Python 3.14 on Apple Silicon needs macOS 14+. The installer picks the right Python per chip — 3.14 on Apple Silicon, 3.13 on Intel — so this only matters when you bring your own Python.

3. How to use it: talk to the agent

The skill self-activates when your prompt contains its signals: PowerPoint, PPT, .pptx, presentation, slide, deck, slides…

Golden rule — provide these 4 groups of information:

  1. What: create new / edit existing / fill a template / extract content (the agent can infer, but explicit is better)
  2. Which files: input and output files — a plain name plus "in this folder" (launch.pptx), or a full path (C:\temp\deck.pptx, ~/decks/launch.pptx) — and the template file if one exists
  3. Content: topic, audience, tone, slide count, the actual material (or where to research it)
  4. Presentation: color preferences, language of the deck, any branding constraints (logo slides, fonts)

4. Prompt recipes per task type

4.1. Create a deck from scratch (CREATE)

Create q4-launch.pptx in this folder: a 12-slide product launch deck for
the Q4 business review.
- Audience: leadership team; tone: confident, data-driven
- Cover, table of contents, 3 sections (Market, Product, Roadmap) with
  section dividers, and a summary slide
- Brand palette built around #ee0033, English, 16:9
- Vary the layouts - use two-column and stat-callout slides, not just bullets

Tip: the skill classifies every slide as one of its 5 page types and picks a palette/style recipe up front — steering those choices ("brand palette around #ee0033", "soft rounded style") costs one line and saves a redesign round.

4.2. Edit an existing deck or fill a template (EDIT)

# Fill a corporate template:
Use corp-template.pptx in this folder as the template and build the FY2026
kickoff deck from kickoff-outline.md. Keep the template's design untouched;
map each outline section to a matching template layout, vary the layouts,
and delete the unused example slides.
 
# Targeted edit:
In q4-launch.pptx in this folder, retitle slide 3 to "Market Signals", swap
slides 5 and 6, and delete the appendix slides after the summary.
Change nothing else.

Important tip: reference slides by their content or title as well as their number ("slide 3, the market overview") — decks drift, and it lets the agent verify it is touching the right slide before editing the XML.

4.3. Read or summarize a deck (READ)

Extract the full text of competitor-analysis.pptx in this folder and summarize
the argument per section. Flag any slide whose claims carry no numbers.

Extraction is text-only (via markitdown) — layout, images and charts do not survive the round trip, which is fine for content review and summarization.

5. Acceptance — make the agent prove it

SKILL.md mandates a QA pass before delivery. You are entitled to (and should) ask for evidence:

"Run the QA extraction and show me the results"

A passing delivery includes:

  • A markitdown re-extraction of the produced deck — the agent reads its own output (python -m markitdown output.pptx) and shows the text landed as planned.
  • A placeholder sweep — the extraction is grepped for leftovers like xxxx, lorem, placeholder; zero hits expected.
  • For edits: confirmation that untouched slides survive byte-identical in content — ask for a before/after extraction diff of the slides you did not change.

Finally, open the file in PowerPoint or LibreOffice for a visual check — overlapping text boxes or an off-palette color are visible in seconds, and the agent can regenerate any single slide (each one is its own JS module).

6. Troubleshooting

SymptomCause & fix
Cannot find module 'pptxgenjs'The PptxGenJS module tree is missing — Install skills, Step 7 installs it (on Ubuntu/macOS as ~/.node_modules, on Windows via the user NODE_PATH variable). Open a new terminal on Windows so the variable is picked up
node: command not foundNode.js missing — Install skills, Step 7. The READ and EDIT paths work without it
No module named markitdownThe wheels step was skipped — Install skills, Step 6. Slides still compile without it, but reading, editing (markitdown's defusedxml dependency) and the skill's required QA pass all need it
The skill doesn't activatePrompt lacks signals. Say "PowerPoint/.pptx/deck" explicitly, or invoke by name: /pptx-generator … (Claude Code), $pptx-generator (Codex), type / and pick the skill (Cursor), "use the pptx-generator skill to…" (CoDev/OpenCode)
Deck opens with wrong fontsThe viewing machine lacks the font — the skill defaults to Arial, preinstalled on Windows; on Linux ask for a font that exists there or install the fonts
Repack fails on a mounted volume (Docker/network share)Python's zipfile seeks while writing — the skill writes to a local temp path first and copies over; if a manual run fails, do the same
Colors look off / theme keys errorThe theme contract uses exactly primary, secondary, accent, light, bg (6-char hex, no #) — ask the agent to re-check its slide modules against the contract

7. Skill limitations

  • Handles .pptx (OOXML) only; legacy binary .ppt is not supported — convert to .pptx in PowerPoint or LibreOffice first.
  • No password-protected/encrypted files.
  • Reading is text extraction only — speaker notes, embedded charts' data and layout geometry are not analyzed.
  • Icon rendering (react-icons + sharp) is optional and not part of the offline bundle — decks fall back to shapes and typography without it.
  • Generated files embed no fonts: the deck renders with the viewing machine's fonts.
  • macOS floors: reading/QA (markitdown) needs macOS 13+, Intel Macs top out at Python 3.13, and Python 3.14 on Apple Silicon needs macOS 14+.

8. Appendix: the design system the agent follows

So you can review the agent's plan — the skill pins these conventions:

ConventionValue
Canvas16:9, 10" × 5.625" (LAYOUT_16x9)
Page typesCover, Table of Contents, Section Divider, Content, Summary — every slide is exactly one
Theme contractprimary (titles), secondary (body), accent (highlights), light (light accent), bg (background) — 6-char hex without #
FontsArial, or an approved alternative
Style recipesSharp, Soft, Rounded, or Pill — one per deck
Page badgeEvery slide except the cover carries a page-number badge at x 9.3", y 5.1" (current number only, e.g. 03, never 3/12)
Output layoutOne JS module per slide in slides/, images in slides/imgs/, compiled deck in slides/output/

Each slide module exports a synchronous createSlide(pres, theme) and is independently runnable for preview — which is why the agent can regenerate a single slide without touching the rest of the deck.