Neplich/dsh_plugin--packages-agent-dsh-agent-imagevault ↗★ 1
@neplich/dsh-agent-imagevault
归档工具结果中的图片为普通文件,并通过本地地址在聊天流中展示。 适合需要长期保存并展示工具生成图片的用户;归档目录可手动清理,附件对象不受影响。
安装
npx -p @deepseek-ai/dsh dsh plugin --profile web add github:Neplich/dsh_plugin#c83599509c2f790ba23c59b19d90e521fa774c1d&path:packages/agent/dsh-agent-imagevault说明文档
阅读完整 README ↗@neplich/dsh-agent-imagevault
Image archiving and chat-stream display for tool results. Two independent jobs:
- Archive — every image block in any tool result (screenshots,
read_image, uploads, …) is copied out of the durable attachment store into a plain-file export directory. Source-agnostic: it works with any tool that produces images. - Display — a loopback HTTP server answers
GET /sha256:.straight from the content-addressed attachment store, giving every session image a stable URL that lives exactly as long as the session history. The Web GUI's markdown renderer accepts http(s) image URLs, so the agent can embed them () to show images in the chat stream.
Also registers one tool: imagevault_dir, which reports the display URL pattern and the export directory.
Why not just files?
Chat images (uploads and tool screenshots alike) already live durably in the content-addressed attachment store at $DSH_HOME/attachments/v1/objects/ — that store's lifetime matches the session history. Serving display URLs directly from it means zero duplication and links that never expire with temp-cleanups. The exported plain files are a convenience for opening images locally; they live in a temp directory the OS may clean, which never breaks chat display.
Install
dsh plugin --profile add @neplich/dsh-agent-imagevault
Config (cordis.yml)
| Key | Default | Meaning |
|---|---|---|
port | 9335 | Loopback port for the display HTTP server |
exportDir | /dsh-image-vault | Directory receiving archived image files |
storeDir | $DSH_HOME/attachments/v1/objects | Attachment object root of the local backend |
Uninstall
dsh plugin --profile remove @neplich/dsh-agent-imagevault
Removing the plugin stops the display server and the archive listener. Artifacts:
| Artifact | Default location | Cleanup |
|---|---|---|
| Exported image files | /dsh-image-vault/ | Left to OS temp cleanup, or delete manually |
| Attachment objects | $DSH_HOME/attachments/ | Not touched — shared session data owned by the attachment service, not by this plugin |
Known limitations
- The display route reads the local attachment backend's file layout (
objects//); with a non-local backend mounted it answers 404 (archiving still works through the publicreadImagecontract). - Archived files are a copy — deleting them never affects the session's own images.