The author further explains how the app improves search results by using cosine similarity to measure the distance between the embeddings of the search query and each icon. The system is also capable of adjusting to user feedback by counting the number of times a user clicks on an icon for a particular search query. The author concludes by discussing the potential for adding more features using Postgres, and encourages other app developers to explore the use of vector embeddings.
Key takeaways:
- Vector embeddings are powerful tools for search and recommendation systems, capable of measuring similarity to arbitrary input, even in different languages.
- Pgvector is a Postgres extension that allows for the storage and querying of embeddings without the need for a new service, combining standard SQL logic with embedding operations.
- Embedding search can be improved by using different embedding models or encoding methods, and can be combined with user feedback data to improve search results over time.
- While Postgres was chosen for this project due to its ability to layer more features on top of the initial search, there are many other vector databases and tools available for different needs and situations.