From 6492cd62a11d649a8195a25df9e341a625131e62 Mon Sep 17 00:00:00 2001 From: Lilleman auf Larv Date: Thu, 24 Sep 2026 23:51:52 +0200 Subject: [PATCH 1/4] Keep ### sub-headings inside their ## section when reading the premises --- CHANGELOG.md | 1 + bin/loop-claude | 2 +- bin/test_loop_claude.py | 4 ++-- todo.md | 1 - 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index f7a4697f..cfa7c1e7 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,7 @@ - `loop-claude` exits 1 when the judge fails three times running; a verdict missing a field or quoting nothing in the transcript is a failure. - `loop-claude` exits 2 when an interrupt gets no answer, saying why: stdin or stdout is not a terminal, or nothing was typed. Rerunning resumes the session. - `loop-claude --help` names the Claude Code version its transcript, session and trust handling were observed on; check it first when an upgrade breaks a cycle. +- `loop-claude` reads a `## Goals` or `## Audience` section of `README.md` whole, `###` sub-headings included. - `loop-claude` runs the model each project's settings pick; `WORKER_MODEL` and `JUDGE_MODEL` override it. This repo runs on Fable 5.1. - Reviewers share one protocol for verdicts, severities, rounds and declines: `agents/review-protocol.md`. - Skills and agents cite `CLAUDE.md` by heading; the comment and documentation bar lives there alone. diff --git a/bin/loop-claude b/bin/loop-claude index d75b8f1c..c2ea8cbc 100755 --- a/bin/loop-claude +++ b/bin/loop-claude @@ -87,7 +87,7 @@ def sections(text): if not fenced and line.startswith("## "): current = line.strip()[3:] found[current] = [] - elif not fenced and line.startswith("#"): + elif not fenced and line.startswith("# "): current = None elif current and line.strip(): found[current].append(line) diff --git a/bin/test_loop_claude.py b/bin/test_loop_claude.py index 78210f4e..7f9e1016 100644 --- a/bin/test_loop_claude.py +++ b/bin/test_loop_claude.py @@ -27,8 +27,8 @@ def human(content): class Sections(unittest.TestCase): def test_keeps_only_headed_sections_with_a_body(self): - text = "# Title\n\nintro\n\n## Goals\n\n1. one\n```sh\n# not a heading\n```\n2. two\n\n## Empty\n\n## Audience\nme\n# Appendix\nnot audience\n" - self.assertEqual(loop.sections(text), {"Goals": "1. one\n```sh\n# not a heading\n```\n2. two", "Audience": "me"}) + text = "# Title\n\nintro\n\n## Goals\n\n1. one\n```sh\n# not a heading\n```\n### Later\n2. two\n\n## Empty\n\n## Audience\nme\n# Appendix\nnot audience\n" + self.assertEqual(loop.sections(text), {"Goals": "1. one\n```sh\n# not a heading\n```\n### Later\n2. two", "Audience": "me"}) class Render(unittest.TestCase): diff --git a/todo.md b/todo.md index d81f43b9..e21535d5 100644 --- a/todo.md +++ b/todo.md @@ -4,7 +4,6 @@ Ordered by how many seats of the 2026-09-24 scoring panel (`docs/decisions.md`) named the place; each is one chunk. -- Keep `###` sub-headings inside their `##` section in `sections`, pinned by a test; today a sub-heading under `## Goals` silently drops the rest of the goals. - Merge `project` and `project_path` into one name and one shape for the project's path. - Name the session, the archive folder and its env var `loop-claude`; today they say `auto-mode`. - Pin every `CLAUDE.md` heading the agents and skills cite with a test that resolves each citation. -- 2.52.0 From 49da0a1c3bf01b2548cd33e9f3c0d7ffe6b0a6ba Mon Sep 17 00:00:00 2001 From: Lilleman auf Larv Date: Thu, 24 Sep 2026 23:54:36 +0200 Subject: [PATCH 2/4] Pin a #-prefixed prose line as body in the sections test --- bin/test_loop_claude.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bin/test_loop_claude.py b/bin/test_loop_claude.py index 7f9e1016..9c22643f 100644 --- a/bin/test_loop_claude.py +++ b/bin/test_loop_claude.py @@ -27,8 +27,8 @@ def human(content): class Sections(unittest.TestCase): def test_keeps_only_headed_sections_with_a_body(self): - text = "# Title\n\nintro\n\n## Goals\n\n1. one\n```sh\n# not a heading\n```\n### Later\n2. two\n\n## Empty\n\n## Audience\nme\n# Appendix\nnot audience\n" - self.assertEqual(loop.sections(text), {"Goals": "1. one\n```sh\n# not a heading\n```\n### Later\n2. two", "Audience": "me"}) + text = "# Title\n\nintro\n\n## Goals\n\n1. one\n```sh\n# not a heading\n```\n### Later\n2. two\n#1 priority\n\n## Empty\n\n## Audience\nme\n# Appendix\nnot audience\n" + self.assertEqual(loop.sections(text), {"Goals": "1. one\n```sh\n# not a heading\n```\n### Later\n2. two\n#1 priority", "Audience": "me"}) class Render(unittest.TestCase): -- 2.52.0 From 485c14e4c61ff3976158aaa21627c1916613463f Mon Sep 17 00:00:00 2001 From: Lilleman auf Larv Date: Thu, 24 Sep 2026 23:57:18 +0200 Subject: [PATCH 3/4] Drop the verbatim claim on the premises and the changelog line for unreleased behaviour; file the missing-premises message --- CHANGELOG.md | 1 - bin/loop-claude | 2 +- todo.md | 1 + 3 files changed, 2 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index cfa7c1e7..f7a4697f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,7 +7,6 @@ - `loop-claude` exits 1 when the judge fails three times running; a verdict missing a field or quoting nothing in the transcript is a failure. - `loop-claude` exits 2 when an interrupt gets no answer, saying why: stdin or stdout is not a terminal, or nothing was typed. Rerunning resumes the session. - `loop-claude --help` names the Claude Code version its transcript, session and trust handling were observed on; check it first when an upgrade breaks a cycle. -- `loop-claude` reads a `## Goals` or `## Audience` section of `README.md` whole, `###` sub-headings included. - `loop-claude` runs the model each project's settings pick; `WORKER_MODEL` and `JUDGE_MODEL` override it. This repo runs on Fable 5.1. - Reviewers share one protocol for verdicts, severities, rounds and declines: `agents/review-protocol.md`. - Skills and agents cite `CLAUDE.md` by heading; the comment and documentation bar lives there alone. diff --git a/bin/loop-claude b/bin/loop-claude index c2ea8cbc..4c23eaa5 100755 --- a/bin/loop-claude +++ b/bin/loop-claude @@ -266,7 +266,7 @@ def run_worker(args): def judge_prompt(task, premises, transcript): return ( - f"README.md, verbatim:\n{premises}\n\n" + f"From README.md:\n{premises}\n\n" f"The task an agent was given:\n{task}\n\n" f"What the agent then did and said, latest last:\n{transcript[-40000:]}\n\n" f"{JUDGE_RULES}" diff --git a/todo.md b/todo.md index e21535d5..2c42b57e 100644 --- a/todo.md +++ b/todo.md @@ -12,4 +12,5 @@ Ordered by how many seats of the 2026-09-24 scoring panel (`docs/decisions.md`) - Make `CLAUDE.md`'s comment rules say an invariant earns a line only where the code cannot show it, state the one-line rule once, and scope the docstring exemption to what a tool consumes; today a reviewer finds two sentences saying keep and one saying delete. - Give the comprehension floor in `larv-review` its own heading and move its six-project calibration sentence to `docs/decisions.md`; today it sits under §2 "Trigger". - Cut what `review-protocol.md` → "Documenting decisions" restates from `CLAUDE.md`: the decision kinds, the create-or-fix line and the record-nothing default. +- Make the missing-premises exit name what is missing: `README.md` itself, a `## Goals` or `## Audience` heading, or a body under one; today all three print the same line. - Re-run the four-seat scoring panel and record the score in `docs/decisions.md`; the target is every dimension at 7.0 or above. -- 2.52.0 From a28b3e0f6d674d2bfa7bbf942c033536cfcf79f1 Mon Sep 17 00:00:00 2001 From: Lilleman auf Larv Date: Thu, 24 Sep 2026 23:58:18 +0200 Subject: [PATCH 4/4] File the scope of "Negation and history" as a chunk --- todo.md | 1 + 1 file changed, 1 insertion(+) diff --git a/todo.md b/todo.md index 2c42b57e..0e82289f 100644 --- a/todo.md +++ b/todo.md @@ -10,6 +10,7 @@ Ordered by how many seats of the 2026-09-24 scoring panel (`docs/decisions.md`) - Define chunk, plan and release inside `JUDGE_RULES`; the judge reads nothing else. - Name the `set -u` empty-array idiom and the `@sh` eval in `statusline.sh`, one line each. - Make `CLAUDE.md`'s comment rules say an invariant earns a line only where the code cannot show it, state the one-line rule once, and scope the docstring exemption to what a tool consumes; today a reviewer finds two sentences saying keep and one saying delete. +- Open `CLAUDE.md` → "Negation and history" with its scope, comments and docs beside code, and cut its two restatements of the section bar; today a reviewer cites it against a `CHANGELOG.md` line, which the next paragraph governs. - Give the comprehension floor in `larv-review` its own heading and move its six-project calibration sentence to `docs/decisions.md`; today it sits under §2 "Trigger". - Cut what `review-protocol.md` → "Documenting decisions" restates from `CLAUDE.md`: the decision kinds, the create-or-fix line and the record-nothing default. - Make the missing-premises exit name what is missing: `README.md` itself, a `## Goals` or `## Audience` heading, or a body under one; today all three print the same line. -- 2.52.0