arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2206.13429cs.SE
收藏

开源代码评审与Issue讨论中的不文明行为检测

Incivility Detection in Open Source Code Review and Issue Discussions

Isabella Ferreira, Ahlaam Rafiq, Jinghui Cheng

AI总结:

针对开源代码评审与Issue讨论中的不文明内容检测问题,对比6种经典机器学习模型与BERT的检测效果,评估上下文信息和跨平台场景下的性能,发现BERT最优且F1达0.95,上下文未提升其效果,跨平台场景下所有模型表现均一般。

摘要:

鉴于开源开发的民主特性,代码评审与Issue讨论中可能存在不文明内容。不文明行为被定义为讨论中传递出无礼语气的特征,会给开源社区带来负面影响。为预防或尽可能降低这些负面影响,开源平台已推出从讨论中移除不文明用语的机制,但这类方法需要人工审核,面对海量讨论时工作量不堪重负。为帮助开源社区解决这一问题,本文旨在将6种经典机器学习模型与BERT进行对比,用于检测开源代码评审与Issue讨论中的不文明行为。此外,我们还评估了添加上下文信息是否能提升模型性能,以及模型在跨平台场景下的表现。研究发现,BERT的性能优于经典机器学习模型,最佳F1值达到0.95;经典机器学习模型在检测非技术类且文明的讨论时表现往往不佳。结果表明,给BERT添加上下文信息并未提升其性能,且所有受分析的分类器在跨平台场景下均无突出表现。最后,我们还对分类器误判的语气类型给出了分析见解。

英文摘要:

Given the democratic nature of open source development, code review and issue discussions may be uncivil. Incivility, defined as features of discussion that convey an unnecessarily disrespectful tone, can have negative consequences to open source communities. To prevent or minimize these negative consequences, open source platforms have included mechanisms for removing uncivil language from the discussions. However, such approaches require manual inspection, which can be overwhelming given the large number of discussions. To help open source communities deal with this problem, in this paper, we aim to compare six classical machine learning models with BERT to detect incivility in open source code review and issue discussions. Furthermore, we assess if adding contextual information improves the models' performance and how well the models perform in a cross-platform setting. We found that BERT performs better than classical machine learning models, with a best F1-score of 0.95. Furthermore, classical machine learning models tend to underperform to detect non-technical and civil discussions. Our results show that adding the contextual information to BERT did not improve its performance and that none of the analyzed classifiers had an outstanding performance in a cross-platform setting. Finally, we provide insights into the tones that the classifiers misclassify.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