DeepSeek Harness 插件

dsh-pdf-background-gray

注册 remove-pdf-background-gray 技能:去除扫描 PDF 的灰色/米白底色,保持分辨率、页面几何与抗锯齿文字边缘(无损 Flate 写回),核心为单文件 Python 脚本(pypdf + Pillow + numpy)。

跳到安装方式

来源信息

GitHub 仓库
zjsthmjialin/pdf-background-gray-codex-skill
最近更新
2026年8月16日
分类
文档与渲染
GitHub stars
1

安装

默认先复制一段 Prompt,让 Agent 读页面和仓库;需要自己装时再切到命令。

复制这段 Prompt,发给 DSH、Codex 或其他 Agent,让它先读页面和仓库。

请先不要安装。阅读这个 DeepSeek Harness 插件,说明它解决什么问题、会访问哪些文件、网络或密钥,以及如何安装和卸载。

插件页面:https://deepseekplugins.org/zh/plugins/zjsthmjialin/pdf-background-gray-codex-skill~23dsh-pdf-background-gray
GitHub:https://github.com/zjsthmjialin/pdf-background-gray-codex-skill/tree/main/dsh-pdf-background-gray
插件名:pdf-background-gray-codex-skill#dsh-pdf-background-gray
作者:zjsthmjialin
安装命令:dsh plugin --profile web add dsh-pdf-background-gray

确认前不要执行安装命令。

检查来源文件

安装前先看这个插件目录里的 README 和其他文件。

文件资源管理器2 个文件
README.md来源说明 · 只读预览

dsh-pdf-background-gray

「Remove PDF Background Gray」技能的 DeepSeek Harness (DSH) 插件化分发包

安装后自动向 DSH 技能系统注册 remove-pdf-background-gray 技能:去除扫描 PDF 的灰色/米白底色,保持原始分辨率、页面几何与抗锯齿文字边缘(不做硬阈值/二值化、不重采样、无损 Flate 压缩)。

安装

dsh plugin --profile web add dsh-pdf-background-gray

重启 DSH Web 后,向 Agent 说"把这份扫描 PDF 去底灰"即自动走技能工作流。

运行时要求(Python)

  • Python 3.10+
  • python -m pip install pypdf Pillow numpy

用法(技能内嵌,直接给 agent 即可)

python scripts/remove_pdf_background_gray.py INPUT.pdf OUTPUT.pdf
# 深色纸张:--low 235 --white-point 250

内容

  • SKILL.md:工作流与护栏(pdfinfo 检查 → 直改图像对象 → 验证)
  • scripts/remove_pdf_background_gray.py:核心脚本(单文件,124 行)

发布 / 维护

npm pack --dry-run
npm publish

维护纪律:技能本体改动 → 同步 skills/remove-pdf-background-gray/ 快照 → 版本迭代重发。 完整迁移流程见 [SKILL-TO-DSH-PLUGIN.md](SKILL-TO-DSH-PLUGIN.md)(同目录模板)。