This is an automated email from the ASF dual-hosted git repository. spmallette pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/tinkerpop.git
commit adba66ea3a02e8c4e9143b2443832eaa1a1474e3 Author: Stephen Mallette <[email protected]> AuthorDate: Mon Aug 10 08:24:31 2026 -0400 Point the beads tooling at metadata.rejected The label is gone, so the report script's decision-pair check matched nothing and flagged every decision. It also flagged every rejected alternative, whose only neighbour is the decision that beat it -- that side is now skipped. Hook prompts reworded to match. Assisted-by: Claude Code:claude-opus-5 --- bin/agent-hooks/kiro.json | 2 +- bin/beads-agent-hook.sh | 10 +++++----- bin/beads-report.py | 9 ++++++--- 3 files changed, 12 insertions(+), 9 deletions(-) diff --git a/bin/agent-hooks/kiro.json b/bin/agent-hooks/kiro.json index d71877351a..2fdfaba1c1 100644 --- a/bin/agent-hooks/kiro.json +++ b/bin/agent-hooks/kiro.json @@ -36,7 +36,7 @@ "trigger": "UserPromptSubmit", "action": { "type": "agent", - "prompt": "If the operator just redirected you -- rejected an approach, said an alternative was already tried, or told you to do something a different way -- create a decision bead and its rejected-alternative sibling now, while the reasoning is exact. Otherwise ignore this and carry on." + "prompt": "If the operator just redirected you -- rejected an approach, said an alternative was already tried, or told you to do something a different way -- create a decision bead and its rejected sibling now, while the reasoning is exact. Otherwise ignore this and carry on." }, "timeout": 15, "enabled": true diff --git a/bin/beads-agent-hook.sh b/bin/beads-agent-hook.sh index 0e35ff51fc..0bb4dd1191 100755 --- a/bin/beads-agent-hook.sh +++ b/bin/beads-agent-hook.sh @@ -114,9 +114,9 @@ case "$event" in active=$(bd list --status=in_progress 2>/dev/null | grep -v '^No issues found' | head -20) text="Beads check — did anything get decided this session? -An alternative that was actually considered and rejected belongs in a decision bead with -its rejected-alternative sibling. An approach you tried and abandoned counts. Anything else -worth remembering goes in a comment on the root bead." +An alternative that was actually considered and rejected belongs in its own decision bead, +marked --metadata '{\"rejected\":true}'. An approach you tried and abandoned counts. Anything +else worth remembering goes in a comment on the root bead." # Editing files while nothing is claimed means the in_progress window -- the only # thing a later session can read to resume -- is never being written. These are two @@ -148,8 +148,8 @@ was underway or where it stopped." [[ -n "$prompt" ]] || exit 0 if printf '%s' "$prompt" | tr '[:upper:]' '[:lower:]' | grep -Eq "$REDIRECT_RE"; then text="That prompt reads as a redirect. If an alternative was just rejected, create the -decision bead and its rejected-alternative sibling now, while the reasoning is exact — -operator redirects are the highest-signal capture trigger there is." +decision bead and its rejected sibling now, while the reasoning is exact — operator +redirects are the highest-signal capture trigger there is." fi ;; diff --git a/bin/beads-report.py b/bin/beads-report.py index 5675ec39cd..f53a4f33c9 100755 --- a/bin/beads-report.py +++ b/bin/beads-report.py @@ -39,7 +39,7 @@ Checks divide into two kinds, and the distinction matters: OBJECTIVE dangling edge targets; rationale on closed unpinned beads. Defects and facts. No judgment involved. - HEURISTIC decision beads with no rejected-alternative neighbour; roots with + HEURISTIC decisions with no rejected alternative recorded; roots with several tasks and no decisions. These cannot distinguish "no decisions were made" from "decisions were not captured", so they are questions for a human, never verdicts. @@ -169,14 +169,17 @@ def main(): # --- HEURISTIC --------------------------------------------------------- + # A rejected alternative's neighbour is the decision that beat it, which is not + # itself rejected -- so only the chosen side of a pair is worth checking here. lonely = [ f"{b['id']:18} {b['title'][:50]}" for b in beads.values() if b.get("issue_type") == "decision" - and not any("rejected-alternative" in (beads[n].get("labels") or []) + and (b.get("metadata") or {}).get("rejected") is not True + and not any((beads[n].get("metadata") or {}).get("rejected") is True for n in neighbours[b["id"]] if n in beads) ] - report("Decision beads with no rejected-alternative neighbour (suspect)", lonely) + report("Decisions with no rejected alternative recorded (suspect)", lonely) # `bd children --json` carries a `parent` field; `bd export` does not -- there # the hierarchy lives only in parent-child edges, which point child -> parent.
