CoolFace
Apppublic

akanksham23/ai-network-intrusion-detection

sourceHugging Faceupdated 9mo agoView on Hugging Face
0likes
App README

πŸ›‘οΈ AI-Based Network Intrusion Detection System (AI-NIDS)

An AI-powered Network Intrusion Detection System that combines Machine Learning (Random Forest) with Generative AI (Groq LLM) to detect, analyze, and explain network attacks, focusing on DDoS traffic from the CIC-IDS2017 dataset.

This project is designed for cybersecurity students to understand how traditional ML and modern LLMs can work together in Security Operations Centers (SOC).


πŸš€ How to Use

  1. 1.Enter Groq API Key (Optional) Add your Groq API key in the sidebar to enable AI-based explanations.
  1. 1.Train the AI Model Click β€œTrain AI Model”. The app automatically loads the CIC-IDS2017 DDoS dataset.
  1. 1.Simulate Network Traffic Click β€œSimulate Random Packet” to analyze a real network flow.
  1. 1.Analyze Results
  2. 2.Detects whether traffic is BENIGN or DDoS
  3. 3.Displays confidence score
  4. 4.Uses Groq AI to explain why the packet was classified as such

🧠 Key Features

  • β€”βœ… Random Forest–based intrusion detection
  • β€”πŸ“Š Feature importance visualization
  • β€”πŸ“ˆ Accuracy & performance metrics
  • β€”πŸŽ― Live packet simulation
  • β€”πŸ€– LLM-based attack explanation (Groq)
  • β€”πŸ›‘οΈ SOC-style security reasoning
  • β€”πŸŽ“ Student-friendly explanations

πŸ“‚ Project Structure

<pre> AI-Based Network Intrusion Detection System β”œβ”€β”€ app.py β”œβ”€β”€ requirements.txt β”œβ”€β”€ Friday-WorkingHours-Afternoon-DDos.pcap_ISCX.csv └── README.md </pre>

πŸ“„ File Details

  • β€”app.py – Streamlit application code
  • β€”requirements.txt – Python dependencies
  • β€”CSV Dataset – CIC-IDS2017 DDoS traffic subset

πŸ“Š Dataset Used

  • β€”CIC-IDS2017
  • β€”Realistic labeled network traffic
  • β€”Industry-standard dataset for IDS research

πŸŽ“ Learning Outcomes

  • β€”Understand ML-based intrusion detection
  • β€”Interpret network traffic features
  • β€”Apply explainable AI in cybersecurity
  • β€”Bridge ML detection with SOC decision-making
  • β€”Gain hands-on experience with Streamlit dashboards

πŸ§ͺ Future Enhancements

  • β€”Real-time PCAP capture
  • β€”Anomaly-based zero-day detection
  • β€”Deep Learning (LSTM / Autoencoders)
  • β€”MITRE ATT&CK mapping
  • β€”PDF attack reports

πŸ‘©β€πŸ’» Author

Akanksha Vikas Mane BE IT | AI-Driven Security Research


⚠️ Disclaimer

This project is for educational and research purposes only. Not intended for direct production deployment.