Auto Generate CAD Drawings From Text Descriptions: TEXT-TO-CAD
2024 (English)Independent thesis Basic level (degree of Bachelor), 10 credits / 15 HE credits
Student thesis [Artistic work]Alternative title
Auto Generera CAD Ritningar from text beskrivning (Swedish)
Abstract [en]
Creating 3D models takes a lot of time and requires experience in 3D modeling tools, such as Blender and Solidworks. People from different backgrounds, such as computer science students, marketing professionals, and others, need to create 3D models for various purposes, including games and marketing. They need a 3D model, but they need a tool that can help them create 3D models quickly and easily.
Our approach for solving this problem is to go from text → code → 3D model. A Large Language Model (LLM) is utilized to convert the text to code. Then, the code is compiled to create 3D models. The code is a set of high-level function calls that create 3D models. These function calls are defined by us and are called sub-generators. The sub-generators generate synthetic data. CodeLlama, an LLM, is used to generate the code. The Blender Python API is used to compile the code to create 3D models. CodeLlama has been trained using in-context learning (ICL). The generated code is evaluated by comparing it with the code generated by ChatGPT 3.5 and Microsoft's Copilot, which are two other language models. CodeLlama was deployed in a local server. The prompt used in the ICL is evaluated by seeing how compressible and generalizable it is.
CodeLLama is trained using ICL to generate code for creating fork, spoons, knives, cups, and dishes. CodeLLama can also generate code that modifies the size and color of the 3D models. Additionally, CodeLLama can generate code for creating scenes by combining the 3D models and defining their relative positions. We conclude that all the evaluated models can be used to generate code for this task, but we chose codeLLaMA because it is free, open-source, and can be run locally without the need for an internet connection.
Abstract [sv]
Skapandet av 3D-modeller tar mycket tid och kräver erfarenhet av verktyg for 3D-modellering, som Blender och Solidworks. Människor från olika bakgrunder, som datavetenskapsstudenter, marknadsföringsproffs och andra, behöver skapa 3D-modeller för olika ändamål, inklusive spel och marknadsföring. De behöver en 3D-modell, men de behöver ett verktyg som kan hjälpa dem att skapa 3D-modeller snabbt och enkelt.
Vårt tillvägagångssätt för att lösa detta problem är att gå från text → kod → 3D-modell. En Large Language Model (LLM) används för att konvertera texten till kod. Sedan kompileras koden för att skapa 3D-modeller. Koden är en uppsättning högnivåfunktionsanrop som skapar 3D-modeller. Dessa funktionsanrop definieras av oss och kallas delgeneratorer. Delgeneratorerna genererar syntetiska data. CodeLlama, en LLM, används för att generera koden. Blender Python API används för att kompilera koden för att skapa 3D-modeller. CodeLlama har tränats med in-context learning (ICL). Den genererade koden utvärderas genom att jämföra den med koden som genererats av ChatGPT 3.5 och Microsofts Copilot, som är två andra språkmodeller. CodeLlama har implementerats i en lokal server. Prompten som används i ICL utvärderas genom att se hur komprimerbar och generaliserbar den är.
Place, publisher, year, edition, pages
2024.
Keywords [en]
Text-to-cad, CAD, Blender, Generative AI, 3D drawings
National Category
Other Engineering and Technologies Other Engineering and Technologies
Identifiers
URN: urn:nbn:se:hh:diva-53882OAI: oai:DiVA.org:hh-53882DiVA, id: diva2:1871889
Subject / course
Computer science and engineering
Educational program
Computer Science and Engineering, 300 credits
Presentation
2024-05-14, J102 Wigforss, Högskolans Campus, 18:34 (English)
Supervisors
Examiners
2024-06-262024-06-172025-02-18Bibliographically approved