This web sample runs text embedding on two text inputs, and then determines how alike they are using cosine similarity. Scores range from -1 to 1. More similar texts have a higher score, less similar a lower score.
- A device that can access the web using Chrome, Firefox, or Safari
- For iOS devices, iOS 16 or later
The live demo and code are available in Codepen.