SecRAG: A Graph-Enhanced RAG Framework with Dynamic Prompt for Cybersecurity Applications
In this paper, we introduce SecRAG, a novel Retrieval-Augmented Generation (RAG) system specifically designed for cybersecurity applications. SecRAG tackles fundamental challenges in context precision and domain-specific terminology through a dual-pronged approach: 1) a data augmentation method optimized for cybersecurity contexts, particularly addressing the RAG system's numerical information sensitivity limitations; and 2) an enhanced dual-level retrieval architecture that integrates graph-based knowledge representation and adaptive text indexing, incorporating a dynamic prompt weighting mechanism based on dual similarity metrics (δ<inf xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:xlink="http://www.w3.org/1999/xlink">1</inf>, δ<inf xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:xlink="http://www.w3.org/1999/xlink">2</inf>) for query relationship and output coherence assessment, to enable comprehensive information discovery. Experimental evaluation on the SecEval benchmark demonstrates that SecRAG achieves stantial improvements over conventional RAG implementations, with a 30% increase in vulnerability node recall rates and reduction in temporal confusion rate to 1.1%. The system has shown particular strengths in specialized areas, achieving overall accuracy rate of 72.02% on the SecEval benchmarks. Our framework effectively addresses the unique challenges of cybersecurity-focused RAG systems, particularly in handling precise numeric attributes and maintaining contextual coherence in multi-turn dialogues.
Authors
- Lun Li (ORCID: https://orcid.org/0000-0002-9984-5948)
- Feng Cheng (ORCID: https://orcid.org/0000-0001-5672-5578)
- Hongsong Zhu (ORCID: https://orcid.org/0000-0003-3720-7403)
- Jie Zhang (ORCID: https://orcid.org/0000-0003-2493-5209)
- Yu Qiao (ORCID: https://orcid.org/0000-0002-6936-4852)
- Jin Gao (ORCID: https://orcid.org/0000-0002-2127-7098)
Institutions
- Chinese Academy of Sciences (CN)
- Institute of Information Engineering (CN)
Publication Details
- Published
- 2025-05-05
- DOI
- https://doi.org/10.1109/cscwd64889.2025.11033478
- Primary Topic
- Graph Theory and Algorithms
- Type
- article
- Field-Weighted Citation Impact
- 0.00