NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

BigCodeBench: Benchmarking Code Generation with Diverse Function Calls and Complex Instructions

Terry Yue Zhuo, Vu Minh Chien, Jenny Chim, Han Hu, Wenhao Yu, Ratnadira Widyasari, Imam Nur Bani Yusuf, Haolan Zhan, Junda He, Indraneil Paul, Simon Brunner, Chen Gong, James Hoang, Armel Randy Zebaze, Xiaoheng Hong, Wen-Ding Li, Jean Kaddour, Ming Xu, Zhihan Zhang, Prateek Yadav, Naman Jain, Alex Gu, Zhoujun Cheng, Jiawei Liu, Qian Liu, Zijian Wang, Binyuan Hui, Niklas Muennighoff, David Lo, Daniel Fried, Xiaoning Du, Harm de Vries, Leandro Von Werra

TL;DR

BigCodeBench is a new, rigorous benchmark designed to close the gap between "toy" coding exercises and real-world software development. By challenging Large Language Models (LLMs) to use 139 different Python libraries across 1,140 complex tasks, it reveals that even top-tier models like GPT-4o still struggle with compositional reasoning, achieving only ~60% accuracy compared to a 97% human baseline.

What Problem Does This Paper Address?

While LLMs have shown impressive results on classic benchmarks like HumanEval and MBPP, these evaluations are increasingly "saturated" and unrepresentative of actual programming. Most existing benchmarks focus on short, self-contained algorithmic puzzles or standalone function calls.

In contrast, real-world task automation requires:

  1. Diverse Tool Use: Invoking specific functions from a wide array of domain-specific libraries (e.g., pandas, matplotlib, cryptography).
  2. Complex Instruction Following: Reasoning through multi-step requirements where the order of operations, error handling, and specific formatting are critical.

The authors argue that current models are hitting a ceiling on simple tasks but failing to translate that success into practical, multi-library "compositional" programming.

Methods

The authors developed a collaborative human-LLM framework to construct 1,140 high-quality programming tasks. The process involves three main stages:

  1. Data Synthesis: Using GPT-4 to expand simple code "seeds" from the ODEX dataset into complex, practical scenarios.
  2. Semi-automatic Refactoring & Test Generation: Leveraging GPT-4’s Code Interpreter to refine implementations and generate at least five test cases per task. Human annotators provided continuous feedback to guide the model when it failed to self-debug.
  3. Human Curation: A team of 20 experts performed a rigorous manual examination to ensure tasks were unambiguous, followed PEP-257 docstring standards, and had high test coverage (averaging 99% branch coverage).
The three-stage construction process for BigCodeBench tasks.

The benchmark is split into two variants:

  • BigCodeBench-Complete: Evaluates code generation based on structured, verbose docstrings.
  • BigCodeBench-Instruct: A more difficult variant where docstrings are transformed into short, natural-language instructions, mimicking how a human might actually prompt a coding assistant.

Datasets

The primary contribution is the BigCodeBench dataset, which features:

  • 1,140 tasks across 7 domains (Computation, Visualization, System, etc.).
  • 139 libraries and 723 unique function calls.
  • Rigorous Testing: An average of 5.6 test cases per task.

Each task is meticulously structured, including detailed docstrings with parameters, return types, exceptions, requirements, and test cases to ensure rigorous evaluation.

Structure of a BigCodeBench task, detailing parameters, returns, and requirements.

The authors compared LLM performance on BigCodeBench against established benchmarks including HumanEval, MBPP, DS-1000, and ODEX.

Key Insights and Ideas

  • "Model Laziness": The authors observed that instruction-tuned models often omit essential boilerplate (like import statements or global constants) when responding to long prompts. They introduced a "calibrated" scoring method to account for this by manually adding missing setup code during evaluation.
  • Sensitivity to Verbosity: Models perform significantly worse on the Instruct variant than the Complete variant. This suggests that LLMs rely heavily on the explicit hints provided in structured docstrings and struggle to "fill in the blanks" when given concise human instructions.
  • Domain Specialization: Models are "jacks of all trades but masters of most." While they excel in general computation and data analysis, they frequently fail in the Network domain, likely due to the complexity of handling socket connections and SSL contexts.
  • The Complexity Gap: BigCodeBench tasks have much higher cyclomatic complexity (more independent logic paths) than HumanEval or DS-1000, making it a much truer test of reasoning.

Key Results

The evaluation of 60 different LLMs produced several striking findings:

  • The Performance Gap: The best-performing model, GPT-4o, achieved a calibrated score of 61.1% on the Complete set and only 51.1% on the Instruct set. This is a far cry from the 97% achieved by human experts.
  • Scaling Laws: Generally, larger models perform better, but the gap between closed-source (OpenAI, Anthropic) and open-source models remains significant.
  • Instruction Tuning: While instruction tuning helps models follow constraints, it doesn't necessarily improve their fundamental ability to reason through complex library interactions.

Limitations and Future Work

  • Multilingualism: Currently, BigCodeBench is limited to Python. The authors plan to expand to other languages where function call patterns differ.
  • Saturation: As models continue to improve, the authors have already proposed a "Hard" subset of the benchmark to maintain a meaningful evaluation ceiling.
  • Agentic Interaction: Future versions aim to evaluate models in an interactive "sandbox" environment where they can self-debug and repair code iteratively, rather than just generating it in a single pass.
  • API Evolution: Libraries change over time. The authors acknowledge the need for a "BigCodeBench-Evolved" to handle deprecated APIs and new library versions.

Summary updated

BibTeX
@inproceedings{zhuo2025bigcodebench,
  author = {Terry Yue Zhuo and Vu Minh Chien and Jenny Chim and Han Hu and Wenhao Yu and Ratnadira Widyasari and Imam Nur Bani Yusuf and Haolan Zhan and Junda He and Indraneil Paul and Simon Brunner and Chen GONG and James Hoang and Armel Randy Zebaze and Xiaoheng Hong and Wen-Ding Li and Jean Kaddour and Ming Xu and Zhihan Zhang and Prateek Yadav and Naman Jain and Alex Gu and Zhoujun Cheng and Jiawei Liu and Qian Liu and Zijian Wang and Binyuan Hui and Niklas Muennighoff and David Lo and Daniel Fried and Xiaoning Du and Harm de Vries and Leandro Von Werra},
  title = {{BigCodeBench: Benchmarking Code Generation with Diverse Function Calls and Complex Instructions}},
  booktitle = {International Conference on Learning Representations},
  year = {2025},
  url = {https://openreview.net/forum?id=YrycTjllL0},
}
Figure