viepilot 1.9.11 → 2.1.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.
Files changed (60) hide show
  1. package/CHANGELOG.md +175 -2
  2. package/README.md +3 -3
  3. package/bin/viepilot.cjs +7 -5
  4. package/bin/vp-tools.cjs +193 -0
  5. package/dev-install.sh +34 -13
  6. package/docs/user/features/architect-design-mode.md +170 -0
  7. package/docs/user/features/hooks.md +93 -0
  8. package/docs/user/features/ui-direction.md +79 -3
  9. package/lib/adapters/claude-code.cjs +42 -0
  10. package/lib/adapters/cursor.cjs +31 -0
  11. package/lib/adapters/index.cjs +26 -0
  12. package/lib/hooks/brainstorm-staleness.cjs +231 -0
  13. package/lib/viepilot-config.cjs +103 -0
  14. package/lib/viepilot-install.cjs +128 -153
  15. package/package.json +1 -1
  16. package/skills/vp-audit/SKILL.md +21 -21
  17. package/skills/vp-auto/SKILL.md +21 -7
  18. package/skills/vp-brainstorm/SKILL.md +46 -35
  19. package/skills/vp-crystallize/SKILL.md +37 -25
  20. package/skills/vp-debug/SKILL.md +2 -2
  21. package/skills/vp-docs/SKILL.md +7 -7
  22. package/skills/vp-evolve/SKILL.md +25 -12
  23. package/skills/vp-info/SKILL.md +23 -23
  24. package/skills/vp-pause/SKILL.md +5 -5
  25. package/skills/vp-request/SKILL.md +12 -12
  26. package/skills/vp-resume/SKILL.md +4 -4
  27. package/skills/vp-rollback/SKILL.md +3 -3
  28. package/skills/vp-status/SKILL.md +4 -4
  29. package/skills/vp-task/SKILL.md +3 -3
  30. package/skills/vp-ui-components/SKILL.md +12 -12
  31. package/skills/vp-update/SKILL.md +17 -17
  32. package/templates/architect/apis.html +159 -0
  33. package/templates/architect/architect-actions.js +217 -0
  34. package/templates/architect/architecture.html +160 -0
  35. package/templates/architect/data-flow.html +109 -0
  36. package/templates/architect/decisions.html +96 -0
  37. package/templates/architect/deployment.html +184 -0
  38. package/templates/architect/erd.html +154 -0
  39. package/templates/architect/feature-map.html +113 -0
  40. package/templates/architect/index.html +108 -0
  41. package/templates/architect/sequence-diagram.html +133 -0
  42. package/templates/architect/style.css +365 -0
  43. package/templates/architect/tech-notes.html +89 -0
  44. package/templates/architect/tech-stack.html +114 -0
  45. package/templates/architect/user-use-cases.html +154 -0
  46. package/templates/project/AI-GUIDE.md +53 -54
  47. package/templates/project/PROJECT-CONTEXT.md +7 -11
  48. package/templates/project/README.md +43 -0
  49. package/templates/project/ROADMAP.md +1 -27
  50. package/workflows/audit.md +3 -3
  51. package/workflows/autonomous.md +38 -5
  52. package/workflows/brainstorm.md +575 -191
  53. package/workflows/crystallize.md +168 -58
  54. package/workflows/debug.md +9 -9
  55. package/workflows/documentation.md +5 -5
  56. package/workflows/evolve.md +44 -12
  57. package/workflows/pause-work.md +2 -2
  58. package/workflows/request.md +8 -8
  59. package/workflows/resume-work.md +1 -1
  60. package/workflows/rollback.md +1 -1
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: vp-request
3
- description: "Tạo request mới: feature, bug fix, enhancement, hoặc brainstorm tiếp"
3
+ description: "Create new request: feature, bug fix, enhancement, or brainstorm continuation"
4
4
  version: 0.2.0
5
5
  ---
6
6
 
@@ -10,7 +10,7 @@ version: 0.2.0
10
10
  - Treat all user text after the skill mention as `{{VP_ARGS}}`
11
11
 
