dsh-thinking-levels 4.4.19 → 4.4.20
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 +6 -0
- package/README.md +10 -2
- package/dsh.plugin.json +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 4.4.20
|
|
4
|
+
|
|
5
|
+
- **connect 类插件兼容矩阵(issue #10 后续收口,无 src/ 变更)。** 普查四家 connect/聚合插件当日版本的 adapter 形态——`@dmh2002/dsh-connect-qoder` 1.27.1 / `dsh-connect-trae` 4.18.5 / `dsh-connect-workbuddy` 5.30.0(dingminhua,ES class + 自有默认档广告)、`dsh-our-free-model`(Ebony-Vinyl,plain class + prepareCall 内部直调 this.resolveModel)——全部为普通对象形态、无 Proxy/freeze、不回读 `llm.adapters`,4.4.18 的 registry-entry facade 方案零返工成立。
|
|
6
|
+
- 新增 `tests/adapter-matrix.spec.ts`(28 例):六形态(hub write-through Proxy / vision-router 只读 Proxy / connect class / 内调 class / frozen / getter-only)× 四行为(不写第三方对象 / 不递归 / 八成员透传 + this 绑定 / 幂等不套娃)表驱动全绿;handle.replace 拓扑瞬态用例锁死收敛(重挂裸 adapter → `adapters-updated` 重包,`Object.is` 同一 facade);混合流用例锁死 our-free-model 式「重注册新实例 + 连续 emit」不套娃。全量回归 285/285。
|
|
7
|
+
- README 新增「Third-party adapter compatibility」契约段,面向 connect 插件作者写明三承诺:永不写入第三方对象 / 只替换注册表条目 / 每 inner adapter 单一 facade 幂等标记。
|
|
8
|
+
|
|
3
9
|
## 4.4.19
|
|
4
10
|
|
|
5
11
|
- **修复 issue #11:选中 auto 时界面看不到实际生效档位。** 报告人观察到「选 Auto 后请求仍以 high 发出,`lastUsed` 一直是 high、`pending` 一直是 auto」。核实结论:auto 不上送**是设计**(它是 scheduler sentinel,请求期由 `decideEffort` 按工具采样窗口解析成具体档位,有降档行为),`lastUsed`/`pending` 是宿主 `modelSelection` 投影的固有语义(`lastUsed` 每次 `request/header` 被重写、`pending` 匹配 header 提交后清空,二者都不承载用户意图 —— 见 `auto-schedule-projection.ts` 模块注释)。**真正的缺陷是显示**:`tlAutoSchedule` 投影新增 `lastEffective` 字段,折叠已提交的 `request/header` 中的 effective effort(宿主在 `dsh-llm` 里把解析结果写进该事件),选择器 chip 据此显示 `Auto → high`。
|
package/README.md
CHANGED
|
@@ -163,9 +163,17 @@ The scheduling policy is the same source as [dsh-tool-turbo](https://github.com/
|
|
|
163
163
|
|
|
164
164
|
**Where the samples come from (4.4.7+).** The scheduler folds `tool/call` events into a Session projection (`tlAutoSchedule`), so it sees real tool history on every host from 0.1.2-rc.1 on; the pre-4.4.7 `session.events` read only ever produced samples on 0.1.0-rc.8. The session's explicit pick is folded from `model/selection` events, so a level the host echoes back can never be mistaken for a manual choice. Known limitation: host `0.1.0-rc.8` exposes no `stateOf` on its projection registry (legacy plane contract), so that one line keeps the old array read — scheduling works there, the echo correction does not.
|
|
165
165
|
|
|
166
|
-
##
|
|
166
|
+
## Third-party adapter compatibility (contract for connect-plugin authors)
|
|
167
|
+
|
|
168
|
+
TL reads the `llm.adapters` registry to advertise `auto` in the model directory, and makes three promises to every plugin that registers adapters there (providers-hub, the connect-* family, our-free-model, vision-router, …):
|
|
169
|
+
|
|
170
|
+
1. **TL never writes to your adapter object.** Since 4.4.18 the advertisement replaces the *registry entry* with a plain-object forwarding facade instead of assigning `adapter.resolveModel` (the old in-place write recursed against providers-hub's write-through Proxy — issue #10 — and threw against vision-router's read-only Proxy — issue #9).
|
|
171
|
+
2. **TL only swaps the registry entry.** The host re-reads `adapters.get(provider)` on every call, so the swap is transparent to you; your adapter stays byte-for-byte untouched, frozen and getter-only shapes included.
|
|
172
|
+
3. **One facade per inner adapter, idempotent.** Re-runs (every `llm/adapters-updated`) never stack a second layer, and one adapter serving several provider routes keeps a single facade identity (the host compares adapter identity to preserve replay state).
|
|
167
173
|
|
|
168
|
-
|
|
174
|
+
What you may rely on: your own `resolveModel` post-processing (default efforts, badges) runs first; TL appends `auto` (and gated `low`) *after* it. Calls made internally on `this` (e.g. `prepareCall` → `this.resolveModel`) bypass the facade by design — only directory/selector flows through the registry. The full shape × behaviour matrix lives in `tests/adapter-matrix.spec.ts`.
|
|
175
|
+
|
|
176
|
+
## Install
|
|
169
177
|
|
|
170
178
|
```bash
|
|
171
179
|
# 1. install the plugin into a profile from npm (web shown; any profile works)
|
package/dsh.plugin.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"id": "dsh-external/dsh-thinking-levels",
|
|
3
|
-
"version": "4.4.
|
|
3
|
+
"version": "4.4.20",
|
|
4
4
|
"main": "./lib/index.js",
|
|
5
5
|
"description": "thinking-level (reasoning_effort) control — auto-adjust per tool round, with optional manual lock and per-tool timing telemetry.",
|
|
6
6
|
"engines": {
|