Berk/minilm-movie-genome
A SentenceTransformer that maps free text to a 256-dimensional
movie taste-profile vector. It is all-MiniLM-L6-v2 with a trained mapping
head appended, so encode returns a unit-length profile embedding instead
of a generic sentence embedding.
The profile axes are MovieLens tag-genome tags. A query and a movie point in similar directions when they share themes, so the dot product between two unit outputs is their thematic cosine similarity.
Usage
from sentence_transformers import SentenceTransformer
model = SentenceTransformer("Berk/minilm-movie-genome")
vec = model.encode("a bleak dystopian sci-fi thriller")
print(vec.shape) # (256,)
The mapping head uses only built-in sentence-transformers modules, so no extra code is required to load it.
How it was built
- Base model:
sentence-transformers/all-MiniLM-L6-v2(frozen). - Mapping head: a small MLP trained on cached MiniLM embeddings with an alignment loss (match each text to its movie's profile) plus a geometry loss (preserve pairwise similarity structure), with L2-normalized targets.
- Targets: MovieLens ml-25m tag-genome relevances, restricted to the 256 highest-variance tags, joined to TMDB plot overviews as the text side.
Full training and search code, including catalog encoding and hybrid filtering, is at https://github.com/bgokden/embedding-space-translation-example.
Data and limitations
This model is derived from MovieLens and TMDB data and is not endorsed by either; please observe their respective terms of use. The tag genome is a proxy for a movie's themes, and plot overviews do not always state them, so the mapping is approximate.