fd-checkpoint

A command that saves the current agent session to checkpoint.json and STATE.md so it can be resumed later. It is part of a workflow that tracks the project's planning state.

In plain words
What is it for?
Use it to force a session checkpoint, update the recorded status and completed steps, and prepare the workspace for /fd-resume.
Why use it?
It creates a recovery point before ending or interrupting a session, preserving progress and status.

Command

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add commands/dvnghiem/flowdeck/fd-checkpoint
Clone the repo
git clone --depth 1 https://github.com/DVNghiem/FlowDeck
Per session 0 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 759 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00000 $0.00759
Opus 5 $0.00000 $0.00380
Sonnet 5 $0.00000 $0.00152
Haiku 4.5 $0.00000 $0.00076

Measured 3d ago against content hash a29a295c3b49, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

fd-checkpoint scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 3d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

docs/commands/fd-checkpoint.md · 70 lines

How it starts

The opening of the file, as written. The whole thing — 70 lines — stays where its author put it; the contents beside it link to each section on GitHub.

/fd-checkpoint

Purpose: Force-save the current session to checkpoint.json and STATE.md so it can be safely resumed later with /fd-resume. Normally runs automatically on session.idle via the session-events hook; invoke manually to force a save before closing a session.

Usage

/fd-checkpoint

What Happens

  1. Check ~/.fd-plan/<slug>/STATE.md exists. If not, error: "No planning workspace. Run /fd-task to start."
  2. Read the current STATE.md and the existing ~/.fd-plan/<slug>/checkpoint.json if present.
  3. Update STATE.md:
    • Set last_updated to the current timestamp
    • Ensure status reflects current state accurately
  4. If ~/.fd-plan/<slug>/<topic>/plan.md exists, scan it for completed steps and update steps_complete in STATE.md.
  5. Write ~/.fd-plan/<slug>/checkpoint.json. This is the file /fd-resume reads first. Merge into the existing file — never drop fields written by an earlier command.
{
  "version": "1",
  "project": "<slug>",
  "topic": "<topic>",
  "saved_at": "<ISO>",
  "current_command": "fd-execute",
  "current_stage": "wave-2",
  "phases": { "1": "complete", "2": "in_progress", "3": "pending" },
  "files_written": ["~/.fd-plan/<slug>/<topic>/plan.md"],
  "worktrees": [],
  "blockers": [],
  "status": "in_progress"
}

Field rules:

  • version — always "1". Bump only when the schema changes incompatibly.
  • project — the project slug (the directory name used for ~/.fd-plan/<slug>/).
  • topic — the active topic slug, i.e. the subdirectory holding the artifacts.
  • saved_at — ISO 8601 timestamp of this save.
  • current_command — the /fd-* command in flight, e.g. fd-execute.
  • current_stage — the stage within that command, e.g. complete, wave-2, failed.
  • phases — every known wave number mapped to complete | in_progress | pending.
  • files_written — planning artifacts written this session, as ~-prefixed paths.
  • worktrees — worktrees still live and unmerged, e.g. fd-<slug>-wave-2. Empty when none.
  • blockers — STATE.md blockers, verbatim. Empty when unblocked.
  • statusin_progress while the pipeline is running, done after /fd-done.

Read the full file on GitHub · 70 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 3d ago First seen · 70 lines · 0 tokens per session scan A a29a295c3b49

Subscribe to this mod's changes

fd-checkpoint is a command published in the GitHub repository DVNghiem/FlowDeck (24 stars, last pushed 14d ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 759 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.