Answer principles round 1: 0 🔴, 6 🟡; derive the reviewers from agents/, open the security pass's prompt with a sentence, and type the review kinds

This commit is contained in:
2026-10-16 06:53:03 +02:00
parent e07c20bd60
commit 56b5924902
5 changed files with 34 additions and 33 deletions
+6 -3
View File
@@ -1,9 +1,12 @@
"""The routing ladder, and the rung an R + C picks from the project's rung: docs/decisions.md → `routing:`."""
import dataclasses
import re
import typing
# How Rung.__str__ spells a rung that names an effort, and Rung.parse reads it back.
WORDING = re.compile(r"(?P<model>\S+) at (?P<effort>\S+) effort")
# What a review launch reviews: a reviewer, a comprehension seat or the security pass.
ReviewKind = typing.Literal["reviewer", "seat", "security"]
@dataclasses.dataclass(frozen=True)
@@ -31,7 +34,7 @@ class Rung:
return Rung(model, effort)
return Rung(family.model, effort) if effort else family
# The one spelling of a rung: the archive records it, loop-claude's environment carries it, and parse reads it back.
# The one spelling of a rung; parse reads it back.
def __str__(self) -> str:
return f"{self.model} at {self.effort} effort" if self.effort else self.model
@@ -81,8 +84,8 @@ def stepped_up(rung: Rung) -> Rung:
return climbed(rung, 1)
def review_rung(kind: str, project: Rung, worker: Rung) -> Rung:
"""The rung a review runs on, which loop-claude's worker prompt and rule-hook's refusal both hold it to: a reviewer on the higher of the worker's rung and the project's, anything else, a comprehension seat or the security pass, on the project's."""
def review_rung(kind: ReviewKind, project: Rung, worker: Rung) -> Rung:
"""The rung a review runs on: a reviewer on the higher of the worker's rung and the project's; a seat or the security pass on the project's."""
return highest(project, worker) if kind == "reviewer" else project