The Crisis of Performance Engineering Created by Agentic Development Speed
OpenAI diagnoses that "the astonishing speed of agentic development has made traditional performance engineering approaches unsustainable." As large-scale services like ChatGPT continuously deploy new models and features, performance regression occurs frequently, but the existing method of having humans investigate and correct each instance has become unmanageable. In response, OpenAI has built the 'Performance Factory' that autonomously detects, diagnoses, corrects, and verifies performance issues by leveraging the full capabilities of Codex.
"The Performance Factory runs in the cloud and automates the investigation and resolution of performance issues, allowing us to align with our roadmap ambitions."
Six Stages of Evolution: From Manual Labor to Agent Factory
The OpenAI performance team summarized how their workflow changed before and after the introduction of Codex into six stages. This process serves as a roadmap for other service teams looking to adopt agentic workflows.
| Stage | Name | Key Features | Human Role |
|---|---|---|---|
| 1 | Pre-Codex | Manual analysis of metrics and logs, trace comparisons, live machine debugging, code reading | Specialized knowledge required, time-consuming |
| 2 | Codex as a partner | Codex searches the codebase, explores metrics and traces, tracks interactions between services, performs profiling | Engineers direct investigation, select tools |
| 3 | Reusable skills | Codifying the investigation process with the `perf-forensics` skill: specifying when and how to use tools | Skill testing and improvement, validation based on evaluation sets |
| 4 | The human proxy | Alerts generated → Engineer copies and pastes into Codex → Shares results on Slack | Reduced to a simple relay role |
| 5 | Automated investigations | Alerts automatically start Codex sessions, posting results in Slack threads | Verification after modification development and deployment remains manual |
| 6 | The factory | End-to-end workflow automation: state-based management from investigation → correction suggestion → code review → deployment → verification | Workflow definition, exception handling, approvals |
`perf-forensics` Skill: Assetization of Investigation Know-How
The `perf-forensics` skill created in stage 3 encapsulates the investigation know-how of the performance team into a reusable skill. This skill instructs Codex on what tools are available, when to use each tool, and how to drill down into slowdowns. It is specifically designed to approach from the following perspectives:
- The timing characteristics of when the slowdown started
- Identification of affected requests
- Investigating whether deployment or configuration changes are the cause
OpenAI tested and improved this skill using evaluation sets (evals) based on past regression cases. As a result, for types of focus such as ChatGPT latency reduction and availability degradation, it became possible to reach a diagnosis with just one alert without additional human intervention.
Performance Factory Architecture: Four Key Components
The Performance Factory consists of the following four components:
1. Task Service + Configurable Workflow
- Engineers define workflows with Markdown configuration files and prompts
- Specifies the state, allowed transitions, and stages requiring engineer approval for tasks
- Separate management of agent instruction prompts for each stage
- All workflows and tasks are visualized in the UI for progress sharing and collaboration
2. Dispatch Loop
- Periodically searches for tasks that can proceed to the next stage
- Starts a Codex turn with instruction prompts appropriate to the current state of the task
- The agent records progress in the task and transitions to the next state upon completion
3. Cloud Execution API
- Programmatically invokes Codex turns in an environment with the same tool access rights as engineers
- Implemented as an internal API, allowing the agent to perform actual investigation, correction, and verification tasks
4. Subscription System
- Wakes the responsible agent for the task when external events occur, such as posting GitHub review comments or completing deployments
- Acts as a trigger for asynchronous collaboration between humans and agents
- Alert Occurs
- Automatic Investigation Starts
- Root Cause Records and Correction Suggestions
- Engineer Code Review
- Automatic Verification After Deployment
- Baseline Recovery Confirmation
Regression Workflow: Complete Automation from Alert to Verification
The first workflow currently operational in the Performance Factory, 'Regression Workflow,' automates the entire process from the moment a performance alert occurs to recovery verification.
1. Alert Occurs → Task Opens: When a performance alert is triggered, a task is automatically created 2. Automatic Investigation: The agent investigates the cause of the slowdown, records findings in the task, and suggests corrections 3. Engineer Review: The engineer reviews and approves the proposed corrections 4. Automatic Verification After Deployment: Upon completion of deployment, the subscription system wakes another agent → confirms whether performance has recovered to baseline within the same task 5. Completion or Rework: The task ends upon confirmation of recovery; if not recovered, it enters an additional investigation loop
"This is the first workflow that automates the entire process from investigation to correction writing and mitigation verification."
Thanks to this design, the task's status and findings are persistently stored, allowing for smooth handovers between agents and engineers even during long waiting periods such as code reviews or deployments. Additionally, it supports creating separate workflows for common optimization patterns for regular execution, or interlinking workflows where optimization discovery workflows delegate tasks to implementation and testing workflows.
Initial Operational Results: Quantitative Metrics Over Three Months
The regression workflow of the Performance Factory recorded the following results over approximately three months (just over three months).
| Total Investigations | 1700 |
| Root Cause Identification | 600 |
| Average Daily Automated Investigations | 17 |
- More than 1,700 investigation tasks tracked
- More than 600 root causes identified
- An average of 17 automated investigations conducted daily
These figures demonstrate a qualitative leap in throughput and speed compared to the era when investigations were conducted manually. This is particularly the result of the combination of the `perf-forensics` skill, which enables "single execution from alert to diagnosis," and the factory architecture where the agent autonomously performs the entire process except for the approval stage requiring human intervention.
Implications: Meaning for Developers, Companies, and the Industry
Developer Perspective: Democratization of Expertise and Reduced Cognitive Load
In the Pre-Codex era, "knowing where to look required deep service knowledge" and selecting from over 30 performance tools according to the situation was also the domain of skilled engineers. The Performance Factory has explicitly articulated this tacit knowledge with skills like `perf-forensics`, allowing agents to take over tool selection, execution, and interpretation, thereby enabling "more people to debug difficult investigations with less expertise and time."
Company Perspective: Reduced Operational Costs and Maintained Release Speed
The response to performance regression has transitioned from an operating model where humans were on standby to handle it to a model where autonomous agents handle it 24/7. An average of 17 automated investigations signifies the liberation of engineering personnel from repetitive diagnostic tasks, making it a strategic asset that maintains service quality standards without slowing down the deployment speed of new features.
Industry Perspective: A Signal of the Generalization of the 'Agent Factory' Pattern
The six-stage evolution of OpenAI from "manual → partner → skillification → proxy → automation → factory" can be interpreted as an agentic workflow adoption framework applicable to repetitive knowledge work across code generation, review, testing, security, and data pipelines. In particular, infrastructure patterns such as task state machines, dispatch loops, and event subscriptions are likely to become the reference architecture for enterprise-grade agent orchestration.