gjunyoung/dsh-library: Mount a local file repository for DSH

Introduction

When running agents with DSH, you encounter a specific pain point: documents delivered by the agent and generated images are usually scattered in the workspace. Later, they are either hard to find or require manual moving. Attachments in a session are session-scoped; closing the session removes the entry point. To achieve the sequence of actions—upload, browse, preview, favorite, and attach back to chat—users often rely on manually creating directories and transferring files, which creates a fragmented workflow.

The plugin introduced below adds a global file repository to Harness, consolidating these actions into the panel: uploads and management are completed in the repository panel at the bottom of the sidebar; the chat side can also send files from the library as attachments.

What is it

gjunyoung/dsh-library is a local file repository plugin for DeepSeek Harness, maintained by gjunyoung, and categorized as “Memory” in the community directory. In one sentence, its positioning is: without modifying Harness itself, it adds a file repository with upload, browse, preview, favorite, and batch export capabilities to the current profile, integrated with chat.

It is a pure plugin implementation: the client side only allows require('react'), and all interactions with Harness are completed through slot registration and loopback HTTP, so there is no need to modify Harness source code. The directory page shows 0 stars, making it a newly emerged project.

Core Features

The following introduces the capabilities listed in the README without expansion.

  • Upload: Supports button upload and drag-and-drop, single file limit 200 MB, automatically appends sequence numbers to files with the same name.
  • Browse: Grid/List views, sorting by time/name/size, supports search, categories include All / Files / Images / Videos / Audio / Favorites.
  • Preview: Text, Markdown, Code, HTML (Sandbox rendering + Source code switching), Images (Inline preview + Full-screen lightbox, supports scroll zoom, drag, rotate, download, delete), PDF. Office files are processed via PDF.
  • Favorite: Can favorite/unfavorite, grouped by folders, default is “Uncategorized”.
  • Batch: Checkbox, Shift range, Select All, ZIP download, Move to folder, Send to current chat, Delete.
  • Chat Integration: The “+” on the left side of the input box allows selecting files from the repository to add to draft attachments; files delivered by the agent via present are automatically stored and the source session is recorded.
  • Storage Management: The settings page allows viewing location and usage, migrating to a new directory, and rebuilding the index.

Installation and Activation

The prerequisite is that DeepSeek Harness is installed locally and a usable profile is available. The installation method given in the official README is to first get the repository to the local machine, then mount it from the plugin entry point; it is not a one-command plugin installation:

  1. Clone or download the repository to any location; the path can contain spaces:
git clone https://github.com/gjunyoung/dsh-library.git
  1. Open Harness → Settings → Plugins → Install Plugin Package, enter the absolute path of that directory, or the path of the .tgz generated by npm pack.

  2. Enable “Repository” in the plugin list.

  3. Restart Harness.

The first startup will create the storage directory at ~/.dsh/library (Windows: C:\Users\<you>\.dsh\library). The README notes that the installation entry point name may vary slightly across versions (“Install”, “Add Plugin”, etc.), but essentially, it mounts that directory as a local dependency for the current profile.

Typical Usage

First, open the panel: click the repository icon at the bottom of the sidebar. The upload area supports drag-and-drop; the “…” menu on the right side of the list provides preview, download, favorite, move to folder, and delete options.

The behavior of the preview drawer varies by file type: Images and PDFs can be zoomed in; HTML is rendered by default and allows switching to source code; Office files are converted once when first opened, then cached. For example, opening a .docx will initially be converted to PDF for display via Harness’s built-in conversion capability.

The entry point for favorites is in the “…”; clicking “Favorite” opens a folder picker, and favorited files show “Unfavorite”. The root level of favorites is a folder list (Uncategorized + individual folders); once inside a folder, the search box becomes active.

Batch operations are on the floating bar at the bottom of the panel: Select All / Deselect All, Download (ZIP), Move to folder, Send to chat, Delete. “Send to chat” corresponds to the chat integration feature, sending selected files as attachments to the current session.

Storage and Maintenance

The structure of the storage directory is as follows:

~/.dsh/library/
├─ index.json          Records (filename, size, hash, source, favorite, folder)
├─ index.backup.json   Previous index backup
├─ blobs/<2>/<sha>.bin Content-addressed file bodies (same content stored once)
├─ orphan/             Bytes without index records (not automatically deleted)
├─ tmp/                Temporary files, Office conversion cache
└─ thumbs/             Reserved thumbnail directory

Backup is copying the entire directory; restore places it back in the same location. Migration goes via Settings → Repository → Enter new directory absolute path → Migrate, which moves files, verifies, and deletes library data in the old directory, then remembers the new location (still effective after restart). Rebuilding the index overwrites index.json with bytes from the disk, suitable for cases where the index is corrupted or the directory has been manually moved; files not in the index appear as recovered-<first 8 chars of hash>, and original names and favorite information cannot be recovered.

Suitable Scenarios and Notes

Suitable for this type of usage: having DSH and a usable profile, wanting to centrally manage agent deliverables and common files, and needing to repeatedly reference library files in chat. For those unwilling to modify Harness itself, this plugin takes the pure plugin path.

A few points to know beforehand. Office only goes via PDF: docx/xlsx/pptx are converted to PDF for display by Harness’s built-in conversion capability, and original tables are not parsed; Excel formulas and charts are not rendered separately. HTML is single-file preview: rendered via srcdoc in a sandbox iframe; scripts can run, but cannot read app data or access the internet; relative references like ./style.css are unavailable. Preview is an in-page drawer: Document preview in Harness’s right sidebar is session-scoped, while the repository is a global panel, so the preview is placed in a drawer inside the panel. Auto-inventory only recognizes delivery: files delivered by the agent using present are automatically stored; files directly written to the workspace via write / edit are not automatically stored, to avoid stuffing in temporary files. Batch favorites are not provided; favorites are done one by one.

Additionally, the plugin runs under the permissions of the current DSH process, and the installation method mounts the local directory as a profile dependency. It is recommended to read the source code before installation to confirm that the storage logic in index.js (host side) and lib/ meets expectations; the license is MIT (© 2026 gjunyoung), allowing free use, modification, and distribution, provided “as is.”

Conclusion

The value of this plugin lies in bringing “file management” into the DSH panel rather than using a separate set of tools: upload, browse, preview, favorite, batch export, and chat attachments are completed in a single interaction, and storage location and index can be maintained independently. It relies on Harness’s built-in Office conversion and sandbox rendering capabilities, has clear capability boundaries, and should be verified against the notes above before use.

  • Directory page: https://www.skillhub.cn/plugins/gjunyoung/dsh-library
  • GitHub: https://github.com/gjunyoung/dsh-library

(The community directory is an independent site and has no official affiliation with DeepSeek / Hui Fang.)

羽毛球分组比赛记分
小程序二维码

欢迎使用《羽毛球分组比赛记分》微信小程序

Xiaoye