Skip to main content

adrlane

Documentation-as-code bootstrap for AI agents.

adrlane scaffolds a minimal docs/ layout and agent skills so AI tools know where to read and write project documentation. The agent decides when to update docs — there is no sync pipeline or enforcement.

Install

Install adrlane once on your machine with uv:

uv tool install adrlane

From a local checkout:

uv tool install -e .

Verify:

adrlane --help

Development checkout

Clone the repository and install dependencies:

git clone https://github.com/koradon/adrlane.git
cd adrlane
uv sync
uv run adrlane --help

Quick start

  1. Install the CLI globally (see Install).
  2. From your project repository root, scaffold docs and project-local skills:
cd /path/to/your-project
adrlane init
  1. Optional: install skills once for all projects on this machine:
adrlane skills install --global
  1. Work with your agent as usual. When docs should change, the agent uses the installed skills (see Agent workflow).

Multi-repo workspace (project root is not a single git repo):

adrlane init --workspace   # adds .adrlane/workspace.yaml for doc routing
# Then run `adrlane init` in each sub-repository for service-level docs.

Preview without writing files:

adrlane init --dry-run

Limit which agent adapters init installs:

adrlane init --agent cursor
adrlane init --agent cursor --agent claude-code
adrlane init --agent codex
adrlane init --agent agy

init and skills --local always use the current working directory — there is no --path flag.

Upgrading

