brainstorming
Structured design dialogue that validates ideas before implementation begins.
context-handoff
Save working state before compaction or session end for reliable recovery
Full skill instructions
Category: Operations Last Updated: January 2026
Ensure reliable context recovery across compaction and session boundaries.
This skill creates a checkpoint of working state that enables another Claude instance (or the same instance post-compaction) to continue work without loss. It addresses the critical gap where automatic or manual compaction can occur without state being persisted.
Key Principle: After this skill runs, current-task.md alone should contain everything needed to continue work.
/compact/context-handoff or /checkpoint (alias)/context)DETERMINE active project:
- Check if in a project worktree
- Check git branch name (feature/{project-name})
- Check recent file modifications under projects/
- If ambiguous: Ask user
IF no active project:
→ "No active project detected. Nothing to checkpoint."
→ STOP
LOCATE current-task.md:
- Path: projects/{project-name}/current-task.md
- IF missing: Create from template
This is the minimum state required for recovery. Be concise.
CAPTURE (in memory first):
1. TASK IDENTIFICATION
- Task ID (from current work or current-task.md)
- Task file path
- Task title
- Current phase
2. PROGRESS STATE
- Completed steps (numbered list)
- Current step number and description
- Step progress (e.g., "Step 4 of 7, sub-step 2 of 3")
3. FILES MODIFIED (this session only)
- List all files created or modified
- Brief purpose for each
- Mark any uncommitted changes
4. DECISIONS MADE (this session only)
- Key implementation choices
- Why each decision was made
- Any alternatives considered
5. NEXT ACTION (CRITICAL - must be explicit)
- Exact next step to take
- Any preconditions
- Files to reference
Structure the update with Quick Recovery at top:
# Current Task State - {Project Name}
> **Last Updated**: {YYYY-MM-DD HH:MM} (by context-handoff)
> **Recovery**: Read "Quick Recovery" section first
---
## Quick Recovery (READ THIS FIRST)
| Field | Value |
|-------|-------|
| **Task** | {NNN} - {Title} |
| **Step** | {N} of {Total}: {Step description} |
| **Status** | {in-progress / blocked} |
| **Next Action** | {Explicit next action to take} |
### Files Modified This Session
- `{path}` - {purpose}
- `{path}` - {purpose}
### Critical Context
{1-3 sentences of essential context for continuation}
---
## Full State (Detailed)
[... rest of current-task.md content ...]
VERIFY current-task.md is complete:
- Quick Recovery section has all fields
- Next Action is explicit (not vague)
- Files Modified matches actual changes
- Timestamp is updated
OPTIONAL: Commit the checkpoint
IF uncommitted changes exist:
→ "Do you want me to commit the state checkpoint? [y/n]"
IF yes:
git add projects/{project-name}/current-task.md
git commit -m "checkpoint: save state for {task-id}"
REPORT to user:
"✅ Context checkpoint saved to current-task.md
Task: {task-id} - {title}
Step: {N} of {total}
Next: {next action}
Ready for /compact or session end.
To resume: 'continue task' or 'where was I?'"
The "Quick Recovery" section must answer these questions in < 30 seconds:
Example:
## Quick Recovery (READ THIS FIRST)
| Field | Value |
|-------|-------|
| **Task** | 045 - Deploy to Production |
| **Step** | 4 of 7: Configure Azure credentials |
| **Status** | in-progress |
| **Next Action** | Test deployment with: `az webapp deploy --slot staging` |
### Files Modified This Session
- `infrastructure/bicep/stacks/model2-full.bicep` - Added AI Search config
- `src/server/api/Sprk.Bff.Api/Program.cs` - Registered RagService
### Critical Context
OIDC federated identity configured. Staging deployment succeeded.
Need to verify health checks before promoting to production.
User: "I need to compact"
↓
Claude: [Invokes context-handoff]
↓
Claude: "✅ State saved. Ready for /compact."
↓
User: /compact
↓
[Compaction occurs]
↓
User: "Where was I?"
↓
Claude: [Invokes project-continue]
↓
Claude: Reads Quick Recovery section, continues work
[Claude working on task]
↓
[After completing step 5 of 8]
↓
Claude: [Proactively invokes context-handoff]
↓
Claude: "Checkpoint saved. Continuing with step 6..."
context-handoff: Creates checkpoint → current-task.md
project-continue: Reads checkpoint → restores context
When to self-checkpoint (Claude should do this automatically):
| Condition | Action |
|---|---|
| Completed a task step | Update current-task.md completed steps |
| Modified 5+ files | Run full context-handoff |
| Made significant decision | Log in current-task.md decisions |
| 30+ minutes of work | Run full context-handoff |
| Before large operation | Run full context-handoff |
| Context feels "heavy" | Check /context, consider checkpoint |
| Situation | Response |
|---|---|
| No active project | "No project context to save. Working on ad-hoc tasks?" |
| current-task.md missing | Create from template, populate with current state |
| Can't determine current task | Ask user: "Which task are you working on?" |
| Conflicting state in file | Ask user: "current-task.md shows task X, but you seem to be on Y. Which is correct?" |
| Git commit fails | "Checkpoint saved but not committed. Commit manually if needed." |
User: "I need to compact, save my progress first"
Claude: [Runs context-handoff]
Output:
"✅ Context checkpoint saved to current-task.md
Task: 032 - Implement Email Export
Step: 3 of 5: Create EmailExportService
Next: Implement SendEmailAsync method using Graph API
Files modified:
- Services/Ai/Export/IEmailExportService.cs - Created interface
- Services/Ai/Export/EmailExportService.cs - Started implementation
Ready for /compact. To resume: 'continue task' or 'where was I?'"
[Claude just completed step 5 of 8]
Claude: "Step 5 complete. Let me checkpoint progress..."
[Runs context-handoff silently]
Claude: "✅ Progress saved. Continuing with Step 6: Add unit tests..."
User: "I'm done for today"
Claude: [Runs context-handoff]
Output:
"✅ Session state saved.
Task 013 at Step 4 of 6.
Next session: Say 'continue task 013' or 'where was I?'
Good night!"
| Skill | Relationship |
|---|---|
project-continue | Reads what context-handoff writes |
task-execute | Should call context-handoff after steps |
push-to-github | Can commit checkpoint as part of workflow |
dotnet test" IS explicitWhen Claude Code resumes after compaction:
This can be automatic if the user's first message is work-related, or explicit via "where was I?".
This skill ensures no work is lost across context boundaries.
Structured design dialogue that validates ideas before implementation begins.
Comprehensive design intelligence for web and mobile UI/UX across 10 technology stacks.
Comprehensive implementation plans for multi-step tasks, breaking down specs into bite-sized, testable steps.
Introduction to the obra skills system with mandatory skill invocation rules and best practices.
Execute a written implementation plan with critical review and task checkpoints.
Delegate independent tasks to specialized agents working concurrently with isolated context.
Isolated git worktrees with smart directory selection and safety verification.
Toolkit for interacting with and testing local web applications using Playwright. Supports verifying frontend functionality, debugging UI behavior, capturing browser screenshots, and viewing browser logs.
Plan searchable and shareable content that drives traffic, builds authority, and generates leads.
README-first repository scanner that extracts commands and classifies reproduction candidates without executing them.
Brainstorm and prioritize marketing strategies tailored to your SaaS stage, budget, and goals.
Plan and optimize your website's page hierarchy, navigation, URL structure, and internal linking.
The world's fastest calendar for remote work
Capture, organize, and utilize your knowledge effortlessly.
Instant Summaries of Audio & Video Interviews with AnySummary
Transform PDFs into engaging mind maps.
Chat with any PDF instantly
Create an optimal daily plan using your voice
A productivity platform to centralize organizational knowledge and workflows with contextual AI assistance.
AskYourPDF Pricing Plans: Tailored to Your Needs