Skip to content
Open
19 changes: 19 additions & 0 deletions docs/clients.md
Original file line number Diff line number Diff line change
Expand Up @@ -248,6 +248,25 @@ surfaces are opted into separately through `dshGo` slots (dsh-Go,
`preset-dsh-go-companion` and `preset-dsh-go-companion-full`, whose nested
`compaction-basic` rows the #4147 structural walk is expected to cover.

**Coexistence with dsh Developer Tools / experimental inspector (#5148):** the
native plugin routes model traffic through a guarded `globalThis.fetch`
accessor — the #1158 self-heal that re-chains any third-party fetch install as
downstream so routing never silently leaves the proxy. dsh's
`@deepseek-ai/dsh-experimental-inspector` (enabled by Developer Tools) refuses
to observe an accessor and throws
`inspector: globalThis.fetch is an accessor and cannot be observed safely`, so
that one entry fails to activate while the rest of `dsh web` runs fine. The
profile loads bili before the inspector, so this is a load-order + mechanism
clash, not a bili fault — and switching the accessor off
(`BILI_RECLAIM_FETCH_PATCH=0`) would reintroduce the #1158 silent un-routing, so
it stays on by default. Workarounds, least impact first: ① set the inspector
entry's `captureFetch: false` in your profile's `cordis.patch.yml` (rest of the
inspector stays active); ② disable dsh Developer Tools; ③
`BILI_RECLAIM_FETCH_PATCH=0` (loses the #1158 self-heal). The clean fix belongs
on the inspector side — degrade only fetch-capture instead of throwing the whole
entry. See also the `BILI_RECLAIM_FETCH_PATCH` coexistence note (#3528) in
configuration.md.

## Kimi Code (Moonshot)

Three aligned modes: `bili kimi` (launcher, cert-MITM — README Quickstart
Expand Down
2 changes: 2 additions & 0 deletions docs/clients.zh-CN.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,8 @@

**dsh-go 宿主(第三方安卓 App):** 该 App(`ccch1mneyyy/dsh-Go`)自带一套 dsh 运行时 —— proot rootfs 里的 dsh `0.2.2-rc.1` / node 24.22.1 / Ubuntu 24.04.5,每次 App 更新替换约 135 个 dsh 文件。上面的 profile 泳道在这里原样可用:在它的 Linux 环境里执行 `dsh plugin --profile <name> add billion-context`,引擎即挂载该 bundle 并把代理拉成自己的子进程。已在 Redmi K80 / Android 16 / arm64-v8a 上验证:首次对话经代理转发(`[window] source=plugin`、`effective window 1048576 -> 792576 (reserved 256000)`、`forward POST → api.deepseek.com/anthropic/v1/messages`),`GET /__bili/plugin/status` 的 `contextTokens` 取自 usage。该宿主的客户端是原生实现,因此只带 `dsh.client.platform: web` 的 bundle(本插件的 Context 标签页与设置页)在那里没有落点 —— 宿主面、工具与 HTTP 面板不受影响,原生界面经 `dshGo` 槽另行接入(dsh-Go 的 `docs/plugins/native-for-free.md`)。它还定义了 `preset-dsh-go-companion` 与 `preset-dsh-go-companion-full`,其内嵌的 `compaction-basic` 行应由 #4147 的结构化遍历覆盖。

**与 dsh Developer Tools / 实验版 inspector 共存(#5148):** 原生插件经一个受守卫的 `globalThis.fetch` **访问器**(getter/setter)路由模型流量 —— 这是 #1158 的自愈机制:任何第三方对 fetch 的安装都会被重链为下游,使路由绝不静默离开代理。dsh 的 `@deepseek-ai/dsh-experimental-inspector`(由 Developer Tools 启用)拒绝观察访问器并抛错 `inspector: globalThis.fetch is an accessor and cannot be observed safely`,于是**这一条 entry 激活失败**,而 `dsh web` 其余部分照常运行。profile 先加载 bili、后加载 inspector,所以这是加载顺序 + 机制冲突,不是 bili 的错;而把访问器关掉(`BILI_RECLAIM_FETCH_PATCH=0`)会重新引入 #1158 的静默失路由(模型流量绕开代理但会话照常跑),因此默认保持开启。绕行方案,影响从小到大:① 在 profile 的 `cordis.patch.yml` 里给该 inspector entry 设 `captureFetch: false`(inspector 其余能力保留);② 关闭 dsh Developer Tools;③ `BILI_RECLAIM_FETCH_PATCH=0`(代价是失去 #1158 自愈)。干净的修法应在 inspector 一侧 —— 遇到访问器时只降级 fetch-capture,而不是整条 entry 抛错。另见 configuration.md 中 `BILI_RECLAIM_FETCH_PATCH` 的共存提示(#3528)。

## Kimi Code(Moonshot)

三种对齐模式:`bili kimi`(启动器,证书 MITM —— README 快速上手 方式 2)、`/bili/` URL 前缀,以及原生插件模式(`bili plugin install kimi`,#963)。Kimi Code v2 的插件体系是纯声明式的(`kimi.plugin.json`:MCP server、hooks、skills —— 没有进程内 JS 执行),所以 bili 无法像 pi/opencode/dsh 那样补丁客户端的 fetch 栈。取而代之,插件带两个小型 node 脚本,在客户端外围完成工作:
Expand Down
Loading