arXivDaily arXiv每日学术速递 周一至周五更新
感恩节,周五至周末无更新,大家顺遂。周一再来吧
arXiv 2304.05193cs.SE
收藏

评估面向代码内容的AIGC检测器

Evaluating AIGC Detectors on Code Content

Jian Wang, Shangqing Liu, Xiaofei Xie, Yi Li

AI总结:

本文首次实证评估现有AIGC检测器在ChatGPT生成的代码内容上的表现,构建492.5K样本数据集并开展人类研究,发现其在代码数据上性能低于自然语言数据,微调可提升同域性能但泛化仍具挑战。

摘要:

人工智能生成内容(AIGC)因其出色的表现而受到广泛关注,其中ChatGPT作为领先的AIGC模型,在包括软件开发和维护在内的各种应用中都能生成高质量的响应。尽管具有潜力,但ChatGPT的滥用引发了重大担忧,尤其是在教育和安全关键领域。目前已开发出大量AIGC检测器并在自然语言数据上进行了评估,然而它们在ChatGPT生成的代码相关内容上的表现尚未得到探索。为填补这一空白,本文首次对软件领域中现有AIGC检测器进行了实证研究。我们创建了一个包含492.5K样本的综合数据集,这些样本由ChatGPT生成的代码相关内容组成,涵盖常见的软件活动,如问答(115K)、代码摘要(126K)和代码生成(226.5K)。我们评估了六个AIGC检测器,包括三个商业解决方案和三个开源解决方案,并评估它们在该数据集上的表现。此外,我们开展了一项人类研究,以了解人类的检测能力,并将其与现有AIGC检测器进行比较。我们的结果表明,与自然语言数据相比,AIGC检测器在代码相关数据上的表现较差。微调可以提升检测器性能,尤其是对于同一领域内的内容;但泛化仍然是一个挑战。人类评估表明,由人类进行检测相当困难。

英文摘要:

Artificial Intelligence Generated Content (AIGC) has garnered considerable attention for its impressive performance, with ChatGPT emerging as a leading AIGC model that produces high-quality responses across various applications, including software development and maintenance. Despite its potential, the misuse of ChatGPT poses significant concerns, especially in education and safetycritical domains. Numerous AIGC detectors have been developed and evaluated on natural language data. However, their performance on code-related content generated by ChatGPT remains unexplored. To fill this gap, in this paper, we present the first empirical study on evaluating existing AIGC detectors in the software domain. We created a comprehensive dataset including 492.5K samples comprising code-related content produced by ChatGPT, encompassing popular software activities like Q&A (115K), code summarization (126K), and code generation (226.5K). We evaluated six AIGC detectors, including three commercial and three open-source solutions, assessing their performance on this dataset. Additionally, we conducted a human study to understand human detection capabilities and compare them with the existing AIGC detectors. Our results indicate that AIGC detectors demonstrate lower performance on code-related data compared to natural language data. Fine-tuning can enhance detector performance, especially for content within the same domain; but generalization remains a challenge. The human evaluation reveals that detection by humans is quite challenging.

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

↑