Skip to content

[codex] Disable client fast mode requests#291

Draft
gulang91-svg wants to merge 1 commit into
james-6-23:mainfrom
gulang91-svg:codex/disable-fast-mode
Draft

[codex] Disable client fast mode requests#291
gulang91-svg wants to merge 1 commit into
james-6-23:mainfrom
gulang91-svg:codex/disable-fast-mode

Conversation

@gulang91-svg

Copy link
Copy Markdown
Contributor

What changed

  • Added CODEX_DISABLE_FAST_MODE / DISABLE_FAST_MODE runtime env support.
  • When enabled, client fast-tier requests are ignored instead of forwarded upstream:
    • OpenAI service_tier: "fast" and service_tier: "priority" are removed before upstream dispatch.
    • Anthropic /v1/messages speed: "fast" no longer maps to Codex service_tier: "priority".
  • Updated service-tier extraction so usage context/logging does not continue to mark those requests as fast when the server disables fast mode.
  • Added startup logging for disable_fast_mode.
  • Documented the new env var in env examples and configuration docs.

Why

The server needs an operator-side override so clients cannot force fast/priority behavior simply by sending request parameters.

Validation

  • Ran go test ./proxy locally.
  • Built and deployed a patched image on the production host.
  • Verified production logs show disable_fast_mode=true and https://sub.laoliu.co/admin/ returns HTTP 200.

@coderabbitai

coderabbitai Bot commented Jun 22, 2026

Copy link
Copy Markdown

Important

Review skipped

Draft detected.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: dcc5f918-6f19-4f6c-923a-2054217393f2

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
✨ 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 and usage tips.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant