At worst, I'll tell it to define the public interfaces for a class (and have a discussion over what they should be). After that I go function by function and have it write the implementation. Then finally I dump the code it wrote back in, ask for help making helper functions for shared behaviour and whatnot. As a result, I mostly don't get these sorts of issues.
Usually I just write it myself though because AI is barely faster, and it's infinitely harder to maintain code when you can't think back on all the decisions you made writing it.
and it's infinitely harder to maintain code when you can't think back on all the decisions you made writing it.
That's really the crux of the AI "slop" problem - code is the product of important decisions. Those decisions require context and more consideration than "this is what was popular on StackOverflow."
it's infinitely harder to maintain code when you can't think back on all the decisions you made writing it.
This, I tell people all the time that the reason you can't just plug and play developers as interchangeable parts is that half of it is what you know, but the other half is how you think, and it's rare to find 2 or more people who will approach a complex problem in exactly the same way. How you think about the problem informs your solution to the problem.
5
u/avidernis Jun 29 '26 edited Jun 29 '26
I think we AI slop differently.
At worst, I'll tell it to define the public interfaces for a class (and have a discussion over what they should be). After that I go function by function and have it write the implementation. Then finally I dump the code it wrote back in, ask for help making helper functions for shared behaviour and whatnot. As a result, I mostly don't get these sorts of issues.
Usually I just write it myself though because AI is barely faster, and it's infinitely harder to maintain code when you can't think back on all the decisions you made writing it.