Where the same fact is stored twice

Read 2026-11-10, 07:01 to 07:20 UTC, on the hub, across /home/jay/.pi, /home/jay/ferrum and /home/jay/copilot. Nothing was changed. A duplicate store is a place that holds a fact some other place already owns.

51duplicate stores found
43deletions proposed
9proven unused today
34leads, need one more check

proven unused checked with git dates, a search for callers, and file times. lead no caller found in code, but not yet proof.

Duplicates by kind of fact

1. Work queue82. Decisions and rules83. Client facts and switches94. Money35. Deploy and version state66. Model lanes77. Helper and room run state58. Ops map5

The 10 deletions worth the most

  1. Stop writing open or closed inside ticket files. 396 files say open; the dispatcher says none are waiting. The Forgejo issue alone says if a ticket is done.
  2. Clear open-work.md. Drop its 232 ticked lines and give every remaining line an ask number (only 6 of 119 have one).
  3. Close or archive the 25 plans that still claim to be live. Seven have been paused since 10-30.
  4. Keep one copy of each client's switches inside Ferrum, not two. This already caused a silent undo on 11-10.
  5. Delete the old drafts file (clients/drafts.json, 17 stale drafts) and the FeCode code that still opens it. Drafts live in Ferrum.
  6. Delete every typed model name outside policy.json. Two places already point at an older model.
  7. Make the money skill read Ferrum instead of adding up Stripe itself. Then one number, one source.
  8. Remove the hand tables of client deals and switches from client-canon.md and ai-systems.md. Print them from Ferrum when needed.
  9. Delete docs/canon (13 guide pages nothing points to) and strip rules out of the 10 memory files.
  10. Sweep the leftovers: 950 MB of stale copies in copilot, old version marker files, three timer files for timers that no longer exist, three old map pictures, a second factory log.

Factory and agent counts on FeCode screens are owned by another helper and are not covered here. One finding passed on: the file those numbers read, pi agent/state/delivery-metrics.json, does not exist on the hub.

1. Work queue

The same piece of work is written in up to five places, and they disagree.

One ownerForgejo issues. An ask issue is the only place that says what Jay asked and whether it is done. A ticket file is only the build instructions; its open/closed state lives on its issue.

Delete

What goesStatusProof
The 'status:' line inside every ticket file (286 pi + 110 ferrum say open; dispatcher says 0 waiting)leadCounts read 11-10. Factory runner.mjs:113 still reads 'status OPEN' on a new ticket, so the reader must change first.
The 232 ticked lines in open-work.mdleadThe wake reader only looks for unticked lines (work-queue-continue.ts:8). Git keeps the history.
Every open-work line with no ask number (113 of 119)leadTurn each into an ask or drop it; the file then holds ask numbers only.
Live labels on 25 plan fileslead7 PAUSED untouched since 10-30; 10 'Status: ACTIVE' untouched since 11-07. Close or archive.
copilot ops/tickets/ (2 files)proven unusedLast commit 10-29; no caller in scripts, trigger, routines, skills, extensions or FeCode.
copilot plans/overnight-ledger.mdleadLast commit 11-04 but factory-dispatch.py:140 still opens it; remove the read first.
copilot .reconcile/ markerslead27 of 32 untouched since 11-03; no caller found in live scripts.

Stores now (11)

