fix(conversations): Show tool calls and redacted notice on empty transcript#119046
Draft
obostjancic wants to merge 1 commit into
Draft
fix(conversations): Show tool calls and redacted notice on empty transcript#119046obostjancic wants to merge 1 commit into
obostjancic wants to merge 1 commit into
Conversation
…script
When a conversation's generation spans have no message content captured, the
redesigned transcript now shows any tool calls that ran and a muted notice
('Message inputs and outputs were not captured') rather than a blank panel.
Two bugs are fixed:
- mergeEmptyTurns dropped pending tool calls when no generation span had
assistantContent, so tool-only turns were silently lost. They are now
flushed onto a synthetic turn anchored on the last generation span.
- The empty-messages path in MessagesPanelNew now extracts orphaned tool
spans directly from nodes and renders them via MessageToolCallsNew, so
tool-only conversations (no generation spans at all) also surface their
calls.
A new buildToolCallsFromSpans helper is exported for direct conversion of
tool span nodes to ToolCall objects without requiring a generation span.
Refs TET-2607
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
eb06431 to
8bbb688
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
When a conversation's generation spans carry no message content, the redesigned transcript (
gen-ai-conversations-redesign) previously showed a blank "No messages found" panel — even when tool calls had run during the conversation.Two improvements are included:
Show tool calls even when there are no messages. Tool spans are now extracted directly from the node list and rendered via
MessageToolCallsNewin the empty-messages path. This covers both the case where tool spans have no accompanying generation span, and the case where generation spans exist but their inputs/outputs were not captured.Treat missing inputs/outputs as redacted. When the panel renders with no message content, it now shows a muted "Message inputs and outputs were not captured" notice instead of nothing, making the reason for the blank panel explicit.
Bug fix:
mergeEmptyTurnsdropped orphaned tool calls. When every generation span in a conversation had noassistantContent, pending tool calls accumulated but were silently discarded because there was no committed turn to flush onto. The fix creates a synthetic tool-call-only turn from the last generation span in that case, so those calls reachturnsToMessagesand appear as an assistant message with empty text but visible tool badges.A new
buildToolCallsFromSpanshelper is exported for converting raw tool span nodes toToolCall[]without needing a generation span as an anchor.Refs TET-2607