lore cairnet wire rollout
LORE + CAIRNET wire-up rollout
Section titled “LORE + CAIRNET wire-up rollout”Operator-facing playbook for ratifying lore_cairnet: required across the 5 governed slugs that need it. Each wave produces one consumer-repo PR (decision doc + contract flip) plus two operator-driven Pebble HTTP POSTs (LORE collection + CAIRNET agent registrations — not PRs).
The control-plane work (probe + verb + prompt + applicability) is shipped in PR sub-project-E. This runbook governs what happens after that PR merges.
Prerequisites
Section titled “Prerequisites”Before running any wave:
- Token in env.
PETROVA_PEBBLE_TOKENmust be set on the operator machine (any shell that will invokepetrova doctororpetrova lore-cairnet-status). Without it, every wired slug surfacesunreachable "PETROVA_PEBBLE_TOKEN not set"— a clear actionable signal, not a regression.Terminal window echo "${PETROVA_PEBBLE_TOKEN:+set}"# expect: set - Endpoint resolution. Default is
https://mcp.devarno.cloud. Override viaPETROVA_PEBBLE_ENDPOINTfor staging/dev. petrova doctor --self-checkpasses. Confirms spine machinery loads with the new probe.- Prompt available.
core/playbook/prompts/09-lore-cairnet-wire.mdexists in the consumer’s pinnedcore/playbook/promptssubmodule.
Phase 1 — strictly serial
Section titled “Phase 1 — strictly serial”Both waves halt at the gate-review checkpoint before Phase 2 starts.
| Wave | Repo | Why this slot |
|---|---|---|
| 1 | grace-hq | already running OpenClaw fleet; agent-emission story is most concrete; smallest blast radius for procedure validation |
| 2 | kahn-hq | agent-fleet observability tool; second-most-natural emitter; canary for batch counting |
After wave 2, gate review — answer in writing (decision doc or runbook update):
- Did the probe correctly resolve LORE 2xx + CAIRNET emission count for both slugs?
- Did
PETROVA_PEBBLE_TOKENresolution work as expected on the operator’s machine? Any surprises in the env-var chain? - Is the silent-agent threshold (0 stones in 30d) producing false-failings? If a wired slug genuinely emits intermittently, the threshold may need a window adjustment, OR the slug should be flipped to
not_applicableuntil ready. - Is the
emission_budget_30ddefault of 50 reasonable in practice? Calibrate per slug if needed (each per-slug recalibration is its own dated decision doc).
If yes to any: pause Phase 2; fix cli/src/probes/lore_cairnet.ts / cli/src/verbs/lore_cairnet_status.ts / runbook defaults; re-test against waves 1–2 evidence; then unblock Phase 2.
Phase 2 — pipelined
Section titled “Phase 2 — pipelined”Per-slug Pebble registrations are independent (no cross-slug review conflicts); consumer-repo PRs (decision doc + contract flip) likewise. These three may overlap.
| Wave | Repo |
|---|---|
| 3a | choco-hq |
| 3b | stratt-hq |
| 3c | devarno-cloud (last; superproject — 28 submodules each with potential agent emissions) |
devarno-cloud is intentionally last in Phase 2: its single registry-level wiring covers a population of submodules that may each grow their own agent stories over time. Calibrating emission_budget_30d here benefits from the wave-1/2/3a/3b observations.
Per-repo decision-doc template
Section titled “Per-repo decision-doc template”Copied verbatim into each consumer repo at wire-time (one PR per slug):
---title: Wire <repo> to LORE + CAIRNETdate: YYYY-MM-DDstatus: ratifiedmr_compliance: [MR-1, MR-7, MR-13]ranks_under: <repo's north-star intent doc>---
## Context
Per `docs/runbooks/lore-cairnet-wire-rollout.md` in petrova-codes, this repo is in wave <N>. Sub-project E's adoption decision (petrova-codes:`docs/decisions/2026-05-01-lore-cairnet-wire-adoption.md`) ratified `integrations_applicability.lore_cairnet: required` for this repo on 2026-05-01.
## Decision
Authorise the wiring per `core/playbook/prompts/09-lore-cairnet-wire.md` (Phase 0 + Phases 1–6). LORE collection slug `<lore_collection_slug>` registered in Pebble. CAIRNET agent registered as `<cairnet_agent_id>`. Initial `emission_budget_30d` set to `<N>` (calibrate after 30d of observations). Decay policy `<90d>`.
Rollback: revert this repo's contract block to `status: pending`. Pebble registrations are kept (collections + agents are append-only by convention; un-registering would invalidate historical emissions).
## Consequences
- `petrova doctor --slug=<repo>` reports `lore_cairnet: ok` once propagated.- `.petrova/contract.yaml.integrations.lore_cairnet.status` flips from `pending` to `wired` in this PR.- Operator runs `petrova lore-cairnet-status <repo>` for ad-hoc inspection.- `emission_budget_30d` recalibration is a separate dated decision doc (per slug).Cross-references
Section titled “Cross-references”- Spec:
docs/superpowers/specs/2026-05-01-petrova-lore-cairnet-spec.md - Plan:
docs/superpowers/plans/2026-05-01-petrova-lore-cairnet-plan.md - Decision:
docs/decisions/2026-05-01-lore-cairnet-wire-adoption.md - Prompt:
core/playbook/prompts/09-lore-cairnet-wire.md
Roadmap (post-wave-3c)
Section titled “Roadmap (post-wave-3c)”- Sub-project E’ candidate — active emission rate-limiter (
petrova lore-cairnet-throttle) that enforcesemission_budget_30dby rejecting writes when over-budget. Requires Pebble write-side auth + quota state. - Per-slug
emission_budget_30dcalibration — separate dated decision doc per slug, informed by 30d of observed emission patterns. - Pebble HEAD endpoints for
/api/knowledge/repos/<slug>(cheaper probe; tracked as cross-repo follow-up againstdevarno-cloud/lore). - Cross-repo Pebble extensions (e.g.
/api/cairn/stones?fleet=trueaggregations) for fleet-wide views — out of scope for sub-project E.