[Feature Request] Command to view/export context compaction summary

Resolved 💬 3 comments Opened Jan 29, 2026 by campusitconsulting Closed Feb 2, 2026

Preflight Checklist

  • [x] I have searched existing requests and this feature hasn't been requested yet
  • [x] This is a single feature request (not multiple features)

Problem Statement

When context runs out or /compact is used, Claude generates a summary that gets passed to the next session (starting with "This session is being continued from a previous conversation..."). Currently there is no way to:

  1. View this summary before or after compaction
  2. 2. Export it to a file for review
  3. 3. Verify what context was preserved vs lost

This makes it difficult to:

  • Debug issues where Claude "forgot" important context
  • - Understand what information survives compaction
  • - - Create manual checkpoints of conversation state

Note: This feature was previously requested in #667 but was auto-closed after 60 days of inactivity without implementation or official response.

Proposed Solution

Add a command to view or export the compaction summary:

/show-summary          # Display the current compaction summary
/show-summary --export # Export to file

Or alternatively:

/compact --preview     # Show what the summary would be without compacting
/compact --export      # Compact and save summary to file

Use Cases

  1. Debugging context loss - Verify what Claude retained after compaction
  2. 2. Manual checkpointing - Save summaries for different feature branches (see #12686 3. Quality control - Review summary before continuing long sessions
  3. 4. Understanding behavior - Learn what Claude considers important to preserve

Related Issues

  • #667 - Requested same feature, auto-closed due to inactivity
  • - #21243 - Broader request for compaction visibility and control

Alternative Solutions

Current workarounds are inadequate:

  1. Using --verbose flag - May show some internal details but doesn't expose the actual summary text
  2. 2. Checking ~/.claude/projects/ logs - Conversation JSON files might contain summary data but format is undocumented and not user-friendly
  3. 3. Manual note-taking - Keeping separate notes of conversation state defeats the purpose of automatic summarization

Priority

Medium - Would be very helpful

Feature Category

CLI commands and flags

Use Case Example

  1. Working on a complex refactoring task across multiple files
  2. 2. Context runs low and auto-compaction triggers
  3. 3. Claude continues but seems to have "forgotten" some earlier decisions
  4. 4. Want to verify what was preserved in the summary
  5. 5. Run /show-summary to see the compaction summary
  6. 6. Discover that important architectural decisions were summarized too briefly
  7. 7. Re-read the relevant documentation to restore that context

Additional Context

Environment: Claude Code CLI, all platforms

View original on GitHub ↗

This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