dshbase

插件目录 / UI & Skins / dsh-chat-image

dsh-chat-image

已验证 · 实测可装 Niobium-41-nb

✓ 持续维护

查看 GitHub ↗ ← 返回插件目录

0Stars
0Forks
0未关闭 issue
—语言
2026-08-17最近推送
跨平台平台

功能简介

Renders chat Markdown image references as a gallery in the DSH web GUI

✅
我们的评价
可用 — 实测通过,早期项目

Renders chat Markdown image references as a gallery in the DSH web GUI 实测能干净安装、正常启动。早期项目,但功能可用。

「已验证」表示我们的自动化 CI 在干净 profile 里实际执行了 dsh plugin add 并启动成功——仅此而已。功能描述与版本兼容性均为作者声明。这不是安全审计,也不代表对第三方代码的背书。

README

dsh-chat-image

npm version
GitHub

English | 中文

Renders chat Markdown image references (![alt](path title)) as a gallery under each closing assistant message in the DeepSeek Harness web GUI.

gallery preview

  • Local workspace paths load through a validated host route (/dsh-chat-image): the path must resolve inside a registered workspace and be a regular file of at most 32 MiB; the file is served with an extension-derived content type.
  • http(s) references are skipped — the built-in markdown renderer already shows them inline.
  • data: URLs render directly.
  • The optional title renders as the caption below the image and as the hover hint; a local file without a title shows its absolute path as the hover hint.
  • A reference whose image fails to load (missing file, out of workspace, over the byte cap) falls back to its alt text; an empty alt renders nothing for that item.
  • Clicking a local image opens the file through the same host opener the tool rows use.

Install

As a standalone bundle, from a dsh installation:

# from npm
dsh plugin --profile web add dsh-chat-image

# from the git repository
dsh plugin --profile web add github:Niobium-41-nb/dsh-chat-image

# from a tarball
dsh plugin --profile web add ./dsh-chat-image-0.1.0.tgz

A git install fetches sources and runs the package's prepare build; pnpm ≥ 10 requires an explicit build allowance for that script (the add output prints the exact pnpm-workspace.yaml entry to add). The web profile's browser roster (clientModules) picks the browser half up automatically through the dsh.client manifest; the Loader mounts the host half through the bundle patch.

Usage

The model writes ordinary Markdown image references in its reply:

![架构图](docs/architecture.png "架构总览")
![](my image.png)      <!-- paths with spaces need angle brackets -->
![inline](data:image/png;base64,AAAA)

Relative paths resolve against the session working directory; absolute paths (drive-letter, /, or \\) pass through. Assistant closing turns only: the tail hole does not exist under user messages, and a turn with produced files keeps that row (the gallery shows only when it declines).

Develop

pnpm install
pnpm test      # vitest: route status matrix + reference extraction
pnpm build     # tsc types (lib/types) + tsdown bundles (lib/index.js, lib/client.js)

The browser bundle is CJS wrapped for the dsh loader (window.__ModuleLoader__.load) with only the frozen platform-module table external; the node half has no runtime imports. Both halves consume harness services structurally, so the package carries no runtime or type dependency on @deepseek-ai/* beyond the platform modules.

Known Limitations

  • Assistant closing turns only. The turn-tail hole exists only under closing assistant messages.
  • Chain exclusivity with the produced-files row. A turn that has both produced files and image references shows only the produced-files row (higher priority).
  • CommonMark destination rules. A path containing spaces must be written in angle brackets (<my image.png>); an unquoted multi-word destination is parsed as path + title.
  • Workspace containment. Only files inside a registered workspace are served; the route answers 403 for anything else, so it cannot read arbitrary host files.

安装

🧩 让 Agent 自动装(推荐)

装一次目录插件,之后本站所有插件都能让 DeepSeek Harness 自动找、自动装:

dsh plugin add dshbase-catalog

然后对 agent 说「帮我装 dsh-chat-image」,它会在目录里找到并自动安装。文档:dshbase-catalog · 已验证场景包。

该插件是 GitHub 源码(未发 npm)——直接从仓库装:

Web profile:

dsh plugin --profile web add github:Niobium-41-nb/dsh-chat-image

Headless(CLI)profile:

dsh plugin --profile headless add github:Niobium-41-nb/dsh-chat-image

实测报告

验证通过:从 GitHub 源码完成 L1 安装 + L2 加载 + L3 运行(dsh 0.1.0-rc.6)。

安全:尚未扫描——我们的每日静态扫描将很快覆盖它。

分享徽章

UI & Skins 里更多

浏览全部 7819 个插件 →