12
12
  ## B. User Prompting
13
- Prompt user conversationally với numbered list options.
13
+ Prompt user conversationally with numbered list options.
14
14
 
15
15
  ## C. Tool Usage
16
16
  Use Cursor tools: `Shell`, `ReadFile`, `Glob`, `rg`, `ApplyPatch`, `WebSearch`, `WebFetch`, `Subagent`
@@ -25,27 +25,27 @@ Use Cursor tools: `Shell`, `ReadFile`, `Glob`, `rg`, `ApplyPatch`, `WebSearch`,
25
25
  <implementation_routing_guard>
26
26
  ## Implementation routing guard (ENH-021)
27
27
 
28
- - Skill này chỉ **tạo request**, **backlog**, **triage** (`.viepilot/requests/*`, `TRACKER`, đôi khi gợi ý ROADMAP) — **không** implement shipping mặc định (`lib/`, `tests/`, `bin/`, `workflows/`, `skills/` của repo, v.v.).
29
- - **Sau request:** **`/vp-evolve`** (ROADMAP + phase + tasks + plan) → **`/vp-auto`** (thực thi). Xem `workflows/request.md`.
30
- - **Ngoại lệ:** User **explicit** (*hotfix ngay*, *sửa trong chat này*, *bypass planning*) — phải **nêu rõ** bypass trong chat.
31
- - **Không** đề xuất *“Start working now”* như implement trực tiếp trong thread này; thay bằng evolve → auto.
28
+ - This skill only **creates requests**, **backlog**, **triage** (`.viepilot/requests/*`, `TRACKER`, sometimes suggests ROADMAP) — does **not** implement default shipping code (`lib/`, `tests/`, `bin/`, `workflows/`, `skills/` of the repo, etc.).
29
+ - **After request:** **`/vp-evolve`** (ROADMAP + phase + tasks + plan) → **`/vp-auto`** (execute). See `workflows/request.md`.
30
+ - **Exception:** User **explicit** (*hotfix now*, *fix in this chat*, *bypass planning*) — must **state clearly** the bypass in chat.
31
+ - **Do not** suggest *”Start working now”* as direct implementation in this thread; use evolve → auto instead.
32
32
  </implementation_routing_guard>
33
33
 
34
34
 
35
35
  <objective>
36
- Tạo quản requests cho dự án đang phát triển:
37
- - Bug report fix
36
+ Create and manage requests for the project under development:
37
+ - Bug report and fix
38
38
  - Feature request
39
39
  - Enhancement/Improvement
40
40
  - Technical debt
41
- - Brainstorm tiếp cho ý tưởng mới
41
+ - Brainstorm continuation for new ideas
42
42
 
43
43
  **Creates/Updates:**
44
44
  - `.viepilot/requests/{TYPE}-{NUMBER}.md`
45
- - `.viepilot/TRACKER.md` (thêm vào backlog)
46
- - `.viepilot/ROADMAP.md` (nếu approved)
45
+ - `.viepilot/TRACKER.md` (add to backlog)
46
+ - `.viepilot/ROADMAP.md` (if approved)
47
47
 
48
- **Routes to:** `/vp-auto` hoặc `/vp-evolve` tùy loại request
48
+ **Routes to:** `/vp-auto` or `/vp-evolve` depending on request type
49
49
  </objective>
50
50
 
51
51
  <execution_context>
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: vp-resume
3
- description: "Resume work từ previous session với full context restoration"
3
+ description: "Resume work from previous session with full context restoration"
4
4
  version: 0.1.1
5
5
  ---
6
6
 
@@ -10,7 +10,7 @@ version: 0.1.1
10
10
  - Treat all user text after the skill mention as `{{VP_ARGS}}`
11
11
 
12
12
  ## B. User Prompting
13
- Prompt user conversationally với options.
13
+ Prompt user conversationally with options.
14
14
 
15
15
  ## C. Tool Usage
16
16
  Use Cursor tools: `Shell`, `ReadFile`, `Glob`, `rg`, `ApplyPatch`, `WebSearch`, `WebFetch`, `Subagent`
