openai / openai/codex

Native multi-provider model switching in Codex Desktop

Open
#46,484 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

app custom-model enhancement
Dominant language
Rust
Stars
125k
Forks
19.4k
PR merge metrics
PR metrics pending

Description

What variant of Codex are you using?

Desktop App

What feature would you like to see?

Codex Desktop currently treats model_provider as a thread/config-level setting, which makes switching between models from different providers inside the same conversation unreliable.

I built a working local workaround using a single logical provider (router) backed by a localhost routing service:

deepseek-* models → DeepSeek Responses API
GPT models → ChatGPT/Codex backend
Codex always sees the same model_provider = "router"

Because Codex already supports changing the model mid-thread, this allows me to switch between GPT and DeepSeek from the normal model picker inside the same conversation while preserving the full context.

The model picker now effectively looks like:

GPT-6 Astra
DeepSeek Flash
DeepSeek V4 Pro
GPT-5.6 Sol
GPT-5.6 Terra
GPT-5.6 Luna
GPT-5.5

This suggests Codex could support this natively by making a picker entry represent something like:

{
model,
model_provider,
authentication
}

rather than requiring one provider to remain active for the whole thread.

Expected UX:

Start a conversation using DeepSeek.
Switch to GPT from the model picker.
Continue the same conversation and context.
Switch back whenever desired.

No duplicate threads, separate CODEX_HOMEs, or manual config changes.

I tested the router approach successfully: DeepSeek requests reached api.deepseek.com and GPT requests reached the ChatGPT Codex backend while remaining in the same Codex thread.

It would be great to have first-class multi-provider routing/model switching directly in Codex Desktop.

Image
Additional information

No response

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by tracing how model_provider and the normal model picker are represented for Desktop App threads; the issue does not name files or tests. Compare the router workaround with the requested {model, model_provider, authentication} picker entry, and verify completion by switching DeepSeek and GPT in one conversation while preserving context and routing each request to its provider.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
api, backend-api-design, desktop
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.