• shirasho@feddit.online
    link
    fedilink
    English
    arrow-up
    41
    arrow-down
    10
    ·
    11 hours ago

    LLMs suck at writing code, but they are absolutely amazing at reading code and finding bugs. I am firmly against the usage of LLMs to write anything, but they have a place as a diagnostics tool when verified by a human.

    • MangoCats@feddit.it
      link
      fedilink
      English
      arrow-up
      5
      ·
      edit-2
      5 hours ago

      I find that depends a LOT on what you’re asking the LLM to write, how well you’re specifying it, etc. As for the code reviews, if it’s code that matters: remember to open a new instance and ask the exact same question again on the code that has been reviewed and “fixed”. Back a year ago, that could get you into a waffle-loop where the engine would change its mind back and forth about what’s optimal and just oscillate between the two. These days they seem to record (and read) enough context to prevent that behavior, but I definitely get behavior of: “Are there any bugs?” “Yes, here are seven bugs.” “Fix those bugs.” “The bugs are fixed.” (and they ususally really are…) “Are there any more bugs?” “No, we have fixed ALL the bugs.” “Are you sure, look again.” “Yes, I am sure we have found and fixed ALL the bugs.” — new context window — “Are there any bugs?” “Yes, here are seven bugs.” different bugs.

      I did that on a bigger project and literally repeated 20 times, finding 140 real bugs - granted, the later bugs were getting pretty trivial / far out edge cases, but they were still real, still fixed, still denied there were any more bugs until opening a fresh context and asking again. This was on Google’s Gemini 3.7 Flash High… Claude Opus 4.8+ seems quite a bit better about being able to continue in a context without becoming blind to issues “it has already solved.”

    • rumba@lemmy.zip
      link
      fedilink
      English
      arrow-up
      2
      ·
      5 hours ago

      IMO: Specifically, they’re bad at architecture and refactoring a small project into a large project. You have to jump through some hoops to make it craft something that needs more than 8m of context ram. If you can manage orchestration and multi-agents that don’t need to know each others context, you can start to pull off bigger stuff, but it’s not a forgone conclusion that it’ll be fine. The worst output comes from it getting stuck on something and trying less likely answers successively until it works. You really have to watch for it to struggle and at the very least stop and start to try some new randoms.

      Also, anything other than Claude-code with some really well-done project definitions is a waste of time.

    • BeKindRewind@lemmy.world
      link
      fedilink
      English
      arrow-up
      3
      ·
      8 hours ago

      There are already several large projects that have hundreds of thousands of users and those projects were almost completely vibe coded. It’s almost the entire retro “recomp” scene now.

      • MangoCats@feddit.it
        link
        fedilink
        English
        arrow-up
        1
        ·
        5 hours ago

        I have done several smaller projects with it, and they have been stable / performant for months - better than similar stuff I coded years earlier and spent 5-10x the effort on.

    • ragas@lemmy.ml
      link
      fedilink
      English
      arrow-up
      2
      ·
      7 hours ago

      At my company we are currently moving to implement AI for exactly that. A cost effective review buddy.

      Various developers have tried to use it for coding and I think apart for one time scripts or getting an initial structure generated, noone is convinced of AI.

    • datavoid@sh.itjust.works
      link
      fedilink
      English
      arrow-up
      9
      arrow-down
      3
      ·
      10 hours ago

      Line completion is pretty damn handy, it’s when you start asking for whole functions that things go downhill

      • ViceroTempus@lemmy.world
        link
        fedilink
        English
        arrow-up
        3
        arrow-down
        2
        ·
        9 hours ago

        Yeah I’ve been using LLM’s in Rider for over a decade. I don’t have a problem with LLM’s. I do have a problem with how they’re currently used, and how people keep trying to use them to replace their own thinking.

        I think they have a place in the coding scene, a limited niche place, but a place none the less. They just aren’t a replacement for software engineers. Architecture and intention are the big differences to me. An LLM cannot understand intention, it just makes statistical guesses that are often wrong.

        • MangoCats@feddit.it
          link
          fedilink
          English
          arrow-up
          2
          ·
          5 hours ago

          An LLM cannot understand intention, it just makes statistical guesses that are often wrong.

          True, when you give a prompt like: “make me a contact management / constant contact app which I can deploy on AWS and scale to 100,000 users.” you get, mostly garbage. If you specify how you want the UX to flow, what fields are most important, what fields should be included in deeper interfaces, what the scheduling looks like, how it gets tuned, what the reports look like, etc. etc. etc. - in other words: give it real requirements and specifications.

          Then, pay attention as it develops, you’ll ususally find that the requirements you gave it aren’t exactly what you really wanted, and when you see what it built that doesn’t match with your visions, you can have it revise the requirements and specs.

          • ViceroTempus@lemmy.world
            link
            fedilink
            English
            arrow-up
            1
            ·
            edit-2
            4 hours ago

            Sure, but for me its just faster to write it myself, in a way that needs to fit into the project. And while I’m aware you can give this context to an LLM, it still can’t read what your previous intentions were, nor what they are currently. So its hard for it to build on it.

            To me they’re best as auto-complete, or research tools in the same vein as StackOverflow. Something to help speed up your existing workflow. Also good at translating both spoken languages, and functions into other coding languages. Everything else seems to get in the way for me.

            • MangoCats@feddit.it
              link
              fedilink
              English
              arrow-up
              2
              ·
              3 hours ago

              Also good at translating both spoken languages

              I know more than a few fluently multi-lingual people who would just roll their eyes…

            • MangoCats@feddit.it
              link
              fedilink
              English
              arrow-up
              1
              ·
              3 hours ago

              There definitely are tasks where using the “standard tools” goes far faster than asking the LLM to do it for you, such as: copying signatures from images onto a .pdf contract - they’re pretty hopeless at editing out background noise, etc. but if you clean up the signature input images enough, they’ll take it home and make the ink solid and the background transparent and overlay them in the .pdf faster than you can open the four files in Photoshop or whatever your tool of choice is.

              By the way, images of signatures on electronic documents have been an outrageous farce since 20 years now, LLMs just make it easier than ever to edit them into an existing .pdf

              Thing is, there’s literally millions of common “computer tasks” and the LLMs themselves are just starting to “learn” which ones they’re good at and which they are not. It would be cool if Opus would self-identify “hey, I’m really good at this…” and “I’m pretty challenged with that, you’d be better off downloading this FOSS tool and doing it yourself, here are helpful instructions…”

    • rothaine@lemmy.zip
      link
      fedilink
      English
      arrow-up
      5
      arrow-down
      3
      ·
      9 hours ago

      Opus-class and higher models are actually great at writing code, but maybe it’s language dependent? I primarily work in TypeScript.

      • aquovie@lemmy.cafe
        link
        fedilink
        English
        arrow-up
        11
        ·
        8 hours ago

        More than anything, it depends on the developer using it. In my experience, most are just slop shovelers that don’t read or review what Claude does. Then it falls on the PR reviewer (me) to be an asshole: Did you review your own code? Do you understand what this part over here does? Why did you choose this method versus alternatives?

        Unless you tell Claude/Opus otherwise, it’s not going to take the initiative to refactor things, tidy up parts it didn’t touch, or hell, it won’t even spellcheck things. Can you really call it a language model if it outputs misspelled words? Its unit tests are great boilerplate but never comprehensive enough for me.

        Claude is the developer that puts zero pride or effort in their work beyond the bare minimum to not get fired.

        • rothaine@lemmy.zip
          link
          fedilink
          English
          arrow-up
          1
          ·
          1 hour ago

          Yes I agree, and honestly code review is now the key skill.

          My company recently started exploring “AI interviewing”, to test candidates on “AI proficiency”, and the questions are all around prompt engineering (is that even a thing anymore?) and stuff. Like no, make sure they can read the fucking code!

        • MangoCats@feddit.it
          link
          fedilink
          English
          arrow-up
          2
          ·
          5 hours ago

          Prompting for refactoring, requirements, specifications, unit tests, integration tests, distribution / install scripts, all of those “good ideas” are things you need to nudge even Claude to do. Once you get it in the habit of doing them it does them automatically more often but still requires the occasional nudge.

      • CancerMancer@sh.itjust.works
        link
        fedilink
        English
        arrow-up
        9
        arrow-down
        1
        ·
        8 hours ago

        I’m not terribly concerned if people write code and test it with AI, so long as they verify the results themselves.

        I recently saw someone try to add a PR to something on github with thousands of lines of changes and then they got mad when people didn’t want to do the free labour verifying it. That is a bullshit use of AI

        • rothaine@lemmy.zip
          link
          fedilink
          English
          arrow-up
          1
          ·
          56 minutes ago

          What are you trying to have it do? I work in a very large and complex codebase, and it honestly scares me sometimes.

        • rothaine@lemmy.zip
          link
          fedilink
          English
          arrow-up
          1
          ·
          58 minutes ago

          I used to be of that mind as well. But the newer models are just too good to deny it any longer.

    • luciferofastora@feddit.org
      link
      fedilink
      English
      arrow-up
      1
      arrow-down
      1
      ·
      edit-2
      7 hours ago

      If we ever find a way to deal with the whole “burning the planet” issue, their best use case is to find and match patterns, not to imitate them.

      The idea of using a language model to process search engine input isn’t the dumbest part about Gemini and plenty of people report good results finding information easier and quicker with ChatGPT. In those cases, the deviation from rigid keywords is desirable because it can match results with related words rather than literal word-matching. Google Search already did a decent job at that (before the enshittification ran rampant), which more complex language models could improve even further.

      The landmine is in their reproduction of those results, where the generated “summary” is the equivalent of a cunning bullshitter that convincingly sounds like he understood the topic but actually has no clue and just delivers a best guess. That’s where the deviation becomes a risk of misinformation or introducing bugs.

      They should narrow things down by finding the likely answers where that matters, not produce more stuff that humans will have to double-check.