Towards an Automated Classification of Software Libraries

被引:0
作者
Auch M. [1 ]
Balluff M. [1 ]
Mandl P. [1 ]
Wolff C. [2 ]
机构
[1] University of Applied Sciences Munich, Lothstraße 34, Munich
[2] University of Regensburg, Universitätsstraße 31, Regensburg
关键词
Classification; !text type='Java']Java[!/text; Machine learning; Recurrent neural network; Software libraries;
D O I
10.1007/s42979-024-02654-2
中图分类号
学科分类号
摘要
Nowadays, the use of third-party libraries in software is common. At the same time, the number of published libraries continues to increase. An automated classification should help to maintain an overview and identify similar software libraries. This paper investigates if new approaches can be used to classify all software libraries crawled from Apache Maven repositories into defined classes using machine learning. In addition to tags that are not always available or of poor quality, we examine one feature that is always available—the id. Consisting of group-id and artifact-id, the id of an Apache Maven software library contains valuable information that can help in classification. Through a developed preprocessing and an optimized recurrent neural network (RNN), the tokenised ids should allow a classification of most libraries. Furthermore, we present an optimized approach through a hybrid use of id tokens and tags in combination. Based on the dataset including 28,600 labeled entries, a comparison of various approaches was carried out. The RNN achieved a balanced accuracy of 71.36% by training on tokenised ids. A model trained on tags achieved a balanced accuracy of 92%. However, the new hybrid approach, which combines tags and ids, optimizes the result to 94.12%. While a classification on tags achieves a better result than the more general id-based approach, the applicability is limited to software libraries that are tagged. The hybrid approach, on the other hand, takes advantage of the classification results based on tags when these are available, but includes valuable information from the always available ids. © The Author(s) 2024.
引用
收藏
相关论文
共 21 条
[1]  
Salza P., Palomba F., Di Nucci D., de Lucia A., Ferrucci F., Third-party libraries in mobile apps, Empir Softw Eng, 25, 3, pp. 2341-2377, (2020)
[2]  
Thung F., Lo D., Lawall J., Automated library recommendation, 2013 20th Working Conference on reverse engineering (WCRE), pp. 182-191, (2013)
[3]  
Auch M., Weber M., Mandl P., Wolff C., Similarity-based analyses on software applications: a systematic literature review, J Syst Soft, 168, (2020)
[4]  
Yu H., Xia X., Zhao X., Qiu W., Combining collaborative filtering and topic modeling for more accurate android mobile app library recommendation, Proceedings of the 9Th Asia-Pacific Symposium on Internetware., pp. 1-6, (2017)
[5]  
Escobar-Avila J., Automatic categorization of software libraries using bytecode, In: 2015 IEEE/ACM 37Th IEEE International Conference on Software Engineering, 2, pp. 784-786, (2015)
[6]  
Auch M., Balluff M., Mandl P., Wolff C., Similarity of software libraries: A tag-based classification approach, Scitepress-Science and Technology Publications Lda, pp. 17-28, (2021)
[7]  
Velazquez-Rodriguez C., de Roover C., Mutama: An automated multi-label tagging approach for software libraries on maven, In: 2020 IEEE 20Th International Working Conference on Source Code Analysis and Manipulation (SCAM), pp. 254-258, (2020)
[8]  
Sanchez C., Maven—guide to naming conventions 2005.
[9]  
Gosling J., Joy B., Steele G., Bracha G., Buckley A., Smith D., Bierman G., Language Specification 2021.
[10]  
Sutskever I., Vinyals O., Le V.Q., Sequence to sequence learning with neural networks.