Skip to content

Add GPT-5 verbosity model options to Codex and OpenCode#3944

Open
totalolage wants to merge 1 commit into
pingdotgg:mainfrom
totalolage:t3code/gpt5-verbosity-opencode
Open

Add GPT-5 verbosity model options to Codex and OpenCode#3944
totalolage wants to merge 1 commit into
pingdotgg:mainfrom
totalolage:t3code/gpt5-verbosity-opencode

Conversation

@totalolage

@totalolage totalolage commented Jul 13, 2026

Copy link
Copy Markdown

Summary

  • Expose a new verbosity model option (low, medium, high, default medium) for GPT-5 family models in both providers.
  • Keep existing controls intact (reasoningEffort, serviceTier, and OpenCode agent behavior).
  • Forward selected verbosity in OpenCode and Codex turn requests.
  • Extend provider and adapter tests in:
    • OpenCodeProvider.test.ts
    • OpenCodeAdapter.test.ts
    • CodexProvider.test.ts
    • CodexAdapter.test.ts

Validation

  • vp check
  • vp run typecheck
  • pnpm run dist:desktop:dmg
  • Opened the generated .dmg artifact directly from release/

Notes

  • This update addresses missing verbosity in Codex-backed GPT-5 models such as codex/GPT-5.3-Codex-Spark.

Note

Low Risk
Changes are additive UI/capability wiring and optional turn parameters; no auth or data-path changes, with coverage in provider and adapter tests.

Overview
Adds a Verbosity model option (low / medium / high, default medium) for models whose IDs start with gpt-5, surfaced in Codex and OpenCode provider capabilities alongside existing reasoning, service tier, agent, and variant controls.

Codex maps the new descriptor in mapCodexModelCapabilities and forwards the selected value from modelSelection through CodexAdapter.sendTurn into the session runtime turn payload. OpenCode exposes the same capability when listing models and passes verbosity into session.promptAsync when present.

Provider and adapter tests cover GPT-5 vs non–GPT-5 capability exposure and end-to-end forwarding for both drivers.

Reviewed by Cursor Bugbot for commit 99c307d. Bugbot is set up for automated code reviews on this repo. Configure here.

Note

Add GPT-5 verbosity model option to Codex and OpenCode providers

  • Adds a verbosity select option (low, medium, high, default medium) to model capabilities for GPT-5 models in both CodexProvider.ts and OpenCodeProvider.ts; non-GPT-5 models are unaffected.
  • Updates CodexAdapter.ts and OpenCodeAdapter.ts to forward the verbosity value from modelSelection to the respective runtime calls when it is present.
📊 Macroscope summarized 99c307d. 4 files reviewed, 0 issues evaluated, 0 issues filtered, 0 comments posted

🗂️ Filtered Issues

No issues evaluated.

@coderabbitai

coderabbitai Bot commented Jul 13, 2026

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on this repository. 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: Repository UI

Review profile: CHILL

Plan: Pro

Run ID: 0d265d67-5f2d-44b0-912a-6c3b1ecd63f5

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.

@github-actions github-actions Bot added size:M 30-99 changed lines (additions + deletions). vouch:unvouched PR author is not yet trusted in the VOUCHED list. labels Jul 13, 2026
...(verbosity ? { verbosity } : {}),
...(input.interactionMode !== undefined ? { interactionMode: input.interactionMode } : {}),
...(codexAttachments.length > 0 ? { attachments: codexAttachments } : {}),
} as CodexSessionRuntimeSendTurnInput & { readonly verbosity?: string };

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Medium Layers/CodexAdapter.ts:1557

The verbosity option is read from modelSelection and placed into turnInput, but CodexSessionRuntimeSendTurnInput has no verbosity field and sendTurn never forwards it to buildTurnStartParams. The intersection type cast as CodexSessionRuntimeSendTurnInput & { readonly verbosity?: string } only silences the compiler, so selecting a verbosity level has no effect on the Codex turn/start request — the value is silently dropped. To make this functional, add verbosity to CodexSessionRuntimeSendTurnInput, destructure it in sendTurn, and include it in the params built by buildTurnStartParams.

🤖 Copy this AI Prompt to have your agent fix this:
In file @apps/server/src/provider/Layers/CodexAdapter.ts around line 1557:

The `verbosity` option is read from `modelSelection` and placed into `turnInput`, but `CodexSessionRuntimeSendTurnInput` has no `verbosity` field and `sendTurn` never forwards it to `buildTurnStartParams`. The intersection type cast `as CodexSessionRuntimeSendTurnInput & { readonly verbosity?: string }` only silences the compiler, so selecting a verbosity level has no effect on the Codex `turn/start` request — the value is silently dropped. To make this functional, add `verbosity` to `CodexSessionRuntimeSendTurnInput`, destructure it in `sendTurn`, and include it in the params built by `buildTurnStartParams`.

@cursor cursor Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes using high effort and found 2 potential issues.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Want fixes drafted automatically? Bugbot Autofix can create code changes for findings. A team admin can enable Autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 99c307d. Configure here.

...(input.interactionMode !== undefined ? { interactionMode: input.interactionMode } : {}),
...(codexAttachments.length > 0 ? { attachments: codexAttachments } : {}),
})
.sendTurn(turnInput)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Codex verbosity never reaches turn

High Severity

The CodexAdapter passes a verbosity parameter to session.runtime.sendTurn, but CodexSessionRuntime doesn't recognize or forward it. This means user-selected verbosity for Codex models is dropped, making the new UI option ineffective.

Fix in Cursor Fix in Web

Reviewed by Cursor Bugbot for commit 99c307d. Configure here.

readonly model: ProviderListResponse["all"][number]["models"][string];
readonly agents: ReadonlyArray<Agent>;
}): ModelCapabilities {
const hasGpt5Verbosity = isGpt5Model(input.model.id);

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OpenCode GPT-5 check case-sensitive

Medium Severity

OpenCode's isGpt5Model check for the verbosity option is case-sensitive, unlike Codex's case-insensitive approach. This leads to inconsistent availability of the verbosity option for models with non-lowercase 'gpt-5' prefixes across providers.

Fix in Cursor Fix in Web

Reviewed by Cursor Bugbot for commit 99c307d. Configure here.

@macroscopeapp

macroscopeapp Bot commented Jul 13, 2026

Copy link
Copy Markdown
Contributor

Approvability

Verdict: Needs human review

1 blocking correctness issue found. This PR adds new user-facing verbosity options for GPT-5 models. Unresolved review comments identify that the Codex verbosity value is silently dropped (feature doesn't work) and there's case-sensitivity inconsistency between providers. These substantive bugs require human review.

You can customize Macroscope's approvability policy. Learn more.

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

Labels

size:M 30-99 changed lines (additions + deletions). vouch:unvouched PR author is not yet trusted in the VOUCHED list.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant