dsh-remote-window 0.1.0-alpha.3 → 0.1.0-alpha.5
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-zh.md +40 -32
- package/README.md +41 -32
- package/assets/server-plugin/checksums.json +2 -1
- package/assets/server-plugin/{dsh-remote-window-server-0.1.0-alpha.3.tgz → dsh-remote-window-server-0.1.0-alpha.5.tgz} +0 -0
- package/lib/client.js +136 -715
- package/lib/client.js.map +1 -1
- package/lib/index.js +1807 -312
- package/lib/protocol.js +1 -1
- package/package.json +53 -53
package/README-zh.md
CHANGED
|
@@ -16,10 +16,11 @@ target rail,并把 server 的**完整官方 DSH UI 以同源 iframe 全屏铺
|
|
|
16
16
|
|
|
17
17
|
- **local(默认)**:agent、会话日志与工具仍在 server,但每次模型请求经 SSH 反向隧道转发到 client
|
|
18
18
|
本机。默认接入方式是 **自动代理本机模型**:client 用本机 DSH 的 `ctx.llm` 枚举全部 provider/model,
|
|
19
|
-
无需填 endpoint 或 key,每个 provider 在 server profile 的模型选择器里各成一条 route
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
19
|
+
无需填 endpoint 或 key,每个 provider 在 server profile 的模型选择器里各成一条 route。**全部
|
|
20
|
+
provider/model 一律转发**,没有勾选 UI;server 会话直接在本机全部模型之间切换。本机暂时没有可用
|
|
21
|
+
模型时也能连接:此时不启动反向隧道,profile 用 server 自己已配的模型,之后本机新增的模型在下次
|
|
22
|
+
连接时自动同步。新 server 通常没配模型 key,所以默认走这里;本机模型目录读取异常时用带 code 的
|
|
23
|
+
错误提示,绝不静默回退到 server 模型。
|
|
23
24
|
- **server(可选)**:server profile 使用自己的模型配置;仅当 server 已配置模型凭据时显式选择。
|
|
24
25
|
|
|
25
26
|
两种来源写同一份 server 会话日志;切换模型来源需要重连,而不是换会话。
|
|
@@ -113,10 +114,11 @@ shell sidebar 隐藏,target rail 保留可用。
|
|
|
113
114
|
`http://127.0.0.1:<随机>/<provider>/v1`。该端口是 SSH `forwardIn` 反向隧道,终止在 client 的
|
|
114
115
|
loopback-only bridge。默认的 **自动代理** 用本机 DSH 自己的 `ctx.llm` 枚举 provider/model
|
|
115
116
|
(`listProviders`/`listModels`),每个模型请求都以官方类型转成 `ctx.llm.stream()`,因此本机 DSH 的
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
sshd 拒绝转发都返回带 code
|
|
117
|
+
凭据与协议原样生效、无需重填。本机发现到的**全部** provider/model 都会代理,没有过滤或勾选;本机
|
|
118
|
+
一个模型都没有时仍然可以连接(不启动桥/隧道,profile 继续用 server 自己的模型),下次连接会重新
|
|
119
|
+
发现并同步新模型。(旧的 **手动 endpoint** 路径仅为兼容旧设置/测试保留,对话框不再提供;profile
|
|
120
|
+
始终只看到占位 key。)本机目录读取异常、桥启动失败或 sshd 拒绝转发都返回带 code 的可操作错误,绝不
|
|
121
|
+
静默回退 server 模型。
|
|
120
122
|
|
|
121
123
|
**server 权威数据。** workspace 清单/标题/顺序/pin/archive 来自 server 官方
|
|
122
124
|
`workspaceRegistry`;session 清单/标题/blank/running 来自 `sessionController` + 插件 JSONL title fold。
|
|
@@ -159,8 +161,8 @@ client 包内置 server 插件 tarball,因此目标机不需要网络或包管
|
|
|
159
161
|
1. 打开浮动 **target rail**(hover 或按 `Alt+R`),点 **新建连接**。
|
|
160
162
|
2. 选择 `SSH`,填目标信息,首次连接确认 host key 指纹。
|
|
161
163
|
3. 选择模型来源:**local**(默认)或 **server**(使用 server profile 自己的模型配置)。选 **local**
|
|
162
|
-
|
|
163
|
-
|
|
164
|
+
时,本机 DSH 的全部 provider/model 都会转发给 server profile(没有勾选步骤);本机还没有模型也能
|
|
165
|
+
连接,之后新增的模型会在下次连接时同步。
|
|
164
166
|
4. 查看探测结果。client 检查 server 的 Node/DSH 运行时与 server 插件,决定后续步骤是部署、更新还是
|
|
165
167
|
跳过;随后启动 profile server,选 local 模型时打开 SSH 反向隧道,并完成握手鉴权。失败的尝试不会
|
|
166
168
|
保存。
|
|
@@ -183,29 +185,35 @@ client 包内置 server 插件 tarball,因此目标机不需要网络或包管
|
|
|
183
185
|
|
|
184
186
|
## Compatibility
|
|
185
187
|
|
|
186
|
-
|
|
188
|
+
兼容性是**声明出来的区间**,不是藏在代码里的常量:
|
|
187
189
|
|
|
188
|
-
|
|
190
|
+
<!-- verified-runtimes:start -->
|
|
191
|
+
| Plugin | Supported DSH | Published runtimes |
|
|
189
192
|
| --- | --- | --- |
|
|
190
|
-
| 0.1.0-alpha.3 | 0.2.1-rc.3 |
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
193
|
+
| 0.1.0-alpha.3 | = 0.2.1-rc.3 | 0.2.1-rc.3 |
|
|
194
|
+
| 0.1.0-alpha.4 | >= 0.2.1-rc.2 <= 0.2.1-rc.5 | 0.2.1-rc.5, 0.2.1-rc.3 |
|
|
195
|
+
| 0.1.0-alpha.5 | >= 0.2.1-rc.2 <= 0.2.1-rc.5 | 0.2.1-rc.5, 0.2.1-rc.3 |
|
|
196
|
+
<!-- verified-runtimes:end -->
|
|
197
|
+
|
|
198
|
+
这张表由 `node scripts/sync-compat.mjs` 从 [`compat/runtimes.json`](compat/runtimes.json) 生成;
|
|
199
|
+
`--check` 会在清单、peer、README 与生成表不一致时让发布失败。三个版本号各有含义,故意分开:
|
|
200
|
+
|
|
201
|
+
- **插件版本**(`0.1.0-alpha.4`)是我们自己的包版本,按我们的节奏走。
|
|
202
|
+
- **DSH 区间**(`min … max`,两端闭)表示这个构建能驱动的 DSH 版本。DSH 是开发者预览版,高于上界的
|
|
203
|
+
版本和低于下界的版本一样可能不兼容,所以判断是闭区间,而不是「这个版本或更新」。区间退化为单版本时
|
|
204
|
+
就直接写成精确版本。
|
|
205
|
+
- **runtime 产物**(`dsh-runtime-<dsh>-<平台>.tar.gz`)按它内含的 DSH 版本命名,而不是插件版本:包里是
|
|
206
|
+
`node/` 加 `@deepseek-ai/dsh@<dsh>`,不含插件代码,多个插件版本复用同一份产物。
|
|
207
|
+
|
|
208
|
+
连接时会自动挑「能拿到 runtime 的最新受支持 DSH」:显式 `DSH_RW_RUNTIME_ARTIFACT` → 区间内且健康的
|
|
209
|
+
全局 DSH → 本地缓存 → 已发布的 release 产物 → POSIX 宿主本地构建。版本在区间内但暂时没有产物时会明确
|
|
210
|
+
报「没有可用 runtime 产物」,不会被当成不兼容。`engines.dsh` 与全部 `@deepseek-ai/dsh-*` peer 使用同一
|
|
211
|
+
表达式:区间为单版本时写精确版本,否则写 `>=min <=max`。
|
|
212
|
+
|
|
213
|
+
远端的 server 可以是 Linux、macOS 或 **Windows**。Windows 目标需要预置
|
|
214
|
+
`dsh-runtime-<version>-win32-<arch>.tar.gz`(`DSH_RW_RUNTIME_ARTIFACT`,或放在
|
|
215
|
+
`~/.dsh/remote-assets/` 的同名文件),或复用一份健康的全局 DSH——client 目前不会自行下载 runtime 产物。
|
|
216
|
+
Windows 契约、失败码与真机验证记录见 [doc/windows-server-support.md](doc/windows-server-support.md)。
|
|
209
217
|
|
|
210
218
|
独立 runtime 会优先复用 `~/.dsh/remote-assets/` 中该平台/版本的缓存包;缓存没有时,client 用本机 pnpm
|
|
211
219
|
按同一 `node/` + `dsh/` 布局构建并上传,因此升级 DSH 后首次连接可能慢一些,之后直接复用。构建只写入
|
|
@@ -261,7 +269,7 @@ dsh plugin --profile web allow-version dsh-remote-window@<已安装版本> \
|
|
|
261
269
|
|
|
262
270
|
| 症状 | 检查 |
|
|
263
271
|
| --- | --- |
|
|
264
|
-
| `incompatible-version` |
|
|
272
|
+
| `incompatible-version` | 本机装区间内的 DSH(`0.2.1-rc.2 … 0.2.1-rc.5`),或对该精确版本做豁免(见 Compatibility)。 |
|
|
265
273
|
| 没有 target rail | 插件必须已安装并在 `web` 启用;重启 `dsh web` 并刷新。hover rail 或按 `Alt+R` 展开。 |
|
|
266
274
|
| `server-plugin-missing` / `server-plugin-version-mismatch` | client 包内置的 server 插件 tarball 丢失/版本不匹配;重装 client 插件后重连。 |
|
|
267
275
|
| `server-plugin-integrity-failed` | 内置/下载的 server 插件 sha256 校验失败;重装 client 包。 |
|
package/README.md
CHANGED
|
@@ -131,12 +131,13 @@ that point at `http://127.0.0.1:<random>/<provider>/v1`. That port is an SSH `fo
|
|
|
131
131
|
tunnel, terminated by a loopback-only bridge on the client. The default **auto proxy** enumerates the
|
|
132
132
|
local DSH's own `ctx.llm` providers/models (`listProviders`/`listModels`) and answers every model call
|
|
133
133
|
from `ctx.llm.stream()` with the harness' native types, so the local DSH's own credentials and protocols
|
|
134
|
-
keep working and nothing is re-entered.
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
134
|
+
keep working and nothing is re-entered. **Every** provider and model is proxied — there is no per-model
|
|
135
|
+
opt-in and no selection UI; the server's model picker simply lists all of this host's models. A host with
|
|
136
|
+
no model at all still connects: no bridge is started, the profile keeps the server's own models, and
|
|
137
|
+
models added later are picked up by the next connection. (The legacy manual endpoint path still exists for
|
|
138
|
+
old saved settings and tests, but the UI no longer offers it; the profile always sees a placeholder key.)
|
|
139
|
+
An unreadable catalog, a broken bridge or an sshd that refuses forwarding is a coded, actionable failure —
|
|
140
|
+
never a silent fallback to server models.
|
|
140
141
|
|
|
141
142
|
**Server-authoritative data.** Workspace list/title/order/pin/archive come from the server's official
|
|
142
143
|
`workspaceRegistry`; session list/title/blank/running come from `sessionController` plus a plugin-side
|
|
@@ -212,33 +213,41 @@ package manager. Then:
|
|
|
212
213
|
|
|
213
214
|
## Compatibility
|
|
214
215
|
|
|
215
|
-
|
|
216
|
+
Compatibility is a **declared interval**, not a constant hidden in the code:
|
|
216
217
|
|
|
217
|
-
|
|
218
|
+
<!-- verified-runtimes:start -->
|
|
219
|
+
| Plugin | Supported DSH | Published runtimes |
|
|
218
220
|
| --- | --- | --- |
|
|
219
|
-
| 0.1.0-alpha.3 | 0.2.1-rc.3 |
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
[
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
221
|
+
| 0.1.0-alpha.3 | = 0.2.1-rc.3 | 0.2.1-rc.3 |
|
|
222
|
+
| 0.1.0-alpha.4 | >= 0.2.1-rc.2 <= 0.2.1-rc.5 | 0.2.1-rc.5, 0.2.1-rc.3 |
|
|
223
|
+
| 0.1.0-alpha.5 | >= 0.2.1-rc.2 <= 0.2.1-rc.5 | 0.2.1-rc.5, 0.2.1-rc.3 |
|
|
224
|
+
<!-- verified-runtimes:end -->
|
|
225
|
+
|
|
226
|
+
The table is generated from [`compat/runtimes.json`](compat/runtimes.json) by
|
|
227
|
+
`node scripts/sync-compat.mjs`; `--check` fails the release when the manifest, the peers, the READMEs or
|
|
228
|
+
the generated table disagree. Three different version numbers appear on purpose:
|
|
229
|
+
|
|
230
|
+
- **Plugin version** (`0.1.0-alpha.4`) names our packages; it moves on our schedule.
|
|
231
|
+
- **DSH interval** (`min … max`, both ends inclusive) says which DSH releases this build can drive. DSH is
|
|
232
|
+
a developer preview, so a release *above* the upper bound can break exactly like one below the lower
|
|
233
|
+
bound: the check is a closed interval, not "this version or newer". An interval of one release is
|
|
234
|
+
written as the exact version.
|
|
235
|
+
- **Runtime artifact** (`dsh-runtime-<dsh>-<platform>.tar.gz`) is named after the DSH release it carries,
|
|
236
|
+
not after the plugin: it contains `node/` plus `@deepseek-ai/dsh@<dsh>` and no plugin code, so several
|
|
237
|
+
plugin versions reuse one artifact.
|
|
238
|
+
|
|
239
|
+
On connect the client picks the newest supported DSH for which a runtime is reachable — explicit
|
|
240
|
+
`DSH_RW_RUNTIME_ARTIFACT` → a healthy global DSH inside the interval → the local cache → a published
|
|
241
|
+
release asset → a local build on a POSIX host. A DSH version *inside* the interval that has no artifact
|
|
242
|
+
yet is reported as such (`no runtime artifact is available for …`), never as an incompatibility.
|
|
243
|
+
`engines.dsh` and every `@deepseek-ai/dsh-*` peer carry the same expression: exact while the interval is a
|
|
244
|
+
single release, `>=min <=max` otherwise.
|
|
245
|
+
|
|
246
|
+
Remote servers can be Linux, macOS or **Windows**. A Windows server needs either a pre-seeded
|
|
247
|
+
`dsh-runtime-<version>-win32-<arch>.tar.gz` (`DSH_RW_RUNTIME_ARTIFACT`, or the same file under
|
|
248
|
+
`~/.dsh/remote-assets/`) or a healthy global DSH to reuse, because the client does not download runtime
|
|
249
|
+
artifacts yet. See [doc/windows-server-support.md](doc/windows-server-support.md) for the Windows contract,
|
|
250
|
+
the codes it can fail with, and the verified real-machine run.
|
|
242
251
|
|
|
243
252
|
The isolated runtime reuses a platform/version cache under `~/.dsh/remote-assets/` first. When the cache is
|
|
244
253
|
missing, the client builds the same `node/` + `dsh/` layout with the host pnpm and uploads it, so the first
|
|
@@ -304,7 +313,7 @@ credential store.
|
|
|
304
313
|
|
|
305
314
|
| Symptom | What to check |
|
|
306
315
|
| --- | --- |
|
|
307
|
-
| `incompatible-version` | Install DSH `0.2.1-rc.
|
|
316
|
+
| `incompatible-version` | Install a DSH release inside the supported interval (`0.2.1-rc.2 … 0.2.1-rc.5`) locally, or exempt that exact pair (see Compatibility). |
|
|
308
317
|
| No target rail | The plugin must be installed and enabled in `web`; restart `dsh web` and reload. Hover the rail or press `Alt+R`. |
|
|
309
318
|
| `server-plugin-missing` / `server-plugin-version-mismatch` | The client package lost or mismatched its bundled server-plugin tarball; reinstall the client plugin and reconnect. |
|
|
310
319
|
| `server-plugin-integrity-failed` | The bundled/downloaded server plugin failed its sha256 check; reinstall the client package. |
|
|
@@ -1,3 +1,4 @@
|
|
|
1
1
|
{
|
|
2
|
-
"dsh-remote-window-server-0.1.0-alpha.
|
|
2
|
+
"dsh-remote-window-server-0.1.0-alpha.4.tgz": "7e801b0032f0739e7f9f40d3f5d491c08ab67094e8b2868bb068f3b83f44138f",
|
|
3
|
+
"dsh-remote-window-server-0.1.0-alpha.5.tgz": "122fff60787d8530b0a5f9e44a1b5c28aead9cee5e88b357b65e51d07f4c6f6f"
|
|
3
4
|
}
|