Skip to content

fix(ui): grey subagent tool calls and soften failure copy#4457

Merged
TheodoreSpeaks merged 2 commits intostagingfrom
fix/grey-subagent-tools
May 5, 2026
Merged

fix(ui): grey subagent tool calls and soften failure copy#4457
TheodoreSpeaks merged 2 commits intostagingfrom
fix/grey-subagent-tools

Conversation

@TheodoreSpeaks
Copy link
Copy Markdown
Collaborator

Summary

  • Apply opacity-60 to subagent tool-call rows so they fade to match the surrounding subagent text (previously text was greyed but tool calls stayed full-opacity).
  • Replace user-facing "Failed" tool-result label with "Attempted to" — Failed reading XAttempted to read X, and humanized fallback Failed Foo BarAttempted to Foo Bar.

Type of Change

  • Bug fix

Testing

Tested manually. bun run lint and bun run check:api-validation:strict pass.

Checklist

  • Code follows project style guidelines
  • Self-reviewed my changes
  • Tests added/updated and passing
  • No new warnings introduced
  • I confirm that I have read and agree to the terms outlined in the Contributor License Agreement (CLA)

@vercel
Copy link
Copy Markdown

vercel Bot commented May 5, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

1 Skipped Deployment
Project Deployment Actions Updated (UTC)
docs Skipped Skipped May 5, 2026 11:43pm

Request Review

@cursor
Copy link
Copy Markdown

cursor Bot commented May 5, 2026

PR Summary

Low Risk
Low risk UI-only tweaks: adjusts opacity styling for subagent message rows and changes tool-call error labels from “Failed” to “Attempted to”, with no behavior or data-flow changes.

Overview
Subagent message groups now render all inner rows (including ToolCallItems) at reduced opacity, so tool-call entries visually match the already-muted subagent text.

Tool-call display copy is softened for error states: Read tools show Attempted to read … instead of Failed reading …, and the generic humanized fallback similarly reports Attempted to … for errors.

Reviewed by Cursor Bugbot for commit 152e39b. Bugbot is set up for automated code reviews on this repo. Configure here.

@greptile-apps
Copy link
Copy Markdown
Contributor

greptile-apps Bot commented May 5, 2026

Greptile Summary

This PR makes two small UI polish fixes for subagent tool-call rows: all rows are faded to 60% opacity to visually match the surrounding dimmed subagent text, and the user-facing error label is softened from "Failed" to "Attempted to".

  • tool-call-item.tsx: Adds opacity-60 unconditionally to every ToolCallItem wrapper, including the animated executing state.
  • store-utils.ts: Updates formatReadingLabel and humanizedFallback to use "Attempted to" instead of "Failed" for ClientToolCallState.error, affecting both the dedicated Read tool path and the generic fallback for all other tools.

Confidence Score: 4/5

Safe to merge — changes are purely visual and copy-only with no logic or data impact.

Both changes are narrow in scope. The opacity tweak dims all tool-call rows uniformly, including the live spinner during the executing state, which may slightly reduce the visibility of in-progress operations. The "Attempted to" copy lands a bit awkwardly for tool names that don't begin with a verb (e.g. "Attempted to File Context"), but this is a pre-existing structural quirk of the fallback formatter rather than a regression.

tool-call-item.tsx warrants a second look if the executing-state dimming turns out to be noticeable in practice.

Important Files Changed

Filename Overview
apps/sim/app/workspace/[workspaceId]/home/components/message-content/components/agent-group/tool-call-item.tsx Adds unconditional opacity-60 to every ToolCallItem regardless of status, including the live executing state where the spinning indicator may become harder to notice.
apps/sim/lib/copilot/tools/client/store-utils.ts Replaces "Failed" with "Attempted to" in both the dedicated read-label formatter and the generic humanized fallback; copy change only, no logic impact.

Flowchart

%%{init: {'theme': 'neutral'}}%%
flowchart TD
    A[resolveToolDisplay] --> B{toolName defined?}
    B -- No --> Z[undefined]
    B -- Yes --> C{isToolHiddenInUi?}
    C -- Yes --> Z
    C -- No --> D{specialToolDisplay?}
    D -- respond/respond suffix --> E[formatRespondLabel 'Gathering thoughts']
    D -- Read tool --> F[formatReadingLabel]
    F --> F1{state}
    F1 -- success --> F2[Read suffix]
    F1 -- error --> F3[Attempted to read suffix]
    F1 -- rejected/aborted --> F4[Skipped reading suffix]
    F1 -- default --> F5[Reading suffix]
    D -- other --> G[humanizedFallback]
    G --> G1{state}
    G1 -- success --> G2[Executed FormattedName]
    G1 -- error --> G3[Attempted to FormattedName]
    G1 -- rejected/aborted --> G4[Skipped FormattedName]
    G1 -- default --> G5[Executing FormattedName]
Loading

Comments Outside Diff (1)

  1. apps/sim/lib/copilot/tools/client/store-utils.ts, line 131-139 (link)

    P2 "Attempted to" precedes a Title-Case noun phrase

    humanizedFallback builds the string as `${stateVerb} ${formattedName}` where formattedName is the tool name converted to Title Case (e.g. Read File). For the error state this yields "Attempted to Read File" — grammatically fine because the capitalised words happen to double as an infinitive + noun. For tool names that don't start with a verb (e.g. file_context"Attempted to File Context") the phrase is odd. The dedicated formatReadingLabel path uses lowercase "read" which works because it's explicitly a verb. You may want to lowercase formattedName in the fallback, or use a different template for error state.

    Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!

Reviews (1): Last reviewed commit: "fix(ui): Adjust tool opacity, failed too..." | Re-trigger Greptile


return (
<div className='flex items-center gap-[8px] pl-[24px]'>
<div className='flex items-center gap-[8px] pl-[24px] opacity-60'>
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Opacity applied during active execution

opacity-60 is unconditional, so the animated PillsRing spinner shown while status === 'executing' is also dimmed to 60%. In practice this may be subtle, but the in-progress indicator is the most important visual affordance when a subagent is working — users may miss that a tool call is still running. Consider limiting the fade to completed states (success, cancelled, error) and keeping the executing row at full opacity.

Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!

Copy link
Copy Markdown

@cursor cursor Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit eda7304. Configure here.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant