Skip to content

Commit c704cd4

Browse files
committed
refocused intro
1 parent 81902b1 commit c704cd4

File tree

2 files changed

+20
-8
lines changed

2 files changed

+20
-8
lines changed

articles/search/vector-search-how-to-create-index.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,9 +21,11 @@ Follow these steps to index vector data:
2121

2222
> [!div class="checklist"]
2323
> + Add one or more vector fields to the index schema.
24-
> + Add one or more vector configurations to the index schema.
24+
> + Add one or more vector configurations.
2525
> + Load the index with vector data [as a separate step](#load-vector-data-for-indexing), after the index schema is defined.
2626
27+
Code samples in the [cognitive-search-vector-pr](https://github.com/Azure/cognitive-search-vector-pr) repository demonstrate end-to-end workflows that include schema definition, vectorization, indexing, and queries.
28+
2729
## Prerequisites
2830

2931
+ Azure Cognitive Search, in any region and on any tier. Most existing services support vector search. For a small subset of services created prior to January 2019, an index containing vector fields fails on creation. In this situation, a new service must be created.
@@ -38,7 +40,7 @@ Prior to indexing, assemble a document payload that includes fields of vector an
3840

3941
Make sure your documents:
4042

41-
1. Provide a field or a metadata property that uniquely identifies each document. All search indexes require a document key. To satisfy document key requirements, your documents must have one field or property that is unique in the index. This field must be mapped to type `Edm.String` and `key=true` in the search index.
43+
1. Provide a field or a metadata property that uniquely identifies each document. All search indexes require a document key. To satisfy document key requirements, a source document must have one field or property that can uniquely identify it in the index. This source field must be mapped to an index field of type `Edm.String` and `key=true` in the search index.
4244

4345
1. Provide vector data (an array of single-precision floating point numbers) in source fields.
4446

articles/search/vector-search-how-to-query.md

Lines changed: 16 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -15,22 +15,32 @@ ms.date: 08/10/2023
1515
> [!IMPORTANT]
1616
> Vector search is in public preview under [supplemental terms of use](https://azure.microsoft.com/support/legal/preview-supplemental-terms/). It's available through the Azure portal, preview REST API, and [beta client libraries](https://github.com/Azure/cognitive-search-vector-pr#readme).
1717
18-
In Azure Cognitive Search, if you added vector fields to a search index, this article explains how to query those fields. It also explains how to combine vector queries with full text search and semantic search for *hybrid search* scenarios.
18+
In Azure Cognitive Search, if you added vector fields to a search index, this article explains how to:
1919

20-
Cognitive Search doesn't provide built-in vectorization of the input string. Encoding (text-to-vector) of the query string requires that you pass the query string to an embedding model for vectorization. You would then pass the response to the search engine for similarity search over vector fields.
20+
> [!div class="checklist"]
21+
> + [Query vector fields](#query-syntax-for-vector-search).
22+
> + [Combine vector, full text search, and semantic search in a hybrid query](#query-syntax-for-hybrid-search).
23+
> + [Query multiple vector fields at once](#query-syntax-for-vector-query-over-multiple-fields).
24+
> + [Run multiple vector queries in parallel](#query-syntax-for-multiple-vector-queries).
2125
22-
All results are returned in plain text, including vectors. If you use Search Explorer in the Azure portal to query an index that contains vectors, the numeric vectors are returned in plain text. Because numeric vectors aren't useful in search results, choose other fields in the index as a proxy for the vector match. For example, if an index has "descriptionVector" and "descriptionText" fields, the query can match on "descriptionVector" but the search result shows "descriptionText". Use the `select` parameter to specify only human-readable fields in the results.
26+
Code samples in the [cognitive-search-vector-pr](https://github.com/Azure/cognitive-search-vector-pr) repository demonstrate end-to-end workflows that include schema definition, vectorization, indexing, and queries.
2327

2428
## Prerequisites
2529

2630
+ Azure Cognitive Search, in any region and on any tier. Most existing services support vector search. For a small subset of services created prior to January 2019, an index containing vector fields will fail on creation. In this situation, a new service must be created.
2731

2832
+ A search index containing vector fields. See [Add vector fields to a search index](vector-search-how-to-query.md).
2933

30-
+ Use REST API version 2023-07-01-preview, the [beta client libraries](https://github.com/Azure/cognitive-search-vector-pr/tree/main), or Search Explorer in the Azure portal.
34+
+ Use REST API version **2023-07-01-Preview**, the [beta client libraries](https://github.com/Azure/cognitive-search-vector-pr/tree/main), or Search Explorer in the Azure portal.
3135

3236
+ (Optional) If you want to also use [semantic search (preview)](semantic-search-overview.md) and vector search together, your search service must be Basic tier or higher, with [semantic search enabled](semantic-search-overview.md#enable-semantic-search).
3337

38+
## Limitations
39+
40+
Cognitive Search doesn't provide built-in vectorization of the query input string. Encoding (text-to-vector) of the query string requires that you pass the query string to an embedding model for vectorization. You would then pass the response to the search engine for similarity search over vector fields.
41+
42+
All results are returned in plain text, including vectors. If you use Search Explorer in the Azure portal to query an index that contains vectors, the numeric vectors are returned in plain text. Because numeric vectors aren't useful in search results, choose other fields in the index as a proxy for the vector match. For example, if an index has "descriptionVector" and "descriptionText" fields, the query can match on "descriptionVector" but the search result shows "descriptionText". Use the `select` parameter to specify only human-readable fields in the results.
43+
3444
## Check your index for vector fields
3545

3646
If you aren't sure whether your search index already has vector fields, look for:
@@ -198,7 +208,7 @@ api-key: {{admin-api-key}}
198208

199209
## Query syntax for vector query over multiple fields
200210

201-
You can set the "vectors.fields" property to multiple vector fields. For example, the Postman collection has vector fields named "titleVector" and "contentVector". Your vector query executes over both the "titleVector" and "contentVector" fields, which must have the same embedding space since they share the same query vector.
211+
You can set the "vectors.fields" property to multiple vector fields. For example, the Postman collection has vector fields named "titleVector" and "contentVector". A single vector query executes over both the "titleVector" and "contentVector" fields, which must have the same embedding space since they share the same query vector.
202212

203213
```http
204214
POST https://{{search-service-name}}.search.windows.net/indexes/{{index-name}}/docs/search?api-version={{api-version}}
@@ -296,4 +306,4 @@ Multiple sets are created if the query targets multiple vector fields, or if the
296306

297307
## Next steps
298308

299-
As a next step, we recommend reviewing the demo code for [Python](https://github.com/Azure/cognitive-search-vector-pr/tree/main/demo-python), or [C#](https://github.com/Azure/cognitive-search-vector-pr/tree/main/demo-dotnet).
309+
As a next step, we recommend reviewing the demo code for [Python](https://github.com/Azure/cognitive-search-vector-pr/tree/main/demo-python), [C#](https://github.com/Azure/cognitive-search-vector-pr/tree/main/demo-dotnet) or [JavaScript](https://github.com/Azure/cognitive-search-vector-pr/tree/main/demo-javascript).

0 commit comments

Comments
 (0)