Freigeben über


ContentUnderstandingClient Class

  • java.lang.Object
    • com.azure.ai.contentunderstanding.ContentUnderstandingClient

public final class ContentUnderstandingClient

Initializes a new instance of the synchronous ContentUnderstandingClient type.

Method Summary

Modifier and Type Method and Description
SyncPoller<BinaryData,BinaryData> beginAnalyze(String analyzerId, BinaryData analyzeRequest, RequestOptions requestOptions)

Extract content and fields from input.

SyncPoller<ContentAnalyzerAnalyzeOperationStatus,AnalysisResult> beginAnalyze(String analyzerId, List<AnalysisInput> inputs)

Extract content and fields from inputs.

SyncPoller<ContentAnalyzerAnalyzeOperationStatus,AnalysisResult> beginAnalyze(String analyzerId, List<AnalysisInput> inputs, Map<String,String> modelDeployments, ProcessingLocation processingLocation)

Extract content and fields from inputs.

SyncPoller<ContentAnalyzerAnalyzeOperationStatus,AnalysisResult> beginAnalyzeBinary(String analyzerId, BinaryData binaryInput)

Extract content and fields from binary input.

SyncPoller<ContentAnalyzerAnalyzeOperationStatus,AnalysisResult> beginAnalyzeBinary(String analyzerId, BinaryData binaryInput, ContentRange contentRange, String contentType, ProcessingLocation processingLocation)

Extract content and fields from binary input.

SyncPoller<BinaryData,BinaryData> beginAnalyzeBinary(String analyzerId, String contentType, BinaryData binaryInput, RequestOptions requestOptions)

Extract content and fields from input.

SyncPoller<BinaryData,BinaryData> beginCopyAnalyzer(String analyzerId, BinaryData copyAnalyzerRequest, RequestOptions requestOptions)

Create a copy of the source analyzer to the current location.

SyncPoller<ContentAnalyzerOperationStatus,ContentAnalyzer> beginCopyAnalyzer(String analyzerId, String sourceAnalyzerId)

Create a copy of the source analyzer to the current location.

SyncPoller<ContentAnalyzerOperationStatus,ContentAnalyzer> beginCopyAnalyzer(String analyzerId, String sourceAnalyzerId, Boolean allowReplace, String sourceAzureResourceId, String sourceRegion)

Create a copy of the source analyzer to the current location.

SyncPoller<BinaryData,BinaryData> beginCreateAnalyzer(String analyzerId, BinaryData resource, RequestOptions requestOptions)

Create a new analyzer asynchronously.

SyncPoller<ContentAnalyzerOperationStatus,ContentAnalyzer> beginCreateAnalyzer(String analyzerId, ContentAnalyzer resource)

Create a new analyzer asynchronously.

SyncPoller<ContentAnalyzerOperationStatus,ContentAnalyzer> beginCreateAnalyzer(String analyzerId, ContentAnalyzer resource, Boolean allowReplace)

Create a new analyzer asynchronously.

void deleteAnalyzer(String analyzerId)

Delete analyzer.

Response<Void> deleteAnalyzerWithResponse(String analyzerId, RequestOptions requestOptions)

Delete analyzer.

void deleteResult(String operationId)

Mark the result of an analysis operation for deletion.

Response<Void> deleteResultWithResponse(String operationId, RequestOptions requestOptions)

Mark the result of an analysis operation for deletion.

ContentAnalyzer getAnalyzer(String analyzerId)

Get analyzer properties.

Response<BinaryData> getAnalyzerWithResponse(String analyzerId, RequestOptions requestOptions)

Get analyzer properties.

ContentUnderstandingDefaults getDefaults()

Return default settings for this Content Understanding resource.

Response<BinaryData> getDefaultsWithResponse(RequestOptions requestOptions)

Return default settings for this Content Understanding resource.

BinaryData getResultFile(String operationId, String path)

Get a file associated with the result of an analysis operation.

Response<BinaryData> getResultFileWithResponse(String operationId, String path, RequestOptions requestOptions)

Get a file associated with the result of an analysis operation.

CopyAuthorization grantCopyAuthorization(String analyzerId, String targetAzureResourceId)

Get authorization for copying this analyzer to another location.

CopyAuthorization grantCopyAuthorization(String analyzerId, String targetAzureResourceId, String targetRegion)

Get authorization for copying this analyzer to another location.

Response<BinaryData> grantCopyAuthorizationWithResponse(String analyzerId, BinaryData grantCopyAuthorizationRequest, RequestOptions requestOptions)

Get authorization for copying this analyzer to another location.

PagedIterable<ContentAnalyzer> listAnalyzers()

List analyzers.

PagedIterable<BinaryData> listAnalyzers(RequestOptions requestOptions)

List analyzers.

ContentAnalyzer updateAnalyzer(String analyzerId, ContentAnalyzer resource)

Update analyzer properties.

Response<BinaryData> updateAnalyzerWithResponse(String analyzerId, BinaryData resource, RequestOptions requestOptions)

Update analyzer properties.

ContentUnderstandingDefaults updateDefaults(ContentUnderstandingDefaults defaults)

Update default model deployment settings.

ContentUnderstandingDefaults updateDefaults(Map<String,String> modelDeployments)

Update default model deployment settings.

Response<BinaryData> updateDefaultsWithResponse(BinaryData updateDefaultsRequest, RequestOptions requestOptions)

Update default settings for this Content Understanding resource.

Methods inherited from java.lang.Object

Method Details

beginAnalyze

public SyncPoller<BinaryData,BinaryData> beginAnalyze(String analyzerId, BinaryData analyzeRequest, RequestOptions requestOptions)

