Automated code checks. Either custom linter rules (like ESLint) or prebuild scripts to enforce whatever architectural or style rules you want, basically all of the stuff that you'd normally flag in code review that can be codified into an automatic check but hasn't been before due to developers either not finding it worth their time to do it, or not having enough time or skill to do that - use the AI to write as many of these as needed, just like:
node prebuild/prebuild.cjs
which will then run all the other checks you've defined like: prebuild/ensure-router-routes-reference-views-not-regular-components.cjs
prebuild/ensure-custom-components-used-instead-of-plain-html.cjs
prebuild/ensure-branded-colors-used-instead-of-tailwind-ones.cjs
prebuild/ensure-eslint-disable-rules-have-explanations.cjs
prebuild/ensure-no-unused-translation-strings-present.cjs
prebuild/ensure-pinia-stores-use-setup-store-format.cjs
prebuild/ensure-resources-only-called-in-pinia-stores.cjs
prebuild/ensure-api-client-only-imported-in-resource-files.cjs
prebuild/ensure-component-import-name-matches-filename.cjs
prebuild/disallow-deep-component-nesting.cjs
prebuild/disallow-long-source-files.cjs
prebuild/disallow-todo-comments-without-jira-issue.cjs
...
and so on. You might have tens of these over the years of working on a project, plus you can write them for most things that you'd conceivably want in "good code". Examples above are closer to a Vue codebase but the same principles apply to most other types of projects out there - many of those would already be served by something like ESLint (you probably want the recommended preset for whatever ruleset exists for the stack you work with), some you'll definitely want to write yourself. And that is useful regardless of whether you even use AI or not, so that by the time code is seen by the person doing the review, hopefully all of those checks already pass.If "good code" is far too nebulous of a term to codify like that, then you have a way different and frankly more complex problem on your hands. If there is stuff that the AI constantly gets wrong, you can use CLAUDE.md as suggested elsewhere or even better - add prebuild script rules specifically for it.
Also, a tech stack with typing helps a bunch - making wrong code harder to even compile/deploy. Like, with TypeScript you get npm run type-check (tsc) and that's frankly lovely to be able to do, before you even start thinking about test coverage. Ofc you still should have tests that check the functionality of what you've made too, as usual.