Skip to content

Improve spec review loop in brainstorming skill#691

Open
Dark1X wants to merge 1 commit intoobra:mainfrom
Dark1X:improve-spec-review-loop
Open

Improve spec review loop in brainstorming skill#691
Dark1X wants to merge 1 commit intoobra:mainfrom
Dark1X:improve-spec-review-loop

Conversation

@Dark1X
Copy link

@Dark1X Dark1X commented Mar 11, 2026

Pull Request: Improve spec review loop in brainstorming skill

Problem Description

The current brainstorming skill has a workflow gap in the spec review phase:

  • After users request changes, the AI modifies the spec document
  • However, after making changes, the AI does not ask the user to review again
  • It proceeds directly to the next step (invoking the writing-plans skill)
  • This prevents users from having the opportunity to review the modified content

Solution

This PR improves the spec review workflow by establishing an explicit "modify-review" loop:

  1. User requests changes
  2. AI applies the changes
  3. AI asks the user to review again (new behavior)
  4. Repeat until the user explicitly approves

Key Changes

1. Updated Checklist Step 8

  • Before: ask user to review the spec file before proceeding
  • After: ask user to review the spec file; if changes requested, apply them and ask again; repeat until user explicitly approves

2. Updated Process Flow Diagram

  • Added "Apply user changes" and "Ask user to review again" nodes
  • Changed "User reviews spec?" to "User satisfied?"
  • Established a clear loop path

3. Enhanced User Review Gate Documentation

  • Added detailed step-by-step instructions
  • Clarified the loop mechanism
  • Added critical reminder: must wait for explicit user confirmation before proceeding

Testing & Validation

Successfully tested through 5 rounds of modify-review cycles:

  • ✅ Each modification correctly triggers a re-prompt for review
  • ✅ Supports multiple consecutive modification rounds
  • ✅ Correctly proceeds to next step after user confirmation
  • ✅ Never skips the review prompt to jump to implementation

Impact Scope

  • Only affects skills/brainstorming/SKILL.md
  • Backward compatible, does not break existing functionality
  • Improves user experience by enhancing spec review control

Modified Files

  • skills/brainstorming/SKILL.md - Primary modification

Motivation

This change ensures users have full control over the spec review process. Previously, after requesting changes, users had no opportunity to verify the modifications before the AI moved to implementation planning. This improvement enables iterative refinement of specs with proper user oversight at each step.

Related Issues

N/A - This is a proactive improvement based on user workflow analysis.

- Add explicit review loop after spec modifications
- Ensure AI asks for user confirmation after each change
- Update process flow diagram to reflect iterative review cycle
- Update checklist step 8 to clarify the loop requirement

This prevents the AI from proceeding to implementation without
user approval after making spec changes. Users now have full
control over the spec review process with multiple revision rounds.
@coderabbitai
Copy link

coderabbitai bot commented Mar 11, 2026

📝 Walkthrough

Walkthrough

The brainstorming skill flow is updated to implement a multi-step user review loop that requires explicit satisfaction before invoking writing-plans. The single review gate is replaced with iterative review, change application, and confirmation steps, with a critical note restricting subsequent skill invocation to only writing-plans.

Changes

Cohort / File(s) Summary
Skill Flow and Gates
skills/brainstorming/SKILL.md
Replaced single user review gate with iterative loop including "Apply user changes", "Ask user to review again", and "User satisfied?" confirmation steps. Added critical requirement preventing writing-plans invocation until explicit user satisfaction. Updated process diagram and restricted next-skill invocation to writing-plans only.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Possibly related issues

Possibly related PRs

Poem

🐰 The brainstorm now loops, round and round,
With user checks at every bound,
No hasty leaps to writing's call,
We gather nods to trust them all,
Till "satisfied?" gets checkmark found! ✨

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Title check ✅ Passed The title directly and concisely summarizes the main change: improving the spec review loop in the brainstorming skill, which aligns with the file modifications and PR objectives.
Description check ✅ Passed The description is comprehensive and directly related to the changeset, clearly explaining the problem, solution, key changes, testing, and impact of the spec review loop improvements.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🧹 Nitpick comments (1)
skills/brainstorming/SKILL.md (1)

135-142: Minor clarity issue: "Return to this User Review Gate" phrasing.

Line 140 states "Return to this User Review Gate" but according to the flow diagram (lines 67-68), after applying user changes, the flow goes through the "Spec review loop" before returning to "Ask user to review again". The text could be clearer about this intermediate step.

Suggested clarification
   2. Re-run the spec review loop if needed
