Now liveThe Skillselion MCP - thousands of ranked skills, loaded into your agent mid-task. No install.Get it →
softaworks avatar

Session Handoff

  • 3.9k installs
  • 2.2k repo stars
  • Updated March 5, 2026
  • softaworks/agent-toolkit

How to create and resume AI agent sessions with preserved context, decisions, and work state across multiple runs.

About

session-handoff creates structured handoff documents that allow fresh AI agents to seamlessly continue prior work without context loss. Triggered when users request state saves, context nears capacity, major milestones complete, or sessions end. It provides CREATE and RESUME workflows: CREATE generates timestamped scaffold files with git metadata, recent commits, and modified file lists, then validates completeness and detects secrets before finalizing. RESUME locates previous handoffs, checks staleness against git history and file changes, loads full context chains, and verifies project state before resuming from the next immediate step. Supports chaining for long-running projects, maintaining context lineage across multiple agent sessions. CREATE workflow scaffolds handoff files with git branch, commits, modified files auto-populated RESUME workflow checks staleness (FRESH/SLIGHTLY_STALE/STALE/VERY_STALE) against git history and file timestamps Validation script detects secrets, checks section completion,

  • CREATE workflow scaffolds handoff files with git branch, commits, modified files auto-populated
  • RESUME workflow checks staleness (FRESH/SLIGHTLY_STALE/STALE/VERY_STALE) against git history and file timestamps
  • Validation script detects secrets, checks section completion, scores quality 0-100 before finalizing
  • Handoff chaining links predecessor documents for multi-session context lineage
  • Templates and checklists guide agents through handoff creation and resumption

Session Handoff by the numbers

  • 3,930 all-time installs (skills.sh)
  • +27 installs in the week ending Jul 28, 2026 (Skillselion tracking)
  • Ranked #183 of 16,659 AI & Agent Building skills by installs in the Skillselion catalog
  • Security screen: MEDIUM risk (skills.sh audit)
  • Data as of Jul 28, 2026 (Skillselion catalog sync)
At a glance

session-handoff capabilities & compatibility

Capabilities
generate scaffolded handoff documents with git m · validate handoff completeness and detect secrets · check handoff staleness against git history · list and chain multiple handoffs · resume from prior handoff context
Use cases
debugging · code review · refactoring · orchestration · memory
Platforms
macOS · Windows · Linux · WSL
Runs
Runs locally
Pricing
Free
From the docs

What session-handoff says it does

Solves long-running agent context exhaustion by enabling fresh agents to continue with zero ambiguity.
skill:softaworks/agent-toolkit#session-handoff
npx skills add https://github.com/softaworks/agent-toolkit --skill session-handoff

Add your badge

Show developers this skill is listed on Skillselion. Paste this into your README.

Listed on Skillselion
Installs3.9k
repo stars2.2k
Security audit3 / 3 scanners passed
Last updatedMarch 5, 2026
Repositorysoftaworks/agent-toolkit

What it does

Enable AI agents to save and resume work sessions with full context preservation, avoiding token exhaustion and task discontinuity.

Who is it for?

Multi-session agent workflows, long-running architecture decisions, debugging cycles, large codebase refactoring, handoff between different agents.

Skip if: Single-session tasks, stateless API operations, short conversations, real-time streaming work.

When should I use this skill?

User requests context save, context window approaches capacity, major task milestone completes, work session ends, resuming prior work, or after 5+ file edits or complex decisions.

What you get

Fresh agents resume prior work with zero ambiguity, full decision rationale, file locations, and next-step clarity.

  • Structured handoff markdown document
  • Continuation instructions for next agent session

By the numbers

  • Handoff validation checks 5+ validation criteria (no TODOs, required sections, no secrets, file refs, quality score)
  • Four staleness levels assessed: FRESH, SLIGHTLY_STALE, STALE, VERY_STALE
  • Proactive suggestion triggers after 5+ file edits or complex debugging work

Files

SKILL.mdMarkdownGitHub ↗

Handoff

Creates comprehensive handoff documents that enable fresh AI agents to seamlessly continue work with zero ambiguity. Solves the long-running agent context exhaustion problem.

Mode Selection

Determine which mode applies:

Creating a handoff? User wants to save current state, pause work, or context is getting full.

  • Follow: CREATE Workflow below

Resuming from a handoff? User wants to continue previous work, load context, or mentions an existing handoff.

  • Follow: RESUME Workflow below

Proactive suggestion? After substantial work (5+ file edits, complex debugging, major decisions), suggest:

"We've made significant progress. Consider creating a handoff document to preserve this context for future sessions. Say 'create handoff' when ready."

CREATE Workflow

Step 1: Generate Scaffold

Run the smart scaffold script to create a pre-filled handoff document:

python scripts/create_handoff.py [task-slug]

Example: python scripts/create_handoff.py implementing-user-auth

For continuation handoffs (linking to previous work):

python scripts/create_handoff.py "auth-part-2" --continues-from 2024-01-15-auth.md

