chore: 1.2.0 rename CLI to open-kimi-ppt-skill and add --version
This commit is contained in:
+14
-4
@@ -4,6 +4,16 @@
|
|||||||
|
|
||||||
本项目遵循 [语义化版本](https://semver.org/lang/zh-CN/)。
|
本项目遵循 [语义化版本](https://semver.org/lang/zh-CN/)。
|
||||||
|
|
||||||
|
## [1.2.0] - 2026-08-06
|
||||||
|
|
||||||
|
### 新增
|
||||||
|
|
||||||
|
- CLI 支持 `-h` / `--help` 与 `-V` / `--version`
|
||||||
|
|
||||||
|
### 变更
|
||||||
|
|
||||||
|
- npm 包名与 CLI 由 `open-kimi-ppt-skills` 统一为 `open-kimi-ppt-skill`(与 GitHub 仓库名一致)。请改用 `npx open-kimi-ppt-skill@latest`;旧包名将不再更新
|
||||||
|
|
||||||
## [1.1.3] - 2026-08-06
|
## [1.1.3] - 2026-08-06
|
||||||
|
|
||||||
### 新增
|
### 新增
|
||||||
@@ -19,7 +29,7 @@
|
|||||||
|
|
||||||
### 变更
|
### 变更
|
||||||
|
|
||||||
- README 默认指引 AI 通过 `npx open-kimi-ppt-skills@latest install -y` 安装,不再建议 clone 仓库
|
- README 默认指引 AI 通过 `npx open-kimi-ppt-skill@latest install -y` 安装,不再建议 clone 仓库
|
||||||
|
|
||||||
## [1.1.2] - 2026-08-06
|
## [1.1.2] - 2026-08-06
|
||||||
|
|
||||||
@@ -57,7 +67,7 @@
|
|||||||
|
|
||||||
- Skill 工作流增加 **step0 本地前置检测**:生成前检查 Node.js 18+、npm/npx、python3,并提示需要 Chromium 系浏览器
|
- Skill 工作流增加 **step0 本地前置检测**:生成前检查 Node.js 18+、npm/npx、python3,并提示需要 Chromium 系浏览器
|
||||||
- 导出脚本在启动时检测 **Node.js 18+** 与 **npm**;缺失或版本过低时给出明确安装指引
|
- 导出脚本在启动时检测 **Node.js 18+** 与 **npm**;缺失或版本过低时给出明确安装指引
|
||||||
- CLI(`open-kimi-ppt-skills`)启动时校验 Node.js 主版本 ≥ 18
|
- CLI(`open-kimi-ppt-skill`)启动时校验 Node.js 主版本 ≥ 18
|
||||||
- 缺失 **PyYAML** 时自动 `pip install --user pyyaml`(与 Pillow / websocket-client 行为一致)
|
- 缺失 **PyYAML** 时自动 `pip install --user pyyaml`(与 Pillow / websocket-client 行为一致)
|
||||||
|
|
||||||
### 文档
|
### 文档
|
||||||
@@ -70,8 +80,8 @@
|
|||||||
|
|
||||||
### 新增
|
### 新增
|
||||||
|
|
||||||
- 首次发布 `open-kimi-ppt-skills`
|
- 首次发布 `open-kimi-ppt-skill`
|
||||||
- PPTD 生成 / 编辑 / 复刻,默认同时交付可编辑 PPTD 项目与 PPTX 成品
|
- PPTD 生成 / 编辑 / 复刻,默认同时交付可编辑 PPTD 项目与 PPTX 成品
|
||||||
- 浏览器侧导出 PPTX(嵌字体、淡入淡出切换),导出前可选多模态视觉质检
|
- 浏览器侧导出 PPTX(嵌字体、淡入淡出切换),导出前可选多模态视觉质检
|
||||||
- 本地在线 PPTD 编辑器(`npx open-kimi-ppt-skills serve`)
|
- 本地在线 PPTD 编辑器(`npx open-kimi-ppt-skill serve`)
|
||||||
- CLI 安装 Skill 到 `~/.agents/skills`(可用 `--target` 指定其他 Agent 目录)
|
- CLI 安装 Skill 到 `~/.agents/skills`(可用 `--target` 指定其他 Agent 目录)
|
||||||
|
|||||||
+14
-4
@@ -4,6 +4,16 @@
|
|||||||
|
|
||||||
This project follows [Semantic Versioning](https://semver.org/).
|
This project follows [Semantic Versioning](https://semver.org/).
|
||||||
|
|
||||||
|
## [1.2.0] - 2026-08-06
|
||||||
|
|
||||||
|
### Added
|
||||||
|
|
||||||
|
- CLI supports `-h` / `--help` and `-V` / `--version`
|
||||||
|
|
||||||
|
### Changed
|
||||||
|
|
||||||
|
- Renamed the npm package and CLI from `open-kimi-ppt-skills` to `open-kimi-ppt-skill` to match the GitHub repo. Use `npx open-kimi-ppt-skill@latest` going forward; the old package name will no longer receive updates
|
||||||
|
|
||||||
## [1.1.3] - 2026-08-06
|
## [1.1.3] - 2026-08-06
|
||||||
|
|
||||||
### Added
|
### Added
|
||||||
@@ -19,7 +29,7 @@ This project follows [Semantic Versioning](https://semver.org/).
|
|||||||
|
|
||||||
### Changed
|
### Changed
|
||||||
|
|
||||||
- README now steers agents to `npx open-kimi-ppt-skills@latest install -y` instead of cloning the repo
|
- README now steers agents to `npx open-kimi-ppt-skill@latest install -y` instead of cloning the repo
|
||||||
|
|
||||||
## [1.1.2] - 2026-08-06
|
## [1.1.2] - 2026-08-06
|
||||||
|
|
||||||
@@ -57,7 +67,7 @@ This project follows [Semantic Versioning](https://semver.org/).
|
|||||||
|
|
||||||
- Skill workflow **step0 prerequisite check**: verify Node.js 18+, npm/npx, and python3 before generation; note that a Chromium-based browser is required for export
|
- Skill workflow **step0 prerequisite check**: verify Node.js 18+, npm/npx, and python3 before generation; note that a Chromium-based browser is required for export
|
||||||
- Export scripts check **Node.js 18+** and **npm** at startup, with clear install guidance when missing or too old
|
- Export scripts check **Node.js 18+** and **npm** at startup, with clear install guidance when missing or too old
|
||||||
- CLI (`open-kimi-ppt-skills`) refuses to start when the Node.js major version is below 18
|
- CLI (`open-kimi-ppt-skill`) refuses to start when the Node.js major version is below 18
|
||||||
- Auto-install **PyYAML** via `pip install --user pyyaml` when missing (same pattern as Pillow / websocket-client)
|
- Auto-install **PyYAML** via `pip install --user pyyaml` when missing (same pattern as Pillow / websocket-client)
|
||||||
|
|
||||||
### Docs
|
### Docs
|
||||||
@@ -70,8 +80,8 @@ This project follows [Semantic Versioning](https://semver.org/).
|
|||||||
|
|
||||||
### Added
|
### Added
|
||||||
|
|
||||||
- Initial release of `open-kimi-ppt-skills`
|
- Initial release of `open-kimi-ppt-skill`
|
||||||
- PPTD create / edit / replicate, delivering both an editable PPTD project and a PPTX by default
|
- PPTD create / edit / replicate, delivering both an editable PPTD project and a PPTX by default
|
||||||
- Browser-side PPTX export (embedded fonts, fade transitions) with optional multimodal visual QA before export
|
- Browser-side PPTX export (embedded fonts, fade transitions) with optional multimodal visual QA before export
|
||||||
- Local in-browser PPTD editor (`npx open-kimi-ppt-skills serve`)
|
- Local in-browser PPTD editor (`npx open-kimi-ppt-skill serve`)
|
||||||
- CLI to install the skill into `~/.agents/skills` (or another agent directory via `--target`)
|
- CLI to install the skill into `~/.agents/skills` (or another agent directory via `--target`)
|
||||||
|
|||||||
@@ -1,8 +1,8 @@
|
|||||||
# open-kimi-ppt-skills
|
# open-kimi-ppt-skill
|
||||||
|
|
||||||
[简体中文](README.md) | [English](README_EN.md)
|
[简体中文](README.md) | [English](README_EN.md)
|
||||||
|
|
||||||
[](https://www.npmjs.com/package/open-kimi-ppt-skills)
|
[](https://www.npmjs.com/package/open-kimi-ppt-skill)
|
||||||
[](https://nodejs.org)
|
[](https://nodejs.org)
|
||||||
|
|
||||||
逆向 Kimi Slides 实现的非官方演示文稿 Skill,让 AI Coding Agent 可以创建、编辑、复刻、读取并导出 PPT/PPTX。每次生成默认产出两份文件:可继续编辑的 PPTD 项目,以及嵌入字体、带淡入淡出翻页切换的 PPTX。支持页内元素动画和[预设主题](theme.md),附带本地浏览器编辑器,可随时手动导出 PPTX。支持 Codex、Claude Code、Cursor、WorkBuddy 等任何兼容 SKILL.md 规范的 Agent。
|
逆向 Kimi Slides 实现的非官方演示文稿 Skill,让 AI Coding Agent 可以创建、编辑、复刻、读取并导出 PPT/PPTX。每次生成默认产出两份文件:可继续编辑的 PPTD 项目,以及嵌入字体、带淡入淡出翻页切换的 PPTX。支持页内元素动画和[预设主题](theme.md),附带本地浏览器编辑器,可随时手动导出 PPTX。支持 Codex、Claude Code、Cursor、WorkBuddy 等任何兼容 SKILL.md 规范的 Agent。
|
||||||
@@ -19,29 +19,29 @@
|
|||||||
对 AI 说「帮我用 npx 安装 open-kimi-ppt skill」,或直接让它执行:
|
对 AI 说「帮我用 npx 安装 open-kimi-ppt skill」,或直接让它执行:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
npx open-kimi-ppt-skills@latest install -y
|
npx open-kimi-ppt-skill@latest install -y
|
||||||
```
|
```
|
||||||
|
|
||||||
**WorkBuddy 用户**:它发现不了共享目录,对 AI 说「帮我用 npx 安装 open-kimi-ppt skill 到 WorkBuddy」,或让它执行:
|
**WorkBuddy 用户**:它发现不了共享目录,对 AI 说「帮我用 npx 安装 open-kimi-ppt skill 到 WorkBuddy」,或让它执行:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
# macOS / Linux
|
# macOS / Linux
|
||||||
npx open-kimi-ppt-skills@latest install --target ~/.workbuddy/skills
|
npx open-kimi-ppt-skill@latest install --target ~/.workbuddy/skills
|
||||||
# Windows
|
# Windows
|
||||||
npx open-kimi-ppt-skills@latest install --target %USERPROFILE%\.workbuddy\skills
|
npx open-kimi-ppt-skill@latest install --target %USERPROFILE%\.workbuddy\skills
|
||||||
```
|
```
|
||||||
|
|
||||||
### 方式二:终端手动安装
|
### 方式二:终端手动安装
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
# 交互多选目录(空格选择、回车确认)
|
# 交互多选目录(空格选择、回车确认)
|
||||||
npx open-kimi-ppt-skills install
|
npx open-kimi-ppt-skill install
|
||||||
|
|
||||||
# 非交互:只装共享目录
|
# 非交互:只装共享目录
|
||||||
npx open-kimi-ppt-skills install -y
|
npx open-kimi-ppt-skill install -y
|
||||||
|
|
||||||
# 装到全部已检测到的 Agent 目录(不存在的会跳过)
|
# 装到全部已检测到的 Agent 目录(不存在的会跳过)
|
||||||
npx open-kimi-ppt-skills install --all
|
npx open-kimi-ppt-skill install --all
|
||||||
```
|
```
|
||||||
|
|
||||||
`--all` 与交互多选会检测以下目录:`~/.agents/skills`、`~/.codex/skills`、`~/.claude/skills`、`~/.cursor/skills`、`~/.workbuddy/skills`。
|
`--all` 与交互多选会检测以下目录:`~/.agents/skills`、`~/.codex/skills`、`~/.claude/skills`、`~/.cursor/skills`、`~/.workbuddy/skills`。
|
||||||
@@ -51,12 +51,12 @@ npx open-kimi-ppt-skills install --all
|
|||||||
先用共享目录,不要默认对每个 Agent 各装一遍;确认某个 Agent 发现不了时,再为它单独指定目录(`--target` 可重复,Windows 下用 `%USERPROFILE%` 代替 `~`):
|
先用共享目录,不要默认对每个 Agent 各装一遍;确认某个 Agent 发现不了时,再为它单独指定目录(`--target` 可重复,Windows 下用 `%USERPROFILE%` 代替 `~`):
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
npx open-kimi-ppt-skills@latest install --target ~/.codex/skills --target ~/.claude/skills
|
npx open-kimi-ppt-skill@latest install --target ~/.codex/skills --target ~/.claude/skills
|
||||||
```
|
```
|
||||||
|
|
||||||
### 更新
|
### 更新
|
||||||
|
|
||||||
再执行一次 `npx open-kimi-ppt-skills@latest install -y` 即可覆盖更新;当初用过 `--target` / `--all` 就带上相同参数。更新只替换 Skill 文件,不影响已生成的 PPTD / PPTX 项目。
|
再执行一次 `npx open-kimi-ppt-skill@latest install -y` 即可覆盖更新;当初用过 `--target` / `--all` 就带上相同参数。更新只替换 Skill 文件,不影响已生成的 PPTD / PPTX 项目。
|
||||||
|
|
||||||
## 使用
|
## 使用
|
||||||
|
|
||||||
@@ -105,30 +105,30 @@ npx open-kimi-ppt-skills@latest install --target ~/.codex/skills --target ~/.cla
|
|||||||
要求带元素入场动画
|
要求带元素入场动画
|
||||||
```
|
```
|
||||||
|
|
||||||
成品示例见 [example/xiaomi-yu7-ppt-animation](example/xiaomi-yu7-ppt-animation)(含 PPTD 项目与 PPTX,可用 `npx open-kimi-ppt-skills serve` 打开预览动画)。
|
成品示例见 [example/xiaomi-yu7-ppt-animation](example/xiaomi-yu7-ppt-animation)(含 PPTD 项目与 PPTX,可用 `npx open-kimi-ppt-skill serve` 打开预览动画)。
|
||||||
|
|
||||||
### 在线编辑与手动导出
|
### 在线编辑与手动导出
|
||||||
|
|
||||||
建议直接让 AI 启动本地编辑器,例如说:
|
建议直接让 AI 启动本地编辑器,例如说:
|
||||||
|
|
||||||
```text
|
```text
|
||||||
帮我执行 npx open-kimi-ppt-skills serve
|
帮我执行 npx open-kimi-ppt-skill serve
|
||||||
```
|
```
|
||||||
|
|
||||||
也可以自己在终端运行:
|
也可以自己在终端运行:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
npx open-kimi-ppt-skills serve
|
npx open-kimi-ppt-skill serve
|
||||||
```
|
```
|
||||||
|
|
||||||
然后打开 <http://127.0.0.1:55173/>,选择包含 `.pptd` 清单、`pages/` 和 `media/` 的完整项目文件夹,即可在浏览器中查看、编辑项目并导出 PPTX。仓库自带的 [example/dji-pocket4](example/dji-pocket4) 是一个完整的 18 页示例项目,可直接打开体验。
|
然后打开 <http://127.0.0.1:55173/>,选择包含 `.pptd` 清单、`pages/` 和 `media/` 的完整项目文件夹,即可在浏览器中查看、编辑项目并导出 PPTX。仓库自带的 [example/dji-pocket4](example/dji-pocket4) 是一个完整的 18 页示例项目,可直接打开体验。
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
# 启动后自动打开浏览器
|
# 启动后自动打开浏览器
|
||||||
npx open-kimi-ppt-skills serve --open
|
npx open-kimi-ppt-skill serve --open
|
||||||
|
|
||||||
# 使用其他端口
|
# 使用其他端口
|
||||||
npx open-kimi-ppt-skills serve --port 56000
|
npx open-kimi-ppt-skill serve --port 56000
|
||||||
```
|
```
|
||||||
|
|
||||||
可写目录需要使用支持 File System Access API 的 Chromium 系浏览器;其他浏览器会回退为只读文件夹上传。按 `Ctrl+C` 停止服务。
|
可写目录需要使用支持 File System Access API 的 Chromium 系浏览器;其他浏览器会回退为只读文件夹上传。按 `Ctrl+C` 停止服务。
|
||||||
|
|||||||
+15
-15
@@ -1,8 +1,8 @@
|
|||||||
# open-kimi-ppt-skills
|
# open-kimi-ppt-skill
|
||||||
|
|
||||||
[简体中文](README.md) | [English](README_EN.md)
|
[简体中文](README.md) | [English](README_EN.md)
|
||||||
|
|
||||||
[](https://www.npmjs.com/package/open-kimi-ppt-skills)
|
[](https://www.npmjs.com/package/open-kimi-ppt-skill)
|
||||||
[](https://nodejs.org)
|
[](https://nodejs.org)
|
||||||
|
|
||||||
An unofficial presentation skill for AI coding agents, reverse-engineered from Kimi Slides. It lets your agent create, edit, replicate, read, and export PPT/PPTX files. Each run produces two outputs by default: an editable PPTD project, and a PPTX with embedded fonts and fade page transitions. On-slide element animations and [preset themes](theme_EN.md) are supported, and a local in-browser PPTD editor is included for manual export. Works with Codex, Claude Code, Cursor, WorkBuddy, and any agent that supports the SKILL.md format.
|
An unofficial presentation skill for AI coding agents, reverse-engineered from Kimi Slides. It lets your agent create, edit, replicate, read, and export PPT/PPTX files. Each run produces two outputs by default: an editable PPTD project, and a PPTX with embedded fonts and fade page transitions. On-slide element animations and [preset themes](theme_EN.md) are supported, and a local in-browser PPTD editor is included for manual export. Works with Codex, Claude Code, Cursor, WorkBuddy, and any agent that supports the SKILL.md format.
|
||||||
@@ -19,29 +19,29 @@ Node.js 18 or later is required. **Install with `npx` — do not clone the repos
|
|||||||
Say "Install the open-kimi-ppt skill for me with npx", or have it run:
|
Say "Install the open-kimi-ppt skill for me with npx", or have it run:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
npx open-kimi-ppt-skills@latest install -y
|
npx open-kimi-ppt-skill@latest install -y
|
||||||
```
|
```
|
||||||
|
|
||||||
**WorkBuddy users**: WorkBuddy can't discover the shared directory. Say "Install the open-kimi-ppt skill for me with npx into WorkBuddy", or have it run:
|
**WorkBuddy users**: WorkBuddy can't discover the shared directory. Say "Install the open-kimi-ppt skill for me with npx into WorkBuddy", or have it run:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
# macOS / Linux
|
# macOS / Linux
|
||||||
npx open-kimi-ppt-skills@latest install --target ~/.workbuddy/skills
|
npx open-kimi-ppt-skill@latest install --target ~/.workbuddy/skills
|
||||||
# Windows
|
# Windows
|
||||||
npx open-kimi-ppt-skills@latest install --target %USERPROFILE%\.workbuddy\skills
|
npx open-kimi-ppt-skill@latest install --target %USERPROFILE%\.workbuddy\skills
|
||||||
```
|
```
|
||||||
|
|
||||||
### Option 2: Manual install
|
### Option 2: Manual install
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
# Interactive checklist (space to select, Enter to confirm)
|
# Interactive checklist (space to select, Enter to confirm)
|
||||||
npx open-kimi-ppt-skills install
|
npx open-kimi-ppt-skill install
|
||||||
|
|
||||||
# Non-interactive: shared directory only
|
# Non-interactive: shared directory only
|
||||||
npx open-kimi-ppt-skills install -y
|
npx open-kimi-ppt-skill install -y
|
||||||
|
|
||||||
# All detected agent skill directories (missing ones are skipped)
|
# All detected agent skill directories (missing ones are skipped)
|
||||||
npx open-kimi-ppt-skills install --all
|
npx open-kimi-ppt-skill install --all
|
||||||
```
|
```
|
||||||
|
|
||||||
Directories detected by `--all` and the interactive checklist: `~/.agents/skills`, `~/.codex/skills`, `~/.claude/skills`, `~/.cursor/skills`, `~/.workbuddy/skills`.
|
Directories detected by `--all` and the interactive checklist: `~/.agents/skills`, `~/.codex/skills`, `~/.claude/skills`, `~/.cursor/skills`, `~/.workbuddy/skills`.
|
||||||
@@ -51,12 +51,12 @@ Directories detected by `--all` and the interactive checklist: `~/.agents/skills
|
|||||||
Start with the shared directory instead of installing once per agent. If a specific agent can't discover the skill there, pass its directory explicitly (`--target` may be repeated; on Windows use `%USERPROFILE%` instead of `~`):
|
Start with the shared directory instead of installing once per agent. If a specific agent can't discover the skill there, pass its directory explicitly (`--target` may be repeated; on Windows use `%USERPROFILE%` instead of `~`):
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
npx open-kimi-ppt-skills@latest install --target ~/.codex/skills --target ~/.claude/skills
|
npx open-kimi-ppt-skill@latest install --target ~/.codex/skills --target ~/.claude/skills
|
||||||
```
|
```
|
||||||
|
|
||||||
### Update
|
### Update
|
||||||
|
|
||||||
Run `npx open-kimi-ppt-skills@latest install -y` again to overwrite the local installation; if you originally used `--target` / `--all`, pass the same flags. Updating only replaces the skill files and does not touch PPTD / PPTX projects you already generated.
|
Run `npx open-kimi-ppt-skill@latest install -y` again to overwrite the local installation; if you originally used `--target` / `--all`, pass the same flags. Updating only replaces the skill files and does not touch PPTD / PPTX projects you already generated.
|
||||||
|
|
||||||
## Usage
|
## Usage
|
||||||
|
|
||||||
@@ -93,30 +93,30 @@ Use open-kimi-ppt to create a Xiaomi YU7 intro PPT, with images as backgrounds f
|
|||||||
Require element entrance animations.
|
Require element entrance animations.
|
||||||
```
|
```
|
||||||
|
|
||||||
See the sample deck at [example/xiaomi-yu7-ppt-animation](example/xiaomi-yu7-ppt-animation) (PPTD project + PPTX; open with `npx open-kimi-ppt-skills serve` to preview animations).
|
See the sample deck at [example/xiaomi-yu7-ppt-animation](example/xiaomi-yu7-ppt-animation) (PPTD project + PPTX; open with `npx open-kimi-ppt-skill serve` to preview animations).
|
||||||
|
|
||||||
### Edit online and export manually
|
### Edit online and export manually
|
||||||
|
|
||||||
Prefer asking your agent to start the local editor, for example:
|
Prefer asking your agent to start the local editor, for example:
|
||||||
|
|
||||||
```text
|
```text
|
||||||
Run npx open-kimi-ppt-skills serve for me.
|
Run npx open-kimi-ppt-skill serve for me.
|
||||||
```
|
```
|
||||||
|
|
||||||
Or run it yourself in a terminal:
|
Or run it yourself in a terminal:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
npx open-kimi-ppt-skills serve
|
npx open-kimi-ppt-skill serve
|
||||||
```
|
```
|
||||||
|
|
||||||
Then open <http://127.0.0.1:55173/> and choose a complete project folder containing the `.pptd` manifest, `pages/`, and `media/` to view, edit, and export PPTX in the browser. The bundled [example/dji-pocket4](example/dji-pocket4) project — a complete 18-page deck — is ready to open for a quick tour.
|
Then open <http://127.0.0.1:55173/> and choose a complete project folder containing the `.pptd` manifest, `pages/`, and `media/` to view, edit, and export PPTX in the browser. The bundled [example/dji-pocket4](example/dji-pocket4) project — a complete 18-page deck — is ready to open for a quick tour.
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
# Open the browser after startup
|
# Open the browser after startup
|
||||||
npx open-kimi-ppt-skills serve --open
|
npx open-kimi-ppt-skill serve --open
|
||||||
|
|
||||||
# Use another port
|
# Use another port
|
||||||
npx open-kimi-ppt-skills serve --port 56000
|
npx open-kimi-ppt-skill serve --port 56000
|
||||||
```
|
```
|
||||||
|
|
||||||
Writable folder access requires a Chromium-based browser with the File System Access API. Other browsers fall back to read-only folder upload. Press `Ctrl+C` to stop the server.
|
Writable folder access requires a Chromium-based browser with the File System Access API. Other browsers fall back to read-only folder upload. Press `Ctrl+C` to stop the server.
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
#!/usr/bin/env node
|
#!/usr/bin/env node
|
||||||
|
|
||||||
import { cpSync, existsSync, mkdtempSync, mkdirSync, renameSync, rmSync } from "node:fs";
|
import { cpSync, existsSync, mkdtempSync, mkdirSync, readFileSync, renameSync, rmSync } from "node:fs";
|
||||||
import { homedir } from "node:os";
|
import { homedir } from "node:os";
|
||||||
import { basename, dirname, join, resolve, sep } from "node:path";
|
import { basename, dirname, join, resolve, sep } from "node:path";
|
||||||
import { spawn } from "node:child_process";
|
import { spawn } from "node:child_process";
|
||||||
@@ -12,6 +12,7 @@ const SKILL_NAME = "open-kimi-ppt";
|
|||||||
const MIN_NODE_MAJOR = 18;
|
const MIN_NODE_MAJOR = 18;
|
||||||
const packageRoot = resolve(dirname(fileURLToPath(import.meta.url)), "..");
|
const packageRoot = resolve(dirname(fileURLToPath(import.meta.url)), "..");
|
||||||
const sourceDirectory = join(packageRoot, "skills", SKILL_NAME);
|
const sourceDirectory = join(packageRoot, "skills", SKILL_NAME);
|
||||||
|
const packageVersion = JSON.parse(readFileSync(join(packageRoot, "package.json"), "utf8")).version;
|
||||||
|
|
||||||
const KNOWN_TARGETS = [
|
const KNOWN_TARGETS = [
|
||||||
{ id: "agents", label: "Shared / default", relative: [".agents", "skills"] },
|
{ id: "agents", label: "Shared / default", relative: [".agents", "skills"] },
|
||||||
@@ -35,12 +36,13 @@ function printHelp(command) {
|
|||||||
console.log(`Start the local PPTD editor and exporter.
|
console.log(`Start the local PPTD editor and exporter.
|
||||||
|
|
||||||
Usage:
|
Usage:
|
||||||
open-kimi-ppt-skills serve [options]
|
open-kimi-ppt-skill serve [options]
|
||||||
|
|
||||||
Options:
|
Options:
|
||||||
--port <number> HTTP port (default: 55173)
|
--port <number> HTTP port (default: 55173)
|
||||||
--open Open the editor in the default browser
|
--open Open the editor in the default browser
|
||||||
-h, --help Show this help
|
-h, --help Show this help
|
||||||
|
-V, --version Show version
|
||||||
`);
|
`);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@@ -48,8 +50,8 @@ Options:
|
|||||||
console.log(`Install ${SKILL_NAME} for your AI coding agent or start its local editor.
|
console.log(`Install ${SKILL_NAME} for your AI coding agent or start its local editor.
|
||||||
|
|
||||||
Usage:
|
Usage:
|
||||||
open-kimi-ppt-skills [install] [options]
|
open-kimi-ppt-skill [install] [options]
|
||||||
open-kimi-ppt-skills serve [options]
|
open-kimi-ppt-skill serve [options]
|
||||||
|
|
||||||
Install options:
|
Install options:
|
||||||
--target <directory> Skills directory (repeatable)
|
--target <directory> Skills directory (repeatable)
|
||||||
@@ -57,18 +59,23 @@ Install options:
|
|||||||
--all Install to all detected agent skill directories
|
--all Install to all detected agent skill directories
|
||||||
(agents whose home directory is missing are skipped)
|
(agents whose home directory is missing are skipped)
|
||||||
-h, --help Show this help
|
-h, --help Show this help
|
||||||
|
-V, --version Show version
|
||||||
|
|
||||||
In an interactive terminal (no --target / --yes / --all), a checklist is shown:
|
In an interactive terminal (no --target / --yes / --all), a checklist is shown:
|
||||||
↑/↓ move space select a all enter confirm
|
↑/↓ move space select a all enter confirm
|
||||||
|
|
||||||
For agents / CI, prefer:
|
For agents / CI, prefer:
|
||||||
npx open-kimi-ppt-skills@latest install -y
|
npx open-kimi-ppt-skill@latest install -y
|
||||||
|
|
||||||
Re-running install replaces an existing open-kimi-ppt installation.
|
Re-running install replaces an existing open-kimi-ppt installation.
|
||||||
Run "open-kimi-ppt-skills serve --help" for server options.
|
Run "open-kimi-ppt-skill serve --help" for server options.
|
||||||
`);
|
`);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function printVersion() {
|
||||||
|
console.log(packageVersion);
|
||||||
|
}
|
||||||
|
|
||||||
function parseArguments(arguments_) {
|
function parseArguments(arguments_) {
|
||||||
const args = [...arguments_];
|
const args = [...arguments_];
|
||||||
const command = args[0] === "install" || args[0] === "serve" ? args.shift() : "install";
|
const command = args[0] === "install" || args[0] === "serve" ? args.shift() : "install";
|
||||||
@@ -122,6 +129,11 @@ function parseArguments(arguments_) {
|
|||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (argument === "--version" || argument === "-V") {
|
||||||
|
options.version = true;
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
throw new Error(`unknown argument: ${argument}`);
|
throw new Error(`unknown argument: ${argument}`);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -340,6 +352,10 @@ async function installSkill(options) {
|
|||||||
async function main() {
|
async function main() {
|
||||||
assertNodeVersion();
|
assertNodeVersion();
|
||||||
const options = parseArguments(process.argv.slice(2));
|
const options = parseArguments(process.argv.slice(2));
|
||||||
|
if (options.version) {
|
||||||
|
printVersion();
|
||||||
|
return;
|
||||||
|
}
|
||||||
if (options.help) {
|
if (options.help) {
|
||||||
printHelp(options.command);
|
printHelp(options.command);
|
||||||
return;
|
return;
|
||||||
+3
-3
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "open-kimi-ppt-skills",
|
"name": "open-kimi-ppt-skill",
|
||||||
"version": "1.1.3",
|
"version": "1.2.0",
|
||||||
"description": "Unofficial reverse-engineered Kimi Slides skill for AI coding agents with local PPTD editing and PPTX export.",
|
"description": "Unofficial reverse-engineered Kimi Slides skill for AI coding agents with local PPTD editing and PPTX export.",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"author": "binaryify",
|
"author": "binaryify",
|
||||||
@@ -27,7 +27,7 @@
|
|||||||
],
|
],
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"bin": {
|
"bin": {
|
||||||
"open-kimi-ppt-skills": "bin/open-kimi-ppt-skills.js"
|
"open-kimi-ppt-skill": "bin/open-kimi-ppt-skill.js"
|
||||||
},
|
},
|
||||||
"files": [
|
"files": [
|
||||||
"bin/",
|
"bin/",
|
||||||
|
|||||||
@@ -19,7 +19,7 @@ The .pptd format is a simplified abstraction layer over OOXML that follows basic
|
|||||||
## PPT production workflow
|
## PPT production workflow
|
||||||
|
|
||||||
### step0. Check local prerequisites
|
### step0. Check local prerequisites
|
||||||
Default delivery includes PPTX export (and optional `npx open-kimi-ppt-skills serve`), which need a local toolchain. **Before generating**, verify:
|
Default delivery includes PPTX export (and optional `npx open-kimi-ppt-skill serve`), which need a local toolchain. **Before generating**, verify:
|
||||||
|
|
||||||
1. **Node.js 18+**: run `node --version`. If `node` is missing or the major version is below 18, **stop immediately**, tell the user to install Node.js 18+ from https://nodejs.org (or their OS package manager), and do not continue with PPTX export / `npx` until it is available. Only continue with PPTD-only output when the user explicitly opts out of PPTX.
|
1. **Node.js 18+**: run `node --version`. If `node` is missing or the major version is below 18, **stop immediately**, tell the user to install Node.js 18+ from https://nodejs.org (or their OS package manager), and do not continue with PPTX export / `npx` until it is available. Only continue with PPTD-only output when the user explicitly opts out of PPTX.
|
||||||
2. **npm / npx**: run `npm --version`. They ship with Node.js; if missing, treat Node.js as not installed correctly and guide the user to reinstall/fix PATH.
|
2. **npm / npx**: run `npm --version`. They ship with Node.js; if missing, treat Node.js as not installed correctly and guide the user to reinstall/fix PATH.
|
||||||
@@ -189,8 +189,8 @@ When generating a PPT, adopt different production approaches for different user
|
|||||||
- local PNG/JPEG/GIF/SVG files inside the PPTD project are supplied to the iframe as data URLs;
|
- local PNG/JPEG/GIF/SVG files inside the PPTD project are supplied to the iframe as data URLs;
|
||||||
- do not claim PowerPoint/WPS/Keynote playback compatibility solely because ZIP validation succeeds.
|
- do not claim PowerPoint/WPS/Keynote playback compatibility solely because ZIP validation succeeds.
|
||||||
8. After export, verify that the output exists and report the generated path. Confirm that every slide has exactly one root-level fade transition in valid CT_Slide order (`cSld`, optional `clrMapOvr`, `transition`, optional `timing/extLst`) and that the PPTX ZIP passes integrity checks. A byte-string search for `<p:fade>` is insufficient because Office ignores transitions nested inside `cSld`. For higher-risk decks, additionally inspect font parts and representative rendered/opened pages as appropriate.
|
8. After export, verify that the output exists and report the generated path. Confirm that every slide has exactly one root-level fade transition in valid CT_Slide order (`cSld`, optional `clrMapOvr`, `transition`, optional `timing/extLst`) and that the PPTX ZIP passes integrity checks. A byte-string search for `<p:fade>` is insufficient because Office ignores transitions nested inside `cSld`. For higher-risk decks, additionally inspect font parts and representative rendered/opened pages as appropriate.
|
||||||
9. When the user wants to open, edit, save, or export a PPTD project manually, start the local browser editor with `npx open-kimi-ppt-skills serve`. Ask the user to open `http://127.0.0.1:55173/` and authorize the complete PPTD project directory. Use a Chromium-based browser for writable access; folder-upload fallback is read-only. The local host only serves the editor shell, while the embedded public Kimi editor and remote assets still require network access.
|
9. When the user wants to open, edit, save, or export a PPTD project manually, start the local browser editor with `npx open-kimi-ppt-skill serve`. Ask the user to open `http://127.0.0.1:55173/` and authorize the complete PPTD project directory. Use a Chromium-based browser for writable access; folder-upload fallback is read-only. The local host only serves the editor shell, while the embedded public Kimi editor and remote assets still require network access.
|
||||||
10. After completing and delivering any presentation, always end the final response with a concise optional next step telling the user that they can run `npx open-kimi-ppt-skills serve` to view or edit the PPTD project, configure slide transition animations, and export PPTX manually. Keep this reminder in addition to, not instead of, the required project and file links.
|
10. After completing and delivering any presentation, always end the final response with a concise optional next step telling the user that they can run `npx open-kimi-ppt-skill serve` to view or edit the PPTD project, configure slide transition animations, and export PPTX manually. Keep this reminder in addition to, not instead of, the required project and file links.
|
||||||
11. Element animations (`page.animations` in PPTD — entrance / emphasis / exit / motion-path; see `reference/pptd.md` §6): use them only when the user explicitly requests animations, or when the deck is clearly intended for live presentation / slideshow playback and animation provides a clear benefit for staged disclosure, process demonstration, causal explanation, pacing, visual impact, or brand storytelling. By default, do not add element animations to reading-oriented, self-study, print, or primarily send-and-browse decks. Prefer 1–3 animation groups per page and simple effects such as fade, fly, and zoom. This is separate from the default PPTX slide-level fade page transition written by `export_pptx.py`.
|
11. Element animations (`page.animations` in PPTD — entrance / emphasis / exit / motion-path; see `reference/pptd.md` §6): use them only when the user explicitly requests animations, or when the deck is clearly intended for live presentation / slideshow playback and animation provides a clear benefit for staged disclosure, process demonstration, causal explanation, pacing, visual impact, or brand storytelling. By default, do not add element animations to reading-oriented, self-study, print, or primarily send-and-browse decks. Prefer 1–3 animation groups per page and simple effects such as fade, fly, and zoom. This is separate from the default PPTX slide-level fade page transition written by `export_pptx.py`.
|
||||||
12. Speaker notes (`notes` on each `.page`): use them only when the user explicitly requests them; otherwise, do not add them.
|
12. Speaker notes (`notes` on each `.page`): use them only when the user explicitly requests them; otherwise, do not add them.
|
||||||
13. Parallel tool calls: during PPT production, make tool calls in parallel whenever possible; in each round, write multiple page files in parallel to reduce the number of steps.
|
13. Parallel tool calls: during PPT production, make tool calls in parallel whenever possible; in each round, write multiple page files in parallel to reduce the number of steps.
|
||||||
|
|||||||
@@ -7,7 +7,7 @@ import test from "node:test";
|
|||||||
import { fileURLToPath } from "node:url";
|
import { fileURLToPath } from "node:url";
|
||||||
|
|
||||||
const projectRoot = resolve(dirname(fileURLToPath(import.meta.url)), "..");
|
const projectRoot = resolve(dirname(fileURLToPath(import.meta.url)), "..");
|
||||||
const cli = join(projectRoot, "bin", "open-kimi-ppt-skills.js");
|
const cli = join(projectRoot, "bin", "open-kimi-ppt-skill.js");
|
||||||
|
|
||||||
function runCli(args, env = process.env) {
|
function runCli(args, env = process.env) {
|
||||||
return spawnSync(process.execPath, [cli, ...args], {
|
return spawnSync(process.execPath, [cli, ...args], {
|
||||||
@@ -164,5 +164,22 @@ test("help documents interactive install and -y for agents", () => {
|
|||||||
assert.match(result.stdout, /space select/);
|
assert.match(result.stdout, /space select/);
|
||||||
assert.match(result.stdout, /-y, --yes/);
|
assert.match(result.stdout, /-y, --yes/);
|
||||||
assert.match(result.stdout, /--all/);
|
assert.match(result.stdout, /--all/);
|
||||||
assert.match(result.stdout, /npx open-kimi-ppt-skills@latest install -y/);
|
assert.match(result.stdout, /npx open-kimi-ppt-skill@latest install -y/);
|
||||||
|
});
|
||||||
|
|
||||||
|
test("-h shows help", () => {
|
||||||
|
const result = runCli(["-h"]);
|
||||||
|
assert.equal(result.status, 0, result.stderr);
|
||||||
|
assert.match(result.stdout, /Usage:/);
|
||||||
|
assert.match(result.stdout, /-h, --help/);
|
||||||
|
assert.match(result.stdout, /-V, --version/);
|
||||||
|
});
|
||||||
|
|
||||||
|
test("--version and -V print the package version", () => {
|
||||||
|
const { version } = JSON.parse(readFileSync(join(projectRoot, "package.json"), "utf8"));
|
||||||
|
for (const args of [["--version"], ["-V"], ["serve", "--version"]]) {
|
||||||
|
const result = runCli(args);
|
||||||
|
assert.equal(result.status, 0, `${args.join(" ")}: ${result.stderr}`);
|
||||||
|
assert.equal(result.stdout.trim(), version);
|
||||||
|
}
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in New Issue
Block a user