# HuntGPT: Integrating Machine Learning-Based Anomaly Detection and Explainable AI with Large Language Models (LLMs)

HuntGPT: 머신러닝 기반 이상 탐지와 설명 가능한 AI를 대규모 언어 모델(LLM)과 통합하기

Tarek Ali, Panos Kostakos · arXiv · 2023년 9월 27일

- **연구 문제** 기존 머신러닝 기반 네트워크 이상 탐지는 오탐과 설명 부족으로 분석가의 신뢰를 얻기 어렵습니다.
- **연구 방법** Random Forest 탐지 모델, SHAP·LIME 설명, GPT-3.5 Turbo 대화 에이전트를 하나의 대시보드로 결합합니다.
- **주요 결과** GPT-3.5 Turbo는 세 가지 사이버보안 문항 묶음에서 72%에서 82.5%의 성공률을 보였고, 생성 설명과 챗봇 응답은 여섯 가지 가독성 공식에서 대체로 대학원 수준으로 평가되었습니다.

## 문제 설정: 탐지 모델의 설명 부족과 운영자의 해석 부담

네트워크 이상 탐지에 머신러닝을 쓰면 위협 헌팅 속도는 높아질 수 있지만, 오탐과 모델 유지의 어려움 때문에 분석가가 결과를 신뢰하기 어렵습니다. 원문은 이 문제를 XAI 도구가 있어도 사이버보안 운영 현장에서 제한적으로 수용되었다는 선행 관찰과 함께 제기합니다. 이 논문은 이 공백을 메우기 위해 탐지, 설명, 대화형 해석을 하나의 대시보드로 묶는 HuntGPT를 제안합니다.

HuntGPT는 KDD99 데이터셋으로 학습한 Random Forest 분류기를 이상 탐지 모델로 사용하고, SHAP와 LIME로 예측 요인을 설명합니다. 여기에 GPT-3.5 Turbo 기반 대화형 에이전트를 붙여 탐지 결과를 설명하고 후속 질문에 답하게 합니다. 따라서 이 연구의 범위는 탐지 정확도 자체보다 설명 가능성과 대화형 해석 경험의 구현과 평가에 있습니다.

## 처리 흐름: 탐지, 설명 생성, 대화형 분석

HuntGPT의 처리 흐름은 세 단계로 구성됩니다. 먼저 사전 학습된 Random Forest 모델을 적재하고, 실행 중에는 개별 네트워크 흐름을 정상 또는 이상으로 예측합니다. 이어서 SHAP와 LIME가 예측에 영향을 준 요인과 플롯을 만들고, 이 결과를 Elasticsearch의 탐지 패킷 인덱스와 AWS S3의 플롯 저장소에 보관합니다.

