Yeah if you just let it run wild, it will produce subpar results. But that is not much different from humans tbh.
When you discuss design and architecture first, and write that out in a design doc or something along those lines, it works quite well for the most part.
And 9 out of 10 times when it produces some poor results, just asking "is this really a good approach?" or just stating "This code makes me very sad" it will most of the time do a really good job of analysing why that code is bad and how to improve it.
Analyzing? No. It’s just being sycophantic. Try it on code that’s actually correct - it’ll go all “oh you’re absolutely right” and wreck it anyway.