Skip to content
Back to skills

Rr Plan

ASecurity

Plan work before any edit. Given a spec (docs/sdlc/specs/<slug>.md), write the programme plan docs/sdlc/plans/<slug>.md — files that change, order of work, risks, proof per requirement, rollback. Given one task, measure its weight with `state.py weight` (six axes, seven lines), take the mode it gives (light, guarded, full), shape the plan by that mode — inline, plan mode, or written — collect every question the plan depends on now, and register the task with `state.py start`, which arms the s...

  • 3 stars
  • 0 votes
  • 0 copies
  • 0 views
  • Added December 1, 2026
ai-agentspythongobashrailsrefactoringgit

Works with

  • claude code
  • terminal

Security analysis

A100/100

Scanned December 5, 2026

npx -y skills add vanssata/claude-agentic-sdlc-module --skill rr-plan --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Rr Plan?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Rr Plan
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/vanssata-rr-plan-claude-agentic-sdlc-module/badge)](https://www.skillsdirectory.com/skills/vanssata-rr-plan-claude-agentic-sdlc-module)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: rr-plan
description: Plan work before any edit. Given a spec (docs/sdlc/specs/<slug>.md), write the programme plan docs/sdlc/plans/<slug>.md — files that change, order of work, risks, proof per requirement, rollback. Given one task, measure its weight with `state.py weight` (six axes, seven lines), take the mode it gives (light, guarded, full), shape the plan by that mode — inline, plan mode, or written — collect every question the plan depends on now, and register the task with `state.py start`, which arms the scope guard. Use on "/rr-plan", "plan this", "plan the implementation", "make the plan from the spec", and whenever /rr-build finds no task in flight.
argument-hint: <task in one sentence> | <path to docs/sdlc/specs/<slug>.md>
---

# /rr-plan $ARGUMENTS

Plan, never edit: this skill reads code and writes a plan, and the first edit
belongs to `/rr-build`. Resolve the install root once:

```bash
for AI_HOME in "${CLAUDE_CONFIG_DIR:-$HOME/.claude}" "${CODEX_HOME:-$HOME/.codex}"; do
  [ -d "$AI_HOME/skills/rr-plan" ] && break
done
STATE="python3 $AI_HOME/skills/ai-task/state.py"
```

Read `docs/sdlc/constitution.md` first and cite the principles a decision rests
on as `C<n>`; if it is absent, say so in one line and go on. `$STATE status`
first: a task already in flight is finished or abandoned before another starts.

## A spec → the programme plan

When `$ARGUMENTS` is a spec (default: the newest `docs/sdlc/specs/*.md`):

1. `docs/sdlc/constitution.md` exists, else `/rr-setup`. The template is
   `docs/sdlc/plans/TEMPLATE.md` when the project overrides it, else
   `$AI_HOME/skills/project-init/templates/plan.md`. If the spec's
   **Flagged concerns** holds unresolved items, list them and have the human
   resolve or explicitly accept each one before planning.
2. Map each requirement to the files that must change
   (`grep -n`; `Explore` when a file is not found in a few calls), order the
   steps so each leaves the repository working, one step about one commit, and
   name the command or test that proves it.
3. Challenge it before writing: *what could this break* (callers, migrations,
   config, other environments) and *which step is the riskiest — can it move
   earlier or be split*. The answers go into **Risks**; mark the risky step.
   For every command, refusal or text a row changes, run
   `grep -rl '<fixed phrase>' tests/ tests/fixtures/` and put every hit into that row's
   files. Name the function and the place the text is printed, not only the file.
4. Copy the template to `docs/sdlc/plans/<slug>.md` — when that plan already exists, revise
   it instead of copying the template over it — and fill **Files that change /
   Order of work / Risks / Proof / Rollback**; Proof maps every requirement R<n>
   to a test or command. Add a **Review focus** list (the likely uncovered inputs, each
   with the test that covers it) and a **Global constraints** block, copied verbatim into
   every implementer brief. One round of corrections; suggest the commit
   `plan: <title>`. Each row of the plan is later one task, planned below —
   unless the whole plan runs as one task through `/rr-build-all` (the project's
   `batch.default` in `weight.json`, or the developer's call): then every row
   becomes one step of that task, so give each row its files and its *Consumes*
   line (the rows it depends on) — that is what `/rr-build-all` reads.

## A task → weight, mode, plan, start

**1. Classify** the request: feature, bugfix, refactoring, hotfix or
investigation — say which and why. `using-riskrails.md` in the shared tree
(`"$AI_HOME/riskrails/ai-path" using-riskrails.md`) and
`workflows.md#<kind>` say what each kind requires. A refactoring and a feature
are never one task.

**2. Name the files** from the request, confirmed with `grep -n`. Recall what
the record holds about them — `$STATE recall --files "<a>,<b>"`: open risks,
residual findings and earlier decisions are evidence for the weight and the
plan. Then weigh:

```bash
$STATE weight --files "<a>,<b>" --goal "<one sentence>" \
  --declare behaviour=<0-2>:"<evidence>" --declare novelty=<0-2>:"<evidence>"
```

Seven lines: six axes, W and the mode. Scope, reversibility, coverage and the
hints are measured; behaviour, domain and novelty are yours to declare, each
with its evidence — a declaration without one is refused. Declare what the
change does to the project's decisions, not how long it feels. An unknown axis
scores 1. A hint raises an axis; a declaration below a hint does not lower it.
The table is `.ai/policies/weight.json` (`weight.md` mirrors it).

**3. The mode is the weight's**, not yours: raising it is free
(`--mode <m> --by "<name>"` on `start`); lowering it is the human's, from their
own terminal, or the command they picked in the dialog. Shape the plan by it:

| Mode | Plan | Who sees it before the first edit |
|---|---|---|
| light | inline: files, the test, the rollback, in one to five lines | nobody — go |
| guarded | plan mode: numbered steps, each with its files and tests | the human accepts the plan |
| full | plan mode, written: steps, files, tests, what stays the same, risks, rollback; `architect` when the design is open, on the model the architect choice gives | the human reads and accepts it |

Guarded and full are planned inside plan mode, in this order:

1. Weight inline first (step 2).
2. The research question, before plan mode, because the ask writes the questions file, which plan
   mode may block: `$STATE choice ask --kind research --stage plan [--topic <slug>]`, and its
   dialog answered.
3. Under Claude Code call `EnterPlanMode`; if that tool is not available, ask the human for
   Shift+Tab or `/plan`.
4. Readers per the research choice: on, the readers of `ai/workers.md` §Research.
5. Draft the plan, then call `ExitPlanMode`. Approving it also switches the
   permission mode to the one the human picked: say so in a few words.
6. A rejected plan is revised, never started. `start` runs only after approval.

Before `architect` starts, ask which model designs:
`$STATE choice ask --kind architect --stage plan [--topic <slug>]`. `CHOICE_ASK`
is answered as in `/rr-spec` §2. On `CHOICE_UNRECORDED` put the question
through the question tool with three options: A the strongest model for this
task, B STRONG for this task, C the strongest model for this task and as the
project default. Name both models from the `ARCHITECT_MODEL on=… off=…` line;
with the two equal (STRONG) there is no question. Record the answer with
`start --choice architect=on|off`. For C also show the human
`python3 "$AI_HOME/skills/rr-setup/setup.py" workers --set architect=on --root <project>`, to run
before `start` or after the task closes (it is refused while a task runs).
`/rr-spec` §4 says how `on` is spawned.

Light stays inline. Under Codex one line asks the human to enter `/plan`;
otherwise the plan is a message, read-only, accepted through the existing
question. Never claim a plan mode you did not observe.

In every mode: a bugfix's first step is its failing test (C2); a change to
legacy behaviour without a test starts with a characterization test; the
rollback is one line, usually `git revert`. A plan over eight steps is advised
against, not refused — fewer, larger steps cost fewer handoffs.

**4. Questions, now.** Everything the plan depends on is asked before `start`,
so `/rr-build` stops only on a real blocker. Ask in the conversation, or on the
record with `$STATE ask --topic <slug> …` and `$STATE answer --topic <slug> …`
(see `/rr-spec`); a plan with an open **(blocking)** question is not accepted.

**5. Start.** One call registers the task, its weight and mode, its files and
steps, and arms the scope guard:

```bash
$STATE start --goal "<one sentence>" --workflow <kind> --files "<a>,<b>" \
  --tests "<t>" [--declare …] [--plan-file /path/steps.json] [--mode <m> --by "<name>"]
```

`--plan-file` is a JSON list `[{"id": "s1", "files": [...], "tests": [...]}]`
for a guarded or full plan with steps; a light task is one scope and needs none.
`--plan-doc <plan file>` stores the approved plan with the task: in full mode
pass the file path that `ExitPlanMode`'s result gives, or `--plan-doc -` when
there is none. When the spec or intent recorded picks, add `--from-topic <slug>`
(every row-task of a programme plan carries it). With no topic and the answer
from the question tool (`CHOICE_UNRECORDED`), pass `--choice workers=<on|off|every>`.
A step may add `"after": ["s0"]`, the steps it waits for. Omitted, it means the step before it
without the batch loop (so a plain list runs one step after another, workers or not), and nothing
at all with `--batch` (`/rr-build-all` runs the rest in parallel); `"after": []` says it needs no
other step. Steps that name one file are ordered by `start` in either case. `--batch --by "<name>"` (or `--no-batch`) sets that
loop for the task; the default is `batch.default` in `weight.json`.
`--files` lists every file of every step — the guard refuses an edit outside
them. `--tests` names the task's own tests; a bugfix names its failing test. At
guarded and full, run `start` only after the human accepted the plan.

Then hand over: `/rr-build` continues from the state, in this session or the
next.

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in ai-agents →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.