作者在 OpenClaw 中提交了一个修复,针对使用嵌入式 harness 而非 codex 的用户解决缓存问题。据引用内容称,GPT-6.2 Astra 和 Sol 在 Responses API 的顶层指令字段中存在缓存失效 Bug,导致缓存命中率从 97.4% 降至 46.4%,且 OpenAI 诊断报告可能错误显示命中;目前的临时方案是将系统提示词放入输入端的首条 developer message 中。
提供了针对特定模型缓存 Bug 的修复方案及临时规避方法,可帮助开发者降低 API 成本。
昨天已在 OpenClaw 中落地了针对该问题的修复(针对少数使用嵌入式 harness 而非 codex 的用户,因为它是一个插件),大多数 harness 还没更新。
如果你本周 GPT-6.2 Astra 或 Sol API 的账单突然上涨,还有一个值得了解的缓存 bug。 OpenAI Codex issue #62312 发现,在 GPT-6.2 Astra 和 Sol 上,放在 Responses API 请求顶层 instructions 字段里的内容实际上不会被缓存。每一轮的缓存 token 数都保持为 0,尽管 OpenAI 自己的诊断工具错误地报告了缓存命中。 影响相当大。从 GPT-6.1 Sol 换到 6.2 Sol 后,实际缓存命中率从 97.4% 降到了 46.4%,意味着每一步都有 64K–72K 的系统 token 按全价计费。 OpenCode 已经有了变通方案:把系统提示词放到 input 中一条前置的 developer 消息里。
原文
If your GPT-6.2 Astra or Sol API bills suddenly went up this week, there's another caching bug worth knowing about. OpenAI Codex issue #62312 found that on GPT-6.2 Astra and Sol, anything placed in the top-level instructions field of a Responses API request isn't actually cached. It stays at 0 cached tokens on every turn, even though OpenAI's own diagnostics incorrectly report a cache hit. The impact is pretty big. Moving from GPT-6.1 Sol to 6.2 Sol dropped actual cache hit rates from 97.4% to 46.4%, meaning 64K–72K system tokens were billed at full price on every step. There's already a workaround in OpenCode: put the system prompt inside a leading developer message in input.
来源:Peter Steinberger · x.com