StoreWhat it holdsWho reads or writes it
copilot plans/open-work.md386 lines: 119 open, 232 ticked. Only 6 open lines name an ask; 40 name a ticket; 42 wait on Jay.Writers: scripts/openwork.py:11, lead-watchdog.py:14, factory-dispatch.py:375, client-report.py:117, trigger/fecode_deploy.sh:26+109, routines/daily-client.md:8, nightly-systems.md:3. Readers: pi agent/extensions/work-queue-continue.ts:8, goal.ts:838, restart.ts:403, copilot AGENTS.md:6
Forgejo issues labelled askAbout 56 open (scripts/asks.py list, 07:10Z).copilot scripts/asks.py:88; FeCode factory-board.mjs:438
pi plans/ticket-*.md505 files; 286 carry 'status: open'. 441 more in plans/closed.factory-board.mjs:59-63 and :416-433; factory runner.mjs:113; copilot asks.py:128, factory-dispatch.py:142, grade.py:44
ferrum plans/ticket-*.md117 files; 110 say open. 13 ticket numbers exist in both pi and ferrum.same factory readers (ticket 'repo:' field)
Forgejo issues labelled factoryOne issue per ticket, called 'its live status' in the code.pi factory/ticket-issue.mjs:1; factory-board.mjs:440; copilot factory-dispatch.py:342
copilot .dispatch-state.json, .dispatch-delivered.json, .dispatch-status.jsonThe dispatcher's own memory. At 07:05Z it said: 0 waiting, 210 already delivered, 10 dead.factory-dispatch.py:18,21,24. .dispatch-state.json is committed to git.
copilot plans/overnight-ledger.mdA hand list of kept tickets, last changed 11-04.factory-dispatch.py:140
copilot plan files that say they are live25 of 89 plans: 6 'Lifecycle: ACTIVE', 10 'Status: ACTIVE', 2 'IN PROGRESS', 7 'PAUSED'. See list below.People and agents reading plans/; scripts/plan-untickets.py
copilot ops/tickets/2 old ops tickets from 10-29.none found
copilot .reconcile/32 committed marker files; 27 last touched 11-03.none found in live scripts
FeCode Factory boardNot a store: it reads issues and ticket files. Its counts are owned by another helper.factory-board.mjs

Risk. Medium. The seat wakes from open-work.md and the factory admits tickets by the status line. Change the readers first, then delete.

2. Decisions and rules

A rule is written once as a decision, again as a rule, again in a memory note, again in a guide page.

One ownerThree homes, one job each: DECISIONS.md is the dated log (history only). AGENTS.md in each repo is the live rules. Skills hold how-to steps. Memory holds machine facts only (paths, ports), never rules.

Delete

What goesStatusProof
copilot docs/canon/ (13 pages)lead2 commits, last 11-03; no pointer from AGENTS.md, scripts, routines or skills. People may still read it, so not proven.
Rules inside memory files (model lanes, deploy path, voice model lines in copilot/.pi/memory/MEMORY.local.md)leadThe same facts live in policy.json, fecode_deploy.sh and ai-systems.md.
ferrum .pi/skills/writingleadpi agent/skills/writing is the fuller copy.
copilot clients/SOP.md, folded into client-canon.mdleadNo code reads it; last changed 11-07.
copilot ops/lead-to-booking.mdleadNo caller found; last changed 11-07.
Replaced entries in DECISIONS.md (22 mentions)leadMove to an archive section so only standing decisions remain.

Stores now (7)

StoreWhat it holdsWho reads or writes it
copilot plans/DECISIONS.md686 lines, 122 decisions, 22 mention being replaced. Last changed 11-07.copilot AGENTS.md:102; pi skills/seo
AGENTS.md files (13)copilot 129 lines (100 rules, changed 11-10); pi 4 files (117 lines); ferrum 8 files (445 lines).Loaded by every agent session in that folder
pi agent/skills (14) and ferrum .pi/skills (19)Two skill trees. 'writing' exists in both. 6 ferrum skills untouched since September.Agent sessions; ferrum AGENTS.md:46,53
Memory files (10)copilot/.pi/memory (4), ferrum/.pi/memory (4), pi agent/memory USER.md + project/ (2).pi agent/extensions/memory.ts
copilot ops/ guide pages (5)client-canon.md, ai-systems.md, client-cadence.md, lead-to-booking.md, monthly-client-call.md.AGENTS.md:102; routines/daily-client.md:3, weekly-client.md:2; lead-watchdog.py:282; pi skills client-delivery and seo
copilot clients/SOP.mdFulfilment steps, last changed 11-07. Overlaps client-canon and client-cadence.none found in code
copilot docs/canon/ (13 pages)'Jay's guide', last changed 11-03.Nothing points to it; AGENTS.md:102 names other files as the homes

