liveBook · Manning

Matrix factorization

As explained in AI-Powered Search

Matrix factorization is a mathematical technique that decomposes a user-item interaction matrix into lower-dimensional factors representing users, latent attributes, and items.

Matrix factorization decomposes a user-item interaction matrix into a user matrix and an item matrix. Their lower-dimensional values represent latent factors inferred from clicks, purchases, ratings, or other positive interactions, making hidden preferences and item similarities easier to generalize. section 4.2.3 section 9.3.1

Let R represent observed preferences, U represent users across latent factors, and I represent items across those factors. The product U · I should approximate R. Multiplying corresponding user and item factor values and summing them produces a predicted preference, including for an originally empty matrix cell. section 9.3.1

A collaborative-filtering pipeline can use matrix factorization to:

  • Compress many sparse interaction signals into a smaller set of meaningful latent dimensions. section 4.2.3
  • Infer preferences for items that a user has not interacted with directly. section 9.3.1
  • Match documents or products through latent attributes associated with shared user interests. section 4.2.3

Movie and product patterns

Purchase histories can reveal groups without exposing product descriptions. Users who buy superhero films may induce factors related to action, Marvel or DC properties, or adult content; other users may induce animated, Disney/Pixar, or child-friendly factors. Similarly, appliance purchases can reveal a color preference, while electronics purchases can separate entertainment systems from smartphone accessories. section 9.3.1

Figure 9.7 Matrix factorization. The user-item matrix R is decomposed into two matrices, a user matrix U and an item matrix I. The product of these two matrices (U . I) should be as close as possible to the original user-item matrix R.
figure

Use the decomposition diagram to inspect how the original interaction matrix becomes user and item factor matrices. section 9.3.1

How AI-Powered Search covers it

How deep it goes
Defines matrix decomposition, latent factors, dot-product prediction, and reconstruction, but does not detail model-training procedures.
Examples
Uses movie purchases, appliance colors, entertainment systems, smartphones, and reconstructed preference matrices.
What it assumes
Assumes user-item interaction data and teaches latent features from product IDs without requiring item descriptions.
What you can do after
Apply it to infer unseen user-item preferences and discover item similarities from sparse interaction signals.
How it connects
Connects collaborative filtering, user-item interaction matrices, latent features, dimensionality reduction, item similarity, and cold start.

Also explained in

Compare how 2 books explain matrix factorization →

Related concepts

This explainer was generated by Manning's knowledge graph from the text of AI-Powered Search. The section links point to the parts of the book it draws on.