arrow
Return

Stepwise API usage assistance using n-gram language models

delete2017-09-01
delete6
delete
OA
AI
A
André L. Santos *
G
Gonçalo Prendi
H
Hugo Sousa
R
Ricardo Ribeiro
DOI:10.1016/j.jss.2016.06.063delete
deleteOriginal
deleteShare
deleteSave
View PDF
Abstract

Abstract

En 中文
Reusing software involves learning third-party APIs, a process that is often time-consuming and error prone. Recommendation systems for API usage assistance based on statistical models built from source code corpora are capable of assisting API users through code completion mechanisms in IDEs. A valid sequence of API calls involving different types may be regarded as a well-formed sentence of tokens from the API vocabulary. In this article we describe an approach for recommending subsequent tokens to complete API sentences using n-gram language models built from source code corpora. The provided system was integrated in the code completion facilities of the Eclipse IDE, providing contextualized completion proposals for Java taking into account the nearest lines of code. The approach was evaluated against existing client code of four widely used APIs, revealing that in more than 90% of the cases the expected subsequent token is within the 10-top-most proposals of our models. The high score provides evidence that the recommendations could help on API learning and exploration, namely through the assistance on writing valid API sentences. (C) 2016 Elsevier Inc. All rights reserved.
Keywords:
API
Usability
N-grams
Code completion
IDE
AI Summary

AI Summary

Key information extracted from the uploaded paper, including a brief overview, abstract, background, key highlights, visual analysis, and future outlook.

Journal

Journal of Systems and Software cover
Journal of Systems and Software
IF:
4.1
Papers:
5.4K
Citations:
8.4K

Organization

I
instituto universitario de lisboa
Scholars:
1.6K
Papers: 1.8K
Citations: 2
Cited Papers

Cited Papers

Discriminative n-gram language modeling
err2007-04-01
err135
PREAI
errRoark, Brian; Saraclar, Murat; Collins, Michael
errShare
errSave
Natural and Synthetic Modulators of the TRPM7 Channel
err2014-11-27
err0
errOAAI
errVladimir Chubanov; Sebastian Schäfer; Silvia Ferioli; Thomas Gudermann
errShare
errSave
errShare
errSave
A field study of API learning obstacles
err2010-12-14
err260
PREAI
errRobillard, Martin P.; DeLine, Robert
errShare
errSave
Recommender systems survey
err2013-07-01
err2.2K
PREAI
errBobadilla, J.; Ortega, F.; Hernando, A.; Gutierrez, A.
errShare
errSave
Improving API Usability
err2016-05-23
err124
errOAAI
errMyers, Brad A.; Stylos, Jeffrey
errShare
errSave
Automated API Property Inference Techniques
err2013-05-01
err144
errOAAI
errRobillard, Martin P.; Bodden, Eric; Kawrykow, David; Mezini, Mira; Ratchford, Tristan
errShare
errSave
no more