CHAPTER 09 · Memory Outside the Weights · 5 / 5
Key takeaways
- The model is stateless; project knowledge lives outside the weights in files the harness loads.
CLAUDE.md/AGENTS.mdare injected every session and reloaded after compaction. Put persistent rules there, not in chat.- Aggregate instructions "more specific wins": root first, working directory last; respect a size cap; load path-scoped rules only when relevant.
- The two-tier pattern (shared rules in git, personal memory per user, with a promotion workflow) makes memory a reviewable team practice and keeps the whole setup portable.
- Memory sits in the cached prefix, so a stable instruction file is both more effective and cheaper.
Original sources: Anthropic's How Claude Code works, the "Agentic Harness Architecture: Seven Pillars" breakdown, and OpenAI's Unrolling the Codex agent loop.