SeerableOfficial/dsh-web-search-toggle
A DeepSeek Harness (DSH) plugin that adds a "Web Search" toggle button to the chat composer tool row. When it is turned on, the agent is instructed that it must search the web before answering — mirroring the "Web Search" toggle in the DeepSeek Web Chat UI. The toggle is per-session (per conversation), like DeepSeek's own
catalog descriptioncatalog 简介 / catalog description:DSH plugin: a per-session "Web Search" toggle that forces the agent to search the web before answering.
Project Overview项目介绍
A DSH plugin that adds a per-session "Web Search" toggle to the chat composer toolbar. When enabled, it injects a system-prompt directive forcing the agent to invoke the web_search tool before answering each turn, with state persisted across reloads. Use it under the DSH web profile with a pre-configured search provider. Enforcement is advisory rather than guaranteed, since compliance remains probabilistic.
DSH 插件,为聊天输入框工具栏添加"Web Search"开关。激活后通过系统提示指令强制代理在每次回答前调用 web_search 工具,状态按会话持久化。适用于 DSH web 配置文件,需预先配置搜索提供商;该指令为概率性遵循,无法保证模型绝对执行。
请帮我了解并安装插件:【dsh-web-search-toggle】【https://github.com/SeerableOfficial/dsh-web-search-toggle】
Send this message to DSH in your current session. CLI install commands may not be accurate across systems — DSH will figure it out for you.把上面这条消息直接发给当前会话里的 DSH,让它帮你了解并安装。安装命令不一定准确,发给 DSH 更稳。
Or use CLI install (for developers)或使用命令行安装(适合开发者)
CLI Install命令行安装
dsh plugin --profile web add dsh-web-search-toggle
把 SeerableOfficial/dsh-web-search-toggle 加入你的 DSH 配置(web profile)即可启用。
READMEREADME
dsh-web-search-toggle
A DeepSeek Harness (DSH) plugin that adds a "Web Search" toggle button to the chat composer tool row. When it is turned on, the agent is instructed that it must search the web before answering — mirroring the "Web Search" toggle in the DeepSeek Web Chat UI. The toggle is per-session (per conversation), like DeepSeek's own per-conversation toggle.
Features
- Adds a compact, pill-shaped "Web Search" button in the composer tool row. Inactive = neutral outline; active = DeepSeek brand blue with a small green "on" dot.
- When ON, injects a mandatory system-prompt directive telling the agent to
call
web_searchbefore answering, on every turn of that session. - Per-session state, persisted across reloads and host restarts.
- Follows DSH's plugin conventions (
dsh.bundle.patch+dsh.client), so it installs like any other DSH web-profile plugin.
How it works
- Client half (
lib/client.js): registers the toggle into the composer's tool row (conversation.input.left, the seat beside the resident access-mode / plan / attach chrome). On toggle it calls the host through the client↔host RPC channel. - Host half (
index.js):- Serves an RPC channel (
/dsh-web-search) withwebsearch.get-state/websearch.set-state, storing the flag per session and persisting it to~/.dsh/dsh-web-search-toggle.json. - Registers a system-prompt section (
dsh-web-search:force) whose text is evaluated on every prompt assembly. When the current session's flag is ON, it injects a mandatory "you MUST callweb_searchfirst" directive into the system prompt; when OFF it renders empty (empty sections disappear).
- Serves an RPC channel (
The web_search tool itself is registered by DSH's own dsh-tool-web package
(via the auto-selected DeepSeek search-provider seam); this plugin only forces
its use.
Why "force" is a directive, not a hard block
DSH has no primitive for "the model MUST call tool X on every turn." So the enforcement is a strong, always-present system-prompt instruction — the authoritative, reliable way to steer the model in this harness. The model follows it, but compliance is probabilistic rather than guaranteed (as in the DeepSeek web chat UI itself).
Requirements
- DeepSeek Harness with the web profile (
dsh --profile web). - A configured web search provider (the built-in DeepSeek search provider, or
any
web_search-providing provider). The plugin forces the tool; it does not install one.
Installation
The plugin is published to npm. From the DSH web profile:
# via the dsh plugin command (recommended — reconciles the bundle list)
dsh plugin --profile web add dsh-web-search-toggle
or with pnpm directly (skips bundle-list reconcile):
cd <your-profile-dir>
npx pnpm add dsh-web-search-toggle
# then add "dsh-web-search-toggle" to dsh.profile.bundles in package.json
Then restart DSH so the bundle patch composes at boot:
dsh --profile web restart # or your normal restart path
Usage
- Open a conversation in the DSH web UI.
- Click the Web Search pill in the composer tool row to toggle it on.
- Ask a question — the agent calls
web_searchfirst and cites sources. - Toggle it off to restore normal behavior.
The on/off state is remembered per session.
Files
| Path | Purpose |
|---|---|
package.json |
Package + dsh.bundle.patch + dsh.client declaration |
index.js |
Host plugin: RPC channel + system-prompt force section |
lib/client.js |
Client plugin: composer "Web Search" toggle |
cordis.patch.yml |
Bundle patch mounting the host half |
LICENSE |
MIT License |
README.md |
This file |
bowenliang123/dsh-context
cocofhu/anime-find
dingyi222666/dsh-session-notification
guo6x/dsh-pilot
TOBYCAI/dsh-sessions-manager
Nono-neko/dsh-browser
Wine-Red/dsh-codex-timeline