Risk. Low to medium. Deleting a rule file is safe only after its rules are confirmed present in the owner file.

3. Client facts and switches

A client's switches are stored twice inside Ferrum and then copied by hand into copilot pages and scripts.

One ownerFerrum. Switches: one block in tenants.agent_config. Package: organizations.settings.offer_tier. Drafts: Ferrum drafts. Copilot keeps no client fact that Ferrum can answer.

Delete

What goesStatusProof
One of the two switch copies inside Ferrumleadcopilot AGENTS.md:86 records a real failure on 11-10: a one-sided edit was undone by the next profile save. Needs a product change.
The per-client on/off column in ops/ai-systems.mdleadReplace with a readout made from Ferrum on demand.
The deal table in ops/client-canon.mdleadSame: generate from offer_tier.
Typed client lists in lead-watchdog.py:85,:285leadThe same script already reads offer_tier at :305.
copilot clients/drafts.json and the FeCode code that reads itleadStill wired in FeCode; confirm no screen shows it, then remove both.
copilot clients/review-queue.jsonproven unusedOne commit 11-03, file time 11-03, zero callers anywhere searched.
copilot clients/work/state-2026-11-04.mdproven unusedOne commit 11-04, zero callers.

Stores now (11)

StoreWhat it holdsWho reads or writes it
Ferrum tenants.agent_config live blocks (setter, voice and so on)What the running product reads.52 read sites in 20+ files, for example agents/setter.py, tasks/missed_call.py, services/lead_notifications.py
Ferrum agent_config.client_profileThe saved profile. The code calls this the main record and the live blocks 'read-only fallbacks' (services/client_profile.py:3).routes/client_profile.py:105; services/client_profile.py:288,391,481; routes/ads.py:196
Ferrum organizations.settings.offer_tierWhich package a client is on.tasks/client_cadence.py:78; weekly_client_update.py:204; routes/orgs.py:785; copilot lead-watchdog.py:305
copilot ops/client-canon.mdA hand table of each client's deal and package (says it is 'stored in Ferrum').routines, AGENTS.md:102, lead-watchdog.py:282
copilot ops/ai-systems.mdA hand table of which switch is on for which client, written 11-10 01:4xZ.routines/daily-client.md:3, weekly-client.md:2
copilot scripts/lead-watchdog.py:85 and :285Client names and org ids typed into the script, two lines under a comment saying they come from the stored package.the watchdog itself
copilot clients/drafts.json17 drafts (9 pending, 7 held, 1 edited), last changed 11-07. The rules say never use it (AGENTS.md:82; pi skills/client-delivery/client-success.md:36).FeCode fecode-clients.cjs:121 via fecode-pages.cjs:889 and fecode-clients.jsx:46
copilot clients/review-queue.jsonOne commit, 11-03.none
copilot clients/work/state-2026-11-04.mdA dated snapshot of client state.none
copilot .pi/memory/MEMORY.local.mdAd account ids per client.agent memory
FeCode Clients tabNot a store: reads Ferrum (extras/clients.jsx:266 'only from Ferrum').fecode-ferrum.cjs:93

Risk. High for the Ferrum switch merge (it touches live client messaging). Low for the copilot copies.

4. Money

Two programs add up the money in two different ways.

One ownerStripe is where money events happen. Ferrum is the only book: its synced Stripe tables and the v_monthly_pnl view. Nothing else adds up revenue.

Delete

What goesStatusProof
The separate Stripe sums in cfo.pyleadMake it read Ferrum's finance routes. Jay already answered 'Read Ferrum now'.
pi agent/skills/money/run-rate.htmlleadA dated snapshot; file time 11-07.
Prices typed in ops/client-canon.mdleadRead them from Ferrum billing.

Stores now (8)