@@ -25,12 +25,12 @@ Use Cursor tools: `Shell`, `ReadFile`, `Glob`, `rg`, `ApplyPatch`, `WebSearch`,
25
25
  <implementation_routing_guard>
26
26
  ## Implementation routing guard (ENH-021)
27
27
 
28
- - **Khôi phục context** — không implement shipping mặc định; tiếp tục **`/vp-auto`** khi task plan. Xem `workflows/request.md`.
28
+ - **Restore context** — does not implement default shipping; continue with **`/vp-auto`** when a task plan exists. See `workflows/request.md`.
29
29
  </implementation_routing_guard>
30
30
 
31
31
 
32
32
  <objective>
33
- Restore complete project context resume work seamlessly.
33
+ Restore complete project context and resume work seamlessly.
34
34
 
35
35
  **Reads:**
36
36
  - `.viepilot/HANDOFF.json`
@@ -25,14 +25,14 @@ Use Cursor tools: `Shell`, `ReadFile`, `Glob`, `rg`, `ApplyPatch`, `WebSearch`,
25
25
  <implementation_routing_guard>
26
26
  ## Implementation routing guard (ENH-021)
27
27
 
28
- - **Checkpoint / revert** — không thay **`/vp-auto`** cho work mới; sau rollback dùng **`/vp-evolve`** / **`/vp-auto`** theo quy trình. Xem `workflows/request.md`.
28
+ - **Checkpoint / revert** — does not replace **`/vp-auto`** for new work; after rollback use **`/vp-evolve`** / **`/vp-auto`** per workflow. See `workflows/request.md`.
29
29
  </implementation_routing_guard>
30
30
 
31
31
 
32
32
  <objective>
33
- Rollback đến bất kỳ checkpoint nào một cách an toàn, với backup state preservation.
33
+ Rollback to any checkpoint safely, with backup and state preservation.
34
34
 
35
- **Checkpoints:** Git tags với prefix `vp-`
35
+ **Checkpoints:** Git tags with prefix `vp-`
36
36
  - `vp-p{N}-t{M}` - Start of task M in phase N
37
37
  - `vp-p{N}-t{M}-done` - Task M complete
38
38
  - `vp-p{N}-complete` - Phase N complete
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: vp-status
3
- description: "Hiển thị progress dashboard actionable insights"
3
+ description: "Display progress dashboard and actionable insights"
4
4
  version: 0.1.1
5
5
  ---
6
6
 
@@ -22,12 +22,12 @@ Use Cursor tools: `Shell`, `ReadFile`, `Glob`, `rg`, `ApplyPatch`, `WebSearch`,
22
22
  <implementation_routing_guard>
23
23
  ## Implementation routing guard (ENH-021)
24
24
 
25
- - **Read-only / dashboard** — không implement shipping; **`/vp-evolve`** → **`/vp-auto`**. Xem `workflows/request.md`.
25
+ - **Read-only / dashboard** — does not implement shipping; **`/vp-evolve`** → **`/vp-auto`**. See `workflows/request.md`.
26
26
  </implementation_routing_guard>
27
27
 
28
28
 
29
29
  <objective>
30
- Hiển thị visual progress dashboard với actionable insights.
30
+ Display a visual progress dashboard with actionable insights.
31
31
 
32
32
  **Reads:**
33
33
  - `.viepilot/TRACKER.md`
@@ -35,7 +35,7 @@ Hiển thị visual progress dashboard với actionable insights.
35
35
  - `.viepilot/phases/*/PHASE-STATE.md`
36
36
  - `CHANGELOG.md`
37
37
 
38
- **Output:** Dashboard display với next action suggestions.
38
+ **Output:** Dashboard display with next action suggestions.
39
39
  </objective>
40
40
 
41
41
  <process>
@@ -22,12 +22,12 @@ Use Cursor tools: `Shell`, `ReadFile`, `Glob`, `rg`, `ApplyPatch`, `WebSearch`,
22
22
  <implementation_routing_guard>
23
23
  ## Implementation routing guard (ENH-021)
24
24
 
