用循环神经网络探索漏洞代码的自然性
Exploring the Naturalness of Buggy Code with Recurrent Neural Networks
摘要:
统计语言模型是自然语言处理中的一种强有力的工具。最近,它们已被用于其他顺序数据,如源代码。(Ray例如,2015)示出了可以训练n-gram源代码语言模式,并且使用它来通过经由关于语言模型的熵确定“不自然”行来预测代码中的错误行。在这项工作中,我们建议使用一个更先进的语言建模技术,长短期记忆循环神经网络,建模源代码和分类错误行的基础上熵。我们表明,我们的方法在使用AUC的错误线分类任务中略优于n-gram模型。
英文摘要:
Statistical language models are powerful tools which have been used for many tasks within natural language processing. Recently, they have been used for other sequential data such as source code.(Ray et al., 2015) showed that it is possible train an n-gram source code language mode, and use it to predict buggy lines in code by determining "unnatural" lines via entropy with respect to the language model. In this work, we propose using a more advanced language modeling technique, Long Short-term Memory recurrent neural networks, to model source code and classify buggy lines based on entropy. We show that our method slightly outperforms an n-gram model in the buggy line classification task using AUC.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。