From 907d09570cd9ce906f52551f7d9d9e908cb28839 Mon Sep 17 00:00:00 2001 From: zerone0x Date: Wed, 4 Mar 2026 04:04:23 +0100 Subject: [PATCH] fix(tui): restore agent name in task progress display MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The v1.2.16 refactor (PR #15607) replaced BlockTool with InlineTool for task rendering. The old code showed the agent type (subagent_type) in the BlockTool title as "# AgentName Task". The new inline format only shows "Task description", dropping the agent name entirely. Restore the agent name prefix so the output reads: │ Explore: Task Verify Refit cancellation behavior └ 22 toolcalls · 1m 1s Falls back to plain "Task description" when subagent_type is not set. Fixes #15915 Co-Authored-By: Claude --- packages/opencode/src/cli/cmd/tui/routes/session/index.tsx | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/packages/opencode/src/cli/cmd/tui/routes/session/index.tsx b/packages/opencode/src/cli/cmd/tui/routes/session/index.tsx index e2747ad3b7a0..4800560fd5a5 100644 --- a/packages/opencode/src/cli/cmd/tui/routes/session/index.tsx +++ b/packages/opencode/src/cli/cmd/tui/routes/session/index.tsx @@ -1975,7 +1975,10 @@ function Task(props: ToolProps) { const content = createMemo(() => { if (!props.input.description) return "" - let content = [`Task ${props.input.description}`] + const agentPrefix = props.input.subagent_type + ? `${Locale.titlecase(props.input.subagent_type)}: ` + : "" + let content = [`${agentPrefix}Task ${props.input.description}`] if (isRunning() && tools().length > 0) { // content[0] += ` · ${tools().length} toolcalls`