From 0a451c73c96364e648b5187a68632c8d78077308 Mon Sep 17 00:00:00 2001 From: Dax Raad Date: Tue, 3 Mar 2026 09:40:46 -0500 Subject: [PATCH 01/14] tui: remove extra empty line from exit message logo display --- packages/opencode/src/cli/cmd/tui/routes/session/index.tsx | 1 - 1 file changed, 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 6062bb07b1..a3f14d6bf9 100644 --- a/packages/opencode/src/cli/cmd/tui/routes/session/index.tsx +++ b/packages/opencode/src/cli/cmd/tui/routes/session/index.tsx @@ -241,7 +241,6 @@ export function Session() { const logo = UI.logo(" ").split(/\r?\n/) return exit.message.set( [ - ``, `${logo[0] ?? ""}`, `${logo[1] ?? ""}`, `${logo[2] ?? ""}`, From e5c5c1df1251e12b9a86727e79092f2979754747 Mon Sep 17 00:00:00 2001 From: Dax Raad Date: Tue, 3 Mar 2026 11:18:18 -0500 Subject: [PATCH 02/14] tui: consistent arrow symbols and indentation in tool output MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Changed tool output formatting to use ↳ consistently for child items instead of mixed └ and spaces, making the terminal interface visual hierarchy clearer when displaying loaded files and running task progress. --- .../opencode/src/cli/cmd/tui/routes/session/index.tsx | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) 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 a3f14d6bf9..0ac96a36d6 100644 --- a/packages/opencode/src/cli/cmd/tui/routes/session/index.tsx +++ b/packages/opencode/src/cli/cmd/tui/routes/session/index.tsx @@ -1879,9 +1879,7 @@ function Read(props: ToolProps) { {(filepath) => ( - - ↳ Loaded {normalizePath(filepath)} - + ↳ Loaded {normalizePath(filepath)} )} @@ -1987,19 +1985,19 @@ function Task(props: ToolProps) { 0}> {" "} · {tools().length} toolcalls - + {(item) => { const title = createMemo(() => (item().state as any).title) return ( <> - {"\n"}└ {Locale.titlecase(item().tool)} {title()} + {"\n"}↳ {Locale.titlecase(item().tool)} {title()} ) }} - {"\n "} + {"\n↳ "} {tools().length} toolcalls · {Locale.duration(duration())} From 1f3ee037aaf31574763af16964efadefb30f9a36 Mon Sep 17 00:00:00 2001 From: Dax Raad Date: Tue, 3 Mar 2026 11:21:32 -0500 Subject: [PATCH 03/14] tui: prefix task descriptions with 'Task' label for clearer identification during delegation --- packages/opencode/src/cli/cmd/tui/routes/session/index.tsx | 2 +- 1 file changed, 1 insertion(+), 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 0ac96a36d6..71ac810e93 100644 --- a/packages/opencode/src/cli/cmd/tui/routes/session/index.tsx +++ b/packages/opencode/src/cli/cmd/tui/routes/session/index.tsx @@ -1981,7 +1981,7 @@ function Task(props: ToolProps) { pending="Delegating..." part={props.part} > - {props.input.description} + Task {props.input.description} 0}> {" "} · {tools().length} toolcalls From 5527b4ea4d3cf91ade526903984a093788866f7a Mon Sep 17 00:00:00 2001 From: Dax Raad Date: Tue, 3 Mar 2026 13:16:00 -0500 Subject: [PATCH 04/14] tui: simplify running tool display to show tool names more directly in task UI --- .../opencode/src/cli/cmd/tui/routes/session/index.tsx | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) 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 71ac810e93..dad1b5d2fb 100644 --- a/packages/opencode/src/cli/cmd/tui/routes/session/index.tsx +++ b/packages/opencode/src/cli/cmd/tui/routes/session/index.tsx @@ -1986,14 +1986,7 @@ function Task(props: ToolProps) { {" "} · {tools().length} toolcalls - {(item) => { - const title = createMemo(() => (item().state as any).title) - return ( - <> - {"\n"}↳ {Locale.titlecase(item().tool)} {title()} - - ) - }} + {"\n"}↳ {Locale.titlecase(current()!.tool)} {(current()!.state as any).title} From ce9900dca09fce449d24ec3e5f5de508c0e766ec Mon Sep 17 00:00:00 2001 From: Dax Raad Date: Tue, 3 Mar 2026 13:16:26 -0500 Subject: [PATCH 05/14] tui: improve toolcall duration visual alignment by adding consistent indentation --- packages/opencode/src/cli/cmd/tui/routes/session/index.tsx | 2 +- 1 file changed, 1 insertion(+), 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 dad1b5d2fb..7722cc795e 100644 --- a/packages/opencode/src/cli/cmd/tui/routes/session/index.tsx +++ b/packages/opencode/src/cli/cmd/tui/routes/session/index.tsx @@ -1990,7 +1990,7 @@ function Task(props: ToolProps) { - {"\n↳ "} + {"\n ↳ "} {tools().length} toolcalls · {Locale.duration(duration())} From ec56e95b9c04b53d1231cdca4643a094ce73aeba Mon Sep 17 00:00:00 2001 From: Dax Raad Date: Tue, 3 Mar 2026 13:41:22 -0500 Subject: [PATCH 06/14] tui: show loaded file paths inline with Read tool to reduce visual clutter tui: change Task tool icon to vertical ellipsis for clearer visual distinction --- .../src/cli/cmd/tui/routes/session/index.tsx | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) 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 7722cc795e..f088cc5b8f 100644 --- a/packages/opencode/src/cli/cmd/tui/routes/session/index.tsx +++ b/packages/opencode/src/cli/cmd/tui/routes/session/index.tsx @@ -1875,14 +1875,14 @@ function Read(props: ToolProps) { part={props.part} > Read {normalizePath(props.input.filePath!)} {input(props.input, ["filePath"])} + + {(filepath) => ( + <> + {"\n"}↳{" "}Loaded {normalizePath(filepath)} + + )} + - - {(filepath) => ( - - ↳ Loaded {normalizePath(filepath)} - - )} - ) } @@ -1975,7 +1975,7 @@ function Task(props: ToolProps) { return ( Date: Tue, 3 Mar 2026 13:51:39 -0500 Subject: [PATCH 07/14] tui: improve path display and consistency in session view --- .../src/cli/cmd/tui/routes/session/index.tsx | 34 +++++++++++-------- 1 file changed, 20 insertions(+), 14 deletions(-) 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 f088cc5b8f..7048f97455 100644 --- a/packages/opencode/src/cli/cmd/tui/routes/session/index.tsx +++ b/packages/opencode/src/cli/cmd/tui/routes/session/index.tsx @@ -1875,14 +1875,14 @@ function Read(props: ToolProps) { part={props.part} > Read {normalizePath(props.input.filePath!)} {input(props.input, ["filePath"])} - - {(filepath) => ( - <> - {"\n"}↳{" "}Loaded {normalizePath(filepath)} - - )} - + + {(filepath) => ( + + ⤷ Loaded {normalizePath(filepath)} + + )} + ) } @@ -1985,12 +1985,12 @@ function Task(props: ToolProps) { 0}> {" "} · {tools().length} toolcalls - - {"\n"}↳ {Locale.titlecase(current()!.tool)} {(current()!.state as any).title} + + {"\n"}⤷ {Locale.titlecase(current()!.tool)} {(current()!.state as any).title} - {"\n ↳ "} + {"\n ⤷ "} {tools().length} toolcalls · {Locale.duration(duration())} @@ -2212,10 +2212,16 @@ function Diagnostics(props: { diagnostics?: Record[] function normalizePath(input?: string) { if (!input) return "" - if (path.isAbsolute(input)) { - return path.relative(process.cwd(), input) || "." - } - return input + + const cwd = process.cwd() + const absolute = path.isAbsolute(input) ? input : path.resolve(cwd, input) + const relative = path.relative(cwd, absolute) + + if (!relative) return "." + if (!relative.startsWith("..")) return relative + + // outside cwd - use absolute + return absolute } function input(input: Record, omit?: string[]): string { From 98309fdd58ff44b8eabbbd5c155758a3e2e1b579 Mon Sep 17 00:00:00 2001 From: Dax Raad Date: Tue, 3 Mar 2026 13:59:15 -0500 Subject: [PATCH 08/14] tui: simplify task tool display with cleaner tree indentation MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Replaces the '⋮' icon with '│' and updates the tree formatting to use consistent '└' characters for better visual hierarchy when showing running and completed task states. --- .../src/cli/cmd/tui/routes/session/index.tsx | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) 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 7048f97455..ddbe1d2a70 100644 --- a/packages/opencode/src/cli/cmd/tui/routes/session/index.tsx +++ b/packages/opencode/src/cli/cmd/tui/routes/session/index.tsx @@ -1975,23 +1975,19 @@ function Task(props: ToolProps) { return ( Task {props.input.description} - 0}> - {" "} - · {tools().length} toolcalls - - {"\n"}⤷ {Locale.titlecase(current()!.tool)} {(current()!.state as any).title} - + 0}> · {tools().length} toolcalls + + {"\n└"} {Locale.titlecase(current()!.tool)} {(current()!.state as any).title} - {"\n ⤷ "} - {tools().length} toolcalls · {Locale.duration(duration())} + {"\n└ "} {tools().length} toolcalls · {Locale.duration(duration())} ) From 8d232d35ebad37d2aad9cbd0ba227ad219703d4b Mon Sep 17 00:00:00 2001 From: Dax Raad Date: Tue, 3 Mar 2026 13:59:45 -0500 Subject: [PATCH 09/14] tui: fix task display nesting so running status only shows when toolcalls exist --- .../src/cli/cmd/tui/routes/session/index.tsx | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) 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 ddbe1d2a70..35a3c50fc4 100644 --- a/packages/opencode/src/cli/cmd/tui/routes/session/index.tsx +++ b/packages/opencode/src/cli/cmd/tui/routes/session/index.tsx @@ -1982,12 +1982,16 @@ function Task(props: ToolProps) { part={props.part} > Task {props.input.description} - 0}> · {tools().length} toolcalls - - {"\n└"} {Locale.titlecase(current()!.tool)} {(current()!.state as any).title} + 0}> + {" "} + · {tools().length} toolcalls + + {"\n└"} {Locale.titlecase(current()!.tool)} {(current()!.state as any).title} + - {"\n└ "} {tools().length} toolcalls · {Locale.duration(duration())} + {"\n└ "} + {tools().length} toolcalls · {Locale.duration(duration())} ) From c27779e1b2c2a4ac94274d55a1d6ee7061a06497 Mon Sep 17 00:00:00 2001 From: Dax Raad Date: Tue, 3 Mar 2026 14:09:27 -0500 Subject: [PATCH 10/14] tui: improve task status display readability in session view Refactored task status rendering to provide clearer information about tool execution progress. Users now see a more consistent and readable format showing active tool calls and completion timing. --- .../src/cli/cmd/tui/routes/session/index.tsx | 30 +++++++++++-------- 1 file changed, 18 insertions(+), 12 deletions(-) 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 35a3c50fc4..7103bec2d3 100644 --- a/packages/opencode/src/cli/cmd/tui/routes/session/index.tsx +++ b/packages/opencode/src/cli/cmd/tui/routes/session/index.tsx @@ -1973,6 +1973,23 @@ function Task(props: ToolProps) { return assistant - first }) + const content = createMemo(() => { + if (!props.input.description) return "" + let content = [`Task ${props.input.description}`] + + if (isRunning() && tools().length > 0) { + content[0] += ` · ${tools().length} toolcalls` + if (current()) content.push(`⤷ ${Locale.titlecase(current()!.tool)} ${(current()!.state as any).title}`) + else content.push(`⤷ Running...`) + } + + if (props.part.state.status === "completed") { + content.push(`└ ${tools().length} toolcalls · ${Locale.duration(duration())}`) + } + + return content.join("\n") + }) + return ( ) { pending="Delegating..." part={props.part} > - Task {props.input.description} - 0}> - {" "} - · {tools().length} toolcalls - - {"\n└"} {Locale.titlecase(current()!.tool)} {(current()!.state as any).title} - - - - {"\n└ "} - {tools().length} toolcalls · {Locale.duration(duration())} - + {content()} ) } From 37fdbe7fa65b250b70fecbbcbe6895de41d9656c Mon Sep 17 00:00:00 2001 From: Dax Raad Date: Tue, 3 Mar 2026 14:12:27 -0500 Subject: [PATCH 11/14] =?UTF-8?q?tui:=20use=20cleaner=20=E2=94=94=20charac?= =?UTF-8?q?ter=20for=20task=20indicators?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Replaces the ⤷ arrow with a cleaner └ character when displaying running tool calls in task output, improving visual clarity in the session interface. --- packages/opencode/src/cli/cmd/tui/routes/session/index.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) 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 7103bec2d3..22f5f8a65c 100644 --- a/packages/opencode/src/cli/cmd/tui/routes/session/index.tsx +++ b/packages/opencode/src/cli/cmd/tui/routes/session/index.tsx @@ -1979,8 +1979,8 @@ function Task(props: ToolProps) { if (isRunning() && tools().length > 0) { content[0] += ` · ${tools().length} toolcalls` - if (current()) content.push(`⤷ ${Locale.titlecase(current()!.tool)} ${(current()!.state as any).title}`) - else content.push(`⤷ Running...`) + if (current()) content.push(`└ ${Locale.titlecase(current()!.tool)} ${(current()!.state as any).title}`) + else content.push(`└ Running...`) } if (props.part.state.status === "completed") { From 6dd903c34845714e6f82678986b94ca114693665 Mon Sep 17 00:00:00 2001 From: Dax Raad Date: Tue, 3 Mar 2026 14:14:43 -0500 Subject: [PATCH 12/14] tui: remove toolcall count from task status to reduce visual clutter --- packages/opencode/src/cli/cmd/tui/routes/session/index.tsx | 2 +- 1 file changed, 1 insertion(+), 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 22f5f8a65c..73ceccc553 100644 --- a/packages/opencode/src/cli/cmd/tui/routes/session/index.tsx +++ b/packages/opencode/src/cli/cmd/tui/routes/session/index.tsx @@ -1978,7 +1978,7 @@ function Task(props: ToolProps) { let content = [`Task ${props.input.description}`] if (isRunning() && tools().length > 0) { - content[0] += ` · ${tools().length} toolcalls` + // content[0] += ` · ${tools().length} toolcalls` if (current()) content.push(`└ ${Locale.titlecase(current()!.tool)} ${(current()!.state as any).title}`) else content.push(`└ Running...`) } From 07025ef5b9793f2ae7d690cf8853cf88a02fba48 Mon Sep 17 00:00:00 2001 From: Dax Raad Date: Tue, 3 Mar 2026 14:36:08 -0500 Subject: [PATCH 13/14] tui: use arrow indicator to clearly show active tool execution in session view --- packages/opencode/src/cli/cmd/tui/routes/session/index.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) 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 73ceccc553..e12b026484 100644 --- a/packages/opencode/src/cli/cmd/tui/routes/session/index.tsx +++ b/packages/opencode/src/cli/cmd/tui/routes/session/index.tsx @@ -1979,8 +1979,8 @@ function Task(props: ToolProps) { if (isRunning() && tools().length > 0) { // content[0] += ` · ${tools().length} toolcalls` - if (current()) content.push(`└ ${Locale.titlecase(current()!.tool)} ${(current()!.state as any).title}`) - else content.push(`└ Running...`) + if (current()) content.push(`⤷ ${Locale.titlecase(current()!.tool)} ${(current()!.state as any).title}`) + else content.push(`⤷ Running...`) } if (props.part.state.status === "completed") { From dc2c9c7673dc16bf7a1f61a728b4412ea5b69536 Mon Sep 17 00:00:00 2001 From: Dax Raad Date: Tue, 3 Mar 2026 15:06:07 -0500 Subject: [PATCH 14/14] tui: show pending toolcall count instead of generic 'Running...' message --- packages/opencode/src/cli/cmd/tui/routes/session/index.tsx | 2 +- 1 file changed, 1 insertion(+), 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 e12b026484..26b2631957 100644 --- a/packages/opencode/src/cli/cmd/tui/routes/session/index.tsx +++ b/packages/opencode/src/cli/cmd/tui/routes/session/index.tsx @@ -1980,7 +1980,7 @@ function Task(props: ToolProps) { if (isRunning() && tools().length > 0) { // content[0] += ` · ${tools().length} toolcalls` if (current()) content.push(`⤷ ${Locale.titlecase(current()!.tool)} ${(current()!.state as any).title}`) - else content.push(`⤷ Running...`) + else content.push(`⤷ ${tools().length} toolcalls`) } if (props.part.state.status === "completed") {