https://github.com/maksandre/debrief
A local UI for inspecting Claude Code session logs. Useful when developing subagents and skills
https://github.com/maksandre/debrief
agents claude claude-code llm-tools observability trace-viewer
Last synced: 10 days ago
JSON representation
A local UI for inspecting Claude Code session logs. Useful when developing subagents and skills
- Host: GitHub
- URL: https://github.com/maksandre/debrief
- Owner: Maksandre
- Created: 2026-05-14T13:19:11.000Z (about 2 months ago)
- Default Branch: main
- Last Pushed: 2026-06-11T17:42:08.000Z (19 days ago)
- Last Synced: 2026-06-11T19:19:43.776Z (19 days ago)
- Topics: agents, claude, claude-code, llm-tools, observability, trace-viewer
- Language: TypeScript
- Homepage:
- Size: 941 KB
- Stars: 2
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Debrief
A local inspector for Claude Code sessions. Reads the `.jsonl` trace files Claude Code writes under `~/.claude/` and turns them into readable conversations plus analytics — cost, prompt-cache health, context-window headroom, where the time went, and where things went wrong.
Useful when developing custom subagents and skills: the delegation tree, per-agent transcripts, prompts, tool calls, and per-agent spend are all visible side by side, and every insight links back to the exact message that produced it.

## What it shows
- The full transcript of a session: user messages, assistant turns, thinking blocks, tool calls, and tool results.
- A sidebar listing every project and session found on disk.
- Live sessions, refreshed every 5 seconds.
- In-conversation search.
- Light and dark themes.
## Stats per session

Cost, token volume, wall-clock duration, peak context vs the model's window, and a per-agent breakdown. Interactive panels surface the actionable detail:
- **Prompt caching** — a context-over-time chart marking every cache rebuild, what each cost, and why (idle TTL expiry, model switch, prefix change), each clickable to the message.
- **Cost & models** — spend per model.
- **Where the time went** — a chronological strip of agent-working vs waiting-on-you vs idle/away time, with clickable spans.
- **Friction** — tool errors and interruptions, grouped and linked.
## Subagent delegation

If the session used subagents, the delegation tree is shown with each agent's prompt, model, tool calls, duration, and cost. Click a row to open that agent's transcript.
## Run
```bash
npm install
npm run dev
```
Then open [http://localhost:5173](http://localhost:5173).
Single-port production build:
```bash
npm run build
npm start # http://localhost:3099
```
Docker:
```bash
docker compose up # http://localhost:3099 — mounts ~/.claude read-only
```
Sessions are read from `~/.claude` by default. Override with the `CLAUDE_DIR` environment variable.
## Cost numbers
Costs are **notional**: every session is priced as if the tokens were billed at the public Anthropic API rates, regardless of how you actually pay. If you're on a Claude Pro/Max subscription, no money was charged per token — the figure shown is what the same usage would have cost on the metered API, which is a useful proxy for comparing sessions, agents, and runs against each other.
Rates come from a bundled snapshot covering Opus, Sonnet, and Haiku 3 → 4.x. Bedrock and Vertex routing are not modeled.