Session Wrap
Capture the current session's context and produce two things:
- Persistent documentation — updated or created in the project's own style
- A continuation prompt — a self-contained message that lets the next chat pick up exactly where this one ends
Philosophy
You are intelligent. Don't follow a rigid template — think about what matters for this specific session and project. The goal is: if someone opens a fresh chat tomorrow with zero context, what do they need to seamlessly continue?
Step 1: Discover the Project's Documentation Conventions
Before writing anything, understand how this project already documents things:
- Look for existing patterns: session summaries, ADRs, changelogs, README, CLAUDE.md,
ai/memory/, docs/, decision logs, plan files
- Check git log for recent documentation commits
- Note the naming conventions, file locations, and formats already in use
Adapt to what exists. If the project uses ADRs, update ADRs. If it uses session summaries, create the next one. If nothing exists, create something minimal and well-placed.
Step 2: Capture What Matters
Reflect on the full conversation and extract:
- What was accomplished — decisions made, files created/modified, problems solved
- What's still open — unresolved questions, next steps, blockers
- Critical context — things the next session must know that aren't obvious from the code alone (rationale, rejected approaches, user preferences, constraints discovered)
- The exact pickup point — what specific task or question should the next session start with
Be ruthless about signal vs noise. Only capture what a smart engineer with access to the codebase couldn't figure out on their own.
Step 3: Write Project Documentation
Update or create documentation using the project's conventions:
- Update existing files that track progress (session summaries, plans, decision logs)
- Create new files only if the project's pattern calls for it (e.g., a new session summary in a series)
- Keep it scannable — bullets, tables, clear headers. A reader should get 80% of the value in 30 seconds.
If no conventions exist, create a single SESSION-HANDOFF.md at the project root.
Step 4: Generate Continuation Prompt
Create a prompt the user can paste into a new chat. This is the most important output.
The prompt should:
- Set the role and mission — what kind of work is being done
- Point to prerequisite files — what to read first (be specific with paths)
- State what's already decided — so the next session doesn't re-debate settled questions
- Define the pickup point — the exact next step, framed as an actionable instruction
- Be self-contained — the prompt alone (plus the files it references) should be enough
Write it in the voice of the user giving instructions to a new collaborator. Make it feel natural, not robotic.
Output
Present to the user:
- Session summary — 3-5 sentences of what happened
- Files written/updated — list with paths
- The continuation prompt — ready to copy-paste, in a code block
1---2name: wrap-session3description: Wrap up a session by capturing context, decisions, and state into project-native documentation, then generate a continuation prompt for the next chat. Use when ending a session, switching context, or preparing a handoff.4---56# Session Wrap78Capture the current session's context and produce two things:91. **Persistent documentation** — updated or created in the project's own style102. **A continuation prompt** — a self-contained message that lets the next chat pick up exactly where this one ends1112---1314## Philosophy1516You are intelligent. Don't follow a rigid template — **think about what matters** for this specific session and project. The goal is: if someone opens a fresh chat tomorrow with zero context, what do they need to seamlessly continue?1718---1920## Step 1: Discover the Project's Documentation Conventions2122Before writing anything, understand how this project already documents things:2324- Look for existing patterns: session summaries, ADRs, changelogs, README, CLAUDE.md, `ai/memory/`, `docs/`, decision logs, plan files25- Check git log for recent documentation commits26- Note the naming conventions, file locations, and formats already in use2728**Adapt to what exists.** If the project uses ADRs, update ADRs. If it uses session summaries, create the next one. If nothing exists, create something minimal and well-placed.2930---3132## Step 2: Capture What Matters3334Reflect on the full conversation and extract:3536- **What was accomplished** — decisions made, files created/modified, problems solved37- **What's still open** — unresolved questions, next steps, blockers38- **Critical context** — things the next session must know that aren't obvious from the code alone (rationale, rejected approaches, user preferences, constraints discovered)39- **The exact pickup point** — what specific task or question should the next session start with4041Be ruthless about signal vs noise. Only capture what a smart engineer with access to the codebase couldn't figure out on their own.4243---4445## Step 3: Write Project Documentation4647Update or create documentation using the project's conventions:4849- **Update existing files** that track progress (session summaries, plans, decision logs)50- **Create new files** only if the project's pattern calls for it (e.g., a new session summary in a series)51- **Keep it scannable** — bullets, tables, clear headers. A reader should get 80% of the value in 30 seconds.5253If no conventions exist, create a single `SESSION-HANDOFF.md` at the project root.5455---5657## Step 4: Generate Continuation Prompt5859Create a prompt the user can paste into a new chat. This is the most important output.6061The prompt should:62- **Set the role and mission** — what kind of work is being done63- **Point to prerequisite files** — what to read first (be specific with paths)64- **State what's already decided** — so the next session doesn't re-debate settled questions65- **Define the pickup point** — the exact next step, framed as an actionable instruction66- **Be self-contained** — the prompt alone (plus the files it references) should be enough6768Write it in the voice of the user giving instructions to a new collaborator. Make it feel natural, not robotic.6970---7172## Output7374Present to the user:75761. **Session summary** — 3-5 sentences of what happened772. **Files written/updated** — list with paths783. **The continuation prompt** — ready to copy-paste, in a code block