Skip to content

Commit 6ca1f44

Browse files
Merge pull request #251288 from jcodella/patch-5
Update vector-search.md
2 parents 14181d3 + add58ce commit 6ca1f44

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

articles/cosmos-db/mongodb/vcore/vector-search.md

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ To create a vector index, use the following `createIndexes` template:
5050
| Field | Type | Description |
5151
| --- | --- | --- |
5252
| `index_name` | string | Unique name of the index. |
53-
| `path_to_property` | string | Path to the property that contains the vector. This path can be a top-level property or a dot notation path to the property. If a dot notation path is used, then all the nonleaf elements can't be arrays. |
53+
| `path_to_property` | string | Path to the property that contains the vector. This path can be a top-level property or a dot notation path to the property. If a dot notation path is used, then all the nonleaf elements can't be arrays. Vectors must be a `number[]` to be indexed and return in vector search results.|
5454
| `kind` | string | Type of vector index to create. Currently, `vector-ivf` is the only supported index option. |
5555
| `numLists` | integer | This integer is the number of clusters that the inverted file (IVF) index uses to group the vector data. We recommend that `numLists` is set to `documentCount/1000` for up to 1 million documents and to `sqrt(documentCount)` for more than 1 million documents. Using a `numLists` value of `1` is akin to performing brute-force search, which will have limited performance. |
5656
| `similarity` | string | Similarity metric to use with the IVF index. Possible options are `COS` (cosine distance), `L2` (Euclidean distance), and `IP` (inner product). |
@@ -63,6 +63,10 @@ To create a vector index, use the following `createIndexes` template:
6363
>
6464
> If you're experimenting with a new scenario or creating a small demo, you can start with `numLists` set to `1` to perform a brute-force search across all vectors. This should provide you with the most accurate results from the vector search, however be aware that the search speed and latency will be slow. After your initial setup, you should go ahead and tune the `numLists` parameter using the above guidance.
6565
66+
> [!IMPORTANT]
67+
> Vectors must be a `number[]` to be indexed. Using another type, such as `double[]`, prevents the document from being indexed. Non-indexed documents won't be returned in the result of a vector search.
68+
69+
6670
## Examples
6771

6872
The following examples show you how to index vectors, add documents that have vector properties, perform a vector search, and retrieve the index configuration.
@@ -206,4 +210,4 @@ This guide demonstrates how to create a vector index, add documents that have ve
206210
> [!div class="nextstepaction"]
207211
> [Build AI apps with Azure Cosmos DB for MongoDB vCore vector search](vector-search-ai.md)
208212
* Learn more about [Azure OpenAI embeddings](../../../ai-services/openai/concepts/understand-embeddings.md)
209-
* Learn how to [generate embeddings using Azure OpenAI](../../../ai-services/openai/tutorials/embeddings.md)
213+
* Learn how to [generate embeddings using Azure OpenAI](../../../ai-services/openai/tutorials/embeddings.md)

0 commit comments

Comments
 (0)