• Mniot@programming.dev
    link
    fedilink
    English
    arrow-up
    7
    arrow-down
    1
    ·
    7 hours ago

    I’ve heard this from others, too. I don’t really get it.

    I watched a teammate working with AI:

    1. Identify the problem: a function was getting passed an object-field when it should be getting the whole object
    2. Write instruction to the AI: “refactor the function I’ve selected to take a Foo instead of a String or Box<String>. Then in the Foo function, use the bar parameter. Don’t change other files or functions.”
    3. Wait ~5s for Cursor to do it

    It did the instructions and didn’t fuck anything up, so I guess it was a success? But they already knew exactly what the fixed code should look like, so it seems like they just took a slow and boring path to get there.

    When I’m working with a new intern, they cost me time. Everything is 2-4x slower. It’s worth it because (a) I like working with people and someone just getting into programming makes me feel happy and (b) after a few months I’m able to trust that they can do things on their own and I’m not constantly checking to see if they’ve actually deleted random code or put an authentication check on an unauthenticated endpoint etc etc. The point of an intern is to see if you want to hire them as a jr dev who will actually become worthwhile in 6+ months.

    • ShortFuse@lemmy.world
      link
      fedilink
      English
      arrow-up
      1
      arrow-down
      7
      ·
      6 hours ago

      There’s a lot of false equivalence in this thread which seems to be a staple of this instance. I’m sure most people here have never used AI coding and I’m just getting ad-hominem “counterpoints”.

      Nothing I said even close to saying AI is a full replacement for training junior devs.

      The reality is, when you actually use an AI as a coding assistant there are strong similarities when training somebody who is new to coding. They’ll choose popular over best practices. When I get an AI assisted code segment, it feels similar to copypasted code from a stackoverflow. This is aside from the hallucinations.

      But LLM operate on patterns, for better or for worse. If you want to generate something serious, that’s a bad idea. There’s a strong misconception that AI will build usable code for you. It probably won’t. It’s only good at snippets. But it does recognize patterns. Some of those patterns are tedious to write, and I’d argue feel even more tedious the more experienced you are in coding.

      My most recent usage of AI was making some script that uses WinGet to setup a dev environment. Like I have a vague recollection of how to make a .cmd script with if branches, but not enough at the top of my head. So you can say “Generate a section here that checks if WinSDK is installed.” And it will. Looks fine, move on. The %errorlevel% code is all injected. Then say “add on a WinGet install if it’s not installed.” Then it does that. Then I have to repeat all that again for ninja, clang, and others. None of this is mission critical, but it’s a chore to write. It’ll even sprinkle some pretty CLI output text.

      There is a strong misconception that AI are “smart” and programmers should be worried. That’s completely overselling what AI can do and probably intentionally by executives. They are at best assistant to coders. I can take a piece of JS code and ask AI to construct an SQL table creation query based on the code (or vice versa). It’s not difficult. Just tedious.

      When working in teams, it’s not uncommon for me to create the first 5%-10% of a project and instruct others on the team to take that as input and scale the rest of the project (eg: design views, build test, build tables, etc).

      There are clear parallels here. You need to recognize the limitations, but there is a lot of functionality they can provide as long as you understand what it can’t do. Read the comments of people who have actually sat down and used it and you’ll see we’ve the same conclusion.

      • Mniot@programming.dev
        link
        fedilink
        English
        arrow-up
        1
        ·
        1 hour ago

        My most recent usage of AI was making some script that uses WinGet to setup a dev environment.

        This is a good example. What I’m saying is that pre-AI, I could look this up on StackOverflow and copy/paste blindly and get a slightly higher success rate than today where I can “AI please solve this”.

        But I shouldn’t pick at the details. I think the “AI hater” mentality comes in because we’ve got this thing that boils down to “a bit more convenient than copying the solution off of StackOverflow” when used very carefully and “much worse than copying and pasting random code” when used otherwise. But instead of this honest pitch, it’s mega-hype and it’s only when people demand specific examples that someone starts talking like you do here.

      • self@awful.systems
        link
        fedilink
        English
        arrow-up
        3
        ·
        4 hours ago

        I feel so bad for the interns, and really your team in general, for having to interact with you

      • froztbyte@awful.systems
        link
        fedilink
        English
        arrow-up
        5
        ·
        6 hours ago

        christ this post is odious

        I feel quite confident in stating two things. 1) you fucking suck at your job. 2) the people reliant on you for things fucking hate dealing with you.

        the fact that you wrote this much florid effluent opinion, with as paltry examples as you bring to bear… christ

        just fucking learn some scripting languages, ffs

          • swlabr@awful.systems
            link
            fedilink
            English
            arrow-up
            6
            ·
            5 hours ago

            It’s only ad-hominem if they discredit your points by insulting you. If they read your points and use them to make statements about your character, that’s not ad hominem, that’s valid inference.

            You probably need an example. Let’s say Alice and Beelice are having a conversation.

            Alice: “I think seed oils are bad for you because RFK Jr. said so! MAGA!”

            If Beelice says: “Alice, you are a real sack of potatoes, and therefore you are wrong,” that’s ad hominem.

            If Beelice says: “Alice, if you’re going to parrot RFK Jr, then the worms deserve to eat the rotten flesh in your skull,” that’s plain inference.

            Understand now, dear?