fix(#2372): widen decision-coverage-plan to all planner-canonical tags, drop misleading "(or body)" (#2443)
* fix(#2372): widen decision-coverage scan to planner-canonical tags, fix message Bug: check.decision-coverage-plan's remediation message told the user to cite decisions "(or body)" but extractPlanDesignatedSections only scanned <objective>/<tasks>/<task>/<action>. A decision cited in <read_first>, <behavior>, <verify>, <acceptance_criteria>, or <done> was invisible to the gate — false BLOCKING coverage gap, plus the message's own fix-hint sent the user to "the body" where re-citing still failed. Two-part fix (must change together — that drift was the bug): 1. Widen XML_DECISION_TAGS_RE in src/check-command-router.cts to also match <read_first>, <behavior>, <verify>, <acceptance_criteria>, <done>. These are all planner-canonical tags the planner is told to use (plan-phase.md:830-862, plan-phase.md:772). The body negative- lookahead mirrors the opening-tag set so each tag's body is captured independently. 2. Correct buildPlanMessage to name ONLY the surfaces the extractor actually scans (front-matter must_haves/truths/objective, designated markdown headings, and the nine planner-canonical tag bodies). The misleading "(or body)" clause is gone. Also updates the planner's documented contract (agents/gsd-planner.md:69) and user-facing docs (docs/CONFIGURATION.md, docs/USER-GUIDE.md) to reflect the wider scan. Regression tests in tests/decisions.test.cjs cover each newly-scanned tag body, a control (no citation still uncovered), and a message/extractor parity assertion that names every scanned surface — so the two cannot drift apart again. Out of scope (per triage): cmdDecisionCoverageVerify/buildVerifyMessage is a separate command (decision-coverage-verify) checking shipped artifacts, not plan citations — untouched. * chore(#2372): regenerate agent-size-baseline + golden-install-parity fixtures gsd-planner.md grew 49172 → 49294 (+122 chars) from the widened decision- coverage contract (5 new scanned tag names + heading clarification). Growth is justified: the contract surface is itself the fix — the prior text under-described what the gate scans, which was the bug. Updates: - tests/agent-size-baseline.json (gsd-planner.md: 49172 → 49294) - 17 tests/fixtures/golden-install-parity/*.json (one hash per runtime) - tests/fixtures/install-tree/*.json (regenerated by gen:golden) * fix(#2372): per-tag matching — outer-tag citations survive inner-tag nesting Code review (subagent) flagged a Medium edge-case regression from the single-alternation regex: when a newly-scanned tag nests inside another scanned tag, the alternation's negative lookahead halts the outer tag's body at the inner tag — losing any D-NN citation in the outer tag's prefix prose. Concretely: <action>per D-05 <verify>npm test</verify></action> → 3-tag alternation (old): captured 'per D-05 <verify>npm test</verify>' as <action> body → D-05 caught → 9-tag alternation (bug): captured 'npm test' only (from <verify>); D-05 in <action> prefix LOST Switches extractXmlTagBodies to per-tag matching: each tag gets its own regex whose negative-lookahead tempers only against the SAME tag's reopening. So <verify> inside <action> is absorbed into <action>'s body (D-05 caught) AND <verify> is matched separately on its own pass. Per-tag preserves both: - the reporter's case (sibling tags inside <read_first>) - nested-tag citations in outer-tag prefix prose - ReDoS safety (each per-tag regex keeps the #2128 body tempering) Also adds the reviewer's other requested edge-case tests: - non-scanned tag (<name>) bearing D-NN must NOT count - self-closing form <read_first /> safely ignored - attribute form <verify type="...">D-NN</verify> (canonical planner shape) - CRLF newlines in tag body do not break capture * chore(changeset): backfill pr:2443 in .changeset/noble-elks-chatter.md
This commit is contained in:
@@ -25,7 +25,7 @@
|
||||
"agents/gsd-pattern-mapper.md": "e62ee90d39084802",
|
||||
"agents/gsd-phase-researcher.md": "cff1196c8e8bb4fa",
|
||||
"agents/gsd-plan-checker.md": "dd1e7cdc837d8f3e",
|
||||
"agents/gsd-planner.md": "6a442501f9d4caa8",
|
||||
"agents/gsd-planner.md": "e2ad6fa2952fe88f",
|
||||
"agents/gsd-project-researcher.md": "85de7f562872ee9b",
|
||||
"agents/gsd-research-synthesizer.md": "18a2e1b30ff7ae3a",
|
||||
"agents/gsd-roadmapper.md": "7a8465ac6d4dd29e",
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
"agents/gsd-pattern-mapper.md": "43c6021cf7caabfa",
|
||||
"agents/gsd-phase-researcher.md": "f1f6fd6a3e67c7a8",
|
||||
"agents/gsd-plan-checker.md": "bf1a4e636f2390de",
|
||||
"agents/gsd-planner.md": "55cc953c6a52ae05",
|
||||
"agents/gsd-planner.md": "86f6cfd300125965",
|
||||
"agents/gsd-project-researcher.md": "4531b7cc8f5e5f7d",
|
||||
"agents/gsd-research-synthesizer.md": "4a4f68e6c75b133a",
|
||||
"agents/gsd-roadmapper.md": "bb2f57695dbab32c",
|
||||
|
||||
@@ -24,7 +24,7 @@
|
||||
"agents/gsd-pattern-mapper.md": "b45b5e106775bec1",
|
||||
"agents/gsd-phase-researcher.md": "4772d9eada32e8bd",
|
||||
"agents/gsd-plan-checker.md": "75851b147f35354a",
|
||||
"agents/gsd-planner.md": "4636f48b1b7ca1f6",
|
||||
"agents/gsd-planner.md": "44a04bdebe044114",
|
||||
"agents/gsd-project-researcher.md": "d7f355894519f9fe",
|
||||
"agents/gsd-research-synthesizer.md": "1c738df9932d325a",
|
||||
"agents/gsd-roadmapper.md": "453e9471ad27c7ea",
|
||||
|
||||
@@ -24,7 +24,7 @@
|
||||
"agents/gsd-pattern-mapper.md": "b45b5e106775bec1",
|
||||
"agents/gsd-phase-researcher.md": "85217c69c1ed2ac6",
|
||||
"agents/gsd-plan-checker.md": "c70134c61b969589",
|
||||
"agents/gsd-planner.md": "3098091aa1f0756d",
|
||||
"agents/gsd-planner.md": "0ec11dd0d673f828",
|
||||
"agents/gsd-project-researcher.md": "f468e96f8339d1e0",
|
||||
"agents/gsd-research-synthesizer.md": "7be02e47f4fd901b",
|
||||
"agents/gsd-roadmapper.md": "8a7f1f1256a6aed5",
|
||||
|
||||
@@ -28,7 +28,7 @@
|
||||
"agents/gsd-pattern-mapper.md": "b526065fd2efa19c",
|
||||
"agents/gsd-phase-researcher.md": "c507db2ba66038f4",
|
||||
"agents/gsd-plan-checker.md": "a609245dbdc4ef2b",
|
||||
"agents/gsd-planner.md": "c2ab476257cd07cf",
|
||||
"agents/gsd-planner.md": "6f390cd0f07473a7",
|
||||
"agents/gsd-project-researcher.md": "049f816c6caa4316",
|
||||
"agents/gsd-research-synthesizer.md": "2f7dcbff50371d4c",
|
||||
"agents/gsd-roadmapper.md": "bbb23d3097911516",
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
"agents/gsd-pattern-mapper.md": "92cfa2e6c2a06bf3",
|
||||
"agents/gsd-phase-researcher.md": "6338474da1a5d65e",
|
||||
"agents/gsd-plan-checker.md": "e704c083b02e8c35",
|
||||
"agents/gsd-planner.md": "8e3e314f962711cd",
|
||||
"agents/gsd-planner.md": "50f9d7d12d8268af",
|
||||
"agents/gsd-project-researcher.md": "e43c59f7f1f2f37a",
|
||||
"agents/gsd-research-synthesizer.md": "87955470c3c129b2",
|
||||
"agents/gsd-roadmapper.md": "20b69eff61a7a9fa",
|
||||
|
||||
@@ -120,8 +120,8 @@
|
||||
"agents/gsd-phase-researcher.toml": "44a3d510cd0ce3bd",
|
||||
"agents/gsd-plan-checker.md": "e7f02c10ea788aee",
|
||||
"agents/gsd-plan-checker.toml": "6f8ceb421d0ad721",
|
||||
"agents/gsd-planner.md": "cb3ff2ef2c58617c",
|
||||
"agents/gsd-planner.toml": "ac51638704036f71",
|
||||
"agents/gsd-planner.md": "19969475e4e38175",
|
||||
"agents/gsd-planner.toml": "f5f4f3876767d323",
|
||||
"agents/gsd-project-researcher.md": "959f2e57c3d69ed8",
|
||||
"agents/gsd-project-researcher.toml": "f395e8e8c4baf1ed",
|
||||
"agents/gsd-research-synthesizer.md": "497f85adf53259ef",
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
"agents/gsd-pattern-mapper.agent.md": "b1f488b0fa6a2395",
|
||||
"agents/gsd-phase-researcher.agent.md": "03cfb510a766fe93",
|
||||
"agents/gsd-plan-checker.agent.md": "c50a5b008ddcbfad",
|
||||
"agents/gsd-planner.agent.md": "8f5f400efea5e446",
|
||||
"agents/gsd-planner.agent.md": "1721f5ace5c95434",
|
||||
"agents/gsd-project-researcher.agent.md": "d73bdbe986ffa8a6",
|
||||
"agents/gsd-research-synthesizer.agent.md": "f03eed4aa89e47c5",
|
||||
"agents/gsd-roadmapper.agent.md": "322048cf8ddcb4e5",
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
"agents/gsd-pattern-mapper.md": "1229c215677f740d",
|
||||
"agents/gsd-phase-researcher.md": "982d59921bed463d",
|
||||
"agents/gsd-plan-checker.md": "ba51999876d40cf2",
|
||||
"agents/gsd-planner.md": "c788d7fb84cf5433",
|
||||
"agents/gsd-planner.md": "71c6e41403d6bc63",
|
||||
"agents/gsd-project-researcher.md": "beeac940d3a10e76",
|
||||
"agents/gsd-research-synthesizer.md": "6315f016d55176f4",
|
||||
"agents/gsd-roadmapper.md": "d28e7d4bac46dde2",
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
"agents/gsd-pattern-mapper.md": "cea092600aeb3978",
|
||||
"agents/gsd-phase-researcher.md": "2bd0402f33d757ca",
|
||||
"agents/gsd-plan-checker.md": "4b4e2b475bf5b5c3",
|
||||
"agents/gsd-planner.md": "d5fa8236f975aacd",
|
||||
"agents/gsd-planner.md": "5f5fa906f62643b6",
|
||||
"agents/gsd-project-researcher.md": "425a7df7f37a5c06",
|
||||
"agents/gsd-research-synthesizer.md": "9d31c87fc2c87ffa",
|
||||
"agents/gsd-roadmapper.md": "64dce5d5f9fa5654",
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
"agents/gsd-pattern-mapper.md": "6a5408fd11d70391",
|
||||
"agents/gsd-phase-researcher.md": "94818f28c498bb26",
|
||||
"agents/gsd-plan-checker.md": "56164206242c8caf",
|
||||
"agents/gsd-planner.md": "13c4b6db72b6bbb3",
|
||||
"agents/gsd-planner.md": "282aa34e2e8bc267",
|
||||
"agents/gsd-project-researcher.md": "60573a38d3dfd9fe",
|
||||
"agents/gsd-research-synthesizer.md": "1f7cd286c5783c86",
|
||||
"agents/gsd-roadmapper.md": "277e0a3252553ab7",
|
||||
|
||||
@@ -79,7 +79,7 @@
|
||||
"agents/subagents/gsd-phase-researcher.yaml": "7633c8e82617e7cc",
|
||||
"agents/subagents/gsd-plan-checker.md": "bd302afc01ed40f0",
|
||||
"agents/subagents/gsd-plan-checker.yaml": "8295181071121db8",
|
||||
"agents/subagents/gsd-planner.md": "d29376ff9f57cc60",
|
||||
"agents/subagents/gsd-planner.md": "285c6a21227787f9",
|
||||
"agents/subagents/gsd-planner.yaml": "2e83ee194bcd7fbd",
|
||||
"agents/subagents/gsd-project-researcher.md": "39bc2ec5a8b18283",
|
||||
"agents/subagents/gsd-project-researcher.yaml": "ce12586b0347e2dc",
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
"agents/gsd-pattern-mapper.md": "7c6d1d9817a9c1e7",
|
||||
"agents/gsd-phase-researcher.md": "9874110700b41f48",
|
||||
"agents/gsd-plan-checker.md": "28ca3dc43669894f",
|
||||
"agents/gsd-planner.md": "87d1aa910eb02ad5",
|
||||
"agents/gsd-planner.md": "5234ac4f1afce5dc",
|
||||
"agents/gsd-project-researcher.md": "dae210ae0b3c6e2b",
|
||||
"agents/gsd-research-synthesizer.md": "e02c6ad5d1b74171",
|
||||
"agents/gsd-roadmapper.md": "1658a40b20d8b575",
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
"agents/gsd-pattern-mapper.md": "83c66c7722e8b165",
|
||||
"agents/gsd-phase-researcher.md": "284e55a86ae46d7f",
|
||||
"agents/gsd-plan-checker.md": "c8a8fcc8ed38eff0",
|
||||
"agents/gsd-planner.md": "f0a5bede90f23be4",
|
||||
"agents/gsd-planner.md": "c38e99d7be01a728",
|
||||
"agents/gsd-project-researcher.md": "b5baac64a15c85e2",
|
||||
"agents/gsd-research-synthesizer.md": "6cd9b501dc97bd50",
|
||||
"agents/gsd-roadmapper.md": "c357a77ab919e9e5",
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
"agents/gsd-pattern-mapper.md": "b5d7a4abb1baecb9",
|
||||
"agents/gsd-phase-researcher.md": "2256f1f82212c757",
|
||||
"agents/gsd-plan-checker.md": "523119bd5d6599fe",
|
||||
"agents/gsd-planner.md": "fb330c599b9c1dac",
|
||||
"agents/gsd-planner.md": "ddfd810f17d39eb6",
|
||||
"agents/gsd-project-researcher.md": "ddf7794e81300032",
|
||||
"agents/gsd-research-synthesizer.md": "a124b00271748d07",
|
||||
"agents/gsd-roadmapper.md": "493ef92b42b12cf4",
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
"agents/gsd-pattern-mapper.md": "ada0c169daa2f0ec",
|
||||
"agents/gsd-phase-researcher.md": "2a45ebde829555ec",
|
||||
"agents/gsd-plan-checker.md": "33fbf70b7b24eb1e",
|
||||
"agents/gsd-planner.md": "61ac0bd59b5b836a",
|
||||
"agents/gsd-planner.md": "f98cfbc92bfff334",
|
||||
"agents/gsd-project-researcher.md": "f6697b316b5995ba",
|
||||
"agents/gsd-research-synthesizer.md": "04036f38c1d373ea",
|
||||
"agents/gsd-roadmapper.md": "fb62e1e3de84b5f9",
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
"agents/gsd-pattern-mapper.md": "68ecefd60811a669",
|
||||
"agents/gsd-phase-researcher.md": "2235f61764d8e969",
|
||||
"agents/gsd-plan-checker.md": "bb38f345d3d41edc",
|
||||
"agents/gsd-planner.md": "42f6e9832d5c2edc",
|
||||
"agents/gsd-planner.md": "1e904e38cccc5dc4",
|
||||
"agents/gsd-project-researcher.md": "f572892f138734ff",
|
||||
"agents/gsd-research-synthesizer.md": "29949bf3f049a8f1",
|
||||
"agents/gsd-roadmapper.md": "840ac933e3b094f9",
|
||||
|
||||
Reference in New Issue
Block a user