resume

resume is a command for coding agents from LucasDuys/forge. It costs 8 tokens per session (1,591 once invoked), scanned A, original, MIT.

A command for continuing an unfinished Forge development run after a context reset, closed session, or manual pause.

In plain words
What is it for?
Use it to recover locks, inspect checkpoints and Git history, find unfinished tasks or abandoned worktrees, and resume a Forge project.
Why use it?
It checks the saved Forge state and recovers interrupted work so execution can continue from its recorded progress.

Command

Installs and runs on its own, but its text points at files inside its plugin — anything it tells you to read at a ${CLAUDE_PLUGIN_ROOT} path is only there once the plugin is installed. Installing the plugin gets both.

Part of the forge plugin — 10 skills, 13 commands, 9 agents, 3 hooks 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/lucasduys/forge/resume
Clone the repo
git clone --depth 1 https://github.com/LucasDuys/forge

Or install forge, the plugin that ships this one along with the rest of its 10 skills, 13 commands, 9 agents, 3 hooks.

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 resume

README.md
[![agentmods](https://agentmods.dev/badge/commands/lucasduys/forge/resume.svg)](https://agentmods.dev/commands/lucasduys/forge/resume)
Your own site
<a href="https://agentmods.dev/commands/lucasduys/forge/resume"><img src="https://agentmods.dev/badge/commands/lucasduys/forge/resume.svg" alt="Measured on agentmods" height="20"></a>
Per session 8 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,591 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.00008 $0.01591
Opus 5 $0.00004 $0.00796
Sonnet 5 $0.00002 $0.00318
Haiku 4.5 $0.00001 $0.00159

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

Security

Grade A, and why

resume 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/resume.md · 123 lines

How it starts

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

Forge Resume

Continue an in-progress Forge execution from where it left off after a context reset, session close, or manual pause.

Step 1: Verify Forge project exists

Check if .forge/ exists. If it does not, stop and tell the user:

No Forge project found. Run /forge brainstorm to get started.

Step 1.5: Forensic recovery (T020, R007/R008)

Before loading any state, run forensic recovery. This handles crashed sessions, stale locks, budget exhaustion, and orphan worktrees. The forensic recovery scan is always safe to run -- on a clean state it is a no-op.

node "${CLAUDE_PLUGIN_ROOT}/scripts/forge-tools.cjs" forensic-recover --forge-dir .forge

The command:

  1. Sets phase to recovering while it runs
  2. Inspects .forge/.forge-loop.lock -- takes over stale locks (heartbeat older than 5 minutes)
  3. Reads checkpoints from .forge/progress/ to find in-flight tasks
  4. Cross-references git log + task-status.json to identify committed tasks
  5. Lists worktrees and flags any orphans (worktrees for tasks not in any frontier or already committed)
  6. If phase: budget_exhausted, reads .forge/resume.md and surfaces the reason
  7. Writes a caveman-form summary to .forge/state.md notes
  8. Sets final phase to idle (clean) or needs_human (warnings present)
  9. Exits 0 on clean recovery, exit 2 if needs_human

Show the recovery report to the user. Read it carefully:

  • If the report lists orphan worktrees, do NOT delete them automatically. Tell the user which paths are orphan and that they need to run git worktree remove <path> manually after reviewing the contents.
  • If the report says Needs human: YES, stop and ask the user how to proceed. Common cases: budget exhausted (raise the cap in .forge/config.json), live lock from another session (verify no other forge instance is running).
  • If Resume point is present, that is the task you will continue from in Step 6.
  • In full autonomy mode, auto-continue if Needs human: no and there are no warnings. Otherwise pause and prompt.

Read the full file on GitHub · 123 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. 4d ago First seen · 123 lines · 8 tokens per session scan A c1590d1536cb

Subscribe to this mod's changes

resume is a command published in the GitHub repository LucasDuys/forge (55 stars, last pushed 1mo ago), licensed MIT. It adds 8 tokens to every session and 1,591 once invoked, about $0.0000 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-30.