The mesh is operated from a command line and must be operable from a browser and from a model's tools, without becoming three systems. The pattern is already in the code and was unnamed: `board` serves HTTP by calling the same functions the CLI calls, holding nothing. Takes the decision 0034 said had to be taken deliberately rather than arrive with a feature: the HTTP surface is not read-only, so a browser login now carries authority over the mesh. Names the dependency by protocol — an OAuth2 identity provider — as the mesh does for AMQP, S3 and OCI. Keycloak is what fills the role; what the control plane knows is that it validates a token, and replacing the provider is a migration rather than a redesign. Says what this must not become, because it is the failure the project was started over: a kernel every module imports, 155 files of code from every context. Shared surfaces are not a shared library. Three adapters calling the same functions is not the same as logic leaving the context that owns it. And records the loop it creates. The networked surfaces depend on a module the control plane assigns, so when identity is down nobody can authenticate — including whoever is trying to fix it. The way out is the command line, which authenticates through nothing and is available to the account that owns the machine. Hence the rule: no capability exists only behind an authenticated surface, because that is a capability which disappears exactly when identity does.
7.4 KiB
02-DECISIONS
Architecture decision records — the "why" trail behind the rules in
00-META and the specifications in 03-DESIGN.
Numbered 02 because a decision precedes the design it authorises. Research concludes,
the decision is recorded here, and only then is the design written. Following the folder
numbers walks the process in the order it happens.
One file per decision, numbered, never deleted. A superseded record has its status: changed
and gains a pointer to what replaced it — its text is never edited. The reasoning that was
rejected is the expensive half to rediscover.
The records run in the order the decisions were taken, oldest first.
Every decision is a record. There is no ledger and no index file — if a decision is worth
recording it is worth a record, and if it is not worth a record it is not recorded
(ADR 0019). A "decision" small enough to be one line is
almost always a rule, and a rule belongs in
00-META/how-we-build.md, where it is enforced and keeps the
incident that earned it.
Frontmatter
---
status: proposed | accepted | superseded
date: YYYY-MM-DD # when the decision was taken, not when it was written down
deciders: name
reconstructed: true|false # true when the record was written after the fact from evidence
superseded-by: # 02-DECISIONS/NNNN-....md, when status is superseded
extends: # 02-DECISIONS/NNNN-....md, when this record widens an earlier one
---
Body
# N. Title in plain language
## Context what was true, with evidence
## Considered Options numbered, each with why it was rejected
## Decision what was decided
## Consequences what follows, including what got harder
## References commits, pull requests, knowledge-base entries, prior art
State evidence, not assertion. "Zero of 124 modules declare brain as a dependency"
outranks "the dependency rule is not followed".
Reconstructed records
Records 0001–0014 were written on 2026-08-23, after the decisions they describe. Records 0015 onward were taken as records. Those
decisions were taken in implementation rather than in a document; the records state what was
decided and the evidence it was decided from, and each carries reconstructed: true and says
so in its first lines.
A reconstructed record is not a transcript. Where the deliberation is not recoverable, the options section states what the alternatives were and why the chosen one won on the evidence available — not a discussion that did not happen. Where a date is not establishable it says so rather than guessing.
Index
A number identifies a record and never changes. Records are referenced from outside this repository — code comments, commit messages — so a number that moves invalidates them silently. Renumbering once cost 96 references across two code repositories, and that is why the numbers are now fixed.
So the folder is in creation order, and the reading order lives here. It is generated from
each record's topic: and written, because a reader looking at the folder on a forge sees the
folder rather than a command. The objection to a written index is that it drifts — which is
answered by checking it rather than by refusing to write one:
python3 00-META/checks/index.py --write regenerate
python3 00-META/checks/index.py fail if stale
What the mesh is
- 0001 — The mesh brokers capabilities; nodes host; agents think
- 0002 — Nodes communicate over a message broker, not over HTTP
- 0003 — An agent is a persistent employee, not an instance of a pool
Its tiers, from the bottom up
- 0004 — A node, and how it joins
- 0005 — The node host
- 0006 — The substrate and the control plane
- 0007 — Connectivity
- 0008 — A context owns its store, exclusively
- 0028 — The substrate supplies the control plane and nothing else
- 0029 — A network is a shape, because an action cannot be undone
- 0030 — Data outlives the mesh that declared it
- 0031 — The control plane authenticates nobody, so identity is a module
- 0033 — The substrate is a store and a broker
What runs on them, and how it gets there
- 0009 — Modules and the graph
- 0010 — Delivery
- 0024 — Model access is a provision, and a licence is a thing with a name
- 0026 — The mesh has a session of its own, and it is the node session's mechanism
- 0027 — A provision names what the consumer is coupled to, not the role it plays
- 0035 — One implementation, several surfaces, and what that costs
How it is built
- 0011 — Managed files are generated onto nodes and never edited there
- 0012 — The mesh creates no symlinks — a derived file is a copy
- 0013 — Schema and state changes are numbered migrations, in the same language as the code
- 0014 — No workspace — each module is a standalone package consuming published dependencies
- 0015 — Applications live in their own repository; the monorepo is for the mesh
- 0016 — The lab
How it is checked
- 0017 — A test defends a decision
- 0018 — A picture of a system is read from the system, never from what asked for it
How we work
- 0019 — How this repository works
- 0020 — The mesh is governed by a constitution, injected where work is decided
- 0021 — HQ is the source of the mesh constitution
- 0022 — The constitution absorbs what is already enforced
- 0023 — The approval is the checkpoint, not the second pair of hands
- 0025 — The design record is read where it is written, never copied to be found
- 0032 — The local account owns the mesh; a surface delegates to a module (superseded)
- 0034 — The local account owns the mesh, and a web application's login is not that