Cosine similarity in elasticsearch with multiple vectors per document

210 Views Asked by At

I have a "documents" index. Every document has multiple embeddings vectors corresponding to chunks of text of the document. Can I run a cosine similarity script using elasticsearch to get the most similar chunk of text to a query vector?

I impemented the search with just one vector per document, but I don't know how to do that if each document has multiple vectors.

0

There are 0 best solutions below