From 27ae4fbd9ce3d22739a5ab56c2add45c54b66a03 Mon Sep 17 00:00:00 2001 From: Thao Le Date: Sun, 17 May 2026 09:33:25 -0400 Subject: [PATCH] fix(plan-ceo-review): persist + stop on /absolute-brainstorm branch Codex cross-review on cc86fe8 surfaced two blocking findings on the mid-session-detection /absolute-brainstorm branch: 1) state_mutation -- option B told the agent to "note progress and pause" with no persisted artifact, so the next user turn could not resume. 2) if_completeness -- no explicit stop condition; agent could fall through into the rest of the review in the same turn. Fix: option B now writes a `*-ceo-handoff-brainstorm.md` artifact (matching the existing `*-ceo-handoff-*.md` glob already read at the top of the skill, so the standard handoff-note check picks it up on return), and the branch ends with an explicit STOP-and-wait instruction. The "Note current progress / after completion" lines are scoped to option A so option B does not fall through into them. Finding 1 (import_resolution -- /absolute-brainstorm not present in this repo) is left as the documented PR caveat: this PR surfaces the offer in /plan-ceo-review; the consuming installation supplies the skill. Co-Authored-By: Claude Opus 4.7 (1M context) --- plan-ceo-review/SKILL.md | 29 +++++++++++++++++++++++------ plan-ceo-review/SKILL.md.tmpl | 29 +++++++++++++++++++++++------ 2 files changed, 46 insertions(+), 12 deletions(-) diff --git a/plan-ceo-review/SKILL.md b/plan-ceo-review/SKILL.md index 5bff777be..f2c075070 100644 --- a/plan-ceo-review/SKILL.md +++ b/plan-ceo-review/SKILL.md @@ -1029,13 +1029,30 @@ Follow its instructions from top to bottom, **skipping these sections** (already Execute every other section at full depth. When the loaded skill's instructions are complete, continue with the next step below. -If they choose B: tell the user to run `/absolute-brainstorm` directly in their -next message — it's a sibling skill, not a sub-invocation. Note current Step 0A -progress, pause this review, and pick up once they return with the brainstorm's -output. - Note current Step 0A progress so you don't re-ask questions already answered. -After completion, re-run the design doc check and resume the review. +After option A completes, re-run the design doc check and resume the review. + +If they choose B: + +Write a handoff note to `~/.gstack/projects/$SLUG/$(date -u +%Y%m%d-%H%M%S)-$BRANCH-ceo-handoff-brainstorm.md` +with: +- Current Step 0A progress (the questions already answered) +- The specific proposal the user wanted vetted +- A note that the review paused for `/absolute-brainstorm` + +Then say: "Saved a handoff note. Run `/absolute-brainstorm` in your next +message. When you come back to `/plan-ceo-review`, I'll read the handoff +plus the brainstorm output and pick up Step 0A from where we left off." + +**STOP here and wait for the user's next message.** Do not continue with +the rest of `/plan-ceo-review` in this turn — `/absolute-brainstorm` is +a sibling skill, not a sub-invocation, so control must return to the user +before any further work in this review happens. + +When the user returns to `/plan-ceo-review`, the standard handoff-note +check at the top of this skill will read `*-ceo-handoff-brainstorm.md` the +same way it reads other handoff notes, and the review resumes from the +recorded Step 0A point with the brainstorm's output as additional input. When reading TODOS.md, specifically: * Note any TODOs this plan touches, blocks, or unlocks diff --git a/plan-ceo-review/SKILL.md.tmpl b/plan-ceo-review/SKILL.md.tmpl index 22b65f9ae..03f848d45 100644 --- a/plan-ceo-review/SKILL.md.tmpl +++ b/plan-ceo-review/SKILL.md.tmpl @@ -181,13 +181,30 @@ If they choose A: {{INVOKE_SKILL:office-hours}} -If they choose B: tell the user to run `/absolute-brainstorm` directly in their -next message — it's a sibling skill, not a sub-invocation. Note current Step 0A -progress, pause this review, and pick up once they return with the brainstorm's -output. - Note current Step 0A progress so you don't re-ask questions already answered. -After completion, re-run the design doc check and resume the review. +After option A completes, re-run the design doc check and resume the review. + +If they choose B: + +Write a handoff note to `~/.gstack/projects/$SLUG/$(date -u +%Y%m%d-%H%M%S)-$BRANCH-ceo-handoff-brainstorm.md` +with: +- Current Step 0A progress (the questions already answered) +- The specific proposal the user wanted vetted +- A note that the review paused for `/absolute-brainstorm` + +Then say: "Saved a handoff note. Run `/absolute-brainstorm` in your next +message. When you come back to `/plan-ceo-review`, I'll read the handoff +plus the brainstorm output and pick up Step 0A from where we left off." + +**STOP here and wait for the user's next message.** Do not continue with +the rest of `/plan-ceo-review` in this turn — `/absolute-brainstorm` is +a sibling skill, not a sub-invocation, so control must return to the user +before any further work in this review happens. + +When the user returns to `/plan-ceo-review`, the standard handoff-note +check at the top of this skill will read `*-ceo-handoff-brainstorm.md` the +same way it reads other handoff notes, and the review resumes from the +recorded Step 0A point with the brainstorm's output as additional input. When reading TODOS.md, specifically: * Note any TODOs this plan touches, blocks, or unlocks