dsh-enter-lock: Adding an Enter-to-Send Lock to DeepSeek Harness Web Input Fields

Preface

The chat input box in DeepSeek Harness Web typically sends messages directly when you press Enter. When editing long prompts, code, or structured text, this default behavior can easily lead to accidental sends; when using a Chinese input method, Enter may also be used to confirm candidate words rather than send messages.

dsh-enter-lock is a DeepSeek Harness Web plugin that adds an Enter send lock to the chat input box. When locked, Enter presses that would trigger the official submission path no longer send messages; when unlocked, the original Enter send behavior is restored.

DSH’s extension capabilities are typically organized as plugins. dsh-enter-lock is maintained by AIFireForAll and is licensed under MIT. If obtained through the DSH community directory, note that the directory is an independent site with no official affiliation with DeepSeek / High-Flyer.

Plugin Positioning

dsh-enter-lock has a single core goal: to prevent accidental keyboard presses from sending messages prematurely.

It does not replace the official input box. It uses the official conversation.input.right slot to provide a lock-shaped button near the chat input box. When locked, the plugin only intercepts keyboard behavior that would actually trigger the official submission path, preserving input, line breaks, candidate confirmation, candidate menu selection, and other operations.

The plugin has zero configuration by default: no API Key required, no settings needed, no settings.yaml written, and no network requests made.

Core Behavior

dsh-enter-lock provides the following capabilities:

  • Adds an Enter send lock to the DeepSeek Harness Web chat input box.
  • Provides a lock-shaped button next to the input box for locking / unlocking.
  • When locked, plain Enter, Ctrl+Enter / Cmd+Enter, and other Enter presses that would trigger the official submission path do not send.
  • Shift+Enter still inserts a line break.
  • Enter during IME composition is allowed through, so input method candidate confirmation is unaffected.
  • Lock state is saved per conversation.
  • Provides a Ctrl+Shift+K (Windows/Linux) or Cmd+Shift+K (macOS) shortcut to toggle lock / unlock.
  • Compatible with the @ file / Session candidate menu and the / command menu — when a candidate menu is open, Enter confirms the candidate and is unaffected.
  • Uses the official conversation.input.right slot and does not replace the official input box.
  • Zero configuration by default; does not write settings.yaml or make network requests.

Clicking the official send button with the mouse still sends messages. This plugin only prevents accidental keyboard sends and does not block deliberate mouse-based sending.

Installation and Enablement

Environment Requirements

Before installing, confirm that your current environment meets the following requirements:

  • DeepSeek Harness 0.1.0-rc.6 or newer.
  • Uses the web profile.
  • Uses a modern Chromium-based browser, such as Chrome / Edge.
  • The shortcut requires version 0.4.0 or above; in 0.3.x, the shortcut is deliberately disabled.

Installing from GitHub

First, run the following command to install the plugin from the AIFireForAll/dsh-enter-lock repository:

dsh plugin --profile web add github:AIFireForAll/dsh-enter-lock

You can also explicitly use a Git URL:

dsh plugin --profile web add https://github.com/AIFireForAll/dsh-enter-lock.git

Installing from a Local Directory

If you want to use a local repository, you can clone the repository first, then install the local directory:

git clone https://github.com/AIFireForAll/dsh-enter-lock.git
dsh plugin --profile web add ./dsh-enter-lock

Verifying Installation

After installation, check whether the plugin appears in the current web profile’s configuration output:

dsh --profile web --dump-config | grep dsh-enter-lock

Starting Web

Once you have confirmed the plugin is installed, start DeepSeek Harness Web:

dsh web

Typical Usage

The following describes how to use it in the typical order of operations.

  1. Start DeepSeek Harness Web:
dsh web
  1. After entering the chat interface, find the lock-shaped button at the bottom-right corner of the chat input box, near the model selector and send button.

  2. Click the lock-shaped button to lock / unlock. When locked, the keyboard submission path is intercepted; when unlocked, the original Enter send behavior is restored.

  3. If the focus is within the chat input card, you can also use the shortcut to toggle:

  • Windows / Linux: Ctrl+Shift+K
  • macOS: Cmd+Shift+K
  1. When locked, the common behaviors are as follows:
  • Plain Enter: does not send.
  • Ctrl+Enter / Cmd+Enter: does not send.
  • Other Enter presses that trigger the official submission path: do not send.
  • Shift+Enter: still inserts a line break.
  • Enter during IME composition: used for candidate confirmation, unaffected.
  • When the @ file / Session candidate menu is open: Enter confirms the candidate, unaffected.
  • When the / command menu is open: Enter confirms the candidate, unaffected.
  • Clicking the official send button with the mouse: still sends.
  1. The lock state is saved per conversation. The lock state is automatically cleared after refreshing the page or restarting.

Applicable Scenarios and Notes

This plugin is suitable for the following scenarios:

  • Editing long prompts, code, or structured text in the chat input box.
  • Using a Chinese input method and not wanting to send messages directly when confirming candidate words.
  • Wanting to keep the official input box, candidate menu, command menu, and send button while only adding keyboard mis-touch protection.

Notes before use:

  • The plugin runs with the current dsh process permissions. Before installation, check the source code and license. This project is licensed under MIT.
  • The lock only prevents accidental keyboard sends; it does not block mouse clicks on the official send button.
  • The shortcut only takes effect when the focus is within the chat input card.
  • The shortcut does not trigger during IME composition.
  • Automatic repetition from holding down the shortcut key is ignored.
  • The lock state is only stored in browser memory and is automatically cleared after refreshing the page or restarting.
  • The plugin has zero configuration by default, requiring no API Key, settings, or settings.yaml.

Uninstallation

If you no longer need this plugin, run:

dsh plugin --profile web remove dsh-enter-lock

Links

GitHub repository:

https://github.com/AIFireForAll/dsh-enter-lock.git
羽毛球分组比赛记分
小程序二维码

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

Xiaoye