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.
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 map5The 10 deletions worth the most
- 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.
- Clear open-work.md. Drop its 232 ticked lines and give every remaining line an ask number (only 6 of 119 have one).
- Close or archive the 25 plans that still claim to be live. Seven have been paused since 10-30.
- Keep one copy of each client's switches inside Ferrum, not two. This already caused a silent undo on 11-10.
- Delete the old drafts file (clients/drafts.json, 17 stale drafts) and the FeCode code that still opens it. Drafts live in Ferrum.
- Delete every typed model name outside policy.json. Two places already point at an older model.
- Make the money skill read Ferrum instead of adding up Stripe itself. Then one number, one source.
- Remove the hand tables of client deals and switches from client-canon.md and ai-systems.md. Print them from Ferrum when needed.
- Delete docs/canon (13 guide pages nothing points to) and strip rules out of the 10 memory files.
- 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.
Delete
| What goes | Status | Proof |
|---|---|---|
| The 'status:' line inside every ticket file (286 pi + 110 ferrum say open; dispatcher says 0 waiting) | lead | Counts 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.md | lead | The 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) | lead | Turn each into an ask or drop it; the file then holds ask numbers only. |
| Live labels on 25 plan files | lead | 7 PAUSED untouched since 10-30; 10 'Status: ACTIVE' untouched since 11-07. Close or archive. |
| copilot ops/tickets/ (2 files) | proven unused | Last commit 10-29; no caller in scripts, trigger, routines, skills, extensions or FeCode. |
| copilot plans/overnight-ledger.md | lead | Last commit 11-04 but factory-dispatch.py:140 still opens it; remove the read first. |
| copilot .reconcile/ markers | lead | 27 of 32 untouched since 11-03; no caller found in live scripts. |
Stores now (11)
| Store | What it holds | Who reads or writes it |
|---|---|---|
| copilot plans/open-work.md | 386 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 ask | About 56 open (scripts/asks.py list, 07:10Z). | copilot scripts/asks.py:88; FeCode factory-board.mjs:438 |
| pi plans/ticket-*.md | 505 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-*.md | 117 files; 110 say open. 13 ticket numbers exist in both pi and ferrum. | same factory readers (ticket 'repo:' field) |
| Forgejo issues labelled factory | One 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.json | The 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.md | A hand list of kept tickets, last changed 11-04. | factory-dispatch.py:140 |
| copilot plan files that say they are live | 25 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 board | Not 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.
Delete
| What goes | Status | Proof |
|---|---|---|
| copilot docs/canon/ (13 pages) | lead | 2 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) | lead | The same facts live in policy.json, fecode_deploy.sh and ai-systems.md. |
| ferrum .pi/skills/writing | lead | pi agent/skills/writing is the fuller copy. |
| copilot clients/SOP.md, folded into client-canon.md | lead | No code reads it; last changed 11-07. |
| copilot ops/lead-to-booking.md | lead | No caller found; last changed 11-07. |
| Replaced entries in DECISIONS.md (22 mentions) | lead | Move to an archive section so only standing decisions remain. |
Stores now (7)
| Store | What it holds | Who reads or writes it |
|---|---|---|
| copilot plans/DECISIONS.md | 686 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.md | Fulfilment 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.
Delete
| What goes | Status | Proof |
|---|---|---|
| One of the two switch copies inside Ferrum | lead | copilot 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.md | lead | Replace with a readout made from Ferrum on demand. |
| The deal table in ops/client-canon.md | lead | Same: generate from offer_tier. |
| Typed client lists in lead-watchdog.py:85,:285 | lead | The same script already reads offer_tier at :305. |
| copilot clients/drafts.json and the FeCode code that reads it | lead | Still wired in FeCode; confirm no screen shows it, then remove both. |
| copilot clients/review-queue.json | proven unused | One commit 11-03, file time 11-03, zero callers anywhere searched. |
| copilot clients/work/state-2026-11-04.md | proven unused | One commit 11-04, zero callers. |
Stores now (11)
| Store | What it holds | Who 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_profile | The 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_tier | Which 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.md | A 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.md | A 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 :285 | Client 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.json | 17 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.json | One commit, 11-03. | none |
| copilot clients/work/state-2026-11-04.md | A dated snapshot of client state. | none |
| copilot .pi/memory/MEMORY.local.md | Ad account ids per client. | agent memory |
| FeCode Clients tab | Not 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.
Delete
| What goes | Status | Proof |
|---|---|---|
| The separate Stripe sums in cfo.py | lead | Make it read Ferrum's finance routes. Jay already answered 'Read Ferrum now'. |
| pi agent/skills/money/run-rate.html | lead | A dated snapshot; file time 11-07. |
| Prices typed in ops/client-canon.md | lead | Read them from Ferrum billing. |
Stores now (8)
| Store | What it holds | Who reads or writes it |
|---|---|---|
| Stripe | The live account. | Ferrum services/stripe_sync (routes/finance.py:343); pi skills/money/cfo.py:56 |
| Ferrum stripe_balance_transactions and stripe_invoices | The 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 view | Monthly profit and loss. | routes/finance.py:96; services/unit_economics.py:243; finance_derive.py |
| pi agent/skills/money/cfo.py | Reads 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.html | A saved page of money figures dated 11-07, kept in a skills folder. | skills/money/SKILL.md:14 |
| copilot ops/client-canon.md | Monthly price per client, typed by hand. | routines |
| copilot plans/2026-11-09-finance.md | A live plan, not a store. Jay's answer F5: 'Read Ferrum now'. | people |
| copilot finance files | None 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.
Delete
| What goes | Status | Proof |
|---|---|---|
| ~/.cache/fecode-deployed.sha.bak and .broken | proven unused | No script in copilot or pi names them; file times 11-09 and 11-08. |
| pi agent/state/pi-cd/ (empty) | proven unused | Empty since 11-02. |
| 4 empty state.json.*.tmp files in pi-fleet-health | proven unused | Zero bytes, dated 11-04. |
| copilot ops/base-fixed.json | lead | Replace the typed time with a read of the build result on Forgejo. |
| The 'FeCode deployed' line in open-work.md | lead | The marker file already holds it. |
Stores now (10)
| Store | What it holds | Who reads or writes it |
|---|---|---|
| hub ~/.cache/fecode-deployed.sha | FeCode 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.sha | The version before, used to list shipped tickets. | fecode_deploy.sh:106,110 |
| hub ~/.cache/fecode-deployed.sha.bak and .broken | Left over from 11-09 and 11-08. | none |
| hub ~/.cache/cutover-deployed.sha | Client sites version. | copilot trigger/iron_site_deploy.sh:13 |
| vps deployed.sha for Ferrum | Ferrum version live. | pi scripts/fleet-health.mjs:384 |
| hub ~/.local/state/pi-fleet-health/state.json | Health and lag for every host. | pi agent/extensions/seat/fleet.mjs:20; FeCode factory-board.mjs:398 |
| copilot ops/base-fixed.json | A 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.md | Restates 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.
Delete
| What goes | Status | Proof |
|---|---|---|
| copilot routines/models.json | lead | policy.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.mjs | lead | Two already disagree with policy.json (5-1 against 5-2). |
| The typed menu in fecode-tasks.jsx:26 | lead | Build the menu from policy.json. |
| Model lines in memory, swimlane.json and ai-systems.md | lead | Point to policy.json instead. |
Stores now (10)
| Store | What it holds | Who reads or writes it |
|---|---|---|
| pi agent/extensions/agents/policy.json | Every 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.json | The same model typed again for the 3 routines. | copilot routines/run.sh:10 |
| pi agent/extensions/goal/judge.ts:41-45 | Sonnet 5.5 and Opus 5.5 typed in code. | the goal judge |
| pi factory/credential_waterfall.mjs:23 and deliver.mjs:221 | Fall back to fable-5-1, one version behind policy.json. | factory rooms |
| FeCode fecode-tasks.jsx:26 | Model menu offers only Opus 5.5 and Sonnet 5.5. | FeCode Tasks screen |
| pi agent/extensions/agents/lane-rules.json | Rules that feed policy.json. A legitimate input, not a copy. | agents/lane-refresh.mjs |
| pi claude-pool/pool.ts:27-30 | Model price list. Legitimate catalogue. | the pool |
| copilot ops/ai-systems.md | Mostly client AI switches (class 3). One line names the voice model. | routines |
| copilot .pi/memory/MEMORY.local.md | Restates 'all lanes = Fable 5.2 medium' and the voice model. | agent memory |
| copilot ops/swimlane.json | Names 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.
Delete
| What goes | Status | Proof |
|---|---|---|
| copilot ops/runs/ (2 folders from 10-29) | proven unused | Same age as ops/tickets; no caller found. |
| pi agent/logs/factory.log | lead | Stale by a day against the runner's log; outcome.mjs still names it. |
| The 'status' field in meta.json | lead | status.json is what the 28 readers use. |
| pi agent/archive-hold/runs/ (888 folders) | lead | No reader found; check size and age before removing. |
| 1,503 watch outcome copies | lead | Keep helper outcomes; watch runs carry little. |
Stores now (10)
| Store | What it holds | Who reads or writes it |
|---|---|---|
| pi agent/runs/*/status.json | 2,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.json | Carries 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.log | Room history, live (written 11-10). | copilot factory-dispatch.py:19; room-fail-detail.py; FeCode factory-board.mjs:103 |
| pi agent/logs/factory.log | A second factory log, last written 11-09. | factory/outcome.mjs:863-868 |
| copilot ops/grades.jsonl | 244 grades since 11-09 (220 helper, 24 ticket). | copilot scripts/grade.py:9; away-check.sh:6 |
| pi agent/state/lane-stats.jobs.jsonl | Job results used to tune lanes. | agents/lane-refresh.mjs, job-lanes.mjs |
| pi agent/state/delivery-metrics.json | Missing 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.
Delete
| What goes | Status | Proof |
|---|---|---|
| 4 wrong entries in swimlane.json | proven unused | The map's own checker reports them missing on the live hosts. |
| copilot systemd/factory-dispatch.timer, seat-health.timer, seat-health.service | proven unused | systemctl 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/ | lead | Keep the newest render only. |
| The hand list of timers in swimlane.json | lead | Fill it from the schedule registry so it cannot drift. |
Stores now (5)
| Store | What it holds | Who reads or writes it |
|---|---|---|
| copilot ops/swimlane.json | 52 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 entries | pi-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.html | Four 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.json | The real list of scheduled jobs (40+ names). | agents/schedule.ts:22; schedule-registry.mjs:110 |
Risk. Low.
Leftovers found on the way
| What | Detail | Status |
|---|---|---|
| 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 changed | Label | Plan in copilot plans/ |
|---|---|---|
| 2026-10-30 | PAUSED | 2026-10-29-factory-self-heal.md |
| 2026-10-30 | PAUSED | 2026-10-29-forgejo-minimum.md |
| 2026-10-30 | PAUSED | 2026-10-29-helper-seat-architecture.md |
| 2026-10-30 | PAUSED | 2026-10-29-skool-value-max.md |
| 2026-10-30 | PAUSED | 2026-10-29-status-grill.md |
| 2026-10-30 | PAUSED | 2026-10-30-grill-everything.md |
| 2026-10-30 | PAUSED | 2026-10-30-over-everything.md |
| 2026-11-01 | IN PROGRESS | 2026-11-01-explorer-and-helpers.md |
| 2026-11-07 | Status: ACTIVE | 2026-11-07-booking-canon.md |
| 2026-11-07 | Status: ACTIVE | 2026-11-07-catchup.md |
| 2026-11-09 | Status: ACTIVE | 2026-11-07-client-success.md |
| 2026-11-07 | Status: ACTIVE | 2026-11-07-devops-bridge.md |
| 2026-11-07 | Status: ACTIVE | 2026-11-07-error-triage.md |
| 2026-11-07 | Status: ACTIVE | 2026-11-07-harness-gut.md |
| 2026-11-07 | Status: ACTIVE | 2026-11-07-onboarding-canon.md |
| 2026-11-07 | Status: ACTIVE | 2026-11-07-runtime-inventory.md |
| 2026-11-07 | Status: ACTIVE | 2026-11-07-selfhosted-updates.md |
| 2026-11-07 | Status: ACTIVE | 2026-11-07-sops.md |
| 2026-11-07 | Lifecycle: ACTIVE | 2026-11-08-a client-xmas.md |
| 2026-11-09 | Lifecycle: ACTIVE | 2026-11-09-fecode-cap.md |
| 2026-11-09 | Lifecycle: ACTIVE | 2026-11-09-finance.md |
| 2026-11-09 | Lifecycle: ACTIVE | 2026-11-09-loop-rules.md |
| 2026-11-09 | Lifecycle: ACTIVE | 2026-11-09-moonshot.md |
| 2026-11-10 | Lifecycle: ACTIVE | 2026-11-09-runtime-audit.md |
| 2026-11-09 | IN PROGRESS | 2026-11-10-week-reflection.md |
Not checked
- Only the hub was read. Versions and timers on desktop, zephyrus and vps were not re-read (the ops map checker did reach them for its 4 wrong entries).
- FeCode's money screen calls a Ferrum address, /finance/summary (fecode-ferrum.cjs:95). No route with that name was found in the local Ferrum code. Not resolved.
- The open ask count (about 56) is one read of scripts/asks.py list at 07:10Z.
- No secrets, environment files or host config files were read. pi agent/models.json and settings.json were not opened.
- 'Lead' means no caller was found in code. It is not proof that nobody uses the file.
Source: read-only pass by helper mwacdq2q for the owner ask of 2026-11-10. Dated snapshot, not a live board.