Session Trace
- Desktop app
- All plans
What it does
Replays one agent session turn by turn, from the transcript the CLI writes on your computer. For every turn you see the prompt, the model requests, each tool call with what it acted on, how many bytes came back into the context and how many tokens that added, plus the context the CLI injected on its own (instructions files, hook output, system reminders, skill bodies). Two charts show the context window size after each request and the running total of billed tokens over time. A What filled the context table ranks every source over the whole session (a tool, a skill, an MCP tool, a sub-agent, your prompts, the agent's own output, the starting context), and Biggest single additions lists the single calls that grew the context the most: the usual suspects when a context fills up too fast or a skill costs more than it should. Nothing is sent anywhere.
Where to find it
- Click the N tok badge of an agent's composer to open Session info: the Session trace section sits right under the context window gauge. Click its title to fold or unfold it (the choice is remembered); folded, it shows one line of key figures. The expand icon on its right opens the trace in a larger view.
- In the conversation view of an agent: the trace icon in the toolbar, next to the copy button, opens the larger view.
How to use it
- Open the trace. The figures at the top count the whole session: turns, model requests, tool calls, tokens billed, peak context, data that went into the context, sub-agent spend, compactions.
- Read the charts: a steep step in Context window is a turn that grew the context a lot. Hover for the exact figures, click a point to open its turn. Time spaces points by the clock, Requests gives every request the same width.
- Look at What filled the context to find the tool or skill that weighs the most over the session, and at Biggest single additions for one-off leaks. Click a row to open its turn.
- In Turns, filter by prompt, tool, file or skill, then expand a turn to see each call: its target, the bytes it returned, the context it added, its duration and errors.
The trace refreshes by itself every 10 seconds while it is open, so you can watch a working agent.
Settings
None.
Agent tools (MCP)
None.
Providers
Claude Code and Codex: full trace, in tokens, read from the provider's billed usage of each request. Antigravity: the CLI does not record token usage, so the trace counts bytes and draws no context line. Other CLIs (Grok, Mistral Vibe, oh-my-pi, OpenCode, Cursor, Copilot…) are not supported yet: the trace button does not appear for them.
Mobile
Not available on the mobile app (the app has no Session info view).
Limits
- The transcript must exist on this computer: a session run on another machine cannot be traced here.
- Transcripts over 200 MB are not traced.
- The list shows the 300 most recent turns and up to 200 calls per turn (the heaviest); the figures, tables and charts still count everything.
- "Context added" is the growth of the context between two requests, shared by size between what entered it. It is a measure from the provider's own usage, not an estimate, but a share between several results of the same request is proportional to their size.
- Codex sub-agents are not yet attached to the call that started them.
Common questions
- How do I find which skill or tool eats my context? Open the session trace and read What filled the context: sources are ranked by the context they added over the whole session.
- Why does my context fill up so fast? Look at Biggest single additions and the steps of the Context window chart: a whole-file read, a big command output, a screenshot or a long skill body usually stands out.
- Does the trace send my session anywhere? No. It is read from the CLI's transcript on your computer.
- What is "The agent's own output"? What the agent wrote itself (answers, reasoning, the content of files it wrote): it stays in the context too.
- What is the "Starting context"? The first request's context: system prompt, tool definitions and instructions files, before any work.
Related
- Claude Code Token Usage: the token badge and Session info the trace opens from.
- Conversation View: the other entry point.