refining-requirements/SKILL.md
Transforms vague feature ideas into precise, codebase-grounded technical requirements. Use when requirements are ambiguous/incomplete, the user struggles to describe behavior, terminology is unclear, or multiple concepts are mixed. Output is a requirements spec—NOT an implementation plan.
npx skillsauth add skyosev/agent-skills refining-requirementsInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Turn unclear or vague requests into precise, codebase-grounded, testable thin-slice technical requirements.
The output is a requirements document, not an implementation plan. However, requirements must be concrete enough that an implementor can derive an implementation plan from them without guessing. Weak assumptions and underestimated risks are unacceptable—call them out or resolve them.
| Requirements (this skill) | Implementation plan (separate step) | | ----------------------------------------------------------- | ---------------------------------------------- | | What the system must do and why | How to build it (file changes, task order) | | References to existing types, interfaces, method signatures | Actual code diffs and new file scaffolds | | Pseudo-code or data-flow sketches clarifying behavior | Step-by-step implementation instructions | | Constraints, invariants, edge cases | Detailed test plans with exact assertions | | Acceptance criteria (black-box, testable) | CI commands, deployment steps |
Extract:
Assess if the request mixes multiple high-level concepts. If yes, split into units:
Outcome of this step MUST be:
Rules:
Use AskUserQuestion tool to ask the smallest set of questions that materially affects:
Do NOT ask questions that only affect deferred scope; put those in the "Next (Deferred)" section as "Open questions".
Produce one artifact:
docs/dev-specs/{Y-m-d-requirements-name}.md — containing the technical requirements and optional deferred scope.
This document serves as the input for a future implementation plan.# [Feature Name]
## Requirements
### Problem Statement
- ...
### Glossary
- ...
### Expected Behavior
Describe behavior as observable outcomes.
- Primary flow:
- Alternate flows:
- Error/invalid states:
### Scope
...
#### Includes
- ...
### Integration Points & Constraints
Relevant types and interfaces, affected modules and their boundaries, architectural constraints, a brief data-flow sketch or
pseudo-code if it clarifies behavior, and any risks or unknowns.
- ...
### Acceptance Criteria
Write as testable conditions (black-box where possible).
- AC1: ...
- AC2: ...
#### Excludes (deferred) `optional`
- ...
### Open Questions
- Q1: ...
- Q2: ...
IMPORTANT ensure that the artifact you produced is present in the correct directory. No need to display it in the output.
tools
Audit TypeScript type definitions for design debt — duplicated shapes, missing derivations, over-engineered generics, under-constrained type parameters, reinvented utility types, and disorganized type architecture. Type structure and maintainability, not type enforcement. Use when: reviewing type definitions for maintainability, reducing type duplication, simplifying over-engineered type-level logic, or reorganizing type architecture after growth.
development
Audit TypeScript test code for quality gaps — missing coverage on critical paths, brittle tests coupled to implementation, over-mocking, assertion-free tests, missing edge cases, and duplicated test setup. Focuses on test effectiveness, not production code structure. Use when: reviewing TypeScript test suites for reliability, reducing false-positive test failures, improving coverage of critical business logic, or cleaning up test debt.
tools
Audit TypeScript class and interface design for SOLID violations — god classes, rigid extension points, broken substitutability, fat interfaces, and concrete dependency chains. Focuses on responsibility assignment and abstraction fitness. Use when: reviewing class hierarchies, preparing for extension with new variants, reducing coupling between services, or improving testability of class-heavy code.
development
Audit TypeScript code for classic code smells — feature envy, data clumps, shotgun surgery, primitive obsession, temporal coupling, comments as deodorant, temporary fields, callback hell, enum abuse, and class abuse. Use when: reviewing TypeScript code for structural design problems, preparing for a refactor, auditing code after rapid feature development, or hunting for misplaced responsibilities.