[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M72YARCJZQF9JWQKFZKM9DFN":3,"skill-same:01M72YARCJZQF9JWQKFZKM9DFN":121},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":19,"linkOnly":20,"markdownContent":21,"markdownBody":22,"frontMatter":23,"refName":39,"commitSha":40,"skillDirectory":41,"forksCount":42,"repositoryHtmlUrl":43,"repositoryHomepageUrl":44,"ownerHtmlUrl":45,"ownerBlogUrl":46,"ownerDescription":47,"updatedAt":48,"install":49,"resources":62},"01M72YARCJZQF9JWQKFZKM9DFN","architecture-design",null,"Use to produce a Software Architecture Document for a feature — Arc42 12 sections + C4 L1\u002FL2 inline + ADRs spawned on a blast-radius gate — once PRD.md and CONTEXT.md exist. The feature's target surface(s) are chosen here (the first §4 decision → SAD frontmatter target_surfaces, read by every downstream stage). Drafts §1–§12 in-memory, batch-validates each section Socratically (4-state machine), spawns an ADR only when a decision crosses the blast-radius threshold (irreversible \u002F multi-module \u002F has legitimate alternatives), writes each resolved section + its ADRs atomically, then runs a clean-context critic before finalizing. Brownfield: reads docs\u002Farchitecture-map.md (re-scans only if absent\u002Fstale). Triggers on \"architecture for {slug}\", \"design architecture for {slug}\", \"SAD for {slug}\", \"arc42 for {slug}\", \"C4 context+container for {slug}\", \"\u002Fsdlc:architecture-design {slug}\", \"спроектуй архітектуру {slug}\", \"SAD для {slug}\", \"архітектурний документ {slug}\". Hard-refuse if docs\u002Ffeatures\u002F{slug}\u002FPRD.md is missing. Triggers: \u002Fsdlc:architecture-design {slug}. Output: docs\u002Ffeatures\u002F{slug}\u002Fsad.md + adr\u002FNNNN-*.md.","genkovich\u002Fagentic-engineering-course-public","genkovich","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F14920737?v=4","01M72Y5BWEEZ8VT4DFW6AGGE8X","Kirill Sulimovsky","01M72Y5BXYRGV5PKCVCHEX81WY",15,"MIT","https:\u002F\u002Fgithub.com\u002Fgenkovich\u002Fagentic-engineering-course-public\u002Fblob\u002Fmain\u002Fmodules\u002F6-sdlc\u002Fsdlc\u002Fplugin\u002Fskills\u002Farchitecture-design\u002FSKILL.md",[],[],"2026-11-10 22:39:42",false,"---\nname: architecture-design\nmodel: opus\neffort: high\nagents: [explorer, critic]\ndescription: >-\n  Use to produce a Software Architecture Document for a feature — Arc42 12 sections + C4 L1\u002FL2\n  inline + ADRs spawned on a blast-radius gate — once PRD.md and CONTEXT.md exist. The feature's\n  target surface(s) are chosen here (the first §4 decision → SAD frontmatter target_surfaces, read by\n  every downstream stage). Drafts §1–§12 in-memory, batch-validates each section Socratically\n  (4-state machine), spawns an ADR only when a decision crosses the blast-radius threshold\n  (irreversible \u002F multi-module \u002F has legitimate alternatives), writes each resolved section + its\n  ADRs atomically, then runs a clean-context critic before finalizing. Brownfield: reads\n  docs\u002Farchitecture-map.md (re-scans only if absent\u002Fstale). Triggers on \"architecture for {slug}\",\n  \"design architecture for {slug}\", \"SAD for {slug}\", \"arc42 for {slug}\", \"C4 context+container for\n  {slug}\", \"\u002Fsdlc:architecture-design {slug}\", \"спроектуй архітектуру {slug}\", \"SAD для {slug}\",\n  \"архітектурний документ {slug}\". Hard-refuse if docs\u002Ffeatures\u002F{slug}\u002FPRD.md is missing.\n  Triggers: \u002Fsdlc:architecture-design {slug}. Output: docs\u002Ffeatures\u002F{slug}\u002Fsad.md + adr\u002FNNNN-*.md.\ntriggers:\n  - \u002Fsdlc:architecture-design\n  - \"architecture for\"\n  - \"design architecture for\"\n  - \"SAD for\"\n  - \"arc42 for\"\n  - \"C4 context+container for\"\n  - \"SAD для\"\n  - \"архітектурний документ\"\nstage: \"04-05\"\n---\n\n# Skill: architecture-design (SDLC stages 04-05 🚪 GATE)\n\nGenerator of the **Software Architecture Document** (`docs\u002Ffeatures\u002F\u003Cslug>\u002Fsad.md` — Arc42 12 sections, C4 Context inline in §3 and C4 Container inline in §5) plus supporting ADRs (`docs\u002Ffeatures\u002F\u003Cslug>\u002Fadr\u002FNNNN-*.md`). It drafts all 12 sections in memory, walks them Socratically one section at a time, spawns an ADR only when a decision's *blast radius* (масштаб удару — how painful it is to reverse the decision later) crosses the gate, writes each resolved section and its ADRs as one atomic commit, and runs a clean-context critic over the finished SAD. The document itself is the state — resuming after an interrupt is free. L3 Component \u002F L4 Code are out of scope. This file is the spine; detail lives in `references\u002F`.\n\nThe Socratic machine, the critic, the size matrix, and the ask-style are **shared** — this skill keeps only its deltas:\n→ [`..\u002F_shared\u002Fsocratic-loop.md`](..\u002F_shared\u002Fsocratic-loop.md) · [`..\u002F_shared\u002Fcritic.md`](..\u002F_shared\u002Fcritic.md) · [`..\u002F_shared\u002Fsize-matrix.md`](..\u002F_shared\u002Fsize-matrix.md) · [`..\u002F_shared\u002Fask-style.md`](..\u002F_shared\u002Fask-style.md)\n\nDepth governs the per-section question volume + autonomy → [`..\u002F_shared\u002Finterview-depth.md`](..\u002F_shared\u002Finterview-depth.md). C4 diagrams are confirmed in prose, never as raw source → [`..\u002F_shared\u002Fdiagram-presentation.md`](..\u002F_shared\u002Fdiagram-presentation.md). architecture-design is also where the feature's **target surface(s)** are chosen — the first §4 decision, written to `sad.md` frontmatter `target_surfaces` and read (never re-derived) by every downstream stage → [`..\u002F_shared\u002Fsurfaces.md`](..\u002F_shared\u002Fsurfaces.md).\n\n## Як це читати (короткий вступ)\n\nЦе інструкція для агента, який запускає skill. У ній **7-крокова процедура** (Protocol нижче) — крок за кроком, як з PRD дістатися до готового `sad.md` з 5-12 ADR.\n\nЯкщо вперше відкриваєш файл — почни з: **`## When to use`** + **`## Inputs`** (коли skill застосовний), потім **`## Protocol`** (7 кроків), потім References (деталі на кожен крок), і **`## Definition of Done`** (що має бути виконано до завершення).\n\n**Словничок термінів** (англо-термін → що означає UA одним рядком):\n\n- *target surface* — таргет-сёрфейс: *що саме ми будуємо* (бекенд-сервіс \u002F веб-фронт \u002F мобільний застосунок \u002F CLI \u002F worker \u002F library-sdk). Обирається тут, у §4, і записується у `target_surfaces:` frontmatter SAD → [`..\u002F_shared\u002Fsurfaces.md`](..\u002F_shared\u002Fsurfaces.md).\n- *depth dial* — депт-діал: регулятор easy\u002Fmedium\u002Fhard на запуск — скільки skill питає vs вирішує сам → [`..\u002F_shared\u002Finterview-depth.md`](..\u002F_shared\u002Finterview-depth.md).\n- *blast radius* — масштаб удару: наскільки боляче буде передумати рішення.\n- *Socratic loop* — режим діалогу з користувачем питаннями про рішення (одна `AskUserQuestion` за раз).\n- *blast-radius gate* — перевірка з 3 критеріями: незворотнє (≥3 днів переробки), зачіпає ≥2 модулі, є чесна альтернатива. **2 з 3 → ADR.**\n- *4-state machine* — 4 можливі дії з рішенням: **Прийняти** \u002F **Виправити** \u002F **Винести у відкрите питання** \u002F **Викинути**.\n- *Save-as-OQ* — рішення не приймається зараз, переноситься у §11 SAD як відкрите питання з власником і дедлайном.\n- *MADR* — формат файлу ADR (markdown з заголовком, контекстом, опціями, наслідками).\n- *clean-context critic* — окремий subagent (`sdlc:critic`), який бачить лише фінальний файл (а не діалог), і шукає внутрішні протиріччя.\n\n## Owner\n\nArchitect \u002F Tech Lead (drives everything). PM is consulted only on §10 Quality goals and §11 Risk severities.\n\n## When to use\n\n- After `sdlc:write-prd` produced `docs\u002Ffeatures\u002F\u003Cslug>\u002FPRD.md` (ideally after `sdlc:clarify-prd` tightened it).\n- Brownfield repo (existing code the feature changes) OR greenfield with a PRD only.\n- `\u002Fsdlc:architecture-design \u003Cslug>` as explicit invocation.\n- Skip if `docs\u002Ffeatures\u002F\u003Cslug>\u002Fsad.md` already has all 12 sections filled (content or `\u003C!-- N\u002FA: reason -->`) AND `adr\u002F` has ≥1 file — suggest review instead.\n\n## Inputs\n\n- `\u003Cslug>` — same feature slug used by every earlier stage.\n- **Gate (hard-refuse if missing):** `docs\u002Ffeatures\u002F\u003Cslug>\u002FPRD.md`. If absent → STOP and point: «run `\u002Fsdlc:write-prd \u003Cslug>` first — architecture-design reads the PRD's goals\u002FNFRs as canonical». `CONTEXT.md` (`## Glossary`) is read when present — it wins over anything that contradicts; absent → derive roles from PRD §4 and note it.\n- (Optional) `docs\u002Ffeatures\u002F\u003Cslug>\u002F.size` — depth hint (MVP vs Full + expected ADR count per the size matrix). Absent → default to M (full set) and say so loudly in the handoff.\n- (Optional) `docs\u002Farchitecture-map.md` — the current-architecture source (produced by `sdlc:map-architecture`). Read it; re-scan only if absent\u002Fstale.\n- A git repo — so the Step-3 brownfield scan can read code when the map is missing.\n\n## Protocol\n\n1. **Gate + size + set interview depth.** `test -f docs\u002Ffeatures\u002F\u003Cslug>\u002FPRD.md` → missing = refuse with the pointer above. Read `.size` if present (shapes ADR count + §6 flow count — see the size matrix; absent → default M). **Then set the interview depth (the opening question):** read `interview_depth` from `.claude\u002Fsdlc.local.md` if present (else default medium), and — unless a `--depth=easy|medium|hard` arg was passed — ask ONE depth-selection `AskUserQuestion` phrased per [`..\u002F_shared\u002Fask-style.md`](..\u002F_shared\u002Fask-style.md), with the saved\u002Fmedium value as the «(Recommended)» first option. The level governs the step-6 per-section question volume (easy: decide convention-defaults itself + an assumptions ledger, ask only blast-radius decisions; medium: walk every real decision; hard: walk every decision, foreground each trade-off) and the C4 diagram confirmation → [`..\u002F_shared\u002Finterview-depth.md`](..\u002F_shared\u002Finterview-depth.md). (The blast-radius → ADR gate and the §11 owner+due rule are floors — enforced at every depth.)\n2. **Read upstream.** `PRD.md` (§2 Goals, §3 Non-goals, §6 NFR with numeric targets + measurement, §6.1 Security\u002Fprivacy + abuse cases, §7 KPIs, §8 Open questions, §13 Recommendation, any §1 ¶4 «Decision override» bullets); `CONTEXT.md` `## Glossary` (canonical roles + domain terms — wins over anything that contradicts).\n3. **Current architecture — read the map, don't re-scan.** Prefer `docs\u002Farchitecture-map.md` (produced by `sdlc:map-architecture`): if it exists and is fresh (its `reflects_commit` ≈ current HEAD), read it — that IS the brownfield context (module layout, layering, datastores, conventions, the §Frontend \u002F UI foundation, the C4 of what exists). Re-scan only if the map is **absent or stale**: dispatch the [`explorer`](..\u002F..\u002Fagents\u002Fexplorer.md) agent — `subagent_type: \"sdlc:explorer\"` (`model: haiku` + `effort: low`, clean-isolated per [`..\u002F_shared\u002Fagent-roster.md`](..\u002F_shared\u002Fagent-roster.md)) — for «primary language + frameworks + versions, module layout, layering\u002Fports conventions, datastores, inter-module comms, the existing design system \u002F component library \u002F tokens (§Frontend), anything that constrains `\u003Cslug>`», and suggest the user run `\u002Fsdlc:map-architecture` to persist it. Greenfield (no source + no map) → note `\u003C!-- brownfield: N\u002FA — greenfield repo -->` in §3. (Fallback to a `subagent_type: \"Explore\"` Agent if `sdlc:explorer` is unavailable.)\n4. **Bootstrap + read template.** Copy [`.\u002Ftemplates\u002Fsad-template.md`](.\u002Ftemplates\u002Fsad-template.md) → `docs\u002Ffeatures\u002F\u003Cslug>\u002Fsad.md`; patch frontmatter (`updated_at`, `ticket`, `feature_size` from `.size`; leave `target_surfaces: []` empty — it's filled when §4's Target-surface decision resolves in step 6). Commit `feat(\u003Cslug>): bootstrap sad.md from PRD + architecture-map`. Read the template's `\u003C!-- … -->` comments (the per-section contract) + [`.\u002Ftemplates\u002Fadr-template.md`](.\u002Ftemplates\u002Fadr-template.md) (MADR shape). This is the only file write between Step 4 and Step 6 — Step 5 drafts in-memory.\n5. **Per-section draft (in-memory).** For each §1 → §12, draft proposed content + the decisions it contains, bundling trivial convention defaults into one question. Per-section sourcing, item-banks, the question budget, and pre-Socratic hygiene → [`.\u002Freferences\u002Fdraft-generation.md`](.\u002Freferences\u002Fdraft-generation.md). Do NOT write `sad.md` here.\n6. **Socratic walk + blast-radius gate, per-section write.** For each §1 → §12: render the full section + its numbered decisions (big picture), walk one `AskUserQuestion` per decision with the shared 4-state machine (per-section question volume scales with the depth dial — at easy, decide convention-defaults yourself and ladder them into the assumptions ledger, asking only blast-radius decisions), apply transitions in-memory, run the blast-radius gate on each **Approved** decision (spawn an ADR on 2-of-3), then write the resolved section + its spawned ADRs + commit `feat(\u003Cslug>): sad §N — \u003Csummary>`. Never return to a written section. **§4's first decision is the Target-surface selection** — *what's being built* (a multiSelect over `backend-service` \u002F `web-frontend` \u002F `mobile-app` \u002F `desktop-app` \u002F `cli` \u002F `worker` \u002F `library-sdk`, derived from PRD §1 «for whom» + §4 roles; the PRD itself names no surface), gated by the blast-radius gate (multi-surface is multi-module + irreversible ⇒ usually an ADR). On resolution, **write `target_surfaces: [...]` to the `sad.md` frontmatter** — it draws one §5 C4 container per surface and is read (never re-derived) by `api-forge` \u002F `complete-sequence-diagrams` \u002F `break-tasks` \u002F `plan-tests` \u002F `review-feature`. For each declared **UI surface** (`web-frontend` \u002F `mobile-app` \u002F `desktop-app`), walk the follow-on **UI-architecture decision** (web → SSR\u002FSPA\u002Fhybrid; mobile → native\u002Fcross-platform; + state\u002Frouting if warranted), gated to an ADR like any §4 strategic choice; the UI **reuses** the existing design system \u002F components \u002F tokens from `architecture-map.md` §Frontend → [`..\u002F_shared\u002Fsurfaces.md`](..\u002F_shared\u002Fsurfaces.md). **For the §3 C4Context and §5 C4Container sections, confirm the diagram per [`..\u002F_shared\u002Fdiagram-presentation.md`](..\u002F_shared\u002Fdiagram-presentation.md)** — write the block into `sad.md`, validate it per [`..\u002F_shared\u002Fmermaid-check.md`](..\u002F_shared\u002Fmermaid-check.md), then **describe the context \u002F containers in prose** (who talks to what, which systems it depends on) and confirm by prose; **never paste the raw C4 source as the question**. At `easy`, write + a one-line summary and proceed (no per-diagram question). architecture-design delta → [`.\u002Freferences\u002Fsocratic-loop.md`](.\u002Freferences\u002Fsocratic-loop.md) (section list, decision-types, the gate); gate scoring → [`.\u002Freferences\u002Fblast-radius-heuristic.md`](.\u002Freferences\u002Fblast-radius-heuristic.md); C4 syntax for §3\u002F§5 → [`.\u002Freferences\u002Fc4-mermaid-syntax.md`](.\u002Freferences\u002Fc4-mermaid-syntax.md); cadence → [`.\u002Freferences\u002Fsocratic-cadence.md`](.\u002Freferences\u002Fsocratic-cadence.md); question shapes → [`.\u002Freferences\u002Fask-examples.md`](.\u002Freferences\u002Fask-examples.md). Maintain the edits-log + an adjacent ADR-spawns log.\n7. **Critic + finalize.** Dispatch the [`critic`](..\u002F..\u002Fagents\u002Fcritic.md) agent — `subagent_type: \"sdlc:critic\"` (carries `model: opus` + `effort: high`, clean-isolated per [`..\u002F_shared\u002Fagent-roster.md`](..\u002F_shared\u002Fagent-roster.md); fallback `general-purpose` if unavailable) — with the architecture-design delta in [`.\u002Freferences\u002Fcritic-phase.md`](.\u002Freferences\u002Fcritic-phase.md) + the agent prompt body in [`.\u002Freferences\u002Fcritic-prompt.md`](.\u002Freferences\u002Fcritic-prompt.md) (over [`..\u002F_shared\u002Fcritic.md`](..\u002F_shared\u002Fcritic.md)) on the final `sad.md` + edits-log + ADR-spawns log; resolve each finding via `AskUserQuestion` (Accept revert \u002F Accept amendment \u002F Override-with-rationale → §1 ¶4 bullet). Run the pre-write backstop scans: **validate every Mermaid block in `sad.md` per [`..\u002F_shared\u002Fmermaid-check.md`](..\u002F_shared\u002Fmermaid-check.md)** (render-parse with `mmdc` if available, else the structural lint — fix any that don't parse, never commit a broken diagram); ADR title in decision-form kebab-case + Status `Accepted`; §9 closed against `adr\u002F`; no `\u003Cplaceholder>` stubs. On pass, write any amendments + commit `feat(\u003Cslug>): sad finalization (critic pass)`. Then **emit the stage-handoff block** per [`..\u002F_shared\u002Fhandoff.md`](..\u002F_shared\u002Fhandoff.md) — *What I did* + *Review* (`sad.md` C4 §3\u002F§5 + `target_surfaces`, `adr\u002F`) + *Run next* (`\u002Fclear`, then `\u002Fsdlc:complete-sequence-diagrams \u003Cslug>`, which writes flows into §6).\n\n## Definition of Done\n\n- `docs\u002Ffeatures\u002F\u003Cslug>\u002Fsad.md` exists with all 12 Arc42 sections filled OR marked `\u003C!-- N\u002FA: \u003Creason> -->`.\n- §3 has a real `C4Context` block and §5 a real `C4Container` block — real names from CONTEXT + the map\u002Fscan, no `\u003Cplaceholder>` stubs, no `Container_Bondary` typos. §6 has ≥1 `sequenceDiagram` (the `complete-sequence-diagrams` stage then covers every critical flow \u002F §5 AC — no cap).\n- Frontmatter `target_surfaces: [...]` is non-empty (the Target-surface decision was made in §4) and §5 draws **one C4 container per declared surface**; each declared UI surface (`web-frontend` \u002F `mobile-app` \u002F `desktop-app`) carries a UI-architecture decision — an ADR, or an inline §4 note if it didn't cross the gate. → [`..\u002F_shared\u002Fsurfaces.md`](..\u002F_shared\u002Fsurfaces.md).\n- §9 ADR table is closed against `adr\u002F` (every file has a row, every row a file). 2–4 ADRs for XS\u002FS, 5–12 for M, 10–15 for L\u002FXL; every ADR Status = `Accepted`, title in decision-form (`0003-sliding-window-with-redis.md` ✓ vs `0003-rate-limiting.md` ✗), no strawman options.\n- §10 scenarios are testable (When \u002F Then \u002F How-verify) and cite PRD §6 NFR numbers verbatim (no inventing, no rounding).\n- §11 carries a row for every `save_as_oq` decision with both owner AND due (severity literal `Open question`); never N\u002FA.\n- §1 Stakeholders + §3 actors match the CONTEXT glossary exactly (no invented `user`\u002F`admin`).\n- Step-3 read the map (or the explorer scan ran on a brownfield, or §3 has the greenfield note). Edits-log maintained. The critic ran on the post-Socratic SAD; every finding resolved or overridden.\n\nFull DoD + anti-patterns + N\u002FA logic per section + ADR-count expectations → [`.\u002Freferences\u002Fchecklist.md`](.\u002Freferences\u002Fchecklist.md). Any check fails → re-open the relevant `AskUserQuestion`, then re-check.\n\n## Anti-patterns\n\n- **An ADR for every decision** — kills the genre. Only blast-radius decisions become ADRs (5–12 for M, not 25). Conversely, missing an irreversibility under-ADRs the feature.\n- **ADR `Status: Proposed` from this skill** — it is synchronous (you decide with the user now), so Status is `Accepted`. Use `sdlc:decide-adr` for an async Proposed → Accepted flow.\n- **ADR title in problem-form** (`0003-rate-limiting.md`) or with a **strawman option** (an alternative an existing constraint already excludes) — both dilute the ADR genre and trigger the critic's F6.\n- **Inventing §10 numbers** the PRD never agreed to — cite PRD §6 NFR verbatim. **Naming a concrete stack in §2** that contradicts the repo's conventions without an Override note pointing at §11.\n- **Re-deriving the surface downstream.** architecture-design declares `target_surfaces` once; `api-forge` \u002F `complete-sequence-diagrams` \u002F `break-tasks` \u002F `plan-tests` \u002F `review-feature` read it. A skill that re-infers the surface when the SAD already declared it is the anti-pattern surfaces.md kills.\n- **Skipping the brownfield context** — guessing the layout produces a fictional §5 Container view and invented §2 Constraints. Read `architecture-map.md`; scan with `sdlc:explorer` only if it's missing\u002Fstale.\n- **Returning to a written section** — each section commits atomically; cross-section drift is the critic's job, not a re-walk. Re-opening §4 after writing §10 means you don't trust the per-section batch.\n- **Save-as-OQ without owner+due** — capture both in the follow-up; missing either downgrades to Drop with a warning, never a half-filled §11 row.\n- **Resolving critic findings unilaterally** (without `AskUserQuestion`) or **one giant end-of-pass commit** — both defeat the per-section, user-in-the-loop contract.\n- **Spilling into C4 L3\u002FL4** — out of scope; suggest a separate diagramming pass.\n\n## References & templates\n\n- [`.\u002Freferences\u002Fdraft-generation.md`](.\u002Freferences\u002Fdraft-generation.md) — Step 5: per-section sourcing for §1–§12, item-banks, the question budget, pre-Socratic hygiene.\n- [`.\u002Freferences\u002Fsocratic-loop.md`](.\u002Freferences\u002Fsocratic-loop.md) — architecture-design's delta over the shared Socratic loop (section list, decision-types incl. Surface + UI-architecture, the blast-radius gate, the §11 OQ table).\n- [`.\u002Freferences\u002Fsocratic-cadence.md`](.\u002Freferences\u002Fsocratic-cadence.md) — how to avoid question fatigue (mini-recap every 5, Recommended-first, bundle trivial defaults).\n- [`.\u002Freferences\u002Fblast-radius-heuristic.md`](.\u002Freferences\u002Fblast-radius-heuristic.md) — the 3-criteria ADR gate (irreversible \u002F multi-module \u002F legitimate alternatives), scoring, target counts.\n- [`.\u002Freferences\u002Fcritic-phase.md`](.\u002Freferences\u002Fcritic-phase.md) — Step 7 dispatch + resolution loop + pre-write backstop scans; architecture-design's delta over the shared critic (F5 floor, F6 = NFR-leak + strawman-ADR + §2-vs-repo, F1 = strategic-vector drift).\n- [`.\u002Freferences\u002Fcritic-prompt.md`](.\u002Freferences\u002Fcritic-prompt.md) — canonical agent prompt body for the Step 7 critic. 6 failure classes adapted for the SAD.\n- [`.\u002Freferences\u002Fc4-mermaid-syntax.md`](.\u002Freferences\u002Fc4-mermaid-syntax.md) — C4Context + C4Container Mermaid cheatsheet for §3\u002F§5.\n- [`.\u002Freferences\u002Fask-examples.md`](.\u002Freferences\u002Fask-examples.md) — architecture-design-specific question shapes (Surface, UI-architecture, strategic-with-ADR-spawn, blast-radius gate, Save-as-OQ follow-up, critic-finding resolution).\n- [`.\u002Freferences\u002Fchecklist.md`](.\u002Freferences\u002Fchecklist.md) — full Definition of Done + anti-patterns + N\u002FA logic + ADR count expectations.\n- [`..\u002F_shared\u002Finterview-depth.md`](..\u002F_shared\u002Finterview-depth.md) — the easy\u002Fmedium\u002Fhard dial set in step 1 (per-section question volume + autonomy).\n- [`..\u002F_shared\u002Fdiagram-presentation.md`](..\u002F_shared\u002Fdiagram-presentation.md) — how the §3\u002F§5 C4 diagrams are confirmed in prose (write → validate → describe), never as raw source.\n- [`..\u002F_shared\u002Fmermaid-check.md`](..\u002F_shared\u002Fmermaid-check.md) — validate every C4 block after writing it.\n- [`..\u002F_shared\u002Fsurfaces.md`](..\u002F_shared\u002Fsurfaces.md) — the target-surface taxonomy (C4-container-grounded); architecture-design owns the selection (§4 first decision → frontmatter `target_surfaces`), downstream reads it.\n- [`.\u002Ftemplates\u002Fsad-template.md`](.\u002Ftemplates\u002Fsad-template.md) · [`.\u002Ftemplates\u002Fadr-template.md`](.\u002Ftemplates\u002Fadr-template.md) · [`.\u002Ftemplates\u002Fc4-context.md`](.\u002Ftemplates\u002Fc4-context.md) · [`.\u002Ftemplates\u002Fc4-container.md`](.\u002Ftemplates\u002Fc4-container.md) · [`.\u002Ftemplates\u002Fdeployment.md`](.\u002Ftemplates\u002Fdeployment.md) — output scaffolds; inline comments are the per-section generation contract. (C4 syntax → [`.\u002Freferences\u002Fc4-mermaid-syntax.md`](.\u002Freferences\u002Fc4-mermaid-syntax.md).)\n","# Skill: architecture-design (SDLC stages 04-05 🚪 GATE)\n\nGenerator of the **Software Architecture Document** (`docs\u002Ffeatures\u002F\u003Cslug>\u002Fsad.md` — Arc42 12 sections, C4 Context inline in §3 and C4 Container inline in §5) plus supporting ADRs (`docs\u002Ffeatures\u002F\u003Cslug>\u002Fadr\u002FNNNN-*.md`). It drafts all 12 sections in memory, walks them Socratically one section at a time, spawns an ADR only when a decision's *blast radius* (масштаб удару — how painful it is to reverse the decision later) crosses the gate, writes each resolved section and its ADRs as one atomic commit, and runs a clean-context critic over the finished SAD. The document itself is the state — resuming after an interrupt is free. L3 Component \u002F L4 Code are out of scope. This file is the spine; detail lives in `references\u002F`.\n\nThe Socratic machine, the critic, the size matrix, and the ask-style are **shared** — this skill keeps only its deltas:\n→ [`..\u002F_shared\u002Fsocratic-loop.md`](..\u002F_shared\u002Fsocratic-loop.md) · [`..\u002F_shared\u002Fcritic.md`](..\u002F_shared\u002Fcritic.md) · [`..\u002F_shared\u002Fsize-matrix.md`](..\u002F_shared\u002Fsize-matrix.md) · [`..\u002F_shared\u002Fask-style.md`](..\u002F_shared\u002Fask-style.md)\n\nDepth governs the per-section question volume + autonomy → [`..\u002F_shared\u002Finterview-depth.md`](..\u002F_shared\u002Finterview-depth.md). C4 diagrams are confirmed in prose, never as raw source → [`..\u002F_shared\u002Fdiagram-presentation.md`](..\u002F_shared\u002Fdiagram-presentation.md). architecture-design is also where the feature's **target surface(s)** are chosen — the first §4 decision, written to `sad.md` frontmatter `target_surfaces` and read (never re-derived) by every downstream stage → [`..\u002F_shared\u002Fsurfaces.md`](..\u002F_shared\u002Fsurfaces.md).\n\n## Як це читати (короткий вступ)\n\nЦе інструкція для агента, який запускає skill. У ній **7-крокова процедура** (Protocol нижче) — крок за кроком, як з PRD дістатися до готового `sad.md` з 5-12 ADR.\n\nЯкщо вперше відкриваєш файл — почни з: **`## When to use`** + **`## Inputs`** (коли skill застосовний), потім **`## Protocol`** (7 кроків), потім References (деталі на кожен крок), і **`## Definition of Done`** (що має бути виконано до завершення).\n\n**Словничок термінів** (англо-термін → що означає UA одним рядком):\n\n- *target surface* — таргет-сёрфейс: *що саме ми будуємо* (бекенд-сервіс \u002F веб-фронт \u002F мобільний застосунок \u002F CLI \u002F worker \u002F library-sdk). Обирається тут, у §4, і записується у `target_surfaces:` frontmatter SAD → [`..\u002F_shared\u002Fsurfaces.md`](..\u002F_shared\u002Fsurfaces.md).\n- *depth dial* — депт-діал: регулятор easy\u002Fmedium\u002Fhard на запуск — скільки skill питає vs вирішує сам → [`..\u002F_shared\u002Finterview-depth.md`](..\u002F_shared\u002Finterview-depth.md).\n- *blast radius* — масштаб удару: наскільки боляче буде передумати рішення.\n- *Socratic loop* — режим діалогу з користувачем питаннями про рішення (одна `AskUserQuestion` за раз).\n- *blast-radius gate* — перевірка з 3 критеріями: незворотнє (≥3 днів переробки), зачіпає ≥2 модулі, є чесна альтернатива. **2 з 3 → ADR.**\n- *4-state machine* — 4 можливі дії з рішенням: **Прийняти** \u002F **Виправити** \u002F **Винести у відкрите питання** \u002F **Викинути**.\n- *Save-as-OQ* — рішення не приймається зараз, переноситься у §11 SAD як відкрите питання з власником і дедлайном.\n- *MADR* — формат файлу ADR (markdown з заголовком, контекстом, опціями, наслідками).\n- *clean-context critic* — окремий subagent (`sdlc:critic`), який бачить лише фінальний файл (а не діалог), і шукає внутрішні протиріччя.\n\n## Owner\n\nArchitect \u002F Tech Lead (drives everything). PM is consulted only on §10 Quality goals and §11 Risk severities.\n\n## When to use\n\n- After `sdlc:write-prd` produced `docs\u002Ffeatures\u002F\u003Cslug>\u002FPRD.md` (ideally after `sdlc:clarify-prd` tightened it).\n- Brownfield repo (existing code the feature changes) OR greenfield with a PRD only.\n- `\u002Fsdlc:architecture-design \u003Cslug>` as explicit invocation.\n- Skip if `docs\u002Ffeatures\u002F\u003Cslug>\u002Fsad.md` already has all 12 sections filled (content or `\u003C!-- N\u002FA: reason -->`) AND `adr\u002F` has ≥1 file — suggest review instead.\n\n## Inputs\n\n- `\u003Cslug>` — same feature slug used by every earlier stage.\n- **Gate (hard-refuse if missing):** `docs\u002Ffeatures\u002F\u003Cslug>\u002FPRD.md`. If absent → STOP and point: «run `\u002Fsdlc:write-prd \u003Cslug>` first — architecture-design reads the PRD's goals\u002FNFRs as canonical». `CONTEXT.md` (`## Glossary`) is read when present — it wins over anything that contradicts; absent → derive roles from PRD §4 and note it.\n- (Optional) `docs\u002Ffeatures\u002F\u003Cslug>\u002F.size` — depth hint (MVP vs Full + expected ADR count per the size matrix). Absent → default to M (full set) and say so loudly in the handoff.\n- (Optional) `docs\u002Farchitecture-map.md` — the current-architecture source (produced by `sdlc:map-architecture`). Read it; re-scan only if absent\u002Fstale.\n- A git repo — so the Step-3 brownfield scan can read code when the map is missing.\n\n## Protocol\n\n1. **Gate + size + set interview depth.** `test -f docs\u002Ffeatures\u002F\u003Cslug>\u002FPRD.md` → missing = refuse with the pointer above. Read `.size` if present (shapes ADR count + §6 flow count — see the size matrix; absent → default M). **Then set the interview depth (the opening question):** read `interview_depth` from `.claude\u002Fsdlc.local.md` if present (else default medium), and — unless a `--depth=easy|medium|hard` arg was passed — ask ONE depth-selection `AskUserQuestion` phrased per [`..\u002F_shared\u002Fask-style.md`](..\u002F_shared\u002Fask-style.md), with the saved\u002Fmedium value as the «(Recommended)» first option. The level governs the step-6 per-section question volume (easy: decide convention-defaults itself + an assumptions ledger, ask only blast-radius decisions; medium: walk every real decision; hard: walk every decision, foreground each trade-off) and the C4 diagram confirmation → [`..\u002F_shared\u002Finterview-depth.md`](..\u002F_shared\u002Finterview-depth.md). (The blast-radius → ADR gate and the §11 owner+due rule are floors — enforced at every depth.)\n2. **Read upstream.** `PRD.md` (§2 Goals, §3 Non-goals, §6 NFR with numeric targets + measurement, §6.1 Security\u002Fprivacy + abuse cases, §7 KPIs, §8 Open questions, §13 Recommendation, any §1 ¶4 «Decision override» bullets); `CONTEXT.md` `## Glossary` (canonical roles + domain terms — wins over anything that contradicts).\n3. **Current architecture — read the map, don't re-scan.** Prefer `docs\u002Farchitecture-map.md` (produced by `sdlc:map-architecture`): if it exists and is fresh (its `reflects_commit` ≈ current HEAD), read it — that IS the brownfield context (module layout, layering, datastores, conventions, the §Frontend \u002F UI foundation, the C4 of what exists). Re-scan only if the map is **absent or stale**: dispatch the [`explorer`](..\u002F..\u002Fagents\u002Fexplorer.md) agent — `subagent_type: \"sdlc:explorer\"` (`model: haiku` + `effort: low`, clean-isolated per [`..\u002F_shared\u002Fagent-roster.md`](..\u002F_shared\u002Fagent-roster.md)) — for «primary language + frameworks + versions, module layout, layering\u002Fports conventions, datastores, inter-module comms, the existing design system \u002F component library \u002F tokens (§Frontend), anything that constrains `\u003Cslug>`», and suggest the user run `\u002Fsdlc:map-architecture` to persist it. Greenfield (no source + no map) → note `\u003C!-- brownfield: N\u002FA — greenfield repo -->` in §3. (Fallback to a `subagent_type: \"Explore\"` Agent if `sdlc:explorer` is unavailable.)\n4. **Bootstrap + read template.** Copy [`.\u002Ftemplates\u002Fsad-template.md`](.\u002Ftemplates\u002Fsad-template.md) → `docs\u002Ffeatures\u002F\u003Cslug>\u002Fsad.md`; patch frontmatter (`updated_at`, `ticket`, `feature_size` from `.size`; leave `target_surfaces: []` empty — it's filled when §4's Target-surface decision resolves in step 6). Commit `feat(\u003Cslug>): bootstrap sad.md from PRD + architecture-map`. Read the template's `\u003C!-- … -->` comments (the per-section contract) + [`.\u002Ftemplates\u002Fadr-template.md`](.\u002Ftemplates\u002Fadr-template.md) (MADR shape). This is the only file write between Step 4 and Step 6 — Step 5 drafts in-memory.\n5. **Per-section draft (in-memory).** For each §1 → §12, draft proposed content + the decisions it contains, bundling trivial convention defaults into one question. Per-section sourcing, item-banks, the question budget, and pre-Socratic hygiene → [`.\u002Freferences\u002Fdraft-generation.md`](.\u002Freferences\u002Fdraft-generation.md). Do NOT write `sad.md` here.\n6. **Socratic walk + blast-radius gate, per-section write.** For each §1 → §12: render the full section + its numbered decisions (big picture), walk one `AskUserQuestion` per decision with the shared 4-state machine (per-section question volume scales with the depth dial — at easy, decide convention-defaults yourself and ladder them into the assumptions ledger, asking only blast-radius decisions), apply transitions in-memory, run the blast-radius gate on each **Approved** decision (spawn an ADR on 2-of-3), then write the resolved section + its spawned ADRs + commit `feat(\u003Cslug>): sad §N — \u003Csummary>`. Never return to a written section. **§4's first decision is the Target-surface selection** — *what's being built* (a multiSelect over `backend-service` \u002F `web-frontend` \u002F `mobile-app` \u002F `desktop-app` \u002F `cli` \u002F `worker` \u002F `library-sdk`, derived from PRD §1 «for whom» + §4 roles; the PRD itself names no surface), gated by the blast-radius gate (multi-surface is multi-module + irreversible ⇒ usually an ADR). On resolution, **write `target_surfaces: [...]` to the `sad.md` frontmatter** — it draws one §5 C4 container per surface and is read (never re-derived) by `api-forge` \u002F `complete-sequence-diagrams` \u002F `break-tasks` \u002F `plan-tests` \u002F `review-feature`. For each declared **UI surface** (`web-frontend` \u002F `mobile-app` \u002F `desktop-app`), walk the follow-on **UI-architecture decision** (web → SSR\u002FSPA\u002Fhybrid; mobile → native\u002Fcross-platform; + state\u002Frouting if warranted), gated to an ADR like any §4 strategic choice; the UI **reuses** the existing design system \u002F components \u002F tokens from `architecture-map.md` §Frontend → [`..\u002F_shared\u002Fsurfaces.md`](..\u002F_shared\u002Fsurfaces.md). **For the §3 C4Context and §5 C4Container sections, confirm the diagram per [`..\u002F_shared\u002Fdiagram-presentation.md`](..\u002F_shared\u002Fdiagram-presentation.md)** — write the block into `sad.md`, validate it per [`..\u002F_shared\u002Fmermaid-check.md`](..\u002F_shared\u002Fmermaid-check.md), then **describe the context \u002F containers in prose** (who talks to what, which systems it depends on) and confirm by prose; **never paste the raw C4 source as the question**. At `easy`, write + a one-line summary and proceed (no per-diagram question). architecture-design delta → [`.\u002Freferences\u002Fsocratic-loop.md`](.\u002Freferences\u002Fsocratic-loop.md) (section list, decision-types, the gate); gate scoring → [`.\u002Freferences\u002Fblast-radius-heuristic.md`](.\u002Freferences\u002Fblast-radius-heuristic.md); C4 syntax for §3\u002F§5 → [`.\u002Freferences\u002Fc4-mermaid-syntax.md`](.\u002Freferences\u002Fc4-mermaid-syntax.md); cadence → [`.\u002Freferences\u002Fsocratic-cadence.md`](.\u002Freferences\u002Fsocratic-cadence.md); question shapes → [`.\u002Freferences\u002Fask-examples.md`](.\u002Freferences\u002Fask-examples.md). Maintain the edits-log + an adjacent ADR-spawns log.\n7. **Critic + finalize.** Dispatch the [`critic`](..\u002F..\u002Fagents\u002Fcritic.md) agent — `subagent_type: \"sdlc:critic\"` (carries `model: opus` + `effort: high`, clean-isolated per [`..\u002F_shared\u002Fagent-roster.md`](..\u002F_shared\u002Fagent-roster.md); fallback `general-purpose` if unavailable) — with the architecture-design delta in [`.\u002Freferences\u002Fcritic-phase.md`](.\u002Freferences\u002Fcritic-phase.md) + the agent prompt body in [`.\u002Freferences\u002Fcritic-prompt.md`](.\u002Freferences\u002Fcritic-prompt.md) (over [`..\u002F_shared\u002Fcritic.md`](..\u002F_shared\u002Fcritic.md)) on the final `sad.md` + edits-log + ADR-spawns log; resolve each finding via `AskUserQuestion` (Accept revert \u002F Accept amendment \u002F Override-with-rationale → §1 ¶4 bullet). Run the pre-write backstop scans: **validate every Mermaid block in `sad.md` per [`..\u002F_shared\u002Fmermaid-check.md`](..\u002F_shared\u002Fmermaid-check.md)** (render-parse with `mmdc` if available, else the structural lint — fix any that don't parse, never commit a broken diagram); ADR title in decision-form kebab-case + Status `Accepted`; §9 closed against `adr\u002F`; no `\u003Cplaceholder>` stubs. On pass, write any amendments + commit `feat(\u003Cslug>): sad finalization (critic pass)`. Then **emit the stage-handoff block** per [`..\u002F_shared\u002Fhandoff.md`](..\u002F_shared\u002Fhandoff.md) — *What I did* + *Review* (`sad.md` C4 §3\u002F§5 + `target_surfaces`, `adr\u002F`) + *Run next* (`\u002Fclear`, then `\u002Fsdlc:complete-sequence-diagrams \u003Cslug>`, which writes flows into §6).\n\n## Definition of Done\n\n- `docs\u002Ffeatures\u002F\u003Cslug>\u002Fsad.md` exists with all 12 Arc42 sections filled OR marked `\u003C!-- N\u002FA: \u003Creason> -->`.\n- §3 has a real `C4Context` block and §5 a real `C4Container` block — real names from CONTEXT + the map\u002Fscan, no `\u003Cplaceholder>` stubs, no `Container_Bondary` typos. §6 has ≥1 `sequenceDiagram` (the `complete-sequence-diagrams` stage then covers every critical flow \u002F §5 AC — no cap).\n- Frontmatter `target_surfaces: [...]` is non-empty (the Target-surface decision was made in §4) and §5 draws **one C4 container per declared surface**; each declared UI surface (`web-frontend` \u002F `mobile-app` \u002F `desktop-app`) carries a UI-architecture decision — an ADR, or an inline §4 note if it didn't cross the gate. → [`..\u002F_shared\u002Fsurfaces.md`](..\u002F_shared\u002Fsurfaces.md).\n- §9 ADR table is closed against `adr\u002F` (every file has a row, every row a file). 2–4 ADRs for XS\u002FS, 5–12 for M, 10–15 for L\u002FXL; every ADR Status = `Accepted`, title in decision-form (`0003-sliding-window-with-redis.md` ✓ vs `0003-rate-limiting.md` ✗), no strawman options.\n- §10 scenarios are testable (When \u002F Then \u002F How-verify) and cite PRD §6 NFR numbers verbatim (no inventing, no rounding).\n- §11 carries a row for every `save_as_oq` decision with both owner AND due (severity literal `Open question`); never N\u002FA.\n- §1 Stakeholders + §3 actors match the CONTEXT glossary exactly (no invented `user`\u002F`admin`).\n- Step-3 read the map (or the explorer scan ran on a brownfield, or §3 has the greenfield note). Edits-log maintained. The critic ran on the post-Socratic SAD; every finding resolved or overridden.\n\nFull DoD + anti-patterns + N\u002FA logic per section + ADR-count expectations → [`.\u002Freferences\u002Fchecklist.md`](.\u002Freferences\u002Fchecklist.md). Any check fails → re-open the relevant `AskUserQuestion`, then re-check.\n\n## Anti-patterns\n\n- **An ADR for every decision** — kills the genre. Only blast-radius decisions become ADRs (5–12 for M, not 25). Conversely, missing an irreversibility under-ADRs the feature.\n- **ADR `Status: Proposed` from this skill** — it is synchronous (you decide with the user now), so Status is `Accepted`. Use `sdlc:decide-adr` for an async Proposed → Accepted flow.\n- **ADR title in problem-form** (`0003-rate-limiting.md`) or with a **strawman option** (an alternative an existing constraint already excludes) — both dilute the ADR genre and trigger the critic's F6.\n- **Inventing §10 numbers** the PRD never agreed to — cite PRD §6 NFR verbatim. **Naming a concrete stack in §2** that contradicts the repo's conventions without an Override note pointing at §11.\n- **Re-deriving the surface downstream.** architecture-design declares `target_surfaces` once; `api-forge` \u002F `complete-sequence-diagrams` \u002F `break-tasks` \u002F `plan-tests` \u002F `review-feature` read it. A skill that re-infers the surface when the SAD already declared it is the anti-pattern surfaces.md kills.\n- **Skipping the brownfield context** — guessing the layout produces a fictional §5 Container view and invented §2 Constraints. Read `architecture-map.md`; scan with `sdlc:explorer` only if it's missing\u002Fstale.\n- **Returning to a written section** — each section commits atomically; cross-section drift is the critic's job, not a re-walk. Re-opening §4 after writing §10 means you don't trust the per-section batch.\n- **Save-as-OQ without owner+due** — capture both in the follow-up; missing either downgrades to Drop with a warning, never a half-filled §11 row.\n- **Resolving critic findings unilaterally** (without `AskUserQuestion`) or **one giant end-of-pass commit** — both defeat the per-section, user-in-the-loop contract.\n- **Spilling into C4 L3\u002FL4** — out of scope; suggest a separate diagramming pass.\n\n## References & templates\n\n- [`.\u002Freferences\u002Fdraft-generation.md`](.\u002Freferences\u002Fdraft-generation.md) — Step 5: per-section sourcing for §1–§12, item-banks, the question budget, pre-Socratic hygiene.\n- [`.\u002Freferences\u002Fsocratic-loop.md`](.\u002Freferences\u002Fsocratic-loop.md) — architecture-design's delta over the shared Socratic loop (section list, decision-types incl. Surface + UI-architecture, the blast-radius gate, the §11 OQ table).\n- [`.\u002Freferences\u002Fsocratic-cadence.md`](.\u002Freferences\u002Fsocratic-cadence.md) — how to avoid question fatigue (mini-recap every 5, Recommended-first, bundle trivial defaults).\n- [`.\u002Freferences\u002Fblast-radius-heuristic.md`](.\u002Freferences\u002Fblast-radius-heuristic.md) — the 3-criteria ADR gate (irreversible \u002F multi-module \u002F legitimate alternatives), scoring, target counts.\n- [`.\u002Freferences\u002Fcritic-phase.md`](.\u002Freferences\u002Fcritic-phase.md) — Step 7 dispatch + resolution loop + pre-write backstop scans; architecture-design's delta over the shared critic (F5 floor, F6 = NFR-leak + strawman-ADR + §2-vs-repo, F1 = strategic-vector drift).\n- [`.\u002Freferences\u002Fcritic-prompt.md`](.\u002Freferences\u002Fcritic-prompt.md) — canonical agent prompt body for the Step 7 critic. 6 failure classes adapted for the SAD.\n- [`.\u002Freferences\u002Fc4-mermaid-syntax.md`](.\u002Freferences\u002Fc4-mermaid-syntax.md) — C4Context + C4Container Mermaid cheatsheet for §3\u002F§5.\n- [`.\u002Freferences\u002Fask-examples.md`](.\u002Freferences\u002Fask-examples.md) — architecture-design-specific question shapes (Surface, UI-architecture, strategic-with-ADR-spawn, blast-radius gate, Save-as-OQ follow-up, critic-finding resolution).\n- [`.\u002Freferences\u002Fchecklist.md`](.\u002Freferences\u002Fchecklist.md) — full Definition of Done + anti-patterns + N\u002FA logic + ADR count expectations.\n- [`..\u002F_shared\u002Finterview-depth.md`](..\u002F_shared\u002Finterview-depth.md) — the easy\u002Fmedium\u002Fhard dial set in step 1 (per-section question volume + autonomy).\n- [`..\u002F_shared\u002Fdiagram-presentation.md`](..\u002F_shared\u002Fdiagram-presentation.md) — how the §3\u002F§5 C4 diagrams are confirmed in prose (write → validate → describe), never as raw source.\n- [`..\u002F_shared\u002Fmermaid-check.md`](..\u002F_shared\u002Fmermaid-check.md) — validate every C4 block after writing it.\n- [`..\u002F_shared\u002Fsurfaces.md`](..\u002F_shared\u002Fsurfaces.md) — the target-surface taxonomy (C4-container-grounded); architecture-design owns the selection (§4 first decision → frontmatter `target_surfaces`), downstream reads it.\n- [`.\u002Ftemplates\u002Fsad-template.md`](.\u002Ftemplates\u002Fsad-template.md) · [`.\u002Ftemplates\u002Fadr-template.md`](.\u002Ftemplates\u002Fadr-template.md) · [`.\u002Ftemplates\u002Fc4-context.md`](.\u002Ftemplates\u002Fc4-context.md) · [`.\u002Ftemplates\u002Fc4-container.md`](.\u002Ftemplates\u002Fc4-container.md) · [`.\u002Ftemplates\u002Fdeployment.md`](.\u002Ftemplates\u002Fdeployment.md) — output scaffolds; inline comments are the per-section generation contract. (C4 syntax → [`.\u002Freferences\u002Fc4-mermaid-syntax.md`](.\u002Freferences\u002Fc4-mermaid-syntax.md).)\n",{"name":5,"model":24,"stage":25,"agents":26,"effort":29,"triggers":30,"description":7},"opus","04-05",[27,28],"explorer","critic","high",[31,32,33,34,35,36,37,38],"\u002Fsdlc:architecture-design","architecture for","design architecture for","SAD for","arc42 for","C4 context+container for","SAD для","архітектурний документ","main","2dc9bdfa5d508a04d414fb0991617e6722ec635a","modules\u002F6-sdlc\u002Fsdlc\u002Fplugin\u002Fskills\u002Farchitecture-design",13,"https:\u002F\u002Fgithub.com\u002Fgenkovich\u002Fagentic-engineering-course-public","https:\u002F\u002Ft.me\u002Fgenkovich","https:\u002F\u002Fgithub.com\u002Fgenkovich","https:\u002F\u002Ft.me\u002Fbeerphp","Beer::PHP 🍺 telegram-channel author \r\n","2026-11-12 03:03:13",{"source":8,"skillName":5,"commands":50,"prompt":60,"zipAvailable":61},[51,54,57],{"tool":52,"command":53},"npx","npx skills add genkovich\u002Fagentic-engineering-course-public --skill architecture-design",{"tool":55,"command":56},"bunx","bunx skills add genkovich\u002Fagentic-engineering-course-public --skill architecture-design",{"tool":58,"command":59},"pnpm","pnpm dlx skills add genkovich\u002Fagentic-engineering-course-public --skill architecture-design","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fgenkovich\u002Fagentic-engineering-course-public\u002Fblob\u002Fmain\u002Fmodules\u002F6-sdlc\u002Fsdlc\u002Fplugin\u002Fskills\u002Farchitecture-design\u002FSKILL.md",true,[63,69,73,77,81,85,89,93,97,101,105,109,113,117],{"path":64,"resourceType":65,"resourceTypeDesc":66,"sizeBytes":67,"sourceHtmlUrl":68},"references\u002Fask-examples.md","REFERENCE","参考文档",31273,"https:\u002F\u002Fgithub.com\u002Fgenkovich\u002Fagentic-engineering-course-public\u002Fblob\u002Fmain\u002Fmodules\u002F6-sdlc\u002Fsdlc\u002Fplugin\u002Fskills\u002Farchitecture-design\u002Freferences\u002Fask-examples.md",{"path":70,"resourceType":65,"resourceTypeDesc":66,"sizeBytes":71,"sourceHtmlUrl":72},"references\u002Fblast-radius-heuristic.md",6803,"https:\u002F\u002Fgithub.com\u002Fgenkovich\u002Fagentic-engineering-course-public\u002Fblob\u002Fmain\u002Fmodules\u002F6-sdlc\u002Fsdlc\u002Fplugin\u002Fskills\u002Farchitecture-design\u002Freferences\u002Fblast-radius-heuristic.md",{"path":74,"resourceType":65,"resourceTypeDesc":66,"sizeBytes":75,"sourceHtmlUrl":76},"references\u002Fc4-mermaid-syntax.md",8765,"https:\u002F\u002Fgithub.com\u002Fgenkovich\u002Fagentic-engineering-course-public\u002Fblob\u002Fmain\u002Fmodules\u002F6-sdlc\u002Fsdlc\u002Fplugin\u002Fskills\u002Farchitecture-design\u002Freferences\u002Fc4-mermaid-syntax.md",{"path":78,"resourceType":65,"resourceTypeDesc":66,"sizeBytes":79,"sourceHtmlUrl":80},"references\u002Fchecklist.md",11390,"https:\u002F\u002Fgithub.com\u002Fgenkovich\u002Fagentic-engineering-course-public\u002Fblob\u002Fmain\u002Fmodules\u002F6-sdlc\u002Fsdlc\u002Fplugin\u002Fskills\u002Farchitecture-design\u002Freferences\u002Fchecklist.md",{"path":82,"resourceType":65,"resourceTypeDesc":66,"sizeBytes":83,"sourceHtmlUrl":84},"references\u002Fcritic-phase.md",10854,"https:\u002F\u002Fgithub.com\u002Fgenkovich\u002Fagentic-engineering-course-public\u002Fblob\u002Fmain\u002Fmodules\u002F6-sdlc\u002Fsdlc\u002Fplugin\u002Fskills\u002Farchitecture-design\u002Freferences\u002Fcritic-phase.md",{"path":86,"resourceType":65,"resourceTypeDesc":66,"sizeBytes":87,"sourceHtmlUrl":88},"references\u002Fcritic-prompt.md",11481,"https:\u002F\u002Fgithub.com\u002Fgenkovich\u002Fagentic-engineering-course-public\u002Fblob\u002Fmain\u002Fmodules\u002F6-sdlc\u002Fsdlc\u002Fplugin\u002Fskills\u002Farchitecture-design\u002Freferences\u002Fcritic-prompt.md",{"path":90,"resourceType":65,"resourceTypeDesc":66,"sizeBytes":91,"sourceHtmlUrl":92},"references\u002Fdraft-generation.md",13968,"https:\u002F\u002Fgithub.com\u002Fgenkovich\u002Fagentic-engineering-course-public\u002Fblob\u002Fmain\u002Fmodules\u002F6-sdlc\u002Fsdlc\u002Fplugin\u002Fskills\u002Farchitecture-design\u002Freferences\u002Fdraft-generation.md",{"path":94,"resourceType":65,"resourceTypeDesc":66,"sizeBytes":95,"sourceHtmlUrl":96},"references\u002Fsocratic-cadence.md",6643,"https:\u002F\u002Fgithub.com\u002Fgenkovich\u002Fagentic-engineering-course-public\u002Fblob\u002Fmain\u002Fmodules\u002F6-sdlc\u002Fsdlc\u002Fplugin\u002Fskills\u002Farchitecture-design\u002Freferences\u002Fsocratic-cadence.md",{"path":98,"resourceType":65,"resourceTypeDesc":66,"sizeBytes":99,"sourceHtmlUrl":100},"references\u002Fsocratic-loop.md",16357,"https:\u002F\u002Fgithub.com\u002Fgenkovich\u002Fagentic-engineering-course-public\u002Fblob\u002Fmain\u002Fmodules\u002F6-sdlc\u002Fsdlc\u002Fplugin\u002Fskills\u002Farchitecture-design\u002Freferences\u002Fsocratic-loop.md",{"path":102,"resourceType":65,"resourceTypeDesc":66,"sizeBytes":103,"sourceHtmlUrl":104},"templates\u002Fadr-template.md",5159,"https:\u002F\u002Fgithub.com\u002Fgenkovich\u002Fagentic-engineering-course-public\u002Fblob\u002Fmain\u002Fmodules\u002F6-sdlc\u002Fsdlc\u002Fplugin\u002Fskills\u002Farchitecture-design\u002Ftemplates\u002Fadr-template.md",{"path":106,"resourceType":65,"resourceTypeDesc":66,"sizeBytes":107,"sourceHtmlUrl":108},"templates\u002Fc4-container.md",1035,"https:\u002F\u002Fgithub.com\u002Fgenkovich\u002Fagentic-engineering-course-public\u002Fblob\u002Fmain\u002Fmodules\u002F6-sdlc\u002Fsdlc\u002Fplugin\u002Fskills\u002Farchitecture-design\u002Ftemplates\u002Fc4-container.md",{"path":110,"resourceType":65,"resourceTypeDesc":66,"sizeBytes":111,"sourceHtmlUrl":112},"templates\u002Fc4-context.md",773,"https:\u002F\u002Fgithub.com\u002Fgenkovich\u002Fagentic-engineering-course-public\u002Fblob\u002Fmain\u002Fmodules\u002F6-sdlc\u002Fsdlc\u002Fplugin\u002Fskills\u002Farchitecture-design\u002Ftemplates\u002Fc4-context.md",{"path":114,"resourceType":65,"resourceTypeDesc":66,"sizeBytes":115,"sourceHtmlUrl":116},"templates\u002Fdeployment.md",1113,"https:\u002F\u002Fgithub.com\u002Fgenkovich\u002Fagentic-engineering-course-public\u002Fblob\u002Fmain\u002Fmodules\u002F6-sdlc\u002Fsdlc\u002Fplugin\u002Fskills\u002Farchitecture-design\u002Ftemplates\u002Fdeployment.md",{"path":118,"resourceType":65,"resourceTypeDesc":66,"sizeBytes":119,"sourceHtmlUrl":120},"templates\u002Fsad-template.md",19180,"https:\u002F\u002Fgithub.com\u002Fgenkovich\u002Fagentic-engineering-course-public\u002Fblob\u002Fmain\u002Fmodules\u002F6-sdlc\u002Fsdlc\u002Fplugin\u002Fskills\u002Farchitecture-design\u002Ftemplates\u002Fsad-template.md",[122,130,137,144,151,158],{"skillNo":123,"name":124,"nameZh":6,"description":125,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":126,"categories":127,"keywords":128,"publishedAt":129},"01M72YGBW5JKECT8WSRHK1YBCJ","release","Run the whole local release pipeline in order, stopping at each human gate. Triggers on \"run the release\", \"prepare a release\", \"\u002Frelease\", \"зроби реліз\", \"підготуй реліз\". Drives the four stages back to back — bump-version → curate-changelog → release-notes → check-docs-drift — pausing after each so the human reviews the diff before the next stage. Prepares everything in the working tree; never tags, commits, or pushes. The tag push (which fires CI) stays the human's action.","https:\u002F\u002Fgithub.com\u002Fgenkovich\u002Fagentic-engineering-course-public\u002Fblob\u002Fmain\u002Fmodules\u002F9-collaboration\u002F9.7-release-docs\u002F.claude\u002Fskills\u002Frelease\u002FSKILL.md",[],[],"2026-11-11 15:11:14",{"skillNo":131,"name":132,"nameZh":6,"description":133,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":134,"categories":135,"keywords":136,"publishedAt":129},"01M72YG87VQ89PRCYQSMNAP5RW","release-notes","Draft partner-facing release notes from the same commits as the changelog. Triggers on \"draft release notes\", \"release notes for the next version\", \"\u002Frelease-notes\", \"нотатки релізу\", \"release notes партнеру\". Same input as curate-changelog, different audience and tone: a short, benefit-first narrative for a user or partner — \"what's new for you\" — not a categorized engineer's list. Keeps only changes a user actually notices; drops internal refactors and tooling. Prints the notes to the chat to seed a GitHub Release description or a partner announcement. Writes no file.","https:\u002F\u002Fgithub.com\u002Fgenkovich\u002Fagentic-engineering-course-public\u002Fblob\u002Fmain\u002Fmodules\u002F9-collaboration\u002F9.7-release-docs\u002F.claude\u002Fskills\u002Frelease-notes\u002FSKILL.md",[],[],{"skillNo":138,"name":139,"nameZh":6,"description":140,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":141,"categories":142,"keywords":143,"publishedAt":129},"01M72YG4BXJH9R6QQZD3G8E358","curate-changelog","Curate the [Unreleased] section of docs\u002FCHANGELOG.md from git history. Triggers on \"curate the changelog\", \"update the changelog\", \"\u002Fcurate-changelog\", \"онови changelog\", \"курування журналу\". Reads git log since the last tag, FILTERS out what a reader never feels (test\u002Fci\u002Fchore\u002Fmerge), GROUPS commits about one feature into one bullet, and REWRITES technical subjects into plain language under the six Keep a Changelog categories (Added\u002FChanged\u002FDeprecated\u002F Removed\u002FFixed\u002FSecurity). The result must have FEWER lines than the raw log — that is the proof of curation, not a dump. Leaves the edit in the working tree; never commits or pushes.","https:\u002F\u002Fgithub.com\u002Fgenkovich\u002Fagentic-engineering-course-public\u002Fblob\u002Fmain\u002Fmodules\u002F9-collaboration\u002F9.7-release-docs\u002F.claude\u002Fskills\u002Fcurate-changelog\u002FSKILL.md",[],[],{"skillNo":145,"name":146,"nameZh":6,"description":147,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":148,"categories":149,"keywords":150,"publishedAt":129},"01M72YFZDKNXQ7WF9ARC5KQ4F5","codify-rule","Turn a repeated mistake into a durable, path-scoped rule in .claude\u002Frules\u002F. Triggers on \"codify this rule\", \"make a rule so this doesn't happen again\", \"\u002Fcodify-rule\", \"закодифікуй правило\", \"петля помилка-правило\". Use only when the same mistake showed up TWICE (twice = a pattern, once = noise). Names the wrong shape and the right shape with one short example of each, scopes the rule to the paths that matter, and leaves the edit in the working tree so the next agent on this repo inherits the fix. Edits only .claude\u002Frules\u002F; never commits or pushes.","https:\u002F\u002Fgithub.com\u002Fgenkovich\u002Fagentic-engineering-course-public\u002Fblob\u002Fmain\u002Fmodules\u002F9-collaboration\u002F9.7-release-docs\u002F.claude\u002Fskills\u002Fcodify-rule\u002FSKILL.md",[],[],{"skillNo":152,"name":153,"nameZh":6,"description":154,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":155,"categories":156,"keywords":157,"publishedAt":129},"01M72YFVKC19NCQDD30R1C282Q","check-docs-drift","Find and fix where docs\u002Fapi.md fell behind the code. Triggers on \"check for doc drift\", \"is the API doc up to date\", \"\u002Fcheck-docs-drift\", \"перевір дрейф документації\", \"docs drift\". Runs the deterministic scripts\u002Fcheck-docs-drift.py (parses the public NoteBook methods with ast, compares to what docs\u002Fapi.md documents — NO LLM finds the gap), reports the drift, and PROPOSES the doc edit that closes it. The gap is found by parsing; the agent writes the missing documentation in the doc's existing style. Edits only docs\u002F; never commits or pushes.","https:\u002F\u002Fgithub.com\u002Fgenkovich\u002Fagentic-engineering-course-public\u002Fblob\u002Fmain\u002Fmodules\u002F9-collaboration\u002F9.7-release-docs\u002F.claude\u002Fskills\u002Fcheck-docs-drift\u002FSKILL.md",[],[],{"skillNo":159,"name":160,"nameZh":6,"description":161,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":162,"categories":163,"keywords":164,"publishedAt":129},"01M72YFQSJ21QX4SQADQ1SQDZR","bump-version","Decide and apply the next semver for a release. Triggers on \"bump the version\", \"what version is next\", \"\u002Fbump-version\", \"простав версію\", \"яка наступна версія\". Reads the next number from the deterministic scripts\u002Fnext-version.sh (NEVER guesses it), explains in plain language WHICH part moved and why (e.g. \"MINOR, because a feat landed: filter notes by tag\"), edits the version line in pyproject.toml, and proposes the matching `git tag vX.Y.Z`. The number is decided by a rule; the agent explains and applies — the human confirms the tag. Never pushes a tag itself.","https:\u002F\u002Fgithub.com\u002Fgenkovich\u002Fagentic-engineering-course-public\u002Fblob\u002Fmain\u002Fmodules\u002F9-collaboration\u002F9.7-release-docs\u002F.claude\u002Fskills\u002Fbump-version\u002FSKILL.md",[],[]]