I'm collaborating with another developer on a React project, and I've noticed that they're making rapid progress while producing sizable files with structural issues, like poor component separation and an excessive number of 'useState' hooks. I'm starting to wonder if they might be using AI to generate most or all of their code. Are there any tools available to scan my codebase to identify files that may have been AI-generated? I want to figure out the best course of action—should I enforce certain coding standards or ask them to stop using AI altogether? I'd love to get some insights.
4 Answers
What’s the issue with AI-generated work? The focus should be on fixing the problems you encountered, not just blaming them on using AI.
To be frank, there are no reliable tools for detecting AI-generated content in code. OpenAI even advised against one tool that mistakenly flagged non-AI content as AI-generated. It's really tough to determine whether code was written with AI, so the best route is to watch them code through pair programming. From what you've said, it doesn't sound like classic AI issues to me, but rather a less experienced dev. I doubt AI would produce code with that many 'useState' hooks.
Honestly, unless there's a good reason not to use AI—like security risks—I wouldn't ban it. Focus on upholding coding standards. If they can make the most out of AI while still following the rules, why not? Just ensure they take a little time to clean things up afterward.
You might want to consider doing some pair programming sessions with them to see their thought process in real-time. It's also important to maintain coding standards. If their AI-generated code aligns with those standards, then who cares? AI is just another tool, similar to autocomplete, after all.

Related Questions
How To: Running Codex CLI on Windows with Azure OpenAI
Set Wordpress Featured Image Using Javascript
How To Fix PHP Random Being The Same
Why no WebP Support with Wordpress
Replace Wordpress Cron With Linux Cron
Customize Yoast Canonical URL Programmatically