You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Plugin lanes: pin identity to client msgids, render outbound from the server-owned history | 插件车道服务端正史:消息身份钉在客户端 id 上,出站前缀由正史渲染 #4491
changed the title [-]插件车道服务端正史:消息身份钉在客户端 id 上,出站前缀由正史渲染 | Plugin lanes: pin identity to client msgids, render outbound from the server-owned history[/-][+]Plugin lanes: pin identity to client msgids, render outbound from the server-owned history | 插件车道服务端正史:消息身份钉在客户端 id 上,出站前缀由正史渲染[/+]on Oct 24, 2026
Activity
[-]插件车道服务端正史:消息身份钉在客户端 id 上,出站前缀由正史渲染 | Plugin lanes: pin identity to client msgids, render outbound from the server-owned history[/-][+]Plugin lanes: pin identity to client msgids, render outbound from the server-owned history | 插件车道服务端正史:消息身份钉在客户端 id 上,出站前缀由正史渲染[/+]ranxianglei commentedon Oct 24, 2026
(ai: vllm-qwen/qwen3.8-27b)
查重: 不重复。 本 issue 是 #4316(已关闭,三层方案 owner 定稿)的登记子项——层 1+2 的插件车道落地。依赖 PR #4335(blocks start_seq/end_seq 真值)、#4346(ledgerSeq 直连+快照渲染盖章)、#4395(行身份剥 wireIndex/tombstone/谱系/seam 指纹)均已合入 master(当前 HEAD
02f544da0);open issue/PR 中未发现并行的「插件车道服务端正史」工作。增量车道(#3248/__bili/plugin/turn)与快照渲染(#3756)是既有设施,本 issue 是接线而非重造。标签:
pidshopencodeompscope/kernelp2(覆盖四个插件车道;领域是消息身份/折叠记账=kernel scope;功能请求不打 bug;现状可用但有 churn 重烧成本与编号换血 → p2)。主题类别:M(跨车道功能提案)。Triage(功能类三步审核,独立做过):
x-bili-plugin-turn,strict ack 契约已在);②服务端正史复用统一存储 v8 行身份底座(Four storage-layer defects: identity hash contaminated with positional metadata (truncation triggers identity swap) / sw | 存储层四缺陷:身份哈希掺位置元数据(截断即换血)/清扫删除回退历史/渲染接缝图片只比长度/fork 谱系死列 #4390/[PR] storage: position-independent row identity + historian tombstones (#4390) #4395:messages 表 append-only + tombstone/reactivate-in-place,msg_id列已存在,msgid pin = 把该列的所有权从内容哈希改为客户端 id,不做双钥);③出站渲染复用 D 引擎(Snapshot rendering: proxy-lane outbound is now rendered authoritatively server-side; existing sessions are immune to ker | 快照渲染:proxy 车道出站从服务端正史渲染,存量会话对内核升级免疫(#3752 根治) #3756 快照渲染机制 + 统一存储读路径);④压缩记账 [PR] #4316 Layer 3 (number directly mapped to canonical seq) PR 1/3: Fold-overwrite into real seq range | #4316 层3(编号直连正史 seq)PR 1/3:折叠覆盖写入真实 seq 区间 #4335/[PR] storage: seq ledger foundations — block interval bounds + ledgerSeq ref stamping (#4316 layer 3, phase 1) #4346 已落地;⑤降级 = shim try/catch 回现行为,恢复后对账由 id 集合代数天然完成。不发明新架构。前置验证:宿主 id 可达性审计表还是空的——这是本 issue 自己的研究项,我会在实现中把 pi/opencode/dsh/omp 四行填掉(判定口径:id 生成位置、切模型/undo 是否稳定、fetch 拦截点是否拿得到 id)。dsh 那行的「存疑」(id 在宿主会话库,拦截点只见序列化 body)如果坐实,dsh 就不具备 msgid pin 条件,降级路径兜底,我会在结论里写清。
执行计划(先 RED 后 GREEN,一个闭环 PR,Closes #4491):
POST /__bili/plugin/render {conversationId, untilSeq}返回服务端渲染前缀(复用 D 引擎读路径 + 既有 cache marks);配置面(issue 即申请,定稿含此门):新增 rollout 门
pluginLaneServerHistory,默认 0%(行为零漂移,旧客户端字节级不变);envBILI_ROLLOUT_PLUGIN_LANE_SERVER_HISTORY> configrollout.features.pluginLaneServerHistory(bool/percent)> 分桶。PR 描述会带完整的 config surface 一节。开始动工。先做服务端机制(S1–S4)+ 门 + RED/GREEN 测试桩,再填审计表,最后接 pi shim(S5/S6)。
ranxianglei commentedon Oct 24, 2026
(ai: vllm-qwen/qwen3.8-27b)
服务端核心已落地,PR:**#4505 #4491)。默认 rollout 0%,放量前零行为变化。
八问
biliMsgIds通道钉身份(上游转发前一律剥除、严格校验、投毒形态硬失败)/ 统一存储为唯一真相((conversationId, seq))/POST /__bili/plugin/render返回正史的纯函数输出(折叠区收敛为摘要锚点,失步一律降级不猜:关=404、存储不可读/冷会话/行坏=503)/ 代数层判追加·消失原因(compressed vs deleted)·世代切换(store 侧的机械行操作——append/tombstone/reactivate/分支视图——[PR] #4316 Layer 3 (number directly mapped to canonical seq) PR 1/3: Fold-overwrite into real seq range | #4316 层3(编号直连正史 seq)PR 1/3:折叠覆盖写入真实 seq 区间 #4335/[PR] storage: seq ledger foundations — block interval bounds + ledgerSeq ref stamping (#4316 layer 3, phase 1) #4346/[PR] storage: position-independent row identity + historian tombstones (#4390) #4395 已具备,本 PR 只加判断层)/ 增量车道通告serverHistory能力。打桩 S1–S4、S6 全绿,S5 服务端半绿(见下)。rollout.features.pluginLaneServerHistory(默认 0)+ envBILI_ROLLOUT_PLUGIN_LANE_SERVER_HISTORY,en+zh CONFIGURATION.md 已文档化;本 issue 即该门的签批申请,PR 内附 config surface 专节。宿主 id 审计(前置验证)结果:
packages/ai/src/types.ts:UserMessage/SystemMessage/ToolResultMessage 均无 id;AssistantMessage.responseId? 只是可选的 provider 侧标识,非宿主稳定身份。agent loop 到 LLM 调用边界才转 wire 消息,before_provider_request拦截点拿不到稳定消息 id。issue 表里「插件 API 层(CoreMessage.id)」在 pi 源码中不存在。要钉身份需要上游宿主改动(宿主盖章 id),客户端侧伪造 id 属于掩盖,不做。结论:暂无宿主有可用的 id 通道,所以本 PR 交付通用服务端核心(hermetic 测试钉死),不接任何宿主 shim;第一个消费者等审计落点。后续(已列 PR,不捆绑):① 首个宿主 shim 接线(被审计阻塞);② tombstone 原因落 dead_refs(需 schema 迁移,v1 先走日志+元数据计数器);③ 渲染前缀 cache 标记回放(v1 有意不带)。
test(lane): msgid lane-flow stakes + gate fixes on the server-history…
feat: plugin-lane server-owned history — msgid pinning, transcript re…
test(lane): msgid lane-flow stakes + gate fixes on the server-history…
ranxianglei commentedon Oct 24, 2026
四宿主接线已交付:PR #4523(dsh=llm/stream ALS 作用域/pi=扩展层 CoreMessage.id/opencode=V1 messages.transform/omp=getBranch 快照+对齐;全或无降级纪律+omp msgidClaims 防重试 400;四套桩 4+5+5+6 例全绿,组装分支全家复验绿)。
接线落地后 #4491 剩余:rollout 开闸(本机狗粮→灰度 1%→5%→25%→100)与 #3464 收尾(fork 宿主 id↔bili ref 映射+字节漂移金桩)。opencode V2 http.request 拿不到 id=已知最弱一环(见 #4491 审计),V2 形状降级内容派生。
19 remaining items
docs: message-identity hierarchy is now msgid > order > hash (ranxian…
feat(fastpath): msgid identity channel x-bili-pf-tail-ids (prevId + n…
feat(fastpath): one watermark channel for every plugin lane (#5403/#5418
#5719: sessionid+msgid last-resort identity rung — re-anchor instead …
#5719: sessionid+msgid last-resort identity rung — re-anchor instead …
feat: snapshot-table compression foundation — the six-stage pipeline (#…
feat: snapshot-table compression foundation — the six-stage pipeline (#…
feat: snapshot-table compression foundation — the six-stage pipeline (#…
msgid: wire dsh full-resend turns onto the biliMsgIds envelope (#6525)
feat: snapshot-table compression foundation — the six-stage pipeline (#…
feat: snapshot-table compression foundation — the six-stage pipeline (#…
feat: snapshot-table compression foundation — the six-stage pipeline (#…
fix(storage): gate the blind pin on content-derived ids; adapt tests …
fix(storage): gate the blind pin on content-derived ids; adapt tests …
fix: first-claim msgid negative guard — refuse raw claim on zero stor…