• iocase@lemmy.zip
    link
    fedilink
    arrow-up
    17
    ·
    edit-2
    1 day ago

    I’ve coded “professionally” (solo dev for a small company. Not the full dev experience so big caveat)

    I find AI is amazing at writing unit tests and other test harnesses. That’s all it’s good for besides summarizing documentation and even then it’s so misleading it’s basically useless you have to constantly doubt it. It’s a pathological liar… And I mean it’s kind of an impossible task… It’s trained on the entire internet. The strongest weights it has are for the oldest and most popular libraries. Oftentimes it’s telling me to use deprecated shit left and right because that’s biased extremely high during training, and maybe 1% of posts on that library mention it’s deprecation.

    I prefer to write my code the old fashioned way. If I have it generate code it’s never pasted in, and I prefer having it explain what I don’t know about what it’s doing. Using it as an assistant and a TDD buddy works relatively well.

    Also if you poke at software architecture. I’ve learned a lot (I wasn’t formally schooled in computer science) and it’s good as long as you constrain the scope of what you’re asking about, and make sure to consider it on your own against the existing project architecture. I still make the design decisions myself.

    Oh, also having it make design decision documents. I often make those to record “this is why I’m doing this feature this way. These are the options I considered, and why I decided my way is better in this particular case” so I have a record of my state of mind and decision making. AI is phenomenal at making easy to read and well summarised DDDs

    • Feyd@programming.dev
      link
      fedilink
      arrow-up
      11
      ·
      23 hours ago

      I find AI is amazing at writing unit tests

      Some of my coworkers say this too. The tests are generally garbage that don’t test what they say they do. All this says is that you don’t care how useful your tests are outside of checking a box

      • iocase@lemmy.zip
        link
        fedilink
        arrow-up
        2
        ·
        edit-2
        19 hours ago

        Yes you have to verify it yourself you don’t just trust it. The biggest benefit is tests are extremely to read and falsify like simple scripts. It’s faster to generate it than type it by hand, and any edits I make are minimal or require a reprompt that gets it right the second time.