semantic-atlas 2.8.0 → 3.0.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/semantic-atlas/SKILL.md +95 -281
- package/.agents/skills/semantic-atlas/agents/openai.yaml +2 -2
- package/.agents/skills/semantic-atlas/references/boundary-design.md +52 -0
- package/.agents/skills/semantic-atlas/references/diagram-design.md +140 -0
- package/.agents/skills/semantic-atlas/references/map-authoring.md +162 -0
- package/.agents/skills/semantic-atlas/references/observations.md +23 -49
- package/.agents/skills/semantic-atlas/references/reconciliation.md +77 -0
- package/README.md +44 -90
- package/README.zh-CN.md +37 -56
- package/dist/application/map-application.d.ts +3 -1
- package/dist/application/map-application.d.ts.map +1 -1
- package/dist/application/map-application.js +59 -0
- package/dist/application/map-application.js.map +1 -1
- package/dist/cli/run-cli.d.ts.map +1 -1
- package/dist/cli/run-cli.js +12 -1
- package/dist/cli/run-cli.js.map +1 -1
- package/dist/contracts/cli.d.ts +8 -1
- package/dist/contracts/cli.d.ts.map +1 -1
- package/dist/contracts/flow-navigation.d.ts +48 -0
- package/dist/contracts/flow-navigation.d.ts.map +1 -0
- package/dist/contracts/flow-navigation.js +2 -0
- package/dist/contracts/flow-navigation.js.map +1 -0
- package/dist/contracts/map.d.ts +5 -5
- package/dist/i18n/index.d.ts +22 -196
- package/dist/i18n/index.d.ts.map +1 -1
- package/dist/i18n/locales/en/cli.d.ts +3 -0
- package/dist/i18n/locales/en/cli.d.ts.map +1 -1
- package/dist/i18n/locales/en/cli.js +3 -0
- package/dist/i18n/locales/en/cli.js.map +1 -1
- package/dist/i18n/locales/en/errors.d.ts +1 -0
- package/dist/i18n/locales/en/errors.d.ts.map +1 -1
- package/dist/i18n/locales/en/errors.js +1 -0
- package/dist/i18n/locales/en/errors.js.map +1 -1
- package/dist/i18n/locales/en/viewer.d.ts +7 -98
- package/dist/i18n/locales/en/viewer.d.ts.map +1 -1
- package/dist/i18n/locales/en/viewer.js +14 -105
- package/dist/i18n/locales/en/viewer.js.map +1 -1
- package/dist/i18n/locales/zh-CN/cli.d.ts +3 -0
- package/dist/i18n/locales/zh-CN/cli.d.ts.map +1 -1
- package/dist/i18n/locales/zh-CN/cli.js +3 -0
- package/dist/i18n/locales/zh-CN/cli.js.map +1 -1
- package/dist/i18n/locales/zh-CN/errors.d.ts +1 -0
- package/dist/i18n/locales/zh-CN/errors.d.ts.map +1 -1
- package/dist/i18n/locales/zh-CN/errors.js +1 -0
- package/dist/i18n/locales/zh-CN/errors.js.map +1 -1
- package/dist/i18n/locales/zh-CN/viewer.d.ts +7 -98
- package/dist/i18n/locales/zh-CN/viewer.d.ts.map +1 -1
- package/dist/i18n/locales/zh-CN/viewer.js +14 -105
- package/dist/i18n/locales/zh-CN/viewer.js.map +1 -1
- package/dist/index.d.ts +2 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js.map +1 -1
- package/dist/query/concept-search-service.d.ts +1 -1
- package/dist/query/concept-search-service.d.ts.map +1 -1
- package/dist/query/concept-search-service.js +2 -2
- package/dist/query/concept-search-service.js.map +1 -1
- package/dist/query/flow-navigation-service.d.ts +16 -0
- package/dist/query/flow-navigation-service.d.ts.map +1 -0
- package/dist/query/flow-navigation-service.js +96 -0
- package/dist/query/flow-navigation-service.js.map +1 -0
- package/dist/query/flow-search-service.d.ts +9 -0
- package/dist/query/flow-search-service.d.ts.map +1 -0
- package/dist/query/flow-search-service.js +69 -0
- package/dist/query/flow-search-service.js.map +1 -0
- package/dist/rendering/flow-projector.d.ts +1 -0
- package/dist/rendering/flow-projector.d.ts.map +1 -1
- package/dist/rendering/flow-projector.js +73 -181
- package/dist/rendering/flow-projector.js.map +1 -1
- package/dist/rendering/map-projector.d.ts +4 -5
- package/dist/rendering/map-projector.d.ts.map +1 -1
- package/dist/rendering/map-projector.js +12 -289
- package/dist/rendering/map-projector.js.map +1 -1
- package/dist/rendering/viewer-browser.d.ts.map +1 -1
- package/dist/rendering/viewer-browser.js +517 -556
- package/dist/rendering/viewer-browser.js.map +1 -1
- package/dist/rendering/viewer-diagram.d.ts +3 -5
- package/dist/rendering/viewer-diagram.d.ts.map +1 -1
- package/dist/rendering/viewer-diagram.js +30 -93
- package/dist/rendering/viewer-diagram.js.map +1 -1
- package/dist/rendering/viewer-layout.d.ts +9 -5
- package/dist/rendering/viewer-layout.d.ts.map +1 -1
- package/dist/rendering/viewer-layout.js +107 -52
- package/dist/rendering/viewer-layout.js.map +1 -1
- package/dist/rendering/viewer-navigation.d.ts +4 -0
- package/dist/rendering/viewer-navigation.d.ts.map +1 -0
- package/dist/rendering/viewer-navigation.js +8 -0
- package/dist/rendering/viewer-navigation.js.map +1 -0
- package/dist/rendering/viewer-page.d.ts +12 -28
- package/dist/rendering/viewer-page.d.ts.map +1 -1
- package/dist/rendering/viewer-page.js +133 -563
- package/dist/rendering/viewer-page.js.map +1 -1
- package/dist/setup/managed-skill-installer.d.ts +1 -1
- package/dist/setup/managed-skill-installer.d.ts.map +1 -1
- package/dist/setup/managed-skill-installer.js +1 -1
- package/dist/setup/managed-skill-installer.js.map +1 -1
- package/dist/setup/package-upgrader.d.ts.map +1 -1
- package/dist/setup/package-upgrader.js +1 -4
- package/dist/setup/package-upgrader.js.map +1 -1
- package/docs/architecture.md +74 -176
- package/docs/evaluation.md +15 -4
- package/docs/index.md +9 -2
- package/docs/map-format.md +47 -21
- package/docs/observations.md +7 -3
- package/docs/product-contract.md +61 -94
- package/examples//350/256/242/345/215/225/347/256/241/347/220/206/README.md +16 -0
- package/examples//350/256/242/345/215/225/347/256/241/347/220/206/docs/business-map/orders.yaml +267 -0
- package/package.json +4 -5
- package/.agents/skills/semantic-atlas-maintenance/SKILL.md +0 -218
- package/.agents/skills/semantic-atlas-maintenance/agents/openai.yaml +0 -4
- package/.agents/skills/semantic-atlas-maintenance/references/boundary-design.md +0 -120
- package/.agents/skills/semantic-atlas-maintenance/references/map-authoring.md +0 -127
- package/.agents/skills/semantic-atlas-maintenance/references/reconciliation.md +0 -149
- package/dist/rendering/diagram-image.d.ts +0 -17
- package/dist/rendering/diagram-image.d.ts.map +0 -1
- package/dist/rendering/diagram-image.js +0 -102
- package/dist/rendering/diagram-image.js.map +0 -1
- package/dist/rendering/manual-layout.d.ts +0 -4
- package/dist/rendering/manual-layout.d.ts.map +0 -1
- package/dist/rendering/manual-layout.js +0 -72
- package/dist/rendering/manual-layout.js.map +0 -1
- package/dist/rendering/map-camera.d.ts +0 -26
- package/dist/rendering/map-camera.d.ts.map +0 -1
- package/dist/rendering/map-camera.js +0 -54
- package/dist/rendering/map-camera.js.map +0 -1
- package/dist/rendering/viewer-legend.d.ts +0 -4
- package/dist/rendering/viewer-legend.d.ts.map +0 -1
- package/dist/rendering/viewer-legend.js +0 -138
- package/dist/rendering/viewer-legend.js.map +0 -1
|
@@ -1,289 +1,103 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: semantic-atlas
|
|
3
|
-
description:
|
|
4
|
-
compatibility:
|
|
3
|
+
description: 理解、绘制和维护有源码依据的业务流程。用于功能、缺陷、重构、评审和影响分析中的业务调查,以及新建、修改或重组业务流程图;按业务意图直接定位相关流程与源码,业务行为变化时在同一分支同步代码和相关流程。
|
|
4
|
+
compatibility: 需要 Node.js 24+、PATH 中的 semantic-atlas CLI,以及目标仓库源码。
|
|
5
5
|
---
|
|
6
6
|
|
|
7
7
|
# Semantic Atlas
|
|
8
8
|
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
9
|
+
让人和 AI 围绕同一份业务流程协作。AI 理解当前业务、核实实现、编写和维护文件;人通过只读界面逐层阅读、讨论和确认。总览与细图统一使用业务流程图。
|
|
10
|
+
|
|
11
|
+
业务图提供调查线索。当前源码、测试、已跟踪的产品决定和必要的运行证据,决定这次可以作出的结论和改动。业务行为变化时,代码与相关流程在同一分支修改、审阅和提交合入。没有业务变化时,不为代码内部调整重画流程。
|
|
12
|
+
|
|
13
|
+
## 1. 从任务确定工作范围
|
|
14
|
+
|
|
15
|
+
| 当前请求 | 本次应完成什么 |
|
|
16
|
+
| --- | --- |
|
|
17
|
+
| 功能、缺陷或重构 | 理解受影响业务,核实证据;行为变化时同步实现和相关流程,检查两者一致 |
|
|
18
|
+
| 评审或影响分析 | 对照当前源码与流程判断影响;用户仅授权分析时,报告必要修改而不直接写文件 |
|
|
19
|
+
| 新建、修改或重组流程图 | 完成指定业务范围的调查、流程文件和实际阅读检查 |
|
|
20
|
+
| 已明确源边界的格式化、局部改名等机械任务 | 直接按仓库工作流完成;业务含义保持时不改流程 |
|
|
21
|
+
| 用户明确要求处理历史观察或候选 | 使用文末可选历史工具,不改变正常工程的同步维护方式 |
|
|
22
|
+
|
|
23
|
+
普通工程任务不意味着重画整个仓库。是否提交、合入、发布或改变数据结构,遵循本次授权和仓库规则;同步代码与图表示一个完整候选,不自动取得发布或生产操作授权。
|
|
24
|
+
|
|
25
|
+
## 2. 直接定位相关业务与源码
|
|
26
|
+
|
|
27
|
+
根据任务、工作空间的项目映射和 `AGENTS.md` 定位目标仓库,当前工作目录不一定是目标仓库。从父工作空间调用时,为查询、校验和渲染命令显式传入 `--repo <目标仓库绝对路径>`;源码锚点相对该仓库解析。CLI 不递归发现子仓库的业务图,多仓库任务分别查询各自资料,不能用错误根目录返回的 `MAP_NOT_FOUND` 判断子仓库没有图。
|
|
28
|
+
|
|
29
|
+
确定目标后,从已经掌握的信息进入相关业务。AI 可以像熟悉系统的程序员一样直达目标,不必每次从总览走完整层级;人的级联浏览菜单不规定 AI 的调查顺序。
|
|
30
|
+
|
|
31
|
+
| 已有信息 | 直接入口 |
|
|
32
|
+
| --- | --- |
|
|
33
|
+
| 已知流程 ID | `semantic-atlas flows "<flow-id>" --repo "<repository-root>"` |
|
|
34
|
+
| 已知业务概念 ID | `semantic-atlas context "<concept-id>" --repo "<repository-root>"` |
|
|
35
|
+
| 只有要完成的业务行为 | `semantic-atlas search --flows "<business-query>" --repo "<repository-root>"`,选命中的流程 ID 再读该层 |
|
|
36
|
+
| 需要补看整体结构或没有合适命中 | 可选用 `semantic-atlas flows --repo "<repository-root>"` 取得根流程与简要目录 |
|
|
37
|
+
|
|
38
|
+
读取目标流程中的动作、判断、连接条件、结果、子流程和步骤引用概念的源码锚点。当前层已足以判断时直接核实对应源码;只有上层承诺、细节或必要协作会改变结论时,才补看父层、子流程或概念上下文,不展开无关邻域。
|
|
39
|
+
|
|
40
|
+
`search --flows` 根据流程及相关业务文本的词面相似度返回候选,不是向量或语义搜索。不同词汇、同义改写或不同语言可能没有命中;分数只说明这次查询的相关排序。需要概念检索时可用普通 `semantic-atlas search "<business-term>"`,同样按业务含义判断结果,而不是把分数当正确性证明。
|
|
41
|
+
|
|
42
|
+
从锚点的 `file` 定位文件,再查 `value` 指定的类、方法或函数;打开当前声明和必要调用方,确认实际动作。资料给的是导航与规则线索,当前源码和证据决定行为。
|
|
43
|
+
|
|
44
|
+
| 结果 | 怎样继续 |
|
|
45
|
+
| --- | --- |
|
|
46
|
+
| 取得相关流程或概念 | 核实当前图的规则、源码和必要使用方,不强制补走总览 |
|
|
47
|
+
| 搜索为空或存在歧义 | 使用已知业务词、可选目录或源码入口继续调查;会改变范围且仍无法确定的选择保持待核实 |
|
|
48
|
+
| 没有相关流程或 `MAP_NOT_FOUND` | 建立当前任务所需的最小业务模型;行为变更时补写相关流程,不先建完整分类体系 |
|
|
49
|
+
| 流程 ID 不存在 | 按当前目录和源码核对替代路径 |
|
|
50
|
+
| 文件无效或 CLI 不可用 | 说明资料不可用,继续有界源码调查;能在本次范围修正的资料问题一起处理 |
|
|
51
|
+
| 锚点缺失或过期 | 用当前实现找到替代入口,同步修正本次依赖的锚点,保留其他仍成立的业务知识 |
|
|
52
|
+
|
|
53
|
+
核实谁承诺结果、拥有规则与状态,谁是调用者或协作者。边界不清或需要调整业务资料时,读取[业务边界](references/boundary-design.md)。沿真实生产者、使用方和外部交接确定影响,不以目录或类数量代替业务责任。
|
|
54
|
+
|
|
55
|
+
## 3. 同步修改实现与受影响流程
|
|
56
|
+
|
|
57
|
+
从相关流程的起点走到本次可能影响的结果,核对动作、判断、条件分支、停止和恢复对象。重点确认会影响数据、费用、权限、租户隔离、接口和用户结果的路径,只追踪当前任务所需范围。
|
|
58
|
+
|
|
59
|
+
先区分差异的含义:实现违反已确认规则时修代码,并让图准确表达修复后的支持路径;业务要求改变时同步改代码和流程;源码位置变化时修正必要锚点;仅内部组织变化且业务含义不变时,保留流程。证据冲突且会改变行为时,先确认关键决定。
|
|
60
|
+
|
|
61
|
+
代码修改与相应流程文件放在同一工作分支。局部条件只改所属细图和直接提到它的说明;入口、结果、重要分支或协作变化时,再检查引用它的上层与相关协作者。不要把必要的图更新留成候选,等合入主分支后才维护。
|
|
62
|
+
|
|
63
|
+
按仓库工程工作流验证并审阅完整差异,把代码行为和图中的规则、分支、备注与源码锚点一起检查。没有业务变化,或图已完整表达修复后行为时,可以没有结构性图修改,但应说明核对结果。
|
|
64
|
+
|
|
65
|
+
## 4. 编写流程资料
|
|
66
|
+
|
|
67
|
+
首次建图或重建较大业务范围时,边分块读取源码边画,不等读完整仓库才写图。按照[流程设计中的持续建图方法](references/diagram-design.md#2-分块调查并持续修正已画流程),把已核实的局部流程及时落盘,记录未覆盖范围;后续证据改变理解时,立即修正或重构已画部分,再继续调查。图和必要状态文件承载外部记忆,当前源码仍负责证实行为。
|
|
68
|
+
|
|
69
|
+
新建图、修图或同步行为变化时:
|
|
70
|
+
|
|
71
|
+
1. 按[业务边界](references/boundary-design.md)建立当前分块有证据的责任范围与必要协作者,逐块核对源码入口、状态和规则,并随新证据修正边界与已画流程;旧节点列表不构成完整性证明。
|
|
72
|
+
2. 按[流程设计](references/diagram-design.md)决定总览和细图的边界、粒度、条件、备注与修改范围。每张图从可理解的入口走到结果;总览也表达真实先后和分支,不能用分类树或无连接卡片代替流程。
|
|
73
|
+
3. 按[文件编写](references/map-authoring.md)使用当前产品格式。复用仍成立的业务身份,共享概念只定义一次。`part_of` 表达归属,不产生执行顺序;总览 `flows` 由 AI 显式编写,步骤通过 `concept` 引用场景的自有流程,形成下层。
|
|
74
|
+
4. 同一业务责任仍成立时复用其文件;独立新业务有自己的领域和文件。文件数量由真实责任决定。新版格式需要更好的表达时,可以按已确认契约重写既有资料,无需为旧业务文件或旧格式保留兼容分支。
|
|
75
|
+
5. 源码锚点保留到具体文件、类和方法,供 AI 与 CLI 定位;Web 隐藏这些资料。备注说明业务规则的背景、目的和取舍,不写 AI 怎样安排图的理由。
|
|
76
|
+
6. 完成结构与阅读检查:
|
|
77
|
+
|
|
78
|
+
```sh
|
|
79
|
+
semantic-atlas validate --repo "<absolute-repository-root>"
|
|
80
|
+
semantic-atlas render --repo "<absolute-repository-root>" --output "<repository-root>/tmp/business-flow.html"
|
|
81
|
+
git diff --check
|
|
82
|
+
git diff -- docs/business-map/
|
|
60
83
|
```
|
|
61
84
|
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
relevant tests, and confirm the business action stated in `description`.
|
|
82
|
-
A missing file or declaration follows the stale-anchor route below. Unbound
|
|
83
|
-
symbols and other anchor kinds remain useful entry points. Query another
|
|
84
|
-
returned stable ID only
|
|
85
|
-
when an owner, upstream action, downstream consumer, shared data concept,
|
|
86
|
-
invariant, interface, or business-relevant path could change the
|
|
87
|
-
implementation scope.
|
|
88
|
-
- An empty search result means the repository has a map without sufficiently
|
|
89
|
-
related vocabulary. Search current product documents and source using the
|
|
90
|
-
original query, likely business synonyms, and directly observed
|
|
91
|
-
collaborators.
|
|
92
|
-
- Ranked candidates that remain indistinguishable after task-specific
|
|
93
|
-
comparison form a bounded ambiguous result. Continue with current evidence
|
|
94
|
-
when it can identify the owner; otherwise preserve the unresolved choice.
|
|
95
|
-
- `MAP_NOT_FOUND` means the repository has no configured shared business map.
|
|
96
|
-
When the map is absent, build the smallest source-supported business model needed for the task.
|
|
97
|
-
Start from the user-visible outcome, identify only the owning business scope,
|
|
98
|
-
actions, data, rules, and interfaces that current evidence requires, and stop
|
|
99
|
-
when the engineering boundary is source-confirmable. Limit this model to
|
|
100
|
-
business meaning supported by the current task rather than repository-folder
|
|
101
|
-
structure or a complete taxonomy.
|
|
102
|
-
- `MAP_DOCUMENT_INVALID`, an unavailable CLI, or an infrastructure failure
|
|
103
|
-
makes map knowledge unavailable for this task. Preserve the failure, build
|
|
104
|
-
the same bounded current-evidence model, and report observation recording as
|
|
105
|
-
unavailable when the CLI boundary cannot accept it.
|
|
106
|
-
- A node without anchors still supplies business vocabulary and relations.
|
|
107
|
-
Search its name, aliases, neighboring concepts, and interface terms, then
|
|
108
|
-
follow current code structure.
|
|
109
|
-
- A missing or stale anchor weakens only that navigation hint. Use current
|
|
110
|
-
evidence to find the replacement location without discarding unrelated
|
|
111
|
-
stable business meaning.
|
|
112
|
-
|
|
113
|
-
Record a successful selection as `context` with the original business query
|
|
114
|
-
and selected stable ID. Record an empty result as `concept_not_found`, an
|
|
115
|
-
unresolved candidate choice as `concept_ambiguous`, and an unavailable search
|
|
116
|
-
contract as `unavailable`.
|
|
117
|
-
|
|
118
|
-
For a mapless task, the observation query records the bounded outcome:
|
|
119
|
-
|
|
120
|
-
```json
|
|
121
|
-
{
|
|
122
|
-
"selector": "<business term>",
|
|
123
|
-
"outcome": "map_not_found"
|
|
124
|
-
}
|
|
125
|
-
```
|
|
126
|
-
|
|
127
|
-
## Confirm The Current-Evidence Model
|
|
128
|
-
|
|
129
|
-
Identify who promises the task's outcome and controls its rules/state, then
|
|
130
|
-
separate that owner from callers, consumers and infrastructure collaborators.
|
|
131
|
-
When ownership or lifecycle coverage is uncertain, read the shared
|
|
132
|
-
[boundary-design reference](../semantic-atlas-maintenance/references/boundary-design.md)
|
|
133
|
-
and apply its source-to-map coverage and cohesion questions to this task only.
|
|
134
|
-
An ordinary engineering task needs a sufficient local model, not a complete
|
|
135
|
-
project partition or a map-authoring artifact.
|
|
136
|
-
|
|
137
|
-
For every statement that could control the change:
|
|
138
|
-
|
|
139
|
-
1. Open current source or tests that implement or exercise the behavior.
|
|
140
|
-
2. Open the tracked product document when it owns the durable rule or outcome.
|
|
141
|
-
3. Confirm both endpoints of an invocation, shared-data, invariant, publish, or
|
|
142
|
-
consume relation when that relation expands the required scope.
|
|
143
|
-
4. Use runtime evidence when the conclusion depends on deployed state rather
|
|
144
|
-
than repository behavior.
|
|
145
|
-
5. Classify relevant map hypotheses as confirmed, missing, stale,
|
|
146
|
-
contradicted, or unresolved. Let confirmed current evidence control the
|
|
147
|
-
task. Keep unresolved statements out of decisive conclusions.
|
|
148
|
-
|
|
149
|
-
Trace a downstream symptom toward its confirmed upstream cause before editing.
|
|
150
|
-
For shared data or interfaces, inspect every confirmed producer and consumer
|
|
151
|
-
needed to preserve the contract. Keep unrelated neighbors outside the change.
|
|
152
|
-
|
|
153
|
-
## Check Relevant Business Flows
|
|
154
|
-
|
|
155
|
-
Use each returned flow as a compact hypothesis about the business-relevant
|
|
156
|
-
actions, decisions, branches, and outcomes in one scenario. Follow only the
|
|
157
|
-
flows and paths that intersect the task; ordinary relation context remains
|
|
158
|
-
sufficient when no flow is relevant.
|
|
159
|
-
|
|
160
|
-
1. Before editing, trace each relevant path from `startsAt` through its labeled
|
|
161
|
-
decisions to the outcomes that could change. Give special attention to paths
|
|
162
|
-
controlling durable data, provider usage or cost, authorization or tenant
|
|
163
|
-
isolation, interfaces, and user-visible results.
|
|
164
|
-
2. Confirm every step or branch that controls the engineering decision in
|
|
165
|
-
current source, tests, tracked product documents, or required runtime
|
|
166
|
-
evidence. Flow order is an investigation lead rather than current execution
|
|
167
|
-
truth.
|
|
168
|
-
3. After implementation or review, trace the affected paths again. Check that
|
|
169
|
-
preserved branches still reach their intended outcomes and that an intended
|
|
170
|
-
product change has a clear durable meaning.
|
|
171
|
-
4. Classify a discrepancy before changing either side:
|
|
172
|
-
- repair source when implementation accidentally breaks the confirmed
|
|
173
|
-
business path;
|
|
174
|
-
- propose a flow update when confirmed product intent changed the durable
|
|
175
|
-
business path;
|
|
176
|
-
- propose a flow correction when decisive current evidence establishes that
|
|
177
|
-
the retained path was already stale;
|
|
178
|
-
- preserve the discrepancy as unresolved when available evidence cannot
|
|
179
|
-
choose the durable behavior;
|
|
180
|
-
- keep the flow unchanged when only implementation structure changed.
|
|
181
|
-
|
|
182
|
-
Keep routine parameter validation, DTO conversion, helpers, framework wiring,
|
|
183
|
-
and Service or Queue names in source rather than flow steps.
|
|
184
|
-
|
|
185
|
-
## Implement And Verify
|
|
186
|
-
|
|
187
|
-
Continue through the repository's normal engineering workflow after the
|
|
188
|
-
current-evidence model is clear. Implement the confirmed cause and affected
|
|
189
|
-
collaborators, add regression coverage at the public behavior boundary, run
|
|
190
|
-
the repository's required checks, and review the final diff against the task
|
|
191
|
-
scope.
|
|
192
|
-
|
|
193
|
-
Final engineering conclusions identify the business boundary, decisive current
|
|
194
|
-
evidence, implementation or review scope, and verification. Phrase map-only
|
|
195
|
-
statements as leads or uncertainty rather than current behavior.
|
|
196
|
-
|
|
197
|
-
## Decide Post-Task Business-Knowledge Maintenance
|
|
198
|
-
|
|
199
|
-
After the engineering or review result is known, choose one maintenance disposition:
|
|
200
|
-
|
|
201
|
-
- `candidate`: current evidence establishes stable business meaning that the
|
|
202
|
-
shared map omits or represents incorrectly. Record one or more domain-owned
|
|
203
|
-
map-update candidates with decisive evidence. Use `kind: "flow"` when the
|
|
204
|
-
durable correction concerns a scenario's actions, decisions, labeled
|
|
205
|
-
branches, or outcomes.
|
|
206
|
-
- `already_represented`: the shared map still expresses the stable business
|
|
207
|
-
meaning needed by the task. Record no candidate.
|
|
208
|
-
- `implementation_local`: the result changes only helpers, framework wiring,
|
|
209
|
-
source organization, tests, or another non-durable implementation detail.
|
|
210
|
-
Record no candidate.
|
|
211
|
-
- `unresolved`: available evidence cannot establish durable business identity,
|
|
212
|
-
ownership, or relation direction. Preserve the uncertainty without proposing
|
|
213
|
-
a canonical edit.
|
|
214
|
-
|
|
215
|
-
A no-change disposition is a complete result when current shared knowledge
|
|
216
|
-
already represents the durable meaning or the change is implementation-local.
|
|
217
|
-
Add concepts, relations, and flows only when current evidence supports their
|
|
218
|
-
accuracy. When no relevant flow changed, record no flow candidate.
|
|
219
|
-
|
|
220
|
-
For every proposed candidate, identify the actual business responsibility from
|
|
221
|
-
its outcomes, owned data/rules, lifecycle and collaborators using the same
|
|
222
|
-
boundary-design reference when that ownership needs investigation. Reuse a mapped
|
|
223
|
-
domain when that meaning matches; an independently meaningful new business area receives
|
|
224
|
-
its own stable `businessDomainId`, even when another domain already has a YAML.
|
|
225
|
-
Use narrower capabilities for behavior belonging inside an existing area.
|
|
226
|
-
The maintenance Skill rechecks this ownership before choosing files. A required
|
|
227
|
-
multi-file ownership correction is explicit authoring/reorganization work,
|
|
228
|
-
while retained candidate origins keep their immutable domain identity.
|
|
229
|
-
|
|
230
|
-
For mapped and mapless tasks alike, retain only the stable meaning established
|
|
231
|
-
by current evidence. Use `unresolved` when the task cannot establish business
|
|
232
|
-
identity or ownership. A local engineering task does not imply mapping the
|
|
233
|
-
whole repository.
|
|
234
|
-
|
|
235
|
-
## Record Accuracy Evidence
|
|
236
|
-
|
|
237
|
-
For business-changing work, read
|
|
238
|
-
[references/observations.md](references/observations.md) after the engineering
|
|
239
|
-
or review result and verification are known.
|
|
240
|
-
|
|
241
|
-
- For engineering and analysis work, record one task observation. It contains
|
|
242
|
-
the map-query outcome, selected concepts, current-evidence dispositions,
|
|
243
|
-
map-update candidates from a `candidate` maintenance disposition, and any
|
|
244
|
-
explicit human correction.
|
|
245
|
-
- For independent review, record one review observation that references the
|
|
246
|
-
existing task observation and contains the accuracy verdict. Keep the task
|
|
247
|
-
observation immutable. When no task observation is available, report the
|
|
248
|
-
missing accuracy-evidence link separately from the review verdict.
|
|
249
|
-
|
|
250
|
-
Independent review owns accuracy judgments, so task observations contain
|
|
251
|
-
investigation evidence rather than correctness verdicts. Generate one stable
|
|
252
|
-
observation ID for the run and reuse the same complete document when retrying an
|
|
253
|
-
interrupted submission.
|
|
254
|
-
|
|
255
|
-
Submit the matching complete JSON document through the installed CLI:
|
|
256
|
-
|
|
257
|
-
```text
|
|
258
|
-
semantic-atlas observe task --stdin [--repo <repository-root>]
|
|
259
|
-
semantic-atlas observe review --stdin [--repo <repository-root>]
|
|
260
|
-
```
|
|
261
|
-
|
|
262
|
-
Report the recorded or idempotent outcome with the engineering result. When
|
|
263
|
-
the observation command fails, the engineering result remains unchanged;
|
|
264
|
-
report the observation failure separately so review can distinguish delivery
|
|
265
|
-
evidence from missing accuracy evidence.
|
|
266
|
-
|
|
267
|
-
## Hand Off Canonical Maintenance
|
|
268
|
-
|
|
269
|
-
Keep canonical map editing in a separate maintenance change after stable reviewed source is available.
|
|
270
|
-
For this candidate-driven handoff, the `semantic-atlas-maintenance` Skill
|
|
271
|
-
rechecks real business ownership using its common authoring rules, then handles
|
|
272
|
-
one confirmed domain and owning YAML. Ownership corrections needing multiple
|
|
273
|
-
files follow its ordinary reviewed authoring path with accurate separate origin
|
|
274
|
-
accounting. Both paths validate the complete graph, inspect the affected Viewer
|
|
275
|
-
areas and submit the Git diff for independent review.
|
|
276
|
-
|
|
277
|
-
A post-integration maintenance run can examine retained candidates from
|
|
278
|
-
business-changing results; an empty or no-change run is successful. Periodic
|
|
279
|
-
reconciliation remains a fallback for accumulated drift, missed observations,
|
|
280
|
-
and changes outside the normal engineering workflow. The understanding and
|
|
281
|
-
maintenance contracts run independently of task orchestrators.
|
|
282
|
-
|
|
283
|
-
## Report The Result
|
|
284
|
-
|
|
285
|
-
Report the business boundary, decisive current evidence, engineering scope,
|
|
286
|
-
verification, accuracy-observation outcome, and maintenance disposition. For
|
|
287
|
-
`candidate`, include the business domain, proposed durable correction, and
|
|
288
|
-
evidence. For `already_represented`, `implementation_local`, or `unresolved`,
|
|
289
|
-
state the evidence-based reason and record no map-update candidate.
|
|
85
|
+
打开受影响流程,按实际变化核对必要的上下层进入与返回、主线、关键分支、数量/时间边界和备注。查看实际阅读尺寸下的文字、连线与角标。角标直接进入子流程;点击节点正文只在有业务备注时打开默认关闭的详情,详情不再承担进入操作。无备注的普通节点保持原样。
|
|
86
|
+
|
|
87
|
+
结构校验证明文件与引用有效,源码证据证明行为,实际阅读证明表达清楚;三者不能互相替代。
|
|
88
|
+
|
|
89
|
+
## 5. 合并时按最终行为消除冲突
|
|
90
|
+
|
|
91
|
+
代码与流程图作为同一业务变更提交和合入。审查通过后,按当前授权执行仓库的提交或合并流程;只有本地修改时如实报告候选状态。
|
|
92
|
+
|
|
93
|
+
遇到分支合并或重放冲突,先理解两边各自改变的规则、入口、结果和协作,再按合并后的代码重审受影响流程。即使文本没有冲突,也要检查两项行为变化叠加后,分支条件、顺序、子流程引用和备注是否仍然成立。不能仅保留两边文字或按格式拼接 YAML。
|
|
94
|
+
|
|
95
|
+
解决后重跑受影响的业务验证、完整图校验和必要阅读检查,确保合并结果中的实现与流程一致。未取得业务决定或关键证据时,保留具体阻塞,不用测试断言替代决定。
|
|
96
|
+
|
|
97
|
+
## 6. 可选:已有历史记录
|
|
98
|
+
|
|
99
|
+
正常工程不要求先生成候选、记录观察或等待主分支更新。只有用户明确要求准确性记录,或要处理已有历史观察和候选时,才读取[观察记录](references/observations.md)与[历史候选校准](references/reconciliation.md),使用已有 `observe`、`reconcile` 命令。它们不替代本次同分支维护,也不阻断代码与流程的交付。
|
|
100
|
+
|
|
101
|
+
## 7. 交付
|
|
102
|
+
|
|
103
|
+
说明当前业务边界、关键依据、代码与流程分别改了什么,以及实际验证。没有业务变化或无需结构性改图时给出简短依据。直接画图提供阅读入口与文件;仅分析时说明建议改动。把已核实的覆盖、尚未调查的范围、资料缺口、未完成的运行验证,以及本地修改与实际合入状态分别讲清楚。当前结果已充分验证后结束,不补画无关业务。
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
interface:
|
|
2
2
|
display_name: "Semantic Atlas"
|
|
3
|
-
short_description: "
|
|
4
|
-
default_prompt: "
|
|
3
|
+
short_description: "理解业务,并同步实现与流程图"
|
|
4
|
+
default_prompt: "使用 $semantic-atlas 根据已有 ID 或业务意图直接定位相关流程和源码证据;业务行为变化时在同一分支同步修改代码与相关流程,核对实际阅读和行为,合并时按最终代码重审受影响路径。"
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
# 业务边界判断
|
|
2
|
+
|
|
3
|
+
创建或改变业务划分,或某个所有者、生命周期与协作者可能改变工程结论时读取。本页负责判断业务责任;[文件编写](map-authoring.md)负责表达。按当前范围使用:项目请求核对项目内相关责任,局部请求核对完整邻域,普通工程任务只建立足以决定改动的模型。
|
|
4
|
+
|
|
5
|
+
## 先确定责任,再安排流程
|
|
6
|
+
|
|
7
|
+
一个业务范围承诺一个可理解的结果,拥有让结果成立的规则与状态,并解释这些状态如何建立、使用、改变和结束。同一客户旅程可以跨越多个这样的所有者;调用别人、使用同一张表、出现在同一路径,只能证明协作。
|
|
8
|
+
|
|
9
|
+
从当前分块的证据建立责任判断,再选择所属文件;后续证据可能要求修改已定边界。对这块已经调查的范围回答:
|
|
10
|
+
|
|
11
|
+
| 问题 | 要取得的证据 |
|
|
12
|
+
| --- | --- |
|
|
13
|
+
| 谁依赖什么结果? | 用户、运营者或其他业务可以依赖的承诺 |
|
|
14
|
+
| 谁决定规则和状态? | 权威记录的含义、允许的变化和判断权 |
|
|
15
|
+
| 生命周期怎样开始与结束? | 真实入口、变更、停止、恢复及重要拒绝/失败路径 |
|
|
16
|
+
| 与谁交换什么? | 输入输出、协作契约、外部所有者与当前仓库的限度 |
|
|
17
|
+
| 哪里证明这些事实? | 当前入口、写入方、规则与测试;会改变边界的缺口 |
|
|
18
|
+
|
|
19
|
+
简短任务可以把判断留在工作说明里,不必新增文档。以上问题用来检验现有责任,不形成没有业务依据的新功能。
|
|
20
|
+
|
|
21
|
+
## 独立核对覆盖
|
|
22
|
+
|
|
23
|
+
先从产品承诺和用户/运营入口发现支持的业务,再用旧图核对。检查会改变当前结论的状态写入、配置与权限所有者、事件/任务/回调和重要分支测试。技术目录帮助定位,不能决定业务划分。
|
|
24
|
+
|
|
25
|
+
边读边补充覆盖记录,分清已证实、未调查和证据不足;不必等全部业务读完才落图。按需保留一张简表:`场景或生命周期 → 所有者 → 决定性证据 → 对应概念/流程,或省略原因`。协作、实现细节和待核实都可以成为明确的省略理由。已经画出某个节点,不证明覆盖完整。
|
|
26
|
+
|
|
27
|
+
多个等价入口可以共用一个场景和多个锚点。只有动作具有独立业务判断或结果时才单独建场景。方法数量、CRUD 列表和每个接口一张图都不是完成标准。
|
|
28
|
+
|
|
29
|
+
## 检验划分是否成立
|
|
30
|
+
|
|
31
|
+
| 可能的问题 | 如何用证据判断 |
|
|
32
|
+
| --- | --- |
|
|
33
|
+
| 过大 | 是否存在能分别交付结果、各自决定规则和状态的责任?分别保留所有者与协作。 |
|
|
34
|
+
| 过碎 | 这些片段是否共同建立、改变或结束同一个结果?保留一个责任,下分能力或场景。 |
|
|
35
|
+
| 遗漏 | 独立发现的入口、状态变化或退出路径是否有重要行为却没有所有者?补到相应层,或记录缺口。 |
|
|
36
|
+
| 放错位置 | 是否仅因调用、消费或目录相同,就放在某业务下面?按规则与生命周期的实际决定者修正归属。 |
|
|
37
|
+
|
|
38
|
+
共享概念只定义一次,再表达已确认的读写和调用关系。同一物理表可能承担不同业务含义;同义业务也可能由多个技术模块实现。依业务语义保留身份。
|
|
39
|
+
|
|
40
|
+
通用执行能力如果独立承诺取消、恢复、完成等生命周期,可以有自己的业务责任;辅助转换、队列包装和适配器的可调用方法,不足以证明独立业务。
|
|
41
|
+
|
|
42
|
+
## 区分归属与阅读范围
|
|
43
|
+
|
|
44
|
+
`part_of` 记录业务归属。总览流程可以引用不同所有者的场景,解释端到端旅程,但不把被引用的业务改归总览所有。每张图回答的范围由当前阅读问题决定,具体表达见[流程设计](diagram-design.md)。
|
|
45
|
+
|
|
46
|
+
跨仓库或第三方内部未在当前证据范围时,只画本地集成责任、已确认接口和必要交接。不要用熟悉的外部产品名代替其内部实现证据。
|
|
47
|
+
|
|
48
|
+
## 何时结束
|
|
49
|
+
|
|
50
|
+
当前分块拥有可证实的结果、规则或状态,重要路径及协作在证据边界内可解释时,及时编码为概念和流程,保留仍准确的稳定 ID,继续下一处必要调查。新证据揭示归属错误、遗漏或跨业务交接时,回头重构已画部分,具体方法见[持续建图](diagram-design.md#2-分块调查并持续修正已画流程)。
|
|
51
|
+
|
|
52
|
+
不确定性会改变归属时,明确记录并只推进有依据的部分。工程调查在行为、所有者和必要协作已足以决定本次改动时结束;画图任务在指定范围的覆盖与完整路径可解释时结束。结构校验和可读性都不能替代业务判断。
|
|
@@ -0,0 +1,140 @@
|
|
|
1
|
+
# 设计可阅读、可维护的业务流程图
|
|
2
|
+
|
|
3
|
+
在新建业务图、调整图的范围或层次、处理读者看不懂的图,以及判断业务更新应改哪些图时读取本指南。
|
|
4
|
+
|
|
5
|
+
总览和细图统一使用业务流程图。每层都要能从入口沿真实动作、条件和交接走到结果;分类目录与无连接的业务卡片不能代替总览。
|
|
6
|
+
|
|
7
|
+
软件提供图的表达、渲染、交互和结构检查。AI 根据当前业务资料判断业务边界、图的范围、阅读层次、表达方式和修改范围。节点数量、图的深度和排布方向都服务于具体内容与读者的任务。
|
|
8
|
+
|
|
9
|
+
先按[业务边界](boundary-design.md)核实谁拥有结果、规则和生命周期,再组织阅读。文件字段和 CLI 命令以当前安装版本的[编写约定](map-authoring.md)为准。AI 显式编写总览流程,使用步骤的 `concept` 引用场景的自有流程形成下层;`part_of` 只表示业务归属,不推断执行顺序。需要新增文件结构时按项目授权确认后实施。
|
|
10
|
+
|
|
11
|
+
## 1. 明确读者正在判断什么
|
|
12
|
+
|
|
13
|
+
从用户请求、已有图和业务资料确定这次阅读的目的。例如:
|
|
14
|
+
|
|
15
|
+
- 系统为客户完成哪些事情,这些业务怎样协作?
|
|
16
|
+
- 用户启动监控后,会经过哪些环节,得到什么结果?
|
|
17
|
+
- 读到一页帖子后,什么条件让这条路线继续或结束?
|
|
18
|
+
|
|
19
|
+
把当前实现、已经确认的业务要求、候选变化和用途解释分别表明依据。业务目的从决定或场景证据取得;源码说明当前做法。会改变图中结果的资料缺口,保留明确的待核实状态。
|
|
20
|
+
|
|
21
|
+
## 2. 分块调查并持续修正已画流程
|
|
22
|
+
|
|
23
|
+
首次建图或从零重建时,把图当作持续修正的外部工作记忆。无需先看完整仓库:选择当前能核实的一条用户路径、规则或生命周期,读相关入口、决定性方法及必要使用方,建立有来源的局部闭环。
|
|
24
|
+
|
|
25
|
+
### 从一个有证据的分块继续
|
|
26
|
+
|
|
27
|
+
1. 明确当前要查的入口、结果和疑问,读取足以证实该路径的源码与规则,不先收集所有目录。
|
|
28
|
+
2. 当证据已支持一条可理解的路径,及时把动作、关键条件、结果和符号锚点写入流程文件,再继续下一块。只画已经核实的内容;外部交接到当前证据边界为止,未知内部过程留作调查缺口。
|
|
29
|
+
3. 保存后核对局部业务含义及已有文件之间的引用。小范围校验帮助发现断链,不能代替继续调查,也不意味着整个业务已覆盖。
|
|
30
|
+
4. 下一块优先处理会改变当前理解的未知:例如同一状态的其他写入方、回调、恢复入口、退出路径或跨业务消费者。根据新证据回看已画流程,再决定继续深入还是转向另一项指定业务。
|
|
31
|
+
|
|
32
|
+
分块以业务证据与理解范围决定,不固定文件数、节点数、层数或调查轮数。需要更多资料才能证实一个条件时先补关键证据;已有局部路径足以写清时,不因仓库其余部分未读而延迟落图。
|
|
33
|
+
|
|
34
|
+
### 新证据要改回已画部分
|
|
35
|
+
|
|
36
|
+
新读到的事实否定了原来的顺序、条件、归属或生命周期时,立即修改、删除或重构原图,不能只追加一个新节点或备注保留相互矛盾的旧解释。必要时拆分或合并流程,修正共享概念、子流程引用、上层摘要、业务备注与锚点,再核对受影响的来路和结果。
|
|
37
|
+
|
|
38
|
+
例如先看到“订单创建后调用发货”,随后发现发货由支付成功事件触发,应改回已画的总览和发货入口,而不是在旧的串行路径旁再追加一条支付事件线。现有方法名或图上的旧结论不能替代调用、状态和运行证据。
|
|
39
|
+
|
|
40
|
+
发现跨业务关系时,核实交接两端的真实契约,回头调整已经画出的所有者、输入输出和连接。未读的另一端不能被描述为已核实内部流程;先表达已证实的边界,并保留明确的下一处调查入口。
|
|
41
|
+
|
|
42
|
+
### 用文件保存进展与恢复上下文
|
|
43
|
+
|
|
44
|
+
长任务在目标项目的 `tmp/` 中维护带日期和主题的状态文件;已有合适记录时直接更新。保存用户范围、当前结论及证据位置、已写概念/流程、未覆盖业务、影响结论的疑问,以及下一步要打开的具体入口。确认事实、暂定理解与未知分开写,避免把“看过文件”当成覆盖完成。
|
|
45
|
+
|
|
46
|
+
业务流程和锚点保存可复用的已核实知识,状态文件保存当前调查进度与待核实项;不向业务 UI 加入调查过程或 AI 编排理由。重要分块落盘或理解重构后更新状态。上下文恢复时,先读状态,再核对当前 Git 差异、已画流程和下一处决定性源码;不依赖上一段对话的记忆继续推断。
|
|
47
|
+
|
|
48
|
+
当指定范围的入口、重要分支、状态变化、退出与恢复路径已有证据支持,协作边界可解释,且相关图已经消除旧误解时,完成整体校验和实际阅读后交付。尚未调查或缺证据的部分单独报告;不把局部合法图宣称为整个系统的完成图,也不为凑齐固定层级扩画无关内容。
|
|
49
|
+
|
|
50
|
+
## 3. 分别判断业务边界与图的边界
|
|
51
|
+
|
|
52
|
+
业务边界由结果承诺、规则与状态的所有权、完整生命周期和协作契约决定。一张图的边界由读者这次需要理解的范围决定。
|
|
53
|
+
|
|
54
|
+
同一条客户旅程可以跨多个业务所有者;一个业务也可以用多张图解释。保留共享概念的稳定编号与资料,让各图引用对应业务;参与一张流程图只表达协作,业务归属继续由所有权决定。
|
|
55
|
+
|
|
56
|
+
在选择本层节点前,明确:
|
|
57
|
+
|
|
58
|
+
| 问题 | 对画图的作用 |
|
|
59
|
+
| --- | --- |
|
|
60
|
+
| 从什么场景开始,到什么结果结束? | 决定本图起点、终点和主要路径 |
|
|
61
|
+
| 这一层读者需要作什么判断? | 决定粒度与关键条件 |
|
|
62
|
+
| 哪些协作者需要出现,怎样交接? | 决定图的外部边界与必要引用 |
|
|
63
|
+
| 哪些细节适合继续深入? | 决定下一层要解释的内容 |
|
|
64
|
+
|
|
65
|
+
图的范围和层次由 AI 在编写时判断,界面不展示 AI 安排图的理由。业务规则自身的目的和取舍写入相应节点的备注;局部修改沿用仍然成立的边界。
|
|
66
|
+
|
|
67
|
+
## 4. 根据理解成本安排层次
|
|
68
|
+
|
|
69
|
+
总览先建立主要业务、关键交接和结果的联系,具体环节再展开其规则。AI 依据实际内容决定层数:简单业务可以在一层读完,复杂业务可以逐层深入。
|
|
70
|
+
|
|
71
|
+
“一层围绕一个问题”是组织方法。紧密相关、共同解释同一结果的问题可以放在一起。判断是否拆图时,检查:
|
|
72
|
+
|
|
73
|
+
- 当前画面是否同时要求读者理解多种粒度或几条独立业务?
|
|
74
|
+
- 一个节点是否需要塞入多个动作、判断和例外才能说清?
|
|
75
|
+
- 连线交叉或长篇文字是否掩盖了主要路径?
|
|
76
|
+
- 某个环节是否有独立、可命名的详细问题,值得未来单独进入?
|
|
77
|
+
|
|
78
|
+
需要拆分时,在上层保留这一步做什么、改变结果的重要条件、产物和详细内容入口;下一层从这个环节的真实输入展开到它承诺的结果。当前 Viewer 只展示显式流程;流程步骤通过概念引用连接场景自己的细图。上层与下层分别交代真实业务路径,保持业务归属真实,不为导航修改所有权。
|
|
79
|
+
|
|
80
|
+
避免仅按技术目录、接口个数、节点数量或固定层数切图。读者能顺着主线理解并找到完整分支,是粒度是否合适的依据。
|
|
81
|
+
|
|
82
|
+
## 5. 写清每条流程连接
|
|
83
|
+
|
|
84
|
+
使用动作、判断与结果表达流程,必要的业务交接放在相应步骤和条件中。连线表示执行顺序或条件后续;业务归属、资料分类和依赖保留在概念资料中,不冒充流程连接。
|
|
85
|
+
|
|
86
|
+
串联箭头表达真实先后;并行路径分别交代触发和汇合;循环写清回到哪一步。选用当前格式能准确表达的结构,涉及新的并行或导航语义时先确定产品契约。
|
|
87
|
+
|
|
88
|
+
每个动作框表达一个可理解的动作;判断框表达一个能作答的问题。复杂条件拆开后,核对“全部满足”或“任意一项满足”的关系仍然等价。分别检查:
|
|
89
|
+
|
|
90
|
+
| 判断要素 | 要写清的内容 |
|
|
91
|
+
| --- | --- |
|
|
92
|
+
| 对象和范围 | 当前判断一条记录、一个账号、一条来源路线,还是整轮任务 |
|
|
93
|
+
| 成立条件 | 全部或任意条件;等于边界、信息待定分别怎样处理 |
|
|
94
|
+
| 生效时点 | 保存前判断,还是接收整页后控制下一次请求 |
|
|
95
|
+
| 结果与后续 | 继续哪一步、停止哪个对象、已有数据怎样保留或处理 |
|
|
96
|
+
|
|
97
|
+
例如两个上限共同控制采集,应写“条数或页数任意一项达到上限后结束本路线”,并交代计数范围和当前页的处理。“继续”“完成”“去重”等词需要具体对象:写“读取这个接口的下一页”“结束本路线”“平台名称和帖子 ID 相同,沿用已有记录”。
|
|
98
|
+
|
|
99
|
+
数量、时间、缓存、资格、权限、失败和恢复规则,只在影响当前业务结果时进入本图。细节分别说明单位、计算范围、生效时点、接受的取舍与证据。
|
|
100
|
+
|
|
101
|
+
## 6. 让人能评价规则的合理性
|
|
102
|
+
|
|
103
|
+
动作和判断说明发生什么;相邻说明交代为什么:
|
|
104
|
+
|
|
105
|
+
- **业务目的**:谁需要这条规则,它帮助取得什么结果。
|
|
106
|
+
- **接受的代价**:在成本、覆盖、新鲜度、失败恢复上作出的取舍。
|
|
107
|
+
- **依据与状态**:已经记录的决定、当前实现、接口能力或有事实支持的解释。
|
|
108
|
+
|
|
109
|
+
上层保留影响结果的重要取舍,详细依据放相邻说明或更细的图。多个独立判断分别对应各自理由,避免用一段笼统背景解释整张图。
|
|
110
|
+
|
|
111
|
+
采用读者使用的业务名和完整动作。一个平台类别、编号或术语容易混淆时,在第一次出现处写清含义。长篇内容先检查是否属于当前层,再决定移动说明、拆判断或安排细图。
|
|
112
|
+
|
|
113
|
+
## 7. 按业务影响决定修改范围
|
|
114
|
+
|
|
115
|
+
先核实业务变化,再在代码所在分支同步它影响的图、摘要、引用和来源。沿用仍准确的概念身份与表达,围绕必要变化整理完整结果;无需为旧格式兼容保留已经妨碍表达的结构。
|
|
116
|
+
|
|
117
|
+
| 变化 | 通常需要检查与调整的范围 |
|
|
118
|
+
| --- | --- |
|
|
119
|
+
| 内部代码移动,业务含义保持 | 相应源码引用;图的业务结构可以保持 |
|
|
120
|
+
| 一条内部规则或条件变化 | 所属细图、规则说明,以及提到该条件的摘要 |
|
|
121
|
+
| 入口、产物、重要分支或协作契约变化 | 该流程、引用它的上层节点和相关协作者 |
|
|
122
|
+
| 业务所有权或生命周期变化 | 重新检查相关边界,按需拆分、合并或重组多张图并更新引用 |
|
|
123
|
+
| 仅有表达或阅读问题 | 调整节点用语、布局和阅读路径,保持已确认业务含义 |
|
|
124
|
+
|
|
125
|
+
例如把某个内部数量上限改为另一个值,先更新对应规则与直接提到它的说明;首次启动开始支持另一类结果时,需要同时检查上层承诺和进入路径。软件文件变化多寡只提供线索,业务影响决定图的改动半径。代码与对应图一起审阅、提交和合入,不把图更新默认留到主分支之后。
|
|
126
|
+
|
|
127
|
+
合并或重放后,按最终代码重走受影响路径,并核对两边规则叠加后的结果;条件、顺序、子流程引用、备注和上层承诺都可能需要调整。文字无冲突或两段 YAML 都保留下来,不证明合并后的业务自洽。
|
|
128
|
+
|
|
129
|
+
## 8. 从读者路径验收
|
|
130
|
+
|
|
131
|
+
先核业务含义,再检查结构,最后查看实际渲染:
|
|
132
|
+
|
|
133
|
+
1. 从当前支持的总览或入口找到目标业务,确认当前范围和外部交接容易理解。
|
|
134
|
+
2. 走正常路径及关键分支,找到清楚的结果、继续或停止对象。
|
|
135
|
+
3. 找到数量、时间、权限和失败规则的具体作用范围,以及主要取舍和依据。
|
|
136
|
+
4. 通过角标进入子流程并返回,检查上下层承诺一致;有业务备注时点击正文查看,备注详情不承担进入操作。
|
|
137
|
+
5. 核对共享概念、节点引用和来源保持一致;完整差异只包含本轮业务影响。
|
|
138
|
+
6. 在实际阅读比例下检查文字、连线、条件标签和说明,按影响调整表达或层次。
|
|
139
|
+
|
|
140
|
+
结构检查证明文件和引用有效,读者路径与业务证据证明图是否讲清楚。完成当前请求的业务范围和阅读结果后交付。
|