Repository navigation
lane 统一决策点收尾:四处 B 类名字旁路迁入 + nudgeOn 单点(#3482) - #3490
Merged
Merged
Conversation
5 tasks
ranxianglei
force-pushed
the
2026-10-17_lane-decisions-b
branch
from
October 17, 2026 05:38
bd784ad to
c5e513a
Compare
Contributor
📦 Built Package ArtifactBranch: Option A — Install this exact build (recommended)npm install -g billion-context@0.0.4144-pr.3490.30ae08eThis exact version is immutable and reproducible. The rolling Option B — Download artifact
tar xzf billion-context-pr3490.tgz
npm install -g packageInstall instructions are refreshed on each push. |
ranxianglei
force-pushed
the
2026-10-17_lane-decisions-b
branch
from
October 17, 2026 05:41
c5e513a to
d0dd6d7
Compare
…nudgeOn gate (#3482) Step 2 (B-class sites, #3417 follow-up): - omp body-pck stamp channel: hostProfileFor(agent).stampsBodyPromptCacheKey (site 3); Cowork-transport possibility is registry property coworkTransportPossible, per-request truth stays environmental (site 2). - codex/claude-responses instructions fingerprint: WIRE_CLIENTS registry with instructionsFingerprintKeyed; session-id.ts observes, never decides (site 4). - billing block (#2189) extraction gated by laneDecisions.billingBlockWanted (profile-declared OR wire-observed — evidence over defaults); wantsBillingBlock now has a real consumer (site 1). - ledger floor call sites unchanged: dshLedgerFloorTokens carries no lane-name check (#1729 guard is deliberately identity-blind, #2193). Step 2.5 (nudgeOn single point): - four hand-copied willInjectNudge conjunctions -> nudgeOn() nine-input pure function; responses' deliberate differences (compaction-trigger exemption, codex-intercept health window) are explicit inputs; openai/google's redundant shouldInject conjunct is subsumed by compressSurfaceOn. - 1024-point boolean cube + verbatim legacy formulas per lane pin equivalence. Structural guard extended: B-class sites carry no raw lane-name gates; every WIRE_CLIENTS entry needs a matches(). Zero wire byte changes (pure migration).
The agent-side consumer (src/agent/pi.ts) imported hostProfileFor from server/lane-decisions, whose preflight import drags acp-kernel and proxy server modules into dist/agent/pi.js / omp.js client-process bundles (measured: both doubled, ~1.33 MB -> ~2.79 MB). Move layer-1 HostProfile registry (table + resolver + ANONYMOUS) into src/host-profiles.ts with zero imports; lane-decisions re-imports/re-exports it; pi.ts imports the leaf directly. Structural guard pins host-profiles.ts import-free. Bundle sizes restored: pi.js 1330878 / omp.js 1330742 (master baseline 1329672 / 1329536; delta now only the ~1 KB leaf table).
ranxianglei
force-pushed
the
2026-10-17_lane-decisions-b
branch
from
October 17, 2026 06:56
7e37ab1 to
48ecfce
Compare
…se flakes
Windows runner flake: listen(0) can land in an OS-reserved port range and
emit error (EACCES/EADDRINUSE) instead of listening; events.once(server,
"listening") rejects on error, so a failed listen strands the test promise
("Promise resolution is still pending but the event loop has already
resolved") and cancels siblings. Retry ephemeral-port listens, destroy
keep-alive sockets in teardown (closeAllConnections), and bound every test
with a 60s timeout so any residual hang surfaces with a stack.
Owner
Author
|
ai: zhipuai-lb/glm-5.3 逐行审完,结论:可合(等 test 腿转绿)。四处 B 类迁移我对照 master 逐个验证了等价性,没有发现行为变化。 等价性核验(对照 origin/master):
两个非阻塞 nit:
CI:除 |
Closed
Contributor
📦 Merged Build PublishedThis merge to master was published as npm install -g billion-context@0.0.527-master.494571f # this exact build
npm install -g billion-context@master # always the newest merged build
|
Merged
This was referenced Oct 17, 2026
ranxianglei
pushed a commit
that referenced
this pull request
Oct 17, 2026
…wn flake, unrelated to this diff
This was referenced Oct 17, 2026
Merged
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #3482(#3417 收尾)。纯搬移,零 wire 字节变更。
Step 2:B 类站点迁移(四站全清)
prepare-anthropic提取门控改为laneDecisions.billingBlockWanted= profile 声明(wantsBillingBlock,dsh)或 wire 观察到块(billingBlockObserved,证据优先,与 toolsReachable 同形状)。wantsBillingBlock死属性落位为真实消费者。coworkTransportPossible进注册表(该传输是否可能);逐请求真相仍是环境观察ompCoworkTransportBypassesFetch(provider/api/代理 env)。stampPromptCacheKey的agent !== "omp"门 →hostProfileFor(agent).stampsBodyPromptCacheKey;pi 的头戳通道差异写进注册表注释。WIRE_CLIENTS注册表(codex=#150 任务 id 复用、claude-responses=#970 子代理共享会话 id,均instructionsFingerprintKeyed: true);instructionsFingerprintApplies只做信号观察,头名字面量只活在注册表。issue 表格前提修正:三处 ledger floor 调用点(prepare-openai:364 / responses:501 / google:305)不迁——
dshLedgerFloorTokens本无 lane 名查,metadata 键由 #1729 守卫写入,而该守卫故意 identity-blind(#2193:marker-decisive,任何车道发 dsh 形状的 compaction 调用都拒)。按 profile 门控会回归该设计并引入 corner case 的 wire delta。Step 2.5:nudgeOn 单点
四份手抄
willInjectNudge合取(就是 #3293 漂移的地方)收敛为nudgeOn()九布尔入参纯函数。三处差异全部显式化:compactionTrigger——仅 responses(hasCompactionTrigger(parsed.input)),其余三线无此概念传false;growthFoldingArmed(loopConfig, modelContextLimit × CODEX_COMPACT_HEALTH_RATIO),gate 只见布尔;shouldInject合取被compressSurfaceOn(≡ shouldInject && reach)吸收,纯冗余消除。等价性钉死:
tests/lane-decisions-b-class.test.ts1024 点布尔立方 × 四份旧公式逐字对照(旧公式从迁移前源码转录);三个有意差异各有独立钉测。结构守卫扩展
WIRE_CLIENTS每条目必须有matches()(防复制粘贴腐烂)。验证
destinationRoutedThroughProxy短路,干净 origin/master 同样红,CI 绿)。