pptx

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

PPTX Skill

PPTX Skill

Quick Reference

快速参考

TaskGuide
Read/analyze content
python -m markitdown presentation.pptx
Edit or create from templateRead editing.md
Create from scratchRead pptxgenjs.md

任务指南
读取/分析内容
python -m markitdown presentation.pptx
从模板编辑或创建阅读 editing.md
从零开始创建阅读 pptxgenjs.md

Reading Content

读取内容

bash
undefined
bash
undefined

Text extraction

提取文本

python -m markitdown presentation.pptx
python -m markitdown presentation.pptx

Visual overview

可视化概览

python scripts/thumbnail.py presentation.pptx
python scripts/thumbnail.py presentation.pptx

Raw XML

原始XML

python scripts/office/unpack.py presentation.pptx unpacked/

---
python scripts/office/unpack.py presentation.pptx unpacked/

---

Editing Workflow

编辑工作流

Read editing.md for full details.
  1. Analyze template with
    thumbnail.py
  2. Unpack → manipulate slides → edit content → clean → pack

完整细节请阅读 editing.md
  1. 使用
    thumbnail.py
    分析模板
  2. 解压 → 操作幻灯片 → 编辑内容 → 清理 → 打包

Creating from Scratch

从零开始创建

Read pptxgenjs.md for full details.
Use when no template or reference presentation is available.

完整细节请阅读 pptxgenjs.md
适用于没有模板或参考演示文稿的场景。

Design Ideas

设计思路

Don't create boring slides. Plain bullets on a white background won't impress anyone. Consider ideas from this list for each slide.
不要制作乏味的幻灯片。 白底黑字的项目符号列表无法打动任何人。为每张幻灯片参考以下设计思路。

Before Starting

开始之前

  • Pick a bold, content-informed color palette: The palette should feel designed for THIS topic. If swapping your colors into a completely different presentation would still "work," you haven't made specific enough choices.
  • Dominance over equality: One color should dominate (60-70% visual weight), with 1-2 supporting tones and one sharp accent. Never give all colors equal weight.
  • Dark/light contrast: Dark backgrounds for title + conclusion slides, light for content ("sandwich" structure). Or commit to dark throughout for a premium feel.
  • Commit to a visual motif: Pick ONE distinctive element and repeat it — rounded image frames, icons in colored circles, thick single-side borders. Carry it across every slide.
  • 选择贴合内容的醒目调色板:调色板需为当前主题量身定制。如果将你的配色方案换到完全不同的演示文稿中依然“适用”,说明你的选择不够具有针对性。
  • 主色优先,避免均衡:一种颜色应占主导(视觉权重60-70%),搭配1-2种辅助色和一种鲜明的强调色。绝不能让所有颜色权重均等。
  • 明暗对比:标题页和结论页使用深色背景,内容页使用浅色(“三明治”结构)。或全程使用深色背景,打造高端质感。
  • 坚持统一视觉主题:选择一个独特元素并重复使用——圆角图片框、彩色圆圈内的图标、单侧粗边框。让它贯穿每一张幻灯片。

Color Palettes

调色板

Choose colors that match your topic — don't default to generic blue. Use these palettes as inspiration:
ThemePrimarySecondaryAccent
Midnight Executive
1E2761
(navy)
CADCFC
(ice blue)
FFFFFF
(white)
Forest & Moss
2C5F2D
(forest)
97BC62
(moss)
F5F5F5
(cream)
Coral Energy
F96167
(coral)
F9E795
(gold)
2F3C7E
(navy)
Warm Terracotta
B85042
(terracotta)
E7E8D1
(sand)
A7BEAE
(sage)
Ocean Gradient
065A82
(deep blue)
1C7293
(teal)
21295C
(midnight)
Charcoal Minimal
36454F
(charcoal)
F2F2F2
(off-white)
212121
(black)
Teal Trust
028090
(teal)
00A896
(seafoam)
02C39A
(mint)
Berry & Cream
6D2E46
(berry)
A26769
(dusty rose)
ECE2D0
(cream)
Sage Calm
84B59F
(sage)
69A297
(eucalyptus)
50808E
(slate)
Cherry Bold
990011
(cherry)
FCF6F5
(off-white)
2F3C7E
(navy)
选择与主题匹配的颜色——不要默认使用通用蓝色。可参考以下调色板:
主题主色辅助色强调色
午夜商务风
1E2761
(藏青)
CADCFC
(冰蓝)
FFFFFF
(白)
森林苔藓风
2C5F2D
(森林绿)
97BC62
(苔藓绿)
F5F5F5
(米白)
活力珊瑚风
F96167
(珊瑚红)
F9E795
(金黄)
2F3C7E
(藏青)
暖陶土风
B85042
(陶土红)
E7E8D1
(沙色)
A7BEAE
(鼠尾草绿)
海洋渐变风
065A82
(深蓝)
1C7293
(水鸭绿)
21295C
(午夜蓝)
炭黑极简风
36454F
(炭黑)
F2F2F2
(米白)
212121
(黑)
青蓝可靠风
028090
(青蓝)
00A896
(海沫绿)
02C39A
(薄荷绿)
浆果奶油风
6D2E46
(浆果紫)
A26769
(灰粉)
ECE2D0
(奶油白)
鼠尾草静谧风
84B59F
(鼠尾草绿)
69A297
(尤加利绿)
50808E
(灰蓝)
樱桃醒目风
990011
(樱桃红)
FCF6F5
(米白)
2F3C7E
(藏青)

For Each Slide

单页幻灯片设计

Every slide needs a visual element — image, chart, icon, or shape. Text-only slides are forgettable.
Layout options:
  • Two-column (text left, illustration on right)
  • Icon + text rows (icon in colored circle, bold header, description below)
  • 2x2 or 2x3 grid (image on one side, grid of content blocks on other)
  • Half-bleed image (full left or right side) with content overlay
Data display:
  • Large stat callouts (big numbers 60-72pt with small labels below)
  • Comparison columns (before/after, pros/cons, side-by-side options)
  • Timeline or process flow (numbered steps, arrows)
Visual polish:
  • Icons in small colored circles next to section headers
  • Italic accent text for key stats or taglines
每张幻灯片都需要视觉元素——图片、图表、图标或形状。纯文本幻灯片容易被遗忘。
版式选项:
  • 双栏布局(左侧文本,右侧插图)
  • 图标+文本行(图标置于彩色圆圈内,搭配粗体标题和下方描述)
  • 2x2或2x3网格(一侧为图片,另一侧为内容块网格)
  • 半出血图片(左侧或右侧全屏)叠加内容
数据展示:
  • 大数字标注(60-72号大数字,下方搭配小标签)
  • 对比栏(前后对比、优缺点对比、并列选项)
  • 时间线或流程步骤(带编号的步骤、箭头)
视觉优化:
  • 章节标题旁添加置于彩色小圆圈内的图标
  • 关键数据或标语使用斜体强调文本

Typography

排版

Choose an interesting font pairing — don't default to Arial. Pick a header font with personality and pair it with a clean body font.
Header FontBody Font
GeorgiaCalibri
Arial BlackArial
CalibriCalibri Light
CambriaCalibri
Trebuchet MSCalibri
ImpactArial
PalatinoGaramond
ConsolasCalibri
ElementSize
Slide title36-44pt bold
Section header20-24pt bold
Body text14-16pt
Captions10-12pt muted
选择有趣的字体搭配——不要默认使用Arial。选择一款有个性的标题字体,搭配简洁的正文字体。
标题字体正文字体
GeorgiaCalibri
Arial BlackArial
CalibriCalibri Light
CambriaCalibri
Trebuchet MSCalibri
ImpactArial
PalatinoGaramond
ConsolasCalibri
元素字号
幻灯片标题36-44号粗体
章节标题20-24号粗体
正文文本14-16号
说明文字10-12号浅色调

Spacing

间距

  • 0.5" minimum margins
  • 0.3-0.5" between content blocks
  • Leave breathing room—don't fill every inch
  • 最小边距0.5英寸
  • 内容块之间间距0.3-0.5英寸
  • 留足空白空间——不要填满每一寸区域

Avoid (Common Mistakes)

避坑指南(常见错误)

  • Don't repeat the same layout — vary columns, cards, and callouts across slides
  • Don't center body text — left-align paragraphs and lists; center only titles
  • Don't skimp on size contrast — titles need 36pt+ to stand out from 14-16pt body
  • Don't default to blue — pick colors that reflect the specific topic
  • Don't mix spacing randomly — choose 0.3" or 0.5" gaps and use consistently
  • Don't style one slide and leave the rest plain — commit fully or keep it simple throughout
  • Don't create text-only slides — add images, icons, charts, or visual elements; avoid plain title + bullets
  • Don't forget text box padding — when aligning lines or shapes with text edges, set
    margin: 0
    on the text box or offset the shape to account for padding
  • Don't use low-contrast elements — icons AND text need strong contrast against the background; avoid light text on light backgrounds or dark text on dark backgrounds
  • NEVER use accent lines under titles — these are a hallmark of AI-generated slides; use whitespace or background color instead

  • 不要重复使用相同版式——在幻灯片间变换分栏、卡片和标注样式
  • 不要居中对齐正文——段落和列表左对齐;仅标题居中
  • 不要忽略字号对比——标题需使用36号以上字号,与14-16号正文形成明显区分
  • 不要默认使用蓝色——选择贴合特定主题的颜色
  • 不要随意设置间距——选择0.3英寸或0.5英寸的间距并保持一致
  • 不要只美化单张幻灯片——要么全程保持精致,要么整体简洁
  • 不要制作纯文本幻灯片——添加图片、图标、图表或视觉元素;避免纯标题+项目符号的形式
  • 不要忘记文本框内边距——当线条或形状与文本边缘对齐时,需将文本框的
    margin
    设为0,或偏移形状以适配内边距
  • 不要使用低对比度元素——图标和文本都需要与背景形成强烈对比;避免浅色文本配浅色背景,或深色文本配深色背景
  • 绝对不要在标题下方添加装饰线——这是AI生成幻灯片的典型特征;改用空白或背景色替代

QA (Required)

QA(必做步骤)

Assume there are problems. Your job is to find them.
Your first render is almost never correct. Approach QA as a bug hunt, not a confirmation step. If you found zero issues on first inspection, you weren't looking hard enough.
默认存在问题。你的任务是找出它们。
首次生成的幻灯片几乎不可能完美。要像寻找Bug一样对待QA,而不是确认无误的步骤。如果首次检查没有发现任何问题,说明你还不够仔细。

Content QA

内容校验

bash
python -m markitdown output.pptx
Check for missing content, typos, wrong order.
When using templates, check for leftover placeholder text:
bash
python -m markitdown output.pptx | grep -iE "xxxx|lorem|ipsum|this.*(page|slide).*layout"
If grep returns results, fix them before declaring success.
bash
python -m markitdown output.pptx
检查是否有内容缺失、拼写错误、顺序错误。
使用模板时,检查是否有残留的占位符文本:
bash
python -m markitdown output.pptx | grep -iE "xxxx|lorem|ipsum|this.*(page|slide).*layout"
如果grep返回结果,修复后再确认完成。

Visual QA

视觉校验

⚠️ USE SUBAGENTS — even for 2-3 slides. You've been staring at the code and will see what you expect, not what's there. Subagents have fresh eyes.
Convert slides to images (see Converting to Images), then use this prompt:
Visually inspect these slides. Assume there are issues — find them.

