@eddyskywalker/dsh-chatgpt-subscription 0.67.0 → 0.68.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.
Files changed (51) hide show
  1. package/CHANGELOG.md +24 -0
  2. package/README.md +1 -1
  3. package/lib/client.js +75 -632
  4. package/lib/client.js.map +1 -1
  5. package/lib/index.js +183 -1872
  6. package/lib/types/client/cline-pass/ClinePassSection.d.ts +1 -1
  7. package/lib/types/client/cline-pass/ClinePassSection.d.ts.map +1 -1
  8. package/lib/types/client/cline-pass/api.d.ts +2 -36
  9. package/lib/types/client/cline-pass/api.d.ts.map +1 -1
  10. package/lib/types/client/cline-pass/locales.d.ts +30 -264
  11. package/lib/types/client/cline-pass/locales.d.ts.map +1 -1
  12. package/lib/types/client/cline-pass/styles.d.ts +2 -2
  13. package/lib/types/client/cline-pass/styles.d.ts.map +1 -1
  14. package/lib/types/client/locales-ru/cline-pass.d.ts.map +1 -1
  15. package/lib/types/client/opendesign/OpenDesignSection.d.ts.map +1 -1
  16. package/lib/types/compat.d.ts +1 -1
  17. package/lib/types/host/antigravity/adapter.d.ts.map +1 -1
  18. package/lib/types/host/antigravity/client-version.d.ts.map +1 -1
  19. package/lib/types/host/antigravity/types.d.ts +5 -5
  20. package/lib/types/host/antigravity/types.d.ts.map +1 -1
  21. package/lib/types/host/cline-pass/adapter.d.ts +3 -4
  22. package/lib/types/host/cline-pass/adapter.d.ts.map +1 -1
  23. package/lib/types/host/cline-pass/client.d.ts +0 -22
  24. package/lib/types/host/cline-pass/client.d.ts.map +1 -1
  25. package/lib/types/host/cline-pass/engine.d.ts +9 -147
  26. package/lib/types/host/cline-pass/engine.d.ts.map +1 -1
  27. package/lib/types/host/cline-pass/line.d.ts.map +1 -1
  28. package/lib/types/host/cline-pass/mapper.d.ts +1 -3
  29. package/lib/types/host/cline-pass/mapper.d.ts.map +1 -1
  30. package/lib/types/host/cline-pass/protocol.d.ts +1 -161
  31. package/lib/types/host/cline-pass/protocol.d.ts.map +1 -1
  32. package/lib/types/host/cline-pass/routes.d.ts +2 -7
  33. package/lib/types/host/cline-pass/routes.d.ts.map +1 -1
  34. package/lib/types/host/cline-pass/store.d.ts +11 -35
  35. package/lib/types/host/cline-pass/store.d.ts.map +1 -1
  36. package/lib/types/host/cline-pass/token-store.d.ts +1 -10
  37. package/lib/types/host/cline-pass/token-store.d.ts.map +1 -1
  38. package/lib/types/host/cline-pass/tools.d.ts.map +1 -1
  39. package/lib/types/host/cline-pass/types.d.ts +7 -76
  40. package/lib/types/host/cline-pass/types.d.ts.map +1 -1
  41. package/lib/types/host/opendesign/adapter.d.ts.map +1 -1
  42. package/lib/types/host/opendesign/mapper.d.ts +13 -1
  43. package/lib/types/host/opendesign/mapper.d.ts.map +1 -1
  44. package/lib/types/host/opendesign/routes.d.ts.map +1 -1
  45. package/lib/types/index.d.ts +4 -4
  46. package/lib/types/index.d.ts.map +1 -1
  47. package/lib/types/shared/cline-pass-contracts.d.ts +6 -92
  48. package/lib/types/shared/cline-pass-contracts.d.ts.map +1 -1
  49. package/lib/types/shared/opendesign-contracts.d.ts +1 -1
  50. package/lib/types/shared/opendesign-contracts.d.ts.map +1 -1
  51. package/package.json +1 -1
package/CHANGELOG.md CHANGED
@@ -2,6 +2,30 @@
2
2
 
3
3
  ## Unreleased
4
4
 
