Skip to content
AI Engineer Guide.

Cosine similarity

Move two vectors and watch the angle. Magnitude is irrelevant; direction is the signal.

AB
Cosine
0.707
Angle
45°

Cosine ignores magnitude. Move A along its own direction and the score does not change; rotate it and the score does.

Related: Similarity metrics