DSH HUB
HomePlugin StorePlugin PacksCommunityRankingsResourcesPublish Guide
Plugin source
Back to catalog

unStone /

unStone/dsh-plugin-web-ppt

Verified

DeepSeek Harness plugin: let your agent read and export .pptx / .ppt — pure JS, no PowerPoint, no conversion, no network.

★ 0 Stars0 Forks0 IssuesN/A Community rating0 Confirmed installs
View on GitHub
READMESource: master@704c9609

dsh-plugin-web-ppt

DeepSeek Harness 插件:让 agent 直接读懂并导出 .pptx / .ppt。

解析与渲染全部走 web-ppt,纯 JS——不装 PowerPoint、不起 LibreOffice、不转格式、不联网。

安装

dsh plugin --profile <你的 profile> add dsh-plugin-web-ppt

装完 dsh --profile <name> --dump-config 里会多出一层 # == dsh-plugin-web-ppt,启动即生效。

工具

工具 干什么 关键参数
ppt_read 逐页返回标题 / 正文 / 演讲者备注,agent 认识一份 PPT 的入口 path、pages、password、include_hidden
ppt_render_svg 每页导出一个自包含 SVG(图片内联为 data URI) path、out_dir、pages
ppt_export_html 整份导出成一份可打印 HTML,浏览器「打印为 PDF」即得 PDF path、out_file、animation_steps

pages 一律是 1 基选择串,形如 1-3,7;不传表示全部。隐藏页默认不参与,与 PowerPoint 放映一致。

文件读写全部经 Harness 的 fs 服务,因此 workspace 归属、沙箱策略与写入审批都照常生效。

配置

在 profile 的 cordis.patch.yml 里按 id 覆盖(注意 patch 会整体替换 config,要把键写全):

- id: web-ppt
  name: dsh-plugin-web-ppt
  config:
    maxFileBytes: 134217728
    maxTextChars: 40000
    includeHidden: false
键 默认 说明
maxFileBytes 67108864(64 MB) 单文件读取上限,超出直接失败
maxTextChars 20000 ppt_read 的文本预算,超出截断并置 truncated
includeHidden false 是否默认把隐藏页算进来

边界

能 不能
.pptx(Zip+OOXML)与 .ppt(CFB+Escher) 导出 PNG——需要 canvas,Node 里没有
加密文件(传 password) 写入 / 编辑 PPT,本插件只读
图表、SmartArt、公式、EMF/WMF 图元 播放动画,只能按终态或按点击批次展开成多页

导出的 SVG 固定走原生 <text> 而不是 foreignObject:后者只有浏览器认,Inkscape / librsvg / 设计工具打开会整块丢失文本。文件是要交出去的,必须自包含。

开发

npm install && npm test

改完代码跑 npm run check && npm test,两条都绿才算完成。

本地挂进 DSH 验证:

dsh plugin --profile dev add /path/to/dsh-plugin-web-ppt

发布

版本号改完打 tag 即可,release.yml 走 npm Trusted Publishing(OIDC),Secrets 里不存凭据:

git tag -a v0.1.0 -m "v0.1.0" && git push origin v0.1.0

⚠️ 第一版走不了 OIDC:npm 要求包已存在才能配置 Trusted Publishing,而包要先发布才会存在。首发先在本地 npm publish 一次,再去 npm 包设置里配好 trusted publisher。

License

MIT

—/ 5

No ratings yet

Verified DSH bundle

Commit 704c96096a20

Community comments

No comments yet. Be the first to write one.

DSH HUB

A community index for DSH plugins. Not an official GitHub or DeepSeek AI product.

CommunityResourcesAPIAbout