AI engineering glossary · RAG vector search
What is hamming distance?
Hamming distance: The number of positions at which two equal-length binary strings differ. It is very fast to compute on bit vectors, making it useful for comparing binary-quantised embeddings or hash signatures.
Hamming distance: an example
Comparing 10110 and 10011 gives Hamming distance 2.
Related terms
More RAG vector search terms
Where you learn it
Hamming distance is part of the AI Engineering Program, which teaches it with notes, a hands-on lab and an exam. The first lesson is free.