SWAVLAMBAN 2025 - Naval Innovathon Hackathon
AI-powered network intrusion detection using Mamba-2 deep learning architecture.
| Metric | Value |
|---|---|
| Detection Rate | 99.4% |
| False Positive Rate | 15.6% |
| Inference Latency | < 10ms |
# Clone and enter directory
cd naval-ai-ids
# Create virtual environment
python -m venv venv
# Activate (Windows)
.\venv\Scripts\activate
# Activate (Linux/Mac)
source venv/bin/activate
# Install dependencies
pip install -r requirements.txt
# Install PyTorch with CUDA (adjust for your CUDA version)
pip install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cu121# Copy example and add your Groq API key
copy .env.example .env
# Edit .env and add your GROQ_API_KEYGet free API key at: https://console.groq.com
streamlit run src/app.py --server.port 8513# In separate terminal
python src/simulator.py --count 50 --speed 2├── src/
│ ├── app.py # Main dashboard (Streamlit)
│ ├── inference_engine.py # GPU inference engine
│ ├── mamba_model.py # Mamba-2 autoencoder architecture
│ ├── genai_rules.py # AI rule generation (Groq/Llama-3)
│ ├── feedback_system.py # Continuous learning
│ ├── simulator.py # Traffic simulator
│ └── csv_preprocessor.py # Data preprocessing
├── models/
│ ├── mamba_enhanced.pth # Trained model weights
│ └── threshold_enhanced.npy # Detection threshold
├── data/
│ └── *.csv # CIC-IDS2017 dataset
├── requirements.txt
└── README.md
┌─────────────────────────────────────────┐
│ MAMBA-2 ANOMALY DETECTOR │
│ (GPU-Accelerated) │
│ │
│ • Trained on NORMAL traffic only │
│ • Reconstruction error = anomaly score │
│ • score > threshold → ATTACK │
└─────────────────────────────────────────┘
One-Class Classification: Model learns normal patterns. Attacks produce high reconstruction error → detected.
- 🔥 Real-time Detection - GPU-accelerated Mamba-2 model
- 🤖 AI Rule Generation - Llama-3 generates WAF rules via Groq API
- 📊 Live Dashboard - Streamlit-based command center
- 🔄 Continuous Learning - Feedback system improves accuracy
- 📈 XAI Explanations - Gradient-based feature importance
- Python 3.10+
- NVIDIA GPU with CUDA support
- 6GB+ VRAM recommended
Naval Innovathon 2025 - Challenge 3