dsh-connect-trae 3.6.1 → 3.8.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 +187 -0
- package/README.en.md +24 -7
- package/README.md +40 -10
- package/lib/client.js +92 -37
- package/lib/index.d.ts +312 -43
- package/lib/index.js +821 -277
- package/package.json +20 -19
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,192 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 3.8.1 (2026-10-18)
|
|
4
|
+
|
|
5
|
+
> **signed-out 不再吞掉账号列表。** 2026-10-18 的现场报告是「本地突然刷不出账号了」:
|
|
6
|
+
> 绑定的账号 access token 过期、refresh 被上游 401,这本身是要重登的凭据问题;真正致命的是
|
|
7
|
+
> 卡片在 `signed-out` 状态下把整张账号表藏起来、只留一行状态——明明列表里还有一个可用账号,
|
|
8
|
+
> 屏幕上却一个都看不见,而唯一能自救的那一下点击(改绑另一个账号)在界面上不存在。
|
|
9
|
+
> 本版修复这条恢复路径。3.8.0 从未发布到 npm,所以本版即「3.8.0 全部内容 + 本修复」。
|
|
10
|
+
|
|
11
|
+
### 修复
|
|
12
|
+
|
|
13
|
+
- **账号面板 signed-out 时仍列出账号名册**(`src/client/TraeUsageCard.tsx`):渲染门控从
|
|
14
|
+
`status !== 'signed-in' || accounts.length === 0` 改为 `status !== 'error' && accounts.length > 0`。
|
|
15
|
+
Host 在「有名册但绑定的账号用不了」时回的就是 `signed-out` + 原因 + 名册——三者同一条响应,
|
|
16
|
+
此前名册被状态丢弃。改绑完成后原因仍单独显示在表格下方一行,不再连带吞掉账号行。
|
|
17
|
+
|
|
18
|
+
### 测试
|
|
19
|
+
|
|
20
|
+
- 新增 1 例(`tests/card-accounts-table.spec.tsx`):断言 signed-out 时原因可见、表头与两行都渲染、
|
|
21
|
+
已绑定行标为当前且不重复给按钮、**另一行的绑定按钮点击后确实写入 `accounts.cn`**。
|
|
22
|
+
变异验证:把门控还原成 `=== 'signed-in'`,恰好只有这一例变红。
|
|
23
|
+
- 全仓 **711** 例通过(710 + 1)。
|
|
24
|
+
|
|
25
|
+
## 3.8.0 (2026-10-18)
|
|
26
|
+
|
|
27
|
+
> **本版未发布到 npm**(tag `v3.8.0` 与 GitHub Release 已建、不可移动;发布被 npm 2FA 的
|
|
28
|
+
> PUT 401 挡住)。其全部内容随 3.8.1 一起上线,以下保留原文。
|
|
29
|
+
|
|
30
|
+
> **国内区多了一个面板:企业版。** 同一张 CN 凭据若属于 `tob_online` 租户,会被两个网关
|
|
31
|
+
> 同时服务——消费池扣个人积分,租户池扣企业额度。同一模型、两种付费方,所以「谁付钱」
|
|
32
|
+
> 必须由你选,不能由插件猜。同时修好 `config_name` 大小写导致的 `4001`,以及企业网关
|
|
33
|
+
> 用 HTTP 200 + `event:error` 拒绝时被当成「这轮助手什么都没说」的问题。
|
|
34
|
+
|
|
35
|
+
### 新增
|
|
36
|
+
|
|
37
|
+
- **卡片新增「企业版」面板**:供应商开关从「按区域」改为「按面板」,国内版、企业版、
|
|
38
|
+
国际版三者并列,各有**独立开关、独立账号绑定、独立模型选择**。
|
|
39
|
+
|
|
40
|
+
| 面板 | provider | 默认开关 |
|
|
41
|
+
|---|---|---|
|
|
42
|
+
| 国内版 | `trae` | 开 |
|
|
43
|
+
| 企业版 | `trae-enterprise` | **关**(原来两个面板的用户不受影响) |
|
|
44
|
+
| 国际版 | `trae-global` | 开 |
|
|
45
|
+
|
|
46
|
+
关掉企业版不会影响国内版;两个 CN 池的模型选择也不再互相覆盖。企业版默认关闭,
|
|
47
|
+
因为纯个人账号用不了企业池——默认放开等于给所有人塞一条一用就失败的 provider。
|
|
48
|
+
|
|
49
|
+
- **`trae-enterprise`(显示名「Trae 企业版」)**:现在 `cn` 区并列发布两个 provider:
|
|
50
|
+
|
|
51
|
+
| provider | 计费池 | 说明 |
|
|
52
|
+
|---|---|---|
|
|
53
|
+
| `trae` | 消费 SOLO | 行为与此前完全一致,永不碰企业网关 |
|
|
54
|
+
| `trae-enterprise` | 企业租户 | **不回落**,失败如实报错 |
|
|
55
|
+
|
|
56
|
+
`TRAE_PROVIDER_IDS` 描述每个区发布哪些 id,`routeOfTraeProvider` 把 id 映射到计费池;
|
|
57
|
+
**路由在构建 provider 的客户端时固定**,不存在「按调用猜一次」。shim 为每个 provider
|
|
58
|
+
提供一条 bearer 路由并按 bearer 分派,未知 token 直接 401,不会退回第一条路由。
|
|
59
|
+
|
|
60
|
+
### 修复
|
|
61
|
+
|
|
62
|
+
- **计费账号与卡片显示可能不是同一个(本版最重要的一个)**:`accounts()` 从**已经为展示
|
|
63
|
+
过滤过**的列表推导 `selected`,而 `current()` 从**全量**登录里解析真正计费的凭据。
|
|
64
|
+
开着 `hideTenantAccounts` 且企业号排序在前时,两者分歧——卡片高亮个人号,聊天扣企业池,
|
|
65
|
+
而卡片里的 `rescanAccounts` 还会把这个错误绑定**存下来**。现在 `inUse` 拆成两个入参:
|
|
66
|
+
显式绑定走全量(展示过滤不得缩小「用户选的号」的查找范围),无绑定时默认值走过滤后列表
|
|
67
|
+
(隐藏企业号是计费决定,不是展示细节);`current()` 与 `accounts()` 传同一对参数,
|
|
68
|
+
结构上不可能再分歧,正在计费的账号也永不会被从列表里隐藏。
|
|
69
|
+
|
|
70
|
+
- **`deepseek-v4.1-flash` 等模型报 `4001`(`param is invalid`)**:网关的 `config_name`
|
|
71
|
+
**区分大小写**,而 Remote 目录给的是小写、网关只认 `DeepSeek-V4.1-Flash`。三处一起修:
|
|
72
|
+
|
|
73
|
+
1. `modelConfig` 补上 `wireConfigName`。DSH 设置通道用它重建文档,未声明的字段会在
|
|
74
|
+
**每次保存时被丢掉**——映射一丢,该模型就要等到下一次发现才能用。
|
|
75
|
+
2. `fetchModels` 改为从**客户端所钉的那条网关**读名录。两个池的名录不同
|
|
76
|
+
(`DeepSeek-V4.1-Flash` 只有企业池列),原本钉在企业池的客户端去读消费池名录,
|
|
77
|
+
永远发现不了自己池的独占模型。
|
|
78
|
+
3. `TraeSoloBridge` 查表改为大小写不敏感,映射都落空时退回目录行自己的 id。
|
|
79
|
+
|
|
80
|
+
- **企业网关的拒绝形态**:它是 **HTTP 200**,但首帧是 `event:error`(`code 4001`)。
|
|
81
|
+
现在会被转成真正的客户端错误,正常流则逐字节重放给调用方——否则拒绝会表现成
|
|
82
|
+
「这一轮助手什么都没说」。
|
|
83
|
+
|
|
84
|
+
- **企业网关要求每次调用带 `session_id`**,而消费网关会拒绝带它的请求体,所以只在该路由上加。
|
|
85
|
+
|
|
86
|
+
### 自测
|
|
87
|
+
|
|
88
|
+
- 企业版相关新增 **38** 项(`enterprise-provider` 17、`card-enterprise-panel` 9、auth 租户
|
|
89
|
+
作用域 4、web-status 过滤 3、catalog 费率 1、solo-bridge 错误码 1……详见 PR 描述第 3 节)。
|
|
90
|
+
覆盖按 bearer 分派、`session_id` 只在该路由、200/`event:error` 识别、流原样透传、
|
|
91
|
+
名录按路由读取、大小写映射与 schema 往返、租户账号作用域、4222 可读等。
|
|
92
|
+
- 计费一致性新增 2 例:`accounts()` 里 `selected` 的那一行必须就是 `current()` 计费的那个账号;
|
|
93
|
+
被隐藏的账号正在计费时仍须留在列表里。两例在修复前均变红(`expected 'tenant-user' to be 'personal-user'`)。
|
|
94
|
+
- 用真实 `tob_online` 帐号实测:企业路由返回 PONG、带 `session_id`、个人 `consumed_amount` 不变。
|
|
95
|
+
- 全仓 **710** 例通过,双 tsconfig 类型检查通过。
|
|
96
|
+
|
|
97
|
+
## 3.7.1 (2026-10-18)
|
|
98
|
+
|
|
99
|
+
> **对齐 DSH 0.2.1-rc.2,并把发布后核验收敛为一条命令。** 宿主 rc.1 → rc.2 对本插件消费的
|
|
100
|
+
> API 是**零变化**(逐字节核对确认),所以本版没有行为改动——它做的是两件事:把开发树钉到
|
|
101
|
+
> 用户实际运行的那份宿主上,以及让「npm 上的包是否等于 tag 指向的源码」不再依赖手工核对。
|
|
102
|
+
|
|
103
|
+
### 变更
|
|
104
|
+
|
|
105
|
+
- **对齐宿主 DSH 0.2.1-rc.2**:13 个 `@deepseek-ai/dsh-*` devDependency 从 `0.2.1-rc.1`
|
|
106
|
+
推进到 `0.2.1-rc.2`。`cordis` / `schemastery` / `pi-ai`(仍 `1.1.0`)均未变。
|
|
107
|
+
- **peer 范围无需改动**:`0.2.1-rc.2` 对 `>=0.1.7-rc.1 <0.3.0-0` 已判通过(实测)。
|
|
108
|
+
|
|
109
|
+
### 新增
|
|
110
|
+
|
|
111
|
+
- **`pnpm run verify:release`**(`scripts/verify-release.mjs`):把 RELEASING.md 第 8 步
|
|
112
|
+
从手工核验变成一条命令,21 项检查一次做完 —— tag 版本、tag 之后的提交、工作树状态、registry 收录、
|
|
113
|
+
`latest` 指向、**发布包每一个文件**与 tag 逐字节比对、`lib/` 由 tag 源码重建后比对。
|
|
114
|
+
退出码即结论:`0` 一致 / `1` 不一致 / `2` 前置条件不满足。
|
|
115
|
+
|
|
116
|
+
> 手工版本的三个已知盲点被闭合:核对清单只写了 8 个文件而发布包有 15 个
|
|
117
|
+
> (`icons/`、`docs/assets/`、`scripts/verify-windows.mjs` 从未被核对);
|
|
118
|
+
> 拿本地 `lib/` 当基准会掩盖「构建自未提交工作树」;`git show` 默认按 UTF-8 解码,
|
|
119
|
+
> 把 PNG 当文本会得到假的不一致 —— 本脚本第一版就踩了这个坑,三个图片文件全部误报。
|
|
120
|
+
|
|
121
|
+
### 文档
|
|
122
|
+
|
|
123
|
+
- RELEASING.md 第 8 步改为脚本优先,手工等价步骤保留在折叠区并注明其局限。
|
|
124
|
+
- **新增 `docs/PENDING_CHANGELOG.md` 暂存机制**:`CHANGELOG.md` 是随包文件,在已发布的 tag
|
|
125
|
+
之后改动它会让 `verify:release` 正确地报「tag 之后改动了发布内容」。未发布版本的条目因此
|
|
126
|
+
暂存在 `docs/`(`docs/*.md` 不进包),发版时并入 CHANGELOG 再删除。RELEASING.md 第 3 步
|
|
127
|
+
已加入对应指引。
|
|
128
|
+
|
|
129
|
+
### 测试
|
|
130
|
+
|
|
131
|
+
- `tests/dsh-peer-range.spec.ts` 的 `MUST_ADMIT` 补入 `0.2.1-rc.1` / `0.2.1-rc.2` / `0.2.1`。
|
|
132
|
+
此前这份「必须放行的版本」清单里**没有当前正在使用的版本**——范围若被误收窄到
|
|
133
|
+
当前宿主之外,测试仍会全绿。变异验证:把上界改到 `<0.2.1-rc.2` → 对应用例立刻变红。
|
|
134
|
+
- 新增 7 例(`tests/verify-release.spec.ts`),用 PATH 上的假 `npm`/`tar` 提供受控发布包,
|
|
135
|
+
子进程跑**真脚本**:一致→0、篡改→1、多出文件→1、无 tag→2、未发布→2、二进制逐字节比对、
|
|
136
|
+
tag 之后有提交仍→0。
|
|
137
|
+
- **变异验证**:把 `git show` 改回 UTF-8 解码 → 2 例变红;让比对恒返回「一致」→ 1 例变红。
|
|
138
|
+
- 全仓 **670** 例通过。
|
|
139
|
+
|
|
140
|
+
### 已核对确认无变化
|
|
141
|
+
|
|
142
|
+
- 逐字节比对插件消费的宿主包(`.d.ts` 与 `lib/*.js`)——`dsh-llm`、`dsh-llm-pi-ai`、
|
|
143
|
+
`dsh-settings`、`dsh-host-webserver`、`dsh-atomic-write`、`dsh-home-paths`、
|
|
144
|
+
`dsh-attachment`、`dsh-client-ui-renderer`,以及 `dsh-app-boot` 的 peer 门禁:**全部相同**。
|
|
145
|
+
- pi-ai 仍为 `1.1.0`,`openai-completions.js` 与 `utils/transcript.js` 未变,
|
|
146
|
+
上一轮的双向适配结论原样成立。
|
|
147
|
+
- 线上请求体探针在真实 rc.2 栈上复跑,结果与 rc.1 一致。
|
|
148
|
+
|
|
149
|
+
|
|
150
|
+
## 3.7.0 (2026-10-17)
|
|
151
|
+
|
|
152
|
+
> **对齐 DSH 0.2.1-rc.1。** 宿主把 `@earendil-works/pi-ai` 从 `^0.85.1` 抬到 `^1.1.0`,
|
|
153
|
+
> 这是 0.2 线里唯一有行为影响的变更。本插件的请求体**没有**回归——但那是靠 3.4.2 的双向适配
|
|
154
|
+
> 兜住的,本版把这条结论从「推理」变成「被测住的对照」。
|
|
155
|
+
|
|
156
|
+
### 变更
|
|
157
|
+
|
|
158
|
+
- **开发树对齐宿主实际随包版本**:13 个 `@deepseek-ai/dsh-*` devDependency 固定为 `0.2.1-rc.1`,
|
|
159
|
+
`cordis` → `^4.0.5`,`schemastery` → `3.18.5`(`pnpm-workspace.yaml` 的 override 同步抬升),
|
|
160
|
+
`@earendil-works/pi-ai` → **`1.1.0`(精确固定,不用 `^`)**,使本地 typecheck 与测试
|
|
161
|
+
跑在与用户**字节一致**的契约上。
|
|
162
|
+
- **`@earendil-works/pi-ai` peer 上界收窄为 `<2.0.0`**:原先 `>=0.85.1` 无上界,会默默放行
|
|
163
|
+
未审阅的 2.x。两端均已实测(0.85.1 ✅、1.1.0 ✅、1.3.0 ✅、2.0.0 ❌)。
|
|
164
|
+
|
|
165
|
+
### 修复
|
|
166
|
+
|
|
167
|
+
- **pi-ai 1.1.0 的类型契约**:1.1.0 把 `ProviderStreams` 的第二参改成带 `unique symbol`
|
|
168
|
+
品牌标记的 `TranscriptContext`,只有 `normalizeContext()` 能产出,于是 `withContextAdaptation`
|
|
169
|
+
在两处调用点报 `TS2345`(升级后才暴露,0.85.1 下类型可通)。适配层本来就在归一化器
|
|
170
|
+
**下方**、且旧代分支**必须**产出无品牌形状,所以在这唯一一条边界上做显式转型,
|
|
171
|
+
并在 `src/adapter.ts` 与测试侧 `send()` helper 处写明理由。
|
|
172
|
+
|
|
173
|
+
### 测试
|
|
174
|
+
|
|
175
|
+
- 新增 **线上请求体矩阵**(`tests/pi-ai-context.spec.ts`):起一个真实 SSE 端点,走
|
|
176
|
+
`createProvider` + 真实 `openAICompletionsApi()`,断言线上 body 里 `roles[0] === 'system'`、
|
|
177
|
+
system 文本等于原提示、`tools` 长度为 1;并覆盖「已归一化输入不二次包裹」的幂等性。
|
|
178
|
+
- 新增 **反向对照**:**不**套适配器时,现代副本会把提示与工具全部丢光(`roles: ["user"]`、
|
|
179
|
+
`system: null`、`tools: 0`,且**不报错**)——这条钉住适配器为什么是承重的。
|
|
180
|
+
- 全仓 **663** 例测试通过(原 660 + 3),双 tsconfig 类型检查通过,构建通过。
|
|
181
|
+
|
|
182
|
+
### 已核对、无需改动
|
|
183
|
+
|
|
184
|
+
- **peer 范围**:DSH 用 `satisfies(runtime, range, { includePrerelease: true })` 求值且只校验
|
|
185
|
+
`@deepseek-ai/dsh*`,`0.2.1-rc.1` 对 `>=0.1.7-rc.1 <0.3.0-0` 已判通过(实测)。预发布悬崖
|
|
186
|
+
只在**默认选项**下成立,不适用于本插件的门禁。
|
|
187
|
+
- **宿主 API**:`dsh-llm` / `dsh-settings` / `dsh-host-webserver` / `dsh-llm-pi-ai` 消费点签名未变。
|
|
188
|
+
- **客户端外壳**:产物仍只 `require` react / react-dom / react/jsx-runtime,槽位与主题令牌未变。
|
|
189
|
+
|
|
3
190
|
## 3.6.1 (2026-10-16)
|
|
4
191
|
|
|
5
192
|
> **「自动续期」不再是一句没有期限的承诺。** 卡片现在会告诉你**刷新令牌**何时到期 ——
|
package/README.en.md
CHANGED
|
@@ -24,7 +24,7 @@
|
|
|
24
24
|
<a href="https://dshfind.com/plugins/dingminhua/dsh-connect-trae"><img src="https://dshfind.com/api/badge/dingminhua/dsh-connect-trae" alt="dshfind plugin"></a>
|
|
25
25
|
</p>
|
|
26
26
|
|
|
27
|
-
A [DeepSeek Harness (DSH)](https://github.com/deepseek-ai/deepseek-harness) bundle plugin that connects locally signed-in Trae models (**
|
|
27
|
+
A [DeepSeek Harness (DSH)](https://github.com/deepseek-ai/deepseek-harness) bundle plugin that connects locally signed-in Trae models (**CN, enterprise, and international installs**) to the DSH model picker. Trae generates structured tool calls while DSH executes its own local tools, with a usage overview (Work/general credits on CN, tenant allowance on enterprise, subscription status on international), daily check-in claiming, and a model-management panel. **The CN, enterprise, and international sides are three parallel providers (`trae` / `trae-enterprise` / `trae-global`) that can be used at the same time**; the settings card separates them with tabs for convenient management.
|
|
28
28
|
|
|
29
29
|
**Runs on macOS, Windows, and Linux**: CI runs the full typecheck / test / build matrix on `ubuntu-latest` and `windows-latest`, and Windows gets purpose-built handling for directory probing, app version headers, and lock behavior — see [Windows notes](#windows-notes).
|
|
30
30
|
|
|
@@ -32,9 +32,10 @@ A [DeepSeek Harness (DSH)](https://github.com/deepseek-ai/deepseek-harness) bund
|
|
|
32
32
|
|
|
33
33
|
## Features
|
|
34
34
|
|
|
35
|
-
- **
|
|
36
|
-
- **
|
|
37
|
-
- **
|
|
35
|
+
- **Three parallel providers** — the CN side registers as the `trae` provider (e.g. `DeepSeek-V4-Flash`, `DeepSeek-V4-Pro`), the enterprise side as `trae-enterprise`, and the international side as `trae-global` (the Gemini/GPT/MiniMax roster); **all three rosters appear in the DSH model picker simultaneously**: different sessions can each pick a side without interfering.
|
|
36
|
+
- **Enterprise is a separate billing channel, not an alias for CN** — the same CN credential, when it belongs to a `tob_online` tenant, is served by **two** gateways: the consumer pool (billed against personal credits) and the tenant pool (billed against the enterprise allowance). Same model, two payers, so **you** choose who pays; the plugin never guesses. `trae` never touches the enterprise gateway, and `trae-enterprise` **never falls back** — a refusal is reported as a refusal instead of quietly re-running on personal credits. Enterprise is **off by default**: a personal-only account cannot use the tenant pool, so shipping it enabled would mean handing everyone a provider that fails on first use.
|
|
37
|
+
- **Any panel can be switched off on its own** — each tab carries its own checkbox (CN and international checked by default, enterprise not): unchecking **withdraws that provider from the DSH model picker entirely** (not merely hiding the tab) and stops all of its requests; checking it again restores it with the account, directory, picks, and context budgets intact. If you never use the international side, just uncheck it.
|
|
38
|
+
- **Tabbed settings card** — the card's top carries a "Domestic / Enterprise / Global" tab bar; each tab holds its own account picker, usage overview, and model management. Account, directory, selection, and unsaved drafts are fully isolated per tab — switching accounts or refreshing models on one tab never touches the other side's runtime catalog or sessions. CN and enterprise share one CN credential pool but keep **separate account bindings and model picks**: the two rosters differ (`DeepSeek-V4.1-Flash` is listed only on the enterprise pool), so picks never overwrite each other.
|
|
38
39
|
- **Multiplier in the model name** — model names show the credit multiplier in Trae's own menu format (e.g. `GLM-5.2 · x0.79`), updated with each directory refresh.
|
|
39
40
|
- **DSH local tool loop** — gets pending structured `tool_calls` from Trae `llm_utils_chat`, lets DSH execute its own local tools, then returns tool results to the model.
|
|
40
41
|
- **Dual-region detection (CN / international)** — detects local sign-ins across Trae CN, TRAE SOLO CN, Trae, and TRAE SOLO installs. The region is derived from the credential's own `userRegion` claim (host suffix and edition label as fallbacks), with no manual switch.
|
|
@@ -51,7 +52,7 @@ A [DeepSeek Harness (DSH)](https://github.com/deepseek-ai/deepseek-harness) bund
|
|
|
51
52
|
|
|
52
53
|
<img src="docs/assets/dsh-connect-trae-composer-credits.png" width="536" alt="Trae credits panel: a table of accounts with their general balance, and the composer readout below" />
|
|
53
54
|
|
|
54
|
-
**Where that readout sits is a choice** (learned from the sibling `dsh-connect-workbuddy` issue #62). The default is the **composer toolbar** (the position described above); if another plugin occupies it and the readout does not appear, move it **below the input box** — the row carrying the round / step / token statistics, where the readout is APPENDED after the shipped figures rather than replacing them. The seat is set **per
|
|
55
|
+
**Where that readout sits is a choice** (learned from the sibling `dsh-connect-workbuddy` issue #62). The default is the **composer toolbar** (the position described above); if another plugin occupies it and the readout does not appear, move it **below the input box** — the row carrying the round / step / token statistics, where the readout is APPENDED after the shipped figures rather than replacing them. The seat is set **per panel** (all three are stored separately), in the card's settings block next to the "show credits in the composer row" checkbox. Why a second seat exists at all: the composer toolbar is a **shared list slot** that the shell's own controls and every other plugin register into, and a shared slot **cannot promise that every occupant is visible** — the report behind that issue is a readout that vanished entirely once a third-party plugin was installed (this plugin has been squeezed out of a shared row once before too, down to a clipped "Tr" at the sidebar foot).
|
|
55
56
|
|
|
56
57
|
- **Secure loopback shim** — one random port + in-process random secret per region; the real Trae token is never handed to pi-ai.
|
|
57
58
|
|
|
@@ -62,13 +63,18 @@ DSH PiAiAdapter (one stack per provider)
|
|
|
62
63
|
-> secure loopback shim (one random port + in-process random secret per region)
|
|
63
64
|
-> TraeSoloBridge
|
|
64
65
|
-> CN: https://trae-api-cn.mchost.guru/api/agent/v3/llm_utils_chat
|
|
66
|
+
-> Enterprise: https://console.enterprise.trae.cn/api/agent/v3/llm_utils_chat
|
|
65
67
|
-> Global: https://coresg-normal.trae.ai/api/agent/v3/llm_utils_chat
|
|
66
68
|
-> Trae SSE / pending function_call
|
|
67
69
|
-> OpenAI SSE tool_calls
|
|
68
70
|
-> DSH executes local tools and returns their results
|
|
69
71
|
```
|
|
70
72
|
|
|
71
|
-
|
|
73
|
+
Each panel owns a complete runtime stack — credential store, model catalog, wire map, upstream clients, loopback shim, adapter — with visibility filtered by the credential's own region claim, so **accounts from several regions can be signed in and used by different sessions at the same time**.
|
|
74
|
+
|
|
75
|
+
**A panel is not a region.** `cn` and `ai` happen to line up with the two regions, but the enterprise pool shares the `cn` credentials while billing a different account and serving a different roster — it needs its own switch, its own account binding, and its own model picks. That is exactly what a "panel" is. Keeping panel and region as two concepts lets `enterprise` ride the same settings pipeline with no change to the stored shape: it is just another slot in the `regions` map.
|
|
76
|
+
|
|
77
|
+
The CN region therefore publishes two providers side by side, and **the route is fixed when the provider's client is built** — there is no "guess once per call". The shim exposes one bearer route per provider and dispatches by bearer; an unknown token gets a 401 rather than falling back to the first route. The enterprise gateway requires a `session_id` on every call while the consumer gateway rejects a body carrying one, so it is added only on that route.
|
|
72
78
|
|
|
73
79
|
Usage overview hits the read-only `https://api.trae.cn/trae/api/v2/pay/*` and `/trae/api/v2/ug/*` endpoints (international accounts read their own gateway's subscription status); the daily check-in claim is the one write among them, going to `POST /trae/api/v2/ug/checkin_credits/claim` with this installation's device id (`x-device-id`, the same identity the chat path sends). That device id is also what Trae keys the "one check-in per device per day" rule on, so switching accounts does not reset the day's slot. Refreshed tokens are kept per region in `$DSH_HOME/.trae-auth.cn.json` and `$DSH_HOME/.trae-auth.ai.json` (two simultaneously signed-in accounts never overwrite each other; the legacy single file `.trae-auth.json` is still read as a migration source).
|
|
74
80
|
|
|
@@ -138,7 +144,7 @@ Restart the DSH process after install/update/uninstall.
|
|
|
138
144
|
## DSH version compatibility
|
|
139
145
|
|
|
140
146
|
**Requires DSH 0.1.7-rc.1 and up** (since 2.3.0 the plugin no longer targets hosts older than 0.1.7; the peer dependency ranges are narrowed accordingly).
|
|
141
|
-
**The peer upper bound is `<0.3.0-0`, so both the 0.1.7 and the 0.2 line are supported.**
|
|
147
|
+
**The peer upper bound is `<0.3.0-0`, so both the 0.1.7 and the 0.2 line are supported (including 0.2.1-rc.2, verified).**
|
|
142
148
|
|
|
143
149
|
### Both pi-ai context generations are supported (since 3.4.2)
|
|
144
150
|
|
|
@@ -161,6 +167,17 @@ The boundary is **0.86**: `dist/utils/transcript.js`, `normalizeContext`, the es
|
|
|
161
167
|
|
|
162
168
|
The 0.2.0 line breaks **no** contract this plugin consumes — a symbol-by-symbol check confirmed every API it imports is unchanged ([full 0.2.0-rc.1 impact check](https://github.com/dingminhua/dsh-connect-trae/blob/main/docs/DSH_0.2.0_RC1_IMPACT_CHECK.md)). But since 0.1.7 DSH enforces a **bundle-level peer gate**: a bundle whose peers are unsatisfied is skipped **whole**, with one line on stderr and nothing in the UI — the plugin simply disappears.
|
|
163
169
|
|
|
170
|
+
### DSH 0.2.1 line (pi-ai 1.1.0) sync
|
|
171
|
+
|
|
172
|
+
The `0.2.1-rc.1` host moved `@earendil-works/pi-ai` from `^0.85.1` to **`^1.1.0`** (unchanged through `0.2.1-rc.2`) — the only change on the 0.2 line with real behavioural impact. Three conclusions:
|
|
173
|
+
|
|
174
|
+
1. **The request body did not regress (measured, not inferred).** The 1.1.0 api reads the prompt **only** from a transcript system message and never touches top-level `systemPrompt` / `tools`, while `dsh-llm-pi-ai`'s `piContext()` still emits the legacy envelope. The bidirectional adapter this plugin has shipped since 3.4.2 covers exactly that: feeding the real host envelope through real `1.1.0` with a local SSE capture yields `roles: ["system","user"]`, an intact system text and `tools: 1`; **without the adapter it degenerates to `roles: ["user"]`, system `null`, `tools: 0`** — with no error. That contrast is pinned as a wire-level matrix in `tests/pi-ai-context.spec.ts`.
|
|
175
|
+
2. **Types were fixed.** 1.1.0 changed `ProviderStreams`' second parameter to a **branded** `TranscriptContext` (a `unique symbol` only `normalizeContext()` can produce). The adapter casts once at that single boundary (`withContextAdaptation` in `src/adapter.ts`) and documents why the brand cannot be obtained honestly there.
|
|
176
|
+
3. **The peer range needed no change.** DSH evaluates with `semver.satisfies(runtime, range, { includePrerelease: true })` and checks only the `@deepseek-ai/dsh*` namespace, so `>=0.1.7-rc.1 <0.3.0-0` already admits both `0.2.1-rc.1` and `0.2.1-rc.2` (verified). Note the prerelease cliff only exists under **default** options — it is not this plugin's situation.
|
|
177
|
+
|
|
178
|
+
The dev tree pins `@earendil-works/pi-ai` at exactly **1.1.0** (the version the host actually bundles) rather than `^1.1.0`, so local typecheck and tests run against the same contract users do; the `schemastery` override moved to `3.18.5` (`dsh-llm-pi-ai@0.2.1-rc.2` declares `~3.18.5`).
|
|
179
|
+
|
|
180
|
+
|
|
164
181
|
### Why the upper bound is not `<0.2.0`
|
|
165
182
|
|
|
166
183
|
2.3.1 wrote `<0.2.0-0`, meaning "not the 0.2.0 release yet". That spelling is **wrong**: in SemVer `0.2.0-rc.1 < 0.2.0-0`, so it excluded the entire 0.2.0 **prerelease** line, and the plugin went dead the moment a user installed the first 0.2.0 prerelease.
|
package/README.md
CHANGED
|
@@ -24,7 +24,7 @@
|
|
|
24
24
|
<a href="https://dshfind.com/plugins/dingminhua/dsh-connect-trae"><img src="https://dshfind.com/api/badge/dingminhua/dsh-connect-trae" alt="dshfind plugin"></a>
|
|
25
25
|
</p>
|
|
26
26
|
|
|
27
|
-
一个独立的 [DeepSeek Harness (DSH)](https://github.com/deepseek-ai/deepseek-harness) bundle 插件。它把本机已登录的 Trae
|
|
27
|
+
一个独立的 [DeepSeek Harness (DSH)](https://github.com/deepseek-ai/deepseek-harness) bundle 插件。它把本机已登录的 Trae 账号(**国内版、企业版与国际版均支持**)接到 DSH 的模型选择器:模型负责生成结构化工具调用,`bash` / `read` / `write` / `edit` 等工具由 DSH 本地执行;同时提供用量概览(国内版 Work/通用积分、企业版租户额度、国际版订阅状态)、每日签到领取与模型管理界面。**国内版、企业版与国际版是三个并行的供应商(`trae` / `trae-enterprise` / `trae-global`),可同时使用**;插件设置卡片以 tab 区分三者,方便统一管理。
|
|
28
28
|
|
|
29
29
|
**支持 macOS、Windows 与 Linux**:CI 在 `ubuntu-latest` 与 `windows-latest` 上跑完整 typecheck / 测试 / 构建;Windows 侧的目录探测、应用版本头与锁行为均有针对性处理,详见 [Windows 说明](#windows-说明)。
|
|
30
30
|
|
|
@@ -32,17 +32,18 @@
|
|
|
32
32
|
|
|
33
33
|
## 功能特性
|
|
34
34
|
|
|
35
|
-
-
|
|
36
|
-
-
|
|
37
|
-
-
|
|
35
|
+
- **三供应商并行接入** —— 国内版注册为 DSH 的 `trae` provider(`DeepSeek-V4-Flash`、`DeepSeek-V4-Pro` 等),企业版注册为 `trae-enterprise`,国际版注册为 `trae-global`(Gemini / GPT / MiniMax 阵容),**三边模型同时出现在 DSH 模型选择器里**:不同会话可以各选一边,互不干扰。
|
|
36
|
+
- **企业版是独立计费通道,不是国内版的别名** —— 同一张 CN 凭据若属于 `tob_online` 租户,会被**两个**网关同时服务:消费池(扣个人积分)与租户池(扣企业额度)。同一模型、两种付费方,所以「谁付钱」由你显式选,插件不替你猜。`trae` 永不碰企业网关;`trae-enterprise` **不回落**,被拒绝就如实报错,不会悄悄改用个人额度重跑。企业版**默认关闭**——纯个人账号用不了企业池,默认放开等于塞一条一用就失败的 provider。
|
|
37
|
+
- **可单独关闭任一面板** —— 三个 tab 各带一个勾选(国内版与国际版默认勾选,企业版默认不勾):取消勾选即把该面板的供应商**整个从 DSH 模型选择器撤掉**(不是只藏起 tab),并且不再发起任何请求;重新勾选即恢复,账号、目录、勾选与上下文预算全部保留。用不到国际版就把国际版关掉即可。
|
|
38
|
+
- **插件卡片 tab 切换** —— 设置卡片顶部为「国内版 / 企业版 / 国际版」三个 tab,各含独立的账号选择、用量概览与模型管理;每个 tab 的账号、目录、勾选与未保存草稿完全隔离——在一个 tab 里切账号或刷新模型,不会触碰另一边的运行时目录与会话。国内版与企业版共用同一份 CN 凭据池,但**各有各的账号绑定与模型勾选**:两个池的名录并不相同(`DeepSeek-V4.1-Flash` 只有企业池列),所以勾选互不覆盖。
|
|
38
39
|
- **倍率内嵌模型名** —— 模型名称按 Trae 自身菜单的格式显示积分倍率(如 `GLM-5.2 · x0.79`),倍率随目录刷新更新。
|
|
39
40
|
- **DSH 本地工具循环** —— 通过 Trae `llm_utils_chat` 获取待执行的结构化 `tool_calls`,交由 DSH 自带的本地工具执行,再将工具结果回传模型。
|
|
40
41
|
- **国内国际双区域自动识别** —— 自动发现 Trae CN / TRAE SOLO CN / Trae / TRAE SOLO 四个本地安装的登录账号;区域由凭证自带的 `userRegion` 声明自动判定(host 后缀与 edition 标签兜底),无需手动指定。
|
|
41
|
-
-
|
|
42
|
+
- **目录与勾选按面板隔离** —— 三个面板各一套模型目录、勾选、图片开关与上下文预算,各自读各自的槽位。名录从**该面板所钉的那条网关**读取——原本钉在企业池的客户端去读消费池名录,会永远发现不了自己池的独占模型。
|
|
42
43
|
- **识图能力跟随 Trae 自身的标注** —— Trae 把某个模型标为 `multimodal` 时,插件直接按多模态对外声明,无需你在卡片上逐一手勾(issue #16)。判据是「**你手动勾选的 ∪ Trae 标注多模态的**」:Trae 明确标 `false` 或未标注的模型保持纯文本,你可以照旧手动为它们打开图片输入。卡片上被自动开启的那一行显示为已勾选且只读,并说明原因。详见下方「图片输入(识图)」。
|
|
43
44
|
- **多账号切换** —— 支持重新读取 Token 列表并选择账号;Token 不写入 DSH 设置。**你的选择会被记住并长期生效**:插件不会因为某个账号额度用尽、或检测到另一个可用账号就自作主张替你切换(换账号意味着换人计费)。所以当绑定的账号额度耗尽时,卡片会**明确告诉你**,并把本机其他还有额度的账号连同其可用积分数列出来,由你一键切换——而不是让面板一直空着、也不自动把你切走。「刷新账号与 Token」每次都会回报结果(找到几个账号、当前仍绑定谁),不会再「点了没反应」。下拉里显示的是产品名(`Trae` / `TRAE SOLO` / 国际版),便于分辨凭据来自哪个安装。
|
|
44
45
|
- **跟随 Trae 当前登录的账号** —— 你在 Trae 桌面端**退出并换登录**后,卡片会检测到「插件绑定的账号」与「Trae 现在登录的账号」不一致,并给出一行提示与**一键切换**(复用账号下拉的同一次写入,不引入第二条切换路径)。想让插件**自动跟随**,可打开设置卡片里的「跟随 Trae 当前登录的账号」开关:此后每次配置生效都会把 `accounts.<region>` 重绑到 App 当前登录的账号。**该开关默认关闭**——已有配置保持原来的严格绑定,自动换绑意味着换人计费,必须由你主动勾选;未勾选时上面那行提示就是你的手动通道。(issue #29)
|
|
45
|
-
- **账号导入 / 导出** —— 不用再为了用第二个账号而把凭据手工写进默认路径、顶掉上一个。在卡片账号区的「导入 / 导出账号」里:**导出**勾选若干账号下载一份 JSON;**导入**选择文件后先看**脱敏预览**(只显示账号标识与「是否有 Token」,不含凭据本身)再勾选导入。文件格式与同族 `dsh-connect-workbuddy` **互通**,两边导出的文件可以互相导入。导入按账号去重(同一账号再导入即覆盖更新),**认不出所属区域或因缺 Token
|
|
46
|
+
- **账号导入 / 导出** —— 不用再为了用第二个账号而把凭据手工写进默认路径、顶掉上一个。在卡片账号区的「导入 / 导出账号」里:**导出**勾选若干账号下载一份 JSON;**导入**选择文件后先看**脱敏预览**(只显示账号标识与「是否有 Token」,不含凭据本身)再勾选导入。文件格式与同族 `dsh-connect-workbuddy` **互通**,两边导出的文件可以互相导入。导入按账号去重(同一账号再导入即覆盖更新),**认不出所属区域或因缺 Token 的记录会被跳过并计数**——国内版与国际版是两条并行计费通道,跨区导入会导致跨区计费,所以这里只认同能**正向识别**的区域(企业版共用 CN 凭据池,不构成第三条导入通道)。导出文件里是**有效 Token,请当作密码保管**。(issue #37)
|
|
46
47
|
- **只读用量与模型管理** —— 国内版查看 Work 积分与通用积分,国际版查看订阅/试用状态;刷新/启用 Trae 模型;只读查询不消耗额度。
|
|
47
48
|
- **积分临近到期会提醒** —— 剩余额度只回答「还有多少」,回答不了「**哪一笔先到期**」;提醒条按到期紧迫程度逐级加重(**7 天 → 24 小时 → 已过期**),写明金额、套餐数和最早到期时间,避免只盯总额时悄悄丢掉最先到期的额度。国内版在用量页与输入框积分面板两处都显示(国际版是订阅制,没有逐包到期数据)。
|
|
48
49
|
- **一键测试启用模型** —— 给**已启用**的每个模型发一条最小消息(一句 `ping`、不带工具),逐个告诉你能不能真的应答:**可用** / **需要更高档位**(Trae `1005`,你的套餐不覆盖)/ **上游不提供**(`4001`,SOLO 通道没有这个模型)/ **被限流**(`4011`,Trae 限了这条通道)/ **登录凭据被拒** / **本次未测出**。最后一项是一等公民:超时、断连、代理、5xx **一律不算「不可用」**——只有上游明确的拒绝才算负面结论。**这是插件里唯一消耗额度的操作**(签到改变的是账号状态,不消耗),只在你点击时运行,结果只留在当前会话里不写入设置。
|
|
@@ -53,7 +54,7 @@
|
|
|
53
54
|
|
|
54
55
|
<img src="docs/assets/dsh-connect-trae-composer-credits.png" width="536" alt="Trae credits panel: a table of accounts with their general balance, and the composer readout below" />
|
|
55
56
|
|
|
56
|
-
**读数显示在哪里可以选**(学自同族 `dsh-connect-workbuddy` issue #62)。默认在**输入框工具栏**(即上面说的位置);如果那里被别的插件占了、读数不显示,改成**输入框下方**——那是「轮次 / 步数 / token
|
|
57
|
+
**读数显示在哪里可以选**(学自同族 `dsh-connect-workbuddy` issue #62)。默认在**输入框工具栏**(即上面说的位置);如果那里被别的插件占了、读数不显示,改成**输入框下方**——那是「轮次 / 步数 / token」统计所在的那一行,读数是**追加**在官方统计之后,不会顶掉它们。位置**按面板分别设置**(三个面板各存各的),在卡片「设置」区紧挨「在输入框工具栏显示积分读数」那个勾选框。之所以要有第二个位置:输入框工具栏是**共享的 list 插槽**,外壳自己的控件和其他插件都注册在那里,而共享插槽**无法保证每个占用者都可见**——同族的报告者装了第三方插件后读数就整个消失了(本插件早年放在侧边栏底部时也被挤成过一个「Tr」的残片)。
|
|
57
58
|
|
|
58
59
|
- **安全 loopback shim** —— 每区域一个随机端口 + 进程内随机 secret,真实 Trae token 不交给 pi-ai。
|
|
59
60
|
|
|
@@ -64,13 +65,18 @@ DSH PiAiAdapter(每个 provider 一套)
|
|
|
64
65
|
-> 安全 loopback shim(每区域一个随机端口 + 进程内随机 secret)
|
|
65
66
|
-> TraeSoloBridge
|
|
66
67
|
-> 国内版 https://trae-api-cn.mchost.guru/api/agent/v3/llm_utils_chat
|
|
68
|
+
-> 企业版 https://console.enterprise.trae.cn/api/agent/v3/llm_utils_chat
|
|
67
69
|
-> 国际版 https://coresg-normal.trae.ai/api/agent/v3/llm_utils_chat
|
|
68
70
|
-> Trae SSE / pending function_call
|
|
69
71
|
-> OpenAI SSE tool_calls
|
|
70
72
|
-> DSH 本地执行工具并回传结果
|
|
71
73
|
```
|
|
72
74
|
|
|
73
|
-
|
|
75
|
+
每个面板各持一套完整的运行时栈——凭据 store、模型 catalog、wire 映射、上游客户端、回环 shim、adapter——按凭证自带的区域声明隔离可见账号,所以**多个区域的账号可以同时在线、同时被不同会话使用**。
|
|
76
|
+
|
|
77
|
+
**面板不是区域。** `cn` 与 `ai` 恰好与两个区域一一对应,但企业池共用 `cn` 凭据却计费到另一个账户、供另一份名录,它需要自己的开关、自己的账号绑定与自己的模型选择——那正是「面板」这个概念。把面板与区域分成两个概念,`enterprise` 就能用同一套设置管道处理,存储形状不变:它只是 `regions` 映射里的又一个槽位。
|
|
78
|
+
|
|
79
|
+
国内区因此并列发布两个 provider,**路由在构建 provider 的客户端时固定**,不存在「按调用猜一次」:shim 为每个 provider 提供一条 bearer 路由并按 bearer 分派,未知 token 直接 401,不会退回第一条路由。企业网关要求每次调用带 `session_id`,而消费网关会拒绝带它的请求体,所以只在该路由上加。
|
|
74
80
|
|
|
75
81
|
用量概览走 `https://api.trae.cn/trae/api/v2/pay/*` 与 `/trae/api/v2/ug/*` 只读接口(国际账号走其自有网关的订阅状态端点);每日签到领取是其中唯一的写操作,走 `POST /trae/api/v2/ug/checkin_credits/claim`,需要携带本机安装的设备号(`x-device-id`,与聊天通道同源)。该设备号也正是签到「每台设备每天一次」的判定依据,所以换账号不会重置当天名额。刷新得到的 token 按区域存放在 `$DSH_HOME/.trae-auth.cn.json` 与 `$DSH_HOME/.trae-auth.ai.json`(两个账号同时在线互不覆盖;旧的单文件 `.trae-auth.json` 作为迁移来源保留读取)。
|
|
76
82
|
|
|
@@ -96,7 +102,7 @@ DSH PiAiAdapter(每个 provider 一套)
|
|
|
96
102
|
|
|
97
103
|
## 模型覆盖范围
|
|
98
104
|
|
|
99
|
-
插件提供的是 Trae **SOLO 通道**的模型(`DeepSeek-V4-Flash-Official`、`DeepSeek-V4-Pro-Official`、`GLM-5.3`、`GLM-5.2`、`Kimi-K3`、`MiniMax-M3`、`Qwen3.8-Max`、`Doubao-Seed-*`
|
|
105
|
+
插件提供的是 Trae **SOLO 通道**的模型(`DeepSeek-V4-Flash-Official`、`DeepSeek-V4-Pro-Official`、`GLM-5.3`、`GLM-5.2`、`Kimi-K3`、`MiniMax-M3`、`Qwen3.8-Max`、`Doubao-Seed-*` 等),三个面板均走这条通道。企业池另有一份名录(例如 `DeepSeek-V4.1-Flash` 只有企业池列),所以两边勾选互不覆盖。
|
|
100
106
|
|
|
101
107
|
以下 3 个模型目前来自 **TraeCode(Trae IDE)通道**,尚未开放到 SOLO 通道:
|
|
102
108
|
|
|
@@ -150,7 +156,7 @@ npm install dsh-connect-trae
|
|
|
150
156
|
## DSH 版本兼容
|
|
151
157
|
|
|
152
158
|
**要求 DSH 0.1.7-rc.1 及以上**(2.3.0 起不再支持 0.1.7 之前的宿主;peer 依赖范围已按此收窄)。
|
|
153
|
-
**peer 上界为 `<0.3.0-0`:0.1.7 与 0.2
|
|
159
|
+
**peer 上界为 `<0.3.0-0`:0.1.7 与 0.2 两条线均受支持(含 0.2.1-rc.2,已实测)。**
|
|
154
160
|
|
|
155
161
|
### 同时支持 pi-ai 的两代上下文(3.4.2 起)
|
|
156
162
|
|
|
@@ -182,6 +188,30 @@ DSH 自己横跨 `@earendil-works/pi-ai` 的两代,而**本插件解析到哪
|
|
|
182
188
|
0.2.0 线对本插件**没有契约破坏**——逐符号核对确认插件消费的 API 全部未变([完整的 0.2.0-rc.1 影响面核对](https://github.com/dingminhua/dsh-connect-trae/blob/main/docs/DSH_0.2.0_RC1_IMPACT_CHECK.md))。但 0.1.7 起 DSH 有一道**bundle 级 peer 门禁**:
|
|
183
189
|
peer 范围不满足的 bundle 会被**整体跳过**,只往 stderr 写一行,界面上表现为「插件凭空消失」。
|
|
184
190
|
|
|
191
|
+
### DSH 0.2.1 线(pi-ai 1.1.0)同步结论
|
|
192
|
+
|
|
193
|
+
宿主 `0.2.1-rc.1` 把 `@earendil-works/pi-ai` 从 `^0.85.1` 抬到了 **`^1.1.0`**(`0.2.1-rc.2` 保持不变),这是 0.2 线里
|
|
194
|
+
唯一有实际行为影响的变化。三项结论:
|
|
195
|
+
|
|
196
|
+
1. **请求体没有丢东西(已实测)**。1.1.0 的 api **只**读 transcript 里的 system 消息,
|
|
197
|
+
顶层 `systemPrompt` / `tools` 完全不再读取;而 `dsh-llm-pi-ai` 的 `piContext()` 仍然产出
|
|
198
|
+
旧版信封。本插件 3.4.2 起就有的双向适配正好覆盖这一点——把真实宿主信封喂进真实
|
|
199
|
+
`1.1.0` + 本地 SSE 捕获线上请求体,得到 `roles: ["system","user"]`、system 文本完好、
|
|
200
|
+
`tools: 1`;**去掉适配则变成 `roles: ["user"]`、system `null`、`tools: 0`**(不报错)。
|
|
201
|
+
这条对照已固化为 `tests/pi-ai-context.spec.ts` 的线上请求体矩阵。
|
|
202
|
+
2. **类型面补齐**。1.1.0 把 `ProviderStreams` 的第二参改成带 `unique symbol` 品牌标记的
|
|
203
|
+
`TranscriptContext`,只有 `normalizeContext()` 能产出。适配层在这条边界上做一次显式转型
|
|
204
|
+
(`src/adapter.ts` 的 `withContextAdaptation`),并在两处调用点写明为何品牌在此处不可诚实获得。
|
|
205
|
+
3. **peer 范围无需改动**。DSH 用 `semver.satisfies(runtime, range, { includePrerelease: true })`
|
|
206
|
+
求值,且只校验 `@deepseek-ai/dsh*` 命名空间,因此 `>=0.1.7-rc.1 <0.3.0-0` 对 `0.2.1-rc.1` / `0.2.1-rc.2` 均已判通过
|
|
207
|
+
(已实测)。**注意**:预发布悬崖只在**默认选项**下成立——那是 `dsh-connect-workbuddy` 侧
|
|
208
|
+
调研文档所描述的困境,本插件不适用。
|
|
209
|
+
|
|
210
|
+
开发树的 `@earendil-works/pi-ai` 钉在 **1.1.0**(宿主实际随包的版本)而非 `^1.1.0`,
|
|
211
|
+
使本地 typecheck 与测试跑在与用户完全一致的契约上;`schemastery` 的 override 同步抬到
|
|
212
|
+
`3.18.5`(`dsh-llm-pi-ai@0.2.1-rc.2` 声明 `~3.18.5`)。
|
|
213
|
+
|
|
214
|
+
|
|
185
215
|
### peer 上界为什么不写 `<0.2.0`
|
|
186
216
|
|
|
187
217
|
2.3.1 曾写 `<0.2.0-0`,意图是「先不支持 0.2.0 正式版」。这个写法**是错的**:
|