mlsanityData to 7 Oct 2026

Finetuning Large Language Models for Vulnerability Detection

arXiv 2401.17010 ↗First posted 30 Jan 2024cs.CR cs.AI cs.LGcited by 39

Not on the map. Why?

Abstract (arXiv)

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.

Key facts. Cited by 39 papers in the map (data through 7 Oct 2026). Builds on 13 of its 31 references that are in the map. First posted on arXiv 30 Jan 2024.

Builds on

13 of 31 references.

References · 13

  1. 2021LoRA: Low-Rank Adaptation of Large Language Modelscited by 14,084
  2. 2020CodeBERT: A Pre-Trained Model for Programming and Natural Languagescited by 1,286
  3. 2023StarCoder: may the source be with you!cited by 790
  4. 2023WizardCoder: Empowering Code Large Language Models with Evol-Instructcited by 728
  5. 2023CodeGeeX: A Pre-Trained Model for Code Generation with Multilingual Benchmarking on HumanEval-Xcited by 294
  6. 2020Deep Learning based Vulnerability Detection: Are We There Yet?cited by 142
  7. 2023CodeGen2: Lessons for Training LLMs on Programming and Natural Languagescited by 124
  8. 2021CVEfixes: Automated Collection of Vulnerabilities and Their Fixes from Open-Source Softwarecited by 89
  9. 2023Data Quality for Software Vulnerability Datasetscited by 49
  10. 2023ChatGPT for Vulnerability Detection, Classification, and Repair: How Far Are We?cited by 44
  11. 2023Evaluation of ChatGPT Model for Vulnerability Detectioncited by 33
  12. 2019A Manually-Curated Dataset of Fixes to Vulnerabilities of Open-Source Softwarecited by 28
1 more
  1. 2023ContraBERT: Enhancing Code Pre-trained Models via Contrastive Learningcited by 16

Built on by

Cited by year (2026 to 7 Oct)

Citing papers per year: 2024: 10; 2025: 21; 2026: 8.

39 papers.

Sort:

By area:

  1. 2024From LLMs to LLM-based Agents for Software Engineering: A Survey of Current, Challenges and Futurecited by 85
  2. 2024When LLMs Meet Cybersecurity: A Systematic Literature Reviewcited by 70
  3. 2024Vul-RAG: Enhancing LLM-based Vulnerability Detection via Knowledge-level RAGcited by 67
  4. 2024CTIBench: A Benchmark for Evaluating LLMs in Cyber Threat Intelligencecited by 61
  5. 2025LLMs in Software Security: A Survey of Vulnerability Detection Techniques and Insightscited by 44
  6. 2024How secure is AI-generated Code: A Large-Scale Comparison of Large Language Modelscited by 23
  7. 2025KNighter: Transforming Static Analysis with LLM-Synthesized Checkerscited by 22
  8. 2025Frontier AI's Impact on the Cybersecurity Landscapecited by 21
  9. 2025Let the Trial Begin: A Mock-Court Approach to Vulnerability Detection using LLM-Based Agentscited by 20
  10. 2024To Err is Machine: Vulnerability Detection Challenges LLM Reasoningcited by 17
  11. 2025Large Language Model (LLM) for Software Security: Code Analysis, Malware Analysis, Reverse Engineeringcited by 15
  12. 2024SECURE: Benchmarking Large Language Models for Cybersecuritycited by 13
27 more
  1. 2025VulnLLM-R: Specialized Reasoning LLM with Agent Scaffold for Vulnerability Detectioncited by 11
  2. 2024From Vulnerabilities to Remediation: A Systematic Literature Review of LLMs in Code Securitycited by 9
  3. 2025R2Vul: Learning to Reason about Software Vulnerabilities with Reinforcement Learning and Structured Reasoning Distillationcited by 7
  4. 2025One Bug, Hundreds Behind: LLMs for Large-Scale Bug Discoverycited by 6
  5. 2025Trace Gadgets: Minimizing Code Context for Machine Learning-Based Vulnerability Predictioncited by 5
  6. 2026SkillMutator: Benchmarking and Defending Language-and-Code Cross-modal Attacks on LLM Agent Skillscited by 5
  7. 2025LPASS: Linear Probes as Stepping Stones for vulnerability detection using compressed LLMscited by 4
  8. 2025Less Data, More Security: Advancing Cybersecurity LLMs Specialization via Resource-Efficient Domain-Adaptive Continuous Pre-training with Minimal Tokenscited by 4
  9. 2025AthenaBench: A Dynamic Benchmark for Evaluating LLMs in Cyber Threat Intelligencecited by 4
  10. 2026From SFT to RL: Demystifying the Post-Training Pipeline for LLM-based Vulnerability Detectioncited by 4
  11. 2024Can LLM Prompting Serve as a Proxy for Static Analysis in Vulnerability Detectioncited by 3
  12. 2025Revisiting Pre-trained Language Models for Vulnerability Detectioncited by 3
  13. 2025Do Code Semantics Help? A Comprehensive Study on Execution Trace-Based Information for Code Large Language Modelscited by 3
  14. 2025Data and Context Matter: Towards Generalizing AI-based Software Vulnerability Detectioncited by 2
  15. 2024Comparing Unidirectional, Bidirectional, and Word2vec Models for Discovering Vulnerabilities in Compiled Lifted Codecited by 1
  16. 2025Goal2Story: A Multi-Agent Fleet based on Privately Enabled sLLMs for Impacting Mapping on Requirements Elicitationcited by 1
  17. 2025A Blueprint for AI-Driven Software Quality: Integrating LLMs with Established Standardscited by 1
  18. 2025HiLDe: Intentional Code Generation via Human-in-the-Loop Decodingcited by 1
  19. 2025Interpretable Anomaly-Based DDoS Detection in AI-RAN with XAI and LLMscited by 1
  20. 2026Enhancing Linux Privilege Escalation Attack Capabilities of Local LLM Agentscited by 1
  21. 2025Enhancing Large Language Models with Faster Code Preprocessing for Vulnerability Detectioncited by 0
  22. 2025Utilizing Large Language Models for Machine Learning Explainabilitycited by 0
  23. 2026An Empirical Evaluation of LLM-Based Approaches for Code Vulnerability Detection: RAG, SFT, and Dual-Agent Systemscited by 0
  24. 2026Cyber Threat Detection and Vulnerability Assessment System using Generative AI and Large Language Modelcited by 0
  25. 2026Words Speak Louder Than Code: Investigating Cognitive Heuristics in LLM-Based Code Vulnerability Detectioncited by 0
  26. 2026Cross-Corpus Evaluation of Generalizable Vulnerability Detection in IoT Firmwarecited by 0
  27. 2026ARQ: Agentic CodeQL Query Refinement for C/C++ Vulnerability Detectioncited by 0