save-state
Skill0 starsChanged 3 months agoMITView on GitHub
Preserve and resume a software project's rolling current state by connecting the user's detailed vision, long-term stages, active-stage phases, immediate actions, technical evidence, successful approaches, failed attempts, and corrections. Use when the user asks to save state, load or check the current project state, see where work left off, add a note to SaveState, checkpoint or close out a state cycle, or persist a project-direction change.
3 other projects use a version of this.
Adopted by
Most recently taken up by
- collectifweb/claude-skillstheir own version, first seen Oct 17, 2026
- bitan-del/claude-skill-save-statetheir own version, first seen May 30, 2026
- tranhieutt/software_development_departmenttheir own version, first seen Apr 30, 2026
Other versions3 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 3
- tranhieutt/software_development_department★ 71same name
- collectifweb/claude-skills★ 4same name
- bitan-del/claude-skill-save-state★ 2same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
The file
We split this skill into the rules it gives an agent
2 rules. 0 are common, 1 is distinctive, and 1 is very specific to this project.
0
Common
Most of the 3 edited versions we read keep these.
1
Distinctive
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 29
Read .savestate/CURRENT.md only if the compact result is insufficient, and the active phase file only when the handoff points at unresolved …
- Distinctive: line 31
Do not begin work. Wait for the user to approve, redirect, or ask.
“Common” is measured: kept by at least 6 in 10 of the 3 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
SaveState
Goal-to-execution continuity: load the compact rolling handoff, brief the user, work after they approve, then save the session delta without losing unresolved prior context.
Current Claude session: ${CLAUDE_SESSION_ID}
Setup
PROJECT_ROOT="$(git rev-parse --show-toplevel 2>/dev/null || pwd)"
PYTHON="$(command -v python3 || command -v python)"
SS="$PYTHON ${CLAUDE_SKILL_DIR}/scripts/state.py"State lives in .savestate/. JSON under .savestate/data/ is the machine source of truth; Markdown files are generated views, so never rewrite them directly. CURRENT.md is the hot handoff.
Load, check, or where we left off
Loading is read-only; it must not initialize, archive, or commit anything.
$SS load --root "$PROJECT_ROOT" --lite- Read
.savestate/CURRENT.mdonly if the compact result is insufficient, and the active phase file only when the handoff points at unresolved detail. - Brief the user in this order: active project path; last session; immediate resume point; open session targets (mention blocked ones with their reasons); one relevant recent issue when useful.
- Do not begin work. Wait for the user to approve, redirect, or ask. Ordinary language like "continue" then starts work; if no briefing exists yet in the conversation, brief first.
Save
A save is one semantic transaction: save-prep, one JSON delta, one apply.
$SS save-prep --root "$PROJECT_ROOT" --session-id "${CLAUDE_SESSION_ID}"
cat <<'JSON' | $SS apply --root "$PROJECT_ROOT" --session-id "${CLAUDE_SESSION_ID}" -
{ ...delta... }
JSONsave-prep returns expected_revision, a prefilled delta_skeleton, the previous handoff, active stage and phase summaries, open target IDs, pending note IDs, Git context, and warnings. If session_warnings reports an empty session ID, decide the boundary yourself: pass "boundary": "new" on your first save of this conversation and "same" afterward; never let a conversation end unarchived because the ID was unavailable.
Reconcile before writing: CURRENT.md is an advancing working note, so every prior item ends up carried forward, progressed, completed, blocked, superseded, or resolved. Never silently drop an unreached target, an unresolved blocker, a live warning, or a still-correct resume point. Omitted fields are preserved automatically; resolve or replace things explicitly. Verify evidence (branch, diff, tests, observed results) before claiming completion.
Routine delta cheat sheet
Most saves need only these fields; all are optional except expected_revision:
{"expected_revision": 0,
"session_summary": "short commit subject",
"handoff": {"last_session": ["what happened"],
"resume_point": {"action": "", "location": "", "start_with": "", "expected": "", "verify": ""}},
"handoff_ops": [
{"op": "complete_target", "id": "ACT-000", "result": ""},
{"op": "add_target", "text": ""},
{"op": "carry_forward_target", "id": "ACT-000"},
{"op": "block_target", "id": "ACT-000", "reason": ""},
{"op": "add_issue", "text": ""},
{"op": "resolve_issue", "text": "exact existing text or the op is rejected"},
{"op": "append_last_session", "text": ""}],
"accomplished": [{"what": "", "how": "", "evidence": "", "files": []}],
"failed": [{"attempt": "", "why": "", "correction": ""}],
"decisions": [{"what": "", "why": ""}],
"lessons": [{"kind": "success", "summary": "", "detail": ""}],
"resolve_notes": ["NOTE-000"],
"git": {"commit": true}}For anything beyond the cheat sheet, vision_ops, goal_ops (stages and phases), or technical, read references/SCHEMA.md first.
The engine applies transactionally: an independent conservation auditor rejects any change the delta does not authorize, the commit is verified after landing with automatic restore on failure, and every applied delta is journaled under .savestate/history/journal/. A rejected save changes nothing. Use --dry-run before risky direction changes. Report only what changed, warnings, the Git result, and the new resume point.
Quick reference
- Exact lightweight note (no full save):
printf '%s' "wording" | $SS note --root "$PROJECT_ROOT" --session-id "${CLAUDE_SESSION_ID}"(stdin form;--textfails on dash-leading wording) - Retrieval, always targeted:
$SS vision --tags x,$SS phase PH-000,$SS find --id/--file/--tag/--text ...,$SS history [--journal] - Health and recovery:
$SS doctor [--repair]; run it whenever an apply fails twice checkpointfreezes a snapshot;closeoutarchives the cycle and opens a new one
Read when the situation arises
references/WORKFLOWS.md: the goal model (vision, stages, phases, actions), vision maturity and approval rules, phase lifecycle and completion evidence, direction changes, checkpoint and closeout semantics, budget distillationreferences/SCHEMA.md: full delta field reference for vision, goal, decision, lesson, and technical operationsreferences/OPERATIONS.md: session boundaries, interrupted-operation recovery, concurrency, drift repair
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

