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
[Bug][kernel] openaiToCore reads only reasoning_content, so a replayed history that carries the reasoning alias loses its thinking block | 请求侧只读 reasoning_content,回传 reasoning 别名的历史会静默丢思维链 #7435
Activity
ranxianglei commentedon Nov 21, 2026
🔶 需要决策
查重:不重复。本 issue 是 #7432(响应侧
delta.reasoning丢帧,已由 PR #7433 修复)的请求侧对应面——openaiToCore只读reasoning_content,回传reasoning别名的历史会静默丢思维链。已检索 open+closed 的 issue/PR,无其他条目覆盖这个请求侧 kernel 缺陷。背景一句话:kernel 的 OpenAI wire 解析入口
openaiToCore(kernel/src/wire/openai.ts:245)只读规范字段reasoning_content;当客户端把历史 assistant 消息的思维链回传成别名reasoning(Ollama Cloud / vLLM / sglang / Magpie 这类 OpenAI-wire 形状)时,core 里产生 0 条 reasoning 消息,coreToOpenai回传的 assistant 只剩["role","content","tool_calls"]——思维链在请求侧被静默丢弃,无日志、无 400。已验证(master
1e357bf2d,与 reporter 版本6a641f378该函数逐字节一致):reasoning_content(规范)["role","content","tool_calls","reasoning_content"]reasoning(别名)["role","content","tool_calls"]["role","content","tool_calls"]待决问题:这是 kernel 边界改动(
openaiToCore是 plugin/proxy 两条车道共用的唯一解析入口),按 Kernel Boundary 规则 1 需要 owner 预先批准才能动kernel/**。是否批准按下述方案实现?选项:
reasoning_content→reasoning→reasoning_text(取第一个「存在且非空」字符串,规范名优先),fieldPresent/blankEcho按命中的字段名判定(别名键存在但为空 → 同样回显reasoning_content: ""),写出侧coreToOpenai保持reasoning_content不变,双向回归测试(Test Blind Spot Retrospective: Reinforcing Negative Assertion Discipline, Tightening Fake Upstream Strictness, Thin Inst | 测试盲区复盘:补反向断言纪律、假上游严格化、薄安装冒烟、形态矩阵与生命周期覆盖 #3617 gate test discipline)。代价:小 kernel 改动 +kernel/package.json版本 bump + human-only review 档把关合并。reasoning别名(不加reasoning_text)。代价:更窄,直接命中本次报的 bug;但reasoning_text若日后出现就再破一次、还得再动 kernel。我的推荐:A。打到根因(kernel wire 规范化本应接受别名),未来兼容,且 human-only review 档把关合并;PR 会写
kernel-change: <reason>、bump 版本、并推演 plugin / proxy 两种模式。不决定的默认行为:issue 保持 open(needs-decision 标签),kernel 不动,bug 持续——用
reasoning别名的客户端思维链在请求侧静默丢失。响应侧(PR #7433)已修,不受影响。triage 标签(已打):
bug+scope/kernel+p2+deepseek-harness。两点说明:deepseek-harness(reporter 的 DeepSeek Harness 0.2.2-rc.5),而非 issue 建议的dsh——repo 有专门的 deepseek-harness 标签,更精确。版本勘误:reporter 报的 kernel 版本是 0.0.201,但其 release commit
6a641f378实际是 0.0.198、master 是 0.0.200——该函数逐字节一致,不影响判定。