Introduction¶
DeepSeek Harness is a plugin-centric agent development environment. In long conversations, clicking into the input box with a mouse or scrolling through messages one by one is inefficient. dsh-vim takes over keyboard interaction in the input box and conversation area, allowing users to edit and navigate using Vim’s operating semantics.
Plugin Scope¶
dsh-vim is a client-side plugin for DeepSeek Harness, developed by maintainer wuRDmemory. It does not modify DSH’s server-side behavior; it only takes over input box editing, conversation area browsing, and left/right sidebar navigation. The plugin operates in NORMAL, INSERT, VISUAL, VISUAL-LINE, and SEARCH modes, supporting standard Vim motions, operators, text objects, registers, and repeat commands.
Core Features¶
Modal Editing in the Input Box¶
The plugin implements Vim’s modal editing in the input box. After clicking the input box, it enters NORMAL mode by default. Press i to enter INSERT mode for typing, and press Esc to return to NORMAL. In NORMAL mode, standard Vim motions and editing commands are available.
Common motion keys:
h j k l left / down / up / right
w b e word-wise motion
0 ^ $ line start / first non-blank / line end
gg G first line / last line
Common editing keys:
i a insert before / after cursor
A I insert at end of line / start of line
o O open a new line below / above
u undo
Ctrl-r redo
. repeat last change
The plugin supports four modes — NORMAL, INSERT, VISUAL, and VISUAL-LINE — plus SEARCH mode entered via / or ?.
Conversation Area Navigation¶
Press Ctrl-2 to enter the conversation area. Use j/k to scroll down/up by 160px. Ctrl-d/Ctrl-u performs half-page scrolling, gg (press g twice) jumps to the top, and G jumps to the bottom. h/l switches between the three tabs: “Conversation / Trace / Context.”
In the conversation area, yy (press y twice) copies the message at the center of the viewport. Press / to incrementally search content, and Esc to return to the input box.
The conversation area uses scroll-based semantics: each scroll step is fixed at 160px, and no message selection box is shown. Message lines are detected via page structure heuristics; when switching tabs or right after the page loads, a brief “locating…” indicator may appear.
Four-Pane Switching¶
The plugin divides the interface into four panes, switched via Ctrl-1 through Ctrl-4:
| Shortcut | Pane |
|---|---|
Ctrl-1 |
Left sidebar: sessions, projects, or file tree |
Ctrl-2 |
Conversation area |
Ctrl-3 |
Input box |
Ctrl-4 |
Right sidebar |
On desktop, the native layer may intercept Ctrl+digit. In that case, use Space 1 through Space 4 in NORMAL mode.
In the sidebar or menus:
j / k next / previous entry
l / o open current entry
Enter open current entry; in the left sidebar this also jumps to the input box
g / G first / last entry
r re-detect panes
Esc return to input box
The sidebar treats each entire row as an entry unit. j/k selects and highlights the whole row, and Enter triggers the open action for that row.
Right Sidebar Behavior¶
Ctrl-4 expands the right sidebar if it is collapsed. If already focused on the right sidebar, pressing Ctrl-4 again collapses it and returns to the input box. Right sidebar behavior depends on the active tab:
- Tab bar:
h/lswitches tabs,Enterenters - File tree, start page, task manager:
j/kselects,Enteropens - Documents, Markdown, plain text:
j/kscrolls - Diff:
j/kscrolls,h/lswitches files - Images:
j/kzooms - Terminal, browser:
Enterenters input mode, keypresses are passed to the content; bareEscreturns to the tab bar - Side conversation:
j/kscrolls,Enterfocuses the input box
Press q, :q, or :q! in the right sidebar to close the current tab.
Installation & Activation¶
Prerequisites¶
- DeepSeek Harness
0.2.0-rc.1or a later0.2.xrelease - Node.js 20 or higher
- Local plugin directory:
D:\DSH\dsh-vim
Installing a Local Plugin¶
Run in PowerShell:
dsh plugin --profile <profile> add D:\DSH\dsh-vim
Replace <profile> with the name of the DSH profile you want to use. After installation, reopen DSH or refresh the client page.
The local directory install is a linked installation. After modifying the plugin’s client.js, simply refresh the page to verify changes — no need to reinstall.
Uninstalling¶
dsh plugin --profile <profile> remove dsh-vim
Verifying the Installation¶
- Open a DSH conversation page.
- Click the input box.
- If you see a
NORMALbadge and a block cursor, the plugin has loaded successfully. - Press
i, type some text, then pressEsc; the badge should return toNORMAL. - Press
Ctrl-2; the status bar should confirm you are in the conversation area.
If the badge does not appear, refresh the page first. If it still doesn’t work, confirm that the install command uses the same profile currently running.
Typical Workflows¶
Editing and Sending a Message¶
- Click the input box. Each time you re-enter the input box, it starts in
NORMAL. - Press
ito enterINSERT. - Type normally; Chinese IME, Enter, and Shift+Enter retain their native browser behavior in INSERT mode.
- Press
Escto return toNORMAL. - Use Vim operations for further editing; when ready to send, press
iagain and then Enter.
Browsing the Conversation¶
- Press
Ctrl-2to enter the conversation area. - Use
j/kto scroll through messages. - Use
h/lto switch between Conversation / Trace / Context tabs. - Use
/to search content. - Press
Escto return to the input box.
Using Vim Editing Commands¶
In NORMAL mode:
d+ motion: delete the selected regionc+ motion: change the selected regiony+ motion: yank (copy) the selected regiondd: delete the entire linecc: change the entire lineyy: yank the entire linep/P: paste after / before the cursorr: replace the current characterx/X: delete the current character or the character before the cursor
Use Cases & Caveats¶
dsh-vim is designed for users who are comfortable with Vim’s operating semantics and want fast message browsing, editing, and navigation within DSH.
The plugin uses DOM heuristic detection to identify page structure. Changes to DSH themes or layouts may require updated detection rules. When detection fails, it will not silently scroll the wrong area; instead, it explains the reason in the badge or status bar.
When the plugin detects that DSH has already claimed a bare letter shortcut, it yields and does not intercept that shortcut. Desktop-native shortcuts may be intercepted before the keypress reaches the web page; in such cases the plugin cannot observe them.
Development & Verification¶
The plugin includes unit tests and a build script:
node --test "test/*.test.mjs"
node test/core.test.mjs
node test/shortcuts.test.mjs
node test/adapter-input-direct.mjs
node tools/build.mjs
The build script writes the bundle to stdout. On local machines, use PowerShell to write to disk to avoid terminal security features converting Node’s output into an unloadable file:
$t = (node tools/build.mjs) -join "`n"
[System.IO.File]::WriteAllText("D:\DSH\dsh-vim\client.js", $t, (New-Object System.Text.UTF8Encoding($false)))
Browser fixture verification:
node tools/dev-server.mjs D:\DSH\dsh-vim 5900
# Open http://127.0.0.1:5900/tools/dev-harness.html
See tools/verify.mjs for full CDP scenarios and performance diagnostics; see docs/design.md and docs/requirements.md for source structure and design trade-offs.
Ecosystem Context¶
The DeepSeek Harness philosophy is “everything is a plugin.” The community directory is an independent site with no official affiliation to DeepSeek / 幻方 (High-Flyer). Plugins run with the privileges of the current dsh process; review the source code and license before installing.
Version Info¶
Current version 0.2.1 (2026-11-22, tag v0.2.1). Fixes in this release: selection box in pane 1 now snaps back to the full row; long lists follow scrolling and only wrap around after truly reaching the bottom; the selection box no longer sticks to user controls at the bottom.