Skip to content

๐Ÿ›ก๏ธ MIL SHIELD: Advanced AI-powered cybersecurity platform for Army & Defense operations. Combines ML models (Random Forest + Autoencoder) with LLM reasoning for real-time threat detection and intelligent response. Built for NexTech Hackathon @ NMIET with 96.8% accuracy in network anomaly detection.

Notifications You must be signed in to change notification settings

mohitksahu/NexTechHackathon-TeamEdgeHackers

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

5 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

๐Ÿ›ก๏ธ MIL SHIELD - NexTech Hackathon @ NMIET: TeamEdgeHackers

An Advanced Military-Grade Network Security System for Army & Defense - Powered by Machine Learning & Large Language Models

Python TensorFlow Streamlit License

๐ŸŽฏ Project Overview

MIL SHIELD is an intelligent cybersecurity platform designed specifically for Army and Defense operations, combining traditional machine learning models with cutting-edge Large Language Model (LLM) reasoning to provide real-time network threat detection and automated response capabilities. Developed for the NexTech Hackathon at NMIET (Narsee Monjee Institute of Engineering and Technology), this system represents the next generation of military-grade network security tailored for defense infrastructure protection.

๐ŸŒŸ Key Features

  • Military-Grade Security: Multi-layered AI defense combining Random Forest, Autoencoder, and LLM models
  • Real-time Threat Detection: Live network monitoring with instant alerts for defense operations
  • Intelligent Decision Making: AI-powered response recommendations for military scenarios
  • Visual Attack Simulation: Interactive camera-based attack scenarios for training purposes
  • Command & Control Dashboard: Military-style Streamlit interface for monitoring operations
  • Comprehensive Analytics: Detailed visualization and threat intelligence reporting
  • Field-Ready Deployment: Optimized for edge computing in defense environments
  • Secure Communication: Built for classified network environments
  • Threat Intelligence: Advanced pattern recognition for emerging cyber threats

๐Ÿ“ Project Structure

๐Ÿ“ฆ NexTechHackathon-TeamEdgeHackers/
โ”œโ”€โ”€ ๐Ÿค– modelTraining/              # Core ML model development
โ”‚   โ”œโ”€โ”€ models/                    # Model architectures
โ”‚   โ”œโ”€โ”€ preprocessing/             # Data preprocessing pipeline
โ”‚   โ”œโ”€โ”€ training_scripts/          # Training workflows
โ”‚   โ”œโ”€โ”€ data/                      # Datasets and processed data
โ”‚   โ”œโ”€โ”€ exports/                   # Trained models and scalers
โ”‚   โ”œโ”€โ”€ visualization/             # Model performance visualizations
โ”‚   โ””โ”€โ”€ gui-streamlit.py          # Interactive dashboard
โ”‚
โ”œโ”€โ”€ ๐ŸŽฏ attack/                     # Attack simulation environment
โ”‚   โ”œโ”€โ”€ index4.py                 # Advanced PyQt5 attack simulator
โ”‚   โ”œโ”€โ”€ stream.py                 # Webcam streaming server
โ”‚   โ”œโ”€โ”€ attack_data_exporter.py   # Attack data generation
โ”‚   โ””โ”€โ”€ data/                     # Attack scenario datasets
โ”‚
โ”œโ”€โ”€ ๐Ÿง  modelPlusLLMPrediction/     # LLM-enhanced decision system
โ”‚   โ”œโ”€โ”€ src/                      # Core system modules
โ”‚   โ”‚   โ”œโ”€โ”€ core/                 # Decision making engines
โ”‚   โ”‚   โ”œโ”€โ”€ network_io/           # Network event handling
โ”‚   โ”‚   โ””โ”€โ”€ utils/                # Utility functions
โ”‚   โ”œโ”€โ”€ configs/                  # Configuration files
โ”‚   โ”œโ”€โ”€ models/                   # Pre-trained model storage
โ”‚   โ”œโ”€โ”€ scripts/                  # Deployment scripts
โ”‚   โ””โ”€โ”€ final_demo.py            # Complete system demonstration
โ”‚
โ””โ”€โ”€ ๐Ÿ“‹ Configuration Files
    โ”œโ”€โ”€ .gitignore               # Git ignore patterns
    โ””โ”€โ”€ README.md               # This file

๐Ÿš€ Quick Start Guide

Prerequisites

  • Python 3.8+ with pip
  • NVIDIA GPU with CUDA support (for LLM inference)
  • Webcam (for attack simulation)
  • Windows 10/11 or Linux

1๏ธโƒฃ Environment Setup

# Clone the repository
git clone https://github.com/mohitksahu/NexTechHackathon-TeamEdgeHackers.git
cd NexTechHackathon-TeamEdgeHackers

# Create virtual environment
python -m venv .venv

# Activate environment (Windows)
.venv\Scripts\activate
# Or on Linux/Mac
source .venv/bin/activate

2๏ธโƒฃ Install Dependencies

# Install model training dependencies
cd modelTraining
pip install -r requirements.txt

