ADR-0021: General Typed Document Relationships¶
- Status: accepted
- Refined by: ADR-0049 (relationship CRUD realized: references/satisfies/verifies + instantiated-from), ADR-0085 (the relation vocabulary consolidated — one trace vocabulary over document relations and item links)
- Date: 2026-06-18
- Deciders: Nicolas Burri
- Relates to: ADR-0002, ADR-0020; GAP-17
Context¶
Links between documents have grown up ad hoc: version-level provenance (derived-from,
ADR-0002) and translation-of (ADR-0020). Supersession and plain references are also
needed. Modelling each separately fragments the schema and repeats work.
Decision¶
A single typed relationship mechanism between documents (and, where relevant, versions), with a closed, code-defined set of relationship types:
derived-from— version → version (provenance, ADR-0002).translation-of— document → document (ADR-0020).supersedes/superseded-by— document → document (replacement).references— document → document (a WI references an SOP).related-to— untyped association.
Relationships are directional, scope-aware (RLS), and audited. Existing provenance and translation become instances of this model; new types require code (closed set, like permissions and signature meanings), but creating relationships of an existing type is ordinary use.
Consequences¶
- The domain model gains a
RELATIONSHIPentity (type, source, target); provenance and translation are expressed through it. - Supersession becomes first-class (answering "what replaced this?").
- References improve navigation and give search/RAG more context.
- Cross-scope relationships are constrained by RLS (you can only relate documents you can see); derivation remains the controlled cross-scope mechanism (ADR-0002).
Requirements¶
Introduces the REQ-REL group (pending requirements baseline v1.2).