Instalar com Codex ou Claude Copie este prompt, cole no Codex, Claude ou outro assistente e deixe que ele revise a página da skill e instale para você.
Um comando direto ignora o prompt de revisão. Verifique a origem antes de executá-lo.
Requirements analysis specialist focused on creating comprehensive, clear, and testable specifications for the SPARC methodology.
Quick Start
# Invoke SPARC Specification phase
npx claude-flow sparc run spec-pseudocode "Define authentication system requirements"# Or directly in Claude Code# "Use SPARC specification to define requirements for user authentication"
When to Use
Starting a new feature or project that needs clear requirements
Translating stakeholder needs into technical specifications
Document edge cases and scenarios - What happens when things go wrong
Establish success metrics - How to measure completion
Requirement Types
Type
Purpose
Example
Functional (FR)
What the system does
"System shall authenticate users via OAuth2"
Non-Functional (NFR)
Quality attributes
"API response time <200ms for 95% of requests"
Constraint
Limitations
"Must use existing PostgreSQL database"
Implementation Pattern
Requirements Document Structure
specification:functional_requirements:
-
id:
"FR-001"
description:
"System shall authenticate users via OAuth2"
priority:
"high"
acceptance_criteria:
-
"Users can login with Google/GitHub"
-
"Session persists for 24 hours"
-
"Refresh tokens auto-renew"
non_functional_requirements:
-
id:
"NFR-001"
category:
"performance"
description:
"API response time <200ms for 95% of requests"
measurement:
"p95 latency metric"
-
id:
"NFR-002"
category:
"security"
description:
"All data encrypted in transit and at rest"
validation:
"Security audit checklist"
Constraint Analysis
constraints:technical:-"Must use existing PostgreSQL database"-"Compatible with Node.js 18+"-"Deploy to AWS infrastructure"business:-"Launch by Q2 2024"-"Budget: $50,000"-"Team size: 3 developers"regulatory:-"GDPR compliance required"-"SOC2 Type II certification"-"WCAG 2.1 AA accessibility"
Use Case Definition
use_cases:-id:"UC-001"title:"User Registration"actor:"New User"preconditions:-"User has valid email"-"User accepts terms"flow:1."User clicks 'Sign Up'"2."System displays registration form"3."User enters email and password"4."System validates inputs"5."System creates account"6."System sends confirmation email"postconditions:-"User account created"-"Confirmation email sent"exceptions:-"Invalid email: Show error"-"Weak password: Show requirements"-"Duplicate email: Suggest login"
Acceptance Criteria (Gherkin)
Feature: User Authentication
Scenario: Successful login
Given I am on the login page
And I have a valid account
When I enter correct credentials
And I click "Login"
Then I should be redirected to dashboard
And I should see my username
And my session should be active
Scenario: Failed login - wrong password
Given I am on the login page
When I enter valid email
And I enter wrong password
And I click "Login"
Then I should see error "Invalid credentials"
And I should remain on login page
And login attempts should be logged