OpenAI Blog→ original

How OpenAI Radically Speeds Up AI Agents Through WebSockets

OpenAI published a technical breakdown optimizing the Codex agent cycle in the Responses API. The main innovation is the transition to WebSockets coupled…

AI-processed from OpenAI Blog; edited by Hamidun News
How OpenAI Radically Speeds Up AI Agents Through WebSockets
Source: OpenAI Blog. Collage: Hamidun News.
◐ Listen to article

The era of slow artificial intelligences, thoughtfully generating responses for several seconds at a time, is gradually fading into the past. The true bottleneck of modern industry has become not so much the computational power of the foundational models themselves, but rather the obsolete data transmission infrastructure. Autonomous agents capable of independently writing program code, analyzing complex databases, and executing intricate multi-step tasks require fundamentally different interaction speeds with servers.

This core problem is precisely what OpenAI's latest update addresses, as the company has completely reimagined its Responses API architecture by implementing WebSocket protocol support and caching at the persistent connection level. This profound technical change marks a critical shift in how developers will build the next generation of autonomous software.

To fully grasp the scope of this infrastructure innovation, one must carefully examine the anatomy of a typical agent process, particularly the so-called Codex agent cycle. Unlike an ordinary conversational chatbot where a live user poses a single specific question and patiently waits for one detailed response, an autonomous AI agent operates in a continuous and intensely demanding cycle. It independently plans its next action, writes a code fragment, sends it for testing, receives an error message, instantly analyzes its causes, and rewrites the code from scratch.

Until now, this complex cycle has inevitably relied on traditional REST APIs. With each new, even the tiniest step, developers had to resend the entire vast previous conversation context and complete action history to the language model. As the natural complexity of the task being solved grew, the volume of transmitted data expanded exponentially, choking network channels and forcing the model to pointlessly waste precious computational resources reprocessing the same information repeatedly.

This created colossal overhead and made the work of serious AI agents unacceptably slow for real commercial applications.

The implementation of WebSocket technology changes the very essence of the logic governing this interaction between the application and the neural network. Instead of establishing a new connection each time and resending all accumulated data baggage, web sockets create a persistent, robust bidirectional communication channel between OpenAI's cloud servers and the developer's local environment. Conceptually, this can be compared to the transition from exchanging long, heavyweight postal shipments to conducting a live, continuous telephone conversation.

The channel remains constantly open, and any data streams can be transmitted almost instantaneously in both directions. However, it is important to understand that the continuous network connection alone would have solved only a small part of the overall latency problem if company engineers had not added a second, far more powerful and important architectural innovation.

OpenAI's genuine technical and engineering achievement lies in implementing advanced caching directly at the level of the active connection. Now, while the web socket remains open, the language model physically maintains the entire context of the current work session in its ultra-fast memory. When the digital agent takes its next step in the endless cycle of programming or deep data analysis, the cloud server needs to process exclusively the new, fresh portion of information, rather than rereading the entire multi-page history from the beginning.

The published technical breakdown from the company convincingly demonstrates that such an elegant approach radically reduces what is called the model generation latency. Enormous computational clusters are finally liberated from meaningless routine work of constantly relearning hundreds of thousands of tokens, which naturally leads to instantaneous system response even in the most intricate and complex multi-step usage scenarios.

The economic and technological consequences of this update for the entire IT industry will be extremely difficult to overestimate. A dramatic reduction in API overhead means not only a multiplied increase in net speed but also a dramatic drop in the daily operational costs of AI agents for medium and large businesses. Various ambitious startups and large corporations attempting to create fully autonomous digital employees have long inevitably run up against harsh economic and technical infeasibility of constant appeals to heavy flagship models via classic internet protocols.

Today, this invisible barrier has finally collapsed. The technological community stands at the very threshold of mass emergence of complex automation systems capable of operating in real time, instantly responding to any changes in source code or incoming data streams without the slightest delay for deliberation.

Ultimately, OpenAI's decisive transition to WebSockets for its Responses API brightly illustrates the global transformation of the entire landscape of the artificial intelligence industry. The basic infrastructure, which was originally designed exclusively for unhurried imitation of human communication, is now rapidly adapting to the harsh demands of machine-to-machine interaction at ultra-high speeds. The technological world is definitively moving from the departing era when a live human patiently awaited a response from a neural network, to a new age where autonomous agents continuously communicate with each other at the speed of light, accomplishing in mere seconds the monumental work that once required long hours of manual labor.

And it is precisely such deep, invisible-to-the-eye infrastructural breakthroughs—not merely formal growth in the number of parameters in the next generation of models—that make this long-awaited transition an objective reality of today.

ZK
Hamidun News
AI news without noise. Daily editorial selection from 400+ sources. A product by Zhemal Khamidun, Head of AI at Alpina Digital.

Want to stop reading about AI and start using it?

AI News is a curated feed of AI/tech news. Hamidun Academy teaches you to use AI systematically in your work.

What do you think?
Loading comments…