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: sdk/documentintelligence/azure-ai-documentintelligence/CHANGELOG.md
+45-15Lines changed: 45 additions & 15 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,29 +1,56 @@
1
1
# Release History
2
2
3
-
## 1.0.0b5 (Unreleased)
3
+
## 1.0.0 (Unreleased)
4
4
5
5
### Features Added
6
6
7
+
- Added support for the Analyze Batch Documents API:
8
+
- Added operations `delete_analyze_batch_result()`, `get_analyze_batch_result()` and `list_analyze_batch_results()` to `DocumentIntelligenceClient`.
9
+
- Added support for the Analyze Documents API:
10
+
- Added operations `delete_analyze_result()` to `DocumentIntelligenceClient`.
11
+
7
12
### Breaking Changes
8
13
14
+
- Renamed request body parameters on all methods to `body`.
15
+
- Renamed operation `get_resource_info()` to `get_resource_details()`.
16
+
- Renamed model `ContentFormat` to `DocumentContentFormat`.
17
+
- Renamed model `AnalyzeBatchResultOperation` to `AnalyzeBatchOperation`.
18
+
- Renamed model `CopyAuthorization` to `ModelCopyAuthorization`.
19
+
- Renamed model `Document` to `AnalyzedDocument`.
20
+
- Renamed model `Error` to `DocumentIntelligenceError`.
21
+
- Renamed model `ErrorResponse` to `DocumentIntelligenceErrorResponse`.
22
+
- Renamed model `InnerError` to `DocumentIntelligenceInnerError`.
23
+
- Renamed model `OperationDetails` to `DocumentIntelligenceOperationDetails`.
24
+
- Renamed model `OperationStatus` to `DocumentIntelligenceOperationStatus`.
25
+
- Renamed model `ResourceDetails` to `DocumentIntelligenceResourceDetails`.
26
+
- Renamed model `Warning` to `DocumentIntelligenceWarning`.
27
+
- Renamed property `items_property` in model `DocumentFieldSchema` to `items_schema`.
28
+
- Renamed enum `FontStyle` to `DocumentFontStyle`.
29
+
- Renamed enum `FontWeight` to `DocumentFontWeight`.
30
+
- Removed model `AnalyzeResultOperation`.
31
+
- Removed `GENERATIVE ` in enum `DocumentBuildMode`.
32
+
9
33
### Bugs Fixed
10
34
11
35
### Other Changes
12
36
37
+
- No need to pass `content-type` when analyze_request is a stream in `begin_analyze_document()` and `begin_classify_document()`.
38
+
13
39
## 1.0.0b4 (2024-09-05)
14
40
15
41
### Features Added
42
+
16
43
- Added support for the Analyze Batch Documents API:
17
-
- Added LRO operation `begin_analyze_batch_documents()` to `DocumentIntelligenceClient`.
18
-
- Added models `AnalyzeBatchDocumentsRequest`, `AnalyzeBatchResult` and `AnalyzeBatchOperationDetail`.
44
+
- Added LRO operation `begin_analyze_batch_documents()` to `DocumentIntelligenceClient`.
45
+
- Added models `AnalyzeBatchDocumentsRequest`, `AnalyzeBatchResult` and `AnalyzeBatchOperationDetail`.
19
46
- Added support for different kinds of output in the Analyze Document API:
20
-
- Added operations `get_analyze_result_figure()` and `get_analyze_result_pdf()` to `DocumentIntelligenceClient`.
21
-
- Added optional kwarg `output` to LRO operation `begin_analyze_document()` overloads in `DocumentIntelligenceClient`.
22
-
- Added enum `AnalyzeOutputOption` to specify output kind, either `pdf` or `figures`.
23
-
- Added property `id` to model `DocumentFigure`.
47
+
- Added operations `get_analyze_result_figure()` and `get_analyze_result_pdf()` to `DocumentIntelligenceClient`.
48
+
- Added optional kwarg `output` to LRO operation `begin_analyze_document()` overloads in `DocumentIntelligenceClient`.
49
+
- Added enum `AnalyzeOutputOption` to specify output kind, either `pdf` or `figures`.
50
+
- Added property `id` to model `DocumentFigure`.
24
51
- Added support for the Copy Classifier API:
25
-
- Added operations `authorize_classifier_copy()` and `begin_copy_classifier_to()` to `DocumentIntelligenceAdministrationClient`.
26
-
- Added models `AuthorizeClassifierCopyRequest` and `ClassifierCopyAuthorization`.
52
+
- Added operations `authorize_classifier_copy()` and `begin_copy_classifier_to()` to `DocumentIntelligenceAdministrationClient`.
53
+
- Added models `AuthorizeClassifierCopyRequest` and `ClassifierCopyAuthorization`.
27
54
- Added optional kwarg `pages` to LRO operation `begin_classify_document()` overloads in `DocumentIntelligenceClient`.
28
55
- Added new kind `GENERATIVE` to enum `DocumentBuildMode`.
29
56
- Added property `warnings` to model `AnalyzeResult`.
@@ -35,24 +62,27 @@
35
62
- Added support for getting `operation_id` via `details` property in the new return types `AnalyzeDocumentLROPoller` and `AsyncAnalyzeDocumentLROPoller` in operation `begin_analyze_document()`.
36
63
37
64
### Breaking Changes
65
+
38
66
- Removed support for extracting lists from analyzed documents:
39
-
- Removed models `DocumentList` and `DocumentListItem`.
40
-
- Removed property `lists` from model `AnalyzeResult`.
67
+
- Removed models `DocumentList` and `DocumentListItem`.
68
+
- Removed property `lists` from model `AnalyzeResult`.
41
69
- Changes to the Compose Document API:
42
-
- Removed model `ComponentDocumentModelDetails`.
43
-
- Removed property `component_models` from model `ComposeDocumentModelRequest`.
44
-
-`ComposeDocumentModelRequest` now requires a dictionary of `DocumentTypeDetails` instances and a classifier ID to be constructed.
70
+
- Removed model `ComponentDocumentModelDetails`.
71
+
- Removed property `component_models` from model `ComposeDocumentModelRequest`.
72
+
-`ComposeDocumentModelRequest` now requires a dictionary of `DocumentTypeDetails` instances and a classifier ID to be constructed.
45
73
- Removed model `QuotaDetails`.
46
74
- Removed property `custom_neural_document_model_builds` from model `ResourceDetails`.
47
75
- Changed the _required_ property `field_schema` from `DocumentTypeDetails` to be _optional_.
48
76
49
77
### Other Changes
78
+
50
79
- Changed the default service API version to `2024-07-31-preview`.
51
-
- Improved performance by about `1.5X` faster when deserializing `JSON` to an `AnalyzeResult` object compared to last version `1.0.0b3`.
80
+
- Improved performance by about `1.5X` faster when deserializing `JSON` to an `AnalyzeResult` object compared to last version `1.0.0b3`.
52
81
53
82
## 1.0.0b3 (2024-04-09)
54
83
55
84
### Other Changes
85
+
56
86
- Changed the default polling interval from 5s to 1s.
Copy file name to clipboardExpand all lines: sdk/documentintelligence/azure-ai-documentintelligence/MIGRATION_GUIDE.md
+3-3Lines changed: 3 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -27,20 +27,20 @@ There are many benefits to using the new design of the `azure-ai-documentintelli
27
27
28
28
Supports output with Markdown content format along with the default plain _text_. For now, this is only supported for "prebuilt-layout". Markdown content format is deemed a more friendly format for LLM consumption in a chat or automation use scenario. Custom models should continue to use the default "text" content format for generating .ocr.json results.
29
29
30
-
Service follows the GFM spec ([GitHub Flavored Markdown](https://github.github.com/gfm/)) for the Markdown format. This SDK introduces a new enum _ContentFormat_ with value "text" or "markdown" to indicate the result content format.
30
+
Service follows the GFM spec ([GitHub Flavored Markdown](https://github.github.com/gfm/)) for the Markdown format. This SDK introduces a new enum _DocumentContentFormat_ with value "text" or "markdown" to indicate the result content format.
31
31
32
32
```python
33
33
from azure.core.credentials import AzureKeyCredential
34
34
from azure.ai.documentintelligence import DocumentIntelligenceClient
35
-
from azure.ai.documentintelligence.models import AnalyzeDocumentRequest, ContentFormat
35
+
from azure.ai.documentintelligence.models import AnalyzeDocumentRequest, DocumentContentFormat
This table shows the relationship between SDK versions and supported API service versions:
32
32
33
-
|SDK version|Supported API service version|
34
-
|-|-|
35
-
|1.0.0b1 | 2023-10-31-preview|
36
-
|1.0.0b2 | 2024-02-29-preview|
33
+
| SDK version | Supported API service version |
34
+
| ----------- | ----------------------------- |
35
+
| 1.0.0 | 2024-11-30 |
37
36
38
37
Older API versions are supported in `azure-ai-formrecognizer`, please see the [Migration Guide][migration-guide] for detailed instructions on how to update application.
39
38
@@ -47,10 +46,10 @@ Older API versions are supported in `azure-ai-formrecognizer`, please see the [M
47
46
48
47
Document Intelligence supports both [multi-service and single-service access][cognitive_resource_portal]. Create a Cognitive Services resource if you plan to access multiple cognitive services under a single endpoint/key. For Document Intelligence access only, create a Document Intelligence resource. Please note that you will need a single-service resource if you intend to use [Azure Active Directory authentication](#create-the-client-with-an-azure-active-directory-credential).
Below is an example of how you can create a Document Intelligence resource using the CLI:
56
55
@@ -132,9 +131,11 @@ name for your resource in order to use this type of authentication.
132
131
To use the [DefaultAzureCredential][default_azure_credential] type shown below, or other credential types provided
133
132
with the Azure SDK, please install the `azure-identity` package:
134
133
135
-
```pip install azure-identity```
134
+
```
135
+
pip install azure-identity
136
+
```
136
137
137
-
You will also need to [register a new AAD application and grant access][register_aad_app] to Document Intelligence by assigning the `"Cognitive Services User"` role to your service principal.
138
+
You will also need to [register a new AAD application and grant access][register_aad_app] to Document Intelligence by assigning the [Cognitive Services Data Reader][entra_auth_role] role to your service principal.
138
139
139
140
Once completed, set the values of the client ID, tenant ID, and client secret of the AAD application as environment variables:
`DocumentIntelligenceClient` provides operations for analyzing input documents using prebuilt and custom models through the `begin_analyze_document` API.
160
-
Use the `model_id` parameter to select the type of model for analysis. See a full list of supported models [here][di-models].
161
-
The `DocumentIntelligenceClient` also provides operations for classifying documents through the `begin_classify_document` API.
161
+
Use the `model_id` parameter to select the type of model for analysis. See a full list of supported models [here][di-models].
162
+
The `DocumentIntelligenceClient` also provides operations for classifying documents through the `begin_classify_document` API.
162
163
Custom classification models can classify each page in an input file to identify the document(s) within and can also identify multiple documents or multiple instances of a single document within an input file.
163
164
164
165
Sample code snippets are provided to illustrate using a DocumentIntelligenceClient [here](#examples"Examples").
@@ -194,16 +195,16 @@ Sample code snippets are provided to illustrate using long-running operations [b
194
195
195
196
The following section provides several code snippets covering some of the most common Document Intelligence tasks, including:
Document Intelligence supports more sophisticated analysis capabilities. These optional features can be enabled and disabled depending on the scenario of the document extraction.
889
888
890
889
The following add-on capabilities are available in this SDK:
890
+
891
891
-[barcode/QR code][addon_barcodes_sample]
892
892
-[formula][addon_formulas_sample]
893
893
-[font/style][addon_fonts_sample]
@@ -900,6 +900,7 @@ Note that some add-on capabilities will incur additional charges. See pricing: h
900
900
### Get Raw JSON Result
901
901
902
902
Can get the HTTP response by passing parameter `raw_response_hook` to any client method.
print(f"Response status code is: {responses["status_code"]}")
924
925
response_body = responses["response_body"]
@@ -964,7 +965,6 @@ print(
964
965
965
966
<!-- END SNIPPET -->
966
967
967
-
968
968
## Troubleshooting
969
969
970
970
### General
@@ -1000,7 +1000,6 @@ See the [Sample README][sample_readme] for several code snippets illustrating co
1000
1000
1001
1001
For more extensive documentation on Azure AI Document Intelligence, see the [Document Intelligence documentation][python-di-product-docs] on docs.microsoft.com.
1002
1002
1003
-
1004
1003
## Contributing
1005
1004
1006
1005
This project welcomes contributions and suggestions. Most contributions require
@@ -1019,6 +1018,7 @@ see the Code of Conduct FAQ or contact [email protected] with any
0 commit comments