Transformer-based LLMs in Cybersecurity: An in-depth Study on Log Anomaly Detection and Conversational Defense Mechanisms
The DOI matches its Crossref record; 16 of the 17 references it cites were found in a registry or an index.
Abstract
With the advancement of conversational AI and Large Language Models (LLMs), interactive chatbots are emerging as pivotal assets for connecting with users across various sectors, enabling various capabilities and functions. However, their potential in the cybersecurity domain remains largely untapped. This article introduces a novel method to enhance chatbot performance by incorporating anomaly detection features. Our chatbot uses advanced GPT-3 models and rule-based logic to identify and extract unusual patterns and deviations within logs, making it more proficient in detecting anomalies. We present the architecture and methodology behind our anomaly detection system, showcasing its effectiveness in real-world scenarios. Combining machine learning and domain expertise, our chatbot sets a new standard in interactive, anomaly-aware conversational agents. Our anomaly detection classifier was able to achieve more than 99% of accuracy by illustrating its robust performance in accurately identifying and flagging outliers or unusual patterns in log file data. We also compared the performance of GPT-3 models with other LLMs: BERT, DistilBERT, and ALBERT. Our findings concluded that GPT-3 models consistently outperform all the other LLM models and exhibit significantly higher performance.
Overview
Integrity signals
Registry
Cites
Statistics
Verification
Claims the paper makes
Claims other papers make about this one
Each is checked against this paper’s own text: does it say what the citing paper says it does?
In the citing paper
“The first is the emergence of large language models (LLMs) capable of zero-shot reasoning over heterogeneous textual artifacts-packet captures rendered as text, system logs, threat-intelligence reports, MITRE ATT&CK technique descriptions, CVE narratives-without bespoke feature engineering”
From Agentic AI and Large Language Models for Autonomous IoT Cybersecurity: A Systematic Survey, Taxonomy, and Research Roadmap (2026) · cites this paper as [16]
In the citing paper
“Hybrid IDS architectures that combine line-rate ML detectors with gateway-resident LLMs for triage are gaining traction because they balance latency (tens of milliseconds) with reasoning capacity [16,68,74,87].”
From Agentic AI and Large Language Models for Autonomous IoT Cybersecurity: A Systematic Survey, Taxonomy, and Research Roadmap (2026) · cites this paper as [16]
Citations
Cites
BERT: Pre-training of Deep Bidirectional Transformers for Language Understanding
Devlin, J., Chang, M.-W., Lee, K., & Toutanova, K. (2018) · arXiv · doi:10.48550/arxiv.1810.04805 · Cited by 73,173 · cited 1×
“The BERT model, developed by Google AI [5], stands as a state-of-the-art transformer-based model that is pre-trained bidirectionally on an extensive textual dataset.”
MethodBERT: Pre-training of Deep Bidirectional Transformers for Language Understanding
Devlin, J., Chang, M.-W., Lee, K., & Toutanova, K. (2019) · Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers) · doi:10.18653/v1/n19-1423 · Cited by 54,325 · cited 1×
“The BERT model, developed by Google AI [5], stands as a state-of-the-art transformer-based model that is pre-trained bidirectionally on an extensive textual dataset.”
MethodDistilBERT, a distilled version of BERT: smaller, faster, cheaper and lighter
Sanh, V., Debut, L., Chaumond, J., & Wolf, T. (2019) · arXiv · doi:10.48550/arxiv.1910.01108 · Cited by 13,823 · cited 1×
“2) DistilBERT DistilBERT is perceived as a streamlined and swifter counterpart to BERT, birthed by Hugging Face [11].”
BackgroundALBERT: A Lite BERT for Self-supervised Learning of Language Representations
Lan, Z., Chen, M., Goodman, S., Gimpel, K., Sharma, P., & Soricut, R. (2019) · arXiv · doi:10.48550/arxiv.1909.11942 · Cited by 4,308 · cited 1×
“3) ALBERT (A Lite BERT) ALBERT, developed by Google AI [9], emerged as a solution to address BERT’s limitations, specifically targeting a diminished model size and augmented training efficacy.”
MethodExperience Report: System Log Analysis for Anomaly Detection
He, S., Zhu, J., He, P., & Lyu, M. R. (2016) · 2016 IEEE 27th International Symposium on Software Reliability Engineering (ISSRE) · doi:10.1109/issre.2016.21 · Cited by 593 · cited 1×
“[7].”
Loghub: a large collection of system log datasets for AI-driven log analytics
Zhu, J., He, S., He, P., Liu, J., & Lyu, M. R. (2023) · 2023 IEEE 34th International Symposium on Software Reliability Engineering (ISSRE) · doi:10.1109/issre59848.2023.00071 · Cited by 302 · cited 1×
“To support this training, we utilize a comprehensive and annotated open-source dataset [17] from prior research on anomaly detection [18], establishing a robust groundwork for detecting anomalies.”
Evaluation of Machine Learning Algorithms for Anomaly Detection
Elmrabit, N., Zhou, F., Li, F., & Zhou, H. (2020) · 2020 International Conference on Cyber Security and Protection of Digital Services (Cyber Security) · doi:10.1109/cybersecurity49315.2020.9138871 · Cited by 212 · cited 1×
“Elmrabit et al. [6] conducted a comprehensive comparison of various machine learning algorithms, including prominent algorithms like Long Short-Term Memory (LSTM), Decision Tree (DT), Random Forest (RF), Deep Neural Network (DNN), etc.”
Experience Report: Log Mining Using Natural Language Processing and Application to Anomaly Detection
Bertero, C., Roy, M., Sauvanaud, C., & Tredan, G. (2017) · 2017 IEEE 28th International Symposium on Software Reliability Engineering (ISSRE) · doi:10.1109/issre.2017.43 · Cited by 139 · cited 1×
“In [2], the authors employed the word2vec model to produce word embeddings for log data.”
Dynamic log file analysis: An unsupervised cluster evolution approach for anomaly detection
Landauer, M., Wurzenberger, M., Skopik, F., Settanni, G., & Filzmoser, P. (2018) · Computers & Security · doi:10.1016/j.cose.2018.08.009 · Cited by 93 · cited 2×
“The importance of identifying anomalies within logs has been underscored in various studies [10, 13, 4].”
BackgroundMachine learning to detect anomalies in web log analysis
Cao, Q., Qiao, Y., & Lyu, Z. (2017) · 2017 3rd IEEE International Conference on Computer and Communications (ICCC) · doi:10.1109/compcomm.2017.8322600 · Cited by 55 · cited 2×
“The importance of identifying anomalies within logs has been underscored in various studies [10, 13, 4].”
Research works printed but not linked: 3
- He, 2020, Loghub: A large collection of system log datasets towards automated log analytics, arXiv preprint arXiv:2008.06448 · arXiv
- Saxena, 2021, IoT Dynamic Log File Analysis: Security Approach for Anomaly Detection In Multi Sensor Environment, International research journal of modernization in engineering technology & Science, 3, 2582
- 10.7717/peerj.12726/table-1 · doi:10.7717/peerj.12726/table-1
Cited by
Kheddar, H. (2025) · Information Fusion · doi:10.1016/j.inffus.2025.103347 · Cited by 161
A Survey on XAI for 5G and Beyond Security: Technical Aspects, Challenges and Research Directions
Senevirathna, T., La, V. H., Marchal, S., Siniarski, B., Liyanage, M., & Wang, S. (2024) · IEEE Communications Surveys & Tutorials · doi:10.1109/comst.2024.3437248 · Cited by 153
“Furthermore, LLM-based penetrating testing tools (e.g.: PentestGPT [169]), anomaly detection tools (e.g., PAC-GPT [170], LogBERT [171], LogBot [172]), and threat detection tools (e.g., TSTEM [173], Cyber Sentinel [174]) The rise of this new addition to the security stack of 5G and beyond begs the…”
Balasubramanian, P., Liyana, S., Sankaran, H., Sivaramakrishnan, S., Pusuluri, S., Pirttikangas, S., & Peltonen, E. (2025) · Artificial Intelligence Review · doi:10.1007/s10462-025-11338-z · Cited by 86
Self-citationLLMs are one-shot URL classifiers and explainers
Rashid, F., Ranaweera, N., Doyle, B., & Seneviratne, S. (2024) · Computer Networks · doi:10.1016/j.comnet.2024.111004 · Cited by 40
CYGENT: A cybersecurity conversational agent with log summarization powered by GPT-3
Balasubramanian, P., Seby, J., & Kostakos, P. (2024) · International Conference on Artificial Intelligence for Internet of Things (AIIoT) · doi:10.1109/aiiot58432.2024.10574658 · Cited by 26
“As part of feature development, in our previous paper [11] we developed an anomaly detection feature for the CYGENT framework which uses fine tuned GPT3 models for detection of anomalies in the log data.”
MethodSelf-citationYuan, Z., Sun, Q., Zhou, H., Shao, M., & Fu, X. (2025) · International Journal of Machine Learning and Cybernetics · doi:10.1007/s13042-024-02516-6 · Cited by 27
“For instance, traditional rule-based detection has been fused with LLM-based detection to enhance log detection performance [173].”
Deep anomaly detection of temporal heterogeneous data in AIOps: a survey
Gui, J., Ma, Z., Zhou, H., Su, Y., Zhang, M., Yu, K., & Wu, X. (2025) · Frontiers of Information Technology & Electronic Engineering · doi:10.1631/fitee.2400467 · Cited by 12
“Transformer-based models (Balasubramanian et al., 2023) use pre-trained embedding to represent log entries in a high-dimensional space, capturing semantic information beyond simple token-level representations.”
Corbelle, C., Carneiro, V., & Cacheda, F. (2024) · Applied Sciences · doi:10.3390/app14135388 · Cited by 9
“Hierarchical thematic classification in a system log can be an effective strategy for reducing its size and preparing it for fine-tuning Large Language Models (LLM) in anomaly detection, which are starting to yield promising results [4].”
BackgroundMethodHex2Sign: Automatic IDS Signature Generation from Hexadecimal Data using LLMs
Balasubramanian, P., Ali, T., Salmani, M., KhoshKholgh, D., & Kostakos, P. (2024) · IEEE International Conference on Big Data (BigData) · doi:10.1109/bigdata62323.2024.10825710 · Cited by 12
Self-citationAdvancing 5G Security and Privacy with AI: A Survey
He, H., Fei, S., & Yan, Z. (2025) · ACM Computing Surveys · doi:10.1145/3744555 · Cited by 13
“2.”
Fine-Tuning Large Language Models for Network Traffic Analysis in Cyber Security
Lavi, O., Manor, O., Schwartz, T., Murillo, A., Messous, A., Sekiya, M., Suga, J., Hikichi, K., & Unno, Y. (2024) · IEEE Conference on Dependable and Secure Computing (DSC) · doi:10.1109/dsc63325.2024.00019 · Cited by 9
“The authors of [14] used fine-tuning for integrating Generative Pre-Trained Transformer (GPT) within rule-based detection algorithms in network log files.”
Lightweight Fine-Tuning of LLMS for Explainable Intrusion Detection in SDN
Lodh, S., Obaidat, I., Rustam, F., & Jurcut, A. D. (2025) · IEEE International Conference on Wireless and Mobile Computing, Networking and Communications (WiMob) · doi:10.1109/wimob66857.2025.11257572 · Cited by 4
“Bal-asubramanian et al. [14] fine-tune GPT-3 models as anomaly detectors on log data, achieving high detection accuracy.”
Nageshwaran, V., & Ezekiel, S. (2026) · doi:10.20944/preprints202606.0142.v1 · Cited by 4
Nageshwaran, V., & Ezekiel, S. (2026) · Electronics · doi:10.3390/electronics15122740 · Cited by 4
Attribution-Driven Explainable Intrusion Detection with Encoder-Based Large Language Models
Biswas, U., Hasan, S., Farhan, S. M., Pillai, N., & Gudla, C. (2026) · IEEE SoutheastCon · doi:10.1109/southeastcon63549.2026.11476386 · Cited by 3
“GPT-3 models have been adapted for anomaly detection [21], while GPT-4 has been examined using in-context learning with limited labeled traffic data [22].”
Guo, J., Gu, Z., Jiang, H., Li, Y., & Zhu, D. (2025) · Array · doi:10.1016/j.array.2025.100447 · Cited by 4
LLMs in Security Testing and Monitoring: An Initial Study
Nguyen, L., Nguyen, M.-D., Bui, A. H., Cavalli, A. R., & de, E. M. (2025) · Lecture notes in computer science · doi:10.1007/978-3-032-00644-8_9 · Cited by 3
LLMs for Intrusion Detection Systems: A Review
Arife Gülşah, E. R. O. L., & Demirci, S. (2025) · doi:10.1109/isctrkiye68593.2025.11224813 · Cited by 2
A Critical Evaluation of Agentic AI in Cybersecurity: The Pros and the Cons
Obojo, V., Ikuesan, R. A., & Iortom, E. (2025) · Cyber Security in Networking Conference (CSNet) · doi:10.1109/csnet67572.2025.11288238 · Cited by 1
“Industry reports forecast that by 2025, AI-driven cyberattacks will constitute more than a quarter of total global threats, highlighting the urgency of developing equally adaptive defence mechanisms [1], [2].”
Enhancing Log Analysis for Intrusion Detection Using Large Language Models
Silva, D. F. C., Vitória, A. R. S., Fanucchi, R. Z., & Filho, A. R. G. (2025) · IEEE Latin Conference on IoT (LCIoT) · doi:10.1109/lciot64881.2025.11118614 · Cited by 1
“Recent research demonstrates that these architectures can effectively identify anomalies in log data [6], [7].”
Bal, S., Mishrra, S., & Das, M. (2025) · Global AI Summit - International Conference on Artificial Intelligence and Emerging Technology (AI Summit) · doi:10.1109/aisummit66170.2025.11411297
“GPT-based models can identify log anomalies but had to be calibrated for long-term cybersecurity effectiveness, Balasubramanian et al. [8] concluded.”
AnomalyExplainerBot: Explainable AI for LLM-Based Anomaly Detection Using BERTViz and Captum
Balasubramanian, P., Kankanamge, D., Gilman, E., & Oussalah, M. (2026) · Communications in computer and information science · doi:10.1007/978-3-032-19099-4_36 · Cited by 1
Self-citationFrom Machine Learning to LogBERT: A Survey of Web Log Anomaly Detection for APT and Botnet Threats
Altmimi, S., & Alomari, E. S. (2026) · Al-Noor Journal of Engineering Management and Computer Science · doi:10.71229/7tzh0144
Metadata
- Authors
- Balasubramanian, P., Seby, J., & Kostakos, P.
- Affiliations
- University of Oulu (FI)
- Venue
- 2023 IEEE International Conference on Big Data (BigData)
- Publisher
- IEEE
- Published
- 2023-12-15
- Pages
- 3590-3599
- OpenAlex
- W4391094158
- Cited by
- 22
- References
- 17
- Citations by year
- 2026: 4 · 2025: 12 · 2024: 6
- FWCI
- 6.65
- Type
- conference paper
- Language
- en
- Open access
- closed
- Locations
- IEEE International Conference on Big Data (BigData) (publishedVersion)
- Funders
- European Commission
- Academy of Finland
- Topics
- Physical Sciences › Computer Science › Computer Networks and Communications › Software System Performance and Reliability
- Physical Sciences › Computer Science › Computer Networks and Communications › Network Security and Intrusion Detection
- Physical Sciences › Computer Science › Artificial Intelligence › Anomaly Detection Techniques and Applications
- Keywords
- log anomaly detection, chatbots, large language models, GPT-3, cybersecurity, transformer models, BERT, DistilBERT, ALBERT, model comparison
About these checks
Registry, retraction, Cites and statistics results are computed, not judged, with one exception: a printed reference that no index lists is read once by a model before it counts as a citation error. Claims are extracted by a model and kept only when their quote appears verbatim in the text; each cited source is then checked, with a model’s help, for whether it says what the claim relies on. Those verdicts can be wrong — read the claim’s quote and the cited source before relying on one.
Statistics and arithmetic are recomputed, not judged.
Confidence bands are shown only for fields calibrated on our annotated test set. None is calibrated yet, so no band is shown.
What counts as a claim ›How we measure confidence ›How we check this ›
Are you an author, or do you see a problem with this page? Request a review
Data sources
Bibliographic data: Semantic Scholar, OpenAlex, Crossref.
Contains information from the Semantic Scholar Academic Graph Datasets, made available under the ODC Attribution License (ODC-BY 1.0).
Semantic Scholar’s data is described in: Kinney, R., et al. (2023). The Semantic Scholar Open Data Platform. arXiv:2301.10140.