The map appears once a question reaches the index.
The diamond is “How much does a Kestrel K2 scanner cost per unit when ordering 50 or more?”.
Chapter 6 of 7
Meaning by neighbours
Every Larkspur document piece and customer question now has an embedding. The assistant needs the pieces closest in meaning to each question.
This chapter: How do you measure how close two meanings are, and find the nearest ones?
About this chapter
You will learn
- Cosine similarity: how close two embeddings point
- Nearest neighbours: the pieces closest to a question
- Why close in meaning is not the same as sharing words
Words you’ll meet
- Cosine similarity
- A score for how alike two vectors point, from -1 to 1; 1 means the same direction.
- Nearest neighbours
- The vectors with the highest similarity to a given one.
Step 1 of 3
scores how alike two vectors point, from -1 to 1. The top scorers are a question’s .
Predict first.