checkpoint

checkpoint is a command for coding agents from sourikduttanyu/astral. It costs 20 tokens per session (334 once invoked), scanned A, original, MIT.

A command that records completed work in a durable Markdown file and prepares an instruction for compacting a conversation. Compaction shortens the active conversation context.

In plain words
What is it for?
It scans a session, lets you choose completed work to remove from active context, saves a resume-ready summary, and generates a ready-to-run /compact line.
Why use it?
It reduces context used by finished work while preserving the decisions, files, commands, and results needed later.

Command

Part of the astral plugin — 5 commands, 3 hooks, 1 MCP server shipped together

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/sourikduttanyu/astral/checkpoint
Clone the repo
git clone --depth 1 https://github.com/sourikduttanyu/astral

Or install astral, the plugin that ships this one along with the rest of its 5 commands, 3 hooks, 1 MCP server.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for checkpoint

README.md
[![agentmods](https://agentmods.dev/badge/commands/sourikduttanyu/astral/checkpoint.svg)](https://agentmods.dev/commands/sourikduttanyu/astral/checkpoint)
Your own site
<a href="https://agentmods.dev/commands/sourikduttanyu/astral/checkpoint"><img src="https://agentmods.dev/badge/commands/sourikduttanyu/astral/checkpoint.svg" alt="Measured on agentmods" height="20"></a>
Per session 20 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 334 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.00020 $0.00334
Opus 5 $0.00010 $0.00167
Sonnet 5 $0.00004 $0.00067
Haiku 4.5 $0.00002 $0.00033

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

Security

Grade A, and why

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 4d 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.

commands/checkpoint.md · 28 lines

What it actually says

Astral checkpoint (hybrid flow). Goal: shed already-finished work from context without losing it — durable record + keep the live thread.

Note: Claude Code has no native partial/verbatim compaction. The only real selectivity comes from /compact's instruction text. This command writes a durable summary AND generates that steered /compact line.

  1. Scan the session. List each COMPLETED, self-contained work-unit (done + verified, not needed for active work) as short bullets.

  2. Use AskUserQuestion (multiSelect) so the user picks which units to shed.

  3. For the chosen units, write a concise resume-ready summary (key decisions, file paths, commands, outcomes) to .astral/checkpoint-<UTC-timestamp>.md. Append a new section if the file already exists.

  4. Identify what must STAY: the active task and any still-relevant open files.

  5. Output a ready-to-run steered compaction line for the user to paste, e.g.:

    /compact Keep: <active task> and open files <...>. Drop: completed work — <units>, now saved in .astral/checkpoint-<ts>.md.

  6. Tell the user: running that /compact sheds the done work but keeps the thread; the .md is the durable backup. Do NOT auto-run it — Claude cannot invoke slash commands; the user runs it.

Keep it tight.

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. 4d ago First seen · 28 lines · 20 tokens per session scan A 8f5ec97bf70f

Subscribe to this mod's changes

checkpoint is a command published in the GitHub repository sourikduttanyu/astral (1 stars, last pushed 2mo ago), licensed MIT. It adds 20 tokens to every session and 334 once invoked, about $0.0001 per session on Opus 5. 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-31.