ClaudeCodeTranscript

works.iterative.claude.ui.claudecode.ClaudeCodeTranscript

The Claude Code adapter: one agent tool's log, read as a transcript.

Only two of Claude Code's entry types carry conversation — user and assistant. Everything else in a transcript file is bookkeeping the reader never sees (file snapshots, mode changes, attachments), and is dropped.

The hard part is that a user entry is not the same thing as a person speaking. Claude Code writes the person's typed message, the expanded body of a slash command or skill, the results of every tool the agent ran, and its own notifications, all as user entries. Attributing any of those to the person would put words in their mouth, so each is recognised and shown as activity instead:

  • isMeta is Claude Code's own marker for text it injected rather than received — expanded command and skill bodies, resumption prompts.
  • isCompactSummary marks the summary written when a session runs out of context. It carries what came before and is worth reading, but it is the tool's account of the conversation, not a turn in it.
  • a turn consisting solely of one of Claude Code's wrapper blocks is that wrapper, not a message; text that merely mentions a wrapper is not.
  • tool results arrive as tool_result content blocks, and read best next to the call they answer, so they are labelled with that tool's name.

Sub-agent entries are a separate source with their own file, joined to a parent tool call; a sidechain entry appearing here is not part of this conversation and is dropped.

Attributes

Graph
Supertypes
class Object
trait Matchable
class Any
Self type

Members list

Value members

Concrete methods

def read(sessionId: String, entries: Seq[ConversationLogEntry]): Transcript

Reads a session's entries as the transcript a person reads.

Reads a session's entries as the transcript a person reads.

Value parameters

entries

the session's main-thread entries, oldest first

sessionId

the session the entries came from, echoed onto the page

Attributes