nanocoder icon indicating copy to clipboard operation
nanocoder copied to clipboard

[Feature] Keep agent `execute_bash` output visible on the completed card

Open coralsundy opened this issue 2 months ago • 1 comments

Description

PR #714 (commit 59dc92f5) made user-typed !commands render their captured output on the completed execute_bash card. Agent-invoked execute_bash calls were left out: they always collapse to a compact card (command + status + token count), discarding the output that had streamed live while the command ran. Once the command finishes that output is gone from the transcript, even though the model still receives it.

One idea is to add a showAgentBashOutput preference to nanocoder-preferences.json that keeps the output on agent bash cards:

  • false (default) — agent execute_bash cards stay compact, exactly as today
  • true — agent execute_bash cards keep their output, even when compact tool display is on

Similarly to success run, a failed command keeps its error output rather than collapsing. Commands you type yourself (!command) already always show their output and are unaffected by this setting.

Users can set "showAgentBashOutput": true, or toggle it at /settings → Behavior → Tool Results and Thinking → Agent Bash Output.

Before / showAgentBashOutput=false

⚒ execute_bash Command: printf "line one\nline two\nline three\n" Status: ● Tokens: ~7

After / showAgentBashOutput=true

⚒ execute_bash Command: printf "line one\nline two\nline three\n" Status: ● line one line two line three Tokens: ~7

Implementation

  • https://github.com/Nano-Collective/nanocoder/pull/945

Use Case

Anyone who wants to see the bash execute output

Proposed Solution

See description

Alternatives Considered

Any alternative solutions or features you've considered

Additional Context

  • [x] I have searched existing issues to ensure this is not a duplicate
  • [x] This feature aligns with the project's goals (local-first AI assistance)

Implementation Notes (optional)

This idea was initially implemented in a sloppy user/tool/both/none setup which is harder to maintain, and confusing to users, thus this new issue to re-design the approach, see:

  • https://github.com/Nano-Collective/nanocoder/pull/945#pullrequestreview-5061116466

coralsundy avatar Sep 14 '26 00:09 coralsundy

Implementation in https://github.com/Nano-Collective/nanocoder/pull/945.

coralsundy avatar Sep 14 '26 00:09 coralsundy