An intelligent java method name recommendation framework via two-phase neural networks

Kang, Yujian
DOI: https://doi.org/10.1007/s10664-024-10574-1
IF: 3.762
2024-11-09
Empirical Software Engineering
Abstract:High-quality method names are very significant for us to understand programs and maintain software efficiently. Giving concise and consistent method names can help developers understand such programs well, especially for inexperienced participants. The importance of the naming strategy to software engineering (SE) has attracted researchers from all around the world who are seeking approaches to enhance the quality of method names. We solve this challenge by using a unique two-phase framework that enables us to recommend precise method names. The first phase involves gathering almost 8,000,000 Java methods from Github as three assessment datasets. We also offer a quick and easy classifier for classifying different categories of methods to improve the searching efficiency. Then, we use heuristic rules to recommend method names for simple method names prefixed with i.e., get-, set-, and is-. In the second phase, we take advantage of the deep learning network to recommend suitable method names for complex method bodies. The experimental findings show that our framework greatly outperforms well-known approaches. The precision of our framework reaches 62 , outperforming traditional approaches by 2 to 13 .
computer science, software engineering
What problem does this paper attempt to address?