探究词汇难度与代码自然度对程序理解的影响
Investigating the Impact of Vocabulary Difficulty and Code Naturalness on Program Comprehension
AI总结:
本研究从语言习得视角出发,采用交叉熵与人工分级词汇表分别衡量代码自然度和词汇难度,通过统计分析探究二者与代码可读性、可理解性的关联及对预测性能的提升作用。
摘要:
研究背景:在软件开发过程中,开发者将大部分时间用于理解源代码。自动评估源代码的可读性与可理解性可为任务分流、代码审查等不同场景带来诸多益处。尽管已有多项研究提出了软件可读性与可理解性的预测方法,但多数仅聚焦于源代码的局部特征,且可理解性预测的性能远未达到预期。\n研究目标:本研究旨在从语言习得的角度评估代码的可读性与可理解性,具体而言,我们将探究代码可读性与可理解性是否与源代码的自然度、词汇难度存在关联。\n研究方法:我们采用交叉熵指标评估代码自然度,同时使用人工构建的代码元素列表及其对应的进阶等级来评估词汇难度。我们将开展统计分析以明确二者的相关性,并分析代码自然度与词汇难度能否用于提升代码可读性、可理解性预测方法的性能。本研究将基于现有数据集开展。
英文摘要:
Context: Developers spend most of their time comprehending source code during software development. Automatically assessing how readable and understandable source code is can provide various benefits in different tasks, such as task triaging and code reviews. While several studies have proposed approaches to predict software readability and understandability, most of them only focus on local characteristics of source code. Besides, the performance of understandability prediction is far from satisfactory. Objective: In this study, we aim to assess readability and understandability from the perspective of language acquisition. More specifically, we would like to investigate whether code readability and understandability are correlated with the naturalness and vocabulary difficulty of source code. Method: To assess code naturalness, we adopted the cross-entropy metric, while we use a manually crafted list of code elements with their assigned advancement levels to assess the vocabulary difficulty. We will conduct a statistical analysis to understand their correlations and analyze whether code naturalness and vocabulary difficulty can be used to improve the performance of code readability and understandability prediction methods. The study will be conducted on existing datasets.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。