GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — [FEATURE]: Let built-in tools like shell and read be called from Code Mode execute · Issue #55087 · anomalyco/opencode

[FEATURE]: Let built-in tools like shell and read be called from Code Mode execute #55087

New issue
Copy link
New issue
Copy link
Open
Open
[FEATURE]: Let built-in tools like shell and read be called from Code Mode execute#55087
Copy link

Description

@remorses
remorses
opened on Oct 13, 2026
Issue body actions

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

Built-in tools (shell, read, grep, glob, edit, write, ...) are registered with codemode: false, so tools.shell(...) inside execute fails with Unknown tool 'shell'. #39312 was closed as expected behavior, but the docs do not say why.

This blocks the main use of execute: combining calls in one step. For example, run a CLI that saves a screenshot, then read the image, in one call:

await tools.shell({ command: 'ghosthand screenshot /tmp/s.png' })
return await tools.readMediaIntoContext({ path: '/tmp/s.png' })

Today this is two tool calls, because shell is not in the catalog.

Proposal

  • Let built-in tools opt in to the Code Mode catalog, with a config flag or a per-tool setting.
  • Nested calls keep their normal permission checks, as other Code Mode tools already do.
  • If there is a reason for the current default, document it on the Tools page.

Related: #54826 (direct MCP servers in Code Mode), #55072 (images from execute).

Reacted by Yaroslav Shumlyanskyi, Houssam Elbadissi, Tommy D. Rossi, BrettB, Dylan Barnett, Lê Hoàng Phương, Alvaro Sevilla and Iceflower

Activity

  1. opencode-agent commented on Oct 13, 2026

    @opencode-agent
    opencode-agentBot
    on Oct 13, 2026 – with OpenCode Agent
    Contributor
    More actions

    Thanks for the detailed request! In short, you're asking for built-in tools like shell, read and grep to be callable as tools.<name>(...) inside Code Mode execute, opt-in through config or per tool, with nested calls still going through the normal permission checks. That way steps like "run a CLI, then read its output file" fit in one call. You'd also like the reason for the current default documented.

    Right now each tool goes either in the top-level tool list or in the Code Mode catalog, never both, and every built-in is set to top-level (codemode: false). That's why tools.shell gives Unknown tool. Changing it needs a change in core, so maintainers will consider it.

    Related issues:

    • execute: tools.shell unavailable inside Code Mode runtime despite being in catalog #39312: the same limitation, reported earlier as a bug and closed as expected behaviour
    • [FEATURE]: Make direct MCP servers also available in codemode #54826: making direct MCP servers available in Code Mode too
    • [FEATURE]: Code Mode execute should return images/attachments to the model #55072: returning images/attachments from execute
    • code mode: execute dispatcher bypasses ask permission for nested plugin tools #47177: permission checks for nested tool calls inside execute
  2. skaldebane commented on Oct 15, 2026

    @skaldebane
    skaldebane
    on Oct 15, 2026
    More actions

    YES, I see models trip up on this sometimes, when trying to chain built-in tools alongside MCP tools. The built-in tools should act as though they are codemode: true tools.

    Reacted by BrettB and Javier Ruere
  3. mattcrichards commented on Nov 16, 2026

    @mattcrichards
    mattcrichards
    on Nov 16, 2026
    More actions

    I independently reproduced this limitation while preparing a controlled coding-agent benchmark using OpenCode 2.2.5 and a local Qwen model.

    Using an isolated OpenCode session against a mock inference server, I captured the effective model-facing tool configuration.

    Observed behavior:

    • Enabling execute successfully exposed Code Mode.
    • Built-in read, edit, shell, and write remained direct model-facing tools.
    • Those built-in tools were unavailable through the Code Mode catalog.
    • The catalog instead exposed an OpenCode worktree-management tool.
    • Enabling Code Mode also introduced additional system-prompt instructions.

    This prevents me from evaluating the primary benefit I wanted to measure: whether consolidating native coding tools behind execute reduces tool-schema overhead, context consumption, and time to first source edit for a local 27B model.

    I stopped the experiment at preflight rather than testing a configuration that didn't satisfy the experimental requirements.

    What would help: An option to expose OpenCode's native coding tools exclusively through Code Mode, while preserving their existing execution semantics and permission checks.

    This would make Code Mode substantially more useful for smaller local models, where model-facing tool complexity and context consumption can have meaningful performance implications.

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

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

      You are visitor 01402775 — GeezerVison does not store the pages you look up.
      Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.