Code quality in the AI age

Posted by europe_man@reddit | ExperiencedDevs | View on Reddit | 110 comments

This has been bothering me for quite some time now. With the advance of AI tools, we see more and more AI generated code in our projects. Now, stakeholders want speed, so they always value features over good and clean code. And, I don't blame them for it, makes sense from their perspective. Makes sense for the business.

But, due to fast pace, quality degrades, naturally. I mean, you can have standards, guidelines, guardrails, etc. However, at some point, if you become too strict then you become a blocker in the process and need to loosen up. Once that happens, code becomes average or below it, so there is pretty much zero chance of having a human glance over it. It always starts with AI and ends with AI. It is very hard to verify the intent behind the code or the bigger picture.

Now, some people push for this. We pass the torch from individuals (that might choose to leave a company at any point) to the AI that is always available. The argument for this is that you can always rewrite whatever feature you want as long as you use the AI. So, code quality, strict guidelines, etc. do not even matter as you are far isolated from the code and the solution. My argument would be, well, you need to verify changes, make sure they do what they do, etc. Again, the counter-argument is that you can test it and ensure it works. This becomes a never ending loop.

Obviously, I have my own opinion on the code quality and how the code should look like. But, that opinion is based on the pre-AI era. I still think it is relevant, I'd say even more than before, but, it is again my opinion. I can say that there are many other people with similar opinion, but there are many (maybe even more) on the other side pushing for shipping fast without thinking about code or code quality.

tl;dr: What is your stance on code quality in this age? How do you ensure you are not an engineer always pushing back on solutions due to poor quality when most other think it is irrelevant because of AI? I don't want to give up on my standards, but, maybe they are too wired to the traditional coding world and should be heavily adjusted?