Back to Course
LLM Engineering: Transformers & RAG
Module 9 of 12
9. The Math of Embeddings
1. High Dimensional Space
You cannot visualize 1536 dimensions (OpenAI Ada-002). But math works the same. $$ A cdot B = |A||B| cos( heta) $$
2. Search
Finding the "closest" document is just finding the vector with the smallest angle. We use Approximate Nearest Neighbors (ANN) indices like FAISS to do this in milliseconds for billions of vectors.