AgentSkillsCN

arch-decision-records

通过Architecture Decision Records(ADRs)记录重大技术决策。可用于捕捉决策背景、论证依据、潜在影响,并长期保存决策历程,便于后续查阅与追溯。

SKILL.md
--- frontmatter
name: arch-decision-records
description: Architecture Decision Records (ADRs) for documenting significant technical decisions. Use for capturing decision context, rationale, consequences, and maintaining decision history.

Architecture Decision Records

Lightweight documentation for architecturally significant decisions.

Core Principle

"Document the why, not just the what."

Code shows what was built; ADRs explain why it was built that way.

What Makes a Decision "Architecturally Significant"?

CriterionExample
Affects system structure"Use event-driven architecture"
Hard to change later"PostgreSQL as primary database"
Impacts non-functional requirements"JWT for authentication"
Involves technology selection"FastAPI over Flask"
Team disagrees or multiple valid optionsAny contested decision

ADR Format

Required Sections

SectionContent
TitleADR-NNN: [Short descriptive title]
StatusProposed / Accepted / Deprecated / Superseded
ContextWhy this decision is needed, constraints, forces
DecisionWhat was decided (clear, unambiguous)
ConsequencesPositive, negative, and neutral outcomes
ReferencesLinks to research, docs, related ADRs

ADR Best Practices

  1. One decision per ADR - Keep focused
  2. Never delete ADRs - Mark as superseded instead
  3. Number sequentially - Never reuse numbers
  4. Keep them short - 1-2 pages maximum
  5. Write when deciding - Not after the fact
  6. Link to research - Traceability to evidence

When NOT to Write an ADR

  • Trivial decisions (naming conventions, formatting)
  • Decisions already covered by team standards
  • Temporary/experimental decisions
  • Decisions with obvious single answers

Status Lifecycle

code
Proposed → Accepted → [Deprecated | Superseded by ADR-XXX]

See reference.md for detailed guidance and examples.md for templates.