Skip to content

fix(catalog): correct the native GPT-5.6 context window to 272k - #1648

Closed
waw4303 wants to merge 1 commit into
lidge-jun:devfrom
waw4303:pr/context-window
Closed

fix(catalog): correct the native GPT-5.6 context window to 272k#1648
waw4303 wants to merge 1 commit into
lidge-jun:devfrom
waw4303:pr/context-window

Conversation

@waw4303

@waw4303 waw4303 commented Aug 14, 2026

Copy link
Copy Markdown
Contributor

PR description: fix(catalog): correct the native GPT-5.6 context window to 272k

Summary

Align the native GPT-5.6 catalog rows with the real Codex OAuth contract. The upstream models.json advertises 372_000 for the GPT-5.6 family, but the effective context for Codex OAuth sessions is the 272_000 standard already used for gpt-5.5. This changes NATIVE_GPT56_CONTEXT_WINDOW from 372_000 to 272_000, so gpt-5.6-sol/terra/luna and account-scoped Daybreak Blue (which inherits Sol capabilities) stop overstating native capacity; the derived auto_compact_token_limit follows automatically (floor(window * 0.9) → 244_800).

  • src/codex/catalog/metadata.ts — constant corrected.
  • tests/codex-catalog.test.ts, tests/codex-catalog-sync-hardening.test.ts — assertions that flow through nativeOpenAiContextWindow/applyNativeOpenAiContextOverride updated to 272_000/244_800. Upstream-snapshot assertions (the raw pinned models.json values) are intentionally untouched.

Verification

  • bun test tests/codex-catalog.test.ts — 176 pass / 0 fail.
  • bun test --timeout 60000 tests/codex-catalog-sync-hardening.test.ts — 25 pass / 0 fail (the three spawn-heavy cases need the CI-style 60s timeout, not Bun's 5s default).
  • bun run typecheck — pass.

Checklist

  • Scope stays focused and avoids unrelated cleanup.
  • Docs or release notes were updated when needed.
  • Security-sensitive changes were reviewed for secrets, auth, and unsafe defaults.

Review readiness checklist

This PR stays in draft until every box below is ticked. Tick all four boxes once the requirements are met:

  • All CI tests are green on my local testing.

  • I pushed my PR to the latest dev commit.

  • I resolved all correct Codex and CodeRabbit findings.

  • My PR is ready for review.

Summary by CodeRabbit

  • Bug Fixes
    • Adjusted the supported context window for native GPT-5.6 models to 272,000 tokens.
    • Updated automatic compaction limits and model catalog behavior to align with the revised context capacity.

The upstream models.json advertises 372k for the GPT-5.6 family, but the
effective Codex OAuth contract is 272k. Align NATIVE_GPT56_CONTEXT_WINDOW
(and Daybreak Blue, which inherits Sol capabilities) with the 272k standard
already used for gpt-5.5, so catalog rows and auto-compact limits stop
overstating native capacity.
@github-actions github-actions Bot added the bug Something isn't working label Aug 14, 2026
@github-actions

Copy link
Copy Markdown
Contributor

Deterministic PR hygiene checks passed.

@coderabbitai

coderabbitai Bot commented Aug 14, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

Important

Review skipped

No new commits to review since the last review.

⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro Plus

Run ID: 8bd65f4e-ec79-40db-aff0-5f44aa9d50d4

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro Plus

Run ID: 220fdafd-5119-4e69-9063-a735f334f2a0

📥 Commits

Reviewing files that changed from the base of the PR and between 8b1c620 and ba299c7.

📒 Files selected for processing (3)
  • src/codex/catalog/metadata.ts
  • tests/codex-catalog-sync-hardening.test.ts
  • tests/codex-catalog.test.ts

📝 Walkthrough

Walkthrough

The native GPT-5.6 context window changes from 372,000 to 272,000 tokens. Catalog synchronization and catalog tests update related context, maximum-context, and auto-compaction expectations.

Changes

GPT-5.6 context window

Layer / File(s) Summary
Update native GPT-5.6 baseline
src/codex/catalog/metadata.ts
NATIVE_GPT56_CONTEXT_WINDOW now defines a 272,000-token context window.
Align catalog expectations
tests/codex-catalog.test.ts, tests/codex-catalog-sync-hardening.test.ts
Catalog tests now expect 272,000-token context limits and 244,800-token auto-compaction limits across native, alias, and Daybreak cases.

Estimated code review effort: 1 (Trivial) | ~5 minutes

Mergeability Score: ⚪ Minimal · up to ba299

This change corrects the native GPT-5.6 context limit and its derived compaction limit, with targeted tests and typechecking passing; no actionable merge-blocking risk remains.

Possibly related PRs

Suggested reviewers: wibias, ingwannu, lidge-jun

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly and concisely describes the primary change: correcting the native GPT-5.6 context window to 272k.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@github-actions

github-actions Bot commented Aug 14, 2026

Copy link
Copy Markdown
Contributor

⏳ DRAFT

  • review readiness checklist open (2/4 boxes ticked).

What to do

  • Tick all four boxes in the PR description once you're done (currently 2/4).

Review readiness checklist

  • ⬜ All CI tests are green on my local testing.
  • ✅ I pushed my PR to the latest dev commit.
  • ✅ I resolved all correct Codex and CodeRabbit findings.
  • ⬜ My PR is ready for review.

2/4 boxes ticked.

This PR stays in draft until every box above is ticked.

@github-actions
github-actions Bot marked this pull request as draft August 14, 2026 01:07
@github-actions
github-actions Bot marked this pull request as ready for review August 14, 2026 01:14
@coderabbitai

coderabbitai Bot commented Aug 14, 2026

Copy link
Copy Markdown
Contributor

Tip

For best results, initiate chat on the files or code changes.

@github-actions[bot] Acknowledged. PR #1648 is marked ready for review. I am replying to the latest comment only because the earlier comment chain is unavailable.


🧠 Learnings used
Learnt from: Wibias
Repo: lidge-jun/opencodex PR: 986
File: .github/workflows/enforce-pr-target.yml:631-636
Timestamp: 2026-08-04T06:41:30.089Z
Learning: For the PR readiness gate in `.github/workflows/enforce-pr-target.yml`, the required scope is to bind contributor checklist completion and maintainer notification to the exact PR head SHA, then reset them after a new head commit. Maintainer approval staleness is separate from this gate and should be enforced by GitHub branch protection, such as `dismiss-stale-reviews` or `require_last_push_approval`, when configured for `dev`.

You are interacting with an AI system.

@Wibias
Wibias marked this pull request as draft August 14, 2026 03:51
@coderabbitai

coderabbitai Bot commented Aug 14, 2026

Copy link
Copy Markdown
Contributor

@github-actions[bot] The readiness gate is complete for head SHA ba299c79dc1f4269dbf6177b5aa0c707c9bc28c2. I will start the independent PR review.


🧠 Learnings used
Learnt from: Wibias
Repo: lidge-jun/opencodex PR: 986
File: .github/workflows/enforce-pr-target.yml:631-636
Timestamp: 2026-08-04T06:41:30.089Z
Learning: For the PR readiness gate in `.github/workflows/enforce-pr-target.yml`, the required scope is to bind contributor checklist completion and maintainer notification to the exact PR head SHA, then reset them after a new head commit. Maintainer approval staleness is separate from this gate and should be enforced by GitHub branch protection, such as `dismiss-stale-reviews` or `require_last_push_approval`, when configured for `dev`.
⚠️ Action not completed

Already reviewed.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@lidge-jun

Copy link
Copy Markdown
Owner

this is I intended

@lidge-jun lidge-jun closed this Aug 14, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants