microsoft/RPG-ZeroRepo
[ICLR 2026] RPG: A Repository Planning Graph for Unified and Scalable Codebase Generation
What it solves
AI coding agents often lose repository-level context during long tasks: requirements drift, architecture decisions get forgotten, and edits miss hidden dependencies. This project gives agents a persistent graph-based planning workspace, so they can keep track of the whole repository throughout a session.
How it works
The core idea is a Repository Planning Graph (RPG) that serves as a structured, searchable map of the repository—linking requirements, features, architecture, files, and dependencies. The project provides three main pieces:
- CoderMind is the agent-facing layer. It works with Claude Code and GitHub Copilot, giving them a persistent RPG workspace via a CLI, slash commands, and MCP graph tools. Agents can plan, generate code, understand an existing codebase, and make graph-aware edits.
- ZeroRepo is the forward pipeline: starting from a natural-language requirement, it decomposes it into features and architecture, builds the RPG, then generates the repository in dependency order.
- RPG-Encoder is the reverse pipeline: it takes an existing codebase and encodes it back into an RPG, so agents can navigate and maintain repositories.
- RepoCraft is a benchmark for evaluating repository-level code generation, measuring coverage, accuracy, and code statistics.
Who it’s for
- Developers using AI coding assistants (Claude Code or GitHub Copilot) who need to handle large, multi-file projects without losing the big picture.
- Researchers reproducing the papers behind RPG, ZeroRepo, or RPG-Encoder, or working on repository-level code generation.
- Teams that want to evaluate or improve long-horizon coding agents.
Highlights
- Persistent RPG workspace replaces chat history and file search as the agent’s memory for repository context.
- Supports both directions: generating a repository from requirements (ZeroRepo) and mapping an existing repository to a graph (RPG-Encoder).
- Integrates with Claude Code and GitHub Copilot via slash commands and MCP tools.
- Includes RepoCraft, a benchmark with 1,052 tasks across 6 real-world Python projects (scikit-learn, pandas, sympy, statsmodels, requests, django).
- Backed by two peer-reviewed papers (ICLR 2026 and ICML 2026) and an MIT license.
Related
- Project
- Project
- Project
- Project
- Project