-  3. **Return to this User Review Gate** - ask again: "I've updated the spec based on your feedback. Please review the changes and let me know if you need any further modifications, or if we can proceed to the implementation plan."
+  3. **Once the spec review passes, return to this User Review Gate** - ask again: "I've updated the spec based on your feedback. Please review the changes and let me know if you need any further modifications, or if we can proceed to the implementation plan."
   4. Repeat this loop until the user explicitly approves
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@skills/brainstorming/SKILL.md` around lines 135 - 142, Replace the ambiguous
phrase "Return to this User Review Gate" with a clearer instruction that
reflects the actual flow: after making requested changes to the spec, re-run the
"Spec review loop" (as referenced earlier in the doc) and then prompt the user
again with the review gate; update the step text in SKILL.md (the block that
currently says "Return to this User Review Gate") to read something like "Re-run
the Spec review loop, then ask the user to review the updated spec" so it
explicitly names the intermediate "Spec review loop" step and the subsequent
prompt.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@skills/brainstorming/SKILL.md`:
- Around line 65-69: The diagram and text disagree about whether the spec
re-review is mandatory; make them consistent by changing the flow to be
conditional: modify the diagram edge from "Apply user changes" -> "Spec review
loop" (currently unconditional) to include a decision node or label like "[if
user requests/reviewer fails]" and update the prose phrase "Re-run the spec
review loop if needed" (the sentence containing "Re-run the spec review loop")
to spell out the trigger criteria (e.g., automated-review failure,
user-requested changes, or user opt-in) and/or note that the system will prompt
the user to re-run the automated review when those criteria are met. Ensure
references to "Apply user changes", "Spec review loop", and the sentence "Re-run
the spec review loop" are updated together so diagram and text match.

---

Nitpick comments:
In `@skills/brainstorming/SKILL.md`:
- Around line 135-142: Replace the ambiguous phrase "Return to this User Review
Gate" with a clearer instruction that reflects the actual flow: after making
requested changes to the spec, re-run the "Spec review loop" (as referenced
earlier in the doc) and then prompt the user again with the review gate; update
the step text in SKILL.md (the block that currently says "Return to this User
Review Gate") to read something like "Re-run the Spec review loop, then ask the
user to review the updated spec" so it explicitly names the intermediate "Spec
review loop" step and the subsequent prompt.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro

Run ID: e25e6881-3ad2-4dde-99e6-f72dceaf01ce

📥 Commits

Reviewing files that changed from the base of the PR and between 5ef73d2 and 531a35e.

📒 Files selected for processing (1)
  • skills/brainstorming/SKILL.md

Comment on lines +65 to +69
"Spec review passed?" -> "Ask user to review again" [label="approved"];
"Ask user to review again" -> "User satisfied?";
"User satisfied?" -> "Apply user changes" [label="changes requested"];
"Apply user changes" -> "Spec review loop" [label="re-run review"];
"User satisfied?" -> "Invoke writing-plans skill" [label="approved"];
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor

Inconsistency: Diagram mandates spec re-review, but text suggests it's optional.

The flow diagram (line 68) shows a mandatory path from "Apply user changes" back to "Spec review loop", but line 139 states "Re-run the spec review loop if needed", suggesting it's optional.

Potential issue: If a user requests changes that the automated spec reviewer doesn't approve (e.g., stylistic preferences, domain-specific terminology), the AI could get caught in a conflict trying to satisfy both the user's intent and the automated reviewer's rules.

Consider: Should the spec review re-run be:

  1. Always mandatory (as the diagram shows) - update line 139 to remove "if needed"
  2. Conditionally optional (as the text suggests) - update the diagram to show an optional path or decision node
  3. User-controlled - ask the user if they want to re-run the automated review after their changes
Suggested clarification approaches

Option 1: Make it clearly mandatory

-  2. Re-run the spec review loop if needed
+  2. Re-run the spec review loop to validate the changes

Option 2: Make it clearly conditional with criteria

-  2. Re-run the spec review loop if needed
+  2. Re-run the spec review loop if the changes affect spec content (not just typos/formatting)
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@skills/brainstorming/SKILL.md` around lines 65 - 69, The diagram and text
disagree about whether the spec re-review is mandatory; make them consistent by
changing the flow to be conditional: modify the diagram edge from "Apply user
changes" -> "Spec review loop" (currently unconditional) to include a decision
node or label like "[if user requests/reviewer fails]" and update the prose
phrase "Re-run the spec review loop if needed" (the sentence containing "Re-run
the spec review loop") to spell out the trigger criteria (e.g., automated-review
failure, user-requested changes, or user opt-in) and/or note that the system
will prompt the user to re-run the automated review when those criteria are met.
Ensure references to "Apply user changes", "Spec review loop", and the sentence
"Re-run the spec review loop" are updated together so diagram and text match.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant