When debugging or developing agents in DeepSeek Harness (DSH), frequently reusing previous prompts and context is a common requirement. Traditional web interfaces lack a convenient quick-reuse mechanism, usually requiring manual copy-pasting or scrolling through the history log. This article introduces a plugin that simulates history behavior in a CLI environment to solve the problem of quickly recalling input box content.
Plugin Introduction¶
violetscar-hui/dsh-chat-history is a pure client-side plugin maintained by VioletScar-Hui. It adds CLI-style history recall functionality to the DSH chat input box: you can use the up and down arrow keys to recall previously sent content in the input box, and the history is preserved across restarts.
Core Features¶
- Up/Down Key History Recall: In the input box, press
↑to recall earlier messages, and↓to browse forward or restore the draft. - Prefilled on Startup: When a session is opened, the plugin automatically loads previously sent messages in the current session into history, without waiting.
- Automatic Entry and Deduplication: After a new message is sent, it is automatically appended to the history. The system automatically removes consecutive duplicates and limits history to 200 entries.
- Editing Without Interruption: The
↑/↓actions are triggered only when the cursor is at the beginning of a line, so they will not be accidentally triggered while editing text. They are also disabled during IME composition or when the slash command menu is open. - Memory-Only Storage: History is stored only in browser memory and is independent per session. After restarting the host, only unsent drafts are reset; history is reprefilled from the session.
- Message Location: Click the “Locate” button in the session header; a panel appears on the left listing all messages sent in the current session. Clicking any one jumps directly to its position.
Installation and Enablement¶
Run the following command in a terminal to install the plugin:
dsh plugin --profile web add github:VioletScar-Hui/dsh-chat-history
After installation is complete, refresh the browser page for it to take effect; there is no need to restart the host.
Typical Usage¶
- Open any session and click the chat input box.
- Ensure the cursor is at the beginning of the line, then press
↑to recall the previously sent message. Continue pressing↑to browse further back. - Press
↓to browse forward through the history; when you reach the latest entry, press↓again to restore the draft you were editing. - Editing the text content exits browsing mode, after which you can send the message normally.
- Message Location: Click the “Locate” button in the top-right corner of the session header. In the panel that appears on the left, click any message, and the input box will automatically navigate to that message’s position in the conversation.
Notes¶
- No Visible Buttons: This plugin has no visible UI buttons and relies entirely on keyboard interaction.
- Session Independence: History is stored only in browser memory, with each session independent. When switching sessions, it is reprefilled from the current session’s history.
- Trigger Condition: The cursor must be at the beginning of a line for the up/down keys to trigger. History recall does not trigger during IME input or when the slash command menu is open.
- Restart Behavior: After restarting the host, the browser reloads the plugin and reprefills history from messages that have already been sent in the current session. Only unsent drafts are reset.
Use Cases¶
This plugin is suitable for developers and users who are accustomed to command-line tools and frequently need to adjust and reuse prompts. It allows quick access to history through keyboard operations, improving interaction efficiency in DSH. The plugin is released under the MIT license, and its source code can be obtained from the plugin marketplace or GitHub.