dsh-xdpool 3.0.6 → 3.0.8

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 CHANGED
@@ -9,6 +9,12 @@
9
9
 
10
10
  ## 更新公告
11
11
 
12
+ **3.0.8** — 账号昵称与模型列表按渠道读取、优先账号开关、CodeArts 图片输入、登录签到提速。
13
+
14
+ - 修复账号池页整页错乱:账号卡回到详情列里,只在选中 WorkBuddy 国内版/国际版时显示
15
+ - 修复一键更新「更新了但版本号一直没变」:现在会同步 lockfile 和 node_modules,不再被 DSH 启动时装回旧版
16
+ - pi-ai 代际守卫修正宿主路径,mismatch / aligned / unknown 都会写进启动日志,切 xdpool 模型崩溃时不再毫无线索
17
+
12
18
  **3.0.6** — 账号卡重做。
13
19
 
14
20
  - 账号池页的账号卡重画成自包含的卡片:昵称、状态徽章(当前使用 / 已停用 / 冷却中)、令牌到期、积分、以及优先/停用/签到/移出池子一排按钮
@@ -285,6 +291,17 @@ xdpool:
285
291
  distribution: sticky
286
292
  ```
287
293
 
294
+ ## 开发文档
295
+
296
+ 给以后改代码的人(包括 AI)画的一幅地图,改功能前先看对应的文档,别靠猜:
297
+
298
+ - [文档地图](docs/MAP.md) —— 总索引,按「要改什么」找到该读哪份
299
+ - [技术栈与构建](docs/TECH-STACK.md) —— 依赖、构建产物、测试、发布、版本号
300
+ - [系统架构](docs/ARCHITECTURE.md) —— 数据流、两个池、启动顺序、持久化、定时任务
301
+ - [HTTP 接口](docs/API.md) —— 所有路由、请求/响应、副作用、来源校验
302
+ - [前端结构](docs/FRONTEND.md) —— 页面结构、组件、样式来源、界面坑
303
+ - [运维与故障定位](docs/OPERATIONS.md) —— 数据文件、日志、升级回滚、故障矩阵
304
+
288
305
  ## 架构
289
306
 
290
307
  - **宿主侧**(`src/`,跑在 DSH 主进程里)
@@ -300,6 +317,22 @@ xdpool:
300
317
  - **构建**
301
318
  `tsdown` 产出 `lib/index.js`(宿主入口)+ `lib/index.d.ts`(类型)+ `lib/bin.js`(CLI)+ `lib/client.js`(CJS,用 `window.__ModuleLoader__.load` 包起来的浏览器 bundle)。四个产物都随仓库提交,所以安装时不需要任何构建脚本。
302
319
 
320
+ ## π-ai 代际对齐(重要)
321
+
322
+ 本插件在宿主里用 pi-ai 组装 provider,宿主适配器用**它自己**那份 pi-ai 消费事件流。
323
+ 两份大版本不一致时(典型:插件侧 0.82.x、宿主侧 1.5.x),第一次请求就会崩在适配器接缝,
324
+ 宿主把它归成不可重试的 `PI_AI_ERROR` —— 现象是「切到 xdpool 系模型,第一条就没内容」。
325
+
326
+ 如何确认:重启 DSH 后看 `~/.dsh/.xdpool/startup.log`,会写 `pi-ai generation: aligned at …`
327
+ 或 `mismatch`。一旦看到 mismatch,在 profile 的 `package.json` 里钉到宿主代:
328
+
329
+ ```json
330
+ { "pnpm": { "overrides": { "@earendil-works/pi-ai": "<宿主版本>" } } }
331
+ ```
332
+
333
+ 然后重装依赖并重启。日志里写 `unknown` 表示两侧只读到一份(比如宿主把它打进了 bundle),
334
+ 插件会继续工作,但代际无法自动核对。
335
+
303
336
  ## 已知限制
304
337
 
305
338
  - **WorkBuddy 主账号的登录仍走桌面 App**:XD Pool 可以为插件自己的二十多家登录渠道发起登录,但 WorkBuddy 本体的 token 由桌面 App 的腾讯 SSO 铸造并和设备绑定,池不会替你登录 WorkBuddy。加号 = 在桌面 App 里登录 / 切换,XD Pool 自动吸收。
package/cordis.patch.yml CHANGED
@@ -1,24 +1,24 @@
1
- # Register the XD Pool provider. Discovery is read-only: the plugin reuses the
2
- # WorkBuddy desktop app's own sign-in files and never starts a separate OAuth
3
- # flow. Requests rotate across every discovered account.
4
- - insert:
5
- - id: llm-xdpool
6
- name: dsh-xdpool
7
- #
8
- # billion-context is gone from this plugin, and so is the row that used to sit
9
- # here (`billion-context-xdpool`, kept disabled).
10
- #
11
- # 2.0.0 inserted that row so a profile without the compressor would get one for
12
- # free. Measured against a profile that had ALREADY installed billion-context —
13
- # the normal state for anyone using it, since `bili-native` comes from that
14
- # plugin's own `dsh.bundle.patch.yml` — the host did not disable the duplicate
15
- # and did not resolve it to a no-op: it ran the fiber to `failed`, because the
16
- # plugin registers a cordis service under its own name and a second registration
17
- # is refused outright (`service "…" has been registered at <…>`). Every user who
18
- # had installed it got a permanently failed entry, unexplained, pointing at us.
19
- #
20
- # The follow-up kept the row, disabled, "for addressability". That was the wrong
21
- # trade: it left a name in this file for a feature the plugin no longer has, and
22
- # the page that read it (`billion-context`) is deleted too. Installing the
23
- # compressor is its own decision, made by installing it — which is the
24
- # arrangement that always worked.
1
+ # Register the XD Pool provider. Discovery is read-only: the plugin reuses the
2
+ # WorkBuddy desktop app's own sign-in files and never starts a separate OAuth
3
+ # flow. Requests rotate across every discovered account.
4
+ - insert:
5
+ - id: llm-xdpool
6
+ name: dsh-xdpool
7
+ #
8
+ # billion-context is gone from this plugin, and so is the row that used to sit
9
+ # here (`billion-context-xdpool`, kept disabled).
10
+ #
11
+ # 2.0.0 inserted that row so a profile without the compressor would get one for
12
+ # free. Measured against a profile that had ALREADY installed billion-context —
13
+ # the normal state for anyone using it, since `bili-native` comes from that
14
+ # plugin's own `dsh.bundle.patch.yml` — the host did not disable the duplicate
15
+ # and did not resolve it to a no-op: it ran the fiber to `failed`, because the
16
+ # plugin registers a cordis service under its own name and a second registration
17
+ # is refused outright (`service "…" has been registered at <…>`). Every user who
18
+ # had installed it got a permanently failed entry, unexplained, pointing at us.
19
+ #
20
+ # The follow-up kept the row, disabled, "for addressability". That was the wrong
21
+ # trade: it left a name in this file for a feature the plugin no longer has, and
22
+ # the page that read it (`billion-context`) is deleted too. Installing the
23
+ # compressor is its own decision, made by installing it — which is the
24
+ # arrangement that always worked.