Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Brand Logo

agnos.is Forums

  1. Home
  2. Programmer Humor
  3. the beautiful code

the beautiful code

Scheduled Pinned Locked Moved Programmer Humor
programmerhumor
226 Posts 135 Posters 0 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • P [email protected]

    Sure, the marketing of LLMs is wildly overstated. I would never argue otherwise. This is entirely a red herring, however.

    I’m saying you should use the tools for what they’re good at, and don’t use them for what they’re bad at. I don’t see why this is controversial at all. You can personally decide that they are good for nothing. Great! Nobody is forcing you to use AI in your work. (Though if they are, you should find a new employer.)

    W This user is from outside of this forum
    W This user is from outside of this forum
    [email protected]
    wrote on last edited by
    #94

    Totally agree with that and I don't think anybody would see that as controversial. LLMs are actually good in a lot of things, but not thinking and typically not if you are an expert. That's why LLMs know more about the anatomy of humans than I do, but probably not more than most people with a medical degree.

    1 Reply Last reply
    0
    • P [email protected]

      Well yeah, it’s working from an incomplete knowledge of the code base. If you asked a human to do the same they would struggle.

      LLMs work only if they can fit the whole context into their memory, and that means working only in highly limited environments.

      M This user is from outside of this forum
      M This user is from outside of this forum
      [email protected]
      wrote on last edited by
      #95

      No, a human would just find an API that is publically available. And the fact that it knew the static class "Misc" means it knows the api. It just halucinated and responded with bullcrap. The entire concept can be summarized with "I want to color a player's model in GAME using python and SCRIPTING ENGINE".

      1 Reply Last reply
      3
      • S [email protected]

        4o has been able to do this for months.

        B This user is from outside of this forum
        B This user is from outside of this forum
        [email protected]
        wrote on last edited by [email protected]
        #96

        I tried, it can't get trough four lines without messing up. Unless I give it tasks that are so stupendously simple that I'm faster typing them myself while watching tv

        S 1 Reply Last reply
        3
        • P [email protected]

          Uh yeah, like all the time. Anyone who says otherwise really hasn’t tried recently. I know it’s a meme that AI can’t code (and still in many cases that’s true, eg. I don’t have the AI do anything with OpenCV or complex math) but it’s very routine these days for common use cases like web development.

          B This user is from outside of this forum
          B This user is from outside of this forum
          [email protected]
          wrote on last edited by
          #97

          You must be a big fan of boilerplate

          P 1 Reply Last reply
          4
          • P [email protected]

            To be fair, if I wrote 3000 new lines of code in one shot, it probably wouldn’t run either.

            LLMs are good for simple bits of logic under around 200 lines of code, or things that are strictly boilerplate. People who are trying to force it to do things beyond that are just being silly.

            O This user is from outside of this forum
            O This user is from outside of this forum
            [email protected]
            wrote on last edited by
            #98

            Perhaps 5 LOC. Maybe 3. And even then I'll analyze every single character in wrote. And then I will in fact find bugs. Most often it hallucinates some functions that would be fantastic to use - if they existed.

            B 1 Reply Last reply
            4
            • alk@sh.itjust.worksA [email protected]

              Code that works is also just text.

              mubelotix@jlai.luM This user is from outside of this forum
              mubelotix@jlai.luM This user is from outside of this forum
              [email protected]
              wrote on last edited by
              #99

              It is text, but not just text

              1 Reply Last reply
              3
              • D [email protected]

                I use ChatGPT for Go programming all the time and it rarely has problems, I think Go is more niche than Kotlin

                O This user is from outside of this forum
                O This user is from outside of this forum
                [email protected]
                wrote on last edited by
                #100

                I get a bit frustrated at it trying to replicate everyone else's code in my code base. Once my project became large enough, I felt it necessary to implement my own error handling instead of go's standard, which was not sufficient for me anymore. Copilot will respect that for a while, until I switch to a different file. At that point it will try to force standard go errors everywhere.

                D 1 Reply Last reply
                0
                • codiunicorn@programming.devC [email protected]
                  This post did not contain any content.
                  1984@lemmy.today1 This user is from outside of this forum
                  1984@lemmy.today1 This user is from outside of this forum
                  [email protected]
                  wrote on last edited by [email protected]
                  #101

                  Its like having a junior developer with a world of confidence just change shit and spend hours breaking things and trying to fix them, while we pay big tech for the privilege of watching the chaos.

                  I asked chat gpt to give me a simple squid proxy config today that blocks everything except https. It confidently gave me one but of course it didnt work. It let through http and despite many attempts to get a working config that did that, it just failed.

                  So yeah in the end i have to learn squid syntax anyway, which i guess is fine, but I spent hours trying to get a working config because we pay for chat gpt to do exactly that....

                  F merc@sh.itjust.worksM N 3 Replies Last reply
                  16
                  • B [email protected]

                    You must be a big fan of boilerplate

                    P This user is from outside of this forum
                    P This user is from outside of this forum
                    [email protected]
                    wrote on last edited by
                    #102

                    Not sure what you mean, boilerplate code is one of the things AI is good at.

                    Take a straightforward Django project for example. Given a models.py file, AI can easily write the corresponding admin file, or a RESTful API file. That’s generally just tedious boilerplate work that requires no decision making - perfect for an AI.

                    More than that and you are probably babysitting the AI so hard that it is faster to just write it yourself.

                    1 Reply Last reply
                    3
                    • O [email protected]

                      Perhaps 5 LOC. Maybe 3. And even then I'll analyze every single character in wrote. And then I will in fact find bugs. Most often it hallucinates some functions that would be fantastic to use - if they existed.

                      B This user is from outside of this forum
                      B This user is from outside of this forum
                      [email protected]
                      wrote on last edited by
                      #103

                      My guess is what's going on is there's tons of psuedo code out there that looks like it's a real language but has functions that don't exist as placeholders and the LLM noticed the pattern to the point where it just makes up functions, not realizing they need to be implemented (because LLMs don't realize things but just pattern match very complex patterns).

                      1 Reply Last reply
                      3
                      • O [email protected]

                        well, it only took 2 years to go from the cursed will smith eating spaghetti video to veo3 which can make completely lifelike videos with audio. so who knows what the future holds

                        T This user is from outside of this forum
                        T This user is from outside of this forum
                        [email protected]
                        wrote on last edited by
                        #104

                        The cursed Will Smith eating spaghetti wasn't the best video AI model available at the time, just what was available for consumers to run on their own hardware at the time. So while the rate of improvement in AI image/video generation is incredible, it's not quite as incredible as that viral video would suggest

                        W 1 Reply Last reply
                        2
                        • C [email protected]

                          This is interesting, I would be quite impressed if this PR got merged without additional changes.

                          I am genuinely curious and no judgement at all, since you mentioned that you are not a rust/GTK expert, are you able to read and and have a decent understanding of the output code?

                          For example, in the sway.rs file, you uncommented a piece of code about floating nodes in get_all_windows function, do you know why it is uncommented? (again, not trying to judge; it is a genuine question. I also don't know rust or GTK, just curious.

                          M This user is from outside of this forum
                          M This user is from outside of this forum
                          [email protected]
                          wrote on last edited by
                          #105

                          This is interesting, I would be quite impressed if this PR got merged without additional changes.

                          We'll see. Whether it gets merged in any form, it's still a big win for me because I finally was able to get some changes implemented that I had been wanting for a couple years.

                          are you able to read and and have a decent understanding of the output code?

                          Yes. I know other coding languages and CSS. Sometimes Claude generated code that was correct but I thought it was awkward or poor, so I had it revise. For example, I wanted to handle a boolean case and it added three booleans and a function for that. I said no, you can use a single boolean for all that. Another time it duplicated a bunch of code for the single and multi-monitor cases and I had it consolidate it.

                          In one case, It got stuck debugging and I was able to help isolate where the error was through testing. Once I suggested where to look harder, it was able to find a subtle issue that I couldn't spot myself. The labels were appearing far too small at one point, but I couldn't see that Claude had changed any code that should affect the label size. It turned out two data structures hadn't been merged correctly, so that default values weren't getting overridden correctly. It was the sort of issue I could see a human dev introducing on the first pass.

                          do you know why it is uncommented?

                          Yes, that's the fix for supporting floating windows. The author reported that previously there was a problem with the z-index of the labels on these windows, so that's apparently why it was implemented but commented out. But it seems due to other changes, that problem no longer exists. I was able to test that labels on floating windows now work correctly.

                          Through the process, I also became more familiar with Rust tooling and Rust itself.

                          C Z 2 Replies Last reply
                          4
                          • 1984@lemmy.today1 [email protected]

                            Its like having a junior developer with a world of confidence just change shit and spend hours breaking things and trying to fix them, while we pay big tech for the privilege of watching the chaos.

                            I asked chat gpt to give me a simple squid proxy config today that blocks everything except https. It confidently gave me one but of course it didnt work. It let through http and despite many attempts to get a working config that did that, it just failed.

                            So yeah in the end i have to learn squid syntax anyway, which i guess is fine, but I spent hours trying to get a working config because we pay for chat gpt to do exactly that....

                            F This user is from outside of this forum
                            F This user is from outside of this forum
                            [email protected]
                            wrote on last edited by
                            #106

                            Man, I can't wait to try out generative AI to generate config files for mission critical stuff!
                            Imagine paying all of us devops wankers when my idiot boss can just ask Chat GPT to sort all this legacy mess we're juggling with on the daily!

                            1 Reply Last reply
                            9
                            • codiunicorn@programming.devC [email protected]
                              This post did not contain any content.
                              A This user is from outside of this forum
                              A This user is from outside of this forum
                              [email protected]
                              wrote on last edited by
                              #107

                              I've used it extensively, almost $100 in credits, and generally it could one shot everything I threw at it. However: I gave it architectural instructions and told it to use test driven development and what test suite to use. Without the tests yeah it wouldn't work, and a decent amount of the time is cleaning up mistakes the tests caught. The same can be said for humans, though.

                              lyra_lycan@lemmy.blahaj.zoneL 1 Reply Last reply
                              7
                              • M [email protected]

                                Conversely, code that works is also text

                                S This user is from outside of this forum
                                S This user is from outside of this forum
                                [email protected]
                                wrote on last edited by
                                #108

                                But not just text

                                Also that's not converse to what the parent comment said

                                M 1 Reply Last reply
                                4
                                • codiunicorn@programming.devC [email protected]
                                  This post did not contain any content.
                                  C This user is from outside of this forum
                                  C This user is from outside of this forum
                                  [email protected]
                                  wrote on last edited by
                                  #109

                                  Laugh it up while you can.

                                  We're in the "haha it can't draw hands!" phase of coding.

                                  G S 2 Replies Last reply
                                  3
                                  • C [email protected]

                                    Laugh it up while you can.

                                    We're in the "haha it can't draw hands!" phase of coding.

                                    G This user is from outside of this forum
                                    G This user is from outside of this forum
                                    [email protected]
                                    wrote on last edited by
                                    #110

                                    someone drank the koolaid.

                                    LLMs will never code for two reasons.

                                    one, because they only regurgitate facsimiles of code. this is because the models are trained to ingest content and provide an interpretation of the collection of their content.

                                    software development is more than that and requires strategic thought and conceptualization, both of which are decades away from AI at best.

                                    two, because the prevalence of LLM generated code is destroying the training data used to build models. think of it like making a copy of a copy of a copy, et cetera.

                                    the more popular it becomes the worse the training data becomes. the worse the training data becomes the weaker the model. the weaker the model, the less likely it will see any real use.

                                    so yeah. we're about 100 years from the whole "it can't draw its hands" stage because it doesn't even know what hands are.

                                    C 1 Reply Last reply
                                    4
                                    • C [email protected]

                                      Laugh it up while you can.

                                      We're in the "haha it can't draw hands!" phase of coding.

                                      S This user is from outside of this forum
                                      S This user is from outside of this forum
                                      [email protected]
                                      wrote on last edited by
                                      #111

                                      AI bad.
                                      But also, video AI started with will Will Smith eating spaghetti just a couple years ago.

                                      We keep talking about AI doing complex tasks right now and it's limitations, then extrapolating its development linearly. It's not linear and it's not in one direction. It's a exponential and rhizomatic process. Humans always over-estimate (ignoring hard limits) and under-estimate (thinking linearly) how these things go. With rocketships, with internet/social media, and now with AI.

                                      1 Reply Last reply
                                      1
                                      • A [email protected]

                                        I've used it extensively, almost $100 in credits, and generally it could one shot everything I threw at it. However: I gave it architectural instructions and told it to use test driven development and what test suite to use. Without the tests yeah it wouldn't work, and a decent amount of the time is cleaning up mistakes the tests caught. The same can be said for humans, though.

                                        lyra_lycan@lemmy.blahaj.zoneL This user is from outside of this forum
                                        lyra_lycan@lemmy.blahaj.zoneL This user is from outside of this forum
                                        [email protected]
                                        wrote on last edited by
                                        #112

                                        How can it pass if it hasn't had lessons.. Well said. Ooh I wonder if lecture footage would be able to teach AI, or audio in from tutors..

                                        1 Reply Last reply
                                        1
                                        • codiunicorn@programming.devC [email protected]
                                          This post did not contain any content.
                                          S This user is from outside of this forum
                                          S This user is from outside of this forum
                                          [email protected]
                                          wrote on last edited by
                                          #113

                                          Honest question: I haven't used AI much. Are there any AIs or IDEs that can reliably rename a variable across all instances in a medium sized Python project? I don't mean easy stuff that an editor can do (e.g. rename QQQ in all instances and get lucky that there are no conflicts). I mean be able to differentiate between local and/or library variables so it doesn't change them, only the correct versions.

                                          L L B K P 8 Replies Last reply
                                          4
                                          Reply
                                          • Reply as topic
                                          Log in to reply
                                          • Oldest to Newest
                                          • Newest to Oldest
                                          • Most Votes


                                          • Login

                                          • Login or register to search.
                                          • First post
                                            Last post
                                          0
                                          • Categories
                                          • Recent
                                          • Tags
                                          • Popular
                                          • World
                                          • Users
                                          • Groups