6 minutes to read - Jun 2, 2023

ChatGPT, Google Bard, and the Future of Design using AI and 3D Printing

VISIT
ChatGPT, Google Bard, and the Future of Design using AI and 3D Printing
Everyone is talking about it, and maybe you’ve even tried it. The release of OpenAI’s ChatGPT and Google Bard has unleashed a wave of intense interest in artificial intelligence (AI).

It can do intriguing tasks like write a contract in seconds instead of hours or even write your kid’s term paper (not recommended). Maybe the most interesting capability is that it can write snippets of code, and that’s extremely powerful for code dabblers who are familiar with the concepts but just don’t code enough to keep their skill set fresh. 

To be honest, as of early 2023 ChatGPT is not ready for primetime, even GPT-4. Often, the service is down or so overwhelmed with requests that you can’t access it. Sometimes, there appears to be some sort of performance throttling, so your mileage may vary depending on when you try it. A more fundamental issue: It will make false statements with full confidence. At the time of this writing, Google Bard is in limited release and the code it creates is similar to ChatGPT.

 That said, both provide a fascinating glimpse into the possibilities that will be unlocked over the next few years as the technology is iterated and improved.

This language-based AI will surely affect professions like teachers, writers, and programmers, but how will it affect 3D CAD design and 3D printing—my livelihood—maybe yours, too?

AI Meets CAD

My thoughts instantly turned to Blender. Blender is powerful, open-source 3D design software. Though it was primarily designed for generating animation and renderings, the program supports STL files that can be used for 3D printing. Blender is not widely used because the interface is not intuitive and much of the functionality is locked behind menus and hotkeys. However, Blender accepts and can execute Python code. 

Python is a popular programming language that can permit users to—among many other things—interface with Blender, which can then turn Python code into an STL file. So, I wondered, can I use ChatGPT to create Python code for Blender? Can I just tell 

ChatGPT in plain English what I want, and it can tell Blender (via Python code) what to do?

Testing ChatGPT’s Code

The phrasing I used was “Create me a Blender script to create a 3D CAD of a _______.”

ChatGPT created a code snippet I could copy and paste into Blender’s text editor. The last step is to simply run the code.

I asked it to create a CAD of a cube. Success! Interestingly, when I asked it a second time to generate code for a cube, it produced different code. Next, I asked it to create a CAD of an elephant skull. Not so successful. Okay, so ChatGPT’s capability to create 3D CAD lies somewhere between a cube and a skull. But where?

A ChatGPT Blender script for a 3D CAD of a cube.

Limitations of AI Code

Blender natively understands basic shapes like cubes, cylinders, cones, and spheres. ChatGPT can make a 3D CAD of an object with a simply defined shape like a ball or rod, and you can even give it dimensions. If you give it a shape with a little more logical depth like a pipe, it makes the attempt but doesn’t quite succeed. It initially created a solid cylinder, but also added a modifier to allow the Blender user to easily add a bend. When asked to make the pipe hollow, it knew to create two cylinders and to Boolean out the inner, smaller cylinder to make the pipe hollow but didn’t quite execute properly. If you have the patience to comb over the Python code you may find the error, or you can even ask ChatGPT to fix the issue and it often does.

A ChatGPT Blender script for a 3D CAD of a pipe.

Who Can Benefit from AI?

Users with more knowledge of Blender’s terminology can get further. Learning to speak the language of Blender for the ChatGPT prompts can enable it to generate very complex shapes. Complex arrays, random distributions, and fractal shapes are all possible. Just a basic knowledge of Blender’s available primitives and modifiers goes a long way. Primitives are basic 2D and 3D shapes like cubes, cones, circles, and curves; modifiers are functions that can be added to a geometry to transform it, and they can be very powerful.

Building Designs by Building Language

Since ChatGPT will take the previous conversation in context, you can build up a part conversationally with it. For example, first you can ask it to write a code to create a sphere, and after that’s done, ask it to update the code to change the diameter. This works well for one or two modifications to the code, but I found ChatGPT would start losing track when things got more complex. Considering the program wasn’t designed for this function it performed surprisingly well and one day it could become a very powerful tool.

Imagining the Future with AI-based Design

The experience gives a peek into a future where you might have a conversation with an AI CAD drafter and your part is designed in real time as the conversation progresses. ChatGPT is already able to conceptually understand how to build up 3D designs from basic concepts, so very soon it may be possible to ask AI to create a CAD of a more useful shape like a custom Y fitting for a pipe.

Someday AI may be able to generate even more complex 3D CAD. This experience inspired me to try out other commonly available AI programs, like the 2D image generator Midjourney, which I used to create the images below.

Although these are just 2D images and not actual 3D CAD, the tool can be very useful for ideation and inspiration. Its AI is using a massive bank of reference images and the designs may be nonsensical or nonfunctional, but some are truly impressive and look manufacturable via 3D printing. Again, this AI tool has a conversational component where you can add input to the prompt to steer the output one way or another, but you would not be able to give specific dimensions.

If 2D-to-3D CAD software becomes more capable and sensitive to the parameters of design for manufacturing, then things could get very interesting very quickly.


Article source
loading...