25
- - Skill này **chỉ** quản **state/tag/task** trong `.viepilot/` — **không** thay **`/vp-auto`** để implement shipping code. Implement: **`/vp-auto`** hoặc user **explicit** override. Chuỗi plan: **`/vp-evolve`** trước. Xem `workflows/request.md`.
25
+ - This skill **only** manages **state/tag/task** in `.viepilot/` — does **not** replace **`/vp-auto`** for implementing shipping code. To implement: use **`/vp-auto`** or user **explicit** override. Plan chain: **`/vp-evolve`** first. See `workflows/request.md`.
26
26
  </implementation_routing_guard>
27
27
 
28
28
 
29
29
  <objective>
30
- Manual control over tasks khi cần fine-grained management.
30
+ Manual control over tasks when fine-grained management is needed.
31
31
 
32
32
  **Commands:**
33
33
  - `list` - List tasks in current phase
@@ -50,7 +50,7 @@ Commands:
50
50
  - /vp-task show 3
51
51
  - /vp-task start 3
52
52
  - /vp-task done 3
53
- - /vp-task skip 3 --reason "Not needed for MVP"
53
+ - /vp-task skip 3 --reason "Not needed for Phase 1"
54
54
  - /vp-task retry 3
55
55
  - /vp-task rollback 3
