Skip to content
Back to skills

svg2pptx

ASecurity

Convert any SVG into a native, fully-editable PowerPoint (.pptx) where every shape, text run, arrow and gradient becomes a real DrawingML object — not a flattened image. Use when the user has an SVG (often AI-generated by GPT/Claude, or hand-authored) and wants an editable .pptx they can refine in PowerPoint/Keynote and re-export to PDF, or asks to "turn this SVG/diagram into PowerPoint", "make this figure editable", "svg to pptx", "矢量转 PPT", "把图做成可编辑的 PPT".

  • 3 stars
  • 0 votes
  • 0 copies
  • 16 views
  • Added September 6, 2026
ai-agentspythongobash

Works with

  • cli

Security analysis

A96/100
  • mediumInstalls packages at runtime which could introduce malicious dependencies

Pro scans all 18 files and shows the line behind each finding

Scanned September 6, 2026

npx -y skills add JamieJustTang/svg2pptx-skill --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of svg2pptx?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for svg2pptx
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/jamiejusttang-svg2pptx/badge)](https://www.skillsdirectory.com/skills/jamiejusttang-svg2pptx)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: svg2pptx
description: >
  Convert any SVG into a native, fully-editable PowerPoint (.pptx) where every shape, text run,
  arrow and gradient becomes a real DrawingML object — not a flattened image. Use when the user
  has an SVG (often AI-generated by GPT/Claude, or hand-authored) and wants an editable .pptx they
  can refine in PowerPoint/Keynote and re-export to PDF, or asks to "turn this SVG/diagram into
  PowerPoint", "make this figure editable", "svg to pptx", "矢量转 PPT", "把图做成可编辑的 PPT".
---

# svg2pptx — SVG → native, editable PowerPoint

This skill converts SVG into **native PowerPoint shapes** (DrawingML): rectangles, paths, text
frames, gradients, arrowheads — each independently clickable, recolorable, and re-typeable in
PowerPoint. The opposite of pasting a picture onto a slide.

## When to use

- The user generated a draft diagram as **PNG or SVG** (e.g. asked GPT/Claude to draw a mechanism,
  architecture, flow, or chart) and now wants an **editable** deck, not a flat export.
- PNG input → first have a vision model **redraw it as a spec-compliant SVG** using the ready-made
  prompt in [`references/png-to-svg-prompt.md`](references/png-to-svg-prompt.md) (recommended: GPT-5.5
  Pro / Claude Opus 4.6+), then run this skill. (Auto-tracing is worse — it turns text into outlines.)
- The user wants to finish a figure in PowerPoint and export to **PDF / Keynote / Google Slides**.

## PNG → SVG → PPTX (when the input is a raster image)

If the user gives a PNG/JPG: read [`references/png-to-svg-prompt.md`](references/png-to-svg-prompt.md),
apply that prompt to the image (yourself, if you are vision-capable) to produce a clean editable SVG
that obeys [`references/shared-standards.md`](references/shared-standards.md), then continue with the
fast/controlled path below. If the quality gate flags an issue, re-author the SVG and retry.

## Fast path (one command)

```bash
python3 convert.py diagram.svg                 # -> diagram.pptx (next to the input)
python3 convert.py slides/ -o deck.pptx         # a folder of .svg -> one multi-page deck
python3 convert.py diagram.svg --check-only      # run the quality gate only
python3 convert.py diagram.svg --svg-snapshot    # also emit a pixel-faithful *_svg.pptx
```

`convert.py` stages the SVG, runs the quality gate, finalizes, and exports automatically.

## Controlled path (manual 3 steps)

The engine reads SVGs from `<project>/svg_output/*.svg`. Run **one command at a time, in order**:

```bash
mkdir -p myproj/svg_output && cp diagram.svg myproj/svg_output/01.svg

python3 scripts/svg_quality_checker.py myproj   # 1) GATE — must be 0 errors
python3 scripts/finalize_svg.py        myproj   # 2) embed icons, crop/embed images, flatten text, roundRect→path
python3 scripts/svg_to_pptx.py         myproj   # 3) export -> myproj/exports/<name>_<ts>.pptx
```

A folder of numbered SVGs (`01.svg`, `02.svg`, …) exports as a multi-page deck.

## Authoring SVG that converts cleanly

PowerPoint's DrawingML is a strict subset of SVG. Before authoring (or when fixing a gate error),
**read [`references/shared-standards.md`](references/shared-standards.md)** — the compatibility
contract. The essentials:

- **No** `<style>`/`class`/CSS, `mask`, `@font-face`, `<foreignObject>`, `<symbol>`+`<use>`,
  `textPath`, `<animate*>`, `<script>`. Use inline attributes only.
- **Characters**: typography/symbols as raw Unicode (`—`, `→`, `±`, `α`); escape only `& < > " '`
  as XML entities. One bad entity aborts the export.
- **Use these** (they convert to native objects): `marker-start`/`marker-end` → arrowheads;
  `clip-path` on `<image>` → cropped picture; `<pattern data-pptx-pattern="...">` → preset fill;
  gradients, `stroke-dasharray`, rotation, donut/pie arc paths.
- **Text**: one logical line = one `<text>` (inline `<tspan>` for color/weight runs; don't put
  `x`/`y`/`dy` on inline tspans or the line splits).
- **viewBox** must equal the canvas pixel size; work in pixels, not pt.

## The quality gate is the contract

`svg_quality_checker.py` enforces the rules above **before** export (finalize rewrites the SVG and
would mask source-level violations). Any **error** must be fixed by re-authoring the offending
element — there is no auto-fix; the substitute must keep the design intent. Warnings are advisory.

## Setup

```bash
python3 -m venv .venv && source .venv/bin/activate
pip install -r requirements.txt
```

Optional: `pip install cairosvg` (preferred PNG-fallback renderer for legacy-Office compatibility;
needs the system `cairo` lib — `brew install cairo` on macOS). Without it the toolkit falls back to
`svglib`+`reportlab`, which are already in `requirements.txt`.

Files in this skill

  • .claude-plugin/marketplace.json701 B
  • .claude-plugin/plugin.json458 B
  • README_zh.md11.3 KB
  • SKILL.md4.6 KB
  • convert.py4.4 KB
  • examples/filtration_demo.pptx30.2 KB
  • examples/filtration_demo.svg6.5 KB
  • examples/support_structure_demo.pptx31.9 KB
  • examples/support_structure_demo.svg10.2 KB
  • references/png-to-svg-prompt.md4.8 KB
  • references/shared-standards.md6.8 KB
  • requirements.txt476 B
  • scripts/config.py21.1 KB
  • scripts/error_helper.py17.2 KB
  • scripts/finalize_svg.py12.3 KB
  • scripts/pptx_animations.py26.1 KB
  • scripts/project_utils.py15.4 KB
  • scripts/svg_position_calculator.py55.5 KB

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…