From 5f8c5e98c3a1b98612057b94f0eaef96402fbd05 Mon Sep 17 00:00:00 2001 From: Jason Lernerman Date: Mon, 24 Aug 2026 21:45:33 -0400 Subject: [PATCH] fix(simulate): mark a cited tool output where it prints A summary can cite a tool output, and the digit jump opened the job without marking it: outputs were skipped unless tool detail was on, and printed with no mark when it was. A cited output now prints regardless of the toggle and carries the mark, like a cited function call. --- cmd/lk/simulate_tui.go | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/cmd/lk/simulate_tui.go b/cmd/lk/simulate_tui.go index 33800b37..914c5dc1 100644 --- a/cmd/lk/simulate_tui.go +++ b/cmd/lk/simulate_tui.go @@ -1931,16 +1931,23 @@ func (m *simulateModel) renderChatTranscript(jobID string) string { } writeToolItem(&b, fmt.Sprintf("ƒ %s(%s)", fc.Name, m.toolArguments(fc.Arguments)), wrapWidth, mark) case *agent.ChatContext_ChatItem_FunctionCallOutput: - if !m.showToolDetail { + fco := v.FunctionCallOutput + // a jump has to land on the turn it cited, so a cited output prints + // whether or not tool detail is on + mark := "" + if m.citedItem(fco.Id) { + cited = true + mark = citedMark() + } + if !m.showToolDetail && mark == "" { continue } - fco := v.FunctionCallOutput output := strings.TrimSpace(fco.Output) if output == "" { continue } ensureAgentBlock() - writeToolItem(&b, "→ "+output, wrapWidth, "") + writeToolItem(&b, "→ "+output, wrapWidth, mark) case *agent.ChatContext_ChatItem_AgentHandoff: h := v.AgentHandoff old := ""