How iFood scales coding agents across 15,000 repositories IFood built a Remote Agents Platform that turns engineering tasks into REST API calls, running agentic coding jobs in isolated Ubuntu sandboxes and returning results as merge requests across its more than 15,000 code repositories, with 25,000+ runs completed at an average inference cost of US$0.04 per run. Senior Software Engineer Victor Coelho said the platform uses GPT-5.6 Luna because benchmarks showed "a great balance of intelligence, efficiency, and execution speed," and that the platform more than doubled the number of vulnerabilities fixed through iFood's internal security platform. The design bookends agentic execution with deterministic steps — cloning the repo, importing agent skills and setting up a working branch at the start, then publishing the merge request at the end — to keep workflows predictable at scale. 15,000 code repositories at iFood 25,000+ runs completed by the platform US$0.04 average inference cost per run 2x+ as many vulnerabilities fixed through the security platform The Remote Agents Platform turned engineering tasks into API calls: teams delegate the work, execution takes place in a remote sandbox, and the result comes back as a merge request. In the internal security platform, the number of vulnerabilities fixed more than doubled. iFood maintains more than 15,000 code repositories. Each periodically needs specific tasks performed: validating code to ensure it meets internal standards, fixing vulnerable dependencies, or running an analysis. None of these tasks is difficult on its own. The challenge comes when those tasks multiply. “Solving this for one repository is easy. The challenge is solving it at scale,” says Victor Coelho, Senior Software Engineer at iFood. “The Remote Agents Platform is designed to make it possible to solve this at scale across all 15,000 repositories.” Before the platform, each team tackled the problem in its own way—and they all ran into the same obstacle. “Before, we had fragmented solutions. Imagine several teams at iFood trying to solve different problems, but without this layer, this agentic runtime, available to them. In the end, those solutions always ran into the same problem.” What was missing wasn’t intelligence or a use case. It was execution infrastructure. A dedicated runtime . “Teams can focus on solving their business problems and delegate execution to our platform.” The team describes the Remote Agents Platform as an API that launches a remote agentic coding task. The cycle has three steps: the user submits a prompt and environment requirements through a REST call; the platform processes the task on a dedicated remote runner inside an isolated sandbox; and the result is retrieved later. “The platform’s entry point, its interface, is a simple REST API. Users can use this API to create the runs they need. Internally, we handle and manage the entire lifecycle and delegate execution to isolated sandboxes,” he explains. Task progress can be monitored in real time. The runner’s internal design alternates between two different types of steps—and that combination makes the overall workflow predictable. Deterministic steps bookend the workflow: cloning the repository, importing the skills the agent can use, and setting up the working branch at the start; publishing the merge request and making the generated artifacts available at the end. In between is the agentic execution itself, running GPT‑5.6 Luna inside the sandbox. “It’s a combination of those two things: deterministic steps and agentic execution within the workflow.” The sandbox runs Ubuntu and includes the toolchains iFood’s ecosystem requires—Python, Java, Kotlin, C , TypeScript, Rust, JavaScript, and Go—along with general-purpose tools. Beyond the sandbox, the agent can access Nexus, GitLab, Docker, Snyk, Kubernetes, and AWS. The model choice came down to three factors considered together, rather than just one. “We chose GPT‑5.6 Luna because, among models at the same checkpoint, the benchmarks showed it offered a great balance of intelligence, efficiency, and execution speed—how quickly it could complete tasks. Those three qualities together led us to choose GPT‑5.6 Luna.” That balance matters more for a platform built to scale than it would for a one-off use case. With tens of thousands of tokens being consumed, the average cost of four U.S. cents per run stops being a minor detail and becomes an architectural consideration. “Given our plans to scale the platform across many use cases at iFood, the balance of efficiency and intelligence that OpenAI’s model provides ensures we can scale sustainably.” Delegating execution at scale creates a new challenge: automatically determining whether the agent did what it was supposed to do. iFood’s answer comes in the step after the session. Once execution is complete, the result is processed using OpenAI’s Structured Outputs, which requires the output to conform to a predefined contract. “We process the result using Structured Outputs, which ensures the response follows a predefined contract. From the agent’s session, we can identify the outputs within the response structure we expect. This helps reduce uncertainty and ensures we can always get a response from the agent’s session, whether positive or negative.” The platform already powers an internal iFood security product that scans the 15,000 repositories for vulnerable dependencies and attempts to fix them. The migration had a direct impact: “With our platform, the accuracy of those changes, those fixes, more than doubled,” says Coelho. This use case illustrates the idea behind the platform: the security team didn’t need to build its own agentic runtime or become experts in agent orchestration. It needed to call an API. The team emphasizes what asynchronous execution frees developers to do, rather than replacement. Because the task is delegated and runs without supervision, the developer doesn’t have to stay focused on monitoring it. “While they’re in a meeting, they can launch a code fix, a performance analysis, or another task that’s a little more routine—something they can delegate without having to monitor it at that moment.” Routine work no longer competes for the team’s attention. That leaves time for problems that require judgment. “You can unlock those productivity gains without necessarily having to monitor the work as it happens.” The Remote Agents Platform was designed as an internal layer with similarities to the way OpenAI makes this type of task available to external customers. “The Remote Agents Platform drew a lot of inspiration from OpenAI’s APIs, both the Batch API and the Agents API, which is an even more recent OpenAI product. We built a platform that resembles those products, but is internal to iFood.” The inspiration went beyond the concept. It extends to the design of the interfaces, the organization of resources, and the approach to asynchronous execution with results retrieved later. “These products directly inspired how we built our solution.” - The platform has completed more than 25,000 tasks, consuming more than 27 billion tokens, at an average cost of US$0.04 per run. - After migrating to the Remote Agents Platform, the internal security platform more than doubled both the accuracy of its fixes and the number of vulnerabilities resolved. - Coverage extends across iFood’s more than 15,000 code repositories. - All runs use GPT‑5.6 Luna, chosen for its balance of intelligence, efficiency, and speed. - Structured Outputs ensures that each session returns a result that follows a predefined contract, whether positive or negative. - Product teams have moved from building fragmented solutions to delegating agentic execution through a REST API. - The bottleneck is often the runtime, not the use case. Several teams already knew what they wanted to automate; they lacked an environment in which to run it. - Combine deterministic steps with agentic execution. Cloning, publishing, and making artifacts available don’t require a model; the complex task in between does. - Treat cost per run as an architectural decision. At scale, the cost per task determines what is feasible to automate. - Require outputs to follow a contract. Without a structured response, there’s no way to know at scale whether the agent achieved its objective. - Asynchronous execution is the real productivity gain. The value lies in not having to monitor the work, rather than completing it faster while watching over it. - Expose agentic capabilities through an internal API so other teams can use them without rebuilding the infrastructure. - Isolate each run in its own sandbox, with your ecosystem’s toolchains already installed. - Choose a model by considering intelligence, cost, and speed together, rather than a single benchmark. - Use structured outputs to classify success and failure automatically. - Start with an internal user with a clear pain point and high volume—at iFood, that was the security platform. The team plans to bring the platform to many more use cases across iFood, expanding the range of internal products that delegate agentic execution to it—with cost per task determining whether that expansion can be sustained.