Anyone using AI to write code?

Being pretty much on my lonesome during the day, I talk to copilot on my phone it is good to have, someone to talk to… I just dont’ like it when it tries to talk like an Aussie. :slight_smile:

I also use Copilot in VS code, it is awesome for doing things like:

  • Explaining a chunk of code I can’t understand or is massive and complicated
  • Helping me improve my code
  • Helping me remember syntax and constructs. (these days I have a memory like a sieve sadly)

Like everyone says, it’s not perfect but it is a nifty tool to have sitting on your shoulder, particularly when you don’t have a peer programming system at your fingertips.

AI is amazing and becoming very powerful in a business environment. Agentic tooling is exploding across the web.

In response to Epicor’s nonsense release timelines regarding AI software, I got to work adding AI for on-prem.

I have examples connected to Epicor, but nothing quite ready to show off. Captured this just now, it is Claude’s family of models connected to Google web search, all through our own API keys and orchestration. I even have it connected to MS Graph. The note regarding message recording is for our internal users to be aware. The AI companies themselves do not log your API calls (if you pay).

Azure OpenAI, OpenAI, Google Deepmind, Anthropic, and xAI. All in one. :smiley:

*All WIP
Recording 2025-03-28 at 07.32.37

I am in a Fantasy NBA league but don’t watch basketball. NBA stats will now be my first use case for ChatGPT. :sweat_smile:

If you want better responses from AI you have to add some things to your prompt, like specific details of the program you are using the code for and any limitations.

One example would be if you are on E10 maybe tell it what the version of C# is available so it does not try to use language features that are not available. Also list libraries it can use like newton soft that are available.

Gemini has some customizations called gems where you can give this information and it will use it for all your queries using that specific gem.

We definitely need companies to start supplying documentation in a format that can be uploaded to an AI, then it uses that documentation to give you better responses.

Came back to give an update…

I think the autocomplete feature of Github Copilot Visual Studio Code extension has been the most successful tool for me so far:

GitHub Copilot in VS Code

I typically write most BPMs/Functions in VS Code and then copy/paste into Kinetic editors.

I have been finding the auto-complete suggestions shockingly good. Many “Holy Sh*t, how did it know that’s what I wanted” moments. And it’s not just about saving keystrokes (like, say, autocomplete in Outlook). It really does relieve a bunch of mental load when writing code.

Also, I find adding a good objective/summary comment at the top of the code snippets really helps:

It will often invent Epicor table/field names and I have to correct those, but the intent of the code suggestion is usually spot on. I do find it can get annoying and make suggestions / clutter the screen when I don’t want them so I’m trying to dial that in better.

As far as the chat/interactive features, I don’t use them as much yet, but have had a couple great wins in debugging. I will tell it “here’s the runtime error I’m getting, what do you think the problem is?”, and it leads me down the right path. This tends to work best on things like null reference errors where the AI can envision the flow of data thru the code and predict where things might go wrong. (it doesn’t help me when the problem is some intricate Epicor quirk like needing to use BeforeImage on certain business objects… but maybe someday! Or maybe that will be a job for Prism?)

Anyway, would love to hear if anyone has tips / experience with this particular extension. I’m trying to stick with this one for a while rather than bounce back and forth between ChatGPT, Copilot, Gemini, etc.

Actually the quirk is the other way around. We really should be using before image all the time, except sometimes, you can get away without it.