![Figure 2: System Components Diagram](https://refivu.com/papers/b050833e-0d12-4b4b-b5d8-471ef2df91cb/figures/figure-ecdd9b4b87116fc43d6db824ca160fea.png?thumb=512)

**Fig. 2** . System Components Diagram

[원문](https://arxiv.org/abs/2309.16021v1) · [CC BY 4.0](https://creativecommons.org/licenses/by/4.0/) · Tarek Ali, Panos Kostakos · HuntGPT: Integrating Machine Learning-Based Anomaly Detection and Explainable AI with Large Language Models (LLMs) · 원문 그림 인용 · 원본 PDF 5쪽에서 그림 영역을 추출했습니다.

![Figure 3: Sections of Detection and Explainability in the Dashboard](https://refivu.com/papers/b050833e-0d12-4b4b-b5d8-471ef2df91cb/figures/figure-048950500613f58a0795d21f514052c7.png?thumb=512)

**Fig. 3** . Sections of Detection and Explainability in the Dashboard.

[원문](https://arxiv.org/abs/2309.16021v1) · [CC BY 4.0](https://creativecommons.org/licenses/by/4.0/) · Tarek Ali, Panos Kostakos · HuntGPT: Integrating Machine Learning-Based Anomaly Detection and Explainable AI with Large Language Models (LLMs) · 원문 그림 인용 · 원본 PDF 7쪽에서 그림 영역을 추출했습니다.

대화 단계에서는 Elasticsearch의 탐지 문서를 가져와 OpenAI API에 전달합니다. 이때 탐지 데이터와 정제된 프롬프트가 함께 들어가며, GPT-3.5 Turbo 기반 AI 어시스턴트가 분석 내용을 만들고 분석가와 후속 대화를 이어 갑니다. 대시보드는 모델의 내부 요인, 원본 패킷, AI 설명을 한 화면에 배치하고 보고서 생성 기능도 제공합니다.

![Figure 1: High level diagram of dashboard integration](https://refivu.com/papers/b050833e-0d12-4b4b-b5d8-471ef2df91cb/figures/figure-203e3be2dad0caf96905293d2a7a96b8.png?thumb=512)

**Fig. 1** . High level diagram of dashboard integration.

[원문](https://arxiv.org/abs/2309.16021v1) · [CC BY 4.0](https://creativecommons.org/licenses/by/4.0/) · Tarek Ali, Panos Kostakos · HuntGPT: Integrating Machine Learning-Based Anomaly Detection and Explainable AI with Large Language Models (LLMs) · 원문 그림 인용 · 원본 PDF 4쪽에서 그림 영역을 추출했습니다.

## 기술 지식 검증: 인증 시험 문항 정확도

저자들은 GPT-3.5 Turbo가 사이버보안 지식을 가졌는지 확인하기 위해 CISM 실습 시험, ISACA 공식 CISM 연습 퀴즈, ISACA 사이버보안 기초 연습 퀴즈를 사용했습니다. 원문의 표 III 기준으로 CISM 실습 시험은 40문항이며 성공률은 82.5%입니다. ISACA 공식 CISM 연습 퀴즈는 10문항이며 80%입니다. ISACA 사이버보안 기초 연습 퀴즈는 25문항이며 72%입니다.

이 결과는 세 개의 문항 묶음에서 얻은 성공률입니다. 세 시험은 같은 난이도의 자격 시험 전체가 아니라 준비용 문항을 사용했으므로, 이 점수는 GPT-3.5 Turbo가 해당 문항 묶음에서 보인 성취로 읽어야 합니다. 원문은 CISM 응시자 중 첫 응시 합격률이 50~60% 수준이라는 외부 정보를 함께 제시하지만, 이를 모델 평가의 직접 기준으로 고정하지는 않습니다.

## 응답 가독성 평가: 여섯 가지 공식과 결과

두 번째 검증은 생성된 이상 설명과 챗봇 응답의 가독성입니다. 저자들은 생성 설명 20건과 챗봇 로그 20건을 평가했으며, 각 로그에는 약 여섯 개의 질문이 포함되었습니다. 평가에는 py-readability-metrics 라이브러리의 여섯 가지 공식을 사용했습니다. 여기에는 Flesch-Kincaid Grade Level, Flesch Reading Ease, Dale Chall, Automated Readability Index, Coleman Liau Index, Linsear Write가 포함됩니다.

표 IV에서 생성 설명의 Flesch-Kincaid Grade Level은 15.7이며 학년 수준은 16입니다. 챗봇 응답은 14.9이며 학년 수준은 15입니다. Flesch Reading Ease는 생성 설명 22.7, 챗봇 응답 23.9로 모두 graduate로 표기됩니다. 원문은 대부분의 공식에서 두 응답 집합이 대학원 수준 또는 그에 준하는 복잡성을 보인다고 보고합니다. 다만 같은 평가가 실제 사용자 이해도나 분석가 작업 성과를 직접 측정한 것은 아닙니다.

## 적용 범위와 남은 질문

이 논문의 근거는 탐지 모델의 정량 성능보다 설명 대시보드의 구성과 두 종류의 텍스트 평가에 집중되어 있습니다. 가독성 공식은 문장 길이와 어휘 특성을 측정하며, 설명이 분석가의 의사결정을 얼마나 개선했는지는 제공된 평가에서 확인되지 않습니다. 또한 GPT-3.5 Turbo의 시험 성공률은 특정 문항 묶음의 결과이며, 실시간 운영 환경에서 대화 응답의 정확성을 보장하는 근거는 아닙니다.

저자들은 향후 과제로 실시간 탐지 능력을 강화하고, 챗봇이 SIEM에 명령을 내리는 actionable AI를 구현하는 방향을 제시합니다. 이는 아직 수행된 실험이 아니라 향후 계획입니다.

## 논문 정보

- **저자**: Tarek Ali, Panos Kostakos
- **학회·저널**: arXiv · 프리프린트
- **최초 공개일**: 2023년 9월 27일
- **등록일**: 2026년 11월 6일
- **수정일**: 2023년 9월 27일
- **버전**: v1
- **arXiv**: 2309.16021
- **분류**: cs.CR
- **원문 이용 조건**: [CC BY 4.0](https://creativecommons.org/licenses/by/4.0/)
- **제공 범위**: 논문 정보, 해설, 허용된 원문 그림

[논문 원문 ↗](https://arxiv.org/abs/2309.16021v1) · [원문 PDF ↗](https://arxiv.org/pdf/2309.16021v1)

AI 해설은 논문 원문과 별개의 설명이며 오류가 있을 수 있습니다. 원문과 그림은 각 출처의 이용 조건과 따로 표시된 권리를 따릅니다.

## 초록

Machine learning (ML) is crucial in network anomaly detection for proactive threat hunting, reducing detection and response times significantly. However, challenges in model training, maintenance, and frequent false positives impact its acceptance and reliability. Explainable AI (XAI) attempts to mitigate these issues, allowing cybersecurity teams to assess AI-generated alerts with confidence, but has seen limited acceptance from incident responders. Large Language Models (LLMs) present a solution through discerning patterns in extensive information and adapting to different functional requirements. We present HuntGPT, a specialized intrusion detection dashboard applying a Random Forest classifier using the KDD99 dataset, integrating XAI frameworks like SHAP and Lime for user-friendly and intuitive model interaction, and combined with a GPT-3.5 Turbo, it delivers threats in an understandable format. The paper delves into the system's architecture, components, and technical accuracy, assessed through Certified Information Security Manager (CISM) Practice Exams, evaluating response quality across six metrics. The results demonstrate that conversational agents, supported by LLM and integrated with XAI, provide robust, explainable, and actionable AI solutions in intrusion detection, enhancing user understanding and interactive experience.

## 원문 인용

Tarek Ali, Panos Kostakos (2023). HuntGPT: Integrating Machine Learning-Based Anomaly Detection and Explainable AI with Large Language Models (LLMs). arXiv:2309.16021v1. https://arxiv.org/abs/2309.16021v1

**BibTeX**

```
@misc{ali2023huntgpt,
  title = {{HuntGPT: Integrating Machine Learning-Based Anomaly Detection and Explainable AI with Large Language Models (LLMs)}},
  author = {Tarek Ali and Panos Kostakos},
  year = {2023},
  eprint = {2309.16021},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2309.16021v1}
}
```

## 이 논문의 용어

- [random forest](https://refivu.com/terms/e69b7b54f2ea-random-forest)
- [LIME](https://refivu.com/terms/b95eeaba5517-lime)
- [SHAP](https://refivu.com/terms/24f6f151db7b-shap)
- [prompt engineering](https://refivu.com/terms/fd335dee5f48-prompt-engineering)
- [Explainable Artificial Intelligence](https://refivu.com/terms/6595d9c6e939-explainable-artificial-intelligence)
- [GPT-3.5 Turbo](https://refivu.com/terms/f4f556eed8a4-gpt-3-5-turbo)
- [Random Forest classifier](https://refivu.com/terms/1cccdc65ae1b-random-forest-classifier)

## 다른 논문 해설

- [Using large language models to estimate features of multi-word expressions: Concreteness, valence, arousal](https://refivu.com/papers/76fd510f-cd7e-4a68-b362-5c8cca20383a-using-large-language-models-to-estimate-features-of.md)
- [Strong and weak alignment of large language models with human values](https://refivu.com/papers/be542b1a-1c29-4f81-beba-ffa28ae6b9f7-strong-and-weak-alignment-of-large-language-models.md)
- [Dr.ICL: Demonstration-Retrieved In-context Learning](https://refivu.com/papers/996dd357-1e54-4c56-bfef-88bcdef0091c-dr-icl-demonstration-retrieved-in-context-learning.md)
- [Large Language Model-Based Uncertainty-Adjusted Label Extraction for Artificial Intelligence Model Development in Upper Extremity Radiography](https://refivu.com/papers/9b222a13-ea6f-4ce3-a329-e7ff28964ff8-large-language-model-based-uncertainty-adjusted-label.md)
- [Unlocking the Archives: Using Large Language Models to Transcribe Handwritten Historical Documents](https://refivu.com/papers/c3f9b9b5-8145-4837-9b3e-abaf5cbfb22c-unlocking-the-archives-using-large-language-models-to.md)
- [Can Large Language Models Transform Natural Language Intent into Formal Method Postconditions?](https://refivu.com/papers/cfece4bb-1558-4163-9369-9dfea374f585-can-large-language-models-transform-natural-language-intent.md)
- [Continuous Conversion of CT Kernel using Switchable CycleGAN with AdaIN](https://refivu.com/papers/15f89611-02ff-4ffe-86b6-6a369bb11661-continuous-conversion-of-ct-kernel-using-switchable-cyclegan.md)
- [Deep Reinforcement Learning Methods for Structure-Guided Processing Path Optimization](https://refivu.com/papers/432340c2-ee29-488c-86a4-095d41711ed7-deep-reinforcement-learning-methods-for-structure-guided.md)
- [Empirical evaluation of shallow and deep learning classifiers for Arabic sentiment analysis](https://refivu.com/papers/bffda9e3-7999-4193-a8cd-36c792c00699-empirical-evaluation-of-shallow-and-deep-learning.md)
- [ZEST: Zero-shot Embodied Skill Transfer for Athletic Robot Control](https://refivu.com/papers/d6e1613f-167f-42f6-baf5-606ceb337d9a-zest-zero-shot-embodied-skill-transfer-for-athletic.md)
- [IoT-based Android Malware Detection Using Graph Neural Network With Adversarial Defense](https://refivu.com/papers/795f8668-0ca1-4227-882e-927a6073e094-iot-based-android-malware-detection-using-graph-neural.md)
- [FICE: Text-Conditioned Fashion Image Editing With Guided GAN Inversion](https://refivu.com/papers/791b37e6-1721-4c3f-b4b7-7e15c64acff2-fice-text-conditioned-fashion-image-editing-with-guided.md)

---

AI 해설에는 오류가 있을 수 있습니다. [Refivu](https://refivu.com/papers/b050833e-0d12-4b4b-b5d8-471ef2df91cb-huntgpt-integrating-machine-learning-based-anomaly-detection)
