HuanLinOTO/dsh-plugin-aigc-canvas 预览 preview

HuanLinOTO/dsh-plugin-aigc-canvas

provider-agnostic AIGC HTTP 桥 + 无限画布 + ffmpeg 后处理,13 个工具包括画布连边/重新生成/媒体编辑

Project Overview项目介绍

This is a native plugin built exclusively for DeepSeek Harness (DSH) that adds a node-based AIGC canvas to the DSH web interface. It exposes five AIGC generation tools directly to DSH-hosted models, including text-to-image, text-to-video, first-and-last-frame to video, multi-reference to video, and text-to-audio. All generated outputs and prompt text are stored as canvas elements addressable by unique UUIDs, and the plugin automatically connects input elements to output elements after generation completes. To install the plugin, users can run the dsh plugin add @huanlin/dsh-plugin-aigc-canvas command via npm, or clone the repository locally and install it via DSH’s local link command for development.

When a model runs a generation tool, the output is automatically added to the canvas and connected to its input prompts and reference elements. If the better-sidebar plugin is installed, users get a dedicated canvas tab that visualizes all nodes, connections, and media in real time via WebSocket, with automatic reconnection if the connection drops. All canvas state and media files are persisted locally in the current working directory, so users can restore their full canvas session after refreshing the browser or restarting DSH. The plugin also includes a read-only tool to list all canvas elements, making it easy to reference existing outputs in new generation tasks.

The current v0.1 release only includes a stub backend that returns synthetic test media files, so it does not support real AIGC generation out of the box. Developers can add support for a real backend by modifying the backend client code to match the existing API contract. Current known limitations include no native force-directed graph layout, no SVG lines between nodes, and no support for deleting or editing elements directly through the UI. The plugin follows DSH’s official plugin specification, includes pre-built dependencies, and works immediately after npm installation with no additional build steps required for end users.

这是一个专为 DeepSeek Harness (DSH) 开发的原生插件,为 DSH 提供节点连线式的 AIGC 画布能力。它向模型暴露了文生图、文生视频、首尾帧生视频、多参考生视频、音频生成五类工具,所有生成的媒体文件和提示词都作为带UUID寻址的画布元素存储,生成后自动连线。可通过npm一键安装,也支持本地克隆开发安装。

典型工作流是模型调用对应的生成工具,生成结果自动存入画布并完成连线,用户可通过注册到 better-sidebar 的画布标签页查看所有元素和连接关系,也支持列出当前画布的所有元素供后续工具调用引用。画布状态会持久化到本地工作目录,重启 DSH 后可恢复会话,适合需要跟踪多轮 AIGC 生成流程、复用之前生成结果的开发者和创作者。

当前版本仅内置了模拟后端,可返回合成测试文件,暂无真实 AIGC 调用能力,也不支持元素的删除和编辑。插件遵循 DSH 官方插件规范,预构建产物已包含所有依赖,npm 安装后开箱即用,支持配置后端地址、API 密钥、超时时间和媒体大小限制。开发可使用 pnpm 完成依赖安装、类型检查、测试和构建。

Pre-install check安装前体检Compatibility · Security兼容性 · 安全性 1 warning1 项注意
  • No license declared - all rights reserved by default; ask the author before commercial use or redistribution未声明开源许可证 —— 默认「保留所有权利」,商用或再分发前先问作者
  • 18 stars - an early-stage project星标 18,属于早期项目
DSH walks through these 9 checksDSH 会逐条核对这 9 项

Compatibility兼容性

  • DSH, Node, OS and profile requirementsDSH 版本 / Node 版本 / 操作系统 / profile 是否满足要求
  • External dependencies and runtimes (Electron / Python / Docker, ...)外部依赖与运行时(Electron / Python / Docker 等)是否齐备
  • Conflicts with installed plugins: command names, skill / tool names, ports, duplicate MCP registration与已装插件是否冲突:命令名、skill / tool 重名、端口占用、重复 MCP 注册

