codex-workflows 0.4.10 → 0.5.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/.agents/skills/coding-rules/references/typescript.md +1 -1
- package/.agents/skills/documentation-criteria/references/plan-template.md +19 -0
- package/.agents/skills/documentation-criteria/references/ui-spec-template.md +2 -0
- package/.agents/skills/integration-e2e-testing/SKILL.md +34 -21
- package/.agents/skills/integration-e2e-testing/references/e2e-design.md +16 -10
- package/.agents/skills/recipe-add-integration-tests/SKILL.md +9 -0
- package/.agents/skills/recipe-build/SKILL.md +34 -5
- package/.agents/skills/recipe-design/SKILL.md +2 -0
- package/.agents/skills/recipe-diagnose/SKILL.md +2 -0
- package/.agents/skills/recipe-front-build/SKILL.md +34 -5
- package/.agents/skills/recipe-front-design/SKILL.md +2 -0
- package/.agents/skills/recipe-front-plan/SKILL.md +3 -1
- package/.agents/skills/recipe-front-review/SKILL.md +31 -11
- package/.agents/skills/recipe-fullstack-build/SKILL.md +34 -5
- package/.agents/skills/recipe-fullstack-implement/SKILL.md +11 -3
- package/.agents/skills/recipe-implement/SKILL.md +14 -4
- package/.agents/skills/recipe-plan/SKILL.md +7 -5
- package/.agents/skills/recipe-prepare-implementation/SKILL.md +162 -0
- package/.agents/skills/recipe-prepare-implementation/agents/openai.yaml +7 -0
- package/.agents/skills/recipe-reverse-engineer/SKILL.md +2 -0
- package/.agents/skills/recipe-review/SKILL.md +36 -6
- package/.agents/skills/recipe-task/SKILL.md +2 -0
- package/.agents/skills/recipe-update-doc/SKILL.md +2 -0
- package/.agents/skills/subagents-orchestration-guide/SKILL.md +37 -33
- package/.agents/skills/subagents-orchestration-guide/references/monorepo-flow.md +1 -1
- package/.agents/skills/task-analyzer/references/skills-index.yaml +13 -5
- package/.agents/skills/testing/references/typescript.md +2 -3
- package/.codex/agents/acceptance-test-generator.toml +69 -31
- package/.codex/agents/task-decomposer.toml +27 -2
- package/.codex/agents/task-executor-frontend.toml +5 -11
- package/.codex/agents/task-executor.toml +8 -14
- package/.codex/agents/technical-designer-frontend.toml +2 -2
- package/.codex/agents/work-planner.toml +54 -17
- package/README.md +12 -2
- package/package.json +1 -1
|
@@ -58,7 +58,8 @@ Test type definitions, budgets, and value-based selection rules are specified in
|
|
|
58
58
|
|
|
59
59
|
Key points:
|
|
60
60
|
- **Integration Tests**: MAX 3 per feature, created alongside implementation
|
|
61
|
-
- **
|
|
61
|
+
- **fixture-e2e**: MAX 3 per feature, created alongside UI implementation, mocked backend / fixture-driven state
|
|
62
|
+
- **service-integration-e2e**: MAX 1-2 per feature, executed in final phase only, live local stack
|
|
62
63
|
|
|
63
64
|
## 4-Phase Generation Process
|
|
64
65
|
|
|
@@ -123,7 +124,7 @@ For each valid AC from Phase 1:
|
|
|
123
124
|
|
|
124
125
|
**Output**: Candidate pool with value metadata
|
|
125
126
|
|
|
126
|
-
### Phase 3: Value-Based Selection (Two-Pass #2)
|
|
127
|
+
### Phase 3: Value-Based Selection and Lane Assignment (Two-Pass #2)
|
|
127
128
|
|
|
128
129
|
Value score and E2E selection rules are defined in **integration-e2e-testing skill**.
|
|
129
130
|
|
|
@@ -138,14 +139,15 @@ Value score and E2E selection rules are defined in **integration-e2e-testing ski
|
|
|
138
139
|
3. **Push-Down Analysis**:
|
|
139
140
|
```
|
|
140
141
|
Can this be unit-tested? → Remove from integration/E2E pool
|
|
141
|
-
Already integration-tested
|
|
142
|
+
Already integration-tested AND verifiable in-process? → Remove from E2E pool
|
|
142
143
|
```
|
|
143
|
-
4. **
|
|
144
|
+
4. **Lane Assignment**:
|
|
144
145
|
```
|
|
145
|
-
|
|
146
|
-
|
|
146
|
+
UI journey verifiable with mocked backend / fixture-driven state → fixture-e2e
|
|
147
|
+
Journey correctness depends on real cross-service behavior → service-integration-e2e
|
|
148
|
+
Service-internal chain only → Not reserved-slot eligible
|
|
147
149
|
```
|
|
148
|
-
5. **Sort by Value Score** (descending order)
|
|
150
|
+
5. **Sort by Value Score within each lane** (descending order)
|
|
149
151
|
|
|
150
152
|
**Output**: Ranked, deduplicated candidate list
|
|
151
153
|
|
|
@@ -153,16 +155,19 @@ Value score and E2E selection rules are defined in **integration-e2e-testing ski
|
|
|
153
155
|
|
|
154
156
|
**Hard Limits per Feature**:
|
|
155
157
|
- **Integration Tests**: MAX 3 tests
|
|
156
|
-
- **
|
|
158
|
+
- **fixture-e2e**: MAX 3 tests
|
|
159
|
+
- **service-integration-e2e**: MAX 1-2 tests
|
|
157
160
|
|
|
158
161
|
**Selection Algorithm**:
|
|
159
162
|
|
|
160
163
|
```
|
|
161
164
|
1. Sort integration candidates by Value Score (descending)
|
|
162
165
|
2. Select up to 3 integration candidates
|
|
163
|
-
3. Reserve 1
|
|
164
|
-
4.
|
|
165
|
-
5.
|
|
166
|
+
3. Reserve 1 fixture-e2e slot for the highest-value user-facing multi-step journey, if one exists
|
|
167
|
+
4. Reserve 1 service-integration-e2e slot only when the journey needs real cross-service verification
|
|
168
|
+
5. Fill remaining fixture-e2e budget with candidates that satisfy `Value Score >= 20`
|
|
169
|
+
6. Fill remaining service-integration-e2e budget with candidates that satisfy `Value Score > 50`
|
|
170
|
+
7. If a lane emits no tests, return its generated file as `null` with a concrete lane-specific absence reason
|
|
166
171
|
```
|
|
167
172
|
|
|
168
173
|
**Output**: Final test set
|
|
@@ -198,24 +203,46 @@ Adapt comment syntax to the project's language when generating annotations.
|
|
|
198
203
|
[Test: 'AC1: Failed payment displays error without creating order']
|
|
199
204
|
```
|
|
200
205
|
|
|
201
|
-
###
|
|
206
|
+
### fixture-e2e Test File
|
|
202
207
|
|
|
203
208
|
```
|
|
204
|
-
// [Feature Name]
|
|
205
|
-
// Generated: [date] | Budget Used: 1/
|
|
206
|
-
// Test Type:
|
|
207
|
-
// Implementation Timing:
|
|
209
|
+
// [Feature Name] fixture-e2e Test - Design Doc: [filename]
|
|
210
|
+
// Generated: [date] | Budget Used: 1/3 fixture-e2e
|
|
211
|
+
// Test Type: Browser UI with mocked backend / fixture-driven state
|
|
212
|
+
// Implementation Timing: Alongside UI implementation
|
|
208
213
|
|
|
209
214
|
[Import statement using detected test framework]
|
|
210
215
|
|
|
211
216
|
[Test suite using detected framework syntax]
|
|
212
|
-
// User Journey:
|
|
213
|
-
// Value Score:
|
|
214
|
-
// Verification:
|
|
215
|
-
// @category: e2e
|
|
217
|
+
// User Journey: Dismiss card -> Undo banner appears -> Undo restores card
|
|
218
|
+
// Value Score: 60 | Business Value: 6 | Frequency: 7 | Defect Detection: 8
|
|
219
|
+
// Verification: Browser-visible state transitions with mocked backend state
|
|
220
|
+
// @category: fixture-e2e
|
|
221
|
+
// @lane: fixture-e2e
|
|
222
|
+
// @dependency: full-ui (mocked backend)
|
|
223
|
+
// @complexity: medium
|
|
224
|
+
[Test: 'User Journey: Dismiss and undo restores the card']
|
|
225
|
+
```
|
|
226
|
+
|
|
227
|
+
### service-integration-e2e Test File
|
|
228
|
+
|
|
229
|
+
```
|
|
230
|
+
// [Feature Name] service-integration-e2e Test - Design Doc: [filename]
|
|
231
|
+
// Generated: [date] | Budget Used: 1/2 service-integration-e2e
|
|
232
|
+
// Test Type: End-to-end against running local stack
|
|
233
|
+
// Implementation Timing: Final phase only
|
|
234
|
+
|
|
235
|
+
[Import statement using detected test framework]
|
|
236
|
+
|
|
237
|
+
[Test suite using detected framework syntax]
|
|
238
|
+
// User Journey: Complete purchase flow (browse -> checkout -> payment -> confirmation persisted)
|
|
239
|
+
// Value Score: 120 | Business Value: 10 (business-critical) | Frequency: 10 (core flow) | Legal: true
|
|
240
|
+
// Verification: Order persists in DB and confirmation event is emitted
|
|
241
|
+
// @category: service-integration-e2e
|
|
242
|
+
// @lane: service-integration-e2e
|
|
216
243
|
// @dependency: full-system
|
|
217
244
|
// @complexity: high
|
|
218
|
-
[Test: 'User Journey: Complete product purchase
|
|
245
|
+
[Test: 'User Journey: Complete product purchase persists order and emits confirmation']
|
|
219
246
|
```
|
|
220
247
|
|
|
221
248
|
### Generation Report
|
|
@@ -226,13 +253,18 @@ Adapt comment syntax to the project's language when generating annotations.
|
|
|
226
253
|
"feature": "[feature name]",
|
|
227
254
|
"generatedFiles": {
|
|
228
255
|
"integration": "[path]/[feature].int.test.[ext]",
|
|
229
|
-
"
|
|
256
|
+
"fixtureE2e": null,
|
|
257
|
+
"serviceE2e": null
|
|
230
258
|
},
|
|
231
259
|
"budgetUsage": {
|
|
232
260
|
"integration": "2/3",
|
|
233
|
-
"
|
|
261
|
+
"fixtureE2e": "0/3",
|
|
262
|
+
"serviceE2e": "0/2"
|
|
234
263
|
},
|
|
235
|
-
"e2eAbsenceReason":
|
|
264
|
+
"e2eAbsenceReason": {
|
|
265
|
+
"fixtureE2e": "all_e2e_candidates_below_threshold",
|
|
266
|
+
"serviceE2e": "no_real_service_dependency"
|
|
267
|
+
}
|
|
236
268
|
}
|
|
237
269
|
```
|
|
238
270
|
|
|
@@ -242,13 +274,18 @@ Adapt comment syntax to the project's language when generating annotations.
|
|
|
242
274
|
"feature": "[feature name]",
|
|
243
275
|
"generatedFiles": {
|
|
244
276
|
"integration": "[path]/[feature].int.test.[ext]",
|
|
245
|
-
"
|
|
277
|
+
"fixtureE2e": "[path]/[feature].fixture.e2e.test.[ext]",
|
|
278
|
+
"serviceE2e": "[path]/[feature].service.e2e.test.[ext]"
|
|
246
279
|
},
|
|
247
280
|
"budgetUsage": {
|
|
248
281
|
"integration": "2/3",
|
|
249
|
-
"
|
|
282
|
+
"fixtureE2e": "1/3",
|
|
283
|
+
"serviceE2e": "1/2"
|
|
250
284
|
},
|
|
251
|
-
"e2eAbsenceReason":
|
|
285
|
+
"e2eAbsenceReason": {
|
|
286
|
+
"fixtureE2e": null,
|
|
287
|
+
"serviceE2e": null
|
|
288
|
+
}
|
|
252
289
|
}
|
|
253
290
|
```
|
|
254
291
|
|
|
@@ -256,8 +293,9 @@ Adapt comment syntax to the project's language when generating annotations.
|
|
|
256
293
|
|
|
257
294
|
Each test case MUST have the following standard annotations for test implementation planning:
|
|
258
295
|
|
|
259
|
-
- **@category**: core-functionality | integration | edge-case | ux
|
|
260
|
-
- **@
|
|
296
|
+
- **@category**: core-functionality | integration | edge-case | ux | fixture-e2e | service-integration-e2e
|
|
297
|
+
- **@lane**: integration | fixture-e2e | service-integration-e2e
|
|
298
|
+
- **@dependency**: none | [component names] | full-ui (mocked backend) | full-system
|
|
261
299
|
- **@complexity**: low | medium | high
|
|
262
300
|
|
|
263
301
|
These annotations are used when planning and prioritizing test implementation.
|
|
@@ -282,7 +320,7 @@ These annotations are used when planning and prioritizing test implementation.
|
|
|
282
320
|
|
|
283
321
|
### Auto-processable
|
|
284
322
|
- **Directory Absent**: Auto-create appropriate directory following detected test structure
|
|
285
|
-
- **No E2E Selected**: Valid outcome when accompanied by `e2eAbsenceReason`
|
|
323
|
+
- **No E2E Selected**: Valid outcome when accompanied by lane-specific `e2eAbsenceReason`
|
|
286
324
|
- **Budget Exceeded by Critical Test**: Report to user
|
|
287
325
|
|
|
288
326
|
### Escalation Required
|
|
@@ -316,7 +354,7 @@ These annotations are used when planning and prioritizing test implementation.
|
|
|
316
354
|
- **Post-execution**:
|
|
317
355
|
- Completeness of selected tests
|
|
318
356
|
- Dependency validity verified
|
|
319
|
-
- Integration tests and
|
|
357
|
+
- Integration tests, fixture-e2e tests, and service-integration-e2e tests generated in separate files when selected
|
|
320
358
|
- Generation report completeness
|
|
321
359
|
|
|
322
360
|
## Completion Gate [BLOCKING]
|
|
@@ -130,8 +130,12 @@ Decompose tasks based on implementation strategy patterns determined in implemen
|
|
|
130
130
|
|---|---|
|
|
131
131
|
| Existing code modification | Files being changed, adjacent tests, relevant Design Doc sections |
|
|
132
132
|
| New feature/component | Adjacent implementations in the same layer/domain, interface-defining Design Doc sections |
|
|
133
|
-
|
|
|
134
|
-
|
|
|
133
|
+
| Frontend component implementation | UI Spec component section cited by the work plan's UI Spec Component -> Task Mapping, interface-defining Design Doc sections, adjacent components |
|
|
134
|
+
| Frontend integration / fixture-e2e test work | UI Spec component section including state and interaction tables, test skeleton file, target implementation, fixture data, browser harness config |
|
|
135
|
+
| Integration test work | Test skeleton file, target implementation under test, existing fixture/auth/setup patterns |
|
|
136
|
+
| fixture-e2e environment/setup work | Existing fixture data, API mock layer, browser harness configuration |
|
|
137
|
+
| service-integration-e2e environment/setup work | Current environment config, startup scripts, seed scripts, auth flow references, external service stubs |
|
|
138
|
+
| Cross-boundary implementation | Connection Map rows touching the task target files, caller/producer module, callee/consumer module, expected signal, contract definition |
|
|
135
139
|
| Bug fix/refactor | Affected code paths, failing tests, reproduction-related files |
|
|
136
140
|
| Behavior replacement/rewrite | Existing implementation being replaced, observable outputs, Verification Strategy section in the Design Doc |
|
|
137
141
|
|
|
@@ -140,6 +144,8 @@ Decompose tasks based on implementation strategy patterns determined in implemen
|
|
|
140
144
|
- Investigation Targets are file paths to read, not actions to perform
|
|
141
145
|
- Use specific paths with optional hints such as `docs/design/payments.md (§ Retry Flow)` or `src/orders/service.ts (createOrder)`
|
|
142
146
|
- When test skeletons exist, include them explicitly
|
|
147
|
+
- When the work plan contains a UI Spec Component -> Task Mapping table, propagate matching component sections to every task listed in the row
|
|
148
|
+
- When the work plan contains a Connection Map, propagate boundary rows touching the task's target files to every task on either side of the boundary
|
|
143
149
|
- When a task matches multiple natures, include Investigation Targets from all matching rows and deduplicate overlaps
|
|
144
150
|
|
|
145
151
|
7. **Implementation Pattern Consistency**
|
|
@@ -185,6 +191,25 @@ When the work plan includes a `Design-to-Plan Traceability` section:
|
|
|
185
191
|
5. **Verification integrity**: For `verification` rows, ensure the corresponding task file includes the required comparison or verification method in Operation Verification Methods.
|
|
186
192
|
6. **Prerequisite integrity**: For `prerequisite` rows, place setup, migration, seed, auth, or environment work before dependent implementation tasks.
|
|
187
193
|
|
|
194
|
+
## UI Spec Propagation
|
|
195
|
+
|
|
196
|
+
When the work plan includes a `UI Spec Component -> Task Mapping` section:
|
|
197
|
+
|
|
198
|
+
1. For each row, locate the task IDs listed in `Covered By Task(s)`.
|
|
199
|
+
2. Add the component section heading to those task files' Investigation Targets.
|
|
200
|
+
3. Include the states listed in `States to Cover` in Investigation Notes and Operation Verification Methods.
|
|
201
|
+
4. Preserve `gap` rows as planning issues and surface them to the caller.
|
|
202
|
+
5. If a task implements UI but no component mapping row covers it, add a warning in the decomposition report.
|
|
203
|
+
|
|
204
|
+
## Connection Map Propagation
|
|
205
|
+
|
|
206
|
+
When the work plan includes a `Connection Map` section:
|
|
207
|
+
|
|
208
|
+
1. For each boundary row, locate all tasks listed in `Covered By Task(s)`.
|
|
209
|
+
2. Add the caller/producer module, callee/consumer module, serialized contract, and expected signal to each listed task's Investigation Targets or Notes.
|
|
210
|
+
3. For tasks on one side of a boundary, include an Operation Verification Method that observes the expected signal from the other side.
|
|
211
|
+
4. Propagate only boundary rows explicitly mapped in the work plan.
|
|
212
|
+
|
|
188
213
|
## Task File Template
|
|
189
214
|
|
|
190
215
|
See task template in documentation-criteria skill for details.
|
|
@@ -133,7 +133,9 @@ Use the appropriate run command based on the `packageManager` field in package.j
|
|
|
133
133
|
|
|
134
134
|
### 1. Task Selection
|
|
135
135
|
|
|
136
|
-
|
|
136
|
+
If the orchestrator prompt provides a task file path, execute only that exact task file. Do not scan or select any other task file.
|
|
137
|
+
|
|
138
|
+
When no task file path is provided, select and execute files with pattern `docs/plans/tasks/*-task-*.md` that have uncompleted checkboxes `[ ]` remaining.
|
|
137
139
|
|
|
138
140
|
### 2. Task Background Understanding
|
|
139
141
|
#### Investigation Targets (Required when present)
|
|
@@ -185,7 +187,7 @@ This is a repeated self-check during implementation, not a one-time pre-implemen
|
|
|
185
187
|
|
|
186
188
|
**Implementation procedure for each checkbox item**:
|
|
187
189
|
1. **Red**: Create React Testing Library test for that checkbox item (failing state)
|
|
188
|
-
※For integration tests
|
|
190
|
+
※For integration tests and fixture-e2e tests, create and execute with the related UI implementation; service-integration-e2e tests are executed in final phase only. Legacy E2E tests without `@lane` are treated as service-integration-e2e unless the task file or skeleton clearly states mocked backend / fixture-driven execution.
|
|
189
191
|
2. **Green**: Implement minimum code to pass test (React function component)
|
|
190
192
|
3. **Refactor**: Improve code quality (readability, maintainability, React best practices)
|
|
191
193
|
4. **Progress Update [MANDATORY]**: Execute the following in sequence (cannot be omitted)
|
|
@@ -211,16 +213,11 @@ Return one of the following as the final response (see Structured Response Speci
|
|
|
211
213
|
- `status: "completed"` — task fully implemented
|
|
212
214
|
- `status: "escalation_needed"` — design deviation or similar component discovered
|
|
213
215
|
|
|
214
|
-
## Research Task Deliverables
|
|
215
|
-
|
|
216
|
-
Research/analysis tasks create deliverable files specified in metadata "Provides".
|
|
217
|
-
Examples: `docs/plans/analysis/component-research.md`, `docs/plans/analysis/api-integration.md`
|
|
218
|
-
|
|
219
216
|
## Structured Response Specification
|
|
220
217
|
|
|
221
218
|
### Field Specifications
|
|
222
219
|
|
|
223
|
-
**requiresTestReview**: Set to `true` when the task added or updated integration tests or
|
|
220
|
+
**requiresTestReview**: Set to `true` when the task added or updated integration tests, fixture-e2e tests, or service-integration-e2e tests. Set to `false` for unit-test-only tasks or tasks with no tests.
|
|
224
221
|
|
|
225
222
|
### 1. Task Completion Response
|
|
226
223
|
Report in the following JSON format upon task completion (**without executing quality checks or commits**, delegating to quality assurance process):
|
|
@@ -380,9 +377,6 @@ When repository-wide verification is insufficient to determine the appropriate d
|
|
|
380
377
|
|
|
381
378
|
**ENFORCEMENT**: HALT if any gate unchecked. Return `status: "escalation_needed"` to caller.
|
|
382
379
|
|
|
383
|
-
## Completion Criteria
|
|
384
|
-
|
|
385
|
-
- [ ] Final response is a single JSON with status `completed` or `escalation_needed`
|
|
386
380
|
"""
|
|
387
381
|
|
|
388
382
|
[[skills.config]]
|
|
@@ -133,7 +133,9 @@ Skill Status:
|
|
|
133
133
|
|
|
134
134
|
### 1. Task Selection
|
|
135
135
|
|
|
136
|
-
|
|
136
|
+
If the orchestrator prompt provides a task file path, execute only that exact task file. Do not scan or select any other task file.
|
|
137
|
+
|
|
138
|
+
When no task file path is provided, select and execute files with pattern `docs/plans/tasks/*-task-*.md` that have uncompleted checkboxes `[ ]` remaining.
|
|
137
139
|
|
|
138
140
|
### 2. Task Background Understanding
|
|
139
141
|
#### Investigation Targets (Required when present)
|
|
@@ -194,7 +196,9 @@ This is a repeated self-check during implementation, not a one-time pre-implemen
|
|
|
194
196
|
**Test types**:
|
|
195
197
|
- Unit tests: RED-GREEN-REFACTOR cycle
|
|
196
198
|
- Integration tests: Create and execute with implementation
|
|
197
|
-
-
|
|
199
|
+
- fixture-e2e tests: Create and execute with the related UI/browser task when the task file specifies that lane
|
|
200
|
+
- service-integration-e2e tests: Execute only in final phase when the task file specifies that lane
|
|
201
|
+
- legacy E2E tests without `@lane`: Treat as service-integration-e2e unless the task file or skeleton clearly states mocked backend / fixture-driven execution
|
|
198
202
|
|
|
199
203
|
#### Operation Verification
|
|
200
204
|
- Execute "Operation Verification Methods" section in task
|
|
@@ -212,16 +216,11 @@ Return one of the following as the final response (see Structured Response Speci
|
|
|
212
216
|
- `status: "completed"` — task fully implemented
|
|
213
217
|
- `status: "escalation_needed"` — design deviation or similar function discovered
|
|
214
218
|
|
|
215
|
-
## Research Task Deliverables
|
|
216
|
-
|
|
217
|
-
Research/analysis tasks create deliverable files specified in metadata "Provides".
|
|
218
|
-
Examples: `docs/plans/analysis/research-results.md`, `docs/plans/analysis/api-spec.md`
|
|
219
|
-
|
|
220
219
|
## Structured Response Specification
|
|
221
220
|
|
|
222
221
|
### Field Specifications
|
|
223
222
|
|
|
224
|
-
**requiresTestReview**: Set to `true` when the task added or updated integration tests or
|
|
223
|
+
**requiresTestReview**: Set to `true` when the task added or updated integration tests, fixture-e2e tests, or service-integration-e2e tests. Set to `false` for unit-test-only tasks or tasks with no tests.
|
|
225
224
|
|
|
226
225
|
### 1. Task Completion Response
|
|
227
226
|
Report in the following JSON format upon task completion (**without executing quality checks or commits**, delegating to quality assurance process):
|
|
@@ -364,11 +363,9 @@ When repository-wide verification is insufficient to determine the appropriate d
|
|
|
364
363
|
```
|
|
365
364
|
|
|
366
365
|
## Execution Principles
|
|
367
|
-
|
|
368
366
|
- Follow RED-GREEN-REFACTOR (see the principles in testing skill)
|
|
369
367
|
- Update progress checkboxes per step
|
|
370
|
-
- Escalate when
|
|
371
|
-
- Escalate when dependency version or representative pattern choice cannot be determined from repository evidence
|
|
368
|
+
- Escalate when design deviation, similar functions, missing investigation targets/test environment, or uncertain dependency/pattern choice blocks repository-evidence-based implementation
|
|
372
369
|
- Stop after implementation and test creation — quality checks and commits are handled separately
|
|
373
370
|
|
|
374
371
|
## Completion Gate [BLOCKING]
|
|
@@ -383,9 +380,6 @@ When repository-wide verification is insufficient to determine the appropriate d
|
|
|
383
380
|
|
|
384
381
|
**ENFORCEMENT**: HALT if any gate unchecked. Return `status: "escalation_needed"` to caller.
|
|
385
382
|
|
|
386
|
-
## Completion Criteria
|
|
387
|
-
|
|
388
|
-
- [ ] Final response is a single JSON with status `completed` or `escalation_needed`
|
|
389
383
|
"""
|
|
390
384
|
|
|
391
385
|
[[skills.config]]
|
|
@@ -119,7 +119,7 @@ Must be performed when creating Design Doc:
|
|
|
119
119
|
1. **Approach Selection Criteria**
|
|
120
120
|
- Execute Phase 1-4 of implementation-approach skill to select strategy
|
|
121
121
|
- **Vertical Slice**: Complete by feature unit, minimal component dependencies, early value delivery
|
|
122
|
-
- **Horizontal Slice**: Implementation by component layer
|
|
122
|
+
- **Horizontal Slice**: Implementation by the project's component layering convention. Use Atomic Design layer names only when the project already adopts Atomic Design.
|
|
123
123
|
- **Hybrid**: Composite, handles complex requirements
|
|
124
124
|
- Document selection reason (record results of metacognitive strategy selection process)
|
|
125
125
|
|
|
@@ -267,7 +267,7 @@ Implementation sample creation checklist:
|
|
|
267
267
|
**Design Doc**: Component hierarchy diagram and data flow diagram are mandatory. Add state transition diagram and sequence diagram for complex cases.
|
|
268
268
|
|
|
269
269
|
**React Diagrams**:
|
|
270
|
-
- Component hierarchy (
|
|
270
|
+
- Component hierarchy (use the project's existing component architecture; Atomic Design labels apply only when adopted)
|
|
271
271
|
- Props flow diagram (parent → child data flow)
|
|
272
272
|
- State management diagram (Context, custom hooks)
|
|
273
273
|
- User interaction flow (click → state update → re-render)
|
|
@@ -43,7 +43,8 @@ Skill Status:
|
|
|
43
43
|
5. Place test implementation and execution appropriately for each phase
|
|
44
44
|
6. Concretize risks and countermeasures
|
|
45
45
|
7. Create explicit Design-to-Plan Traceability so Design Doc technical requirements are covered without silent omission
|
|
46
|
-
8.
|
|
46
|
+
8. Propagate UI Spec component and runtime boundary context into the plan so task decomposition can pass it to executors
|
|
47
|
+
9. Document in progress-trackable format
|
|
47
48
|
|
|
48
49
|
## Input Parameters
|
|
49
50
|
|
|
@@ -53,8 +54,8 @@ Skill Status:
|
|
|
53
54
|
- **prd** (optional): Path to PRD document
|
|
54
55
|
- **adr** (optional): Path to ADR document
|
|
55
56
|
- **testSkeletons** (optional): Paths to integration/E2E test skeleton files from acceptance-test-generator
|
|
56
|
-
- `generatedFiles.
|
|
57
|
-
- When provided, carry `e2eAbsenceReason` into the work plan and treat it as an explicit planning input
|
|
57
|
+
- `generatedFiles.fixtureE2e` and `generatedFiles.serviceE2e` may be `null` when a lane is intentionally not generated
|
|
58
|
+
- When provided, carry lane-specific `e2eAbsenceReason` into the work plan and treat it as an explicit planning input
|
|
58
59
|
- **updateContext** (update mode only): Path to existing plan, reason for changes
|
|
59
60
|
|
|
60
61
|
## Workflow
|
|
@@ -86,7 +87,9 @@ Choose Strategy A (TDD) if test skeletons are provided, Strategy B (implementati
|
|
|
86
87
|
- Place tasks with the lowest dependencies in earlier phases
|
|
87
88
|
- Map normalized verification timing to phases as follows: `phase_1` -> earliest implementation phase, `per_phase` -> each relevant phase, `integration_phase` -> integration phase, `final_phase` -> final Quality Assurance phase
|
|
88
89
|
- Include verification tasks in the phase corresponding to the Verification Strategy timing
|
|
89
|
-
- When test skeletons are provided, place integration test implementation based on `@dependency` metadata from test skeletons (see Test Design Information Processing > Step 2)
|
|
90
|
+
- When test skeletons are provided, place integration test implementation based on `@dependency` metadata from test skeletons (see Test Design Information Processing > Step 2)
|
|
91
|
+
- When fixture-e2e skeletons are provided, place creation/execution alongside the relevant UI implementation phase
|
|
92
|
+
- When service-integration-e2e skeletons are provided, place execution-only tasks in the final phase
|
|
90
93
|
- When test skeletons are not provided, include test implementation tasks based on Design Doc acceptance criteria
|
|
91
94
|
- Final phase is always Quality Assurance
|
|
92
95
|
|
|
@@ -115,12 +118,37 @@ Traceability rules:
|
|
|
115
118
|
- Any `gap` without justification is an error
|
|
116
119
|
- Any justified `gap` must be flagged for user confirmation before plan approval
|
|
117
120
|
|
|
121
|
+
### 5a. Map UI Spec Components to Tasks
|
|
122
|
+
|
|
123
|
+
When a UI Spec is provided, map each documented component to the task(s) that implement it or test it.
|
|
124
|
+
|
|
125
|
+
Rules:
|
|
126
|
+
- Use the UI Spec component section heading exactly as written.
|
|
127
|
+
- Identify required states such as default, loading, empty, error, and partial.
|
|
128
|
+
- Record the mapping in the `UI Spec Component -> Task Mapping` table from the plan template.
|
|
129
|
+
- Mark components with no covering task as `gap` with justification and user confirmation before approval.
|
|
130
|
+
|
|
131
|
+
### 5b. Map Runtime Boundaries to Tasks
|
|
132
|
+
|
|
133
|
+
When implementation crosses runtime, process, deployment, or service boundaries, create a `Connection Map`.
|
|
134
|
+
|
|
135
|
+
A boundary qualifies only when all of the following hold:
|
|
136
|
+
- The two sides run in separate processes, services, runtimes, or deployed artifacts.
|
|
137
|
+
- A serialized contract crosses the boundary, such as HTTP, RPC, event payload, queue message, or webhook payload.
|
|
138
|
+
- A failure on one side creates an observable signal on the other side, such as a status code, timeout, missing field, dropped message, or persisted row.
|
|
139
|
+
|
|
140
|
+
Map only boundaries satisfying all three qualifications above: separate runtime, serialized contract, and observable cross-side signal.
|
|
141
|
+
|
|
142
|
+
For each boundary, record the caller/producer, callee/consumer, expected signal, and covering tasks in the `Connection Map` table.
|
|
143
|
+
|
|
118
144
|
### 6. Define Tasks with Completion Criteria
|
|
119
145
|
For each task, derive completion criteria from Design Doc acceptance criteria. Apply the 3-element completion definition (Implementation Complete, Quality Complete, Integration Complete).
|
|
120
146
|
|
|
121
147
|
### 7. Produce Work Plan Document
|
|
122
148
|
Write the work plan following the plan template from documentation-criteria skill. Include Phase Structure Diagram and Task Dependency Diagram (mermaid).
|
|
123
149
|
|
|
150
|
+
The plan header MUST include `Implementation Readiness: pending`. This marker is promoted by the implementation-readiness orchestration before build execution.
|
|
151
|
+
|
|
124
152
|
## Work Plan Output Format
|
|
125
153
|
|
|
126
154
|
- Storage location and naming convention follow the principles in documentation-criteria skill
|
|
@@ -161,7 +189,8 @@ Create Red state tests based on unit test definitions provided from previous pro
|
|
|
161
189
|
**Test Implementation Timing and Placement**:
|
|
162
190
|
- Unit tests: Phase 0 Red → Green during implementation
|
|
163
191
|
- Integration tests: Create and execute at completion of relevant feature implementation (include in phase tasks like "[Feature name] implementation with integration test creation")
|
|
164
|
-
-
|
|
192
|
+
- fixture-e2e tests: Create and execute alongside the relevant UI feature implementation
|
|
193
|
+
- service-integration-e2e tests: Execute only in final phase
|
|
165
194
|
|
|
166
195
|
#### Meta Information Utilization
|
|
167
196
|
Analyze meta information (@category, @dependency, @complexity, etc.) included in test definitions,
|
|
@@ -181,6 +210,7 @@ Read available test skeleton files (integration tests, and E2E tests only when p
|
|
|
181
210
|
|
|
182
211
|
**Comment patterns to extract**:
|
|
183
212
|
- `// @category:` → Test classification (core-functionality, edge-case, e2e, etc.)
|
|
213
|
+
- `// @lane:` → Test lane (integration, fixture-e2e, service-integration-e2e)
|
|
184
214
|
- `// @dependency:` → Dependent components (material for phase placement decisions)
|
|
185
215
|
- `// @complexity:` → Complexity (high/medium/low, material for effort estimation)
|
|
186
216
|
- `// Value Score:` → Priority judgment
|
|
@@ -190,6 +220,7 @@ Read available test skeleton files (integration tests, and E2E tests only when p
|
|
|
190
220
|
1. **Dependency-based Phase Placement**
|
|
191
221
|
- `// @dependency: none` → Place in earlier phases
|
|
192
222
|
- `// @dependency: [component name]` → Place in phase after dependent component implementation
|
|
223
|
+
- `// @dependency: full-ui (mocked backend)` → Place alongside UI implementation
|
|
193
224
|
- `// @dependency: full-system` → Place in final phase
|
|
194
225
|
|
|
195
226
|
2. **Complexity-based Effort Estimation**
|
|
@@ -198,32 +229,36 @@ Read available test skeleton files (integration tests, and E2E tests only when p
|
|
|
198
229
|
|
|
199
230
|
#### Step 3: Extract Environment Prerequisites from E2E Skeletons
|
|
200
231
|
|
|
201
|
-
When E2E test skeletons are provided, first identify the E2E skeleton subset using file naming conventions such as `*.e2e.test
|
|
232
|
+
When E2E test skeletons are provided, first identify the E2E skeleton subset using file naming conventions such as `*.fixture.e2e.test.*`, `*.service.e2e.test.*`, or `*.e2e.test.*`, then scan only those files for environment prerequisites in two stages:
|
|
202
233
|
|
|
203
234
|
**Stage 1: Detect precondition patterns**
|
|
204
235
|
- `Preconditions:` annotations mentioning seed data, test users, subscriptions, or required DB state
|
|
236
|
+
- `@lane: fixture-e2e` or `@dependency: full-ui (mocked backend)` combined with fixture loaders or API mock handlers
|
|
205
237
|
- `@dependency: full-system` combined with auth/login setup
|
|
206
238
|
- Environment variable references such as `E2E_*` or `TEST_*`
|
|
207
239
|
- External service dependencies that require mock/intercept or a running local dependency
|
|
208
240
|
|
|
209
241
|
**Stage 2: Generate Phase 0 setup tasks**
|
|
210
|
-
-
|
|
211
|
-
-
|
|
212
|
-
-
|
|
213
|
-
-
|
|
242
|
+
- fixture-e2e fixture data → Add a Phase 0 task for fixture state files
|
|
243
|
+
- fixture-e2e mocked backend → Add a Phase 0 task for the project's API mock layer
|
|
244
|
+
- fixture-e2e browser harness → Add a Phase 0 task for Playwright or the project's browser harness
|
|
245
|
+
- service-integration-e2e seed data → Add a Phase 0 task for seed preparation
|
|
246
|
+
- service-integration-e2e auth fixture/login state → Add a Phase 0 task for auth setup
|
|
247
|
+
- service-integration-e2e external service stubs → Add a Phase 0 task for stubs or intercepts
|
|
248
|
+
- service-integration-e2e environment configuration → Add a Phase 0 task for env vars and local service startup
|
|
214
249
|
- Other prerequisites → Add a matching setup task with clear traceability to the E2E skeleton
|
|
215
250
|
|
|
216
|
-
Place these setup tasks before implementation and annotate them as E2E setup work.
|
|
251
|
+
Place these setup tasks before implementation and annotate them as E2E setup work with the relevant lane.
|
|
217
252
|
|
|
218
253
|
#### Step 3a: E2E Absence Handling
|
|
219
254
|
|
|
220
|
-
When
|
|
221
|
-
- Require `e2eAbsenceReason` from the generator output
|
|
255
|
+
When an E2E lane generated file is `null`:
|
|
256
|
+
- Require the corresponding lane-specific `e2eAbsenceReason` from the generator output
|
|
222
257
|
- Record the absence reason in the work plan header
|
|
223
|
-
- Skip
|
|
224
|
-
- Accept the null E2E
|
|
258
|
+
- Skip prerequisite extraction and execution task creation for that lane
|
|
259
|
+
- Accept the null E2E lane as a valid planning input when a concrete absence reason is present
|
|
225
260
|
|
|
226
|
-
When
|
|
261
|
+
When an E2E lane generated file is `null` and its `e2eAbsenceReason` is missing:
|
|
227
262
|
- Flag a planning gap for user confirmation before plan approval
|
|
228
263
|
|
|
229
264
|
#### Step 4: Classify and Place Tests
|
|
@@ -232,7 +267,9 @@ When `generatedFiles.e2e` is `null` and `e2eAbsenceReason` is missing:
|
|
|
232
267
|
- Setup items (Mock preparation, measurement tools, Helpers, etc.) → Prioritize in Phase 1
|
|
233
268
|
- Unit tests (individual functions) → Start from Phase 0 with Red-Green-Refactor
|
|
234
269
|
- Integration tests → Place as create/execute tasks when relevant feature implementation is complete
|
|
235
|
-
-
|
|
270
|
+
- fixture-e2e tests → Place as create/execute tasks alongside relevant UI implementation
|
|
271
|
+
- service-integration-e2e tests → Place as execute-only tasks in final phase when a skeleton exists
|
|
272
|
+
- legacy E2E tests without a lane → Treat as service-integration-e2e unless the skeleton clearly uses mocked backend fixtures
|
|
236
273
|
- Non-functional requirement tests (performance, UX, etc.) → Place in quality assurance phase
|
|
237
274
|
- Risk levels ("high risk", "required", etc.) → Move to earlier phases
|
|
238
275
|
|
package/README.md
CHANGED
|
@@ -27,8 +27,6 @@ $recipe-implement Add user authentication with JWT
|
|
|
27
27
|
|
|
28
28
|
Small changes stay lightweight. Larger tasks get structure: requirements → design → task decomposition → TDD implementation → quality gates.
|
|
29
29
|
|
|
30
|
-
codex-workflows is the Codex-native counterpart of [Claude Code Workflows](https://github.com/shinpr/claude-code-workflows): same document-driven development style, adapted for Codex CLI, subagents, and GPT models.
|
|
31
|
-
|
|
32
30
|
---
|
|
33
31
|
|
|
34
32
|
## Why codex-workflows?
|
|
@@ -159,6 +157,7 @@ Invoke recipes with `$recipe-name` in Codex. Type `$recipe-` and use tab complet
|
|
|
159
157
|
| `$recipe-task` | Single task with rule selection | Bug fixes, small changes |
|
|
160
158
|
| `$recipe-design` | Requirements → ADR/Design Doc | Architecture planning |
|
|
161
159
|
| `$recipe-plan` | Design Doc → test skeletons → work plan | Planning phase, including nullable E2E skeleton handling |
|
|
160
|
+
| `$recipe-prepare-implementation` | Verify work plan readiness and resolve prep gaps | Pre-build check that the plan is implementable |
|
|
162
161
|
| `$recipe-build` | Execute backend tasks autonomously | Resume backend implementation |
|
|
163
162
|
| `$recipe-review` | Design Doc compliance and security validation with auto-fixes | Post-implementation check |
|
|
164
163
|
| `$recipe-diagnose` | Problem investigation → failure-point verification → solution | Bug investigation |
|
|
@@ -182,6 +181,16 @@ Invoke recipes with `$recipe-name` in Codex. Type `$recipe-` and use tab complet
|
|
|
182
181
|
| `$recipe-fullstack-implement` | Full lifecycle with separate Design Docs per layer | Cross-layer features |
|
|
183
182
|
| `$recipe-fullstack-build` | Execute tasks with layer-aware agent routing | Resume cross-layer implementation |
|
|
184
183
|
|
|
184
|
+
### Working State
|
|
185
|
+
|
|
186
|
+
Recipes use `docs/plans/` as ephemeral working state for work plans, decomposed task files, prep tasks, review-fix tasks, and intermediate analysis files. Add it to your project's `.gitignore` unless your team intentionally wants to review those transient files:
|
|
187
|
+
|
|
188
|
+
```gitignore
|
|
189
|
+
docs/plans/
|
|
190
|
+
```
|
|
191
|
+
|
|
192
|
+
PRDs, ADRs, UI Specs, and Design Docs are durable project documents and are intended to be committed.
|
|
193
|
+
|
|
185
194
|
### Examples
|
|
186
195
|
|
|
187
196
|
**Full feature development:**
|
|
@@ -315,6 +324,7 @@ your-project/
|
|
|
315
324
|
│ ├── recipe-design/
|
|
316
325
|
│ ├── recipe-build/
|
|
317
326
|
│ ├── recipe-plan/
|
|
327
|
+
│ ├── recipe-prepare-implementation/
|
|
318
328
|
│ ├── recipe-review/
|
|
319
329
|
│ ├── recipe-diagnose/
|
|
320
330
|
│ ├── recipe-task/
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "codex-workflows",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.5.0",
|
|
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",
|