56
56
  ```
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: vp-ui-components
3
- description: "Quản workflow sưu tầm tái sử dụng UI components"
3
+ description: "Manage workflow for collecting and reusing UI components"
4
4
  version: 0.1.1
5
5
  ---
6
6
 
@@ -10,7 +10,7 @@ version: 0.1.1
10
10
  - Treat all user text after the skill mention as `{{VP_ARGS}}`
11
11
 
12
12
  ## B. User Prompting
13
- Prompt user conversationally với numbered list options.
13
+ Prompt user conversationally with numbered list options.
14
14
 
15
15
  ## C. Tool Usage
16
16
  Use Cursor tools: `Shell`, `ReadFile`, `Glob`, `rg`, `ApplyPatch`, `WebSearch`, `WebFetch`, `Subagent`
@@ -25,23 +25,23 @@ Use Cursor tools: `Shell`, `ReadFile`, `Glob`, `rg`, `ApplyPatch`, `WebSearch`,
25
25
  <implementation_routing_guard>
26
26
  ## Implementation routing guard (ENH-021)
27
27
 
28
- - **Curation** `ui-components/` + metadata — không implement toàn bộ feature app / framework shipping mặc định; thay đổi lớn **`/vp-evolve`** → **`/vp-auto`**. Xem `workflows/request.md`.
28
+ - **Curation** `ui-components/` + metadata — does not implement full app feature / default framework shipping; large changes go through **`/vp-evolve`** → **`/vp-auto`**. See `workflows/request.md`.
29
29
  </implementation_routing_guard>
30
30
 
31
31
 
32
32
  <objective>
33
- Thu thập, phân loại, lưu trữ UI components để tái sử dụng:
33
+ Collect, classify, and store UI components for reuse:
34
34
  - Global library: `~/.viepilot/ui-components/`
35
35
  - Project library: `.viepilot/ui-components/`
36
36
 
37
- Nguồn thể đến từ prompt/link/snippet (đặc biệt 21st.dev), sau đó chuẩn hóa thành artifacts metadata.
37
+ Sources can come from prompt/link/snippet (especially 21st.dev), then normalized into artifacts with metadata.
38
38
 
39
39
  **Creates/Updates:**
40
40
  - `~/.viepilot/ui-components/{category}/{component-id}/...`
41
41
  - `.viepilot/ui-components/{category}/{component-id}/...`
42
- - `INDEX.md` cho global + local store
42
+ - `INDEX.md` for global + local store
43
43
 
44
- **After:** Component thể dùng lại cho `/vp-brainstorm --ui` `/vp-crystallize`.
44
+ **After:** Component is reusable for `/vp-brainstorm --ui` and `/vp-crystallize`.
45
45
  </objective>
46
46
 
47
47
  <execution_context>
@@ -50,11 +50,11 @@ Nguồn có thể đến từ prompt/link/snippet (đặc biệt 21st.dev), sau
50
50
 
51
51
  <context>
52
52
  Optional flags:
53
- - `--add` : Add/capture component mới
54
- - `--list` : Liệt component theo category
55
- - `--sync` : Đồng bộ global ↔ local index
56
- - `--from-21st` : Ưu tiên flow ingest từ 21st.dev references
57
- - `--approve` : Mark component status thành approved
53
+ - `--add` : Add/capture new component
54
+ - `--list` : List components by category
55
+ - `--sync` : Sync global ↔ local index
56
+ - `--from-21st` : Prioritize ingest flow from 21st.dev references
57
+ - `--approve` : Mark component status as approved
58
58
  </context>
59
59
 
60
60
  <process>
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: vp-update
3
- description: "Nâng cấp package viepilot qua npm (dry-run, --yes, --global) qua vp-tools"
3
+ description: "Upgrade viepilot package via npm (dry-run, --yes, --global) via vp-tools"
4
4
  version: 0.1.1
5
5
  ---
6
6
 
@@ -22,18 +22,18 @@ Use Cursor tools: `Shell`, `ReadFile`, `Glob`, `rg`, `ApplyPatch`, `WebSearch`,
22
22
  <implementation_routing_guard>
23
23
  ## Implementation routing guard (ENH-021)
24
24
 
25
- - **Nâng cấp ViePilot package** (npm) — không implement feature product trong repo đang làm việc mặc định; feature code qua **`/vp-auto`**. Xem `workflows/request.md`.
25
+ - **Upgrade ViePilot package** (npm) — does not implement product features in the working repo by default; feature code goes through **`/vp-auto`**. See `workflows/request.md`.
26
26
  </implementation_routing_guard>
27
27
 
28
28
 
29
29
  <objective>
30
- Chạy **`vp-tools update`** để lên kế hoạch và (khi được xác nhận) thực thi `npm` nâng cấp `viepilot`.
30
+ Run **`vp-tools update`** to plan and (when confirmed) execute the `npm` upgrade of `viepilot`.
31
31
 
32
- **Ràng buộc an toàn:**
33
- - **Non-interactive** (CI, agent không TTY): bắt buộc **`--dry-run`** hoặc **`--yes`**; nếu không sẽ exit lỗi.
34
- - Luôn ưu tiên **`--dry-run`** trước khi apply, trừ khi user đã yêu cầu apply.
32
+ **Safety constraints:**
33
+ - **Non-interactive** (CI, agent without TTY): **`--dry-run`** or **`--yes`** is required; otherwise exits with an error.
34
+ - Always prefer **`--dry-run`** before applying, unless the user has explicitly requested to apply.
35
35
 
36
- **Phân biệt target:** trong repo **không phải** ViePilot nhưng `node_modules/viepilot`, lệnh thể cập nhật **local dependency**. Muốn chỉ nâng **global**, thêm **`--global`**.
36
+ **Target distinction:** in a repo that is **not** ViePilot but has `node_modules/viepilot`, the command may update the **local dependency**. To upgrade only the **global** install, add **`--global`**.
37
37
  </objective>
38
38
 
39
39
  <execution_context>
@@ -42,31 +42,31 @@ Chạy **`vp-tools update`** để lên kế hoạch và (khi được xác nh
42
42
 
43
43
  <process>
44
44
 
45
- ### Step 1: Dry run (mặc định khi tự động)
45
+ ### Step 1: Dry run (default when automated)
46
46
  ```bash
47
47
  vp-tools update --dry-run
48
48
  ```
49
- Đọc output: planned npm command, phiên bản hiện tại vs latest, cảnh báo ambiguous/global.
49
+ Read output: planned npm command, current version vs latest, ambiguous/global warnings.
50
50
 
51
- ### Step 2: Apply (sau khi user đồng ý hoặc đã yêu cầu rõ)
51
+ ### Step 2: Apply (after user confirms or explicitly requests it)
52
52
  ```bash
53
53
  vp-tools update --yes
