Classical ML Algorithms
4 of 10 LiveFirst-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.
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.
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.
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.
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.
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.
Problem & Generative / Discriminative Framing
What distribution is modeled, what independence assumptions are made, and why naive baselines break.
Scoring & Potential Machinery
Interactive parameter matrices, margins, or impurity scores—click any cell to inspect its inputs.
From Raw Scores to Probabilities
Exact normalization (partition function Z(x), softmax, Bayes rule, log-space forward-backward).
Inference & Decoding
Step-by-step DP / decision path (Viterbi, tree traversal, kernel evaluation) vs. greedy baselines.
Training & Optimization
How parameters are learned (L-BFGS, SMO, EM, Newton-Raphson / second-order GBDT splits).
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.
Generative · Conditional independence, Laplace smoothing, log-odds
Discriminative · Cross-entropy, log-odds geometry, IRLS / Newton-Raphson
Generative Sequence · Joint P(x, y), Forward-Backward, Viterbi, Baum-Welch EM
Discriminative Sequence · Log-potentials, Z(x), Forward-Backward, Viterbi, L-BFGS
Primal/dual margins, KKT conditions, kernels, SMO
Gini vs. entropy, information gain, pruning
Bootstrap aggregating, feature subsampling, variance reduction
Pseudo-residuals, 2nd-order Taylor gain, shrinkage
Latent responsibilities, E-step / M-step ELBO
Covariance eigendecomposition, SVD, variance projection