@intentsolutionsio/sprint 1.0.0 → 1.0.6
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/README.md +11 -1
- package/agents/allpurpose-agent.md +39 -3
- package/agents/cicd-agent.md +32 -3
- package/agents/nextjs-dev.md +33 -2
- package/agents/nextjs-diagnostics-agent.md +41 -3
- package/agents/project-architect.md +54 -3
- package/agents/python-dev.md +37 -3
- package/agents/qa-test-agent.md +31 -3
- package/agents/ui-test-agent.md +47 -3
- package/agents/website-designer.md +36 -3
- package/commands/clean.md +8 -0
- package/commands/generate-map.md +5 -0
- package/commands/new.md +7 -0
- package/commands/setup.md +19 -0
- package/commands/sprint.md +38 -16
- package/commands/test.md +13 -2
- package/package.json +1 -1
- package/skills/agent-patterns/SKILL.md +18 -5
- package/skills/agent-patterns/references/examples.md +17 -0
- package/skills/agent-patterns/references/ui-test-report.md +8 -1
- package/skills/api-contract/SKILL.md +16 -5
- package/skills/api-contract/references/best-practices.md +3 -1
- package/skills/api-contract/references/errors.md +1 -1
- package/skills/api-contract/references/examples.md +16 -1
- package/skills/api-contract/references/pagination.md +2 -1
- package/skills/api-contract/references/typescript-interfaces.md +2 -1
- package/skills/api-contract/references/writing-endpoints.md +4 -1
- package/skills/spec-writing/SKILL.md +14 -5
- package/skills/spec-writing/references/examples.md +7 -0
- package/skills/spec-writing/references/testing-configuration.md +6 -1
- package/skills/sprint-workflow/SKILL.md +16 -5
- package/skills/sprint-workflow/references/examples.md +17 -0
- package/skills/sprint-workflow/references/sprint-phases.md +7 -1
package/commands/sprint.md
CHANGED
|
@@ -24,6 +24,7 @@ PHASE 5 - Finalization
|
|
|
24
24
|
## Step 1: Locate Sprint and Determine State
|
|
25
25
|
|
|
26
26
|
Find the highest sprint index in the current project:
|
|
27
|
+
|
|
27
28
|
```bash
|
|
28
29
|
ls -d .claude/sprint/*/ 2>/dev/null | sort -V | tail -1
|
|
29
30
|
```
|
|
@@ -31,6 +32,7 @@ ls -d .claude/sprint/*/ 2>/dev/null | sort -V | tail -1
|
|
|
31
32
|
The result should be something like `.claude/sprint/3/` - this is your **sprint directory**.
|
|
32
33
|
|
|
33
34
|
Check what files exist:
|
|
35
|
+
|
|
34
36
|
```bash
|
|
35
37
|
test -f .claude/sprint/[N]/specs.md && echo "SPECS_EXISTS"
|
|
36
38
|
test -f .claude/sprint/[N]/status.md && echo "STATUS_EXISTS"
|
|
@@ -40,9 +42,11 @@ test -f .claude/sprint/[N]/manual-test-report.md && echo "MANUAL_REPORT_EXISTS"
|
|
|
40
42
|
### Case A: No sprint directory exists
|
|
41
43
|
|
|
42
44
|
Tell the user:
|
|
45
|
+
|
|
43
46
|
```
|
|
44
47
|
No sprint found. Create one first with /sprint:new
|
|
45
48
|
```
|
|
49
|
+
|
|
46
50
|
Stop here.
|
|
47
51
|
|
|
48
52
|
### Case B: specs.md exists but no status.md (Fresh sprint)
|
|
@@ -56,6 +60,7 @@ Read the status.md to understand current state. Then **ask the user what they wa
|
|
|
56
60
|
**If status.md indicates sprint is COMPLETE/DONE:**
|
|
57
61
|
|
|
58
62
|
Use AskUserQuestion tool:
|
|
63
|
+
|
|
59
64
|
```
|
|
60
65
|
Sprint [N] appears to be complete.
|
|
61
66
|
|
|
@@ -72,6 +77,7 @@ Options:
|
|
|
72
77
|
**If status.md indicates sprint is IN PROGRESS:**
|
|
73
78
|
|
|
74
79
|
Check for manual-test-report.md:
|
|
80
|
+
|
|
75
81
|
- If exists: Proceed to Step 2 (will use the report to inform architect)
|
|
76
82
|
- If not exists: Ask user:
|
|
77
83
|
|
|
@@ -95,6 +101,7 @@ ls .claude/sprint/[N]/*-report*.md 2>/dev/null
|
|
|
95
101
|
```
|
|
96
102
|
|
|
97
103
|
This includes:
|
|
104
|
+
|
|
98
105
|
- `manual-test-report.md` - From `/sprint:test` command (user observations)
|
|
99
106
|
- `backend-report-*.md` - From previous implementation iterations
|
|
100
107
|
- `frontend-report-*.md` - From previous implementation iterations
|
|
@@ -165,11 +172,13 @@ Initialize:
|
|
|
165
172
|
stage = "architecture"
|
|
166
173
|
|
|
167
174
|
Repeat the sprint cycle until:
|
|
175
|
+
|
|
168
176
|
- Architect completes Phase 5
|
|
169
177
|
|
|
170
178
|
You can now proceed to Phase 1 - Architect Planning
|
|
171
179
|
|
|
172
180
|
# PHASE 1 - Architect Planning
|
|
181
|
+
|
|
173
182
|
(stage = "architecture")
|
|
174
183
|
|
|
175
184
|
Increment iteration counter by 1.
|
|
@@ -193,17 +202,19 @@ Wait for the architect response.
|
|
|
193
202
|
stage = "implementation"
|
|
194
203
|
- Move to PHASE 2.
|
|
195
204
|
|
|
196
|
-
|
|
205
|
+
1. If the architect requests `qa-test-agent` or `ui-test-agent`:
|
|
206
|
+
|
|
197
207
|
- This means the architect believes implementation is ready for testing.
|
|
198
208
|
- Set:
|
|
199
209
|
stage = "qa"
|
|
200
210
|
- Move to PHASE 3.
|
|
201
211
|
|
|
202
212
|
1. If the architect says FINALIZE
|
|
203
|
-
- Jump to PHASE 5 - Finalization.
|
|
204
213
|
|
|
214
|
+
- Jump to PHASE 5 - Finalization.
|
|
205
215
|
|
|
206
216
|
# PHASE 2 - Implementation (Parallel agent implementers)
|
|
217
|
+
|
|
207
218
|
(stage = "implementation")
|
|
208
219
|
|
|
209
220
|
1. **Spawn requested agents in parallel**
|
|
@@ -214,6 +225,7 @@ Wait for the architect response.
|
|
|
214
225
|
Example prompts:
|
|
215
226
|
|
|
216
227
|
**For python-dev:**
|
|
228
|
+
|
|
217
229
|
```
|
|
218
230
|
Execute your standard sprint workflow for sprint [N].
|
|
219
231
|
|
|
@@ -225,6 +237,7 @@ Wait for the architect response.
|
|
|
225
237
|
```
|
|
226
238
|
|
|
227
239
|
**For nextjs-dev**
|
|
240
|
+
|
|
228
241
|
```
|
|
229
242
|
Execute your standard sprint workflow for sprint [N].
|
|
230
243
|
|
|
@@ -234,9 +247,10 @@ Wait for the architect response.
|
|
|
234
247
|
|
|
235
248
|
Perform your workflow and report using your mandatory output format.
|
|
236
249
|
```
|
|
250
|
+
|
|
237
251
|
(Apply similar templates for other implementation agents)
|
|
238
252
|
|
|
239
|
-
|
|
253
|
+
1. **Collect reports**
|
|
240
254
|
- Wait for all agents to complete
|
|
241
255
|
- Gather each agent's final report
|
|
242
256
|
|
|
@@ -261,6 +275,7 @@ After you collect an agent report, you MUST:
|
|
|
261
275
|
`.claude/sprint/[index]/[slug]-report-[iteration].md`
|
|
262
276
|
|
|
263
277
|
Examples:
|
|
278
|
+
|
|
264
279
|
- `.claude/sprint/3/backend-report-1.md`
|
|
265
280
|
- `.claude/sprint/3/frontend-report-1.md`
|
|
266
281
|
- `.claude/sprint/3/qa-report-2.md`
|
|
@@ -269,6 +284,7 @@ Examples:
|
|
|
269
284
|
- `.claude/sprint/3/cicd-report-1.md`
|
|
270
285
|
|
|
271
286
|
Then, when you call `project-architect` again, you:
|
|
287
|
+
|
|
272
288
|
- Include the report contents in your message (as you already do).
|
|
273
289
|
- Optionally mention which `[slug]-report-[iteration].md` files were created.
|
|
274
290
|
|
|
@@ -276,14 +292,15 @@ Agents never manage `[iteration]` or filenames. Only the orchestrator (you) does
|
|
|
276
292
|
|
|
277
293
|
1. **Return reports to architect**
|
|
278
294
|
- Spawn project-architect again (resume mode) with:
|
|
279
|
-
|
|
295
|
+
|
|
296
|
+
```text
|
|
280
297
|
Here are the reports from the agents you requested:
|
|
281
|
-
|
|
298
|
+
[all reports]
|
|
282
299
|
|
|
283
300
|
Analyze these reports and decide next steps.
|
|
284
301
|
```
|
|
285
|
-
2. Loop back to phase 1.
|
|
286
302
|
|
|
303
|
+
2. Loop back to phase 1.
|
|
287
304
|
|
|
288
305
|
# PHASE 3 - QA & UI Testing
|
|
289
306
|
|
|
@@ -312,6 +329,7 @@ If `ui-test-agent` was requested:
|
|
|
312
329
|
### Determine testing mode
|
|
313
330
|
|
|
314
331
|
Check specs.md for `UI Testing Mode`:
|
|
332
|
+
|
|
315
333
|
- If `UI Testing Mode: manual` -> set `testing_mode = "MANUAL"`
|
|
316
334
|
- Otherwise -> set `testing_mode = "AUTOMATED"`
|
|
317
335
|
|
|
@@ -367,9 +385,10 @@ If spawning multiple testing agents (ui-test + diagnostics), spawn them in the *
|
|
|
367
385
|
## Step 3: Collect and Save Reports
|
|
368
386
|
|
|
369
387
|
After all testing agents complete, save reports as:
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
388
|
+
|
|
389
|
+
- `.claude/sprint/[N]/qa-report-[iteration].md` (if qa-test-agent ran)
|
|
390
|
+
- `.claude/sprint/[N]/ui-test-report-[iteration].md` (if ui-test-agent ran)
|
|
391
|
+
- `.claude/sprint/[N]/nextjs-diagnostics-report-[iteration].md` (if nextjs-diagnostics-agent ran)
|
|
373
392
|
|
|
374
393
|
## Step 4: Send to Architect
|
|
375
394
|
|
|
@@ -390,7 +409,6 @@ Decide next steps based on these test results.
|
|
|
390
409
|
|
|
391
410
|
Set `stage = "architecture"` and loop back to PHASE 1.
|
|
392
411
|
|
|
393
|
-
|
|
394
412
|
# PHASE 4 - Architect Review & Iteration Control
|
|
395
413
|
|
|
396
414
|
In each architect review cycle, the architect may:
|
|
@@ -408,11 +426,15 @@ In each architect review cycle, the architect may:
|
|
|
408
426
|
|
|
409
427
|
After each architect review, update the iteration counter:
|
|
410
428
|
|
|
411
|
-
|
|
429
|
+
```text
|
|
430
|
+
iteration += 1
|
|
431
|
+
```
|
|
412
432
|
|
|
413
433
|
If:
|
|
414
434
|
|
|
415
|
-
|
|
435
|
+
```text
|
|
436
|
+
iteration > 5
|
|
437
|
+
```
|
|
416
438
|
|
|
417
439
|
Then:
|
|
418
440
|
|
|
@@ -422,9 +444,9 @@ Then:
|
|
|
422
444
|
Implementation or tests are still not passing.
|
|
423
445
|
|
|
424
446
|
Review .claude/sprint/[N]/ and provide guidance:
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
447
|
+
- Should we continue iterating?
|
|
448
|
+
- Should we adjust the specifications?
|
|
449
|
+
- Are there manual fixes required?
|
|
428
450
|
|
|
429
451
|
- Stop until the user provides new instructions.
|
|
430
452
|
|
|
@@ -447,6 +469,7 @@ When the architect signals that Phase 5 is complete:
|
|
|
447
469
|
2) **Clean up ephemeral reports:**
|
|
448
470
|
|
|
449
471
|
Delete manual test reports - they're no longer relevant after the sprint completes:
|
|
472
|
+
|
|
450
473
|
```bash
|
|
451
474
|
rm -f .claude/sprint/[N]/manual-test-report*.md
|
|
452
475
|
```
|
|
@@ -459,7 +482,6 @@ When the architect signals that Phase 5 is complete:
|
|
|
459
482
|
|
|
460
483
|
Terminate the sprint.
|
|
461
484
|
|
|
462
|
-
|
|
463
485
|
# KEY RULES
|
|
464
486
|
|
|
465
487
|
- Implementation agents (backend, frontend, db, cicd, etc.) MAY run in parallel.
|
package/commands/test.md
CHANGED
|
@@ -8,6 +8,7 @@ argument-hint: "[url]"
|
|
|
8
8
|
You are launching a manual UI testing session using Chrome browser.
|
|
9
9
|
|
|
10
10
|
This is a **standalone command** - it does NOT run the full sprint workflow. Use this when you want to:
|
|
11
|
+
|
|
11
12
|
- Quickly explore your app in a real browser
|
|
12
13
|
- Manually test features while console errors are captured
|
|
13
14
|
- Debug UI issues interactively
|
|
@@ -18,11 +19,13 @@ This is a **standalone command** - it does NOT run the full sprint workflow. Use
|
|
|
18
19
|
### Step 0: Locate Sprint Directory
|
|
19
20
|
|
|
20
21
|
Find the current sprint directory:
|
|
22
|
+
|
|
21
23
|
```bash
|
|
22
24
|
ls -d .claude/sprint/*/ 2>/dev/null | sort -V | tail -1
|
|
23
25
|
```
|
|
24
26
|
|
|
25
27
|
If no sprint exists, create the first one:
|
|
28
|
+
|
|
26
29
|
```bash
|
|
27
30
|
mkdir -p .claude/sprint/1
|
|
28
31
|
```
|
|
@@ -32,6 +35,7 @@ Store the sprint directory path (e.g., `.claude/sprint/1/`) for saving the repor
|
|
|
32
35
|
### Step 1: Determine Frontend URL
|
|
33
36
|
|
|
34
37
|
Check for URL in this order:
|
|
38
|
+
|
|
35
39
|
1. Command argument (e.g., `/sprint:test http://localhost:8080`)
|
|
36
40
|
2. `.claude/project-map.md` - look for frontend URL
|
|
37
41
|
3. Default: `http://localhost:3000`
|
|
@@ -69,6 +73,7 @@ Call: mcp__claude-in-chrome__computer
|
|
|
69
73
|
```
|
|
70
74
|
|
|
71
75
|
Report to user:
|
|
76
|
+
|
|
72
77
|
```
|
|
73
78
|
Browser opened at [URL]
|
|
74
79
|
|
|
@@ -93,6 +98,7 @@ If errors are found, briefly note them but don't interrupt the user's flow.
|
|
|
93
98
|
### Step 6: Wait for User to Finish
|
|
94
99
|
|
|
95
100
|
The user will indicate they're done testing by saying something like:
|
|
101
|
+
|
|
96
102
|
- "done"
|
|
97
103
|
- "finish"
|
|
98
104
|
- "stop testing"
|
|
@@ -103,19 +109,22 @@ The user will indicate they're done testing by saying something like:
|
|
|
103
109
|
When the user signals completion:
|
|
104
110
|
|
|
105
111
|
1. Take final screenshot:
|
|
112
|
+
|
|
106
113
|
```
|
|
107
114
|
Call: mcp__claude-in-chrome__computer
|
|
108
115
|
- action: "screenshot"
|
|
109
116
|
- tabId: [tabId]
|
|
110
117
|
```
|
|
111
118
|
|
|
112
|
-
|
|
119
|
+
1. Get all console messages:
|
|
120
|
+
|
|
113
121
|
```
|
|
114
122
|
Call: mcp__claude-in-chrome__read_console_messages
|
|
115
123
|
- tabId: [tabId]
|
|
116
124
|
```
|
|
117
125
|
|
|
118
|
-
|
|
126
|
+
1. Optionally get network requests if relevant:
|
|
127
|
+
|
|
119
128
|
```
|
|
120
129
|
Call: mcp__claude-in-chrome__read_network_requests
|
|
121
130
|
- tabId: [tabId]
|
|
@@ -154,6 +163,7 @@ Generate a report with this structure:
|
|
|
154
163
|
Write the report to: `.claude/sprint/[N]/manual-test-report.md`
|
|
155
164
|
|
|
156
165
|
If a previous `manual-test-report.md` exists, append a timestamp suffix:
|
|
166
|
+
|
|
157
167
|
- `.claude/sprint/[N]/manual-test-report-[timestamp].md`
|
|
158
168
|
|
|
159
169
|
**Inform the user:**
|
|
@@ -168,6 +178,7 @@ The architect will use it to understand what needs to be fixed.
|
|
|
168
178
|
## Error Handling
|
|
169
179
|
|
|
170
180
|
If the browser fails to open or navigate:
|
|
181
|
+
|
|
171
182
|
- Report the error to the user
|
|
172
183
|
- Suggest checking if the app is running
|
|
173
184
|
- Provide the URL that was attempted
|
package/package.json
CHANGED
|
@@ -1,13 +1,20 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: agent-patterns
|
|
3
|
-
description:
|
|
4
|
-
|
|
3
|
+
description: 'Execute this skill should be used when the user asks about "SPAWN REQUEST
|
|
4
|
+
format", "agent reports", "agent coordination", "parallel agents", "report format",
|
|
5
|
+
"agent communication", or needs to understand how agents coordinate within the sprint
|
|
6
|
+
system. Use when appropriate context detected. Trigger with relevant phrases based
|
|
7
|
+
on skill purpose.
|
|
8
|
+
|
|
9
|
+
'
|
|
5
10
|
allowed-tools: Read
|
|
6
11
|
version: 1.0.0
|
|
7
12
|
author: Damien Laine <damien.laine@gmail.com>
|
|
8
13
|
license: MIT
|
|
9
|
-
|
|
10
|
-
|
|
14
|
+
tags:
|
|
15
|
+
- community
|
|
16
|
+
- agent-patterns
|
|
17
|
+
compatibility: Designed for Claude Code, also compatible with Codex and OpenClaw
|
|
11
18
|
---
|
|
12
19
|
# Agent Patterns
|
|
13
20
|
|
|
@@ -25,6 +32,7 @@ Agent Patterns defines the coordination protocol for multi-agent sprint executio
|
|
|
25
32
|
## Instructions
|
|
26
33
|
|
|
27
34
|
1. Structure every agent spawn using the SPAWN REQUEST format. Include the agent name, the specification file it should read, and any scope constraints:
|
|
35
|
+
|
|
28
36
|
```
|
|
29
37
|
SPAWN REQUEST
|
|
30
38
|
Agent: python-dev
|
|
@@ -32,6 +40,7 @@ Agent Patterns defines the coordination protocol for multi-agent sprint executio
|
|
|
32
40
|
Contract: .claude/sprint/1/api-contract.md
|
|
33
41
|
Scope: Authentication endpoints only
|
|
34
42
|
```
|
|
43
|
+
|
|
35
44
|
2. Ensure each spawned agent receives only the files relevant to its scope. Pass the `api-contract.md` as a shared interface so backend and frontend agents stay synchronized.
|
|
36
45
|
3. Collect structured reports from every agent upon completion. Each report must include: work completed, files modified, tests added, and conformity status against the specification.
|
|
37
46
|
4. When running agents in parallel, partition work by domain boundary (e.g., backend vs. frontend vs. CI/CD). Never assign overlapping file paths to concurrent agents.
|
|
@@ -58,6 +67,7 @@ Agent Patterns defines the coordination protocol for multi-agent sprint executio
|
|
|
58
67
|
## Examples
|
|
59
68
|
|
|
60
69
|
**Spawning parallel implementation agents:**
|
|
70
|
+
|
|
61
71
|
```
|
|
62
72
|
SPAWN REQUEST
|
|
63
73
|
Agent: python-dev
|
|
@@ -69,9 +79,11 @@ Agent: nextjs-dev
|
|
|
69
79
|
Specs: .claude/sprint/1/frontend-specs.md
|
|
70
80
|
Contract: .claude/sprint/1/api-contract.md
|
|
71
81
|
```
|
|
82
|
+
|
|
72
83
|
Both agents share the same `api-contract.md` to ensure API compatibility.
|
|
73
84
|
|
|
74
85
|
**Structured agent report format:**
|
|
86
|
+
|
|
75
87
|
```
|
|
76
88
|
AGENT REPORT
|
|
77
89
|
Agent: python-dev
|
|
@@ -83,6 +95,7 @@ Notes: JWT token expiry set to 24h per spec
|
|
|
83
95
|
```
|
|
84
96
|
|
|
85
97
|
**Testing agent coordination:**
|
|
98
|
+
|
|
86
99
|
```
|
|
87
100
|
SPAWN REQUEST
|
|
88
101
|
Agent: qa-test-agent
|
|
@@ -100,4 +113,4 @@ Run After: qa-test-agent
|
|
|
100
113
|
- `${CLAUDE_SKILL_DIR}/references/ui-test-report.md` -- Structured UI test report format with coverage and failure tracking
|
|
101
114
|
- Sprint workflow skill for phase lifecycle context
|
|
102
115
|
- API contract skill for shared interface design
|
|
103
|
-
- Sprint plugin README for agent architecture overview
|
|
116
|
+
- Sprint plugin README for agent architecture overview
|
|
@@ -5,6 +5,7 @@
|
|
|
5
5
|
The simplest pattern: one agent implementing one spec file with a shared contract.
|
|
6
6
|
|
|
7
7
|
**SPAWN REQUEST block:**
|
|
8
|
+
|
|
8
9
|
```
|
|
9
10
|
SPAWN REQUEST
|
|
10
11
|
Agent: python-dev
|
|
@@ -14,6 +15,7 @@ Scope: All backend endpoints
|
|
|
14
15
|
```
|
|
15
16
|
|
|
16
17
|
**Agent reads these files, implements, then returns:**
|
|
18
|
+
|
|
17
19
|
```
|
|
18
20
|
AGENT REPORT
|
|
19
21
|
Agent: python-dev
|
|
@@ -34,6 +36,7 @@ Multiple agents running concurrently, each assigned to a non-overlapping domain
|
|
|
34
36
|
boundary to prevent file conflicts.
|
|
35
37
|
|
|
36
38
|
**Architect produces three SPAWN REQUEST blocks:**
|
|
39
|
+
|
|
37
40
|
```
|
|
38
41
|
SPAWN REQUEST
|
|
39
42
|
Agent: python-dev
|
|
@@ -54,6 +57,7 @@ Scope: Docker, GitHub Actions, and deployment configs
|
|
|
54
57
|
```
|
|
55
58
|
|
|
56
59
|
**Domain boundaries (no file overlap):**
|
|
60
|
+
|
|
57
61
|
```
|
|
58
62
|
python-dev → src/api/*, src/models/*, tests/api/*
|
|
59
63
|
nextjs-dev → app/*, components/*, tests/ui/*
|
|
@@ -61,6 +65,7 @@ cicd-agent → .github/workflows/*, Dockerfile, docker-compose.yml
|
|
|
61
65
|
```
|
|
62
66
|
|
|
63
67
|
**All three agents run simultaneously. Reports collected:**
|
|
68
|
+
|
|
64
69
|
```
|
|
65
70
|
AGENT REPORT
|
|
66
71
|
Agent: python-dev
|
|
@@ -90,6 +95,7 @@ Testing agents must run after implementation agents complete. QA runs first,
|
|
|
90
95
|
then UI testing runs after QA passes.
|
|
91
96
|
|
|
92
97
|
**Sequential SPAWN REQUEST chain:**
|
|
98
|
+
|
|
93
99
|
```
|
|
94
100
|
SPAWN REQUEST
|
|
95
101
|
Agent: qa-test-agent
|
|
@@ -106,6 +112,7 @@ Scope: Browser-based E2E tests for all user flows
|
|
|
106
112
|
```
|
|
107
113
|
|
|
108
114
|
**QA agent report:**
|
|
115
|
+
|
|
109
116
|
```
|
|
110
117
|
AGENT REPORT
|
|
111
118
|
Agent: qa-test-agent
|
|
@@ -122,6 +129,7 @@ Conformity: 2 endpoints deviate from api-contract.md error codes
|
|
|
122
129
|
```
|
|
123
130
|
|
|
124
131
|
**UI test agent report (using structured format):**
|
|
132
|
+
|
|
125
133
|
```
|
|
126
134
|
AGENT REPORT
|
|
127
135
|
Agent: ui-test-agent
|
|
@@ -145,6 +153,7 @@ After collecting all agent reports, the architect decides whether to iterate
|
|
|
145
153
|
or finalize.
|
|
146
154
|
|
|
147
155
|
**Architect receives reports from Iteration 1:**
|
|
156
|
+
|
|
148
157
|
```
|
|
149
158
|
python-dev: COMPLETE (all endpoints working)
|
|
150
159
|
nextjs-dev: COMPLETE (all components rendered)
|
|
@@ -153,6 +162,7 @@ ui-test-agent: 1 failure (checkout button disabled)
|
|
|
153
162
|
```
|
|
154
163
|
|
|
155
164
|
**Architect analysis:**
|
|
165
|
+
|
|
156
166
|
```
|
|
157
167
|
Conformity Review:
|
|
158
168
|
✓ 4/6 API endpoints fully conformant
|
|
@@ -177,6 +187,7 @@ Updated status.md:
|
|
|
177
187
|
```
|
|
178
188
|
|
|
179
189
|
**Architect spawns narrowed Iteration 2:**
|
|
190
|
+
|
|
180
191
|
```
|
|
181
192
|
SPAWN REQUEST
|
|
182
193
|
Agent: python-dev
|
|
@@ -196,6 +207,7 @@ The orchestrator detects the project framework and selects appropriate
|
|
|
196
207
|
specialized agents.
|
|
197
208
|
|
|
198
209
|
**Project detection:**
|
|
210
|
+
|
|
199
211
|
```
|
|
200
212
|
Phase 0 scan:
|
|
201
213
|
→ Found: next.config.js → Framework: Next.js
|
|
@@ -209,6 +221,7 @@ Agent selection:
|
|
|
209
221
|
```
|
|
210
222
|
|
|
211
223
|
**For a different project stack:**
|
|
224
|
+
|
|
212
225
|
```
|
|
213
226
|
Phase 0 scan:
|
|
214
227
|
→ Found: nuxt.config.ts → Framework: Nuxt 3
|
|
@@ -226,6 +239,7 @@ Agent selection:
|
|
|
226
239
|
When an agent fails to produce a valid report or encounters unrecoverable errors.
|
|
227
240
|
|
|
228
241
|
**Failed agent report:**
|
|
242
|
+
|
|
229
243
|
```
|
|
230
244
|
AGENT REPORT
|
|
231
245
|
Agent: python-dev
|
|
@@ -237,6 +251,7 @@ Conformity: Unable to assess — implementation did not start
|
|
|
237
251
|
```
|
|
238
252
|
|
|
239
253
|
**Architect response:**
|
|
254
|
+
|
|
240
255
|
```
|
|
241
256
|
Architect reviews failure:
|
|
242
257
|
→ Root cause: platform-specific dependency issue
|
|
@@ -256,6 +271,7 @@ Notes: Use asyncpg instead of psycopg2-binary for PostgreSQL
|
|
|
256
271
|
When agents need strict boundaries to prevent overlapping modifications.
|
|
257
272
|
|
|
258
273
|
**Tightly scoped SPAWN REQUEST:**
|
|
274
|
+
|
|
259
275
|
```
|
|
260
276
|
SPAWN REQUEST
|
|
261
277
|
Agent: python-dev
|
|
@@ -273,6 +289,7 @@ Forbidden Paths:
|
|
|
273
289
|
```
|
|
274
290
|
|
|
275
291
|
**Agent respects boundaries in its report:**
|
|
292
|
+
|
|
276
293
|
```
|
|
277
294
|
AGENT REPORT
|
|
278
295
|
Agent: python-dev
|
|
@@ -3,15 +3,18 @@
|
|
|
3
3
|
## UI TEST REPORT
|
|
4
4
|
|
|
5
5
|
### MODE
|
|
6
|
+
|
|
6
7
|
AUTOMATED
|
|
7
8
|
|
|
8
9
|
### SUMMARY
|
|
10
|
+
|
|
9
11
|
- Total tests run: 8
|
|
10
12
|
- Passed: 7
|
|
11
13
|
- Failed: 1
|
|
12
14
|
- Session duration: 45s
|
|
13
15
|
|
|
14
16
|
### COVERAGE
|
|
17
|
+
|
|
15
18
|
- Scenarios covered:
|
|
16
19
|
- Login with valid credentials
|
|
17
20
|
- Login with invalid password
|
|
@@ -21,6 +24,7 @@ AUTOMATED
|
|
|
21
24
|
- Email verification flow (requires email testing setup)
|
|
22
25
|
|
|
23
26
|
### FAILURES
|
|
27
|
+
|
|
24
28
|
- Scenario: Registration validation
|
|
25
29
|
- Path/URL: /register
|
|
26
30
|
- Symptom: Error message not displayed
|
|
@@ -28,8 +32,11 @@ AUTOMATED
|
|
|
28
32
|
- Actual: Form submits without feedback
|
|
29
33
|
|
|
30
34
|
### CONSOLE ERRORS
|
|
35
|
+
|
|
31
36
|
None.
|
|
32
37
|
|
|
33
38
|
### NOTES FOR ARCHITECT
|
|
39
|
+
|
|
34
40
|
- Registration error handling needs frontend fix
|
|
35
|
-
|
|
41
|
+
|
|
42
|
+
```
|
|
@@ -1,13 +1,21 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: api-contract
|
|
3
|
-
description:
|
|
4
|
-
|
|
3
|
+
description: 'Configure this skill should be used when the user asks about "API contract",
|
|
4
|
+
"api-contract.md", "shared interface", "TypeScript interfaces", "request response
|
|
5
|
+
schemas", "endpoint design", or needs guidance on designing contracts that coordinate
|
|
6
|
+
backend and frontend agents. Use when building or modifying API endpoints. Trigger
|
|
7
|
+
with phrases like ''create API'', ''design endpoint'', or ''API scaffold''.
|
|
8
|
+
|
|
9
|
+
'
|
|
5
10
|
allowed-tools: Read
|
|
6
11
|
version: 1.0.0
|
|
7
12
|
author: Damien Laine <damien.laine@gmail.com>
|
|
8
13
|
license: MIT
|
|
9
|
-
|
|
10
|
-
|
|
14
|
+
tags:
|
|
15
|
+
- community
|
|
16
|
+
- api
|
|
17
|
+
- typescript
|
|
18
|
+
compatibility: Designed for Claude Code, also compatible with Codex and OpenClaw
|
|
11
19
|
---
|
|
12
20
|
# API Contract
|
|
13
21
|
|
|
@@ -51,6 +59,7 @@ API Contract guides the creation of `api-contract.md` files that serve as the sh
|
|
|
51
59
|
## Examples
|
|
52
60
|
|
|
53
61
|
**Authentication endpoint contract:**
|
|
62
|
+
|
|
54
63
|
```markdown
|
|
55
64
|
#### POST /auth/register
|
|
56
65
|
|
|
@@ -78,6 +87,7 @@ Create a new user account.
|
|
|
78
87
|
```
|
|
79
88
|
|
|
80
89
|
**Paginated list endpoint:**
|
|
90
|
+
|
|
81
91
|
```markdown
|
|
82
92
|
#### GET /products
|
|
83
93
|
|
|
@@ -99,6 +109,7 @@ List products with pagination.
|
|
|
99
109
|
```
|
|
100
110
|
|
|
101
111
|
**Shared TypeScript interface:**
|
|
112
|
+
|
|
102
113
|
```typescript
|
|
103
114
|
interface ApiError {
|
|
104
115
|
code: string;
|
|
@@ -112,4 +123,4 @@ interface ApiError {
|
|
|
112
123
|
- `${CLAUDE_SKILL_DIR}/references/writing-endpoints.md` -- Endpoint definition template and key elements
|
|
113
124
|
- `${CLAUDE_SKILL_DIR}/references/typescript-interfaces.md` -- Canonical type definitions and guidelines
|
|
114
125
|
- `${CLAUDE_SKILL_DIR}/references/pagination.md` -- Pagination parameters and PaginatedResponse interface
|
|
115
|
-
- `${CLAUDE_SKILL_DIR}/references/best-practices.md` -- Contract authoring rules (specificity, DRY, no implementation details)
|
|
126
|
+
- `${CLAUDE_SKILL_DIR}/references/best-practices.md` -- Contract authoring rules (specificity, DRY, no implementation details)
|
|
@@ -22,6 +22,7 @@
|
|
|
22
22
|
"password": "SecurePass123"
|
|
23
23
|
}
|
|
24
24
|
```
|
|
25
|
+
|
|
25
26
|
```
|
|
26
27
|
|
|
27
28
|
### Document All States
|
|
@@ -42,6 +43,7 @@ Reference shared types instead of duplicating:
|
|
|
42
43
|
### No Implementation Details
|
|
43
44
|
|
|
44
45
|
The contract defines WHAT, not HOW:
|
|
46
|
+
|
|
45
47
|
- Don't mention database columns
|
|
46
48
|
- Don't specify frameworks
|
|
47
|
-
- Don't include file paths
|
|
49
|
+
- Don't include file paths
|