dsh-fast-mode 1.5.8 → 1.5.9

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/BENCHMARK.md CHANGED
@@ -1452,31 +1452,56 @@ node bin/experiment.mjs stop # end it; later sessions g
1452
1452
  - **速度**:墙钟合计 **0.967×**(1543.5 s → 1493.3 s),逐格中位 **0.999×**、3/5 格更快,步数 0.66×。逐格:`ledger` 0.78×、`shellops` 0.98×、`migrate` 1.00×、`stategraph` 1.31×、`codebase` 1.79×。
1453
1453
  - **读法**:单对、n=5,噪声带比合池 0.798× 的总口径宽,**不用这块替换总量结论**;它只用于回答「发版这一步有没有把质量或方向弄坏」。质量答案是没坏;速度方向在这一块落进噪声(0.97×)。
1454
1454
  - 原始结果 `bench/results/suite-REL16.jsonl`;`python3 bench/report.py --files bench/results/suite-REL16.jsonl --baseline off` 可复算。
1455
- ## 合池的自助区间与逐任务稳定性(2026-10-27,含 PPX2)
1455
+ ## 合池的自助区间与逐任务稳定性(2026-10-27,含 PPX2 与 SG2)
1456
1456
 
1457
- 合池点估计 **0.8087×** 是 128 对有效单元的比值加总,不是承诺值。给这 128 对做 2000 次自助重抽(`python3 bench/pool.py --ci 2000`)后:**墙钟总比 95 % 区间 [0.734, 0.894]**,中位 **[0.706, 0.885]**,步数总比 0.8062×,更快 87/128。区间上沿还贴着 0.9,所以对外只说「大约两成」,不说「至少两成」;要收窄区间只能加样本,不是换机制。
1457
+ 合池点估计 **0.825×** 是 132 对有效单元的比值加总,不是承诺值。给这 132 对做 2000 次自助重抽(`python3 bench/pool.py --ci 2000`)后:**墙钟总比 95 % 区间 [0.747, 0.914]**、逐格中位 0.813×(区间 [0.710, 0.883])、89/132 对更快。`bench/results/suite-*.jsonl` 里每行都带 `valid` 判定,合池只吃 `exit==0 && steps>=1 && out>0 && exact && !leak` 的单元。
1458
1458
 
1459
- PPX2 是这一轮唯一新增的 off 锚定块(4 家族 × 2 对 × 3 臂,`bench/results/suite-PPX2.jsonl`)。它合进来的总量是 **0.912×(8 对,6/8 更快)**,把合池从 0.798× 抬到 **0.809×** —— 方向没变,幅度更保守。它还暴露了一件事:**同一批任务在另一块里符号会翻**,见下表 `debugfix`/`perfrefactor` 两行。
1459
+ 新增的 off 锚定块 **SG2**(4 家族 × 1 对 × 3 臂,`bench/results/suite-SG2.jsonl`)合进来是 **1.235×(4 对,2/4 更快)**,把合池从 0.809× 抬到 **0.825×**。它也是第一块把 `ledger`(2.024×,输出 34.1k vs 18.7k token)和 `perfrefactor`(1.427×)的反向样本算进分母的块——抬上去的那 1.6 个点就是把这两类任务如实计入的代价。
1460
1460
 
