RepoOps
Open the app
07 / Memory and the brain

Tell an unmeasured brain from an unhealthy one

Brain health scores a repository's brain on four dimensions and averages only the ones it could measure. A dimension with nothing behind it shows a dash, not a zero, so a new install reads as unmeasured rather than as failing.

Last updated

Watch it

30.1 s, captions on. Narration: Microsoft Zira Desktop (provisional voice; an approved narration source is pending).Transcript
Read the narration
  1. 0:00 A new brain scored twenty-five.
  2. 0:02 Nothing had been measured yet.
  3. 0:06 Average only what you measured.
  4. 0:08 A dimension with no data reports a dash, not zero.
  5. 0:13 Four sub-scores, and the composite says how many it covered.
  6. 0:17 Expired proposals are excluded, not rejections.
  7. 0:23 A dash is a question, not a grade.
  8. 0:26 Fix the worst measured score.

Synthetic example. Read the guide

1

How to

At least one tracked repository. Nothing else has to run for the four sub-scores; Drift moves once a citation-rot scan has run.

  1. Open Memory, then the Wiki tab, and find Brain health.

    Pick the repository and a trend window of 14, 30 or 60 days in the card's header. Changing either reads again without changing anything.

  2. Read Composite with its count.

    The composite is the equal-weight mean of the sub-scores that returned a number, and the line under it names how many did. 80 and over is green, 50 and over amber, below 50 red, and an unmeasured score is grey.

  3. Read the four sub-scores.

    Coverage is the share of top-level brain files edited in the last 30 days. Freshness compares the median file age with a 14-day target: 100 at or under the target, 0 at four times it. Drift is the share of brain files with a citation-rot or vector-drift event, plus wiki pages whose cited sources no longer resolve. Adoption is the share of reviewed proposals that were accepted; expired proposals are left out of the denominator and counted beside it.

  4. Give Drift something to measure.

    Press Scan again on Broken citations, higher on the same tab, to run a scan now; Brain health scores again when it finishes. The daemon's nightly pass runs the same scan; REPOOPS_NIGHTLY_OFF=1 stops it.

  5. Work Fixes worth making first.

    At most three, worst measured sub-score first; an unmeasured one sorts last. Each fix links to where it is made and, where an action exists, has Preview (a dry run) and Apply. Nothing happens until you press Apply.

  6. Read Do lessons stop repeat mistakes, under Brain health.

    Four numbers over the active lessons, each with what it counted. Repeat errors is the share of watched lessons that recurred in the last 90 days; a lesson is watched when it carries an error-signature guard, the only guard that records a recurrence. Enforced lessons is the share whose check names a test, lint rule, probe, hook or preview-check step; a line in CLAUDE.md is not a check. Days to a check is the median from the incident to the check's recorded start, or else its first recorded catch, which is an upper bound. Stale lessons is the share whose cited code is gone at HEAD. A number with nothing to count reads not measured, with the reason. Below them: the citation counts, each watched lesson with its recurrences, and Lessons with a check: per registry the repository keeps (per repository on repoops.ai), how many lessons name a check, how many are unenforced, and how many say a check exists without naming one.

  7. Turn on the lessons check run, under Setup.

    In Change risk card on GitHub, press Turn the lessons check on for a repository. Each open pull request then gets a RepoOps lessons check run listing the lessons about the files it changes whose check is missing, or that it skips by deleting the test or adding a skip. It concludes neutral or success and never fails the build, unless you also press Let it fail the build. It posts only on a private repository, and GitHub lets only a GitHub App create a check run.

2

Use cases

The score dropped and nobody changed the brain

Situation
Coverage and Freshness fell over a week. No file was deleted and no sweep ran.
You do
Set the trend window to 60 and read the notes under Coverage and Freshness.
You see
Coverage names how many files are stale, and Freshness the median age against 14 days. Time passed and files aged past 30 days; the age-based scores fell as designed, and Freshness recommends a refresh.

Adoption reads a dash while the queue is full

Situation
Hundreds of proposals sit unreviewed, and Adoption shows a dash or a low score beside an expired count.
You do
Open the recommendation to drain the queue, press Preview, then Apply, and decide on the proposals.
You see
An unattended inbox is told apart from a badly tuned proposer. Adoption stays a dash until someone accepts or rejects a proposal, because nothing reviewed means nothing to score.
3

Expected outcome

WorkedA composite over a named count of measured sub-scores, a trend line under each sub-score once two days are measured, and up to three fixes.
WorkedOn a fresh install: a grey dash for the composite and a dash on each sub-score, none of them red.
WorkedCoverage and Freshness draw only the days the score was read; Adoption and Drift draw the whole window.
Did not workThe composite is a grey dash.

Next step: Every dimension returned nothing. Read each sub-score note for which input is missing.

Did not workThe Coverage and Freshness trend lines are shorter than the window.

Next step: Nothing to fix: past file ages cannot be re-read. Leave boot prewarm on (REPOOPS_PREWARM) so a day is recorded on each start.

Did not workDrift never moves.

Next step: No citation-rot scan has run. Press Scan again on Broken citations and check that REPOOPS_NIGHTLY_OFF is unset.

Did not workThe hosted page says there is no rollup for this team yet.

Next step: Connect a desktop and turn the event push on.

4

What else to consider

What it does not grade

It grades whether the brain is kept, not whether it is correct: a wrong fact edited yesterday scores full marks. The composite is a mean of what was measured, so one measured dimension and three dashes still show a number. Intelligence vitals (Tier A), below the score, is four separate measures of whether the brain's faculties work, never summed; the same numbers print with npm run brain-vitals.

Brain health on repoops.ai

repoops.ai draws no Brain health score. /team/brain-health opens the Wiki tab of the Memory page, which lists each published wiki claim with the check its desktop ran. The four scores, the trend and the recommendations are on the desktop. The lesson numbers are on both: each desktop sends them with its nightly citation scan, and the Wiki tab adds them up across your repositories, newest report per repository. The Fleet tab on Memory lists the same numbers per repository, in both apps, beside the lessons one repository sent to another.

Team brain metrics

Every bound desktop sends a brain pulse: errors and decisions logged per week, recurring prevention-rule fingerprints, and open questions older than 30 days. Each desktop sends it hourly with its device token: counts, fingerprints, up to three sample titles per recurring rule and aged question titles, never proposal bodies or prompts. The weekly team digest email sums them, leaving out a device whose last pulse is older than 7 days. The Team brain metrics page is gone: /team/brain-metrics opens the Memory page's Wiki tab.

Brain diff: what changed between two dates

Brain diff, on the Decisions tab of Memory under What changed in the brain, lists every create, update and delete to brain files from the append-only event log, grouped by day, newest first. Set From and To (the last 7 days by default), choose a repository or all of yours, and press Read. Each row shows the time, the kind, the path, the actor and a summary, and View at this point opens Ask the brain on that file as it stood that day. The same read is GET /api/brain/diff.

Data and cost

No model call anywhere in the score, the trend, the recommendations or the vitals. One row per repository per UTC day is kept in brain-health-history.jsonl in the data directory, at most 2,000 rows; no route deletes it, and removing the file by hand drops every recorded day.