@comfanion/workflow 3.9.0 → 4.1.0
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/package.json +1 -1
- package/src/build-info.json +1 -1
- package/src/opencode/config.yaml +1 -1
- package/src/opencode/skills/epic-writing/SKILL.md +15 -14
- package/src/opencode/skills/story-writing/SKILL.md +152 -245
- package/src/opencode/templates/epic-template.md +12 -10
- package/src/opencode/templates/story-template.md +91 -357
package/package.json
CHANGED
package/src/build-info.json
CHANGED
package/src/opencode/config.yaml
CHANGED
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
# PROJECT CONFIGURATION
|
|
7
7
|
# =============================================================================
|
|
8
8
|
project_name: "ai-wf"
|
|
9
|
-
version: "
|
|
9
|
+
version: "4.1.0"
|
|
10
10
|
|
|
11
11
|
# =============================================================================
|
|
12
12
|
# USER CONFIGURATION
|
|
@@ -206,26 +206,27 @@ S01 (Domain) ──┬──► S02 (Repo Interface) ──► S04 (Repo Impl)
|
|
|
206
206
|
└──► S03 (Use Cases) ──► S05 (HTTP) ─┴──► S06 (Events) ──► S07 (Tests)
|
|
207
207
|
```
|
|
208
208
|
|
|
209
|
-
###
|
|
209
|
+
### Story Breakdown
|
|
210
210
|
|
|
211
211
|
```markdown
|
|
212
|
-
###
|
|
213
|
-
|
|
214
|
-
| Story | Tasks |
|
|
215
|
-
|
|
216
|
-
| S01 | 4 |
|
|
217
|
-
| S02 | 3 |
|
|
218
|
-
| S03 | 5 |
|
|
219
|
-
| S04 | 4 |
|
|
220
|
-
| S05 | 3 |
|
|
221
|
-
| S06 | 3 |
|
|
222
|
-
| S07 | 3 |
|
|
223
|
-
| **Total** | **25** |
|
|
212
|
+
### Stories Summary
|
|
213
|
+
|
|
214
|
+
| Story | Tasks | Size | Deps |
|
|
215
|
+
|-------|-------|------|------|
|
|
216
|
+
| S01 | 4 | M | - |
|
|
217
|
+
| S02 | 3 | S | S01 |
|
|
218
|
+
| S03 | 5 | L | S01 |
|
|
219
|
+
| S04 | 4 | M | S02 |
|
|
220
|
+
| S05 | 3 | S | S03 |
|
|
221
|
+
| S06 | 3 | S | S04 |
|
|
222
|
+
| S07 | 3 | S | S05,S06 |
|
|
223
|
+
| **Total** | **25** | | |
|
|
224
224
|
|
|
225
225
|
**Parallel Opportunities:** S02+S03, S04+S05
|
|
226
|
-
**With Parallelism:** ~10 days (2 weeks)
|
|
227
226
|
```
|
|
228
227
|
|
|
228
|
+
**Note:** No hour estimates. Use T-shirt sizes (XS/S/M/L/XL) for relative complexity.
|
|
229
|
+
|
|
229
230
|
## Epic Sizing
|
|
230
231
|
|
|
231
232
|
### Guidelines
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: story-writing
|
|
3
|
-
description: How to write
|
|
3
|
+
description: How to write stories as execution plans with self-contained tasks
|
|
4
4
|
license: MIT
|
|
5
5
|
compatibility: opencode
|
|
6
6
|
metadata:
|
|
@@ -85,37 +85,54 @@ Use template at: `@.opencode/templates/story-template.md`
|
|
|
85
85
|
|
|
86
86
|
## Story Structure
|
|
87
87
|
|
|
88
|
-
|
|
88
|
+
**Philosophy:** Story = execution plan. Tasks are the main content, not ceremony.
|
|
89
|
+
|
|
90
|
+
### Header (Minimal)
|
|
89
91
|
|
|
90
92
|
```markdown
|
|
91
93
|
# Story N.M: [Title]
|
|
92
94
|
|
|
93
95
|
**Story ID:** [MODULE]-S[EPIC]-[NN]
|
|
94
96
|
**Epic:** [MODULE]-E[EPIC] - [Epic Title]
|
|
95
|
-
**Status:**
|
|
96
|
-
**
|
|
97
|
-
|
|
97
|
+
**Status:** draft | ready-for-dev | in-progress | review | done
|
|
98
|
+
**Size:** XS | S | M | L | XL
|
|
99
|
+
```
|
|
100
|
+
|
|
101
|
+
### Goal (1-2 sentences)
|
|
102
|
+
|
|
103
|
+
```markdown
|
|
104
|
+
## Goal
|
|
105
|
+
|
|
106
|
+
Implement CRUD use cases for merchant products with validation and event publishing.
|
|
98
107
|
```
|
|
99
108
|
|
|
100
|
-
|
|
109
|
+
**NOT** the verbose "As a... I want... So that..." format. Just state what the story achieves.
|
|
110
|
+
|
|
111
|
+
### Acceptance Criteria (Brief List)
|
|
101
112
|
|
|
102
113
|
```markdown
|
|
103
|
-
##
|
|
114
|
+
## Acceptance Criteria
|
|
104
115
|
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
116
|
+
- [ ] Products can be created with EAN validation
|
|
117
|
+
- [ ] Products can be retrieved by ID
|
|
118
|
+
- [ ] Products can be updated with optimistic locking
|
|
119
|
+
- [ ] Products can be listed with filters and pagination
|
|
120
|
+
- [ ] All operations publish domain events
|
|
108
121
|
```
|
|
109
122
|
|
|
110
|
-
|
|
123
|
+
**NOT** detailed Given/When/Then for each. Just a checklist of what "done" looks like.
|
|
124
|
+
|
|
125
|
+
### Tasks (MAIN CONTENT - 80% of file)
|
|
111
126
|
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
127
|
+
Self-contained tasks with documentation links. See Task Structure below.
|
|
128
|
+
|
|
129
|
+
### Sections (Simplified)
|
|
130
|
+
|
|
131
|
+
1. **Header** - Minimal metadata
|
|
132
|
+
2. **Goal** - 1-2 sentences
|
|
133
|
+
3. **Acceptance Criteria** - Brief checklist
|
|
134
|
+
4. **Tasks** - MAIN CONTENT (80% of file)
|
|
135
|
+
5. **Notes** - Optional additional context
|
|
119
136
|
|
|
120
137
|
## Naming Conventions
|
|
121
138
|
|
|
@@ -141,65 +158,23 @@ Examples:
|
|
|
141
158
|
- INVENTORY-S10-01
|
|
142
159
|
```
|
|
143
160
|
|
|
144
|
-
##
|
|
161
|
+
## Self-Contained Tasks (NO ESTIMATES)
|
|
145
162
|
|
|
146
|
-
|
|
163
|
+
### Task Philosophy
|
|
147
164
|
|
|
148
|
-
|
|
165
|
+
**CRITICAL:** Tasks must be **SELF-CONTAINED** - an AI agent or developer can take ANY task and execute it independently without asking questions.
|
|
149
166
|
|
|
150
|
-
|
|
151
|
-
## Acceptance Criteria
|
|
152
|
-
|
|
153
|
-
### AC1: Create product with valid data
|
|
154
|
-
|
|
155
|
-
**Given** authenticated merchant with "product:create" permission
|
|
156
|
-
**When** POST /api/v1/products with:
|
|
157
|
-
- name: "Test Product"
|
|
158
|
-
- price: 100.00
|
|
159
|
-
- currency: "UAH"
|
|
160
|
-
**Then** 201 Created returned
|
|
161
|
-
**And** response contains product with generated UUID
|
|
162
|
-
**And** product status is "pending"
|
|
163
|
-
**And** "product.created" event published to Kafka
|
|
164
|
-
|
|
165
|
-
### AC2: Reject invalid product data
|
|
166
|
-
|
|
167
|
-
**Given** authenticated merchant
|
|
168
|
-
**When** POST /api/v1/products with missing required field "name"
|
|
169
|
-
**Then** 400 Bad Request returned
|
|
170
|
-
**And** error response contains:
|
|
171
|
-
- field: "name"
|
|
172
|
-
- message: "name is required"
|
|
173
|
-
**And** no product is created in database
|
|
174
|
-
|
|
175
|
-
### AC3: Unauthorized access rejected
|
|
176
|
-
|
|
177
|
-
**Given** user without "product:create" permission
|
|
178
|
-
**When** POST /api/v1/products
|
|
179
|
-
**Then** 403 Forbidden returned
|
|
180
|
-
```
|
|
181
|
-
|
|
182
|
-
### AC Coverage
|
|
183
|
-
|
|
184
|
-
Each story should have:
|
|
185
|
-
- **Happy path** - At least 1 success scenario
|
|
186
|
-
- **Validation errors** - Invalid input handling
|
|
187
|
-
- **Authorization** - Permission checks
|
|
188
|
-
- **Edge cases** - Boundary conditions
|
|
189
|
-
|
|
190
|
-
## Atomic Tasks (4-6 hours each)
|
|
167
|
+
**NO ESTIMATES** - Don't estimate time. Focus on clear scope and outcomes.
|
|
191
168
|
|
|
192
169
|
### Task Decomposition Rules
|
|
193
170
|
|
|
194
|
-
**MANDATORY**: Every story MUST be broken into atomic tasks:
|
|
195
|
-
|
|
196
171
|
| Rule | Description |
|
|
197
172
|
|------|-------------|
|
|
198
|
-
| **
|
|
199
|
-
| **
|
|
200
|
-
| **
|
|
201
|
-
| **
|
|
202
|
-
| **
|
|
173
|
+
| **Self-contained** | Task has ALL information needed to execute |
|
|
174
|
+
| **Documentation links** | Every task links to relevant docs, schemas, examples |
|
|
175
|
+
| **Clear input/output** | What exists before, what must exist after |
|
|
176
|
+
| **Testable outcome** | How to verify task is complete |
|
|
177
|
+
| **Independent execution** | Can be picked up without context from other tasks |
|
|
203
178
|
|
|
204
179
|
## Development Methodologies
|
|
205
180
|
|
|
@@ -235,203 +210,137 @@ Interface → Stub Implementation → Tests → Real Implementation
|
|
|
235
210
|
|
|
236
211
|
**Best for:** Exploratory work, unclear requirements, rapid prototyping
|
|
237
212
|
|
|
238
|
-
### Task Structure
|
|
213
|
+
### Task Structure (MANDATORY FORMAT)
|
|
239
214
|
|
|
240
|
-
|
|
241
|
-
```markdown
|
|
242
|
-
### T2: Implement {{Entity}} Aggregate + Tests
|
|
243
|
-
- **Estimate:** 5h
|
|
244
|
-
- **Depends on:** T1
|
|
245
|
-
- **Methodology:** TDD
|
|
246
|
-
- **Deliverables:**
|
|
247
|
-
- [ ] Aggregate: `domain/aggregate/entity.go`
|
|
248
|
-
- [ ] Value objects: `domain/valueobject/*.go`
|
|
249
|
-
- **Validation Test:** `domain/aggregate/entity_test.go`
|
|
250
|
-
- [ ] Test creation happy path
|
|
251
|
-
- [ ] Test validation errors
|
|
252
|
-
- [ ] Test business rules
|
|
253
|
-
- [ ] **⚠️ ALL TESTS MUST PASS**
|
|
254
|
-
```
|
|
215
|
+
Each task MUST have this structure to be self-contained:
|
|
255
216
|
|
|
256
|
-
**STUB Task:**
|
|
257
217
|
```markdown
|
|
258
|
-
###
|
|
259
|
-
- **Estimate:** 6h
|
|
260
|
-
- **Depends on:** T1
|
|
261
|
-
- **Methodology:** STUB
|
|
262
|
-
- **Deliverables:**
|
|
263
|
-
- [ ] Stub: `infrastructure/repo/entity_memory_repo.go`
|
|
264
|
-
- [ ] Real: `infrastructure/repo/entity_postgres_repo.go`
|
|
265
|
-
- **Validation Test:** `infrastructure/repo/entity_repo_test.go`
|
|
266
|
-
- [ ] Test Save, FindByID, List
|
|
267
|
-
- [ ] Test with stub first
|
|
268
|
-
- [ ] Replace stub with real
|
|
269
|
-
- [ ] **⚠️ ALL TESTS MUST PASS**
|
|
270
|
-
```
|
|
271
|
-
|
|
272
|
-
---
|
|
218
|
+
### T{N}: {Clear Task Name}
|
|
273
219
|
|
|
274
|
-
|
|
220
|
+
**Goal:** One sentence describing what this task achieves.
|
|
275
221
|
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
| GREEN | 🟢 | Implement to pass tests |
|
|
281
|
-
| STUB | 🧪 | Stub implementation (STUB methodology) |
|
|
282
|
-
| REFACTOR | 🔵 | Clean up, no new functionality |
|
|
283
|
-
| INTEGRATION | 🔗 | E2E integration test |
|
|
284
|
-
| DOCS | 📝 | Documentation only |
|
|
222
|
+
**Documentation:**
|
|
223
|
+
- [AGENTS.md#section](../../../AGENTS.md#section) - Relevant coding patterns
|
|
224
|
+
- [data-model.md#table](../docs/data-model.md#table) - Database schema
|
|
225
|
+
- [example.go](../src/path/example.go) - Pattern to follow
|
|
285
226
|
|
|
286
|
-
|
|
227
|
+
**Input (Prerequisites):**
|
|
228
|
+
- T{N-1} completed (if dependent)
|
|
229
|
+
- Existing file: `path/to/existing.go` - what it provides
|
|
230
|
+
- Repository interface defined in: `path/to/interface.go`
|
|
287
231
|
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
-
|
|
291
|
-
- **Depends on:** T1, T2 | - (none)
|
|
292
|
-
- **Blocks:** T5, T6 | - (none)
|
|
293
|
-
- **Type:** 🔴 RED | 🟢 GREEN | 🔵 REFACTOR | 📝 DOCS
|
|
294
|
-
- **Files:** `path/to/file.go`
|
|
295
|
-
- **Definition of Done:**
|
|
296
|
-
- [ ] Specific deliverable 1
|
|
297
|
-
- [ ] Specific deliverable 2
|
|
298
|
-
- **Notes:** Implementation hints
|
|
299
|
-
```
|
|
232
|
+
**Output (Deliverables):**
|
|
233
|
+
- `path/to/new_file.go` - Description of what this file does
|
|
234
|
+
- `path/to/new_file_test.go` - Tests covering X, Y, Z
|
|
300
235
|
|
|
301
|
-
|
|
236
|
+
**Implementation Steps:**
|
|
237
|
+
1. Read documentation links above
|
|
238
|
+
2. Create file structure following pattern from [example.go]
|
|
239
|
+
3. Implement X following AGENTS.md conventions
|
|
240
|
+
4. Write tests covering: happy path, validation errors, edge cases
|
|
241
|
+
5. Run tests, ensure all pass
|
|
302
242
|
|
|
303
|
-
|
|
243
|
+
**Acceptance Criteria:**
|
|
244
|
+
- [ ] File created at correct path
|
|
245
|
+
- [ ] Follows naming conventions from AGENTS.md
|
|
246
|
+
- [ ] All tests pass: `go test ./path/to/...`
|
|
247
|
+
- [ ] No linting errors: `golangci-lint run`
|
|
304
248
|
|
|
249
|
+
**Notes:** Additional hints, gotchas, or context
|
|
305
250
|
```
|
|
306
|
-
T1 ──┬──► T2 ──► T4
|
|
307
|
-
│ │
|
|
308
|
-
└──► T3 ────┴──► T5 ──► T6
|
|
309
|
-
```
|
|
310
251
|
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
252
|
+
### Why This Structure?
|
|
253
|
+
|
|
254
|
+
| Section | Purpose |
|
|
255
|
+
|---------|---------|
|
|
256
|
+
| **Goal** | Agent knows the "why" |
|
|
257
|
+
| **Documentation** | Agent can read all needed context |
|
|
258
|
+
| **Input** | Agent knows what must exist before starting |
|
|
259
|
+
| **Output** | Agent knows exactly what to create |
|
|
260
|
+
| **Implementation Steps** | Agent has step-by-step guidance |
|
|
261
|
+
| **Acceptance Criteria** | Agent can verify completion |
|
|
314
262
|
|
|
315
|
-
### Summary Table
|
|
263
|
+
### Tasks Summary Table
|
|
316
264
|
|
|
317
265
|
```markdown
|
|
318
|
-
| ID | Task |
|
|
319
|
-
|
|
320
|
-
| T1 |
|
|
321
|
-
| T2 | Repository
|
|
322
|
-
| T3 | Use
|
|
323
|
-
| T4 |
|
|
324
|
-
| T5 | HTTP
|
|
325
|
-
| T6 | Integration tests + refactor | 5h | T4, T5 | ⬜ |
|
|
266
|
+
| ID | Task | Deps | Status |
|
|
267
|
+
|----|------|------|--------|
|
|
268
|
+
| T1 | MerchantProduct Aggregate + Value Objects | - | ⬜ |
|
|
269
|
+
| T2 | Repository Interface | T1 | ⬜ |
|
|
270
|
+
| T3 | CreateProduct Use Case | T2 | ⬜ |
|
|
271
|
+
| T4 | PostgreSQL Repository Implementation | T2 | ⬜ |
|
|
272
|
+
| T5 | HTTP Handler + Routes | T3, T4 | ⬜ |
|
|
326
273
|
```
|
|
327
274
|
|
|
328
275
|
**Status:** ⬜ TODO | 🔄 IN_PROGRESS | ✅ DONE | ⏸️ BLOCKED
|
|
329
276
|
|
|
330
|
-
###
|
|
331
|
-
|
|
332
|
-
Group tasks by parallel execution opportunity:
|
|
277
|
+
### Dependency Graph (Optional)
|
|
333
278
|
|
|
334
|
-
```markdown
|
|
335
|
-
### Execution Order
|
|
336
|
-
|
|
337
|
-
Phase 1: T1 (no deps)
|
|
338
|
-
Phase 2: T2, T3 (parallel - both depend only on T1)
|
|
339
|
-
Phase 3: T4, T6 (parallel - independent branches)
|
|
340
|
-
Phase 4: T5 (waits for T3, T4)
|
|
341
|
-
Phase 5: T7 (waits for T5)
|
|
342
|
-
Phase 6: T8, T6-continued (parallel)
|
|
343
|
-
Phase 7: T9 (waits for T6, T8)
|
|
344
|
-
Phase 8: T10 (final)
|
|
345
|
-
|
|
346
|
-
**Critical Path:** T1 → T2 → T4 → T5 → T7 → T8 → T9 → T10
|
|
347
|
-
**Total Estimate:** 32h (4 days)
|
|
348
|
-
**Parallel Savings:** ~3h (25%)
|
|
349
279
|
```
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
```markdown
|
|
354
|
-
| ID | Task | Est | Depends On | Type |
|
|
355
|
-
|----|------|-----|------------|------|
|
|
356
|
-
| T1 | Domain layer: Product aggregate + value objects + tests | 6h | - | 🔴🟢 |
|
|
357
|
-
| T2 | Repository interface + CreateProduct use case tests | 5h | T1 | 🔴 |
|
|
358
|
-
| T3 | CreateProduct use case implementation | 5h | T2 | 🟢 |
|
|
359
|
-
| T4 | PostgreSQL repository implementation + tests | 6h | T2 | 🟢 |
|
|
360
|
-
| T5 | HTTP handler + tests | 5h | T3 | 🔴🟢 |
|
|
361
|
-
| T6 | Integration tests + refactor + documentation | 5h | T4, T5 | 🔵 |
|
|
362
|
-
|
|
363
|
-
**Graph:**
|
|
364
|
-
T1 ──► T2 ──┬──► T4 ──► T5 ──► T7 ──► T8 ──┬──► T9 ──► T10
|
|
365
|
-
│ │
|
|
366
|
-
T3 ─────────┴───────────► T6 ───────────────┘
|
|
280
|
+
T1 ──► T2 ──┬──► T3 ──┬──► T5
|
|
281
|
+
│ │
|
|
282
|
+
└──► T4 ──┘
|
|
367
283
|
```
|
|
368
284
|
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
If a task exceeds 6h, consider splitting it. **Each task MUST have validation test.**
|
|
372
|
-
|
|
373
|
-
| Original (8h+) | Split Into (with tests) |
|
|
374
|
-
|----------------|------------------------|
|
|
375
|
-
| "Full domain layer" (10h) | **T1:** Value objects + tests (4h)<br>**T2:** Aggregate + business rules + tests (6h) |
|
|
376
|
-
| "Full repository" (10h) | **T1:** Interface + Save/FindByID + tests (5h)<br>**T2:** List/Search + advanced queries + tests (5h) |
|
|
377
|
-
|
|
378
|
-
### Task Template with Validation
|
|
379
|
-
|
|
380
|
-
```markdown
|
|
381
|
-
### T{N}: {Task Name}
|
|
382
|
-
- **Estimate:** 5h
|
|
383
|
-
- **Depends on:** T{N-1}
|
|
384
|
-
- **Methodology:** TDD | STUB
|
|
385
|
-
- **Deliverables:**
|
|
386
|
-
- [ ] File: `path/to/implementation.go`
|
|
387
|
-
- [ ] File: `path/to/implementation2.go`
|
|
388
|
-
- **Validation Test:** `path/to/implementation_test.go`
|
|
389
|
-
- [ ] Test case 1: happy path
|
|
390
|
-
- [ ] Test case 2: error handling
|
|
391
|
-
- [ ] Test case 3: edge case
|
|
392
|
-
- [ ] **⚠️ ALL TESTS MUST PASS** ← MANDATORY
|
|
393
|
-
- **Notes:** Implementation hints
|
|
394
|
-
```
|
|
395
|
-
|
|
396
|
-
### Validation Test Requirements
|
|
397
|
-
|
|
398
|
-
**Every task MUST have:**
|
|
285
|
+
---
|
|
399
286
|
|
|
400
|
-
|
|
401
|
-
|-----------|----------|-------------|
|
|
402
|
-
| Happy path | ✅ Yes | Normal success case |
|
|
403
|
-
| Error handling | ✅ Yes | Expected failures |
|
|
404
|
-
| Edge cases | Recommended | Boundary conditions |
|
|
405
|
-
| **Pass gate** | ✅ MANDATORY | `⚠️ ALL TESTS MUST PASS` |
|
|
287
|
+
## Full Task Example
|
|
406
288
|
|
|
407
|
-
|
|
289
|
+
Here's a complete example of a self-contained task:
|
|
408
290
|
|
|
409
|
-
**TDD Example:**
|
|
410
291
|
```markdown
|
|
411
|
-
###
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
292
|
+
### T1: MerchantProduct Aggregate + Value Objects
|
|
293
|
+
|
|
294
|
+
**Goal:** Create the MerchantProduct aggregate with all value objects and domain validation.
|
|
295
|
+
|
|
296
|
+
**Documentation:**
|
|
297
|
+
- [AGENTS.md#type-safety](../../../AGENTS.md#type-safety) - Value object patterns
|
|
298
|
+
- [AGENTS.md#naming-conventions](../../../AGENTS.md#naming-conventions) - File/package naming
|
|
299
|
+
- [catalog-data-model.md#merchant_products](../docs/catalog-data-model.md#31-merchant-products) - Database schema
|
|
300
|
+
- [modules/catalog/domain/entity/marketplace_category.go](../src/services/catalog/modules/catalog/domain/entity/marketplace_category.go) - Example entity pattern
|
|
301
|
+
|
|
302
|
+
**Input (Prerequisites):**
|
|
303
|
+
- None (first task in story)
|
|
304
|
+
- Existing patterns in `modules/catalog/domain/` to follow
|
|
305
|
+
|
|
306
|
+
**Output (Deliverables):**
|
|
307
|
+
- `modules/catalog/domain/valueobject/merchant_id.go` - UUID wrapper with validation
|
|
308
|
+
- `modules/catalog/domain/valueobject/product_id.go` - UUID wrapper
|
|
309
|
+
- `modules/catalog/domain/valueobject/merchant_sku.go` - String with max length validation
|
|
310
|
+
- `modules/catalog/domain/valueobject/ean.go` - GTIN-13 checksum validation
|
|
311
|
+
- `modules/catalog/domain/valueobject/product_status.go` - Enum (pending, active, etc.)
|
|
312
|
+
- `modules/catalog/domain/entity/merchant_product.go` - Aggregate with private fields + getters
|
|
313
|
+
- `modules/catalog/domain/entity/merchant_product_test.go` - All tests
|
|
314
|
+
|
|
315
|
+
**Implementation Steps:**
|
|
316
|
+
1. Read AGENTS.md sections on value objects and naming
|
|
317
|
+
2. Look at existing `marketplace_category.go` for entity pattern
|
|
318
|
+
3. Create value objects with `New*()` factory functions that validate
|
|
319
|
+
4. Create aggregate with private fields, public getters, factory method
|
|
320
|
+
5. Write tests: creation happy path, validation errors, status transitions
|
|
321
|
+
6. Run `go test ./modules/catalog/domain/...`
|
|
322
|
+
|
|
323
|
+
**Acceptance Criteria:**
|
|
324
|
+
- [ ] All files created at correct paths
|
|
325
|
+
- [ ] Value objects validate on construction (not setters)
|
|
326
|
+
- [ ] EAN validates GTIN-13 checksum
|
|
327
|
+
- [ ] Aggregate uses private fields with getters
|
|
328
|
+
- [ ] Tests cover: valid creation, invalid data rejection, status transitions
|
|
329
|
+
- [ ] `go test ./modules/catalog/domain/...` passes
|
|
330
|
+
- [ ] `golangci-lint run ./modules/catalog/domain/...` passes
|
|
331
|
+
|
|
332
|
+
**Notes:**
|
|
333
|
+
- EAN checksum algorithm: sum odd positions × 1, even × 3, check digit makes sum divisible by 10
|
|
334
|
+
- Status enum values from PRD: pending, pending_category, pending_dedup, pending_pim, active, declined
|
|
335
|
+
```
|
|
336
|
+
|
|
337
|
+
### What Makes This Task Self-Contained?
|
|
338
|
+
|
|
339
|
+
1. **Agent can start immediately** - all documentation links provided
|
|
340
|
+
2. **No guessing** - exact file paths specified
|
|
341
|
+
3. **Pattern to follow** - links to existing code examples
|
|
342
|
+
4. **Clear verification** - specific test commands and criteria
|
|
343
|
+
5. **Context included** - notes explain non-obvious details (EAN algorithm)
|
|
435
344
|
|
|
436
345
|
## Definition of Done
|
|
437
346
|
|
|
@@ -610,13 +519,11 @@ Add to each story:
|
|
|
610
519
|
|
|
611
520
|
Before completing story:
|
|
612
521
|
- [ ] Story ID is unique
|
|
613
|
-
- [ ]
|
|
614
|
-
- [ ]
|
|
615
|
-
- [ ]
|
|
616
|
-
- [ ]
|
|
617
|
-
- [ ] **TODO placeholders defined for future work**
|
|
522
|
+
- [ ] Goal is clear (1-2 sentences)
|
|
523
|
+
- [ ] Acceptance criteria as checklist (what "done" looks like)
|
|
524
|
+
- [ ] Tasks are self-contained with documentation links
|
|
525
|
+
- [ ] Each task has: Goal, Documentation, Input, Output, Steps, AC
|
|
618
526
|
- [ ] Definition of Done is complete
|
|
619
|
-
- [ ] Estimate is reasonable
|
|
620
527
|
- [ ] Links to epic are correct
|
|
621
528
|
|
|
622
529
|
## Output
|
|
@@ -84,8 +84,8 @@ S01 ──► S02 ──► S03 ──► S04
|
|
|
84
84
|
### Story Decomposition Rules
|
|
85
85
|
|
|
86
86
|
Each story MUST:
|
|
87
|
-
1. Be completable
|
|
88
|
-
2. Have
|
|
87
|
+
1. Be completable (not too big, not too small)
|
|
88
|
+
2. Have self-contained tasks with documentation links
|
|
89
89
|
3. Have clear dependencies on other stories
|
|
90
90
|
4. Map to specific Acceptance Criteria
|
|
91
91
|
|
|
@@ -99,15 +99,17 @@ Each story MUST:
|
|
|
99
99
|
6. **Events** - Domain events, Kafka publishers
|
|
100
100
|
7. **Integration Tests** - End-to-end verification
|
|
101
101
|
|
|
102
|
-
###
|
|
102
|
+
### Stories by Layer
|
|
103
103
|
|
|
104
|
-
| Layer | Stories | Tasks |
|
|
105
|
-
|
|
106
|
-
| Domain | 1 | 4 |
|
|
107
|
-
| Application |
|
|
108
|
-
| Infrastructure | 2 | 5 |
|
|
109
|
-
| Testing | 1 | 3 |
|
|
110
|
-
| **Total** | **
|
|
104
|
+
| Layer | Stories | Tasks | Size |
|
|
105
|
+
|-------|---------|-------|------|
|
|
106
|
+
| Domain | 1 | 4 | M |
|
|
107
|
+
| Application | 2 | 6 | M |
|
|
108
|
+
| Infrastructure | 2 | 5 | L |
|
|
109
|
+
| Testing | 1 | 3 | S |
|
|
110
|
+
| **Total** | **6** | **18** | |
|
|
111
|
+
|
|
112
|
+
**Note:** No hour estimates. Size = relative complexity (XS/S/M/L/XL).
|
|
111
113
|
|
|
112
114
|
---
|
|
113
115
|
|
|
@@ -8,436 +8,170 @@ workflowType: 'story'
|
|
|
8
8
|
|
|
9
9
|
**Story ID:** {{module}}-S{{epic_number}}-{{story_number}}
|
|
10
10
|
**Epic:** {{module}}-E{{epic_number}} - {{epic_title}}
|
|
11
|
-
**Status:** draft | ready-for-dev | in-progress | review | done
|
|
12
|
-
**
|
|
13
|
-
**Estimate:** XS | S | M | L | XL
|
|
14
|
-
**Created:** {{date}}
|
|
15
|
-
**Last Updated:** {{date}}
|
|
11
|
+
**Status:** draft | ready-for-dev | in-progress | review | done
|
|
12
|
+
**Size:** XS | S | M | L | XL
|
|
16
13
|
|
|
17
14
|
---
|
|
18
15
|
|
|
19
|
-
##
|
|
16
|
+
## Prerequisites (PM reads before writing tasks)
|
|
20
17
|
|
|
21
|
-
|
|
22
|
-
**I want** {{capability}},
|
|
23
|
-
**So that** {{benefit}}.
|
|
18
|
+
<!-- ⚠️ MANDATORY: Read these docs before writing tasks! -->
|
|
24
19
|
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
### AC1: {{criterion_name}}
|
|
30
|
-
|
|
31
|
-
**Given** {{precondition}}
|
|
32
|
-
**When** {{action}}
|
|
33
|
-
**Then** {{expected_result}}
|
|
34
|
-
**And** {{additional_check}}
|
|
35
|
-
|
|
36
|
-
### AC2: {{criterion_name}}
|
|
37
|
-
|
|
38
|
-
**Given** {{precondition}}
|
|
39
|
-
**When** {{action}}
|
|
40
|
-
**Then** {{expected_result}}
|
|
41
|
-
|
|
42
|
-
### AC3: {{criterion_name}}
|
|
43
|
-
|
|
44
|
-
**Given** {{precondition}}
|
|
45
|
-
**When** {{action}}
|
|
46
|
-
**Then** {{expected_result}}
|
|
20
|
+
- [ ] `AGENTS.md` / `CLAUDE.md` - coding patterns, naming, error handling
|
|
21
|
+
- [ ] `docs/coding-standards/` - detailed coding standards
|
|
22
|
+
- [ ] `docs/architecture/{{module}}/` - module architecture, data model
|
|
23
|
+
- [ ] Existing code in `src/services/{{module}}/` - patterns to follow
|
|
47
24
|
|
|
48
25
|
---
|
|
49
26
|
|
|
50
|
-
##
|
|
51
|
-
|
|
52
|
-
<!--
|
|
53
|
-
METHODOLOGY: {{methodology}} (tdd | stub)
|
|
54
|
-
- TDD: Interface → Test (failing) → Implementation → Refactor
|
|
55
|
-
- STUB: Interface → Stub → Test → Full Implementation
|
|
56
|
-
|
|
57
|
-
RULES:
|
|
58
|
-
- Each task is 4-6 hours of focused work
|
|
59
|
-
- Each task includes TEST as validation gate
|
|
60
|
-
- Tasks have explicit dependencies
|
|
61
|
-
- Dev agent respects dependency order
|
|
62
|
-
-->
|
|
63
|
-
|
|
64
|
-
### Development Methodology: **{{methodology}}**
|
|
27
|
+
## Goal
|
|
65
28
|
|
|
66
|
-
|
|
67
|
-
{{#if methodology == "tdd"}}
|
|
68
|
-
TDD Flow per Task:
|
|
69
|
-
1. Define Interface/Contract
|
|
70
|
-
2. Write Failing Test (RED)
|
|
71
|
-
3. Implement Minimal Code (GREEN)
|
|
72
|
-
4. Refactor
|
|
73
|
-
5. Validate: Test MUST pass
|
|
74
|
-
{{/if}}
|
|
75
|
-
{{#if methodology == "stub"}}
|
|
76
|
-
STUB Flow per Task:
|
|
77
|
-
1. Define Interface/Contract
|
|
78
|
-
2. Write Stub Implementation (returns mock data)
|
|
79
|
-
3. Write Tests against Stub
|
|
80
|
-
4. Replace Stub with Real Implementation
|
|
81
|
-
5. Validate: Test MUST pass
|
|
82
|
-
{{/if}}
|
|
83
|
-
```
|
|
29
|
+
{{Short description - 1-2 sentences. What this story achieves. Same as in epic's stories table.}}
|
|
84
30
|
|
|
85
31
|
---
|
|
86
32
|
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
```
|
|
90
|
-
T1 ──┬──► T2 ──► T3
|
|
91
|
-
│
|
|
92
|
-
└──► T4 ──► T5
|
|
93
|
-
│
|
|
94
|
-
T3 ───────────────┴──► T6
|
|
95
|
-
```
|
|
96
|
-
|
|
97
|
-
### Tasks Summary
|
|
98
|
-
|
|
99
|
-
| ID | Task | Est | Deps | Test | Status |
|
|
100
|
-
|----|------|-----|------|------|--------|
|
|
101
|
-
| T1 | {{task_1}} | 5h | - | unit | ⬜ |
|
|
102
|
-
| T2 | {{task_2}} | 6h | T1 | unit | ⬜ |
|
|
103
|
-
| T3 | {{task_3}} | 5h | T2 | unit | ⬜ |
|
|
104
|
-
| T4 | {{task_4}} | 5h | T1 | unit | ⬜ |
|
|
105
|
-
| T5 | {{task_5}} | 5h | T3,T4 | integration | ⬜ |
|
|
33
|
+
## Acceptance Criteria
|
|
106
34
|
|
|
107
|
-
|
|
35
|
+
- [ ] {{criterion_1}}
|
|
36
|
+
- [ ] {{criterion_2}}
|
|
37
|
+
- [ ] {{criterion_3}}
|
|
38
|
+
- [ ] All tests pass
|
|
39
|
+
- [ ] No linting errors
|
|
108
40
|
|
|
109
41
|
---
|
|
110
42
|
|
|
111
|
-
|
|
112
|
-
- **Estimate:** 6h
|
|
113
|
-
- **Depends on:** -
|
|
114
|
-
- **Blocks:** T2
|
|
115
|
-
- **Deliverables:**
|
|
116
|
-
- [ ] Interface/contract defined
|
|
117
|
-
- [ ] Value objects with validation
|
|
118
|
-
- [ ] Aggregate with business rules
|
|
119
|
-
- [ ] Factory methods
|
|
120
|
-
- **Validation Test:**
|
|
121
|
-
- [ ] Value object tests (validation, equality)
|
|
122
|
-
- [ ] Aggregate creation tests
|
|
123
|
-
- [ ] Business rules tests
|
|
124
|
-
- [ ] **⚠️ ALL TESTS MUST PASS**
|
|
125
|
-
- **Notes:** {{implementation_hint}}
|
|
43
|
+
## Tasks
|
|
126
44
|
|
|
127
|
-
|
|
45
|
+
| ID | Task | Deps | Status |
|
|
46
|
+
|----|------|------|--------|
|
|
47
|
+
| T1 | {{task_1_name}} | - | ⬜ |
|
|
48
|
+
| T2 | {{task_2_name}} | T1 | ⬜ |
|
|
49
|
+
| T3 | {{task_3_name}} | T2 | ⬜ |
|
|
128
50
|
|
|
129
|
-
|
|
130
|
-
- **Estimate:** 5h
|
|
131
|
-
- **Depends on:** T1
|
|
132
|
-
- **Blocks:** T3, T4
|
|
133
|
-
- **Deliverables:**
|
|
134
|
-
- [ ] Repository interface (ports)
|
|
135
|
-
- [ ] Use case interface
|
|
136
|
-
- [ ] Use case DTOs (input/output)
|
|
137
|
-
- [ ] Use case tests (with mock repository)
|
|
138
|
-
- **Validation Test:**
|
|
139
|
-
- [ ] Use case happy path test
|
|
140
|
-
- [ ] Use case error handling tests
|
|
141
|
-
- [ ] **⚠️ ALL TESTS MUST PASS**
|
|
142
|
-
- **Notes:** {{implementation_hint}}
|
|
51
|
+
**Status:** ⬜ TODO | 🔄 IN_PROGRESS | ✅ DONE | ⏸️ BLOCKED
|
|
143
52
|
|
|
144
53
|
---
|
|
145
54
|
|
|
146
|
-
###
|
|
147
|
-
- **Estimate:** 5h
|
|
148
|
-
- **Depends on:** T2
|
|
149
|
-
- **Blocks:** T5
|
|
150
|
-
- **Deliverables:**
|
|
151
|
-
- [ ] Use case handler implementation
|
|
152
|
-
- [ ] Mappers (entity ↔ DTO)
|
|
153
|
-
- [ ] Error handling
|
|
154
|
-
- **Validation Test:**
|
|
155
|
-
- [ ] All use case tests pass
|
|
156
|
-
- [ ] Edge cases covered
|
|
157
|
-
- [ ] **⚠️ ALL TESTS MUST PASS**
|
|
158
|
-
- **Notes:** {{implementation_hint}}
|
|
159
|
-
|
|
160
|
-
---
|
|
55
|
+
### T1: {{task_1_name}}
|
|
161
56
|
|
|
162
|
-
|
|
163
|
-
- **Estimate:** 6h
|
|
164
|
-
- **Depends on:** T2
|
|
165
|
-
- **Blocks:** T5
|
|
166
|
-
- **Deliverables (TDD):**
|
|
167
|
-
- [ ] Write repository tests first
|
|
168
|
-
- [ ] PostgreSQL repository implementation
|
|
169
|
-
- **Deliverables (STUB):**
|
|
170
|
-
- [ ] In-memory stub first
|
|
171
|
-
- [ ] PostgreSQL implementation
|
|
172
|
-
- **Validation Test:**
|
|
173
|
-
- [ ] Test Save
|
|
174
|
-
- [ ] Test FindByID (found/not found)
|
|
175
|
-
- [ ] Test List with filters
|
|
176
|
-
- [ ] **⚠️ ALL TESTS MUST PASS**
|
|
177
|
-
- **Notes:** {{implementation_hint}}
|
|
57
|
+
**Goal:** {{what_this_task_achieves}}
|
|
178
58
|
|
|
179
|
-
|
|
59
|
+
**Documentation:**
|
|
60
|
+
- [AGENTS.md#section](../../../AGENTS.md#section) - {{what_pattern}}
|
|
61
|
+
- [data-model.md#table](../../../docs/data-model.md#section) - {{schema_info}}
|
|
62
|
+
- [existing_example.go](../path/to/example.go) - Pattern to follow
|
|
180
63
|
|
|
181
|
-
|
|
182
|
-
-
|
|
183
|
-
-
|
|
184
|
-
- **Blocks:** -
|
|
185
|
-
- **Deliverables:**
|
|
186
|
-
- [ ] HTTP handler/controller
|
|
187
|
-
- [ ] Routes registered
|
|
188
|
-
- [ ] Request/response validation
|
|
189
|
-
- [ ] Integration tests
|
|
190
|
-
- [ ] Documentation updated
|
|
191
|
-
- **Validation Test:**
|
|
192
|
-
- [ ] Test 201 Created
|
|
193
|
-
- [ ] Test 400 Bad Request (validation)
|
|
194
|
-
- [ ] Test 404 Not Found
|
|
195
|
-
- [ ] E2E: API → Service → Repo → DB
|
|
196
|
-
- [ ] **⚠️ ALL TESTS MUST PASS**
|
|
197
|
-
- [ ] **⚠️ NO REGRESSIONS**
|
|
198
|
-
- **Notes:** {{implementation_hint}}
|
|
64
|
+
**Input (Prerequisites):**
|
|
65
|
+
- {{what_must_exist_before_starting}}
|
|
66
|
+
- Existing file: `path/to/dependency.go` - provides {{what}}
|
|
199
67
|
|
|
200
|
-
|
|
68
|
+
**Output (Deliverables):**
|
|
69
|
+
- `path/to/new_file.go` - {{description}}
|
|
70
|
+
- `path/to/new_file_test.go` - Tests for {{what}}
|
|
201
71
|
|
|
202
|
-
|
|
72
|
+
**Implementation Steps:**
|
|
73
|
+
1. Read documentation links above
|
|
74
|
+
2. {{step_2}}
|
|
75
|
+
3. {{step_3}}
|
|
76
|
+
4. Write tests covering: happy path, errors, edge cases
|
|
77
|
+
5. Run: `go test ./path/to/...`
|
|
203
78
|
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
| 4 | T5 | 5h | Integration tests |
|
|
210
|
-
| **Total** | | **22h** | **All green** |
|
|
79
|
+
**Acceptance Criteria:**
|
|
80
|
+
- [ ] Files created at specified paths
|
|
81
|
+
- [ ] Follows patterns from AGENTS.md
|
|
82
|
+
- [ ] Tests pass: `go test ./path/to/...`
|
|
83
|
+
- [ ] Lint passes: `golangci-lint run`
|
|
211
84
|
|
|
212
|
-
**
|
|
213
|
-
**With Parallelism (T3 || T4):** ~2.5 days
|
|
85
|
+
**Notes:** {{additional_context_or_gotchas}}
|
|
214
86
|
|
|
215
87
|
---
|
|
216
88
|
|
|
217
|
-
|
|
89
|
+
### T2: {{task_2_name}}
|
|
218
90
|
|
|
219
|
-
|
|
220
|
-
When implementing, leave TODO comments for:
|
|
221
|
-
- Next tasks in this story
|
|
222
|
-
- Future stories/epics
|
|
223
|
-
- Technical debt
|
|
224
|
-
- Planned improvements
|
|
225
|
-
|
|
226
|
-
Format: TODO({TYPE}:{ID}): {description}
|
|
227
|
-
-->
|
|
91
|
+
**Goal:** {{what_this_task_achieves}}
|
|
228
92
|
|
|
229
|
-
|
|
93
|
+
**Documentation:**
|
|
94
|
+
- [AGENTS.md#section](link) - {{pattern}}
|
|
95
|
+
- [T1 output](../path/from/T1) - Uses types from T1
|
|
230
96
|
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
| `src/application/{{usecase}}` | Add caching | STORY | S{{epic}}-04 |
|
|
235
|
-
| `src/infrastructure/repo/` | Add batch operations | EPIC | E{{next_epic}} |
|
|
236
|
-
| `src/api/` | Add rate limiting | BACKLOG | - |
|
|
97
|
+
**Input (Prerequisites):**
|
|
98
|
+
- T1 completed
|
|
99
|
+
- Files from T1: `path/to/aggregate.go`
|
|
237
100
|
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
// TODO(TASK:T3): Implement validation logic here
|
|
242
|
-
// Called from: T2 implementation
|
|
243
|
-
// Blocked until: T3 starts
|
|
244
|
-
|
|
245
|
-
// TODO(STORY:{{module}}-S05-04): Add pagination support
|
|
246
|
-
// This story implements basic list, pagination in next story
|
|
247
|
-
// See: docs/sprint-artifacts/sprint-1/stories/story-05-04.md
|
|
248
|
-
|
|
249
|
-
// TODO(EPIC:{{module}}-E06): Replace with event-driven approach
|
|
250
|
-
// Current sync implementation, async in Epic 6
|
|
251
|
-
// See: docs/sprint-artifacts/backlog/epic-06.md
|
|
252
|
-
|
|
253
|
-
// TODO(SPRINT:SP3): Performance optimization needed
|
|
254
|
-
// Current O(n²), optimize in Sprint 3
|
|
255
|
-
|
|
256
|
-
// TODO(BACKLOG): Consider adding retry logic
|
|
257
|
-
// Not planned yet, but would improve reliability
|
|
258
|
-
|
|
259
|
-
// TODO(TECH_DEBT): Refactor this duplication
|
|
260
|
-
// Copy-pasted from X, extract common logic
|
|
261
|
-
|
|
262
|
-
// FIXME(BUG:GH-123): Fix null pointer exception
|
|
263
|
-
// Occurs when input is empty
|
|
264
|
-
// Ticket: https://github.com/org/repo/issues/123
|
|
265
|
-
|
|
266
|
-
// HACK: Temporary workaround for API limitation
|
|
267
|
-
// Remove when: STORY:{{module}}-S05-08 implemented
|
|
268
|
-
```
|
|
101
|
+
**Output (Deliverables):**
|
|
102
|
+
- `path/to/file.go` - {{description}}
|
|
103
|
+
- `path/to/file_test.go` - Tests
|
|
269
104
|
|
|
270
|
-
**
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
\bTODO\(.*\):.*
|
|
274
|
-
\bFIXME\(.*\):.*
|
|
275
|
-
\bHACK:.*
|
|
276
|
-
```
|
|
105
|
+
**Implementation Steps:**
|
|
106
|
+
1. {{step}}
|
|
107
|
+
2. {{step}}
|
|
277
108
|
|
|
278
|
-
|
|
109
|
+
**Acceptance Criteria:**
|
|
110
|
+
- [ ] {{criterion}}
|
|
111
|
+
- [ ] Tests pass
|
|
279
112
|
|
|
280
|
-
|
|
281
|
-
|----|------|-------------|--------------|
|
|
282
|
-
| T3 | Task | Validation logic | No |
|
|
283
|
-
| S{{epic}}-04 | Story | Pagination | No |
|
|
284
|
-
| E{{next_epic}} | Epic | Event-driven | No |
|
|
113
|
+
**Notes:** {{notes}}
|
|
285
114
|
|
|
286
115
|
---
|
|
287
116
|
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
<!-- Context for the developer implementing this story -->
|
|
291
|
-
|
|
292
|
-
### Coding Standards Applied (MANDATORY)
|
|
293
|
-
|
|
294
|
-
**Standards documents used for this story:**
|
|
295
|
-
- [ ] `CLAUDE.md` - Project patterns, file structure, conventions
|
|
296
|
-
- [ ] `docs/coding-standards/` - Detailed coding standards
|
|
297
|
-
- [ ] Naming conventions
|
|
298
|
-
- [ ] Error handling patterns
|
|
299
|
-
- [ ] Testing patterns
|
|
300
|
-
- [ ] `docs/architecture/{{module}}/architecture.md` - Module-specific patterns
|
|
301
|
-
|
|
302
|
-
**Key patterns from CLAUDE.md:**
|
|
303
|
-
- File naming: `{{file_naming_pattern}}`
|
|
304
|
-
- Package structure: `{{package_structure}}`
|
|
305
|
-
- Error handling: `{{error_handling_pattern}}`
|
|
306
|
-
- Test file naming: `{{test_naming_pattern}}`
|
|
307
|
-
|
|
308
|
-
### Architecture Requirements
|
|
309
|
-
- Follow hexagonal architecture patterns
|
|
310
|
-
- Domain layer must not import infrastructure
|
|
311
|
-
- Use value objects for domain concepts
|
|
312
|
-
|
|
313
|
-
### Technical Specifications
|
|
314
|
-
- {{technical_specs}}
|
|
315
|
-
|
|
316
|
-
### Dependencies
|
|
317
|
-
- Depends on: {{dependencies}}
|
|
318
|
-
- Blocked by: {{blockers}}
|
|
319
|
-
|
|
320
|
-
### Previous Learnings
|
|
321
|
-
- {{learnings_from_similar_work}}
|
|
117
|
+
### T3: {{task_3_name}}
|
|
322
118
|
|
|
323
|
-
|
|
324
|
-
- `src/path/to/related/file` - [why relevant]
|
|
325
|
-
- `docs/architecture.md#section` - [architecture guidance]
|
|
326
|
-
- `CLAUDE.md#section` - [coding patterns]
|
|
119
|
+
**Goal:** {{goal}}
|
|
327
120
|
|
|
328
|
-
|
|
329
|
-
-
|
|
330
|
-
- **MANDATORY:** Follow `docs/coding-standards/`
|
|
331
|
-
- Match existing code style in module
|
|
121
|
+
**Documentation:**
|
|
122
|
+
- {{links}}
|
|
332
123
|
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
// (language-specific syntax)
|
|
337
|
-
```
|
|
124
|
+
**Input (Prerequisites):**
|
|
125
|
+
- T2 completed
|
|
126
|
+
- {{dependencies}}
|
|
338
127
|
|
|
339
|
-
|
|
128
|
+
**Output (Deliverables):**
|
|
129
|
+
- {{files}}
|
|
340
130
|
|
|
341
|
-
|
|
131
|
+
**Implementation Steps:**
|
|
132
|
+
1. {{steps}}
|
|
342
133
|
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
134
|
+
**Acceptance Criteria:**
|
|
135
|
+
- [ ] {{criteria}}
|
|
136
|
+
- [ ] All tests pass
|
|
137
|
+
- [ ] **⚠️ NO REGRESSIONS** (run full test suite)
|
|
347
138
|
|
|
348
|
-
|
|
349
|
-
1. {{integration_scenario_1}}
|
|
350
|
-
2. {{integration_scenario_2}}
|
|
139
|
+
**Notes:** {{notes}}
|
|
351
140
|
|
|
352
141
|
---
|
|
353
142
|
|
|
354
|
-
##
|
|
355
|
-
|
|
356
|
-
<!-- Automatically updated by Dev agent during implementation -->
|
|
357
|
-
|
|
358
|
-
### Implementation Plan
|
|
359
|
-
<!-- Dev agent documents approach here -->
|
|
143
|
+
## Notes
|
|
360
144
|
|
|
361
|
-
|
|
362
|
-
<!-- Dev agent logs debugging notes here -->
|
|
363
|
-
|
|
364
|
-
### Completion Notes
|
|
365
|
-
<!-- Dev agent summarizes what was implemented -->
|
|
145
|
+
<!-- Optional: additional context, learnings, blockers -->
|
|
366
146
|
|
|
367
147
|
---
|
|
368
148
|
|
|
369
|
-
##
|
|
370
|
-
|
|
371
|
-
<!-- Dev agent updates with all changed files -->
|
|
372
|
-
|
|
373
|
-
### Created Files
|
|
374
|
-
-
|
|
375
|
-
|
|
376
|
-
### Modified Files
|
|
377
|
-
-
|
|
149
|
+
## Definition of Done
|
|
378
150
|
|
|
379
|
-
|
|
380
|
-
-
|
|
151
|
+
- [ ] All acceptance criteria met
|
|
152
|
+
- [ ] All tasks completed
|
|
153
|
+
- [ ] Tests passing (>80% coverage)
|
|
154
|
+
- [ ] Code follows AGENTS.md patterns
|
|
155
|
+
- [ ] No linting errors
|
|
156
|
+
- [ ] PR merged to epic branch
|
|
381
157
|
|
|
382
158
|
---
|
|
383
159
|
|
|
384
160
|
## Changelog
|
|
385
161
|
|
|
386
|
-
<!-- UPDATE AT END OF SESSION -->
|
|
387
|
-
|
|
388
162
|
| Version | Date | Author | Changes |
|
|
389
163
|
|---------|------|--------|---------|
|
|
390
|
-
| 0.1 | {{date}} | @
|
|
164
|
+
| 0.1 | {{date}} | @pm | Story created |
|
|
391
165
|
|
|
392
166
|
<!--
|
|
393
167
|
Changelog Guidelines:
|
|
394
168
|
- Update at END of work session
|
|
395
169
|
- Dev: summarize what was implemented
|
|
396
170
|
- Version: 0.x=draft, 1.0=ready-for-dev, 1.x=in-progress, 2.0=done
|
|
397
|
-
|
|
398
|
-
Example session entries:
|
|
399
|
-
| 2.0 | 2024-01-25 | @dev | Complete: T1-T7 done; All tests pass; Ready for review |
|
|
400
|
-
| 1.1 | 2024-01-23 | @dev | Progress: T1-T4 complete; T5 blocked by API issue |
|
|
401
|
-
| 1.0 | 2024-01-20 | @sm | Ready for dev: 7 tasks defined; AC reviewed |
|
|
402
171
|
-->
|
|
403
172
|
|
|
404
173
|
---
|
|
405
174
|
|
|
406
|
-
## Definition of Done
|
|
407
|
-
|
|
408
|
-
- [ ] All acceptance criteria implemented and verified
|
|
409
|
-
- [ ] All tasks/subtasks marked complete [x]
|
|
410
|
-
- [ ] Unit tests written and passing (>80% coverage)
|
|
411
|
-
- [ ] Integration tests written and passing
|
|
412
|
-
- [ ] Code follows CLAUDE.md patterns
|
|
413
|
-
- [ ] Code reviewed and approved
|
|
414
|
-
- [ ] No linting errors
|
|
415
|
-
- [ ] No failing tests (full suite)
|
|
416
|
-
- [ ] File List complete
|
|
417
|
-
- [ ] Change Log updated
|
|
418
|
-
- [ ] PR merged to epic branch
|
|
419
|
-
|
|
420
|
-
---
|
|
421
|
-
|
|
422
|
-
## Senior Developer Review (AI)
|
|
423
|
-
|
|
424
|
-
<!-- Added after code-review workflow runs -->
|
|
425
|
-
|
|
426
|
-
### Review Date
|
|
427
|
-
<!-- Date of review -->
|
|
428
|
-
|
|
429
|
-
### Review Outcome
|
|
430
|
-
<!-- Approve | Changes Requested | Blocked -->
|
|
431
|
-
|
|
432
|
-
### Action Items
|
|
433
|
-
- [ ] {{action_item_1}}
|
|
434
|
-
- [ ] {{action_item_2}}
|
|
435
|
-
|
|
436
|
-
### Review Follow-ups (AI)
|
|
437
|
-
<!-- Tasks added based on review findings -->
|
|
438
|
-
|
|
439
|
-
---
|
|
440
|
-
|
|
441
175
|
## Jira Metadata
|
|
442
176
|
|
|
443
177
|
```yaml
|