Skip to content

memories/claude-code.md is at exactly 1200 lines: the next addition fails the size gate #1350

Description

@d-morrison

memories/claude-code.md is at exactly 1200 lines on main as of
b22068a8 --- the limit scripts/check-memory-file-size.py reports on and
scripts/test_check_memory_file_size.py asserts against the live corpus. The
next line added to that file fails CI.

Why this needs its own issue rather than being noticed in the moment

The two instruments disagree about severity, which is what makes this easy to
walk into:

  • scripts/check-memory-file-size.py prints an advisory notice and exits 0.
    Read on its own it looks like a suggestion.
  • scripts/test_check_memory_file_size.py asserts the live corpus stays under
    the limit and exits 1. That is what fails CI.

So a session that adds to this file, runs the checker, and sees exit 0 has not
learned anything about whether it just broke the build. Hit during #1344, where
a ~45-line addition took the file from 1196 to 1232 and the advisory exit code
gave no signal; it was caught only by running the test rather than the script.

Current shape

check-memory-file-size.py's own report names the largest sections:

memories/claude-code.md: 1200 lines
      164  ## ai-config's three context pools -- only one of them is worth splitting
      127  ## Wiring ai-config skills/memories into a consumer repo's `claude` bots
       82  ## Bash tool cwd persists across calls -- an easy trap when juggling sibling repo checkouts
       74  ## A plugin ref resolves by the marketplace's *declared* name, not by its URL
       62  ## Skill command blocks -- resolve the ai-config repo root with the per-skill symlink

The first two are 291 lines between them and are about ai-config's own
distribution and consumption
(context pools, wiring the plugin into a consumer
repo's bots) rather than about Claude Code's behaviour, which is what the rest of
the file covers. That looks like the natural seam, but the split is a judgment
call and the checker's own message says so --- move whole sections, register the
new file in memories/MEMORY.md, and repoint inbound references.

Suggested fix

Split per the ai-config#694 pattern. Whoever takes it should also decide whether
the gate wants a small margin rather than a hard 1200, since landing a file at
exactly the limit means the next contributor pays for the split at an arbitrary
moment --- which is what happened here.

(Found 2026-08-09 while wrapping up #1344.)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions