cancel

cancel is a command for coding agents from tzachbon/smart-ralph. It costs 7 tokens per session (375 once invoked), scanned A, original, MIT.

A command that stops the active feature execution loop and removes its temporary execution state. It keeps the progress file so work can be resumed later.

In plain words
What is it for?
Use it to cancel an active implementation run, optionally naming the feature, and leave its progress available for a later restart.
Why use it?
It provides a controlled way to stop implementation without losing the recorded history or progress. It also reports the phase, task progress, and iteration count before cleanup.

Command

Part of the ralph-speckit plugin — 4 skills, 14 commands, 6 agents, 1 hook 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/tzachbon/smart-ralph/cancel
Clone the repo
git clone --depth 1 https://github.com/tzachbon/smart-ralph

Or install ralph-speckit, the plugin that ships this one along with the rest of its 4 skills, 14 commands, 6 agents, 1 hook.

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 cancel

README.md
[![agentmods](https://agentmods.dev/badge/commands/tzachbon/smart-ralph/cancel.svg)](https://agentmods.dev/commands/tzachbon/smart-ralph/cancel)
Your own site
<a href="https://agentmods.dev/commands/tzachbon/smart-ralph/cancel"><img src="https://agentmods.dev/badge/commands/tzachbon/smart-ralph/cancel.svg" alt="Measured on agentmods" height="20"></a>
Per session 7 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 375 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.00007 $0.00375
Opus 5 $0.00003 $0.00187
Sonnet 5 $0.00001 $0.00075
Haiku 4.5 $0.00001 $0.00038

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

Security

Grade A, and why

cancel 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 5d 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.

plugins/ralph-speckit/commands/cancel.md · 67 lines

What it actually says

Cancel Execution

You are canceling the active execution loop and cleaning up state files.

Determine Target Feature

  1. If $ARGUMENTS contains a feature name, use that
  2. Otherwise, read .specify/.current-feature to get active feature
  3. If no active feature, inform user there's nothing to cancel

Check State

  1. Check if .specify/specs/$feature/.speckit-state.json exists
  2. If not, inform user no active loop for this feature

Read Current State

If state file exists, read and display:

  • Current phase
  • Task progress (taskIndex/totalTasks)
  • Iteration count

Cleanup

  1. Delete state file:

    rm .specify/specs/$feature/.speckit-state.json
    
  2. Optionally clear current-feature pointer (ask user or skip if they specified feature directly)

  3. Keep .progress.md as it contains valuable context

Output

Canceled execution for feature: $feature

State before cancellation:
- Phase: <phase>
- Progress: <taskIndex>/<totalTasks> tasks
- Iterations: <globalIteration>

Cleanup:
- [x] Removed .speckit-state.json
- [ ] Kept .progress.md (contains history)

To resume later:
- Run /speckit:implement to restart execution
- Progress file retains completed tasks and learnings

If No Active Loop

No active execution loop found.

To start a new feature: /speckit:start <name>
To check status: /speckit:status
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. 5d ago First seen · 67 lines · 7 tokens per session scan A 56cc02530713

Subscribe to this mod's changes

cancel is a command published in the GitHub repository tzachbon/smart-ralph (532 stars, last pushed 2d ago), licensed MIT. It adds 7 tokens to every session and 375 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.