fix(phase-runner): add research gate to block planning on unresolved open questions (#1618)
* chore: add v1.31.0 npm known-issue notice to issue template config Adds a top-priority contact link to the issue template chooser so users are redirected to the Discussions announcement before opening a duplicate issue about v1.31.0 not being on npm. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> * fix(phase-runner): add research gate to block planning on unresolved open questions (#1602) Plan-phase could proceed to planning even when RESEARCH.md had unresolved open questions in its ## Open Questions section. This caused agents to plan and execute with fundamental design decisions still undecided. - Add `research-gate.ts` with pure `checkResearchGate()` function that parses RESEARCH.md for unresolved open questions - Integrate gate into PhaseRunner between research (step 2) and plan (step 3) using existing `invokeBlockerCallback` pattern - Add Dimension 11 (Research Resolution) to gsd-plan-checker.md agent - Gate passes when: no Open Questions section, section has (RESOLVED) suffix, all individual questions marked RESOLVED, or section is empty - Gate fires `onBlockerDecision` callback with PhaseStepType.Research and lists the unresolved questions in the error message - Auto-approves (skip) when no callback registered (headless mode) - 18 new tests: 13 unit tests for checkResearchGate, 5 integration tests for PhaseRunner research gate behavior Closes #1602 Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> --------- Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -478,6 +478,45 @@ issue:
|
||||
fix_hint: "Add eslint verification step to each task's <verify> block"
|
||||
```
|
||||
|
||||
## Dimension 11: Research Resolution (#1602)
|
||||
|
||||
**Question:** Are all research questions resolved before planning proceeds?
|
||||
|
||||
**Skip if:** No RESEARCH.md exists for this phase.
|
||||
|
||||
**Process:**
|
||||
1. Read the phase's RESEARCH.md file
|
||||
2. Search for a `## Open Questions` section
|
||||
3. If section heading has `(RESOLVED)` suffix → PASS
|
||||
4. If section exists: check each listed question for inline `RESOLVED` marker
|
||||
5. FAIL if any question lacks a resolution
|
||||
|
||||
**Red flags:**
|
||||
- RESEARCH.md has `## Open Questions` section without `(RESOLVED)` suffix
|
||||
- Individual questions listed without resolution status
|
||||
- Prose-style open questions that haven't been addressed
|
||||
|
||||
**Example — unresolved questions:**
|
||||
```yaml
|
||||
issue:
|
||||
dimension: research_resolution
|
||||
severity: blocker
|
||||
description: "RESEARCH.md has unresolved open questions"
|
||||
file: "01-RESEARCH.md"
|
||||
unresolved_questions:
|
||||
- "Hash prefix — keep or change?"
|
||||
- "Cache TTL — what duration?"
|
||||
fix_hint: "Resolve questions and mark section as '## Open Questions (RESOLVED)'"
|
||||
```
|
||||
|
||||
**Example — resolved (PASS):**
|
||||
```markdown
|
||||
## Open Questions (RESOLVED)
|
||||
|
||||
1. **Hash prefix** — RESOLVED: Use "guest_contract:"
|
||||
2. **Cache TTL** — RESOLVED: 5 minutes with Redis
|
||||
```
|
||||
|
||||
</verification_dimensions>
|
||||
|
||||
<verification_process>
|
||||
|
||||
Reference in New Issue
Block a user