CAMInstructor

Assembly Line

Can ChatGPT Create Usable G-Code Programs?

📅 Date:

✍️ Author: Julia Hider

🔖 Topics: ChatGPT, Large Language Model, Computer Numerical Control

🏢 Organizations: CAMInstructor


Mike Wearne is an educational content creator at CAMInstructor, has a take on the GPT-3 G-code. “If we use a basic program that’s a drill four holes sort of thing, and compare this to someone who’s just learning G code, I would say it’s not bad,” he says. “I would give it a low B or a high C.” The overall structure was there — it put the right codes in the right places, such as G20 and G21 to switch between metric and imperial units, and G90 for absolute positioning at the top of the program. “If you’re new to G-code programming, those are usually the tough things to remember and to get in the right spot,” he notes. However, it was missing some elements, such as tool changes and spindle speeds.

Wearne also noticed a marked improvement in the G code GPT-4 produces. “It’s like GPT-4 can think more about its answers and GPT-3.5 just spits out whatever it comes up with as quick as it can,” he explains. With its most recent update, Wearne says it can program simple parts almost perfectly. Whereas GPT-3 was getting a high C or low B as a grade for its code, “For the simple parts, if we’re in G-code 101, GPT-4 is getting an A,” he says.

Read more at Modern Machine Shop