Adr Writing logo

Adr Writing

OrganizationPopular
marmelab
adr-writing

Architecture Decision Record format and rules for the developer agent. Load when the implementation introduces a structural decision worth remembering 6 months later — new pattern, new dependency, deliberate departure from convention, non-obvious schema choice. Skip for naming and file-layout micro-choices. No ADR is the default.

Overview

Publishermarmelab
Repositoryatomic-crm
Skill nameadr-writing
Stars
1.4K
Forks
860
Bundled files
Instructions only
LicenseMIT
Links
  • Markdown instructions

    A SKILL.md file the model loads on demand, so it only costs tokens when a request actually matches.

  • Works with any LLM

    AI skills are plain Markdown, not provider-specific code, so this works with GPT, Claude, Gemini, Grok, or a local model.

  • Self-contained

    Everything the model needs lives in the instructions — no extra files to sync.

  • Open source

    Published by marmelab on GitHub. Read the source before you install it.

Installation

Install the Adr Writing AI skill in TypingMind to use it with any LLM, or drop it into another agent that reads SKILL.md.

1

Install in TypingMind

TypingMind installs a skill straight from its GitHub folder — it reads SKILL.md, bundles the resource files, and stores the result locally.

  1. Open the app and go to Plugins → Skills.
  2. Choose "Install from GitHub".
  3. Paste the skill folder URL below and confirm.
    https://github.com/marmelab/atomic-crm/tree/main/.claude/skills/adr-writing
  4. Enable the skill in any chat where you want it available.
Plugins → Skills → Add skill → From GitHub URL, then paste the folder URL and press Continue.
2

Install in another agent

Any agent that reads the Agent Skills format can use this skill — copy the folder into that agent's skills directory.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/marmelab/atomic-crm.git /tmp/atomic-crm
mkdir -p .claude/skills
cp -r /tmp/atomic-crm/.claude/skills/adr-writing .claude/skills/adr-writing
Restart Claude Code after copying so it picks up the new skill.

Use it in TypingMind

Enable Adr Writing in any TypingMind chat and the model takes it from there. Its name and description sit in the system prompt, and the moment a request matches, the model loads the full instructions itself — you never invoke it by hand, and it costs no tokens until it is actually used.

The model loads Adr Writing on its own as soon as a request matches it.

Works with any AI model

AI skills are plain Markdown instructions rather than provider-specific code, so Adr Writing is not tied to the model it was written for. Install it once in TypingMind and use it with GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama, or a local model you run yourself — all on your own API keys.

  • Loaded only when it is needed

    The system prompt carries just the name and description. The instructions are fetched on the first matching request, so an idle skill costs nothing.

  • Switch models mid-chat

    Because the skill is instructions rather than code, changing model does not break it — the next model reads the same SKILL.md.

Skill instructions

This is the SKILL.md content the model loads. Read it before installing — a skill is instructions your model will follow.

ADR — Architecture Decision Record

Load only when you have a structural decision to record. Default behaviour for any developer is no ADR.

When to write one

Yes:

  • New pattern introduced into the codebase (not just used once — recurring).
  • New runtime dependency (npm package, new Supabase extension, external service).
  • Deliberate departure from an existing convention.
  • Non-obvious schema choice (denormalisation, computed column, soft-delete strategy).

No:

  • File naming, folder placement.
  • A bug fix or refactor with no structural impact.
  • Style decisions already captured by lint/prettier.

File naming — namespaced by session + ticket

Path: <WORKTREE_PATH>/adr/ADR-<SESSION_SHORT_ID>-<TASK-XXX>-<slug>.md

  • <SESSION_SHORT_ID> is your session id — the prefix of your BRANCH_NAME before the / (e.g. BRANCH_NAME=58e4ec51/TASK-004 → 58e4ec51). It scopes the ADR to this session.
  • <TASK-XXX> is the literal ticket id. Together with the session id it forms the namespace — there is no separate sequence number (e.g. ADR-58e4ec51-TASK-004-supabase-rls-strategy.md).
  • <slug> is kebab-case, ASCII, ≤ 40 chars.
  • One ADR per ticket is the common case. If the same ticket genuinely needs two ADRs, the distinct slugs keep them apart.

Why the session+ticket namespace: in a wave, N developers run in parallel on worktrees branched from the same base. A monotonically-incremented ADR-NNN-… scheme makes every worker independently pick the same next number (e.g. all land on ADR-003); different slugs hide the collision from git merge, so duplicate numbers land in $CLAUDE_PROJECT_DIR/adr/ silently. <TASK-XXX> removes the intra-wave collision; the <SESSION_SHORT_ID> prefix removes the cross-session one — ticket numbering restarts at TASK-001 each session, so two sessions both producing a TASK-004 would otherwise overwrite each other's ADR in the shared $CLAUDE_PROJECT_DIR/adr/.

