@ifi/pi-spec 0.2.14
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +528 -0
- package/extension/assets/templates/agent-file-template.md +28 -0
- package/extension/assets/templates/checklist-template.md +40 -0
- package/extension/assets/templates/commands/analyze.md +187 -0
- package/extension/assets/templates/commands/checklist.md +298 -0
- package/extension/assets/templates/commands/clarify.md +184 -0
- package/extension/assets/templates/commands/constitution.md +84 -0
- package/extension/assets/templates/commands/implement.md +201 -0
- package/extension/assets/templates/commands/plan.md +96 -0
- package/extension/assets/templates/commands/specify.md +242 -0
- package/extension/assets/templates/commands/tasks.md +203 -0
- package/extension/assets/templates/constitution-template.md +50 -0
- package/extension/assets/templates/plan-template.md +104 -0
- package/extension/assets/templates/spec-template.md +115 -0
- package/extension/assets/templates/tasks-template.md +251 -0
- package/extension/git.ts +64 -0
- package/extension/index.ts +366 -0
- package/extension/prompts.ts +124 -0
- package/extension/scaffold.ts +151 -0
- package/extension/status.ts +231 -0
- package/extension/types.ts +93 -0
- package/extension/workspace.ts +242 -0
- package/package.json +50 -0
|
@@ -0,0 +1,203 @@
|
|
|
1
|
+
---
|
|
2
|
+
description: Generate an actionable, dependency-ordered tasks.md for the feature based on available design artifacts.
|
|
3
|
+
handoffs:
|
|
4
|
+
- label: Analyze For Consistency
|
|
5
|
+
agent: speckit.analyze
|
|
6
|
+
prompt: Run a project analysis for consistency
|
|
7
|
+
send: true
|
|
8
|
+
- label: Implement Project
|
|
9
|
+
agent: speckit.implement
|
|
10
|
+
prompt: Start the implementation in phases
|
|
11
|
+
send: true
|
|
12
|
+
scripts:
|
|
13
|
+
sh: scripts/bash/check-prerequisites.sh --json
|
|
14
|
+
ps: scripts/powershell/check-prerequisites.ps1 -Json
|
|
15
|
+
---
|
|
16
|
+
|
|
17
|
+
## User Input
|
|
18
|
+
|
|
19
|
+
```text
|
|
20
|
+
$ARGUMENTS
|
|
21
|
+
```
|
|
22
|
+
|
|
23
|
+
You **MUST** consider the user input before proceeding (if not empty).
|
|
24
|
+
|
|
25
|
+
## Pre-Execution Checks
|
|
26
|
+
|
|
27
|
+
**Check for extension hooks (before tasks generation)**:
|
|
28
|
+
- Check if `.specify/extensions.yml` exists in the project root.
|
|
29
|
+
- If it exists, read it and look for entries under the `hooks.before_tasks` key
|
|
30
|
+
- If the YAML cannot be parsed or is invalid, skip hook checking silently and continue normally
|
|
31
|
+
- Filter to only hooks where `enabled: true`
|
|
32
|
+
- For each remaining hook, do **not** attempt to interpret or evaluate hook `condition` expressions:
|
|
33
|
+
- If the hook has no `condition` field, or it is null/empty, treat the hook as executable
|
|
34
|
+
- If the hook defines a non-empty `condition`, skip the hook and leave condition evaluation to the HookExecutor implementation
|
|
35
|
+
- For each executable hook, output the following based on its `optional` flag:
|
|
36
|
+
- **Optional hook** (`optional: true`):
|
|
37
|
+
```
|
|
38
|
+
## Extension Hooks
|
|
39
|
+
|
|
40
|
+
**Optional Pre-Hook**: {extension}
|
|
41
|
+
Command: `/{command}`
|
|
42
|
+
Description: {description}
|
|
43
|
+
|
|
44
|
+
Prompt: {prompt}
|
|
45
|
+
To execute: `/{command}`
|
|
46
|
+
```
|
|
47
|
+
- **Mandatory hook** (`optional: false`):
|
|
48
|
+
```
|
|
49
|
+
## Extension Hooks
|
|
50
|
+
|
|
51
|
+
**Automatic Pre-Hook**: {extension}
|
|
52
|
+
Executing: `/{command}`
|
|
53
|
+
EXECUTE_COMMAND: {command}
|
|
54
|
+
|
|
55
|
+
Wait for the result of the hook command before proceeding to the Outline.
|
|
56
|
+
```
|
|
57
|
+
- If no hooks are registered or `.specify/extensions.yml` does not exist, skip silently
|
|
58
|
+
|
|
59
|
+
## Outline
|
|
60
|
+
|
|
61
|
+
1. **Setup**: Run `{SCRIPT}` from repo root and parse FEATURE_DIR and AVAILABLE_DOCS list. All paths must be absolute. For single quotes in args like "I'm Groot", use escape syntax: e.g 'I'\''m Groot' (or double-quote if possible: "I'm Groot").
|
|
62
|
+
|
|
63
|
+
2. **Load design documents**: Read from FEATURE_DIR:
|
|
64
|
+
- **Required**: plan.md (tech stack, libraries, structure), spec.md (user stories with priorities)
|
|
65
|
+
- **Optional**: data-model.md (entities), contracts/ (interface contracts), research.md (decisions), quickstart.md (test scenarios)
|
|
66
|
+
- Note: Not all projects have all documents. Generate tasks based on what's available.
|
|
67
|
+
|
|
68
|
+
3. **Execute task generation workflow**:
|
|
69
|
+
- Load plan.md and extract tech stack, libraries, project structure
|
|
70
|
+
- Load spec.md and extract user stories with their priorities (P1, P2, P3, etc.)
|
|
71
|
+
- If data-model.md exists: Extract entities and map to user stories
|
|
72
|
+
- If contracts/ exists: Map interface contracts to user stories
|
|
73
|
+
- If research.md exists: Extract decisions for setup tasks
|
|
74
|
+
- Generate tasks organized by user story (see Task Generation Rules below)
|
|
75
|
+
- Generate dependency graph showing user story completion order
|
|
76
|
+
- Create parallel execution examples per user story
|
|
77
|
+
- Validate task completeness (each user story has all needed tasks, independently testable)
|
|
78
|
+
|
|
79
|
+
4. **Generate tasks.md**: Use `templates/tasks-template.md` as structure, fill with:
|
|
80
|
+
- Correct feature name from plan.md
|
|
81
|
+
- Phase 1: Setup tasks (project initialization)
|
|
82
|
+
- Phase 2: Foundational tasks (blocking prerequisites for all user stories)
|
|
83
|
+
- Phase 3+: One phase per user story (in priority order from spec.md)
|
|
84
|
+
- Each phase includes: story goal, independent test criteria, tests (if requested), implementation tasks
|
|
85
|
+
- Final Phase: Polish & cross-cutting concerns
|
|
86
|
+
- All tasks must follow the strict checklist format (see Task Generation Rules below)
|
|
87
|
+
- Clear file paths for each task
|
|
88
|
+
- Dependencies section showing story completion order
|
|
89
|
+
- Parallel execution examples per story
|
|
90
|
+
- Implementation strategy section (MVP first, incremental delivery)
|
|
91
|
+
|
|
92
|
+
5. **Report**: Output path to generated tasks.md and summary:
|
|
93
|
+
- Total task count
|
|
94
|
+
- Task count per user story
|
|
95
|
+
- Parallel opportunities identified
|
|
96
|
+
- Independent test criteria for each story
|
|
97
|
+
- Suggested MVP scope (typically just User Story 1)
|
|
98
|
+
- Format validation: Confirm ALL tasks follow the checklist format (checkbox, ID, labels, file paths)
|
|
99
|
+
|
|
100
|
+
6. **Check for extension hooks**: After tasks.md is generated, check if `.specify/extensions.yml` exists in the project root.
|
|
101
|
+
- If it exists, read it and look for entries under the `hooks.after_tasks` key
|
|
102
|
+
- If the YAML cannot be parsed or is invalid, skip hook checking silently and continue normally
|
|
103
|
+
- Filter to only hooks where `enabled: true`
|
|
104
|
+
- For each remaining hook, do **not** attempt to interpret or evaluate hook `condition` expressions:
|
|
105
|
+
- If the hook has no `condition` field, or it is null/empty, treat the hook as executable
|
|
106
|
+
- If the hook defines a non-empty `condition`, skip the hook and leave condition evaluation to the HookExecutor implementation
|
|
107
|
+
- For each executable hook, output the following based on its `optional` flag:
|
|
108
|
+
- **Optional hook** (`optional: true`):
|
|
109
|
+
```
|
|
110
|
+
## Extension Hooks
|
|
111
|
+
|
|
112
|
+
**Optional Hook**: {extension}
|
|
113
|
+
Command: `/{command}`
|
|
114
|
+
Description: {description}
|
|
115
|
+
|
|
116
|
+
Prompt: {prompt}
|
|
117
|
+
To execute: `/{command}`
|
|
118
|
+
```
|
|
119
|
+
- **Mandatory hook** (`optional: false`):
|
|
120
|
+
```
|
|
121
|
+
## Extension Hooks
|
|
122
|
+
|
|
123
|
+
**Automatic Hook**: {extension}
|
|
124
|
+
Executing: `/{command}`
|
|
125
|
+
EXECUTE_COMMAND: {command}
|
|
126
|
+
```
|
|
127
|
+
- If no hooks are registered or `.specify/extensions.yml` does not exist, skip silently
|
|
128
|
+
|
|
129
|
+
Context for task generation: {ARGS}
|
|
130
|
+
|
|
131
|
+
The tasks.md should be immediately executable - each task must be specific enough that an LLM can complete it without additional context.
|
|
132
|
+
|
|
133
|
+
## Task Generation Rules
|
|
134
|
+
|
|
135
|
+
**CRITICAL**: Tasks MUST be organized by user story to enable independent implementation and testing.
|
|
136
|
+
|
|
137
|
+
**Tests are OPTIONAL**: Only generate test tasks if explicitly requested in the feature specification or if user requests TDD approach.
|
|
138
|
+
|
|
139
|
+
### Checklist Format (REQUIRED)
|
|
140
|
+
|
|
141
|
+
Every task MUST strictly follow this format:
|
|
142
|
+
|
|
143
|
+
```text
|
|
144
|
+
- [ ] [TaskID] [P?] [Story?] Description with file path
|
|
145
|
+
```
|
|
146
|
+
|
|
147
|
+
**Format Components**:
|
|
148
|
+
|
|
149
|
+
1. **Checkbox**: ALWAYS start with `- [ ]` (markdown checkbox)
|
|
150
|
+
2. **Task ID**: Sequential number (T001, T002, T003...) in execution order
|
|
151
|
+
3. **[P] marker**: Include ONLY if task is parallelizable (different files, no dependencies on incomplete tasks)
|
|
152
|
+
4. **[Story] label**: REQUIRED for user story phase tasks only
|
|
153
|
+
- Format: [US1], [US2], [US3], etc. (maps to user stories from spec.md)
|
|
154
|
+
- Setup phase: NO story label
|
|
155
|
+
- Foundational phase: NO story label
|
|
156
|
+
- User Story phases: MUST have story label
|
|
157
|
+
- Polish phase: NO story label
|
|
158
|
+
5. **Description**: Clear action with exact file path
|
|
159
|
+
|
|
160
|
+
**Examples**:
|
|
161
|
+
|
|
162
|
+
- ✅ CORRECT: `- [ ] T001 Create project structure per implementation plan`
|
|
163
|
+
- ✅ CORRECT: `- [ ] T005 [P] Implement authentication middleware in src/middleware/auth.py`
|
|
164
|
+
- ✅ CORRECT: `- [ ] T012 [P] [US1] Create User model in src/models/user.py`
|
|
165
|
+
- ✅ CORRECT: `- [ ] T014 [US1] Implement UserService in src/services/user_service.py`
|
|
166
|
+
- ❌ WRONG: `- [ ] Create User model` (missing ID and Story label)
|
|
167
|
+
- ❌ WRONG: `T001 [US1] Create model` (missing checkbox)
|
|
168
|
+
- ❌ WRONG: `- [ ] [US1] Create User model` (missing Task ID)
|
|
169
|
+
- ❌ WRONG: `- [ ] T001 [US1] Create model` (missing file path)
|
|
170
|
+
|
|
171
|
+
### Task Organization
|
|
172
|
+
|
|
173
|
+
1. **From User Stories (spec.md)** - PRIMARY ORGANIZATION:
|
|
174
|
+
- Each user story (P1, P2, P3...) gets its own phase
|
|
175
|
+
- Map all related components to their story:
|
|
176
|
+
- Models needed for that story
|
|
177
|
+
- Services needed for that story
|
|
178
|
+
- Interfaces/UI needed for that story
|
|
179
|
+
- If tests requested: Tests specific to that story
|
|
180
|
+
- Mark story dependencies (most stories should be independent)
|
|
181
|
+
|
|
182
|
+
2. **From Contracts**:
|
|
183
|
+
- Map each interface contract → to the user story it serves
|
|
184
|
+
- If tests requested: Each interface contract → contract test task [P] before implementation in that story's phase
|
|
185
|
+
|
|
186
|
+
3. **From Data Model**:
|
|
187
|
+
- Map each entity to the user story(ies) that need it
|
|
188
|
+
- If entity serves multiple stories: Put in earliest story or Setup phase
|
|
189
|
+
- Relationships → service layer tasks in appropriate story phase
|
|
190
|
+
|
|
191
|
+
4. **From Setup/Infrastructure**:
|
|
192
|
+
- Shared infrastructure → Setup phase (Phase 1)
|
|
193
|
+
- Foundational/blocking tasks → Foundational phase (Phase 2)
|
|
194
|
+
- Story-specific setup → within that story's phase
|
|
195
|
+
|
|
196
|
+
### Phase Structure
|
|
197
|
+
|
|
198
|
+
- **Phase 1**: Setup (project initialization)
|
|
199
|
+
- **Phase 2**: Foundational (blocking prerequisites - MUST complete before user stories)
|
|
200
|
+
- **Phase 3+**: User Stories in priority order (P1, P2, P3...)
|
|
201
|
+
- Within each story: Tests (if requested) → Models → Services → Endpoints → Integration
|
|
202
|
+
- Each phase should be a complete, independently testable increment
|
|
203
|
+
- **Final Phase**: Polish & Cross-Cutting Concerns
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
# [PROJECT_NAME] Constitution
|
|
2
|
+
<!-- Example: Spec Constitution, TaskFlow Constitution, etc. -->
|
|
3
|
+
|
|
4
|
+
## Core Principles
|
|
5
|
+
|
|
6
|
+
### [PRINCIPLE_1_NAME]
|
|
7
|
+
<!-- Example: I. Library-First -->
|
|
8
|
+
[PRINCIPLE_1_DESCRIPTION]
|
|
9
|
+
<!-- Example: Every feature starts as a standalone library; Libraries must be self-contained, independently testable, documented; Clear purpose required - no organizational-only libraries -->
|
|
10
|
+
|
|
11
|
+
### [PRINCIPLE_2_NAME]
|
|
12
|
+
<!-- Example: II. CLI Interface -->
|
|
13
|
+
[PRINCIPLE_2_DESCRIPTION]
|
|
14
|
+
<!-- Example: Every library exposes functionality via CLI; Text in/out protocol: stdin/args → stdout, errors → stderr; Support JSON + human-readable formats -->
|
|
15
|
+
|
|
16
|
+
### [PRINCIPLE_3_NAME]
|
|
17
|
+
<!-- Example: III. Test-First (NON-NEGOTIABLE) -->
|
|
18
|
+
[PRINCIPLE_3_DESCRIPTION]
|
|
19
|
+
<!-- Example: TDD mandatory: Tests written → User approved → Tests fail → Then implement; Red-Green-Refactor cycle strictly enforced -->
|
|
20
|
+
|
|
21
|
+
### [PRINCIPLE_4_NAME]
|
|
22
|
+
<!-- Example: IV. Integration Testing -->
|
|
23
|
+
[PRINCIPLE_4_DESCRIPTION]
|
|
24
|
+
<!-- Example: Focus areas requiring integration tests: New library contract tests, Contract changes, Inter-service communication, Shared schemas -->
|
|
25
|
+
|
|
26
|
+
### [PRINCIPLE_5_NAME]
|
|
27
|
+
<!-- Example: V. Observability, VI. Versioning & Breaking Changes, VII. Simplicity -->
|
|
28
|
+
[PRINCIPLE_5_DESCRIPTION]
|
|
29
|
+
<!-- Example: Text I/O ensures debuggability; Structured logging required; Or: MAJOR.MINOR.BUILD format; Or: Start simple, YAGNI principles -->
|
|
30
|
+
|
|
31
|
+
## [SECTION_2_NAME]
|
|
32
|
+
<!-- Example: Additional Constraints, Security Requirements, Performance Standards, etc. -->
|
|
33
|
+
|
|
34
|
+
[SECTION_2_CONTENT]
|
|
35
|
+
<!-- Example: Technology stack requirements, compliance standards, deployment policies, etc. -->
|
|
36
|
+
|
|
37
|
+
## [SECTION_3_NAME]
|
|
38
|
+
<!-- Example: Development Workflow, Review Process, Quality Gates, etc. -->
|
|
39
|
+
|
|
40
|
+
[SECTION_3_CONTENT]
|
|
41
|
+
<!-- Example: Code review requirements, testing gates, deployment approval process, etc. -->
|
|
42
|
+
|
|
43
|
+
## Governance
|
|
44
|
+
<!-- Example: Constitution supersedes all other practices; Amendments require documentation, approval, migration plan -->
|
|
45
|
+
|
|
46
|
+
[GOVERNANCE_RULES]
|
|
47
|
+
<!-- Example: All PRs/reviews must verify compliance; Complexity must be justified; Use [GUIDANCE_FILE] for runtime development guidance -->
|
|
48
|
+
|
|
49
|
+
**Version**: [CONSTITUTION_VERSION] | **Ratified**: [RATIFICATION_DATE] | **Last Amended**: [LAST_AMENDED_DATE]
|
|
50
|
+
<!-- Example: Version: 2.1.1 | Ratified: 2025-06-13 | Last Amended: 2025-07-16 -->
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
# Implementation Plan: [FEATURE]
|
|
2
|
+
|
|
3
|
+
**Branch**: `[###-feature-name]` | **Date**: [DATE] | **Spec**: [link]
|
|
4
|
+
**Input**: Feature specification from `/specs/[###-feature-name]/spec.md`
|
|
5
|
+
|
|
6
|
+
**Note**: This template is filled in by the `/speckit.plan` command. See `.specify/templates/plan-template.md` for the execution workflow.
|
|
7
|
+
|
|
8
|
+
## Summary
|
|
9
|
+
|
|
10
|
+
[Extract from feature spec: primary requirement + technical approach from research]
|
|
11
|
+
|
|
12
|
+
## Technical Context
|
|
13
|
+
|
|
14
|
+
<!--
|
|
15
|
+
ACTION REQUIRED: Replace the content in this section with the technical details
|
|
16
|
+
for the project. The structure here is presented in advisory capacity to guide
|
|
17
|
+
the iteration process.
|
|
18
|
+
-->
|
|
19
|
+
|
|
20
|
+
**Language/Version**: [e.g., Python 3.11, Swift 5.9, Rust 1.75 or NEEDS CLARIFICATION]
|
|
21
|
+
**Primary Dependencies**: [e.g., FastAPI, UIKit, LLVM or NEEDS CLARIFICATION]
|
|
22
|
+
**Storage**: [if applicable, e.g., PostgreSQL, CoreData, files or N/A]
|
|
23
|
+
**Testing**: [e.g., pytest, XCTest, cargo test or NEEDS CLARIFICATION]
|
|
24
|
+
**Target Platform**: [e.g., Linux server, iOS 15+, WASM or NEEDS CLARIFICATION]
|
|
25
|
+
**Project Type**: [e.g., library/cli/web-service/mobile-app/compiler/desktop-app or NEEDS CLARIFICATION]
|
|
26
|
+
**Performance Goals**: [domain-specific, e.g., 1000 req/s, 10k lines/sec, 60 fps or NEEDS CLARIFICATION]
|
|
27
|
+
**Constraints**: [domain-specific, e.g., <200ms p95, <100MB memory, offline-capable or NEEDS CLARIFICATION]
|
|
28
|
+
**Scale/Scope**: [domain-specific, e.g., 10k users, 1M LOC, 50 screens or NEEDS CLARIFICATION]
|
|
29
|
+
|
|
30
|
+
## Constitution Check
|
|
31
|
+
|
|
32
|
+
*GATE: Must pass before Phase 0 research. Re-check after Phase 1 design.*
|
|
33
|
+
|
|
34
|
+
[Gates determined based on constitution file]
|
|
35
|
+
|
|
36
|
+
## Project Structure
|
|
37
|
+
|
|
38
|
+
### Documentation (this feature)
|
|
39
|
+
|
|
40
|
+
```text
|
|
41
|
+
specs/[###-feature]/
|
|
42
|
+
├── plan.md # This file (/speckit.plan command output)
|
|
43
|
+
├── research.md # Phase 0 output (/speckit.plan command)
|
|
44
|
+
├── data-model.md # Phase 1 output (/speckit.plan command)
|
|
45
|
+
├── quickstart.md # Phase 1 output (/speckit.plan command)
|
|
46
|
+
├── contracts/ # Phase 1 output (/speckit.plan command)
|
|
47
|
+
└── tasks.md # Phase 2 output (/speckit.tasks command - NOT created by /speckit.plan)
|
|
48
|
+
```
|
|
49
|
+
|
|
50
|
+
### Source Code (repository root)
|
|
51
|
+
<!--
|
|
52
|
+
ACTION REQUIRED: Replace the placeholder tree below with the concrete layout
|
|
53
|
+
for this feature. Delete unused options and expand the chosen structure with
|
|
54
|
+
real paths (e.g., apps/admin, packages/something). The delivered plan must
|
|
55
|
+
not include Option labels.
|
|
56
|
+
-->
|
|
57
|
+
|
|
58
|
+
```text
|
|
59
|
+
# [REMOVE IF UNUSED] Option 1: Single project (DEFAULT)
|
|
60
|
+
src/
|
|
61
|
+
├── models/
|
|
62
|
+
├── services/
|
|
63
|
+
├── cli/
|
|
64
|
+
└── lib/
|
|
65
|
+
|
|
66
|
+
tests/
|
|
67
|
+
├── contract/
|
|
68
|
+
├── integration/
|
|
69
|
+
└── unit/
|
|
70
|
+
|
|
71
|
+
# [REMOVE IF UNUSED] Option 2: Web application (when "frontend" + "backend" detected)
|
|
72
|
+
backend/
|
|
73
|
+
├── src/
|
|
74
|
+
│ ├── models/
|
|
75
|
+
│ ├── services/
|
|
76
|
+
│ └── api/
|
|
77
|
+
└── tests/
|
|
78
|
+
|
|
79
|
+
frontend/
|
|
80
|
+
├── src/
|
|
81
|
+
│ ├── components/
|
|
82
|
+
│ ├── pages/
|
|
83
|
+
│ └── services/
|
|
84
|
+
└── tests/
|
|
85
|
+
|
|
86
|
+
# [REMOVE IF UNUSED] Option 3: Mobile + API (when "iOS/Android" detected)
|
|
87
|
+
api/
|
|
88
|
+
└── [same as backend above]
|
|
89
|
+
|
|
90
|
+
ios/ or android/
|
|
91
|
+
└── [platform-specific structure: feature modules, UI flows, platform tests]
|
|
92
|
+
```
|
|
93
|
+
|
|
94
|
+
**Structure Decision**: [Document the selected structure and reference the real
|
|
95
|
+
directories captured above]
|
|
96
|
+
|
|
97
|
+
## Complexity Tracking
|
|
98
|
+
|
|
99
|
+
> **Fill ONLY if Constitution Check has violations that must be justified**
|
|
100
|
+
|
|
101
|
+
| Violation | Why Needed | Simpler Alternative Rejected Because |
|
|
102
|
+
|-----------|------------|-------------------------------------|
|
|
103
|
+
| [e.g., 4th project] | [current need] | [why 3 projects insufficient] |
|
|
104
|
+
| [e.g., Repository pattern] | [specific problem] | [why direct DB access insufficient] |
|
|
@@ -0,0 +1,115 @@
|
|
|
1
|
+
# Feature Specification: [FEATURE NAME]
|
|
2
|
+
|
|
3
|
+
**Feature Branch**: `[###-feature-name]`
|
|
4
|
+
**Created**: [DATE]
|
|
5
|
+
**Status**: Draft
|
|
6
|
+
**Input**: User description: "$ARGUMENTS"
|
|
7
|
+
|
|
8
|
+
## User Scenarios & Testing *(mandatory)*
|
|
9
|
+
|
|
10
|
+
<!--
|
|
11
|
+
IMPORTANT: User stories should be PRIORITIZED as user journeys ordered by importance.
|
|
12
|
+
Each user story/journey must be INDEPENDENTLY TESTABLE - meaning if you implement just ONE of them,
|
|
13
|
+
you should still have a viable MVP (Minimum Viable Product) that delivers value.
|
|
14
|
+
|
|
15
|
+
Assign priorities (P1, P2, P3, etc.) to each story, where P1 is the most critical.
|
|
16
|
+
Think of each story as a standalone slice of functionality that can be:
|
|
17
|
+
- Developed independently
|
|
18
|
+
- Tested independently
|
|
19
|
+
- Deployed independently
|
|
20
|
+
- Demonstrated to users independently
|
|
21
|
+
-->
|
|
22
|
+
|
|
23
|
+
### User Story 1 - [Brief Title] (Priority: P1)
|
|
24
|
+
|
|
25
|
+
[Describe this user journey in plain language]
|
|
26
|
+
|
|
27
|
+
**Why this priority**: [Explain the value and why it has this priority level]
|
|
28
|
+
|
|
29
|
+
**Independent Test**: [Describe how this can be tested independently - e.g., "Can be fully tested by [specific action] and delivers [specific value]"]
|
|
30
|
+
|
|
31
|
+
**Acceptance Scenarios**:
|
|
32
|
+
|
|
33
|
+
1. **Given** [initial state], **When** [action], **Then** [expected outcome]
|
|
34
|
+
2. **Given** [initial state], **When** [action], **Then** [expected outcome]
|
|
35
|
+
|
|
36
|
+
---
|
|
37
|
+
|
|
38
|
+
### User Story 2 - [Brief Title] (Priority: P2)
|
|
39
|
+
|
|
40
|
+
[Describe this user journey in plain language]
|
|
41
|
+
|
|
42
|
+
**Why this priority**: [Explain the value and why it has this priority level]
|
|
43
|
+
|
|
44
|
+
**Independent Test**: [Describe how this can be tested independently]
|
|
45
|
+
|
|
46
|
+
**Acceptance Scenarios**:
|
|
47
|
+
|
|
48
|
+
1. **Given** [initial state], **When** [action], **Then** [expected outcome]
|
|
49
|
+
|
|
50
|
+
---
|
|
51
|
+
|
|
52
|
+
### User Story 3 - [Brief Title] (Priority: P3)
|
|
53
|
+
|
|
54
|
+
[Describe this user journey in plain language]
|
|
55
|
+
|
|
56
|
+
**Why this priority**: [Explain the value and why it has this priority level]
|
|
57
|
+
|
|
58
|
+
**Independent Test**: [Describe how this can be tested independently]
|
|
59
|
+
|
|
60
|
+
**Acceptance Scenarios**:
|
|
61
|
+
|
|
62
|
+
1. **Given** [initial state], **When** [action], **Then** [expected outcome]
|
|
63
|
+
|
|
64
|
+
---
|
|
65
|
+
|
|
66
|
+
[Add more user stories as needed, each with an assigned priority]
|
|
67
|
+
|
|
68
|
+
### Edge Cases
|
|
69
|
+
|
|
70
|
+
<!--
|
|
71
|
+
ACTION REQUIRED: The content in this section represents placeholders.
|
|
72
|
+
Fill them out with the right edge cases.
|
|
73
|
+
-->
|
|
74
|
+
|
|
75
|
+
- What happens when [boundary condition]?
|
|
76
|
+
- How does system handle [error scenario]?
|
|
77
|
+
|
|
78
|
+
## Requirements *(mandatory)*
|
|
79
|
+
|
|
80
|
+
<!--
|
|
81
|
+
ACTION REQUIRED: The content in this section represents placeholders.
|
|
82
|
+
Fill them out with the right functional requirements.
|
|
83
|
+
-->
|
|
84
|
+
|
|
85
|
+
### Functional Requirements
|
|
86
|
+
|
|
87
|
+
- **FR-001**: System MUST [specific capability, e.g., "allow users to create accounts"]
|
|
88
|
+
- **FR-002**: System MUST [specific capability, e.g., "validate email addresses"]
|
|
89
|
+
- **FR-003**: Users MUST be able to [key interaction, e.g., "reset their password"]
|
|
90
|
+
- **FR-004**: System MUST [data requirement, e.g., "persist user preferences"]
|
|
91
|
+
- **FR-005**: System MUST [behavior, e.g., "log all security events"]
|
|
92
|
+
|
|
93
|
+
*Example of marking unclear requirements:*
|
|
94
|
+
|
|
95
|
+
- **FR-006**: System MUST authenticate users via [NEEDS CLARIFICATION: auth method not specified - email/password, SSO, OAuth?]
|
|
96
|
+
- **FR-007**: System MUST retain user data for [NEEDS CLARIFICATION: retention period not specified]
|
|
97
|
+
|
|
98
|
+
### Key Entities *(include if feature involves data)*
|
|
99
|
+
|
|
100
|
+
- **[Entity 1]**: [What it represents, key attributes without implementation]
|
|
101
|
+
- **[Entity 2]**: [What it represents, relationships to other entities]
|
|
102
|
+
|
|
103
|
+
## Success Criteria *(mandatory)*
|
|
104
|
+
|
|
105
|
+
<!--
|
|
106
|
+
ACTION REQUIRED: Define measurable success criteria.
|
|
107
|
+
These must be technology-agnostic and measurable.
|
|
108
|
+
-->
|
|
109
|
+
|
|
110
|
+
### Measurable Outcomes
|
|
111
|
+
|
|
112
|
+
- **SC-001**: [Measurable metric, e.g., "Users can complete account creation in under 2 minutes"]
|
|
113
|
+
- **SC-002**: [Measurable metric, e.g., "System handles 1000 concurrent users without degradation"]
|
|
114
|
+
- **SC-003**: [User satisfaction metric, e.g., "90% of users successfully complete primary task on first attempt"]
|
|
115
|
+
- **SC-004**: [Business metric, e.g., "Reduce support tickets related to [X] by 50%"]
|