piggy00544/dsh-upgrade-kit--plugins-dsh-plugin-file-preview ↗★ 1

dsh-plugin-file-preview

Out-of-tree dsh client UI plugin: Codex-style produced-file preview cards under each assistant turn + a right-side preview panel (shell.overlay), plus a per-session drop-to-upload drawer. 核心用途是为 DSH 带来直观的文件管理与预览体验。适合经常需要让 AI 生成图片、PDF、代码文件,并希望直接在聊天界面内查看、下载或上传附件的用户。

Package
dsh-plugin-file-preview
Compatibility
Unverified
Version
0.2.0
License
MIT
Last updated
Aug 21, 2026

Install

This plugin has no verified bundle, or compatibility checks failed. Read the repository notes first. Read the full README ↗

dsh-plugin-file-preview — 会话文件预览插件

给 DeepSeek Harness 的 Web UI 加上「文件在哪、长什么样」的直观体验:产物卡片 + 附件面板 + 拖拽上传,纯 UI 插件,不动会话数据。

功能

能力说明
产物预览卡片每个 assistant 回合尾部自动挂出本轮产生的文件(图片 / PDF / 文本 / 大文件),点卡片直接看内容,不用再去翻工作区目录
附件预览面板会话头部出现「附件」按钮 → 右侧滑出面板:本会话附件列表 + 按类型预览(图片、文本、PDF、二进制信息)
拖拽上传抽屉把文件拖进聊天窗口即可上传到当前会话(按 session 隔离)
智能预览按扩展名路由预览模式:图片直显、PDF 内嵌、文本高亮、超限文件显示大小/哈希元信息

安装(DSH web profile)

cd /path/to/dsh-upgrade-kit
dsh plugin --profile web add link:$PWD/plugins/dsh-plugin-file-preview

然后在 $DSH_HOME/profiles/web/cordis.patch.yml 末尾追加:

- insert:
    - id: file-preview
      name: 'dsh-plugin-file-preview'

重启 web:launchctl kickstart -k gui/$(id -u)/com.deepseek.dsh-web

更省事:用整合包根目录的 install.sh 一键装全部四个工具,本步骤自动完成。

结构

  • lib/index.js — host 半边(空壳注册,纯 UI 插件)
  • lib/client.js — 浏览器半边(已构建产物,开箱即用)
  • src/client.tsx — 源码;node build.mjs 重新构建(需要 esbuild,脚本自动经 npx 拉取)

许可

MIT License