gpt-5.5 1M上下文 Bug
- 系统设置中 设置了context 1M 处理方式为透穿 不处理
- config.toml中设置了 model_context_window = 1000000 model_auto_compact_token_limit = 665000
- 新开窗口,设置gpt-5.4模型,发送hello,执行/status, 输出97% left (38.1K used / 950K)
- 设置模型为gpt-5.5 xhigh, /status输出100% left (0 used / 1M),发送hello,再次执行/status, 输出89% left (39.5K used / 258K)
问题定位了,codex的问题,内部强制了上下文最大是27200 codex cli执行: codex debug models --bundled | jq '.models[] | select(.slug=="gpt-5.5") | {slug, context_window, max_context_window}' codex app执行: /Applications/Codex.app/Contents/Resources/codex debug models --bundled | jq '.models[] | select(.slug=="gpt-5.5" or .slug=="gpt-5.4") | {slug, context_window, max_context_window, auto_compact_token_limit, effective_context_window_percent}' 能看到 { "slug": "gpt-5.5", "context_window": 272000, "max_context_window": 272000 } 解决方案: 执行命令: codex debug models --bundled 2>/dev/null | jq '(.models[] | select(.slug=="gpt-5.5") | .context_window) = 1000000 | (.models[] | select(.slug=="gpt-5.5") | .max_context_window) = 1000000 | (.models[] | select(.slug=="gpt-5.5") | .auto_compact_token_limit) = 665000 ' > /Users/shentengfei/.codex/model_catalog_gpt55_1m.json 修改~/.codex/config.toml,在文件顶部添加: model_catalog_json = "/Users/shentengfei/.codex/model_catalog_gpt55_1m.json"
实测上述方案无效。上游还是会打回。大家还是把config.toml中配置改小一点,这样还能压缩一下
实测上述方案无效。上游还是会打回。大家还是把config.toml中改配置小一点,这样还能压缩一下
有效的,你还需要在~/.codex/config.toml加上model_catalog_json = "/Users/YOUR_NAME/.codex/model_catalog_gpt55_1m.json"
实测上述方案无效。上游还是会打回。大家还是把config.toml中改配置小一点,这样还能压缩一下
有效的,你还需要在~/.codex/config.toml加上model_catalog_json = "/Users/YOUR_NAME/.codex/model_catalog_gpt55_1m.json"
我配置了,虽然窗口context会变成1M, 但是如果你一直运行, 超过272KB,上游会打回的。
实测上述方案无效。上游还是会打回。大家还是把config.toml中改配置小一点,这样还能压缩一下
有效的,你还需要在~/.codex/config.toml加上model_catalog_json = "/Users/YOUR_NAME/.codex/model_catalog_gpt55_1m.json"
我配置了,虽然窗口上下文会变成1M,但是如果你一直运行,超过272KB,上游会打回的。
哦哦,谢谢解答
实测上述方案无效。上游还是会打回。大家还是把config.toml中改配置小一点,这样还能压缩一下
有效的,你还需要在~/.codex/config.toml加上model_catalog_json = "/Users/YOUR_NAME/.codex/model_catalog_gpt55_1m.json"
我配置了,虽然窗口context会变成1M, 但是如果你一直运行, 超过272KB,上游会打回的。
你开了fast吗
实测上述方案无效。上游还是会打回。大家还是把config.toml中改配置小一点,这样还能压缩一下
有效的,你还需要在~/.codex/config.toml加上model_catalog_json = "/Users/YOUR_NAME/.codex/model_catalog_gpt55_1m.json"
我配置了,虽然窗口context会变成1M, 但是如果你一直运行, 超过272KB,上游会打回的。
你开了fast吗
没开。这个有什么影响吗
实测上述方案无效。上游还是会打回。大家还是把config.toml中改配置小一点,这样还能压缩一下
有效的,你还需要在~/.codex/config.toml加上model_catalog_json = "/Users/YOUR_NAME/.codex/model_catalog_gpt55_1m.json"
我配置了,虽然窗口context会变成1M, 但是如果你一直运行, 超过272KB,上游会打回的。
你开了fast吗
没开。这个有什么影响吗
那应该和fast没关系,我看到cursor的fast和1m上下文只能二选一