Algorithm Library
Detailed pages for each algorithm and a live comparison table that runs algorithms on synthetic data and measures performance in your browser.
- 37Items
Algorithms
Supervised Learning (6)
Logistic regression
Estimates the probability that a sample is an attack with a sigmoid over a weighted sum of features, trained by gradient descent on cross-entropy loss.
Detailsk-Nearest Neighbours
Labels a sample by the majority of its k nearest training neighbours under Euclidean distance after scaling.
DetailsGaussian Naive Bayes
Assumes features are conditionally independent given the class and Gaussian, then applies Bayes’ rule.
DetailsDecision tree
Splits the space with successive threshold rules, choosing at each node the split that reduces Gini impurity most.
DetailsLinear SVM (Pegasos)
Finds a maximum-margin separating hyperplane, trained here with Pegasos stochastic gradient descent on the hinge loss.
DetailsFlow feature engineering
Turning packets into flow records with features such as duration, bytes, SYN ratio, ports and entropy.
DetailsNLP Models (5)
Multinomial Naive Bayes
Models word counts per class and applies Bayes’ rule; the traditional choice for short-text classification.
DetailsTF-IDF
Weights a word by its frequency in the document and its rarity across documents, so distinctive words stand out.
DetailsURL lexical features
Analysing the URL as characters: length, dots, symbols, “@”, path depth and domain entropy, with no connection.
DetailsWord embeddings
Represent words as dense vectors placing similar meanings near each other.
DetailsBERT and DistilBERT
Transformer language models fine-tuned for text classification; DistilBERT is a smaller, faster distilled version.
DetailsEnsemble Learning (4)
Random forest
Builds many decision trees on bootstrap samples and random feature subsets, then votes or averages their probabilities.
DetailsGradient boosting (simplified)
Adds small trees sequentially, each correcting the errors of the ensemble so far with a step along the loss gradient.
DetailsXGBoost
An optimised gradient-boosted-trees implementation with explicit regularisation; very common on tabular data.
DetailsLightGBM
Gradient-boosted trees growing leaf-wise and using feature bundling for faster training.
DetailsDeep Learning (6)
Multi-layer perceptron (MLP)
Layers of non-linear units learning intermediate representations by back-propagation; here a small network with one hidden layer.
Details1-D convolutional networks
Applies convolutional filters over a sequence (bytes/packets) to extract local patterns.
DetailsSequence networks (LSTM/GRU)
Keeps an internal memory across an event sequence to learn what is normal and flag deviation.
DetailsTransformers for text
Use self-attention to represent word context and serve in email and report classification.
DetailsVariational autoencoder (VAE)
A probabilistic autoencoder learning a latent distribution; likelihood or reconstruction error serves as the anomaly score.
DetailsLSTM autoencoder
Compresses a time sequence with LSTM units and reconstructs it; a large reconstruction error signals an unusual sequence.
DetailsUnsupervised Learning (5)
Isolation Forest
Isolates points with random splits; anomalies are isolated with fewer splits, so shortness of the average path length measures anomaly.
DetailsLocal Outlier Factor (LOF)
Compares a point’s local density with that of its neighbours; a point sparser than its neighbours gets a higher score.
DetailsDBSCAN
Groups dense points into clusters and treats points far from every cluster as noise/anomalies.
DetailsK-means (distance to centroid)
Clusters data into k groups; points far from the nearest centroid are treated as anomalous.
DetailsAutoencoder
A network that compresses the input to a small code and reconstructs it; a large reconstruction error signals an unseen pattern.
DetailsSemi-Supervised Learning (1)
One-class SVM (random Fourier features)
Learns a boundary around normal data; implemented here as a Gaussian-kernel approximation with random Fourier features and SGD training.
DetailsRule-based and statistical (non-learning; extra to the eight) (6)
Robust z-score
Measures distance from the median in units of the median absolute deviation (MAD) so the statistics are not distorted by the outliers themselves.
DetailsRules and thresholds (sliding window)
Counts events (such as failed logins) in a sliding time window and alerts above a threshold.
DetailsIndicator risk scoring (weighted sum)
Combines factors such as reliability, sightings, recency, asset value and campaign with analyst-set weights.
DetailsIncident priority scoring
Ranks incidents by severity, asset value and detection confidence and compares them with a simple manual order.
DetailsDGA detection with entropy and lexical features
Measures a domain name’s entropy, length and digit ratio; algorithmically generated names are usually more random. Compared with learned models.
DetailsHandling class imbalance
Attacks are usually rare; handle it with recall, PR-AUC, re-weighting and threshold tuning instead of accuracy.
DetailsExplainable AI (2)
Permutation importance
Measures the drop in performance when one feature’s values are shuffled, showing how much the model depends on it.
DetailsShapley values (Monte-Carlo estimate)
Distributes the gap between a prediction and a baseline over features as the average marginal contribution over random orderings. A SHAP-style estimate, not the SHAP library.
DetailsGraph Neural Networks (2)
Node-degree anomaly in a communication graph
Counts how many peers each host talks to and flags those whose degree exceeds the mean by several standard deviations.
DetailsGraph neural networks in security
Passes messages between neighbouring nodes to learn a representation of each host or event from its graph context.
DetailsNo matching entries.
