aidokitwiki

How to write an ADR

Audience-Contributor Status-Shipped v0.5

Purpose #

Recipe for adding a new Architecture Decision Record under .docs/docs/architecture/decisions/.

When you need one #

Per CLAUDE.md §7.5 and contributing/contribution-guide.md, file an ADR when a change touches:

You do not need one for: bug fixes, doc updates, additive content (new skill in @aidokit/base-skills, new catalog entry that fits the existing shape — though ADR-0015 is an example of when a "data" change warranted an ADR because it expanded the security surface).

Steps #

1. Pick the next number #

ls .docs/docs/architecture/decisions/ | grep -E '^[0-9]{4}-' | sort | tail -5

The next ADR is the next monotonically-increasing four-digit number. Never reuse a number, even if there's a gap.

2. Copy the template #

cp .docs/docs/architecture/decisions/0000-template.md \
   .docs/docs/architecture/decisions/00NN-short-kebab-slug.md

3. Fill in the header #

# ADR 00NN: Short title

| Field         | Value                                       |
| ------------- | ------------------------------------------- |
| Status        | Proposed                                    |
| Date          | YYYY-MM-DD                                  |
| Deciders      | Project maintainers                         |
| Supersedes    | —                                           |
| Superseded by | —                                           |
| Related ADRs  | (list)                                      |

Status starts as Proposed. On merge, the maintainer flips to Accepted (or Rejected with reasons).

4. Required sections #

The template enforces:

6. Open the PR #

Title: docs(adr): NNNN <short-slug>

Body: cite the change(s) the ADR enables (a follow-up PR may implement it; some ADRs are pure architecture decisions).

7. After acceptance #

  1. Maintainer flips status from Proposed to Accepted.
  2. If the decision deprecates a previous ADR, set Supersedes on the new ADR and Superseded by on the old one. Do not delete the old ADR.

Worked examples #

Read these to see the expected depth and tone.

Common pitfalls #