Introduction

When running agents with DSH, the model often produces multiple files in a single turn of conversation via write/edit-like tools: Markdown reports, scripts, CSV data, HTML pages. The default DSH web interface offers limited help with this—the file view only supports HTML, and viewing other formats requires leaving the session to look for paths in the file system and open them with other apps. DSH’s philosophy is “everything is a plugin,” and this gap in the interface is left for client plugins to fill. The dsh-artifact-preview introduced below does exactly that: making files written by the agent directly visible, clickable, and previewable within the chat.

What is this

dsh-artifact-preview is a DSH client plugin maintained by nirvanaslash (where dsh.client.platform is "web"). Its one-sentence positioning is: A Codex-style DeepSeek Harness (DSH) artifact preview plugin—artifact rows within the chat + a resizable split-pane sidebar preview.

It solves the problem of not having to leave the session to view artifacts. The closing message of the chat directly presents an “artifact” row; clicking any file renders a preview in the right-side split pane. The license is MIT, and the current version is 0.1.2.

Core Features

Artifact Row within the Chat

After the agent writes files, the closing message displays an “artifact” row containing file chips and inline image thumbnails; clicking any item opens the sidebar preview. This row is tracked based on files produced by the model in the current turn via write/edit-like tools.

Split Pane Sidebar Preview Panel

The preview panel is located on the right side of the window. It is a true split pane with adjustable width, keeping the conversation content visible and unobscured. Files of different types are rendered accordingly:

  • Markdown: Rich text, supporting headings, tables, lists, code blocks, links, and images; local images with relative paths are automatically resolved.
  • Source code (.py .js .ts .sh .css, etc.): Dark syntax highlighting.
  • CSV: HTML table.
  • JSON: Collapsible tree.
  • Images (.png .jpg .gif .webp .svg, etc.): Centered view with a checkerboard background.
  • HTML / localhost ports: Iframe rendering; the dev server provides port chips, along with a URL bar, forward/backward/refresh buttons, and open externally.

Global Hooks for Other Plugins

The plugin exposes two global hooks on window: window.__dshOpenFilePreview and __dshCanPreviewPath. Other plugins can route “open file” intents to this preview panel without having to implement rendering logic themselves.

Installation and Activation

The installation command is as follows. This package declares dsh.bundle and dsh.client, so dsh plugin add will install dependencies and automatically register the preview as an active client-plugin layer, requiring no manual profile editing:

dsh plugin --profile web add github:nirvanaslash/dsh-artifact-preview

After installation, you need to restart the dsh web service (or DSH Desktop) and refresh the page.

After the npm release is complete, you can also install it using the command below; the Marketplace search path applies as well (as of the time of writing, the npm release is not yet complete; the original README text says “Once the package is published to npm”):

dsh plugin --profile web add dsh-artifact-preview

There are two prerequisites:

  1. DSH Desktop, or a dsh web profile installed with the dsh-file-changes companion plugin. The preview retrieves file content via the /dsh-files/static/<absolute-path> route; this route is built-in in DSH Desktop; a bare dsh web installation requires installing the dsh-file-changes companion plugin first.

  2. The model needs to produce files via write/edit-like tools; the plugin’s “artifact” row is tracked exactly this way.

Compatibility and Known Limitations

The plugin is built for the DSH 0.1.0-rc.7 (built-in in DSH Desktop 2.0.1) client plugin ABI: window.__ModuleLoader__ module format, dsh.client metadata, dsh.bundle patch registration, and the conversation.chat.turnTail chain slot. Chain slot election relies on a low priority (-100) to make the artifact row win over the official deliverables row; this behavior needs to be re-verified after DSH upgrades. Regarding dependencies, the package declares react ^18.2.0 in peerDependencies.

There are two optional behaviors that were deliberately not packaged because they require patching DSH core files:

  • Multi-type preview buttons in the file view;
  • “Open -> Preview” for filenames mentioned in the message body.

By default, the file view maintains DSH’s original HTML-only behavior, and files mentioned in the body are opened with the system app. The artifact row and preview panel within the chat are entirely self-contained by this package and do not rely on core patches.

Use Cases and Notes

The target audience is clear: developers running agents on DSH Desktop or dsh web profiles, frequently having models produce files, and wanting to view results in place within the session. If you are writing other client plugins, you can also directly reuse window.__dshOpenFilePreview / __dshCanPreviewPath to hook your “open file” actions into this preview system.

There are a few things to note before installation:

  1. The plugin runs with the permissions of the current DSH process; installing a third-party plugin is equivalent to putting code into your work environment. It is recommended to check the source code before installing.

  2. The license is MIT, and the source code is hosted on GitHub, allowing for direct review.

  3. The plugin is bound to the DSH 0.1.0-rc.7 ABI and chain slot behavior; after upgrading DSH, keep an eye on whether the artifact row still appears normally.

Conclusion

dsh-artifact-preview fills a specific small gap in daily DSH usage: from “the model has finished writing a file” to “seeing the content.” With the plugin installed, the service restarted, and the page refreshed, the artifact row and sidebar preview take over this path.

The plugin page is in the community directory: https://www.skillhub.cn/plugins/nirvanaslash/dsh-artifact-preview
Source code is on GitHub: https://github.com/nirvanaslash/dsh-artifact-preview

It should be noted that this directory is an independent community site with no official affiliation with DeepSeek / High-Flyer.