Evaluating Code Comment Generation With Summarized API Docs

被引:0
|
作者
Matmti, Bilel [1 ]
Fard, Fatemeh [1 ]
机构
[1] Univ British Columbia, Dept Comp Sci, Okanagan, BC, Canada
基金
加拿大自然科学与工程研究理事会;
关键词
API Docs; text summarization; comment generation; external knowledge source;
D O I
10.1109/NLBSE59153.2023.00019
中图分类号
TP18 [人工智能理论];
学科分类号
081104 ; 0812 ; 0835 ; 1405 ;
摘要
Code comment generation is the task of generating a high-level natural language description for a given code snippet. API2Com is a comment generation model designed to leverage the Application Programming Interface Documentations (API Docs) as an external knowledge resource. Shahbazi et al. [1] showed that API Docs might help increase the model's performance. However, the model's performance in generating pertinent comments deteriorates due to the lengthy documentation used in the input as the number of APIs used in a method increases. In this paper, we propose to evaluate how summarizing the API Docs using an extractive text summarization technique, TextRank, will impact the overall performance of the API2Com. The results of our experiments using the same Java dataset confirm the inverse correlation between the number of APIs and the model's performance. As the number of APIs increases, the performance metrics tend to deteriorate for both configurations of the model, with or without API Docs summarization using TextRank. Experiments also show the impact of the number of APIs on TextRank algorithm capacity to improve the model performance. For example, with 8 APIs, TextRank summarization improved the model BLEU score by 18% on average, but the performance tends to decrease as the number of APIs increases. This demonstrates an open area of research to determine the winning combination in terms of the model configuration and the length of documentation used.
引用
收藏
页码:60 / 63
页数:4
相关论文
共 50 条
  • [31] Evaluating and optimising compiler code generation for NVIDIA Grace
    Jesus, Ricardo
    Weiland, Michele
    53RD INTERNATIONAL CONFERENCE ON PARALLEL PROCESSING, ICPP 2024, 2024, : 691 - 700
  • [32] An api for runtime code patching
    Buck, B
    Hollingsworth, JK
    INTERNATIONAL JOURNAL OF HIGH PERFORMANCE COMPUTING APPLICATIONS, 2000, 14 (04): : 317 - 329
  • [33] For you summarized: The BEAUTIfUL-Study. Expert comment
    Eber, B.
    JOURNAL FUR HYPERTONIE, 2009, 13 (01): : 31 - 32
  • [34] To Reuse or Not To Reuse? A Framework and System for Evaluating Summarized Knowledge
    Liu M.X.
    Kittur A.
    Myers B.A.
    Proceedings of the ACM on Human-Computer Interaction, 2021, 5 (CSCW1)
  • [35] Evaluating Impact of Conventional Code Analysis Against Large Language Models in API Vulnerability Detection
    Yildirim, Recep
    Aydin, Kerem
    Cetin, Orcun
    PROCEEDINGS OF THE 2024 EUROPEAN INTERDISCIPLINARY CYBERSECURITY CONFERENCE, EICC 2024, 2024, : 57 - 64
  • [36] Summarized criterion for evaluating wear resistance and strength of steels
    Sorokin, G. M.
    Malyshev, V. N.
    Kurakin, I. B.
    JOURNAL OF FRICTION AND WEAR, 2013, 34 (06) : 454 - 459
  • [37] A Simple Retrieval-based Method for Code Comment Generation
    Zhu, Xiaoning
    Sha, Chaofeng
    Niu, Junyu
    Proceedings - 2022 IEEE International Conference on Software Analysis, Evolution and Reengineering, SANER 2022, 2022, : 1089 - 1100
  • [38] A Simple Retrieval-based Method for Code Comment Generation
    Zhu, Xiaoning
    Sha, Chaofeng
    Niu, Junyu
    2022 IEEE INTERNATIONAL CONFERENCE ON SOFTWARE ANALYSIS, EVOLUTION AND REENGINEERING (SANER 2022), 2022, : 1089 - 1100
  • [39] Deep code comment generation with hybrid lexical and syntactical information
    Hu, Xing
    Li, Ge
    Xia, Xin
    Lo, David
    Jin, Zhi
    EMPIRICAL SOFTWARE ENGINEERING, 2020, 25 (03) : 2179 - 2217
  • [40] Survey of State-of-the-art Automatic Code Comment Generation
    Chen X.
    Yang G.
    Cui Z.-Q.
    Meng G.-Z.
    Wang Z.
    Ruan Jian Xue Bao/Journal of Software, 2021, 32 (07): : 2118 - 2141