1461
- 逐任务拆开看,方向稳定的只剩两个家族(双侧符号检验,7 块 + PPX2,共 128 对):
1462
-
1463
- | 任务 | n | 中位墙钟 | 均值 | 四分位区间 | 更快 | 符号检验 p | 输出比中位 |
1464
- |---|---|---|---|---|---|---|---|
1465
- | `codeimpl` | 15 | 0.709 | 0.754 | 0.62–0.90 | 13/15 | **0.007** | 0.831 |
1466
- | `stategraph` | 10 | 0.667 | 0.741 | 0.59–0.72 | 8/10 | 0.109 | 0.737 |
1467
- | `migrate` | 15 | 0.739 | 0.849 | 0.53–1.28 | 11/15 | 0.118 | 0.802 |
1468
- | `codebase` | 11 | 0.586 | 0.898 | 0.51–1.49 | 7/11 | 0.549 | 0.657 |
1469
- | `shellops` | 12 | 0.774 | 0.928 | 0.66–1.44 | 8/12 | 0.388 | 0.932 |
1470
- | `ledger` | 13 | 0.782 | 0.822 | 0.45–1.22 | 8/13 | 0.581 | 0.950 |
1471
- | `shellpipeline` | 12 | 0.844 | 0.835 | 0.67–0.99 | 10/12 | **0.039** | 0.761 |
1472
- | `perfrefactor` | 13 | 0.890 | 1.118 | 0.72–1.36 | 7/13 | 1.000 | 0.865 |
1473
- | `csvpipe` | 13 | 0.983 | 1.014 | 0.54–1.48 | 8/13 | 0.581 | 0.883 |
1474
- | `debugfix` | 14 | 1.183 | 1.323 | 0.83–1.92 | 7/14 | 1.000 | 1.286 |
1475
-
1476
- - **稳的**:`codeimpl`(13/15 更快,p = 0.007,中位 0.709×)与 `shellpipeline`(10/12,p = 0.039)。这两个家族的收益同时出现在墙钟和步数上。
1477
- - **中位好看但不稳的**:`codebase` 中位 0.586× 但均值 0.898×、四分位 0.51–1.49×,p = 0.549 —— 靠少数长格拉低中位,不能说成「普遍快 41 %」。
1478
- - **不许当结论的两行**:`debugfix` 在中位 1.183×(p = 1.000,7/14 更快);但在 PPX2 这一块里 `debugfix` 是 **0.651×(2/2 更快)**、`perfrefactor` 是 **0.687×(2/2 更快)**,与混池方向相反。样本只有 2 对时不构成反证,但足以说明**「哪个家族快」不能跨块引用** —— 对外只能说合池,不能说逐家族表是稳定的。
1479
- - **输出口径**:`debugfix` 输出比 1.286× 仍是唯一明显变长的家族;`codebase`/`stategraph`/`shellpipeline` 输出明显变短(0.657/0.737/0.761)。合池输出 0.806×,与墙钟同向 —— 速来自少写,不是来自少做。
1461
+ | 块 | n | 墙钟总比 | 更快 |
1462
+ |---|---|---|---|
1463
+ | `W1` | 11 | 0.710× | 7/11 |
1464
+ | `W3` | 29 | 0.721× | 23/29 |
1465
+ | `W5` | 20 | 0.793× | 11/20 |
1466
+ | `W6` | 19 | 0.931× | 11/19 |
1467
+ | `W7` | 17 | 0.734× | 13/17 |
1468
+ | `W8b` | 19 | 0.819× | 13/19 |
1469
+ | `REL16` | 5 | 0.967× | 3/5 |
1470
+ | `PPX2` | 8 | 0.912× | 6/8 |
1471
+ | `SG2` | 4 | 1.235× | 2/4 |
1472
+
1473
+ 合池输出比 **0.822×**、步数比 **0.809×**、逐格中位 **0.813×**。
1474
+
1475
+ | 任务 | n | 中位墙钟 | 均值 | 四分位区间 | 更快 | 符号检验 p |
1476
+ |---|---|---|---|---|---|---|
1477
+ | `codebase` | 11 | 0.586 | 0.898 | 0.51–1.49 | 7/11 | 0.549 |
1478
+ | `stategraph` | 10 | 0.667 | 0.741 | 0.57–0.86 | 8/10 | 0.109 |
1479
+ | `shellops` | 13 | 0.683 | 0.896 | 0.55–1.38 | 9/13 | 0.267 |
1480
+ | `codeimpl` | 15 | 0.709 | 0.754 | 0.62–0.90 | 13/15 | **0.007** |
1481
+ | `migrate` | 15 | 0.739 | 0.849 | 0.53–1.28 | 11/15 | 0.118 |
1482
+ | `ledger` | 14 | 0.812 | 0.908 | 0.44–1.29 | 8/14 | 0.791 |
1483
+ | `shellpipeline` | 12 | 0.844 | 0.835 | 0.66–0.97 | 10/12 | **0.039** |
1484
+ | `perfrefactor` | 14 | 0.961 | 1.140 | 0.69–1.53 | 7/14 | 1.000 |
1485
+ | `debugfix` | 15 | 0.976 | 1.287 | 0.77–1.92 | 8/15 | 1.000 |
1486
+ | `csvpipe` | 13 | 0.983 | 1.014 | 0.54–1.50 | 8/13 | 0.581 |
1487
+
1488
+ - **稳的**:`codeimpl`(13/15 更快,p = 0.007,中位 0.709×)与 `shellpipeline`(10/12,p = 0.039)。这两个家族的收益同时出现在墙钟和步数上,是唯一能对外说「这个形状有稳定收益」的两行。
1489
+ - **中位好看但不稳的**:`codebase` 中位 0.586× 但均值 0.898×、四分位 0.51–1.49×,p = 0.549 —— 靠少数长格拉低中位,不能说成「普遍快 41 %」。`shellops` 同理(中位 0.683×、均值 0.896×、p = 0.267)。
1490
+ - **加了 SG2 之后方向变坏的**:`ledger` 中位 0.812× 但均值 0.908×、四分位 0.44–1.29×(SG2 里 2.024×);`debugfix` 中位 0.976×、均值 1.287×(输出 1.29×);`perfrefactor` 中位 0.961×、均值 1.140×。这三类不是「快得少」,是**平均在变慢**,默认指引写「先试一次,复验变多就关」。
1491
+ - **不许跨块引用的行**:`debugfix` 在 PPX2 这一块里是 **0.651×(2/2 更快)**、`perfrefactor` 是 **0.687×(2/2 更快)**,与混池方向相反。块内 n=2 撑不起任何引用,写在这里只是提醒别拿单块当结论。
1492
+ - **输出口径**:合池输出 0.822×,与墙钟同向 —— 速度来自少写、少复验,不是来自更快地写同样多的东西。`debugfix` 输出 1.29× 是唯一明显变长的家族。
1480
1493
  - 开销口径:这些区间是**墙钟**的自助区间;块内两臂逐对交替跑,所以不含跨时段机器漂移。块间不可比,合池只做同 `(tag, task, pair)` 的配对。
