You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Custom agents are identified in lowercase (work-item, pr-writer, adversarial-review), and the agent record already carries that string as name. The prompt ribbon still titlecases the id for display, so the label does not match the identifier users configure and reference:
There is no CLI setting to turn this off — the full settings reference has no agent-label or casing option — and renaming the agent file does not help, since the transform is applied to the id itself.
Proposed fix
Use agent.name instead of Locale.titlecase(agent.id). The API already returns the lowercase id as name for custom agents ("id": "work-item", "name": "work-item"), while built-ins keep their display names (General, Explore), so the one-line change fixes custom agents without affecting built-ins.
Related: #30372 fixed the same class of bug (CSS capitalize on custom agent identifiers) in the legacy app prompt selector.
Plugins
None.
OpenCode version
2.1.2
Steps to reproduce
Create ~/.config/opencode/agents/work-item.md with mode: primary.
Start the TUI and select the work-item agent (shift+tab).
The prompt ribbon reads Work-Item.
Expected behavior
The ribbon shows the agent identifier as defined: work-item.
Thanks for the detailed write-up! You're asking for the TUI prompt ribbon to show custom agent ids exactly as you defined them (work-item) instead of titlecasing them (Work-Item), for example by showing the agent's name.
The titlecasing is deliberate for now. The TUI applies Locale.titlecase to agent ids in many places, not only the ribbon: session messages, "Switched agent" lines, subagent titles and so on. So changing it is a display design choice rather than a bug fix. You're right that it's inconsistent, though: the agent picker shows the raw id while the ribbon titlecases it. I've passed this on to the maintainers to consider.
The prompt ribbon now uses agent.name instead of Locale.titlecase(agent.id). The API already returns the lowercase id as the name for custom agents and the display name for the built-ins, so the one-line change fixes custom agents and leaves the built-ins alone.
No bun in this environment, so I could not run the TUI suite; the PR body says so.
Activity
opencode-agent commentedon Oct 21, 2026
Thanks for the detailed write-up! You're asking for the TUI prompt ribbon to show custom agent ids exactly as you defined them (
work-item) instead of titlecasing them (Work-Item), for example by showing the agent'sname.The titlecasing is deliberate for now. The TUI applies
Locale.titlecaseto agent ids in many places, not only the ribbon: session messages, "Switched agent" lines, subagent titles and so on. So changing it is a display design choice rather than a bug fix. You're right that it's inconsistent, though: the agent picker shows the raw id while the ribbon titlecases it. I've passed this on to the maintainers to consider.Related:
lab1207 commentedon Oct 21, 2026
Claiming this one — opened #57730: #57730
The prompt ribbon now uses
agent.nameinstead ofLocale.titlecase(agent.id). The API already returns the lowercase id as the name for custom agents and the display name for the built-ins, so the one-line change fixes custom agents and leaves the built-ins alone.No
bunin this environment, so I could not run the TUI suite; the PR body says so.