Lune

FSE2025顶会

One-for-All Does Not Work! Enhancing Vulnerability Detection by Mixture-of-Experts (MoE)

Xu Yang, Shaowei Wang, Jiayuan Zhou, Wenhan Zhu

摘要

Deep Learning-based Vulnerability Detection (DLVD) techniques have garnered significant interest due to their ability to automatically learn vulnerability patterns from previously compromised code. Despite the notable accuracy demonstrated by pioneering tools, the broader application of DLVD methods in real-world scenarios is hindered by significant challenges. A primary issue is the “one-for-all” design, where a single model is trained to handle all types of vulnerabilities. This approach fails to capture the patterns of different vulnerability types, resulting in suboptimal performance, particularly for less common vulnerabilities that are often underrepresented in training datasets. To address these challenges, we propose MoEVD, which adopts the Mixture-of-Experts (MoE) framework for vulnerability detection. MoEVD decomposes vulnerability detection into two tasks, CWE type classification and CWE-specific vulnerability detection. By splitting the task, in vulnerability detection, MoEVD allows specific experts to handle distinct types of vulnerabilities instead of handling all vulnerabilities within one model. Our results show that MoEVD achieves an F1-score of 0.44, significantly outperforming all studied state-of-the-art (SOTA) baselines by at least 12.8%. MoEVD excels across almost all CWE types, improving recall over the best SOTA baseline by 9% to 77.8%. Notably, MoEVD does not sacrifice performance on long-tailed CWE types; instead, its MoE design enhances performance (F1-score) on these by at least 7.3%, addressing long-tailed issues effectively.

问 Lune

几分钟读透这篇 Paper,不用再花一下午。

Lune 能读完全文,也能读引用它的顶会 Paper,讲清它的结论、证据和局限,每一点都注明出自哪篇 Paper。不用硬啃,也不靠猜。

已有 2 篇顶会 Paper 引用了它。别等审稿人问起,先弄清它们发现了什么。

可以从这些问题问起

Lune 可以查阅

全文 · 引用它的顶会 Paper · 相关的 Paper

获取答案

免费开始,无需绑卡

脉络

  • Towards Secure Logging: Characterizing and Benchmarking Logging Code Security Issues with LLMs 引用了 Vulnerability detection with fine-grained interpretations
  • Three Heads Are Better Than One: A Multi-perspective Reasoning Framework for Enhanced Vulnerability Detection 引用了 CodeBERT: A Pre-Trained Model for Programming and Natural Languages
  • Three Heads Are Better Than One: A Multi-perspective Reasoning Framework for Enhanced Vulnerability Detection 引用了 Towards Causal Deep Learning for Vulnerability Detection
  • Towards Causal Deep Learning for Vulnerability Detection 引用了 CodeBERT: A Pre-Trained Model for Programming and Natural Languages
  • Towards Causal Deep Learning for Vulnerability Detection 引用了 GraphCodeBERT: Pre-training Code Representations with Data Flow
它引用的引用它的从左到右按年份排列,引用越多,位置越高。

引用它的顶会 Paper2

  1. Three Heads Are Better Than One: A Multi-perspective Reasoning Framework for Enhanced Vulnerability DetectionXin Peng, Bo Lin, Jing Wang, Xiaoling Li 等FSE 2026 · 1 次引用
  2. Towards Secure Logging: Characterizing and Benchmarking Logging Code Security Issues with LLMsHe Yang Yuan, Xin Wang, Kundi Yao, An Ran Chen 等FSE 2026

它引用的 Paper10

  1. CodeBERT: A Pre-Trained Model for Programming and Natural LanguagesZhangyin Feng, Daya Guo, Duyu Tang, Nan Duan 等EMNLP Findings 2020 · 2,828 次引用
  2. GShard: Scaling Giant Models with Conditional Computation and Automatic ShardingDmitry Lepikhin, HyoukJoong Lee, Yuanzhong Xu, Dehao Chen 等ICLR 2021 · 1,954 次引用
  3. GraphCodeBERT: Pre-training Code Representations with Data FlowDaya Guo, Shuo Ren, Shuai Lu, Zhangyin Feng 等ICLR 2021 · 1,644 次引用
  4. Vulnerability detection with fine-grained interpretationsYi Li, Shaohua Wang, Tien N. NguyenFSE 2021 · 283 次引用
  5. Towards Causal Deep Learning for Vulnerability DetectionMd Mahbubur Rahman, Ira Ceka, Chengzhi Mao, Saikat Chakraborty 等ICSE 2024 · 22 次引用

相关 Paper

  1. Rethinking Mixture-of-Experts for Vulnerability Detection: An Empirical Study and Improved DesignRongze Jiang, Chaofeng Sha, Xin PengISSTA 2026
  2. Leveraging Mixture-of-Experts Framework for Smart Contract Vulnerability Repair with Large Language ModelHang Yuan, Xizhi Hou, Lei Yu, Li Yang 等ASE 2025 · 1 次引用
  3. Applying Contrastive Learning to Code Vulnerability Type ClassificationChen Ji, Su Yang, Hongyu Sun, Yuqing ZhangEMNLP 2024 · 6 次引用
  4. Toward Improved Deep Learning-based Vulnerability DetectionAdriana Sejfia, Satyaki Das, Saad Shafiq, Nenad MedvidovicICSE 2024 · 14 次引用
  5. DeepVD: Toward Class-Separation Features for Neural Network Vulnerability DetectionWenbo Wang, Tien N. Nguyen, Shaohua Wang, Yi Li 等ICSE 2023 · 32 次引用
黄昏的海面,两侧是细线勾勒的悬崖