Aug 10, 2021 - Technology

OpenAI's Codex turns written language into computer code

Illustration of an infinite, recursive tunnel of laptops.
Illustration: Shoshana Gordon/Axios

A new AI system can read written instructions in conversational language and transform it into working computer code.

Why it matters: The model is the latest example of progress in natural language processing, the ability of AIs to read and write text.

  • But it also points toward a future in which coders will be able to offload some of their work to AIs, and where ordinary people may be able to code without actually learning how to code.

Driving the news: Today OpenAI is releasing an improved version of its Codex AI model and inviting businesses and private developers to access it through its API.

  • Codex is a descendant of OpenAI's massive text-generating model GPT-3, which was released last summer.
  • But while GPT-3 was trained on a huge quantity of language data taken from the internet — enabling it to read and then complete text prompts submitted by a human user — Codex was trained on both language and billions of lines of publicly available computer code.
  • As a result, users can issue commands in written English, and Codex will produce computer code capable of carrying out those instructions, essentially making it an English to Python (or JavaScript or Ruby or any of the more than a dozen programming languages in Codex's training data) computer code translator.

What they're saying: "We think this is a tool that can remove barriers of entry to allow more people to get into computer coding," says Greg Brockman, a co-founder and chief technology officer at OpenAI. "It's really the start of being able to talk to your computer and get it to do what you're asking in a capable, reliable way."

How it works: At an online demo for Axios, Brockman showed how Codex could be instructed to print text, add emotional feeling and even send that text as an SMS.

Animated GIF - Find & Share on GIPHY
Credit: OpenAI

What's next: Developers in the OpenAI beta test will be able to build applications on top of the Codex API, allowing them to "push the envelope on what's out there," says Brockman.

Go deeper