Embeddings and Vector Databases
Understand how text embeddings turn meaning into vectors and how vector databases enable the retrieval step at the heart of RAG.
From Words to Vectors
Computers cannot compare meaning directly. An embedding is a vector of numbers representing a text’s meaning, so similar texts land close together.
What an Embedding Looks Like
An embedding model maps text to a fixed-length vector with hundreds or thousands of dimensions. The numbers are not readable — what counts is their geometric relationships.
text = 'a cup of coffee'
embedding = [0.12, -0.04, 0.88, 0.31] # simplified
print('dimensions:', len(embedding))All lessons in this course
- What are Large Language Models?
- The Need for Retrieval Augmented Generation
- Core Components of a RAG System
- Embeddings and Vector Databases