3D printing or additive manufacturing is a revolutionary technology that enables the creation of physical objects from digital models. However, the quality and accuracy of 3D printing depend on the correctness and efficiency of the G-code, a low-level numerical control programming language that instructs 3D printers how to move and extrude material. Debugging G-code is a challenging task that requires a syntactic and semantic understanding of the G-code format and the geometry of the part to be printed. In this paper, we present the first extensive evaluation of six state-of-the-art foundational large language models (LLMs) for comprehending and debugging G-code files for 3D printing. We design effective prompts to enable pre-trained LLMs to understand and manipulate G-code and test their performance on various aspects of G-code debugging and manipulation, including detection and correction of common errors and the ability to perform geometric transformations. We analyze their strengths and weaknesses for understanding complete G-code files. We also discuss the implications and limitations of using LLMs for G-code comprehension.
翻译:3D打印或增材制造是一项革命性技术,能够通过数字模型直接生成实体物体。然而,3D打印的质量与精度取决于G代码的正确性与有效性——G代码是一种低级数控编程语言,用于指令3D打印机的运动轨迹与材料挤出行为。调试G代码是一项艰巨任务,需要同时理解G代码的语法语义格式及待打印部件的几何结构。本文首次系统评估了六种最先进的基础大语言模型(LLMs)在3D打印G代码文件理解与调试中的表现。我们设计了高效提示策略,使预训练LLMs能够理解并操作G代码,并从多个维度测试其调试与操作性能,包括常见错误的检测与修正、几何变换能力等。我们分析了这些模型在处理完整G代码文件时的优势与局限,并探讨了将大语言模型应用于G代码理解的潜在影响与现存挑战。