qpact

Analyzes the current Claude Code session and renders an interactive HTML report with a tuned /compact instruction.

Updated Aug 14, 2026
One-click install
npx skills add https://github.com/QSchlegel/session-viz --skill qpact-qschlegel
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: qpact
Source: https://github.com/QSchlegel/session-viz/tree/main/plugins/session-viz/skills/qpact
Command: npx skills add https://github.com/QSchlegel/session-viz --skill qpact-qschlegel

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) components.

What problem does it solve? A bare /compact command summarizes a session generically, often losing the architecture decisions and open threads that matter. This Skill analyzes the current Claude Code session transcript, measures prompting quality and friction, and produces a focused /compact instruction so compaction preserves what the session was actually about. ## Core Features & Use Cases - Session spine extraction: Collapses a multi-megabyte transcript into a compact JSON spine with a computed score, friction metrics, and per-turn token data. - Persistent intent store: Merges conclusions into a per-repository store so re-runs reuse prior analysis instead of re-deriving it, with turn-level citations for every claim. - Interactive HTML report: Renders the session as an interactive document with a concept graph and a copyable /compact instruction at the top. - Use Case: Before compacting a long debugging session, run /qpact to get a measured quality score, see where the session drifted, and copy a /compact line that names the exact decisions and unresolved threads to preserve. ## Quick Start Ask the assistant to run /qpact to analyze the current session and open the HTML report with the copyable /compact instruction.

Frequently Asked Questions about qpact

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I analyze my current Claude Code session before compacting?▼

Run /qpact in Claude Code. It extracts the session transcript into a JSON spine, computes a quality score with friction metrics, renders an interactive HTML report, and places a copyable /compact instruction at the top of the page.

How to make /compact preserve important decisions from a long session?▼

Run /qpact first. It derives what the session was actually about and writes focus instructions naming the architecture, decisions, and open threads to keep, which you paste into /compact so the summary retains them.

Can the AI run /compact automatically after the analysis?▼

No. /compact is a built-in command only the user can invoke, and the PreCompact hook cannot inject instructions. The Skill delivers a copy-pasteable instruction line in the HTML report instead.

Does re-running the analysis on the same session redo all the work?▼

No. A per-repository intent store records prior runs. On a re-run, only new turns are analyzed; fields left out of the update are kept exactly as recorded, with their original turn citations and dates.

What data does the session report send off my machine?▼

The first run prints a full disclosure and sends nothing. Later runs ship 48 bounded fields plus the rendered page by default; titles quoting prompts are withheld, and --withhold-document keeps the facts while stopping the page.