Skip to content

[PR] fix: stop takeover-broken banner false alarm from agentless sidecar lanes (#3651) - #3653

Merged
ranxianglei merged 8 commits into
masterfrom
2026-10-18_agentless-refusal-banner-floor
Oct 20, 2026
Merged

ranxianglei merged 8 commits into
masterfrom
2026-10-18_agentless-refusal-banner-floor

Conversation

@ranxianglei

@ranxianglei ranxianglei commented Oct 18, 2026 •

Copy link
Copy Markdown
Owner

Closes #3651

What

The #3581 visibility banner 「接管已失效:模型请求正在直连(不压缩)…」 fired as a false alarm on dsh desktop workers: by-design agentless lanes (dsh's title-gen sidecar et al.) refuse a handful of small one-shot calls per worker lifetime with no active initiator, and #3581 escalated that FIRST refusal immediately. Field evidence in #3651: exactly one refused sidecar call per short-lived worker boot while the main conversation compressed fine — the banner lit on every boot and its "restart the host" advice could never help.

The #3651 thread then set the reporting CONTRACT this PR converges on (owner directive): normal interceptions must stay silent; a report only exists for something broken, diagnosable, and actionable — with error text, impact scope, remedy, and a diagnostics-submission path to GitHub.

Changes (four labeled commits, plus two review fixes already on the branch)

  1. In-passing fix: paste-safe host-side logs (src/agent/host-log.ts, src/log-mask.ts): the paste-safe sink previously existed only on the proxy side; host-side event lines ([dsh-client] persistClientEvent) were written verbatim, which is how real non-public upstream hostnames leaked into the public log pasted in Model request is connecting directly (uncompressed) | 模型请求正在直连(不压缩) #3651. Host-side events now get the same treatment: non-public hosts → <private-host>, URL query strings dropped, loopback hosts kept verbatim so attach-target/pinned-origin diagnostics still identify bili itself.
  2. In-passing fix: durable trace for the See how to integrate the plugin that automatically disables dsh compression. | 自动关闭 dsh 压缩的插件看如何集成 #3354 overlay in non-web-app profiles (src/agent/dsh-native.ts): the web-profile note was the ONLY confirmation that the load-time compaction-disable overlay took effect, and it is scoped to profiles bundling @deepseek-ai/dsh-web-app — every other profile booted silently even though registerCompactionDisable runs unconditionally (field triage of Model request is connecting directly (uncompressed) | 模型请求正在直连(不压缩) #3651 could not tell "overlay registered" from "profile shape unconfirmed"). One once-per-process durable client event now records the non-web-app case, pointing at the fix(dsh): profile 层 patch 其实可以关掉 web profile 的原生自动压缩(#1772 结论修正)+ 一个会静默清空整个 preset 的写法坑 #2474 snapshot fallback and the 在bili网页配置界面支持关闭和开启dsh的自动压缩功能 #2028 allowDshCompaction interplay.
  3. Interim escalation floor for none episodes (src/agent/dsh-native.ts) — SUPERSEDED by commit 4: agentless refusals reported only after 3 cumulative, then doubling. Kept in history because the owner's contract comment landed mid-review; commit 4 removes the floor entirely per the contract ("正常拦截了就不应该报告").
  4. Diagnosable-failure reporting contract (src/agent/dsh-native.ts, src/agent/shared.ts, src/plugin.ts, src/server/attribution-status.ts, src/web/client.ts, src/web/i18n.ts, src/log-mask.ts), per the owner's four-point directive in Model request is connecting directly (uncompressed) | 模型请求正在直连(不压缩) #3651:
    • Normal interception = silence. Agentless (none) refusals NEVER call reportAttributionHealth anymore — no floor, no cadence. They keep their durable per-endpoint masked log line and local counters (recovery still resets them) and can no longer raise the banner under any circumstances.
    • Reported failures carry diagnostics. threw reports (the attribution lookup itself throwing — a genuine bug-shaped failure) now carry the error text (≤300 chars) and the masked endpoint (≤200 chars, loopback origins verbatim) end-to-end: plugin → admin handler → status store → wire. Cadence unchanged from #3581a (first refusal immediate, then doubling) plus the give-up latch.
    • Banner reworked around the payload. Instead of an opaque count line it shows: what failed (error line), impact scope (since when, how many requests went direct), concrete remedy (restart the host process), and copy-diagnostics / submit-diagnostics buttons wired to the existing /__bili/diagnostics endpoint (prefilled GitHub issue). zh/en copy rewritten accordingly.
    • Loopback exemption made shared and byte-stable. The loopback-verbatim rule moved into new maskUrlForDiagnostics/maskUrlsForDiagnostics in src/log-mask.ts (used by both the endpoint field and host-log events); loopback URLs are returned VERBATIM rather than re-serialized, because URL.pathname appends / to pathless URLs and would drift byte-pinned local-origin lines.

Behavior changes (disclosed)

Surface Old New Why
Attribution report, none episode first-refusal report (#3581) → ≥3 floor (interim, commit 3) never reported owner contract: normal interceptions must stay silent; agentless sidecar calls are by design and can never recover
Attribution report, threw episode first refusal + doubling, count only first refusal + doubling, count + error text + masked endpoint a report must be diagnosable, not just visible
Web banner content single line: agent + refused count + "restart the host" error line + impact scope (since/count) + remedy + copy/submit-diagnostics buttons (GitHub prefill) owner contract: actionable, with scope and an exit
Banner trigger conditions any degraded entry with refusals>0 while no live session unchanged (only threw episodes can now degrade an entry) availability signal stays live-bounded
Host-side log lines ([dsh-client] etc.) URLs verbatim (non-public hosts visible) non-public hosts masked, query strings dropped, loopback verbatim (byte-stable) log-paste leak found while triaging #3651
Host-side durable events in non-dsh-web-app profiles silent boot (no confirmation the #3354 overlay registered) one once-per-process trace line with #2474 fallback pointer field verification of the load-time disable needs a confirmation trace in every profile shape

No new config surface. No request-routing change — only when the degradation report fires and what it carries. Wire addition is additive (optional error/endpoint fields on the existing /__bili/plugin/attribution payload; older proxies ignore them).

Tests

@github-actions

github-actions Bot commented Oct 18, 2026 •

Copy link
Copy Markdown
Contributor

📦 Built Package Artifact

Branch: 2026-10-18_agentless-refusal-banner-floor (887e481)

Option A — Install this exact build (recommended)

npm install -g billion-context@0.0.4660-pr.3653.bff9c85

This exact version is immutable and reproducible. The rolling pr tag tracks the newest test build across all PRs.

Option B — Download artifact

  1. Download the artifact from the Actions run
  2. Extract the tarball and install:
tar xzf billion-context-pr3653.tgz
npm install -g package

Install instructions are refreshed on each push.

@ranxianglei ranxianglei changed the title fix: stop takeover-broken banner false alarm from agentless sidecar lanes (#3651) [PR] fix: stop takeover-broken banner false alarm from agentless sidecar lanes (#3651) Oct 18, 2026
@ranxianglei

Copy link
Copy Markdown
Owner Author

🤖 Powered by ework · qwen3.8-27b

[bot] 🏷 (ai: vllm-qwen/qwen3.8-27b)

收到,开始审核 PR #3653。

查重:不重复。 无其他在途 PR/issue 修同一误报缺陷。相邻条目核对过:#3622(dsh-native takeover health 上 /__bili/status + 面板)是可见性功能扩展、#3593/#3581 是横幅机制本身(已合入)、#3578 是真失效形态的另一面——都不是本 PR 的重复。注意 #3622 与本 PR 同触 src/agent/dsh-native.ts,合并顺序可能有热点文件交互,审核时会一并看。

正在拉分支独立审 diff(不沿用 #3651 线程结论),随后按八问给完整审核意见。

ranxianglei pushed a commit that referenced this pull request Oct 18, 2026
…w finding on #3653)

The paste-safe-sink commit swapped the fully-expanded ::1 literal
(0:0:0:0:0:0:0:1) for 0:0:0:0 (fully-expanded ::), silently flipping two
free-text edge cases vs master with no stated reason: expanded ::1 in
prose would now be masked, expanded :: exempted. Restoring the original
literal keeps this PR's log-mask change purely additive (export only).
ranxianglei pushed a commit that referenced this pull request Oct 18, 2026
…ew finding on #3653)

The new floor test covered pure-none episodes only. If a later edit drops
the (changed && state === threw) clause, a silent sub-floor none episode
flipping to an internal error would stay silent until doubling — exactly
the #3581a contract this PR claims to preserve. Extended the #3651 test:
sub-floor none x2 → threw must report immediately ({state:threw, refusals:7}).
ranxianglei pushed a commit that referenced this pull request Oct 18, 2026
…w finding on #3653)

The paste-safe-sink commit swapped the fully-expanded ::1 literal
(0:0:0:0:0:0:0:1) for 0:0:0:0 (fully-expanded ::), silently flipping two
free-text edge cases vs master with no stated reason: expanded ::1 in
prose would now be masked, expanded :: exempted. Restoring the original
literal keeps this PR's log-mask change purely additive (export only).
ranxianglei pushed a commit that referenced this pull request Oct 18, 2026
…ew finding on #3653)

The new floor test covered pure-none episodes only. If a later edit drops
the (changed && state === threw) clause, a silent sub-floor none episode
flipping to an internal error would stay silent until doubling — exactly
the #3581a contract this PR claims to preserve. Extended the #3651 test:
sub-floor none x2 → threw must report immediately ({state:threw, refusals:7}).
@ranxianglei
ranxianglei force-pushed the 2026-10-18_agentless-refusal-banner-floor branch from 3340cc7 to 8725583 Compare October 18, 2026 05:38
@ranxianglei

Copy link
Copy Markdown
Owner Author

🤖 Powered by ework · qwen3.8-27b

(ai: vllm-qwen/qwen3.8-27b)

冲突已解决:分支已 rebase 到最新 master(8396c432)并 force-push,新 head 8725583f,GitHub 已确认 mergeable: true(当前 blocked 仅因等 CI/review,冲突状态已清除)。

结构化八问

  1. 是什么问题:PR [PR] fix: stop takeover-broken banner false alarm from agentless sidecar lanes (#3651) #3653 的分支与 master 分叉,GitHub 报 dirty(合并冲突),CI 无法在干净基线上跑。
  2. 什么原因导致的:纯文本冲突、无语义冲突——master 侧([Bug][dsh-native] 运行中自动换版后接管静默失效:旧 fetch hook 持有已 dispose 的 ctx,currentInitiator() 永久 threw,重启才恢复 #3578/Test Blind Spot Retrospective: Reinforcing Negative Assertion Discipline, Tightening Fake Upstream Strictness, Thin Inst | 测试盲区复盘:补反向断言纪律、假上游严格化、薄安装冒烟、形态矩阵与生命周期覆盖 #3617-E③)和 PR 侧都在 tests/dsh-native.test.ts 的同一个锚点(「压缩接管失效后完全静默:面板与 /__bili/status 看不出压缩已停,用户全价直连直到重启才恢复 #3581 recovery clears…」测试之后、「方式一安装的dsh 原生插件:llm-pi-ai 传输(OpenAI SDK + options.fetch 注入)绕过 globalThis.fetch 拦截,模型请求不进代理、压缩完全不生效 #1158 apply() persists bootstrap failures」之前)各自插入了不同的新测试:master 插入「[Bug][dsh-native] 运行中自动换版后接管静默失效:旧 fetch hook 持有已 dispose 的 ctx,currentInitiator() 永久 threw,重启才恢复 #3578 transition contract」真实 /__bili/status 端到端测试,PR 插入「Model request is connecting directly (uncompressed) | 模型请求正在直连(不压缩) #3651 agentless none-lane floor」测试;第 4 个 commit 又把 Model request is connecting directly (uncompressed) | 模型请求正在直连(不压缩) #3651 测试改名(加 none→threw 断言),在同一位置二次撞车。README×2、src/agent/dsh-native.ts 均自动合并成功。
  3. 影响范围与严重程度:仅 PR 分支自身;不触碰任何用户可见行为或已发布代码。不解决则 CI 全红、PR 无法合并。
  4. 怎么修复的:rebase 到 master 后取并集解法——master 的 [Bug][dsh-native] 运行中自动换版后接管静默失效:旧 fetch hook 持有已 dispose 的 ctx,currentInitiator() 永久 threw,重启才恢复 #3578 过渡契约测试原样保留在前,PR 的 Model request is connecting directly (uncompressed) | 模型请求正在直连(不压缩) #3651 floor 测试保留其后且采用其更新后的标题(含 none→threw 立即上报断言);两个测试各测各的契约,互不干扰。未改动任何逻辑行,四个 commit 内容逐字保留。
  5. 是否有回归问题:无。rebase 后本地验证:typecheck ✅、build ✅、定向测试 tests/dsh-native.test.ts + tests/log-mask.test.ts 79/79 通过;git diff --stat origin/master..HEAD 的文件集与原 PR 完全一致(6 files, +126/−10)。全量回归交给 CI。
  6. 是否破坏缓存:不涉及。
  7. 是否改了设计方向:不涉及。
  8. 是否引入了新的配置:不涉及。

收工判定:冲突闭环,等 CI 绿后即可按原 PR 描述合入(仍需人工 merge)。

@ranxianglei

Copy link
Copy Markdown
Owner Author

🤖 Powered by ework · qwen3.8-27b

(ai: vllm-qwen/qwen3.8-27b)

独立审核完成(⓪ 结论由 diff 与代码路径独立产出,未复读 #3651 侧分析)。审核中在 PR 分支直接修了两处小问题(独立标注 commit),另立了一个无关发现(#3656)。

审核过程摘要

  • 查重:不重复(见首评);修复方向正确——在决策点(host 侧升级策略)修,不是下游过滤报告;proxy 侧 latest-wins 展示层不动。
  • 对 none/threw episode 全谱系按代码逐条推演:纯 none = 静默×2 → 报@3 → 翻倍 3→6→12 ✓;纯 threw = 立即@1 → 翻倍@2… 与 #3581a 原契约完全一致 ✓;none→threw 过渡 = 立即上报 ✓;threw→none = 变更报告抑制到下一次翻倍/floor(显示滞后可接受:none 比 threw 轻,且恢复会很快以 ok 覆盖)✓;恢复复位 ✓。
  • 请求路由未动:gate 照旧拒绝直连,只有降级报告时机变了;give-up latch(threw settle-retry 阶梯)未触碰。
  • 测试有效性:新回归测试断言有牙(floor 下零报告 / 跨 floor 精确 {state,refusals} / 翻倍延续 / 恢复复位),bug 回归时抓得住。

审核中发现的两处小修(已推 PR 分支,独立 commit)

  1. fix(log-mask): restore master's expanded IPv6 loopback literal — paste-safe sink 改动里把 isLoopbackIp 的展开形字面量 0:0:0:0:0:0:0:1(展开的 ::1)换成了 0:0:0:0(展开的 ::),相对 master 静默改变了两个自由文本边界语义(prose 里的展开 ::1 会被 mask、展开 :: 被豁免),PR 未披露。已还原 master 原字面量,使本 PR 的 log-mask 改动变成纯增量(仅 export)。
  2. test(dsh-native): pin the none→threw immediate-report invariant — 原测试只覆盖纯 none episode,没有任何断言钉住 (changed && state === "threw") 子句:若日后有人删掉它,静默 sub-floor none episode 中途转内部错误将保持静默直到翻倍——正是本 PR 声称保留的 #3581a 契约。在 Model request is connecting directly (uncompressed) | 模型请求正在直连(不压缩) #3651 测试里补了混合 episode 断言(sub-floor none×2 → threw 必须立即报 {state:"threw", refusals:7})。

行为变更清单(独立核验,与 PR 正文表格一致)

Surface Old New
Banner 触发,none episode 首次拒绝即报 ≥3 次累计拒绝后报,然后翻倍(3→6→12…)
Banner 触发,threw episode 首次拒绝即报 + 翻倍 不变
Host 侧日志行([dsh-client] 等) URL 原文写出 非公开 host 打码、query 丢弃、loopback 保留原文

已知残余权衡(可接受):每 worker 生命周期合法拒绝 >3 次的车道仍会亮 banner——现场证据 sidecar ≤2 次/worker,floor=3 留了一倍余量;若未来出现合法拒绝更多的宿主,调 ATTR_NONE_ESCALATION_FLOOR(模块常量,不进配置面,与同文件 DEFAULT_THREW_RETRY 待遇一致)。

回归审查(既有行为清单,逐项)

  • #3581a threw cadence:测试断言未改且通过(immediate@1、doubling@2、latch≥3)✓
  • 恢复复位(noteAttrRecovery):不变,有测试 ✓
  • give-up latch / threw settle-retry 阶梯:未触碰 ✓
  • proxy /__bili/status attribution 展示:generic latest-wins,不受 host 侧 floor 影响 ✓
  • proxy 侧日志 masking 路径:未动;host 侧新增 URL masking(有意变更,已披露)✓
  • isLoopbackIp 自由文本豁免语义:PR 中有漂移(见小修 1),已还原 ✓
  • 请求路由 / wire 形态 / 配置面:无变化 ✓
  • 高危模式过一遍:无 fail-fast→吞错(每次拒绝仍写 durable per-endpoint 日志行)、无表外阈值漂移、无输出格式变化 ✓

测试与 CI 状态:本地 typecheck clean + 定向套件 78/78(含扩展后的 #3651 测试、log-mask 全套)。CI:原 head 5cc9bff 全绿(30/30 success/skip);审核期间分支已被 rebase 到最新 master(现 head 8725583fd,包含上述两处审核修复,我已核对 rebase 后 hunks 与我本地验证过的内容一致),rebased head 上全部 e2e 车道绿,核心 test matrix 在跑。

无关发现(已单独立项,不阻塞本 PR):手动触发的 ci-gate-plugins(真模型插件门控车道)今日起在 master 和多条 PR 分支上每次 dispatch 都失败——已立 #3656([no-dispatch],沙箱内读不到 job 日志,需人工看 Actions)。该 workflow 无 push 触发器、不在 required checks,不影响本 PR 合并。

结构化八问

  1. 是什么问题:dsh desktop worker 的 agentless sidecar 车道(title-gen 等)每个 worker 生命周期合法拒绝少数一次性调用,压缩接管失效后完全静默:面板与 /__bili/status 看不出压缩已停,用户全价直连直到重启才恢复 #3581 的接管失效 banner 却把「首次拒绝」当作接管坏掉的证据 → 短命 worker 每次启动都误报,且「重启宿主」建议永远无效。
  2. 什么原因导致的:压缩接管失效后完全静默:面板与 /__bili/status 看不出压缩已停,用户全价直连直到重启才恢复 #3581 升级策略没区分证据类别——合法 agentless 拒绝(none)与内部错误(threw)共用「首次即升级」规则;sidecar 车道永不恢复、必然命中。根因在升级策略层,不在 wire/路由层。
  3. 影响范围与严重程度:跑短命 worker 的 dsh desktop 用户每次启动见误报(误导、错误恢复指引);主会话压缩全程不受影响。严重度 = 体验/信任瑕疵,无可用性、无数据影响。
  4. 怎么修复的:给 none 证据类加 floor=3(累计 3 次后才上报,之后沿用既有翻倍节奏),threw 保持立即上报+翻倍不变;修在 host 侧决策点,proxy 仍是哑展示层。顺带把 host 侧日志同一类粘贴泄露堵上(非公开 host 打码/query 丢/loopback 留原文)。
  5. 是否有回归问题:无(逐项清单见上;发现的唯一漂移——log-mask 字面量互换——已当场修掉并还原 master 语义)。
  6. 是否破坏缓存:不涉及——无缓存/重试游标/去重键受影响(threw settle-retry 阶梯未动)。
  7. 是否改了设计方向:否——架构不变(host 报告、proxy 展示),只是同一机制内细化了证据类别区分。
  8. 是否引入了新的配置:无配置面变化;仅模块常量 ATTR_NONE_ESCALATION_FLOOR = 3(不可配置,与文件内其他常量待遇一致)。

判定:核心 test matrix 转绿后可合(e2e 车道已在 rebased head 全绿,原 head 曾全绿;两处审核小修已含在分支里)。合并是 human-only——CI 转绿后请自行合并:#3653

@ranxianglei

Copy link
Copy Markdown
Owner Author

🤖 Powered by ework · qwen3.8-27b

(ai: vllm-qwen/qwen3.8-27b)

增量复核:第三个标注提交 01878d7de(非 web-profile 的 #3354 overlay 落盘痕迹)+ CI 终态。

对第三提交的独立审核(不沿用上一轮结论,逐条重验):

八问(本轮增量)

  1. 是什么问题:See how to integrate the plugin that automatically disables dsh compression. | 自动关闭 dsh 压缩的插件看如何集成 #3354 的 load-time compaction-disable overlay 在非 web profile 里注册了却零痕迹,现场排障无法区分「overlay 已注册」和「profile 形状未确认」。
  2. 什么原因导致的:唯一的确认输出(web-profile note)被 scope 在 bundling @deepseek-ai/dsh-web-app 的 profile,而 overlay 注册本身无条件执行。
  3. 影响范围与严重程度:仅可观测性缺口,影响所有非 web dsh profile 的现场排障;无功能/路由影响。
  4. 怎么修复的:对该情形补一条每进程一次的 durable client event,带 fix(dsh): profile 层 patch 其实可以关掉 web profile 的原生自动压缩(#1772 结论修正)+ 一个会静默清空整个 preset 的写法坑 #2474 全量快照回退指引与 在bili网页配置界面支持关闭和开启dsh的自动压缩功能 #2028 allowDshCompaction 交互说明。
  5. 是否有回归问题:审过的既有行为——web-profile note 路径(不变)、bundles===undefined 双沉默(保持)、一次性不重复(新增断言钉住)、新行同样经过 paste-safe 掩码管线(文本无 URL,无副作用)。未发现破坏。
  6. 是否破坏缓存:不涉及(纯 durable 日志)。
  7. 是否改了设计方向:不涉及。
  8. 是否引入新配置:无(模块级行为,与 webProfileWarned 先例一致,不做成配置面)。

行为变更披露(增量):非 web dsh profile 启动日志从「静默」变为「每进程一行 durable trace」(纯增量可观测性)。

CI 终态:

判定:内容侧三轮审核全部通过(floor 机制 + 两处审核修正 + 第三提交),分支头全绿。merge-ref run 转绿后即可合,合并仍由人工执行。

awork added 8 commits October 20, 2026 14:07
In-passing fix found while working #3651: the paste-safe sink only existed on the proxy side. Host-side event lines ([dsh-client]/[native-client] persistClientEvent) were written verbatim, so a user pasting bili.log into a public issue leaked real non-public upstream hostnames (opencode.ai, zcode.z.ai) even though the proxy-side lines showed <private-host>. logHostEvent now applies maskUrlsLoopbackSafe(maskIpsInText(redactSecretsInText(...))) with loopback hosts exempt so attach-target/pinned-origin diagnostics keep identifying bili itself.
…ion floor (#3651)

The #3581 takeover-broken banner fired on the FIRST none-state refusal, but by-design agentless lanes (dsh's title-gen sidecar et al.) refuse a handful of small one-shot calls per host lifetime and can never recover — field shape from #3651: exactly one refused sidecar call per short-lived worker boot while the main conversation compressed fine, banner lit on every boot, 'restart the host' advice could not help. none episodes now escalate only past ATTR_NONE_ESCALATION_FLOOR (3 cumulative refusals), then keep the doubling cadence; threw keeps its original #3581a contract (first refusal immediate + doubling) since an exception in the attribution lookup is internal error, never legitimate agentless evidence. A genuinely broken takeover refuses every model call, so any real episode crosses the floor within the first user turn.
…w finding on #3653)

The paste-safe-sink commit swapped the fully-expanded ::1 literal
(0:0:0:0:0:0:0:1) for 0:0:0:0 (fully-expanded ::), silently flipping two
free-text edge cases vs master with no stated reason: expanded ::1 in
prose would now be masked, expanded :: exempted. Restoring the original
literal keeps this PR's log-mask change purely additive (export only).
…ew finding on #3653)

The new floor test covered pure-none episodes only. If a later edit drops
the (changed && state === threw) clause, a silent sub-floor none episode
flipping to an internal error would stay silent until doubling — exactly
the #3581a contract this PR claims to preserve. Extended the #3651 test:
sub-floor none x2 → threw must report immediately ({state:threw, refusals:7}).
…web-app profile (#3651)

The web-profile note was the only confirmation that the load-time
compaction-disable overlay took effect, and it is scoped to profiles
bundling @deepseek-ai/dsh-web-app — every other profile boots silently
even though registerCompactionDisable runs unconditionally. Field
triage (#3651) could not tell "overlay registered" from "profile
shape unconfirmed" because of this gap. One once-per-process durable
client event now records the non-web-app case (with the #2474 fallback
pointer and the #2028 allowDshCompaction interplay noted).

Closes nothing by itself — third labeled commit of the #3651 PR.
…3651)

Owner contract from the #3651 thread: normal interceptions must stay silent;
a report only exists for something broken, diagnosable, and actionable.

- agentless 'none' refusals (by-design sidecar/agentless lanes) NEVER call
  reportAttributionHealth anymore — the interim escalation floor is dropped;
  they keep their durable per-endpoint masked log line and local counters
  (recovery still resets them). They can no longer raise the banner.
- 'threw' reports now carry diagnostics: the error text (<=300 chars), the
  masked endpoint (<=200 chars, loopback origins verbatim), first-seen time
  and count — end to end (plugin -> admin handler -> status store -> wire).
- The banner is reworked around that payload: what failed (error line),
  impact scope (since when, how many requests went direct), concrete remedy
  (restart the host), and copy-diagnostics / submit-diagnostics buttons
  (prefilled GitHub issue via the existing /__bili/diagnostics endpoint).
- Loopback exemption moved into shared maskUrlForDiagnostics/maskUrlsForDiagnostics
  (verbatim, not re-serialized: URL.pathname would append '/' to pathless
  URLs and drift byte-pinned lines); host-log events use it too.
Internal-only after the loopback exemption moved into maskUrlForDiagnostics;
no external importer remains.
…ch gate (#3653)

Rebase artifact: master's #3806 made the web-profile note conditional on the
#3354 overlay latching (cordis on/reflect present); a hook-less host now gets
the ARMED alarm instead. The bare subcase keeps its original purpose (the
non-inject direct profileContext bundles path) by supplying minimal no-op
hooks so the passive note is what's asserted.
@ranxianglei
ranxianglei force-pushed the 2026-10-18_agentless-refusal-banner-floor branch from 813e18e to 887e481 Compare October 20, 2026 06:53
@ranxianglei
ranxianglei merged commit c4f2518 into master Oct 20, 2026
44 checks passed
@github-actions

Copy link
Copy Markdown
Contributor

📦 Merged Build Published

This merge to master was published as 0.0.653-master.c4f2518 (rolling master tag).

npm install -g billion-context@0.0.653-master.c4f2518  # this exact build
npm install -g billion-context@master  # always the newest merged build

npm view billion-context@master prints the current version at any time.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Model request is connecting directly (uncompressed) | 模型请求正在直连(不压缩)

1 participant