LogPurge: Log Data Purification for Anomaly Detection via Rule-Enhanced Filtering

Fuente: arXiv
Salvato in:
Dettagli Bibliografici
Autori principali: Zhang, Shenglin, Chen, Ziang, Que, Zijing, Liu, Yilun, Sun, Yongqian, Wei, Sicheng, Pei, Dan, Li, Hailin
Natura: Preprint
Pubblicazione: 2025
Soggetti:
Accesso online:
Tags: Aggiungi Tag
Nessun Tag, puoi essere il primo ad aggiungerne!!
_version_ 1866911273554280448
author Zhang, Shenglin
Chen, Ziang
Que, Zijing
Liu, Yilun
Sun, Yongqian
Wei, Sicheng
Pei, Dan
Li, Hailin
author_facet Zhang, Shenglin
Chen, Ziang
Que, Zijing
Liu, Yilun
Sun, Yongqian
Wei, Sicheng
Pei, Dan
Li, Hailin
contents Log anomaly detection, which is critical for identifying system failures and preempting security breaches, detects irregular patterns within large volumes of log data, and impacts domains such as service reliability, performance optimization, and database log analysis. Modern log anomaly detection methods rely on training deep learning models on clean, anomaly-free log sequences. However, obtaining such clean log data requires costly and tedious human labeling, and existing automatic cleaning methods fail to fully integrate the specific characteristics and actual semantics of logs in their purification process. In this paper, we propose a cost-aware, rule-enhanced purification framework, LogPurge, that automatically selects a sufficient subset of normal log sequences from contamination log sequences to train a anomaly detection model. Our approach involves a two-stage filtering algorithm: In the first stage, we use a large language model (LLM) to remove clustered anomalous patterns and enhance system rules to improve LLM's understanding of system logs; in the second stage, we utilize a divide-and-conquer strategy that decomposes the remaining contaminated regions into smaller subproblems, allowing each to be effectively purified through the first stage procedure. Our experiments, conducted on two public datasets and one industrial dataset, show that our method significantly removes an average of 98.74% of anomalies while retaining 82.39% of normal samples. Compared to the latest unsupervised log sample selection algorithms, our method achieves F-1 score improvements of 35.7% and 84.11% on the public datasets, and an impressive 149.72% F-1 improvement on the private dataset, demonstrating the effectiveness of our approach.
format Preprint
id arxiv_https___arxiv_org_abs_2511_14062
institution arXiv
publishDate 2025
record_format arxiv
spellingShingle LogPurge: Log Data Purification for Anomaly Detection via Rule-Enhanced Filtering
Zhang, Shenglin
Chen, Ziang
Que, Zijing
Liu, Yilun
Sun, Yongqian
Wei, Sicheng
Pei, Dan
Li, Hailin
Software Engineering
Machine Learning
Log anomaly detection, which is critical for identifying system failures and preempting security breaches, detects irregular patterns within large volumes of log data, and impacts domains such as service reliability, performance optimization, and database log analysis. Modern log anomaly detection methods rely on training deep learning models on clean, anomaly-free log sequences. However, obtaining such clean log data requires costly and tedious human labeling, and existing automatic cleaning methods fail to fully integrate the specific characteristics and actual semantics of logs in their purification process. In this paper, we propose a cost-aware, rule-enhanced purification framework, LogPurge, that automatically selects a sufficient subset of normal log sequences from contamination log sequences to train a anomaly detection model. Our approach involves a two-stage filtering algorithm: In the first stage, we use a large language model (LLM) to remove clustered anomalous patterns and enhance system rules to improve LLM's understanding of system logs; in the second stage, we utilize a divide-and-conquer strategy that decomposes the remaining contaminated regions into smaller subproblems, allowing each to be effectively purified through the first stage procedure. Our experiments, conducted on two public datasets and one industrial dataset, show that our method significantly removes an average of 98.74% of anomalies while retaining 82.39% of normal samples. Compared to the latest unsupervised log sample selection algorithms, our method achieves F-1 score improvements of 35.7% and 84.11% on the public datasets, and an impressive 149.72% F-1 improvement on the private dataset, demonstrating the effectiveness of our approach.
title LogPurge: Log Data Purification for Anomaly Detection via Rule-Enhanced Filtering
topic Software Engineering
Machine Learning
url https://arxiv.org/abs/2511.14062