C1: two entries the optimization lens can cite for the model/effort axis,
both read out of the primary sources in this session rather than from the
plan's 2026-07-14 summary of them.
Verifying corrected the plan's own numbers: effort is settable in SIX
places, not five (/effort, the /model slider, --effort,
CLAUDE_CODE_EFFORT_LEVEL, settings effortLevel, skill/subagent
frontmatter), the default is high on every supporting model EXCEPT Opus
4.7 (xhigh), and the level count is model-dependent (Opus 4.6 and Sonnet
4.6 have no xhigh).
- BP-MODEL-001: subagent `model` defaults to `inherit`, so a subagent
that names no model costs what the session costs; the documented pin
is overridable by CLAUDE_CODE_SUBAGENT_MODEL and per-invocation model
- BP-MODEL-002: effort is an axis separate from model choice, and higher
is not universally better (`max` "may show diminishing returns and is
prone to overthinking")
- both carry the 2026-07-07 model/effort blog as a corroborating source
with a real `published` date, so B1's evidence-age rule has teeth:
measured stale with reasons ['evidence-age'] at a reference date 378
days past publication while their verified stamps are pristine. The
docs pages themselves get NO published date — they carry none, and
guessing one in the field whose whole job is dating evidence is the
lie the rule exists to catch
- new blanket guard: every corroborating source must carry a parseable
published date. Without it newestEvidenceMs() returns null and the
entry stays green on evidence of any age — a silent hole. Seen red
against its own defect before it was trusted
- knowledge-refresh-cli's stale branch no longer expires on every new
entry: its reference date has to sit after every `verified` stamp, was
bumped once for BP-SUB-001 and would have needed a third bump now, so
it moves to a date no stamp can reach
Register 14 -> 16 entries. Frozen v5.0.0 snapshots untouched (no scanner
output changes); suite 1579/0.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01NKjojcdYYiCQP5AudUyQ5e
Add knowledge/best-practices.json: a machine-readable, provenance-stamped, schema-validated best-practices register — the source of truth for the upcoming v5.7 optimization lens (CA-OPT). 13 seed entries migrated from the v5.5 V-rows (loading-model + compaction facts) and the Anthropic 'Steering Claude Code' blog (mechanism-fit rules); each entry carries source.url + verified date + confidence. Only confirmed claims are user-facing (Verifiseringsplikt).
scanners/lib/best-practices-register.mjs: zero-dependency loader + validator (loadRegister/validateRegister/getEntry, native JSON.parse — not YAML, since the repo is zero-dep and yaml-parser.mjs can't parse arrays-of-objects). tests/lib/best-practices-register.test.mjs: 22 tests (schema, provenance integrity, negative cases, lookup).
Byte-stable: no scanner consumes the register yet (Chunk 2), so all scanner output is unchanged. Suite 1023->1045, self-audit A/A, readmeCheck passed. Full design: docs/v5.7-optimization-lens-plan.md.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>