0
0
Prompt Engineering / GenAIml~5 mins

Vector similarity metrics in Prompt Engineering / GenAI - Cheat Sheet & Quick Revision

Choose your learning style9 modes available
Recall & Review
beginner
What is the purpose of vector similarity metrics in machine learning?
Vector similarity metrics measure how alike two vectors are. They help compare data points, like checking if two images or texts are similar.
Click to reveal answer
beginner
Explain Cosine Similarity in simple terms.
Cosine Similarity measures the angle between two vectors. If the angle is small, the vectors are similar. It ignores their length and focuses on direction.
Click to reveal answer
beginner
What is Euclidean Distance and how does it relate to similarity?
Euclidean Distance is the straight-line distance between two points (vectors). Smaller distance means higher similarity, bigger distance means less similar.
Click to reveal answer
intermediate
How does Jaccard Similarity work for comparing vectors?
Jaccard Similarity compares two sets by dividing the size of their overlap by the size of their union. For vectors, it measures how many features they share compared to total features.
Click to reveal answer
intermediate
Why might you choose Cosine Similarity over Euclidean Distance?
Cosine Similarity focuses on direction, ignoring length, which is useful when magnitude varies but pattern matters. Euclidean Distance considers magnitude, which can be misleading if scale differs.
Click to reveal answer
Which metric measures the angle between two vectors?
ACosine Similarity
BEuclidean Distance
CJaccard Similarity
DManhattan Distance
If two vectors have a Euclidean distance of zero, what does that mean?
AThey are identical
BThey are completely different
CThey have no features
DThey have opposite directions
Jaccard Similarity is best used for comparing:
AAngles between vectors
BContinuous numeric vectors
CDistances in 3D space
DSets or binary vectors
Which similarity metric ignores the length of vectors and focuses on direction?
AEuclidean Distance
BHamming Distance
CCosine Similarity
DJaccard Similarity
A higher Euclidean distance between two vectors means:
AThey are more similar
BThey are less similar
CThey have the same direction
DThey have identical features
Describe three common vector similarity metrics and when you might use each.
Think about what each metric focuses on: angle, distance, or overlap.
You got /3 concepts.
    Explain why choosing the right similarity metric matters in machine learning tasks.
    Consider how data features and scale affect similarity.
    You got /3 concepts.