CRUMB a card from devarno-cloud

CAIRNET+LORE Coupling Architecture

cairnet advanced 7 min read

ELI5

CAIRNET and LORE are like two buildings connected by a one-way bridge. Information can travel from CAIRNET to LORE (when a stone is promoted), but never from LORE back to CAIRNET. A human guard stands at the bridge entrance to check that only worthy stones cross. This separation keeps LORE clean and official while letting CAIRNET be messy and experimental.

Technical Deep Dive

The Coupling Contract

Defined in atlas/campaigns/2026-04-25-cairnet-lore-coupling.md. The core architectural decision: CAIRNET ships decoupled from LORE. The only coupling is graduation — one-way, asynchronous, and human-gated.

Five Coupling Rules

RuleDescriptionImplementation
One-wayCAIRNET calls LORE; LORE never writes to CAIRNETCairnGraduationService creates LORE decision drafts; no reverse write path exists
AsynchronousGraduation is not part of the stone post/react transactionPost-react hook fires graduation opportunistically; reaction succeeds regardless
Human-gatedManual graduation requires admin/operator role; auto-graduation creates drafts onlyGraduateButton is role-gated; CairnGraduationService.auto_graduate() → draft status
Sybil-boundedAuto-graduation requires distinct-org threshold≥3 distinct reactor_org values in Fossil reactions
AuditableEvery graduation creates audit recordsAirlock audit stream + cairn_graduations_queue table

Why Decoupled?

The campaign deliberately inverted obvious sequencing — instead of building LORE’s write-path first and then CAIRNET on top, CAIRNET was built as a self-contained MVP against its own cairn_* schema:

  1. CAIRNET MVP needs nothing from LORE — posting, reacting, browsing all work independently
  2. CAIRNET generates organic signal — real-world stone quality metrics emerge before any commitment to promote them
  3. LORE’s write-path is verified independently — the Result<T> seam was validated without CAIRNET pressure
  4. Graduation is deferred until both systems prove themselves in isolation

The Graduation Edge

The only connection point between the two systems:

CAIRNET stone (cairn_stones) ──[graduate]──→ LORE decision draft (proof_decisions)
graduated_from_cairn_id FK
  • cairn_stones.graduated_to_lore_id — nullable FK pointing to the LORE decision
  • proof_decisions.graduated_from_cairn_id — nullable FK pointing back to the source stone
  • cairn_graduations_queue.lore_draft_id — tracks draft decisions pending human review

Key Terms

  • One-way coupling → CAIRNET → LORE only; LORE has no write path back to CAIRNET
  • Human-gated → Manual graduation requires airlock admin/operator role; auto-graduation creates drafts requiring human approval
  • Sybil-bounded → Auto-graduation requires Fossils from ≥3 distinct orgs
  • Graduation edge → The single connection point: cairn_stones.graduated_to_lore_idproof_decisions.graduated_from_cairn_id
  • CairnGraduationService → The pebble service implementing the one-way bridge (manual + auto paths)
  • Best-effort graduation → Auto-graduation is a post-react hook; failure does not block the reaction

Q&A

Q: Why can’t LORE write back to CAIRNET? A: LORE is the formal, curated record. If LORE could modify CAIRNET stones, it would violate CAIRNET’s informal/emergent design. The separation preserves CAIRNET’s “raw notebook” character.

Q: What happens if graduating a stone fails? A: Manual graduation returns an error to the UI. Auto-graduation silently fails (best-effort) — the reaction still succeeds, the stone just doesn’t get promoted.

Q: Can a stone be graduated twice? A: No — the graduated_to_lore_id column prevents re-graduation. Once set, the GraduateButton is disabled.

Examples

The coupling is a one-way turnstile at a museum — visitors (stones) can enter the permanent collection (LORE), but exhibits never go back to the lobby (CAIRNET). A curator (human admin) decides what enters, and the security system (Sybil check) prevents coordinated stuffing of the ballot box.

neighbors on the map