Source-code reference

One comment at the most representative line of the change, pointing at the ADR you just wrote:

  • TS/JS/CSS: // See adr/ADR-<SESSION_SHORT_ID>-<TASK-XXX>-<slug>.md
  • Python/SQL/shell: # See adr/ADR-<SESSION_SHORT_ID>-<TASK-XXX>-<slug>.md

No need for more than one reference; reviewers follow the link.

Commit

The ADR + its reference comment go in the same commit as the code they describe (WORKFLOW step 3). Subject:

docs(TASK-XXX): ADR-<SESSION_SHORT_ID>-<TASK-XXX> <title>

Reviewers see the ADR alongside the implementation.

Template (≤ 25 lines)

markdown
# ADR-<SESSION_SHORT_ID>-<TASK-XXX> — <decision title>

- **Date**: YYYY-MM-DD
- **Ticket**: TASK-XXX
- **Session**: <SESSION_SHORT_ID>

## Context

2–4 lines on what made this decision necessary.

## Decision

1–3 lines on what was chosen.

## Consequences

- Up to 4 bullets: what this enables, costs, locks in.

## Alternatives considered

- Up to 3, one line each, with reason for rejection. If none were captured, write `- _Not captured at decision time._` — never invent.

Keep it short. An ADR longer than 25 lines is a sign that the decision either belongs in code comments or is actually several decisions that should be split.

Red Flags

  • An ADR written for a naming, file-placement, or pure-style choice (no ADR is the default).
  • A monotonic ADR-NNN-… filename instead of the ADR-<SESSION_SHORT_ID>-<TASK-XXX>-<slug> namespace parallel workers collide on the same number.
  • An ADR file written outside the worktree, or committed separately from the code it describes.
  • Alternatives considered invented after the fact instead of - _Not captured at decision time._.
  • An ADR past 25 lines likely belongs in code comments or is several decisions.

Verification

  • The change is a genuine structural decision (new pattern, dependency, convention departure, non-obvious schema) otherwise no ADR.
  • Filename is <WORKTREE_PATH>/adr/ADR-<SESSION_SHORT_ID>-<TASK-XXX>-<slug>.md.
  • Exactly one source-code reference comment points at the ADR.
  • ADR + reference comment are in the same commit as the code, with the docs(TASK-XXX): subject.
  • Body follows the template and is ≤ 25 lines.

Frequently asked questions

What does the Adr Writing AI skill do?

Architecture Decision Record format and rules for the developer agent. Load when the implementation introduces a structural decision worth remembering 6 months later — new pattern, new dependency, deliberate departure from convention, non-obvious schema choice. Skip for naming and file-layout micro-choices. No ADR is the default.

Why use Adr Writing on TypingMind?

Because you install it once and use it with any model. Adr Writing is plain Markdown rather than provider-specific code, so the same skill runs on GPT-5, Claude, Gemini, Grok, or a local model — and you can switch model mid-chat without it breaking. TypingMind runs on your own API keys, so you pay providers directly instead of a per-seat subscription, and your skills and chats stay in your own storage.

How do I install Adr Writing in TypingMind?

Open Plugins → Skills → Install from GitHub in TypingMind and paste https://github.com/marmelab/atomic-crm/tree/main/.claude/skills/adr-writing. TypingMind reads its SKILL.md and installs it as a skill you can enable per chat.

Which AI models can use Adr Writing?

Any model you connect in TypingMind. AI skills are plain Markdown instructions rather than provider-specific code, so GPT, Claude, Gemini, Grok, and local models can all load this skill when a request matches it.

How many AI models can I use with Adr Writing?

As many as you like. As long as a model supports skills, you can use Adr Writing with it — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama and more — all on TypingMind with your own API keys.

Is the Adr Writing AI skill free?

Yes. It is published on GitHub by marmelab under the MIT license. You only pay your own AI provider for the tokens you use.

What are AI skills?

An AI skill is a reusable instruction bundle that teaches an AI model how to do one specific task. It follows the open Agent Skills format: a SKILL.md file with a name and description, plus any scripts, templates or reference files the model may need. The model reads the instructions only when your request matches the skill, so an installed skill costs nothing until it is used.

How are AI skills different from plugins or MCP servers?

A plugin or MCP server gives a model new tools to call — code that runs somewhere and returns a result. An AI skill gives the model knowledge and process instead: how to approach a task, which steps to follow, what good output looks like. Skills are plain Markdown, so they need no server, no API key and no runtime, and they work with any model.

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