Skip to main content

Classical ML Algorithms

4 of 10 Live

First-principles deep dives into the probability math, transition mechanics, inference algorithms, and optimization loops behind classical machine learning. Built to go beyond static slide decks with live numeric walkthroughs.

Classical MLeasy15 min

Naive Bayes: Generative Priors, Laplace Smoothing & Log-Odds

Deep-dive into Multinomial Naive Bayes: how class priors and conditional word likelihoods multiply via Bayes' rule, why unseen words collapse probabilities without Laplace smoothing, and how correlated features cause double-counting.

generative classifierbayes rulelaplace smoothinglog-oddsconditional independence
Open Deep Dive
Classical MLeasy15 min

Logistic Regression: Log-Odds Geometry, Cross-Entropy & IRLS

Deep-dive into binary Logistic Regression: how linear logits map to calibrated probabilities via the sigmoid, why Binary Cross-Entropy is convex, and how second-order IRLS (Newton-Raphson) outpaces Gradient Descent.

discriminative classifierlog-oddsbinary cross-entropyl2 regularizationirls newton-raphson
Open Deep Dive
Classical MLhard20 min

Hidden Markov Models (HMM): Generative Sequences, Viterbi & Baum-Welch

Deep-dive into Hidden Markov Models: how row-stochastic initial, transition, and emission probabilities define P(O, Q), how Forward-Backward computes data likelihood P(O | λ), and how Baum-Welch EM learns without labels.

generative sequence modelmarkov chainviterbi decodingforward-backwardbaum-welch em
Open Deep Dive
Classical MLhard20 min

Conditional Random Fields (CRF): Potentials, Z(x), Viterbi & L-BFGS

Deep-dive into linear-chain CRFs: how emission and transition log-potentials combine, how Forward-Backward computes the partition function Z(x), how Viterbi decodes the global MAP sequence, and how L-BFGS learns weights.

discriminative sequence modellog-potentialspartition function Z(x)forward-backwardviterbi decodingl-bfgs optimization
Open Deep Dive

Standardized 6-Part Study Blueprint

Every module in this series follows the same six-part analytical structure so you can compare how different models score, normalize, infer, and train.

01

Problem & Generative / Discriminative Framing

What distribution is modeled, what independence assumptions are made, and why naive baselines break.

02

Scoring & Potential Machinery

Interactive parameter matrices, margins, or impurity scores—click any cell to inspect its inputs.

03

From Raw Scores to Probabilities

Exact normalization (partition function Z(x), softmax, Bayes rule, log-space forward-backward).

04

Inference & Decoding

Step-by-step DP / decision path (Viterbi, tree traversal, kernel evaluation) vs. greedy baselines.

05

Training & Optimization

How parameters are learned (L-BFGS, SMO, EM, Newton-Raphson / second-order GBDT splits).

06

Comparison & Failure Modes

Side-by-side contrasts with neighboring models (e.g., HMM vs. MEMM vs. CRF) and complexity bounds.

Series Roadmap (10 Classical Algorithms)

Planned sequence of interactive deep dives covering probabilistic sequence models, linear/kernel classifiers, tree ensembles, and unsupervised methods.

01
Naive Bayes

Generative · Conditional independence, Laplace smoothing, log-odds

Live
02
Logistic Regression

Discriminative · Cross-entropy, log-odds geometry, IRLS / Newton-Raphson

Live
03
Hidden Markov Models (HMM)

Generative Sequence · Joint P(x, y), Forward-Backward, Viterbi, Baum-Welch EM

Live
04
Conditional Random Fields (CRF)

Discriminative Sequence · Log-potentials, Z(x), Forward-Backward, Viterbi, L-BFGS

Live
05
Support Vector Machines (SVM)

Primal/dual margins, KKT conditions, kernels, SMO

Planned
06
Decision Trees (CART)

Gini vs. entropy, information gain, pruning

Planned
07
Random Forests

Bootstrap aggregating, feature subsampling, variance reduction

Planned
08
Gradient Boosted Trees (GBDT / XGBoost)

Pseudo-residuals, 2nd-order Taylor gain, shrinkage

Planned
09
Gaussian Mixture Models & EM

Latent responsibilities, E-step / M-step ELBO

Planned
10
Principal Component Analysis (PCA)

Covariance eigendecomposition, SVD, variance projection

Planned