Overview
Ask Codex CLI to write a scripted CAD project for a multi-joint robot arm, with forward kinematics, exported part files and a small interface for moving the joints, then review every change and check the design yourself.
Problem or Objective
- Which agents produce CAD models, drawings or printable parts from a description?
- Which agents help people write software that controls robots or other hardware?
More in Research and Analysis
AI Agents and Models
Tools and Integrations
- Tools
- Codex CLI · Python
- Prerequisites
- A ChatGPT account with Codex, Python, a code-based CAD library that exports the formats you need, and a CAD viewer to inspect the parts.
How It Works
Install Codex CLI, sign in with your ChatGPT account and start it in an empty project folder under version control. Pick a code-based CAD library you can install in Python and check that it exports the file formats your printer or workshop needs. Describe the arm: number of joints, reach, payload target, link lengths and motor or bearing sizes you already own. Ask Codex to plan the project first, then to write one module per part, an assembly script, a forward kinematics function with tests, an export script for each part, and a simple interface with one slider per joint that shows the arm's pose. Review the plan and each set of changes before accepting them, and run the tests and exports yourself. Open the exported parts in a CAD viewer, check clearances, joint limits and wall thickness, and treat strength and torque calculations as engineering work you still have to do.
Implementation Workflow
Steps assembled from the agents, tools and prompt of this entry. Adapt them to your own setup.
- Choose the agentSet up Codex CLI.
- Connect the toolsConnect the tools this workflow relies on: Codex CLI, Python.
- Check the prerequisitesA ChatGPT account with Codex, Python, a code-based CAD library that exports the formats you need, and a CAD viewer to inspect the parts.
- Gather your detailsCollect what the prompt asks for: Number of joints, Reach, Payload target, Code-based CAD library, Motors and bearings on hand, Export format.
- Run the starter promptPaste the starter prompt below into Codex CLI and adapt it to your case.
- Check against the documentationCompare what you get with the documentation at github.com before you rely on it.
Practical Starter Prompt: Build a scripted CAD model of a robot arm
Fill the fields to adapt the prompt. Empty fields stay as visible [placeholders].
In this folder, build a Python project for a robot arm with [Number of joints] joints, a reach of about [Reach] and a payload target of [Payload target], using [Code-based CAD library]. Parts must fit [Motors and bearings on hand]. First write a plan and wait for my approval. Then create one module per part, an assembly script, a forward kinematics function with unit tests, an export script that writes each part as [Export format], and a simple interface with one slider per joint that shows the pose. Show me each set of changes before applying it and list every dimension you assumed.Approve the plan and each set of changes, run the tests and exports yourself, and check clearances, joint limits and loads before making any part.
Expected Results and Benefits
This is a suggested workflow, not a reported result. The points below are what the cited documentation says the tools can do.
This is a suggested workflow, not a reported outcome. OpenAI's pages say Codex CLI is a coding agent that runs locally on your computer, signs in with a ChatGPT plan and pauses some actions for your approval. They say nothing about CAD or robotics, so whether the generated geometry, kinematics and exports are correct depends on the library you choose and on your own checks.
Limitations and Considerations
Codex is included across ChatGPT plans and usage limits vary by plan; check what yours allows for a long session. Some actions pause for your approval, and an optional auto-review can approve eligible actions for you; keep reviewing changes yourself on a project like this. Check the CAD library's license and its export formats before you start. Generated geometry and kinematics can contain mistakes, so verify dimensions, clearances and loads before cutting or printing any part. Results depend on your setup and were not independently reproduced by Top 200 Repos.
GitHub Repositories
AI Agent Repository
Source code of the agent that does the work.
Related Videos
About openai/codex
Meet the New Codex CLI (opens in a new tab)
Published by the project’s official channel.
Watch on YouTube (opens in a new tab)Independent creators. Listing a video implies no endorsement, sponsorship or partnership.
Sources
- openai/codex README (opens in a new tab)
Project documentation · github.com · Undated · Source checked 25 Nov 2026, 11:59 UTC
What this source supports
- Codex CLI is a coding agent from OpenAI that runs locally on your computer, with installers for Mac, Linux and Windows.
- Using Codex with your ChatGPT plan | OpenAI Help Center (opens in a new tab)
Project documentation · help.openai.com · Undated · Source checked 26 Nov 2026, 17:27 UTC
What this source supports
- Codex is included across ChatGPT plans, including Free and Go; usage limits vary by plan.
- Codex CLI lets you work with code from your terminal; you sign in with ChatGPT in the Codex client you launch.
- Auto-review lets a separate reviewer check eligible actions that would otherwise pause for your approval; it does not replace every approval prompt.
