File size: 4,046 Bytes
7702e45 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 | ---
language:
- en
license: apache-2.0
tags:
- cybersecurity
- small-language-models
- ransomware-detection
- lateral-movement
- onnx
- int8
- edge-ai
pipeline_tag: text-classification
---
# EdgeShield: Dual-Stream Small Language Model Cybersecurity Framework
[](https://opensource.org/licenses/Apache-2.0)
[](https://github.com/graval/edgeshield)
[](https://www.kaggle.com/models/gauravr1/edgeshield-models)
EdgeShield is an edge-native cybersecurity framework that uses a decoupled dual-stream Small Language Model (SLM) architecture and tiered selective gating to intercept lateral movement (MITRE TA0008) and pre-encryption ransomware before cryptographic destruction begins.
---
## ๐๏ธ Architecture & Model Lineage
EdgeShield decouples host threat monitoring into two specialized streams:
1. **Stream A (LSA - Log Sequence Analyzer)**:
- **Backbone:** 44M parameter `microsoft/deberta-v3-small` with sliding-window attention ($K=3$) and Supervised Contrastive Loss.
- **Target:** High-fidelity authentication logs and host command sequences to detect stealthy lateral movement.
- **Formats:** PyTorch FP32 and Quantized INT8 ONNX (with AVX-VNNI acceleration).
2. **Stream B (BPD - Behavioral Pattern Detector)**:
- **Backbone:** Compact Transformer with Attention Threat Scoring Head.
- **Target:** Captures pre-encryption ransomware precursor indicators, defense evasion (T1562.001), and rapid file entropy variations.
- **Formats:** PyTorch FP32 and Quantized INT8 ONNX.
3. **Tiered Selective Gating Engine**:
- Two-stage filter (fast-path allowlist + Shannon file entropy triage).
- Operates in **48.55 μs**, discarding **94.75%** of benign telemetry with **100% attack pass-through** (0 drop misses).
---
## ๐บ๏ธ Repository Structure & Releases
| Tag / Revision | Milestone | Key Artifacts |
| :--- | :--- | :--- |
| **`v1.0-temscon`** | **IEEE TEMSCON-ASPAC 2026** (Oct 2026) | Baseline PyTorch FP32 weights for Stream A (`edgeshield_lsa`) and Stream B (`edgeshield_bpd`) |
| **`v2.0-int8-quantized` (`main`)** | **Extended Journal** | Quantized INT8 ONNX models (`edgeshield_lsa_int8.onnx`, `edgeshield_bpd_int8.onnx`) optimized for edge CPUs (<50 MB RAM, 15.30 ms latency) |
---
## ๐ Quick Usage (ONNX Runtime INT8)
```python
import onnxruntime as ort
import numpy as np
# Load quantized Stream A (LSA)
session = ort.InferenceSession("models/v2_int8/edgeshield_lsa_int8.onnx", providers=["CPUExecutionProvider"])
# Example dummy sequence input
input_ids = np.zeros((1, 128), dtype=np.int64)
attention_mask = np.ones((1, 128), dtype=np.int64)
outputs = session.run(None, {"input_ids": input_ids, "attention_mask": attention_mask})
logits = outputs[0]
print("Prediction logits:", logits)
```
---
## ๐ Citation
```bibtex
% 1. Accepted Conference Baseline
@inproceedings{raval2026edgeshield_temscon,
author = {Raval, Gauravkumar and Bhatt, Tejaskumar},
title = {{EdgeShield: Lightweight Dual-Stream Small Language Model Architecture for Pre-Encryption Ransomware Defense on Edge Devices}},
booktitle = {Proceedings of the 5th IEEE Technology and Engineering Management Conference - Asia Pacific (TEMSCON-ASPAC)},
year = {2026},
note = {Accepted and In Press}
}
% 2. Extended Framework & Deployment Benchmarks
@article{raval2026edgeshield_journal,
author = {Raval, Gauravkumar and Bhatt, Tejaskumar},
title = {{EdgeShield: A High-Throughput Edge-Native Small Language Model Architecture for Pre-Encryption Ransomware Early Warning and Lateral Movement Interception}},
journal = {Target Journal: TBD (Manuscript in Preparation)},
year = {2026},
note = {Under Submission / Pre-submission Draft}
}
```
## ๐ฅ Authors
- **Gauravkumar Raval** (GLS University)
- **Dr. Tejaskumar Bhatt** (GLS University)
|