durable-session-state

Persist task plans, scope decisions, and gate approvals to durable project files.

437|45|Updated Jan 27, 2026
One-click install
npx skills add https://github.com/ZaxbyHub/opencode-swarm --skill durable-session-state
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: durable-session-state
Source: https://github.com/ZaxbyHub/opencode-swarm/tree/main/.claude/skills/durable-session-state
Command: npx skills add https://github.com/ZaxbyHub/opencode-swarm --skill durable-session-state

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Long-running swarm-mode AI coding sessions lose critical context during compaction, restarts, or handoffs, leading to re-litigated settled decisions, invalidated approvals, and wasted rework of already completed work.

Core Features & Use Cases

  • Durable artifact persistence: Automatically saves task plans, scope decisions, validation evidence, and reviewer/critic gate approvals to structured, project-local files.
  • Stale approval detection: Tracks git HEAD and diff summaries at each gate approval to automatically invalidate outdated approvals when work continues after a session resumes.
  • Use case: Ideal for multi-phase swarm development tasks, long coding sessions, and cross-session handoffs, ensuring no work is lost or repeated unnecessarily.

Quick Start

Use the durable-session-state skill to save your current task's plan, decisions, and gate approvals to the project's .claude/session/tasks/ directory before your session compacts or restarts.

Frequently Asked Questions about durable-session-state

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

FAQPage Schema
How do I persist AI coding session state across context compaction and restarts?

To persist session state across compaction, save task plans, scope decisions, and validation evidence to durable project files in the .claude/session/tasks/ directory before your session compacts or restarts. This ensures long-running swarm-mode tasks retain critical context.

What is stale approval detection in swarm-mode development?

Stale approval detection tracks git HEAD and diff summaries at each gate approval to automatically invalidate outdated reviewer approvals when code edits occur after a session resumes. This enforces the swarm-mode contract that approvals must happen after the latest edit.

How do I save task artifacts and gate approval ledgers for cross-session handoffs?

You can save task artifacts and gate approval ledgers by writing them to structured, project-local files. This automatically persists critical validation evidence and approval records, preventing re-litigated decisions and wasted rework during team handoffs.

Does durable session persistence work with multi-phase development workflows?

Yes, durable session persistence is ideal for multi-phase swarm development tasks and long coding sessions. It maintains authoritative task artifacts and validation evidence across compaction, restarts, and handoffs, ensuring no completed work is lost or repeated.

Why does session context loss cause rework in long-running AI coding tasks?

Session context loss causes rework because compaction, restarts, or handoffs drop critical task plans and settled scope decisions. Without durable persistence to project files, teams face invalidated approvals and must re-litigate previously settled decisions unnecessarily.