←back to thread

421 points briankelly | 5 comments | | HN request time: 0s | source
Show context
necovek ◴[] No.43575664[source]
The premise might possibly be true, but as an actually seasoned Python developer, I've taken a look at one file: https://github.com/dx-tooling/platform-problem-monitoring-co...

All of it smells of a (lousy) junior software engineer: from configuring root logger at the top, module level (which relies on module import caching not to be reapplied), over not using a stdlib config file parser and building one themselves, to a raciness in load_json where it's checked for file existence with an if and then carrying on as if the file is certainly there...

In a nutshell, if the rest of it is like this, it simply sucks.

replies(23): >>43575714 #>>43575764 #>>43575953 #>>43576545 #>>43576732 #>>43576977 #>>43577008 #>>43577017 #>>43577193 #>>43577214 #>>43577226 #>>43577314 #>>43577850 #>>43578934 #>>43578952 #>>43578973 #>>43579760 #>>43581498 #>>43582065 #>>43583922 #>>43585046 #>>43585094 #>>43587376 #
nottorp ◴[] No.43576545[source]
Here's a rl example from today:

I asked $random_llm to give me code to recursively scan a directory and give me a list of file names relative to the top directory scanned and their sizes.

It gave me working code. On my test data directory it needed ... 6.8 seconds.

After 5 min of eliminating obvious inefficiencies the new code needed ... 1.4 seconds. And i didn't even read the docs for the used functions yet, just changed what seemed to generate too many filesystem calls for each file.

replies(1): >>43576568 #
bongodongobob ◴[] No.43576568[source]
Nice, sounds like it saved you some time.
replies(1): >>43576603 #
nottorp ◴[] No.43576603[source]
You "AI" enthusiasts always try to find a positive spin :)

What if I had trusted the code? It was working after all.

I'm guessing that if i asked for string manipulation code it would have done something worth posting on accidentally quadratic.

replies(3): >>43577234 #>>43578219 #>>43579068 #
FeepingCreature ◴[] No.43579068[source]
> What if I had trusted the code? It was working after all.

Then you would have been done five minutes earlier? I mean, this sort of reads like a parody of microoptimization.

replies(1): >>43579203 #
nottorp ◴[] No.43579203[source]
No, it reads like "your precious AI generates first year junior code". Like the original article.
replies(1): >>43579698 #
1. FeepingCreature ◴[] No.43579698[source]
There is nothing wrong with first year junior code that does the job.
replies(1): >>43580049 #
2. nottorp ◴[] No.43580049[source]
Does not. Do you know my requirements? This is actually in a time critical path.
replies(1): >>43580266 #
3. FeepingCreature ◴[] No.43580266[source]
Well, that wasn't in your comment. :P

If you hadn't told me that I would also not have bothered optimizing syscalls.

Did you tell the AI the profiler results and ask for ways to make it faster?

replies(1): >>43580694 #
4. nottorp ◴[] No.43580694{3}[source]
> Well, that wasn't in your comment. :P

Acting like a LLM now :P

> Did you tell the AI the profiler results and ask for ways to make it faster?

Looking for ways to turn a 10 minute job into a couple days?

replies(1): >>43583430 #
5. FeepingCreature ◴[] No.43583430{4}[source]
AI actually doesn't really work for the "a couple days" scale yet. As a heavy AI user, this sort of iterative correction would usually be priced in in a 10-minute AI session. That said-

> Acting like a LLM now :P

Hey, if we're going to be like that, it sure sounds like you gave the employee an incomplete spec so you could then blame it for failing. So... at least I'm not acting like a PM :P