# What's the difference between using multiple single-vector records vs. one record with multiple vectors in OpenSearch?

**URL:** <https://discuss.elastic.co/t/whats-the-difference-between-using-multiple-single-vector-records-vs-one-record-with-multiple-vectors-in-opensearch/369069>\
**Category:** Elasticsearch\
**Created:** [October 18, 2024, 1:43pm UTC](https://discuss.elastic.co/t/whats-the-difference-between-using-multiple-single-vector-records-vs-one-record-with-multiple-vectors-in-opensearch/369069 "2024-10-18T13:43:50Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![cheesydown](https://avatars.discourse-cdn.com/v4/letter/c/54ee81/32.png) [@cheesydown](https://discuss.elastic.co/u/cheesydown)\
**Post date:** [October 18, 2024, 1:43pm UTC](https://discuss.elastic.co/t/whats-the-difference-between-using-multiple-single-vector-records-vs-one-record-with-multiple-vectors-in-opensearch/369069/1 "2024-10-18T13:43:50Z")

</div>

I'm trying to move my company's Pinecone-based vector DB to use OpenSearch's k-NN search. One of the main motivations is that we want something that can support multi-vector search.

Currently I've made an OpenSearch index as follows (roughly):

```auto
"metadata": {
    "type": "",
    "model_version": "",
    ...
}
"vector": {
    "values": [0.1, 0.2, 0.3, ...]
}

```

My logic is that we have multiple such documents and we'd use these vectors inside of the search query's `should` array. However, my colleague told me that this isn't "multi-vector" search and it's no different than a vector DB that only supports single vectors like Pinecone.

What he told me to do is something like this:

```auto
"metadata": {
    "type": "",
    "model_version": "",
    ...
}
"vectors": {
    "title": {
        "values": [0.1, 0.2, 0.3, ...]
    },
    "body": {
        "values": [0.4, 0.5, 0.6, ...]
    }
}

```

In the above example the scenario is that for a given document we may sometimes want to use the title and body information separately in order to retrieve results with interpolated scores.

In my setting, the `"title"` and `"body"` would each be their own record, whereas in my colleague's one record would contain multiple relevant vectors.

I'm having trouble understanding what the difference is between querying multiple records with a `should` query vs. using multiple vectors inside of a single row.

---

<div class="post-metadata">

**Author:** ![Christian\_Dahlqvist](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/christian_dahlqvist/32/4617_2.png) [@Christian\_Dahlqvist](https://discuss.elastic.co/u/Christian_Dahlqvist)\
**Post date:** [October 18, 2024, 1:47pm UTC](https://discuss.elastic.co/t/whats-the-difference-between-using-multiple-single-vector-records-vs-one-record-with-multiple-vectors-in-opensearch/369069/2 "2024-10-18T13:47:41Z")

</div>

Opensearch is not supported here so I would recommend you instead ask your question in the Opensearch forum.

---

<div class="post-metadata">

**Author:** ![stephenb](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/stephenb/32/40856_2.png) [@stephenb](https://discuss.elastic.co/u/stephenb)\
**Post date:** [October 18, 2024, 1:48pm UTC](https://discuss.elastic.co/t/whats-the-difference-between-using-multiple-single-vector-records-vs-one-record-with-multiple-vectors-in-opensearch/369069/3 "2024-10-18T13:48:33Z")

</div>

> **[OpenSearch](https://forum.opensearch.org/)**
>
> OpenSearch makes it easy to ingest, search, visualize, and analyze your data.

---

<div class="post-metadata">

**Author:** ![cheesydown](https://avatars.discourse-cdn.com/v4/letter/c/54ee81/32.png) [@cheesydown](https://discuss.elastic.co/u/cheesydown)\
**Post date:** [October 18, 2024, 2:04pm UTC](https://discuss.elastic.co/t/whats-the-difference-between-using-multiple-single-vector-records-vs-one-record-with-multiple-vectors-in-opensearch/369069/4 "2024-10-18T14:04:23Z")

</div>

My bad. I thought the syntax and inner workings were similar enough.

---

<div class="post-metadata">

**Author:** ![Christian\_Dahlqvist](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/christian_dahlqvist/32/4617_2.png) [@Christian\_Dahlqvist](https://discuss.elastic.co/u/Christian_Dahlqvist)\
**Post date:** [October 18, 2024, 2:18pm UTC](https://discuss.elastic.co/t/whats-the-difference-between-using-multiple-single-vector-records-vs-one-record-with-multiple-vectors-in-opensearch/369069/5 "2024-10-18T14:18:11Z")

</div>

The implementations are as far as I know completely different.

Another option would naturally be to switch to Elasticsearch as you would then be in the right place. 🙂

---

<div class="post-metadata">

**Author:** ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)\
**Post date:** [October 18, 2024, 4:26pm UTC](https://discuss.elastic.co/t/whats-the-difference-between-using-multiple-single-vector-records-vs-one-record-with-multiple-vectors-in-opensearch/369069/6 "2024-10-18T16:26:59Z")

</div>

From #Elastic Search to #Elasticsearch

---

<div class="post-metadata">

**Author:** ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)\
**Post date:** [October 18, 2024, 4:29pm UTC](https://discuss.elastic.co/t/whats-the-difference-between-using-multiple-single-vector-records-vs-one-record-with-multiple-vectors-in-opensearch/369069/8 "2024-10-18T16:29:51Z")

</div>

I'd read

> **[Elasticsearch vs. OpenSearch: Vector Search Performance Comparison - Search Labs](https://www.elastic.co/search-labs/blog/elasticsearch-opensearch-vector-search-performance-comparison)**
>
> Elasticsearch is out-of-the-box 2x–12x faster than OpenSearch for vector search

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [November 15, 2024, 4:29pm UTC](https://discuss.elastic.co/t/whats-the-difference-between-using-multiple-single-vector-records-vs-one-record-with-multiple-vectors-in-opensearch/369069/9 "2024-11-15T16:29:52Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
