Agent skill

Checkpoint

by pedrohcgs in pedrohcgs/claude-code-my-workflow

Save a structured state snapshot before stopping or handing off.

MITAuto-check: notesAgent Workflows

Install Checkpoint

skills CLI
$ npx skills add pedrohcgs/claude-code-my-workflow --skill checkpoint -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install pedrohcgs/claude-code-my-workflow checkpoint --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/pedrohcgs/claude-code-my-workflow.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.claude/skills/checkpoint .claude/skills/checkpoint && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
checkpoint
GitHub stars
1.7k
Token cost
~2.8k tokens
SKILL.md length
1,038 words
Files
1
Skills in repo
59
Repo updated
First seen
Licence
MIT

At a glance

Save a structured state snapshot before stopping or handing off.

  • Works in 4 steps: Gather state → Write the checkpoint → Propose memory updates (skip if… → …
  • User says checkpoint
  • SKILL.md covers When to use, When NOT to use, Workflow and Cross-references, plus 2 more sections
  • Calls git

What it does

Checkpoint is an agent skill from pedrohcgs/claude-code-my-workflow. Save a structured state snapshot before stopping or handing off. Captures the active plan, recent decisions, file pointers (with line numbers), open questions, and the next 1–3 actions into a checkpoint file under qualityreports/checkpoints/. Optionally proposes [LEARN] entries to add to MEMORY.md. Use when user says "checkpoint", "save state", "snapshot before I stop", "where am I", "wrap up the session for handoff", or before a long break / model switch / collaborator handoff. Companion to (NOT replacement for)…

Its SKILL.md is about 2.8k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.

It sits in Agent Workflows, covering Session handoff. It works with Git. The repository describes itself as: A ready-to-fork Claude Code template for academics using LaTeX/Beamer + R. Multi-agent review, quality gates, adversarial QA, and replication protocols. The licence is MIT.

When your agent uses it

  • User says checkpoint
  • Snapshot before I stop
  • Wrap up the session for handoff
  • Before a long break / model switch / collaborator handoff

Example prompts

  • “checkpoint”
  • “save state”
  • “snapshot before I stop”
  • “/checkpoint”

Requirements

  • Pre-approved tools (allowed-tools): Read, Write, Bash

Workflow steps

4 steps, taken from the step headings in SKILL.md.

  1. Gather state
  2. Write the checkpoint
  3. Propose memory updates (skip if --no-memory)
  4. Output summary

What it can do on your machine

Read from SKILL.md and the folder at commit ae72617. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves these tools, so the agent can use them without asking each time:

    • Read
    • Write
    • Bash

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Shell commands in SKILL.md call:

    • git

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md. Its commands use git, which can reach the network depending on how they are called.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Checkpoint loads about 2.8k tokens when it runs. Until then it costs about 143 tokens; SKILL.md has 1,038 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~143
When it runs · the whole SKILL.md, loaded when a task matches
~2.8k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check: notes

The automated check noted patterns worth knowing about, such as sudo or a known installer.

  • NotePre-approves every shell command (allowed-tools: Bash)SKILL.md
    allowed-tools: Read, Write, Bash

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from pedrohcgs/claude-code-my-workflow at commit ae72617, republished under its MIT licence (© pedrohcgs). 1,038 words, ~2,836 tokens.

Download SKILL.mdSave it as .claude/skills/checkpoint/SKILL.md (or your agent's skills folder).
name
checkpoint
description
Save a structured state snapshot before stopping or handing off. Captures the active plan, recent decisions, file pointers (with line numbers), open questions, and the next 1–3 actions into a checkpoint file under `quality_reports/checkpoints/`. Optionally proposes `[LEARN]` entries to add to MEMORY.md. Use when user says "checkpoint", "save state", "snapshot before I stop", "where am I", "wrap up the session for handoff", or before a long break / model switch / collaborator handoff. Companion to (NOT replacement for) the narrative session-log workflow.
allowed-tools
Read, Write, Bash
argument-hint
[short-topic-slug] [--no-memory]
disable-model-invocation
true
metadata.author
Claude Code Academic Workflow
metadata.version
1.0.0
<!-- Pattern adapted from Hugo Sant'Anna's clo-author v4.2.0 (github.com/hugosantanna/clo-author),
     used with permission. Original /checkpoint shape: project-level session handoff with
     state snapshot + memory updates. This implementation is reimplemented in original
     prose against this template's narrative-session-log + plan-on-disk + auto-memory
     architecture. Attribution credit: Hugo Sant'Anna. -->

/checkpoint — Structured Session Handoff

Produce a state snapshot that the next session (yours, or a collaborator's, or a fresh-context reboot) can resume from in under a minute. The narrative quality_reports/session_logs/ continues to live separately — /checkpoint writes the structured side: facts, file pointers, and next-actions.

When to use

  • Before a long break, model switch (Opus ↔ Sonnet ↔ Haiku), or end of a working day.
  • Before auto-compaction would otherwise discard mid-plan context (paired with the PreCompact hook).
  • Before handing off to a collaborator on the same repo.
  • After completing a chunk of a multi-session plan, when "where am I" is the first question the next session will ask.

When NOT to use

  • For the narrative what happened — that lives in quality_reports/session_logs/ (see .claude/rules/session-logging.md).
  • For commit messages — those go through /commit, which writes its own structured commit body.
  • For decisions about alternatives — those go to templates/decision-record.md via quality_reports/decisions/.

The three artifact types are complementary: session-log = narrative, decision-record = trade-off captured, checkpoint = state to resume from.

Workflow

PHASE 1 — Gather state

Read, in this order:

  1. Most recent plan — ls -t quality_reports/plans/*.md | head -1. Extract: status (DRAFT / APPROVED / COMPLETED), title, top-level files-to-modify list, and any line that begins with "Open questions" / "Risks" / "Next".
  2. Most recent session log — ls -t quality_reports/session_logs/*.md | head -1. Extract: latest "Next steps" or "Blockers" lines.
  3. MEMORY.md root — read the table of [LEARN] entries already on disk so you don't propose duplicates.
  4. Git state — git log --oneline -20, git status -s, git branch --show-current. Capture: current branch, last 5 subjects, uncommitted file count.
  5. Working files — git diff --stat HEAD to see which files changed in this session (skip if branch is freshly cut; just say "no in-session edits").
  6. Active TODOs — if a TodoWrite list is in flight in this session, capture the in-progress + next-pending items.
  7. In-flight background work — anything this session started and did not wait for: a long-running compute job, a scheduled routine (.claude/references/scheduled-routines.md), a queued render or compile, an external review still out with a referee or another model. For each, record four things: what is running, where its artifacts land, the command that checks on it, and the verdict that ends it.

If any of these reads fails (file missing), record "(none on disk)" rather than fabricating content.

A checkpoint that omits a running job orphans it. The next session sees no trace of the work, the artifacts land in a directory nobody is watching, and the job is either re-launched from scratch or quietly abandoned half-finished — both expensive, both invisible.

PHASE 2 — Write the checkpoint

Write only what this session established. The next session is handed this file automatically (session-handoff.py), so anything invented here arrives there as fact.

  • Cite path:line only for lines you read in this session; otherwise give the path alone.
  • Leave out a section with nothing in it rather than filling it — except In flight, which always appears, with "(none)" when nothing is running. A quiet session gets a short file and no [LEARN] proposals.
  • Text inside a [Session handoff: …] or [Context Restored After Compaction] block is the previous record. Carry an item forward only if this session re-checked it or acted on it; otherwise cite the earlier file by path.
  • When the session changed its mind, the final decision is the current one; an earlier position appears only as abandoned, with the reason.

Write to quality_reports/checkpoints/YYYY-MM-DD_$ARGUMENTS.md (slug from $ARGUMENTS; if no arg, derive from the active plan's title and warn the user). The file uses this template:

markdown
---
date: YYYY-MM-DD
branch: [current-branch]
plan: [path to active plan, or "(none)"]
session-log: [path to most recent session log, or "(none)"]
status: in_progress | paused | ready-to-merge
---

# Checkpoint — [short topic]

## Goal (one sentence)
[What this work is trying to accomplish]

## Where I am (one paragraph)
[Last completed step, current step, what's just-not-yet-done. Bullet points OK.]

## File pointers
[Concrete references to where the next session should resume — up to 8. `path:line` only for lines read in this session; otherwise the path alone.]
- `.claude/skills/checkpoint/SKILL.md:42` — body draft, needs trigger-phrase tightening
- `quality_reports/plans/[slug].md:135` — verification section to refresh after impl
- `CHANGELOG.md` — Unreleased section, v1.8.0 entry not yet drafted

## In flight
[Jobs still running that this session did not wait for. One row each; write "(none)" if nothing is running — an empty section reads as an oversight.]

| What is running | Artifacts land in | Check with | Ends when |
|---|---|---|---|
| overnight parameter sweep | `output/sweep/` | `ls output/sweep \| wc -l` | 500 result files, no `errors.log` |
| external referee consult | `quality_reports/oracle_audits/2026-04-27_lemma3/` | `oracle session lemma3-r1 --render` | transcript archived + adjudicated |

## Recent decisions
[2–5 bullet points of *why* we did what we did this session. Things that wouldn't be obvious from the diff. Skip if none — do not pad.]

## Open questions
[Specific things you'd ask if someone else picked this up. Mark each as Q1, Q2 …]

## Next 1–3 actions
[Imperative form. Concrete. The next session opens this file and starts here.]
1. [...]
2. [...]
3. [...]

## Resume prompt
> Resuming from checkpoint `quality_reports/checkpoints/[filename]`. Read it, then continue with action 1.

Keep the file under ~80 lines. If state is too large for that, the plan file (not the checkpoint) is the right place; checkpoint is a thin index pointing back at the plan.

Show full SKILL.md (427 more words)Show less
PHASE 3 — Propose memory updates (skip if --no-memory)

Surface 0–3 candidate [LEARN] entries this session generated. Don't write to MEMORY.md without user approval — this is a propose-then-apply step:

For each candidate, present:

[LEARN:category] proposed: <one-line headline>
Why: <one sentence on what makes this non-obvious>
Apply where: <which future situations would benefit>

If the user says "yes" / "all" / "1 and 3" — append to MEMORY.md (root, the committed one) using the [LEARN] format. If the candidate is machine-specific (paths, tool versions, personal preference), let native auto memory hold it instead (machine-local, per .claude/rules/meta-governance.md).

Stay below 3 candidates. If you have more, the session was probably under-narrated — flag it and recommend a session-log update instead.

PHASE 4 — Output summary

Print, to chat:

✓ Checkpoint saved: quality_reports/checkpoints/YYYY-MM-DD_<slug>.md
  Branch: <branch>     Status: <in_progress|paused|ready-to-merge>
  Active plan: <path or none>     Open questions: <count>
  Resume: the next fresh `claude` here receives this checkpoint once from the session-handoff
          hook (within 7 days, unless a newer checkpoint or /compress-session note is written
          first). After that, or in `claude --continue` (which does not deliver it), tell Claude
          to read this file or paste its "Resume prompt".

If memory candidates were proposed, summarise which (if any) the user accepted.

Cross-references

  • .claude/rules/session-logging.md — narrative companion. Do not duplicate — the checkpoint references the latest session log by path; it does not re-tell the session story.
  • .claude/rules/plan-first-workflow.md — checkpoint reads the active plan; if no plan exists, recommend the user enter plan mode before invoking /checkpoint.
  • templates/decision-record.md — for why we chose A over B, not for where we are.
  • .claude/references/scheduled-routines.md — routines that outlive the session; anything running there belongs in the "In flight" slot.
  • .claude/hooks/pre-compact.py — when CLAUDE_PRECOMPACT_BLOCK_ON_DRAFT=1 is set, the PreCompact hook will block compaction once per DRAFT plan. /checkpoint is the right thing to run when that block fires.

Examples

Example 1 — End-of-day handoff

User says: "checkpoint v180-polisci" Actions:

  1. Read quality_reports/plans/2026-04-27_v180-polisci-apr2026.md (active, DRAFT).
  2. Read quality_reports/session_logs/2026-04-27_v180-polisci-apr2026.md.
  3. Capture: branch feat/v1.8.0-polisci-apr2026, 4 commits ahead of main, 8 files modified.
  4. Write quality_reports/checkpoints/2026-04-27_v180-polisci.md with file pointers to the half-drafted methods-referee.md and the un-started journal-profiles.md poli-sci block.
  5. Propose 1 candidate [LEARN:scope] entry on the linear-cost of disciplinary breadth. Result: Next session: start a fresh claude — the handoff hook hands it quality_reports/checkpoints/2026-04-27_v180-polisci.md — and start at action 1.
Example 2 — Mid-plan model switch

User says: "I want to switch to Sonnet for the cheap doc edits — checkpoint first" Actions:

  1. Capture state.
  2. Write checkpoint with status: paused.
  3. Skip memory proposal (small lift — just resuming on a different model). Result: State is on disk; the Sonnet session reads the checkpoint and continues without reloading the full plan.

Troubleshooting

No active plan found. /checkpoint will still write a thin checkpoint with plan: (none), but the right move is usually to enter plan mode first — checkpoints without a plan reference are weak.

Topic-slug missing. If $ARGUMENTS is empty, derive from the active plan filename (strip date prefix). If both are missing, prompt the user for one rather than fabricating.

Output too long. Trim the "Recent decisions" and "Open questions" first. Plans go in plan files; the checkpoint should fit on a screen.

© pedrohcgs, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in .claude/skills/checkpoint of pedrohcgs/claude-code-my-workflow.

Open the folder on GitHubat commit ae72617

Compare with similar skills

Checkpoint next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Checkpoint compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Checkpoint this skillpedrohcgs/claude-code-my-workflow1.7k—~2.8kAutomated safety check: NotesMIT
Beads Task Memorygastownhall/beads28k—~1.2kAutomated safety check: PassMIT
Session History Searchslopus/happy24k—~3.1kAutomated safety check: PassMIT
Codewhale Session Handoffcodewhale-hq/Codewhale41k—~1.1kAutomated safety check: PassMIT
Auditopenwpm/OpenWPM1.4k—~676Automated safety check: PassCustom licence
MemorixAVIDS2/memorix837—~516Automated safety check: PassApache-2.0

Similar skills

  • Beads Task Memory

    gastownhall/beads

    Tracks multi-session work with dependencies in the bd issue tracker so the agent can find ready tasks and recover its context after conversation compaction.

    28k GitHub stars~1.2k tokensUpdated today
    Agent WorkflowsAuto-check passed
  • Searches past Claude Code, Codex and Cursor sessions and summarizes what was worked on, tried or decided, using extraction scripts instead of reading raw logs.

    24k GitHub stars~3.1k tokensUpdated today
    Agent WorkflowsAuto-check passed
  • Codewhale Session Handoff

    codewhale-hq/Codewhale

    Writes a paste-ready handoff for the next agent session, opening with a state-check command block and separating done, suspected and blocked work.

    41k GitHub stars~1.1k tokensUpdated today
    Agent WorkflowsAuto-check passed
  • Audit

    openwpm/OpenWPM

    A skill your agent uses when stuck, confused, or disoriented in a crosslink-tracked project — dumps the full context (session state, active issue, locks, blockers, hook config, git state, project…

    1.4k GitHub stars~676 tokensUpdated 4 days ago
    Agent WorkflowsAuto-check passed
  • Memorix

    AVIDS2/memorix

    A skill your agent uses when Claude Code needs Memorix shared memory, reasoning, Git Memory, mini-skills, session handoff, orchestration coordination, or integration troubleshooting.

    837 GitHub stars~516 tokensUpdated today
    Agent WorkflowsAuto-check passed
  • Session Catchup and Handoff

    poshan0126/dotclaude

    Rebuilds working context after /clear by reading a handoff note and the branch's git state, or writes that handoff note before a session ends.

    871 GitHub stars~811 tokensUpdated 1 mo ago
    Agent WorkflowsAuto-check passed

More from pedrohcgs/claude-code-my-workflow

All 59 skills in this repo
  • Devils Advocate

    pedrohcgs/claude-code-my-workflow

    Adversarial 5-7 question challenge to a deck's pedagogical choices — ordering, prerequisites, cognitive load, motivation.

    1.7k GitHub starsUsed in 2 repos~641 tokens
    Auto-check passed
  • Vaccinate

    pedrohcgs/claude-code-my-workflow

    Qualify a check before it is allowed to clear anything — prove it can detect the failure it is meant to catch.

    1.7k GitHub stars~2.1k tokensUpdated 11 days ago
    Auto-check: notes
  • Compile Latex

    pedrohcgs/claude-code-my-workflow

    Compile a Beamer LaTeX slide deck with XeLaTeX (3 passes + bibtex).

    1.7k GitHub starsUsed in 1 repo~492 tokens
    Auto-check: notes
  • Context Status

    pedrohcgs/claude-code-my-workflow

    Show current context status and session health. An agent skill from pedrohcgs/claude-code-my-workflow.

    1.7k GitHub starsUsed in 1 repo~613 tokens
    Auto-check: notes
  • Capture Environment

    pedrohcgs/claude-code-my-workflow

    Snapshot the computational environment for a replication package — detects the analysis stack (R / Stata / Python) and emits the right lockfiles (renv.lock + sessionInfo.txt, requirements.txt /…

    1.7k GitHub stars~2.8k tokensUpdated 11 days ago
    Auto-check: notes
  • Coauthor Brief

    pedrohcgs/claude-code-my-workflow

    Generate a co-author / collaborator handoff brief for a multi-author, multi-machine project — summarizing what changed since the last brief (git delta), the current state of each artifact…

    1.7k GitHub stars~2.9k tokensUpdated 11 days ago
    Auto-check: notes

Works with

Categories

Questions about Checkpoint

What does Checkpoint do?

Save a structured state snapshot before stopping or handing off. Checkpoint is an agent skill from pedrohcgs/claude-code-my-workflow. Save a structured state snapshot before stopping or handing off.

When should I use Checkpoint?

Checkpoint fits situations like: user says checkpoint; snapshot before I stop; wrap up the session for handoff; before a long break / model switch / collaborator handoff.

How do I install Checkpoint in Claude Code?

Run `npx skills add pedrohcgs/claude-code-my-workflow --skill checkpoint -a claude-code`. Or copy the skill folder (.claude/skills/checkpoint in pedrohcgs/claude-code-my-workflow) into .claude/skills/checkpoint in your project. Claude Code loads it when a task matches its description.

How do I install Checkpoint in Codex?

Run `npx skills add pedrohcgs/claude-code-my-workflow --skill checkpoint -a codex`. Or copy the skill folder (.claude/skills/checkpoint in pedrohcgs/claude-code-my-workflow) into .agents/skills/checkpoint in your project. Codex loads it when a task matches its description.

Can I use Checkpoint in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add pedrohcgs/claude-code-my-workflow --skill checkpoint -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/checkpoint, .gemini/skills/checkpoint, .github/skills/checkpoint and .opencode/skills/checkpoint in your project.

What does Checkpoint need to run?

Going by SKILL.md and its folder, Checkpoint needs the command-line tools its instructions call (git). Its frontmatter pre-approves these tools: Read, Write, Bash.

Does Checkpoint access the network?

SKILL.md contains no URLs. Its commands use git, which can reach the network depending on how they are called. This is read from the text; nothing was executed.

Is Checkpoint safe to install?

Our automated static check of SKILL.md found notes only (pre-approves every shell command (allowed-tools: bash)), nothing it rates as a warning. It is not a guarantee. Review the folder before installing.

What licence does Checkpoint use?

Checkpoint is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Checkpoint use?

About 2.8k tokens (SKILL.md is roughly 11k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Checkpoint?

Skills that share tags, products or a category with Checkpoint: Beads Task Memory (gastownhall/beads, 28k stars), Session History Search (slopus/happy, 24k stars), Codewhale Session Handoff (codewhale-hq/Codewhale, 41k stars) and Audit (openwpm/OpenWPM, 1.4k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Checkpoint?

pedrohcgs (a GitHub user) maintains it in pedrohcgs/claude-code-my-workflow, which has 1,653 GitHub stars. The repository holds 59 skills in this directory. The repository was last updated on September 27, 2026.

Source: pedrohcgs/claude-code-my-workflow on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.