Featured image

If you are building an application that requires search, I recommend using Elasticsearch early on. In addition to the usual full-text search, Elasticsearch allows you to perform a hybrid search: combine the results of text and vector search. Of course, for small amounts of data, you can use PostgreSQL tsvector with the pgvector extension, but in the long term, Elasticsearch will provide good performance. I’d also like to remind you that vector embeddings can be extracted not only from text but also from images or audio files (for example, using Sentence Transformers models). This will allow users to combine different types of input data for search, while achieving maximum accuracy.