Extract content and fields from input.

Query Parameters

| ------------------ | ------ | -------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
| Name               | Type   | Required | Description                                                                                                                                       |
| stringEncoding     | String | No       | The string encoding format for content spans in the response. Possible values are 'codePoint', 'utf16', and \`utf8\`. Default is \`codePoint\`.") |
| processingLocation | String | No       | The location where the data may be processed. Defaults to global. Allowed values: "geography", "dataZone", "global".                              |

You can add these to a request with RequestOptions#addQueryParam

Request Body Schema

{
     inputs (Required): [
          (Required){
             url: String (Optional)
             data: byte[] (Optional)
             name: String (Optional)
             mimeType: String (Optional)
             range: String (Optional)
         }
     ]
     modelDeployments (Optional): {
         String: String (Required)
     }
 }

Response Body Schema

{
     id: String (Required)
     status: String(NotStarted/Running/Succeeded/Failed/Canceled) (Required)
     error (Optional): {
         code: String (Required)
         message: String (Required)
         target: String (Optional)
         details (Optional): [
             (recursive schema, see above)
         ]
         innererror (Optional): {
             code: String (Optional)
             innererror (Optional): (recursive schema, see innererror above)
         }
     }
     result (Optional): {
         analyzerId: String (Optional)
         apiVersion: String (Optional)
         createdAt: OffsetDateTime (Optional)
         warnings (Optional): [
             (recursive schema, see above)
         ]
         stringEncoding: String (Optional)
         contents (Required): [
              (Required){
                 kind: String(document/audioVisual) (Required)
                 mimeType: String (Required)
                 analyzerId: String (Optional)
                 category: String (Optional)
                 path: String (Optional)
                 markdown: String (Optional)
                 fields (Optional): {
                     String (Required): {
                         type: String(string/date/time/number/integer/boolean/array/object/json) (Required)
                         spans (Optional): [
                              (Optional){
                                 offset: int (Required)
                                 length: int (Required)
                             }
                         ]
                         confidence: Double (Optional)
                         source: String (Optional)
                     }
                 }
             }
         ]
     }
     usage (Optional): {
         documentPagesMinimal: Integer (Optional)
         documentPagesBasic: Integer (Optional)
         documentPagesStandard: Integer (Optional)
         audioHours: Double (Optional)
         videoHours: Double (Optional)
         contextualizationTokens: Integer (Optional)
         tokens (Optional): {
             String: int (Required)
         }
     }
 }

Parameters:

analyzerId - The unique identifier of the analyzer.
analyzeRequest - The analyzeRequest parameter.
requestOptions - The options to configure the HTTP request before HTTP client sends it.

Returns:

the SyncPoller<T,U> for polling of provides status details for analyze operations.

beginAnalyze

public SyncPoller<ContentAnalyzerAnalyzeOperationStatus,AnalysisResult> beginAnalyze(String analyzerId, List<AnalysisInput> inputs)

Extract content and fields from inputs. Uses default string encoding (utf16), service default model deployments, and global processing location.

Parameters:

analyzerId - The unique identifier of the analyzer.
inputs - The inputs to analyze.

Returns:

the SyncPoller<T,U> for polling of the analyze operation.

beginAnalyze

public SyncPoller<ContentAnalyzerAnalyzeOperationStatus,AnalysisResult> beginAnalyze(String analyzerId, List<AnalysisInput> inputs, Map<String,String> modelDeployments, ProcessingLocation processingLocation)

Extract content and fields from inputs. Uses default string encoding (utf16).

Parameters:

analyzerId - The unique identifier of the analyzer.
inputs - The inputs to analyze.
modelDeployments - Custom model deployment mappings. Set to null to use service defaults.
processingLocation - The processing location for the analysis. Set to null to use the service default.

Returns:

the SyncPoller<T,U> for polling of the analyze operation.

beginAnalyzeBinary

public SyncPoller<ContentAnalyzerAnalyzeOperationStatus,AnalysisResult> beginAnalyzeBinary(String analyzerId, BinaryData binaryInput)

Extract content and fields from binary input. Uses default content type (application/octet-stream), default string encoding (utf16), and service default processing location.

Parameters:

analyzerId - The unique identifier of the analyzer.
binaryInput - The binary content of the document to analyze.

Returns:

the SyncPoller<T,U> for polling of the analyze operation.

beginAnalyzeBinary

public SyncPoller<ContentAnalyzerAnalyzeOperationStatus,AnalysisResult> beginAnalyzeBinary(String analyzerId, BinaryData binaryInput, ContentRange contentRange, String contentType, ProcessingLocation processingLocation)

Extract content and fields from binary input. Uses default string encoding (utf16). Use factory methods such as pages(int start, int end), ContentRange#timeRange(long, long), or ContentRange#combine(ContentRange...) to build the range.

Parameters:

analyzerId - The unique identifier of the analyzer.
binaryInput - The binary content of the document to analyze.
contentRange - Range of the input to analyze. Use ContentRange factory methods to build the range, or null to skip.
contentType - Request content type.
processingLocation - The location where the data may be processed. Set to null for service default.

Returns:

the SyncPoller<T,U> for polling of the analyze operation.

beginAnalyzeBinary

public SyncPoller<BinaryData,BinaryData> beginAnalyzeBinary(String analyzerId, String contentType, BinaryData binaryInput, RequestOptions requestOptions)

Extract content and fields from input.

Query Parameters

| ------------------ | ------ | -------- | --------------------------------------------------------------------------------------------------------------------------------------------------- |
| Name               | Type   | Required | Description                                                                                                                                         |
| stringEncoding     | String | No       | The string encoding format for content spans in the response. Possible values are 'codePoint', 'utf16', and \`utf8\`. Default is \`codePoint\`.")   |
| processingLocation | String | No       | The location where the data may be processed. Defaults to global. Allowed values: "geography", "dataZone", "global".                                |
| range              | String | No       | Range of the input to analyze (ex. \`1-3,5,9-\`). Document content uses 1-based page numbers, while audio visual content uses integer milliseconds. |

You can add these to a request with RequestOptions#addQueryParam

Request Body Schema

BinaryData

Response Body Schema

{
     id: String (Required)
     status: String(NotStarted/Running/Succeeded/Failed/Canceled) (Required)
     error (Optional): {
         code: String (Required)
         message: String (Required)
         target: String (Optional)
         details (Optional): [
             (recursive schema, see above)
         ]
         innererror (Optional): {
             code: String (Optional)
             innererror (Optional): (recursive schema, see innererror above)
         }
     }
     result (Optional): {
         analyzerId: String (Optional)
         apiVersion: String (Optional)
         createdAt: OffsetDateTime (Optional)
         warnings (Optional): [
             (recursive schema, see above)
         ]
         stringEncoding: String (Optional)
         contents (Required): [
              (Required){
                 kind: String(document/audioVisual) (Required)
                 mimeType: String (Required)
                 analyzerId: String (Optional)
                 category: String (Optional)
                 path: String (Optional)
                 markdown: String (Optional)
                 fields (Optional): {
                     String (Required): {
                         type: String(string/date/time/number/integer/boolean/array/object/json) (Required)
                         spans (Optional): [
                              (Optional){
                                 offset: int (Required)
                                 length: int (Required)
                             }
                         ]
                         confidence: Double (Optional)
                         source: String (Optional)
                     }
                 }
             }
         ]
     }
     usage (Optional): {
         documentPagesMinimal: Integer (Optional)
         documentPagesBasic: Integer (Optional)
         documentPagesStandard: Integer (Optional)
         audioHours: Double (Optional)
         videoHours: Double (Optional)
         contextualizationTokens: Integer (Optional)
         tokens (Optional): {
             String: int (Required)
         }
     }
 }

Parameters:

analyzerId - The unique identifier of the analyzer.
contentType - Request content type.
binaryInput - The binary content of the document to analyze.
requestOptions - The options to configure the HTTP request before HTTP client sends it.

Returns:

the SyncPoller<T,U> for polling of provides status details for analyze operations.

beginCopyAnalyzer

public SyncPoller<BinaryData,BinaryData> beginCopyAnalyzer(String analyzerId, BinaryData copyAnalyzerRequest, RequestOptions requestOptions)

Create a copy of the source analyzer to the current location.

Query Parameters

| ------------ | ------- | -------- | ---------------------------------------------------- |
| Name         | Type    | Required | Description                                          |
| allowReplace | Boolean | No       | Allow the operation to replace an existing resource. |

You can add these to a request with RequestOptions#addQueryParam

Request Body Schema

{
     sourceAzureResourceId: String (Optional)
     sourceRegion: String (Optional)
     sourceAnalyzerId: String (Required)
 }

Response Body Schema

{
     analyzerId: String (Required)
     description: String (Optional)
     tags (Optional): {
         String: String (Required)
     }
     status: String(creating/ready/deleting/failed) (Required)
     createdAt: OffsetDateTime (Required)
     lastModifiedAt: OffsetDateTime (Required)
     warnings (Optional): [
          (Optional){
             code: String (Required)
             message: String (Required)
             target: String (Optional)
             details (Optional): [
                 (recursive schema, see above)
             ]
             innererror (Optional): {
                 code: String (Optional)
                 innererror (Optional): (recursive schema, see innererror above)
             }
         }
     ]
     baseAnalyzerId: String (Optional)
     config (Optional): {
         returnDetails: Boolean (Optional)
         locales (Optional): [
             String (Optional)
         ]
         enableOcr: Boolean (Optional)
         enableLayout: Boolean (Optional)
         enableFigureDescription: Boolean (Optional)
         enableFigureAnalysis: Boolean (Optional)
         enableFormula: Boolean (Optional)
         tableFormat: String(html/markdown) (Optional)
         chartFormat: String(chartJs/markdown) (Optional)
         annotationFormat: String(none/markdown) (Optional)
         disableFaceBlurring: Boolean (Optional)
         estimateFieldSourceAndConfidence: Boolean (Optional)
         contentCategories (Optional): {
             String (Required): {
                 description: String (Optional)
                 analyzerId: String (Optional)
                 analyzer (Optional): (recursive schema, see analyzer above)
             }
         }
         enableSegment: Boolean (Optional)
         segmentPerPage: Boolean (Optional)
         omitContent: Boolean (Optional)
     }
     fieldSchema (Optional): {
         name: String (Optional)
         description: String (Optional)
         fields (Optional, Required on create): {
             String (Required): {
                 method: String(generate/extract/classify) (Optional)
                 type: String(string/date/time/number/integer/boolean/array/object/json) (Optional)
                 description: String (Optional)
                 items (Optional): (recursive schema, see items above)
                 properties (Optional): {
                     String (Required): (recursive schema, see String above)
                 }
                 examples (Optional): [
                     String (Optional)
                 ]
                 enum (Optional): [
                     String (Optional)
                 ]
                 enumDescriptions (Optional): {
                     String: String (Required)
                 }
                 $ref: String (Optional)
                 estimateSourceAndConfidence: Boolean (Optional)
             }
         }
         definitions (Optional): {
             String (Required): (recursive schema, see String above)
         }
     }
     dynamicFieldSchema: Boolean (Optional)
     processingLocation: String(geography/dataZone/global) (Optional)
     knowledgeSources (Optional): [
          (Optional){
             kind: String(labeledData) (Required)
         }
     ]
     models (Optional): {
         String: String (Required)
     }
     supportedModels (Optional): {
         completion (Optional): [
             String (Optional)
         ]
         embedding (Optional): [
             String (Optional)
         ]
     }
 }

Parameters:

analyzerId - The unique identifier of the analyzer.
copyAnalyzerRequest - The copyAnalyzerRequest parameter.
requestOptions - The options to configure the HTTP request before HTTP client sends it.

Returns:

the SyncPoller<T,U> for polling of analyzer that extracts content and fields from multimodal documents.

beginCopyAnalyzer

public SyncPoller<ContentAnalyzerOperationStatus,ContentAnalyzer> beginCopyAnalyzer(String analyzerId, String sourceAnalyzerId)

Create a copy of the source analyzer to the current location.

Parameters:

analyzerId - The unique identifier of the analyzer.
sourceAnalyzerId - Source analyzer ID.

Returns:

the SyncPoller<T,U> for polling of analyzer that extracts content and fields from multimodal documents.

beginCopyAnalyzer

public SyncPoller<ContentAnalyzerOperationStatus,ContentAnalyzer> beginCopyAnalyzer(String analyzerId, String sourceAnalyzerId, Boolean allowReplace, String sourceAzureResourceId, String sourceRegion)

Create a copy of the source analyzer to the current location.

Parameters:

analyzerId - The unique identifier of the analyzer.
sourceAnalyzerId - Source analyzer ID.
allowReplace - Allow the operation to replace an existing resource.
sourceAzureResourceId - Azure resource ID of the source analyzer location. Defaults to the current resource.
sourceRegion - Azure region of the source analyzer location. Defaults to current region.

Returns:

the SyncPoller<T,U> for polling of analyzer that extracts content and fields from multimodal documents.

beginCreateAnalyzer

public SyncPoller<BinaryData,BinaryData> beginCreateAnalyzer(String analyzerId, BinaryData resource, RequestOptions requestOptions)

Create a new analyzer asynchronously.

Query Parameters

| ------------ | ------- | -------- | ---------------------------------------------------- |
| Name         | Type    | Required | Description                                          |
| allowReplace | Boolean | No       | Allow the operation to replace an existing resource. |

You can add these to a request with RequestOptions#addQueryParam

Request Body Schema

{
     analyzerId: String (Required)
     description: String (Optional)
     tags (Optional): {
         String: String (Required)
     }
     status: String(creating/ready/deleting/failed) (Required)
     createdAt: OffsetDateTime (Required)
     lastModifiedAt: OffsetDateTime (Required)
     warnings (Optional): [
          (Optional){
             code: String (Required)
             message: String (Required)
             target: String (Optional)
             details (Optional): [
                 (recursive schema, see above)
             ]
             innererror (Optional): {
                 code: String (Optional)
                 innererror (Optional): (recursive schema, see innererror above)
             }
         }
     ]
     baseAnalyzerId: String (Optional)
     config (Optional): {
         returnDetails: Boolean (Optional)
         locales (Optional): [
             String (Optional)
         ]
         enableOcr: Boolean (Optional)
         enableLayout: Boolean (Optional)
         enableFigureDescription: Boolean (Optional)
         enableFigureAnalysis: Boolean (Optional)
         enableFormula: Boolean (Optional)
         tableFormat: String(html/markdown) (Optional)
         chartFormat: String(chartJs/markdown) (Optional)
         annotationFormat: String(none/markdown) (Optional)
         disableFaceBlurring: Boolean (Optional)
         estimateFieldSourceAndConfidence: Boolean (Optional)
         contentCategories (Optional): {
             String (Required): {
                 description: String (Optional)
                 analyzerId: String (Optional)
                 analyzer (Optional): (recursive schema, see analyzer above)
             }
         }
         enableSegment: Boolean (Optional)
         segmentPerPage: Boolean (Optional)
         omitContent: Boolean (Optional)
     }
     fieldSchema (Optional): {
         name: String (Optional)
         description: String (Optional)
         fields (Optional, Required on create): {
             String (Required): {
                 method: String(generate/extract/classify) (Optional)
                 type: String(string/date/time/number/integer/boolean/array/object/json) (Optional)
                 description: String (Optional)
                 items (Optional): (recursive schema, see items above)
                 properties (Optional): {
                     String (Required): (recursive schema, see String above)
                 }
                 examples (Optional): [
                     String (Optional)
                 ]
                 enum (Optional): [
                     String (Optional)
                 ]
                 enumDescriptions (Optional): {
                     String: String (Required)
                 }
                 $ref: String (Optional)
                 estimateSourceAndConfidence: Boolean (Optional)
             }
         }
         definitions (Optional): {
             String (Required): (recursive schema, see String above)
         }
     }
     dynamicFieldSchema: Boolean (Optional)
     processingLocation: String(geography/dataZone/global) (Optional)
     knowledgeSources (Optional): [
          (Optional){
             kind: String(labeledData) (Required)
         }
     ]
     models (Optional): {
         String: String (Required)
     }
     supportedModels (Optional): {
         completion (Optional): [
             String (Optional)
         ]
         embedding (Optional): [
             String (Optional)
         ]
     }
 }

Response Body Schema

{
     analyzerId: String (Required)
     description: String (Optional)
     tags (Optional): {
         String: String (Required)
     }
     status: String(creating/ready/deleting/failed) (Required)
     createdAt: OffsetDateTime (Required)
     lastModifiedAt: OffsetDateTime (Required)
     warnings (Optional): [
          (Optional){
             code: String (Required)
             message: String (Required)
             target: String (Optional)
             details (Optional): [
                 (recursive schema, see above)
             ]
             innererror (Optional): {
                 code: String (Optional)
                 innererror (Optional): (recursive schema, see innererror above)
             }
         }
     ]
     baseAnalyzerId: String (Optional)
     config (Optional): {
         returnDetails: Boolean (Optional)
         locales (Optional): [
             String (Optional)
         ]
         enableOcr: Boolean (Optional)
         enableLayout: Boolean (Optional)
         enableFigureDescription: Boolean (Optional)
         enableFigureAnalysis: Boolean (Optional)
         enableFormula: Boolean (Optional)
         tableFormat: String(html/markdown) (Optional)
         chartFormat: String(chartJs/markdown) (Optional)
         annotationFormat: String(none/markdown) (Optional)
         disableFaceBlurring: Boolean (Optional)
         estimateFieldSourceAndConfidence: Boolean (Optional)
         contentCategories (Optional): {
             String (Required): {
                 description: String (Optional)
                 analyzerId: String (Optional)
                 analyzer (Optional): (recursive schema, see analyzer above)
             }
         }
         enableSegment: Boolean (Optional)
         segmentPerPage: Boolean (Optional)
         omitContent: Boolean (Optional)
     }
     fieldSchema (Optional): {
         name: String (Optional)
         description: String (Optional)
         fields (Optional, Required on create): {
             String (Required): {
                 method: String(generate/extract/classify) (Optional)
                 type: String(string/date/time/number/integer/boolean/array/object/json) (Optional)
                 description: String (Optional)
                 items (Optional): (recursive schema, see items above)
                 properties (Optional): {
                     String (Required): (recursive schema, see String above)
                 }
                 examples (Optional): [
                     String (Optional)
                 ]
                 enum (Optional): [
                     String (Optional)
                 ]
                 enumDescriptions (Optional): {
                     String: String (Required)
                 }
                 $ref: String (Optional)
                 estimateSourceAndConfidence: Boolean (Optional)
             }
         }
         definitions (Optional): {
             String (Required): (recursive schema, see String above)
         }
     }
     dynamicFieldSchema: Boolean (Optional)
     processingLocation: String(geography/dataZone/global) (Optional)
     knowledgeSources (Optional): [
          (Optional){
             kind: String(labeledData) (Required)
         }
     ]
     models (Optional): {
         String: String (Required)
     }
     supportedModels (Optional): {
         completion (Optional): [
             String (Optional)
         ]
         embedding (Optional): [
             String (Optional)
         ]
     }
 }

Parameters:

analyzerId - The unique identifier of the analyzer.
resource - The resource instance.
requestOptions - The options to configure the HTTP request before HTTP client sends it.

Returns:

the SyncPoller<T,U> for polling of analyzer that extracts content and fields from multimodal documents.

beginCreateAnalyzer

public SyncPoller<ContentAnalyzerOperationStatus,ContentAnalyzer> beginCreateAnalyzer(String analyzerId, ContentAnalyzer resource)

Create a new analyzer asynchronously.

Parameters:

analyzerId - The unique identifier of the analyzer.
resource - The resource instance.

Returns:

the SyncPoller<T,U> for polling of analyzer that extracts content and fields from multimodal documents.

beginCreateAnalyzer

public SyncPoller<ContentAnalyzerOperationStatus,ContentAnalyzer> beginCreateAnalyzer(String analyzerId, ContentAnalyzer resource, Boolean allowReplace)

Create a new analyzer asynchronously.

Parameters:

analyzerId - The unique identifier of the analyzer.
resource - The resource instance.
allowReplace - Allow the operation to replace an existing resource.

Returns:

the SyncPoller<T,U> for polling of analyzer that extracts content and fields from multimodal documents.

deleteAnalyzer

public void deleteAnalyzer(String analyzerId)

Delete analyzer.

Parameters:

analyzerId - The unique identifier of the analyzer.

deleteAnalyzerWithResponse

public Response<Void> deleteAnalyzerWithResponse(String analyzerId, RequestOptions requestOptions)

Delete analyzer.

Parameters:

analyzerId - The unique identifier of the analyzer.
requestOptions - The options to configure the HTTP request before HTTP client sends it.

Returns:

deleteResult

public void deleteResult(String operationId)

Mark the result of an analysis operation for deletion.

Parameters:

operationId - Operation identifier.

deleteResultWithResponse

public Response<Void> deleteResultWithResponse(String operationId, RequestOptions requestOptions)

Mark the result of an analysis operation for deletion.

Parameters:

operationId - Operation identifier.
requestOptions - The options to configure the HTTP request before HTTP client sends it.

Returns:

getAnalyzer

public ContentAnalyzer getAnalyzer(String analyzerId)

Get analyzer properties.

Parameters:

analyzerId - The unique identifier of the analyzer.

Returns:

analyzer properties.

getAnalyzerWithResponse

public Response<BinaryData> getAnalyzerWithResponse(String analyzerId, RequestOptions requestOptions)

Get analyzer properties.

Response Body Schema

{
     analyzerId: String (Required)
     description: String (Optional)
     tags (Optional): {
         String: String (Required)
     }
     status: String(creating/ready/deleting/failed) (Required)
     createdAt: OffsetDateTime (Required)
     lastModifiedAt: OffsetDateTime (Required)
     warnings (Optional): [
          (Optional){
             code: String (Required)
             message: String (Required)
             target: String (Optional)
             details (Optional): [
                 (recursive schema, see above)
             ]
             innererror (Optional): {
                 code: String (Optional)
                 innererror (Optional): (recursive schema, see innererror above)
             }
         }
     ]
     baseAnalyzerId: String (Optional)
     config (Optional): {
         returnDetails: Boolean (Optional)
         locales (Optional): [
             String (Optional)
         ]
         enableOcr: Boolean (Optional)
         enableLayout: Boolean (Optional)
         enableFigureDescription: Boolean (Optional)
         enableFigureAnalysis: Boolean (Optional)
         enableFormula: Boolean (Optional)
         tableFormat: String(html/markdown) (Optional)
         chartFormat: String(chartJs/markdown) (Optional)
         annotationFormat: String(none/markdown) (Optional)
         disableFaceBlurring: Boolean (Optional)
         estimateFieldSourceAndConfidence: Boolean (Optional)
         contentCategories (Optional): {
             String (Required): {
                 description: String (Optional)
                 analyzerId: String (Optional)
                 analyzer (Optional): (recursive schema, see analyzer above)
             }
         }
         enableSegment: Boolean (Optional)
         segmentPerPage: Boolean (Optional)
         omitContent: Boolean (Optional)
     }
     fieldSchema (Optional): {
         name: String (Optional)
         description: String (Optional)
         fields (Optional, Required on create): {
             String (Required): {
                 method: String(generate/extract/classify) (Optional)
                 type: String(string/date/time/number/integer/boolean/array/object/json) (Optional)
                 description: String (Optional)
                 items (Optional): (recursive schema, see items above)
                 properties (Optional): {
                     String (Required): (recursive schema, see String above)
                 }
                 examples (Optional): [
                     String (Optional)
                 ]
                 enum (Optional): [
                     String (Optional)
                 ]
                 enumDescriptions (Optional): {
                     String: String (Required)
                 }
                 $ref: String (Optional)
                 estimateSourceAndConfidence: Boolean (Optional)
             }
         }
         definitions (Optional): {
             String (Required): (recursive schema, see String above)
         }
     }
     dynamicFieldSchema: Boolean (Optional)
     processingLocation: String(geography/dataZone/global) (Optional)
     knowledgeSources (Optional): [
          (Optional){
             kind: String(labeledData) (Required)
         }
     ]
     models (Optional): {
         String: String (Required)
     }
     supportedModels (Optional): {
         completion (Optional): [
             String (Optional)
         ]
         embedding (Optional): [
             String (Optional)
         ]
     }
 }

Parameters:

analyzerId - The unique identifier of the analyzer.
requestOptions - The options to configure the HTTP request before HTTP client sends it.

Returns:

analyzer properties along with Response<T>.

getDefaults

public ContentUnderstandingDefaults getDefaults()

Return default settings for this Content Understanding resource.

Returns:

default settings for this Content Understanding resource.

getDefaultsWithResponse

public Response<BinaryData> getDefaultsWithResponse(RequestOptions requestOptions)

Return default settings for this Content Understanding resource.

Response Body Schema

{
     modelDeployments (Required): {
         String: String (Required)
     }
 }

Parameters:

requestOptions - The options to configure the HTTP request before HTTP client sends it.

Returns:

default settings for this Content Understanding resource along with Response<T>.

getResultFile

public BinaryData getResultFile(String operationId, String path)

Get a file associated with the result of an analysis operation.

Parameters:

operationId - Operation identifier.
path - File path.

Returns:

a file associated with the result of an analysis operation.

getResultFileWithResponse

public Response<BinaryData> getResultFileWithResponse(String operationId, String path, RequestOptions requestOptions)

Get a file associated with the result of an analysis operation.

Response Body Schema

BinaryData

Parameters:

operationId - Operation identifier.
path - File path.
requestOptions - The options to configure the HTTP request before HTTP client sends it.

Returns:

a file associated with the result of an analysis operation along with Response<T>.

grantCopyAuthorization

public CopyAuthorization grantCopyAuthorization(String analyzerId, String targetAzureResourceId)

Get authorization for copying this analyzer to another location.

Parameters:

analyzerId - The unique identifier of the analyzer.
targetAzureResourceId - Azure resource ID of the target analyzer location.

Returns:

authorization for copying this analyzer to another location.

grantCopyAuthorization

public CopyAuthorization grantCopyAuthorization(String analyzerId, String targetAzureResourceId, String targetRegion)

Get authorization for copying this analyzer to another location.

Parameters:

analyzerId - The unique identifier of the analyzer.
targetAzureResourceId - Azure resource ID of the target analyzer location.
targetRegion - Azure region of the target analyzer location. Defaults to current region.

Returns:

authorization for copying this analyzer to another location.

grantCopyAuthorizationWithResponse

public Response<BinaryData> grantCopyAuthorizationWithResponse(String analyzerId, BinaryData grantCopyAuthorizationRequest, RequestOptions requestOptions)

Get authorization for copying this analyzer to another location.

Request Body Schema

{
     targetAzureResourceId: String (Required)
     targetRegion: String (Optional)
 }

Response Body Schema

{
     source: String (Required)
     targetAzureResourceId: String (Required)
     expiresAt: OffsetDateTime (Required)
 }

Parameters:

analyzerId - The unique identifier of the analyzer.
grantCopyAuthorizationRequest - The grantCopyAuthorizationRequest parameter.
requestOptions - The options to configure the HTTP request before HTTP client sends it.

Returns:

authorization for copying this analyzer to another location along with Response<T>.

listAnalyzers

public PagedIterable<ContentAnalyzer> listAnalyzers()

List analyzers.

Returns:

paged collection of ContentAnalyzer items as paginated response with PagedIterable<T>.

listAnalyzers

public PagedIterable<BinaryData> listAnalyzers(RequestOptions requestOptions)

List analyzers.

Response Body Schema

{
     analyzerId: String (Required)
     description: String (Optional)
     tags (Optional): {
         String: String (Required)
     }
     status: String(creating/ready/deleting/failed) (Required)
     createdAt: OffsetDateTime (Required)
     lastModifiedAt: OffsetDateTime (Required)
     warnings (Optional): [
          (Optional){
             code: String (Required)
             message: String (Required)
             target: String (Optional)
             details (Optional): [
                 (recursive schema, see above)
             ]
             innererror (Optional): {
                 code: String (Optional)
                 innererror (Optional): (recursive schema, see innererror above)
             }
         }
     ]
     baseAnalyzerId: String (Optional)
     config (Optional): {
         returnDetails: Boolean (Optional)
         locales (Optional): [
             String (Optional)
         ]
         enableOcr: Boolean (Optional)
         enableLayout: Boolean (Optional)
         enableFigureDescription: Boolean (Optional)
         enableFigureAnalysis: Boolean (Optional)
         enableFormula: Boolean (Optional)
         tableFormat: String(html/markdown) (Optional)
         chartFormat: String(chartJs/markdown) (Optional)
         annotationFormat: String(none/markdown) (Optional)
         disableFaceBlurring: Boolean (Optional)
         estimateFieldSourceAndConfidence: Boolean (Optional)
         contentCategories (Optional): {
             String (Required): {
                 description: String (Optional)
                 analyzerId: String (Optional)
                 analyzer (Optional): (recursive schema, see analyzer above)
             }
         }
         enableSegment: Boolean (Optional)
         segmentPerPage: Boolean (Optional)
         omitContent: Boolean (Optional)
     }
     fieldSchema (Optional): {
         name: String (Optional)
         description: String (Optional)
         fields (Optional, Required on create): {
             String (Required): {
                 method: String(generate/extract/classify) (Optional)
                 type: String(string/date/time/number/integer/boolean/array/object/json) (Optional)
                 description: String (Optional)
                 items (Optional): (recursive schema, see items above)
                 properties (Optional): {
                     String (Required): (recursive schema, see String above)
                 }
                 examples (Optional): [
                     String (Optional)
                 ]
                 enum (Optional): [
                     String (Optional)
                 ]
                 enumDescriptions (Optional): {
                     String: String (Required)
                 }
                 $ref: String (Optional)
                 estimateSourceAndConfidence: Boolean (Optional)
             }
         }
         definitions (Optional): {
             String (Required): (recursive schema, see String above)
         }
     }
     dynamicFieldSchema: Boolean (Optional)
     processingLocation: String(geography/dataZone/global) (Optional)
     knowledgeSources (Optional): [
          (Optional){
             kind: String(labeledData) (Required)
         }
     ]
     models (Optional): {
         String: String (Required)
     }
     supportedModels (Optional): {
         completion (Optional): [
             String (Optional)
         ]
         embedding (Optional): [
             String (Optional)
         ]
     }
 }

Parameters:

requestOptions - The options to configure the HTTP request before HTTP client sends it.

Returns:

paged collection of ContentAnalyzer items as paginated response with PagedIterable<T>.

updateAnalyzer

public ContentAnalyzer updateAnalyzer(String analyzerId, ContentAnalyzer resource)

Update analyzer properties.

Parameters:

analyzerId - The unique identifier of the analyzer.
resource - The resource instance.

Returns:

analyzer that extracts content and fields from multimodal documents.

updateAnalyzerWithResponse

public Response<BinaryData> updateAnalyzerWithResponse(String analyzerId, BinaryData resource, RequestOptions requestOptions)

Update analyzer properties.

Request Body Schema

{
     analyzerId: String (Required)
     description: String (Optional)
     tags (Optional): {
         String: String (Required)
     }
     status: String(creating/ready/deleting/failed) (Required)
     createdAt: OffsetDateTime (Required)
     lastModifiedAt: OffsetDateTime (Required)
     warnings (Optional): [
          (Optional){
             code: String (Required)
             message: String (Required)
             target: String (Optional)
             details (Optional): [
                 (recursive schema, see above)
             ]
             innererror (Optional): {
                 code: String (Optional)
                 innererror (Optional): (recursive schema, see innererror above)
             }
         }
     ]
     baseAnalyzerId: String (Optional)
     config (Optional): {
         returnDetails: Boolean (Optional)
         locales (Optional): [
             String (Optional)
         ]
         enableOcr: Boolean (Optional)
         enableLayout: Boolean (Optional)
         enableFigureDescription: Boolean (Optional)
         enableFigureAnalysis: Boolean (Optional)
         enableFormula: Boolean (Optional)
         tableFormat: String(html/markdown) (Optional)
         chartFormat: String(chartJs/markdown) (Optional)
         annotationFormat: String(none/markdown) (Optional)
         disableFaceBlurring: Boolean (Optional)
         estimateFieldSourceAndConfidence: Boolean (Optional)
         contentCategories (Optional): {
             String (Required): {
                 description: String (Optional)
                 analyzerId: String (Optional)
                 analyzer (Optional): (recursive schema, see analyzer above)
             }
         }
         enableSegment: Boolean (Optional)
         segmentPerPage: Boolean (Optional)
         omitContent: Boolean (Optional)
     }
     fieldSchema (Optional): {
         name: String (Optional)
         description: String (Optional)
         fields (Optional, Required on create): {
             String (Required): {
                 method: String(generate/extract/classify) (Optional)
                 type: String(string/date/time/number/integer/boolean/array/object/json) (Optional)
                 description: String (Optional)
                 items (Optional): (recursive schema, see items above)
                 properties (Optional): {
                     String (Required): (recursive schema, see String above)
                 }
                 examples (Optional): [
                     String (Optional)
                 ]
                 enum (Optional): [
                     String (Optional)
                 ]
                 enumDescriptions (Optional): {
                     String: String (Required)
                 }
                 $ref: String (Optional)
                 estimateSourceAndConfidence: Boolean (Optional)
             }
         }
         definitions (Optional): {
             String (Required): (recursive schema, see String above)
         }
     }
     dynamicFieldSchema: Boolean (Optional)
     processingLocation: String(geography/dataZone/global) (Optional)
     knowledgeSources (Optional): [
          (Optional){
             kind: String(labeledData) (Required)
         }
     ]
     models (Optional): {
         String: String (Required)
     }
     supportedModels (Optional): {
         completion (Optional): [
             String (Optional)
         ]
         embedding (Optional): [
             String (Optional)
         ]
     }
 }

Response Body Schema

{
     analyzerId: String (Required)
     description: String (Optional)
     tags (Optional): {
         String: String (Required)
     }
     status: String(creating/ready/deleting/failed) (Required)
     createdAt: OffsetDateTime (Required)
     lastModifiedAt: OffsetDateTime (Required)
     warnings (Optional): [
          (Optional){
             code: String (Required)
             message: String (Required)
             target: String (Optional)
             details (Optional): [
                 (recursive schema, see above)
             ]
             innererror (Optional): {
                 code: String (Optional)
                 innererror (Optional): (recursive schema, see innererror above)
             }
         }
     ]
     baseAnalyzerId: String (Optional)
     config (Optional): {
         returnDetails: Boolean (Optional)
         locales (Optional): [
             String (Optional)
         ]
         enableOcr: Boolean (Optional)
         enableLayout: Boolean (Optional)
         enableFigureDescription: Boolean (Optional)
         enableFigureAnalysis: Boolean (Optional)
         enableFormula: Boolean (Optional)
         tableFormat: String(html/markdown) (Optional)
         chartFormat: String(chartJs/markdown) (Optional)
         annotationFormat: String(none/markdown) (Optional)
         disableFaceBlurring: Boolean (Optional)
         estimateFieldSourceAndConfidence: Boolean (Optional)
         contentCategories (Optional): {
             String (Required): {
                 description: String (Optional)
                 analyzerId: String (Optional)
                 analyzer (Optional): (recursive schema, see analyzer above)
             }
         }
         enableSegment: Boolean (Optional)
         segmentPerPage: Boolean (Optional)
         omitContent: Boolean (Optional)
     }
     fieldSchema (Optional): {
         name: String (Optional)
         description: String (Optional)
         fields (Optional, Required on create): {
             String (Required): {
                 method: String(generate/extract/classify) (Optional)
                 type: String(string/date/time/number/integer/boolean/array/object/json) (Optional)
                 description: String (Optional)
                 items (Optional): (recursive schema, see items above)
                 properties (Optional): {
                     String (Required): (recursive schema, see String above)
                 }
                 examples (Optional): [
                     String (Optional)
                 ]
                 enum (Optional): [
                     String (Optional)
                 ]
                 enumDescriptions (Optional): {
                     String: String (Required)
                 }
                 $ref: String (Optional)
                 estimateSourceAndConfidence: Boolean (Optional)
             }
         }
         definitions (Optional): {
             String (Required): (recursive schema, see String above)
         }
     }
     dynamicFieldSchema: Boolean (Optional)
     processingLocation: String(geography/dataZone/global) (Optional)
     knowledgeSources (Optional): [
          (Optional){
             kind: String(labeledData) (Required)
         }
     ]
     models (Optional): {
         String: String (Required)
     }
     supportedModels (Optional): {
         completion (Optional): [
             String (Optional)
         ]
         embedding (Optional): [
             String (Optional)
         ]
     }
 }

Parameters:

analyzerId - The unique identifier of the analyzer.
resource - The resource instance.
requestOptions - The options to configure the HTTP request before HTTP client sends it.

Returns:

analyzer that extracts content and fields from multimodal documents along with Response<T>.

updateDefaults

public ContentUnderstandingDefaults updateDefaults(ContentUnderstandingDefaults defaults)

Update default model deployment settings. This is a convenience method that accepts a ContentUnderstandingDefaults object.

Parameters:

defaults - The ContentUnderstandingDefaults instance with settings to update.

Returns:

the updated ContentUnderstandingDefaults.

updateDefaults

public ContentUnderstandingDefaults updateDefaults(Map<String,String> modelDeployments)

Update default model deployment settings. This is the recommended public API for updating default model deployment settings. This method provides a simpler API that accepts a Map of model names to deployment names.

Parameters:

modelDeployments - Mapping of model names to deployment names. For example: { "gpt-4.1": "myGpt41Deployment", "text-embedding-3-large": "myTextEmbedding3LargeDeployment" }.

Returns:

the updated ContentUnderstandingDefaults.

updateDefaultsWithResponse

public Response<BinaryData> updateDefaultsWithResponse(BinaryData updateDefaultsRequest, RequestOptions requestOptions)

Update default settings for this Content Understanding resource.

Request Body Schema

{
     modelDeployments (Optional): {
          (Optional): {
             String: String (Required)
         }
     }
 }

Response Body Schema

{
     modelDeployments (Required): {
         String: String (Required)
     }
 }

Parameters:

updateDefaultsRequest - The updateDefaultsRequest parameter.
requestOptions - The options to configure the HTTP request before HTTP client sends it.

Returns:

default settings for this Content Understanding resource along with Response<T>.

Applies to