▶ Interactive Lab

Embedding Similarity (2D)

Place words in 2D embedding space; compute cosine similarity.

Advertisement
click and drag any word to move it
Words near each other = high cosine similarity. Drag to explore.

What you're seeing

Real embeddings live in 768-1536 dimensions. 2D versions (UMAP/t-SNE projections) preserve relative distances approximately.

Cosine similarity measures angle between vectors, ignoring magnitude. Standard for semantic similarity. Dot-product or L2 also used; cosine wins for length-invariance.

★ KEY TAKEAWAY
Cosine similarity = dot product of unit vectors = cosine of angle. Foundation of semantic search.
▶ WHAT TO TRY
  • Drag word vectors closer/farther.
  • Watch top-5 similar pairs change.
  • Normalizing makes magnitude irrelevant; only direction matters.