Answer architecture round 1: delete question-bench, keep its run's results in item 77 citing the commit that held it, and correct item 85's mention of item 78

This commit is contained in:
2026-10-09 00:46:44 +02:00
parent a9ec529158
commit 0050cd6772
11 changed files with 7 additions and 507 deletions
+2 -14
View File
@@ -22,29 +22,17 @@ class ScoringRun:
heading: str
commit: str
places: list[Place]
overall: float | None
def scoring_runs(history: str) -> list[ScoringRun]:
"""Each scoring run in a comprehension history, with the places its seats named, as they wrote them, and the seats' mean overall score; paired rulings name what changed, not what is hard, and are left out."""
"""Each scoring run in a comprehension history, with the places its seats named, as they wrote them; paired rulings name what changed, not what is hard, and are left out."""
runs = []
for heading, bodies in sections(history).items():
if (named := RUN.match(heading)) and ", against " not in heading:
runs.append(ScoringRun(heading, named.group(3), [place for body in bodies for place in seat_places(body)], mean_overall("\n".join(bodies))))
runs.append(ScoringRun(heading, named.group(3), [place for body in bodies for place in seat_places(body)]))
return runs
def mean_overall(body: str) -> float | None:
"""The last cell of the table's `Mean` row."""
for line in body.splitlines():
if line.startswith("| Mean |"):
try:
return float(line.strip().strip("|").split("|")[-1])
except ValueError:
return None
return None
def seat_places(body: str) -> list[Place]:
places = []
listing = False