Make config.toml profiles selectable via CLI

Open 💬 6 comments Opened Oct 6, 2025 by jschmdt

What feature would you like to see?

Custom Profiles in CLI – defined via config.toml

When I define a custom profile in the Codex config.toml like this:

[model_providers.lms]
name = "LM Studio"
base_url = "http://localhost:1234/v1"

[profiles.gpt-oss-120b-lms]
model_provider = "lms"
model = "gpt-oss:120b"

Make it available inside the model selector like this… See Screenshot of a mockup layout I created:

<img width="1023" height="324" alt="Image" src="https://github.com/user-attachments/assets/5cab4532-0b0e-4039-ae38-5a3318769a46" />

Behavior

  • If a profile is defined via config.toml > make visible in the CLI /model selector
  • If no profile is defined via config.toml > just show gpt-5-codex / gpt-5
1. gpt-5-codex (currrent)
2. gpt-5
3. custom-model-profile (only visible when defined)

Options in config.toml

To make it more concise, let the user add a small name description as well:

Option A:
Derivate the name directly from [profiles.gpt-oss-120b-lms] » Model name shown in CLI » gpt-oss-120b-lms

Option B
Let the user add a custom name and description inside the profile:

[profiles.gpt-oss-120b-lms]
model_provider = "lms"
model = "gpt-oss:120b"
👉 model_name="gpt-oss-120b"
👉 model_description="This is a custom description."

Other UX possibilities to implement this feature:

Implement this feature via a new shortcut /provider:

  1. When called in Codex » this shortcut lists all custom providers you defined in confg.toml
  2. Switch easily between OpenAI and local providers "OpenAI", "Ollama" & "LM Studio"
  3. When provider is selected » "/models" now lists all corresponding custom models like gpt-oss-120b-lms (example mentioned earlier), etc.

Additional information

Would streamline the UX workflow for selecting models:
Instead codex --oss --profile gpt-oss-120b-lms » Just start codex and select the custom defined profiles and models.

View original on GitHub ↗

This issue has 6 comments on GitHub. Read the full discussion on GitHub ↗