OpenAI's Codex Max solves one of my biggest AI coding annoyances - and it's a lot faster

1 week ago 15
Codex Max
Elyse Betters Picaro / ZDNET

Follow ZDNET: Add us as a preferred source on Google.


ZDNET's key takeaways

  • Codex Max processes massive workloads through improved context handling.
  • Faster execution and fewer tokens deliver better real-world efficiency.
  • First Windows-trained Codex enhances cross-platform development tasks.

Following a week of major AI programming announcements from Microsoft and Google, OpenAI has joined in the fun. Today, OpenAI is announcing a new version of Codex, its programming-focused AI model.

While the announcement was today, the actual GPT-5.1-Codex-Max capability will be available tomorrow in Codex for ChatGPT Plus, Pro, Business, Edu, and Enterprise users. API access is "coming soon." OpenAI says the new Max model "replaces GPT-5.1-Codex as the recommended model for agentic coding tasks in Codex and Codex-like environments."

Also: Linus Torvalds is surprisingly optimistic about vibe coding - except for this one 'horrible' use

(Disclosure: Ziff Davis, ZDNET's parent company, filed an April 2025 lawsuit against OpenAI, alleging it infringed Ziff Davis copyrights in training and operating its AI systems.)

The big news

The big news is that the new Max model can work on bigger assignments. AIs have a context window, which is roughly the amount of information and processing an AI can handle in one shot. In a human, think of it as attention span, or as how much work somebody can get done before needing a new cup of coffee.

Also: You'll code faster and spend less with OpenAI's new GPT-5.1 update - here's how

Internally, the size of a context window is really how many tokens an AI can handle before running out. Tokens are super-tiny chunks of information. They don't directly correspond to words, letters, or lines of code, but instead are memory representations of those things.

Codex has a fairly large context window, but it does get overwhelmed. For example, I've found that when I coded using Codex, it could do very large project assignments without crying. But if I fed it a giant dump from a code crash with a ton of text in the dump, it ran out of context window fairly quickly. That's because the tokens weren't being consumed in project processing. They were being consumed in handling the big data dump.

The above-the-fold feature of GPT-5.1-Codex-Max is that it can handle much larger context windows and operate across context windows by using a process called compaction.

Compaction is the process that a model can use to shrink or compress portions of the conversation or code context when the overall token window is getting full.

You know how when you're talking and talking and talking to a friend and their eyes glaze over, but then you clap your hands together, exclaim "Snap out of it," and regain their attention? That's compaction. What? It can't just be me.

Also: The best free AI for coding in 2025 - only 3 make the cut now

In the AI, it means that Codex Max can work on much larger tasks, like very complex systemwide refactors (finding, changing, and fixing cross-references). It also allows the AI to work on a single task for hours at a time. OpenAI says Codex can handle a 24-hour task.

Compaction isn't new. I've bumped into it in Claude Code on my $100/month Max plan. One difference is Claude has a context window of about 200,000 tokens. At one point during my coding, Claude informed me we had used up quite a bit and recommended either I start a new session or it would run a compaction, which took about five minutes.

By contrast, OpenAI says Max can "coherently work over millions of tokens in a single task."

Less is more

The SWE-Bench Verified evaluation is basically a test of AI processing accuracy. It measures how well the AI solves a set of coding problems. According to OpenAI, GPT-5.1-Codex-Max "reaches the same performance" as the previous model, GPT-5.1-Codex.

Also: Google's Antigravity puts coding productivity before AI hype - and the result is astonishing

In other words, the AI didn't deteriorate in its AIness. But where it gets interesting is that Max can sustain that performance using 30% fewer thinking tokens and run 27% to 42% faster on real-world coding tasks. In my imagination, I picture some engineer over at OpenAI raising a fist and exclaiming, "Darn it, I was trying for 43%, but no."

This has some real-world implications. You may recall that the $20/month ChatGPT Plus plan has fairly high restrictions on Codex use, allowing about 5 hours of run before running out of tokens. With Max using 30% fewer tokens, you might get an extra hour of programming in for the same price.

OpenAI provided some examples of model performance compared to the non-Max version. In one example, Max used 27,000 tokens compared to 37,000, generated 707 lines of code instead of 864, and ran 27% faster.

Also: How to vibe code your first iPhone app with AI - no experience necessary

Let's take a moment to focus on that lines of code mention. If you can get code to work in fewer lines of code, it's usually easier to maintain and often runs faster. While you can get crazy making concise code (I'm looking at the few remaining Perl coders out there), fewer lines for the same routine is generally a measure of better programming practice or better algorithms.

So if Codex is saving lines, that's generally a good thing. Let's look at a few other examples:

  • 16,000 instead of 26,000 tokens, 586 code lines instead of 933, and 38% faster
  • 8,000 tokens instead of 12,000, 578 lines of code instead of 911, and 33% faster
  • 16,000 instead of 38,000 tokens, 529 lines of code instead of 667, and 42% faster

Obviously, every task will be different, but faster, better, cheaper is always good.

Better cybersecurity

Ever since GPT-5 was released earlier in the year, OpenAI incorporated cybersecurity-specific monitoring to detect and disrupt malicious activity. As you might imagine, if you're letting your agent run free with access to the command line for hours and hours, it could be a juicy target for hackers.

OpenAI says the GPT-5.1-Codex-Max model performs "significantly better" on sustained, "long-horizon" reasoning. This sustained performance helps the model improve on cybersecurity as well.

Also: How to use ChatGPT to write code - and my top trick for debugging what it generates

Codex runs in a secure sandbox where file writing can only take place in a defined workspace and network access is disabled, unless a coder decides to dance with the Devil in the pale moonlight and turn it on.

The company says, "We recommend keeping Codex in this restricted-access mode, since enabling internet or web search can introduce prompt-injection risks from untrusted content."

Trained for Windows

Codex works really well on the Mac. It was trained to do so. Many OpenAI developers use Macs for coding. However, GPT-5.1-Codex-Max also works well in Windows. OpenAI reports, "It's also the first model we've trained to operate effectively in Windows environments, with training tasks that make it a better collaborator in the Codex CLI."

Also: Is ChatGPT Plus still worth $20? How it compares to the Free and Pro plans

Considering OpenAI's growing relationship with Microsoft, it makes sense that OpenAI would give Windows a little more love.

That's a wrap

Well, that wraps it for this announcement. 

Also: 10 ChatGPT Codex secrets I only learned after 60 hours of pair programming with it

As Codex Max pushes into larger context windows, long-running tasks, and new Windows-specific training, what stands out to you? Do you see compaction and multi-million-token workflows changing how you approach big coding projects? Are the speed and token-efficiency gains enough to shift your everyday development? And if you use Windows, are you planning to try the new Windows-trained model in your workflow? Let me know what you think in the comments below.


You can follow my day-to-day project updates on social media. Be sure to subscribe to my weekly update newsletter, and follow me on Twitter/X at @DavidGewirtz, on Facebook at Facebook.com/DavidGewirtz, on Instagram at Instagram.com/DavidGewirtz, on Bluesky at @DavidGewirtz.com, and on YouTube at YouTube.com/DavidGewirtzTV.

Read Entire Article