PaperCompiler: Faithful Paper-to-Code Generation via Repository-Level Specification Compilation
Yunhao Liu, Hong Phuc Pham, Jaehong Yoon
NTU Singapore
Published September 2, 2026 · on the feed September 3, 2026 · ▲ 6 · arXiv 2609.02272
The abstract
Faithfully translating research papers into repository-level implementations remains challenging because papers often describe methods at a high level, leave implementation assumptions implicit, and require generated repositories to preserve method logic, evaluation protocols, and cross-file consistency. Despite recent advances in paper-to-code agents, their intermediate outputs are often presented as free-form plans or summaries that downstream coding agents may ignore, reinterpret, or compress, leading to algorithmic simplification and inconsistent repository structure. To address these challenges, we introduce PaperCompiler, a paper-to-code generation framework that compiles paper-grounded evidence into explicit repository-level implementation specifications. PaperCompiler grounds implementation-relevant evidence while preserving source provenance and distinguishing paper-supported, inferred, externally delegated, and unresolved information. The resulting specifications encode non-degradation requirements, ownership assignments, cross-file dependencies, and file-level constraints. Repository generation proceeds under these compiled specifications while retaining flexibility over local engineering choices not fixed by the paper. PaperCompiler outperforms strong baselines on Paper2CodeBench, achieving a 13.8% relative improvement in reference-based fidelity (from 3.64 to 4.15) and reducing high-severity evaluator critiques (from 13.2% to 6.1%).
The Brief
2:15A short podcast summary of the paper. Written and voiced by AI.
Transcript
PaperCompiler. Faithful Paper-to-Code Generation via Repository-Level Specification Compilation. By Yunhao Liu and two others, from Nanyang Technological University, Singapore. Published on the second of September. Its code repository is public and real: eleven source files.
Turning a research paper into a working repository is hard to do faithfully. Papers often describe methods at a high level and leave implementation assumptions implicit, while the repository that comes out has to preserve the method's logic, its evaluation protocol, and consistency across many files. Paper-to-code agents have advanced, but their intermediate outputs tend to be free-form plans or summaries. A downstream coding agent may ignore those, reinterpret them, or compress them, and the result is a simplified algorithm and a repository whose structure does not hang together.
PaperCompiler replaces the loose plan with something closer to a contract. It compiles evidence grounded in the paper into explicit, repository-level implementation specifications. While doing so it keeps track of where each piece of evidence came from, and it separates four kinds of information: what the paper supports, what was inferred, what is delegated to something external, and what remains unresolved.
The compiled specifications encode several things a free-form plan leaves loose. There are non-degradation requirements, ownership assignments, dependencies that cross file boundaries, and constraints at the level of individual files. Repository generation then proceeds under those specifications. It is not a rigid template, though. Local engineering choices that the paper itself does not fix are left flexible, so the specification binds what the paper determines and leaves the rest to the coding agent.
On Paper2CodeBench, PaperCompiler outperforms strong baselines. Reference-based fidelity rises from three point six four to four point one five, a relative improvement of thirteen point eight percent. High-severity critiques from the evaluator fall from thirteen point two percent to six point one percent, less than half the earlier rate.
The contribution sits in the hand-off between reading and writing. Where earlier pipelines passed a summary that could be quietly reinterpreted, this one passes a specification that records provenance, marks what is known and what is not, and states which requirements must survive into the code.
Paper Quest · 7 chapters · about 39 min
Play this paper
Learn it by doing: make the calls the authors made, guess the result before you see it, and defend it in a viva graded on your own words. Chapter 1 is right here.
Chapter 1 🧩 · The problem
Papers leave gaps, and coding agents fill them the easy way. That is the wall here.
You hand a research paper to a coding agent and ask for a full repository. The paper describes its method at a high level and leaves many implementation assumptions unstated.
The road ahead
- 1 · The problem ~6 min A coding agent loses a paper's method details as notes pass between stages, so the finished repository simplifies the algorithm and its files disagree.
- 2 · What came before ~3 min
- 3 · The key idea ~8 min Replace the loose plan with explicit specifications compiled from paper evidence, each requirement owned by a file, with rules against simplifying the method.
- 4 · Choose your own research ~3 min
- 5 · Build the method ~8 min Ground evidence in the paper, tag how sure each piece is, compile it into per-file specifications, then generate files under them.
- 6 · The experiment ~6 min You’ll guess: On Paper2CodeBench, how big was PaperCompiler's relative improvement in reference-based fidelity over strong baselines?
- 7 · The viva ~5 min Three questions from the examiners, answered in your own words. Win it for the paper’s trophy.
Free, with Google or an email address. Your stars and progress are kept.