Brainstorm: Generate questions with selectable options (A/B/C) and remove 2-4 limit #18

Open
opened 2026-06-05 05:56:01 +00:00 by aaron · 2 comments
Owner

Problem

The brainstorm step asks "2-4 clarifying questions" with open-ended answers. This means:

  1. Claude asks vague questions without options — user has to write paragraphs
  2. Hard 2-4 limit — sometimes 0 questions are needed (clear issue), sometimes 6+ (complex architecture)
  3. No structure for quick answers — user can't just pick A/B/C

Also: issues lose their label state frequently. Multiple comments (especially re-approvals) seem to confuse the state machine — labels get dropped or overwritten, causing issues to fall back to [open] instead of staying in their correct state.

Fix

1. Brainstorm prompt change

In .forgejo/workflows/claude-task.yml, Brainstorm step, change the system prompt from:

Ask 2-4 clarifying questions that would help you implement it correctly. Be specific and practical.

To:

Review the issue and determine how many questions you need (0 if the issue is already clear, or as many as needed for a complex task). For each question, provide 2-3 concrete options the user can choose from. Format:

**Q1. [Question]?**
- A) [Option A] — [brief tradeoff]
- B) [Option B] — [brief tradeoff]

If the issue is already detailed and clear, say "No questions — issue is clear enough to proceed" instead of forcing questions.

2. Remove the 2-4 hard limit

Let Claude decide based on issue complexity. A well-written issue with clear success criteria needs 0 questions. A vague "make it better" issue might need 5+.

3. Label state stability

Investigate why labels get dropped. Likely causes:

  • Multiple rapid comments (re-approvals) trigger state transitions that conflict
  • update-label.sh removes old label before adding new one — if the step fails after removal, label is lost
  • Race condition: issue_comment events fire faster than the workflow can process them

Fix: Add a check at the start of each step to verify the expected label is still set before proceeding. If not, re-set it and skip (don't re-run the action).

Files to Change

File Change
.forgejo/workflows/claude-task.yml Update brainstorm system prompt, add label guard
scripts/update-label.sh Add idempotency — check before removing

Success Criteria

  • Brainstorm generates questions with A/B/C options
  • Questions count adapts to issue complexity (0-N, not fixed 2-4)
  • Labels no longer get lost on rapid comments/re-approvals
  • Clear issues skip brainstorm and go straight to plan
## Problem The brainstorm step asks "2-4 clarifying questions" with open-ended answers. This means: 1. Claude asks vague questions without options — user has to write paragraphs 2. Hard 2-4 limit — sometimes 0 questions are needed (clear issue), sometimes 6+ (complex architecture) 3. No structure for quick answers — user can't just pick A/B/C Also: **issues lose their label state frequently.** Multiple comments (especially re-approvals) seem to confuse the state machine — labels get dropped or overwritten, causing issues to fall back to `[open]` instead of staying in their correct state. ## Fix ### 1. Brainstorm prompt change In `.forgejo/workflows/claude-task.yml`, Brainstorm step, change the system prompt from: ``` Ask 2-4 clarifying questions that would help you implement it correctly. Be specific and practical. ``` To: ``` Review the issue and determine how many questions you need (0 if the issue is already clear, or as many as needed for a complex task). For each question, provide 2-3 concrete options the user can choose from. Format: **Q1. [Question]?** - A) [Option A] — [brief tradeoff] - B) [Option B] — [brief tradeoff] If the issue is already detailed and clear, say "No questions — issue is clear enough to proceed" instead of forcing questions. ``` ### 2. Remove the 2-4 hard limit Let Claude decide based on issue complexity. A well-written issue with clear success criteria needs 0 questions. A vague "make it better" issue might need 5+. ### 3. Label state stability Investigate why labels get dropped. Likely causes: - Multiple rapid comments (re-approvals) trigger state transitions that conflict - `update-label.sh` removes old label before adding new one — if the step fails after removal, label is lost - Race condition: issue_comment events fire faster than the workflow can process them Fix: Add a check at the start of each step to verify the expected label is still set before proceeding. If not, re-set it and skip (don't re-run the action). ## Files to Change | File | Change | |------|--------| | `.forgejo/workflows/claude-task.yml` | Update brainstorm system prompt, add label guard | | `scripts/update-label.sh` | Add idempotency — check before removing | ## Success Criteria - [ ] Brainstorm generates questions with A/B/C options - [ ] Questions count adapts to issue complexity (0-N, not fixed 2-4) - [ ] Labels no longer get lost on rapid comments/re-approvals - [ ] Clear issues skip brainstorm and go straight to plan
Author
Owner

approved

approved

Claude — Clarifying Questions

The user hasn't answered the questions yet — the tool returned a prompt asking the user to answer. I'll wait for their response. Here's a summary of what I'm asking:

  1. Skip flow — When brainstorm finds no questions needed, should it auto-advance the label to awaiting-approval, or stay put and wait for the user to comment?

  2. Label fix approach — Should update-label.sh use atomic replace (single API call), check-and-add idempotency, or both (atomic replace + workflow-level guard)?

  3. Answer parsing — Is the A/B/C formatting purely cosmetic for readability, or should the workflow parse selected options to feed structured input into the plan step?

These directly affect the implementation scope. Please answer and I'll proceed.


Please answer these questions so I can create an implementation plan.

## Claude — Clarifying Questions The user hasn't answered the questions yet — the tool returned a prompt asking the user to answer. I'll wait for their response. Here's a summary of what I'm asking: 1. **Skip flow** — When brainstorm finds no questions needed, should it auto-advance the label to `awaiting-approval`, or stay put and wait for the user to comment? 2. **Label fix approach** — Should `update-label.sh` use atomic replace (single API call), check-and-add idempotency, or both (atomic replace + workflow-level guard)? 3. **Answer parsing** — Is the A/B/C formatting purely cosmetic for readability, or should the workflow parse selected options to feed structured input into the plan step? These directly affect the implementation scope. Please answer and I'll proceed. --- *Please answer these questions so I can create an implementation plan.*
Sign in to join this conversation.
No milestone
No project
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
aaron/claude-ci-demo#18
No description provided.