Skip to content

acp: model config option labels leak raw provider IDs instead of provider display names #64785

Done

Description

@wenzewoo

Summary

session/new returns the model catalog through configOptions, and every model option's name is built as `${providerID}/${model.name}`. This leaks the raw provider ID into the human-readable label, so ACP clients display opencode-go/DeepSeek V4.1 Flash 1017 instead of OpenCode Go / DeepSeek V4.1 Flash 1017. The TUI does not do this: it renders the provider display name (OpenCode Go) as the group/category and the plain model name as the title.

As a result, ACP clients that render options[].name directly show slug-case, machine-oriented labels that no other OpenCode surface shows.

Environment

  • OpenCode 2.3.2 (opencode acp)
  • macOS 15 (arm64)

Reproduction

  1. Start opencode acp.
  2. Send initialize, then session/new with { "cwd": "...", "mcpServers": [] }.
  3. Inspect result.configOptions where id == "model".

Actual response excerpt:

{
  "id": "model",
  "name": "Model",
  "category": "model",
  "type": "select",
  "currentValue": "opencode/tidepool-alpha-free",
  "options": [
    { "value": "opencode-go/deepseek-v4.1-flash", "name": "opencode-go/DeepSeek V4.1 Flash 1017" },
    { "value": "opencode/beam-free", "name": "opencode/Beam Free" },
    { "value": "opencode-go/beam-free", "name": "opencode-go/Beam Free" }
  ]
}

Expected (display names, matching the TUI):

{ "value": "opencode-go/deepseek-v4.1-flash", "name": "OpenCode Go / DeepSeek V4.1 Flash 1017" }

Root cause

packages/cli/src/acp/config-option.ts interpolates the raw provider ID into the label:

options: catalog.models
  .toSorted((a, b) => Order.String(a.providerID, b.providerID) || a.name.localeCompare(b.name))
  .map((item) => ({ value: advertisedModel(item), name: `${item.providerID}/${item.name}` })),

The TUI, by contrast, uses the provider display name:

// packages/tui/src/component/dialog-model.tsx
providerName: provider?.name ?? model.providerID,
category: connected() ? (freeGroup(model) ? "Free" : (provider?.name ?? model.providerID)) : undefined,

Provider display names are available from the same catalog source the TUI consumes (opencode-go → OpenCode Go, opencode → OpenCode).

Suggested fix

Resolve the provider display name when building the model config option and use it in name, e.g. `${provider.name} / ${model.name}`, while keeping value as the stable providerID/modelID identifier. If resolving names in the ACP catalog is undesirable, at minimum drop the provider prefix from name when it adds no information, since value is already unique.

Activity

  1. opencodejr commented on Nov 19, 2026

    @opencodejr
    Contributor

    Thanks for the detailed write-up and the suggested fix!

    You're asking for the ACP model options returned by session/new to use the provider's display name (e.g. OpenCode Go / DeepSeek V4.1 Flash 1017) and keep value as the stable providerID/modelID ref. That would match the TUI model picker.

    Right now the ACP adapter builds each label as ${item.providerID}/${item.name} on purpose. The TUI dialog uses provider?.name ?? model.providerID. So this is behaving as currently designed, and making the two consistent is an improvement, so I'm marking it as a feature request. Maintainers will consider it.

    I didn't find any existing issue asking for this.

  2. added
    area/ide-acp
    type/feature
    version/v2
    on Nov 19, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area/ide-acpplatform/macostype/featureversion/v2

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions