[son of anton]
Recommendation & search

Representation learning

item embeddings, image–text retrieval, similarity search

Learn a vector space where distance means similarity, to power retrieval, matching, and downstream models.

Linear algebra
Information theory
Optimisation
Foundations
Inner products, projections, and the geometry of high-dimensional spaces; InfoNCE is a mutual-information bound.
Frame the problem
Frame
Define what similar means and who consumes the space: retrieval, clustering, or a downstream model. That decides the loss and the evaluation.
Sourcing & signal
Labeling & data collection
Data & labels
Positive pairs come from co-occurrence, clicks, captions, or augmentation. Negatives are usually sampled, and how you sample them is the design.
Modalities → vectors
Tokenization
Embedding layers
word2vec & GloVebackground
Represent
One encoder per modality. Ids as embedding tables; text and images through pretrained encoders.
Split the data
Split
By entity. Hold out pairs whose entities appear on neither side of training if you need generalisation to new items.
Dumb baseline
Dimensionality reduction
Matrix factorization
Attention & transformersbackground
Contrastive training
Siamese or two-tower with in-batch negatives; hard negatives once the easy ones are solved.
Metric learning
Two-tower retrieval & ANN
Pretrained and multimodal
CLIP-style image–text spaces; sentence encoders from masked or contrastive pretraining.
Vision transformers & CLIP
Masked & contrastive pretraining
Model
PCA or SVD over co-occurrence, or matrix factorization, is the baseline embedding.
Loss functions
Training craft
Fine-tuning a pretrained model
Train
Triplet, InfoNCE, or sampled softmax. Temperature and batch size matter more than depth.
Embedding geometry & retrieval eval
Ranking & recsys metrics
Evaluate offline
Recall@k on held-out pairs. Check anisotropy and hubness; a space can score well and still collapse.
A/B testing & interleaving
Evaluate online
Measured through whatever consumes it: a retrieval A/B, or downstream model lift.
Serving & release
Inference optimisation
Ship & monitor
Version the space: a retrained encoder invalidates every stored vector. Plan the re-index.
Mini Map