Scan the codebase for refactoring opportunities from the perspective of a senior engineer who has cleaned up a lot of AI-generated code