{"status":"ok","message-type":"work","message-version":"1.0.0","message":{"indexed":{"date-parts":[[2026,11,4]],"date-time":"2026-11-04T22:48:13Z","timestamp":1793832493913,"version":"4.6.1"},"reference-count":70,"publisher":"Association for Computing Machinery (ACM)","issue":"5","content-domain":{"domain":["dl.acm.org"],"crossmark-restriction":true},"short-container-title":["ACM Trans. Softw. Eng. Methodol."],"published-print":{"date-parts":[[2026,5,31]]},"abstract":"<jats:p>\n                    Detecting vulnerabilities is vital for software security, yet deep learning-based vulnerability detectors (DLVD) face a data shortage, which limits their effectiveness. Data augmentation can potentially alleviate the data shortage, but augmenting vulnerable code is challenging and requires a generative solution that maintains vulnerability. Previous works have only focused on generating samples that contain single statements or specific types of vulnerabilities. Recently, large language models (LLMs) have been used to solve various code generation and comprehension tasks with inspiring results, especially when fused with retrieval augmented generation (RAG). Therefore, we propose\n                    <jats:italic toggle=\"yes\">VulScribeR<\/jats:italic>\n                    , a novel LLM-based solution that leverages carefully curated prompt templates to augment vulnerable datasets. More specifically, we explore three strategies to augment both single and multi-statement vulnerabilities, with LLMs, namely Mutation, Injection, and Extension. Our extensive evaluation across four vulnerability datasets and DLVD models, using three LLMs, show that our approach beats two SOTA methods VulGen and VGX, and Random Oversampling (ROS) by 27.48%, 27.93%, and 15.41% in F1-score with 5K generated vulnerable samples on average, and 53.84%, 54.10%, 69.90%, and 40.93% with 15K generated vulnerable samples. Our approach demonstrates its feasibility for large-scale data augmentation by generating 1K samples at as cheap as US$1.88.\n                  <\/jats:p>","DOI":"10.1145\/3760775","type":"journal-article","created":{"date-parts":[[2025,8,18]],"date-time":"2025-08-18T16:00:45Z","timestamp":1755532845000},"page":"1-26","update-policy":"https:\/\/doi.org\/10.1145\/crossmark-policy","source":"Crossref","is-referenced-by-count":18,"title":["VulScribeR: Exploring RAG-based Vulnerability Augmentation with LLMs"],"prefix":"10.1145","volume":"35","author":[{"ORCID":"https:\/\/orcid.org\/0000-0002-3463-7873","authenticated-orcid":false,"given":"Seyed Shayan","family":"Daneshvar","sequence":"first","affiliation":[{"name":"Department of Computer Science, University of Manitoba, Winnipeg, Manitoba, Canada"}],"role":[{"vocabulary":"crossref","role":"author"}]},{"ORCID":"https:\/\/orcid.org\/0000-0002-8598-5181","authenticated-orcid":false,"given":"Yu","family":"Nong","sequence":"additional","affiliation":[{"name":"Washington State University, Pullman, Washington, USA"}],"role":[{"vocabulary":"crossref","role":"author"}]},{"ORCID":"https:\/\/orcid.org\/0000-0001-9963-6225","authenticated-orcid":false,"given":"Xu","family":"Yang","sequence":"additional","affiliation":[{"name":"Department of Computer Science, University of Manitoba, Winnipeg, Manitoba, Canada"}],"role":[{"vocabulary":"crossref","role":"author"}]},{"ORCID":"https:\/\/orcid.org\/0000-0003-3823-1771","authenticated-orcid":false,"given":"Shaowei","family":"Wang","sequence":"additional","affiliation":[{"name":"Department of Computer Science, University of Manitoba, Winnipeg, Manitoba, Canada"}],"role":[{"vocabulary":"crossref","role":"author"}]},{"ORCID":"https:\/\/orcid.org\/0000-0002-5224-9970","authenticated-orcid":false,"given":"Haipeng","family":"Cai","sequence":"additional","affiliation":[{"name":"University at Buffalo, Buffalo, New York, USA"}],"role":[{"vocabulary":"crossref","role":"author"}]}],"member":"320","published-online":{"date-parts":[[2026,4,24]]},"reference":[{"key":"e_1_3_2_2_2","unstructured":"Syed Shayan Daneshvar. 2024. Official repository for VulScribeR. Retrieved from https:\/\/github.com\/shayandaneshvar\/VulScribeR"},{"key":"e_1_3_2_3_2","unstructured":"Sara Abdali Richard Anarfi C. J. Barberan Jia He and Erfan Shayegani. 2025. Securing large language models: Threats vulnerabilities and responsible practices. arXiv:2403.12503. Retrieved from https:\/\/arxiv.org\/abs\/2403.12503"},{"key":"e_1_3_2_4_2","unstructured":"Josh Achiam Steven Adler Sandhini Agarwal Lama Ahmad Ilge Akkaya Florencia Leoni Aleman Diogo Almeida Janko Altenschmidt Sam Altman Shyamal Anadkat et al. 2023. Gpt-4 technical report. arXiv:2303.08774. Retrieved from https:\/\/arxiv.org\/abs\/2303.08774"},{"key":"e_1_3_2_5_2","unstructured":"Jinze Bai Shuai Bai Yunfei Chu Zeyu Cui Kai Dang Xiaodong Deng Yang Fan Wenbin Ge Yu Han Fei Huang et al. 2023. Qwen technical report. arXiv:2309.16609. Retrieved from https:\/\/arxiv.org\/abs\/2309.16609"},{"key":"e_1_3_2_6_2","doi-asserted-by":"publisher","DOI":"10.1162\/neco.1995.7.1.108"},{"key":"e_1_3_2_7_2","doi-asserted-by":"publisher","DOI":"10.1145\/3404835.3462840"},{"key":"e_1_3_2_8_2","doi-asserted-by":"publisher","DOI":"10.1145\/3540250.3549162"},{"key":"e_1_3_2_9_2","doi-asserted-by":"publisher","DOI":"10.1109\/TSE.2021.3087402"},{"key":"e_1_3_2_10_2","doi-asserted-by":"publisher","DOI":"10.1613\/jair.953"},{"key":"e_1_3_2_11_2","doi-asserted-by":"publisher","DOI":"10.1145\/3597503.3639085"},{"key":"e_1_3_2_12_2","doi-asserted-by":"publisher","DOI":"10.1109\/ICSE48619.2023.00022"},{"key":"e_1_3_2_13_2","doi-asserted-by":"crossref","unstructured":"Seyed Shayan Daneshvar Da Tan Shaowei Wang and Carson Leung. 2025. A study on mixup-inspired augmentation methods for software vulnerability detection. arXiv:2504.15632. Retrieved from https:\/\/arxiv.org\/abs\/2504.15632","DOI":"10.1145\/3756681.3757017"},{"key":"e_1_3_2_14_2","unstructured":"Terrance DeVries and Graham W. Taylor. 2017. Improved regularization of convolutional neural networks with cutout. arXiv:1708.04552. Retrieved from https:\/\/arxiv.org\/abs\/1708.04552"},{"key":"e_1_3_2_15_2","unstructured":"Yangruibo Ding Yanjun Fu Omniyyah Ibrahim Chawin Sitawarin Xinyun Chen Basel Alomair David Wagner Baishakhi Ray and Yizheng Chen. 2024. Vulnerability detection with code language models: How far are we? arXiv:2403.18624. Retrieved from https:\/\/arxiv.org\/abs\/2403.18624"},{"key":"e_1_3_2_16_2","doi-asserted-by":"publisher","DOI":"10.1007\/s10664-025-10624-2"},{"key":"e_1_3_2_17_2","unstructured":"Xueying Du Geng Zheng Kaixin Wang Jiayi Feng Wentai Deng Mingwei Liu Bihuan Chen Xin Peng Tao Ma and Yiling Lou. 2024. Vul-RAG: Enhancing LLM-based vulnerability detection via knowledge-level RAG. arXiv:2406.11147. Retrieved from https:\/\/arxiv.org\/abs\/2406.11147"},{"key":"e_1_3_2_18_2","doi-asserted-by":"publisher","DOI":"10.1145\/3379597.3387501"},{"key":"e_1_3_2_19_2","unstructured":"Richard Fang Rohan Bindu Akul Gupta and Daniel Kang. 2024. Llm agents can autonomously exploit one-day vulnerabilities. arXiv:2404.08144. Retrieved from https:\/\/arxiv.org\/abs\/2404.08144"},{"key":"e_1_3_2_20_2","doi-asserted-by":"crossref","unstructured":"Zhangyin Feng Daya Guo Duyu Tang Nan Duan Xiaocheng Feng Ming Gong Linjun Shou Bing Qin Ting Liu Daxin Jiang et al. and Ming Zhou. 2020. CodeBERT: A pre-trained model for programming and natural languages. arXiv:2002.08155. Retrieved from https:\/\/arxiv.org\/abs\/2002.08155","DOI":"10.18653\/v1\/2020.findings-emnlp.139"},{"key":"e_1_3_2_21_2","doi-asserted-by":"publisher","DOI":"10.1109\/TNNLS.2013.2292894"},{"key":"e_1_3_2_22_2","doi-asserted-by":"publisher","DOI":"10.1145\/3524842.3528452"},{"key":"e_1_3_2_23_2","doi-asserted-by":"publisher","DOI":"10.1007\/978-3-031-37586-6_17"},{"key":"e_1_3_2_24_2","doi-asserted-by":"publisher","DOI":"10.1109\/ASE56229.2023.00109"},{"key":"e_1_3_2_25_2","doi-asserted-by":"publisher","DOI":"10.1109\/ACCESS.2019.2917620"},{"key":"e_1_3_2_26_2","doi-asserted-by":"publisher","DOI":"10.1145\/3611643.3617850"},{"key":"e_1_3_2_27_2","unstructured":"Daya Guo Qihao Zhu Dejian Yang Zhenda Xie Kai Dong Wentao Zhang Guanting Chen Xiao Bi Y. Wu Y. K. Li et al. 2024. DeepSeek-Coder: When the large language model meets programming \u2013 The rise of code intelligence. arXiv:2401.14196. Retrieved from https:\/\/arxiv.org\/abs\/2401.14196"},{"key":"e_1_3_2_28_2","unstructured":"Hongyu Guo Yongyi Mao and Richong Zhang. 2019. Augmenting data with mixup for sentence classification: An empirical study. arXiv:1905.08941. Retrieved from https:\/\/api.semanticscholar.org\/"},{"key":"e_1_3_2_29_2","doi-asserted-by":"publisher","DOI":"10.1109\/SANER64311.2025.00053"},{"key":"e_1_3_2_30_2","doi-asserted-by":"publisher","DOI":"10.1016\/0004-3702(94)00094-8"},{"key":"e_1_3_2_31_2","unstructured":"Nafis Tanveer Islam Joseph Khoury Andrew Seong Gonzalo De La Torre Parra Elias Bou-Harb and Peyman Najafirad. 2024. LLM-powered code vulnerability repair with reinforcement learning and semantic reward. arXiv:2401.03374. Retrieved from https:\/\/arxiv.org\/abs\/2401.03374"},{"key":"e_1_3_2_32_2","doi-asserted-by":"publisher","DOI":"10.1145\/3587102.3588785"},{"key":"e_1_3_2_33_2","doi-asserted-by":"publisher","DOI":"10.18653\/v1\/2022.emnlp-main.327"},{"key":"e_1_3_2_34_2","doi-asserted-by":"publisher","DOI":"10.1145\/3468264.3468597"},{"key":"e_1_3_2_35_2","doi-asserted-by":"publisher","DOI":"10.14722\/ndss.2018.23158"},{"key":"e_1_3_2_36_2","doi-asserted-by":"publisher","DOI":"10.1007\/978-3-030-41579-2_13"},{"key":"e_1_3_2_37_2","doi-asserted-by":"publisher","DOI":"10.14722\/ndss.2025.241491"},{"key":"e_1_3_2_38_2","doi-asserted-by":"publisher","DOI":"10.1145\/3652032.3657564"},{"key":"e_1_3_2_39_2","doi-asserted-by":"publisher","DOI":"10.1016\/j.jss.2024.112031"},{"key":"e_1_3_2_40_2","doi-asserted-by":"publisher","DOI":"10.1145\/3597503.3639150"},{"key":"e_1_3_2_41_2","doi-asserted-by":"publisher","DOI":"10.1002\/smr.2634"},{"key":"e_1_3_2_42_2","doi-asserted-by":"publisher","DOI":"10.1109\/ICSE48619.2023.00205"},{"key":"e_1_3_2_43_2","doi-asserted-by":"publisher","DOI":"10.1145\/3597503.3639116"},{"key":"e_1_3_2_44_2","doi-asserted-by":"publisher","DOI":"10.1145\/3540250.3549128"},{"key":"e_1_3_2_45_2","doi-asserted-by":"publisher","DOI":"10.1109\/ICSE48619.2023.00211"},{"key":"e_1_3_2_46_2","doi-asserted-by":"publisher","DOI":"10.1109\/WACV48630.2021.00141"},{"key":"e_1_3_2_47_2","unstructured":"OpenAI. 2022. Introducing ChatGPT. Retrieved December 28 2023 from https:\/\/openai.com\/blog\/chatgpt"},{"key":"e_1_3_2_48_2","unstructured":"OpenAI. 2024. GPT-4o mini. Retrieved May 10 2025 from https:\/\/platform.openai.com\/docs\/models\/gpt-4o-mini"},{"key":"e_1_3_2_49_2","doi-asserted-by":"publisher","DOI":"10.1145\/3540250.3558931"},{"key":"e_1_3_2_50_2","doi-asserted-by":"publisher","DOI":"10.1002\/spe.4380250705"},{"issue":"1","key":"e_1_3_2_51_2","first-page":"37","article-title":"E valuation: From precision, recall and F-measure to ROC, informedness, markedness & correlation","volume":"2","author":"Powers David","year":"2011","unstructured":"David Powers. 2011. E valuation: From precision, recall and F-measure to ROC, informedness, markedness & correlation. Journal of Machine Learning Technologies 2, 1 (2011), 37\u201363.","journal-title":"Journal of Machine Learning Technologies"},{"key":"e_1_3_2_52_2","unstructured":"QwietAI.2025. Joern: Code Analysis Tool. Retrieved from https:\/\/github.com\/joernio\/joern"},{"key":"e_1_3_2_53_2","doi-asserted-by":"publisher","DOI":"10.1109\/TSE.2019.2924371"},{"key":"e_1_3_2_54_2","doi-asserted-by":"publisher","DOI":"10.1109\/TSE.2021.3056941"},{"key":"e_1_3_2_55_2","doi-asserted-by":"publisher","DOI":"10.5555\/3698900.3699138"},{"key":"e_1_3_2_56_2","doi-asserted-by":"publisher","DOI":"10.1561\/1500000019"},{"key":"e_1_3_2_57_2","doi-asserted-by":"publisher","DOI":"10.1109\/APR59189.2023.00012"},{"key":"e_1_3_2_58_2","doi-asserted-by":"publisher","DOI":"10.1145\/2897937.2897995"},{"key":"e_1_3_2_59_2","unstructured":"Qwen Team. 2024. Code with CodeQwen1.5. Retrieved from https:\/\/qwenlm.github.io\/blog\/codeqwen1.5\/"},{"key":"e_1_3_2_60_2","doi-asserted-by":"publisher","DOI":"10.1109\/ICSE48619.2023.00189"},{"key":"e_1_3_2_61_2","doi-asserted-by":"publisher","DOI":"10.1109\/ICSME58846.2023.00014"},{"key":"e_1_3_2_62_2","doi-asserted-by":"publisher","DOI":"10.1145\/3643753"},{"key":"e_1_3_2_63_2","doi-asserted-by":"publisher","DOI":"10.1007\/978-3-031-55642-5_4"},{"key":"e_1_3_2_64_2","doi-asserted-by":"publisher","DOI":"10.1109\/ICSE48619.2023.00192"},{"key":"e_1_3_2_65_2","doi-asserted-by":"publisher","unstructured":"Yifan Yao Jinhao Duan Kaidi Xu Yuanfang Cai Zhibo Sun and Yue Zhang. 2024. A survey on large language model (LLM) security and privacy: The good the bad and the ugly. High-Confidence Computing 4 2 (2024) 100211. DOI: 10.1016\/j.hcc.2024.100211","DOI":"10.1016\/j.hcc.2024.100211"},{"key":"e_1_3_2_66_2","volume-title":"Proceedings of the International Conference on Learning Representations","author":"Yao Ziyu","year":"2021","unstructured":"Ziyu Yao, Frank F. Xu, Pengcheng Yin, Huan Sun, and Graham Neubig. 2021. Learning structural edits via incremental tree transformations. In Proceedings of the International Conference on Learning Representations. Retrieved from https:\/\/openreview.net\/forum?id=v9hAX77--cZ"},{"key":"e_1_3_2_67_2","doi-asserted-by":"publisher","DOI":"10.1016\/j.jss.2022.111304"},{"key":"e_1_3_2_68_2","doi-asserted-by":"publisher","DOI":"10.1109\/ICCV.2019.00612"},{"key":"e_1_3_2_69_2","volume-title":"Proceedings of the International Conference on Learning Representations","author":"Zhang Hongyi","year":"2018","unstructured":"Hongyi Zhang, Moustapha Cisse, Yann N. Dauphin, and David Lopez-Paz. 2018. Mixup: Beyond empirical risk minimization. In Proceedings of the International Conference on Learning Representations. Retrieved from https:\/\/openreview.net\/forum?id=r1Ddp1-Rb"},{"key":"e_1_3_2_70_2","doi-asserted-by":"publisher","DOI":"10.1109\/ICAICA52286.2021.9497888"},{"key":"e_1_3_2_71_2","volume-title":"Advances in Neural Information Processing Systems","author":"Zhou Yaqin","year":"2019","unstructured":"Yaqin Zhou, Shangqing Liu, Jingkai Siow, Xiaoning Du, and Yang Liu. 2019. Devign: Effective vulnerability identification by learning comprehensive program semantics via graph neural networks. In Advances in Neural Information Processing Systems. H. Wallach, H. Larochelle, A. Beygelzimer, F. d\u2019Alch\u00e9-Buc, E. Fox, and R. Garnett (Eds.), Vol. 32. Curran Associates, Inc. Retrieved from https:\/\/proceedings.neurips.cc\/paper_files\/paper\/2019\/file\/49265d2447bc3bbfe9e76306ce40a31f-Paper.pdf"}],"container-title":["ACM Transactions on Software Engineering and Methodology"],"original-title":[],"language":"en","link":[{"URL":"https:\/\/dl.acm.org\/doi\/pdf\/10.1145\/3760775","content-type":"unspecified","content-version":"vor","intended-application":"similarity-checking"}],"deposited":{"date-parts":[[2026,4,25]],"date-time":"2026-04-25T06:34:13Z","timestamp":1777098853000},"score":1,"resource":{"primary":{"URL":"https:\/\/dl.acm.org\/doi\/10.1145\/3760775"}},"subtitle":[],"short-title":[],"issued":{"date-parts":[[2026,4,24]]},"references-count":70,"journal-issue":{"issue":"5","published-print":{"date-parts":[[2026,5,31]]}},"alternative-id":["10.1145\/3760775"],"URL":"https:\/\/doi.org\/10.1145\/3760775","relation":{},"ISSN":["1049-331X","1557-7392"],"issn-type":[{"value":"1049-331X","type":"print"},{"value":"1557-7392","type":"electronic"}],"subject":[],"published":{"date-parts":[[2026,4,24]]},"assertion":[{"value":"2024-11-06","order":0,"name":"received","label":"Received","group":{"name":"publication_history","label":"Publication History"}},{"value":"2025-08-05","order":2,"name":"accepted","label":"Accepted","group":{"name":"publication_history","label":"Publication History"}},{"value":"2026-04-24","order":3,"name":"published","label":"Published","group":{"name":"publication_history","label":"Publication History"}}]}}