Repository navigation
fix(coderd/x/chatd): remember quickgen parameter rejections per model - #31493
Merged
deansheather merged 1 commit intoNov 9, 2026
Conversation
On Claude Opus 5.5, title generation and the turn-status label each made four upstream requests, three of them rejected with a 400: the temperature retry restarted from a forced tool call the model had already rejected. Wrap resolved models in quickgenParamModel, which falls back to text mode when the forced tool_choice is rejected and drops temperature when it is rejected, recording each rejection per provider and model in a replica-wide map with a 6 hour TTL. The first job on a replica makes 3 requests; later jobs make 1.
Member
|
@codex review |
Member
|
@codex security review |
Codex Review Summary: 🔄 RunningThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
Codex Review: Didn't find any major issues. Bravo. Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
ethanndickson
approved these changes
Nov 9, 2026
deansheather
deleted the
dean/codagt-1411-quickgen-side-jobs-make-3-rejected-requests-per-run-on
branch
November 9, 2026 11:39
This branch was previously deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
On Claude Opus 5.5, chat title generation and the turn-status label each made four upstream requests, three of them rejected with a 400. The temperature retry in
generateQuickgenObjectcalledgenerateObjectagain, which restarted from the forced tool call the model had already rejected. Each turn left about sixbad_requestrows inaibridge_interceptionsand added 1.5 to 3.5 seconds of latency.This replaces the per-call fallbacks with
quickgenParamModel, a wrapper applied inresolveModelCall. It falls back to plain JSON text when the model rejects the forcedtool_choice, dropstemperaturewhen the model rejects it, and records each rejection in a replica-widesync.Mapkeyed by AI provider ID, model, and parameter, following the existingthinkingDropBlockmap. Entries expire after 6 hours so a provider that starts accepting a parameter again is picked up without a restart. Only quickgen callsGenerateObject, so chat turns are unaffected.Rejections are still detected by matching
tool_choiceortemperaturein a 400 body, as before. A false match now persists for the TTL on that replica rather than one job; the worst case is text mode or no temperature for that model.Closes CODAGT-1411
Decision log