dsh-plugin-verified-search
f0909172434
Verified current-source search workflow for DeepSeek Harness
PROJECT TOPICS
PROJECT README
简体中文 | English
npm package: dsh-attachments · GitHub repository:
CocoSgt/dsh-attachments
A third-party attachment plugin for DeepSeek Harness (dsh): bring any file into the conversation, zero type rejection.
<cwd>/.dsh/uploads/ and staged per session, and a card (icon tile + file name + size + ✕) appears above the composer. Nothing uses the host's native draft-image pipeline (createDraftImages/addImages are not used); if the model needs to see an image, it reads it by path with the harness-native read_image tool, so non-vision models are never blocked by "this model doesn't support images".agent/pre-step wave as a message with source: { kind: 'user' } (inserted right before your message, same injection pattern as the official dsh-agent-instructions), so it lands in the logs and replays safely. After injection the cards disappear automatically.accept filter.📎 … → .dsh/uploads/…, e.g. copied from a previous message) re-materializes them as cards.Stashed files render as cards above the composer (conversation.input.dock): extension icon tile + file name + size + ✕. The ✕ removes the file from the session stash and deletes it from disk. Image cards carry a local thumbnail preview. Cards are backed by the host-side pending list as the source of truth (listStash) and refresh via 2-second polling (they vanish once the stash is consumed by a send). Clicking a card opens a preview overlay: images render directly, text/code render as plain text, everything else offers "open with system app", and the header carries a "copy reference" action whose text is the attachment's wire format — paste it back into the composer to re-attach.
lib/index.js): AttachmentsGateway extends TypertRemoteService and serves the fileStash namespace with six RPCs: stashFile, removeStash, restageFile, clearStash, readStash, listStash. Path safety: writes only under <cwd>/.dsh/uploads/, file names are sanitized and prefixed with a timestamp, and removal/preview paths are resolved and prefix-checked. Because third-party dual-copy setups are blind to SRC discovery, the plugin also registers a weak (src-json) manifest into the host typert registry.lib/client.js): hand-written strict zod descriptors mounted via $mount, exposing ctx.remote.fileStash; the button registers conversation.input.left, the card bar registers conversation.input.dock; full-window drag/paste routes through the "current composer" context captured by the store. The host folds pending attachments into the next agent/pre-step decision.dsh-attachments). Slot components receive the standard reactive t seat; window-level modules (dropzone overlay, preview, history cards, intake toasts) translate at call time via a namespace-bound t. Host-side RPC failures carry a stable dot-code plus {name} params (e.g. stash.err.tooLarge with {max}) alongside a Chinese fallback message — the client renders the localized text when its dictionary has the code, otherwise the fallback. The 📎 … → path reference-line format injected into the model's history is protocol text and is never localized.Install from npm:
dsh plugin --profile web add dsh-attachments
All three dsh plugins can be added in one command:
dsh plugin --profile web add dsh-skills dsh-attachments dsh-inspector
GitHub fallback:
dsh plugin --profile web add github:CocoSgt/dsh-attachments
Note: a self-built profile's
~/.dsh/profiles/<name>/package.jsonmust list@deepseek-ai/dsh-baseand@deepseek-ai/dsh-web-appindsh.profile.bundles, otherwise startup hangs silently.
Restart dsh web afterwards. Uninstall:
dsh plugin --profile web remove dsh-attachments.
The other two plugins from the same suite:
.skill
packages into one global library, invocable from the "/" menu..dsh/uploads/ is not garbage-collected automatically; the card ✕ deletes the corresponding file, and files referenced by already-sent messages should be kept (history still points at them).pnpm install
pnpm run check # tsc --noEmit
pnpm run build # tsdown (host + browser bundle)
Note: host method parameter names ARE the RPC wire field names (Gateway SRC mode) — the build must never mangle parameter names.
This package and its repository carry the dsh-plugin, dsh, deepseek-harness
and related keywords/topics. DeepSeek Harness ships no official plugin
marketplace and no official discovery tag — once a third-party plugin is
published, nothing links it back to the ecosystem and users have no way to
find it. These community tags are the only practical discovery channel
(npm: keywords:dsh-plugin; GitHub: topic:dsh-plugin). Unofficial, but
essential — that is why they are here.
MIT
CLASSIFICATION EVIDENCE
系统优先读取 GitHub Topics,再与站内分类词典和词根规则比对。