Published November 2, 2023 | Version v2
Dataset Open

APIBench: A Benchmark Dataset for Evaluating API Recommendation Approaches in Python and Java

  • 1. The Chinese University of Hong Kong
  • 2. Harbin Institute of Technology, Shenzhen


APIBench is the benchmark dataset APIBench released in the paper "Revisiting, Benchmarking and Exploring APIRecommendation: How Far Are We?". 

APIBench contains two sub-dataset for evaluating the performance of query-based and code-based API recommendation approaches, namely APIBench-Q and APIBench-C. Each sub-dataset has a Java version and a Python version.

APIBench-Q contains 4,309 Python queries and 6,563 Java queries collected from Stack Overflow posts generated from Aug 2008 to Feb 2021 and tutorial websites Geeks4Geeks, Java2s, and Kode Java in April 2021.

APIBench-C contains 2,361 Python projects and 1,477 Java projects mined from GitHub in April 2021.

Please read the file for detailed information about the benchmark.

The evaluation results of existing API recommendation approaches can be found in this GitHub repository.


Files (6.8 GB)

Name Size Download all
2.9 GB Preview Download
3.9 GB Preview Download
15.0 MB Preview Download
91.6 kB Preview Download

Additional details

Related works

Is identical to
Journal article: 10.1109/TSE.2022.3197063 (DOI)