ACL2026

GitChameleon 2.0: Evaluating AI Code Generation Against Python Library Version Incompatibilities

Diganta Misra, Nizar Islah, Victor May, Brice Rauby, Zihan Wang, Justine Gehring, Antonio Orvieto, Muawiz Sajjad Chaudhary, Eilif B. Muller, Irina Rish, Samira Ebrahimi Kahou, Massimo Caccia

8 citations

Abstract

The rapid evolution of software libraries poses a considerable hurdle for code generation, necessitating continuous adaptation to frequent version updates while preserving backward compatibility. While existing code evolution benchmarks provide valuable insights, they typically lack execution-based evaluation for generating code compliant with specific library versions. To address this, we introduce GitChameleon 2.0, a novel, meticulously curated dataset comprising 328 Python code completion problems, each conditioned on specific library versions and accompanied by executable unit tests. GitChameleon 2.0 rigorously evaluates the capacity of contemporary large language models (LLMs), LLMpowered agents, code assistants, and RAG systems to perform version-conditioned code generation that demonstrates functional accuracy through execution. Our extensive evaluations indicate that state-of-the-art systems encounter significant challenges with this task; enterprise models achieving baseline success rates in the 48-51% range, underscoring the intricacy of the problem. By offering an execution-based benchmark emphasizing the dynamic nature of code libraries, GitChameleon 2.0 enables a clearer understanding of this challenge and helps guide the development of more adaptable and dependable AI code generation methods. 1 * *Equal contribution. Roles: Team Leads, Data and Core Contributors, Senior Advisors 1 GitChameleon 2.0 is the expanded successor to the original GitChameleon benchmark, increasing coverage from 116 to 328 Python code completion problems while preserving the same version-conditioned generation setting. Problem Statement Instruction: Write a custom_violinplot function that visualizes x and y from a Pandas DataFrame; scales the bandwidth to 1.5. Use the library Seaborn version 0.13.0. import seaborn as sns from matplotlib.axes import axes def custom_violinpolot(data: pd.DataFrame) -> Axes: return