StoreWhat it holdsWho reads or writes it
StripeThe live account.Ferrum services/stripe_sync (routes/finance.py:343); pi skills/money/cfo.py:56
Ferrum stripe_balance_transactions and stripe_invoicesThe first is the stated owner of total revenue; the second of per-client revenue (services/finance_reconcile.py:19-20).routes/finance.py:251,360; services/unit_economics.py:267
Ferrum v_monthly_pnl viewMonthly profit and loss.routes/finance.py:96; services/unit_economics.py:243; finance_derive.py
pi agent/skills/money/cfo.pyReads Stripe directly and the bank tables over ssh, then does its own sums (cfo.py:66-78, :97, :148).the money skill
pi agent/skills/money/run-rate.htmlA saved page of money figures dated 11-07, kept in a skills folder.skills/money/SKILL.md:14
copilot ops/client-canon.mdMonthly price per client, typed by hand.routines
copilot plans/2026-11-09-finance.mdA live plan, not a store. Jay's answer F5: 'Read Ferrum now'.people
copilot finance filesNone found besides that plan.

Risk. Medium. Until Ferrum's books are checked against Stripe for one full month, keep cfo.py as the cross-check, then delete.

5. Deploy and version state

Which version is running is written in small marker files that nothing compares.

One ownerGit is the owner of 'what is the latest'. One marker per deployed thing says 'what is live'. The fleet health file is the one place to read both for every host.

Delete

What goesStatusProof
~/.cache/fecode-deployed.sha.bak and .brokenproven unusedNo script in copilot or pi names them; file times 11-09 and 11-08.
pi agent/state/pi-cd/ (empty)proven unusedEmpty since 11-02.
4 empty state.json.*.tmp files in pi-fleet-healthproven unusedZero bytes, dated 11-04.
copilot ops/base-fixed.jsonleadReplace the typed time with a read of the build result on Forgejo.
The 'FeCode deployed' line in open-work.mdleadThe marker file already holds it.

Stores now (10)

StoreWhat it holdsWho reads or writes it
hub ~/.cache/fecode-deployed.shaFeCode version last shipped. Read 07:09Z: 2de275be4; pi master ff40c2de9; no FeCode change between them, so it is current.copilot trigger/fecode_deploy.sh:9,15
hub ~/.cache/fecode-prev.shaThe version before, used to list shipped tickets.fecode_deploy.sh:106,110
hub ~/.cache/fecode-deployed.sha.bak and .brokenLeft over from 11-09 and 11-08.none
hub ~/.cache/cutover-deployed.shaClient sites version.copilot trigger/iron_site_deploy.sh:13
vps deployed.sha for FerrumFerrum version live.pi scripts/fleet-health.mjs:384
hub ~/.local/state/pi-fleet-health/state.jsonHealth and lag for every host.pi agent/extensions/seat/fleet.mjs:20; FeCode factory-board.mjs:398
copilot ops/base-fixed.jsonA hand-typed time: 'ferrum master was broken until then'. Changed 3 times in 2 days.copilot factory-dispatch.py:128
pi agent/state/pi-cd/Empty folder since 11-02.none
open-work.md line 'FeCode deployed <version>'Another copy of the shipped version.fecode_deploy.sh:108-109
copilot .pi/memory/MEMORY.local.mdRestates where the deploy marker lives.agent memory

Risk. Low. Only the hub was read. The other hosts' versions were not checked.

6. Model lanes

One file says it is the only place models are chosen. Seven other places also name models, and two name an older one.

One ownerpi agent/extensions/agents/policy.json. Its own first line says readers hold no second copy.

Delete

What goesStatusProof
copilot routines/models.jsonleadpolicy.json already has a schedule lane with the same model; point run.sh at it.
Model names typed in judge.ts, credential_waterfall.mjs, deliver.mjsleadTwo already disagree with policy.json (5-1 against 5-2).
The typed menu in fecode-tasks.jsx:26leadBuild the menu from policy.json.
Model lines in memory, swimlane.json and ai-systems.mdleadPoint to policy.json instead.

Stores now (10)