1481
1494
 
1482
- **什么时候开、什么时候别开**(按形状,不按任务名,README 同款):开在多产物、反复复验的中长任务;`debugfix`/`perfrefactor` 这类短改修**先用一次,看它是否在替你复验**——混池里它们是负的,但 PPX2 里是正的,所以给的是「先试再定」,不是禁令;`csvpipe` 中位 0.983×,接近 1,等于没赚没亏。开关本来就按会话记:同一会话里一旦发现提示在拖后腿,关掉即可,不需要重启宿主。
1495
+ ## DBG2:三个慢家族的定向复测(2026-10-27,未进合池)
1496
+
1497
+ 原计划 3 家族 × 3 对 × 2 臂 = 18 格,只跑完 14 格(`csvpipe` 第 3 对卡在 18 分钟未收),**7 对可用**:`debugfix` 3 对、`perfrefactor` 2 对、`csvpipe` 2 对。这一块从 13:21 跑到 14:2x,机器 load 5–8(Spotlight 重启后重建索引),**墙钟被拉长约 2–4 倍,不满足合池的负载前提**,所以只作方向参考、不进 `CLEAN`:
1498
+
1499
+ | 家族 | n | 墙钟总比 | 逐对 |
1500
+ |---|---|---|---|
1501
+ | `debugfix` | 3 | 1.021× | 1.059 / 1.060 / 0.943 |
1502
+ | `perfrefactor` | 2 | 1.207× | 1.291 / 1.122 |
1503
+ | `csvpipe` | 2 | 1.783× | 3.298 / 0.268 |
1504
+
1505
+ 读法:`debugfix` 在负载下基本持平(三条全在 1.0 上下),`perfrefactor` 两条都慢 12–29 %,`csvpipe` 两条方向完全相反(一条跑飞成 3.3×、一条 0.27×)——后者说明这个家族的方差大过机制本身,任何单点数字都不能引用。**结论与混池一致:`debugfix`/`perfrefactor`/`csvpipe` 默认不承诺收益,指引写「先试一次」。**
1506
+
1507
+ **什么时候开、什么时候别开**(按形状,不按任务名,README 同款):开在多产物、反复复验的中长任务;`debugfix`/`perfrefactor`/`csvpipe` 这类短改修和数据整形**先用一次,看它是否在替你复验**——混池里它们是负的,所以给的是「先试再定」,不是「都会快」。合池的 0.825× 是全部样本的加总口径,别拿它单点承诺某个任务。
package/CHANGELOG.md CHANGED
@@ -1,5 +1,13 @@
1
1
  # Changelog
