计算 Javadoc 注释的相似性

IF 0.7 4区 计算机科学 Q4 COMPUTER SCIENCE, SOFTWARE ENGINEERING Programming and Computer Software Pub Date : 2024-05-22 DOI:10.1134/s0361768824010043
D. V. Koznov, E. Yu. Ledeneva, D. V. Luciv, P. I. Braslavski
{"title":"计算 Javadoc 注释的相似性","authors":"D. V. Koznov, E. Yu. Ledeneva, D. V. Luciv, P. I. Braslavski","doi":"10.1134/s0361768824010043","DOIUrl":null,"url":null,"abstract":"<h3 data-test=\"abstract-sub-heading\">Abstract</h3><p>Code comments are an essential part of software documentation. Many software projects suffer from the problem of low-quality comments that are often produced by copy-paste. In case of similar methods, classes, etc. copy-pasted comments with minor modifications are justified. However, in many cases this approach leads to degraded documentation quality and, subsequently, to problematic maintenance and development of the project. In this study, we address the problem of near-duplicate code comments detection, which can potentially improve software documentation. We have conducted a thorough evaluation of traditional string similarity metrics and modern machine learning methods. In our experiment, we use a collection of Javadoc comments from four industrial open-source Java projects. We have found out that LCS (Longest Common Subsequence) is the best similarity algorithm taking into account both quality (Precision 94%, Recall 74%) and performance.</p>","PeriodicalId":54555,"journal":{"name":"Programming and Computer Software","volume":null,"pages":null},"PeriodicalIF":0.7000,"publicationDate":"2024-05-22","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"0","resultStr":"{\"title\":\"Calculating Similarity of Javadoc Comments\",\"authors\":\"D. V. Koznov, E. Yu. Ledeneva, D. V. Luciv, P. I. Braslavski\",\"doi\":\"10.1134/s0361768824010043\",\"DOIUrl\":null,\"url\":null,\"abstract\":\"<h3 data-test=\\\"abstract-sub-heading\\\">Abstract</h3><p>Code comments are an essential part of software documentation. Many software projects suffer from the problem of low-quality comments that are often produced by copy-paste. In case of similar methods, classes, etc. copy-pasted comments with minor modifications are justified. However, in many cases this approach leads to degraded documentation quality and, subsequently, to problematic maintenance and development of the project. In this study, we address the problem of near-duplicate code comments detection, which can potentially improve software documentation. We have conducted a thorough evaluation of traditional string similarity metrics and modern machine learning methods. In our experiment, we use a collection of Javadoc comments from four industrial open-source Java projects. We have found out that LCS (Longest Common Subsequence) is the best similarity algorithm taking into account both quality (Precision 94%, Recall 74%) and performance.</p>\",\"PeriodicalId\":54555,\"journal\":{\"name\":\"Programming and Computer Software\",\"volume\":null,\"pages\":null},\"PeriodicalIF\":0.7000,\"publicationDate\":\"2024-05-22\",\"publicationTypes\":\"Journal Article\",\"fieldsOfStudy\":null,\"isOpenAccess\":false,\"openAccessPdf\":\"\",\"citationCount\":\"0\",\"resultStr\":null,\"platform\":\"Semanticscholar\",\"paperid\":null,\"PeriodicalName\":\"Programming and Computer Software\",\"FirstCategoryId\":\"94\",\"ListUrlMain\":\"https://doi.org/10.1134/s0361768824010043\",\"RegionNum\":4,\"RegionCategory\":\"计算机科学\",\"ArticlePicture\":[],\"TitleCN\":null,\"AbstractTextCN\":null,\"PMCID\":null,\"EPubDate\":\"\",\"PubModel\":\"\",\"JCR\":\"Q4\",\"JCRName\":\"COMPUTER SCIENCE, SOFTWARE ENGINEERING\",\"Score\":null,\"Total\":0}","platform":"Semanticscholar","paperid":null,"PeriodicalName":"Programming and Computer Software","FirstCategoryId":"94","ListUrlMain":"https://doi.org/10.1134/s0361768824010043","RegionNum":4,"RegionCategory":"计算机科学","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"Q4","JCRName":"COMPUTER SCIENCE, SOFTWARE ENGINEERING","Score":null,"Total":0}
引用次数: 0

摘要

摘要代码注释是软件文档的重要组成部分。许多软件项目都存在注释质量不高的问题,这些注释往往是通过复制粘贴产生的。在方法、类等相似的情况下,复制粘贴注释并稍加修改是合理的。然而,在很多情况下,这种方法会导致文档质量下降,进而给项目的维护和开发带来问题。在本研究中,我们探讨了近乎重复的代码注释检测问题,这有可能改善软件文档。我们对传统的字符串相似度指标和现代机器学习方法进行了全面评估。在实验中,我们使用了来自四个工业开源 Java 项目的 Javadoc 注释集合。我们发现,从质量(精确度 94%,召回率 74%)和性能两方面考虑,LCS(最长公共后缀)是最佳的相似性算法。
本文章由计算机程序翻译,如有差异,请以英文原文为准。
查看原文
分享 分享
微信好友 朋友圈 QQ好友 复制链接
本刊更多论文
Calculating Similarity of Javadoc Comments

Abstract

Code comments are an essential part of software documentation. Many software projects suffer from the problem of low-quality comments that are often produced by copy-paste. In case of similar methods, classes, etc. copy-pasted comments with minor modifications are justified. However, in many cases this approach leads to degraded documentation quality and, subsequently, to problematic maintenance and development of the project. In this study, we address the problem of near-duplicate code comments detection, which can potentially improve software documentation. We have conducted a thorough evaluation of traditional string similarity metrics and modern machine learning methods. In our experiment, we use a collection of Javadoc comments from four industrial open-source Java projects. We have found out that LCS (Longest Common Subsequence) is the best similarity algorithm taking into account both quality (Precision 94%, Recall 74%) and performance.

求助全文
通过发布文献求助,成功后即可免费获取论文全文。 去求助
来源期刊
Programming and Computer Software
Programming and Computer Software 工程技术-计算机:软件工程
CiteScore
1.60
自引率
28.60%
发文量
35
审稿时长
>12 weeks
期刊介绍: Programming and Computer Software is a peer reviewed journal devoted to problems in all areas of computer science: operating systems, compiler technology, software engineering, artificial intelligence, etc.
期刊最新文献
Comparative Efficiency Analysis of Hashing Algorithms for Use in zk-SNARK Circuits in Distributed Ledgers Constructing the Internal Voronoi Diagram of Polygonal Figure Using the Sweepline Method RuGECToR: Rule-Based Neural Network Model for Russian Language Grammatical Error Correction Secure Messaging Application Development: Based on Post-Quantum Algorithms CSIDH, Falcon, and AES Symmetric Key Cryptosystem Analytical Review of Confidential Artificial Intelligence: Methods and Algorithms for Deployment in Cloud Computing
×
引用
GB/T 7714-2015
复制
MLA
复制
APA
复制
导出至
BibTeX EndNote RefMan NoteFirst NoteExpress
×
×
提示
您的信息不完整,为了账户安全,请先补充。
现在去补充
×
提示
您因"违规操作"
具体请查看互助需知
我知道了
×
提示
现在去查看 取消
×
提示
确定
0
微信
客服QQ
Book学术公众号 扫码关注我们
反馈
×
意见反馈
请填写您的意见或建议
请填写您的手机或邮箱
已复制链接
已复制链接
快去分享给好友吧!
我知道了
×
扫码分享
扫码分享
Book学术官方微信
Book学术文献互助
Book学术文献互助群
群 号:481959085
Book学术
文献互助 智能选刊 最新文献 互助须知 联系我们:info@booksci.cn
Book学术提供免费学术资源搜索服务,方便国内外学者检索中英文文献。致力于提供最便捷和优质的服务体验。
Copyright © 2023 Book学术 All rights reserved.
ghs 京公网安备 11010802042870号 京ICP备2023020795号-1