5
+ ## 0.68.1 - 2026-11-11
6
+
7
+ - **[opendesign / 号池] 套餐不含某个模型不再判成密钥失效,并补回清除失效标记的入口**
8
+ - **现象**:Go 档账号用 `deepseek-v4.1-flash` 偶发失败后,卡片把该账号标成「登录已失效 / 需替换 Key」,而同一把 Key 打同一个模型在下一次请求就成功;用户反复「重新登录」也只能换一个新账号,旧行一直是红的。
9
+ - **根因**:`isAuthenticationError` 把 **401 与 403 一律**判成 `AUTH`,`streamErrorCode` 因此把网关的 `tier_request_kind_not_entitled`(`membership tier "go" is not entitled to use this model for chat_completions`)与 `tier_model_not_entitled`(`Go/Plus 用户不允许访问最贵的模型`)也归到 `AUTH`,`standDown` 再写成 `authStatus: "invalid"`。这两种拒绝说的是**套餐与模型**,同一把 Key 对其余模型照常可用;而 `invalid` 只由 `clearAuthFailed` 解除,本线路的账号路由又没有该 action(实测 `POST {"action":"relogin"}` 返回 `Unsupported account action.`),于是正常账号被永久挂起。
10
+ - **改法**:`mapper.ts` 新增 `isModelEntitlementDenial`,`streamErrorCode` 在 `AUTH` 之前把它归为 `PROVIDER_ERROR`;`isAuthenticationError` 只在 401,或 403 的正文点名了密钥(`invalid_api_key` / `key was revoked` 等)时才返回真。`adapter.ts` 对权益类拒绝改成「跳过本账号、换下一个账号」,**不落任何标记**——号池里可能有更高档位的 Key,而当前账号对其余模型仍然有效。`routes.ts` 新增 `relogin`(清标记、不删账号),卡片「重新登录」改为先清标记再走登录,与同仓其余线路一致。
11
+ - **刻意不做**:不改 `PROVIDER_ERROR` 的重试语义、不动 `QUOTA` 判定,也不把 5xx 拉进这次分类——`database_unavailable` 已经是 `SERVER`,本来就不会挂起账号。
12
+ - **回归**:`test/opendesign-mapper.test.ts` 覆盖两种 `tier_*` 403、不带凭证线索的 403(现在是 `HTTP_403`,此前是 `AUTH`)、带凭证线索的 403 与 401;`test/opendesign-adapter.test.ts` 覆盖承重的一步——权益类 403 换到下一个账号、且该账号既不落 `invalid` 也不进冷却(合并后补齐,并做过反向对照:短路 `adapter.ts` 那条分支即失败);`test/opendesign-routes.test.ts` 覆盖 `relogin` 清标记后账号仍在、别名保留、`usable` 恢复。`npm run typecheck` 通过;四个 opendesign 测试文件 171 例全通过;全量 Vitest 为 384 文件通过 / 2 跳过,6991 例通过 / 9 跳过,0 失败。
13
+
14
+ ## 0.68.0 - 2026-11-11
15
+
16
+ - **[cline-pass / 路由] 移除客户端上游钉选,模型路由完全交还 Cline 网关**
17
+ - Cline 对客户端自带的 `providerOptions` 模型路由直接返回 HTTP 403,钉选子系统因此无法作为可用能力存在,也不再保留「失败后重试」的兼容路径:删除上游钉选存储与请求注入、`strict` / `preferred` 钉选模式、渠道排除与 `gateway.has` 能力过滤、逐渠道判定与渠道编辑器。
18
+ - 移除 `/models/pin`、`/models/reset`、`/models/probe`、`/models/validate` 四个宿主路由,以及 `cline_pass_pin`、`cline_pass_probe`、`cline_pass_validate` 三个管理工具(可选工具由 8 个收缩为 5 个)与对应的公开 DTO / 导出面;被移除的路由现在返回 404。
19
+ - 普通模型测试与线上会话一律只走 Cline 自动路由:请求体既不含 `provider`,也不含 `providerOptions`,即使旧设置里仍残留钉选数据也不会再被读取或注入;旧 `pinSpelling` 键不再持久化。
20
+ - 响应侧的管线、实际服务渠道、一手指纹与匿名贡献者路由(`openai-compatible-private`,无 ZDR 保障)仍作为只读事实回读并在卡片上告警;账号池轮换、AUTH / QUOTA 退避、传输重试、空回合重放、模型目录、配额与请求历史语义不变。
21
+ - 旧配置迁移只保留 `pins` 键用于「在用目录行」提升判定,其路由取值被忽略;升级后卡片的渠道编辑器消失,属于预期内的功能移除。
22
+ - **验证**:`npm run typecheck` 通过;全量 Vitest 为 384 个文件通过 / 2 个跳过(6988 例通过 / 9 例跳过 / 0 失败);`npm run build` 通过(PR 作者在 v0.67.0 基线上验证,合并后本仓库复跑 typecheck 与全量测试同样通过)。
23
+
24
+ - **[antigravity] 新增 Gemini 4 Carbon、同步官方 2.31.0 客户端标识并对齐上游模型目录(2026-11-11 线上实测)**
25
+ - **客户端版本与构建号对齐**:从官方最新更新清单发布的 `2.31.0` 归档(`language_server` 构建元数据)核实并同步 `DEFAULT_ANTIGRAVITY_VERSION = '2.31.0'`、`DEFAULT_ANTIGRAVITY_CL = '1017595969'` 与 `HUB_RELEASE_CHANGELISTS['2.31.0']`,确保首轮请求与运行期读取到 `2.31.0` 清单后的 `User-Agent` 均完整携带对应 `cl=1017595969`。
26
+ - **新增 Gemini 4 Carbon 与关闭思考回退**:对齐上游 `/v1internal:fetchAvailableModels`(`defaultAgentModelId: "gemini-4-carbon-medium"`),在可选模型目录首位新增 `gemini-4-carbon`(`Gemini 4 Carbon`,上下文窗口 `1048576`,最大输出 `262144`,支持文本与图片输入及 `low` / `medium` / `high` 三档思考,归属 `gemini` 配额组);线上实测裸 `gemini-4-carbon` 与 `gemini-4-carbon-tiered` 均返回 `404 NOT_FOUND`,路由一对一映射至 `gemini-4-carbon-low` / `gemini-4-carbon-medium` / `gemini-4-carbon-high`(默认 `gemini-4-carbon-medium`),并修正适配器在显式收到 `off` / `none` 思考档位时命中 `ROUTING[model].off`(`gemini-4-carbon-low`)且附带 `includeThoughts: false`。
27
+ - **清理已下线旧模型与同步静态限额**:移除上游目录已下线且调用返回 `404` / 下线提示的 4 个旧 Gemini 3.x 模型(`gemini-3.7-flash`、`gemini-3.6-flash`、`gemini-3.5-flash`、`gemini-3.1-pro`);同步上游目录公布的静态兜底限额:Claude Opus 5.5 / Sonnet 5.5 更新为 `contextWindow: 1000000`、`maxTokens: 128000`,`gpt-oss-120b` 更新为 `contextWindow: 131072`、`maxTokens: 32768`。
28
+
5
29
  ## 0.67.0 - 2026-11-10