Security安全性

  • Repo matches the facts registered here; archived or abandoned?仓库是否与页面登记一致,是否归档或长期停更
  • Safety of preinstall / install / postinstall and install.sh / setup.ps1preinstall / install / postinstall 与 install.sh、setup.ps1 是否安全
  • curl|bash, download-then-execute, obfuscation, unrelated domains → stop immediatelycurl|bash、下载即执行、混淆代码、无关域名 → 立刻停止
  • Typosquatting or unmaintained packages among the new dependencies新增依赖里有没有 typosquatting 或无人维护的包
  • Requested permissions vs. what the feature actually needs申请了哪些权限、是否超出功能所需(filesystem / network / shell / clipboard)
  • Any sudo / admin requirement, plus uninstall and rollback是否要求 sudo / 管理员权限,以及卸载与回滚方式

Anything uncertain must be marked unknown with a note on how to confirm it. This site's signal screen is a static snapshot, not a security audit.拿不准的必须标「未知」并说明要我怎么确认。本站的信号筛查是静态快照,不能替代安全审计。

Or use CLI install (for developers)或使用命令行安装(适合开发者)

CLI Install命令行安装

dsh plugin --profile web add @huanlin/dsh-plugin-aigc-canvas

把 HuanLinOTO/dsh-plugin-aigc-canvas 加入你的 DSH 配置(web profile)即可启用。

READMEREADME

dsh-plugin-aigc-canvas card

dsh-aigc-canvas

npm version

DSH 插件:一个节点-连线式的 AIGC 画布。向模型暴露文生图 / 文生视频 / 首尾帧生视频 / 多参考生视频 / 音频生成五类工具,生成的图片 / 视频 / 音频以及提示词都作为画布元素(uuid 寻址)存在,生成完成后自动按多对一(promise + 所有参考元素 → 输出)在画布上连线。

安装

# 从 npm 安装(推荐):
dsh plugin --profile web add @huanlin/dsh-plugin-aigc-canvas

# 从本地 clone 开发安装(开发阶段):
dsh plugin --profile web add link:D:\Projects\deepseek-harness\dsh-aigc-canvas

预构建 lib/ 入库策略(含 @deepseek-ai/* private peer deps,必须预构建),npm 安装开箱即用,无需 allowBuilds。

配置

在 cordis.patch.yml 或 DSH GUI 中配置:

字段 类型 默认值 说明
baseURL string stub://aigc-backend AIGC 后端 API 地址。stub://aigc-backend = 内置 stub 后端(无网络,合成 PNG/MP4/MP3 字节)。其他值会触发 backend-error 等待未来实现
apiKeyEnv credential-ref AIGC_API_KEY API key 的环境变量名 / 凭据引用。stub 后端不读
requestTimeoutMs number 60000 单次后端请求超时(ms)
mediaSizeLimit number 104857600 (100 MiB) 单个媒体文件大小上限(媒体路由校验)

工具

模型可见的六个工具,均在调用代理的会话作用域内执行(模型不需要传 sessionId):

aigc_text_to_image

文生图。把 prompt 也作为 prompt 元素存入画布,生成图片作为 image 元素,自动连线 prompt → image。

参数:prompt(必填)、negative_prompt、width(默认 1024)、height(默认 1024)、seed。

aigc_text_to_video

文生视频。同上,prompt 元素 → video 元素。

参数:prompt(必填)、negative_prompt、width(默认 1280)、height(默认 720)、duration_seconds(默认 5)、seed。

aigc_first_last_frame_to_video

首尾帧 + 文生视频。first_frame_uuid / last_frame_uuid 必须是已存在的 image 元素 uuid(由 aigc_text_to_image 返回)。prompt 元素 + 两个 image 元素都 → video 元素(三条边)。

参数:prompt(必填)、first_frame_uuid(必填)、last_frame_uuid(必填)、width、height、duration_seconds、seed。

aigc_multi_reference_to_video

多参考生视频。reference_uuids 是 image / video / audio 元素的 uuid 数组(至少一个)。prompt 元素 + 所有参考元素都 → video 元素。

参数:prompt(必填)、reference_uuids(必填,非空数组)、width、height、duration_seconds、seed。

aigc_generate_audio

Showing the opening section of the README — the full document lives in the repository以上为 README 开头摘要,完整文档在仓库内 · View the full README on GitHub →在 GitHub 查看完整 README →

← 上一个 Prev dsh-gui-customization 下一个 Next dsh-plugin-subagent-director →