Commit Graph

1 Commits

Author SHA1 Message Date
Claude
b868c24c84 feat: improve autofix suggestion detection for PR comments
Add detection logic to recognize actionable suggestions in PR comments, even when
they come from bot accounts like claude[bot]. This addresses the issue where the
autofix workflow incorrectly classified clear bug fix suggestions as not actionable.

New features:
- detectActionableSuggestion(): Analyzes comment body for actionable patterns
- Detects GitHub inline committable suggestions (```suggestion blocks)
- Detects clear bug fix language patterns (e.g., "should be", "change to", "replace with")
- Detects code alternatives and fix recommendations
- Returns confidence level (high/medium/low) and reason for the determination
- checkContainsActionableSuggestion(): Context-aware wrapper for GitHub events
- checkContainsTriggerOrActionableSuggestion(): Combined trigger and suggestion check
- checkIsActionableForAutofix(): Convenience function for autofix workflows
- extractSuggestionCode(): Extracts code from GitHub suggestion blocks

This enables workflows to automatically apply suggestions from code review comments,
improving the developer experience for PR reviews.
2026-01-12 03:04:17 +00:00