/spec-requirements

/spec-requirements#

Generate requirements from the project description in your initialized spec.

Usage#

Claude Code:

/spec-requirements user-authentication

Antigravity:

/spec-requirements user-authentication
# or
@spec-requirements user-authentication

Description#

/spec-requirements reads:

  • .specs/[feature-name]/spec.json
  • .specs/[feature-name]/requirements.md (Project Description input)

Then it writes detailed requirements back into requirements.md using EARS-style acceptance criteria.

EARS Pattern Examples#

  • When [event], the [system] shall [response]
  • If [condition], the [system] shall [response]
  • While [state], the [system] shall [response]
  • Where [feature flag], the [system] shall [response]
  • The [system] shall [response]

Output Format (Example)#

# Requirements Document

## Requirements

### Requirement 1: User Sign-in
**Objective:** As an end user, I want to sign in securely, so that I can access my account.

#### Acceptance Criteria
1. When a user submits valid credentials, the authentication service shall return a valid session token.
2. If a user submits invalid credentials, the authentication service shall return an authentication error.

Notes#

  • Focuses on what to build, not implementation details
  • Requirements should be clear, testable, and verifiable
  • Updates phase metadata in spec.json

Next Steps#

  • /spec-design - Generate technical design from approved requirements