Skip to content

fix: codex Unsupported parameter: max_output_tokens - #2684

Merged
Calcium-Ion merged 2 commits into
QuantumNous:mainfrom
seefs001:fix/codex-rm-max-output-tokens
Jan 21, 2026
Merged

fix: codex Unsupported parameter: max_output_tokens#2684
Calcium-Ion merged 2 commits into
QuantumNous:mainfrom
seefs001:fix/codex-rm-max-output-tokens

Conversation

@seefs001

@seefs001 seefs001 commented Jan 17, 2026

Copy link
Copy Markdown
Collaborator

Summary by CodeRabbit

  • Bug Fixes
    • Removed the maximum output token restriction so responses are no longer artificially truncated.
    • Cleared custom temperature overrides to restore default sampling behavior.
    • Result: more complete and consistent AI-generated outputs across requests.

✏️ Tip: You can customize this high-level summary in your review settings.

@coderabbitai

coderabbitai Bot commented Jan 17, 2026

Copy link
Copy Markdown
Contributor

Walkthrough

The ConvertOpenAIResponsesRequest function in the adaptor now disables max output tokens by setting MaxOutputTokens = 0 and clears Temperature by setting it to nil; control flow and error handling remain unchanged.

Changes

Cohort / File(s) Summary
OpenAI Response Conversion
relay/channel/codex/adaptor.go
Sets request.MaxOutputTokens = 0 to disable max output tokens and request.Temperature = nil to clear temperature in ConvertOpenAIResponsesRequest (added comment about removal of max_output_tokens).

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~2 minutes

Poem

🐰 I hopped in the code with a twitch of my nose,
MaxOutput set zero — the cap gently goes,
Temperature cleared with a delicate nudge,
One tidy tweak, not a function to judge,
A rabbit’s small cheer for a change that’s just snug! 🥕

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly and specifically addresses the main change: removing the unsupported 'max_output_tokens' parameter from the Codex adaptor, which aligns with the code modification that disables max output tokens.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
  • 📝 Generate docstrings

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.

@Calcium-Ion
Calcium-Ion merged commit 1af0269 into QuantumNous:main Jan 21, 2026
1 check passed
ennnnny pushed a commit to ennnnny/new-api that referenced this pull request Mar 17, 2026
…tput-tokens

fix: codex Unsupported parameter: max_output_tokens
@coderabbitai coderabbitai Bot mentioned this pull request May 12, 2026
11 tasks
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.

2 participants