Look for:
- Overlapping elements (text through shapes, lines through words, stacked elements)
- Text overflow or cut off at edges/box boundaries
- Decorative lines positioned for single-line text but title wrapped to two lines
- Source citations or footers colliding with content above
- Elements too close (< 0.3" gaps) or cards/sections nearly touching
- Uneven gaps (large empty area in one place, cramped in another)
- Insufficient margin from slide edges (< 0.5")
- Columns or similar elements not aligned consistently
- Low-contrast text (e.g., light gray text on cream-colored background)
- Low-contrast icons (e.g., dark icons on dark backgrounds without a contrasting circle)
- Text boxes too narrow causing excessive wrapping
- Leftover placeholder content

For each slide, list issues or areas of concern, even if minor.

Read and analyze these images:
1. /path/to/slide-01.jpg (Expected: [brief description])
2. /path/to/slide-02.jpg (Expected: [brief description])

Report ALL issues found, including minor ones.
⚠️ 请使用子代理——即使只有2-3张幻灯片。你一直盯着代码,看到的是预期效果,而非实际效果。子代理拥有全新的视角。
将幻灯片转换为图片(见转换为图片),然后使用以下提示词:
请视觉检查这些幻灯片。默认存在问题——找出它们。

检查要点:
- 元素重叠(文本穿过形状、线条穿过文字、元素堆叠)
- 文本溢出或被边缘/文本框边界截断
- 装饰线是为单行文本设计的,但标题换行成了两行
- 来源引用或页脚与上方内容冲突
- 元素间距过近(小于0.3英寸)或卡片/区块几乎相连
- 间距不均(一处空白过大,另一处过于拥挤)
- 与幻灯片边缘的边距不足(小于0.5英寸)
- 分栏或同类元素未对齐一致
- 文本对比度低(例如:浅灰色文本配米黄色背景)
- 图标对比度低(例如:深色图标配深色背景,且无对比色圆圈衬托)
- 文本框过窄导致换行过多
- 残留的占位符内容

列出每张幻灯片的问题或需要注意的地方,即使是小问题也不要遗漏。

请阅读并分析这些图片:
1. /path/to/slide-01.jpg(预期:[简要描述])
2. /path/to/slide-02.jpg(预期:[简要描述])

报告所有发现的问题,包括小问题。

Verification Loop

验证循环

  1. Generate slides → Convert to images → Inspect
  2. List issues found (if none found, look again more critically)
  3. Fix issues
  4. Re-verify affected slides — one fix often creates another problem
  5. Repeat until a full pass reveals no new issues
Do not declare success until you've completed at least one fix-and-verify cycle.

  1. 生成幻灯片 → 转换为图片 → 检查
  2. 列出发现的问题(如果没有发现问题,请更仔细地重新检查)
  3. 修复问题
  4. 重新验证受影响的幻灯片——一次修复往往会引发另一个问题
  5. 重复上述步骤,直到完整检查未发现新问题
至少完成一次修复-验证循环后,才能确认完成。

Converting to Images

转换为图片

Convert presentations to individual slide images for visual inspection:
bash
python scripts/office/soffice.py --headless --convert-to pdf output.pptx
pdftoppm -jpeg -r 150 output.pdf slide
This creates
slide-01.jpg
,
slide-02.jpg
, etc.
To re-render specific slides after fixes:
bash
pdftoppm -jpeg -r 150 -f N -l N output.pdf slide-fixed

将演示文稿转换为单张幻灯片图片,以便视觉检查:
bash
python scripts/office/soffice.py --headless --convert-to pdf output.pptx
pdftoppm -jpeg -r 150 output.pdf slide
这将生成
slide-01.jpg
slide-02.jpg
等文件。
修复后重新渲染特定幻灯片:
bash
pdftoppm -jpeg -r 150 -f N -l N output.pdf slide-fixed

Dependencies

依赖项

  • pip install "markitdown[pptx]"
    - text extraction
  • pip install Pillow
    - thumbnail grids
  • npm install -g pptxgenjs
    - creating from scratch
  • LibreOffice (
    soffice
    ) - PDF conversion (auto-configured for sandboxed environments via
    scripts/office/soffice.py
    )
  • Poppler (
    pdftoppm
    ) - PDF to images
  • pip install "markitdown[pptx]"
    - 文本提取
  • pip install Pillow
    - 缩略图网格
  • npm install -g pptxgenjs
    - 从零开始创建幻灯片
  • LibreOffice (
    soffice
    ) - PDF转换(通过
    scripts/office/soffice.py
    为沙箱环境自动配置)
  • Poppler (
    pdftoppm
    ) - PDF转图片