You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: articles/search/search-api-migration.md
+40-38Lines changed: 40 additions & 38 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,7 +1,7 @@
1
1
---
2
2
title: Upgrade REST API versions
3
3
titleSuffix: Azure AI Search
4
-
description: Review differences in API versions and learn the steps for migrating code to the newest Azure AI Search service REST API version.
4
+
description: Review differences in API versions and learn the steps for migrating code to the newer versions.
5
5
6
6
manager: nitinme
7
7
author: bevloh
@@ -10,43 +10,53 @@ ms.service: cognitive-search
10
10
ms.custom:
11
11
- ignite-2023
12
12
ms.topic: conceptual
13
-
ms.date: 11/27/2023
13
+
ms.date: 04/17/2024
14
14
---
15
15
16
16
# Upgrade to the latest REST API in Azure AI Search
17
17
18
-
Use this article to migrate data plane calls to newer *stable*versions of the [**Search REST API**](/rest/api/searchservice/).
18
+
Use this article to migrate data plane calls to newer versions of the [**Search REST API**](/rest/api/searchservice/).
19
19
20
-
+[**2023-11-01**](/rest/api/searchservice/search-service-api-versions#2023-11-01) is the most recent stable version. Semantic ranking and vector search support are generally available in this version.
20
+
+[**2023-11-01**](/rest/api/searchservice/search-service-api-versions#2023-11-01) is the most recent stable version. Semantic ranking and support for indexing and querying vectors are generally available in this version.
21
21
22
-
+[**2023-10-01-preview**](/rest/api/searchservice/search-service-api-versions#2023-10-01-preview) is the most recent preview version. [Integrated data chunking and vectorization](vector-search-integrated-vectorization.md) using the [Text Split](cognitive-search-skill-textsplit.md) skill and [Azure OpenAI Embedding](cognitive-search-skill-azure-openai-embedding.md) skill are introduced in this version. *There's no migration guidance for preview API versions*, but you can review [code samples](https://github.com/Azure/azure-search-vector-samples) and [walkthroughs](vector-search-how-to-configure-vectorizer.md) for help with new features.
22
+
+[**2023-10-01-preview**](/rest/api/searchservice/search-service-api-versions#2023-10-01-preview) is the most recent preview version. Preview features include [built-in query vectorization](vector-search-how-to-configure-vectorizer.md), [built-in data chunking and vectorization during indexing](vector-search-integrated-vectorization.md) (uses the [Text Split](cognitive-search-skill-textsplit.md) skill and [Azure OpenAI Embedding](cognitive-search-skill-azure-openai-embedding.md) skill). Refer to [code samples](https://github.com/Azure/azure-search-vector-samples) and [walkthroughs](vector-search-how-to-configure-vectorizer.md) for help with new features.
23
+
24
+
+**2023-07-01-preview** was the first REST API for vector support. It's now deprecated and you should migrate to either **2023-11-01** or **2023-10-01-preview** immediately.
23
25
24
26
> [!NOTE]
25
-
> API reference docs are now versioned. To get the right content, open a reference page and then apply the version-specific filter located above the table of contents.
27
+
> API reference docs are now versioned. To get the right content, open a reference page and then filter by version, using the selector located above the table of contents.
26
28
27
29
<aname="UpgradeSteps"></a>
28
30
29
31
## How to upgrade
30
32
31
-
Azure AI Search strives for backward compatibility. To upgrade and continue with existing functionality, you can usually just change the API version number. Conversely, situations calling for change codes include:
33
+
Azure AI Search breaks backward compatibility as a last resort. This section provides instructions to help you modify existing code that won't run in a newer version. Upgrade is necessary when:
34
+
35
+
+ Your code references a retired or deprecated API version and is subject to one or more of the breaking changes. API versions that fall into this category include 2023-07-10-preview for vectors and [2019-05-06](#upgrade-to-2019-05-06).
32
36
33
37
+ Your code fails when unrecognized properties are returned in an API response. As a best practice, your application should ignore properties that it doesn't understand.
34
38
35
39
+ Your code persists API requests and tries to resend them to the new API version. For example, this might happen if your application persists continuation tokens returned from the Search API (for more information, look for `@search.nextPageParameters` in the [Search API Reference](/rest/api/searchservice/Search-Documents)).
36
40
37
-
+ Your code references an API version that predates 2019-05-06 and is subject to one or more of the breaking changes in that release. The section [Upgrade to 2019-05-06](#upgrade-to-2019-05-06) provides more detail.
41
+
## Upgrade to 2023-10-01-preview
42
+
43
+
This version is identical to 2023-11-01 but has extra features in public preview: [built-in query vectorizer](vector-search-how-to-configure-vectorizer.md) and [vector prefilter mode](vector-search-filters.md). If you want to use those features, you should upgrade to the latest preview version.
38
44
39
-
If any of these situations apply to you, change your code to maintain existing functionality. Otherwise, no changes should be necessary, although you might want to start using features added in the new version.
45
+
The vector search algorithm configuration inside a search index is identical to 2023-11-01. To fix breaking changes from 2023-07-01-preview, follow the instructions in the next section.
40
46
41
47
## Upgrade to 2023-11-01
42
48
43
49
This version has breaking changes and behavioral differences for semantic ranking and vector search support.
44
50
45
-
+[Semantic ranking](semantic-search-overview.md) no longer uses `queryLanguage`. It also requires a `semanticConfiguration` definition. If you're migrating from 2020-06-30-preview, a semantic configuration replaces `searchFields`. See [Migrate from preview version](semantic-how-to-configure.md#migrate-from-preview-versions) for steps.
51
+
+[Semantic ranking](semantic-search-overview.md) is generally available and no longer uses the `queryLanguage` property. It also requires a `semanticConfiguration` definition.
52
+
53
+
To upgrade from 2020-06-30-preview, create a `semanticConfiguration` to replace `searchFields`. See [Migrate from preview version](semantic-how-to-configure.md#migrate-from-preview-versions) for steps.
54
+
55
+
+[Vector search](vector-search-overview.md) support was introduced in [Create or Update Index (2023-07-01-preview)](/rest/api/searchservice/preview-api/create-or-update-index).
46
56
47
-
+[Vector search](vector-search-overview.md) support was introduced in [Create or Update Index (2023-07-01-preview)](/rest/api/searchservice/preview-api/create-or-update-index). If you're migrating from that version, there are new options and several breaking changes. New options include vector filter mode, vector profiles, and an exhaustive K-nearest neighbors algorithm and query-time exhaustive k-NN flag. Breaking changes include renaming and restructuring the vector configuration in the index, and vector query syntax.
57
+
To upgrade from 2023-07-01-preview, rename and restructure the vector configuration in the index, and rewrite your vector query syntax using the instructions in this section.
48
58
49
-
If you added vector support using 2023-10-01-preview, there are no breaking changes, but there's one behavior difference: the `vectorFilterMode` default changed from postfilter to prefilter for [filter expressions](vector-search-filters.md). The default is prefilter for indexes created after 2023-10-01. Indexes created before that date only support postfilter, regardless of how you set the filter mode.
59
+
To upgrade from 2023-10-01-preview, there are no breaking changes, but there's one behavior difference: the `vectorFilterMode` default changed from postfilter to prefilter for [filter expressions](vector-search-filters.md). If your 2023-10-01-preview code doesn't set `vectorFilterMode` explicitly, make sure you understand the new behavior, or set the mode to postfilter to retain the old behavior.
50
60
51
61
> [!TIP]
52
62
> Azure portal supports a one-click upgrade path for 2023-07-01-preview indexes. The portal detects 2023-07-01-preview indexes and provides a **Migrate** button. Before selecting **Migrate**, select **Edit JSON** to review the updated schema first. You should find a schema that conforms to the changes described in this section. Portal migration only handles indexes with one vector search algorithm configuration, creating a default profile that maps to the algorithm. Indexes with multiple configurations require manual migration.
@@ -55,7 +65,7 @@ Here are the steps for migrating from 2023-07-01-preview:
55
65
56
66
1. Call [Get Index](/rest/api/searchservice/indexes/get?view=rest-searchservice-2023-11-01&tabs=HTTP&preserve-view=true) to retrieve the existing definition.
57
67
58
-
1. Modify the vector search configuration. This API introduces the concept of "vector profiles" which bundles together vector-related configurations under one name. It also renames `algorithmConfigurations` to `algorithms`.
68
+
1. Modify the vector search configuration. This API introduces the concept of *vector profiles that bundles together vector-related configurations under one name. It also renames `algorithmConfigurations` to `algorithms`.
59
69
60
70
+ Rename `algorithmConfigurations` to `algorithms`. This is only a renaming of the array. The contents are backwards compatible. This means your existing HNSW configuration parameters can be used.
61
71
@@ -210,48 +220,40 @@ These steps complete the migration to 2023-11-01 API version.
210
220
211
221
In this version, there's one breaking change and several behavioral differences. Generally available features include:
212
222
213
-
+ [Knowledge store](knowledge-store-concept-intro.md), persistent storage of enriched content created through skillsets, created for downstream analysis and processing through other applications. A knowledge store exists in Azure Storage, which you provision and then provide connection details to a skillset. With this capability, an indexer-driven AI enrichment pipeline can populate a knowledge store in addition to a search index. If you used the preview version of this feature, it's equivalent to the generally available version. The only code change required is modifying the api-version.
223
+
+ [Knowledge store](knowledge-store-concept-intro.md), persistent storage of enriched content created through skillsets, created for downstream analysis and processing through other applications. A knowledge store is created through Azure AI Search REST APIs but it resides in Azure Storage.
214
224
215
225
### Breaking change
216
226
217
-
Existing code written against earlier API versions will break on api-version=2020-06-30 and later if code contains the following functionality:
227
+
Code written against earlier API versions breaks on 2020-06-30 and later if code contains the following functionality:
218
228
219
-
* Any Edm.Date literals (a date composed of year-month-day, such as `2020-12-12`) in filter expressions must follow the Edm.DateTimeOffset format: `2020-12-12T00:00:00Z`. This change was necessary to handle erroneous or unexpected query results due to timezone differences.
229
+
+ Any Edm.Date literals (a date composed of year-month-day, such as `2020-12-12`) in filter expressions must follow the Edm.DateTimeOffset format: `2020-12-12T00:00:00Z`. This change was necessary to handle erroneous or unexpected query results due to timezone differences.
220
230
221
231
### Behavior changes
222
232
223
-
* [BM25 ranking algorithm](index-ranking-similarity.md) replaces the previous ranking algorithm with newer technology. Services created after 2019 use this algorithm automatically. For older services, you must set parameters to use the new algorithm.
233
+
+ [BM25 ranking algorithm](index-ranking-similarity.md) replaces the previous ranking algorithm with newer technology. Services created after 2019 use this algorithm automatically. For older services, you must set parameters to use the new algorithm.
224
234
225
-
* Ordered results for null values have changed in this version, with null values appearing first if the sort is `asc` and last if the sort is `desc`. If you wrote code to handle how null values are sorted, be aware of this change.
235
+
+ Ordered results for null values have changed in this version, with null values appearing first if the sort is `asc` and last if the sort is `desc`. If you wrote code to handle how null values are sorted, be aware of this change.
226
236
227
237
## Upgrade to 2019-05-06
228
238
229
-
Version 2019-05-06 is the previous generally available release of the REST API. Features that became generally available in this API version include:
239
+
Features that became generally available in this API version include:
230
240
231
-
* [Autocomplete](index-add-suggesters.md) is a typeahead feature that completes a partially specified term input.
232
-
* [Complex types](search-howto-complex-data-types.md) provides native support for structured object data in search index.
233
-
* [JsonLines parsing modes](search-howto-index-json-blobs.md), part of Azure Blob indexing, creates one search document per JSON entity that is separated by a newline.
234
-
* [AI enrichment](cognitive-search-concept-intro.md) provides indexing that uses the AI enrichment engines of Azure AI services.
241
+
+ [Autocomplete](index-add-suggesters.md) is a typeahead feature that completes a partially specified term input.
242
+
+ [Complex types](search-howto-complex-data-types.md) provides native support for structured object data in search index.
243
+
+ [JsonLines parsing modes](search-howto-index-json-blobs.md), part of Azure Blob indexing, creates one search document per JSON entity that is separated by a newline.
244
+
+ [AI enrichment](cognitive-search-concept-intro.md) provides indexing that uses the AI enrichment engines of Azure AI services.
235
245
236
246
### Breaking changes
237
247
238
-
Existing code written against earlier API versions will break on api-version=2019-05-06 and later if code contains the following functionality:
239
-
240
-
#### Indexer for Azure Cosmos DB - datasource is now `"type": "cosmosdb"`
241
-
242
-
If you're using an [Azure Cosmos DB indexer](search-howto-index-cosmosdb.md), you must change `"type": "documentdb"` to `"type": "cosmosdb"`.
243
-
244
-
#### Indexer execution result errors no longer have status
245
-
246
-
The error structure for indexer execution previously had a `status` element. This element was removed because it wasn't providing useful information.
248
+
Code written against an earlier API version breaks on 2019-05-06 and later if it contains the following functionality:
247
249
248
-
#### Indexer data source API no longer returns connection strings
250
+
1. Type property for Azure Cosmos DB. For indexers targeting an [Azure Cosmos DB for NoSQL API](search-howto-index-cosmosdb.md) data source, change `"type": "documentdb"` to `"type": "cosmosdb"`.
249
251
250
-
From API versions 2019-05-06 and 2019-05-06-Preview onwards, the data source API no longer returns connection strings in the response of any REST operation. In previous API versions, for data sources created using POST, Azure AI Search returned **201** followed by the OData response, which contained the connection string in plain text.
252
+
1. If your indexer error handling includes references to the `status` property, you should remove it. We removed status from the error response because it wasn't providing useful information.
251
253
252
-
#### Named Entity Recognition cognitive skill is now discontinued
254
+
1. Data source connection strings are no longer returned in the response. From API versions 2019-05-06 and 2019-05-06-Preview onwards, the data source API no longer returns connection strings in the response of any REST operation. In previous API versions, for data sources created using POST, Azure AI Search returned **201** followed by the OData response, which contained the connection string in plain text.
253
255
254
-
If you called the [Name Entity Recognition](cognitive-search-skill-named-entity-recognition.md) skill in your code, the call fails. Replacement functionality is [Entity Recognition Skill (V3)](cognitive-search-skill-entity-recognition-v3.md). Follow the recommendations in [Deprecated skills](cognitive-search-skill-deprecated.md) to migrate to a supported skill.
256
+
1. Named Entity Recognition cognitive skill is retired. If you called the [Name Entity Recognition](cognitive-search-skill-named-entity-recognition.md) skill in your code, the call fails. Replacement functionality is [Entity Recognition Skill (V3)](cognitive-search-skill-entity-recognition-v3.md). Follow the recommendations in [Deprecated skills](cognitive-search-skill-deprecated.md) to migrate to a supported skill.
255
257
256
258
### Upgrading complex types
257
259
@@ -306,9 +308,9 @@ You can update "flat" indexes to the new format with the following steps using A
306
308
307
309
1. Perform a GET request to retrieve your index. If it’s already in the new format, you’re done.
308
310
309
-
2. Translate the index from the “flat” format to the new format. You have to write code for this task since there's no sample code available at the time of this writing.
311
+
1. Translate the index from the “flat” format to the new format. You have to write code for this task since there's no sample code available at the time of this writing.
310
312
311
-
3. Perform a PUT request to update the index to the new format. Avoid changing any other details of the index, such as the searchability/filterability of fields, because changes that affect the physical expression of existing index isn't allowed by the Update Index API.
313
+
1. Perform a PUT request to update the index to the new format. Avoid changing any other details of the index, such as the searchability/filterability of fields, because changes that affect the physical expression of existing index isn't allowed by the Update Index API.
312
314
313
315
> [!NOTE]
314
316
> It is not possible to manage indexes created with the old "flat" format from the Azure portal. Please upgrade your indexes from the “flat” representation to the “tree” representation at your earliest convenience.
Copy file name to clipboardExpand all lines: articles/search/search-api-versions.md
+5-1Lines changed: 5 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -14,7 +14,7 @@ ms.custom:
14
14
- devx-track-python
15
15
- ignite-2023
16
16
ms.topic: conceptual
17
-
ms.date: 01/10/2024
17
+
ms.date: 04/17/2024
18
18
---
19
19
20
20
# API versions in Azure AI Search
@@ -25,6 +25,10 @@ As a rule, the REST APIs and libraries are versioned only when necessary, since
25
25
26
26
See [Azure SDK lifecycle and support policy](https://azure.github.io/azure-sdk/policies_support.html) for more information about the deprecation path.
27
27
28
+
## Deprecated versions
29
+
30
+
**2023-07-01-preview** was deprecated on April 8, 2024 and will be retired on July 8, 2024. This was the first REST API that offered vector search support. Newer API versions have a different vector configuration. We recommend [migrating to a newer version](search-api-migration.md) as soon as possible.
Copy file name to clipboardExpand all lines: articles/search/whats-new.md
+2-1Lines changed: 2 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -7,7 +7,7 @@ author: HeidiSteen
7
7
ms.author: heidist
8
8
ms.service: cognitive-search
9
9
ms.topic: overview
10
-
ms.date: 04/03/2024
10
+
ms.date: 04/17/2024
11
11
ms.custom:
12
12
- references_regions
13
13
- ignite-2023
@@ -26,6 +26,7 @@ ms.custom:
26
26
|[**Built-in vector quantization, narrow vector data types, and a new `stored` property (preview)**](vector-search-how-to-configure-compression-storage.md)| Feature | This preview adds support for larger vector workloads at a lower cost through three enhancements. First, *scalar quantization* reduces vector index size in memory and on disk. Second, [narrow data types](/rest/api/searchservice/supported-data-types) can be assigned to vector fields that can use them. Third, we added more flexible vector field storage options.|
27
27
|[**2024-03-01-preview Search REST API**](/rest/api/searchservice/search-service-api-versions#2024-03-01-preview)| API | New preview version of the Search REST APIs for the new data types, vector compression properties, and storage options. |
28
28
|[**2024-03-01-preview Management REST API**](/rest/api/searchmanagement/operation-groups?view=rest-searchmanagement-2024-03-01-preview&preserve-view=true)| API | New preview version of the Management REST APIs for control plane operations. |
29
+
|[**2023-07-01-preview deprecation announcement**](/rest/api/searchservice/search-service-api-versions#2023-07-01-preview)| API | Deprecation announced on April 8, 2024. Retirement on July 8, 2024. This was the first REST API that offered vector search support. Newer API versions have a different vector configuration. We recommend [migrating to a newer version](search-api-migration.md) as soon as possible. |
0 commit comments