dsh-deeppilot 0.7.0 → 0.8.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/COMPATIBILITY.md +70 -4
- package/README.md +22 -15
- package/README.zh-CN.md +15 -11
- package/icon.svg +13 -0
- package/lib/client.js +364 -165
- package/lib/client.js.map +1 -1
- package/lib/index.d.ts +118 -97
- package/lib/index.js +209 -77
- package/lib/index.js.map +1 -1
- package/locale/en.json +6 -0
- package/locale/zh.json +6 -0
- package/package.json +22 -17
package/COMPATIBILITY.md
CHANGED
|
@@ -7,7 +7,7 @@ This file separates tested evidence from intended behavior. Passing unit tests d
|
|
|
7
7
|
| Component | Baseline | Evidence |
|
|
8
8
|
|---|---|---|
|
|
9
9
|
| Node.js | 22 or newer | package engine and CI |
|
|
10
|
-
| DSH CLI and Host API | the `0.1.5-rc.*` and `0.1.6-*`/`0.1.6` lines, `0.1.5-rc.1` minimum, for plugin `0.7.x` | plugin source typecheck, unit suite (
|
|
10
|
+
| DSH CLI and Host API | the `0.1.5-rc.*` and `0.1.6-*`/`0.1.6` lines, `0.1.5-rc.1` minimum, for plugin `0.7.x` | plugin source typecheck, unit suite (265 tests) and `tsdown` build run against the `0.1.5-rc.2`, `0.1.6-alpha.1` and `0.1.6-alpha.2` package families; the `deeppilot/report` contribution registered through both the `0.1.6-alpha.1` and the `0.1.6-alpha.2` `TypertRegistry`; bridge and `/phone` protocol tests |
|
|
11
11
|
| Host OS | macOS, Linux, Windows on packaged amd64/arm64 helper targets | helper checksums plus user-confirmed Windows/Linux Funnel launch and connection; local LAN validation remains part of alpha testing |
|
|
12
12
|
| Remote access | Tailscale Funnel, ports 443/8443/10000 | helper and supervisor tests |
|
|
13
13
|
| iOS | native DeepPilot client, protocol v2 | simulator build and v2 pairing/challenge evidence |
|
|
@@ -15,6 +15,7 @@ This file separates tested evidence from intended behavior. Passing unit tests d
|
|
|
15
15
|
## Protocol boundary
|
|
16
16
|
|
|
17
17
|
- Protocol v2 is the only supported wire version. Existing protocol-v1 devices must pair again after upgrading.
|
|
18
|
+
- The pairing QR now encodes a `deeppilot://pair` link, and the settings page shows that same string in one copy field. An app build that predates the link only parses the JSON payload, so it must be updated before pairing against this plugin; a link pasted into an older app is rejected instead of being half-applied. The current app still accepts the JSON payload.
|
|
18
19
|
- Plugin `0.7.x` serves the LAN listener over self-signed TLS only; devices paired over LAN with `0.6.x` or older must pair again so the app receives the certificate fingerprint. The DSH web server no longer carries `/phone` compatibility routes. Funnel pairings are unaffected.
|
|
19
20
|
- Bearer authentication, URL credentials, and first-frame shared tokens are rejected. A supported client registers a P-256 public key through `/phone/pair` and signs each WebSocket challenge.
|
|
20
21
|
- Without a compatible embedded helper, the core bridge and trusted-LAN mode can still run; remote Funnel reports `unavailable`.
|
|
@@ -23,12 +24,18 @@ This file separates tested evidence from intended behavior. Passing unit tests d
|
|
|
23
24
|
Older plugin versions used developer-preview DSH builds and remain historical
|
|
24
25
|
artifacts.
|
|
25
26
|
- The declared peer range is a disjunction,
|
|
26
|
-
`^0.1.5-rc.1 || >=0.1.6-alpha.1 <0.2.0-0
|
|
27
|
+
`^0.1.5-rc.1 || >=0.1.6-alpha.1 <0.2.0-0 || >=0.1.7-alpha.1 <0.2.0-0`,
|
|
28
|
+
because npm's prerelease rule only
|
|
27
29
|
lets a prerelease version satisfy a range whose comparators carry a
|
|
28
30
|
prerelease on the same `major.minor.patch` tuple. Neither `^0.1.5-rc.1` nor
|
|
29
|
-
`>=0.1.5-rc.1` alone admits a `0.1.6` prerelease
|
|
31
|
+
`>=0.1.5-rc.1` alone admits a `0.1.6` prerelease, and the `0.1.7-alpha.*`
|
|
32
|
+
line is likewise rejected by `>=0.1.6-alpha.1 <0.2.0-0` because no
|
|
33
|
+
comparator there carries a prerelease on the `0.1.7` tuple — every new
|
|
34
|
+
prerelease line needs its own disjunct.
|
|
35
|
+
`tests/compatibility-metadata.test.ts`
|
|
30
36
|
asserts the range admits `0.1.5-rc.1`, `0.1.5-rc.2`, `0.1.6-alpha.1`,
|
|
31
|
-
`0.1.6-beta.1
|
|
37
|
+
`0.1.6-beta.1`, `0.1.6`, `0.1.7-alpha.1` and `0.1.7`,
|
|
38
|
+
and rejects `0.2.0`.
|
|
32
39
|
- DSH `0.1.6-alpha.1` replaced `agent/session-start` with `agent/created`,
|
|
33
40
|
deprecated the synchronous `snapshotEvents`/`eventAt`/`ownEvents` history
|
|
34
41
|
readers, and renamed the PTC packages to the `ptc-runtime` family. The plugin
|
|
@@ -36,6 +43,62 @@ This file separates tested evidence from intended behavior. Passing unit tests d
|
|
|
36
43
|
from the Cordis context (`sessionController`, `workspaceController`,
|
|
37
44
|
`directoryPickerController`, `sessionProjections`) and the `session/event`
|
|
38
45
|
and `api-session/*` events, all of which kept their `0.1.5-rc` shape.
|
|
46
|
+
- DSH `0.1.6-alpha.2` changed the strict codec shape carried by an
|
|
47
|
+
`InvocationDescriptor`. Through `0.1.6-alpha.1` a descriptor published the
|
|
48
|
+
schema value itself and every consumer called `codec.schema.parse(value)`;
|
|
49
|
+
`alpha.2` instead validates a lazy `create()` factory at registration and the
|
|
50
|
+
Gateway parses through `codec.create().parse(value)`. A codec carrying only
|
|
51
|
+
`schema` is rejected by the `alpha.2` registry
|
|
52
|
+
(`typert: … strict codec has no create() factory`), which aborts plugin
|
|
53
|
+
activation. One `strictCodec()` helper in `src/report-wire.ts` emits both
|
|
54
|
+
keys — the same hand-written, dependency-free codec — so a single published
|
|
55
|
+
package registers and parses on either generation, and
|
|
56
|
+
`tests/report-wire.test.ts` pins both access paths.
|
|
57
|
+
The other `alpha.2` Typert change — a contributed schema's materialized
|
|
58
|
+
`schema` becoming a lazy `create()` factory — does not apply here: this
|
|
59
|
+
Remote contributes no schemas, which the same test asserts.
|
|
60
|
+
- DSH `0.1.7-alpha.1` rewrote the settings subsystem: `installSection`,
|
|
61
|
+
`SettingsSectionHooks`, and the client `settingsScope` service are gone,
|
|
62
|
+
section values persist in this plugin own profile config entry, and the
|
|
63
|
+
settings UI refuses writes to fields the schema does not declare
|
|
64
|
+
`.volatile()`. The plugin adapts across both generations: `live()` in
|
|
65
|
+
`src/config.ts` feature-detects the volatile method and, on schemastery
|
|
66
|
+
3.18.2, writes the same metadata through `extra('volatile', true)` (an
|
|
67
|
+
unconditional `.volatile()` throws at import on ≤ 0.1.6 and kills
|
|
68
|
+
activation); volatile fields are exactly the ones the settings surface
|
|
69
|
+
writes (`enabled`, `local`, `remote`, plus read-time `debug`) while
|
|
70
|
+
`devicesPath`, `historyBufferMax`, and `push` keep remount-on-edit
|
|
71
|
+
semantics; `normalizeOptions` unwraps the `{ get() }`
|
|
72
|
+
references 0.1.7 carries in `apply()` options (a surviving reference fails
|
|
73
|
+
every plain-value comparison the bridge makes), the host re-runs its
|
|
74
|
+
transport reconciles on `loader/volatile-update`, and the client binds
|
|
75
|
+
`ctx.configForms.get('deeppilot')` through `src/client/settings-scope.ts`
|
|
76
|
+
when `settingsScope` is absent. Neither seam is declared in the client
|
|
77
|
+
entry's `inject`: a service name no running host provides keeps the whole
|
|
78
|
+
entry pending (`dsh-deeppilot: pending (waiting for service: settingsScope)`
|
|
79
|
+
on the first 0.1.7 boot), so both are awaited as optional injections, and
|
|
80
|
+
both are read through `ctx.get()` because a Cordis context proxy throws
|
|
81
|
+
`cannot get property "settingsScope" without inject` on an undeclared
|
|
82
|
+
service read; `tests/client-entry.test.ts` activates the real entry against
|
|
83
|
+
a Cordis context shaped like each generation and pins that audit. The same
|
|
84
|
+
release added
|
|
85
|
+
`session.projections`; the bridge feature-detects it via
|
|
86
|
+
`supportsProjections` and refreshes a session projection baseline on open,
|
|
87
|
+
while older hosts keep list-row projection hints. Plugin-manager display
|
|
88
|
+
metadata (`locale/*.json`, `package.json.icon`) and `--dump-config-schema`
|
|
89
|
+
are additive and inert on older hosts; `npm run check:config-schema`
|
|
90
|
+
projects this package Config through the pinned 0.1.7 CLI in CI and pins
|
|
91
|
+
the volatile annotations on the four live fields (devDependency floor:
|
|
92
|
+
`@deepseek-ai/schemastery` 3.18.3, which is also what a profile install
|
|
93
|
+
resolves through the `^3.18.2` peer range).
|
|
94
|
+
- DSH `0.1.6-alpha.2` made runtime plugin removal real, through both the
|
|
95
|
+
Plugin Manager and the client entry reconciler. Every long-lived resource is
|
|
96
|
+
registered through `ctx.effect`, and the settings-page stylesheet stamps
|
|
97
|
+
`data-plugin="dsh-deeppilot"` so the module system's `removeOwnedStyles()`
|
|
98
|
+
can delete it; the module system only auto-claims styles present during
|
|
99
|
+
factory materialization, while this sheet is injected from `apply()`.
|
|
100
|
+
Without that stamp, disabling the plugin would leave its sheet styling the
|
|
101
|
+
page.
|
|
39
102
|
- The compatibility facade converts the
|
|
40
103
|
current Session controller's raw event arrays into the stable wrapped
|
|
41
104
|
history entries consumed by the phone bridge. Sessions persisted by earlier
|
|
@@ -47,6 +110,9 @@ This file separates tested evidence from intended behavior. Passing unit tests d
|
|
|
47
110
|
|
|
48
111
|
- Intel macOS support for the embedded helper;
|
|
49
112
|
- signed/notarized helper distribution;
|
|
113
|
+
- validation against the `0.1.7-*` package line: the peer range admits
|
|
114
|
+
`0.1.7-alpha.1` and later `0.1.7` releases, but typecheck, unit-suite, and
|
|
115
|
+
runtime evidence against those host packages have not been produced yet;
|
|
50
116
|
- repair or migration of persisted history rejected by the Host's own session
|
|
51
117
|
reader;
|
|
52
118
|
- every DSH developer-preview revision;
|
package/README.md
CHANGED
|
@@ -38,16 +38,18 @@ does not require the helper.
|
|
|
38
38
|
|
|
39
39
|
| Plugin version | Required DSH | How to install |
|
|
40
40
|
|---|---|---|
|
|
41
|
-
| `0.
|
|
42
|
-
| `0.
|
|
43
|
-
| `0.
|
|
41
|
+
| `0.8.x` (current stable, `latest`) | DSH `0.1.5-rc.1` or newer | `dsh plugin --profile web add dsh-deeppilot` |
|
|
42
|
+
| `0.7.x` (previous stable) | DSH `0.1.5-rc.1` or newer | `dsh plugin --profile web add dsh-deeppilot@0.7.1` |
|
|
43
|
+
| `0.6.x` (legacy) | DSH `0.1.5-rc.1` or newer | `dsh plugin --profile web add dsh-deeppilot@0.6.2` |
|
|
44
44
|
|
|
45
|
-
`0.
|
|
45
|
+
`0.8.x` is built and typechecked against the DSH
|
|
46
46
|
[0.1.5-rc.1](https://www.npmjs.com/package/@deepseek-ai/dsh/v/0.1.5-rc.1)
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
47
|
+
and [0.1.7-alpha.1](https://www.npmjs.com/package/@deepseek-ai/dsh/v/0.1.7-alpha.1)
|
|
48
|
+
Host and client package families — the config-schema release check projects the
|
|
49
|
+
plugin's Config through the pinned 0.1.7 CLI. It uses the Gateway multi-client
|
|
50
|
+
Remote Events routing that keeps Web and DeepPilot independently answerable.
|
|
51
|
+
Earlier plugin alphas remain historical artifacts; users installing the `alpha`
|
|
52
|
+
tag for pre-release testing should update DSH to `0.1.5-rc.1` or newer.
|
|
51
53
|
|
|
52
54
|
```sh
|
|
53
55
|
# DSH 0.1.5-rc.1 or newer (recommended):
|
|
@@ -58,8 +60,12 @@ dsh web
|
|
|
58
60
|
```
|
|
59
61
|
|
|
60
62
|
After DSH restarts, open **Settings → DeepPilot**, enable the connection, show
|
|
61
|
-
the pairing QR code, and scan it in the DeepPilot app.
|
|
62
|
-
shows
|
|
63
|
+
the pairing QR code, and scan it in the DeepPilot app. Below the QR code the same
|
|
64
|
+
panel shows one copyable piece of pairing info (address, single-use code and
|
|
65
|
+
certificate fingerprint) that can be pasted into the app in one step — useful for
|
|
66
|
+
Simulator or when the camera is unavailable. Switching between the LAN and
|
|
67
|
+
public address issues a matching new QR code and string immediately, with the
|
|
68
|
+
panel staying open.
|
|
63
69
|
|
|
64
70
|
LAN access is enabled by default on the plugin's independent TCP port `3098`
|
|
65
71
|
and is TLS-only. The plugin generates a self-signed certificate on first start
|
|
@@ -88,15 +94,16 @@ DeepPilot state under `$DSH_HOME/deeppilot/`.
|
|
|
88
94
|
|
|
89
95
|
## Publishing (maintainers)
|
|
90
96
|
|
|
91
|
-
`0.
|
|
92
|
-
the
|
|
93
|
-
|
|
97
|
+
`0.8.x` targets DSH `0.1.5-rc.1`+ and adapts to the DSH 0.1.7 settings rewrite;
|
|
98
|
+
`0.7.x` keeps the pre-0.1.7 settings API during the migration window, `0.6.x`
|
|
99
|
+
keeps the pre-TLS LAN transport for the same DSH family, and `0.5.x` stays
|
|
100
|
+
compatible with DSH `0.1.1-rc.2`–`0.1.2-alpha.1`. Keep them published:
|
|
94
101
|
|
|
95
102
|
1. Bump `version` in `package.json` and in the root `""` entry of
|
|
96
103
|
`package-lock.json`, then run `npm test && npm run typecheck && npm run build`
|
|
97
104
|
and inspect `npm pack --dry-run --json` (the check
|
|
98
105
|
`tests/compatibility-metadata.test.ts` enforces the peer range and asserts it
|
|
99
|
-
admits
|
|
106
|
+
admits the `0.1.5-rc.*`, the `0.1.6-*`, and the `0.1.7-*` lines).
|
|
100
107
|
2. Commit the release and push it. `npm publish` runs `prepack` (build) and
|
|
101
108
|
`prepublishOnly` (test + typecheck) automatically.
|
|
102
109
|
3. Publish pre-releases without touching `latest`:
|
|
@@ -106,7 +113,7 @@ with DSH `0.1.1-rc.2`–`0.1.2-alpha.1`. Keep them published:
|
|
|
106
113
|
```
|
|
107
114
|
|
|
108
115
|
After a successful publish, `npm view dsh-deeppilot dist-tags --json` shows
|
|
109
|
-
`"latest": "0.
|
|
116
|
+
`"latest": "0.8.x"` and `"alpha": "0.8.x-alpha.y"`. Verify the published
|
|
110
117
|
package by installing it into a DSH `0.1.5-rc.1` profile before pointing
|
|
111
118
|
users at it.
|
|
112
119
|
4. Tag the release commit `vX.Y.Z` and prepare a GitHub Release
|
package/README.zh-CN.md
CHANGED
|
@@ -35,13 +35,15 @@
|
|
|
35
35
|
|
|
36
36
|
| 插件版本 | 所需 DSH | 安装命令 |
|
|
37
37
|
|---|---|---|
|
|
38
|
-
| `0.
|
|
39
|
-
| `0.
|
|
40
|
-
| `0.
|
|
38
|
+
| `0.8.x`(当前稳定版,`latest`) | DSH `0.1.5-rc.1` 或更高 | `dsh plugin --profile web add dsh-deeppilot` |
|
|
39
|
+
| `0.7.x`(旧版稳定版) | DSH `0.1.5-rc.1` 或更高 | `dsh plugin --profile web add dsh-deeppilot@0.7.1` |
|
|
40
|
+
| `0.6.x`(历史版本) | DSH `0.1.5-rc.1` 或更高 | `dsh plugin --profile web add dsh-deeppilot@0.6.2` |
|
|
41
41
|
|
|
42
|
-
`0.
|
|
42
|
+
`0.8.x` 基于 DSH
|
|
43
43
|
[0.1.5-rc.1](https://www.npmjs.com/package/@deepseek-ai/dsh/v/0.1.5-rc.1)
|
|
44
|
-
|
|
44
|
+
与 [0.1.7-alpha.1](https://www.npmjs.com/package/@deepseek-ai/dsh/v/0.1.7-alpha.1)
|
|
45
|
+
的 Host 与 client 包族构建并完成类型检查 —— 发布前的 config-schema 检查会通过
|
|
46
|
+
固定的 0.1.7 CLI 投影本插件的 Config。它使用 Gateway 多 Client Remote Events
|
|
45
47
|
路由,使 Web 与 DeepPilot 能独立处理同一交互。旧 alpha 仅保留为历史产物;安装
|
|
46
48
|
`alpha` tag 进行预发布测试的用户应先把 DSH 更新到 `0.1.5-rc.1` 或更高版本。
|
|
47
49
|
|
|
@@ -54,7 +56,9 @@ dsh web
|
|
|
54
56
|
```
|
|
55
57
|
|
|
56
58
|
DSH 重启后,打开 **设置 → DeepPilot**,启用连接并显示配对二维码,然后在
|
|
57
|
-
DeepPilot App
|
|
59
|
+
DeepPilot App 中扫码。二维码下方同时显示一段可复制的「配对信息」(含地址、一次性配对码
|
|
60
|
+
与证书指纹),在 App 里粘贴一次即可完成配对,适合模拟器或相机不可用时使用;在「内网 /
|
|
61
|
+
公网」之间切换会立即为所选地址生成新的二维码与配对信息,面板保持展开。
|
|
58
62
|
|
|
59
63
|
局域网连接默认使用插件独立的 TCP `3098` 端口,且只提供 TLS。插件首次启动时生成
|
|
60
64
|
自签证书(私钥位于 `$DSH_HOME/deeppilot/lan-tls/`),配对二维码携带其公钥指纹,
|
|
@@ -78,14 +82,14 @@ dsh plugin --profile web remove dsh-deeppilot
|
|
|
78
82
|
|
|
79
83
|
## 发布说明(维护者)
|
|
80
84
|
|
|
81
|
-
`0.
|
|
82
|
-
|
|
83
|
-
`0.1.1-rc.2`–`0.1.2-alpha.1`,各版本线都要保持发布:
|
|
85
|
+
`0.8.x` 面向 DSH `0.1.5-rc.1`+ 并适配 DSH 0.1.7 的设置系统重写;迁移期内
|
|
86
|
+
`0.7.x` 保留 0.1.7 之前的设置 API,`0.6.x` 在同一 DSH 版本族上保留 TLS 化之前的
|
|
87
|
+
局域网传输,`0.5.x` 保持兼容 DSH `0.1.1-rc.2`–`0.1.2-alpha.1`,各版本线都要保持发布:
|
|
84
88
|
|
|
85
89
|
1. 同步修改 `package.json` 与 `package-lock.json` 根 `""` 条目中的
|
|
86
90
|
`version`,然后运行 `npm test && npm run typecheck && npm run build`,
|
|
87
91
|
并检查 `npm pack --dry-run --json`(`tests/compatibility-metadata.test.ts`
|
|
88
|
-
会强制校验 peer 范围,并断言它同时接纳 `0.1.5-rc
|
|
92
|
+
会强制校验 peer 范围,并断言它同时接纳 `0.1.5-rc.*`、`0.1.6-*` 与 `0.1.7-*` 三条线)。
|
|
89
93
|
2. 提交发布并推送。`npm publish` 会自动执行 `prepack`(构建)与
|
|
90
94
|
`prepublishOnly`(测试 + 类型检查)。
|
|
91
95
|
3. 发布预发布版本,不要动 `latest`:
|
|
@@ -95,7 +99,7 @@ dsh plugin --profile web remove dsh-deeppilot
|
|
|
95
99
|
```
|
|
96
100
|
|
|
97
101
|
发布成功后,`npm view dsh-deeppilot dist-tags --json` 应显示
|
|
98
|
-
`"latest": "0.
|
|
102
|
+
`"latest": "0.8.x"` 与 `"alpha": "0.8.x-alpha.y"`。向用户推荐前,请先在
|
|
99
103
|
DSH `0.1.5-rc.1` profile 中安装验证发布的包。
|
|
100
104
|
4. 为发布提交打 `vX.Y.Z` tag,并准备包含英文与简体中文说明的
|
|
101
105
|
GitHub Release,链接本 README 的发布说明。
|
package/icon.svg
ADDED
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 128 128" role="img" aria-label="DeepPilot">
|
|
2
|
+
<defs>
|
|
3
|
+
<linearGradient id="dp-bg" x1="0" y1="0" x2="128" y2="128" gradientUnits="userSpaceOnUse">
|
|
4
|
+
<stop offset="0" stop-color="#2563eb"/>
|
|
5
|
+
<stop offset="1" stop-color="#0c1b4a"/>
|
|
6
|
+
</linearGradient>
|
|
7
|
+
</defs>
|
|
8
|
+
<rect width="128" height="128" rx="28" fill="url(#dp-bg)"/>
|
|
9
|
+
<g transform="translate(24 24) scale(3.5)" fill="none" stroke="#ffffff" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
|
10
|
+
<path d="m22 2-7 20-4-9-9-4Z"/>
|
|
11
|
+
<path d="M22 2 11 13"/>
|
|
12
|
+
</g>
|
|
13
|
+
</svg>
|