@michengai/dsh-btw 1.1.1 → 1.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +15 -0
- package/CHANGELOG.zh-CN.md +15 -0
- package/README.md +44 -0
- package/README.zh-CN.md +44 -0
- package/lib/client.js +780 -7350
- package/lib/index.js +112 -9
- package/lib/types/client/NativeBtwAsk.d.ts +49 -0
- package/lib/types/client/SelectionAsk.d.ts +3 -1
- package/lib/types/client/SettingsCard.d.ts +21 -0
- package/lib/types/client/official-quote.d.ts +52 -0
- package/lib/types/client/settings-scope.d.ts +67 -0
- package/lib/types/client/styles.d.ts +1 -1
- package/lib/types/client/user-quote-chip.d.ts +4 -1
- package/lib/types/index.d.ts +2 -1
- package/lib/types/limits.d.ts +7 -0
- package/lib/types/locales.d.ts +18 -0
- package/lib/types/server/settings.d.ts +51 -0
- package/lib/types/server/tool-guard.d.ts +8 -1
- package/package.json +14 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,20 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## [1.3.0] - 2026-10-29
|
|
4
|
+
|
|
5
|
+
- Configurable tool whitelist: add a settings page on the plugin's row in **Plugins** (the same place as `dsh-subagent-default-model`'s configuration) where a comma-free, one-per-line list of tool names widens what a side question may call. The execution-time guard reads the whitelist on every call, so changes apply to the next side question without reloading the plugin. Empty keeps the previous text-only behaviour (#22).
|
|
6
|
+
- Configurable prompt: the same page can replace the built-in side-question prompt. The tool-permission sentence and the reply-channel sentence are always appended, so a custom prompt cannot talk the model past the guard, and `send_message` stays outside the whitelist so returning an answer is still bound to the parent session (#22).
|
|
7
|
+
- Keep parent prompt cache intact: the whitelist and custom prompt only change the trailing user message; tool definitions and system prompt stay byte-identical to the main conversation (#22).
|
|
8
|
+
- Pre-fill prompt box with built-in text: opening settings shows the actual prompt to edit in place instead of a blank box. Saving it unchanged restores the default rather than pinning a stale snapshot into configuration (#22).
|
|
9
|
+
|
|
10
|
+
## [1.2.0] - 2026-10-29
|
|
11
|
+
|
|
12
|
+
- Align with official message quotes specification: Pixel-perfect adoption of `@deepseek-ai/dsh-message-quotes` text selection interactions. Seamlessly integrate into the native `conversation.chat.text-interaction` slot on newer hosts while providing an exact floating fallback on older hosts.
|
|
13
|
+
- Deterministic selection toolbar ordering: Lock toolbar layout with "Quote text" on the left and "Ask BTW" on the right with a 6px gap, completely eliminating race-condition button jumping and capsule squeezing.
|
|
14
|
+
- Clean composer with rich-text quote link: Render quotes as inline rich-text link cards inside the input composer and completely eliminate obsolete floating pill bars above the composer.
|
|
15
|
+
- Bubble quote cards and HoverCard full-text preview: Elevate user bubble quotes to inline quote cards with native double-quote SVG markers and ellipsis overflow, accompanied by full-text HoverCard popovers on mouse hover.
|
|
16
|
+
- Compatibility matrix expansion: Broaden multi-host compatibility test suites to encompass the latest Release Candidate (`0.2.0-rc.2`) and latest Alpha release (`0.3.0-alpha.0`), ensuring 100% parity from `0.2.0-rc.1` through cutting-edge hosts.
|
|
17
|
+
|
|
3
18
|
## [1.1.1] - 2026-10-27
|
|
4
19
|
|
|
5
20
|
- Add official plugin vector icon: Introduce `assets/icon.svg` (transparent vector icon designed with dual bubbles and thought sparkles) and declare `icon` in the plugin manifest for better visual representation in the host extension manager and marketplace.
|
package/CHANGELOG.zh-CN.md
CHANGED
|
@@ -1,5 +1,20 @@
|
|
|
1
1
|
# 更新日志
|
|
2
2
|
|
|
3
|
+
## [1.3.0] - 2026-10-29
|
|
4
|
+
|
|
5
|
+
- 可配置的工具白名单:在 **插件** 页本插件行新增配置页(位置与 `dsh-subagent-default-model` 的配置页相同),按行填写除 `send_message` 之外允许旁问调用的工具名。执行期闸门每次调用都重读配置,改完对下一次旁问生效,不需要重新加载插件;留空保持原先的「只允许纯文字回答」(#22)。
|
|
6
|
+
- 可配置的提示词:同一配置页可替换内置旁问提示词。工具权限说明与回传通道说明始终追加在末尾,自定义提示词无法让模型绕过闸门;`send_message` 也不在名单内,答案回传仍然只允许发给自己的父会话(#22)。
|
|
7
|
+
- 保持主会话 prompt cache 不受影响:白名单与自定义提示词只改变末尾的用户消息,工具定义与系统提示词仍与主会话逐字节一致(#22)。
|
|
8
|
+
- 提示词输入框预填内置文案:打开配置即可在原提示词上直接修改,不用面对空白框猜内置写了什么;把文案改回内置原文再保存等于恢复默认,不会把一份过期快照钉进用户配置(#22)。
|
|
9
|
+
|
|
10
|
+
## [1.2.0] - 2026-10-29
|
|
11
|
+
|
|
12
|
+
- 接入官方选区引用规范:1:1 像素级复刻官方 `@deepseek-ai/dsh-message-quotes` 选区交互体验。在新版本宿主中自动接入原生 `conversation.chat.text-interaction` 插槽;在老版本宿主中通过高精度浮层降级承接。
|
|
13
|
+
- 选区工具栏顺序与间距锁死:锁定浮层为「引用文本」在左、「旁问」在右,间距固定 6px,彻底消除渲染竞争导致的前后跳变与胶囊挤压。
|
|
14
|
+
- 输入框引用富文本链接呈现:点击引用后在输入框内以富文本链接卡片样式呈现引文,彻底拔除输入框上方多余的悬浮药丸横条,保持输入区域干净整洁。
|
|
15
|
+
- 消息气泡引文与悬停预览升级:消息气泡内的引用升级为多行内联卡片(带原生双引号图标、无多余下划线、单行截断),并在鼠标悬停时通过 HoverCard 原生浮层展示完整引文全文。
|
|
16
|
+
- 兼容性矩阵扩展:官方兼容性测试矩阵全面覆盖最新版 RC(`0.2.0-rc.2`)与最新版阿尔法宿主(`0.3.0-alpha.0`),实现从 `0.2.0-rc.1` 至最新宿主的双轨无缝运行与 1:1 体验一致性。
|
|
17
|
+
|
|
3
18
|
## [1.1.1] - 2026-10-27
|
|
4
19
|
|
|
5
20
|
- 补充插件官方矢量图标:新增 `assets/icon.svg` 透明矢量图标(双层气泡与思考火花造型),并在插件清单中声明 `icon` 字段,提升宿主扩展管理面板与插件市场的视觉呈现。
|
package/README.md
CHANGED
|
@@ -48,6 +48,18 @@ Each answer has its own copy, collapse or expand, and close controls in the uppe
|
|
|
48
48
|
|
|
49
49
|

|
|
50
50
|
|
|
51
|
+
### Side-question settings
|
|
52
|
+
|
|
53
|
+
Open **Plugins**, pick `@michengai/dsh-btw`, and the settings form sits directly on the detail page — the whitelist and the prompt box, pre-filled with the built-in prompt so you can edit it in place.
|
|
54
|
+
|
|
55
|
+

|
|
56
|
+
|
|
57
|
+
### Drawing from a side question
|
|
58
|
+
|
|
59
|
+
With `pele_draw` on the whitelist, a side question can render a diagram. It shows up inside the side-question panel, and the main conversation is untouched.
|
|
60
|
+
|
|
61
|
+

|
|
62
|
+
|
|
51
63
|
## DSH product ecosystem
|
|
52
64
|
|
|
53
65
|
For a desktop workbench, download [DSH Codex Desktop](https://github.com/MichengAI/dsh-codex-desktop/releases). Existing [DeepSeek Harness](https://github.com/deepseek-ai/deepseek-harness) installations can add plugins as needed by following each project's README. Below are 11 first-party plugins; consult the corresponding desktop release notes and bundled catalog for what that version includes.
|
|
@@ -141,6 +153,38 @@ BTW accepts text only. Side questions with images or files are rejected without
|
|
|
141
153
|
- Each question is independent and uses completed content from the main conversation at the time you ask. It does not include an answer still being generated or previous side questions.
|
|
142
154
|
- Bubbles are not restored after refreshing the page. Copy any answers you want to keep first.
|
|
143
155
|
|
|
156
|
+
## Settings
|
|
157
|
+
|
|
158
|
+
Both entries are optional. Leaving them empty keeps the built-in behaviour: text answers only, with the shipped prompt.
|
|
159
|
+
|
|
160
|
+
Open **Plugins**, find `@michengai/dsh-btw`, and open **Configure** on its row. The page sits in the same place as the configuration page of `dsh-subagent-default-model`.
|
|
161
|
+
|
|
162
|
+
| Field | Effect |
|
|
163
|
+
| --- | --- |
|
|
164
|
+
| **Allowed tools** | Tool names the side question may call in addition to `send_message`, one per line (for example `pele_draw`). Empty allows text answers only, which is the default. |
|
|
165
|
+
| **Custom prompt** | Instruction text that replaces the built-in side-question prompt. The box is pre-filled with the built-in prompt so you can edit it in place; saving it unchanged restores the default. |
|
|
166
|
+
|
|
167
|
+
Notes:
|
|
168
|
+
|
|
169
|
+
- The whitelist widens what the side question may call; the main conversation is never restricted by it. A name that does not exist simply allows nothing.
|
|
170
|
+
- `send_message` is not a whitelist entry. Delivering an answer back to the main conversation stays bound to the rule that it may only target the side question's own parent session, so a whitelist entry cannot turn it into "send to any agent".
|
|
171
|
+
- The custom prompt replaces the instruction prefix only. The tool-permission sentence and the reply-channel sentence are always appended, so the model never believes it can call everything.
|
|
172
|
+
- Changes apply to the next side question without reloading the plugin.
|
|
173
|
+
- The permission sentence names the allowed tools, so widening the whitelist changes the side-question prompt. That prompt is a trailing user message; the tool list and system prompt stay byte-identical to the main conversation, so parent prompt cache reuse is unaffected.
|
|
174
|
+
|
|
175
|
+
### Example: let a side question draw diagrams
|
|
176
|
+
|
|
177
|
+
[`dsh-pele`](https://github.com/hesheng01/dsh-pele) provides the `pele_draw` tool, which renders Mermaid source into an SVG card inside the conversation. Add `pele_draw` to **Allowed tools** and a side question can draw too.
|
|
178
|
+
|
|
179
|
+
> Note: `dsh-pele` is a recent plugin that is not published to npm and not in the plugin marketplace yet, so it cannot be installed by searching the marketplace. Clone the repository and install its `plugin` directory into your profile:
|
|
180
|
+
>
|
|
181
|
+
> ```bash
|
|
182
|
+
> git clone https://github.com/hesheng01/dsh-pele.git
|
|
183
|
+
> dsh plugin --profile <profile> add <absolute-path>/dsh-pele/plugin
|
|
184
|
+
> ```
|
|
185
|
+
>
|
|
186
|
+
> The first install needs a Host restart.
|
|
187
|
+
|
|
144
188
|
## Uninstallation
|
|
145
189
|
|
|
146
190
|
```powershell
|
package/README.zh-CN.md
CHANGED
|
@@ -48,6 +48,18 @@
|
|
|
48
48
|
|
|
49
49
|

|
|
50
50
|
|
|
51
|
+
### 旁问配置
|
|
52
|
+
|
|
53
|
+
打开 **插件**,选中 `@michengai/dsh-btw`,配置表单就在详情页上——放行工具与提示词两个输入框,提示词框已预填内置文案,可以直接在上面改。
|
|
54
|
+
|
|
55
|
+

|
|
56
|
+
|
|
57
|
+
### 在旁问里画图
|
|
58
|
+
|
|
59
|
+
把 `pele_draw` 加进白名单后,旁问也能画图。图显示在旁问面板里,主对话不受影响。
|
|
60
|
+
|
|
61
|
+

|
|
62
|
+
|
|
51
63
|
## DSH 产品生态
|
|
52
64
|
|
|
53
65
|
想使用桌面工作台,可下载 [DSH Codex Desktop](https://github.com/MichengAI/dsh-codex-desktop/releases);已有 [DeepSeek Harness](https://github.com/deepseek-ai/deepseek-harness) 环境,可按各项目 README 按需安装。以下列出 11 个自研插件;桌面端实际随附范围以对应版本的发行说明和内置清单为准。
|
|
@@ -141,6 +153,38 @@ BTW 只接受文字。输入框中附带图片或普通文件时会拒绝旁问
|
|
|
141
153
|
- 每次旁问相互独立,参考的是提问时主会话已完成的内容,不包含正在生成的回答或之前的旁问。
|
|
142
154
|
- 刷新页面后气泡不会保留,需要保存的答案请先复制。
|
|
143
155
|
|
|
156
|
+
## 配置
|
|
157
|
+
|
|
158
|
+
下面两项都是可选的。两项都留空时保持出厂行为:只允许纯文字回答,使用内置提示词。
|
|
159
|
+
|
|
160
|
+
打开 **插件**,找到 `@michengai/dsh-btw`,点击该行的 **配置**。配置页位置与 `dsh-subagent-default-model` 的配置页相同。
|
|
161
|
+
|
|
162
|
+
| 配置项 | 作用 |
|
|
163
|
+
| --- | --- |
|
|
164
|
+
| **放行工具** | 除 `send_message` 之外,旁问还允许调用的工具名,每行一个(例如 `pele_draw`)。留空表示只允许纯文字回答,这也是默认值。 |
|
|
165
|
+
| **自定义提示词** | 替换内置的旁问提示词。输入框已预填内置文案,可直接在上面修改;原样保存即恢复默认。 |
|
|
166
|
+
|
|
167
|
+
说明:
|
|
168
|
+
|
|
169
|
+
- 白名单只放宽旁问能调用的范围,从不限制主对话;写了不存在的工具名,等于什么都没放行。
|
|
170
|
+
- `send_message` 不能写进白名单。把答案回传主对话仍然只允许发给旁问自己的父会话,白名单无法把它变成「发给任意 agent」。
|
|
171
|
+
- 自定义提示词只替换指令前缀;工具权限说明与回传通道说明始终追加在末尾,避免模型误以为可以随意调用工具。
|
|
172
|
+
- 改完对下一次旁问生效,不需要重新加载插件。
|
|
173
|
+
- 权限说明里会点名放行的工具,因此放宽白名单会改变旁问提示词。它属于末尾的用户消息,工具定义与系统提示词仍与主会话逐字节一致,不影响主会话的 prompt cache 复用。
|
|
174
|
+
|
|
175
|
+
### 示例:让旁问画图
|
|
176
|
+
|
|
177
|
+
[`dsh-pele`](https://github.com/hesheng01/dsh-pele) 提供 `pele_draw` 工具,把 Mermaid 源码渲染成会话里的 SVG 图表卡片。把 `pele_draw` 填进 **放行工具**,旁问也能画图。
|
|
178
|
+
|
|
179
|
+
> 注意:`dsh-pele` 是最近新出的插件,还没有发布到 npm,也暂时没上架插件市场,因此在插件市场里搜不到。安装方式是从 GitHub 克隆仓库,把其中的 `plugin` 目录装进 profile:
|
|
180
|
+
>
|
|
181
|
+
> ```bash
|
|
182
|
+
> git clone https://github.com/hesheng01/dsh-pele.git
|
|
183
|
+
> dsh plugin --profile <profile> add <绝对路径>/dsh-pele/plugin
|
|
184
|
+
> ```
|
|
185
|
+
>
|
|
186
|
+
> 首次接入需要重启 Host。
|
|
187
|
+
|
|
144
188
|
## 卸载
|
|
145
189
|
|
|
146
190
|
```powershell
|