Introduction¶
The DeepSeek Harness (DSH) ecosystem emphasizes extending functionality through plugins. When using a plain-text model (such as deepseek-v4-flash), pasted images are converted into text prompts by dsh-tool-vision, causing only the text to be visible in the conversation while the image itself is not displayed. dsh-bridge-preview is intended to address this presentation-layer pain point.
What Is This¶
dsh-bridge-preview is a client-side plugin maintained by xing666173 under the MIT license. It provides in-conversation inline preview functionality for the “image bridge” feature of DeepSeek Harness’s dsh-tool-vision plugin.
This plugin does not modify persisted messages, does not touch the slot system, and does not affect model request content. It operates only at the user interface layer, rendering originally plain-text prompts as visible images.
Core Features¶
-
Bubble Inline Display
User bubbles directly display image thumbnails; clicking a thumbnail allows viewing the full-size image. -
Automatic Scanning Mechanism
The plugin usesMutationObserverto monitor DOM changes and enables immediate preview for new messages; it also includes a 2-second fallback scanning logic to complete previews for older messages. -
Purely Additive Architecture
At the logic layer, it is “purely additive”: it only adds presentation, without modifying underlying data storage, changing conversation slots, or interfering with model inference. -
Silent Degradation
If an image fails to load, the plugin automatically removes the corresponding image tag, without breaking the conversation structure or displaying error messages.
Installation and Activation¶
Run the following command in the terminal to install:
dsh plugin --profile web-desktop add github:xing666173/dsh-bridge-preview
Prerequisites:
Before installing, ensure that dsh-tool-vision is installed and enabled, and that the image bridge feature is enabled in its configuration (the default configuration is bridgeTextOnly: true).
After installation, restart dsh (or perform a hard refresh of the page), and the plugin will take effect.
Typical Usage¶
When a user pastes an image through dsh-tool-vision, the system generates a text prompt similar to the following:
[User sent an image (image.png), exported to: C:\...\dsh-vision-bridge\image_sha256:xxx.png. Inspect it with the inspect_image tool to see its content.]
The plugin automatically injects an <img> tag above the text block and renders the image pointed to by the path after exported to:.
Use Cases and Notes¶
Use Cases:
- Using a plain-text model for multimodal interaction.
- Needing to quickly view image content within the conversation flow without frequently switching to logs for inspection.
Notes:
1. Windows Filename Handling: On Windows, filenames exported by dsh-tool-vision can contain colons (such as image_sha256:xxx.png). This is effectively an NTFS Alternate Data Stream (ADS), and Node.js can read it directly without special handling.
2. Maintaining the Prompt Format: If the upstream dsh-tool-vision changes the prompt text format, the regular expression HINT_RE in client.js must be updated accordingly to maintain compatibility.
3. Server-Side Routing Restrictions: The server registers a same-origin loopback route /plugins/dsh-bridge-preview/image. This route restricts the request Host (local machine only), image extensions, and file size limit (20MB), and performs directory traversal prevention.
Conclusion¶
dsh-bridge-preview is a lightweight plugin focused on the UI layer. Without changing any underlying logic, it significantly improves the visual experience when using a plain-text model.
- Plugin directory: https://www.skillhub.cn/plugins/xing666173/dsh-bridge-preview
- Source repository: https://github.com/xing666173/dsh-bridge-preview