feat(ce-resolve-pr-feedback): tighten clustering to cross-round only#611
Merged
feat(ce-resolve-pr-feedback): tighten clustering to cross-round only#611
Conversation
…ound evidence for clustering Drop single-round clustering and tighten the cross-invocation gate with a cheap spatial-overlap precheck. New-only groups no longer trigger cluster analysis; a cluster must contain at least one previously-resolved thread. The precheck compares paths only — no LLM calls — so the cross_invocation.signal false-positive tax is cut off before full categorization runs. Resolver agent drops the systemic/coincidental (single-round) assessment branch. Cluster briefs always represent a cross-invocation cluster, so <prior-resolutions> is mandatory and the three cross-round modes (band-aid / correct-but-incomplete / sound-and-independent) are the only ones left. Rationale: single-round clustering typically bailed as "coincidental" after paying full categorization and broader-area read costs. First-round "one helper fits all" opportunities are intentionally handled as individual fixes until repeated reviewer evidence promotes the pattern.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Clustering in
ce-resolve-pr-feedbacknow requires cross-round evidence before it activates. The volume-only trigger (3+ new comments) is removed, and thecross_invocationsignal is paired with a cheap spatial-overlap precheck so an unrelated resolved thread no longer pays for full category analysis.Why this changes
The prior design let cluster analysis fire from either (a) 3+ new comments in one review round, or (b) the script reporting any mix of resolved and unresolved threads. In practice, single-round clusters usually bailed as "coincidental" after already paying full categorization and broader-area read costs. The cross-invocation gate was broad enough that a PR with one ancient unrelated resolved thread plus one new unrelated thread would still enter analysis.
Clustering now only activates when reviewers have flagged the same area across multiple rounds. That is the evidence shape where "investigate siblings for the same issue" (the correct-but-incomplete mode) earns its keep.
Gate logic
cross_invocation.signaltrue, no path overlap with resolved threadscross_invocation.signaltrue, new thread shares file or directory subtree with a resolved threadThe spatial-overlap precheck compares paths only. No category inference, no LLM calls, so the false-positive tax is cut off before full categorization runs. Only inline
review_threadswith file paths participate;pr_commentsandreview_bodiesare always dispatched individually regardless of clustering.Resolver agent
ce-pr-comment-resolver's cluster-mode workflow drops the single-round branch.<prior-resolutions>is now mandatory in every cluster brief, so the three cross-round assessment modes (band-aid / correct-but-incomplete / sound-and-independent) are the only paths left. The systemic and coincidental single-round modes are removed.Tradeoff, noted explicitly
First-round reviewer feedback that happens to point at a shared abstraction opportunity (e.g., "these 4 comments all want the same helper") is now handled as individual fixes instead of a coordinated cluster. This is the intentional tradeoff: the dispatch-coordination value of single-round clustering was judged to be outweighed by the scope-creep risk of LLM-driven holistic refactors on thin evidence. The skill body calls this out so the decision can be revisited if the failure appears in practice.