dsh-input-traffic 0.2.10-beta.2 → 0.2.11-beta.1
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 +9 -0
- package/INSTALL.md +163 -152
- package/INSTALL.zh.md +162 -151
- package/README.md +9 -6
- package/lib/client.js +28 -28
- package/lib/client.js.map +1 -1
- package/lib/types/client/index.d.ts +1 -1
- package/lib/types/client/index.d.ts.map +1 -1
- package/lib/types/client/index.js.map +1 -1
- package/package.json +11 -7
- package/lib/types/client/auto-continue-core.d.ts +0 -103
- package/lib/types/client/auto-continue-core.d.ts.map +0 -1
- package/lib/types/client/auto-continue-core.js +0 -131
- package/lib/types/client/auto-continue-core.js.map +0 -1
- package/lib/types/client/auto-continue-store.d.ts +0 -41
- package/lib/types/client/auto-continue-store.d.ts.map +0 -1
- package/lib/types/client/auto-continue-store.js +0 -93
- package/lib/types/client/auto-continue-store.js.map +0 -1
package/CHANGELOG.md
CHANGED
|
@@ -4,6 +4,15 @@
|
|
|
4
4
|
|
|
5
5
|
## Unreleased
|
|
6
6
|
|
|
7
|
+
### 破坏性:仅支持 DSH 0.1.2+,完成 `dsh-client-runtime` 移除替换(0.2.11-beta.1)
|
|
8
|
+
|
|
9
|
+
- **`engines.dsh` 收窄为 `>=0.1.2-alpha.1 <0.2.0-0`**:`@deepseek-ai/dsh-client-runtime` 在 0.1.2-alpha.1 被整体删除(commit `be531688f3`),该版本即为本插件的硬分段点。旧版线(≤0.2.10-beta.2)继续服务 DSH 0.1.0/0.1.1。
|
|
10
|
+
- **`ClientContext` / `SessionId` 改由真实归属包提供**:`src/client/index.ts` 改为 `import type { Context as ClientContext } from '@deepseek-ai/cordis'` 与 `import type { SessionId } from '@deepseek-ai/dsh-session/types'`,与官方客户端插件一致。
|
|
11
|
+
- **契约拆除 `dsh-client-runtime` 镜像**:`src/types/contracts.d.ts` 删除 `declare module '@deepseek-ai/dsh-client-runtime/client'`;`QueuedMessage` / `SessionSnapshot` / `ISessions` 迁回 `@deepseek-ai/dsh-api-session-controller/client`,`SnapshotSelectorHook` 迁回 `@deepseek-ai/dsh-client-store`。
|
|
12
|
+
- **新增 `src/types/cordis-augment.d.ts`**:把 `slots` / `sessions` / `locale` / `settingsScope` / `conversation` 声明到 cordis `Context`(官方客户端插件的做法),替代已删除的 `ClientContext`;`ctx.get<IConversation>('conversation')` 相应改为 `ctx.get('conversation')`,因为真实 cordis `get` 由 `Context[K]` 决定返回类型。
|
|
13
|
+
- **`SettingsScopeSnapshot` 补齐 `base` / `user` / `revision`**,`SettingsScopeFace.bind` 增加可选 `decode`。
|
|
14
|
+
- **新增 `@deepseek-ai/dsh-session` peerDependency**;其余 `@deepseek-ai/dsh-client-*` peer 区间同步收窄到 `>=0.1.2-alpha.1 <0.2.0-0`。
|
|
15
|
+
|
|
7
16
|
### 变更:冻结按钮文案与 session-guard 的分工说明
|
|
8
17
|
|
|
9
18
|
- **按钮文案**:`steer.freeze` →「冻结追加」(Freeze & append / 凍結して追加 / 동결 후 추가),
|
package/INSTALL.md
CHANGED
|
@@ -1,152 +1,163 @@
|
|
|
1
|
-
# Installation Guide (Official DSH CLI)
|
|
2
|
-
|
|
3
|
-
This guide uses only the official DSH `dsh plugin` command. The command installs the dependency into a profile and synchronizes `dsh.profile.bundles`. Do not replace it with plain `npm install`, direct `pnpm add` in the profile, or manual edits to the profile manifest.
|
|
4
|
-
|
|
5
|
-
- [English installation guide](./INSTALL.md)
|
|
6
|
-
- [中文安装指南](./INSTALL.zh.md)
|
|
7
|
-
- [日本語インストールガイド](./INSTALL.ja.md)
|
|
8
|
-
- [한국어 설치 안내](./INSTALL.ko.md)
|
|
9
|
-
- [English README](./README.en.md)
|
|
10
|
-
- [中文 README](./README.md)
|
|
11
|
-
- [日本語 README](./README.ja.md)
|
|
12
|
-
- [한국어 README](./README.ko.md)
|
|
13
|
-
- [Changelog](./CHANGELOG.md)
|
|
14
|
-
- [日本語 changelog](./CHANGELOG.ja.md)
|
|
15
|
-
- [한국어 changelog](./CHANGELOG.ko.md)
|
|
16
|
-
|
|
17
|
-
The placeholders in this guide are:
|
|
18
|
-
|
|
19
|
-
- `<profile>`: the DSH profile to modify, usually `web`;
|
|
20
|
-
- `dsh-input-traffic`: the npm package and runtime plugin ID.
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
dsh
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
```
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
```
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
dsh
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
##
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
1
|
+
# Installation Guide (Official DSH CLI)
|
|
2
|
+
|
|
3
|
+
This guide uses only the official DSH `dsh plugin` command. The command installs the dependency into a profile and synchronizes `dsh.profile.bundles`. Do not replace it with plain `npm install`, direct `pnpm add` in the profile, or manual edits to the profile manifest.
|
|
4
|
+
|
|
5
|
+
- [English installation guide](./INSTALL.md)
|
|
6
|
+
- [中文安装指南](./INSTALL.zh.md)
|
|
7
|
+
- [日本語インストールガイド](./INSTALL.ja.md)
|
|
8
|
+
- [한국어 설치 안내](./INSTALL.ko.md)
|
|
9
|
+
- [English README](./README.en.md)
|
|
10
|
+
- [中文 README](./README.md)
|
|
11
|
+
- [日本語 README](./README.ja.md)
|
|
12
|
+
- [한국어 README](./README.ko.md)
|
|
13
|
+
- [Changelog](./CHANGELOG.md)
|
|
14
|
+
- [日本語 changelog](./CHANGELOG.ja.md)
|
|
15
|
+
- [한국어 changelog](./CHANGELOG.ko.md)
|
|
16
|
+
|
|
17
|
+
The placeholders in this guide are:
|
|
18
|
+
|
|
19
|
+
- `<profile>`: the DSH profile to modify, usually `web`;
|
|
20
|
+
- `dsh-input-traffic`: the npm package and runtime plugin ID.
|
|
21
|
+
|
|
22
|
+
> **Version requirement — DSH v0.1.2 or newer.**
|
|
23
|
+
>
|
|
24
|
+
> Check the running version first (`dsh --version`).
|
|
25
|
+
>
|
|
26
|
+
> | DSH version | Action |
|
|
27
|
+
> | --- | --- |
|
|
28
|
+
> | ≥ 0.1.2 | Install this release. |
|
|
29
|
+
> | < 0.1.2 | Stay on the previous plugin line (0.2.10-beta.2 or earlier). Do not run an older plugin build against DSH v0.1.2+ — upgrade the plugin instead. |
|
|
30
|
+
>
|
|
31
|
+
> The boundary is `0.1.2-alpha.1`, where DSH removed `@deepseek-ai/dsh-client-runtime`. This release imports `Context` from `@deepseek-ai/cordis` and `SessionId` from `@deepseek-ai/dsh-session/types` instead, matching the official client plugins.
|
|
32
|
+
|
|
33
|
+
## 0. Prerequisites and profile discovery
|
|
34
|
+
|
|
35
|
+
```bash
|
|
36
|
+
echo "DSH_HOME=${DSH_HOME:-$HOME/.dsh}"
|
|
37
|
+
dsh --version
|
|
38
|
+
ls "${DSH_HOME:-$HOME/.dsh}/profiles"
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
Use the profile named by your running DSH process. `web` is common, but the active `--profile` argument is authoritative.
|
|
42
|
+
|
|
43
|
+
## 1. Official installation
|
|
44
|
+
|
|
45
|
+
Install the latest version:
|
|
46
|
+
|
|
47
|
+
```bash
|
|
48
|
+
dsh plugin --profile <profile> add dsh-input-traffic -w
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
(The `-w` flag is required when the profile is a pnpm workspace root, as `web` is.)
|
|
52
|
+
|
|
53
|
+
Install the current release explicitly:
|
|
54
|
+
|
|
55
|
+
```bash
|
|
56
|
+
dsh plugin --profile <profile> add dsh-input-traffic@0.2.9 -w
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
The official CLI updates the profile dependency, lockfile, and `dsh.profile.bundles` automatically. Do not add a manual YAML row.
|
|
60
|
+
|
|
61
|
+
### Supply-chain cooling period
|
|
62
|
+
|
|
63
|
+
The dsh runtime uses pnpm 11, whose `minimumReleaseAge` policy may block a freshly published version with `ERR_PNPM_MINIMUM_RELEASE_AGE_VIOLATION`. Add the version to `minimumReleaseAgeExclude` in `~/.dsh/profiles/web/pnpm-workspace.yaml`:
|
|
64
|
+
|
|
65
|
+
```yaml
|
|
66
|
+
minimumReleaseAgeExclude:
|
|
67
|
+
- dsh-input-traffic@0.2.9
|
|
68
|
+
```
|
|
69
|
+
|
|
70
|
+
## 2. Upgrade
|
|
71
|
+
|
|
72
|
+
Upgrade to the latest registry version:
|
|
73
|
+
|
|
74
|
+
```bash
|
|
75
|
+
dsh plugin --profile <profile> update dsh-input-traffic -w
|
|
76
|
+
```
|
|
77
|
+
|
|
78
|
+
Restart DSH for host changes and refresh the Web page for client changes.
|
|
79
|
+
|
|
80
|
+
## 3. Local-path / link: registration (alternative)
|
|
81
|
+
|
|
82
|
+
For development or offline installs, register the plugin from a local checkout:
|
|
83
|
+
|
|
84
|
+
```bash
|
|
85
|
+
# ~/.dsh/profiles/web/package.json dependencies:
|
|
86
|
+
# "dsh-input-traffic": "link:<absolute path to dsh-input-traffic>"
|
|
87
|
+
# ~/.dsh/profiles/web/cordis.patch.yml:
|
|
88
|
+
# - insert:
|
|
89
|
+
# - id: input-traffic
|
|
90
|
+
# name: dsh-input-traffic
|
|
91
|
+
cd ~/.dsh/profiles/web && pnpm install && dsh web
|
|
92
|
+
```
|
|
93
|
+
|
|
94
|
+
Or use the official CLI with a local path (no network needed):
|
|
95
|
+
|
|
96
|
+
```bash
|
|
97
|
+
dsh plugin --profile <profile> add /absolute/path/to/dsh-input-traffic -w
|
|
98
|
+
```
|
|
99
|
+
|
|
100
|
+
## 4. Verify installation
|
|
101
|
+
|
|
102
|
+
Check the dependency and installed version:
|
|
103
|
+
|
|
104
|
+
```bash
|
|
105
|
+
grep -n "dsh-input-traffic" \
|
|
106
|
+
"${DSH_HOME:-$HOME/.dsh}/profiles/<profile>/package.json"
|
|
107
|
+
node -p "require('${DSH_HOME:-$HOME/.dsh}/profiles/<profile>/node_modules/dsh-input-traffic/package.json').version"
|
|
108
|
+
```
|
|
109
|
+
|
|
110
|
+
Check the official composition:
|
|
111
|
+
|
|
112
|
+
```bash
|
|
113
|
+
dsh --profile <profile> --dump-default-config
|
|
114
|
+
```
|
|
115
|
+
|
|
116
|
+
It must contain:
|
|
117
|
+
|
|
118
|
+
```yaml
|
|
119
|
+
- id: input-traffic
|
|
120
|
+
name: dsh-input-traffic
|
|
121
|
+
```
|
|
122
|
+
|
|
123
|
+
## 5. Verify the plugin
|
|
124
|
+
|
|
125
|
+
Restart DSH, then refresh the Web page. In a session, verify:
|
|
126
|
+
|
|
127
|
+
1. The three-tier planning dock appears in the waiting area;
|
|
128
|
+
2. The "Freeze session" button is visible on the composer's right;
|
|
129
|
+
3. The official "busy-Enter behavior" settings row is hidden;
|
|
130
|
+
4. While the agent is busy, sending a message places it in the waiting area with red/yellow/green planning buttons.
|
|
131
|
+
|
|
132
|
+
## Japanese and Korean support status
|
|
133
|
+
|
|
134
|
+
The plugin ships `ja` and `ko` dictionaries, but the current official DSH release exposes only `zh` and `en` through `LocaleRuntime`. On stock DSH, selecting Japanese or Korean fails with `locale "<id>" is not registered`.
|
|
135
|
+
|
|
136
|
+
To use them before official support lands, maintain a DSH fork and update:
|
|
137
|
+
|
|
138
|
+
- `packages/client/locale/src/locale-settings.ts`: add `ja` and `ko` to `LOCALE_IDS`.
|
|
139
|
+
- `packages/client/locale/src/client/index.ts`: add `{ id: 'ja', label: '日本語' }` and `{ id: 'ko', label: '한국어' }` to `LOCALES`.
|
|
140
|
+
- Add the corresponding core dictionaries and tests, then rebuild and run the forked DSH.
|
|
141
|
+
|
|
142
|
+
A plugin-only change cannot extend DSH's global locale list.
|
|
143
|
+
|
|
144
|
+
## 6. Troubleshooting
|
|
145
|
+
|
|
146
|
+
| Symptom | Action |
|
|
147
|
+
| --- | --- |
|
|
148
|
+
| `dsh` is not found | Install or enable the official DSH CLI. |
|
|
149
|
+
| `ERR_PNPM_MINIMUM_RELEASE_AGE_VIOLATION` | Add the version to `minimumReleaseAgeExclude` in the profile's `pnpm-workspace.yaml`. |
|
|
150
|
+
| Plugin shows as "disabled/unmounted" with no error | Check the profile composition. |
|
|
151
|
+
| Client entry missing from `__DSH_BOOT__` | Confirm `exports["./client"]` exists and the host fiber was established. |
|
|
152
|
+
| Freeze/resume buttons not working | Ensure session-guard is installed if using session-level locking; the plugin operates fail-open when session-guard is absent. |
|
|
153
|
+
| Stale client bundle | Hard-refresh the browser (Ctrl+Shift+R) after an upgrade. |
|
|
154
|
+
|
|
155
|
+
## 7. Remove
|
|
156
|
+
|
|
157
|
+
Use the official command:
|
|
158
|
+
|
|
159
|
+
```bash
|
|
160
|
+
dsh plugin --profile <profile> remove dsh-input-traffic
|
|
161
|
+
```
|
|
162
|
+
|
|
163
|
+
Restart DSH afterwards to restore the official queue dock and the "busy-Enter behavior" settings row.
|