ppt-template-creator
它能做什么
本技能指导智能体把公司的 PowerPoint 模板打包成一项独立的技能。适合希望未来的演示文稿都遵循其认可模板的团队。
适用场景
- ✓当你已有一份正式的 PowerPoint 模板,并希望重复使用时。
- ✓当你的团队需要把标准模板转换为技能的时候。
- ✓当你希望为智能体记录模板的版式和占位符的时候。
技能链接
https://github.com/anthropics/financial-services/blob/main/plugins/vertical-plugins/financial-analysis/skills/ppt-template-creator/SKILL.md复制后粘贴给你的 AI(Claude、ChatGPT 或 Cursor),让它按照说明操作。
使用方法
最简单的方法:复制下面的消息,粘贴给你的 AI。它会读取这个技能并按说明操作。
可直接粘贴的消息
适用于 Claude Code、Codex 或 Cursor:在项目文件夹中运行,即可安装该技能。
下载 SKILL.md,放进智能体的技能文件夹。
可以这样问 AI
“请帮我把公司的 PowerPoint 模板转换为可复用的技能,以便未来的演示文稿都遵循该模板。”
每周 5 个新技能,1 分钟读完。
工作原理
智能体会读取模板的版式和占位符位置,将模板文件添加到新的技能文件夹中,并编写使用说明。随后,它会用一份示例演示文稿来测试该技能。
技术内容(原始 SKILL.md)
作者在 GitHub 上的英文原文。
PPT Template Creator
This skill creates SKILLS, not presentations. Use this when a user wants to turn their PowerPoint template into a reusable skill that can generate presentations later. If the user just wants to create a presentation, use the pptx skill instead.
The generated skill includes:
assets/template.pptx- the template fileSKILL.md- complete instructions (no reference to this meta skill needed)
For general skill-building best practices, refer to the skill-creator skill. This skill focuses on PPT-specific patterns.
Workflow
- User provides template (.pptx or .potx)
- Analyze template - extract layouts, placeholders, dimensions
- Initialize skill - use the
skill-creatorskill to set up the skill structure - Add template - copy .pptx to
assets/template.pptx - Write SKILL.md - follow template below with PPT-specific details
- Create example - generate sample presentation to validate
- Package - use the
skill-creatorskill to package into a .skill file
Step 2: Analyze Template
CRITICAL: Extract precise placeholder positions - this determines content area boundaries.
from pptx import Presentation
prs = Presentation(template_path)
print(f"Dimensions: {prs.slide_width/914400:.2f}\" x {prs.slide_height/914400:.2f}\"")
print(f"Layouts: {len(prs.slide_layouts)}")
for idx, layout in enumerate(prs.slide_layouts):
print(f"\n[{idx}] {layout.name}:")
for ph in layout.placeholders:
try:
ph_idx = ph.placeholder_format.idx
ph_type = ph.placeholder_format.type
# IMPORTANT: Extract exact positions in inches
left = ph.left / 914400
top = ph.top / 914400
width = ph.width / 914400
height = ph.height / 914400
print(f" idx={ph_idx}, type={ph_type}")
print(f" x={left:.2f}\", y={top:.2f}\", w={width:.2f}\", h={height:.2f}\"")
except:
pass
Key measurements to document:
- Title position: Where does the title placeholder sit?
- Subtitle/description: Where is the subtitle line?
- Footer placeholders: Where do footers/sources appear?
- Content area: The space BETWEEN subtitle and footer is your content area
Finding the True Content Start Position
CRITICAL: The content area does NOT always start immediately after the subtitle placeholder. Many templates have a visual border, line, or reserved space between the subtitle and content area.
Best approach: Look at Layout 2 or similar "content" layouts that have an OBJECT placeholder - this placeholder's y position indicates where content should actually start.
# Find the OBJECT placeholder to determine true content start
for idx, layout in enumerate(prs.slide_layouts):
for ph in layout.placeholders:
try:
if ph.placeholder_format.type == 7: # OBJECT type
top = ph.top / 914400
print(f"Layout [{idx}] {layout.name}: OBJECT starts at y={top:.2f}\"")
# This y value is where your content should start!
except:
pass
Example: A template might have:
- Subtitle ending at y=1.38"
- But OBJECT placeholder starting at y=1.90"
- The gap (0.52") is reserved for a border/line - do not place content there
Use the OBJECT placeholder's y position as your content start, not the subtitle's end position.
Step 5: Write SKILL.md
The generated skill should have this structure:
[company]-ppt-template/
├── SKILL.md
└── assets/
└── template.pptx
Generated SKILL.md Template
The generated SKILL.md must be self-contained with all instructions embedded. Use this template, filling in the bracketed values from your analysis:
---
name: [company]-ppt-template
description: [Company] PowerPoint template for creating presentations. Use when creating [Company]-branded pitch decks, board materials, or client presentations.
---
# [Company] PPT Template
Template: `assets/template.pptx` ([WIDTH]" x [HEIGHT]", [N] layouts)
## Creating Presentations
```python
from pptx import Presentation
prs = Presentation("path/to/skill/assets/template.pptx")
# DELETE all existing slides first
while len(prs.slides) > 0:
rId = prs.slides._sldIdLst[0].rId
prs.part.drop_rel(rId)
del prs.slides._sldIdLst[0]
# Add slides from layouts
slide = prs.slides.add_slide(prs.slide_layouts[LAYOUT_IDX])
```
#
常见问题
它会制作演示文稿吗?
不会。本技能制作的是一项技能,而不是演示文稿。如需制作演示文稿,应使用 pptx 技能。
新技能包含哪些文件?
模板文件和一个 SKILL.md 说明文件,因此新技能无需依赖本创建技能即可运行。
可以打包分享吗?
可以。本技能会使用 skill-creator 技能,将结果打包成一个技能文件。
详情
作者的原始描述
Creates self-contained PPT template SKILLS (not presentations) from user-provided PowerPoint templates. Use ONLY when a user wants to create a reusable skill from their template. For creating actual presentations, use the pptx skill instead.
热度
- GitHub 星标
- 41k
- 排名
- #6609
- 许可证
- Apache-2.0
- 更新时间
- 2026/10/28
评论
- …