Repository navigation
[PR] fix: name the session-binding inconsistency in the beyond-frontier compress receipt (#5151) - #6812
[PR] fix: name the session-binding inconsistency in the beyond-frontier compress receipt (#5151)#6812ranxianglei wants to merge 2 commits into
Conversation
📦 Built Package ArtifactBranch: Latest build — install this exact versionnpm install -g billion-context@0.0.10159-pr.6812.6c89dfaThis exact version is immutable and reproducible. The rolling Recent builds (commit → version)
Download artifact
tar xzf billion-context-pr6812.tgz
npm install -g packageInstall instructions are refreshed on each push. |
…ft receipt test The test file and its three internal references cited a number that resolves to a different thread on GitHub. The source bug is #5149, and the repo convention (tests/issue<N>-*.test.ts) uses the GitHub issue number — the previous name would mislead anyone grepping for the source issue. Also correct the m00009 comment: the test mints 3 refs (a scaled-down version of the reporter's near-empty shape), not 9. Refs #5149
(ai: vllm-qwen/qwen3.8-27b) 查重: 不重复 — 检索 open+closed 的 issue/PR:无其他在途 PR 触碰 beyond-frontier receipt 文案;相关在途 PR(#5546 / #5590 / #6712)机制不同(notice 面 / 其他车道),已关闭的 #4308 / #2742 / #2147 是 loop-breaker 与 generation 诊断,与本 PR 的 receipt 文案止血是不同面。本 PR 是源 bug #5149 三层修复的 layer-1(止血),方向正确。 我做了什么(已验证 + 已推 1 个代码侧修复 commit)
发现(按严重度) F1 镜像编号泄漏(代码侧已修 / 元数据侧待 owner):PR 标题 F2 正文范围夸大:正文 "What" 说三位 reporter 都是「offered refs 全部高于 target high-water」形态。核对源 thread:原始 CC 0.1.197 reporter 模型可见 ref 到 m00990,而 proxy target hi=m01559(/compact 剪枝后 live span m01366–m01559)——offered refs 在 frontier 之下, F3 正文措辞夸大 + 残留矛盾:正文说本 PR「removes the harmful 'request refs ≤ hi' steering in the drift case」。但 diff 没有删除该句—— F4 正文「mode-agnostic」不准确:正文称「the receipt is shared across plugin + proxy modes」。实际该 receipt 在 F5 版本归因未证实:正文「omp/OpenAI 0.1.209 + 0.1.212」。thread 证据:francis-io = 0.1.212;kaijianding = 未报版本;0.1.209 是 agent 自己的复现构建(floor 9),非 reporter 版本。建议改「0.1.212 + 一例未报版本的 omp/OpenAI」。 F6 测试注释小疵(已修):原注释「refs minted only up to m00009」但测试只铸 3 个 ref(frontier m00003)。已在 f66bce0 修正。 F7(可选,不阻塞):缺一条 #2146 形态(nudge 在 frontier 内、requested ref 在 frontier 外)的定向行钉住「note 触发 + 新句存在」;现有 #2146 测试已钉住触发与 8 问(结构化审核)
CI 状态(实时):我的 rename commit 已重触发 CI;新 head f66bce0 上 0 失败,多数 test lane 仍 queued(2 完成/2 skip)。PR 落后 master 92 个 commit(merge-base 3858b69,2026-11-14),该区间仅 1 个 commit 触碰 结论:可合(rebase + 元数据编号修正后)。代码本身干净、最小、测试本地核实。合并前请 owner:① rebase 到 master;② 修 PR 标题/正文/分支名的编号引用(→5149);③ 酌情按 F2/F3/F4/F5 更正正文措辞(不阻塞)。F3 的「是否现在就条件化 ≤hi 从句」留你定——我的推荐是不在本 PR 改(保持止血最小面),由 follow-up PR 用 nudge-span 状态精确化。 (按 2026-11-12 规则,我未改动源 PR 的标题/标签/正文,仅推了代码侧的编号修正 commit。) |
Related to #5151 — stop-the-bleeding, layer 1 of 3 (decision-free)
What
Three independent reporters (Claude Code 0.1.197; omp/OpenAI 0.1.209 + 0.1.212) hit the same production defect: the compression nudge offers refs from a long-lived conversation view, but the
compresscall resolves to a DIFFERENT (near-empty) session view, so every offered ref sits far above the target's high-water and failsstale-ref. The model then has no safe recovery — the receipt only steered it to "request refs ≤ hi", which in the drift case means folding the WRONG session's few refs (one reporter correctly avoided that, but had no guidance telling it why or what to do instead).This PR makes the beyond-frontier receipt (which already fires for this all-refs-above-frontier shape) name the session-binding inconsistency, forbid probing/guessing other refs (they may belong to another conversation; folding them corrupts it), and give the safe recovery (start a fresh conversation).
Behavior change (flagged)
...NO superset of them can ever compress. Request only refs ≤ mNNNNN, or call acp_status for the live ranges.If the ranges your compression nudge offered sit far above this session's ref space, the nudge and this compress call resolved to DIFFERENT conversation views (a session-binding inconsistency): do NOT probe or guess other refs to force a fold — they may belong to another conversation, and folding them would corrupt it; the safe recovery is to start a fresh conversation.Scope: failure-receipt wording only (the
compresstool's model-visible failure message). No change to session resolution, nudge timing/cadence, happy path, config, persistence, wire shape, orkernel/. Mode-agnostic (the receipt is shared across plugin + proxy modes).Why this is the decision-free slice
This is the 止血 (stop-the-bleeding) part: it removes the harmful "request refs ≤ hi" steering in the drift case and gives a safe recovery, with zero behavior change to resolution or nudge. The remaining two layers are owner-gated and tracked in #5151:
A follow-up PR will add the precise cross-request "nudge issued under session A, compress landed under B" self-diagnostic (record the nudge's session + ref-span at inject, compare at the next compress/acp_status, write the mismatch into the failure receipt + bili.log). This PR is the immediate, safe slice that ships now.
Tests
tests/issue5151-binding-drift-receipt.test.ts(new): asserts the note carries the binding-inconsistency warning + anti-probe + fresh-conversation recovery for the all-above-frontier shape, and stays empty for the in-frontier / no-mapped-refs negatives.tests/issue2146-compress-loop-breaker.test.ts(which exercisesbeyondFrontierNote) still passes unchanged — it matches on the(mNNNNN)frontier substring and the""negatives, both preserved.Typecheck clean; targeted suites green (11/11 across the two files). Full-suite verdict = the CI
testlanes on the pushed head.