The invention relates to the technical field of
artificial intelligence and computer
system security, in particular to a log
anomaly detection method based on pattern awareness and a synthetic attention mechanism, which comprises the following steps: generating initial event embedding through log analysis and vectorization; constructing a parallel mode
perception path and a sequence context path, respectively utilizing a dynamic graph
attention network to extract macroscopic
service mode structure features, and capturing a microscopic
time sequence dependency relationship based on a Transform
encoder; designing a bidirectionally guided synthetic attention mechanism, realizing mode-to-sequence focusing guidance and sequence-to-mode anomaly
backtracking, and generating a synthetic anomaly representation fused with a context abstract and a mode deviation; and finally, outputting an abnormal
score and interpretable alarm information through an MLP classifier. According to the technical scheme, collaborative modeling of the macroscopic mode and the microscopic details in the
log data can be achieved, and the accuracy, robustness and
interpretability of
anomaly detection in a complex scene are remarkably improved.