ResearchTrend.AI
  • Papers
  • Communities
  • Events
  • Blog
  • Pricing
Papers
Communities
Social Events
Terms and Conditions
Pricing
Parameter LabParameter LabTwitterGitHubLinkedInBlueskyYoutube

© 2025 ResearchTrend.AI, All rights reserved.

  1. Home
  2. Papers
  3. 2506.11058
21
0
v1v2 (latest)

Refactoring Codebases through Library Design

26 May 2025
Ziga Kovacic
Celine Lee
Justin T Chiu
Wenting Zhao
Kevin Ellis
ArXiv (abs)PDFHTML
Main:7 Pages
5 Figures
8 Tables
Appendix:22 Pages
Abstract

Maintainable and general software allows developers to build robust applications efficiently, yet achieving these qualities often requires refactoring specialized solutions into reusable components. This challenge becomes particularly relevant as code agents become increasingly accurate at solving isolated programming problems. We investigate code agents' capacity to refactor code in ways supporting growth and reusability. We present both a method and a benchmark for refactoring: Librarian, a sample-and-rerank method for generating reusable libraries, and Minicode, a benchmark where code agents must minimize and refactor multiple independent solutions into a joint library. Compared to state-of-the-art code agents, Librarian achieves strong results on both compression and correctness on Minicode, obtaining compression rates 1.6-2x better than coding agents while also improving correctness. We open-source our code and benchmark at this https URL.

View on arXiv
@article{kovacic2025_2506.11058,
  title={ Refactoring Codebases through Library Design },
  author={ Ziga Kovacic and Celine Lee and Justin Chiu and Wenting Zhao and Kevin Ellis },
  journal={arXiv preprint arXiv:2506.11058},
  year={ 2025 }
}
Comments on this paper