codex-workflows 0.2.3 → 0.2.4
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/.agents/skills/documentation-criteria/SKILL.md +3 -3
- package/.agents/skills/documentation-criteria/references/design-template.md +1 -26
- package/.agents/skills/documentation-criteria/references/plan-template.md +3 -18
- package/.agents/skills/recipe-add-integration-tests/SKILL.md +58 -18
- package/.codex/agents/task-decomposer.toml +1 -1
- package/.codex/agents/technical-designer-frontend.toml +2 -2
- package/.codex/agents/technical-designer.toml +2 -2
- package/.codex/agents/work-planner.toml +7 -6
- package/package.json +1 -1
|
@@ -64,16 +64,16 @@ description: "Documentation creation criteria for PRD, ADR, Design Doc, UI Spec,
|
|
|
64
64
|
### UI Specification
|
|
65
65
|
**Purpose**: Define UI structure, screen transitions, component decomposition, and interaction design
|
|
66
66
|
**Includes**: Screen list and transitions, component state x display matrix, interaction definitions, AC traceability, existing component reuse map, accessibility requirements
|
|
67
|
-
**Excludes**: Technical implementation details, API contracts, test implementation, implementation schedule
|
|
67
|
+
**Excludes**: Technical implementation details, API contracts, test implementation (generated by acceptance-test-generator), implementation schedule
|
|
68
68
|
|
|
69
69
|
### Design Document
|
|
70
70
|
**Purpose**: Define technical implementation methods in detail
|
|
71
71
|
**Includes**: Existing codebase analysis, technical approach, dependencies and constraints, interface/contract definitions, data flow, acceptance criteria, change impact map, code inspection evidence
|
|
72
|
-
**Excludes**: Why that technology was chosen (reference ADR), when/who to implement (reference Work Plan)
|
|
72
|
+
**Excludes**: Why that technology was chosen (reference ADR), when/who to implement (reference Work Plan), detailed test strategy and test case selection (generated by acceptance-test-generator from acceptance criteria)
|
|
73
73
|
|
|
74
74
|
### Work Plan
|
|
75
75
|
**Purpose**: Implementation task management and progress tracking
|
|
76
|
-
**Includes**: Task breakdown, schedule estimates,
|
|
76
|
+
**Includes**: Task breakdown, schedule estimates, test skeleton file paths, Phase 4 Quality Assurance Phase (required), progress records
|
|
77
77
|
**Excludes**: Technical rationale, design details
|
|
78
78
|
|
|
79
79
|
**Phase Division Criteria**:
|
|
@@ -259,40 +259,15 @@ System Invariants:
|
|
|
259
259
|
- Prerequisites: [Required pre-implementations]
|
|
260
260
|
|
|
261
261
|
### Integration Points
|
|
262
|
-
Each integration point requires E2E verification:
|
|
263
262
|
|
|
264
263
|
**Integration Point 1: [Name]**
|
|
265
264
|
- Components: [Component A] to [Component B]
|
|
266
|
-
-
|
|
265
|
+
- Contract: [Interface/API contract between components]
|
|
267
266
|
|
|
268
267
|
### Migration Strategy
|
|
269
268
|
|
|
270
269
|
[Technical migration approach, ensuring backward compatibility]
|
|
271
270
|
|
|
272
|
-
## Test Strategy
|
|
273
|
-
|
|
274
|
-
### Basic Test Design Policy
|
|
275
|
-
|
|
276
|
-
Automatically derive test cases from acceptance criteria:
|
|
277
|
-
- Create at least one test case for each acceptance criterion
|
|
278
|
-
- Implement measurable standards from acceptance criteria as assertions
|
|
279
|
-
|
|
280
|
-
### Unit Tests
|
|
281
|
-
|
|
282
|
-
[Unit testing policy and coverage goals]
|
|
283
|
-
|
|
284
|
-
### Integration Tests
|
|
285
|
-
|
|
286
|
-
[Integration testing policy and important test cases]
|
|
287
|
-
|
|
288
|
-
### E2E Tests
|
|
289
|
-
|
|
290
|
-
[E2E testing policy]
|
|
291
|
-
|
|
292
|
-
### Performance Tests
|
|
293
|
-
|
|
294
|
-
[Performance testing methods and standards]
|
|
295
|
-
|
|
296
271
|
## Security Considerations
|
|
297
272
|
|
|
298
273
|
Evaluate the following for this feature's trust boundaries and data flow:
|
|
@@ -48,11 +48,6 @@ Related Issue/PR: #XXX (if any)
|
|
|
48
48
|
- [ ] [Functional completion criteria]
|
|
49
49
|
- [ ] [Quality completion criteria]
|
|
50
50
|
|
|
51
|
-
#### Operational Verification Procedures
|
|
52
|
-
1. [Operation verification steps]
|
|
53
|
-
2. [Expected result verification]
|
|
54
|
-
3. [Performance verification (when applicable)]
|
|
55
|
-
|
|
56
51
|
### Phase 2: [Phase Name] (Estimated commits: X)
|
|
57
52
|
**Purpose**: [What this phase aims to achieve]
|
|
58
53
|
|
|
@@ -66,11 +61,6 @@ Related Issue/PR: #XXX (if any)
|
|
|
66
61
|
- [ ] [Functional completion criteria]
|
|
67
62
|
- [ ] [Quality completion criteria]
|
|
68
63
|
|
|
69
|
-
#### Operational Verification Procedures
|
|
70
|
-
1. [Operation verification steps]
|
|
71
|
-
2. [Expected result verification]
|
|
72
|
-
3. [Performance verification (when applicable)]
|
|
73
|
-
|
|
74
64
|
### Phase 3: [Phase Name] (Estimated commits: X)
|
|
75
65
|
**Purpose**: [What this phase aims to achieve]
|
|
76
66
|
|
|
@@ -84,9 +74,6 @@ Related Issue/PR: #XXX (if any)
|
|
|
84
74
|
- [ ] [Functional completion criteria]
|
|
85
75
|
- [ ] [Quality completion criteria]
|
|
86
76
|
|
|
87
|
-
#### Operational Verification Procedures
|
|
88
|
-
[Copy relevant integration point operational verification from Design Doc]
|
|
89
|
-
|
|
90
77
|
### Final Phase: Quality Assurance (Required) (Estimated commits: 1)
|
|
91
78
|
**Purpose**: Overall quality assurance and Design Doc consistency verification
|
|
92
79
|
|
|
@@ -94,13 +81,10 @@ Related Issue/PR: #XXX (if any)
|
|
|
94
81
|
- [ ] Verify all Design Doc acceptance criteria achieved
|
|
95
82
|
- [ ] Security review: Verify security considerations from Design Doc are implemented
|
|
96
83
|
- [ ] Quality checks (types, lint, format)
|
|
97
|
-
- [ ] Execute all tests
|
|
84
|
+
- [ ] Execute all tests (including integration/E2E from test skeletons, when provided)
|
|
98
85
|
- [ ] Coverage 70%+
|
|
99
86
|
- [ ] Document updates
|
|
100
87
|
|
|
101
|
-
#### Operational Verification Procedures
|
|
102
|
-
[Copy operational verification procedures from Design Doc]
|
|
103
|
-
|
|
104
88
|
### Quality Assurance
|
|
105
89
|
- [ ] Implement staged quality checks (details: refer to ai-development-guide skill)
|
|
106
90
|
- [ ] All tests pass
|
|
@@ -110,7 +94,8 @@ Related Issue/PR: #XXX (if any)
|
|
|
110
94
|
|
|
111
95
|
## Completion Criteria
|
|
112
96
|
- [ ] All phases completed
|
|
113
|
-
- [ ]
|
|
97
|
+
- [ ] All integration/E2E tests passing (when test skeletons provided)
|
|
98
|
+
- [ ] Acceptance criteria manually verified (when test skeletons are not provided)
|
|
114
99
|
- [ ] Design Doc acceptance criteria satisfied
|
|
115
100
|
- [ ] Staged quality checks completed (zero errors)
|
|
116
101
|
- [ ] All tests pass
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: recipe-add-integration-tests
|
|
3
|
-
description: "Add integration/E2E tests to existing codebase using Design
|
|
3
|
+
description: "Add integration/E2E tests to existing codebase using Design Docs."
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
## Required Skills [LOAD BEFORE EXECUTION]
|
|
@@ -26,11 +26,11 @@ description: "Add integration/E2E tests to existing codebase using Design Doc ac
|
|
|
26
26
|
- Test review -> Spawn integration-test-reviewer agent
|
|
27
27
|
- Quality checks -> Spawn quality-fixer agent
|
|
28
28
|
|
|
29
|
-
|
|
29
|
+
Document paths: $ARGUMENTS
|
|
30
30
|
|
|
31
31
|
## Prerequisites
|
|
32
32
|
|
|
33
|
-
- Design Doc must exist (created manually or via reverse-engineer)
|
|
33
|
+
- At least one Design Doc must exist (created manually or via reverse-engineer)
|
|
34
34
|
- Existing implementation to test
|
|
35
35
|
|
|
36
36
|
## Execution Flow
|
|
@@ -39,27 +39,59 @@ Design Doc path: $ARGUMENTS
|
|
|
39
39
|
|
|
40
40
|
Reference documentation-criteria skill for task file template in Step 3.
|
|
41
41
|
|
|
42
|
-
### Step 1: Validate
|
|
42
|
+
### Step 1: Discover and Validate Documents
|
|
43
43
|
|
|
44
|
-
|
|
44
|
+
```bash
|
|
45
|
+
# Verify at least one document path was provided
|
|
46
|
+
test -n "$ARGUMENTS" || { echo "ERROR: No document paths provided"; exit 1; }
|
|
47
|
+
|
|
48
|
+
# Verify provided paths exist
|
|
49
|
+
ls $ARGUMENTS
|
|
50
|
+
```
|
|
51
|
+
|
|
52
|
+
Use only the user-provided paths in `$ARGUMENTS`. Do not auto-discover additional Design Docs or UI Specs.
|
|
53
|
+
|
|
54
|
+
Classify provided documents by path and filename, using first-match-wins:
|
|
55
|
+
- Path matches `docs/ui-spec/*.md` -> **UI Spec**
|
|
56
|
+
- Path matches `docs/design/*-backend-*.md` or `docs/design/*backend*.md` -> **Design Doc (backend)**
|
|
57
|
+
- Path matches `docs/design/*-frontend-*.md` or `docs/design/*frontend*.md` -> **Design Doc (frontend)**
|
|
58
|
+
- Path matches `docs/design/*.md` and none of the above -> **single-layer Design Doc**
|
|
59
|
+
|
|
60
|
+
If a filename appears to match both backend and frontend, halt and ask the user which layer it belongs to.
|
|
45
61
|
|
|
46
62
|
### Step 2: Skeleton Generation
|
|
47
63
|
|
|
48
|
-
Spawn acceptance-test-generator agent
|
|
64
|
+
Spawn acceptance-test-generator agent with only the documents that exist from Step 1:
|
|
65
|
+
```text
|
|
66
|
+
Generate test skeletons from the following documents:
|
|
67
|
+
- Design Doc (backend): [path] <- include only if exists
|
|
68
|
+
- Design Doc (frontend): [path] <- include only if exists
|
|
69
|
+
- UI Spec: [path] <- include only if exists
|
|
70
|
+
```
|
|
49
71
|
|
|
50
|
-
**Expected output**: `generatedFiles`
|
|
72
|
+
**Expected output**: `generatedFiles` as a structured object grouped by layer, for example:
|
|
73
|
+
```json
|
|
74
|
+
{
|
|
75
|
+
"backend": ["path/to/backend.int.test.ts"],
|
|
76
|
+
"frontend": ["path/to/frontend.int.test.ts"],
|
|
77
|
+
"e2e": ["path/to/flow.e2e.test.ts"]
|
|
78
|
+
}
|
|
79
|
+
```
|
|
51
80
|
|
|
52
|
-
### Step 3: Create Task
|
|
81
|
+
### Step 3: Create Task Files [GATE]
|
|
53
82
|
|
|
54
83
|
**[STOP — BLOCKING]** Present task file content to user for confirmation before proceeding to implementation.
|
|
55
84
|
**CANNOT proceed until user explicitly confirms.**
|
|
56
85
|
|
|
57
|
-
Create task file
|
|
86
|
+
Create one task file per layer, using the monorepo-flow.md naming convention for deterministic agent routing:
|
|
87
|
+
- Backend skeletons exist -> `docs/plans/tasks/integration-tests-backend-task-YYYYMMDD.md`
|
|
88
|
+
- Frontend skeletons exist -> `docs/plans/tasks/integration-tests-frontend-task-YYYYMMDD.md`
|
|
89
|
+
- Single-layer (no backend/frontend distinction) -> `docs/plans/tasks/integration-tests-backend-task-YYYYMMDD.md`
|
|
58
90
|
|
|
59
|
-
**Template
|
|
91
|
+
**Template** (per task file):
|
|
60
92
|
```markdown
|
|
61
93
|
---
|
|
62
|
-
name: Implement integration tests for [feature name]
|
|
94
|
+
name: Implement [layer] integration tests for [feature name]
|
|
63
95
|
type: test-implementation
|
|
64
96
|
---
|
|
65
97
|
|
|
@@ -69,8 +101,8 @@ Implement test cases defined in skeleton files.
|
|
|
69
101
|
|
|
70
102
|
## Target Files
|
|
71
103
|
|
|
72
|
-
- Skeleton: [
|
|
73
|
-
- Design Doc: [
|
|
104
|
+
- Skeleton: [layer-specific paths from Step 2 generatedFiles]
|
|
105
|
+
- Design Doc: [layer-specific Design Doc from Step 1]
|
|
74
106
|
|
|
75
107
|
## Tasks
|
|
76
108
|
|
|
@@ -85,17 +117,22 @@ Implement test cases defined in skeleton files.
|
|
|
85
117
|
- No quality issues
|
|
86
118
|
```
|
|
87
119
|
|
|
88
|
-
**Output**: "Task file created at [path]. Ready for Step 4."
|
|
120
|
+
**Output**: "Task file(s) created at [path(s)]. Ready for Step 4."
|
|
89
121
|
|
|
90
122
|
### Step 4: Test Implementation
|
|
91
123
|
|
|
92
|
-
|
|
124
|
+
For each task file from Step 3, invoke task-executor routed by filename pattern:
|
|
125
|
+
- `*-backend-task-*` -> Spawn `task-executor`
|
|
126
|
+
- `*-frontend-task-*` -> Spawn `task-executor-frontend`
|
|
127
|
+
- Prompt: "Task file: [task file path from Step 3]. Implement tests following the task file."
|
|
128
|
+
|
|
129
|
+
Execute one task file at a time through Steps 4 -> 5 -> 6 -> 7 before starting the next.
|
|
93
130
|
|
|
94
131
|
**Expected output**: `status`, `testsAdded`
|
|
95
132
|
|
|
96
133
|
### Step 5: Test Review
|
|
97
134
|
|
|
98
|
-
Spawn integration-test-reviewer agent: "Review test quality. Test files: [paths from Step 4 testsAdded]. Skeleton files: [paths from Step 2 generatedFiles]."
|
|
135
|
+
Spawn integration-test-reviewer agent: "Review test quality. Test files: [paths from Step 4 testsAdded]. Skeleton files: [layer-specific paths from Step 2 generatedFiles matching current task's layer]."
|
|
99
136
|
|
|
100
137
|
**Expected output**: `status` (approved/needs_revision), `requiredFixes`
|
|
101
138
|
|
|
@@ -103,11 +140,14 @@ Spawn integration-test-reviewer agent: "Review test quality. Test files: [paths
|
|
|
103
140
|
|
|
104
141
|
Check Step 5 result:
|
|
105
142
|
- `status: approved` -> Mark complete, proceed to Step 7
|
|
106
|
-
- `status: needs_revision` -> Spawn
|
|
143
|
+
- `status: needs_revision` -> Spawn the layer-appropriate executor with: "Fix the following issues in test files: [requiredFixes from Step 5]." Then return to Step 5. Maximum 2 revision cycles per task file; if still `needs_revision`, escalate to the user.
|
|
107
144
|
|
|
108
145
|
### Step 7: Quality Check
|
|
109
146
|
|
|
110
|
-
Spawn quality-fixer
|
|
147
|
+
Spawn quality-fixer routed by task filename pattern:
|
|
148
|
+
- `*-backend-task-*` -> Spawn `quality-fixer`
|
|
149
|
+
- `*-frontend-task-*` -> Spawn `quality-fixer-frontend`
|
|
150
|
+
- Prompt: "Final quality assurance for test files added in this workflow. Run all tests and verify coverage."
|
|
111
151
|
|
|
112
152
|
**Expected output**: `status` (`approved`/`blocked`)
|
|
113
153
|
|
|
@@ -106,7 +106,7 @@ Decompose tasks based on implementation strategy patterns determined in implemen
|
|
|
106
106
|
- **Phase Completion Task Auto-generation (Required)**:
|
|
107
107
|
- Based on "Phase X" notation in work plan, generate after each phase's final task
|
|
108
108
|
- Filename: `{plan-name}-phase{number}-completion.md`
|
|
109
|
-
- Content:
|
|
109
|
+
- Content: All task completion checklist, list test skeleton file paths for verification
|
|
110
110
|
- Criteria: Always generate if the plan contains the string "Phase"
|
|
111
111
|
|
|
112
112
|
5. **Task Structuring**
|
|
@@ -338,9 +338,9 @@ function useUserData(userId: string) {
|
|
|
338
338
|
- [ ] **Agreement checklist completed** (most important)
|
|
339
339
|
- [ ] **Prerequisite common ADRs referenced** (required)
|
|
340
340
|
- [ ] **Change impact map created** (required)
|
|
341
|
-
- [ ] **Component verification procedures for each phase** (required)
|
|
342
341
|
- [ ] Response to requirements and design validity
|
|
343
|
-
- [ ]
|
|
342
|
+
- [ ] Error handling strategy
|
|
343
|
+
- [ ] Acceptance criteria written in testable format: each criterion includes a measurable condition and expected outcome (verifiable by acceptance-test-generator)
|
|
344
344
|
- [ ] Props change matrix completeness
|
|
345
345
|
- [ ] Implementation approach selection rationale (vertical/horizontal/hybrid)
|
|
346
346
|
- [ ] Latest React best practices researched and references cited
|
|
@@ -314,9 +314,9 @@ Implementation sample creation checklist:
|
|
|
314
314
|
- [ ] **Agreement checklist completed** (most important)
|
|
315
315
|
- [ ] **Prerequisite common ADRs referenced** (required)
|
|
316
316
|
- [ ] **Change impact map created** (required)
|
|
317
|
-
- [ ] **E2E verification procedures for each phase** (required)
|
|
318
317
|
- [ ] Response to requirements and design validity
|
|
319
|
-
- [ ]
|
|
318
|
+
- [ ] Error handling strategy
|
|
319
|
+
- [ ] Acceptance criteria written in testable format: each criterion includes a measurable condition and expected outcome (verifiable by acceptance-test-generator)
|
|
320
320
|
- [ ] Interface change matrix completeness
|
|
321
321
|
- [ ] Implementation approach selection rationale (vertical/horizontal/hybrid)
|
|
322
322
|
- [ ] Latest best practices researched and references cited
|
|
@@ -40,7 +40,7 @@ Skill Status:
|
|
|
40
40
|
2. Clarify task dependencies
|
|
41
41
|
3. Phase division and prioritization
|
|
42
42
|
4. Define completion criteria for each task (derived from Design Doc acceptance criteria)
|
|
43
|
-
5.
|
|
43
|
+
5. Place test implementation and execution appropriately for each phase
|
|
44
44
|
6. Concretize risks and countermeasures
|
|
45
45
|
7. Document in progress-trackable format
|
|
46
46
|
|
|
@@ -60,7 +60,7 @@ Skill Status:
|
|
|
60
60
|
Read the Design Doc(s), UI Spec, PRD, and ADR (if provided). Extract:
|
|
61
61
|
- Acceptance criteria and implementation approach
|
|
62
62
|
- Technical dependencies and implementation order
|
|
63
|
-
- Integration points
|
|
63
|
+
- Integration points and their contracts
|
|
64
64
|
|
|
65
65
|
### 2. Process Test Design Information (when provided)
|
|
66
66
|
Read test skeleton files and extract meta information (see Test Design Information Processing section).
|
|
@@ -71,7 +71,8 @@ Choose Strategy A (TDD) if test skeletons are provided, Strategy B (implementati
|
|
|
71
71
|
### 4. Compose Phases
|
|
72
72
|
Structure phases based on technical dependencies from Design Doc:
|
|
73
73
|
- Place tasks with lowest dependencies in earlier phases
|
|
74
|
-
-
|
|
74
|
+
- When test skeletons are provided, place integration test implementation based on `@dependency` metadata from test skeletons (see Test Design Information Processing > Step 2) and place E2E test execution in the final phase
|
|
75
|
+
- When test skeletons are not provided, include test implementation tasks based on Design Doc acceptance criteria
|
|
75
76
|
- Include quality assurance in final phase
|
|
76
77
|
|
|
77
78
|
### 5. Define Tasks with Completion Criteria
|
|
@@ -206,8 +207,8 @@ Verification: L1 — [specific verification method]
|
|
|
206
207
|
Compose phases based on technical dependencies and implementation approach from Design Doc.
|
|
207
208
|
Always include quality assurance (all tests passing, acceptance criteria achieved) in final phase.
|
|
208
209
|
|
|
209
|
-
###
|
|
210
|
-
|
|
210
|
+
### Test Skeleton Integration
|
|
211
|
+
Follow the test skeleton placement rules defined in Step 4 of the Planning Process.
|
|
211
212
|
|
|
212
213
|
## Diagram Creation (using mermaid notation)
|
|
213
214
|
|
|
@@ -219,7 +220,7 @@ When creating work plans, **Phase Structure Diagrams** and **Task Dependency Dia
|
|
|
219
220
|
- [ ] Phase composition based on technical dependencies
|
|
220
221
|
- [ ] All requirements converted to tasks
|
|
221
222
|
- [ ] Quality assurance exists in final phase
|
|
222
|
-
- [ ]
|
|
223
|
+
- [ ] Test skeleton file paths listed in corresponding phases (when provided)
|
|
223
224
|
- [ ] Test design information reflected (only when provided)
|
|
224
225
|
- [ ] Setup tasks placed in first phase
|
|
225
226
|
- [ ] Risk level-based prioritization applied
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "codex-workflows",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.4",
|
|
4
4
|
"description": "Task-oriented agentic coding framework for OpenAI Codex CLI — skills, recipes, and subagents for structured development workflows",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "Shinsuke Kagawa",
|