| id | copy-paste-blindness | ||||
|---|---|---|---|---|---|
| name | Copy-Paste Blindness | ||||
| group | code-review | ||||
| severity | high | ||||
| scope | sessions | ||||
| version | 1 | ||||
| tags |
|
||||
| thresholds |
|
Detects sessions with large AI-generated code blocks that have no follow-up refinement, suggesting code is accepted without review.
{{count}} sessions have large AI-generated code blocks with no follow-up refinement. Code may be accepted without review.
Always review AI-generated code before accepting. Ask follow-up questions to refine, test, and understand the output.
{{extra.workspace}}: {{extra.aiLoc}} AI LOC, {{extra.messageCount}} messages, no refinement
scan: sessions
match: requestCount >= 2 AND flatSumField(requests, "aiCode", "loc") >= thresholds.minAiLoc AND NOT (\
anyWhere(slice(requests, 1), "messageText", "matches", "(?i)\\b(change|fix|modify|update|refactor|wrong|instead|actually|revert|redo|try again)\\b") OR \
someWhere(slice(requests, 1), "editedFiles.length", ">", 0))
aggregate: count
check: count >= thresholds.minSessions
examples: {{workspaceName}}: {{flatSumField(requests, "aiCode", "loc")}} AI LoC, no refinement