2
2
 
3
+ ## 1.5.9
4
+
5
+ - **合池口径再扩一块(无行为变更,纯数据与文档)**:新增 SG2 块(`shellops`/`debugfix`/`perfrefactor`/`ledger` × 1 对 × 3 臂,4 对 off 锚定)后,合池变成 **9 块、132 对、10 个家族**:总墙钟 **0.825×**(省 18 %)、输出 token 0.822×、步数 0.809×、逐格中位 0.813×、132 对里 89 对更快;2000 次自助重抽的总比 95 % 区间 **[0.747, 0.914]**、中位区间 [0.710, 0.883]。上一版对外写的 0.809× / 省 19 % 是 128 对口径,**本版按更全样本改口径**,不是行为变了。
6
+ - **SG2 自己就是一块反向样本**:4 对合进来是 **1.235×(2/4 更快)**,其中 `ledger` 2.024×(输出 34.1k vs 18.7k token)、`perfrefactor` 1.427×,正是把「输出会变长的家族」如实计进分母的结果。`sg15` 臂在同块比 `def15` 更差(1.295×、中位 1.392×、1/4 更快),**继续默认关**,不进默认机制。
7
+ - **逐家族稳定性重算**:稳的仍然只有 `codeimpl`(13/15 更快、p = 0.007、中位 0.709×)和 `shellpipeline`(10/12、p = 0.039、中位 0.844×);`ledger`(均值 0.908×、四分位 0.44–1.29×)、`debugfix`(均值 1.287×、输出 1.29×)、`perfrefactor`(均值 1.140×)在扩样本后**平均在变慢**,文档与 README 的「什么时候别开」改按这三类写。
8
+ - **DBG2 定向复测(未进合池)**:`debugfix`/`perfrefactor`/`csvpipe` 各 3 对,只跑完 7 对(`csvpipe` 第 3 对卡在 18 分钟未收),且全程机器 load 5–8、墙钟被拉长 2–4 倍,**不满足合池前提**,只作方向参考:`debugfix` 1.021×(三条 1.06/1.06/0.94)、`perfrefactor` 1.207×(1.29/1.12)、`csvpipe` 1.783×(一条 3.30×、一条 0.27×,方差大过机制)。结论与混池一致:这三类默认不承诺收益。
9
+ - **复现前置**:`python3` 必须是能 `import yaml` 的解释器(本机 `/usr/bin/python3` 因 Xcode license 返回 rc=69);`bench/pool.py` 的区块清单已含 `SG2`。
10
+
3
11
  ## 1.5.8
4
12
 
5
13
  - **合池口径再收紧(无行为变更,纯数据与文档)**:新增 PPX2 块(4 家族 × 2 对 × 3 臂,8 对 off 锚定)后,合池变成 **8 块、128 对、10 个家族**:总墙钟 **0.809×**(省 19 %)、输出 0.806×、步数 0.806×、逐格中位 0.813×、87/128 更快,2000 次自助重抽 95 % 区间 **[0.734, 0.894]**(中位 [0.706, 0.885])。上一版的 0.798× / 120 对是被一块偏乐观的数据抬高的,这版把 PPX2 一起算进去。
