API code recommendation using statistical learning from fine-grained changes

@article{Nguyen2016APICR,
  title={API code recommendation using statistical learning from fine-grained changes},
  author={Anh Tuan Nguyen and Michael C Hilton and Mihai Codoban and Hoan Anh Nguyen and Lily Mast and Eli Rademacher and Tien Nhut Nguyen and Danny Dig},
  journal={Proceedings of the 2016 24th ACM SIGSOFT International Symposium on Foundations of Software Engineering},
  year={2016}
}
  • A. Nguyen, Michael C Hilton, Danny Dig
  • Published 1 November 2016
  • Computer Science
  • Proceedings of the 2016 24th ACM SIGSOFT International Symposium on Foundations of Software Engineering
Learning and remembering how to use APIs is difficult. While code-completion tools can recommend API methods, browsing a long list of API method names and their documentation is tedious. Moreover, users can easily be overwhelmed with too much information. We present a novel API recommendation approach that taps into the predictive power of repetitive code changes to provide relevant API recommendations for developers. Our approach and tool, APIREC, is based on statistical learning from fine… 

Figures and Tables from this paper

Effective API Recommendation without Historical Software Repositories
TLDR
Empirical evaluation on a large corpus of open source projects shows that RecRank significantly improves top-1 API recommendation accuracy and mean reciprocal rank when compared to state-of-the-art API recommendation approaches.
Revisiting, Benchmarking and Exploring API Recommendation: How Far Are We?
TLDR
This paper revisits the API recommendation task and groups the approaches into two categories according to the task definition, i.e., query-based API recommendation and code- based API recommendation, and builds a benchmark named APIBench, which distill some actionable insights and challenges for API recommendation.
Generative API usage code recommendation with parameter concretization
TLDR
An engine called DeepAPIRec is developed, which automatically recommends the API usage code for Java programs based on a tree-based long short-term memory (LSTM) neural network inspired by recent developments in the machine-learning community.
Learning APIs through Mining Code Snippet Examples
TLDR
A Bi-LSTM based encoder-decoder model with attention mechanism and beam search, DAMCA is proposed that takes all three lexical, syntactic and semantic contexts of a method call and returns a list of method call sequences as the completion suggestions.
APIRecX: Cross-Library API Recommendation via Pre-Trained Language Model
TLDR
APIRecX is proposed, the first cross-library API recommendation approach, which uses BPE to split each API call in each API sequence and pre-trains a GPT based language model, and then recommends APIs by fine-tuning the pre-trained model.
Query expansion based on statistical learning from code changes
TLDR
It is discovered that code changes can imply what users want and proposed a novel query expansion technique with code changes (QECC), which exploits (changes, contexts) pairs from changed methods and recommends the query results that meet actual needs perfectly.
Personalized API Recommendations
TLDR
This work proposes a personalized API recommendation method that considers developers’ differences and achieves better accuracy in recommending both library APIs and self-defined APIs compared with the state-of-the-art.
An analysis of correctness for API recommendation: are the unmatched results useless?
TLDR
The online evaluation confirms that some unmatched APIs can also benefit to programming due to the functional correlation with ground-truth APIs, and proposes an approach to improve the measurement of correctness based on API functional correlation.
Holistic Combination of Structural and Textual Code Information for Context based API Recommendation
TLDR
APIRec-CST is a deep learning model that combines the API usage with the text information in the source code based on an API Context Graph Network and a Code Token Network that simultaneously learn structural and textual features for API recommendation.
Learning from Examples to Find Fully Qualified Names of API Elements in Code Snippets
TLDR
This paper proposes a novel context-sensitive technique, called COSTER, to resolve FQNs of API elements in such code snippets, which significantly reduces the training time compared to the StatType, a state-of-the-art technique, without sacrificing accuracy.
...
1
2
3
4
5
...

References

SHOWING 1-10 OF 55 REFERENCES
Automatic recommendation of API methods from feature requests
TLDR
This work proposes an automated approach that takes as input a textual description of a feature request, and recommends methods in library APIs that developers can use to implement the feature.
Automatic parameter recommendation for practical API usage
TLDR
An automated technique, called Precise, is proposed, which mines existing code bases, uses an abstract usage instance representation for each API usage example, and then builds a parameter usage database and generates parameter candidates by concretizing the instances adaptively.
ExPort: Detecting and visualizing API usages in large source code repositories
TLDR
This paper presents a technique for automatically mining and visualizing API usage examples capable of finding examples of API usage that occur across several functions in a program by representing software as a Relational Topic Model.
Exploring API method parameter recommendations
TLDR
A study is presented that helps to understand how developers complete method parameters and a recommendation technique is developed, called Parc, that collects parameter usage context using a source code localness property that suggests that developers tend to collocate related code fragments.
Mining fine-grained code changes to detect unknown change patterns
TLDR
This work presents the first approach that identifies previously unknown frequent code change patterns from a fine-grained sequence of code changes, and effectively handles challenges that distinguish continuous code change pattern mining from the existing data mining techniques.
A Dataset for API Usage
TLDR
This work introduces an approach that takes type information into account while mining API method invocations and annotation usages, and accurately makes a connection between a method invocation and the class of the API to which the method belongs to.
Using Structure-Based Recommendations to Facilitate Discoverability in APIs
TLDR
The results provide evidence that relevant API elements not accessible from the type a developer is working with could be efficiently located through guidance based on structural relationships, and help developers overcome discoverability hurdles in multiple tasks and various contexts.
An evaluation of the strategies of sorting, filtering, and grouping API methods for Code Completion
TLDR
Three ways to enhance the current code-completion systems to work more effectively with large APIs are proposed, including two methods for sorting APIs, by type hierarchy and by use count, and a proposal to group API proposals by their functional roles which can help maintain a well-ordered, meaningful list of API proposals in the presence of dynamic reordering.
Lase: Locating and applying systematic edits by learning from examples
TLDR
The results indicate that LASE should help developers in automating systematic editing, as it is the first to do both for nontrivial program edits.
Mining source code repositories at massive scale using language modeling
TLDR
This paper builds the first giga-token probabilistic language model of source code, based on 352 million lines of Java, and proposes new metrics that measure the complexity of a code module and the topical centrality of a module to a software project.
...
1
2
3
4
5
...