54
54
  ```
55
- Hoặc ép global:
55
+ Or force global:
56
56
  ```bash
57
57
  vp-tools update --global --dry-run
58
58
  vp-tools update --global --yes
59
59
  ```
60
60
 
61
61
  ### Step 3: Interactive
62
- Nếu terminal tương tác **không** `--yes`, CLI thể hỏi xác nhận trước khi chạy npm.
62
+ If the terminal is interactive and **no** `--yes` flag is present, the CLI may prompt for confirmation before running npm.
63
63
 
64
- ### Step 4: Rollback gợi ý
65
- Output dry-run/update thường gợi ý `npm install -g viepilot@<previous>` — giữ phiên bản từ `vp-tools info` nếu cần hoàn tác.
64
+ ### Step 4: Suggested rollback
65
+ Dry-run/update output typically suggests `npm install -g viepilot@<previous>` — keep the previous version from `vp-tools info` in case a rollback is needed.
66
66
  </process>
67
67
 
68
68
  <success_criteria>
69
- - [ ] Không chạy apply trong non-interactive thiếu `--yes`
70
- - [ ] Nêu target (local vs global) khi user đang project lạ
71
- - [ ] Ghi nhận khi đã `already up to date` (no-op thành công)
69
+ - [ ] Do not run apply in non-interactive mode without `--yes`
70
+ - [ ] Clearly state target (local vs global) when user is in an external project
71
+ - [ ] Acknowledge when `already up to date` (successful no-op)
72
72
  </success_criteria>
@@ -0,0 +1,159 @@
1
+ <!DOCTYPE html>
2
+ <html lang="vi">
3
+ <head>
4
+ <meta charset="UTF-8" />
5
+ <meta name="viewport" content="width=device-width, initial-scale=1.0" />
6
+ <title>APIs — {project}</title>
7
+ <link rel="stylesheet" href="style.css" />
8
+ </head>
9
+ <body data-arch-slug="apis">
10
+ <nav class="nav-sidebar">
11
+ <div class="logo">
12
+ <span>ViePilot Architect Mode</span>
13
+ <strong>{project}</strong>
14
+ </div>
15
+ <ul>
16
+ <li><a href="index.html">🏠 Hub</a></li>
17
+ <li><a href="architecture.html">🏗️ Architecture</a></li>
18
+ <li><a href="sequence-diagram.html">🎬 Sequence</a></li>
19
+ <li><a href="data-flow.html">🔄 Data Flow</a></li>
20
+ <li><a href="decisions.html">📋 Decisions (ADR)</a></li>
21
+ <li><a href="tech-stack.html">🛠️ Tech Stack</a></li>
22
+ <li><a href="tech-notes.html">📝 Tech Notes</a></li>
23
+ <li><a href="feature-map.html">🗺️ Feature Map</a></li>
24
+ <li><a href="erd.html">🗄️ ERD</a></li>
25
+ <li><a href="user-use-cases.html">👤 Use Cases</a></li>
26
+ <li><a href="deployment.html">🚀 Deployment</a></li>
27
+ <li><a href="apis.html" class="active">🔌 APIs</a></li>
28
+ </ul>
29
+ </nav>
30
+
31
+ <main class="main-content">
32
+ <div class="page-header">
33
+ <div>
34
+ <h1>🔌 APIs</h1>
35
+ <p>Service API listing and design decisions</p>
36
+ </div>
37
+ <button id="theme-toggle" onclick="toggleTheme()">☀️ Light</button>
38
+ </div>
39
+
40
+ <div class="card">
41
+ <h2>{Service 1} API</h2>
42
+ <table>
43
+ <thead>
44
+ <tr>
45
+ <th>Method</th>
46
+ <th>Path</th>
47
+ <th>Auth?</th>
48
+ <th>Request Body</th>
49
+ <th>Response</th>
50
+ <th>Status codes</th>
51
+ <th>Notes</th>
52
+ </tr>
53
+ </thead>
54
+ <tbody>
55
+ <tr data-arch-id="A1">
56
+ <td><span class="badge method-get">GET</span></td>
57
+ <td>/api/resource</td>
58
+ <td>Yes</td>
59
+ <td>—</td>
60
+ <td>{ data: [...] }</td>
61
+ <td>200, 401, 500</td>
62
+ <td>{Notes}</td>
63
+ </tr>
64
+ <tr data-arch-id="A2">
65
+ <td><span class="badge method-post">POST</span></td>
66
+ <td>/api/resource</td>
67
+ <td>Yes</td>
68
+ <td>{ name, ... }</td>
69
+ <td>{ id, name, ... }</td>
70
+ <td>201, 400, 401</td>
71
+ <td>{Notes}</td>
72
+ </tr>
73
+ <tr data-arch-id="A3">
74
+ <td><span class="badge method-put">PUT</span></td>
75
+ <td>/api/resource/:id</td>
76
+ <td>Yes</td>
77
+ <td>{ name, ... }</td>
78
+ <td>{ id, name, ... }</td>
79
+ <td>200, 400, 404</td>
80
+ <td>{Notes}</td>
81
+ </tr>
82
+ <tr data-arch-id="A4">
83
+ <td><span class="badge method-delete">DELETE</span></td>
84
+ <td>/api/resource/:id</td>
85
+ <td>Yes</td>
86
+ <td>—</td>
87
+ <td>{ success: true }</td>
88
+ <td>200, 404</td>
89
+ <td>{Notes}</td>
90
+ </tr>
91
+ <tr data-arch-id="A5">
92
+ <td><span class="badge method-patch">PATCH</span></td>
93
+ <td>/api/resource/:id</td>
94
+ <td>Yes</td>
95
+ <td>{ field: value }</td>
96
+ <td>{ id, field, ... }</td>
97
+ <td>200, 400, 404</td>
98
+ <td>{Notes}</td>
99
+ </tr>
100
+ </tbody>
101
+ </table>
102
+ </div>
103
+
104
+ <div class="card">
105
+ <h2>API Design Decisions</h2>
106
+ <table>
107
+ <thead>
108
+ <tr>
109
+ <th>Decision</th>
110
+ <th>Choice</th>
111
+ <th>Rationale</th>
112
+ <th>Notes</th>
113
+ </tr>
114
+ </thead>
115
+ <tbody>
116
+ <tr data-arch-id="A6">
117
+ <td>API Style</td>
118
+ <td>
119
+ <span class="badge method-get">REST</span>
120
+ <span class="badge" style="background:#8b5cf620;color:#c4b5fd;">GraphQL</span>
121
+ <span class="badge" style="background:#0ea5e920;color:#38bdf8;">gRPC</span>
122
+ <span class="badge" style="background:#f59e0b20;color:#fbbf24;">WebSocket</span>
123
+ </td>
124
+ <td>{Rationale}</td>
125
+ <td>{Notes}</td>
126
+ </tr>
127
+ <tr data-arch-id="A7">
128
+ <td>Authentication</td>
129
+ <td>{JWT / Session / OAuth2 / API Key}</td>
130
+ <td>{Rationale}</td>
131
+ <td>{Notes}</td>
132
+ </tr>
133
+ <tr data-arch-id="A8">
134
+ <td>Versioning</td>
135
+ <td>{URL path / Header / None}</td>
136
+ <td>{Rationale}</td>
137
+ <td>{Notes}</td>
138
+ </tr>
139
+ <tr data-arch-id="A9">
140
+ <td>Rate limiting</td>
141
+ <td>{Strategy}</td>
142
+ <td>{Rationale}</td>
143
+ <td>{Notes}</td>
144
+ </tr>
145
+ </tbody>
146
+ </table>
147
+ </div>
148
+ </main>
149
+
150
+ <script>
151
+ function toggleTheme() {
152
+ const html = document.documentElement;
153
+ const isLight = html.classList.toggle('light');
154
+ document.getElementById('theme-toggle').textContent = isLight ? '🌙 Dark' : '☀️ Light';
155
+ }
156
+ </script>
157
+ <script src="architect-actions.js"></script>
158
+ </body>
159
+ </html>