Agent skill · Code Review & Quality

session-inspector

This skill should be used when inspecting, analyzing, or querying Claude Code session logs. Use when users ask about session history, want to find sessions, analyze context usage, extract tool call patterns, debug agent execution, or understand what happened in previous sessions. Essential for understanding Claude Code's ~/.claude/projects/ structure, JSONL session format, and the erk extraction pipeline.

majiayu000github.com/majiayu000GitHub ↗
claude-codeMIT
Install
npx skills add majiayu000/claude-skill-registry --skill session-inspector --agent claude-code

Same command for any agent — swap --agent for codex, cursor, copilot.

Facts
Files in the skill folder: 2
SKILL.md size: 8 KB
Bundled scripts: none
Path: skills/analysis/session-inspector/SKILL.md
Open the folder on GitHub →
Where it comes from
Stars: 534
Language: HTML

Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.

From the SKILL.md

# Session Inspector ## Overview Session Inspector provides comprehensive tools for inspecting Claude Code session logs stored in `~/.claude/projects/`. The skill enables: - Discovering and listing sessions for any project/worktree - Preprocessing sessions to readable XML format - Analyzing context window consumption - Extracting plans from sessions - Creating GitHub issues from session content - Debugging agent subprocess execution - Understanding the two-stage extraction pipeline ## When to Use Invoke this skill when users: - Ask what sessions exist for a project or worktree - Want to find a specific session by ID or content - Need to analyze context window consumption - Ask about tool call patterns or frequencies - Need to debug agent subprocess failures - Want to extract plans from sessions - Ask about session history or previous conversations - Need to understand session preprocessing or extraction ## Quick Reference: CLI Commands All commands invoked via `erk exec <command>`: | Command | Purpose | | ---------------------------- | ------------------------------------------------ | | `list-sessions` | List sessions with metadata for current worktree | | `preprocess-session` | Co

What's inside
Steps it walks through
  1. Overview
  2. When to Use
  3. Quick Reference: CLI Commands
  4. Slash Commands
  5. Core Capabilities
  6. 1. List Sessions
  7. 2. Preprocess Session to XML
  8. 3. Extract Plan from Session
  9. 4. Create GitHub Issue from Session
  10. 5. Render Session for GitHub
  11. 6. Extract Session from GitHub Issue
  12. Directory Structure
  13. Session ID
  14. Two-Stage Extraction Pipeline
Ships with 1 file
  • metadata.json
Commands it runs
erk exec list-sessions [--limit N] [--min-size BYTES]
erk exec preprocess-session <log-path> [OPTIONS]
erk exec extract-latest-plan [--session-id SESSION_ID]
erk exec create-issue-from-session [--session-id SESSION_ID]
erk exec render-session-content --session-file <path> [--session-label LABEL] [--extraction-hints HINTS]
erk exec extract-session-from-issue <issue-number> [--output PATH] [--session-id ID]
erk exec list-sessions --session-id abc123-def456
erk exec extract-latest-plan --session-id <id>
erk exec create-issue-from-session --session-id <id>
ls -lt "$PROJECT_DIR"/agent-*.jsonl | head -10
More from claude-skill-registry
All skills →
About this skill
What does the session-inspector skill do?

This skill should be used when inspecting, analyzing, or querying Claude Code session logs. Use when users ask about session history, want to find sessions, analyze context usage, extract tool call patterns, debug agent execution, or understand what happened in previous sessions. Essential for understanding Claude Code's ~/.claude/projects/ structure, JSONL session format, and the erk extraction pipeline.

How do I install it?

Run `npx skills add majiayu000/claude-skill-registry --skill session-inspector --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.

Where does this skill come from?

From majiayu000/claude-skill-registry, a repository with 534 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.

Is a popular skill a good skill?

Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.

Keep going