• TranquilTurbulence@lemmy.zip
      link
      fedilink
      English
      arrow-up
      1
      ·
      9 hours ago

      I did that today. It went something like this:

      “See the naming conventions at the beginning of the script. Apply all the rules to all the non-conforming variable names and the new custom function we made earlier.“

      There were like 100 changes here and there, and I just didn’t feel like doing all that work manually.

      • definitemaybe@lemmy.ca
        link
        fedilink
        arrow-up
        2
        ·
        2 hours ago

        In my experience, the trick to this is to get a list of changes to make yourself, rather than trusting the machine to actually get it right. (Unless you’re in a dev/test environment and don’t care much if it fucks it up.)

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

          This code isn’t anywhere near production yet. I’m still going to make a hundred little changes, but an LLM can do all the boring stuff so that I can focus on the interesting bits. There’s also going to be plenty of testing and iterative tweaks, so any major mistakes will be exposed sooner rather than later. Honestly, about half of the errors will be caused by me.

    • crunchy@lemmy.dbzer0.com
      link
      fedilink
      English
      arrow-up
      13
      ·
      24 hours ago

      I can count on one hand the number of jobs or functions I’ve seen people try to get AI to do that isn’t already done better by a hard-coded program or an Excel spreadsheet.

    • TehPers@beehaw.org
      link
      fedilink
      English
      arrow-up
      1
      ·
      20 hours ago

      I’ve used it as a sort of find and replace in the past, but by feeding it the output from Ripgrep to skip the “find” part. The “replace” was just unwrapping unnecessarily confusing “try” blocks and allowing errors to propagate to the appropriate handlers. This would have required a syntax-aware replacement tool (and some exist but I didn’t really feel like learning one for a one-off).

      As a simple “find this text and replace with this other text” it makes no sense.