Skip to content

New tui does not let running agents using @agent_name. #3831

Closed

Description

@skozar

Description

New TUI in versions 1.0.x doesn’t allow running agents using @agent_name. In older versions (0.15.x), it works correctly.

In versions 1.0.x, writing @ provides autocompletion to select files but doesn’t show agents. If you ignore autocompletion and type the agent name directly, it doesn’t recognize the name in the prompt and treats it as part of the input.

This is an issue when creating custom agents meant to function as subtasks.

According to the (documentation)[https://opencode.ai/docs/agents/], it should still work?

OpenCode version

1.0.x

Steps to reproduce

  1. run opencode
  2. switch to build mode
  3. write prompt @plan create plan to implement hello world application in python
  4. TUI will accept it as just regular prompt in build mode and would not invoke @plan agent.

Screenshot and/or share link

Image

Operating System

macOS 17.7

Terminal

iTerm2. Problem is the same with regular Terminal.

Activity

  1. added
    opentuiThis relates to changes in v1.0, now that opencode uses opentui
    on Nov 3, 2025
  2. self-assigned this
    on Nov 4, 2025
  3. thdxr commented on Nov 4, 2025

    @thdxr
    Member

    is this the built in plan mode? you don't have anything configured?

  4. AbbasSrour commented on Nov 4, 2025

    @AbbasSrour

    I can confirm as well, the @ is not showing subagents for me also.

  5. skozar commented on Nov 4, 2025

    @skozar
    Author

    is this the built in plan mode? you don't have anything configured?

    i have configured agent named @refactor. It does work too.

  6. skozar commented on Nov 4, 2025

    @skozar
    Author

    is this the built in plan mode? you don't have anything configured?

    yes, it's default plan mode in example

  7. thdxr commented on Nov 4, 2025

    @thdxr
    Member

    can i see your config?

  8. deleted a comment from thdxr on Nov 4, 2025
  9. thdxr commented on Nov 4, 2025

    @thdxr
    Member
        return agents
          .filter((agent) => !agent.builtIn && agent.mode !== "primary")
    
  10. thdxr commented on Nov 4, 2025

    @thdxr
    Member

    this is how we check

  11. skozar commented on Nov 4, 2025

    @skozar
    Author

    this is how we check

    In my use case, I've redefined the default @build agent to be a subagent. I did this to prevent unintentional switches to build mode without compromising the planning process.

    But I'd still like to have the option to run simple tasks that don’t require planning by using @build do some task.

    Is it possible to modify the check and remove the restriction on using built-in agents as subagents? Is there any reason for this limitation that I’m not understanding?

    Thank you.

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

Metadata

Metadata

Assignees

Labels

bugSomething isn't workingopentuiThis relates to changes in v1.0, now that opencode uses opentui

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions