pr-explain: require one rule per quiz item and an unambiguous stem #153
No reviewers
Labels
No labels
bug
duplicate
enhancement
help wanted
invalid
question
wontfix
bug
duplicate
enhancement
help wanted
invalid
question
wontfix
No milestone
No project
No assignees
2 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
allod/tools!153
Loading…
Reference in a new issue
No description provided.
Delete branch "agent/quiz-item-rules"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
The quiz-authoring prompt for
allod pr explaingains three rules, so generated quiz items stop failing the way one item in the allod/archetypes#39 report did.Nothing about the tool's behavior, output shape, or validator changes. The prompt is read from disk at run time, so this takes effect on the next report generated and alters no existing one. All three
pr-explainsuites pass unchanged. If it reads wrong, revert the commit: there is no state, no regenerated report, and nothing that branches on the prompt's text.What prompted it
An item in the report for allod/archetypes#39 asked why the fleet gate rejects a given assignment. Its scenario read "Both exported hosts contain
guest-a, and one host also containslegacy", and its key was "rejectsguest-afor cardinality two and rejectslegacybecause inventory did not select it for microVM". Three separate failures, each now addressed:legacy" reads, to anyone who knows a hypervisor runs guests of both runtimes, as an ordinary and correct arrangement. The item needed it to mean "legacyis in this host'smicrovm.vmsattrset", which it never said.config.microvm.vmsand cannot see libvirt domains at all. The item punished a reasonable parse rather than a misconception.What changed
pr-explain/quiz-prompt.md, three additions and a renumbering:andto join two independent findings. Name the construct the scenario turns on rather than a verb that could carry more than one meaning, because the reader cannot recover an internal meaning the stem did not state.Risk
Low. The prompt is instruction text consumed by an authoring pass; no code path branches on it, and
pr_explain_emit_assetreads it from disk, so there is no embedded copy to fall out of sync. The added length is roughly 150 words against a 6.7 KB prompt, immaterial next to the whole quoted report that pass already receives.The rules are stated, not enforced. The validator cannot detect a compound key or an ambiguous stem, so the new checklist line is the only gate and it is a self-check by the authoring model — the same enforcement every other authoring rule in this file has. If that proves insufficient, the next step is a validator rule, which this change does not attempt.
Validation
bash tests/pr-explain/components.sh— 86 passed.bash tests/pr-explain/command.sh— 706 passed.bash tests/pr-explain/validation.sh— 104 passed.No report was regenerated. Doing so costs a full authoring run against a live pull request, and no test asserts on this file's prose. Whether the next generated quiz is actually better is unmeasured here, and the first regenerated report is where that gets checked.
Refs allod/archetypes#39.