Large language models (LLMs) have shown strong potential for automated software vulnerability detection, particularly in retrieval-augmented generation (RAG) settings. However, for approaches relying on proprietary models and APIs, reproducibility and replicability remain largely unexplored, raising the question of whether reported results generalize or depend primarily on specific model choices. In this work, we present a reproducibility study of Vul-RAG, a RAG-based framework for source code vulnerability detection that enhances LLMs with high-level vulnerability knowledge. We first replicate the results in a fully local and open-weights setting using the reported open-weight baseline models. We then extend the evaluation to a diverse set of recent open-weight LLMs, including code-specialized, general-purpose, and reasoning models of varying parameter sizes. The results confirm that the findings of Vul-RAG are reproducible under local deployment, but with minor deviations. Across all evaluated models, we observe a performance plateau at approximately 0.30 pairwise accuracy (code pairs for which both the vulnerable and the patched function are correctly classified). Notably, this plateau persists even for more recent and advanced models, indicating that improvements in model capacity alone do not substantially enhance performance. Finally, we discuss practical implications and trade-offs between detection effectiveness, model capabilities, and model scale. Implementation and evaluation artifacts are publicly available at https://github.com/hs-esslingen-it-security/revisiting-Vul-RAG.


翻译:大型语言模型(LLMs)在自动化软件漏洞检测方面展现出巨大潜力,尤其体现在检索增强生成(RAG)场景中。然而,对于依赖专有模型和API的方法,其可重现性与可复现性仍未得到充分探索,这引发了一个问题:已报道的研究结果是否具有普适性,抑或主要依赖于特定的模型选择。本文对Vul-RAG(一种基于RAG的源代码漏洞检测框架,通过注入高层级漏洞知识增强LLMs)进行了可重现性研究。我们首先使用已报道的开放权重基线模型,在完全本地化与开放权重环境下复现了原始结果。随后我们将评估扩展至一系列多样化的近期开放权重LLMs,涵盖代码专用、通用及推理模型,参数规模各异。结果证实,Vul-RAG的研究发现在本地部署下具有可重现性,但存在微小偏差。在所有被评估模型中,我们观察到性能在约0.30的成对准确率(即可正确分类漏洞函数与修复函数对的代码对比例)处达到平台期。值得注意的是,即使对于更新、更先进的模型,这一平台期依然存在,表明单纯提升模型能力并不能显著提高性能。最后,我们探讨了检测效能、模型能力与模型规模之间的实际意义与权衡。实现代码与评估构件已公开于https://github.com/hs-esslingen-it-security/revisiting-Vul-RAG。

0
下载
关闭预览

相关内容

重现性是指在不同条件下使用同一方法对同一样品进行分析所得单个结果之间的一致程度。不同条件指不同操作者、不同实验室、不同或相同的时间。
检索增强生成(RAG)与推理的协同作用:一项系统综述
专知会员服务
16+阅读 · 2025年4月27日
定制化大型语言模型的图检索增强生成综述
专知会员服务
38+阅读 · 2025年1月28日
智能体检索增强生成:关于智能体RAG的综述
专知会员服务
94+阅读 · 2025年1月21日
微软最新《检索增强生成(RAG)》综述
专知会员服务
57+阅读 · 2024年9月24日
检索增强生成系统中的可信度:综述
专知会员服务
44+阅读 · 2024年9月18日
RAG与RAU:自然语言处理中的检索增强语言模型综述
专知会员服务
89+阅读 · 2024年5月3日
推荐召回算法之深度召回模型串讲
AINLP
22+阅读 · 2019年6月14日
NLG ≠ 机器写作 | 专家专栏
量子位
13+阅读 · 2018年9月10日
【学界】机器学习模型的“可解释性”到底有多重要?
GAN生成式对抗网络
12+阅读 · 2018年3月3日
国家自然科学基金
4+阅读 · 2017年12月31日
国家自然科学基金
6+阅读 · 2017年12月31日
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
4+阅读 · 2015年12月31日
国家自然科学基金
3+阅读 · 2015年12月31日
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
VIP会员
最新内容
学习数据的几何:形状空间分析数学综述
专知会员服务
7+阅读 · 6月17日
定向能反无人机系统最新发展动态
专知会员服务
7+阅读 · 6月17日
从燃煤战舰到算法战争:水面指挥的永恒要求
专知会员服务
6+阅读 · 6月17日
相关基金
国家自然科学基金
4+阅读 · 2017年12月31日
国家自然科学基金
6+阅读 · 2017年12月31日
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
4+阅读 · 2015年12月31日
国家自然科学基金
3+阅读 · 2015年12月31日
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
Top
微信扫码咨询专知VIP会员