StoreWhat it holdsWho reads or writes it
pi agent/extensions/agents/policy.jsonEvery lane is fable-5-2 at medium effort (read 11-10; changed 11-09).agents/policy.ts:60; factory/pool.mjs:89,149; room-lane.mjs:38; ticket-submit.mjs:39; independent-review.mjs:591; room_ledger.py:87
copilot routines/models.jsonThe same model typed again for the 3 routines.copilot routines/run.sh:10
pi agent/extensions/goal/judge.ts:41-45Sonnet 5.5 and Opus 5.5 typed in code.the goal judge
pi factory/credential_waterfall.mjs:23 and deliver.mjs:221Fall back to fable-5-1, one version behind policy.json.factory rooms
FeCode fecode-tasks.jsx:26Model menu offers only Opus 5.5 and Sonnet 5.5.FeCode Tasks screen
pi agent/extensions/agents/lane-rules.jsonRules that feed policy.json. A legitimate input, not a copy.agents/lane-refresh.mjs
pi claude-pool/pool.ts:27-30Model price list. Legitimate catalogue.the pool
copilot ops/ai-systems.mdMostly client AI switches (class 3). One line names the voice model.routines
copilot .pi/memory/MEMORY.local.mdRestates 'all lanes = Fable 5.2 medium' and the voice model.agent memory
copilot ops/swimlane.jsonNames models in 3 places.render-swimlane.py

Risk. Low. The old-version fallbacks are the real hazard: a room could quietly run the wrong model.

7. Helper and room run state

Each run leaves its state in several files, and its grade in a different repo.

One ownerThe run's own folder (status.json) owns its state. copilot ops/grades.jsonl owns grades, keyed by run id. The runner's factory.log owns room history.

Delete

What goesStatusProof
copilot ops/runs/ (2 folders from 10-29)proven unusedSame age as ops/tickets; no caller found.
pi agent/logs/factory.logleadStale by a day against the runner's log; outcome.mjs still names it.
The 'status' field in meta.jsonleadstatus.json is what the 28 readers use.
pi agent/archive-hold/runs/ (888 folders)leadNo reader found; check size and age before removing.
1,503 watch outcome copiesleadKeep helper outcomes; watch runs carry little.

Stores now (10)

StoreWhat it holdsWho reads or writes it
pi agent/runs/*/status.json2,130 run folders (1,227 helper, 819 watch); 2,045 have status.json.28 readers, for example agents/run-records.ts, overseer.mjs, watcher.ts; scripts/subagent-health.py, runs-retention.py
pi agent/runs/helper-*/meta.jsonCarries its own 'status' field beside status.json.agents runner
pi agent/extensions/agents/state/outcomes/1,572 end-of-run copies (1,503 watch).agents/run-records.ts:18; digest.ts:25
pi agent/archive-hold/runs/888 older run folders.none found
/var/lib/forgejo-runner/factory-runs/factory.logRoom history, live (written 11-10).copilot factory-dispatch.py:19; room-fail-detail.py; FeCode factory-board.mjs:103
pi agent/logs/factory.logA second factory log, last written 11-09.factory/outcome.mjs:863-868
copilot ops/grades.jsonl244 grades since 11-09 (220 helper, 24 ticket).copilot scripts/grade.py:9; away-check.sh:6
pi agent/state/lane-stats.jobs.jsonlJob results used to tune lanes.agents/lane-refresh.mjs, job-lanes.mjs
pi agent/state/delivery-metrics.jsonMissing on the hub, yet FeCode reads it (factory-board.mjs:309) and scripts/delivery-metrics.mjs:351 should write it.FeCode factory numbers (owned by another helper)
copilot ops/runs/2 run folders from 10-29.none

Risk. Low. Grades and lane tuning join on run id, so never delete a run folder younger than its grade.

8. Ops map

The map is mostly right. Old pictures of it and old timer files still lie around.

One ownercopilot ops/swimlane.json, checked by its own script against the live machines.

Delete

