html-to-ppt

Automatically reads local HTML files, intelligently parses elements such as headings, paragraphs, tables, lists, images, and code blocks, and converts them into a well-structured PowerPoint presentation (.pptx). Supports 16:9 widescreen, automatic cover generation, zebra-striped table styling, base64-embedded images, and ordered/unordered lists.

Installation

Review the source and dependencies with a prompt. A package is available to download.

Install with an AI assistant

Copy the prompt so your assistant can review the pinned revision and dependencies first.

View promptHide prompt
Check whether SkillPI Skill Finder is installed for your current agent. If it is missing, install and enable it using the official instructions at https://github.com/Findskills/skillpi. Then use Skill Finder to locate and install "html-to-ppt" from this exact SkillPI detail page: https://skillpi.com/skills/deepskill-fc1e173ef2a758683a66d63f7cebf4bc688859167ea02dbc8bd9ad331b57b38d. Verify the upstream source and version against https://skillhub.cn/skills/user_3d494648/html-to-ppt before installing. If they do not match, stop and report the mismatch. Report the installed path and source version.

Source and setup

skillhub.cn

Setup guidance pending

See the original source for supported tools, dependencies, and permissions.

Installation test pending

Automatically reads local HTML files, intelligently parses elements such as headings, paragraphs, tables, lists, images, and code blocks, and converts them into a well-structured PowerPoint presentation (.pptx). Supports 16:9 widescreen, automatic cover generation, zebra-striped table styling, base64-embedded images, and ordered/unordered lists.

0 Downloads

Introduction source: third_party · user_3d494648 · 0.0.0 Reference

SkillPi interpretation

Tasks
Translation pending; see source documentation.
Software, accounts and paid services
Python 3.8+ python-pptx beautifulsoup4 lxml Pillow
Testing
Not tested

Browse files

Browse files at the source ↗

Original SKILL.md

Open original ↗
Frontmatter
name: html-to-pptx
description: 自动读取本地 HTML 文件,智能解析标题、段落、表格、列表、图片、代码块等元素,并转换为结构清晰的 PowerPoint 演示文稿(.pptx)。支持 16:9 宽屏、自动封面生成、表格斑马纹配色、base64 内嵌图片、有序/无序列表。
version: 1.0.0
author: Marvis
tags: [html, pptx, converter, document, presentation]

HTML to PPTX

自动读取本地 HTML 文件并转换为 PowerPoint 演示文稿。

使用方法

python html_to_pptx.py <输入HTML路径> [输出PPTX路径]

不指定输出路径时,自动在 HTML 同目录生成同名 .pptx 文件。

功能

功能 说明
标题识别 h1~h6 自动作为幻灯片分页标志和标题
封面生成 提取 <title> 作为封面页,深色主题
段落文本 自动排版,适配幻灯片宽度
表格 HTML 表格完整转换,深色表头 + 斑马纹
列表 有序列表 / 无序列表
图片 本地相对路径图片 + base64 内嵌图片
代码块 <pre> 代码块等宽字体灰色背景
分割线 <hr> 转换为视觉分隔线

依赖

  • Python 3.8+
  • python-pptx
  • beautifulsoup4
  • lxml
  • Pillow
pip install python-pptx beautifulsoup4 lxml

示例

输入 HTML:

<h1>季度总结</h1>
<p>本季度营收增长 30%。</p>
<table>
  <tr><th>指标</th><th>Q1</th><th>Q2</th></tr>
  <tr><td>营收</td><td>1200</td><td>1580</td></tr>
</table>
<ul>
  <li>项目A已上线</li>
  <li>项目B进行中</li>
</ul>

输出:包含封面、指标表格、项目列表的完整 PPTX。

Current listing version

0.0.0

Verify the source revision ↗

Quality assessment

Out of 100 · Assessment report from SkillPi LAB.

Scenario Value85/100

Highlights

  • 解决 HTML 转 PPTX 的实际文档转换需求
  • 功能覆盖全面,支持标题、表格、列表、图片、代码块等多种元素
  • 受众广泛,适用于办公、汇报等高频场景
Trigger Precision95/100

Highlights

  • 触发描述清晰完整,覆盖核心功能点
  • description 位置正确,无截断或错位
Structure and Standards90/100

Highlights

  • 文档结构完整,包含使用方法、功能说明、依赖、示例
  • 步骤清晰,有端到端示例,frontmatter 完整
Execution Reliability70/100

Areas to improve

  • 异常处理缺失 Reported severity: Major

    未提及对 HTML 文件不存在、图片路径错误、依赖缺失等主要异常的捕获与处理机制

    Recommendation: 建议在脚本中添加 try-catch 逻辑,对文件读取、图片加载、依赖调用等关键步骤进行异常处理,并给出友好提示

Highlights

  • 依赖明确,参数说明清晰
  • 支持 base64 内嵌图片,提升兼容性
Evidence Verifiability (mean of the first four)85/100

The arithmetic mean of the first four original scores, rounded to a whole number.

Static text checks

100 / 100 · skillpi-20261123-no-r3-v1

No current rules matched the text.

This score reflects rule matches in the text and is provided for reference before use. It excludes attachments and runtime behavior.

Permissions and checks before use

Automatically summarized from this main document. Matches may be examples or defensive advice; they are not actual permission declarations. Attachments, external dependencies and runtime behavior are not covered.

  • Install or fetch external dependencies

    Use official sources and pin versions. Check install scripts in an isolated environment. This document check does not cover code downloaded later.

    Mentioned in main document · lines 43

These notices grant no permissions. Your host tool must still confirm file changes, secrets, external transfers or costs as needed.

Security rating and access scope

safe · Static evidence review; not a runtime safety guarantee.

Python 3.8+ python-pptx beautifulsoup4 lxml Pillow

Before use, confirm and authorize actual file access, external services and network destinations in your host. This review grants no runtime permissions.