How to generate vector art with ChatGPT Codex
Published
Codex is OpenAI's coding agent, included with ChatGPT plans, and it can also generate images. VTracer's Gen AI lab can use your Codex to make the artwork, then trace it to SVG on your own computer. Unlike the lab's local models, Codex runs in OpenAI's cloud: there is nothing to download and no GPU needed, but your prompt is sent to OpenAI, and generation uses your ChatGPT plan's limits.
Codex at a glance
| Made by | OpenAI |
| Image model | gpt-image-2, Codex's built-in image generation |
| Runs | In OpenAI's cloud |
| Account | Your own ChatGPT plan, signed in to Codex |
| Cost | Counts toward your Codex usage limits |
| Download and memory | None: nothing runs locally but the tracing |
| Image size | Around 1,250 × 1,250 pixels in our rounds, sometimes portrait or landscape |
| Image-to-image | Yes: sketches and reference images |
| What leaves your machine | Your prompt, and any sketch or reference image |
According to OpenAI's documentation, Codex's built-in image generation uses gpt-image-2 and counts toward your general Codex usage limits; image generations use those limits 3 to 5 times faster on average than turns without images, depending on quality and size. Codex is included in ChatGPT's Free, Go, Plus, Pro, Business, Edu and Enterprise plans; see Codex pricing for which plans include image generation and what happens when limits run out.
Set up Codex in VTracer
You do this once. VTracer does not sign in to OpenAI for you: Codex keeps its own sign-in, and VTracer runs it on your machine.
- In the Gen AI tab, click the settings button, the gear beside the menu in the Model section.
- In the Models window, open the Vendor tab and follow its instructions: install the Codex CLI, and sign in with your ChatGPT account. If you installed Codex somewhere other than the standard location, put the path to its
codexprogram in the box under OpenAI Codex. Once Codex is found and signed in, a green dot shows beside its name, with your account, the Codex version and your plan; the button on the right checks again. - Open the model menu. OpenAI Codex is now listed under Vendor, marked Signed in. Choose it.
How to generate vector art with Codex in VTracer
- In the Gen AI tab, choose OpenAI Codex from the model menu.
- Type a subject and any details, and pick an art style. All eight art styles work with Codex.
- Generate. VTracer sends the prompt to Codex, receives the image, and traces it with VTracer 2 on your device, with the background removed.
Codex returns larger images than the local models, so VTracer upscales them less before tracing. A round took about 50 seconds in our test, depending on OpenAI's servers rather than your hardware.
The art styles with Codex
Here is a single red fox sitting in each of the eight art styles, generated by Codex and traced:
- Faithful to the style. Codex follows style instructions closely: the stencil is a single silhouette in 10 paths, the flat design and clip art foxes take under 30.
- Detailed when asked. Inked, low poly, linocut and line art come out finely worked, with hundreds of paths. Choose a simpler style for small, editable SVGs.
- Larger images, more detail. At around 1,250 pixels, Codex's images carry more fine detail than the local models' 512-pixel ones.
Compare these with the same subject from Z-Image Turbo in Art styles.
From a sketch
Codex can also work from your drawing. As with every sketch round, VTracer first cleans up the photo, lifting your pencil lines off the paper into clean ink, and it is that clean drawing that goes to Codex along with your prompt:
Codex keeps the poses, the wink, the striped tail and the patches from the drawing, and colors each cat in its own way. See Text-to-image vs image-to-image for how sketches and reference images differ.
Privacy and rights
- Sent to OpenAI: your prompt, and the sketch or reference image if you use one. This is the only way of generating in the Gen AI lab in which anything leaves your machine; with the local models, nothing does.
- Stays on your device: the tracing, your SVGs, and everything else in VTracer.
- Your images: OpenAI's terms of use govern what you may do with what Codex generates.
Best for
People who already have a ChatGPT plan, computers without a strong GPU, and artwork that benefits from Codex's prompt following and larger images. To keep everything on your device, use one of the local models: see Which AI image model is best for vector art?