Repository navigation
fix(#2451): address review findings M1–M3 + two nits - #2460
Conversation
The #2432 dsh local-compaction rebase landed on the openai lane only, while CONFIGURATION.md names responses "the lane dsh desktop's compaction actually rides" (#2360). A dsh-bound session replaying [checkpoint summary, retained tail…] on this wire kept the pre-#2432 death spiral: partially-alive blocks, self-destructing fold anchors, every later compress failing to anchor (#2451 review M1). prepare-responses.ts now runs the same detector as prepare-openai.ts: dsh-bound session (metadata.pluginAgent === "dsh") + checkpoint framing in a resent message (carriesDshLocalCompactionSummary) + decimated fold coverage (missing >= DSH_LOCAL_COMPACTION_MIN_MISSING and >= half the covered set) -> markNativeCompactionBoundary + reconcile back-to-back, re-seeding refs onto the compacted view in the SAME turn. The codex detector (#2372) is preserved verbatim on its own lane branch; decimated coverage without either producer's framing stays on the churn paths. Folds in the new e2e are driven through POST /__bili/plugin/tool — plugin mode suppresses the compress loop, so the model-fold fixture from the codex tests cannot drive a dsh-bound session. Negatives pin: intact history with framing (paste analog), a session never dsh-bound, and foreign (codex) framing on a dsh-bound session.
📦 Built Package ArtifactBranch: Option A — Install this exact build (recommended)npm install -g billion-context@0.0.2673-pr.2460.a238ee3This exact version is immutable and reproducible. The rolling Option B — Download artifact
tar xzf billion-context-pr2460.tgz
npm install -g packageInstall instructions are refreshed on each push. |
|
ci 失败 |
|
M2 — receipt ↔ acp_status contradiction on substrate-destruction breakers (08bf355) 详细解释 这个是把 acp status 改成啥了 |
[bot] 🏷 M2 到底把 先说它治的病(#2360 形态的自相矛盾)
改动全在
一句话总结: 要看住的一个前提:这条恢复路径成立,靠的是"substrate-destruction 后从当前 resent view 重推的范围确实锚得上"(区别于 stale-ref 的旧代 ref)。新增的 recovery-path 测试钉的就是这个,控制组验证 armed+stale-ref 仍保持压制。 另:CI 失败我并行在处理 —— failure 定位到 |
[bot] 🏷 CI 失败已定位并修掉 —— 已推新提交到分支 结论:红的不是测试,是 八问
本地复跑该门禁已绿( |
[bot] 🏷 CI 状态更新(commit
等这 4 个翻绿即可合并(合并按规矩由你来操作)。需要我确认最后这几个翻绿的话 ping 我一声再查一次。 |
[bot] 🏷 CI 全绿 ✅ ——
回顾这次 CI 失败:M3 给 runaway tool-xml lane 加的 corroborator 常量 现在可以合并了(合并按规矩由你操作)。 |
The armed/pre-armed suppression of the Compressible-ranges list is gone. The table is live by construction — buildCompressibleRanges (kernel/src/ recommend.ts) derives refs from the CURRENT resent view only, after screening covered/media/protected/withdrawn messages — so an advertised range always anchors, and hiding it behind failure-cause policy only produced contradictions: - armed on substrate-destruction, the receipt orders "run acp_status once, then compress ONLY a range it currently reports" — suppression made that promised recovery unreachable (#2451 review M2, the #2360 two-orders shape); - armed/pre-armed on stale-ref, the failed refs were the model's stale INPUT, not the table — suppression hid the very remedy. acp_status now reports the table unconditionally and carries no order of its own: substrate-destruction attribution keeps the receipt's recovery line; every other cause mirrors the receipt's STOP order ("do not attempt to compress now; continue the task"). Anti-loop pressure stays where it belongs — in the receipts. tests: armed (unknown cause / stale-ref / substrate) and pre-armed (n=1/2) all assert the table stays up, the matching annotation renders, and no SUPPRESSED claim appears anywhere.
The tool-xml lane tripped on raw fragment COUNT alone: a burst of short ANTML fragments riding real content (~60 tags in one turn of genuine tool chatter) looked identical to a true runaway skeleton flood. Gate it on a second signal — average gap bytes between fragments: genuine tool chatter leaves prose between its fragments (gaps far above TOOL_XML_GAP_AVG_BYTES = 64), while a runaway model re-emits the skeleton with almost nothing in between. toolGapBytes counts every fed byte as gap the feed it arrives in (the no-"<" fast path now routes through feedGapOnly so prose chunks count), each TOOL_XML match subtracts its own length, TAIL_CAP-dropped bytes stay counted (over-counting gaps is FP-safe), and acp-tag bytes are deliberately not subtracted.
…nused-exports gate)
4243e28 to
5b6b7a0
Compare
|
Review follow-up (M2 redesign): Review question was whether the armed-substrate-only exemption was the right cut. It wasn't — cause-string-driven suppression is unnecessary given how the table is built:
New behavior:
Anti-loop pressure stays where it belongs — in the receipts (which carry the STOP order and scrub the poll hints), not in hiding a live table. Tests (tests/issue2432-breaker-awareness.test.ts, 8/8): armed × {unknown cause, stale-ref, substrate} and pre-armed n=1/2 all assert the table stays up, the matching annotation renders, and no SUPPRESSED claim appears anywhere. History note: branch was force-updated to rebuild the commit cleanly; the gate fix 4243e28 (drop unused |
[bot] 🏷 M2 重设计 review 结论:架构成立,可合(等最后 4 个 test suite 翻绿;merge 按规矩由你操作) 没重做你的改动,而是独立验证地基 + 审是否改坏别处。已核对分支真实状态:force-update 后 head= 最关键一条——我去 kernel 源码核实了地基,不是信注释: 八问
一个非阻塞小观察(供你定,我没擅自动你的注释): CI: |
[bot] 🏷 CI 全绿确认: 顺带一个 FYI(非阻塞):PR 当前 按规矩 merge 由你操作;我这边 review 到此收工。上面那条非阻塞的注释小观察(src/acp-status.ts:203-208)要不要我补个标注 commit,等你一句话。 |
📦 Merged Build PublishedThis merge to master was published as npm install -g billion-context@0.0.172-master.c171d38 # this exact build
npm install -g billion-context@master # always the newest merged build
|
Review follow-up to #2451 (full review: #2451 (comment)). #2451 itself is a version-bump release PR — these are the forward-fix items, not merge blockers.
M1 — dsh native compaction rebase missing on the /v1/responses lane (
db585eff)#2432 landed the dsh local-compaction rebase on the openai lane only, but CONFIGURATION.md names responses "the lane dsh desktop's compaction actually rides" (#2360).
prepare-responses.tsnow runs the same detector: dsh-bound session + checkpoint framing + decimated fold coverage → rebase in the same turn. New e2etests/issue2451-dsh-responses-compaction.test.ts(4 tests; folds driven through/__bili/plugin/toolsince plugin mode suppresses the compress loop).M2 — receipt ↔ acp_status contradiction on substrate-destruction breakers (
08bf3556)The post-compress receipt ordered "run acp_status, then compress a range it reports" while armed-breaker acp_status suppressed ranges and said "Do not attempt to compress now". acp_status now re-derives live ranges from the current resent view when the armed breaker's failures were substrate-destruction, and carries exactly one order per state.
M3 — tool-xml runaway lane had no corroborator (
f3d7fe4b)Trip now also requires avg gap-per-fragment ≤ 64 bytes (
TOOL_XML_GAP_AVG_BYTES): genuine skeleton floods pack fragments back-to-back; fragments spread over real content (#1039 user intent) no longer trip.Nits (
67dc6ae3)relay.ts: mask upstream URL in the[lane-credential] applieddebug log (release v0.1.188 #2377 class).update.tsbootSmoke:windowsHide: true([Bug] Windows: 其余 3 处 child_process 调用漏 windowsHide(version.ts / claude-native-bootstrap.ts / update.ts)—— #2439 同机制漏网点 #2441 class).Tests: tsc clean; 38/38 across the compaction suites (codex #2372 5, dsh openai #2432 6, breaker-awareness 8 incl. new recovery-path test, runaway-guard 14 incl. 4 new, new responses-lane 4); e2e-native-dsh 2/2; update-host-guard + update-desktop-inplace 12/12; responses-lane neighbors (compat-drop/roles, previous-response-id, plugin-dev-position, chain-self-exemption) 62/62.