Skip to content

feat: display subagent tool calls in CLI and UI#6535

Merged
jamadeo merged 1 commit intoblock:mainfrom
rabi:subagent_tool_calls
Feb 3, 2026
Merged

feat: display subagent tool calls in CLI and UI#6535
jamadeo merged 1 commit intoblock:mainfrom
rabi:subagent_tool_calls

Conversation

@rabi
Copy link
Contributor

@rabi rabi commented Jan 16, 2026

Summary

  • Add notification forwarding from subagent to parent agent
  • Create tool call notifications for subagent ToolRequest messages
  • Add render_subagent_tool_call() to display tool headers in CLI
  • Add formatSubagentToolCall() helper in UI for consistent display
  • Use session ID suffix for unique subagent identification

Type of Change

  • Feature
  • Bug fix
  • Refactor / Code quality
  • Performance improvement
  • Documentation
  • Tests
  • Security fix
  • Build / Release
  • Other (specify below)

AI Assistance

  • This PR was created or reviewed with AI assistance

Testing

Tested locally with both cli and ui.

Context: ○○○○○○○○○○ 0% (0/128000 tokens)
( O)> Use a subagent with google provider and gemini-2.5-pro model to fetch last 10 PRs from vllm-project/vllm and another subagent with gcp_vertex_ai provider and claude-opus-4-5@20251101 model to fetch last 10 PRs from sgl-project/sglang and then output them together in a tabular format

─── subagent |  ──────────────────────────
instructions: Fetch the last 10 Pull Requests from the repository 'vllm-project/vllm'. Return the details inclu...
extensions: github
settings:
    model: gemini-2.5-pro
    provider: google


─── [subagent:53] list_pull_requests | github ──────────────────────────
direction: desc
owner: vllm-project
perPage: 10
repo: vllm
sort: created
state: all


─── subagent |  ──────────────────────────
instructions: Fetch the last 10 Pull Requests from the repository 'sgl-project/sglang'. Return the details incl...
extensions: github
settings:
    model: claude-opus-4-5@20251101
    provider: gcp_vertex_ai


─── [subagent:54] list_pull_requests | github ──────────────────────────
owner: sgl-project
perPage: 10
repo: sglang


─── [subagent:54] get_file_contents | github ──────────────────────────
owner: sgl-project
path: /tmp/goose_mcp_responses/mcp_response_20260116_090422.774994.txt
repo: sglang


─── [subagent:54] search_pull_requests | github ──────────────────────────
order: desc
owner: sgl-project
perPage: 10
query: is:pr
repo: sglang
sort: created

Here are the last 10 Pull Requests from both `vllm-project/vllm` and `sgl-project/sglang` combined into a single table:

@rabi rabi force-pushed the subagent_tool_calls branch 2 times, most recently from d4217c1 to 52e5ff6 Compare January 21, 2026 10:56
@jamadeo jamadeo self-requested a review January 28, 2026 17:12
Copy link
Collaborator

@jamadeo jamadeo left a comment

Choose a reason for hiding this comment

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

this makes sense to me. I could see an argument that it might get too verbose, but let's merge it an if that's the feedback we get, we can scale it back

arguments: Option<&JsonObject>,
debug: bool,
) {
if tool_name == "code_execution__execute_code" {
Copy link
Collaborator

Choose a reason for hiding this comment

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

any way we can avoid hard coding this? if the name changes it would be easy to miss

Copy link
Contributor Author

@rabi rabi Jan 29, 2026

Choose a reason for hiding this comment

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

Thanks @jamadeo, "code_execution__execute_code" and other tool names are hardcoded in other places in the codebase as well (e.g., in extension_manager.rs) and we probably have to change everywhere. I'll propose a followup to change them, if that works for you?

Copy link
Collaborator

Choose a reason for hiding this comment

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

Sounds good, thank you @rabi

@rabi rabi force-pushed the subagent_tool_calls branch from 52e5ff6 to c35da50 Compare January 29, 2026 05:57
- Add notification forwarding from subagent to parent agent
- Create tool call notifications for subagent ToolRequest messages
- Add render_subagent_tool_call() to display tool headers in CLI
- Add formatSubagentToolCall() helper in UI for consistent display
- Use session ID suffix for unique subagent identification

Signed-off-by: rabi <ramishra@redhat.com>
@rabi rabi force-pushed the subagent_tool_calls branch from c35da50 to c514681 Compare February 3, 2026 04:28
@rabi
Copy link
Contributor Author

rabi commented Feb 3, 2026

@DOsinga Hey, when you've time, can you please check if this is something that's going to useful for UX perspective? Thanks.

@peterwilli
Copy link
Contributor

This is amazing, I was looking for something like this!

@jamadeo
Copy link
Collaborator

jamadeo commented Feb 3, 2026

I think it's a solid improvement in the subagent UX. If we need to allow turning down the verbosity, we can always add that in.

@jamadeo jamadeo added this pull request to the merge queue Feb 3, 2026
Merged via the queue into block:main with commit 1e645c0 Feb 3, 2026
18 checks passed
zanesq added a commit that referenced this pull request Feb 3, 2026
* 'main' of github.com:block/goose:
  feat: display subagent tool calls in CLI and UI (#6535)
  chore(release): release version 1.23.0 (minor) (#6906)
  Document keyboard shortcut menu (#6928)
  Document duplicate session button and fork command (#6923)
  docs: cli external editor (#6922)
stebbins pushed a commit to stebbins/goose that referenced this pull request Feb 4, 2026
Signed-off-by: rabi <ramishra@redhat.com>
Signed-off-by: Harrison <hcstebbins@gmail.com>
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.

3 participants