A Systematic Evaluation of Large Code Models in API Suggestion: When, Which, and How
Chaozheng Wang, Shuzheng Gao, Cuiyun Gao, Wenxuan Wang, Chun Yong, Chong, Shan Gao, Michael R. Lyu

TL;DR
This paper systematically evaluates large code models for API suggestion across three scenarios—when, which, and how—using a new benchmark based on Java projects, revealing their strengths and limitations in practical API recommendation tasks.
Contribution
It introduces a comprehensive benchmark and evaluation framework for assessing large code models in API suggestion, covering multiple practical scenarios.
Findings
Models vary significantly across scenarios
Context selection greatly impacts model performance
Large models show promise but have limitations in practical API use
Abstract
API suggestion is a critical task in modern software development, assisting programmers by predicting and recommending third-party APIs based on the current context. Recent advancements in large code models (LCMs) have shown promise in the API suggestion task. However, they mainly focus on suggesting which APIs to use, ignoring that programmers may demand more assistance while using APIs in practice including when to use the suggested APIs and how to use the APIs. To mitigate the gap, we conduct a systematic evaluation of LCMs for the API suggestion task in the paper. To facilitate our investigation, we first build a benchmark that contains a diverse collection of code snippets, covering 176 APIs used in 853 popular Java projects. Three distinct scenarios in the API suggestion task are then considered for evaluation, including (1) ``\textit{when to use}'', which aims at determining the…
Peer Reviews
No public reviews on file for this paper yet. If you reviewed it on a platform where reviews are public (OpenReview, ICLR, NeurIPS, ICML), you can paste yours below so the community can read it here.
Videos
No videos yet. Explain this paper in a talk, walkthrough, or lecture? Add one.
Taxonomy
TopicsService-Oriented Architecture and Web Services · Software Engineering Research · Web Data Mining and Analysis