The script will:

  • Create .claude/handoffs/ directory if needed
  • Generate timestamped filename
  • Pre-fill: timestamp, project path, git branch, recent commits, modified files
  • Add handoff chain links if continuing from previous
  • Output file path for editing

Step 2: Complete the Handoff Document

Open the generated file and fill in all [TODO: ...] sections. Prioritize these sections:

1. Current State Summary - What's happening right now 2. Important Context - Critical info the next agent MUST know 3. Immediate Next Steps - Clear, actionable first steps 4. Decisions Made - Choices with rationale (not just outcomes)

Use the template structure in references/handoff-template.md for guidance.

Step 3: Validate the Handoff

Run the validation script to check completeness and security:

python scripts/validate_handoff.py <handoff-file>

The validator checks:

  • [ ] No [TODO: ...] placeholders remaining
  • [ ] Required sections present and populated
  • [ ] No potential secrets detected (API keys, passwords, tokens)
  • [ ] Referenced files exist
  • [ ] Quality score (0-100)

Do not finalize a handoff with secrets detected or score below 70.

Step 4: Confirm Handoff

Report to user:

  • Handoff file location
  • Validation score and any warnings
  • Summary of captured context
  • First action item for next session

RESUME Workflow

Step 1: Find Available Handoffs

List handoffs in the current project:

python scripts/list_handoffs.py

This shows all handoffs with dates, titles, and completion status.

Step 2: Check Staleness

Before loading, check how current the handoff is:

python scripts/check_staleness.py <handoff-file>

Staleness levels:

  • FRESH: Safe to resume - minimal changes since handoff
  • SLIGHTLY_STALE: Review changes, then resume
  • STALE: Verify context carefully before resuming
  • VERY_STALE: Consider creating a fresh handoff

The script checks:

  • Time since handoff was created
  • Git commits since handoff
  • Files changed since handoff
  • Branch divergence
  • Missing referenced files

Step 3: Load the Handoff

Read the relevant handoff document completely before taking any action.

If handoff is part of a chain (has "Continues from" link), also read the linked previous handoff for full context.

Step 4: Verify Context

Follow the checklist in references/resume-checklist.md:

1. Verify project directory and git branch match 2. Check if blockers have been resolved 3. Validate assumptions still hold 4. Review modified files for conflicts 5. Check environment state

Step 5: Begin Work

Start with "Immediate Next Steps" item #1 from the handoff document.

Reference these sections as you work:

  • "Critical Files" for important locations
  • "Key Patterns Discovered" for conventions to follow
  • "Potential Gotchas" to avoid known issues

Step 6: Update or Chain Handoffs

As you work:

  • Mark completed items in "Pending Work"
  • Add new discoveries to relevant sections
  • For long sessions: create a new handoff with --continues-from to chain them

Handoff Chaining

For long-running projects, chain handoffs together to maintain context lineage:

handoff-1.md (initial work)
    ↓
handoff-2.md --continues-from handoff-1.md
    ↓
handoff-3.md --continues-from handoff-2.md

Each handoff in the chain:

  • Links to its predecessor
  • Can mark older handoffs as superseded
  • Provides context breadcrumbs for new agents

When resuming from a chain, read the most recent handoff first, then reference predecessors as needed.

Storage Location

Handoffs are stored in: .claude/handoffs/

Naming convention: YYYY-MM-DD-HHMMSS-[slug].md

Example: 2024-01-15-143022-implementing-auth.md

Resources

scripts/

ScriptPurpose
create_handoff.py [slug] [--continues-from <file>]Generate new handoff with smart scaffolding
list_handoffs.py [path]List available handoffs in a project
validate_handoff.py <file>Check completeness, quality, and security
check_staleness.py <file>Assess if handoff context is still current

references/

  • handoff-template.md - Complete template structure with guidance
  • resume-checklist.md - Verification checklist for resuming agents

Related skills

Forks & variants (3)

Session Handoff has 3 known copies in the catalog totaling 20 installs. They canonicalize to this original listing.

How it compares

Unlike prompt injection or context prefixes, session-handoff uses structured markdown documents with git metadata, validation, and staleness checking to enable robust multi-session agent continuity.

FAQ

When should I create a handoff?

Create when: user requests save/pause, context approaches capacity, major milestone completes, session ends, or after substantial work (5+ edits, complex debugging, architecture decisions).

How does staleness checking work?

Staleness script checks time since creation, git commits since handoff, modified files, branch divergence, and missing referenced files - returns FRESH/SLIGHTLY_STALE/STALE/VERY_STALE.

Can I chain handoffs for long projects?

Yes. Use --continues-from flag to link handoffs, maintaining context lineage. Read most recent first, reference predecessors as needed for full history.

Is Session Handoff safe to install?

skills.sh reports 3 of 3 security scanners passed. Review the Security Audits panel on this page before installing in production.

AI & Agent Buildingagentsautomation

This week in AI coding

Five minutes, every Monday - the tools, releases and tactics for developers.

unsubscribe anytime.