How iFood scales coding agents across 15,000 repositories
本文为原文前 6,000 字符的节选翻译,完整内容请查看原文。
How iFood scales coding agents across 15,000 repositories
2026年11月24日,iFood 如何在 15,000 个代码仓库中扩展编码智能体。联系销售,企业规模,拉丁美洲地区,技术行业,产品:API。iFood 拥有 15,000 个代码仓库,平台已完成 25,000 多次运行,平均每次运行推理成本为 0.04 美元,通过安全平台修复的漏洞数量增加了 2 倍以上。
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.
远程智能体平台将工程任务转化为 API 调用:团队委派工作,执行在远程沙箱中进行,结果以合并请求的形式返回。在内部安全平台中,修复的漏洞数量增加了一倍以上。
The challenge isn’t the task—it’s the scale. 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.
挑战不在于任务本身,而在于规模。iFood 维护着超过 15,000 个代码仓库。每个仓库都需要定期执行特定任务:验证代码以确保其符合内部标准、修复易受攻击的依赖项或运行分析。这些任务单独来看并不困难,但当任务数量成倍增加时,挑战就出现了。
“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.”
“为一个仓库解决这个问题很容易。挑战在于如何大规模地解决它,”iFood 高级软件工程师 Victor Coelho 表示。“远程智能体平台旨在使在所有 15,000 个仓库中大规模解决此问题成为可能。”
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.”
在该平台出现之前,每个团队都以自己的方式处理问题,但他们都遇到了同样的障碍。“以前,我们的解决方案是碎片化的。想象一下 iFood 的几个团队试图解决不同的问题,但没有这个层级,即这个智能体运行时供他们使用。最终,这些解决方案总是遇到同样的问题。”
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.”—Victor Coelho, Senior Software Engineer, iFood.
缺失的不是智能或用例,而是执行基础设施,即一个专用的运行时。“团队可以专注于解决他们的业务问题,并将执行工作委派给我们的平台。”——iFood 高级软件工程师 Victor Coelho。
A coding agent in the cloud, accessible through an API. 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.
云端的编码智能体,可通过 API 访问。该团队将远程智能体平台描述为一个启动远程智能体编码任务的 API。该周期分为三个步骤:用户通过 REST 调用提交提示词和环境要求;平台在隔离沙箱内的专用远程运行器上处理任务;随后获取结果。
“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.
“该平台的入口点及其接口是一个简单的 REST API。用户可以使用此 API 创建他们需要的运行任务。在内部,我们处理和管理整个生命周期,并将执行委派给隔离的沙箱,”他解释道。任务进度可以实时监控。
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.
运行器的内部设计在两种不同类型的步骤之间交替,这种组合使得整体工作流程具有可预测性。确定性步骤构成了工作流程的起点和终点:开始时克隆仓库、导入智能体可使用的技能并设置工作分支;结束时发布合并请求并提供生成的工件。中间则是智能体执行本身,在沙箱内运行 GPT-5.6 Luna。
“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.
“这是工作流程中这两者的结合:确定性步骤和智能体执行。”沙箱运行 Ubuntu,并包含 iFood 生态系统所需的工具链(Python、Java、Kotlin、C#、TypeScript、Rust、JavaScript 和 Go)以及通用工具。在沙箱之外,智能体可以访问 Nexus、GitLab、Docker、Snyk、Kubernetes 和 AWS。
Why GPT‑5.6 Luna. 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.”
为什么选择 GPT-5.6 Luna?模型选择归结为三个综合考虑的因素,而不仅仅是一个。“我们选择 GPT-5.6 Luna 是因为在相同检查点的模型中,基准测试显示它在智能、效率和执行速度(完成任务的速度)之间提供了极佳的平衡。这三种品质共同促使我们选择了 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.”—Victor Coelho, Senior Software Engineer, iFood.
对于一个旨在扩展的平台而言,这种平衡比一次性用例更为重要。随着数万个 Token 的消耗,每次运行平均 4 美分的成本不再是一个微小的细节,而成为了一项架构考量。“鉴于我们计划在 iFood 的许多用例中扩展该平台,OpenAI 模型提供的效率与智能的平衡确保了我们可以可持续地进行扩展。”——iFood 高级软件工程师 Victor Coelho。
How to tell whether the agent completed the task. 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.
如何判断智能体是否完成了任务?大规模委派执行带来了一个新挑战:自动确定智能体是否完成了预定任务。iFood 的答案是在会话后的步骤中给出的。一旦执行完成,结果将使用 OpenAI 的结构化输出(Structured Outputs)进行处理,这要求输出符合预定义的契约。
“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.”—Victor Coelho, Senior Software Engineer, iFood.
“我们使用结构化输出处理结果,这确保了响应遵循预定义的契约。从智能体的会话中,我们可以识别出响应结构中我们预期的输出。这有助于减少不确定性,并确保我们始终能从智能体的会话中获得响应,无论是正面还是负面的。”——iFood 高级软件工程师 Victor Coelho。
The first major user: security. 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.
第一个主要用户:安全部门。该平台已经为 iFood 的一个内部安全产品提供支持,该产品扫描 15,000 个仓库以查找易受攻击的依赖项并尝试修复它们。迁移产生了直接影响:“有了我们的平台,这些更改和修复的准确性提高了一倍以上,”Coelho 说。这个用例阐明了平台背后的理念:安全团队不需要构建自己的智能体运行时,也不需要成为智能体编排方面的专家。他们只需要调用一个 API。
Asynchronous execution gives developers their time back. 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 w
常规工作不再占用团队的注意力。这留出了时间来处理需要判断力的问题。“你可以释放这些生产力收益……”