@namewta/speculo 1.0.2 → 1.0.3
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/README.md +6 -2
- package/package.json +2 -2
- package/template/AGENTS.md +3 -1
- package/template/canonical/canonical-specdev-goal-plan.md +757 -225
- package/template/canonical/canonical-specdev-grill-with-docs.md +221 -133
- package/template/canonical/canonical-specdev-spec.md +73 -3
- package/template/canonical/canonical-specdev-tickets.md +681 -252
- package/template/canonical/canonical-specdev-wayfinder.md +330 -113
- package/template/commands/git-repository-audit.md +3 -602
- package/template/commands/references/git-repository-audit-procedure.md +608 -0
- package/template/skills/writing-great-skills/SKILL.md +2 -0
- package/template/skills/writing-great-skills/references/document-contract.md +23 -0
- package/template/workflows/learning/common/rules/activation-and-memory.md +7 -3
- package/template/workflows/ops/common/rules/activation-and-memory.md +7 -3
- package/template/workflows/person/common/rules/activation-and-memory.md +7 -3
- package/template/workflows/specdev/G-grill-with-docs/G-grill-with-docs.md +13 -136
- package/template/workflows/specdev/G-grill-with-docs/references/interview-procedure.md +134 -0
- package/template/workflows/specdev/I-implement/I-implement.md +15 -189
- package/template/workflows/specdev/I-implement/evidence-template.md +12 -0
- package/template/workflows/specdev/I-implement/execution-preflight.md +1 -1
- package/template/workflows/specdev/I-implement/references/implementation-procedure.md +192 -0
- package/template/workflows/specdev/P-goal-plan/P-goal-plan.md +28 -143
- package/template/workflows/specdev/P-goal-plan/completion-control.md +1 -1
- package/template/workflows/specdev/P-goal-plan/references/goal-lifecycle.md +35 -0
- package/template/workflows/specdev/P-goal-plan/references/goal-tickets-map-template.md +15 -0
- package/template/workflows/specdev/P-goal-plan/references/map-control.md +28 -0
- package/template/workflows/specdev/{O-orchestrate-implementation/O-orchestrate-implementation.md → P-goal-plan/references/multi-change-plan.md} +21 -33
- package/template/workflows/specdev/P-goal-plan/references/replan-and-recovery.md +21 -0
- package/template/workflows/specdev/P-goal-plan/references/single-change-plan.md +149 -0
- package/template/workflows/specdev/R-review-architecture/R-review-architecture.md +48 -53
- package/template/workflows/specdev/R-review-architecture/architecture-review-template.md +19 -10
- package/template/workflows/specdev/R-review-architecture/proposal-to-ticket.md +3 -1
- package/template/workflows/specdev/R-review-architecture/review-rubric.md +52 -0
- package/template/workflows/specdev/README.md +36 -216
- package/template/workflows/specdev/T-tickets/T-tickets.md +19 -230
- package/template/workflows/specdev/T-tickets/references/planning-procedure.md +233 -0
- package/template/workflows/specdev/T-tickets/ticket-template.md +16 -0
- package/template/workflows/specdev/T-tickets/tickets-map-template.md +14 -0
- package/template/workflows/specdev/T-triage/T-triage.md +3 -1
- package/template/workflows/specdev/W-wayfinder/W-wayfinder.md +24 -118
- package/template/workflows/specdev/W-wayfinder/references/initiative-discovery.md +29 -0
- package/template/workflows/specdev/W-wayfinder/references/initiative-template.json +8 -0
- package/template/workflows/specdev/W-wayfinder/references/map-traversal.md +120 -0
- package/template/workflows/specdev/W-wayfinder/wayfinder-map-template.md +4 -0
- package/template/workflows/specdev/common/README.md +1 -1
- package/template/workflows/specdev/common/rules/activation-and-memory.md +7 -3
- package/template/workflows/specdev/common/rules/artifact-contract.md +10 -2
- package/template/workflows/specdev/common/rules/operating-governance.md +38 -0
- package/template/workflows/specdev/common/rules/parent-implementation-orchestration.md +6 -2
- package/template/workflows/specdev/common/rules/skill-invocation.md +27 -0
- package/template/workflows/specdev/common/rules/workflow-routing.md +24 -0
- package/template/workflows/specdev/common/rules/workflow-state-and-lifecycle.md +93 -0
- package/template/workflows/specdev/common/schemas/goal-tickets-map.schema.json +33 -0
- package/template/workflows/specdev/common/schemas/initiative.schema.json +94 -0
- package/template/workflows/specdev/common/schemas/ticket.schema.json +168 -1
- package/template/workflows/specdev/common/schemas/tickets-map.schema.json +74 -6
- package/template/workflows/specdev/common/skills/code-review/SKILL.md +3 -2
- package/template/workflows/specdev/common/skills/code-review/references/risk-review.md +25 -0
- package/template/workflows/specdev/common/skills/plan-quality-review/SKILL.md +10 -0
- package/template/workflows/specdev/common/skills/plan-quality-review/references/checklist.md +13 -0
- package/template/workflows/specdev/common/skills/subagent-delivery/SKILL.md +5 -83
- package/template/workflows/specdev/common/skills/subagent-delivery/references/dispatch-and-accept.md +87 -0
- package/template/workflows/specdev/common/tools/README.md +14 -2
- package/template/workflows/specdev/common/tools/plan-contract.mjs +256 -0
- package/template/workflows/specdev/common/tools/ticket-control.mjs +251 -0
- package/template/workflows/specdev/common/tools/validate-specdev.mjs +58 -40
- package/template/workflows/specdev/manifest.json +97 -1
- package/template/canonical/canonical-specdev-orchestrate-implementation.md +0 -2839
- package/template/workflows/specdev/O-orchestrate-implementation/implementation-evidence-template.md +0 -39
- package/template/workflows/specdev/O-orchestrate-implementation/implementation-map-template.md +0 -50
- package/template/workflows/specdev/O-orchestrate-implementation/implementation-plan-template.md +0 -61
- package/template/workflows/specdev/R-review-architecture/architecture-report-contract.md +0 -123
- package/template/workflows/specdev/R-review-architecture/architecture-review-report-template.html +0 -106
- /package/template/workflows/specdev/{O-orchestrate-implementation/conflict-and-drift.md → P-goal-plan/references/multi-conflict-and-drift.md} +0 -0
- /package/template/workflows/specdev/{O-orchestrate-implementation/execution-loop.md → P-goal-plan/references/multi-execution-loop.md} +0 -0
- /package/template/workflows/specdev/{O-orchestrate-implementation/input-readiness.md → P-goal-plan/references/multi-input-readiness.md} +0 -0
- /package/template/workflows/specdev/{O-orchestrate-implementation/super-dag.md → P-goal-plan/references/multi-super-dag.md} +0 -0
package/template/workflows/specdev/O-orchestrate-implementation/implementation-evidence-template.md
DELETED
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
# Implementation Orchestration Evidence
|
|
2
|
-
|
|
3
|
-
## 1. Parent Plan and Final Revision
|
|
4
|
-
|
|
5
|
-
- Parent change:
|
|
6
|
-
- Final Implementation Map revision:
|
|
7
|
-
- Workspace/integration strategy:
|
|
8
|
-
- Lead and epoch:
|
|
9
|
-
|
|
10
|
-
## 2. Member and Ticket Completion
|
|
11
|
-
|
|
12
|
-
| Change | Composite Tickets | Final status | Child Evidence | Final Git result |
|
|
13
|
-
|---|---|---|---|---|
|
|
14
|
-
|
|
15
|
-
## 3. Dependency and Serialization Audit
|
|
16
|
-
|
|
17
|
-
| Edge or pair | Required order/lock | Observed execution | Evidence |
|
|
18
|
-
|---|---|---|---|
|
|
19
|
-
|
|
20
|
-
## 4. Repository Integration Audit
|
|
21
|
-
|
|
22
|
-
| Repository/ref | Ordered results | Stale candidates | Final checkpoint | Evidence |
|
|
23
|
-
|---|---|---|---|---|
|
|
24
|
-
|
|
25
|
-
## 5. Aggregate Verification
|
|
26
|
-
|
|
27
|
-
| Command/check | Environment | Exit/result | Evidence |
|
|
28
|
-
|---|---|---|---|
|
|
29
|
-
|
|
30
|
-
## 6. Contract, Drift and Deviation Audit
|
|
31
|
-
|
|
32
|
-
- Cross-change contracts:
|
|
33
|
-
- Map/child drift disposition:
|
|
34
|
-
- Deviations/blockers:
|
|
35
|
-
|
|
36
|
-
## 7. Residual Risk and Boundary
|
|
37
|
-
|
|
38
|
-
- Residual risk:
|
|
39
|
-
- Not performed: archive, push, PR, remote merge, deploy, production migration unless separately authorized.
|
package/template/workflows/specdev/O-orchestrate-implementation/implementation-map-template.md
DELETED
|
@@ -1,50 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
schema_version: 1
|
|
3
|
-
artifact: implementation-map
|
|
4
|
-
change: <YYYY-MM-DD-parent-topic>
|
|
5
|
-
status: ready
|
|
6
|
-
revision: 1
|
|
7
|
-
members: [<child-change-a>, <child-change-b>]
|
|
8
|
-
tasks: [<child-change-a>::T-01, <child-change-b>::T-01]
|
|
9
|
-
dependencies: []
|
|
10
|
-
serializations: []
|
|
11
|
-
---
|
|
12
|
-
|
|
13
|
-
# Implementation Map: <Outcome>
|
|
14
|
-
|
|
15
|
-
## 1. Members and Source Authority
|
|
16
|
-
|
|
17
|
-
| Change | Spec | Tickets Map | Change status | Role |
|
|
18
|
-
|---|---|---|---|---|
|
|
19
|
-
| `<child-change-a>` | ready | ready | active | delivery |
|
|
20
|
-
| `<child-change-b>` | ready | ready | active | delivery |
|
|
21
|
-
|
|
22
|
-
## 2. Composite Ticket Inventory
|
|
23
|
-
|
|
24
|
-
| Composite ID | Child Ticket | Status | Ready | Writable/shared summary | Contracts |
|
|
25
|
-
|---|---|---|---|---|---|
|
|
26
|
-
| `<child-change-a>::T-01` | T-01 | ready | yes | pending | pending |
|
|
27
|
-
| `<child-change-b>::T-01` | T-01 | ready | yes | pending | pending |
|
|
28
|
-
|
|
29
|
-
## 3. Implementation Super-DAG
|
|
30
|
-
|
|
31
|
-
| Edge | Kind | Source and reason | Start Gate | Evidence |
|
|
32
|
-
|---|---|---|---|---|
|
|
33
|
-
| none | none | independent until proven otherwise | n/a | n/a |
|
|
34
|
-
|
|
35
|
-
## 4. Conflict and Serialization
|
|
36
|
-
|
|
37
|
-
| Pair | Resource or overlap | Owner | Release condition |
|
|
38
|
-
|---|---|---|---|
|
|
39
|
-
| none | none observed | n/a | n/a |
|
|
40
|
-
|
|
41
|
-
## 5. Contract and Path Coverage
|
|
42
|
-
|
|
43
|
-
| Contract/shared surface | Producer task | Consumer tasks | Ordering/lock | Verification |
|
|
44
|
-
|---|---|---|---|---|
|
|
45
|
-
|
|
46
|
-
## 6. Revision Log
|
|
47
|
-
|
|
48
|
-
| Revision | Source change | Affected tasks/edges | Reason |
|
|
49
|
-
|---|---|---|---|
|
|
50
|
-
| 1 | initial Ready inputs | all | parent creation |
|
package/template/workflows/specdev/O-orchestrate-implementation/implementation-plan-template.md
DELETED
|
@@ -1,61 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
schema_version: 1
|
|
3
|
-
artifact: implementation-plan
|
|
4
|
-
change: <YYYY-MM-DD-parent-topic>
|
|
5
|
-
status: ready
|
|
6
|
-
source_map_revision: 1
|
|
7
|
-
orchestration: lead-directed
|
|
8
|
-
lead: <owner-or-session-locator>
|
|
9
|
-
implementation_agent_limit: 3
|
|
10
|
-
integration_attempt_limit: 3
|
|
11
|
-
ticket_workspace_policy: current
|
|
12
|
-
integration_gate: direct-parent
|
|
13
|
-
ready_for_execution: true
|
|
14
|
-
---
|
|
15
|
-
|
|
16
|
-
# Implementation Plan: <Outcome>
|
|
17
|
-
|
|
18
|
-
## 1. Outcome and Authority
|
|
19
|
-
|
|
20
|
-
- Outcome: <aggregate implementation outcome>
|
|
21
|
-
- Lead: <recoverable owner/session locator>
|
|
22
|
-
- False completion: <what must not be called done>
|
|
23
|
-
- Authority: child Spec/Tickets for behavior and implementation; parent Map/Plan for cross-change execution only.
|
|
24
|
-
|
|
25
|
-
## 2. Ready Frontier and Waves
|
|
26
|
-
|
|
27
|
-
| Wave | Composite tasks | Dependency Gate | Serialization/resource Gate | Status |
|
|
28
|
-
|---|---|---|---|---|
|
|
29
|
-
| 1 | pending | dependencies satisfied | locks available | ready |
|
|
30
|
-
|
|
31
|
-
## 3. Workspace and Dispatch Contract
|
|
32
|
-
|
|
33
|
-
- Ticket workspace policy: current / required.
|
|
34
|
-
- Dispatch IDs use `<member-change>::<ticket-id>`.
|
|
35
|
-
- The implementation agent limit is global across all members; the Lead is not counted.
|
|
36
|
-
- Read-only review/research/test-observation agents do not consume the implementation limit.
|
|
37
|
-
|
|
38
|
-
## 4. Repository Integration Queue
|
|
39
|
-
|
|
40
|
-
| Repository/ref | Ordered composite tasks | Current parent checkpoint | Active candidate | Owner |
|
|
41
|
-
|---|---|---|---|---|
|
|
42
|
-
| current repository/current ref | pending | pending-read | none | Lead |
|
|
43
|
-
|
|
44
|
-
## 5. Gates and Aggregate Verification
|
|
45
|
-
|
|
46
|
-
| Gate | Required tasks | Verification | Evidence | Status |
|
|
47
|
-
|---|---|---|---|---|
|
|
48
|
-
| child completion | all child Tickets | child completion contract | child Evidence | pending |
|
|
49
|
-
| aggregate | all members completed | full suite and applicable E2E | parent Evidence | pending |
|
|
50
|
-
|
|
51
|
-
## 6. Conflict, Drift and Recovery
|
|
52
|
-
|
|
53
|
-
- Re-read Map revision, Lead epoch, child Tickets, Git HEAD, active dispatches and locks before every action.
|
|
54
|
-
- Any parent advance makes older candidates stale and requires reconstruction.
|
|
55
|
-
- On pause, persist last accepted task, stale candidates, blockers, next legal task and required reads.
|
|
56
|
-
|
|
57
|
-
## 7. Progress and Decisions
|
|
58
|
-
|
|
59
|
-
| Time | Composite task | Dispatch/result | Child Evidence | Parent checkpoint | Next recomputation |
|
|
60
|
-
|---|---|---|---|---|---|
|
|
61
|
-
| pending | none | not started | none | pending-read | compute frontier |
|
|
@@ -1,123 +0,0 @@
|
|
|
1
|
-
# HTML 报告格式
|
|
2
|
-
|
|
3
|
-
架构审查渲染为一个独立的 HTML 文件,存放在操作系统临时目录中。Tailwind 和 Mermaid 均来自 CDN。Mermaid 处理图形状的图表;手工构建的 div 和内联 SVG 处理更具编辑性的可视化(质量图、横截面图)。混合使用两者 — 不要所有事情都依赖 Mermaid,否则会变得千篇一律。
|
|
4
|
-
|
|
5
|
-
## 脚手架
|
|
6
|
-
|
|
7
|
-
```html
|
|
8
|
-
<!doctype html>
|
|
9
|
-
<html lang="en">
|
|
10
|
-
<head>
|
|
11
|
-
<meta charset="utf-8" />
|
|
12
|
-
<title>Architecture review — {{repo name}}</title>
|
|
13
|
-
<script src="https://cdn.tailwindcss.com"></script>
|
|
14
|
-
<script type="module">
|
|
15
|
-
import mermaid from "https://cdn.jsdelivr.net/npm/mermaid@11/dist/mermaid.esm.min.mjs";
|
|
16
|
-
mermaid.initialize({ startOnLoad: true, theme: "neutral", securityLevel: "loose" });
|
|
17
|
-
</script>
|
|
18
|
-
<style>
|
|
19
|
-
/* Tailwind 无法很好覆盖的小型自定义层:
|
|
20
|
-
虚线接缝线、手绘感箭头等。 */
|
|
21
|
-
.seam { stroke-dasharray: 4 4; }
|
|
22
|
-
.leak { stroke: #dc2626; }
|
|
23
|
-
.deep { background: linear-gradient(135deg, #0f172a, #1e293b); }
|
|
24
|
-
</style>
|
|
25
|
-
</head>
|
|
26
|
-
<body class="bg-stone-50 text-slate-900 font-sans">
|
|
27
|
-
<main class="max-w-5xl mx-auto px-6 py-12 space-y-12">
|
|
28
|
-
<header>...</header>
|
|
29
|
-
<section id="candidates" class="space-y-10">...</section>
|
|
30
|
-
<section id="top-recommendation">...</section>
|
|
31
|
-
</main>
|
|
32
|
-
</body>
|
|
33
|
-
</html>
|
|
34
|
-
```
|
|
35
|
-
|
|
36
|
-
## 页头
|
|
37
|
-
|
|
38
|
-
仓库名称、日期和一个紧凑的图例:实线框 = 模块,虚线 = 接缝,红色箭头 = 泄漏,粗黑框 = 深模块。无介绍段落 — 直接进入候选。
|
|
39
|
-
|
|
40
|
-
## 候选卡片
|
|
41
|
-
|
|
42
|
-
图表承担主要分量。文字稀疏、平实,并使用来自 `<Path>{roots.workflows}/specdev/common/rules/codebase-design.md</Path>` 的术语,不刻意修饰。
|
|
43
|
-
|
|
44
|
-
每个候选是一个 `<article>`:
|
|
45
|
-
|
|
46
|
-
- **标题** — 简短,命名深化方案(例如"Collapse the Order intake pipeline")。
|
|
47
|
-
- **徽章行** — 推荐强度(`Strong` = 翡翠绿,`Worth exploring` = 琥珀色,`Speculative` = 石板灰),外加一个依赖类别标签(`in-process`、`local-substitutable`、`ports & adapters`、`mock`)。
|
|
48
|
-
- **文件** — 等宽字体列表,`font-mono text-sm`。
|
|
49
|
-
- **Before / After 图表** — 核心。两列,并排。参见下方模式。
|
|
50
|
-
- **Problem** — 一句话。痛点是什么。
|
|
51
|
-
- **Solution** — 一句话。改变了什么。
|
|
52
|
-
- **Wins** — 要点,每个不超过 6 个词。例如 "Tests hit one interface"、"Pricing logic stops leaking"、"Delete 4 shallow wrappers"。
|
|
53
|
-
- **ADR 标注**(如适用)— 一行,放在琥珀色调的框中。
|
|
54
|
-
|
|
55
|
-
无需解释段落。如果图表需要一段文字才能理解,重新画图。
|
|
56
|
-
|
|
57
|
-
## 图表模式
|
|
58
|
-
|
|
59
|
-
选择适合候选的模式。混合使用它们。不要让每个图表看起来都一样 — 多样性本身就是目的的一部分。
|
|
60
|
-
|
|
61
|
-
### Mermaid 图表(依赖/调用流的常用工具)
|
|
62
|
-
|
|
63
|
-
当重点是"X 调用 Y 调用 Z,看看这有多混乱"时,使用 Mermaid `flowchart` 或 `graph`。用 Tailwind 风格卡片包裹它,这样不会显得突兀。使用 classDef 将泄漏边缘着红色,深模块着深色。序列图适合展示"before:6 个往返;after:1 个"。
|
|
64
|
-
|
|
65
|
-
```html
|
|
66
|
-
<div class="rounded-lg border border-slate-200 bg-white p-4">
|
|
67
|
-
<pre class="mermaid">
|
|
68
|
-
flowchart LR
|
|
69
|
-
A[OrderHandler] --> B[OrderValidator]
|
|
70
|
-
B --> C[OrderRepo]
|
|
71
|
-
C -.leak.-> D[PricingClient]
|
|
72
|
-
classDef leak stroke:#dc2626,stroke-width:2px;
|
|
73
|
-
class C,D leak
|
|
74
|
-
</pre>
|
|
75
|
-
</div>
|
|
76
|
-
```
|
|
77
|
-
|
|
78
|
-
### 手工绘制的框线图(当 Mermaid 的布局难以驾驭时)
|
|
79
|
-
|
|
80
|
-
模块用带边框和标签的 `<div>` 表示。箭头用绝对定位在相对容器上的内联 SVG `<line>` 或 `<path>` 元素表示。当你希望"after"图表看起来像一个粗边的深模块,内部元素灰显时使用 — Mermaid 不会以合适的权重渲染这种效果。
|
|
81
|
-
|
|
82
|
-
### 横截面图(适合分层浅度)
|
|
83
|
-
|
|
84
|
-
堆叠水平条(`h-12 border-l-4`)来展示调用经过的各层。Before:6 个薄层,每个都不做什么。After:一个厚条,标注合并后的职责。
|
|
85
|
-
|
|
86
|
-
### 质量图(适合"接口与实现一样宽"的场景)
|
|
87
|
-
|
|
88
|
-
每个模块两个矩形 — 一个表示接口表面积,一个表示实现。Before:接口矩形几乎和实现矩形一样高(浅)。After:接口矩形短,实现矩形高(深)。
|
|
89
|
-
|
|
90
|
-
### 调用图坍缩
|
|
91
|
-
|
|
92
|
-
Before:嵌套框呈现的函数调用树。After:同一棵树坍缩成一个框,内部调用在其内部以淡化形式显示。
|
|
93
|
-
|
|
94
|
-
## 样式指导
|
|
95
|
-
|
|
96
|
-
- 偏向编辑风格,而非企业仪表盘风格。宽松的留白。标题可选择衬线字体(`font-serif` 与 stone/slate 搭配效果很好)。
|
|
97
|
-
- 色彩使用克制:一种强调色(翠绿或靛蓝),加上红色用于泄漏,琥珀色用于警告。
|
|
98
|
-
- 保持图表约 320px 高,使 before/after 能够舒适地并排放置而无需滚动。
|
|
99
|
-
- 使用 `text-xs uppercase tracking-wider` 用于图表内的模块标签 — 它们应读起来像示意图,而非 UI。
|
|
100
|
-
- 唯一的脚本是 Tailwind CDN 和 Mermaid ESM 导入。除此之外报告是静态的 — 没有应用代码,除了 Mermaid 自身的渲染之外没有交互。
|
|
101
|
-
|
|
102
|
-
## 顶部推荐部分
|
|
103
|
-
|
|
104
|
-
一张更大的卡片。候选名称,一句话说明为什么,指向其卡片的锚链接。这就够了。
|
|
105
|
-
|
|
106
|
-
## 语气
|
|
107
|
-
|
|
108
|
-
平实的英语,简洁 — 但架构名词和动词直接来自 `<Path>{roots.workflows}/specdev/common/rules/codebase-design.md</Path>`。简洁不是偏离的借口。
|
|
109
|
-
|
|
110
|
-
**完全使用:** module、interface、implementation、depth、deep、shallow、seam、adapter、leverage、locality。
|
|
111
|
-
|
|
112
|
-
**绝不替代:** component、service、unit(代替 module)· API、signature(代替 interface)· boundary(代替 seam)· layer、wrapper(代替 module,当你的意思是 module 时)。
|
|
113
|
-
|
|
114
|
-
**符合风格的表达方式:**
|
|
115
|
-
|
|
116
|
-
- "Order intake module is shallow — interface nearly matches the implementation."
|
|
117
|
-
- "Pricing leaks across the seam."
|
|
118
|
-
- "Deepen: one interface, one place to test."
|
|
119
|
-
- "Two adapters justify the seam: HTTP in prod, in-memory in tests."
|
|
120
|
-
|
|
121
|
-
**Wins 要点**用术语表命名收益:*"locality: bugs concentrate in one module"*、*"leverage: one interface, N call sites"*、*"interface shrinks; implementation absorbs the wrappers"*。不要写 *"easier to maintain"* 或 *"cleaner code"* — 这些术语不在术语表中,不值得留下。
|
|
122
|
-
|
|
123
|
-
不模糊其词,不清喉咙,不说"值得注意的是……"。如果一句话可以变成一个要点,就变成要点。如果一个要点可以删除,就删除它。如果一个术语不在 `<Path>{roots.workflows}/specdev/common/rules/codebase-design.md</Path>` 中,在发明新术语之前先用术语表中已有的。
|
package/template/workflows/specdev/R-review-architecture/architecture-review-report-template.html
DELETED
|
@@ -1,106 +0,0 @@
|
|
|
1
|
-
<!doctype html>
|
|
2
|
-
<html lang="zh-CN">
|
|
3
|
-
<head>
|
|
4
|
-
<meta charset="utf-8">
|
|
5
|
-
<meta name="viewport" content="width=device-width, initial-scale=1">
|
|
6
|
-
<title>Architecture review - {{repo name}}</title>
|
|
7
|
-
<script src="https://cdn.tailwindcss.com"></script>
|
|
8
|
-
<script type="module">
|
|
9
|
-
import mermaid from "https://cdn.jsdelivr.net/npm/mermaid@11/dist/mermaid.esm.min.mjs";
|
|
10
|
-
mermaid.initialize({ startOnLoad: true, theme: "neutral", securityLevel: "loose" });
|
|
11
|
-
</script>
|
|
12
|
-
<style>
|
|
13
|
-
* { letter-spacing: 0 !important; }
|
|
14
|
-
.seam { stroke-dasharray: 4 4; }
|
|
15
|
-
.leak { stroke: #dc2626; }
|
|
16
|
-
.module-label { font-size: 0.72rem; text-transform: uppercase; }
|
|
17
|
-
.quality-bar { min-height: 2.75rem; }
|
|
18
|
-
code { overflow-wrap: anywhere; }
|
|
19
|
-
</style>
|
|
20
|
-
</head>
|
|
21
|
-
<body class="bg-stone-50 text-slate-900 font-sans">
|
|
22
|
-
<main class="mx-auto max-w-5xl space-y-12 px-4 py-10 sm:px-6 sm:py-12">
|
|
23
|
-
<header class="space-y-4 border-b border-slate-300 pb-6">
|
|
24
|
-
<div class="flex flex-col gap-2 sm:flex-row sm:items-end sm:justify-between">
|
|
25
|
-
<div>
|
|
26
|
-
<p class="text-sm font-semibold text-emerald-700">{{repo name}} / {{date}}</p>
|
|
27
|
-
<h1 class="mt-1 font-serif text-3xl font-semibold sm:text-4xl">Architecture review</h1>
|
|
28
|
-
</div>
|
|
29
|
-
<p class="text-sm text-slate-600">{{review scope}}</p>
|
|
30
|
-
</div>
|
|
31
|
-
<div class="flex flex-wrap gap-x-5 gap-y-2 text-xs text-slate-600" aria-label="图例">
|
|
32
|
-
<span><span class="mr-1 inline-block h-3 w-5 border border-slate-700 align-middle"></span>module</span>
|
|
33
|
-
<span><span class="mr-1 inline-block h-3 w-5 border border-dashed border-slate-700 align-middle"></span>seam</span>
|
|
34
|
-
<span><span class="mr-1 inline-block h-0 w-5 border-t-2 border-red-600 align-middle"></span>leak</span>
|
|
35
|
-
<span><span class="mr-1 inline-block h-3 w-5 border-4 border-slate-900 align-middle"></span>deep module</span>
|
|
36
|
-
</div>
|
|
37
|
-
<p class="text-xs text-slate-500">
|
|
38
|
-
Decision record: <code><Path>{roots.state}/specdev/changes/{change}/architecture-review.md</Path></code>
|
|
39
|
-
</p>
|
|
40
|
-
</header>
|
|
41
|
-
|
|
42
|
-
<section id="candidates" class="space-y-10">
|
|
43
|
-
<article id="ar-001" class="rounded-lg border border-slate-300 bg-white p-5 shadow-sm sm:p-7">
|
|
44
|
-
<div class="flex flex-col gap-3 sm:flex-row sm:items-start sm:justify-between">
|
|
45
|
-
<div>
|
|
46
|
-
<p class="text-sm font-semibold text-emerald-700">AR-001</p>
|
|
47
|
-
<h2 class="mt-1 font-serif text-2xl font-semibold">Collapse the Order intake pipeline</h2>
|
|
48
|
-
</div>
|
|
49
|
-
<div class="flex flex-wrap gap-2 text-xs font-semibold">
|
|
50
|
-
<span class="rounded border border-emerald-700 bg-emerald-50 px-2 py-1 text-emerald-800">Strong</span>
|
|
51
|
-
<span class="rounded border border-slate-400 bg-slate-50 px-2 py-1 text-slate-700">in-process</span>
|
|
52
|
-
</div>
|
|
53
|
-
</div>
|
|
54
|
-
|
|
55
|
-
<div class="mt-5 border-y border-slate-200 py-3">
|
|
56
|
-
<p class="text-xs font-semibold uppercase text-slate-500">Files</p>
|
|
57
|
-
<p class="mt-1 font-mono text-sm">src/order/handler.ts · src/order/validator.ts · test/order.test.ts</p>
|
|
58
|
-
</div>
|
|
59
|
-
|
|
60
|
-
<div class="mt-6 grid gap-6 lg:grid-cols-2">
|
|
61
|
-
<section aria-labelledby="before-title">
|
|
62
|
-
<h3 id="before-title" class="text-sm font-semibold">Before</h3>
|
|
63
|
-
<div class="mt-2 min-h-80 rounded-lg border border-slate-200 bg-stone-50 p-4">
|
|
64
|
-
<pre class="mermaid">
|
|
65
|
-
flowchart LR
|
|
66
|
-
A[OrderHandler] --> B[OrderValidator]
|
|
67
|
-
B --> C[OrderRepo]
|
|
68
|
-
C -. leak .-> D[PricingClient]
|
|
69
|
-
classDef leaking stroke:#dc2626,stroke-width:2px
|
|
70
|
-
class C,D leaking
|
|
71
|
-
</pre>
|
|
72
|
-
</div>
|
|
73
|
-
</section>
|
|
74
|
-
<section aria-labelledby="after-title">
|
|
75
|
-
<h3 id="after-title" class="text-sm font-semibold">After</h3>
|
|
76
|
-
<div class="mt-2 flex min-h-80 flex-col justify-center rounded-lg border-4 border-slate-900 bg-white p-5">
|
|
77
|
-
<p class="module-label font-semibold text-slate-500">Interface</p>
|
|
78
|
-
<div class="quality-bar mt-2 flex items-center rounded border border-emerald-700 bg-emerald-50 px-4 text-sm font-semibold text-emerald-900">one narrow interface</div>
|
|
79
|
-
<p class="module-label mt-6 font-semibold text-slate-500">Hidden implementation</p>
|
|
80
|
-
<div class="mt-2 space-y-2 text-sm text-slate-500">
|
|
81
|
-
<div class="rounded border border-slate-200 bg-slate-50 p-3">validation</div>
|
|
82
|
-
<div class="rounded border border-slate-200 bg-slate-50 p-3">pricing protocol</div>
|
|
83
|
-
<div class="rounded border border-slate-200 bg-slate-50 p-3">persistence</div>
|
|
84
|
-
</div>
|
|
85
|
-
</div>
|
|
86
|
-
</section>
|
|
87
|
-
</div>
|
|
88
|
-
|
|
89
|
-
<dl class="mt-6 grid gap-5 border-t border-slate-200 pt-5 sm:grid-cols-3">
|
|
90
|
-
<div><dt class="text-xs font-semibold uppercase text-slate-500">Problem</dt><dd class="mt-1 text-sm">Callers coordinate three shallow modules and absorb the failure order.</dd></div>
|
|
91
|
-
<div><dt class="text-xs font-semibold uppercase text-slate-500">Solution</dt><dd class="mt-1 text-sm">Move the intake policy behind one deep module.</dd></div>
|
|
92
|
-
<div><dt class="text-xs font-semibold uppercase text-slate-500">Wins</dt><dd class="mt-1 text-sm">One test surface · Local failure policy · Fewer leaking seams</dd></div>
|
|
93
|
-
</dl>
|
|
94
|
-
|
|
95
|
-
<p class="mt-5 rounded border border-amber-500 bg-amber-50 px-4 py-3 text-sm text-amber-950">ADR note: {{none or conflict explanation}}</p>
|
|
96
|
-
</article>
|
|
97
|
-
</section>
|
|
98
|
-
|
|
99
|
-
<section id="top-recommendation" class="border-t-4 border-emerald-700 pt-6">
|
|
100
|
-
<p class="text-sm font-semibold text-emerald-700">Best recommendation</p>
|
|
101
|
-
<h2 class="mt-1 font-serif text-2xl font-semibold"><a class="underline decoration-emerald-600 decoration-2 underline-offset-4" href="#ar-001">Collapse the Order intake pipeline</a></h2>
|
|
102
|
-
<p class="mt-2 max-w-3xl text-slate-700">It removes the hottest coordination seam while preserving the domain language and existing behavior.</p>
|
|
103
|
-
</section>
|
|
104
|
-
</main>
|
|
105
|
-
</body>
|
|
106
|
-
</html>
|
|
File without changes
|
|
File without changes
|
|
File without changes
|