package/README.en.md CHANGED
@@ -40,9 +40,9 @@ No model switch, no `reasoningEffort` rewrite, no request-field injection (`serv
40
40
 
41
41
  ## Measured
42
42
 
43
- **Toggle it on and the headline is: about 19% faster in total, and 15–30% faster on the shapes it fits.** That is every clean block with an `off` anchor pooled (8 blocks, 128 valid pairs, 10 task families; recompute with `python3 bench/pool.py`): total wall clock **0.809×** (19% less), output tokens 0.806×, steps 0.806×, per-cell median 0.813×, faster in 87 of 128 pairs. Bootstrapping those 128 pairs (`python3 bench/pool.py --ci 2000`) puts the total ratio at a 95% interval of **[0.734, 0.894]** (11% to 27% faster) and the per-cell median at [0.706, 0.885] — "about 19%" is a point estimate, not a floor. Per-family stability and sign tests are in [BENCHMARK.md](BENCHMARK.md), section "合池的自助区间与逐任务稳定性", which also explains why per-family numbers cannot be quoted across blocks.
43
+ **Toggle it on and the headline is: about 18% faster in total, and 15–25% faster on the shapes it fits.** That is every clean block with an `off` anchor pooled (9 blocks, 132 valid pairs, 10 task families; recompute with `python3 bench/pool.py`): total wall clock **0.825×** (18% less), output tokens 0.822×, steps 0.809×, per-cell median 0.813×, faster in 89 of 132 pairs. Bootstrapping those 132 pairs (`python3 bench/pool.py --ci 2000`) puts the total ratio at a 95% interval of **[0.747, 0.914]** (9% to 25% faster) and the per-cell median at [0.710, 0.883] — "about 18%" is a point estimate, not a floor. Per-family stability and sign tests are in [BENCHMARK.md](BENCHMARK.md), section "合池的自助区间与逐任务稳定性", which also explains why per-family numbers cannot be quoted across blocks.
44
44
 
45
- **When to turn it on, and when not to.** On: mid-length tasks with several artifacts and repeated re-checks — `codeimpl` 0.608x, `stategraph` 0.708x, `migrate` 0.748x, `shellpipeline` 0.749x, with `shellops` 0.803x, `codebase` 0.808x and `ledger` 0.811x on the same side. Off: one-to-five-step repairs — `debugfix` 1.245x and `perfrefactor` 1.077x, where the injected reminder cannot pay for itself. `csvpipe` 0.982x is a wash. The switch is the lightning bolt per conversation; it remembers your last choice and applies from the next request.
45
+ **When to turn it on, and when not to.** On: mid-length tasks with several artifacts and repeated re-checks — `codeimpl` 0.663x (faster in 13 of 15 pairs, sign test p = 0.007) and `shellpipeline` 0.749x (p = 0.039), with `stategraph` 0.708x, `shellops` 0.748x, `codebase` 0.808x and `migrate` 0.822x on the same side but with too few pairs to stand alone. Off: one-to-five-step repairs and data reshaping — `debugfix` 1.032x (output actually 1.29x longer) and `perfrefactor` 1.009x, where the injected reminder cannot pay for itself. `ledger` 0.915x and `csvpipe` 0.982x are a wash. The switch is the lightning bolt per conversation; it remembers your last choice and applies from the next request.
46
46
 
47
47
  **1.5.0 ships no step-based finish line by default.** `finishLineSteps` and `stepBudget` both default to `0`: there is no "remind me at step 10" and no "stop at step 30". When to finish is decided by task state and completion evidence — repeating an already-passing check verbatim against the same artifact suggests reusing the result and spending the step on what is left; several steps with no new result suggests changing the method (a reminder only, it never ends the turn); a stuck tool is cancelled by the watchdog and awaited until it really stops. A finished task is reported normally; a reminder never votes to stop for you.
48
48
 
package/README.md CHANGED
@@ -40,9 +40,9 @@
40
40
 
41
41
  ## 实测
42
42
 
43
- **打开小闪电,排头的一句结论:整任务总量约快 19 %,适合的形状快 15–30 %。** 这是把**所有**有 `off` 锚的干净块一起加总的结果(8 个块、128 对有效配对、10 个任务家族,`python3 bench/pool.py` 可复算):总墙钟 **0.809×**(省 19 %)、输出 token 0.806×、步数 0.806×、逐格中位 0.813×、128 对里 87 对更快。对这 128 对做自助重抽(`python3 bench/pool.py --ci 2000`),总比 95 % 区间是 **[0.734, 0.894]**(即省 11 %–27 %),逐格中位区间 [0.706, 0.885]——「约 19 %」是点估计、不是下限承诺;逐家族稳定性与符号检验见 [BENCHMARK.md](BENCHMARK.md) 的「合池的自助区间与逐任务稳定性」一节,那里也写了为什么逐家族数字不能跨块引用。
43
+ **打开小闪电,排头的一句结论:整任务总量约快 18 %,适合的形状快 15–25 %。** 这是把**所有**有 `off` 锚的干净块一起加总的结果(9 个块、132 对有效配对、10 个任务家族,`python3 bench/pool.py` 可复算):总墙钟 **0.825×**(省 18 %)、输出 token 0.822×、步数 0.809×、逐格中位 0.813×、132 对里 89 对更快。对这 132 对做自助重抽(`python3 bench/pool.py --ci 2000`),总比 95 % 区间是 **[0.747, 0.914]**(即省 9 %–25 %),逐格中位区间 [0.710, 0.883]——「约 18 %」是点估计、不是下限承诺;逐家族稳定性与符号检验见 [BENCHMARK.md](BENCHMARK.md) 的「合池的自助区间与逐任务稳定性」一节,那里也写了为什么逐家族数字不能跨块引用。
44
44
 
45
- **什么时候开、什么时候别开(按实测形状,不按任务名)。** 开:有多份产物、要反复跑同一份检查的中长任务——`codeimpl` 0.608×、`stategraph` 0.708×、`migrate` 0.748×、`shellpipeline` 0.749×,`shellops` 0.803×、`codebase` 0.808×、`ledger` 0.811× 也在同一侧。别开:1–5 步的小改修——`debugfix` 1.245×、`perfrefactor` 1.077×,提醒本身的注入成本收不回来。`csvpipe` 0.982× 打平,开不开都行。开关就是每会话的小闪电,默认记住上次选择,下一个请求生效。
45
+ **什么时候开、什么时候别开(按实测形状,不按任务名)。** 开:有多份产物、要反复跑同一份检查的中长任务——`codeimpl` 0.663×(15 对里 13 对更快,符号检验 p = 0.007)、`shellpipeline` 0.749×(p = 0.039),`stategraph` 0.708×、`shellops` 0.748×、`codebase` 0.808×、`migrate` 0.822× 也在同一侧但样本撑不起单列结论。别开:1–5 步的小改修与数据整形——`debugfix` 1.032×(输出反而长 1.29×)、`perfrefactor` 1.009×,提醒本身的注入成本收不回来。`ledger` 0.915×、`csvpipe` 0.982× 打平,开不开都行。开关就是每会话的小闪电,默认记住上次选择,下一个请求生效。
46
46
 
47
47
  **1.5.0 的默认不做步数收尾。** `finishLineSteps` 与 `stepBudget` 默认都是 `0`:没有“第 10 步提醒收尾”,也没有“30 步停止”。结束由任务状态和完成证据决定 —— 同一份产物上逐字重复一条已通过的检查,建议复用结果、把这一步留给剩下的工作;连续几步没有新结果,建议换方法(只是提醒,不结束回合);工具卡住,看门狗取消它并等它真正停下。任务做完就正常报告,提醒不会替你判停。
48
48
 
package/index.js CHANGED
@@ -95,7 +95,7 @@ const TAG = '[fast-mode]'
95
95
  * Shipped identity of this build. Traced into the debug log so a stale install is
96
96
  * visible at a glance, and pinned by a test against `package.json`.
97
97
  */
98
- export const VERSION = '1.5.8'
98
+ export const VERSION = '1.5.9'
99
99
  const GLOBAL_AGENT = '__global__'
100
100
 
101
101
  /**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "dsh-fast-mode",
3
- "version": "1.5.8",
3
+ "version": "1.5.9",
4
4
  "description": "DeepSeek Harness fast mode: same thinking effort, fewer round trips. An adaptive parallel tool fan-out, output discipline that never trims the answer, and a cancellable stall guard. Never changes reasoning effort, the model, or the request body. Provider-agnostic, one dependency (@deepseek-ai/schemastery).",
5
5
  "repository": {
6
6
  "type": "git",