Code 2025
Automating Large Scale Refactors with Parallel Agents - Robert Brennan, OpenHands
Overview
This talk explores automating large-scale software refactoring and maintenance tasks using parallel AI agents. The core idea is that while individual agents are effective for smaller tasks, complex, multi-faceted operations like dependency updates, code modernization, or vulnerability remediation require orchestrating multiple agents working in parallel. This approach aims to tackle significant technical debt and improve developer productivity by automating laborious processes that are currently too large or complex for a single agent.
Who should watch
- AI engineers and developers looking to automate complex code maintenance and refactoring.
- Product Managers and builders interested in leveraging AI for large-scale software updates.
- Teams struggling with technical debt, dependency management, and vulnerability remediation.
- Engineers exploring advanced agent orchestration patterns beyond single-agent workflows.
Key takeaways
- Large-scale refactoring and maintenance tasks are often too complex for a single AI agent, necessitating agent orchestration.
- Parallel agents can significantly accelerate tasks like CVE remediation, code modernization, and dependency updates, leading to substantial time savings.
- Cloud-based agent environments offer scalability and security advantages over local execution for parallel agent tasks.
- Effective task decomposition, clear dependencies, and intermediate human review are crucial for successful agent orchestration.
- The OpenHands SDK provides tools for building and orchestrating agents, enabling complex workflows like vulnerability scanning and remediation at scale.
- Strategies for task decomposition include piece-by-piece iteration, dependency tree-based ordering, and scaffolding to manage dual states during migration.
- Context sharing between agents can be managed through manual input, shared files, or direct agent-to-agent messaging, though the latter introduces non-determinism.
- Automating CVE remediation with parallel agents can reduce resolution times by up to 30x, with downstream teams only needing to merge pull requests.
Notable quotes
*Automating massive refactors with parallel agents.*
*These are tasks that are super automatable. You can throw agents at them, but they tend to be way too big for like you know a single just one shot.*
*The goal is not to automate this process 100%. It's something like 90% automation. That's still, you know, an order of magnitude productivity lift.*
Unofficial community note. Prefer the recording for nuance.