weaviate / weaviate-examples

Weaviate vector database – examples
MIT License
291 stars 71 forks source link

Retrieval based in two sbert models #53

Open miguelwon opened 1 year ago

miguelwon commented 1 year ago

Hi, I'm currently working in a system where I score the document based on a calculated score from two separate retrievals, each one with it's own sbert model (a linear sum of two cosine similarities) . Is this type of query possible with weaviate? If so, is there any example I can have look? Thanks!

bobvanluijt commented 1 year ago

Hi @miguelwon –

Are you storing the output in different classes?

miguelwon commented 1 year ago

Hi @bobvanluijt . Not sure what you mean by that. I'm not storing the output. I want to retrieve an instance from a DB, where for each instance I have two embeddings, needed to calculate a cosine similarity and add the result with a weighted average. I would like to know if weaviate allows to do this type of operations. To sum up, I want something similar with a common DB text retrieval, where we can give weights to different fields of the indexer.

bobvanluijt commented 1 year ago

Hi @miguelwon –

[...] where we can give weights to different fields of the indexer.

That's certainly possible, but you have to store the results (probably) in different classes. If you join our Slack the community can help you get started.