dsh-plugin-bridge 0.3.2 → 0.3.4
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/README.md +7 -3
- package/README.zh.md +7 -3
- package/docs/design.md +2 -0
- package/docs/guide.zh.md +3 -3
- package/lib/dsh-alpha-host.d.ts +1 -1
- package/lib/dsh-alpha-host.js +26 -9
- package/lib/host.d.ts +14 -0
- package/lib/migrate.js +6 -0
- package/package.json +16 -14
- package/reports/dsh-0.1.3-alpha.2-compat-2026-09-08.md +65 -0
- package/reports/dsh-0.1.5-alpha.1-compat-2026-09-09.md +49 -0
package/README.md
CHANGED
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
[](https://github.com/Totoro-qaq/dsh-plugin-bridge/actions/workflows/ci.yml)
|
|
10
10
|
[](LICENSE)
|
|
11
11
|
[](package.json)
|
|
12
|
-
[](https://github.com/deepseek-ai/deepseek-harness)
|
|
13
13
|
[](https://github.com/awesome-dsh-plugin/awesome-dsh-plugin)
|
|
14
14
|
[](https://dshfind.com/en/plugins/Totoro-qaq/dsh-plugin-bridge?ref=badge)
|
|
15
15
|
|
|
@@ -35,7 +35,7 @@ dsh plugin --profile web add dsh-plugin-bridge
|
|
|
35
35
|
Pinned GitHub fallback:
|
|
36
36
|
|
|
37
37
|
```bash
|
|
38
|
-
dsh plugin --profile web add github:Totoro-qaq/dsh-plugin-bridge#v0.3.
|
|
38
|
+
dsh plugin --profile web add github:Totoro-qaq/dsh-plugin-bridge#v0.3.4
|
|
39
39
|
```
|
|
40
40
|
|
|
41
41
|
Then type in the official WebUI:
|
|
@@ -118,6 +118,10 @@ The five sections are Goal, Current state, Key decisions and conventions, Key fi
|
|
|
118
118
|
| 0.1.0-rc.7 / rc.8 | Yes | Contract-checked | Client-module/command-slot contract plus server fallback |
|
|
119
119
|
| 0.1.1-rc.2 | Yes | Yes | Installed official WebUI: doctor 13/13, edit/confirm/auto-open, three-run repeat gate |
|
|
120
120
|
| 0.1.2-alpha.2 / alpha.3 / alpha.5 | Yes | Yes | Official DSH npm hosts: typed controllers 13/13 and PTC auto-open; the alpha.5 gate installed the branch tarball, retained alpha.3 titles, edited ordered lists, fell back from unresolved image to text, and removed cleanly |
|
|
121
|
+
| 0.1.2-rc.1 → 0.1.3-alpha.2 | Yes (Bridge 0.3.3+) | Yes (Bridge 0.3.3+) | Real npm-host upgrade, preserved v2 history/title, exact edited payload, PTC paused goal, image fallback and clean removal; see [acceptance report](reports/dsh-0.1.3-alpha.2-compat-2026-09-08.md) |
|
|
122
|
+
| 0.1.5-alpha.1 | Yes (Bridge 0.3.4+) | Yes (Bridge 0.3.4+) | Official npm host with session format V3: tarball install, served native-card bundle, doctor 13/13 and preset listing on a V3 session; SDK type diff and V3 fold fixtures. Model-backed preview, migration and image fallback were not re-run; see [smoke report](reports/dsh-0.1.5-alpha.1-compat-2026-09-09.md) |
|
|
123
|
+
|
|
124
|
+
Use Bridge 0.3.4 or later for DSH 0.1.5-alpha.1: DSH published no 0.1.4, and a caret prerelease range such as `^0.1.3-alpha.2` never matches the next prerelease minor, so 0.3.4 adds `^0.1.5-alpha.1` and builds against that SDK with byte-identical `lib/` output. Session format V3 records the system prompt as a `system/message` surface node; Bridge folds only user, assistant and tool events, so prompt text never enters a handoff. Use Bridge 0.3.3 or later for DSH 0.1.3-alpha.2; Bridge 0.3.2 does not include those compatibility changes. The typed adapter reads the default 240-message history window with one fresh `inspect` call instead of four; it does not cache running state. `doctor` checks method availability, not end-to-end compatibility.
|
|
121
125
|
|
|
122
126
|
CI covers Node.js 22 and 24. Run `/bridge --doctor` after every Harness upgrade; it names missing required gateway methods instead of failing vaguely.
|
|
123
127
|
|
|
@@ -148,7 +152,7 @@ npm ci
|
|
|
148
152
|
npm run verify
|
|
149
153
|
```
|
|
150
154
|
|
|
151
|
-
`verify` builds and type-checks both plugin halves, runs
|
|
155
|
+
`verify` builds and type-checks both plugin halves, runs 176 tests, checks generated `lib/` and datasets, then packs, installs, and imports the actual npm tarball. Tests spend no model tokens. `prepublishOnly` runs the same gate; GitHub releases also require the tag to match `package.json` before trusted npm publishing.
|
|
152
156
|
|
|
153
157
|
Community listings: [Awesome DSH Plugin](https://github.com/awesome-dsh-plugin/awesome-dsh-plugin) · [Awesome DeepSeek Harness](https://github.com/Dominic789654/awesome-deepseek-harness)
|
|
154
158
|
|
package/README.zh.md
CHANGED
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
[](https://github.com/Totoro-qaq/dsh-plugin-bridge/actions/workflows/ci.yml)
|
|
10
10
|
[](LICENSE)
|
|
11
11
|
[](package.json)
|
|
12
|
-
[](https://github.com/deepseek-ai/deepseek-harness)
|
|
13
13
|
[](https://github.com/awesome-dsh-plugin/awesome-dsh-plugin)
|
|
14
14
|
[](https://dshfind.com/zh/plugins/Totoro-qaq/dsh-plugin-bridge?ref=badge)
|
|
15
15
|
|
|
@@ -35,7 +35,7 @@ dsh plugin --profile web add dsh-plugin-bridge
|
|
|
35
35
|
GitHub 固定版本备用路径:
|
|
36
36
|
|
|
37
37
|
```bash
|
|
38
|
-
dsh plugin --profile web add github:Totoro-qaq/dsh-plugin-bridge#v0.3.
|
|
38
|
+
dsh plugin --profile web add github:Totoro-qaq/dsh-plugin-bridge#v0.3.4
|
|
39
39
|
```
|
|
40
40
|
|
|
41
41
|
然后在官方 WebUI 输入:
|
|
@@ -118,6 +118,10 @@ token 百分比会随 preset、回复长度和缓存状态大幅波动;worker
|
|
|
118
118
|
| 0.1.0-rc.7 / rc.8 | 支持 | 契约核对 | client module / command slot 契约与服务端回退 |
|
|
119
119
|
| 0.1.1-rc.2 | 支持 | 支持 | 官方 WebUI 实装:doctor 13/13、编辑/确认/自动跳转、三次重复门禁 |
|
|
120
120
|
| 0.1.2-alpha.2 / alpha.3 / alpha.5 | 支持 | 支持 | 官方 DSH npm 宿主:typed controllers 13/13 与 PTC 自动跳转;alpha.5 门禁安装分支 tarball,保留 alpha.3 标题,编号列表可编辑,未解析图片降级为文本,卸载干净 |
|
|
121
|
+
| 0.1.2-rc.1 → 0.1.3-alpha.2 | 支持(Bridge 0.3.3+) | 支持(Bridge 0.3.3+) | 官方 npm 宿主真实升级、v2 历史与标题保留、编辑内容逐字交接、PTC goal 暂停、图片回退及卸载;见[验收记录](reports/dsh-0.1.3-alpha.2-compat-2026-09-08.md) |
|
|
122
|
+
| 0.1.5-alpha.1 | 支持(Bridge 0.3.4+) | 支持(Bridge 0.3.4+) | 官方 npm 宿主(会话格式 V3):tarball 安装、原生卡片 bundle 已下发、V3 会话上 doctor 13/13 与预设列表;SDK 类型 diff 与 V3 折叠 fixture。未重跑需要模型的预览、迁移与图片回退;见[smoke 记录](reports/dsh-0.1.5-alpha.1-compat-2026-09-09.md) |
|
|
123
|
+
|
|
124
|
+
DSH 0.1.5-alpha.1 请使用 Bridge 0.3.4 或更高版本:DSH 没有发布 0.1.4,而 `^0.1.3-alpha.2` 这类 caret 预发布范围不会匹配下一个预发布 minor,所以 0.3.4 追加 `^0.1.5-alpha.1` 并基于该 SDK 构建,`lib/` 产物逐字节相同。会话格式 V3 把系统提示词记成 `system/message` surface node;Bridge 只折叠用户、助手和工具事件,提示词文本不会进入交接。DSH 0.1.3-alpha.2 请使用 Bridge 0.3.3 或更高版本;Bridge 0.3.2 不包含那些兼容改动。typed adapter 只调用一次 `inspect`,就能读取默认 240 条消息的历史窗口,原来需要四次;不会缓存运行状态。`doctor` 检查方法是否存在,不能代替完整迁移验收。
|
|
121
125
|
|
|
122
126
|
CI 覆盖 Node.js 22/24。每次升级 Harness 后先跑 `/bridge --doctor`;缺哪个必要网关方法会被直接点名。
|
|
123
127
|
|
|
@@ -148,7 +152,7 @@ npm ci
|
|
|
148
152
|
npm run verify
|
|
149
153
|
```
|
|
150
154
|
|
|
151
|
-
`verify` 会构建并类型检查插件两端、运行
|
|
155
|
+
`verify` 会构建并类型检查插件两端、运行 176 项测试、核对 `lib/` 与数据集,再把真实 npm tarball 打包、安装并导入。测试不消耗模型 token。`prepublishOnly` 使用同一个 gate;GitHub Release 还会先检查 tag 与 `package.json` 版本一致,再走可信 npm 发布。
|
|
152
156
|
|
|
153
157
|
社区收录:[Awesome DSH Plugin](https://github.com/awesome-dsh-plugin/awesome-dsh-plugin) · [Awesome DeepSeek Harness](https://github.com/Dominic789654/awesome-deepseek-harness)
|
|
154
158
|
|
package/docs/design.md
CHANGED
|
@@ -81,4 +81,6 @@ Bridge's preview, safety, and migration engine depends on the typed `BridgeHost`
|
|
|
81
81
|
|
|
82
82
|
`/bridge --doctor` checks thirteen required semantic capabilities and names missing capabilities before mutation. Attachment recovery and goal clearing are optional enhancements and do not raise that baseline. Any future adapter must implement `BridgeHost` and pass the same fail-closed fixtures.
|
|
83
83
|
|
|
84
|
+
Hosts that already materialize a full snapshot may optionally implement `sessions.historyWindow`. `foldedHistory` requests its complete message budget once through this method; other adapters keep the existing paged `history` path. The typed DSH adapter takes one fresh `inspect` snapshot per window, returns only the bounded tail, and retains no snapshot between calls. Worker polling continues through fresh `history` reads. This reduces repeated Bridge-side reads and allocations; it does not promise bounded disk I/O inside the host. Method probes check availability only; v2 log replay and actual migration are covered by the [installed-host acceptance](../reports/dsh-0.1.3-alpha.2-compat-2026-09-08.md). DSH 0.1.5 session format V3 adds `system/message` surface nodes and positional replacements; the fold and the message budget ignore both, and the [0.1.5-alpha.1 smoke](../reports/dsh-0.1.5-alpha.1-compat-2026-09-09.md) records the installed-host probe without a model-backed migration.
|
|
85
|
+
|
|
84
86
|
The server-side slash command remains the compatibility core. The package also ships an optional WebUI client half that occupies the official per-command slot, reuses `MarkdownText` / `JsonTree`, offers lossless Text/Markdown editing, submits the reviewed summary back to the same host command, and opens the created target through the official Session runtime. The React-free `dsh-plugin-bridge/client-contract` export lets other UIs reuse the same parser and wire while unknown UIs retain the server/file fallback. No folding, attachment, goal, or fail-closed policy is reimplemented in the browser. The version boundary and fallback are documented in [native-webui-feasibility.md](native-webui-feasibility.md).
|
package/docs/guide.zh.md
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
## 1. 安装
|
|
6
6
|
|
|
7
|
-
前置:已安装 dsh(`dsh --version` 能输出版本,本插件已核对 0.1.0-rc.6 / rc.7 / rc.8,在 0.1.1-rc.2 完成真实视觉迁移,并用官方 npm `0.1.2-alpha.2` 完成 typed-controller
|
|
7
|
+
前置:已安装 dsh(`dsh --version` 能输出版本,本插件已核对 0.1.0-rc.6 / rc.7 / rc.8,在 0.1.1-rc.2 完成真实视觉迁移,并用官方 npm `0.1.2-alpha.2` 完成 typed-controller 安装、编辑、迁移与卸载验收,官方 npm `0.1.5-alpha.1` 完成安装、doctor 13/13 与预设列表 smoke),并有一个可跑的 web profile(跑过一次 `dsh web` 即会自动初始化)。
|
|
8
8
|
|
|
9
9
|
```bash
|
|
10
10
|
dsh plugin --profile web add dsh-plugin-bridge
|
|
@@ -13,7 +13,7 @@ dsh plugin --profile web add dsh-plugin-bridge
|
|
|
13
13
|
需要固定 GitHub tag 或 npm 暂时不可用时:
|
|
14
14
|
|
|
15
15
|
```bash
|
|
16
|
-
dsh plugin --profile web add github:Totoro-qaq/dsh-plugin-bridge#v0.3.
|
|
16
|
+
dsh plugin --profile web add github:Totoro-qaq/dsh-plugin-bridge#v0.3.4
|
|
17
17
|
```
|
|
18
18
|
|
|
19
19
|
发生了什么(不用手动干预):
|
|
@@ -141,7 +141,7 @@ dsh-bridge migrate --to code --summary-file <path>
|
|
|
141
141
|
A:确认重启过 `dsh web`(插件在启动时挂载),并且用的是 `web` profile。命令注册依赖 `commands` 服务;执行时优先用 rc.2 的 `apiProxy`,alpha 则使用 typed Session / Workspace / Preset / Goal controllers。必要能力不完整时 `/bridge --doctor` 会逐项报告,不会假装可用。
|
|
142
142
|
|
|
143
143
|
**Q:升级了 dsh 之后还能用吗?**
|
|
144
|
-
A:先打一次 `/bridge --doctor`,它会告诉你这套 host 暴露了十三项能力里的哪几项、当前模式是什么、生效配置是什么。全绿就是好的。缺能力它会点名,把那行连同你的 dsh 版本发到 issues 就行。rc.6 / rc.7 / rc.8 已逐条核对;0.1.1-rc.2 的原图迁移已实测;官方 npm `0.1.2-alpha.2` 的 typed-controller 13/13、三态编辑、PTC
|
|
144
|
+
A:先打一次 `/bridge --doctor`,它会告诉你这套 host 暴露了十三项能力里的哪几项、当前模式是什么、生效配置是什么。全绿就是好的。缺能力它会点名,把那行连同你的 dsh 版本发到 issues 就行。rc.6 / rc.7 / rc.8 已逐条核对;0.1.1-rc.2 的原图迁移已实测;官方 npm `0.1.2-alpha.2` 的 typed-controller 13/13、三态编辑、PTC 自动跳转、暂停目标与干净卸载也已实测;官方 npm `0.1.5-alpha.1`(会话格式 V3)已实测安装、doctor 13/13 与预设列表,需要模型的迁移验收尚未重跑。
|
|
145
145
|
|
|
146
146
|
**Q:图片迁移需要怎么选模型?**
|
|
147
147
|
A:图片已有助手分析时,Bridge 逐字搬这段视觉证据,不需要再次烧视觉 token。图片还没被分析时,源会话应选 `deepseek-v4-flash-vision-exp` 等视觉路由;Bridge 会在 kickoff 前把源 provider/model/reasoning effort 复制到目标,再搬原图。文本模型仍不能识图,Bridge 也不会暗中启动本地视觉模型。
|
package/lib/dsh-alpha-host.d.ts
CHANGED
|
@@ -58,7 +58,7 @@ type ContextLike = AlphaServices & {
|
|
|
58
58
|
};
|
|
59
59
|
/** Probe the real alpha services instead of the adapter's always-present closures. */
|
|
60
60
|
export declare function probeDshAlphaHost(input: ContextLike): BridgeHostProbe[];
|
|
61
|
-
/** Create the semantic BridgeHost over DSH
|
|
61
|
+
/** Create the semantic BridgeHost over DSH typed Host controllers. */
|
|
62
62
|
export declare function createDshAlphaHost(input: ContextLike, signal?: AbortSignal): BridgeHost;
|
|
63
63
|
/** Prefer the stable rc.2 path when present; otherwise use alpha controllers. */
|
|
64
64
|
export declare function resolveDshHost(input: ContextLike, signal?: AbortSignal): BridgeHost;
|
package/lib/dsh-alpha-host.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* DSH v0.1.2
|
|
2
|
+
* DSH v0.1.2/v0.1.3 typed-controller adapter.
|
|
3
3
|
*
|
|
4
4
|
* The alpha removed the legacy ApiProxy service. Keep that product change at
|
|
5
5
|
* this boundary: migration code continues to consume BridgeHost, while this
|
|
6
|
-
* adapter talks to the Host controllers structurally
|
|
7
|
-
*
|
|
6
|
+
* adapter talks to the Host controllers structurally while the browser half
|
|
7
|
+
* builds against the current client SDK.
|
|
8
8
|
*/
|
|
9
9
|
import { randomUUID } from 'node:crypto';
|
|
10
10
|
import { createApiProxyHost, probeApiProxy } from './api-rpc.js';
|
|
@@ -117,11 +117,23 @@ function currentModel(row) {
|
|
|
117
117
|
};
|
|
118
118
|
}
|
|
119
119
|
function paginateHistory(events, beforeSeq, maxMessages) {
|
|
120
|
-
|
|
120
|
+
// Snapshot events are ordered. Locate the cursor without copying/scanning
|
|
121
|
+
// the entire prefix on every page; only allocate the returned window.
|
|
122
|
+
let end = events.length;
|
|
123
|
+
if (beforeSeq !== undefined) {
|
|
124
|
+
let low = 0;
|
|
125
|
+
while (low < end) {
|
|
126
|
+
const middle = Math.floor((low + end) / 2);
|
|
127
|
+
if ((events[middle]?.seq ?? -1) < beforeSeq)
|
|
128
|
+
low = middle + 1;
|
|
129
|
+
else
|
|
130
|
+
end = middle;
|
|
131
|
+
}
|
|
132
|
+
}
|
|
121
133
|
let count = 0;
|
|
122
134
|
let cut = 0;
|
|
123
|
-
for (let index =
|
|
124
|
-
const type =
|
|
135
|
+
for (let index = end - 1; index >= 0; index -= 1) {
|
|
136
|
+
const type = events[index]?.type;
|
|
125
137
|
if (type !== 'user/message' && type !== 'assistant/message')
|
|
126
138
|
continue;
|
|
127
139
|
count += 1;
|
|
@@ -131,7 +143,7 @@ function paginateHistory(events, beforeSeq, maxMessages) {
|
|
|
131
143
|
}
|
|
132
144
|
}
|
|
133
145
|
return {
|
|
134
|
-
events:
|
|
146
|
+
events: events.slice(cut, end).map(event => ({ event })),
|
|
135
147
|
hasMore: cut > 0,
|
|
136
148
|
};
|
|
137
149
|
}
|
|
@@ -151,13 +163,13 @@ export function probeDshAlphaHost(input) {
|
|
|
151
163
|
available: typeof ALPHA_METHODS[method]?.(services) === 'function',
|
|
152
164
|
}));
|
|
153
165
|
}
|
|
154
|
-
/** Create the semantic BridgeHost over DSH
|
|
166
|
+
/** Create the semantic BridgeHost over DSH typed Host controllers. */
|
|
155
167
|
export function createDshAlphaHost(input, signal) {
|
|
156
168
|
const services = servicesOf(input);
|
|
157
169
|
const controller = services.sessionController;
|
|
158
170
|
const abort = signal ?? new AbortController().signal;
|
|
159
171
|
const host = {
|
|
160
|
-
descriptor: Object.freeze({ id: 'dsh-typed-controllers',
|
|
172
|
+
descriptor: Object.freeze({ id: 'dsh-typed-controllers', transport: 'in-process' }),
|
|
161
173
|
sessions: Object.freeze({
|
|
162
174
|
list: async (request = {}) => {
|
|
163
175
|
const list = required('session.list', controller?.list);
|
|
@@ -173,6 +185,11 @@ export function createDshAlphaHost(input, signal) {
|
|
|
173
185
|
const value = await invoke('session.history', () => inspect.call(controller, request.sessionId, abort));
|
|
174
186
|
return paginateHistory(value.events, request.beforeSeq, request.maxMessages ?? 60);
|
|
175
187
|
},
|
|
188
|
+
historyWindow: async (request) => {
|
|
189
|
+
const inspect = required('session.history', controller?.inspect);
|
|
190
|
+
const value = await invoke('session.history', () => inspect.call(controller, request.sessionId, abort));
|
|
191
|
+
return paginateHistory(value.events, undefined, request.maxMessages);
|
|
192
|
+
},
|
|
176
193
|
models: async ({ sessionId }) => {
|
|
177
194
|
const list = required('session.list', controller?.list);
|
|
178
195
|
const catalog = required('session.models', controller?.modelCatalog);
|
package/lib/host.d.ts
CHANGED
|
@@ -85,6 +85,20 @@ export interface BridgeHost {
|
|
|
85
85
|
}[];
|
|
86
86
|
hasMore?: boolean;
|
|
87
87
|
}>;
|
|
88
|
+
/** Optional single-read window for hosts that already materialize a complete
|
|
89
|
+
* snapshot. Each invocation reads fresh state; readers must not cache it
|
|
90
|
+
* across commands or worker polls. The budget counts user/assistant message events. */
|
|
91
|
+
historyWindow?(input: {
|
|
92
|
+
sessionId: string;
|
|
93
|
+
maxMessages: number;
|
|
94
|
+
}, options?: {
|
|
95
|
+
timeoutMs?: number;
|
|
96
|
+
}): Promise<{
|
|
97
|
+
events?: {
|
|
98
|
+
event: SessionEvent;
|
|
99
|
+
}[];
|
|
100
|
+
hasMore?: boolean;
|
|
101
|
+
}>;
|
|
88
102
|
models(input: {
|
|
89
103
|
sessionId: string;
|
|
90
104
|
}): Promise<SessionModels>;
|
package/lib/migrate.js
CHANGED
|
@@ -151,6 +151,12 @@ export async function foldedHistory(input, sessionId, options = {}) {
|
|
|
151
151
|
const host = asBridgeHost(input);
|
|
152
152
|
const pageMessages = options.pageMessages ?? HISTORY_PAGE_MESSAGES;
|
|
153
153
|
const maxPages = options.maxPages ?? HISTORY_MAX_PAGES;
|
|
154
|
+
if (maxPages <= 0)
|
|
155
|
+
return [];
|
|
156
|
+
if (host.sessions.historyWindow) {
|
|
157
|
+
const window = await host.sessions.historyWindow({ sessionId, maxMessages: pageMessages * maxPages }, { timeoutMs: 60_000 });
|
|
158
|
+
return foldSessionEvents((window.events ?? []).map(entry => entry.event));
|
|
159
|
+
}
|
|
154
160
|
let events = [];
|
|
155
161
|
let beforeSeq;
|
|
156
162
|
for (let page = 0; page < maxPages; page += 1) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "dsh-plugin-bridge",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.4",
|
|
4
4
|
"description": "Previewable cross-preset session migration for DeepSeek Harness with bounded, fixed-schema handoffs",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "lib/index.js",
|
|
@@ -14,6 +14,8 @@
|
|
|
14
14
|
"reports/native-workbench-2026-08-25.md",
|
|
15
15
|
"reports/native-workbench-2026-08-25.raw.json",
|
|
16
16
|
"reports/dsh-0.1.2-alpha.2-compat-2026-08-31.md",
|
|
17
|
+
"reports/dsh-0.1.3-alpha.2-compat-2026-09-08.md",
|
|
18
|
+
"reports/dsh-0.1.5-alpha.1-compat-2026-09-09.md",
|
|
17
19
|
"cordis.patch.yml",
|
|
18
20
|
"README.md",
|
|
19
21
|
"README.zh.md"
|
|
@@ -60,11 +62,11 @@
|
|
|
60
62
|
},
|
|
61
63
|
"peerDependencies": {
|
|
62
64
|
"@deepseek-ai/cordis": "^4.0.1",
|
|
63
|
-
"@deepseek-ai/dsh-api-remotes": "^0.1.0-rc.7 || ^0.1.1-rc.1 || ^0.1.2-alpha.1",
|
|
64
|
-
"@deepseek-ai/dsh-client-ui-chat": "^0.1.0-rc.7 || ^0.1.1-rc.1 || ^0.1.2-alpha.1",
|
|
65
|
-
"@deepseek-ai/dsh-client-ui-conversation": "^0.1.0-rc.7 || ^0.1.1-rc.1 || ^0.1.2-alpha.1",
|
|
66
|
-
"@deepseek-ai/dsh-client-ui-primitives": "^0.1.0-rc.7 || ^0.1.1-rc.1 || ^0.1.2-alpha.1",
|
|
67
|
-
"@deepseek-ai/dsh-client-ui-slots": "^0.1.0-rc.7 || ^0.1.1-rc.1 || ^0.1.2-alpha.1",
|
|
65
|
+
"@deepseek-ai/dsh-api-remotes": "^0.1.0-rc.7 || ^0.1.1-rc.1 || ^0.1.2-alpha.1 || ^0.1.3-alpha.2 || ^0.1.5-alpha.1",
|
|
66
|
+
"@deepseek-ai/dsh-client-ui-chat": "^0.1.0-rc.7 || ^0.1.1-rc.1 || ^0.1.2-alpha.1 || ^0.1.3-alpha.2 || ^0.1.5-alpha.1",
|
|
67
|
+
"@deepseek-ai/dsh-client-ui-conversation": "^0.1.0-rc.7 || ^0.1.1-rc.1 || ^0.1.2-alpha.1 || ^0.1.3-alpha.2 || ^0.1.5-alpha.1",
|
|
68
|
+
"@deepseek-ai/dsh-client-ui-primitives": "^0.1.0-rc.7 || ^0.1.1-rc.1 || ^0.1.2-alpha.1 || ^0.1.3-alpha.2 || ^0.1.5-alpha.1",
|
|
69
|
+
"@deepseek-ai/dsh-client-ui-slots": "^0.1.0-rc.7 || ^0.1.1-rc.1 || ^0.1.2-alpha.1 || ^0.1.3-alpha.2 || ^0.1.5-alpha.1",
|
|
68
70
|
"react": "^18.2.0"
|
|
69
71
|
},
|
|
70
72
|
"peerDependenciesMeta": {
|
|
@@ -81,14 +83,14 @@
|
|
|
81
83
|
},
|
|
82
84
|
"devDependencies": {
|
|
83
85
|
"@deepseek-ai/cordis": "4.0.2",
|
|
84
|
-
"@deepseek-ai/dsh-api-remotes": "
|
|
85
|
-
"@deepseek-ai/dsh-api-session-controller": "
|
|
86
|
-
"@deepseek-ai/dsh-client-ui-chat": "
|
|
87
|
-
"@deepseek-ai/dsh-client-ui-conversation": "
|
|
88
|
-
"@deepseek-ai/dsh-client-ui-primitives": "
|
|
89
|
-
"@deepseek-ai/dsh-client-ui-renderer": "
|
|
90
|
-
"@deepseek-ai/dsh-client-ui-session": "
|
|
91
|
-
"@deepseek-ai/dsh-client-ui-slots": "
|
|
86
|
+
"@deepseek-ai/dsh-api-remotes": "0.1.5-alpha.1",
|
|
87
|
+
"@deepseek-ai/dsh-api-session-controller": "0.1.5-alpha.1",
|
|
88
|
+
"@deepseek-ai/dsh-client-ui-chat": "0.1.5-alpha.1",
|
|
89
|
+
"@deepseek-ai/dsh-client-ui-conversation": "0.1.5-alpha.1",
|
|
90
|
+
"@deepseek-ai/dsh-client-ui-primitives": "0.1.5-alpha.1",
|
|
91
|
+
"@deepseek-ai/dsh-client-ui-renderer": "0.1.5-alpha.1",
|
|
92
|
+
"@deepseek-ai/dsh-client-ui-session": "0.1.5-alpha.1",
|
|
93
|
+
"@deepseek-ai/dsh-client-ui-slots": "0.1.5-alpha.1",
|
|
92
94
|
"@types/node": "^26.2.0",
|
|
93
95
|
"@types/react": "~18.3.1",
|
|
94
96
|
"react": "^18.3.1",
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
# DSH 0.1.3-alpha.2 compatibility and history-window acceptance
|
|
2
|
+
|
|
3
|
+
Date: 2026-09-08 (Asia/Shanghai). **Bridge 0.3.3 release acceptance**. The runtime tests used the implementation candidate based on `d2b9be2`, before its package version was bumped from 0.3.2 to 0.3.3. These results do not apply to the unchanged registry 0.3.2 package.
|
|
4
|
+
|
|
5
|
+
## Environments and artifact
|
|
6
|
+
|
|
7
|
+
- Official npm DSH `0.1.2-rc.1`: 214 DSH packages at that version; Node 24.19.0.
|
|
8
|
+
- Official npm DSH `0.1.3-alpha.2`: 223 DSH packages at that version; Node 22.23.1.
|
|
9
|
+
- Candidate built from this branch and installed with the official `dsh plugin --profile web add <tarball>` command. The same isolated profile was then opened by alpha.2.
|
|
10
|
+
- `pnpm peers check` reported no peer dependency issues after upgrade.
|
|
11
|
+
- The profile, workspace, credentials copy, browser and host test driver were isolated. Only synthetic Session content was submitted to the configured DeepSeek endpoint. Test drivers and browser recordings are not part of the plugin package.
|
|
12
|
+
- Alpha.2's `fs-ext` was built during installation under Node 22. Attempting to launch that installation under Node 24 produced `ERR_DLOPEN_FAILED`; using the matching Node 22 runtime resolved the environment error. This run does not claim an installed alpha.2/Node 24 test.
|
|
13
|
+
|
|
14
|
+
## Upgrade and real migration
|
|
15
|
+
|
|
16
|
+
| Check | Result |
|
|
17
|
+
|---|---|
|
|
18
|
+
| Old-host installed command | Doctor 13/13; actual preview and migration via `commands.execute` succeeded |
|
|
19
|
+
| Old-host facts | Project BRIDGE-A13-7813, PostgreSQL, port 7813, planned-but-not-created `src/migration.ts`, and MongoDB prohibition preserved |
|
|
20
|
+
| Old-host target | PTC, paused goal, zero autonomous goal rounds |
|
|
21
|
+
| Same-profile upgrade | Original title retained; source header becomes format v2 |
|
|
22
|
+
| Old log artifacts | All four pre-upgrade JSONL/Zstandard artifacts remain byte-identical by SHA-256 |
|
|
23
|
+
| Source content | Folded user and assistant text exactly matches the pre-upgrade snapshot; no test file was created |
|
|
24
|
+
| Alpha.2 command | Doctor 13/13; preview requested through the installed WebUI |
|
|
25
|
+
| Native editing | Text/Markdown round trip preserves numbered-list continuation; edited Next step reaches target exactly |
|
|
26
|
+
| Default confirmation | Exactly one new target; automatically opened in PTC, goal paused, zero goal rounds |
|
|
27
|
+
| Target response | Restates the critical facts and waits; does not execute tools or create files |
|
|
28
|
+
| Restart | Edited objective and paused state remain intact; old log hashes still match |
|
|
29
|
+
|
|
30
|
+
The reviewed native payload had SHA-256 `cba24d3dc1dd707de9f7cfb1b111ac95311838f166216825115c11c86e987f5e` and included long synthetic text to exercise scrolling. Both the submitted content and target goal retained those exact bytes.
|
|
31
|
+
|
|
32
|
+
## UI and image fallback
|
|
33
|
+
|
|
34
|
+
- At 1280, 768 and 375 pixels, the document had no horizontal overflow; the preview had its own scrollable body and scrolling it did not move the confirmation controls.
|
|
35
|
+
- A separate 375-pixel check scrolled the confirmation button into view and verified that its center hit the actual button, rather than the fixed composer. Native confirmation then succeeded at the desktop viewport.
|
|
36
|
+
- No page errors were observed during the connected preview/edit/confirm runs. No pixel-baseline comparison or full accessibility audit was performed.
|
|
37
|
+
- A real image was admitted through the official vision route, then cancelled before any assistant message; the source contained one durable image and zero assistant analyses. Its selected model was changed to text-only `deepseek-v4-flash` before migration.
|
|
38
|
+
- Target prompt admission rejected the image with `session/attachment-invalid` and `Model "deepseek-v4-flash" does not support image input`. Bridge returned a visible warning and completed a text-only kickoff containing the unresolved-image warning. The target had zero image blocks and a paused goal.
|
|
39
|
+
- Raw-image delivery to a vision-capable target was not repeated in this run.
|
|
40
|
+
|
|
41
|
+
## History cost comparison
|
|
42
|
+
|
|
43
|
+
The fixture contains 6,000 synthetic user-message events, created through the old host's Session API and upgraded to v2. The default returned window remains 240 messages. The installed alpha.2 `SessionController.inspect` was instrumented to count reads; results below compare the original `main` implementation against the candidate using the same real controller. The session had no attached Agent during the cold-session query comparison. Five sequential samples were taken per implementation, original first; host/OS caches may affect timing. Heap delta is before/after allocation during a read, **not peak RSS or retained memory**.
|
|
44
|
+
|
|
45
|
+
| Metric | Original 0.3.2 | Candidate |
|
|
46
|
+
|---|---:|---:|
|
|
47
|
+
| Full `inspect` calls per source window | 4 | 1 |
|
|
48
|
+
| Returned message count | 240 | 240 |
|
|
49
|
+
| Median read + fold time | 12.93 ms | 6.70 ms |
|
|
50
|
+
| Median observed heap delta | 5,579,552 B | 5,165,760 B |
|
|
51
|
+
| Folded content equality | Identical | Identical |
|
|
52
|
+
|
|
53
|
+
Original times (ms): 58.612, 12.926, 12.533, 12.958, 11.980. Candidate: 7.643, 6.689, 6.703, 7.015, 6.665. The initial original sample also pays first-read setup. An earlier attached-session comparison showed little wall-clock change (about 4–5 ms in both paths). The reliable improvement is avoiding repeated full reads; this is not an end-to-end model latency or universal speedup claim.
|
|
54
|
+
|
|
55
|
+
The adapter retains no running-state or cross-request history cache. Regression tests additionally cover new events after a window read, current worker turn completion, errors/cancellation, and equality with the paged path across tool and compaction records.
|
|
56
|
+
|
|
57
|
+
## Removal and verification
|
|
58
|
+
|
|
59
|
+
- Official `dsh plugin --profile web remove dsh-plugin-bridge`, followed by a host restart, removed the dependency, bundle registration and profile package link.
|
|
60
|
+
- The old Session remained readable through the generic command renderer. The browser had zero Bridge cards, zero Bridge style elements, zero Bridge resource requests, and zero observed page errors.
|
|
61
|
+
- Executing `/bridge --doctor` returned no command execution; an independently registered companion command still succeeded.
|
|
62
|
+
- Host restart successfully reopened the same persisted sessions, exercising normal session-lock release. Crash recovery and multi-process lock contention were not separately tested.
|
|
63
|
+
- `npm ci` followed by `npm run verify` passed under Node 22.23.1: 174 tests, build/typecheck, generated artifact checks, datasets and package import smoke. The Node 24.19.0 test run also passed all 174 tests.
|
|
64
|
+
- Summary model calls, UI fixtures and inspection endpoints were restricted to the isolated acceptance environment. No user Session database was edited or deleted.
|
|
65
|
+
- After acceptance, the temporary credential copy, both installed runtimes, synthetic profile, browser process and three test-created summary directories were removed. Sanitized measurement results, check logs and screenshots were retained outside the repository.
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
# DSH 0.1.5-alpha.1 compatibility smoke
|
|
2
|
+
|
|
3
|
+
Date: 2026-09-09 (Asia/Shanghai). **Bridge 0.3.4 release smoke**. The runtime checks used the candidate built from the `compat/dsh-0.1.5-alpha.1` branch on top of `f2d0fba`, before its package version was bumped from 0.3.3 to 0.3.4. These results do not apply to the registry 0.3.3 package, whose peer ranges stop at `^0.1.3-alpha.2`.
|
|
4
|
+
|
|
5
|
+
This is a smaller gate than the [0.1.3-alpha.2 acceptance](dsh-0.1.3-alpha.2-compat-2026-09-08.md): it proves install, load, host probing and the command path on the new host, and it audits the SDK contract by type diff. It does not repeat the model-backed preview, edit, migration or image-fallback runs; see [Not covered](#not-covered).
|
|
6
|
+
|
|
7
|
+
## Upstream change
|
|
8
|
+
|
|
9
|
+
DSH went from `dsh-v0.1.3-alpha.2` (2026-09-07) to `dsh-v0.1.5-alpha.1` (2026-09-08, 563 commits); no 0.1.4 was published to npm. Relevant items from the release notes and from diffing the published `.d.ts` files of every package Bridge pins (`dsh-api-remotes`, `dsh-api-session-controller`, `dsh-client-ui-chat/-conversation/-primitives/-renderer/-session/-slots`) plus the Host packages it calls structurally (`dsh-goal`, `dsh-session`, `dsh-session-persistence`, `dsh-commands`, `dsh-agent`, `dsh-agent-presets`, `dsh-workspace`, `dsh-api-workspace-controller`):
|
|
10
|
+
|
|
11
|
+
| Change | Effect on Bridge |
|
|
12
|
+
|---|---|
|
|
13
|
+
| Session format V3: `SESSION_FORMAT_VERSION = 3`, new `system/message` surface event, `SurfaceOp.replace` fields renamed to `startSeq`/`endSeq`, `user/message` payload unchanged (`UserMessage` with `content`) | None at runtime. The fold handles user, assistant, chunk, tool and turn events only; `system/message` and replacement copies are skipped, and the message budget counts user/assistant events only. New fixtures lock this in. |
|
|
14
|
+
| `ctx.agent` removed; `AgentSetup` receives the Agent explicitly; `Inbox` is now type-only | None. Bridge never read `ctx.agent` or `Inbox`; goals already receive the Agent from `sessionController.resolveAgent`. |
|
|
15
|
+
| `GoalService.pause/resume/clear(agent, ref)`, `remoteExportCreate(agent, request)`, new `goal/activation-changed` event, model may no longer resume a user-paused goal | Signatures unchanged. The paused migration target now also shows a resume control in the official UI. |
|
|
16
|
+
| `SessionController.list/create/inspect/modelCatalog/selectModel/prompt/cancel/rename/attachment/resolveAgent` and `SessionInspection { events }` | Unchanged; `session/attachment-invalid` with `MODEL_DOES_NOT_SUPPORT_IMAGES` still exists. |
|
|
17
|
+
| Client: Details panel removed (`DetailsSlotProps`, `SelectionTarget`, `conversation.details.tool` gone); `openFile` gains `options`; `MarkdownText` gains optional `pathImages`; `conversation.chat.commandview` and `CommandRowProps` unchanged; `commands.execute(sessionId, line, attachments)` unchanged | None. Bridge does not use the removed types. |
|
|
18
|
+
| `fs-ext` no longer compiles natively on macOS/Linux | Install no longer depends on a matching Node ABI. |
|
|
19
|
+
| Semver: `^0.1.3-alpha.2` does not satisfy `0.1.5-alpha.1` | The only required change: add `|| ^0.1.5-alpha.1` to the five optional peers and pin devDependencies to `0.1.5-alpha.1`. |
|
|
20
|
+
|
|
21
|
+
## Build against the 0.1.5-alpha.1 SDK
|
|
22
|
+
|
|
23
|
+
- devDependencies pinned to `0.1.5-alpha.1`; `npm install` changed only the `@deepseek-ai/*` entries in the lockfile.
|
|
24
|
+
- `tsc` typecheck of both halves passed; `tsdown` client build passed.
|
|
25
|
+
- The generated `lib/` (server build and browser bundle) is byte-identical to the 0.3.3 build, so the SDK bump changes no shipped code.
|
|
26
|
+
- Node 22.23.1 test run: 176/176 after updating the load test's pin and adding two V3 fixtures (fold ignores `system/message` and replacement nodes; the typed adapter's single-read window and the paged path agree on a V3 snapshot and never count system nodes toward the budget).
|
|
27
|
+
|
|
28
|
+
## Installed host smoke
|
|
29
|
+
|
|
30
|
+
Environment: official npm `@deepseek-ai/dsh@0.1.5-alpha.1` installed into a scratch prefix (541 packages, Node 22.23.1, pnpm 11.22.0), isolated `DSH_HOME`, no credentials configured, no user profile or session touched.
|
|
31
|
+
|
|
32
|
+
| Check | Result |
|
|
33
|
+
|---|---|
|
|
34
|
+
| `dsh plugin --profile web add <packed tarball>` | Profile initialized; Bridge joined `dsh.profile.bundles` after `@deepseek-ai/dsh-base` and `@deepseek-ai/dsh-web-app`; no peer warnings |
|
|
35
|
+
| `dsh web --no-open` boot | Served; the combined `/plugins/??…` module table includes `dsh-plugin-bridge/client.js`, and the served text contains the native-card style id and the `conversation.chat.commandview` registration |
|
|
36
|
+
| Slash-command menu | `/bridge` listed with its description |
|
|
37
|
+
| `/bridge --doctor` on a fresh session | `dsh-typed-controllers · 13/13 个方法可用`, mode `standard`, targets `ptc · minimal · cordis` |
|
|
38
|
+
| `/bridge` (no arguments) | Usage plus `可迁入:ptc · minimal · cordis`, `当前:standard` |
|
|
39
|
+
| Session storage | The created session was written as `session.v3.jsonl.zstd` |
|
|
40
|
+
|
|
41
|
+
Both command results were read from the `POST /api/commands/execute` responses. The WebUI's `ws://…/api/remote.mux` stream could not be held by the automation browser used for this run, so the rendered card was not inspected visually; the card bundle itself is unchanged from 0.3.3, where it was verified on 0.1.3-alpha.2.
|
|
42
|
+
|
|
43
|
+
## Not covered
|
|
44
|
+
|
|
45
|
+
- No model request was made: the summary worker, native Text/Markdown editing, confirmation, target restatement, paused goal and image-to-text fallback were not re-run on 0.1.5-alpha.1. The 0.1.3-alpha.2 report remains the latest full migration evidence.
|
|
46
|
+
- No in-place upgrade of an existing v2 profile to V3 was exercised; DSH states it rewrites supported histories into new V3 log files while preserving the originals, and Bridge reads history only through `inspect`, but this run did not measure it.
|
|
47
|
+
- No removal/restart cycle was repeated on this host.
|
|
48
|
+
|
|
49
|
+
The isolated install, profile and scratch workspace were left outside the repository and can be deleted; nothing from them is part of the package.
|