| name | github-issue-refiner |
| description | Refine rough, incomplete, or ambiguous GitHub issues into decision-complete engineering specs with clear scope, acceptance criteria, implementation approach, test plan, and risks. Use when a user asks to improve an issue, clarify requirements, split scope, or produce implementation-ready backlog items. |
Github Issue Refiner
Overview
Turn fuzzy issue text into an implementation-ready specification.
Produce a result that lets an engineer execute with minimal follow-up decisions.
Workflow
- Read the issue text and linked context.
- Inspect codebase paths implied by the issue.
- Resolve discoverable facts from the repo before asking for preferences.
- Apply UX exploration gate criteria from
references/ux-exploration-gate.md.
- If UX gate is triggered, require
ux-mockup-explorer output before implementation.
- Rewrite the issue as a decision-complete spec.
- Write acceptance criteria as
AC-<n> and map each AC to required tests.
- Add explicit assumptions where facts are missing.
- Flag risks, dependencies, and rollout concerns.
Output Contract
Produce these sections in order:
- Problem Statement
- Goals and Non-Goals
- Scope
- Current Behavior
- Proposed Behavior
- Technical Plan
- API/Schema Contract Changes (if any)
- UX Exploration Requirement (required/not required + reason)
- Acceptance Criteria
- Test Plan (required test matrix grouped by type)
- Rollout and Monitoring
- Risks and Mitigations
- Dependencies
- Open Questions (optional; only if unresolved and high impact)
Quality Rules
- Keep requirements testable and falsifiable.
- Prefer concrete paths, interfaces, and data contracts over abstract wording.
- Separate user intent from implementation assumptions.
- Avoid shipping unresolved product decisions to implementation.
- Keep output concise and executable.
- If UX exploration is required, block implementation until selected option is recorded.
- Acceptance criteria must be uniquely labeled (
AC-1, AC-2, ...).
- Test plan must include a required test matrix grouped by
Unit, Component, Integration, E2E, and Non-functional.
- Each test matrix row must include: test ID, mapped AC, scenario, expected assertion, suggested path/module, and whether the test is new or existing.
- Every AC must map to at least one automated test, or explicitly state why it is manual-only.
- Include at least one negative-path test for each behavior-changing AC unless not applicable, with reason.
- Use exact section headings and numbering from
references/issue-refinement-template.md so output can be validated mechanically.
- For non-functional or exploratory ACs where direct 1:1 automation or negative-path tests are not meaningful, include a measurable verification probe/check and explicit rationale.
- Required test matrix rows are automated tests only; manual checks belong in the
Manual-only ACs subsection with justification.
Scope Splitting Rules
If issue scope is too large:
- Produce parent issue summary.
- Propose child issues by vertical slice.
- Give each child issue independent acceptance criteria.
- Identify sequencing constraints and parallelizable tracks.
Reference Files
- Issue template and checklist:
references/issue-refinement-template.md
- UX gate criteria:
references/ux-exploration-gate.md
Use that template when preparing final issue output.