init is additive: it never overwrites an existing file. After you upgrade the adrlane package, re-running init will not refresh stale docs/llm/* contracts or skills. Use upgrade for that.

# 1. Upgrade the installed CLI
uv tool upgrade adrlane

# 2. In each bootstrapped repository: refresh package-owned content
cd /path/to/your-project
adrlane upgrade

# 3. If you use global skills, refresh those too
adrlane skills upgrade --global

adrlane upgrade overwrites:

  • docs/llm/* contract files and templates
  • .adrlane/bootstrap-version
  • local agent skill files (same as skills upgrade --local)

It never touches user-owned content: docs/README.md, docs/ideas/README.md, docs/roadmap/README.md, the contents of docs/{specs,plans,adr,ideas,roadmap}, or .adrlane/workspace.yaml.

Preview: adrlane upgrade --dry-run. Details: ADR 0005.

Commands

Command Description
adrlane init Bootstrap docs/ and install agent skills in the current repository
adrlane init --dry-run Show planned bootstrap actions without writing files
adrlane init --agent <name> Limit adapters (cursor, claude-code, codex, agy; repeatable)
adrlane init --workspace Bootstrap with multi-repo doc routing config
adrlane skills install --global Install skills in ~/.cursor/skills/, ~/.claude/skills/, ~/.codex/skills/ and ~/.gemini/config/skills/
adrlane skills install --local Install skills in the current repository (skips existing files)
adrlane skills upgrade --global Overwrite global skills with the current package version
adrlane skills upgrade --local Overwrite local skills in the current repository
adrlane upgrade Refresh docs/llm/* contract files, .adrlane/bootstrap-version, and local agent skills after upgrading the adrlane package
adrlane upgrade --dry-run Show planned upgrade actions without writing files
adrlane upgrade --agent <name> Limit which agent adapters get their skills refreshed (repeatable)
adrlane doctor Report docs/agent-adapter drift (informational only, never fails)

Agent workflow

adrlane does not detect documentation gaps, schedule updates, or write docs on its own. The agent decides when documentation needs updating during normal development.

Typical loop:

  1. Developer installs adrlane and runs adrlane init once per repository.
  2. Developer works with Cursor or Claude Code as usual.
  3. When the agent judges that behavior, decisions, or structure should be recorded, it uses the installed skills and docs/llm/* to create or patch files under docs/.
  4. Developer reviews with git diff and commits normally.

Skills are thin adapters; the contract is docs/llm/AGENT_PROTOCOL.md and docs/llm/DECISION_RULES.md.

Documentation model

init scaffolds a minimal core that grows with the project:

Path Purpose
docs/specs/ What the system should do
docs/plans/ How to implement a spec
docs/adr/ Why significant decisions were made
docs/ideas/ Early concepts that may be promoted to specs
docs/roadmap/ Now / Next / Later horizons
docs/llm/ Agent contract, decision rules, and templates

Templates live in docs/llm/templates/. Documents use markdown sections (## Status, ## Related) — not YAML frontmatter.

When the project gains new documentation needs (runbooks, API reference, CLI docs), the agent adds new folders under docs/ and updates docs/README.md. init does not predict project type.

One exception grows outside that minimal core on request rather than by default: the adrlane-write-architecture-overview skill creates or refreshes a single docs/architecture.md — a whole-system overview with diagrams — when asked, or proactively after a change that alters module boundaries, execution flow, or requirements to run.

Release history stays in Git and release tooling — not in docs/.

Agent skills

By default, init installs seven skills for every supported agent:

Skill Role
adrlane-dev-context Ambient — read specs before coding; propose ADRs after significant decisions
adrlane-write-idea Write or update ideas
adrlane-write-spec Write or update specs (and Gherkin .feature files)
adrlane-write-plan Write or update implementation plans
adrlane-write-adr Document architectural decisions
adrlane-write-architecture-overview Create or refresh docs/architecture.md, the whole-system overview
adrlane-workspace-routing Route docs to project or sub-repo trees (when .adrlane/workspace.yaml exists)

Project-local (default via init): .cursor/skills/, .claude/skills/, .codex/skills/ and .agents/skills/ in the repository.

Global (optional via skills install --global): same skills in your home directory, shared across all projects.

Codex CLI scans both: <repo>/.codex/skills as a project-local skill root, and $CODEX_HOME/skills (default ~/.codex/skills) as the user-level one. The same .codex/skills prefix therefore serves both scopes.

Antigravity CLI (agy) scans <workspace>/.agents/skills as its project-local skill root, but a different, unrelated global root: ~/.gemini/config/skills. Its adapter installs into .agents/skills for --local and .gemini/config/skills for --global — see ADR 0009.

Skills are thin adapters; the canonical contract lives in docs/llm/AGENT_PROTOCOL.md and docs/llm/DECISION_RULES.md.

Multi-repo workspace

Use this when the Cursor workspace root is not a single git repository — for example a folder that contains several independent repos plus shared project docs.

Setup

cd /path/to/project-root

# Project-level docs + routing config + skills
adrlane init --workspace

# Service-level docs in each repository
cd repository1 && adrlane init
cd ../repository2 && adrlane init

Open the project root in Cursor so routing applies. Optionally install skills globally once: adrlane skills install --global.

Layouts

Flat — repositories are direct children of the project root. No repo_roots needed:

project/
  docs/                 ← cross-cutting ADRs, specs, roadmap
  repository1/docs/     ← service-specific docs
  repository2/docs/

Grouped — repositories live under category folders. Uncomment and edit repo_roots in .adrlane/workspace.yaml:

project/
  docs/
  services/order-service/docs/
  frontends/checkout-fe/docs/
project_docs: docs
repo_roots:
  - services
  - frontends

How routing works

The adrlane-workspace-routing skill (active when .adrlane/workspace.yaml exists) sends documentation to:

Scope Location Examples
Project docs/ at project root Platform ADRs, cross-service conventions
Service <repo>/docs/ API specs, service-internal decisions

The other adrlane-write-* skills follow the resolved path automatically. Link project and service docs in ## Related.

Contributing

Run tests:

uv run pytest

Install pre-commit hooks:

uv run pre-commit install
uv run pre-commit run --all-files

Dependency management:

uv add <package>          # runtime dependency
uv add --dev <package>    # dev dependency
uv lock                   # refresh lockfile after manual pyproject edits

License

AGPL-3.0-or-later. See LICENSE.

Metadata

Release files for adrlane 0.5.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for adrlane 0.5.2
File Size Uploaded Provenance
adrlane-0.5.2.tar.gz 34.2 kB With provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for adrlane 0.5.2
File Interpreter ABI Platform
adrlane-0.5.2-py3-none-any.whl Python 3 none any Details

Total release size: 85.5 kB

Release files / adrlane-0.5.2.tar.gz

Download URL adrlane-0.5.2.tar.gz
Size 34.2 kB
Tags Source
SHA-256 checksum
How to use checksums
9a1fd07164ce7a32e23eae58dd8c848b8649718a9f9d490eb40768aeed00ec26
BLAKE2b-256 checksum
How to use checksums
ba60fb68d0dfe226fb88c3f8dd45752e12a77f7e662aeb17cc7262422228d38e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 16, 2026.

Transparency log

Release files / adrlane-0.5.2-py3-none-any.whl

Download URL adrlane-0.5.2-py3-none-any.whl
Size 51.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
6c33dda232aafeab8959f9695761a71257fbd0c874e0bd0a828bb3d7bf97c0f0
BLAKE2b-256 checksum
How to use checksums
02e1b82a12f2d9d1c39060ee302f468a415d8da3685a61c0cd212f9785bbd4e6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 16, 2026.

Transparency log

Security for adrlane 0.5.2

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

All 2 files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for adrlane-0.5.2.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 16, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page