Ranter
Join devRant
Do all the things like
++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatar
Sign Up
Pipeless API
From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple API
Learn More
Comments
-
YourMom15132dCan we crown you AI Slop Queen?
I really liked using AI to make re-entrant versions of C functions. I wanted to use strtok, but it saves info in the function. So not safe to use across threads (at least how I understand it). So I asked chatgpt to make a version that allowed me to feed it a pointer. Now pointer is localized on stack. -
YourMom15132dWhen people say they don't like AI. I think they mean stuff like this:
https://independent.co.uk/news/uk/...
lol -
Hazarth92352d504 lines seems a bit misleading, since things are just formatted to be one-liners and pretty much all the variables are really badly named. ^^; This reads more like obfuscated code than readable code.
In fact formatting this according to the pep8 rules yields 727 lines. Though sometimes the single-line formatting does work nicely and I don't hate it.
I think it could be simplified further though. This function irks me:
```
def is_truthy(s, v):
if v is None:
return False
if isinstance(v, (int, float)):
return v != 0
if isinstance(v, (str, list)):
return len(v) > 0
return True
```
especially since this is python you don't have to care about types *that much* I think it could be implemented like this:
```
def is_truthy(s, v):
return v not in ["", 0, [], {}, None]
```
the typeof can also be simplifed, but I'm out of chars -
YourMom15132d@Hazarth its been about 7 years since I was doing python everyday. I have forgotten how much python lets you get away with things you can't do in other languages.
-
retoor15541d@Hazarth upvote because you have actually read it. I think i stated that, i did not play much with the language and some exceptions may be possible. But don't make the common mistake to point out what an AI does wrong, look at all the sick stuff it does right! We really to focus on that to be moving forward. It's a majestic piece of coded, even with the small flaws it has. Also, in a realistic scenario, you would add stuff as review comment and you'll get answer to that question. I can't respond on the commentairy because i don't know it's reasoning. But what you have pointed out, i do not think it's wrong or bad quality or whatsoever. I really think it's worth a safe.
-
retoor15541d@afaIk I had to think what you mean with that comment because python barely has any, but you probably mean code-hiding. That a lot stuff happens under the hood. That is correct, but python is kinda like what AI is now. Kind of cheating for the sake of rapid development. I am sure that people about python were almost as pissed as AI regarding the level of cheating and that people with lesser skills are able to do great things. Rationally, python is many times a good choice. I limited myself to C and Python development for now, ignoring the other languages. This is because those two are in someway the opposite.
-
retoor15541d@YourMom you can crown me, but when is something slop and when is something sophisticated AI usage? If you call everything slop, the word dus not have meaning anymore.
-
YourMom15131d@retoor
Just the comparison against a whole bunch of unrelated types and it works properly. You would have to use variants or some shit in C++ to do this. It wouldn't be nearly as clean either.
I only say slop because it is common ignorant buzz word. I don't think what you are making is slop. Labeling all AI slop is just as ignorant as people who think AGI is around the corner. -
Wisecrack947523hWhat I've found AI is, is more a mirror of the user's intelligence.
It's decent at implementing things that a dev already has an understanding of.
Like when I started asking for the math behind ideas I had.
That and explaining things. It gives you something, you can ask what every single thing does, what every individual line of code or symbol means, and then synthesis it yourself, and check and verify the machine hasn't bullshitted along the way.
It's also good at implementing things the user *doesn't* understand, but those will frequently be implemented poorly, or flat out wrong.
But its come a long way.
I've mainly used it as a teacher. Most models are good enough to explain ideas in a way that you have enough of a grasp to then go read the actual documents for something and not be completely lost.
Related Rants
-
xjose97x20Just saw a variable in C named like this: long time_ago; //in a galaxy far away I laughed no stop. -
mijit20*Builds a web component for a client website* CLIENT: I don't like it, can I have it a tiny bit over to the r... -
elgringo41Student - Teacher renaming .c to .exe make the program executable ? Teacher - Yes A group of people stand up...

Dear diary,
It's really amazing what learning curve AI has but what you are able to do with in the end. I think I finally fully understand now and delivered three projects today. i made a FastAPI port from Python to C using a monster vibe. I created a production grade webdav server with user management and quota support. The webdav market is very limited. It does support the whole RFC (Latest one for webdav). This was a huge project. It became perfectly what I wanted. And, I had to wait until Claue was done with my monster prompt and I had my language specification. So I tought, I do another one but the most minimal source code but still the implementation that I had described (so far). This resulted in a 504 lines of code single file interpreter with a modern looking language supporting OOP and complex functions like split() (yeah, that is a complex function). I've just built it on the side and have no intentions with it, but the source code is so beautifully done that it's worth a repository: https://retoor.molodetz.nl/retoor/.... It's in Python (not a serious project) but readable for everyone. It's interesting source code but does not contain any good patterns relating interpreter design. But still; it works well and has quite some examples. It's cool to be able to read a whole interpreter source code. Just like the wren language, I have read all. was very cool. Wren regarding source code quality always #1.
Showing off, guaranteed zero upvotes :P
I am just happy, finally I can build big quality things. Quality is WAY higher and more compleet than I would've done it myself. All the investment was not for nothing, that's great. I do not have double coude and whatnot because of vibing style. New hobbie.
Programming language is hard to get performant (in comparison to Python for example) while it IS a bytecode interpreter. String concat is very slow, but there are tricks for that. My C will be a bit like Arduino C. IIRC it is C without having to take length for strings into account. But the new version of syntax will be as my 504 lines project mentioned here.
Happy retoor (L)
random
curve
python
fastapi
development
webdav
completed
ai
c
llm