1Z0-184-25 Question 15
Single answerYou are implementing an AI-driven recommendation engine on Oracle Cloud Infrastructure (OCI) for image embeddings stored in a vector index. Your team has normalized all of the image embeddings to unit length to ensure consistent magnitude. Which distance metric is generally recommended to accurately capture the similarity of these normalized vectors based on their angular difference?
- A
Use Euclidean (L2) distance for computing the distance between the embeddings
- B
Use Cosine similarity (or distance) to compare angle-based similarity
- C
Use Dot Product distance for handling normalized embeddings
- D
Use Manhattan (L1) distance to measure vector similarity
Show answer and explanation
Correct answer: B
Explanation
When vectors are normalized to unit length, the angle between them becomes especially significant for similarity searches. Cosine similarity or the associated cosine distance best reflects the directional closeness of these vectors. This aligns with common AI and machine learning best practices for handling normalized embeddings, and it is well-supported by OCI� vector search capabilities for tasks such as semantic text or image similarity. Refer to Oracle documentation on �Vector Search and Indexing� within Oracle Database and AI Services for further guidance on choosing the right distance metric.
- A. Incorrect.
Euclidean distance measures the direct line distance between two points in the embedding space. Although it can be used for vector similarity, it does not directly capture the angle between normalized vectors, which is often a better measure of semantic or visual similarity.
- B. Correct.
Cosine similarity (or its distance equivalent) is typically preferred for normalized embeddings because it focuses on the angle between vectors, rather than their magnitude. Since your team has normalized all vectors, this metric accurately captures how similar they are in direction, reflecting semantic or visual similarity.
- C. Incorrect.
Dot Product can be used for measuring similarity, but it is more sensitive to vector magnitude. While normalized embeddings reduce some magnitude effects, cosine-based distance functions generally provide a more standard measure of angular similarity.
- D. Incorrect.
Manhattan distance measures the absolute difference across dimensions. Although it can be applied to vector data, it is not as commonly used for normalized embeddings when the primary interest is the angular relationship between vectors.