← Latest papers
🤖 AI

Repo0: Design-Driven Zero-to-All Code Generation

Repo0 introduces a continuous structural evolution framework that utilizes a Dual-Directed-Acyclic-Graph (Dual-DAG) to iteratively refine modular repository architectures from natural-language requirements before guiding test-driven code generation, achieving superior functionality coverage and pass rates compared to existing baselines.

Original authors: Silin Chen, Haoyi Teng, Xiaodong Gu, Yuling Shi, Jiale Huang, Yongpan Wang, Hongyu Zhang, Haibing Guan

Published 2026-08-21
📖 5 min read🧠 Deep dive

Original authors: Silin Chen, Haoyi Teng, Xiaodong Gu, Yuling Shi, Jiale Huang, Yongpan Wang, Hongyu Zhang, Haibing Guan

Original paper licensed under CC BY 4.0 (http://creativecommons.org/licenses/by/4.0/). This is an AI-generated explanation of the paper below. It is not written or endorsed by the authors. For technical accuracy, refer to the original paper. Read full disclaimer

In the world of software creation, building a program has long been treated like assembling a house from a finished blueprint. An architect draws the plans, deciding exactly where the walls, doors, and windows go, and then builders follow those instructions to lay the bricks. For years, artificial intelligence systems designed to write code have operated under this same assumption: they were given a pre-existing map of the software's structure and asked only to fill in the details. But in the real world, software is rarely built from a perfect, static plan. Requirements change, connections between parts become tangled, and the initial design often reveals its flaws only when the first lines of code are written. This gap between a rigid plan and the messy reality of building something from scratch is where a new approach is emerging, one that treats the design of a software project not as a fixed starting point, but as a living thing that grows and changes alongside the code itself.

Researchers at Shanghai Jiao Tong University and Chongqing University have developed a system called Repo0 to tackle this challenge. Their work addresses a specific and difficult problem known as "zero-to-all" code generation. This is the task of taking a simple, natural-language description of what a piece of software should do and constructing the entire project from the ground up, without any pre-existing files, folders, or architectural diagrams to guide the way. Previous attempts at this task often failed because the AI would generate code that worked in isolation but clashed with the rest of the system, creating a tangled mess of dependencies that was hard to maintain. The researchers found that the core issue was not the AI's ability to write code, but its inability to organize that code into a coherent structure that could evolve as the project grew.

To solve this, the team created a framework that continuously refines the software's architecture while it is being built. Instead of locking in a design at the very beginning, Repo0 maintains a dynamic map of the project's structure. This map is split into two layers: one that tracks what the software needs to do, and another that tracks how the software is built to do it. As the system works, it constantly checks these two layers against each other. If a part of the software becomes too broad or tries to do too many unrelated things, the system identifies this lack of focus and splits it into smaller, more specialized pieces. Conversely, if two parts are so tightly connected that they are essentially doing the same job, the system merges them to reduce redundancy. This process is guided by specific rules about how software components should relate to one another, ensuring that the final product is organized, efficient, and easy to understand.

The researchers tested this approach on six real-world software projects, ranging from small utilities to massive data analysis libraries. They compared Repo0 against other advanced AI systems that used traditional, static planning methods. The results were clear: the system that allowed its design to evolve continuously produced significantly better software. It successfully implemented a much higher percentage of the required features and passed more of the rigorous tests designed to check if the code actually worked as intended. In some cases, the improvement was dramatic, with the new system achieving nearly perfect coverage of required functions where other methods struggled to reach even half. The study showed that the key to success was not just writing more code, but having the system recognize when its own structure was becoming messy and fixing it before moving forward.

A critical finding was that the system needed to stop refining its design at the right time. If the AI kept changing the structure indefinitely, the project would become fragmented and unstable. The researchers found that by using specific measures of how well the parts fit together, the system could determine exactly when the design had settled into its best form. Once this point of stability was reached, the system would lock in the structure and focus entirely on generating the code. This balance between constant improvement and knowing when to stop proved essential. Without these guiding rules, the AI tended to over-complicate the design, breaking it into too many tiny pieces and making the final product harder to use.

The study also revealed that the quality of the initial design mattered less than the ability to correct it. Even when the system started with a rough or imperfect plan, the continuous process of splitting, merging, and revising allowed it to recover and build a robust structure. This suggests that for complex tasks, the ability to adapt and self-correct is more valuable than the ability to get the first guess right. The researchers demonstrated that by treating the software architecture as a continuous process of evolution rather than a single event, AI agents can build complex systems that are not only functional but also well-organized and reliable. This approach marks a shift in how we think about automated software creation, moving away from the idea of a perfect blueprint and toward a more flexible, responsive method of construction that mirrors the way human developers actually work.

Drowning in papers in your field?

Get daily digests of the most novel papers matching your research keywords — with technical summaries, in your language.

Try Digest →