@chenmk/superflow 0.1.1 → 0.1.2
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/INSTALL.en.md +32 -5
- package/INSTALL.md +58 -17
- package/README.md +83 -7
- package/README.zh-CN.md +80 -11
- package/assets/brand/superflow-banner.svg +80 -0
- package/assets/context-templates/business-rules.md +45 -78
- package/assets/context-templates/decisions.md +63 -149
- package/assets/context-templates/external-systems.md +64 -161
- package/assets/context-templates/incidents.md +40 -78
- package/assets/context-templates-en/business-rules.md +72 -0
- package/assets/context-templates-en/decisions.md +72 -0
- package/assets/context-templates-en/external-systems.md +78 -0
- package/assets/context-templates-en/incidents.md +52 -0
- package/assets/manifest.json +6 -4
- package/assets/scripts/claude-auto-backup-hook.sh +11 -6
- package/assets/scripts/codex-auto-backup-hook.sh +11 -6
- package/assets/skills-en/api-doc-changelog/SKILL.md +64 -151
- package/assets/skills-en/superflow-clarify/SKILL.md +4 -4
- package/assets/skills-en/superflow-clarify/agents/openai.yaml +1 -1
- package/assets/skills-en/superflow-design/agents/openai.yaml +1 -1
- package/assets/skills-en/superflow-docs/SKILL.md +27 -27
- package/assets/skills-en/superflow-docs/agents/openai.yaml +1 -1
- package/assets/skills-en/superflow-implement/SKILL.md +113 -457
- package/assets/skills-en/superflow-implement/agents/openai.yaml +1 -1
- package/assets/skills-en/superflow-pipeline/SKILL.md +167 -840
- package/assets/skills-en/superflow-pipeline/agents/openai.yaml +1 -1
- package/assets/skills-en/superflow-pipeline/references/api-design-template.md +17 -426
- package/assets/skills-en/superflow-pipeline/references/architecture-design-template.md +15 -114
- package/assets/skills-en/superflow-pipeline/references/batch-prompt-template.md +36 -524
- package/assets/skills-en/superflow-pipeline/references/batch-split-guide.md +19 -133
- package/assets/skills-en/superflow-pipeline/references/document-templates.md +50 -123
- package/assets/skills-en/superflow-pipeline/references/feature-gated-workflow.md +12 -119
- package/assets/skills-en/superflow-pipeline/references/implementation-prompt-template.md +22 -1044
- package/assets/skills-en/superflow-pipeline/references/mock-strategy-guide.md +11 -81
- package/assets/skills-en/superflow-pipeline/references/openspec-format.md +17 -51
- package/assets/skills-en/superflow-pipeline/references/orchestration.md +17 -632
- package/assets/skills-en/superflow-pipeline/references/p0-baseline-template.md +10 -169
- package/assets/skills-en/superflow-pipeline/references/prompt-usage-template.md +29 -128
- package/assets/skills-en/superflow-pipeline/references/quality-gate.md +36 -299
- package/assets/skills-en/superflow-pipeline/references/quality-standards.md +12 -186
- package/assets/skills-en/superflow-pipeline/references/reviewer-checklist.md +12 -154
- package/assets/skills-en/superflow-pipeline/references/sql-risk-review-checklist.md +19 -316
- package/assets/skills-en/superflow-pipeline/references/test-execution-template.md +22 -220
- package/assets/skills-en/superflow-pipeline/references/test-guide.md +12 -26
- package/assets/skills-en/superflow-pipeline/references/traceability-matrix.md +5 -103
- package/assets/skills-en/superflow-pipeline/references/validation-integrity.md +12 -130
- package/assets/skills-en/superflow-pipeline/scripts/superflow-guard.sh +23 -23
- package/assets/skills-en/superflow-pipeline/scripts/superflow-state.sh +1 -1
- package/assets/skills-en/superflow-pipeline/scripts/superflow-status.sh +15 -15
- package/assets/skills-en/superflow-table-impact-analysis/SKILL.md +3 -3
- package/dist/cli/index.js +61 -54
- package/dist/cli/index.js.map +1 -1
- package/dist/commands/doctor.js +31 -12
- package/dist/commands/doctor.js.map +1 -1
- package/dist/commands/init.js +75 -27
- package/dist/commands/init.js.map +1 -1
- package/dist/commands/scan.js +8 -4
- package/dist/commands/scan.js.map +1 -1
- package/dist/commands/uninstall.js +3 -3
- package/dist/commands/uninstall.js.map +1 -1
- package/dist/commands/update.js +8 -3
- package/dist/commands/update.js.map +1 -1
- package/dist/core/cli-help.js +98 -0
- package/dist/core/cli-help.js.map +1 -0
- package/dist/core/context.js +40 -17
- package/dist/core/context.js.map +1 -1
- package/dist/core/detect.js +58 -5
- package/dist/core/detect.js.map +1 -1
- package/dist/core/i18n.js +10 -8
- package/dist/core/i18n.js.map +1 -1
- package/dist/core/manifest.js +3 -0
- package/dist/core/manifest.js.map +1 -1
- package/dist/core/scripts.js +8 -0
- package/dist/core/scripts.js.map +1 -1
- package/dist/core/skills.js +6 -0
- package/dist/core/skills.js.map +1 -1
- package/dist/core/state.js +12 -1
- package/dist/core/state.js.map +1 -1
- package/package.json +4 -3
|
@@ -1,193 +1,106 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: api-doc-changelog
|
|
3
|
-
description:
|
|
4
|
-
规范 API 联调文档(api.md)的变更标注格式。当编写或更新前后端联调接口文档时,
|
|
5
|
-
自动在接口和字段级别标注变更类型,让前端 agent 一眼看出两个版本之间改了什么。
|
|
6
|
-
适用于:写 api.md、更新 api.md、推送飞书前检查文档、SuperBridge Flow 流程生成接口设计。
|
|
7
|
-
触发词:api文档变更、接口变更标记、changelog、联调文档更新、接口变更标注、
|
|
8
|
-
变更追踪、接口diff、版本变更、提测文档。
|
|
3
|
+
description: Standardize API documentation changelog annotations. Use when writing or updating api.md, preparing frontend integration docs, marking API/field-level changes, or reviewing API docs before handoff.
|
|
9
4
|
---
|
|
10
5
|
|
|
11
|
-
# API
|
|
6
|
+
# API Documentation Changelog Standard
|
|
12
7
|
|
|
13
|
-
|
|
8
|
+
Use this skill when `api.md` must show what changed between the previous
|
|
9
|
+
baseline and the current delivery. The goal is to make API deltas visible to
|
|
10
|
+
frontend, QA, and integration agents without forcing them to diff a large file.
|
|
14
11
|
|
|
15
|
-
|
|
16
|
-
1. 这次新增了哪些接口?
|
|
17
|
-
2. 哪些接口的参数/返回值改了?改了哪个字段?
|
|
18
|
-
3. 哪些接口被废弃或删除了?
|
|
12
|
+
## Required Structure
|
|
19
13
|
|
|
20
|
-
|
|
21
|
-
本规范通过**文档顶部的变更概览 + 接口内联标注**,让变更信息对前端 agent 零门槛可见。
|
|
22
|
-
|
|
23
|
-
---
|
|
24
|
-
|
|
25
|
-
## 一、文档顶部变更概览
|
|
26
|
-
|
|
27
|
-
在 `## 1. 通用约定` 之前,插入变更概览节。格式如下:
|
|
14
|
+
Add a changelog overview before the first normal API section:
|
|
28
15
|
|
|
29
16
|
```markdown
|
|
30
|
-
## 0.
|
|
17
|
+
## 0. Change Overview
|
|
31
18
|
|
|
32
|
-
>
|
|
19
|
+
> Baseline: v1.0 | Current: v1.1 | Date: YYYY-MM-DD
|
|
33
20
|
|
|
34
|
-
###
|
|
21
|
+
### Added APIs
|
|
35
22
|
|
|
36
|
-
|
|
|
37
|
-
|
|
38
|
-
| `POST /api/
|
|
23
|
+
| API | Summary |
|
|
24
|
+
|-----|---------|
|
|
25
|
+
| `POST /api/example` | Adds example creation |
|
|
39
26
|
|
|
40
|
-
###
|
|
27
|
+
### Changed APIs
|
|
41
28
|
|
|
42
|
-
|
|
|
43
|
-
|
|
44
|
-
| `GET /api/
|
|
45
|
-
| `PUT /api/zzz/{id}` | 入参 `status` 枚举值新增 `3=待审核` |
|
|
29
|
+
| API | Change Summary |
|
|
30
|
+
|-----|----------------|
|
|
31
|
+
| `GET /api/example` | Adds query parameter `keyword`; response adds `tag` |
|
|
46
32
|
|
|
47
|
-
###
|
|
33
|
+
### Deprecated APIs
|
|
48
34
|
|
|
49
|
-
|
|
|
50
|
-
|
|
51
|
-
| `GET /api/old` |
|
|
35
|
+
| API | Replacement | Removal Plan |
|
|
36
|
+
|-----|-------------|--------------|
|
|
37
|
+
| `GET /api/old` | `GET /api/new` | v2.0 |
|
|
52
38
|
```
|
|
53
39
|
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
1. **每次提测必须更新**:推送飞书前,必须刷新变更概览节的内容和日期。
|
|
57
|
-
2. **只写本次变更**:变更概览只记录"上一版基线 → 当前版本"的差量,不是完整历史。
|
|
58
|
-
3. **完整历史在第 8 节**:文档末尾的"接口变更记录"表保留完整历史,格式不变。
|
|
59
|
-
4. **无变更也要写**:如果没有变更,写"本次提测无接口变更,仅修复已知问题"。
|
|
60
|
-
|
|
61
|
-
---
|
|
62
|
-
|
|
63
|
-
## 二、接口级别内联标注
|
|
64
|
-
|
|
65
|
-
每个接口的标题行后紧跟变更标签,用方括号标注变更类型:
|
|
40
|
+
If there are no API changes, write that explicitly:
|
|
66
41
|
|
|
67
42
|
```markdown
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
#### `PUT /api/parking-guns/{id}` `[修改]`
|
|
71
|
-
|
|
72
|
-
#### `DELETE /api/old-endpoint` `[废弃]`
|
|
43
|
+
No API contract changes in this delivery.
|
|
73
44
|
```
|
|
74
45
|
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
| 标签 | 含义 | 使用场景 |
|
|
78
|
-
|------|------|----------|
|
|
79
|
-
| `[新增]` | 本次新增的接口 | 全新开发的接口 |
|
|
80
|
-
| `[修改]` | 本次有改动的接口 | 参数、响应、行为有任何变化 |
|
|
81
|
-
| `[废弃]` | 已废弃但暂未移除 | 已有替代方案,但保留兼容 |
|
|
82
|
-
| 无标签 | 本次无变更 | 上个版本就存在且未修改的接口 |
|
|
83
|
-
|
|
84
|
-
### 规则
|
|
85
|
-
|
|
86
|
-
1. **只有本次变更的接口才加标签**,稳定接口不加。
|
|
87
|
-
2. 下次提测时,上一轮的标签要**清除**(上一轮的变更已不再是"新"变更)。
|
|
88
|
-
3. 接口标题和标签之间用空格分隔。
|
|
46
|
+
## API-Level Labels
|
|
89
47
|
|
|
90
|
-
|
|
48
|
+
For each changed API heading, append one label:
|
|
91
49
|
|
|
92
|
-
|
|
50
|
+
- `[Added]`
|
|
51
|
+
- `[Changed]`
|
|
52
|
+
- `[Deprecated]`
|
|
93
53
|
|
|
94
|
-
|
|
54
|
+
Stable APIs from earlier versions do not need labels. Remove old labels during
|
|
55
|
+
the next delivery cycle so labels always mean "changed in this delivery".
|
|
95
56
|
|
|
96
|
-
|
|
57
|
+
Example:
|
|
97
58
|
|
|
98
59
|
```markdown
|
|
99
|
-
|
|
100
|
-
|------|------|------|------|
|
|
101
|
-
| name | String | 是 | 套餐名称 |
|
|
102
|
-
| keyword | String | 否 | 搜索关键词 `【本次新增】` |
|
|
103
|
-
| status | Integer | 否 | 状态:1 上架,2 下架,3 待审核 `【枚举值变更:新增 3】` |
|
|
104
|
-
| oldField | String | 否 | ~~已废弃,使用 newField~~ `【本次废弃】` |
|
|
60
|
+
#### `GET /api/orders` `[Changed]`
|
|
105
61
|
```
|
|
106
62
|
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
| 标注 | 含义 | 在说明列中的写法 |
|
|
110
|
-
|------|------|-----------------|
|
|
111
|
-
| 新增字段 | 本次新增的入参或返回字段 | 追加 `【本次新增】` |
|
|
112
|
-
| 字段修改 | 类型、校验规则、枚举值等有变化 | 追加 `【本次变更:具体改了什么】` |
|
|
113
|
-
| 字段废弃 | 仍在返回但已不推荐使用 | 用删除线 + 追加 `【本次废弃】` |
|
|
114
|
-
| 字段移除 | 不再返回或不再接受 | 从表中移除,在变更概览中说明 |
|
|
115
|
-
|
|
116
|
-
### 规则
|
|
117
|
-
|
|
118
|
-
1. 标注追加在说明文字末尾,用 `【】` 包裹,与正常说明文字区分。
|
|
119
|
-
2. 变更描述要**具体**:写"枚举值新增 3=待审核",不要只写"有变更"。
|
|
120
|
-
3. 下次提测时清除上一轮标注。
|
|
121
|
-
4. JSON 响应示例中不需要标注,以字段表为准。
|
|
122
|
-
|
|
123
|
-
---
|
|
124
|
-
|
|
125
|
-
## 四、操作流程
|
|
63
|
+
## Field-Level Labels
|
|
126
64
|
|
|
127
|
-
|
|
65
|
+
In request and response field tables, append change notes to the description
|
|
66
|
+
column:
|
|
128
67
|
|
|
129
|
-
|
|
130
|
-
|
|
68
|
+
| Field | Type | Required | Description |
|
|
69
|
+
|-------|------|----------|-------------|
|
|
70
|
+
| `keyword` | String | No | Search keyword `[Added]` |
|
|
71
|
+
| `status` | Integer | No | Status enum `[Changed: adds 3=Pending Review]` |
|
|
72
|
+
| `oldField` | String | No | ~~Deprecated; use `newField`~~ `[Deprecated]` |
|
|
131
73
|
|
|
132
|
-
|
|
133
|
-
## 0. 变更概览(本次提测变更)
|
|
134
|
-
|
|
135
|
-
> 首个版本,全部接口为新增。详见接口列表。
|
|
136
|
-
```
|
|
74
|
+
Rules:
|
|
137
75
|
|
|
138
|
-
|
|
76
|
+
- Be concrete. Write what changed, not just "changed".
|
|
77
|
+
- Mark added, changed, deprecated, and removed fields.
|
|
78
|
+
- Remove prior delivery labels in the next delivery cycle.
|
|
79
|
+
- JSON examples do not need inline labels; field tables are the source of truth.
|
|
139
80
|
|
|
140
|
-
|
|
141
|
-
2. **对比代码变更**(git diff、接口实现变化、DTO 字段变化)确定变更范围。
|
|
142
|
-
3. **更新变更概览**:在 `## 0. 变更概览` 节中列出新增/修改/废弃的接口。
|
|
143
|
-
4. **添加接口级标签**:在变更接口的标题行后追加 `[新增]`/`[修改]`/`[废弃]`。
|
|
144
|
-
5. **添加字段级标注**:在变更字段的说明列末尾追加 `【本次新增】`/`【本次变更:...】`。
|
|
145
|
-
6. **清除上一轮标注**:删除上一轮提测的变更标签和字段标注。
|
|
146
|
-
7. **更新第 8 节历史表**:在文档末尾的变更记录表中追加一行。
|
|
81
|
+
## Change Classification
|
|
147
82
|
|
|
148
|
-
|
|
83
|
+
Mark a change when any of these happen:
|
|
149
84
|
|
|
150
|
-
|
|
151
|
-
-
|
|
152
|
-
-
|
|
153
|
-
-
|
|
154
|
-
-
|
|
155
|
-
|
|
85
|
+
- API added, removed, or deprecated.
|
|
86
|
+
- Request parameter added, removed, renamed, made required, or made optional.
|
|
87
|
+
- Response field added, removed, renamed, or type-changed.
|
|
88
|
+
- Enum value added, removed, or meaning-changed.
|
|
89
|
+
- Validation rule, sorting, permission behavior, error code, or idempotency
|
|
90
|
+
behavior changes.
|
|
156
91
|
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
## 五、变更判定标准
|
|
160
|
-
|
|
161
|
-
以下情况算"变更",必须标注:
|
|
162
|
-
|
|
163
|
-
| 变更类型 | 示例 |
|
|
164
|
-
|----------|------|
|
|
165
|
-
| 新增接口 | 新增 POST /api/xxx |
|
|
166
|
-
| 删除接口 | 移除 GET /api/old |
|
|
167
|
-
| 新增参数/字段 | 入参增加 keyword 字段 |
|
|
168
|
-
| 删除参数/字段 | 不再返回 oldField |
|
|
169
|
-
| 修改字段类型 | String → Long |
|
|
170
|
-
| 修改枚举值 | status 新增值 3 |
|
|
171
|
-
| 修改校验规则 | 长度限制从 64 改为 128 |
|
|
172
|
-
| 修改必填状态 | 可选 → 必填 |
|
|
173
|
-
| 修改行为逻辑 | 排序规则改变、权限逻辑变更 |
|
|
174
|
-
| 修改错误码 | 新增错误码或修改错误码含义 |
|
|
175
|
-
|
|
176
|
-
以下情况**不算变更**,不需要标注:
|
|
177
|
-
- 修正错别字
|
|
178
|
-
- 调整文档格式
|
|
179
|
-
- 补充边界说明(不改变接口行为)
|
|
180
|
-
- curl 示例调整(不改变接口契约)
|
|
181
|
-
|
|
182
|
-
---
|
|
92
|
+
Do not mark a change for typo fixes, formatting, or explanatory notes that do
|
|
93
|
+
not change the contract.
|
|
183
94
|
|
|
184
|
-
##
|
|
95
|
+
## Superflow Integration
|
|
185
96
|
|
|
186
|
-
|
|
97
|
+
During `superflow-docs`:
|
|
187
98
|
|
|
188
|
-
1.
|
|
189
|
-
2.
|
|
190
|
-
|
|
99
|
+
1. If `api.md` is new, write "initial version" in the overview.
|
|
100
|
+
2. If `api.md` exists, compare the current contract against the baseline and
|
|
101
|
+
update the overview plus inline labels.
|
|
102
|
+
3. Before handoff, verify that frontend-facing changes are visible both in the
|
|
103
|
+
overview and near the affected API/field.
|
|
191
104
|
|
|
192
|
-
|
|
193
|
-
|
|
105
|
+
The full historical API change log can stay near the end of `api.md`; the
|
|
106
|
+
overview is the delivery-specific delta.
|
|
@@ -43,7 +43,7 @@ any full SDD document or implementation prompt is generated.
|
|
|
43
43
|
- When a feature relies on a status, enum, sync field, derived field, default
|
|
44
44
|
value, or compatibility behavior, freeze the business semantics before API or
|
|
45
45
|
design freezing. Record:
|
|
46
|
-
|
|
46
|
+
`Source field | Source enum | Target field | Target enum | Consumer meaning | Business basis | Unknowns`.
|
|
47
47
|
Do not treat non-null, present, successful, or "has any value" as correct.
|
|
48
48
|
Do not accept fallback/default/keep-old-value behavior unless the requirement
|
|
49
49
|
or owner explicitly approves it for dirty historical data or uncontrollable
|
|
@@ -119,11 +119,11 @@ Use the detailed workflow in:
|
|
|
119
119
|
clarification questions.
|
|
120
120
|
9. For database-backed behavior, add a table reverse impact table before
|
|
121
121
|
freezing:
|
|
122
|
-
|
|
122
|
+
`Table/field | Writer | Reader/filter | Cross-repo/external consumer | Real entry | Reverse-state scenario | Required test`.
|
|
123
123
|
If any consumer or real entry is unknown, mark the feature blocked.
|
|
124
124
|
10. For status/enum/sync/default behavior, add a semantic mapping table before
|
|
125
125
|
freezing:
|
|
126
|
-
|
|
126
|
+
`Source field | Source enum | Target field | Target enum | Consumer meaning | Business basis | Unknowns`.
|
|
127
127
|
If a proposed default, fallback, old-value retention, or null conversion is
|
|
128
128
|
not explicitly approved by the requirement or owner, mark it rejected and do
|
|
129
129
|
not include it in the design.
|
|
@@ -132,7 +132,7 @@ Use the detailed workflow in:
|
|
|
132
132
|
13. Draft a rough API contract: path, action, core request, core response. Field types can be approximate.
|
|
133
133
|
14. Wait for programmer confirmation of the rough API.
|
|
134
134
|
15. Produce a precise API section with field names, types, requiredness, defaults, enums, errors, examples, and curl.
|
|
135
|
-
16. Mark the feature as
|
|
135
|
+
16. Mark the feature as `frozen` only when understanding, rough API, precise API,
|
|
136
136
|
and validation data needs are confirmed or explicitly blocked.
|
|
137
137
|
17. Only after the current feature is frozen or blocked, move to the next
|
|
138
138
|
indexed feature. Do not batch-confirm multiple features from memory or a
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
interface:
|
|
2
2
|
display_name: "SDD Clarify"
|
|
3
|
-
short_description: "
|
|
3
|
+
short_description: "Clarify requirements, confirm features one by one, and freeze API drafts"
|
|
4
4
|
default_prompt: "Use $superflow-clarify to process this requirement one confirmed feature at a time before SDD docs."
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
interface:
|
|
2
2
|
display_name: "SDD Design"
|
|
3
|
-
short_description: "
|
|
3
|
+
short_description: "Use Superpowers for source-level technical design and reverse impact analysis"
|
|
4
4
|
default_prompt: "Use $superflow-design to create the Superpowers technical design after SDD contract docs are complete."
|
|
@@ -72,7 +72,7 @@ For complex requirements, verify these before writing docs:
|
|
|
72
72
|
`$superflow-table-impact-analysis` when available.
|
|
73
73
|
- For any status, enum, sync, derived, default, or compatibility behavior, the
|
|
74
74
|
docs include business semantic evidence:
|
|
75
|
-
|
|
75
|
+
`Source field | Source enum | Target field | Target enum | Consumer meaning | Business basis | Unknowns`.
|
|
76
76
|
If the docs only prove that a value exists, is non-null, or lets the request
|
|
77
77
|
succeed, stop and return to `$superflow-clarify`. If fallback/default/keep-old-value
|
|
78
78
|
behavior is proposed without explicit requirement or owner approval, stop.
|
|
@@ -121,7 +121,7 @@ For complex requirements, verify these before writing docs:
|
|
|
121
121
|
DB/log evidence, and matching `test-report.md` section. If test data,
|
|
122
122
|
token, device, third-party dependency, or environment is unavailable, mark
|
|
123
123
|
that case `Blocked`/`Partially verified`; do not leave it as an open TODO.
|
|
124
|
-
- `feature-gates.md` exists and the current feature is
|
|
124
|
+
- `feature-gates.md` exists and the current feature is `frozen`.
|
|
125
125
|
- `ui-contract.md` contains page-to-API/DTO/DB mapping.
|
|
126
126
|
- `gap-analysis.md` has no unresolved blocker for the current feature.
|
|
127
127
|
- A precise `api.md` section exists or can be generated from the confirmed API draft.
|
|
@@ -201,8 +201,8 @@ Use references only as needed:
|
|
|
201
201
|
platform adapters, or configuration consumers are affected.
|
|
202
202
|
- Do not freeze cross-module design from "this module can technically call it"
|
|
203
203
|
evidence. `design.md` or `traceability-matrix.md` must include:
|
|
204
|
-
|
|
205
|
-
|
|
204
|
+
`Flow step | Call direction | Business-entry owner | Adapter owner | Existing entry/exit |
|
|
205
|
+
Proposed entry/exit | Responsibility fit | Evidence anchor | No bypass`.
|
|
206
206
|
Outbound adapters, protocol translators, MQ notification consumers, and
|
|
207
207
|
device gateways must not be promoted into business-entry orchestrators unless
|
|
208
208
|
the contract says they own that entry and records approval.
|
|
@@ -213,33 +213,33 @@ Use references only as needed:
|
|
|
213
213
|
turn an assumption into a requirement, table design, API contract, or prompt.
|
|
214
214
|
- Do not finalize database-backed design from a forward-only flow. For each
|
|
215
215
|
affected table/field, `design.md` or `traceability-matrix.md` must include:
|
|
216
|
-
|
|
216
|
+
`Table/field | Writer | Reader/filter | Cross-repo/external consumer | Real entry | Reverse-state scenario | Required test`.
|
|
217
217
|
Status fields must include recovery scenarios such as offline -> online,
|
|
218
218
|
deleted -> restored, missing -> reappearing, and old invalid value -> valid
|
|
219
219
|
after an upstream omission.
|
|
220
220
|
- Do not finalize status/enum/sync/default design from "has a value" evidence.
|
|
221
221
|
`design.md` or `traceability-matrix.md` must include:
|
|
222
|
-
|
|
222
|
+
`Source field | Source enum | Target field | Target enum | Consumer meaning | Business basis | Unknowns`.
|
|
223
223
|
Default values, fallback values, null-to-available conversions, old-value
|
|
224
224
|
retention, and alternative-field substitution are forbidden unless explicitly
|
|
225
225
|
required for dirty historical data or uncontrollable external input. Approved
|
|
226
226
|
compatibility must document:
|
|
227
|
-
|
|
227
|
+
`Fallback trigger | Business basis | Masked anomaly | Monitoring/alert/exposure | Removal condition | Owner approval`.
|
|
228
228
|
- `design.md`, `tests.md`, `sdd-quality-gate.md`, or `test-report.md` must name
|
|
229
|
-
the relationship judgment as
|
|
229
|
+
the relationship judgment as `confirmed/partially confirmed/unknown` when a bug fix hinges on
|
|
230
230
|
existing data or call-chain behavior.
|
|
231
231
|
- `design.md` must reference the frozen `api.md` fields and errors.
|
|
232
|
-
- `design.md` must include a "
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
- `design.md` or `traceability-matrix.md` must include a "
|
|
232
|
+
- `design.md` must include a "Field Semantic Contract" table for every risky field:
|
|
233
|
+
`Field | Source table/DTO/event | Real semantics | Target field | Target semantics | Equivalent? |
|
|
234
|
+
Evidence anchor | Forbidden usage | Unknowns/owner`.
|
|
235
|
+
- `design.md` or `traceability-matrix.md` must include a "Write-Through Closure" table for
|
|
236
236
|
every persisted or synchronized value:
|
|
237
|
-
|
|
238
|
-
DB column |
|
|
239
|
-
- `design.md` must include a "
|
|
240
|
-
|
|
241
|
-
DB
|
|
242
|
-
- `design.md` or `sdd-quality-gate.md` must include a "
|
|
237
|
+
`Business action | Java setter/assignment | Converter/DTO mapping | Mapper insert/update |
|
|
238
|
+
DB column | Later reader | Consumer entry | Verification SQL | Test case`.
|
|
239
|
+
- `design.md` must include a "Real Entry Call Chain" table:
|
|
240
|
+
`User/external action | Upstream service/API | Current repo entry | MQ/async callback | Key field change |
|
|
241
|
+
DB state | Settlement/notification/display consumer | Real verification method`.
|
|
242
|
+
- `design.md` or `sdd-quality-gate.md` must include a "No Fallback Or Guesswork"
|
|
243
243
|
section. It must explicitly list forbidden defaults, fallback queries,
|
|
244
244
|
substitute fields, keep-old-value behavior, null conversion, and downstream
|
|
245
245
|
compensation. Approved compatibility must include owner confirmation and
|
|
@@ -250,16 +250,16 @@ Use references only as needed:
|
|
|
250
250
|
OpenSpec/SDD owns WHAT/API/DB/tests/gates; Superpowers owns source-level HOW,
|
|
251
251
|
TDD/RED order, team split, worktree/port plan, and verification choreography.
|
|
252
252
|
The final technical design is created by `$superflow-design`, not `$superflow-docs`.
|
|
253
|
-
- `test-report.md` skeleton must include an "Agent
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
253
|
+
- `test-report.md` skeleton must include an "Agent Pre-Execution Self-Check" section with:
|
|
254
|
+
`Real entry located | Field semantic contract checked | Write-through closure checked |
|
|
255
|
+
No-fallback boundary confirmed | RED test executed | Allowed files | Forbidden files |
|
|
256
|
+
Blockers`.
|
|
257
257
|
- `tasks.md`, `tests.md`, and later prompts must use the same field names as `api.md`.
|
|
258
258
|
- `tests.md` is a pre-implementation contract. It must not be a vague checklist.
|
|
259
259
|
Every case must include:
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
test-report
|
|
260
|
+
`Case ID | Requirement/scenario | Level L1/L2/L3/L4 | Precondition data | Steps |
|
|
261
|
+
Automation command | Response assertion | DB assertion | Log assertion | RED expected failure | GREEN expected pass |
|
|
262
|
+
test-report evidence location`.
|
|
263
263
|
- Each visible UI field, button action, list column, dropdown, and enum must map to API/DTO/DB/tests or be explicitly out of scope.
|
|
264
264
|
- Every spec scenario must have at least one test case.
|
|
265
265
|
- Every implementation batch must have at least one test that can fail before
|
|
@@ -290,8 +290,8 @@ Use references only as needed:
|
|
|
290
290
|
CR/Px follow-ups: failing evidence before the fix, then the same path passing
|
|
291
291
|
after the fix.
|
|
292
292
|
- `test-report.md` skeleton must include these sections before implementation:
|
|
293
|
-
`RED
|
|
294
|
-
|
|
293
|
+
`RED failure evidence`, `GREEN pass evidence`, `interface automation evidence`, `DB evidence`,
|
|
294
|
+
`log evidence`, `manual/blocking cases`, and `Partially verified boundary`.
|
|
295
295
|
Each section must reference concrete `tests.md` case IDs.
|
|
296
296
|
- `sdd-quality-gate.md` must include blocking checks for:
|
|
297
297
|
executable tests frozen, RED/GREEN expectations present, interface automation
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
interface:
|
|
2
2
|
display_name: "SDD Docs"
|
|
3
|
-
short_description: "
|
|
3
|
+
short_description: "Generate API-first SDD document sets from frozen feature scope"
|
|
4
4
|
default_prompt: "Use $superflow-docs to generate API-first OpenSpec SDD documents from the confirmed feature."
|