codex-workflows 0.4.6 → 0.4.7
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.
|
@@ -36,26 +36,74 @@ Skill Status:
|
|
|
36
36
|
|
|
37
37
|
## Detection Criteria (The Only Rule)
|
|
38
38
|
|
|
39
|
-
**Detection Target**:
|
|
40
|
-
|
|
41
|
-
**Rationale**:
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
-
|
|
57
|
-
|
|
58
|
-
|
|
39
|
+
**Detection Target**: Only compare items explicitly extractable from the source file. Ignore items that are not documented in the source file.
|
|
40
|
+
|
|
41
|
+
**Rationale**: design-sync is a candidate generator for downstream review by the orchestrator and/or a human reviewer. Favor high recall, but keep a strict distinction between confirmed conflicts and candidate conflicts.
|
|
42
|
+
|
|
43
|
+
### Match Basis Rules
|
|
44
|
+
|
|
45
|
+
Each detected item MUST include `match_basis` and `confidence`.
|
|
46
|
+
|
|
47
|
+
**high confidence** (confirmed conflict):
|
|
48
|
+
- `exact_string`: identical identifier string in both documents
|
|
49
|
+
- `explicit_alias`: one document explicitly links the identifier to an alias in the other
|
|
50
|
+
|
|
51
|
+
**medium confidence** (candidate conflict):
|
|
52
|
+
- `same_endpoint_role`: same user-facing or service-facing endpoint role with differing path/version/handler details
|
|
53
|
+
- `same_integration_role`: same service or component role in the same flow stage with differing method names, parameters, or outputs
|
|
54
|
+
- `same_ac_slot`: same user action or trigger and same outcome category, but differing conditions, constraints, or thresholds
|
|
55
|
+
- `same_numeric_role`: same normalized config or threshold role with differing numeric values
|
|
56
|
+
- `same_term_role`: same normalized domain term role with differing definition text
|
|
57
|
+
|
|
58
|
+
**Candidate evidence rule**:
|
|
59
|
+
- Medium-confidence matches MUST include a `reason`
|
|
60
|
+
- `reason` MUST describe the structural evidence connecting the items
|
|
61
|
+
- Candidate conflicts require a valid medium-confidence `match_basis`; do not invent new values
|
|
62
|
+
|
|
63
|
+
**General shared signals for candidate matching**:
|
|
64
|
+
- `resource_key`: normalized resource or domain noun extracted from the identifier. Match only when the normalized noun is identical after singular/plural normalization
|
|
65
|
+
- `trigger_key`: normalized trigger phrase describing the initiating user or system action. Match only when the normalized verb family and target resource are both identical
|
|
66
|
+
- `outcome_key`: normalized observable result phrase. Match only when the normalized outcome verb family and target resource are both identical
|
|
67
|
+
- `stage_key`: one of `route_entry`, `service_entry`, `validation`, `persistence_read`, `persistence_write`, `event_emit`, `render`, `other`. Match only when the enumerated stage is identical
|
|
68
|
+
|
|
69
|
+
**Numeric-role signals**:
|
|
70
|
+
- `numeric_key`: normalized config or threshold identifier. Match only when the normalized numeric role is identical
|
|
71
|
+
- `unit_key`: normalized measurement unit (`ms`, `seconds`, `minutes`, `percent`, `count`, `bytes`). Match only when the unit is identical
|
|
72
|
+
- `scope_key`: normalized feature or subsystem scope for the numeric parameter (`retry`, `checkout`, `auth`, `cache`). Match only when the scope is identical
|
|
73
|
+
|
|
74
|
+
**Term-role signals**:
|
|
75
|
+
- `term_key`: normalized canonical term name. Match only when the normalized term is identical
|
|
76
|
+
- `subject_key`: normalized subject that the term defines (`order_fulfillment`, `session_lifecycle`, `inventory_reservation`). Match only when the subject is identical
|
|
77
|
+
- `boundary_key`: normalized boundary or span phrase expressed by the definition (`payment_confirmation_to_carrier_handoff`). Match only when the normalized boundary is identical
|
|
78
|
+
|
|
79
|
+
**Signal counting rule**:
|
|
80
|
+
- For `same_endpoint_role`, `same_integration_role`, and `same_ac_slot`, count only `resource_key`, `trigger_key`, `outcome_key`, and `stage_key`
|
|
81
|
+
- For `same_numeric_role`, count only `numeric_key`, `unit_key`, and `scope_key`
|
|
82
|
+
- For `same_term_role`, count only `term_key`, `subject_key`, and `boundary_key`
|
|
83
|
+
- Count a signal only when its matching rule is satisfied exactly
|
|
84
|
+
- Never count `trigger_key` or `outcome_key` when the value is `none`
|
|
85
|
+
- Never count `stage_key` when its value is `other`
|
|
86
|
+
- Never count `unit_key`, `scope_key`, `subject_key`, or `boundary_key` when the value is `none`
|
|
87
|
+
- `same_endpoint_role`, `same_integration_role`, and `same_ac_slot` require at least 2 matching signals
|
|
88
|
+
- `same_numeric_role` requires `numeric_key` plus at least 1 of `unit_key` or `scope_key`
|
|
89
|
+
- `same_term_role` requires `term_key` plus at least 1 of `subject_key` or `boundary_key`
|
|
90
|
+
|
|
91
|
+
**Match basis selection order**:
|
|
92
|
+
1. `exact_string`
|
|
93
|
+
2. `explicit_alias`
|
|
94
|
+
3. `same_endpoint_role`
|
|
95
|
+
4. `same_integration_role`
|
|
96
|
+
5. `same_ac_slot`
|
|
97
|
+
6. `same_numeric_role`
|
|
98
|
+
7. `same_term_role`
|
|
99
|
+
|
|
100
|
+
Select the first rule in this order whose requirements are satisfied.
|
|
101
|
+
|
|
102
|
+
**Core constraints**:
|
|
103
|
+
- Confirmed conflicts use only `exact_string` or `explicit_alias`
|
|
104
|
+
- Candidate conflicts require an allowed medium-confidence `match_basis` plus that match-basis' required signals
|
|
105
|
+
- Section proximity alone does not establish the same design slot
|
|
106
|
+
- Scope is detection and reporting only. Provide conflict recommendations, but do not resolve conflicts
|
|
59
107
|
|
|
60
108
|
## Input Parameters
|
|
61
109
|
|
|
@@ -73,53 +121,107 @@ Skill Status:
|
|
|
73
121
|
|
|
74
122
|
Read the Design Doc specified in arguments and extract:
|
|
75
123
|
|
|
76
|
-
**Extraction Targets**:
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
-
|
|
81
|
-
|
|
82
|
-
|
|
124
|
+
**Extraction Targets**: term definitions, type definitions, numeric parameters, component names, path identifiers, integration points, and acceptance criteria.
|
|
125
|
+
|
|
126
|
+
**Extraction Output**:
|
|
127
|
+
```yaml
|
|
128
|
+
- identifier: "[exact string from source document]"
|
|
129
|
+
category: "[term | type | numeric | component | path | integration | acceptance-criteria]"
|
|
130
|
+
section: "[section where found]"
|
|
131
|
+
context: "[definition | reference | constraint]"
|
|
132
|
+
resource_key: "[normalized noun or none]"
|
|
133
|
+
trigger_key: "[normalized trigger phrase or none]"
|
|
134
|
+
outcome_key: "[normalized observable result phrase or none]"
|
|
135
|
+
stage_key: "[route_entry | service_entry | validation | persistence_read | persistence_write | event_emit | render | other]"
|
|
136
|
+
numeric_key: "[normalized config or threshold identifier, else none]"
|
|
137
|
+
unit_key: "[normalized measurement unit, else none]"
|
|
138
|
+
scope_key: "[normalized feature or subsystem scope, else none]"
|
|
139
|
+
term_key: "[normalized canonical term name, else none]"
|
|
140
|
+
subject_key: "[normalized definition subject, else none]"
|
|
141
|
+
boundary_key: "[normalized boundary/span phrase, else none]"
|
|
142
|
+
alias_of: "[exact identifier if explicitly aliased, else none]"
|
|
143
|
+
```
|
|
144
|
+
|
|
145
|
+
**Key derivation rules**:
|
|
146
|
+
- `resource_key`: normalize the primary domain noun to lowercase snake_case singular. For URL paths, use the last non-parameter path segment. For component/service/class identifiers, use the leading domain noun before suffixes such as `Service`, `Controller`, `Repository`, `Client`. For free-text terms, use the canonical term noun phrase
|
|
147
|
+
- `trigger_key`: normalize to lowercase verb-plus-target form only when the text describes an initiating action. For endpoints, use HTTP method plus normalized resource (for example `post_order`). For acceptance criteria, use the triggering action phrase. Otherwise use `none`
|
|
148
|
+
- `outcome_key`: normalize to lowercase verb-plus-target form only when the text describes an observable result or produced artifact. For pure config names or pure term definitions, use `none`
|
|
149
|
+
- `stage_key`: assign the closest enumerated lifecycle stage from the identifier/context. Use `other` only when no enumerated stage applies
|
|
150
|
+
- `numeric_key`: for numeric parameters, normalize the parameter name to lowercase snake_case without the value or unit (for example `retry_backoff_initial_delay`). Otherwise use `none`
|
|
151
|
+
- `unit_key`: for numeric parameters, normalize the unit token to lowercase canonical form (`ms`, `seconds`, `minutes`, `percent`, `count`, `bytes`). Otherwise use `none`
|
|
152
|
+
- `scope_key`: for numeric parameters, normalize the owning feature or subsystem to lowercase snake_case (`retry`, `checkout`, `auth`, `cache`). Otherwise use `none`
|
|
153
|
+
- `term_key`: for term definitions, normalize the canonical term name to lowercase snake_case. Otherwise use `none`
|
|
154
|
+
- `subject_key`: for term definitions, normalize the subject being defined to lowercase snake_case. Otherwise use `none`
|
|
155
|
+
- `boundary_key`: for term definitions, normalize the boundary/span phrase to lowercase snake_case with `from_to` wording when applicable. Otherwise use `none`
|
|
156
|
+
- `alias_of`: set to the exact referenced identifier only when the document explicitly states an alias/equivalence. Otherwise use `none`
|
|
83
157
|
|
|
84
158
|
### 2. Survey All Design Docs
|
|
85
159
|
|
|
86
|
-
- Search docs/design/*.md
|
|
87
|
-
-
|
|
88
|
-
- Detect conflict patterns
|
|
160
|
+
- Search `docs/design/*.md` excluding the template and `source_design`
|
|
161
|
+
- Extract target-document items with the same schema and key derivation rules
|
|
89
162
|
|
|
90
163
|
### 3. Conflict Classification and Severity Assessment
|
|
91
164
|
|
|
92
|
-
**
|
|
93
|
-
1. Extract each item
|
|
94
|
-
2.
|
|
95
|
-
3.
|
|
96
|
-
4.
|
|
165
|
+
**Conflict Detection Process**:
|
|
166
|
+
1. Extract each item from the source file using the extraction output format
|
|
167
|
+
2. Derive and record all normalized keys for each extracted item: `resource_key`, `trigger_key`, `outcome_key`, `stage_key`, `numeric_key`, `unit_key`, `scope_key`, `term_key`, `subject_key`, `boundary_key`, and `alias_of`
|
|
168
|
+
3. Extract candidate items from each target document using the same extraction output format and key derivation rules
|
|
169
|
+
4. For each source item, search all normalized target-document items for matches using Match Basis Rules
|
|
170
|
+
5. Select `match_basis` using the required selection order
|
|
171
|
+
6. Record a `confirmed_conflict` when values differ and confidence is high
|
|
172
|
+
7. Record a `candidate_conflict` when values differ and confidence is medium
|
|
173
|
+
8. Items not in the source file are not detection targets
|
|
174
|
+
|
|
175
|
+
**explicit_alias application rule**:
|
|
176
|
+
- Apply `explicit_alias` only when one item's `alias_of` equals the other item's exact `identifier`
|
|
177
|
+
- Do not infer aliases from similarity; the alias relationship must be explicit in the document text
|
|
178
|
+
|
|
179
|
+
**Category to candidate match-basis mapping**:
|
|
180
|
+
|
|
181
|
+
| Source category | Allowed medium-confidence match_basis |
|
|
182
|
+
|----------------|----------------------------------------|
|
|
183
|
+
| `path` | `same_endpoint_role` |
|
|
184
|
+
| `integration`, `component` | `same_integration_role` |
|
|
185
|
+
| `acceptance-criteria` | `same_ac_slot` |
|
|
186
|
+
| `numeric` | `same_numeric_role` |
|
|
187
|
+
| `term` | `same_term_role` |
|
|
188
|
+
| `type` | none — use only high-confidence matching |
|
|
97
189
|
|
|
98
190
|
| Conflict Type | Criteria | Severity |
|
|
99
191
|
|--------------|----------|----------|
|
|
100
|
-
| **Type definition mismatch** |
|
|
101
|
-
| **
|
|
102
|
-
| **
|
|
103
|
-
| **
|
|
104
|
-
| **
|
|
105
|
-
| **No conflict** | Item not in source file | - |
|
|
192
|
+
| **Type definition mismatch** | Same type/interface role, different properties or field types | critical |
|
|
193
|
+
| **Path or integration point conflict** | Same path or integration role, different target/method/handler | critical |
|
|
194
|
+
| **Numeric parameter mismatch** | Same config role, different value | high |
|
|
195
|
+
| **Acceptance criteria conflict** | Same AC slot, different conditions or thresholds | high |
|
|
196
|
+
| **Term definition mismatch** | Same term role, different definition text | medium |
|
|
106
197
|
|
|
107
198
|
### 4. Decision Flow
|
|
108
199
|
|
|
109
200
|
```
|
|
110
|
-
|
|
201
|
+
Item extracted from source file?
|
|
111
202
|
No → Not a detection target (end)
|
|
112
|
-
Yes →
|
|
113
|
-
No → No
|
|
114
|
-
Yes →
|
|
203
|
+
Yes → Match found in other files via Match Basis Rules?
|
|
204
|
+
No → No comparison target (end)
|
|
205
|
+
Yes → Select highest-priority applicable match_basis
|
|
206
|
+
No valid match_basis → No conflict (end)
|
|
207
|
+
high-confidence basis → Value/definition/referent differs?
|
|
208
|
+
No → No conflict (end)
|
|
209
|
+
Yes → Record confirmed_conflict
|
|
210
|
+
medium-confidence basis → Do the required signals for that match_basis match exactly?
|
|
211
|
+
No → No conflict (end)
|
|
212
|
+
Yes → Value/definition/referent differs?
|
|
213
|
+
No → No conflict (end)
|
|
214
|
+
Yes → Record candidate_conflict
|
|
115
215
|
|
|
116
216
|
Severity Assessment:
|
|
117
|
-
- Type/integration point → critical (implementation error risk)
|
|
217
|
+
- Type/path/integration point → critical (implementation error risk)
|
|
118
218
|
- Numeric/acceptance criteria → high (behavior impact)
|
|
119
219
|
- Term → medium (confusion risk)
|
|
120
220
|
```
|
|
121
221
|
|
|
122
|
-
**When in doubt**:
|
|
222
|
+
**When in doubt**:
|
|
223
|
+
- If the item is not explicitly documented in the source file, skip it
|
|
224
|
+
- Otherwise apply the category mapping and required-signal rule
|
|
123
225
|
|
|
124
226
|
## Output Format
|
|
125
227
|
|
|
@@ -138,12 +240,16 @@ Severity Assessment:
|
|
|
138
240
|
"critical": 1,
|
|
139
241
|
"high": 1,
|
|
140
242
|
"medium": 0,
|
|
243
|
+
"confirmed_conflicts": 1,
|
|
244
|
+
"candidate_conflicts": 1,
|
|
141
245
|
"sync_status": "CONFLICTS_FOUND"
|
|
142
246
|
},
|
|
143
|
-
"
|
|
247
|
+
"confirmed_conflicts": [
|
|
144
248
|
{
|
|
145
249
|
"id": "CONFLICT-001",
|
|
146
250
|
"severity": "critical",
|
|
251
|
+
"confidence": "high",
|
|
252
|
+
"match_basis": "exact_string",
|
|
147
253
|
"type": "Type definition mismatch",
|
|
148
254
|
"source_file": "[source file]",
|
|
149
255
|
"source_location": "[section/line]",
|
|
@@ -154,11 +260,30 @@ Severity Assessment:
|
|
|
154
260
|
"recommendation": "[Recommend unifying to source file's value]"
|
|
155
261
|
}
|
|
156
262
|
],
|
|
263
|
+
"candidate_conflicts": [
|
|
264
|
+
{
|
|
265
|
+
"id": "CANDIDATE-001",
|
|
266
|
+
"severity": "high",
|
|
267
|
+
"confidence": "medium",
|
|
268
|
+
"match_basis": "same_ac_slot",
|
|
269
|
+
"type": "Acceptance criteria conflict",
|
|
270
|
+
"source_file": "[source file]",
|
|
271
|
+
"source_location": "[section/line]",
|
|
272
|
+
"source_value": "[content in source file]",
|
|
273
|
+
"target_file": "[file with conflict]",
|
|
274
|
+
"target_location": "[section/line]",
|
|
275
|
+
"target_value": "[conflicting content]",
|
|
276
|
+
"reason": "[structural evidence linking the items]",
|
|
277
|
+
"recommendation": "[Recommend reviewing whether these describe the same design slot]"
|
|
278
|
+
}
|
|
279
|
+
],
|
|
157
280
|
"no_conflicts_docs": ["[filename1]", "[filename2]"]
|
|
158
281
|
}
|
|
159
282
|
```
|
|
160
283
|
|
|
161
|
-
|
|
284
|
+
`total_conflicts` MUST equal `confirmed_conflicts + candidate_conflicts`.
|
|
285
|
+
|
|
286
|
+
When no conflicts: `"sync_status": "NO_CONFLICTS"`, `"confirmed_conflicts": []`, `"candidate_conflicts": []`
|
|
162
287
|
|
|
163
288
|
### SKIP Status
|
|
164
289
|
|
|
@@ -175,7 +300,8 @@ When fewer than 2 Design Docs exist, return immediately:
|
|
|
175
300
|
"sync_status": "SKIPPED",
|
|
176
301
|
"reason": "fewer_than_2_design_docs"
|
|
177
302
|
},
|
|
178
|
-
"
|
|
303
|
+
"confirmed_conflicts": [],
|
|
304
|
+
"candidate_conflicts": []
|
|
179
305
|
}
|
|
180
306
|
```
|
|
181
307
|
|
|
@@ -183,44 +309,107 @@ ENFORCEMENT: sync_status MUST be one of: CONFLICTS_FOUND | NO_CONFLICTS | SKIPPE
|
|
|
183
309
|
|
|
184
310
|
## Detection Pattern Examples
|
|
185
311
|
|
|
186
|
-
###
|
|
312
|
+
### High confidence: exact_string (type definition)
|
|
187
313
|
```
|
|
188
314
|
Source Design Doc:
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
role: admin | user
|
|
315
|
+
OrderItem
|
|
316
|
+
quantity: number
|
|
317
|
+
unitPrice: number
|
|
193
318
|
|
|
194
319
|
Other Design Doc (conflict):
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
320
|
+
OrderItem
|
|
321
|
+
quantity: string # different type
|
|
322
|
+
unitPrice: number
|
|
323
|
+
discount: number # extra property
|
|
199
324
|
```
|
|
200
325
|
|
|
201
|
-
###
|
|
326
|
+
### Medium confidence: same_endpoint_role
|
|
202
327
|
```
|
|
203
328
|
# Source Design Doc
|
|
204
|
-
|
|
329
|
+
POST /api/v2/orders -> OrderController.create
|
|
205
330
|
|
|
206
331
|
# Other Design Doc (conflict)
|
|
207
|
-
|
|
332
|
+
POST /api/v1/orders -> OrderController.submit
|
|
208
333
|
```
|
|
209
334
|
|
|
210
|
-
|
|
335
|
+
Report as `candidate_conflict` when the shared signals are:
|
|
336
|
+
- same resource key: orders
|
|
337
|
+
- same trigger key: post_order
|
|
338
|
+
- same stage key: route_entry
|
|
339
|
+
|
|
340
|
+
### Medium confidence: same_ac_slot
|
|
211
341
|
```
|
|
212
342
|
# Source Design Doc
|
|
213
|
-
|
|
343
|
+
When user submits valid credentials, the system creates a session with 30-minute expiry
|
|
214
344
|
|
|
215
345
|
# Other Design Doc (conflict)
|
|
216
|
-
|
|
346
|
+
When user submits valid credentials, the system issues a JWT with 60-minute expiry
|
|
217
347
|
```
|
|
218
348
|
|
|
349
|
+
Report as `candidate_conflict` when the shared signals are:
|
|
350
|
+
- same trigger key: submit valid credentials
|
|
351
|
+
- same outcome key: successful sign-in
|
|
352
|
+
|
|
353
|
+
### Medium confidence: same_numeric_role
|
|
354
|
+
```
|
|
355
|
+
# Source Design Doc
|
|
356
|
+
Retry backoff initial delay: 100 ms
|
|
357
|
+
|
|
358
|
+
# Other Design Doc (conflict)
|
|
359
|
+
Initial retry delay: 250 ms
|
|
360
|
+
```
|
|
361
|
+
|
|
362
|
+
Report as `candidate_conflict` when the signals are:
|
|
363
|
+
- same numeric key: retry_backoff_initial_delay
|
|
364
|
+
- same unit key: ms
|
|
365
|
+
- same scope key: retry
|
|
366
|
+
|
|
367
|
+
### Medium confidence: same_term_role
|
|
368
|
+
```
|
|
369
|
+
# Source Design Doc
|
|
370
|
+
Fulfillment window = time between payment confirmation and carrier handoff
|
|
371
|
+
|
|
372
|
+
# Other Design Doc (conflict)
|
|
373
|
+
Order fulfillment window = time between payment confirmation and warehouse pick start
|
|
374
|
+
```
|
|
375
|
+
|
|
376
|
+
Report as `candidate_conflict` when the signals are:
|
|
377
|
+
- same term key: fulfillment_window
|
|
378
|
+
- same subject key: order_fulfillment
|
|
379
|
+
|
|
380
|
+
### Not a candidate conflict
|
|
381
|
+
```
|
|
382
|
+
# Source Design Doc
|
|
383
|
+
POST /api/users/register
|
|
384
|
+
|
|
385
|
+
# Other Design Doc
|
|
386
|
+
POST /api/accounts/signup
|
|
387
|
+
```
|
|
388
|
+
|
|
389
|
+
Do not report this pair when only one shared signal is present or when no allowed match_basis applies.
|
|
390
|
+
|
|
391
|
+
### Not a numeric-role candidate conflict
|
|
392
|
+
```
|
|
393
|
+
# Source Design Doc
|
|
394
|
+
Retry backoff initial delay: 100 ms
|
|
395
|
+
|
|
396
|
+
# Other Design Doc
|
|
397
|
+
Retry limit: 3
|
|
398
|
+
```
|
|
399
|
+
|
|
400
|
+
Do not report this pair when `scope_key: retry` matches but `numeric_key` does not.
|
|
401
|
+
|
|
219
402
|
## Quality Checklist
|
|
220
403
|
|
|
221
404
|
- [ ] Correctly read source_design
|
|
222
|
-
- [ ] Surveyed all Design Docs
|
|
223
|
-
- [ ]
|
|
405
|
+
- [ ] Surveyed all target Design Docs
|
|
406
|
+
- [ ] Extracted source and target items using the same schema and key derivation rules
|
|
407
|
+
- [ ] Recorded all required normalized keys for extracted items
|
|
408
|
+
- [ ] Match basis selected using the required priority order
|
|
409
|
+
- [ ] High-confidence conflicts use only `exact_string` or `explicit_alias`
|
|
410
|
+
- [ ] Candidate conflicts use only allowed medium-confidence match-basis values and required signals
|
|
411
|
+
- [ ] `explicit_alias` is used only when `alias_of` equals the counterpart's exact identifier
|
|
412
|
+
- [ ] Medium-confidence conflicts include `reason` with structural evidence
|
|
224
413
|
- [ ] Correctly assigned severity to each conflict
|
|
225
414
|
- [ ] Output in JSON format
|
|
226
415
|
|
|
@@ -234,16 +423,7 @@ Integration: UserService.login() → TokenService.generate()
|
|
|
234
423
|
|
|
235
424
|
- All target files have been read
|
|
236
425
|
- JSON output completed
|
|
237
|
-
-
|
|
238
|
-
|
|
239
|
-
## Important Notes
|
|
240
|
-
|
|
241
|
-
### Scope: Detection and Reporting Only
|
|
242
|
-
design-sync **specializes in detection and reporting**. Conflict resolution is handled by the orchestrator or other agents.
|
|
243
|
-
|
|
244
|
-
### Relationship with document-reviewer
|
|
245
|
-
- **document-reviewer**: Single document quality, completeness, and rule compliance
|
|
246
|
-
- **design-sync**: Cross-document consistency verification (use after document-reviewer)
|
|
426
|
+
- Quality checklist items verified
|
|
247
427
|
|
|
248
428
|
## Completion Gate [BLOCKING]
|
|
249
429
|
|
|
@@ -36,31 +36,12 @@ Skill Status:
|
|
|
36
36
|
|
|
37
37
|
**Current Date Retrieval**: Before starting work, retrieve the actual current date from the operating environment (do not rely on training data cutoff date).
|
|
38
38
|
|
|
39
|
-
## Main Responsibilities
|
|
40
|
-
|
|
41
|
-
1. Identify and evaluate frontend technical options (React libraries, state management, UI frameworks)
|
|
42
|
-
2. Document architecture decisions (ADR) for frontend
|
|
43
|
-
3. Create detailed design (Design Doc) for React components and features
|
|
44
|
-
4. **Define feature acceptance criteria and ensure verifiability in browser environment**
|
|
45
|
-
5. Analyze trade-offs and verify consistency with existing React architecture
|
|
46
|
-
6. **Research latest React/frontend technology information and cite sources**
|
|
47
|
-
|
|
48
39
|
## Document Creation Criteria
|
|
49
40
|
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
-
|
|
54
|
-
- Design Doc: Required for 3+ component/file changes
|
|
55
|
-
- Also required regardless of scale for:
|
|
56
|
-
- Complex state management logic
|
|
57
|
-
- Criteria: Managing 3+ state variables, or coordinating 5+ async operations (API calls)
|
|
58
|
-
- Example: Complex form state management, multiple API call orchestration
|
|
59
|
-
- Introduction of new React patterns or custom hooks
|
|
60
|
-
- Example: New context patterns, custom hook libraries
|
|
61
|
-
|
|
62
|
-
### Important: Assessment Consistency
|
|
63
|
-
- If assessments conflict, include and report the discrepancy in output
|
|
41
|
+
Follow documentation-criteria skill. If scale or document-type assessments conflict, report the discrepancy in output.
|
|
42
|
+
Representative triggers:
|
|
43
|
+
- ADR: component architecture, state-management, React pattern, or external library changes
|
|
44
|
+
- Design Doc: 3+ component/file changes, complex state management, or new React patterns/custom hooks
|
|
64
45
|
|
|
65
46
|
## Mandatory Process Before Design Doc Creation
|
|
66
47
|
|
|
@@ -261,29 +242,6 @@ Exclude from ADR: Schedules, implementation procedures, specific code
|
|
|
261
242
|
|
|
262
243
|
Implementation guidelines MUST only include principles (e.g., "Use custom hooks for logic reuse" is correct, "Implement in Phase 1" is not)
|
|
263
244
|
|
|
264
|
-
## Output Policy
|
|
265
|
-
Execute file output immediately. Final approval is managed by the orchestrator recipe.
|
|
266
|
-
|
|
267
|
-
## Important Design Principles
|
|
268
|
-
|
|
269
|
-
1. **Consistency First Priority**: Follow existing React component patterns, document clear reasons when introducing new patterns
|
|
270
|
-
2. **Appropriate Abstraction**: Design optimal for current requirements, thoroughly apply YAGNI principle (follow project rules)
|
|
271
|
-
3. **Testability**: Props-driven design and mockable custom hooks
|
|
272
|
-
4. **Test Derivation from Feature Acceptance Criteria**: Clear React Testing Library test cases that satisfy each feature acceptance criterion
|
|
273
|
-
5. **Explicit Trade-offs**: Quantitatively evaluate benefits and drawbacks of each option (performance, accessibility)
|
|
274
|
-
6. **Active Use of Latest Information**:
|
|
275
|
-
- MUST research latest React best practices, libraries, and approaches with web search before design
|
|
276
|
-
- Cite information sources in "References" section with URLs
|
|
277
|
-
- Especially confirm multiple reliable sources when introducing new technologies
|
|
278
|
-
|
|
279
|
-
## Design Doc Completion Checklist
|
|
280
|
-
|
|
281
|
-
- [ ] Agreement Checklist completed and reflected in design
|
|
282
|
-
- [ ] Implementation approach selected with rationale
|
|
283
|
-
- [ ] Verification Strategy defined with correctness definition, target comparison, method, observable success indicator, timing, and early verification point
|
|
284
|
-
- [ ] Change Impact Map included
|
|
285
|
-
- [ ] Interface Change Impact Analysis included
|
|
286
|
-
|
|
287
245
|
## Implementation Sample Standards Compliance
|
|
288
246
|
|
|
289
247
|
**MANDATORY**: All implementation samples in ADR and Design Docs MUST strictly comply with coding-rules skill standards without exception.
|
|
@@ -296,51 +254,6 @@ Implementation sample creation checklist:
|
|
|
296
254
|
- Error handling approaches (Error Boundary, error state management)
|
|
297
255
|
- Environment variables (no secrets client-side)
|
|
298
256
|
|
|
299
|
-
**Example Implementation Sample**:
|
|
300
|
-
```typescript
|
|
301
|
-
// Compliant: Function component with Props type definition
|
|
302
|
-
type ButtonProps = {
|
|
303
|
-
label: string
|
|
304
|
-
onClick: () => void
|
|
305
|
-
disabled?: boolean
|
|
306
|
-
}
|
|
307
|
-
|
|
308
|
-
export function Button({ label, onClick, disabled = false }: ButtonProps) {
|
|
309
|
-
return (
|
|
310
|
-
<button onClick={onClick} disabled={disabled}>
|
|
311
|
-
{label}
|
|
312
|
-
</button>
|
|
313
|
-
)
|
|
314
|
-
}
|
|
315
|
-
|
|
316
|
-
// Compliant: Custom hook with type safety
|
|
317
|
-
function useUserData(userId: string) {
|
|
318
|
-
const [user, setUser] = useState<User | null>(null)
|
|
319
|
-
const [error, setError] = useState<Error | null>(null)
|
|
320
|
-
|
|
321
|
-
useEffect(() => {
|
|
322
|
-
async function fetchUser() {
|
|
323
|
-
try {
|
|
324
|
-
const response = await fetch(`/api/users/${userId}`)
|
|
325
|
-
const data: unknown = await response.json()
|
|
326
|
-
|
|
327
|
-
if (!isUser(data)) {
|
|
328
|
-
throw new Error('Invalid user data')
|
|
329
|
-
}
|
|
330
|
-
|
|
331
|
-
setUser(data)
|
|
332
|
-
} catch (err) {
|
|
333
|
-
setError(err instanceof Error ? err : new Error('Unknown error'))
|
|
334
|
-
}
|
|
335
|
-
}
|
|
336
|
-
|
|
337
|
-
fetchUser()
|
|
338
|
-
}, [userId])
|
|
339
|
-
|
|
340
|
-
return { user, error }
|
|
341
|
-
}
|
|
342
|
-
```
|
|
343
|
-
|
|
344
257
|
## Diagram Creation (using mermaid notation)
|
|
345
258
|
|
|
346
259
|
**ADR**: Option comparison diagram, decision impact diagram
|
|
@@ -390,14 +303,9 @@ function useUserData(userId: string) {
|
|
|
390
303
|
|
|
391
304
|
## Acceptance Criteria Creation Guidelines
|
|
392
305
|
|
|
393
|
-
**Principle**: Set specific, verifiable conditions in browser environment. Avoid ambiguous expressions
|
|
306
|
+
**Principle**: Set specific, verifiable conditions in browser environment. Avoid ambiguous expressions and make each criterion convertible to React Testing Library test cases.
|
|
394
307
|
**Example**: "Form works" → "After entering valid email and password, clicking submit button calls API and displays success message"
|
|
395
|
-
|
|
396
|
-
- Expected behavior (happy path)
|
|
397
|
-
- Error handling (unhappy path)
|
|
398
|
-
- Edge cases (empty states, loading states)
|
|
399
|
-
|
|
400
|
-
4. **Priority**: Place important acceptance criteria at the top
|
|
308
|
+
Cover happy path, unhappy path, and edge cases including empty and loading states. Place important criteria first.
|
|
401
309
|
|
|
402
310
|
### AC Scoping for Autonomous Implementation (Frontend)
|
|
403
311
|
|
|
@@ -451,6 +359,14 @@ Completion rule for reverse-engineer mode:
|
|
|
451
359
|
- Every Unit Inventory route or public export is accounted for in the Design Doc
|
|
452
360
|
- Every claim about component structure, props flow, state flow, API interaction, or error handling cites file:line evidence
|
|
453
361
|
|
|
362
|
+
## Completion Criteria
|
|
363
|
+
|
|
364
|
+
- Output file paths and document types are determined correctly
|
|
365
|
+
- Required sections for the selected mode are completed
|
|
366
|
+
- Quality checklist items are satisfied
|
|
367
|
+
- Create/update mode includes acceptance criteria and verification strategy
|
|
368
|
+
- Reverse-engineer mode satisfies the reverse-engineer completion rule
|
|
369
|
+
|
|
454
370
|
## Completion Gate [BLOCKING]
|
|
455
371
|
|
|
456
372
|
☐ All completion criteria met with evidence
|
|
@@ -36,31 +36,12 @@ Skill Status:
|
|
|
36
36
|
|
|
37
37
|
**Current Date Retrieval**: Before starting work, retrieve the actual current date from the operating environment (do not rely on training data cutoff date).
|
|
38
38
|
|
|
39
|
-
## Main Responsibilities
|
|
40
|
-
|
|
41
|
-
1. Identify and evaluate technical options
|
|
42
|
-
2. Document architecture decisions (ADR)
|
|
43
|
-
3. Create detailed design (Design Doc)
|
|
44
|
-
4. **Define feature acceptance criteria and ensure verifiability**
|
|
45
|
-
5. Analyze trade-offs and verify consistency with existing architecture
|
|
46
|
-
6. **Research latest technology information and cite sources**
|
|
47
|
-
|
|
48
39
|
## Document Creation Criteria
|
|
49
40
|
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
-
|
|
54
|
-
- Design Doc: Required for 3+ file changes
|
|
55
|
-
- Also required regardless of scale for:
|
|
56
|
-
- Complex implementation logic
|
|
57
|
-
- Criteria: Managing 3+ states, or coordinating 5+ asynchronous processes
|
|
58
|
-
- Example: Complex state management, coordinating multiple asynchronous operations
|
|
59
|
-
- Introduction of new algorithms or patterns
|
|
60
|
-
- Example: New caching strategies, custom routing implementation
|
|
61
|
-
|
|
62
|
-
### Important: Assessment Consistency
|
|
63
|
-
- If assessments conflict, include and report the discrepancy in output
|
|
41
|
+
Follow documentation-criteria skill. If scale or document-type assessments conflict, report the discrepancy in output.
|
|
42
|
+
Representative triggers:
|
|
43
|
+
- ADR: contract, architecture, data-flow, or external dependency changes
|
|
44
|
+
- Design Doc: 3+ file changes, complex implementation logic, or new algorithms/patterns
|
|
64
45
|
|
|
65
46
|
## Mandatory Process Before Design Doc Creation
|
|
66
47
|
|
|
@@ -293,21 +274,6 @@ Exclude from ADR: Schedules, implementation procedures, specific code
|
|
|
293
274
|
|
|
294
275
|
Implementation guidelines MUST only include principles (e.g., "Use dependency injection" is correct, "Implement in Phase 1" is not)
|
|
295
276
|
|
|
296
|
-
## Output Policy
|
|
297
|
-
Execute file output immediately. Final approval is managed by the orchestrator recipe.
|
|
298
|
-
|
|
299
|
-
## Important Design Principles
|
|
300
|
-
|
|
301
|
-
1. **Consistency First Priority**: Follow existing patterns, document clear reasons when introducing new patterns
|
|
302
|
-
2. **Appropriate Abstraction**: Design optimal for current requirements, thoroughly apply YAGNI principle (follow project rules)
|
|
303
|
-
3. **Testability**: Parameterized dependencies (dependency injection, function parameters) and mockable design
|
|
304
|
-
4. **Test Derivation from Feature Acceptance Criteria**: Clear test cases that satisfy each feature acceptance criterion
|
|
305
|
-
5. **Explicit Trade-offs**: Quantitatively evaluate benefits and drawbacks of each option
|
|
306
|
-
6. **Active Use of Latest Information**:
|
|
307
|
-
- MUST research latest best practices, libraries, and approaches with web search before design
|
|
308
|
-
- Cite information sources in "References" section with URLs
|
|
309
|
-
- Especially confirm multiple reliable sources when introducing new technologies
|
|
310
|
-
|
|
311
277
|
## Implementation Sample Standards Compliance
|
|
312
278
|
|
|
313
279
|
**MANDATORY**: All implementation samples in ADR and Design Docs MUST strictly comply with project coding standards.
|
|
@@ -366,14 +332,9 @@ Implementation sample creation checklist:
|
|
|
366
332
|
|
|
367
333
|
## Acceptance Criteria Creation Guidelines
|
|
368
334
|
|
|
369
|
-
**Principle**: Set specific, verifiable conditions. Avoid ambiguous expressions
|
|
335
|
+
**Principle**: Set specific, verifiable conditions. Avoid ambiguous expressions and make each criterion convertible to tests.
|
|
370
336
|
**Example**: "Login works" → "After authentication with correct credentials, navigates to dashboard screen"
|
|
371
|
-
|
|
372
|
-
- Expected behavior (happy path)
|
|
373
|
-
- Error handling (unhappy path)
|
|
374
|
-
- Edge cases
|
|
375
|
-
|
|
376
|
-
4. **Priority**: Place important acceptance criteria at the top
|
|
337
|
+
Cover happy path, unhappy path, and edge cases. Place important criteria first.
|
|
377
338
|
|
|
378
339
|
### AC Scoping for Autonomous Implementation
|
|
379
340
|
|
|
@@ -389,10 +350,6 @@ Implementation sample creation checklist:
|
|
|
389
350
|
- Implementation details (technology choice, algorithms, internal structure) → Focus on observable behavior
|
|
390
351
|
- UI presentation method (layout, styling) → Focus on information availability
|
|
391
352
|
|
|
392
|
-
**Example**:
|
|
393
|
-
- Implementation detail: "Data is stored using specific technology X" (avoid)
|
|
394
|
-
- Observable behavior: "Saved data can be retrieved after system restart" (preferred)
|
|
395
|
-
|
|
396
353
|
**Principle**: AC = User-observable behavior verifiable in isolated CI environment
|
|
397
354
|
|
|
398
355
|
*Note: Non-functional requirements (performance, reliability, etc.) are defined in the "Non-functional Requirements" section and automatically verified by quality check tools
|
|
@@ -433,6 +390,14 @@ Completion rule for reverse-engineer mode:
|
|
|
433
390
|
- Every Unit Inventory route or public export is accounted for in the Design Doc
|
|
434
391
|
- Every claim about architecture, data flow, public contracts, integrations, or error handling cites file:line evidence
|
|
435
392
|
|
|
393
|
+
## Completion Criteria
|
|
394
|
+
|
|
395
|
+
- Output file paths and document types are determined correctly
|
|
396
|
+
- Required sections for the selected mode are completed
|
|
397
|
+
- Quality checklist items are satisfied
|
|
398
|
+
- Create/update mode includes acceptance criteria and verification strategy
|
|
399
|
+
- Reverse-engineer mode satisfies the reverse-engineer completion rule
|
|
400
|
+
|
|
436
401
|
## Completion Gate [BLOCKING]
|
|
437
402
|
|
|
438
403
|
☐ All completion criteria met with evidence
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "codex-workflows",
|
|
3
|
-
"version": "0.4.
|
|
3
|
+
"version": "0.4.7",
|
|
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",
|