Modern networks generate vast, heterogeneous traffic that must be continuously analyzed for security and performance. Traditional network traffic analysis systems, whether rule-based or machine learning-driven, often suffer from high false positives and lack interpretability, limiting analyst trust. In this paper, we present ReGAIN, a multi-stage framework that combines traffic summarization, retrieval-augmented generation (RAG), and Large Language Model (LLM) reasoning for transparent and accurate network traffic analysis. ReGAIN creates natural-language summaries from network traffic, embeds them into a multi-collection vector database, and utilizes a hierarchical retrieval pipeline to ground LLM responses with evidence citations. The pipeline features metadata-based filtering, MMR sampling, a two-stage cross-encoder reranking mechanism, and an abstention mechanism to reduce hallucinations and ensure grounded reasoning. Evaluated on ICMP ping flood and TCP SYN flood traces from the real-world traffic dataset, it demonstrates robust performance, achieving accuracy between 95.95% and 98.82% across different attack types and evaluation benchmarks. These results are validated against two complementary sources: dataset ground truth and human expert assessments. ReGAIN also outperforms rule-based, classical ML, and deep learning baselines while providing unique explainability through trustworthy, verifiable responses.


翻译:现代网络产生海量异构流量,必须持续分析以保障安全与性能。传统的网络流量分析系统(无论是基于规则还是机器学习驱动)通常存在误报率高、可解释性不足的问题,限制了分析人员的信任度。本文提出ReGAIN——一个融合流量摘要生成、检索增强生成(RAG)与大语言模型(LLM)推理的多阶段框架,旨在实现透明且精准的网络流量分析。ReGAIN将网络流量转化为自然语言摘要,将其嵌入多集合向量数据库,并采用分层检索管道为LLM响应提供证据引证。该管道具备基于元数据的过滤功能、MMR采样机制、两阶段交叉编码器重排序机制以及弃权机制,以降低幻觉生成并确保基于证据的推理。通过在真实流量数据集的ICMP ping泛洪与TCP SYN泛洪流量轨迹上进行评估,本框架展现出鲁棒的性能,在不同攻击类型和评估基准下准确率达到95.95%至98.82%。这些结果通过两个互补来源验证:数据集真实标签与人类专家评估。ReGAIN在超越基于规则、经典机器学习和深度学习基线方法的同时,通过提供可信且可验证的响应,实现了独特的可解释性优势。

0
下载
关闭预览

相关内容

图机器学习 2.2-2.4 Properties of Networks, Random Graph
图与推荐
10+阅读 · 2020年3月28日
Single-Shot Object Detection with Enriched Semantics
统计学习与视觉计算组
14+阅读 · 2018年8月29日
论文浅尝 | Know-Evolve: Deep Temporal Reasoning for Dynamic KG
开放知识图谱
36+阅读 · 2018年3月30日
国家自然科学基金
4+阅读 · 2015年12月31日
国家自然科学基金
46+阅读 · 2015年12月31日
国家自然科学基金
6+阅读 · 2014年12月31日
国家自然科学基金
17+阅读 · 2008年12月31日
VIP会员
相关资讯
图机器学习 2.2-2.4 Properties of Networks, Random Graph
图与推荐
10+阅读 · 2020年3月28日
Single-Shot Object Detection with Enriched Semantics
统计学习与视觉计算组
14+阅读 · 2018年8月29日
论文浅尝 | Know-Evolve: Deep Temporal Reasoning for Dynamic KG
开放知识图谱
36+阅读 · 2018年3月30日
相关基金
国家自然科学基金
4+阅读 · 2015年12月31日
国家自然科学基金
46+阅读 · 2015年12月31日
国家自然科学基金
6+阅读 · 2014年12月31日
国家自然科学基金
17+阅读 · 2008年12月31日
Top
微信扫码咨询专知VIP会员