# Install LLM prediction system
cd ../modelPlusLLMPrediction
pip install -r requirements.txt

# Install attack simulation tools
cd ../attack
pip install -r req.txt

3๏ธโƒฃ Launch the System

Option A: Interactive Dashboard

cd modelTraining
streamlit run gui-streamlit.py

Option B: LLM-Enhanced Analysis

cd modelPlusLLMPrediction
python final_demo.py

Option C: Attack Simulation

cd attack
python index4.py  # Launch PyQt5 simulator
# Or
python stream.py  # Start webcam streaming

๐ŸŽฎ Usage Examples

๐Ÿ“Š CyberAttack Dashboard

The interactive dashboard provides real-time monitoring capabilities:

  1. Download Network Logs: CSV files with network traffic data
  2. Real-time Analysis: Live threat detection with ML models
  3. Visualization: Interactive charts and attack pattern analysis
  4. Alert System: Immediate notifications for detected threats

Dashboard Preview

๐Ÿค– LLM Decision Engine

The AI-powered decision system offers intelligent threat response:

# Example: Process a network event
from src.core.decision_maker import DecisionMaker

decision_maker = DecisionMaker()
result = decision_maker.process_event({
    "src_ip": "192.168.1.100",
    "dst_ip": "10.0.0.50",
    "protocol": "TCP",
    "threat_score": 0.85
})

print(f"Decision: {result['action']}")
print(f"Confidence: {result['confidence']}")
print(f"Reasoning: {result['explanation']}")

๐ŸŽฏ Attack Simulation

Interactive attack scenarios for testing:

  1. Camera-based Simulation: Visual attack pattern recognition
  2. Network Traffic Generation: Synthetic attack data creation
  3. Real-time Response Testing: Validate system responses

๐Ÿงช Model Performance

Model Accuracy Precision Recall F1-Score
Random Forest 94.2% 93.8% 94.1% 93.9%
Autoencoder 91.7% 90.5% 92.3% 91.4%
Hybrid System 96.8% 96.2% 96.5% 96.3%

๐Ÿ”ง Configuration

Model Training Settings

# modelTraining/config.yaml
random_forest:
  n_estimators: 100
  max_depth: 20
  random_state: 42

autoencoder:
  hidden_layers: [64, 32, 16, 32, 64]
  epochs: 100
  batch_size: 32

LLM Configuration

# modelPlusLLMPrediction/configs/llm_config.yaml
mode: local
model_name: microsoft/DialoGPT-medium
quantization: q4_0
context_window: 2048

๐Ÿ› ๏ธ Development

Adding New Models

  1. Create model class in modelTraining/models/
  2. Implement training script in training_scripts/
  3. Update preprocessing pipeline if needed
  4. Add visualization in visualization/

Extending LLM Capabilities

  1. Modify modelPlusLLMPrediction/src/core/llm_agent.py
  2. Update configuration in configs/llm_config.yaml
  3. Add new decision logic in decision_maker.py

Custom Attack Simulations

  1. Extend attack/index4.py with new scenarios
  2. Add data generation in attack_data_exporter.py
  3. Update visualization components

๐Ÿ“ˆ Performance Optimization

  • CUDA Acceleration: GPU-optimized inference
  • Model Quantization: 4-bit quantization for efficiency
  • Batch Processing: Optimized data pipeline
  • Memory Management: Efficient resource utilization

๐Ÿค Contributing

We welcome contributions! Please see our contributing guidelines:

  1. Fork the repository
  2. Create a feature branch (git checkout -b feature/amazing-feature)
  3. Commit your changes (git commit -m 'Add amazing feature')
  4. Push to the branch (git push origin feature/amazing-feature)
  5. Open a Pull Request

๐Ÿ“‹ Requirements

Core Dependencies

  • tensorflow>=2.17.0
  • scikit-learn>=1.5.1
  • pandas>=2.2.2
  • numpy>=1.26.4
  • streamlit
  • PyQt5
  • opencv-python

LLM Dependencies

  • torch
  • transformers
  • accelerate
  • bitsandbytes

๐Ÿ† Team EdgeHackers

๐Ÿ“„ License

This project is licensed under the MIT License - see the LICENSE file for details.

๐Ÿ™ Acknowledgments

๐Ÿ“ž Support

For questions and support:


๐Ÿ›ก๏ธ Defending the Nation with AI-Powered Intelligence ๐Ÿ‡ฎ๐Ÿ‡ณ

Built with โค๏ธ by Team EdgeHackers for NexTech Hackathon @ NMIET

"Securing Defense Networks, Protecting Our Forces"

About

๐Ÿ›ก๏ธ MIL SHIELD: Advanced AI-powered cybersecurity platform for Army & Defense operations. Combines ML models (Random Forest + Autoencoder) with LLM reasoning for real-time threat detection and intelligent response. Built for NexTech Hackathon @ NMIET with 96.8% accuracy in network anomaly detection.

Resources

Stars

Watchers

Forks