Hacker News new | past | comments | ask | show | jobs | submit
We should probably take a step back and think about why we ever did code review in the first place. I'd say there were two primary forms: "mentor review" and "peer review".

"Mentor review" describes the situation where there is a knowledge imbalance between the author and reviewer. It can represent an onboarding situation but it isn't static - there are always areas of the codebase that some people are more familiar with than others.

A "peer review" is more the situation where both the author and reviewer have similar knowledge in a given area. The purpose of the review here is primarily to look for oversights.

I'd say, the peer review should be deprecated at this point. AI can generally do a better job at looking for minor / localized problems. The "mentor" type review should stay however as it is still very valuable.

In both cases, mentor and peer review, there's also an element of "does this make sense to someone else" that is important. The code can be technically correct, performant etc, but hard for another human to understand and inevitably (at least in the past) it was really really important for another human to be able to understand it at some point in the future.

It may be the case that code of today does not need a human to understand it in the future, but it feels like we're a very far way from that being true for code that organizations rely on.

It's not just about oversights. It's also about spreading the knowledge so someone who didn't write the code knows what's going on.

If you're never even properly reviewing the code you have no idea what it's doing under the hood.

And an LLM is not a compiler.

Is the value of the "mentor review" at the code level or the planning and engineering level though? If we are moving towards the AI writing the code then I feel like we should shift the review to the planning phase once the plan is committed. This would allow the more senior developer to mentor the junior on issues related to their understanding the problem and engineering a proper solution to hand to the AI coder.