# Finsformer: A Novel Approach to Detecting Financial Attacks Using Transformer and Cluster-Attention
## 4 Results and Discussion
### Limitations and Future Work  
This study has achieved certain innovations and progress in the field of financial attack detection, yet it also faces some limitations and proposes directions for future research. Firstly, regarding the innovations of this work, the Finsformer model, by integrating the  
\begin{table}
\begin{tabular}{l c c c c} \hline \hline
**Feature Extractor** & **Precision** & **Recall** & **Accuracy** & **F1-Score** \\ \hline Manual Feature Extractor & & & & \\ (SVM) [47] & 0.87 & 0.89 & 0.89 & 0.88 \\ RNN [38] & 0.93 & 0.91 & 0.91 & 0.92 \\ CNN [36] & 0.92 & 0.91 & 0.92 & 0.91 \\ Finsformer & 0.97 & 0.94 & 0.95 & 0.95 \\ \hline \hline \end{tabular}
\end{table}
Table 3: Detection results of different feature extractors.  
Transformer architecture and cluster-attention mechanism, has effectively enhanced the accuracy and efficiency of financial attack detection. The Transformer's powerful capability in processing sequential data allows Finsformer to capture long-term dependencies and complex patterns in financial data. Concurrently, the introduction of the cluster-attention mechanism strengthens the model's ability to identify key patterns in financial transaction data, particularly demonstrating superior performance in dealing with large-scale and diverse datasets. The experimental results show that Finsformer surpasses traditional deep learning models such as RNN, LSTM, Transformer, and BERT in several key performance metrics. However, this study also has limitations. Primarily, the computational efficiency of the Finsformer model, especially in processing large datasets, remains a challenge. Although the Transformer architecture offers good parallel processing capabilities, the training and inference speed of the model might be impacted when handling very large-scale data. Additionally, the performance of the model largely depends on the quality and diversity of the data. In practical applications, financial transaction data might be plagued with issues of noise, inconsistency, and incompleteness, potentially affecting the model's accuracy and robustness.  
Future research directions could unfold in several areas: firstly, optimizing the computational efficiency of the Finsformer model, particularly in handling large datasets, and exploring more efficient training and inference methods. Secondly, further enhancing the model's robustness to noise and inconsistent data, for instance, by introducing more advanced data preprocessing and augmentation techniques. Additionally, considering integrating the Finsformer model with other types of security defense mechanisms, such as traditional network security technologies, to improve the overall level of financial security. Furthermore, exploring the application of the Finsformer model in a broader range of financial security scenarios, such as fraud detection and abnormal transaction monitoring, to validate the model's generalization ability and practical application value. Simultaneously, testing and optimizing Finsformer on more diverse and larger datasets is considered, to assess its adaptability and effectiveness in different financial environments.  
In conclusion, although this paper has made some progress in the realm of financial attack detection, continued in-depth research and constant optimization are required in the face of ever-changing and increasingly complex financial security threats. Through future efforts, significant achievements in the field of financial security are anticipated, providing robust technical support for the stability and development of the finance industry.