Remix.run Logo
DrScientist 3 hours ago

Sometimes, particularly in the optimisation space, the clarity of the resulting code is a factor along with absolute performance - ie how easy is it for somebody looking at it later to understand it.

And what is 'understandable' could be a key difference between an AI bot and a human.

For example what's to stop an AI agent talking some code from an interpreted language and stripping out all the 'unnecessary' symbols - stripping comments, shortening function names and variables etc?

For a machine it may not change the understandability one jot - but to a human it has become impossible to reason over.

You could argue that replacing np.column_stack() with np.vstack().T() - makes it slightly more difficult to understand what's going on.

bagacrap an hour ago | parent [-]

The maintainers (humans) asked for this change.

To answer your other questions: instructions, including the general directive to follow nearby precedent. In my experience AI code is harder to understand because it's too verbose with too many low-value comments (explaining already clear parts of code). Much like the angry blog post here which uses way too many words and still misses the point of the rejection.

But if you specifically told it to obfuscate function names I'm sure it would be happy to do so. It's not entirely clear to me how that would affect a future agent's ability to interpret that file, because it still does use tools like grep to find call sites, and that wouldn't work so well if the function name is simply `f`. So the actual answer to "what's stopping it?" might be that we created it in our own image.