From ebba70ad2be3163a9dc96f5b2a2f2fac6d1b255d Mon Sep 17 00:00:00 2001 From: Andrey Antukh Date: Wed, 16 Sep 2026 18:00:55 +0000 Subject: [PATCH] :books: Normalize plan followup and sub-plan naming Define derived plan naming for .agents/plans/. Parent basename stays intact and derivatives append --review-NN for review followups and --task-NN for roadmap sub-plans, with no new date so ls groups them. Document the rule in the planner skill, the in-place vs new-file policy in make-a-plan, and examples in the agents README. AI-assisted-by: muse-spark-1.3-contributor --- .agents/README.md | 19 ++++++++++++++ .agents/skills/make-a-plan/SKILL.md | 16 +++++++++--- .agents/skills/planner/SKILL.md | 39 +++++++++++++++++++++++++++++ 3 files changed, 70 insertions(+), 4 deletions(-) diff --git a/.agents/README.md b/.agents/README.md index e4abf7ae64..25c59b5bc4 100644 --- a/.agents/README.md +++ b/.agents/README.md @@ -344,6 +344,25 @@ delegating when it helps), review it when the task is complex (`/review-plan`), implement it (`/implement-plan`), and mark progress on the roadmap as you land each piece. +### Plan file naming (base + derivatives) + +Base plans live in `.agents/plans/` as `YYYY-MM-DD-.md`. +Derived plans reuse the parent basename verbatim and append one +suffix per level with `--`, with no new date — the parent prefix +keeps everything adjacent in `ls`: + +- Review followup on implemented work: + `2026-09-14-paste-before-init-crash.md` → + `2026-09-14-paste-before-init-crash--review-01.md` +- Roadmap sub-plan (task number from the roadmap): + `2026-09-20-upload-pipeline-roadmap.md` → + `2026-09-20-upload-pipeline-roadmap--task-01-chunk-upload.md` +- Chained: `...--task-02-gc--review-01.md` + +While a plan is still unimplemented, `/make-a-plan` revises it in +place. Once implemented and reviewed, it writes a new followup file. +Full rules live in the `planner` skill. + ## 7. Connecting `gh` CLI with a token The `create-issue` and `create-pr` flows need an authenticated `gh` diff --git a/.agents/skills/make-a-plan/SKILL.md b/.agents/skills/make-a-plan/SKILL.md index cd9129f85b..6b5ea09005 100644 --- a/.agents/skills/make-a-plan/SKILL.md +++ b/.agents/skills/make-a-plan/SKILL.md @@ -16,8 +16,13 @@ stop — this skill needs the build agent to save the plan. - The user asks to plan, design, or break down a task, in any phrasing: "make a plan", "how would we build X", "design an approach for Y" — or runs `/make-a-plan`. -- The user asks to rework or extend an existing plan (for example, after - review findings) — revise the saved plan file in place. +- The user asks to rework or extend an existing plan. While the plan is + still unimplemented (pre-`implement-plan` iteration, e.g. after + `/review-plan` findings or user feedback), revise the saved plan file + in place. Once the plan has been implemented and reviewed (post + `/review-code` findings on committed work), write a new derived plan + file instead — never rewrite the executed plan. The `planner` skill + defines the derived naming (`--review-NN`, `--task-NN`). Do not use it to execute a plan — that is the `implement-plan` flow. @@ -34,8 +39,11 @@ Do not use it to execute a plan — that is the `implement-plan` flow. 3. Once all decisions are answered and the plan is final, save it verbatim to the announced path under `.agents/plans/` (create the directory if it does not exist). This step is the flow's explicit authorization to write the plan - file — the only write allowed here. If I later ask for changes, update the - saved file directly. + file — the only write allowed here. A fresh plan uses + `.agents/plans/YYYY-MM-DD-.md`; a derived plan uses the parent + basename plus the `planner` suffix (`--review-NN`, `--task-NN`) in its + own new file. If I later ask for changes to a still-unimplemented plan, + update the saved file directly. 4. Present me with a clear, self-contained summary of the plan's most relevant points only after all required decisions have been answered. Write it for someone who knows only the project's high-level goal and may not know the plan's low-level context. diff --git a/.agents/skills/planner/SKILL.md b/.agents/skills/planner/SKILL.md index 4595dbc242..aa77b6397f 100644 --- a/.agents/skills/planner/SKILL.md +++ b/.agents/skills/planner/SKILL.md @@ -153,6 +153,45 @@ Announce the save path `.agents/plans/YYYY-MM-DD-.md` (today's date, lowercase hyphen-separated slug, e.g. `2026-09-10-add-batch-get-profiles`; an explicit user path wins). +### Derived plans + +Never invent a fresh slug when the plan derives from an existing one. +The derived name is `` plus one suffix per level, +joined with `--` (double hyphen; single hyphens already separate +slug words, so `--` marks where the derivation starts). The parent +name is never edited, and no new date is added — the parent prefix +already carries its date, which keeps parent and derivatives adjacent +in `ls`. Record the real creation date inside the plan (`Created:`). + +Valid names match: + +``` +^\d{4}-\d{2}-\d{2}-[a-z0-9-]+(--(review-\d{2}|task-\d{2})(-[a-z0-9-]+)?)*\.md$ +``` + +- `review-NN` — a new plan addressing findings of a `review-code` or + `review-plan` on already-implemented work. `NN` counts reviews of + that parent from `01`. Example: parent + `2026-09-14-paste-before-init-crash.md` → + `2026-09-14-paste-before-init-crash--review-01.md`, + then `--review-02.md`. +- `task-NN-` — sub-plan for task `NN` of a high-level + roadmap plan. `NN` is the roadmap task number. Example: parent + `2026-09-20-upload-pipeline-roadmap.md` → + `2026-09-20-upload-pipeline-roadmap--task-01-chunk-upload.md`. + Levels chain: `...--task-02-gc--review-01.md`. + +Never use `v2`, `final`, `new`, or `fix2` as suffixes. Keep the +optional short slug to 3-4 lowercase hyphen-separated words. + +Every derived plan opens its `Context` with: + +```markdown +Parent: `.md` +Source: review-code over `` (branch ``) | task `NN` of roadmap `.md` +Created: YYYY-MM-DD +``` + End the response by suggesting the next steps: `/review-plan` to get a second opinion on the plan and `/implement-plan` to execute it.