Finetuning Large Language Models for Vulnerability Detection

要約

このペーパーでは、ソース コードの脆弱性を検出するタスクのために大規模言語モデル (LLM) を微調整した結果を示します。
当社では、最先端の LLM StarCoder を最近改良した WizardCoder を活用し、さらなる微調整を通じて脆弱性検出に適応させています。
トレーニングを加速するために、WizardCoder のトレーニング手順を変更し、最適なトレーニング体制を調査します。
正の例よりも負の例の方が多い不均衡なデータセットについては、分類パフォーマンスを向上させるためのさまざまな手法も検討します。
微調整された WizardCoder モデルは、CodeBERT のようなモデルと比較して、バランスの取れた脆弱性データセットと不均衡な脆弱性データセットに対する ROC AUC および F1 測定の改善を達成し、ソース コードの脆弱性検出に事前トレーニング済み LLM を適応させることの有効性を示しています。
主な貢献は、最先端のコード LLM、WizardCoder の微調整、パフォーマンスを損なうことなくトレーニング速度の向上、トレーニング手順とレジームの最適化、クラスの不均衡の処理、および困難な脆弱性検出データセットのパフォーマンスの向上です。
これは、特殊なソース コード分析タスク向けに大規模な事前トレーニング済み言語モデルを微調整することによる転移学習の可能性を示しています。

要約(オリジナル)

This paper presents the results of finetuning large language models (LLMs) for the task of detecting vulnerabilities in source code. We leverage WizardCoder, a recent improvement of the state-of-the-art LLM StarCoder, and adapt it for vulnerability detection through further finetuning. To accelerate training, we modify WizardCoder’s training procedure, also we investigate optimal training regimes. For the imbalanced dataset with many more negative examples than positive, we also explore different techniques to improve classification performance. The finetuned WizardCoder model achieves improvement in ROC AUC and F1 measures on balanced and imbalanced vulnerability datasets over CodeBERT-like model, demonstrating the effectiveness of adapting pretrained LLMs for vulnerability detection in source code. The key contributions are finetuning the state-of-the-art code LLM, WizardCoder, increasing its training speed without the performance harm, optimizing the training procedure and regimes, handling class imbalance, and improving performance on difficult vulnerability detection datasets. This demonstrates the potential for transfer learning by finetuning large pretrained language models for specialized source code analysis tasks.

arxiv情報

著者 Alexey Shestov,Anton Cheshkov,Rodion Levichev,Ravil Mussabayev,Pavel Zadorozhny,Evgeny Maslov,Chibirev Vadim,Egor Bulychev
発行日 2024-01-30 13:46:49+00:00
arxivサイト arxiv_id(pdf)

提供元, 利用サービス

arxiv.jp, Google

カテゴリー: cs.AI, cs.CR, cs.LG パーマリンク