Skip to content

[FEATURE]:Allow configurable TUI widths for model selector and current model display #31582

Closed as not planned

Description

@websvcPT

Feature hasn't been suggested before.

  • I have verified this feature I'm about to request hasn't been suggested before.

Describe the enhancement you want to request

Hi,

Would the project be open to a PR adding configurable TUI width options for some UI areas, especially the model selector and the current model display in the main window?

Context

I am using OpenCode with models provided through Eden AI. The model configuration supports a custom name field, so I am generating model names that include useful operational metadata directly in the TUI:

  • provider/model name
  • context size
  • input/output price
  • model capabilities
  • input/output modality indicators

Example:

qwen/qwen3.7-max-2026-05-20 [1M] $1.625/$4.875 🤓🔧⛁𓊂🧇 🖹|🖹

This is useful when comparing models because Eden AI exposes many models with different prices, context windows, and capabilities.

Problem

The current TUI layout is too narrow for this use case in two places:

  1. The model selector dialog truncates model names too aggressively.
  2. The main window also truncates or wraps the current model name, making it hard to see which model is currently active when the configured display name includes additional metadata.

This makes the name field less useful for model comparison and current model visibility.

Screenshots

Model selector width/truncation:

Image Image

Main window current model display truncation/wrapping:

Image

Similar / related issues

I searched existing open and closed issues and found a few related TUI/layout issues, but I did not find an exact duplicate for configurable TUI dialog/model-selector width.

Related but not equivalent:

This request is specifically about allowing users to configure TUI width/truncation behavior while keeping the current defaults unchanged.

Request

Could OpenCode allow optional configuration for TUI widths?

The default behavior could remain exactly as it is today. This would only allow users with wider terminals or custom model names to opt in to a wider layout.

Possible configuration shape:

{
  "tui": {
    "modelSelector": {
      "width": 120,
      "titleWidth": 100,
      "truncate": "left"
    },
    "currentModel": {
      "width": 100
    }
  }
}

Alternative simpler shape:

{
  "tui": {
    "dialogSize": "xlarge",
    "modelSelectorTitleWidth": 100,
    "currentModelWidth": 100
  }
}

Expected behavior

  • Keep current defaults unchanged.
  • Allow users to increase model selector width when the terminal has enough columns.
  • Clamp configured widths to terminal size to avoid broken layouts.
  • Optionally support left/right truncation for long model names.
  • Allow the current model display in the main window to use more horizontal space, or truncate in a configurable way.

Why this helps

When using custom provider configurations, the model selector can become more than just a list of model IDs. It can show context size, price, and capabilities, which makes model selection much easier.

This is especially useful with provider aggregators such as Eden AI, where many models are available and the differences between them are not obvious from the model ID alone.

PR

I would be willing to work on a PR if this is something the maintainers would consider accepting.

Before doing so, I would appreciate guidance on:

  • whether this configuration would be acceptable;
  • the preferred configuration shape;
  • whether this should apply only to the model selector or more generally to TUI dialogs/selectors;
  • whether the current model display in the main window should have separate width/truncation configuration.

Activity

  1. github-actions commented on Jun 10, 2026

    @github-actions
    Contributor

    This issue might be a duplicate of existing issues. Please check:

    If your feature request covers ground not addressed by those issues, feel free to clarify how it differs — specifically the configurable width aspect (rather than just a bug fix) and the model selector dialog truncation.

  2. websvcPT commented on Jun 10, 2026

    @websvcPT
    Author

    This issue might be a duplicate of existing issues. Please check:

    If your feature request covers ground not addressed by those issues, feel free to clarify how it differs — specifically the configurable width aspect (rather than just a bug fix) and the model selector dialog truncation.

    #26989 and #20402 do focus on both points I'm talking about, but I'm offering to contribute if that's acceptable for you

  3. interconnectedMe commented on Jun 16, 2026

    @interconnectedMe
    Image
  4. github-actions commented on Aug 16, 2026

    @github-actions
    Contributor

    To stay organized issues are automatically closed after 60 days of no activity. If the issue is still relevant please open a new one.

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

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions