Repository navigation
docs(072): selection gate feature page and runnable example (increment 4) - #595
Conversation
AI review (findings)Reviewing the diff for bugs, security problems, and inconsistencies against the governance context. Spec 072 change — removing Shell script review ( Documented output vs. actual script output — The "Try it" section in sh docs/features/selection-gate/example/run.sh
# gate select: exit 0, selected ← spurious
# gate: gate select exit 0, selected
# gate-strict: gate select exit 0, selected
# verdicts match the expected files (/tmp/rustev-selection-gate.XXXXXX)The script produces exactly three lines of output: the Expected JSON vs. documentation tables — The tables in
{"head": "f8590bf2286e019af983660ed160007a30a0064f", "verdict": "findings", "findings": [{"path": "docs/features/selection-gate.md", "line": 74, "severity": "low", "category": "correctness", "summary": "The documented script output includes a spurious first line '# gate select: exit 0, selected' that run.sh never produces; the script emits only the two 'gate:' / 'gate-strict:' echo lines and the final 'verdicts match' line."}]}Subject: 21156e4...f8590bf, diff digest 4b2f4bfa9c67dbd087a36a32f59b6b97370ce7c3f175d5ab6602773b3987dfaa, 1 call(s). An AI comment is not an approval. |
f8590bf to
5042b3a
Compare
AI review (no-findings)Reviewing the diff against governance context and checking each changed file for bugs, security problems, and inconsistencies.
Expected JSON files vs. documentation tables
Documentation internal consistency
No concrete bugs, security problems, or governance contradictions found. {"head": "5042b3ab65ffede00cfacfd838614b6d8db312ed", "verdict": "no-findings", "findings": []}Subject: 21156e4...5042b3a, diff digest 4a10f845a7d0b0b9b9241007341b65aad890b9fa65ee1d14d56497968c1353d3, 1 call(s). An AI comment is not an approval. |
5042b3a to
05a28d5
Compare
AI review (findings)Reviewing the diff for correctness, security, and consistency with governance.
No security issues found. The shell script does not construct commands from external data, uses no {"head": "05a28d5631c504fbd58d5f69b82f59f687e71567", "verdict": "findings", "findings": [{"path": "docs/features/selection-gate/example/run.sh", "line": 16, "severity": "low", "category": "correctness", "summary": "Comment says the work directory 'must not exist' when provided as an argument, but mkdir -p silently accepts an existing directory; no guard enforces the documented precondition."}]}Subject: dc60f26...05a28d5, diff digest 4a10f845a7d0b0b9b9241007341b65aad890b9fa65ee1d14d56497968c1353d3, 1 call(s). An AI comment is not an approval. |
05a28d5 to
a5b4193
Compare
AI review (findings)Reviewing the diff against the governance context and the changed files.
Line 51–52 of sed "s/\"threshold\":\"0.6\"/\"threshold\":\"$threshold\"/" \
baseline.definition.json > "$name.definition.json"The pattern matches the compact form
Lines ~212–221 (the five-row table in "How a verdict is decided"): the column header reads "
The removal of
The {"head": "a5b419359584f8765fa18103702a2ec9718350b6", "verdict": "findings", "findings": [{"path": "docs/features/selection-gate/example/run.sh", "line": 51, "severity": "low", "category": "correctness", "summary": "The sed pattern matches compact JSON 'threshold\":\"0.6\"' without a space; if synthetic-example.definition.json is pretty-printed with a space after the colon, the substitution silently fails and both candidate plans are identical to the baseline, causing an opaque verdict-diff failure rather than a clear diagnostic."}, {"path": "docs/features/selection-gate.md", "line": 212, "severity": "low", "category": "correctness", "summary": "The verdict decision table's 'and_any (if declared)' column has no row for the absent-and_any case with all require rules passing, leaving the most common case (used by both gate.json examples) unspecified in the table."}]}Subject: dc60f26...a5b4193, diff digest aa61058f66c058ade633c4edd0b374dd20fab58053dd062451e30bcee0b409c5, 1 call(s). An AI comment is not an approval. |
a5b4193 to
97bf8a2
Compare
AI review (findings)Reviewing the diff: a new feature doc ( Checks performed
Finding In the increment 4 prose added to
Increment 3 is prior to the current increment 4, so the condition "until increment 3 publishes their schemas" names a past increment as a future gate. The intent is plainly to defer until a later increment publishes the schemas; this should reference a future increment (e.g., "a later increment" or a not-yet-numbered one). {"head": "97bf8a20d5b0ec333f3c899e4ec4b7867450bf43", "verdict": "findings", "findings": [{"path": "specs/072-documentation-source-gaps/spec.md", "line": 243, "severity": "low", "category": "correctness", "summary": "Increment 4 prose says 'until increment 3 publishes their schemas', but increment 3 is already past; this should reference a future increment."}]}Subject: dc60f26...97bf8a2, diff digest 72887fe7bcba16ed6b220c628b5e181db6e38b89dccfc0b656eaa3a2bdaf6a9a, 1 call(s). An AI comment is not an approval. |
97bf8a2 to
b19f785
Compare
AI review (no-findings)Reviewing the diff across the three changed paths: the new documentation page and example directory, and the spec modification.
The only change is removing
Verdict logic table vs. examples: The The "Reading the result" JSON block is explicitly labelled abridged ( The acknowledged gap (selection-gate/1 and selection/1 schemas not yet published; field tables hand-kept until increment 3 merges) is stated clearly and is not a defect introduced by this PR.
Example JSON files
No concrete defects found. {"head": "b19f7852302fb7d0679ca26234785bbaaf7d9b6a", "verdict": "no-findings", "findings": []}Subject: dc60f26...b19f785, diff digest 123d9a324c5c08a927f704c7e5a512c9be49a4737a39f065a3ee9b5f58f14f2d, 1 call(s). An AI comment is not an approval. |
…mple docs/features/selection-gate.md and its example, which compiles the synthetic example definition, evaluates two threshold variants by replay and checks both gates' verdicts against committed expected files.
b19f785 to
73321bc
Compare
AI review (no-findings)Reviewing the diff: new feature documentation ( Documentation consistencyThe verdict decision table in
The numbers in the table (0.75 = 3/4 routed at baseline, 1.0 at route-more, 0.0 at route-less) are internally consistent with the binary threshold logic described. The replay-band-zero claim ("On replay, the band is zero") correctly explains why acceptance_coverage 0.0 vs 0.75 is an immediate fail with no tolerance. Shell script (
|
Spec 072 increment 4: the selection gate feature page and its runnable example (3.4, R-2).
docs/features/selection-gate.md: what the gate decides, when to use it, a worked example with real output, the decision order, the documents and their fields, exit codes, pitfalls and limits.docs/features/selection-gate/example/:run.shcompilessynthetic-example.definition.json(increment 1, no digest rewriting), captures replay bundles for every dataset case, evaluates the baseline and two threshold variants twice by replay, records the baseline, and runsgate selectwithgate.jsonandgate-strict.json. It compares verdicts and rule results (not bytes: run records carry measured latency) withexpected-gate.jsonandexpected-gate-strict.json.Stacked on #589. 072 joins
VERIFIED_SPECSand an acceptance group in the last increment, because its Verification also names increment 3's schema test.Verified locally:
make gate;env RUSTEV=<built rustev> sh docs/features/selection-gate/example/run.shexits 0 with both verdict files matching.