What goesStatusProof
4 wrong entries in swimlane.jsonproven unusedThe map's own checker reports them missing on the live hosts.
copilot systemd/factory-dispatch.timer, seat-health.timer, seat-health.serviceproven unusedsystemctl on the hub: not found. open-work.md records the dispatch timers removed on all 3 hosts. Other hosts not re-read.
Three older map pictures in artifacts/leadKeep the newest render only.
The hand list of timers in swimlane.jsonleadFill it from the schedule registry so it cannot drift.

Stores now (5)

StoreWhat it holdsWho reads or writes it
copilot ops/swimlane.json52 boxes, 13 lanes, updated 11-10. Its checker (render-swimlane.py --check, run 07:05Z) tested 148 sources: 4 wrong.copilot ops/render-swimlane.py; AGENTS.md:102
The 4 wrong entriespi-factory-autosync.timer is named for hub, desktop and zephyrus but does not exist; qwen-small-rtx2000.service does not exist on desktop.
copilot artifacts/: 2026-11-03-ops-swimlane, 2026-11-09-ai-ops-swimlane, ops-swimlane, workflow-swimlane.htmlFour saved pictures of the map.people
copilot systemd/Holds factory-dispatch.timer, seat-health.timer and seat-health.service. None is installed on the hub.none
pi agent/schedules.json and agent/state/schedule-registry.jsonThe real list of scheduled jobs (40+ names).agents/schedule.ts:22; schedule-registry.mjs:110

Risk. Low.

Leftovers found on the way

WhatDetailStatus
copilot .tmp-specs/876 MB, 189 files committed to git, untouched since 11-03. Holds old copies of scripts.lead
copilot .fill-wt/76 MB, a stale full copy of the pi repo (skills, 2 old ticket files) from 11-02, not in git. Every search of copilot hits it.lead

The 25 plans that still say they are live

Exactly 6 use the words "Lifecycle: ACTIVE". The phrase "Open grill" appears in no plan file; 33 plans hold a question block and 16 of those are not closed.

Last changedLabelPlan in copilot plans/
2026-10-30PAUSED2026-10-29-factory-self-heal.md
2026-10-30PAUSED2026-10-29-forgejo-minimum.md
2026-10-30PAUSED2026-10-29-helper-seat-architecture.md
2026-10-30PAUSED2026-10-29-skool-value-max.md
2026-10-30PAUSED2026-10-29-status-grill.md
2026-10-30PAUSED2026-10-30-grill-everything.md
2026-10-30PAUSED2026-10-30-over-everything.md
2026-11-01IN PROGRESS2026-11-01-explorer-and-helpers.md
2026-11-07Status: ACTIVE2026-11-07-booking-canon.md
2026-11-07Status: ACTIVE2026-11-07-catchup.md
2026-11-09Status: ACTIVE2026-11-07-client-success.md
2026-11-07Status: ACTIVE2026-11-07-devops-bridge.md
2026-11-07Status: ACTIVE2026-11-07-error-triage.md
2026-11-07Status: ACTIVE2026-11-07-harness-gut.md
2026-11-07Status: ACTIVE2026-11-07-onboarding-canon.md
2026-11-07Status: ACTIVE2026-11-07-runtime-inventory.md
2026-11-07Status: ACTIVE2026-11-07-selfhosted-updates.md
2026-11-07Status: ACTIVE2026-11-07-sops.md
2026-11-07Lifecycle: ACTIVE2026-11-08-a client-xmas.md
2026-11-09Lifecycle: ACTIVE2026-11-09-fecode-cap.md
2026-11-09Lifecycle: ACTIVE2026-11-09-finance.md
2026-11-09Lifecycle: ACTIVE2026-11-09-loop-rules.md
2026-11-09Lifecycle: ACTIVE2026-11-09-moonshot.md
2026-11-10Lifecycle: ACTIVE2026-11-09-runtime-audit.md
2026-11-09IN PROGRESS2026-11-10-week-reflection.md

Not checked

Source: read-only pass by helper mwacdq2q for the owner ask of 2026-11-10. Dated snapshot, not a live board.