-
Notifications
You must be signed in to change notification settings - Fork 1
Build Loop Circular Progress Detection with Intervention Suggestions #654
Open
Description
Strategic Improvement
Detect when build loop iterations make lateral moves instead of forward progress (e.g., repeatedly fixing the same test differently, or ping-ponging between two states). When circular progress is detected, pause and suggest alternative approaches or request human intervention. This prevents wasted iterations and improves success rate by catching "going in circles" patterns early.
Acceptance Criteria
- Analyze git diffs between consecutive iterations to detect repeated changes to same files/lines
- Calculate progress metrics: forward movement vs. lateral churn ratio
- Detect circular patterns: if last 3 iterations show <20% unique changes, flag as circular
- When detected, write .claude/circular-progress-alert.md with analysis and suggested interventions
- Emit event "build_loop_circular_progress" with iteration numbers and affected files
- Add --strict-progress flag to loop that fails fast on circular detection
- Unit tests validating detection logic with synthetic iteration histories
Context
- Priority: P0
- Complexity: fast
- Generated by: Strategic Intelligence Agent
- Strategy alignment: P0: Reliability & Success Rate