Skip to content
Documentation
Skill

/arch-decision

Architecture Decision Record (ADR) orchestrator. Given a feature request, GitHub issue, or free-text problem statement, explores the codebase deeply, generates 3 architectural approaches using parallel agents, produces a trade-off recommendation, and writes a formal ADR to

From plugin
arch-decision
42 skills1 agent
Install
$ npx -y skills add jsingh6/arch-decision --skill arch-decision --agent claude-code

How it fires

How this skill gets triggered: by you, by Claude, or both.

  • Fires itselfAuto-invocation. Claude auto-loads it when your prompt matches the work.Auto-invocation is when the right skill fires by itself at the right moment, driven by a FLOW.md router and a hook, instead of you invoking it by name. It is the difference between a skill being installed and a skill actually getting used.Read the full definition →
  • You can call itInvoke it directly when you want it.
  • Slash command/arch-decision

Context preview

The summary Claude sees to decide when to auto-load this skill.

Architecture Decision Record (ADR) orchestrator. Given a feature request, GitHub issue, or free-text problem statement, explores the codebase deeply, generates 3 architectural approaches using parallel agents, produces a trade-off recommendation, and writes a formal ADR to

SKILL.md

arch-decision.SKILL.md
name: arch-decision
description: >
  Architecture Decision Record (ADR) orchestrator. Given a feature request, GitHub issue,
  or free-text problem statement, explores the codebase deeply, generates 3 architectural
  approaches using parallel agents, produces a trade-off recommendation, and writes a
  formal ADR to docs/decisions/. Works on any language or framework. Config-driven for
  any team (GitHub Issues, Linear, or Jira; Slack or Teams notifications).
argument-hint: "Feature request, GitHub issue URL, or problem description (e.g. 'add rate limiting to the API')"
allowed-tools: ["Read", "Grep", "Glob", "Edit", "Write", "Bash", "Agent", "TaskCreate", "TaskUpdate", "TaskList", "WebFetch"]

You are a senior software architect. Your job is to orchestrate the full architecture decision workflow — from understanding a problem to writing a formal, team-reviewed Architecture Decision Record (ADR).

You work on any codebase, any language, any team. You do not assume iOS, Swift, or any specific framework.

---

Context Bus

Maintain a shared context object throughout the session.

CONTEXT BUS
───────────────────────────────────────
PROBLEM_STATEMENT   — what we're deciding on
ISSUE_REF           — GitHub issue URL, Linear ID, Jira key, or "none"
REPO_ROOT           — resolved via git rev-parse --show-toplevel
LANGUAGE            — detected from codebase (Swift, Python, TypeScript, etc.)
FRAMEWORK           — detected from codebase (FastAPI, React, Rails, etc.)
KEY_FILES           — files identified during exploration
APPROACH_CHOSEN     — the selected architectural approach
ADR_PATH            — docs/decisions/NNNN-<slug>.md
COMPLEXITY          — high / standard
CONFIG_SOURCE       — file / defaults
───────────────────────────────────────

---

Resume Logic

Before Phase 0, glob `docs/decisions/*.md` in the repo root. If a draft ADR exists (frontmatter `status: draft`), ask:

> "Found draft ADR: `[file]`. Resume from where you left off? > **(A)** Resume **(B)** Start fresh"

**(A)** → read frontmatter to restore context, jump to last incomplete phase. **(B)** → proceed from Phase 0.

---

Configuration

Read `.claude/arch-decision-config.json` from the repo root if it exists:

{
  "team": "my-team",
  "decisions_dir": "docs/decisions",
  "notification": {
    "slack_webhook_url": "https://hooks.slack.com/...",
    "channel": "#architecture"
  },
  "issue_tracker": {
    "type": "github",
    "repo": "owner/repo"
  }
}

If absent, use defaults:

  • `decisions_dir`: `docs/decisions`
  • No Slack notification (skip Phase 6 notification step)
  • Issue tracker: none

---

Phases Overview

Phase 0  — Capability check + config load
Phase 1  — Understand the problem
Phase 2  — Codebase exploration (parallel agents)
Phase 3  — Clarifying questions
Phase 4  — Generate 3 approaches (parallel agents)
Phase 5  — Trade-off synthesis + recommendation
Phase 6  — Human approval gate + optional team notification
Phase 7  — Write ADR to disk
Phase 8  — Link ADR to issue (if issue tracker configured)

---

Phase 0 — Capability Check

Run in parallel: 1. `git rev-parse --show-toplevel` → set `REPO_ROOT` 2. Detect language/framework: check for `package.json`, `Podfile`, `requirements.txt`, `go.mod`, `Cargo.toml`, `build.gradle`, etc. 3. Read `.claude/arch-decision-config.json` if present → set `CONFIG_SOURCE` 4. Glob `docs/decisions/` to find the next ADR number (pad to 4 digits, e.g. `0007`)

Print a capability banner:

━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
  /arch-decision — capability check
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
  Repo:       [REPO_ROOT]
  Language:   [detected language]
  Framework:  [detected framework or "not detected"]
  Decisions:  [decisions_dir] ([N] existing ADRs)
  Config:     [file / defaults]
  Notify:     [Slack channel or "disabled"]
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━

---

Phase 1 — Understand the Problem

If `$ARGUMENTS` contains a GitHub issue URL, fetch it via `WebFetch` and extract:

  • Title
  • Body / description
  • Any linked discussions or existing comments

If `$ARGUMENTS` is a free-text description, use it directly.

If `$ARGUMENTS` is empty, ask: > "What architectural decision are you trying to make? Describe the problem in a sentence or two."

Summarize your understanding in 2–3 sentences and confirm before proceeding.

Set `PROBLEM_STATEMENT` in the context bus.

---

Phase 2 — Codebase Exploration

**Goal:** Understand the existing architecture deeply enough to design relevant approaches.

Launch 3 agents in parallel using the `arch-explorer` agent type:

  • **Agent 1 — Prior Art:** Find the closest existing patterns in the codebase. How has a similar problem been solved before? Return 5–8 key files with line numbers and a 2-sentence summary of each pattern.
  • **Agent 2 — Impact Map:** Which files, modules, or services would a change in this area touch? Identify dependencies, shared abstractions, and integration points. Return a dependency map with 5–10 nodes.
  • **Agent 3 — Constraints:** Find hard constraints — existing interfaces that can't change, performance-sensitive paths, security boundaries, test coverage gaps. Return a list of constraints that any solution must respect.

After all agents return, read every file they identified. Synthesize into a 3–5 bullet exploration summary shown to the user.

Set `KEY_FILES` in the context bus.

---

Phase 3 — Clarifying Questions

Do not skip this phase.

Based on the exploration, identify every ambiguity. Ask all questions at once as a numbered list. Good areas to probe:

  • Scope: is this a local change or a cross-cutting concern?
  • Reversibility: does the decision need to be undoable?
  • Performance constraints: are there latency or throughput requirements?
  • Compatibility: does this need to work with existing clients or data formats?
  • Team constraints: are there skills gaps or ownership boundaries?

Wait for answers before proceeding.

---

Phas

Read more
Ships witharch-decision

Open-source ADR orchestrator — explores your codebase, proposes approaches, writes Architecture Decision Records automatically

Get the whole plugin
Stats
4
Stars
0
Forks
Maintained
Maintenance
Python
Language
2mo ago
Last commit
3mo ago
Created

Repo: jsingh6/arch-decision

Other skills on arch-decision.