6
30
 
7
31
  - **[dispatch / Code Mode] 统一 K31P 通用工具入口并切断进展更新空转**
package/README.md CHANGED
@@ -147,7 +147,7 @@ npx @deepseek-ai/dsh plugin --profile web add "link:C:\absolute\path\to\dsh-chat
147
147
  | `minimax_generate_video` | `minimax-code` 会话 | 调用 MiniMax-H3 / H3-Max / Hailuo-2.3 生成视频(支持首尾帧与参考图/视频/音频)并下载至工作区 |
148
148
  | `minimax_understand_video` | `minimax-code` 会话 | 上传或内联本地视频并调用 MiniMax 视频理解接口回答问题 |
149
149
  | `enter_plan_mode` / `leave_plan_mode` | `dispatch` 预设会话 | 调度模式下在澄清访谈收敛后进入只读计划模式,或显式放弃规划 |
150
- | `cline_pass_*`(共 8 个) | 可选开启(默认不注册) | Cline Pass 状态、目录、渠道探测、逐渠道校验、钉选与请求历史管理工具 |
150
+ | `cline_pass_*`(共 5 个) | 可选开启(默认不注册) | Cline Pass 状态、目录、普通模型测试、账号与请求历史管理工具 |
151
151
 
152
152
  ### Web 客户端与看板扩展
153
153