diff --git a/specification/ai/ContentUnderstanding/audioVisualContent.tsp b/specification/ai/ContentUnderstanding/audioVisualContent.tsp index b7aeff14fd80..40f496e4009a 100644 --- a/specification/ai/ContentUnderstanding/audioVisualContent.tsp +++ b/specification/ai/ContentUnderstanding/audioVisualContent.tsp @@ -28,7 +28,7 @@ model AudioVisualContent extends MediaContent { @doc("Height of each video frame in pixels, if applicable.") height?: int32; - @added(Versions.v2025_05_01_preview) + // @added(Versions.v2025_05_01_preview) @doc("List of camera shot changes in the video, represented by its timestamp in milliseconds. Only if returnDetails is true.") cameraShotTimesMs?: int64[]; @@ -38,17 +38,18 @@ model AudioVisualContent extends MediaContent { @doc("List of transcript phrases. Only if returnDetails is true.") transcriptPhrases?: TranscriptPhrase[]; - @removed(Versions.v2025_05_01_preview) - @doc("List of faces in the video. Only if enableFace and returnDetails are true.") - faces?: ImageFace[]; + // @removed(Versions.v2025_05_01_preview) + // @doc("List of faces in the video. Only if enableFace and returnDetails are true.") + // faces?: ImageFace[]; - @added(Versions.v2025_05_01_preview) - @doc("List of detected persons in the video. Only if enableFace and returnDetails are true.") - persons?: DetectedPerson[]; + // @added(Versions.v2025_05_01_preview) + // @removed(Versions.v2025_11_01) + // @doc("List of detected persons in the video. Only if enableFace and returnDetails are true.") + // persons?: DetectedPerson[]; - @added(Versions.v2025_05_01_preview) - @doc("List of audio visual segments. Only if enableSegmentation and returnDetails are true.") - segments?: AudioVisualSegment[]; + @added(Versions.v2025_11_01) + @doc("List of detected content segments. Only if enableSegment is true.") + segments?: AudioVisualContentSegment[]; } @doc("Transcript phrase.") @@ -95,34 +96,55 @@ model TranscriptWord { span?: ContentSpan; } -@added(Versions.v2025_05_01_preview) -@doc("Audio visual segment, such as a scene, chapter, etc.") -model AudioVisualSegment { - @doc("Segment ID.") - segmentId: string; +// @added(Versions.v2025_05_01_preview) +// @removed(Versions.v2025_11_01) +// @doc("Audio visual segment, such as a scene, chapter, etc.") +// model AudioVisualSegment { +// @doc("Segment ID.") +// segmentId: string; - @doc("Start time of the segment in milliseconds.") - startTimeMs: int64; +// @doc("Start time of the segment in milliseconds.") +// startTimeMs: int64; - @doc("End time of the segment in milliseconds.") - endTimeMs: int64; +// @doc("End time of the segment in milliseconds.") +// endTimeMs: int64; - @doc("Short description of the segment.") - description: string; +// @doc("Short description of the segment.") +// description: string; - @doc("Span of the segment in the markdown content.") - span?: ContentSpan; -} +// @doc("Span of the segment in the markdown content.") +// span?: ContentSpan; +// } -@added(Versions.v2025_05_01_preview) -@doc("Detected person.") -model DetectedPerson { - @doc("Person identifier in the optional person directory if found. Otherwise, each unknown person is assigned a unique `Person-{Number}`.") - personId?: string; +// @added(Versions.v2025_05_01_preview) +// @removed(Versions.v2025_11_01) +// @doc("Detected person.") +// model DetectedPerson { +// @doc("Person identifier in the optional person directory if found. Otherwise, each unknown person is assigned a unique `Person-{Number}`.") +// personId?: string; - @doc("Confidence of the person identification, if a person directory is provided.") - confidence?: float32; +// @doc("Confidence of the person identification, if a person directory is provided.") +// confidence?: float32; + +// @doc("Encoded source that identifies the position of the person in the input content.") +// source?: SourceExpression; +// } - @doc("Encoded source that identifies the position of the person in the input content.") - source?: SourceExpression; +@added(Versions.v2025_11_01) +@doc("Detected audio/visual content segment.") +model AudioVisualContentSegment { + @doc("Segment identifier.") + segmentId: string; + + @doc("Classified content category.") + category: string; + + @doc("Span of the segment in the markdown content.") + span: ContentSpan; + + @doc("Start time of the segment in milliseconds.") + startTimeMs: int64; + + @doc("End time of the segment in milliseconds.") + endTimeMs: int64; } diff --git a/specification/ai/ContentUnderstanding/classifierModels.tsp b/specification/ai/ContentUnderstanding/classifierModels.tsp deleted file mode 100644 index eaaaac5da4e7..000000000000 --- a/specification/ai/ContentUnderstanding/classifierModels.tsp +++ /dev/null @@ -1,162 +0,0 @@ -import "@azure-tools/typespec-azure-core"; -import "@typespec/rest"; -import "@typespec/http"; - -using Azure.Core; -using TypeSpec.Rest; -using TypeSpec.Http; -using TypeSpec.Versioning; - -namespace ContentUnderstanding; - -@added(Versions.v2025_05_01_preview) -@doc("Classifier that classifies content into categories with optional splitting.") -@resource("classifiers") -model ContentClassifier { - @doc("The unique identifier of the classifier.") - @key - @visibility(Lifecycle.Read) - @pattern("^[a-zA-Z0-9._-]{1,64}$") - classifierId: string; - - @doc("A description of the classifier.") - description?: string; - - @doc("Tags associated with the classifier.") - tags?: Record; - - @doc("The status of the classifier.") - @visibility(Lifecycle.Read) - status: ResourceStatus; - - @doc("The date and time when the classifier was created.") - @visibility(Lifecycle.Read) - createdAt: utcDateTime; - - @doc("The date and time when the classifier was last modified.") - @visibility(Lifecycle.Read) - lastModifiedAt: utcDateTime; - - @doc("Warnings encountered while creating the classifier.") - @visibility(Lifecycle.Read) - warnings?: Azure.Core.Foundations.Error[]; - - // TODO: Do we want to provide an overall instruction? - - @doc("The categories to classify against.") - @visibility(Lifecycle.Create, Lifecycle.Read) - categories: Record; - - @doc("Mode used to split input into content objects.") - @visibility(Lifecycle.Create, Lifecycle.Read) - splitMode?: ClassifierSplitMode = ClassifierSplitMode.noSplit; - - @added(Versions.v2025_05_01_preview) - @doc("The location where the data may be processed.") - @visibility(Lifecycle.Create, Lifecycle.Read) - processingLocation?: ProcessingLocation = ProcessingLocation.geography; -} - -@added(Versions.v2025_05_01_preview) -@doc("A classifier category.") -model ClassifierCategoryDefinition { - @doc("The description of the category.") - @visibility(Lifecycle.Create, Lifecycle.Read) - description?: string; - - @doc("Optional analyzer used to process the content.") - analyzerId?: string; -} - -@added(Versions.v2025_05_01_preview) -@doc("Mode used to split input into content objects.") -union ClassifierSplitMode { - string, - - @doc("Treat the entire input as a single content object.") - noSplit: "noSplit", - - @doc("Split each page of the input into a separate content object.") - perPage: "perPage", - - @doc("Split the input into content objects based on the input and category definitions.") - auto: "auto", -} - -@added(Versions.v2025_05_01_preview) -@doc("Classify operation parameters.") -model ClassifyParameters { - // @doc("Range of the input to classify (ex. `1-3;5;9-`). Document content uses 1-based page numbers, while audio visual content uses integer milliseconds.") - // @query - // range?: RangeExpression; - - @added(Versions.v2025_05_01_preview) - @doc("The encoding format for content spans in the response.") - @query - stringEncoding?: StringEncoding = StringEncoding.codePoint; - - @added(Versions.v2025_05_01_preview) - @doc("The location where the data may be processed.") - @query - processingLocation?: ProcessingLocation; -} - -@added(Versions.v2025_05_01_preview) -@doc("Classify operation request.") -model ClassifyRequest { - ...ClassifyParameters; - - @doc("The URL of the document to classify.") - url?: url; -} - -@added(Versions.v2025_05_01_preview) -@doc("Classify operation request directly from binary content.") -model ClassifyBinaryRequest { - ...ClassifyParameters; - - #suppress "@azure-tools/typespec-azure-core/no-closed-literal-union" "Conflicts with @typespec/http/content-type-string" - @doc("Request content type.") - @header - contentType: string = "application/octet-stream"; - - @doc("The binary content of the document to classify.") - @bodyRoot - input: bytes; -} - -// @added(Versions.v2025_05_01_preview) -// @doc("...") -// model AdHocClassifyRequest { -// ...ClassifyRequest; - -// @doc("The content categories to classify against.") -// categories?: Record; - -// @doc("Mode used to split input into content objects.") -// splitMode?: ClassifierSplitMode = ClassifierSplitMode.noSplit; -// } - -@added(Versions.v2025_05_01_preview) -@doc("Classify operation result.") -model ClassifyResult { - @doc("The unique identifier of the classifier.") - @pattern("^[a-zA-Z0-9._-]{1,64}$") - classifierId?: string; - - @doc("The version of the API used to classify the document.") - apiVersion?: string; - - @doc("The date and time when the result was created.") - createdAt?: utcDateTime; - - @doc("Warnings encountered while classifying the document.") - warnings?: Azure.Core.Foundations.Error[]; - - @added(Versions.v2025_05_01_preview) - @doc("The string encoding used for content spans.") - stringEncoding?: StringEncoding = StringEncoding.codePoint; - - @doc("The classified content.") - contents: MediaContent[]; -} diff --git a/specification/ai/ContentUnderstanding/classifierRoutes.tsp b/specification/ai/ContentUnderstanding/classifierRoutes.tsp deleted file mode 100644 index 6efb11aca64e..000000000000 --- a/specification/ai/ContentUnderstanding/classifierRoutes.tsp +++ /dev/null @@ -1,97 +0,0 @@ -import "@azure-tools/typespec-azure-core"; -import "@azure-tools/typespec-client-generator-core"; -import "@typespec/rest"; -import "@typespec/http"; -import "./classifierModels.tsp"; - -using Azure.Core; -using Azure.ClientGenerator.Core; -using TypeSpec.Rest; -using TypeSpec.Http; -using TypeSpec.Versioning; - -namespace ContentUnderstanding; - -@added(Versions.v2025_05_01_preview) -interface ContentClassifiers { - @doc("Get the status of a classifier creation operation.") - getOperationStatus is Operations.GetResourceOperationStatus< - ContentClassifier, - ContentClassifier - >; - - @doc("Create a new classifier asynchronously.") - @pollingOperation(ContentClassifiers.getOperationStatus) - createOrReplace is Operations.LongRunningResourceCreateOrReplace; - - @doc("Update classifier properties.") - update is Operations.ResourceUpdate; - - @doc("Get classifier properties.") - get is Operations.ResourceRead; - - @doc("Delete classifier.") - delete is Operations.ResourceDelete; - - @doc("List classifiers.") - list is Operations.ResourceList; - - @doc("Classify content with optional splitting.") - @sharedRoute - @action("classify") - @pollingOperation(ContentClassifiers.getResult) - classify is Operations.LongRunningResourceAction< - ContentClassifier, - ClassifyRequest, - ClassifyResult - >; - - @doc("Classify content with optional splitting.") - @sharedRoute - @action("classify") - @pollingOperation(ContentClassifiers.getResult) - classifyBinary is Operations.LongRunningResourceAction< - ContentClassifier, - ClassifyBinaryRequest, - ClassifyResult - >; - - // @added(Versions.v2025_05_01_preview) - // @doc("Classify input and route to analyzers for processing using adhoc classifier.") - // @pollingOperation(ContentClassifiers.getResult) - // @action("classify") - // adHocClassify is Operations.LongRunningResourceCollectionAction< - // ContentClassifier, - // AdHocClassifyRequest, - // ClassifyResult - // >; - - #suppress "@azure-tools/typespec-azure-core/use-standard-operations" "This is a custom operation status endpoint." - @doc("Get the result of a classifier operation.") - // This operation is marked as internal because client generators automatically handle - // the polling pattern for long-running operations. When users call classify(), the - // generated SDK returns a poller that internally uses this endpoint to check status - // and retrieve results, eliminating the need for manual operation ID management. - @access(Access.internal) - @route("/classifierResults/{operationId}") - getResult is Foundations.GetOperationStatus<{}, ClassifyResult>; - - // #suppress "@azure-tools/typespec-azure-core/use-standard-operations" "Doesn't fit standard ops" - // @added(Versions.v2025_05_01_preview) - // @doc("Mark the result of a classifier operation for deletion.") - // @route("/classifierResults/{operationId}") - // @delete - // deleteResult is Foundations.Operation< - // { - // @doc("Classifier identifier.") - // @path - // classifierId: string; - - // @doc("Operation identifier.") - // @path - // operationId: string; - // }, - // TypeSpec.Http.NoContentResponse, - // ServiceTraits - // >; -} diff --git a/specification/ai/ContentUnderstanding/client.tsp b/specification/ai/ContentUnderstanding/client.tsp index 4c9795bb6a8c..b6e6cc9b9706 100644 --- a/specification/ai/ContentUnderstanding/client.tsp +++ b/specification/ai/ContentUnderstanding/client.tsp @@ -1,31 +1,95 @@ import "@azure-tools/typespec-client-generator-core"; +import "@typespec/rest"; +import "@typespec/http"; +import "@typespec/versioning"; import "./main.tsp"; using Azure.ClientGenerator.Core; using ContentUnderstanding; -// Rename type as field_type to avoid conflict with Python built-in class 'type'. -@@clientName(ArrayField.type, "field_type", "python"); -@@clientName(BooleanField.type, "field_type", "python"); -@@clientName(DateField.type, "field_type", "python"); -@@clientName(IntegerField.type, "field_type", "python"); -@@clientName(NumberField.type, "field_type", "python"); -@@clientName(ObjectField.type, "field_type", "python"); -@@clientName(StringField.type, "field_type", "python"); -@@clientName(TimeField.type, "field_type", "python"); +namespace ClientCustomizations; -// Rename 'items' to avoid conflict with Python built-in function 'items' for dictionaries. -@@clientName(ContentFieldDefinition.items, "item_definition", "python"); +@client({ + name: "ContentUnderstandingClient", + service: ContentUnderstanding, +}) +interface ContentUnderstandingClient { + // Flatten all ContentAnalyzers operations to client level + // LRO operations will automatically get "begin_" prefix in Python -@@clientName(AnalyzeBinaryRequest.input, "binary_input", "python"); -@@clientName(ClassifyBinaryRequest.input, "binary_input", "python"); + analyze is ContentAnalyzers.analyze; + + analyzeBinary is ContentAnalyzers.analyzeBinary; + + copyAnalyzer is ContentAnalyzers.copy; + + #suppress "@azure-tools/typespec-azure-core/use-standard-names" "Doesn't fit standard naming" + createAnalyzer is ContentAnalyzers.createOrReplace; + + deleteAnalyzer is ContentAnalyzers.delete; + + #suppress "@azure-tools/typespec-azure-core/use-standard-operations" "Doesn't fit standard ops" + deleteResult is ContentAnalyzers.deleteResult; + + getAnalyzer is ContentAnalyzers.get; + + #suppress "@azure-tools/typespec-azure-core/use-standard-operations" "Doesn't fit standard ops" + getDefaults is ContentAnalyzers.getDefaults; + + #suppress "@azure-tools/typespec-azure-core/use-standard-operations" "Doesn't fit standard ops" + getOperationStatus is ContentAnalyzers.getOperationStatus; + + #suppress "@azure-tools/typespec-azure-core/use-standard-operations" "Doesn't fit standard ops" + getResult is ContentAnalyzers.getResult; + + #suppress "@azure-tools/typespec-azure-core/use-standard-operations" "Doesn't fit standard ops" + getResultFile is ContentAnalyzers.getResultFile; + + grantCopyAuthorization is ContentAnalyzers.grantCopyAuthorization; + + listAnalyzers is ContentAnalyzers.list; + + updateAnalyzer is ContentAnalyzers.update; + + #suppress "@azure-tools/typespec-azure-core/use-standard-operations" "Doesn't fit standard ops" + updateDefaults is ContentAnalyzers.updateDefaults; +} + +// Rename type as fieldType to avoid conflict with built-in 'type' keyword. +@@clientName(ArrayField.type, "fieldType"); +@@clientName(BooleanField.type, "fieldType"); +@@clientName(DateField.type, "fieldType"); +@@clientName(IntegerField.type, "fieldType"); +@@clientName(NumberField.type, "fieldType"); +@@clientName(ObjectField.type, "fieldType"); +@@clientName(StringField.type, "fieldType"); +@@clientName(TimeField.type, "fieldType"); +@@clientName(JsonField.type, "fieldType"); + +// Rename 'items' to avoid conflict with built-in 'items' method. +@@clientName(ContentFieldDefinition.items, "itemDefinition"); + +@@clientName(AnalyzeBinaryRequest.input, "binaryInput"); + +// Rename 'range' to 'inputRange' for clarity that it specifies input range. +@@clientName(AnalyzeInput.range, "inputRange"); +@@clientName(AnalyzeBinaryRequest.range, "inputRange"); + +// Mark polling operations as internal - client generators automatically handle +// the polling pattern for long-running operations. When users call analyze(), the +// generated SDK returns a poller that internally uses these endpoints to check status +// and retrieve results, eliminating the need for manual operation ID management. +@@access(ContentUnderstandingClient.getResult, Access.internal); +@@access(ContentUnderstandingClient.getOperationStatus, Access.internal); // Client-only docs clarifying that these properties accept raw binary bytes (not base64 strings) in Python SDK. @@clientDoc(AnalyzeInput.data, "Raw image bytes. Provide bytes-like object; do not base64-encode. Only one of url or data should be specified.", DocumentationMode.replace ); -@@clientDoc(FaceSource.data, - "Raw image bytes. Provide bytes-like object; do not base64-encode. Only one of url or data should be specified.", - DocumentationMode.replace + +// .NET-specific naming: use GetAnalyzers instead of ListAnalyzers +@@clientName(ContentUnderstandingClient.listAnalyzers, + "getAnalyzers", + "csharp" ); diff --git a/specification/ai/ContentUnderstanding/documentContent.tsp b/specification/ai/ContentUnderstanding/documentContent.tsp index 55becf4647af..b6d6037dbd72 100644 --- a/specification/ai/ContentUnderstanding/documentContent.tsp +++ b/specification/ai/ContentUnderstanding/documentContent.tsp @@ -42,9 +42,22 @@ model DocumentContent extends MediaContent { @doc("List of figures in the document. Only if enableLayout and returnDetails are true.") figures?: DocumentFigure[]; - @added(Versions.v2025_05_01_preview) - @doc("List of detected persons in the document. Only if enableFace and returnDetails are true.") - persons?: DetectedPerson[]; + // @added(Versions.v2025_05_01_preview) + // @removed(Versions.v2025_11_01) + // @doc("List of detected persons in the document. Only if enableFace and returnDetails are true.") + // persons?: DetectedPerson[]; + + @added(Versions.v2025_11_01) + @doc("List of annotations in the document. Only if enableAnnotations and returnDetails are true.") + annotations?: DocumentAnnotation[]; + + @added(Versions.v2025_11_01) + @doc("List of hyperlinks in the document. Only if returnDetails are true.") + hyperlinks?: DocumentHyperlink[]; + + @added(Versions.v2025_11_01) + @doc("List of detected content segments. Only if enableSegment is true.") + segments?: DocumentContentSegment[]; } @doc("Length unit used by the width, height, and source properties.") @@ -174,7 +187,7 @@ model DocumentFormula { """) model DocumentParagraph { @doc("Semantic role of the paragraph.") - role?: ParagraphRole; + role?: SemanticRole; @doc("Paragraph text.") content: string; @@ -210,6 +223,10 @@ model DocumentTable { @doc("List of table footnotes.") footnotes?: DocumentFootnote[]; + + @added(Versions.v2025_11_01) + @doc("Semantic role of the table.") + role?: SemanticRole; } @doc("Table cell in a document table.") @@ -244,8 +261,28 @@ model DocumentTableCell { elements?: DocumentElement[]; } +@added(Versions.v2025_11_01) +@doc("Figure kind.") +union DocumentFigureKind { + string, + + @doc("Unknown figure kind.") + `unknown`: "unknown", + + @doc("Figure containing a chart, such as a bar chart, line chart, or pie chart.") + chart: "chart", + + @doc("Figure containing a diagram, such as a flowchart or network diagram.") + mermaid: "mermaid", +} + @doc("Figure in a document.") +@discriminator("kind") model DocumentFigure { + @added(Versions.v2025_11_01) + @doc("Figure kind.") + kind: DocumentFigureKind = DocumentFigureKind.`unknown`; + @doc("Figure identifier.") id: string; @@ -263,6 +300,35 @@ model DocumentFigure { @doc("List of figure footnotes.") footnotes?: DocumentFootnote[]; + + @added(Versions.v2025_11_01) + @doc("Description of the figure.") + description?: string; + + @added(Versions.v2025_11_01) + @doc("Semantic role of the figure.") + role?: SemanticRole; +} + +@added(Versions.v2025_11_01) +@doc("Figure containing a chart, such as a bar chart, line chart, or pie chart.") +model DocumentChartFigure extends DocumentFigure { + @doc("Figure kind.") + kind: DocumentFigureKind.chart; + + #suppress "@azure-tools/typespec-azure-core/bad-record-type" "External API shape takes an arbitrary json" + @doc("Chart content represented using [Chart.js config](https://www.chartjs.org/docs/latest/configuration/).") + content: Record; +} + +@added(Versions.v2025_11_01) +@doc("Figure containing a diagram, such as a flowchart or network diagram.") +model DocumentMermaidFigure extends DocumentFigure { + @doc("Figure kind.") + kind: DocumentFigureKind.mermaid; + + @doc("Diagram content represented using [Mermaid syntax](https://mermaid.js.org/intro/).") + content: string; } @doc("Section in a document.") @@ -378,7 +444,7 @@ union DocumentFormulaKind { } @doc("Semantic role of the paragraph.") -union ParagraphRole { +union SemanticRole { string, @doc("Text near the top edge of the page.") @@ -423,15 +489,127 @@ union DocumentTableCellKind { description: "description", } -@removed(Versions.v2025_05_01_preview) -@doc("Face in an image.") -model ImageFace { - @doc("Face identifier.") - faceId?: string; +// @removed(Versions.v2025_05_01_preview) +// @doc("Face in an image.") +// model ImageFace { +// @doc("Face identifier.") +// faceId?: string; - @doc("Confidence of predicting the face.") - confidence?: float32; +// @doc("Confidence of predicting the face.") +// confidence?: float32; + +// @doc("Encoded source that identifies the position of the face in the content.") +// source?: SourceExpression; +// } + +@added(Versions.v2025_11_01) +@doc("Annotation in a document, such as a strikethrough or a comment.") +model DocumentAnnotation { + @doc("Annotation identifier.") + id: string; + + @doc("Annotation kind.") + kind: DocumentAnnotationKind; + + @doc("Spans of the content associated with the annotation.") + spans?: ContentSpan[]; - @doc("Encoded source that identifies the position of the face in the content.") + @doc("Position of the annotation.") source?: SourceExpression; + + @doc("Comments associated with the annotation.") + comments?: DocumentAnnotationComment[]; + + @doc("Annotation author.") + author?: string; + + @doc("Date and time when the annotation was created.") + createdAt?: utcDateTime; + + @doc("Date and time when the annotation was last modified.") + lastModifiedAt?: utcDateTime; + + @doc("Tags associated with the annotation.") + tags?: string[]; +} + +@added(Versions.v2025_11_01) +@doc("Document annotation kind.") +union DocumentAnnotationKind { + string, + + @doc("Highlight annotation.") + highlight: "highlight", + + @doc("Strikethrough annotation.") + strikethrough: "strikethrough", + + @doc("Underline annotation.") + underline: "underline", + + @doc("Italic annotation.") + italic: "italic", + + @doc("Bold annotation.") + bold: "bold", + + @doc("Circle annotation.") + circle: "circle", + + @doc("Note annotation.") + note: "note", +} + +@added(Versions.v2025_11_01) +@doc("Comment associated with a document annotation.") +model DocumentAnnotationComment { + @doc("Comment message in Markdown.") + message: string; + + @doc("Author of the comment.") + author?: string; + + @doc("Date and time when the comment was created.") + createdAt?: utcDateTime; + + @doc("Date and time when the comment was last modified.") + lastModifiedAt?: utcDateTime; + + @doc("Tags associated with the comment.") + tags?: string[]; +} + +@added(Versions.v2025_11_01) +@doc("Hyperlink in a document, such as a link to a web page or an email address.") +model DocumentHyperlink { + @doc("Hyperlinked content.") + content: string; + + @doc("URL of the hyperlink.") + url: string; + + @doc("Span of the hyperlink in the markdown content.") + span?: ContentSpan; + + @doc("Position of the hyperlink.") + source?: SourceExpression; +} + +@added(Versions.v2025_11_01) +@doc("Detected document content segment.") +model DocumentContentSegment { + @doc("Segment identifier.") + segmentId: string; + + @doc("Classified content category.") + category: string; + + @doc("Span of the segment in the markdown content.") + span: ContentSpan; + + @doc("Start page number (1-indexed) of the segment.") + startPageNumber: int32; + + @doc("End page number (1-indexed) of the segment.") + endPageNumber: int32; } diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentAnalyzers_Analyze.json b/specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_Analyze.json similarity index 72% rename from specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentAnalyzers_Analyze.json rename to specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_Analyze.json index 6014aeb07b19..dca4bd216946 100644 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentAnalyzers_Analyze.json +++ b/specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_Analyze.json @@ -2,16 +2,20 @@ "title": "Analyze URL", "operationId": "ContentAnalyzers_Analyze", "parameters": { - "api-version": "2025-05-01-preview", + "api-version": "2025-11-01", "analyzerId": "myAnalyzer", "body": { - "url": "https://host.com/doc.pdf" + "inputs": [ + { + "url": "https://host.com/doc.pdf" + } + ] } }, "responses": { "202": { "headers": { - "Operation-Location": "https://myendpoint.cognitiveservices.azure.com/contentunderstanding/analyzerResults/3b31320d-8bab-4f88-b19c-2322a7f11034?api-version=2025-05-01-preview" + "Operation-Location": "https://myendpoint.cognitiveservices.azure.com/contentunderstanding/analyzerResults/3b31320d-8bab-4f88-b19c-2322a7f11034?api-version=2025-11-01" }, "body": { "id": "3b31320d-8bab-4f88-b19c-2322a7f11034", diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentAnalyzers_AnalyzeBinary.json b/specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_AnalyzeBinary.json similarity index 83% rename from specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentAnalyzers_AnalyzeBinary.json rename to specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_AnalyzeBinary.json index 137d64950de4..0e42cc4b5fd0 100644 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentAnalyzers_AnalyzeBinary.json +++ b/specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_AnalyzeBinary.json @@ -2,14 +2,14 @@ "title": "Analyze File", "operationId": "ContentAnalyzers_AnalyzeBinary", "parameters": { - "api-version": "2025-05-01-preview", + "api-version": "2025-11-01", "analyzerId": "myAnalyzer", "input": "RXhhbXBsZSBGaWxl" }, "responses": { "202": { "headers": { - "Operation-Location": "https://myendpoint.cognitiveservices.azure.com/contentunderstanding/analyzerResults/3b31320d-8bab-4f88-b19c-2322a7f11034?api-version=2025-05-01-preview" + "Operation-Location": "https://myendpoint.cognitiveservices.azure.com/contentunderstanding/analyzerResults/3b31320d-8bab-4f88-b19c-2322a7f11034?api-version=2025-11-01" }, "body": { "id": "3b31320d-8bab-4f88-b19c-2322a7f11034", diff --git a/specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_Copy.json b/specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_Copy.json new file mode 100644 index 000000000000..7e3724d7c490 --- /dev/null +++ b/specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_Copy.json @@ -0,0 +1,44 @@ +{ + "title": "Copy Analyzer", + "operationId": "ContentAnalyzers_Copy", + "parameters": { + "api-version": "2025-11-01", + "analyzerId": "targetAnalyzer", + "body": { + "sourceAzureResourceId": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.CognitiveServices/accounts/myResource", + "sourceRegion": "westus2", + "sourceAnalyzerId": "sourceAnalyzer" + } + }, + "responses": { + "202": { + "headers": { + "Operation-Location": "https://myendpoint.cognitiveservices.azure.com/contentunderstanding/analyzers/targetAnalyzer/operations/3b31320d-8bab-4f88-b19c-2322a7f11034?api-version=2025-11-01" + }, + "body": { + "analyzerId": "targetAnalyzer", + "description": "My analyzer", + "status": "creating", + "createdAt": "2025-05-01T18:46:36.051Z", + "lastModifiedAt": "2025-05-01T18:46:36.051Z", + "baseAnalyzerId": "prebuilt-document", + "config": { + "enableOcr": true, + "enableLayout": true, + "returnDetails": true + }, + "fieldSchema": { + "name": "MyForm", + "description": "My form", + "fields": { + "Company": { + "type": "string", + "description": "Name of company." + } + }, + "definitions": {} + } + } + } + } +} diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentAnalyzers_CreateOrReplace.json b/specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_CreateOrReplace.json similarity index 73% rename from specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentAnalyzers_CreateOrReplace.json rename to specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_CreateOrReplace.json index 01a42bd582ae..f5ba18471e3e 100644 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentAnalyzers_CreateOrReplace.json +++ b/specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_CreateOrReplace.json @@ -2,14 +2,14 @@ "title": "Create or Replace Analyzer", "operationId": "ContentAnalyzers_CreateOrReplace", "parameters": { - "api-version": "2025-05-01-preview", + "api-version": "2025-11-01", "analyzerId": "myAnalyzer", "resource": { "description": "My analyzer", "tags": { "createdBy": "John" }, - "baseAnalyzerId": "prebuilt-documentAnalyzer", + "baseAnalyzerId": "prebuilt-document", "config": { "enableFormula": false, "returnDetails": true @@ -25,18 +25,20 @@ }, "definitions": {} }, - "trainingData": { - "kind": "blob", - "containerUrl": "https://myStorageAccount.blob.core.windows.net/myContainer?mySasToken", - "prefix": "trainingData", - "fileListPath": "trainingData/fileList.jsonl" - } + "knowledgeSources": [ + { + "kind": "labeledData", + "containerUrl": "https://myStorageAccount.blob.core.windows.net/myContainer", + "prefix": "trainingData", + "fileListPath": "trainingData/fileList.jsonl" + } + ] } }, "responses": { "200": { "headers": { - "Operation-Location": "https://myendpoint.cognitiveservices.azure.com/contentunderstanding/analyzers/myAnalyzer/operations/3b31320d-8bab-4f88-b19c-2322a7f11034?api-version=2025-05-01-preview" + "Operation-Location": "https://myendpoint.cognitiveservices.azure.com/contentunderstanding/analyzers/myAnalyzer/operations/3b31320d-8bab-4f88-b19c-2322a7f11034?api-version=2025-11-01" }, "body": { "analyzerId": "myAnalyzer", @@ -47,10 +49,9 @@ "status": "creating", "createdAt": "2025-05-01T18:46:36.051Z", "lastModifiedAt": "2025-05-01T18:46:36.051Z", - "baseAnalyzerId": "prebuilt-documentAnalyzer", + "baseAnalyzerId": "prebuilt-document", "config": { "locales": null, - "enableFace": false, "enableOcr": true, "enableLayout": true, "enableFormula": false, @@ -67,17 +68,19 @@ }, "definitions": {} }, - "trainingData": { - "kind": "blob", - "containerUrl": "https://myStorageAccount.blob.core.windows.net/myContainer", - "prefix": "trainingData", - "fileListPath": "trainingData/fileList.jsonl" - } + "knowledgeSources": [ + { + "kind": "labeledData", + "containerUrl": "https://myStorageAccount.blob.core.windows.net/myContainer", + "prefix": "trainingData", + "fileListPath": "trainingData/fileList.jsonl" + } + ] } }, "201": { "headers": { - "Operation-Location": "https://myendpoint.cognitiveservices.azure.com/contentunderstanding/analyzers/myAnalyzer/operations/3b31320d-8bab-4f88-b19c-2322a7f11034?api-version=2025-05-01-preview" + "Operation-Location": "https://myendpoint.cognitiveservices.azure.com/contentunderstanding/analyzers/myAnalyzer/operations/3b31320d-8bab-4f88-b19c-2322a7f11034?api-version=2025-11-01" }, "body": { "analyzerId": "myAnalyzer", @@ -88,10 +91,9 @@ "status": "creating", "createdAt": "2025-05-01T18:46:36.051Z", "lastModifiedAt": "2025-05-01T18:46:36.051Z", - "baseAnalyzerId": "prebuilt-documentAnalyzer", + "baseAnalyzerId": "prebuilt-document", "config": { "locales": null, - "enableFace": false, "enableOcr": true, "enableLayout": true, "enableFormula": false, @@ -108,12 +110,14 @@ }, "definitions": {} }, - "trainingData": { - "kind": "blob", - "containerUrl": "https://myStorageAccount.blob.core.windows.net/myContainer", - "prefix": "trainingData", - "fileListPath": "trainingData/fileList.jsonl" - } + "knowledgeSources": [ + { + "kind": "labeledData", + "containerUrl": "https://myStorageAccount.blob.core.windows.net/myContainer", + "prefix": "trainingData", + "fileListPath": "trainingData/fileList.jsonl" + } + ] } } } diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentAnalyzers_DeleteAnalyzer.json b/specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_DeleteAnalyzer.json similarity index 80% rename from specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentAnalyzers_DeleteAnalyzer.json rename to specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_DeleteAnalyzer.json index c8d0eb850630..9531dc990aa3 100644 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentAnalyzers_DeleteAnalyzer.json +++ b/specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_DeleteAnalyzer.json @@ -2,7 +2,7 @@ "title": "Delete Analyzer", "operationId": "ContentAnalyzers_Delete", "parameters": { - "api-version": "2025-05-01-preview", + "api-version": "2025-11-01", "analyzerId": "myAnalyzer" }, "responses": { diff --git a/specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_DeleteResult.json b/specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_DeleteResult.json new file mode 100644 index 000000000000..eb5d9608eacb --- /dev/null +++ b/specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_DeleteResult.json @@ -0,0 +1,11 @@ +{ + "title": "Delete Analyzer Result", + "operationId": "ContentAnalyzers_DeleteResult", + "parameters": { + "api-version": "2025-11-01", + "operationId": "3b31320d-8bab-4f88-b19c-2322a7f11034" + }, + "responses": { + "204": {} + } +} diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentAnalyzers_GetAnalyzer.json b/specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_GetAnalyzer.json similarity index 71% rename from specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentAnalyzers_GetAnalyzer.json rename to specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_GetAnalyzer.json index f1fda37ca830..d12e41cc23d0 100644 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentAnalyzers_GetAnalyzer.json +++ b/specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_GetAnalyzer.json @@ -2,7 +2,7 @@ "title": "Get Analyzer", "operationId": "ContentAnalyzers_Get", "parameters": { - "api-version": "2025-05-01-preview", + "api-version": "2025-11-01", "analyzerId": "myAnalyzer" }, "responses": { @@ -16,10 +16,9 @@ "status": "creating", "createdAt": "2025-05-01T18:46:36.051Z", "lastModifiedAt": "2025-05-01T18:46:36.051Z", - "baseAnalyzerId": "prebuilt-documentAnalyzer", + "baseAnalyzerId": "prebuilt-document", "config": { "locales": null, - "enableFace": false, "enableOcr": true, "enableLayout": true, "enableFormula": false, @@ -36,12 +35,14 @@ }, "definitions": {} }, - "trainingData": { - "kind": "blob", - "containerUrl": "https://myStorageAccount.blob.core.windows.net/myContainer", - "prefix": "trainingData", - "fileListPath": "trainingData/fileList.jsonl" - } + "knowledgeSources": [ + { + "kind": "labeledData", + "containerUrl": "https://myStorageAccount.blob.core.windows.net/myContainer", + "prefix": "trainingData", + "fileListPath": "trainingData/fileList.jsonl" + } + ] } } } diff --git a/specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_GetDefaults.json b/specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_GetDefaults.json new file mode 100644 index 000000000000..7284181bec72 --- /dev/null +++ b/specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_GetDefaults.json @@ -0,0 +1,17 @@ +{ + "title": "Get Defaults", + "operationId": "ContentAnalyzers_GetDefaults", + "parameters": { + "api-version": "2025-11-01" + }, + "responses": { + "200": { + "body": { + "modelDeployments": { + "gpt-4.1": "myGpt41Deployment", + "text-embedding-3-large": "myTextEmbedding3LargeDeployment" + } + } + } + } +} diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentAnalyzers_GetOperationStatus.json b/specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_GetOperationStatus.json similarity index 75% rename from specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentAnalyzers_GetOperationStatus.json rename to specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_GetOperationStatus.json index bad83a330075..29461a247bc1 100644 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentAnalyzers_GetOperationStatus.json +++ b/specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_GetOperationStatus.json @@ -2,7 +2,7 @@ "title": "Get Analyzer Operation Status", "operationId": "ContentAnalyzers_GetOperationStatus", "parameters": { - "api-version": "2025-05-01-preview", + "api-version": "2025-11-01", "analyzerId": "myAnalyzer", "operationId": "3b31320d-8bab-4f88-b19c-2322a7f11034" }, @@ -20,10 +20,9 @@ "status": "ready", "createdAt": "2025-05-01T18:46:36.051Z", "lastModifiedAt": "2025-05-01T18:46:36.051Z", - "baseAnalyzerId": "prebuilt-documentAnalyzer", + "baseAnalyzerId": "prebuilt-document", "config": { "locales": null, - "enableFace": false, "enableOcr": true, "enableLayout": true, "enableFormula": false, @@ -40,12 +39,14 @@ }, "definitions": {} }, - "trainingData": { - "kind": "blob", - "containerUrl": "https://myStorageAccount.blob.core.windows.net/myContainer", - "prefix": "trainingData", - "fileListPath": "trainingData/fileList.jsonl" - } + "knowledgeSources": [ + { + "kind": "labeledData", + "containerUrl": "https://myStorageAccount.blob.core.windows.net/myContainer", + "prefix": "trainingData", + "fileListPath": "trainingData/fileList.jsonl" + } + ] } } } diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentAnalyzers_GetResult.json b/specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_GetResult.json similarity index 92% rename from specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentAnalyzers_GetResult.json rename to specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_GetResult.json index 4784a3fef0a8..baa13ee5651c 100644 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentAnalyzers_GetResult.json +++ b/specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_GetResult.json @@ -2,7 +2,7 @@ "title": "Get Analysis Result", "operationId": "ContentAnalyzers_GetResult", "parameters": { - "api-version": "2025-05-01-preview", + "api-version": "2025-11-01", "analyzerId": "myAnalyzer", "operationId": "3b31320d-8bab-4f88-b19c-2322a7f11034" }, @@ -13,11 +13,12 @@ "status": "Succeeded", "result": { "analyzerId": "myAnalyzer", - "apiVersion": "2025-05-01-preview", + "apiVersion": "2025-11-01", "createdAt": "2025-05-01T18:46:36.244Z", "contents": [ { "kind": "document", + "mimeType": "application/pdf", "markdown": "# CONTOSO\n\n...", "startPageNumber": 1, "endPageNumber": 2, diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentAnalyzers_GetResultFile.json b/specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_GetResultFile.json similarity index 88% rename from specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentAnalyzers_GetResultFile.json rename to specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_GetResultFile.json index 85f6d1022bf6..583f8af7abce 100644 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentAnalyzers_GetResultFile.json +++ b/specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_GetResultFile.json @@ -2,7 +2,7 @@ "title": "Get Analysis Result File", "operationId": "ContentAnalyzers_GetResultFile", "parameters": { - "api-version": "2025-05-01-preview", + "api-version": "2025-11-01", "analyzerId": "myAnalyzer", "operationId": "3b31320d-8bab-4f88-b19c-2322a7f11034", "path": "figure-1.1" diff --git a/specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_GrantCopyAuthorization.json b/specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_GrantCopyAuthorization.json new file mode 100644 index 000000000000..cc784acb03a4 --- /dev/null +++ b/specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_GrantCopyAuthorization.json @@ -0,0 +1,21 @@ +{ + "title": "Grant Copy Authorization", + "operationId": "ContentAnalyzers_GrantCopyAuthorization", + "parameters": { + "api-version": "2025-11-01", + "analyzerId": "sourceAnalyzer", + "body": { + "targetAzureResourceId": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.CognitiveServices/accounts/myResource", + "targetRegion": "westus2" + } + }, + "responses": { + "200": { + "body": { + "source": "https://myendpoint.cognitiveservices.azure.com/contentunderstanding/analyzers/sourceAnalyzer", + "targetAzureResourceId": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.CognitiveServices/accounts/myResource", + "expiresAt": "2025-12-01T18:46:36.051Z" + } + } + } +} diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentAnalyzers_List.json b/specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_List.json similarity index 82% rename from specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentAnalyzers_List.json rename to specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_List.json index a8e1d24d3866..8aa7bf8cbe99 100644 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentAnalyzers_List.json +++ b/specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_List.json @@ -2,7 +2,7 @@ "title": "List Analyzers", "operationId": "ContentAnalyzers_List", "parameters": { - "api-version": "2025-05-01-preview" + "api-version": "2025-11-01" }, "responses": { "200": { @@ -17,10 +17,9 @@ "status": "ready", "createdAt": "2025-05-01T18:46:36.051Z", "lastModifiedAt": "2025-05-01T18:46:36.051Z", - "baseAnalyzerId": "prebuilt-documentAnalyzer", + "baseAnalyzerId": "prebuilt-document", "config": { "locales": null, - "enableFace": false, "enableOcr": true, "enableLayout": true, "enableFormula": false, @@ -37,12 +36,14 @@ }, "definitions": {} }, - "trainingData": { - "kind": "blob", - "containerUrl": "https://myStorageAccount.blob.core.windows.net/myContainer", - "prefix": "trainingData", - "fileListPath": "trainingData/fileList.jsonl" - } + "knowledgeSources": [ + { + "kind": "labeledData", + "containerUrl": "https://myStorageAccount.blob.core.windows.net/myContainer", + "prefix": "trainingData", + "fileListPath": "trainingData/fileList.jsonl" + } + ] }, { "analyzerId": "myAnalyzer2", @@ -56,7 +57,6 @@ "baseAnalyzerId": "prebuilt-imageAnalyzer", "config": { "locales": null, - "enableFace": false, "enableOcr": true, "enableLayout": true, "enableFormula": false, @@ -75,7 +75,7 @@ } } ], - "nextLink": "https://myendpoint.cognitiveservices.azure.com/contentunderstanding/analyzers?nextLink=nextLinkData&api-version=2025-05-01-preview" + "nextLink": "https://myendpoint.cognitiveservices.azure.com/contentunderstanding/analyzers?nextLink=nextLinkData&api-version=2025-11-01" } } } diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentAnalyzers_Update.json b/specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_Update.json similarity index 75% rename from specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentAnalyzers_Update.json rename to specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_Update.json index 8e63c7164ab3..22e952b3e2f2 100644 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentAnalyzers_Update.json +++ b/specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_Update.json @@ -2,7 +2,7 @@ "title": "Update Analyzer", "operationId": "ContentAnalyzers_Update", "parameters": { - "api-version": "2025-05-01-preview", + "api-version": "2025-11-01", "analyzerId": "myAnalyzer", "resource": { "description": "Updated analyzer description.", @@ -23,10 +23,9 @@ "status": "succeeded", "createdAt": "2025-05-01T18:46:36.051Z", "lastModifiedAt": "2025-05-01T18:46:36.051Z", - "baseAnalyzerId": "prebuilt-documentAnalyzer", + "baseAnalyzerId": "prebuilt-document", "config": { "locales": null, - "enableFace": false, "enableOcr": true, "enableLayout": true, "enableFormula": false, @@ -43,12 +42,14 @@ }, "definitions": {} }, - "trainingData": { - "kind": "blob", - "containerUrl": "https://myStorageAccount.blob.core.windows.net/myContainer", - "prefix": "trainingData", - "fileListPath": "trainingData/fileList.jsonl" - } + "knowledgeSources": [ + { + "kind": "labeledData", + "containerUrl": "https://myStorageAccount.blob.core.windows.net/myContainer", + "prefix": "trainingData", + "fileListPath": "trainingData/fileList.jsonl" + } + ] } } } diff --git a/specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_UpdateDefaults.json b/specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_UpdateDefaults.json new file mode 100644 index 000000000000..866e47085042 --- /dev/null +++ b/specification/ai/ContentUnderstanding/examples/2025-11-01/ContentAnalyzers_UpdateDefaults.json @@ -0,0 +1,22 @@ +{ + "title": "Update Defaults", + "operationId": "ContentAnalyzers_UpdateDefaults", + "parameters": { + "api-version": "2025-11-01", + "body": { + "modelDeployments": { + "gpt-4.1": "newGpt41Deployment" + } + } + }, + "responses": { + "200": { + "body": { + "modelDeployments": { + "gpt-4.1": "newGpt41Deployment", + "text-embedding-3-large": "myTextEmbedding3LargeDeployment" + } + } + } + } +} diff --git a/specification/ai/ContentUnderstanding/main.tsp b/specification/ai/ContentUnderstanding/main.tsp index 117cca1e23e1..59627795b7a1 100644 --- a/specification/ai/ContentUnderstanding/main.tsp +++ b/specification/ai/ContentUnderstanding/main.tsp @@ -4,27 +4,15 @@ import "@typespec/versioning"; import "@azure-tools/typespec-azure-core"; import "./routes.tsp"; import "./personDirectoryRoutes.tsp"; -import "./classifierRoutes.tsp"; import "./models.tsp"; import "./documentContent.tsp"; import "./audioVisualContent.tsp"; using TypeSpec.Http; -using TypeSpec.Rest; using TypeSpec.Versioning; -using Azure.Core; @doc("The Content Understanding service extracts content and fields from multimodal input.") -@useAuth( - ApiKeyAuth | OAuth2Auth<[ - { - type: OAuth2FlowType.authorizationCode, - authorizationUrl: "https://login.microsoftonline.com/common/oauth2/authorize", - tokenUrl: "https://login.microsoftonline.com/common/oauth2/token", - scopes: ["https://cognitiveservices.azure.com/.default"], - } - ]> -) +@useAuth(AzureKey | EntraIdToken) @service(#{ title: "Content Understanding" }) @server( "{endpoint}/contentunderstanding", @@ -37,12 +25,22 @@ using Azure.Core; @versioned(ContentUnderstanding.Versions) namespace ContentUnderstanding; +@doc("Key-based authentication using the access key of the Azure resource.") +model AzureKey + is ApiKeyAuth; + +@doc("Microsoft Entra ID OAuth2 authentication using an access token.") +model EntraIdToken + is Azure.Core.AadOauth2Auth<["https://cognitiveservices.azure.com/.default"]>; + @doc("Service API versions.") enum Versions { - // // @doc("The 2024-12-01-preview version of the Content Understanding service.") // v2024_12_01_preview: "2024-12-01-preview", - @doc("The 2025-05-01-preview version of the Content Understanding service.") - v2025_05_01_preview: "2025-05-01-preview", + // @doc("The 2025-05-01-preview version of the Content Understanding service.") + // v2025_05_01_preview: "2025-05-01-preview", + + @doc("The 2025-11-01 version of the Content Understanding service.") + v2025_11_01: "2025-11-01", } diff --git a/specification/ai/ContentUnderstanding/models.tsp b/specification/ai/ContentUnderstanding/models.tsp index f0a14682a84d..306d75dcc439 100644 --- a/specification/ai/ContentUnderstanding/models.tsp +++ b/specification/ai/ContentUnderstanding/models.tsp @@ -1,6 +1,5 @@ import "@azure-tools/typespec-azure-core"; import "@azure-tools/typespec-client-generator-core"; - import "@typespec/rest"; import "@typespec/http"; @@ -19,6 +18,8 @@ model ContentAnalyzer { @key @visibility(Lifecycle.Read) @pattern("^[a-zA-Z0-9._-]{1,64}$") + @minLength(1) + @maxLength(64) analyzerId: string; @doc("A description of the analyzer.") @@ -29,7 +30,7 @@ model ContentAnalyzer { @doc("The status of the analyzer.") @visibility(Lifecycle.Read) - status: ResourceStatus; + status: ContentAnalyzerStatus; @doc("The date and time when the analyzer was created.") @visibility(Lifecycle.Read) @@ -46,12 +47,14 @@ model ContentAnalyzer { @doc("The analyzer to incrementally train from.") @visibility(Lifecycle.Create, Lifecycle.Read) @pattern("^[a-zA-Z0-9._-]{1,64}$") + @minLength(1) + @maxLength(64) baseAnalyzerId?: string; - @removed(Versions.v2025_05_01_preview) - @doc("The scenario for which the analyzer is optimized.") - @visibility(Lifecycle.Create, Lifecycle.Read) - scenario?: string; + // @removed(Versions.v2025_05_01_preview) + // @doc("The scenario for which the analyzer is optimized.") + // @visibility(Lifecycle.Create, Lifecycle.Read) + // scenario?: string; @doc("Analyzer configuration settings.") @visibility(Lifecycle.Create, Lifecycle.Read) @@ -61,32 +64,58 @@ model ContentAnalyzer { @visibility(Lifecycle.Create, Lifecycle.Read) fieldSchema?: FieldSchema; - @doc("The data source containing training data for the analyzer.") + @added(Versions.v2025_11_01) + @doc("Indicates whether the result may contain additional fields outside of the defined schema.") @visibility(Lifecycle.Create, Lifecycle.Read) - trainingData?: DataSource; + dynamicFieldSchema?: boolean = false; - @added(Versions.v2025_05_01_preview) - @doc("The location where the data may be processed.") - @visibility(Lifecycle.Create, Lifecycle.Read) - processingLocation?: ProcessingLocation = ProcessingLocation.geography; + // @removed(Versions.v2025_11_01) + // @doc("The data source containing training data for the analyzer.") + // @visibility(Lifecycle.Create, Lifecycle.Read) + // trainingData?: DataSource; - @added(Versions.v2025_05_01_preview) - @doc("The analysis mode: standard, pro. Default is standard.") + // @added(Versions.v2025_05_01_preview) + @doc("The location where the data may be processed. Defaults to global.") @visibility(Lifecycle.Create, Lifecycle.Read) - mode?: AnalysisMode = AnalysisMode.standard; + processingLocation?: ProcessingLocation = ProcessingLocation.global; // @added(Versions.v2025_05_01_preview) - // @doc("The processing priority: normal, low. Default is normal.") + // @removed(Versions.v2025_11_01) + // @doc("The analysis mode: standard, pro. Default is standard.") // @visibility(Lifecycle.Create, Lifecycle.Read) - // priority?: ProcessingPriority = ProcessingPriority.normal; + // mode?: AnalysisMode = AnalysisMode.standard; - @added(Versions.v2025_05_01_preview) + // @added(Versions.v2025_05_01_preview) @doc("Additional knowledge sources used to enhance the analyzer.") + @visibility(Lifecycle.Create, Lifecycle.Read) knowledgeSources?: KnowledgeSource[]; + + @added(Versions.v2025_11_01) + @doc(""" + Mapping of model roles to specific model names. + Ex. { "completion": "gpt-4.1", "embedding": "text-embedding-3-large" }. + """) + @visibility(Lifecycle.Create, Lifecycle.Read) + models?: Record; + + @added(Versions.v2025_11_01) + @doc("Chat completion and embedding models supported by the analyzer.") + @visibility(Lifecycle.Read) + supportedModels?: SupportedModels; +} + +@added(Versions.v2025_11_01) +@doc("Chat completion and embedding models supported by the analyzer.") +model SupportedModels { + @doc("Chat completion models supported by the analyzer.") + completion: Record; + + @doc("Embedding models supported by the analyzer.") + embedding: Record; } @doc("Status of a resource.") -union ResourceStatus { +union ContentAnalyzerStatus { string, @doc("The resource is being created.") @@ -102,6 +131,7 @@ union ResourceStatus { failed: "failed", } +// @added(Versions.v2025_05_01_preview) @doc("The location where the data may be processed.") union ProcessingLocation { string, @@ -116,43 +146,34 @@ union ProcessingLocation { global: "global", } -@added(Versions.v2025_05_01_preview) -@doc("Analysis mode.") -union AnalysisMode { - string, - - // @doc("Lite analysis mode.") - // lite: "lite", - - @doc("Standard analysis mode.") - standard: "standard", - - @doc("Pro analysis mode.") - pro: "pro", -} - // @added(Versions.v2025_05_01_preview) -// @doc("Processing priority.") -// union ProcessingPriority { +// @removed(Versions.v2025_11_01) +// @doc("Analysis mode.") +// union AnalysisMode { // string, -// @doc("Normal processing priority.") -// normal: "normal", +// @doc("Standard analysis mode.") +// standard: "standard", -// @doc("Low processing priority. Allow processing of larger inputs.") -// low: "low", +// @doc("Pro analysis mode.") +// pro: "pro", // } -@added(Versions.v2025_05_01_preview) +// @added(Versions.v2025_05_01_preview) @doc("Knowledge source kind.") union KnowledgeSourceKind { string, - @doc("A reference knowledge source.") - reference: "reference", + // @removed(Versions.v2025_11_01) + // @doc("A reference knowledge source.") + // reference: "reference", + + @added(Versions.v2025_11_01) + @doc("A labeled data knowledge source.") + labeledData: "labeledData", } -@added(Versions.v2025_05_01_preview) +// @added(Versions.v2025_05_01_preview) @doc("Knowledge source.") @discriminator("kind") model KnowledgeSource { @@ -160,19 +181,36 @@ model KnowledgeSource { kind: KnowledgeSourceKind; } -@added(Versions.v2025_05_01_preview) -@doc("File knowledge source.") -model ReferenceKnowledgeSource extends KnowledgeSource { - @doc("Indicates that the knowledge source is a reference knowledge source.") - kind: KnowledgeSourceKind.reference; +// @added(Versions.v2025_05_01_preview) +// @removed(Versions.v2025_11_01) +// @doc("File knowledge source.") +// model ReferenceKnowledgeSource extends KnowledgeSource { +// @doc("A blob container containing reference data for analysis.") +// kind: KnowledgeSourceKind.reference; + +// @doc("The URL of the blob container.") +// containerUrl: url; - @doc("The URL of the blob container.") +// @doc("An optional prefix to filter blobs within the container.") +// prefix?: string; + +// @doc("Path to a file listing specific blobs to include.") +// fileListPath: string; +// } + +@added(Versions.v2025_11_01) +@doc("Labeled data knowledge source.") +model LabeledDataKnowledgeSource extends KnowledgeSource { + @doc("A blob container containing labeled data.") + kind: KnowledgeSourceKind.labeledData; + + @doc("The URL of the blob container containing labeled data.") containerUrl: url; @doc("An optional prefix to filter blobs within the container.") prefix?: string; - @doc("Path to a file listing specific blobs to include.") + @doc("An optional path to a file listing specific blobs to include.") fileListPath: string; } @@ -204,12 +242,14 @@ model ContentAnalyzerConfig { @doc("List of locale hints for speech transcription.") locales?: string[]; - @doc("Enable face detection.") - enableFace?: boolean; + // @removed(Versions.v2025_11_01) + // @doc("Enable face detection.") + // enableFace?: boolean; - @added(Versions.v2025_05_01_preview) - @doc("Specify the person directory used for identifying detected faces.") - personDirectoryId?: string; + // @added(Versions.v2025_05_01_preview) + // @removed(Versions.v2025_11_01) + // @doc("Specify the person directory used for identifying detected faces.") + // personDirectoryId?: string; @doc("Enable optical character recognition (OCR).") enableOcr?: boolean; @@ -217,39 +257,77 @@ model ContentAnalyzerConfig { @doc("Enable layout analysis.") enableLayout?: boolean; - @added(Versions.v2025_05_01_preview) - @doc("Representation format of tables in analyze result markdown.") - tableFormat?: TableFormat = TableFormat.html; + @added(Versions.v2025_11_01) + @doc("Enable generation of figure description.") + enableFigureDescription?: boolean; - @removed(Versions.v2025_05_01_preview) - @doc("Enable barcode detection.") - enableBarcode?: boolean; + @added(Versions.v2025_11_01) + @doc("Enable analysis of figures, such as charts and diagrams.") + enableFigureAnalysis?: boolean; + + // @removed(Versions.v2025_05_01_preview) + // @doc("Enable barcode detection.") + // enableBarcode?: boolean; @doc("Enable mathematical formula detection.") enableFormula?: boolean; - @added(Versions.v2025_05_01_preview) + // @added(Versions.v2025_05_01_preview) + @doc("Representation format of tables in analyze result markdown.") + tableFormat?: TableFormat = TableFormat.html; + + @added(Versions.v2025_11_01) + @doc("Representation format of charts in analyze result markdown.") + chartFormat?: ChartFormat = ChartFormat.chartJs; + + @added(Versions.v2025_11_01) + @doc("Representation format of annotations in analyze result markdown.") + annotationFormat?: AnnotationFormat = AnnotationFormat.markdown; + + // @added(Versions.v2025_05_01_preview) @doc("Disable the default blurring of faces for privacy while processing the content.") disableFaceBlurring?: boolean; - @added(Versions.v2025_05_01_preview) - @doc("Disable content filtering that detects and prevents the output of harmful content.") - disableContentFiltering?: boolean; + // @added(Versions.v2025_05_01_preview) + // @removed(Versions.v2025_11_01) + // @doc("Disable content filtering that detects and prevents the output of harmful content.") + // disableContentFiltering?: boolean; - @added(Versions.v2025_05_01_preview) - @doc("Return grounding source and confidence for extracted fields.") + // @added(Versions.v2025_05_01_preview) + @doc("Return field grounding source and confidence.") estimateFieldSourceAndConfidence?: boolean; - @added(Versions.v2025_05_01_preview) - @doc("Segmentation mode used to split audio/visual content.") - segmentationMode?: SegmentationMode = SegmentationMode.noSegmentation; + // @added(Versions.v2025_05_01_preview) + // @removed(Versions.v2025_11_01) + // @doc("Segmentation mode used to split audio/visual content.") + // segmentationMode?: SegmentationMode = SegmentationMode.noSegmentation; + + // @added(Versions.v2025_05_01_preview) + // @removed(Versions.v2025_11_01) + // @doc("Segmentation definition for use with custom segmentation mode.") + // segmentationDefinition?: string; + + @added(Versions.v2025_11_01) + @doc("Map of categories to classify the input content(s) against.") + contentCategories?: Record; + + @added(Versions.v2025_11_01) + @doc("Enable segmentation of the input by contentCategories.") + enableSegment?: boolean; - @added(Versions.v2025_05_01_preview) - @doc("Segmentation definition for use with custom segmentation mode.") - segmentationDefinition?: string; + @added(Versions.v2025_11_01) + @doc("Force segmentation of document content by page.") + segmentPerPage?: boolean; + + @added(Versions.v2025_11_01) + @doc(""" + Omit the content for this analyzer from analyze result. + Only return content(s) from additional analyzers specified in contentCategories, if any. + """) + omitContent?: boolean; } -@added(Versions.v2025_05_01_preview) +// @added(Versions.v2025_05_01_preview) @doc("Representation format of tables in analyze result markdown.") union TableFormat { string, @@ -257,59 +335,88 @@ union TableFormat { @doc("Represent tables using HTML table elements: \\, \\, \\
, \\
.") html: "html", - // @doc("Represent tables using GitHub Flavored Markdown table syntax, which does not support merged cells or rich headers.") - // markdown: "markdown", + @added(Versions.v2025_11_01) + @doc("Represent tables using GitHub Flavored Markdown table syntax, which does not support merged cells or rich headers.") + markdown: "markdown", } -@added(Versions.v2025_05_01_preview) -@doc("Segmentation mode used to split audio/visual content.") -union SegmentationMode { +@added(Versions.v2025_11_01) +@doc("Representation format of charts in analyze result markdown.") +union ChartFormat { string, - @doc("No segmentation.") - noSegmentation: "noSegmentation", + @doc("Represent charts as Chart.js code blocks.") + chartJs: "chartJs", - @doc("Automatic segmentation.") - auto: "auto", - - @doc("Segment according to custom segmentation definition.") - custom: "custom", + @doc("Represent charts as markdown tables.") + markdown: "markdown", } -@doc("Data source kind.") -union DataSourceKind { +@added(Versions.v2025_11_01) +@doc("Representation format of annotations in analyze result markdown.") +union AnnotationFormat { string, - @doc("A blob storage data source.") - blob: "blob", -} + @doc("Do not represent annotations.") + none: "none", -@doc("Data source specifying a set of documents.") -@discriminator("kind") -model DataSource { - @doc("The kind of data source.") - kind: DataSourceKind; + @doc("Represent basic annotation information using markdown formatting.") + markdown: "markdown", } -@doc("Blob storage data source.") -model BlobDataSource extends DataSource { - @doc("Indicates that the data source is a blob.") - kind: "blob"; +// @added(Versions.v2025_05_01_preview) +// @removed(Versions.v2025_11_01) +// @doc("Segmentation mode used to split audio/visual content.") +// union SegmentationMode { +// string, - @doc("The URL of the blob container.") - containerUrl: url; +// @doc("No segmentation.") +// noSegmentation: "noSegmentation", - @doc("An optional prefix to filter blobs within the container.") - prefix?: string; +// @doc("Automatic segmentation.") +// auto: "auto", - @doc("An optional path to a file listing specific blobs to include.") - fileListPath?: string; -} +// @doc("Segment according to custom segmentation definition.") +// custom: "custom", +// } + +// @removed(Versions.v2025_11_01) +// @doc("Data source kind.") +// union DataSourceKind { +// string, + +// @doc("A blob storage data source.") +// blob: "blob", +// } + +// @removed(Versions.v2025_11_01) +// @doc("Data source specifying a set of documents.") +// @discriminator("kind") +// model DataSource { +// @doc("The kind of data source.") +// kind: DataSourceKind; +// } + +// @removed(Versions.v2025_11_01) +// @doc("Blob storage data source.") +// model BlobDataSource extends DataSource { +// @doc("Indicates that the data source is a blob.") +// kind: "blob"; + +// @doc("The URL of the blob container.") +// containerUrl: url; + +// @doc("An optional prefix to filter blobs within the container.") +// prefix?: string; + +// @doc("An optional path to a file listing specific blobs to include.") +// fileListPath?: string; +// } @doc("Definition of the field using a JSON Schema like syntax.") model ContentFieldDefinition { @doc("Generation method.") - method?: GenerationMethod = GenerationMethod.generate; + method?: GenerationMethod; @doc("Semantic data type of the field value.") type?: ContentFieldType; @@ -334,6 +441,10 @@ model ContentFieldDefinition { @doc("Reference to another field definition.") $ref?: string; + + @added(Versions.v2025_11_01) + @doc("Return grounding source and confidence.") + estimateSourceAndConfidence?: boolean; } @doc("Generation method.") @@ -377,73 +488,92 @@ union ContentFieldType { @doc("Named list of subfields.") object: "object", -} -@added(Versions.v2025_05_01_preview) -@doc("String encoding format.") -union StringEncoding { - string, + @added(Versions.v2025_11_01) + @doc("JSON object.") + json: "json", +} - @doc("Unicode code point (UTF-32) encoding, used by languages such as Python, etc.") - codePoint: "codePoint", +@added(Versions.v2025_11_01) +@doc("Content category definition.") +model ContentCategoryDefinition { + @doc("The description of the category.") + description?: string; - @doc("UTF-16 encoding, used by languages such as C#, JavaScript, Java, etc.") - utf16: "utf16", + @doc("Optional analyzer used to process the content.") + analyzerId?: string; - @doc("UTF-8 encoding, used by languages such as Go, Rust, Ruby, PHP, etc.") - utf8: "utf8", + @doc("Optional inline definition of analyzer used to process the content.") + analyzer?: ContentAnalyzer; } @doc("Analyze operation parameters.") model AnalyzeParameters { // @added(Versions.v2025_05_01_preview) - // @doc("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.") - // @query - // range?: RangeExpression; - - @added(Versions.v2025_05_01_preview) - @doc("The encoding format for content spans in the response.") - @query - stringEncoding?: StringEncoding = StringEncoding.codePoint; - - @added(Versions.v2025_05_01_preview) - @doc("The location where the data may be processed.") + @doc(""" + The string encoding format for content spans in the response. + Possible values are 'codePoint', 'utf16', and `utf8`. Default is `codePoint`.") + """) @query - processingLocation?: ProcessingLocation; + stringEncoding?: string = "codePoint"; // @added(Versions.v2025_05_01_preview) - // @doc("The processing priority: normal, low. Default is normal.") - // @query - // priority?: ProcessingPriority = ProcessingPriority.normal; + @doc("The location where the data may be processed. Defaults to global.") + @query + processingLocation?: ProcessingLocation = ProcessingLocation.global; } @doc("Analyze operation request.") model AnalyzeRequest { ...AnalyzeParameters; - @doc("The URL of the primary input to analyze. Only one of url or data should be specified.") - url?: url; + // @removed(Versions.v2025_11_01) + // @doc("The URL of the primary input to analyze. Only one of url or data should be specified.") + // url?: url; - @added(Versions.v2025_05_01_preview) - @doc("Base64-encoded binary content of the primary input to analyze. Only one of url or data should be specified.") - data?: bytes; + // @removed(Versions.v2025_11_01) + // @added(Versions.v2025_05_01_preview) + // @doc("Base64-encoded binary content of the primary input to analyze. Only one of url or data should be specified.") + // data?: bytes; - @added(Versions.v2025_05_01_preview) - @doc("Additional inputs to analyze. Only supported in analyzers with mode=pro.") + // @added(Versions.v2025_05_01_preview) + @doc("Inputs to analyze. Currently, only pro mode supports multiple inputs.") inputs?: AnalyzeInput[]; + + @added(Versions.v2025_11_01) + @doc(""" + Override default mapping of model names to deployments. + Ex. { "gpt-4.1": "myGpt41Deployment", "text-embedding-3-large": "myTextEmbedding3LargeDeployment" }. + """) + modelDeployments?: Record; } -@added(Versions.v2025_05_01_preview) +@added(Versions.v2025_11_01) +@doc(""" + Range expression for specifying parts of the input to analyze (ex. `1-3,5,9-`). + Document content uses 1-based page numbers, while audio visual content uses integer milliseconds. + """) +scalar RangeExpression extends string; + +// @added(Versions.v2025_05_01_preview) @doc("Additional input to analyze.") model AnalyzeInput { @doc("The URL of the input to analyze. Only one of url or data should be specified.") - url: url; + url?: url; @doc("Base64-encoded binary content of the input to analyze. Only one of url or data should be specified.") data?: bytes; @doc("Name of the input.") name?: string; + + @added(Versions.v2025_11_01) + @doc("The MIME type of the input content. Ex. application/pdf, image/jpeg, etc.") + mimeType?: string; + + @added(Versions.v2025_11_01) + @doc("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.") + range?: RangeExpression; } @doc("Analyze operation request directly from binary content.") @@ -458,19 +588,22 @@ model AnalyzeBinaryRequest { @doc("The binary content of the document to analyze.") @bodyRoot input: bytes; + + @added(Versions.v2025_11_01) + @doc("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.") + @query + range?: RangeExpression; } @doc("Get result operation parameters.") -model GetResultParameters { - // @doc("Embed images as base64 data URIs in Markdown.") - // @query - // embedImages?: boolean; -} +model GetResultParameters {} @doc("Analyze operation result.") model AnalyzeResult { @doc("The unique identifier of the analyzer.") @pattern("^[a-zA-Z0-9._-]{1,64}$") + @minLength(1) + @maxLength(64) analyzerId?: string; @doc("The version of the API used to analyze the document.") @@ -482,9 +615,12 @@ model AnalyzeResult { @doc("Warnings encountered while analyzing the document.") warnings?: Azure.Core.Foundations.Error[]; - @added(Versions.v2025_05_01_preview) - @doc("The string encoding used for content spans.") - stringEncoding?: StringEncoding = StringEncoding.codePoint; + // @added(Versions.v2025_05_01_preview) + @doc(""" + The string encoding format for content spans in the response. + Possible values are 'codePoint', 'utf16', and `utf8`. Default is `codePoint`.") + """) + stringEncoding?: string = "codePoint"; @doc("The extracted content.") contents: MediaContent[]; @@ -507,18 +643,24 @@ model MediaContent { @doc("Content kind.") kind: MediaContentKind; - // TODO: Should be required. - @added(Versions.v2025_05_01_preview) + // @added(Versions.v2025_05_01_preview) @doc("Detected MIME type of the content. Ex. application/pdf, image/jpeg, etc.") - mimeType?: string; + mimeType: string; + + @added(Versions.v2025_11_01) + @doc("The analyzer that generated this content.") + @pattern("^[a-zA-Z0-9._-]{1,64}$") + @minLength(1) + @maxLength(64) + analyzerId?: string; - @added(Versions.v2025_05_01_preview) + // @added(Versions.v2025_05_01_preview) @doc("Classified content category.") category?: string; - @added(Versions.v2025_05_01_preview) + // @added(Versions.v2025_05_01_preview) @doc("The path of the content in the input.") - path?: url; + path?: string; @doc("Markdown representation of the content.") markdown?: string; @@ -628,3 +770,113 @@ model ObjectField extends ContentField { @doc("Object field value.") valueObject?: Record; } + +@added(Versions.v2025_11_01) +@doc("JSON field extracted from the content.") +model JsonField extends ContentField { + @doc("Semantic data type of the field value.") + type: ContentFieldType.json; + + #suppress "@azure-tools/typespec-azure-core/no-unknown" "Property value is dynamic and can be any JSON object." + @doc("JSON field value.") + valueJson?: unknown; +} + +@added(Versions.v2025_11_01) +@doc("Usage details.") +model UsageDetails { + @doc(""" + The number of document pages processed at the minimal level. + For documents without explicit pages (ex. txt, html), every 3000 UTF-16 characters is counted as one page. + """) + documentPagesMinimal?: int32; + + @doc(""" + The number of document pages processed at the basic level. + For documents without explicit pages (ex. txt, html), every 3000 UTF-16 characters is counted as one page. + """) + documentPagesBasic?: int32; + + @doc(""" + The number of document pages processed at the standard level. + For documents without explicit pages (ex. txt, html), every 3000 UTF-16 characters is counted as one page. + """) + documentPagesStandard?: int32; + + @doc("The hours of audio processed.") + audioHours?: float32; + + @doc("The hours of video processed.") + videoHours?: float32; + + @doc("The number of contextualization tokens consumed for preparing context, generating confidence scores, source grounding, and output formatting.") + contextualizationTokens?: int32; + + @doc("The number of LLM and embedding tokens consumed, grouped by model (ex. GTP 4.1) and type (ex. input, cached input, output).") + tokens?: Record; +} + +@added(Versions.v2025_11_01) +@doc("Copy authorization details for cross-resource copy.") +model CopyAuthorization { + @doc("Full path of the source analyzer.") + source: string; + + @doc("Azure resource ID of the target location to copy to.") + targetAzureResourceId: string; + + @doc("Date/time when the copy authorization expires.") + expiresAt: utcDateTime; +} + +@doc("Provides status details for analyzer creation operations.") +model ContentAnalyzerOperationStatus { + ...Azure.Core.Foundations.OperationStatus; + + @added(Versions.v2025_11_01) + @doc("Usage details of the analyzer creation operation.") + usage?: UsageDetails; +} + +@doc("Provides status details for analyze operations.") +model ContentAnalyzerAnalyzeOperationStatus { + ...Azure.Core.Foundations.OperationStatus; + + @added(Versions.v2025_11_01) + @doc("Usage details of the analyze operation.") + usage?: UsageDetails; +} + +@added(Versions.v2025_11_01) +@doc("default settings for this Content Understanding resource.") +model ContentUnderstandingDefaults { + @doc(""" + Mapping of model names to deployments. + Ex. { "gpt-4.1": "myGpt41Deployment", "text-embedding-3-large": "myTextEmbedding3LargeDeployment" }. + """) + @visibility(Lifecycle.Create, Lifecycle.Read, Lifecycle.Update) + modelDeployments: Record; +} + +@added(Versions.v2025_11_01) +@doc("Copy operation request.") +model CopyRequest { + @doc("Azure resource ID of the source analyzer location. Defaults to the current resource.") + sourceAzureResourceId?: string; + + @doc("Azure region of the source analyzer location. Defaults to current region.") + sourceRegion?: string; + + @doc("Source analyzer ID.") + sourceAnalyzerId: string; +} + +@added(Versions.v2025_11_01) +@doc("Grant copy authorization request.") +model GrantCopyAuthorizationRequest { + @doc("Azure resource ID of the target analyzer location.") + targetAzureResourceId: string; + + @doc("Azure region of the target analyzer location. Defaults to current region.") + targetRegion?: string; +} diff --git a/specification/ai/ContentUnderstanding/personDirectoryModels.tsp b/specification/ai/ContentUnderstanding/personDirectoryModels.tsp index 6765d0a6c211..fcca30d5360e 100644 --- a/specification/ai/ContentUnderstanding/personDirectoryModels.tsp +++ b/specification/ai/ContentUnderstanding/personDirectoryModels.tsp @@ -12,292 +12,292 @@ using TypeSpec.Versioning; namespace ContentUnderstanding; -@added(Versions.v2025_05_01_preview) -@doc("Bounding box in an image.") -model BoundingBox { - @doc("Left coordinate of the bounding box.") - left: int32; - - @doc("Top coordinate of the bounding box.") - top: int32; - - @doc("Width of the bounding box.") - width: int32; - - @doc("Height of the bounding box.") - height: int32; -} - -@added(Versions.v2025_05_01_preview) -@doc("Input face source with an optional target bounding box. If not specified, the largest face will be used.") -model FaceSource { - @doc("Image URL. Only one of url or data should be specified.") - url?: url; - - @doc("Base64-encoded image data. Only one of url or data should be specified.") - data?: bytes; - - @doc("User provided identifier for the source image.") - imageReferenceId?: string; - - @doc("Bounding box specifying the region of interest.") - targetBoundingBox?: BoundingBox; -} - -@added(Versions.v2025_05_01_preview) -@doc("Detected bounding box of an object.") -model DetectedBoundingBox { - @doc("Bounding box of the detected face.") - boundingBox?: BoundingBox; - - // confidence: float32; -} - -@added(Versions.v2025_05_01_preview) -@doc("Directory of people and their faces.") -@resource("personDirectories") -model PersonDirectory { - @doc("The unique identifier of the person directory.") - @key - @visibility(Lifecycle.Read) - @pattern("^[a-zA-Z0-9._-]{1,64}$") - personDirectoryId: string; - - @doc("A description of the person directory.") - description?: string; - - @doc("Tags associated with the person directory.") - tags?: Record; - - @doc("The date and time when the person directory was created.") - @visibility(Lifecycle.Read) - createdAt: utcDateTime; - - @doc("The date and time when the person directory was last modified.") - @visibility(Lifecycle.Read) - lastModifiedAt: utcDateTime; - - @doc("Number of people in the person directory.") - @visibility(Lifecycle.Read) - personCount: int32; - - @doc("Number of faces in the person directory.") - @visibility(Lifecycle.Read) - faceCount: int32; -} - -@added(Versions.v2025_05_01_preview) -@doc("Person in a person directory.") -@parentResource(PersonDirectory) -@resource("persons") -model PersonDirectoryPerson { - @doc("The unique identifier of the person.") - @key - @visibility(Lifecycle.Read) - @pattern("^[a-zA-Z0-9._-]{1,64}$") - personId: string; - - @doc("Tags associated with the person.") - tags?: Record; - - @doc("List of faces associated with the person.") - faceIds?: string[]; -} - -@added(Versions.v2025_05_01_preview) -@doc("Face in a person directory.") -@parentResource(PersonDirectory) -@resource("faces") -model PersonDirectoryFace { - @doc("The unique identifier of the face.") - @key - @visibility(Lifecycle.Read) - @pattern("^[a-zA-Z0-9._-]{1,64}$") - faceId: string; - - @doc("Person associated with the face, if any.") - personId?: string; - - @doc("User provided identifier for the source image.") - @visibility(Lifecycle.Read) - imageReferenceId?: string; - - @doc("Bounding box of the face in the source image.") - @visibility(Lifecycle.Read) - boundingBox?: BoundingBox; -} - -@added(Versions.v2025_05_01_preview) -@doc("Detect faces parameters.") -model DetectFacesParameters { - @doc("Image URL. Only one of url or data should be specified.") - url?: string; - - @doc("Base64-encoded image data. Only one of url or data should be specified.") - data?: bytes; - - @doc("Maximum number of faces to return (up to 100).") - maxDetectedFaces?: int32 = 100; -} - -@added(Versions.v2025_05_01_preview) -@doc("Detect faces response.") -model DetectFacesResult { - @doc("List of detected faces.") - detectedFaces: DetectedBoundingBox[]; -} - -@added(Versions.v2025_05_01_preview) -@doc("Compare faces parameters.") -model CompareFacesParameters { - @doc("First face to compare.") - faceSource1: FaceSource; - - @doc("Second face to compare.") - faceSource2: FaceSource; -} - -@added(Versions.v2025_05_01_preview) -@doc("Compare faces response.") -model CompareFacesResult { - @doc("Details of the first detected face.") - detectedFace1: DetectedBoundingBox; - - @doc("Details of the second detected face.") - detectedFace2: DetectedBoundingBox; - - @doc("Confidence score of the face comparison.") - confidence: float32; -} - -@added(Versions.v2025_05_01_preview) -@doc("Add person parameters.") -model AddPersonParameters { - @doc("The unique identifier of the person directory.") - @path - personDirectoryId: string; - - ...PersonDirectoryPerson; -} - -@added(Versions.v2025_05_01_preview) -@doc("Add face parameters.") -model AddFaceParameters { - @doc("The unique identifier of the person directory.") - @path - personDirectoryId: string; - - @doc("Source of the face.") - faceSource: FaceSource; - - @doc("Person identifier with which to associate the face.") - personId?: string; - - @doc("Face quality threshold below which the face will not be added. Default is medium.") - qualityThreshold?: QualityForRecognition = QualityForRecognition.medium; -} - -@added(Versions.v2025_05_01_preview) -@doc("Quality of the face for recognition-based operations.") -union QualityForRecognition { - string, - - @doc("Low quality.") - low: "low", - - @doc("Medium quality.") - medium: "medium", - - @doc("High quality.") - high: "high", -} - -@added(Versions.v2025_05_01_preview) -@doc("Identify person parameters.") -model IdentifyPersonParameters { - @doc("Source of the face.") - faceSource: FaceSource; - - @doc("Maximum number of person candidates to return (up to 10).") - maxPersonCandidates?: int32 = 1; -} - -@added(Versions.v2025_05_01_preview) -@doc("Identify person response.") -model IdentifyPersonResult { - @doc("Details of the detected face.") - detectedFace: DetectedBoundingBox; - - @doc("List of person candidates matching the input face.") - personCandidates: PersonCandidate[]; -} - -@added(Versions.v2025_05_01_preview) -@doc("Identified person candidate.") -model PersonCandidate { - @doc("The unique identifier of the person.") - @pattern("^[a-zA-Z0-9._-]{1,64}$") - personId: string; - - @doc("Tags associated with the person.") - tags?: Record; - - @doc("Confidence score of the person matching the input face.") - confidence: float32; -} - -@added(Versions.v2025_05_01_preview) -@doc("Find similar faces parameters.") -model FindSimilarFacesParameters { - @doc("Source of the face.") - faceSource?: FaceSource; - - @doc("Maximum number of similar faces to return (up to 1000).") - maxSimilarFaces?: int32 = 1000; - - // @doc("Continuation token for paginated results.") - // @query - // @continuationToken - // token?: string; -} - -@added(Versions.v2025_05_01_preview) -@doc("Find similar faces response.") -model FindSimilarFacesResult { - @doc("Details of the detected face.") - detectedFace: DetectedBoundingBox; - - @doc("List of similar faces.") - @pageItems - similarFaces: SimilarFace[]; - - // @doc("Continuation token for the next page of results.") - // @continuationToken - // nextToken?: string; -} - -@added(Versions.v2025_05_01_preview) -@doc("Similar face found in the person directory.") -model SimilarFace { - ...PersonDirectoryFace; - - @doc("Confidence that this face matches the input face.") - confidence: float32; -} - -@added(Versions.v2025_05_01_preview) -@doc("Verify person parameters.") -model VerifyPersonParameters { - @doc("Source of the face.") - faceSource: FaceSource; -} - -@added(Versions.v2025_05_01_preview) -@doc("Verify person response.") -model VerifyPersonResult { - @doc("Details of the detected face.") - detectedFace: DetectedBoundingBox; - - @doc("Confidence score of the person verification.") - confidence: float32; -} +// @added(Versions.v2025_05_01_preview) +// @doc("Bounding box in an image.") +// model BoundingBox { +// @doc("Left coordinate of the bounding box.") +// left: int32; + +// @doc("Top coordinate of the bounding box.") +// top: int32; + +// @doc("Width of the bounding box.") +// width: int32; + +// @doc("Height of the bounding box.") +// height: int32; +// } + +// @added(Versions.v2025_05_01_preview) +// @doc("Input face source with an optional target bounding box. If not specified, the largest face will be used.") +// model FaceSource { +// @doc("Image URL. Only one of url or data should be specified.") +// url?: url; + +// @doc("Base64-encoded image data. Only one of url or data should be specified.") +// data?: bytes; + +// @doc("User provided identifier for the source image.") +// imageReferenceId?: string; + +// @doc("Bounding box specifying the region of interest.") +// targetBoundingBox?: BoundingBox; +// } + +// @added(Versions.v2025_05_01_preview) +// @doc("Detected bounding box of an object.") +// model DetectedBoundingBox { +// @doc("Bounding box of the detected face.") +// boundingBox?: BoundingBox; + +// // confidence: float32; +// } + +// @added(Versions.v2025_05_01_preview) +// @doc("Directory of people and their faces.") +// @resource("personDirectories") +// model PersonDirectory { +// @doc("The unique identifier of the person directory.") +// @key +// @visibility(Lifecycle.Read) +// @pattern("^[a-zA-Z0-9._-]{1,64}$") +// personDirectoryId: string; + +// @doc("A description of the person directory.") +// description?: string; + +// @doc("Tags associated with the person directory.") +// tags?: Record; + +// @doc("The date and time when the person directory was created.") +// @visibility(Lifecycle.Read) +// createdAt: utcDateTime; + +// @doc("The date and time when the person directory was last modified.") +// @visibility(Lifecycle.Read) +// lastModifiedAt: utcDateTime; + +// @doc("Number of people in the person directory.") +// @visibility(Lifecycle.Read) +// personCount: int32; + +// @doc("Number of faces in the person directory.") +// @visibility(Lifecycle.Read) +// faceCount: int32; +// } + +// @added(Versions.v2025_05_01_preview) +// @doc("Person in a person directory.") +// @parentResource(PersonDirectory) +// @resource("persons") +// model PersonDirectoryPerson { +// @doc("The unique identifier of the person.") +// @key +// @visibility(Lifecycle.Read) +// @pattern("^[a-zA-Z0-9._-]{1,64}$") +// personId: string; + +// @doc("Tags associated with the person.") +// tags?: Record; + +// @doc("List of faces associated with the person.") +// faceIds?: string[]; +// } + +// @added(Versions.v2025_05_01_preview) +// @doc("Face in a person directory.") +// @parentResource(PersonDirectory) +// @resource("faces") +// model PersonDirectoryFace { +// @doc("The unique identifier of the face.") +// @key +// @visibility(Lifecycle.Read) +// @pattern("^[a-zA-Z0-9._-]{1,64}$") +// faceId: string; + +// @doc("Person associated with the face, if any.") +// personId?: string; + +// @doc("User provided identifier for the source image.") +// @visibility(Lifecycle.Read) +// imageReferenceId?: string; + +// @doc("Bounding box of the face in the source image.") +// @visibility(Lifecycle.Read) +// boundingBox?: BoundingBox; +// } + +// @added(Versions.v2025_05_01_preview) +// @doc("Detect faces parameters.") +// model DetectFacesParameters { +// @doc("Image URL. Only one of url or data should be specified.") +// url?: string; + +// @doc("Base64-encoded image data. Only one of url or data should be specified.") +// data?: bytes; + +// @doc("Maximum number of faces to return (up to 100).") +// maxDetectedFaces?: int32 = 100; +// } + +// @added(Versions.v2025_05_01_preview) +// @doc("Detect faces response.") +// model DetectFacesResult { +// @doc("List of detected faces.") +// detectedFaces: DetectedBoundingBox[]; +// } + +// @added(Versions.v2025_05_01_preview) +// @doc("Compare faces parameters.") +// model CompareFacesParameters { +// @doc("First face to compare.") +// faceSource1: FaceSource; + +// @doc("Second face to compare.") +// faceSource2: FaceSource; +// } + +// @added(Versions.v2025_05_01_preview) +// @doc("Compare faces response.") +// model CompareFacesResult { +// @doc("Details of the first detected face.") +// detectedFace1: DetectedBoundingBox; + +// @doc("Details of the second detected face.") +// detectedFace2: DetectedBoundingBox; + +// @doc("Confidence score of the face comparison.") +// confidence: float32; +// } + +// @added(Versions.v2025_05_01_preview) +// @doc("Add person parameters.") +// model AddPersonParameters { +// @doc("The unique identifier of the person directory.") +// @path +// personDirectoryId: string; + +// ...PersonDirectoryPerson; +// } + +// @added(Versions.v2025_05_01_preview) +// @doc("Add face parameters.") +// model AddFaceParameters { +// @doc("The unique identifier of the person directory.") +// @path +// personDirectoryId: string; + +// @doc("Source of the face.") +// faceSource: FaceSource; + +// @doc("Person identifier with which to associate the face.") +// personId?: string; + +// @doc("Face quality threshold below which the face will not be added. Default is medium.") +// qualityThreshold?: QualityForRecognition = QualityForRecognition.medium; +// } + +// @added(Versions.v2025_05_01_preview) +// @doc("Quality of the face for recognition-based operations.") +// union QualityForRecognition { +// string, + +// @doc("Low quality.") +// low: "low", + +// @doc("Medium quality.") +// medium: "medium", + +// @doc("High quality.") +// high: "high", +// } + +// @added(Versions.v2025_05_01_preview) +// @doc("Identify person parameters.") +// model IdentifyPersonParameters { +// @doc("Source of the face.") +// faceSource: FaceSource; + +// @doc("Maximum number of person candidates to return (up to 10).") +// maxPersonCandidates?: int32 = 1; +// } + +// @added(Versions.v2025_05_01_preview) +// @doc("Identify person response.") +// model IdentifyPersonResult { +// @doc("Details of the detected face.") +// detectedFace: DetectedBoundingBox; + +// @doc("List of person candidates matching the input face.") +// personCandidates: PersonCandidate[]; +// } + +// @added(Versions.v2025_05_01_preview) +// @doc("Identified person candidate.") +// model PersonCandidate { +// @doc("The unique identifier of the person.") +// @pattern("^[a-zA-Z0-9._-]{1,64}$") +// personId: string; + +// @doc("Tags associated with the person.") +// tags?: Record; + +// @doc("Confidence score of the person matching the input face.") +// confidence: float32; +// } + +// @added(Versions.v2025_05_01_preview) +// @doc("Find similar faces parameters.") +// model FindSimilarFacesParameters { +// @doc("Source of the face.") +// faceSource?: FaceSource; + +// @doc("Maximum number of similar faces to return (up to 1000).") +// maxSimilarFaces?: int32 = 1000; + +// // @doc("Continuation token for paginated results.") +// // @query +// // @continuationToken +// // token?: string; +// } + +// @added(Versions.v2025_05_01_preview) +// @doc("Find similar faces response.") +// model FindSimilarFacesResult { +// @doc("Details of the detected face.") +// detectedFace: DetectedBoundingBox; + +// @doc("List of similar faces.") +// @pageItems +// similarFaces: SimilarFace[]; + +// // @doc("Continuation token for the next page of results.") +// // @continuationToken +// // nextToken?: string; +// } + +// @added(Versions.v2025_05_01_preview) +// @doc("Similar face found in the person directory.") +// model SimilarFace { +// ...PersonDirectoryFace; + +// @doc("Confidence that this face matches the input face.") +// confidence: float32; +// } + +// @added(Versions.v2025_05_01_preview) +// @doc("Verify person parameters.") +// model VerifyPersonParameters { +// @doc("Source of the face.") +// faceSource: FaceSource; +// } + +// @added(Versions.v2025_05_01_preview) +// @doc("Verify person response.") +// model VerifyPersonResult { +// @doc("Details of the detected face.") +// detectedFace: DetectedBoundingBox; + +// @doc("Confidence score of the person verification.") +// confidence: float32; +// } diff --git a/specification/ai/ContentUnderstanding/personDirectoryRoutes.tsp b/specification/ai/ContentUnderstanding/personDirectoryRoutes.tsp index a96ce4a6b7fd..81fcee73584c 100644 --- a/specification/ai/ContentUnderstanding/personDirectoryRoutes.tsp +++ b/specification/ai/ContentUnderstanding/personDirectoryRoutes.tsp @@ -12,159 +12,161 @@ using TypeSpec.Versioning; namespace ContentUnderstanding; -@added(Versions.v2025_05_01_preview) -interface PersonDirectories { - #suppress "@azure-tools/typespec-azure-core/use-standard-operations" "Doesn't fit standard ops" - @doc("Create a new person directory.") - @put - create is Foundations.ResourceOperation< - PersonDirectory, - Foundations.ResourceBody & - TraitProperties< - ServiceTraits, - TraitLocation.Parameters, - TraitContext.Create - >, - Foundations.ResourceCreatedResponse & - TraitProperties< - ServiceTraits, - TraitLocation.Response, - TraitContext.Create - >, - ServiceTraits - >; - - @doc("Update person directory properties.") - update is Operations.ResourceUpdate; - - @doc("Get person directory properties.") - get is Operations.ResourceRead; - - @doc("Delete person directory and all associated persons and faces.") - delete is Operations.ResourceDelete; - - @doc("List person directories.") - list is Operations.ResourceList; - - #suppress "@azure-tools/typespec-azure-core/use-standard-operations" "Doesn't fit standard ops" - @doc("Add a new person and optionally associate with existing faces.") - @route("/personDirectories/{personDirectoryId}/persons") - @post - addPerson is Foundations.Operation< - AddPersonParameters & - TraitProperties< - ServiceTraits, - TraitLocation.Parameters, - TraitContext.Create - >, - Foundations.ResourceCreatedResponse | (Foundations.LocationOfCreatedResourceResponse & - TraitProperties< - ServiceTraits, - TraitLocation.Response, - TraitContext.Create - >), - ServiceTraits - >; - - #suppress "@azure-tools/typespec-azure-core/use-standard-operations" "Doesn't fit standard ops" - @doc("Update person properties.") - updatePerson is Operations.ResourceUpdate; - - @doc("Get person properties.") - getPerson is Operations.ResourceRead; - - @doc("Delete person. Any linked faces will be disassociated, but not deleted.") - deletePerson is Operations.ResourceDelete; - - @doc("List persons.") - listPersons is Operations.ResourceList; - - #suppress "@azure-tools/typespec-azure-core/use-standard-operations" "Doesn't fit standard ops" - @doc("Add a new face.") - @route("/personDirectories/{personDirectoryId}/faces") - @post - addFace is Foundations.Operation< - AddFaceParameters & - TraitProperties< - ServiceTraits, - TraitLocation.Parameters, - TraitContext.Create - >, - Foundations.ResourceCreatedResponse | (Foundations.LocationOfCreatedResourceResponse & - TraitProperties< - ServiceTraits, - TraitLocation.Response, - TraitContext.Create - >), - ServiceTraits - >; - - @doc("Update face properties, such as modifying the association with a person.") - updateFace is Operations.ResourceUpdate; - - @doc("Get face properties.") - getFace is Operations.ResourceRead; - - @doc("Delete face. Any linked person will be disassociated, but not deleted.") - deleteFace is Operations.ResourceDelete; - - @doc("List faces.") - listFaces is Operations.ResourceList; - - @doc("Identify the person from a face.") - @action("identify") - identifyPerson is Operations.ResourceCollectionAction< - PersonDirectoryPerson, - IdentifyPersonParameters, - IdentifyPersonResult - >; - - @doc("Find similar faces.") - @action("find") - findSimilarFaces is Operations.ResourceCollectionAction< - PersonDirectoryFace, - FindSimilarFacesParameters, - FindSimilarFacesResult - >; - - @doc("Verify if a face matches the person.") - @action("verify") - verifyPerson is Operations.ResourceAction< - PersonDirectoryPerson, - VerifyPersonParameters, - VerifyPersonResult - >; -} - -@added(Versions.v2025_05_01_preview) -interface Faces { - #suppress "@azure-tools/typespec-azure-core/use-standard-operations" "Doesn't fit standard ops" - @doc("Detect faces in an image.") - @route("/faces:detect") - @action - detect is Foundations.Operation< - DetectFacesParameters & - TraitProperties< - ServiceTraits, - TraitLocation.Parameters, - TraitContext.Action - >, - DetectFacesResult, - ServiceTraits - >; - - #suppress "@azure-tools/typespec-azure-core/use-standard-operations" "Doesn't fit standard ops" - @doc("Compare the similarity between two faces.") - @route("/faces:compare") - @action - compare is Foundations.Operation< - CompareFacesParameters & - TraitProperties< - ServiceTraits, - TraitLocation.Parameters, - TraitContext.Action - >, - CompareFacesResult, - ServiceTraits - >; -} +// @added(Versions.v2025_05_01_preview) +// @removed(Versions.v2025_11_01) +// interface PersonDirectories { +// #suppress "@azure-tools/typespec-azure-core/use-standard-operations" "Doesn't fit standard ops" +// @doc("Create a new person directory.") +// @put +// create is Foundations.ResourceOperation< +// PersonDirectory, +// Foundations.ResourceBody & +// TraitProperties< +// ServiceTraits, +// TraitLocation.Parameters, +// TraitContext.Create +// >, +// Foundations.ResourceCreatedResponse & +// TraitProperties< +// ServiceTraits, +// TraitLocation.Response, +// TraitContext.Create +// >, +// ServiceTraits +// >; + +// @doc("Update person directory properties.") +// update is Operations.ResourceUpdate; + +// @doc("Get person directory properties.") +// get is Operations.ResourceRead; + +// @doc("Delete person directory and all associated persons and faces.") +// delete is Operations.ResourceDelete; + +// @doc("List person directories.") +// list is Operations.ResourceList; + +// #suppress "@azure-tools/typespec-azure-core/use-standard-operations" "Doesn't fit standard ops" +// @doc("Add a new person and optionally associate with existing faces.") +// @route("/personDirectories/{personDirectoryId}/persons") +// @post +// addPerson is Foundations.Operation< +// AddPersonParameters & +// TraitProperties< +// ServiceTraits, +// TraitLocation.Parameters, +// TraitContext.Create +// >, +// Foundations.ResourceCreatedResponse | (Foundations.LocationOfCreatedResourceResponse & +// TraitProperties< +// ServiceTraits, +// TraitLocation.Response, +// TraitContext.Create +// >), +// ServiceTraits +// >; + +// #suppress "@azure-tools/typespec-azure-core/use-standard-operations" "Doesn't fit standard ops" +// @doc("Update person properties.") +// updatePerson is Operations.ResourceUpdate; + +// @doc("Get person properties.") +// getPerson is Operations.ResourceRead; + +// @doc("Delete person. Any linked faces will be disassociated, but not deleted.") +// deletePerson is Operations.ResourceDelete; + +// @doc("List persons.") +// listPersons is Operations.ResourceList; + +// #suppress "@azure-tools/typespec-azure-core/use-standard-operations" "Doesn't fit standard ops" +// @doc("Add a new face.") +// @route("/personDirectories/{personDirectoryId}/faces") +// @post +// addFace is Foundations.Operation< +// AddFaceParameters & +// TraitProperties< +// ServiceTraits, +// TraitLocation.Parameters, +// TraitContext.Create +// >, +// Foundations.ResourceCreatedResponse | (Foundations.LocationOfCreatedResourceResponse & +// TraitProperties< +// ServiceTraits, +// TraitLocation.Response, +// TraitContext.Create +// >), +// ServiceTraits +// >; + +// @doc("Update face properties, such as modifying the association with a person.") +// updateFace is Operations.ResourceUpdate; + +// @doc("Get face properties.") +// getFace is Operations.ResourceRead; + +// @doc("Delete face. Any linked person will be disassociated, but not deleted.") +// deleteFace is Operations.ResourceDelete; + +// @doc("List faces.") +// listFaces is Operations.ResourceList; + +// @doc("Identify the person from a face.") +// @action("identify") +// identifyPerson is Operations.ResourceCollectionAction< +// PersonDirectoryPerson, +// IdentifyPersonParameters, +// IdentifyPersonResult +// >; + +// @doc("Find similar faces.") +// @action("find") +// findSimilarFaces is Operations.ResourceCollectionAction< +// PersonDirectoryFace, +// FindSimilarFacesParameters, +// FindSimilarFacesResult +// >; + +// @doc("Verify if a face matches the person.") +// @action("verify") +// verifyPerson is Operations.ResourceAction< +// PersonDirectoryPerson, +// VerifyPersonParameters, +// VerifyPersonResult +// >; +// } + +// @added(Versions.v2025_05_01_preview) +// @removed(Versions.v2025_11_01) +// interface Faces { +// #suppress "@azure-tools/typespec-azure-core/use-standard-operations" "Doesn't fit standard ops" +// @doc("Detect faces in an image.") +// @route("/faces:detect") +// @action +// detect is Foundations.Operation< +// DetectFacesParameters & +// TraitProperties< +// ServiceTraits, +// TraitLocation.Parameters, +// TraitContext.Action +// >, +// DetectFacesResult, +// ServiceTraits +// >; + +// #suppress "@azure-tools/typespec-azure-core/use-standard-operations" "Doesn't fit standard ops" +// @doc("Compare the similarity between two faces.") +// @route("/faces:compare") +// @action +// compare is Foundations.Operation< +// CompareFacesParameters & +// TraitProperties< +// ServiceTraits, +// TraitLocation.Parameters, +// TraitContext.Action +// >, +// CompareFacesResult, +// ServiceTraits +// >; +// } diff --git a/specification/ai/ContentUnderstanding/routes.tsp b/specification/ai/ContentUnderstanding/routes.tsp index 293ec5de8f97..9dc3c68d2451 100644 --- a/specification/ai/ContentUnderstanding/routes.tsp +++ b/specification/ai/ContentUnderstanding/routes.tsp @@ -1,11 +1,11 @@ import "@azure-tools/typespec-azure-core"; -import "@azure-tools/typespec-client-generator-core"; import "@typespec/rest"; import "@typespec/http"; import "./models.tsp"; using Azure.Core; using Azure.ClientGenerator.Core; +using Azure.Core.Traits; using TypeSpec.Rest; using TypeSpec.Http; using TypeSpec.Versioning; @@ -19,23 +19,51 @@ model OperationIdHeader { operationId?: string; } +alias AllowReplaceTrait = QueryParametersTrait< + { + @added(Versions.v2025_11_01) + @doc("Allow the operation to replace an existing resource.") + @query + allowReplace?: boolean = false; + }, + TraitContext.Create | TraitContext.Action +>; + alias ServiceTraits = Traits.NoRepeatableRequests & Traits.NoConditionalRequests & Traits.SupportsClientRequestId; -alias Operations = ResourceOperations; +alias Operations = ResourceOperations; interface ContentAnalyzers { + #suppress "@azure-tools/typespec-azure-core/use-standard-operations" "This is a custom operation status endpoint." @doc("Get the status of an analyzer creation operation.") - getOperationStatus is Operations.GetResourceOperationStatus< - ContentAnalyzer, - ContentAnalyzer + @route("/analyzers/{analyzerId}/operations/{operationId}") + getOperationStatus is Foundations.Operation< + { + @doc("The unique identifier of the analyzer.") + @path + @pattern("^[a-zA-Z0-9._-]{1,64}$") + @minLength(1) + @maxLength(64) + analyzerId: string; + + @doc("The unique ID of the operation.") + @path + operationId: string; + }, + ContentAnalyzerOperationStatus, + ServiceTraits >; @doc("Create a new analyzer asynchronously.") @pollingOperation(ContentAnalyzers.getOperationStatus) - createOrReplace is Operations.LongRunningResourceCreateOrReplace; + createOrReplace is Operations.LongRunningResourceCreateOrReplace< + ContentAnalyzer, + AllowReplaceTrait + >; @doc("Update analyzer properties.") + @convenientAPI(false) update is Operations.ResourceUpdate; @doc("Get analyzer properties.") @@ -48,8 +76,6 @@ interface ContentAnalyzers { list is Operations.ResourceList; @doc("Extract content and fields from input.") - @sharedRoute - @action("analyze") @pollingOperation(ContentAnalyzers.getResult) analyze is Operations.LongRunningResourceAction< ContentAnalyzer, @@ -57,9 +83,8 @@ interface ContentAnalyzers { AnalyzeResult >; + @added(Versions.v2025_11_01) @doc("Extract content and fields from input.") - @sharedRoute - @action("analyze") @pollingOperation(ContentAnalyzers.getResult) analyzeBinary is Operations.LongRunningResourceAction< ContentAnalyzer, @@ -69,50 +94,52 @@ interface ContentAnalyzers { #suppress "@azure-tools/typespec-azure-core/use-standard-operations" "This is a custom operation status endpoint." @doc("Get the result of an analysis operation.") - // This operation is marked as internal because client generators automatically handle - // the polling pattern for long-running operations. When users call analyze(), the - // generated SDK returns a poller that internally uses this endpoint to check status - // and retrieve results, eliminating the need for manual operation ID management. - @access(Access.internal) @route("/analyzerResults/{operationId}") - getResult is Foundations.GetOperationStatus< - GetResultParameters, - AnalyzeResult - >; - - #suppress "@azure-tools/typespec-azure-core/use-standard-operations" "Doesn't fit standard ops" - @removed(Versions.v2025_05_01_preview) - @doc("Get an image associated with the result of an analysis operation.") - @route("/analyzers/{analyzerId}/results/{operationId}/images/{imageId}") - @get - getResultImage is Foundations.Operation< + getResult is Foundations.Operation< { - @doc("Analyzer identifier.") - @path - analyzerId: string; - - @doc("Operation identifier.") + @doc("The unique ID of the operation.") @path operationId: string; - @doc("Image identifier.") - @path - imageId: string; - }, - { - @doc("Response content type.") - @header - contentType: "image/*"; - - @doc("Image content.") - @bodyRoot - image: bytes; + ...GetResultParameters; }, + ContentAnalyzerAnalyzeOperationStatus, ServiceTraits >; + // #suppress "@azure-tools/typespec-azure-core/use-standard-operations" "Doesn't fit standard ops" + // @removed(Versions.v2025_05_01_preview) + // @doc("Get an image associated with the result of an analysis operation.") + // @route("/analyzers/{analyzerId}/results/{operationId}/images/{imageId}") + // @get + // getResultImage is Foundations.Operation< + // { + // @doc("Analyzer identifier.") + // @path + // analyzerId: string; + + // @doc("Operation identifier.") + // @path + // operationId: string; + + // @doc("Image identifier.") + // @path + // imageId: string; + // }, + // { + // @doc("Response content type.") + // @header + // contentType: "image/*"; + + // @doc("Image content.") + // @bodyRoot + // image: bytes; + // }, + // ServiceTraits + // >; + #suppress "@azure-tools/typespec-azure-core/use-standard-operations" "Doesn't fit standard ops" - @added(Versions.v2025_05_01_preview) + // @added(Versions.v2025_05_01_preview) @doc("Get a file associated with the result of an analysis operation.") @route("/analyzerResults/{operationId}/files/{+path}") @get @@ -138,18 +165,60 @@ interface ContentAnalyzers { ServiceTraits >; - // #suppress "@azure-tools/typespec-azure-core/use-standard-operations" "Doesn't fit standard ops" - // @added(Versions.v2025_05_01_preview) - // @doc("Mark the result of an analysis operation for deletion.") - // @route("/analyzerResults/{operationId}") - // @delete - // deleteResult is Foundations.Operation< - // { - // @doc("Operation identifier.") - // @path - // operationId: string; - // }, - // TypeSpec.Http.NoContentResponse, - // ServiceTraits - // >; + #suppress "@azure-tools/typespec-azure-core/use-standard-operations" "Doesn't fit standard ops" + @added(Versions.v2025_11_01) + @doc("Mark the result of an analysis operation for deletion.") + @route("/analyzerResults/{operationId}") + @delete + deleteResult is Foundations.Operation< + { + @doc("Operation identifier.") + @path + operationId: string; + }, + TypeSpec.Http.NoContentResponse, + ServiceTraits + >; + + @added(Versions.v2025_11_01) + @doc("Create a copy of the source analyzer to the current location.") + @pollingOperation(ContentAnalyzers.getOperationStatus) + copy is Operations.LongRunningResourceAction< + ContentAnalyzer, + CopyRequest, + ContentAnalyzer, + Foundations.Error, + AllowReplaceTrait + >; + + @added(Versions.v2025_11_01) + @doc("Get authorization for copying this analyzer to another location.") + grantCopyAuthorization is Operations.ResourceAction< + ContentAnalyzer, + GrantCopyAuthorizationRequest, + CopyAuthorization + >; + + #suppress "@azure-tools/typespec-azure-core/use-standard-operations" "Doesn't fit standard ops" + @added(Versions.v2025_11_01) + @doc("Return default settings for this Content Understanding resource.") + @route("/defaults") + @get + getDefaults is Foundations.Operation< + {}, + ContentUnderstandingDefaults, + ServiceTraits + >; + + #suppress "@azure-tools/typespec-azure-core/use-standard-operations" "Doesn't fit standard ops" + @added(Versions.v2025_11_01) + @doc("Return default settings for this Content Understanding resource.") + @route("/defaults") + @patch + @convenientAPI(false) + updateDefaults is Foundations.Operation< + MergePatchUpdate, + ContentUnderstandingDefaults, + ServiceTraits + >; } diff --git a/specification/ai/ContentUnderstanding/tspconfig.yaml b/specification/ai/ContentUnderstanding/tspconfig.yaml index 4233fff08f8f..bec6a2349688 100644 --- a/specification/ai/ContentUnderstanding/tspconfig.yaml +++ b/specification/ai/ContentUnderstanding/tspconfig.yaml @@ -4,6 +4,10 @@ parameters: emit: - "@azure-tools/typespec-autorest" + # - "@azure-typespec/http-client-csharp" + # - "@azure-tools/typespec-python" + # - "@azure-tools/typespec-ts" + # - "@azure-tools/typespec-java" linter: extends: @@ -16,21 +20,32 @@ options: emitter-output-dir: "{project-root}/.." omit-unreachable-types: true output-file: "{azure-resource-provider-folder}/{service-name}/{version-status}/{version}/ContentUnderstanding.json" - "@azure-tools/typespec-csharp": - emitter-output-dir: "{output-dir}/{service-dir}/{namespace}" - clear-output-folder: true - model-namespace: false - namespace: "Azure.AI.ContentUnderstanding" - flavor: azure "@azure-typespec/http-client-csharp": emitter-output-dir: "{output-dir}/{service-dir}/{namespace}" - namespace: Azure.AI.ContentUnderstanding model-namespace: false + namespace: "Azure.AI.ContentUnderstanding" "@azure-tools/typespec-python": package-pprint-name: "Azure AI Content Understanding" emitter-output-dir: "{output-dir}/{service-dir}/azure-ai-contentunderstanding" namespace: "azure.ai.contentunderstanding" package-version: 1.0.0b1 + generate-test: true + generate-sample: true + flavor: azure + "@azure-tools/typespec-ts": + emitter-output-dir: "{output-dir}/{service-dir}/ai-content-understanding-rest" + is-modular-library: true + package-details: + name: "@azure-rest/ai-content-understanding" + description: "Azure Content Understanding Rest Client" + version: "1.0.0-beta.1" + generate-test: true + flavor: azure + "@azure-tools/typespec-java": + emitter-output-dir: "{output-dir}/{service-dir}/azure-ai-contentunderstanding" + namespace: com.azure.ai.contentunderstanding + enable-sync-stack: true + generate-tests: true + partial-update: true + use-eclipse-language-server: false flavor: azure - generate-test: false - generate-sample: false diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2024-12-01-preview/examples/Analyzers_DeleteAnalyzer.json b/specification/ai/data-plane/ContentUnderstanding/preview/2024-12-01-preview/examples/Analyzers_DeleteAnalyzer.json deleted file mode 100644 index 72985aaf2e39..000000000000 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2024-12-01-preview/examples/Analyzers_DeleteAnalyzer.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "title": "Delete Custom Analyzer", - "operationId": "Analyzers_Delete", - "parameters": { - "api-version": "2024-12-01-preview", - "analyzerId": "myAnalyzer" - }, - "responses": { - "204": {} - } -} diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/ContentUnderstanding.json b/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/ContentUnderstanding.json deleted file mode 100644 index 9f505f244fa6..000000000000 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/ContentUnderstanding.json +++ /dev/null @@ -1,5733 +0,0 @@ -{ - "swagger": "2.0", - "info": { - "title": "Content Understanding", - "version": "2025-05-01-preview", - "description": "The Content Understanding service extracts content and fields from multimodal input.", - "x-typespec-generated": [ - { - "emitter": "@azure-tools/typespec-autorest" - } - ] - }, - "schemes": [ - "https" - ], - "x-ms-parameterized-host": { - "hostTemplate": "{endpoint}/contentunderstanding", - "useSchemePrefix": false, - "parameters": [ - { - "name": "endpoint", - "in": "path", - "description": "Content Understanding service endpoint.", - "required": true, - "type": "string", - "format": "uri", - "x-ms-skip-url-encoding": true - } - ] - }, - "produces": [ - "application/json" - ], - "consumes": [ - "application/json" - ], - "security": [ - { - "ApiKeyAuth": [] - }, - { - "OAuth2Auth": [ - "https://cognitiveservices.azure.com/.default" - ] - } - ], - "securityDefinitions": { - "ApiKeyAuth": { - "type": "apiKey", - "name": "Ocp-Apim-Subscription-Key", - "in": "header" - }, - "OAuth2Auth": { - "type": "oauth2", - "flow": "accessCode", - "authorizationUrl": "https://login.microsoftonline.com/common/oauth2/authorize", - "scopes": { - "https://cognitiveservices.azure.com/.default": "" - }, - "tokenUrl": "https://login.microsoftonline.com/common/oauth2/token" - } - }, - "tags": [], - "paths": { - "/analyzerResults/{operationId}": { - "get": { - "operationId": "ContentAnalyzers_GetResult", - "description": "Get the result of an analysis operation.", - "parameters": [ - { - "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" - }, - { - "name": "operationId", - "in": "path", - "description": "The unique ID of the operation.", - "required": true, - "type": "string" - } - ], - "responses": { - "200": { - "description": "The request has succeeded.", - "schema": { - "type": "object", - "description": "Provides status details for long running operations.", - "properties": { - "id": { - "type": "string", - "description": "The unique ID of the operation." - }, - "status": { - "$ref": "#/definitions/Azure.Core.Foundations.OperationState", - "description": "The status of the operation" - }, - "error": { - "$ref": "#/definitions/Azure.Core.Foundations.Error", - "description": "Error object that describes the error when status is \"Failed\"." - }, - "result": { - "$ref": "#/definitions/AnalyzeResult", - "description": "The result of the operation." - } - }, - "required": [ - "id", - "status" - ] - } - }, - "default": { - "description": "An unexpected error response.", - "schema": { - "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" - }, - "headers": { - "x-ms-error-code": { - "type": "string", - "description": "String error code indicating what went wrong." - } - } - } - }, - "x-ms-examples": { - "Get Analysis Result": { - "$ref": "./examples/ContentAnalyzers_GetResult.json" - } - } - } - }, - "/analyzerResults/{operationId}/files/{path}": { - "get": { - "operationId": "ContentAnalyzers_GetResultFile", - "description": "Get a file associated with the result of an analysis operation.", - "produces": [ - "*/*", - "application/json" - ], - "parameters": [ - { - "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" - }, - { - "name": "operationId", - "in": "path", - "description": "Operation identifier.", - "required": true, - "type": "string" - }, - { - "name": "path", - "in": "path", - "description": "File path.", - "required": true, - "type": "string", - "x-ms-skip-url-encoding": true - } - ], - "responses": { - "200": { - "description": "The request has succeeded.", - "schema": { - "type": "file" - } - }, - "default": { - "description": "An unexpected error response.", - "schema": { - "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" - }, - "headers": { - "x-ms-error-code": { - "type": "string", - "description": "String error code indicating what went wrong." - } - } - } - }, - "x-ms-examples": { - "Get Analysis Result File": { - "$ref": "./examples/ContentAnalyzers_GetResultFile.json" - } - } - } - }, - "/analyzers": { - "get": { - "operationId": "ContentAnalyzers_List", - "description": "List analyzers.", - "parameters": [ - { - "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" - }, - { - "$ref": "#/parameters/Azure.Core.ClientRequestIdHeader" - } - ], - "responses": { - "200": { - "description": "The request has succeeded.", - "schema": { - "$ref": "#/definitions/PagedContentAnalyzer" - }, - "headers": { - "x-ms-client-request-id": { - "type": "string", - "format": "uuid", - "description": "An opaque, globally-unique, client-generated string identifier for the request." - } - } - }, - "default": { - "description": "An unexpected error response.", - "schema": { - "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" - }, - "headers": { - "x-ms-error-code": { - "type": "string", - "description": "String error code indicating what went wrong." - } - } - } - }, - "x-ms-examples": { - "List Analyzers": { - "$ref": "./examples/ContentAnalyzers_List.json" - } - }, - "x-ms-pageable": { - "nextLinkName": "nextLink" - } - } - }, - "/analyzers/{analyzerId}": { - "get": { - "operationId": "ContentAnalyzers_Get", - "description": "Get analyzer properties.", - "parameters": [ - { - "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" - }, - { - "name": "analyzerId", - "in": "path", - "description": "The unique identifier of the analyzer.", - "required": true, - "type": "string", - "pattern": "^[a-zA-Z0-9._-]{1,64}$" - }, - { - "$ref": "#/parameters/Azure.Core.ClientRequestIdHeader" - } - ], - "responses": { - "200": { - "description": "The request has succeeded.", - "schema": { - "$ref": "#/definitions/ContentAnalyzer" - }, - "headers": { - "x-ms-client-request-id": { - "type": "string", - "format": "uuid", - "description": "An opaque, globally-unique, client-generated string identifier for the request." - } - } - }, - "default": { - "description": "An unexpected error response.", - "schema": { - "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" - }, - "headers": { - "x-ms-error-code": { - "type": "string", - "description": "String error code indicating what went wrong." - } - } - } - }, - "x-ms-examples": { - "Get Analyzer": { - "$ref": "./examples/ContentAnalyzers_GetAnalyzer.json" - } - } - }, - "put": { - "operationId": "ContentAnalyzers_CreateOrReplace", - "description": "Create a new analyzer asynchronously.", - "parameters": [ - { - "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" - }, - { - "name": "analyzerId", - "in": "path", - "description": "The unique identifier of the analyzer.", - "required": true, - "type": "string", - "pattern": "^[a-zA-Z0-9._-]{1,64}$" - }, - { - "$ref": "#/parameters/Azure.Core.ClientRequestIdHeader" - }, - { - "name": "resource", - "in": "body", - "description": "The resource instance.", - "required": true, - "schema": { - "$ref": "#/definitions/ContentAnalyzer" - } - } - ], - "responses": { - "200": { - "description": "The request has succeeded.", - "schema": { - "$ref": "#/definitions/ContentAnalyzer" - }, - "headers": { - "Operation-Location": { - "type": "string", - "format": "uri", - "description": "The location for monitoring the operation state." - }, - "x-ms-client-request-id": { - "type": "string", - "format": "uuid", - "description": "An opaque, globally-unique, client-generated string identifier for the request." - } - } - }, - "201": { - "description": "The request has succeeded and a new resource has been created as a result.", - "schema": { - "$ref": "#/definitions/ContentAnalyzer" - }, - "headers": { - "Operation-Location": { - "type": "string", - "format": "uri", - "description": "The location for monitoring the operation state." - }, - "x-ms-client-request-id": { - "type": "string", - "format": "uuid", - "description": "An opaque, globally-unique, client-generated string identifier for the request." - } - } - }, - "default": { - "description": "An unexpected error response.", - "schema": { - "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" - }, - "headers": { - "x-ms-error-code": { - "type": "string", - "description": "String error code indicating what went wrong." - } - } - } - }, - "x-ms-examples": { - "Create or Replace Analyzer": { - "$ref": "./examples/ContentAnalyzers_CreateOrReplace.json" - } - }, - "x-ms-long-running-operation": true - }, - "patch": { - "operationId": "ContentAnalyzers_Update", - "description": "Update analyzer properties.", - "consumes": [ - "application/merge-patch+json" - ], - "parameters": [ - { - "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" - }, - { - "name": "analyzerId", - "in": "path", - "description": "The unique identifier of the analyzer.", - "required": true, - "type": "string", - "pattern": "^[a-zA-Z0-9._-]{1,64}$" - }, - { - "$ref": "#/parameters/Azure.Core.ClientRequestIdHeader" - }, - { - "name": "resource", - "in": "body", - "description": "The resource instance.", - "required": true, - "schema": { - "$ref": "#/definitions/ContentAnalyzerUpdate" - } - } - ], - "responses": { - "200": { - "description": "The request has succeeded.", - "schema": { - "$ref": "#/definitions/ContentAnalyzer" - }, - "headers": { - "x-ms-client-request-id": { - "type": "string", - "format": "uuid", - "description": "An opaque, globally-unique, client-generated string identifier for the request." - } - } - }, - "default": { - "description": "An unexpected error response.", - "schema": { - "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" - }, - "headers": { - "x-ms-error-code": { - "type": "string", - "description": "String error code indicating what went wrong." - } - } - } - }, - "x-ms-examples": { - "Update Analyzer": { - "$ref": "./examples/ContentAnalyzers_Update.json" - } - } - }, - "delete": { - "operationId": "ContentAnalyzers_Delete", - "description": "Delete analyzer.", - "parameters": [ - { - "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" - }, - { - "name": "analyzerId", - "in": "path", - "description": "The unique identifier of the analyzer.", - "required": true, - "type": "string", - "pattern": "^[a-zA-Z0-9._-]{1,64}$" - }, - { - "$ref": "#/parameters/Azure.Core.ClientRequestIdHeader" - } - ], - "responses": { - "204": { - "description": "There is no content to send for this request, but the headers may be useful. ", - "headers": { - "x-ms-client-request-id": { - "type": "string", - "format": "uuid", - "description": "An opaque, globally-unique, client-generated string identifier for the request." - } - } - }, - "default": { - "description": "An unexpected error response.", - "schema": { - "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" - }, - "headers": { - "x-ms-error-code": { - "type": "string", - "description": "String error code indicating what went wrong." - } - } - } - }, - "x-ms-examples": { - "Delete Analyzer": { - "$ref": "./examples/ContentAnalyzers_DeleteAnalyzer.json" - } - } - } - }, - "/analyzers/{analyzerId}:analyze": { - "post": { - "operationId": "ContentAnalyzers_Analyze", - "description": "Extract content and fields from input.", - "parameters": [ - { - "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" - }, - { - "name": "analyzerId", - "in": "path", - "description": "The unique identifier of the analyzer.", - "required": true, - "type": "string", - "pattern": "^[a-zA-Z0-9._-]{1,64}$" - }, - { - "$ref": "#/parameters/AnalyzeParameters.stringEncoding" - }, - { - "$ref": "#/parameters/AnalyzeParameters.processingLocation" - }, - { - "$ref": "#/parameters/Azure.Core.ClientRequestIdHeader" - }, - { - "name": "body", - "in": "body", - "required": true, - "schema": { - "$ref": "#/definitions/AnalyzeRequest" - } - } - ], - "responses": { - "202": { - "description": "The request has been accepted for processing, but processing has not yet completed.", - "schema": { - "type": "object", - "description": "Provides status details for long running operations.", - "properties": { - "id": { - "type": "string", - "description": "The unique ID of the operation." - }, - "status": { - "$ref": "#/definitions/Azure.Core.Foundations.OperationState", - "description": "The status of the operation" - }, - "error": { - "$ref": "#/definitions/Azure.Core.Foundations.Error", - "description": "Error object that describes the error when status is \"Failed\"." - }, - "result": { - "$ref": "#/definitions/AnalyzeResult", - "description": "The result of the operation." - } - }, - "required": [ - "id", - "status" - ] - }, - "headers": { - "Operation-Location": { - "type": "string", - "format": "uri", - "description": "The location for monitoring the operation state." - }, - "x-ms-client-request-id": { - "type": "string", - "format": "uuid", - "description": "An opaque, globally-unique, client-generated string identifier for the request." - } - } - }, - "default": { - "description": "An unexpected error response.", - "schema": { - "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" - }, - "headers": { - "x-ms-error-code": { - "type": "string", - "description": "String error code indicating what went wrong." - } - } - } - }, - "x-ms-examples": { - "Analyze URL": { - "$ref": "./examples/ContentAnalyzers_Analyze.json" - } - }, - "x-ms-long-running-operation": true - } - }, - "/analyzers/{analyzerId}/operations/{operationId}": { - "get": { - "operationId": "ContentAnalyzers_GetOperationStatus", - "description": "Get the status of an analyzer creation operation.", - "parameters": [ - { - "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" - }, - { - "name": "analyzerId", - "in": "path", - "description": "The unique identifier of the analyzer.", - "required": true, - "type": "string", - "pattern": "^[a-zA-Z0-9._-]{1,64}$" - }, - { - "name": "operationId", - "in": "path", - "description": "The unique ID of the operation.", - "required": true, - "type": "string" - } - ], - "responses": { - "200": { - "description": "The request has succeeded.", - "schema": { - "type": "object", - "description": "Provides status details for long running operations.", - "properties": { - "id": { - "type": "string", - "description": "The unique ID of the operation." - }, - "status": { - "$ref": "#/definitions/Azure.Core.Foundations.OperationState", - "description": "The status of the operation" - }, - "error": { - "$ref": "#/definitions/Azure.Core.Foundations.Error", - "description": "Error object that describes the error when status is \"Failed\"." - }, - "result": { - "$ref": "#/definitions/ContentAnalyzer", - "description": "The result of the operation." - } - }, - "required": [ - "id", - "status" - ] - } - }, - "default": { - "description": "An unexpected error response.", - "schema": { - "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" - }, - "headers": { - "x-ms-error-code": { - "type": "string", - "description": "String error code indicating what went wrong." - } - } - } - }, - "x-ms-examples": { - "Get Analyzer Operation Status": { - "$ref": "./examples/ContentAnalyzers_GetOperationStatus.json" - } - } - } - }, - "/classifierResults/{operationId}": { - "get": { - "operationId": "ContentClassifiers_GetResult", - "description": "Get the result of a classifier operation.", - "parameters": [ - { - "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" - }, - { - "name": "operationId", - "in": "path", - "description": "The unique ID of the operation.", - "required": true, - "type": "string" - } - ], - "responses": { - "200": { - "description": "The request has succeeded.", - "schema": { - "type": "object", - "description": "Provides status details for long running operations.", - "properties": { - "id": { - "type": "string", - "description": "The unique ID of the operation." - }, - "status": { - "$ref": "#/definitions/Azure.Core.Foundations.OperationState", - "description": "The status of the operation" - }, - "error": { - "$ref": "#/definitions/Azure.Core.Foundations.Error", - "description": "Error object that describes the error when status is \"Failed\"." - }, - "result": { - "$ref": "#/definitions/ClassifyResult", - "description": "The result of the operation." - } - }, - "required": [ - "id", - "status" - ] - } - }, - "default": { - "description": "An unexpected error response.", - "schema": { - "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" - }, - "headers": { - "x-ms-error-code": { - "type": "string", - "description": "String error code indicating what went wrong." - } - } - } - }, - "x-ms-examples": { - "Get Analysis Result": { - "$ref": "./examples/ContentClassifiers_GetResult.json" - } - } - } - }, - "/classifiers": { - "get": { - "operationId": "ContentClassifiers_List", - "description": "List classifiers.", - "parameters": [ - { - "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" - }, - { - "$ref": "#/parameters/Azure.Core.ClientRequestIdHeader" - } - ], - "responses": { - "200": { - "description": "The request has succeeded.", - "schema": { - "$ref": "#/definitions/PagedContentClassifier" - }, - "headers": { - "x-ms-client-request-id": { - "type": "string", - "format": "uuid", - "description": "An opaque, globally-unique, client-generated string identifier for the request." - } - } - }, - "default": { - "description": "An unexpected error response.", - "schema": { - "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" - }, - "headers": { - "x-ms-error-code": { - "type": "string", - "description": "String error code indicating what went wrong." - } - } - } - }, - "x-ms-examples": { - "List Classifiers": { - "$ref": "./examples/ContentClassifiers_List.json" - } - }, - "x-ms-pageable": { - "nextLinkName": "nextLink" - } - } - }, - "/classifiers/{classifierId}": { - "get": { - "operationId": "ContentClassifiers_Get", - "description": "Get classifier properties.", - "parameters": [ - { - "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" - }, - { - "name": "classifierId", - "in": "path", - "description": "The unique identifier of the classifier.", - "required": true, - "type": "string", - "pattern": "^[a-zA-Z0-9._-]{1,64}$" - }, - { - "$ref": "#/parameters/Azure.Core.ClientRequestIdHeader" - } - ], - "responses": { - "200": { - "description": "The request has succeeded.", - "schema": { - "$ref": "#/definitions/ContentClassifier" - }, - "headers": { - "x-ms-client-request-id": { - "type": "string", - "format": "uuid", - "description": "An opaque, globally-unique, client-generated string identifier for the request." - } - } - }, - "default": { - "description": "An unexpected error response.", - "schema": { - "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" - }, - "headers": { - "x-ms-error-code": { - "type": "string", - "description": "String error code indicating what went wrong." - } - } - } - }, - "x-ms-examples": { - "Get Classifier": { - "$ref": "./examples/ContentClassifiers_GetClassifier.json" - } - } - }, - "put": { - "operationId": "ContentClassifiers_CreateOrReplace", - "description": "Create a new classifier asynchronously.", - "parameters": [ - { - "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" - }, - { - "name": "classifierId", - "in": "path", - "description": "The unique identifier of the classifier.", - "required": true, - "type": "string", - "pattern": "^[a-zA-Z0-9._-]{1,64}$" - }, - { - "$ref": "#/parameters/Azure.Core.ClientRequestIdHeader" - }, - { - "name": "resource", - "in": "body", - "description": "The resource instance.", - "required": true, - "schema": { - "$ref": "#/definitions/ContentClassifier" - } - } - ], - "responses": { - "200": { - "description": "The request has succeeded.", - "schema": { - "$ref": "#/definitions/ContentClassifier" - }, - "headers": { - "Operation-Location": { - "type": "string", - "format": "uri", - "description": "The location for monitoring the operation state." - }, - "x-ms-client-request-id": { - "type": "string", - "format": "uuid", - "description": "An opaque, globally-unique, client-generated string identifier for the request." - } - } - }, - "201": { - "description": "The request has succeeded and a new resource has been created as a result.", - "schema": { - "$ref": "#/definitions/ContentClassifier" - }, - "headers": { - "Operation-Location": { - "type": "string", - "format": "uri", - "description": "The location for monitoring the operation state." - }, - "x-ms-client-request-id": { - "type": "string", - "format": "uuid", - "description": "An opaque, globally-unique, client-generated string identifier for the request." - } - } - }, - "default": { - "description": "An unexpected error response.", - "schema": { - "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" - }, - "headers": { - "x-ms-error-code": { - "type": "string", - "description": "String error code indicating what went wrong." - } - } - } - }, - "x-ms-examples": { - "Create or Replace Classifier": { - "$ref": "./examples/ContentClassifiers_CreateOrReplace.json" - } - }, - "x-ms-long-running-operation": true - }, - "patch": { - "operationId": "ContentClassifiers_Update", - "description": "Update classifier properties.", - "consumes": [ - "application/merge-patch+json" - ], - "parameters": [ - { - "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" - }, - { - "name": "classifierId", - "in": "path", - "description": "The unique identifier of the classifier.", - "required": true, - "type": "string", - "pattern": "^[a-zA-Z0-9._-]{1,64}$" - }, - { - "$ref": "#/parameters/Azure.Core.ClientRequestIdHeader" - }, - { - "name": "resource", - "in": "body", - "description": "The resource instance.", - "required": true, - "schema": { - "$ref": "#/definitions/ContentClassifierUpdate" - } - } - ], - "responses": { - "200": { - "description": "The request has succeeded.", - "schema": { - "$ref": "#/definitions/ContentClassifier" - }, - "headers": { - "x-ms-client-request-id": { - "type": "string", - "format": "uuid", - "description": "An opaque, globally-unique, client-generated string identifier for the request." - } - } - }, - "default": { - "description": "An unexpected error response.", - "schema": { - "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" - }, - "headers": { - "x-ms-error-code": { - "type": "string", - "description": "String error code indicating what went wrong." - } - } - } - }, - "x-ms-examples": { - "Update Classifier": { - "$ref": "./examples/ContentClassifiers_Update.json" - } - } - }, - "delete": { - "operationId": "ContentClassifiers_Delete", - "description": "Delete classifier.", - "parameters": [ - { - "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" - }, - { - "name": "classifierId", - "in": "path", - "description": "The unique identifier of the classifier.", - "required": true, - "type": "string", - "pattern": "^[a-zA-Z0-9._-]{1,64}$" - }, - { - "$ref": "#/parameters/Azure.Core.ClientRequestIdHeader" - } - ], - "responses": { - "204": { - "description": "There is no content to send for this request, but the headers may be useful. ", - "headers": { - "x-ms-client-request-id": { - "type": "string", - "format": "uuid", - "description": "An opaque, globally-unique, client-generated string identifier for the request." - } - } - }, - "default": { - "description": "An unexpected error response.", - "schema": { - "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" - }, - "headers": { - "x-ms-error-code": { - "type": "string", - "description": "String error code indicating what went wrong." - } - } - } - }, - "x-ms-examples": { - "Delete Classifier": { - "$ref": "./examples/ContentClassifiers_DeleteClassifier.json" - } - } - } - }, - "/classifiers/{classifierId}:classify": { - "post": { - "operationId": "ContentClassifiers_Classify", - "description": "Classify content with optional splitting.", - "parameters": [ - { - "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" - }, - { - "name": "classifierId", - "in": "path", - "description": "The unique identifier of the classifier.", - "required": true, - "type": "string", - "pattern": "^[a-zA-Z0-9._-]{1,64}$" - }, - { - "$ref": "#/parameters/ClassifyParameters.stringEncoding" - }, - { - "$ref": "#/parameters/ClassifyParameters.processingLocation" - }, - { - "$ref": "#/parameters/Azure.Core.ClientRequestIdHeader" - }, - { - "name": "body", - "in": "body", - "required": true, - "schema": { - "$ref": "#/definitions/ClassifyRequest" - } - } - ], - "responses": { - "202": { - "description": "The request has been accepted for processing, but processing has not yet completed.", - "schema": { - "type": "object", - "description": "Provides status details for long running operations.", - "properties": { - "id": { - "type": "string", - "description": "The unique ID of the operation." - }, - "status": { - "$ref": "#/definitions/Azure.Core.Foundations.OperationState", - "description": "The status of the operation" - }, - "error": { - "$ref": "#/definitions/Azure.Core.Foundations.Error", - "description": "Error object that describes the error when status is \"Failed\"." - }, - "result": { - "$ref": "#/definitions/ClassifyResult", - "description": "The result of the operation." - } - }, - "required": [ - "id", - "status" - ] - }, - "headers": { - "Operation-Location": { - "type": "string", - "format": "uri", - "description": "The location for monitoring the operation state." - }, - "x-ms-client-request-id": { - "type": "string", - "format": "uuid", - "description": "An opaque, globally-unique, client-generated string identifier for the request." - } - } - }, - "default": { - "description": "An unexpected error response.", - "schema": { - "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" - }, - "headers": { - "x-ms-error-code": { - "type": "string", - "description": "String error code indicating what went wrong." - } - } - } - }, - "x-ms-examples": { - "Classify URL": { - "$ref": "./examples/ContentClassifiers_Classify.json" - } - }, - "x-ms-long-running-operation": true - } - }, - "/classifiers/{classifierId}/operations/{operationId}": { - "get": { - "operationId": "ContentClassifiers_GetOperationStatus", - "description": "Get the status of a classifier creation operation.", - "parameters": [ - { - "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" - }, - { - "name": "classifierId", - "in": "path", - "description": "The unique identifier of the classifier.", - "required": true, - "type": "string", - "pattern": "^[a-zA-Z0-9._-]{1,64}$" - }, - { - "name": "operationId", - "in": "path", - "description": "The unique ID of the operation.", - "required": true, - "type": "string" - } - ], - "responses": { - "200": { - "description": "The request has succeeded.", - "schema": { - "type": "object", - "description": "Provides status details for long running operations.", - "properties": { - "id": { - "type": "string", - "description": "The unique ID of the operation." - }, - "status": { - "$ref": "#/definitions/Azure.Core.Foundations.OperationState", - "description": "The status of the operation" - }, - "error": { - "$ref": "#/definitions/Azure.Core.Foundations.Error", - "description": "Error object that describes the error when status is \"Failed\"." - }, - "result": { - "$ref": "#/definitions/ContentClassifier", - "description": "The result of the operation." - } - }, - "required": [ - "id", - "status" - ] - } - }, - "default": { - "description": "An unexpected error response.", - "schema": { - "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" - }, - "headers": { - "x-ms-error-code": { - "type": "string", - "description": "String error code indicating what went wrong." - } - } - } - }, - "x-ms-examples": { - "Get Classifier Operation Status": { - "$ref": "./examples/ContentClassifiers_GetOperationStatus.json" - } - } - } - }, - "/faces:compare": { - "post": { - "operationId": "Faces_Compare", - "description": "Compare the similarity between two faces.", - "parameters": [ - { - "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" - }, - { - "$ref": "#/parameters/Azure.Core.ClientRequestIdHeader" - }, - { - "name": "body", - "in": "body", - "required": true, - "schema": { - "$ref": "#/definitions/CompareFacesParameters" - } - } - ], - "responses": { - "200": { - "description": "The request has succeeded.", - "schema": { - "$ref": "#/definitions/CompareFacesResult" - } - }, - "default": { - "description": "An unexpected error response.", - "schema": { - "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" - }, - "headers": { - "x-ms-error-code": { - "type": "string", - "description": "String error code indicating what went wrong." - } - } - } - }, - "x-ms-examples": { - "Compare the Similarity Between Two Faces": { - "$ref": "./examples/Faces_Compare.json" - } - } - } - }, - "/faces:detect": { - "post": { - "operationId": "Faces_Detect", - "description": "Detect faces in an image.", - "parameters": [ - { - "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" - }, - { - "$ref": "#/parameters/Azure.Core.ClientRequestIdHeader" - }, - { - "name": "body", - "in": "body", - "required": true, - "schema": { - "$ref": "#/definitions/DetectFacesParameters" - } - } - ], - "responses": { - "200": { - "description": "The request has succeeded.", - "schema": { - "$ref": "#/definitions/DetectFacesResult" - } - }, - "default": { - "description": "An unexpected error response.", - "schema": { - "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" - }, - "headers": { - "x-ms-error-code": { - "type": "string", - "description": "String error code indicating what went wrong." - } - } - } - }, - "x-ms-examples": { - "Detect Faces in an Image": { - "$ref": "./examples/Faces_Detect.json" - } - } - } - }, - "/personDirectories": { - "get": { - "operationId": "PersonDirectories_List", - "description": "List person directories.", - "parameters": [ - { - "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" - }, - { - "$ref": "#/parameters/Azure.Core.ClientRequestIdHeader" - } - ], - "responses": { - "200": { - "description": "The request has succeeded.", - "schema": { - "$ref": "#/definitions/PagedPersonDirectory" - }, - "headers": { - "x-ms-client-request-id": { - "type": "string", - "format": "uuid", - "description": "An opaque, globally-unique, client-generated string identifier for the request." - } - } - }, - "default": { - "description": "An unexpected error response.", - "schema": { - "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" - }, - "headers": { - "x-ms-error-code": { - "type": "string", - "description": "String error code indicating what went wrong." - } - } - } - }, - "x-ms-examples": { - "List Person Directories": { - "$ref": "./examples/PersonDirectories_List.json" - } - }, - "x-ms-pageable": { - "nextLinkName": "nextLink" - } - } - }, - "/personDirectories/{personDirectoryId}": { - "get": { - "operationId": "PersonDirectories_Get", - "description": "Get person directory properties.", - "parameters": [ - { - "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" - }, - { - "name": "personDirectoryId", - "in": "path", - "description": "The unique identifier of the person directory.", - "required": true, - "type": "string", - "pattern": "^[a-zA-Z0-9._-]{1,64}$" - }, - { - "$ref": "#/parameters/Azure.Core.ClientRequestIdHeader" - } - ], - "responses": { - "200": { - "description": "The request has succeeded.", - "schema": { - "$ref": "#/definitions/PersonDirectory" - }, - "headers": { - "x-ms-client-request-id": { - "type": "string", - "format": "uuid", - "description": "An opaque, globally-unique, client-generated string identifier for the request." - } - } - }, - "default": { - "description": "An unexpected error response.", - "schema": { - "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" - }, - "headers": { - "x-ms-error-code": { - "type": "string", - "description": "String error code indicating what went wrong." - } - } - } - }, - "x-ms-examples": { - "Get Person Directory": { - "$ref": "./examples/PersonDirectories_Get.json" - } - } - }, - "put": { - "operationId": "PersonDirectories_Create", - "description": "Create a new person directory.", - "parameters": [ - { - "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" - }, - { - "name": "personDirectoryId", - "in": "path", - "description": "The unique identifier of the person directory.", - "required": true, - "type": "string", - "pattern": "^[a-zA-Z0-9._-]{1,64}$" - }, - { - "$ref": "#/parameters/Azure.Core.ClientRequestIdHeader" - }, - { - "name": "resource", - "in": "body", - "description": "The resource instance.", - "required": true, - "schema": { - "$ref": "#/definitions/PersonDirectory" - } - } - ], - "responses": { - "201": { - "description": "The request has succeeded and a new resource has been created as a result.", - "schema": { - "$ref": "#/definitions/PersonDirectory" - }, - "headers": { - "x-ms-client-request-id": { - "type": "string", - "format": "uuid", - "description": "An opaque, globally-unique, client-generated string identifier for the request." - } - } - }, - "default": { - "description": "An unexpected error response.", - "schema": { - "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" - }, - "headers": { - "x-ms-error-code": { - "type": "string", - "description": "String error code indicating what went wrong." - } - } - } - }, - "x-ms-examples": { - "Create Person Directory": { - "$ref": "./examples/PersonDirectories_Create.json" - } - } - }, - "patch": { - "operationId": "PersonDirectories_Update", - "description": "Update person directory properties.", - "consumes": [ - "application/merge-patch+json" - ], - "parameters": [ - { - "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" - }, - { - "name": "personDirectoryId", - "in": "path", - "description": "The unique identifier of the person directory.", - "required": true, - "type": "string", - "pattern": "^[a-zA-Z0-9._-]{1,64}$" - }, - { - "$ref": "#/parameters/Azure.Core.ClientRequestIdHeader" - }, - { - "name": "resource", - "in": "body", - "description": "The resource instance.", - "required": true, - "schema": { - "$ref": "#/definitions/PersonDirectoryUpdate" - } - } - ], - "responses": { - "200": { - "description": "The request has succeeded.", - "schema": { - "$ref": "#/definitions/PersonDirectory" - }, - "headers": { - "x-ms-client-request-id": { - "type": "string", - "format": "uuid", - "description": "An opaque, globally-unique, client-generated string identifier for the request." - } - } - }, - "default": { - "description": "An unexpected error response.", - "schema": { - "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" - }, - "headers": { - "x-ms-error-code": { - "type": "string", - "description": "String error code indicating what went wrong." - } - } - } - }, - "x-ms-examples": { - "Update Person Directory": { - "$ref": "./examples/PersonDirectories_Update.json" - } - } - }, - "delete": { - "operationId": "PersonDirectories_Delete", - "description": "Delete person directory and all associated persons and faces.", - "parameters": [ - { - "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" - }, - { - "name": "personDirectoryId", - "in": "path", - "description": "The unique identifier of the person directory.", - "required": true, - "type": "string", - "pattern": "^[a-zA-Z0-9._-]{1,64}$" - }, - { - "$ref": "#/parameters/Azure.Core.ClientRequestIdHeader" - } - ], - "responses": { - "204": { - "description": "There is no content to send for this request, but the headers may be useful. ", - "headers": { - "x-ms-client-request-id": { - "type": "string", - "format": "uuid", - "description": "An opaque, globally-unique, client-generated string identifier for the request." - } - } - }, - "default": { - "description": "An unexpected error response.", - "schema": { - "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" - }, - "headers": { - "x-ms-error-code": { - "type": "string", - "description": "String error code indicating what went wrong." - } - } - } - }, - "x-ms-examples": { - "Delete Person Directory": { - "$ref": "./examples/PersonDirectories_Delete.json" - } - } - } - }, - "/personDirectories/{personDirectoryId}/faces": { - "get": { - "operationId": "PersonDirectories_ListFaces", - "description": "List faces.", - "parameters": [ - { - "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" - }, - { - "name": "personDirectoryId", - "in": "path", - "description": "The unique identifier of the person directory.", - "required": true, - "type": "string", - "pattern": "^[a-zA-Z0-9._-]{1,64}$" - }, - { - "$ref": "#/parameters/Azure.Core.ClientRequestIdHeader" - } - ], - "responses": { - "200": { - "description": "The request has succeeded.", - "schema": { - "$ref": "#/definitions/PagedPersonDirectoryFace" - }, - "headers": { - "x-ms-client-request-id": { - "type": "string", - "format": "uuid", - "description": "An opaque, globally-unique, client-generated string identifier for the request." - } - } - }, - "default": { - "description": "An unexpected error response.", - "schema": { - "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" - }, - "headers": { - "x-ms-error-code": { - "type": "string", - "description": "String error code indicating what went wrong." - } - } - } - }, - "x-ms-examples": { - "List Faces in Person Directory": { - "$ref": "./examples/PersonDirectories_ListFaces.json" - } - }, - "x-ms-pageable": { - "nextLinkName": "nextLink" - } - }, - "post": { - "operationId": "PersonDirectories_AddFace", - "description": "Add a new face.", - "parameters": [ - { - "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" - }, - { - "$ref": "#/parameters/AddFaceParameters.personDirectoryId" - }, - { - "$ref": "#/parameters/Azure.Core.ClientRequestIdHeader" - }, - { - "name": "body", - "in": "body", - "required": true, - "schema": { - "$ref": "#/definitions/AddFaceParameters" - } - } - ], - "responses": { - "201": { - "description": "The request has succeeded and a new resource has been created as a result.", - "schema": { - "$ref": "#/definitions/PersonDirectoryFace" - }, - "headers": { - "Location": { - "type": "string", - "format": "uri", - "description": "The location of an instance of PersonDirectoryFace" - }, - "x-ms-client-request-id": { - "type": "string", - "format": "uuid", - "description": "An opaque, globally-unique, client-generated string identifier for the request." - } - } - }, - "default": { - "description": "An unexpected error response.", - "schema": { - "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" - }, - "headers": { - "x-ms-error-code": { - "type": "string", - "description": "String error code indicating what went wrong." - } - } - } - }, - "x-ms-examples": { - "Add Face to Person Directory": { - "$ref": "./examples/PersonDirectories_AddFace.json" - } - } - } - }, - "/personDirectories/{personDirectoryId}/faces/{faceId}": { - "get": { - "operationId": "PersonDirectories_GetFace", - "description": "Get face properties.", - "parameters": [ - { - "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" - }, - { - "name": "personDirectoryId", - "in": "path", - "description": "The unique identifier of the person directory.", - "required": true, - "type": "string", - "pattern": "^[a-zA-Z0-9._-]{1,64}$" - }, - { - "name": "faceId", - "in": "path", - "description": "The unique identifier of the face.", - "required": true, - "type": "string", - "pattern": "^[a-zA-Z0-9._-]{1,64}$" - }, - { - "$ref": "#/parameters/Azure.Core.ClientRequestIdHeader" - } - ], - "responses": { - "200": { - "description": "The request has succeeded.", - "schema": { - "$ref": "#/definitions/PersonDirectoryFace" - }, - "headers": { - "x-ms-client-request-id": { - "type": "string", - "format": "uuid", - "description": "An opaque, globally-unique, client-generated string identifier for the request." - } - } - }, - "default": { - "description": "An unexpected error response.", - "schema": { - "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" - }, - "headers": { - "x-ms-error-code": { - "type": "string", - "description": "String error code indicating what went wrong." - } - } - } - }, - "x-ms-examples": { - "Get Face in Person Directory": { - "$ref": "./examples/PersonDirectories_GetFace.json" - } - } - }, - "patch": { - "operationId": "PersonDirectories_UpdateFace", - "description": "Update face properties, such as modifying the association with a person.", - "consumes": [ - "application/merge-patch+json" - ], - "parameters": [ - { - "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" - }, - { - "name": "personDirectoryId", - "in": "path", - "description": "The unique identifier of the person directory.", - "required": true, - "type": "string", - "pattern": "^[a-zA-Z0-9._-]{1,64}$" - }, - { - "name": "faceId", - "in": "path", - "description": "The unique identifier of the face.", - "required": true, - "type": "string", - "pattern": "^[a-zA-Z0-9._-]{1,64}$" - }, - { - "$ref": "#/parameters/Azure.Core.ClientRequestIdHeader" - }, - { - "name": "resource", - "in": "body", - "description": "The resource instance.", - "required": true, - "schema": { - "$ref": "#/definitions/PersonDirectoryFaceUpdate" - } - } - ], - "responses": { - "200": { - "description": "The request has succeeded.", - "schema": { - "$ref": "#/definitions/PersonDirectoryFace" - }, - "headers": { - "x-ms-client-request-id": { - "type": "string", - "format": "uuid", - "description": "An opaque, globally-unique, client-generated string identifier for the request." - } - } - }, - "default": { - "description": "An unexpected error response.", - "schema": { - "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" - }, - "headers": { - "x-ms-error-code": { - "type": "string", - "description": "String error code indicating what went wrong." - } - } - } - }, - "x-ms-examples": { - "Update Face in Person Directory": { - "$ref": "./examples/PersonDirectories_UpdateFace.json" - } - } - }, - "delete": { - "operationId": "PersonDirectories_DeleteFace", - "description": "Delete face. Any linked person will be disassociated, but not deleted.", - "parameters": [ - { - "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" - }, - { - "name": "personDirectoryId", - "in": "path", - "description": "The unique identifier of the person directory.", - "required": true, - "type": "string", - "pattern": "^[a-zA-Z0-9._-]{1,64}$" - }, - { - "name": "faceId", - "in": "path", - "description": "The unique identifier of the face.", - "required": true, - "type": "string", - "pattern": "^[a-zA-Z0-9._-]{1,64}$" - }, - { - "$ref": "#/parameters/Azure.Core.ClientRequestIdHeader" - } - ], - "responses": { - "204": { - "description": "There is no content to send for this request, but the headers may be useful. ", - "headers": { - "x-ms-client-request-id": { - "type": "string", - "format": "uuid", - "description": "An opaque, globally-unique, client-generated string identifier for the request." - } - } - }, - "default": { - "description": "An unexpected error response.", - "schema": { - "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" - }, - "headers": { - "x-ms-error-code": { - "type": "string", - "description": "String error code indicating what went wrong." - } - } - } - }, - "x-ms-examples": { - "Delete Face from Person Directory": { - "$ref": "./examples/PersonDirectories_DeleteFace.json" - } - } - } - }, - "/personDirectories/{personDirectoryId}/faces:find": { - "post": { - "operationId": "PersonDirectories_FindSimilarFaces", - "description": "Find similar faces.", - "parameters": [ - { - "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" - }, - { - "name": "personDirectoryId", - "in": "path", - "description": "The unique identifier of the person directory.", - "required": true, - "type": "string", - "pattern": "^[a-zA-Z0-9._-]{1,64}$" - }, - { - "$ref": "#/parameters/Azure.Core.ClientRequestIdHeader" - }, - { - "name": "body", - "in": "body", - "required": true, - "schema": { - "$ref": "#/definitions/FindSimilarFacesParameters" - } - } - ], - "responses": { - "200": { - "description": "The request has succeeded.", - "schema": { - "$ref": "#/definitions/FindSimilarFacesResult" - }, - "headers": { - "x-ms-client-request-id": { - "type": "string", - "format": "uuid", - "description": "An opaque, globally-unique, client-generated string identifier for the request." - } - } - }, - "default": { - "description": "An unexpected error response.", - "schema": { - "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" - }, - "headers": { - "x-ms-error-code": { - "type": "string", - "description": "String error code indicating what went wrong." - } - } - } - }, - "x-ms-examples": { - "Find Similar Faces": { - "$ref": "./examples/PersonDirectories_FindSimilarFaces.json" - } - } - } - }, - "/personDirectories/{personDirectoryId}/persons": { - "get": { - "operationId": "PersonDirectories_ListPersons", - "description": "List persons.", - "parameters": [ - { - "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" - }, - { - "name": "personDirectoryId", - "in": "path", - "description": "The unique identifier of the person directory.", - "required": true, - "type": "string", - "pattern": "^[a-zA-Z0-9._-]{1,64}$" - }, - { - "$ref": "#/parameters/Azure.Core.ClientRequestIdHeader" - } - ], - "responses": { - "200": { - "description": "The request has succeeded.", - "schema": { - "$ref": "#/definitions/PagedPersonDirectoryPerson" - }, - "headers": { - "x-ms-client-request-id": { - "type": "string", - "format": "uuid", - "description": "An opaque, globally-unique, client-generated string identifier for the request." - } - } - }, - "default": { - "description": "An unexpected error response.", - "schema": { - "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" - }, - "headers": { - "x-ms-error-code": { - "type": "string", - "description": "String error code indicating what went wrong." - } - } - } - }, - "x-ms-examples": { - "List Persons in Person Directory": { - "$ref": "./examples/PersonDirectories_ListPersons.json" - } - }, - "x-ms-pageable": { - "nextLinkName": "nextLink" - } - }, - "post": { - "operationId": "PersonDirectories_AddPerson", - "description": "Add a new person and optionally associate with existing faces.", - "parameters": [ - { - "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" - }, - { - "$ref": "#/parameters/AddPersonParameters.personDirectoryId" - }, - { - "$ref": "#/parameters/Azure.Core.ClientRequestIdHeader" - }, - { - "name": "body", - "in": "body", - "required": true, - "schema": { - "$ref": "#/definitions/AddPersonParameters" - } - } - ], - "responses": { - "201": { - "description": "The request has succeeded and a new resource has been created as a result.", - "schema": { - "$ref": "#/definitions/PersonDirectoryPerson" - }, - "headers": { - "Location": { - "type": "string", - "format": "uri", - "description": "The location of an instance of PersonDirectoryPerson" - }, - "x-ms-client-request-id": { - "type": "string", - "format": "uuid", - "description": "An opaque, globally-unique, client-generated string identifier for the request." - } - } - }, - "default": { - "description": "An unexpected error response.", - "schema": { - "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" - }, - "headers": { - "x-ms-error-code": { - "type": "string", - "description": "String error code indicating what went wrong." - } - } - } - }, - "x-ms-examples": { - "Add Person to Person Directory": { - "$ref": "./examples/PersonDirectories_AddPerson.json" - } - } - } - }, - "/personDirectories/{personDirectoryId}/persons/{personId}": { - "get": { - "operationId": "PersonDirectories_GetPerson", - "description": "Get person properties.", - "parameters": [ - { - "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" - }, - { - "name": "personDirectoryId", - "in": "path", - "description": "The unique identifier of the person directory.", - "required": true, - "type": "string", - "pattern": "^[a-zA-Z0-9._-]{1,64}$" - }, - { - "name": "personId", - "in": "path", - "description": "The unique identifier of the person.", - "required": true, - "type": "string", - "pattern": "^[a-zA-Z0-9._-]{1,64}$" - }, - { - "$ref": "#/parameters/Azure.Core.ClientRequestIdHeader" - } - ], - "responses": { - "200": { - "description": "The request has succeeded.", - "schema": { - "$ref": "#/definitions/PersonDirectoryPerson" - }, - "headers": { - "x-ms-client-request-id": { - "type": "string", - "format": "uuid", - "description": "An opaque, globally-unique, client-generated string identifier for the request." - } - } - }, - "default": { - "description": "An unexpected error response.", - "schema": { - "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" - }, - "headers": { - "x-ms-error-code": { - "type": "string", - "description": "String error code indicating what went wrong." - } - } - } - }, - "x-ms-examples": { - "Get Person in Person Directory": { - "$ref": "./examples/PersonDirectories_GetPerson.json" - } - } - }, - "patch": { - "operationId": "PersonDirectories_UpdatePerson", - "description": "Update person properties.", - "consumes": [ - "application/merge-patch+json" - ], - "parameters": [ - { - "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" - }, - { - "name": "personDirectoryId", - "in": "path", - "description": "The unique identifier of the person directory.", - "required": true, - "type": "string", - "pattern": "^[a-zA-Z0-9._-]{1,64}$" - }, - { - "name": "personId", - "in": "path", - "description": "The unique identifier of the person.", - "required": true, - "type": "string", - "pattern": "^[a-zA-Z0-9._-]{1,64}$" - }, - { - "$ref": "#/parameters/Azure.Core.ClientRequestIdHeader" - }, - { - "name": "resource", - "in": "body", - "description": "The resource instance.", - "required": true, - "schema": { - "$ref": "#/definitions/PersonDirectoryPersonUpdate" - } - } - ], - "responses": { - "200": { - "description": "The request has succeeded.", - "schema": { - "$ref": "#/definitions/PersonDirectoryPerson" - }, - "headers": { - "x-ms-client-request-id": { - "type": "string", - "format": "uuid", - "description": "An opaque, globally-unique, client-generated string identifier for the request." - } - } - }, - "default": { - "description": "An unexpected error response.", - "schema": { - "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" - }, - "headers": { - "x-ms-error-code": { - "type": "string", - "description": "String error code indicating what went wrong." - } - } - } - }, - "x-ms-examples": { - "Update Person in Person Directory": { - "$ref": "./examples/PersonDirectories_UpdatePerson.json" - } - } - }, - "delete": { - "operationId": "PersonDirectories_DeletePerson", - "description": "Delete person. Any linked faces will be disassociated, but not deleted.", - "parameters": [ - { - "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" - }, - { - "name": "personDirectoryId", - "in": "path", - "description": "The unique identifier of the person directory.", - "required": true, - "type": "string", - "pattern": "^[a-zA-Z0-9._-]{1,64}$" - }, - { - "name": "personId", - "in": "path", - "description": "The unique identifier of the person.", - "required": true, - "type": "string", - "pattern": "^[a-zA-Z0-9._-]{1,64}$" - }, - { - "$ref": "#/parameters/Azure.Core.ClientRequestIdHeader" - } - ], - "responses": { - "204": { - "description": "There is no content to send for this request, but the headers may be useful. ", - "headers": { - "x-ms-client-request-id": { - "type": "string", - "format": "uuid", - "description": "An opaque, globally-unique, client-generated string identifier for the request." - } - } - }, - "default": { - "description": "An unexpected error response.", - "schema": { - "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" - }, - "headers": { - "x-ms-error-code": { - "type": "string", - "description": "String error code indicating what went wrong." - } - } - } - }, - "x-ms-examples": { - "Delete Person from Person Directory": { - "$ref": "./examples/PersonDirectories_DeletePerson.json" - } - } - } - }, - "/personDirectories/{personDirectoryId}/persons/{personId}:verify": { - "post": { - "operationId": "PersonDirectories_VerifyPerson", - "description": "Verify if a face matches the person.", - "parameters": [ - { - "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" - }, - { - "name": "personDirectoryId", - "in": "path", - "description": "The unique identifier of the person directory.", - "required": true, - "type": "string", - "pattern": "^[a-zA-Z0-9._-]{1,64}$" - }, - { - "name": "personId", - "in": "path", - "description": "The unique identifier of the person.", - "required": true, - "type": "string", - "pattern": "^[a-zA-Z0-9._-]{1,64}$" - }, - { - "$ref": "#/parameters/Azure.Core.ClientRequestIdHeader" - }, - { - "name": "body", - "in": "body", - "required": true, - "schema": { - "$ref": "#/definitions/VerifyPersonParameters" - } - } - ], - "responses": { - "200": { - "description": "The request has succeeded.", - "schema": { - "$ref": "#/definitions/VerifyPersonResult" - }, - "headers": { - "x-ms-client-request-id": { - "type": "string", - "format": "uuid", - "description": "An opaque, globally-unique, client-generated string identifier for the request." - } - } - }, - "default": { - "description": "An unexpected error response.", - "schema": { - "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" - }, - "headers": { - "x-ms-error-code": { - "type": "string", - "description": "String error code indicating what went wrong." - } - } - } - }, - "x-ms-examples": { - "Verify If a Face Matches the Person": { - "$ref": "./examples/PersonDirectories_VerifyPerson.json" - } - } - } - }, - "/personDirectories/{personDirectoryId}/persons:identify": { - "post": { - "operationId": "PersonDirectories_IdentifyPerson", - "description": "Identify the person from a face.", - "parameters": [ - { - "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" - }, - { - "name": "personDirectoryId", - "in": "path", - "description": "The unique identifier of the person directory.", - "required": true, - "type": "string", - "pattern": "^[a-zA-Z0-9._-]{1,64}$" - }, - { - "$ref": "#/parameters/Azure.Core.ClientRequestIdHeader" - }, - { - "name": "body", - "in": "body", - "required": true, - "schema": { - "$ref": "#/definitions/IdentifyPersonParameters" - } - } - ], - "responses": { - "200": { - "description": "The request has succeeded.", - "schema": { - "$ref": "#/definitions/IdentifyPersonResult" - }, - "headers": { - "x-ms-client-request-id": { - "type": "string", - "format": "uuid", - "description": "An opaque, globally-unique, client-generated string identifier for the request." - } - } - }, - "default": { - "description": "An unexpected error response.", - "schema": { - "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" - }, - "headers": { - "x-ms-error-code": { - "type": "string", - "description": "String error code indicating what went wrong." - } - } - } - }, - "x-ms-examples": { - "Identify the Person from a Face": { - "$ref": "./examples/PersonDirectories_IdentifyPerson.json" - } - } - } - } - }, - "x-ms-paths": { - "/analyzers/{analyzerId}:analyze?_overload=analyzeBinary": { - "post": { - "operationId": "ContentAnalyzers_AnalyzeBinary", - "description": "Extract content and fields from input.", - "consumes": [ - "*/*" - ], - "parameters": [ - { - "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" - }, - { - "name": "analyzerId", - "in": "path", - "description": "The unique identifier of the analyzer.", - "required": true, - "type": "string", - "pattern": "^[a-zA-Z0-9._-]{1,64}$" - }, - { - "$ref": "#/parameters/AnalyzeParameters.stringEncoding" - }, - { - "$ref": "#/parameters/AnalyzeParameters.processingLocation" - }, - { - "$ref": "#/parameters/Azure.Core.ClientRequestIdHeader" - }, - { - "$ref": "#/parameters/AnalyzeBinaryRequest.input" - } - ], - "responses": { - "202": { - "description": "The request has been accepted for processing, but processing has not yet completed.", - "schema": { - "type": "object", - "description": "Provides status details for long running operations.", - "properties": { - "id": { - "type": "string", - "description": "The unique ID of the operation." - }, - "status": { - "$ref": "#/definitions/Azure.Core.Foundations.OperationState", - "description": "The status of the operation" - }, - "error": { - "$ref": "#/definitions/Azure.Core.Foundations.Error", - "description": "Error object that describes the error when status is \"Failed\"." - }, - "result": { - "$ref": "#/definitions/AnalyzeResult", - "description": "The result of the operation." - } - }, - "required": [ - "id", - "status" - ] - }, - "headers": { - "Operation-Location": { - "type": "string", - "format": "uri", - "description": "The location for monitoring the operation state." - }, - "x-ms-client-request-id": { - "type": "string", - "format": "uuid", - "description": "An opaque, globally-unique, client-generated string identifier for the request." - } - } - }, - "default": { - "description": "An unexpected error response.", - "schema": { - "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" - }, - "headers": { - "x-ms-error-code": { - "type": "string", - "description": "String error code indicating what went wrong." - } - } - } - }, - "x-ms-examples": { - "Analyze File": { - "$ref": "./examples/ContentAnalyzers_AnalyzeBinary.json" - } - }, - "x-ms-long-running-operation": true - } - }, - "/classifiers/{classifierId}:classify?_overload=classifyBinary": { - "post": { - "operationId": "ContentClassifiers_ClassifyBinary", - "description": "Classify content with optional splitting.", - "consumes": [ - "*/*" - ], - "parameters": [ - { - "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" - }, - { - "name": "classifierId", - "in": "path", - "description": "The unique identifier of the classifier.", - "required": true, - "type": "string", - "pattern": "^[a-zA-Z0-9._-]{1,64}$" - }, - { - "$ref": "#/parameters/ClassifyParameters.stringEncoding" - }, - { - "$ref": "#/parameters/ClassifyParameters.processingLocation" - }, - { - "$ref": "#/parameters/Azure.Core.ClientRequestIdHeader" - }, - { - "$ref": "#/parameters/ClassifyBinaryRequest.input" - } - ], - "responses": { - "202": { - "description": "The request has been accepted for processing, but processing has not yet completed.", - "schema": { - "type": "object", - "description": "Provides status details for long running operations.", - "properties": { - "id": { - "type": "string", - "description": "The unique ID of the operation." - }, - "status": { - "$ref": "#/definitions/Azure.Core.Foundations.OperationState", - "description": "The status of the operation" - }, - "error": { - "$ref": "#/definitions/Azure.Core.Foundations.Error", - "description": "Error object that describes the error when status is \"Failed\"." - }, - "result": { - "$ref": "#/definitions/ClassifyResult", - "description": "The result of the operation." - } - }, - "required": [ - "id", - "status" - ] - }, - "headers": { - "Operation-Location": { - "type": "string", - "format": "uri", - "description": "The location for monitoring the operation state." - }, - "x-ms-client-request-id": { - "type": "string", - "format": "uuid", - "description": "An opaque, globally-unique, client-generated string identifier for the request." - } - } - }, - "default": { - "description": "An unexpected error response.", - "schema": { - "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" - }, - "headers": { - "x-ms-error-code": { - "type": "string", - "description": "String error code indicating what went wrong." - } - } - } - }, - "x-ms-examples": { - "Classify File": { - "$ref": "./examples/ContentClassifiers_ClassifyBinary.json" - } - }, - "x-ms-long-running-operation": true - } - } - }, - "definitions": { - "AddFaceParameters": { - "type": "object", - "description": "Add face parameters.", - "properties": { - "faceSource": { - "$ref": "#/definitions/FaceSource", - "description": "Source of the face." - }, - "personId": { - "type": "string", - "description": "Person identifier with which to associate the face." - }, - "qualityThreshold": { - "type": "string", - "description": "Face quality threshold below which the face will not be added. Default is medium.", - "default": "medium", - "enum": [ - "low", - "medium", - "high" - ], - "x-ms-enum": { - "name": "QualityForRecognition", - "modelAsString": true, - "values": [ - { - "name": "low", - "value": "low", - "description": "Low quality." - }, - { - "name": "medium", - "value": "medium", - "description": "Medium quality." - }, - { - "name": "high", - "value": "high", - "description": "High quality." - } - ] - } - } - }, - "required": [ - "faceSource" - ] - }, - "AddPersonParameters": { - "type": "object", - "description": "Add person parameters.", - "properties": { - "tags": { - "type": "object", - "description": "Tags associated with the person.", - "additionalProperties": { - "type": "string" - } - }, - "faceIds": { - "type": "array", - "description": "List of faces associated with the person.", - "items": { - "type": "string" - } - } - } - }, - "AnalyzeInput": { - "type": "object", - "description": "Additional input to analyze.", - "properties": { - "url": { - "type": "string", - "format": "uri", - "description": "The URL of the input to analyze. Only one of url or data should be specified." - }, - "data": { - "type": "string", - "format": "byte", - "description": "Base64-encoded binary content of the input to analyze. Only one of url or data should be specified." - }, - "name": { - "type": "string", - "description": "Name of the input." - } - }, - "required": [ - "url" - ] - }, - "AnalyzeRequest": { - "type": "object", - "description": "Analyze operation request.", - "properties": { - "url": { - "type": "string", - "format": "uri", - "description": "The URL of the primary input to analyze. Only one of url or data should be specified." - }, - "data": { - "type": "string", - "format": "byte", - "description": "Base64-encoded binary content of the primary input to analyze. Only one of url or data should be specified." - }, - "inputs": { - "type": "array", - "description": "Additional inputs to analyze. Only supported in analyzers with mode=pro.", - "items": { - "$ref": "#/definitions/AnalyzeInput" - } - } - } - }, - "AnalyzeResult": { - "type": "object", - "description": "Analyze operation result.", - "properties": { - "analyzerId": { - "type": "string", - "description": "The unique identifier of the analyzer.", - "pattern": "^[a-zA-Z0-9._-]{1,64}$" - }, - "apiVersion": { - "type": "string", - "description": "The version of the API used to analyze the document." - }, - "createdAt": { - "type": "string", - "format": "date-time", - "description": "The date and time when the result was created." - }, - "warnings": { - "type": "array", - "description": "Warnings encountered while analyzing the document.", - "items": { - "$ref": "#/definitions/Azure.Core.Foundations.Error" - } - }, - "stringEncoding": { - "type": "string", - "description": "The string encoding used for content spans.", - "default": "codePoint", - "enum": [ - "codePoint", - "utf16", - "utf8" - ], - "x-ms-enum": { - "name": "StringEncoding", - "modelAsString": true, - "values": [ - { - "name": "codePoint", - "value": "codePoint", - "description": "Unicode code point (UTF-32) encoding, used by languages such as Python, etc." - }, - { - "name": "utf16", - "value": "utf16", - "description": "UTF-16 encoding, used by languages such as C#, JavaScript, Java, etc." - }, - { - "name": "utf8", - "value": "utf8", - "description": "UTF-8 encoding, used by languages such as Go, Rust, Ruby, PHP, etc." - } - ] - } - }, - "contents": { - "type": "array", - "description": "The extracted content.", - "items": { - "$ref": "#/definitions/MediaContent" - } - } - }, - "required": [ - "contents" - ] - }, - "ArrayField": { - "type": "object", - "description": "Array field extracted from the content.", - "properties": { - "valueArray": { - "type": "array", - "description": "Array field value.", - "items": { - "$ref": "#/definitions/ContentField" - } - } - }, - "allOf": [ - { - "$ref": "#/definitions/ContentField" - } - ], - "x-ms-discriminator-value": "array" - }, - "AudioVisualContent": { - "type": "object", - "description": "Audio visual content. Ex. audio/wav, video/mp4.", - "properties": { - "startTimeMs": { - "type": "integer", - "format": "int64", - "description": "Start time of the content in milliseconds." - }, - "endTimeMs": { - "type": "integer", - "format": "int64", - "description": "End time of the content in milliseconds." - }, - "width": { - "type": "integer", - "format": "int32", - "description": "Width of each video frame in pixels, if applicable." - }, - "height": { - "type": "integer", - "format": "int32", - "description": "Height of each video frame in pixels, if applicable." - }, - "cameraShotTimesMs": { - "type": "array", - "description": "List of camera shot changes in the video, represented by its timestamp in milliseconds. Only if returnDetails is true.", - "items": { - "type": "integer", - "format": "int64" - } - }, - "keyFrameTimesMs": { - "type": "array", - "description": "List of key frames in the video, represented by its timestamp in milliseconds. Only if returnDetails is true.", - "items": { - "type": "integer", - "format": "int64" - } - }, - "transcriptPhrases": { - "type": "array", - "description": "List of transcript phrases. Only if returnDetails is true.", - "items": { - "$ref": "#/definitions/TranscriptPhrase" - } - }, - "persons": { - "type": "array", - "description": "List of detected persons in the video. Only if enableFace and returnDetails are true.", - "items": { - "$ref": "#/definitions/DetectedPerson" - } - }, - "segments": { - "type": "array", - "description": "List of audio visual segments. Only if enableSegmentation and returnDetails are true.", - "items": { - "$ref": "#/definitions/AudioVisualSegment" - } - } - }, - "required": [ - "startTimeMs", - "endTimeMs" - ], - "allOf": [ - { - "$ref": "#/definitions/MediaContent" - } - ], - "x-ms-discriminator-value": "audioVisual" - }, - "AudioVisualSegment": { - "type": "object", - "description": "Audio visual segment, such as a scene, chapter, etc.", - "properties": { - "segmentId": { - "type": "string", - "description": "Segment ID." - }, - "startTimeMs": { - "type": "integer", - "format": "int64", - "description": "Start time of the segment in milliseconds." - }, - "endTimeMs": { - "type": "integer", - "format": "int64", - "description": "End time of the segment in milliseconds." - }, - "description": { - "type": "string", - "description": "Short description of the segment." - }, - "span": { - "$ref": "#/definitions/ContentSpan", - "description": "Span of the segment in the markdown content." - } - }, - "required": [ - "segmentId", - "startTimeMs", - "endTimeMs", - "description" - ] - }, - "Azure.Core.Foundations.Error": { - "type": "object", - "description": "The error object.", - "properties": { - "code": { - "type": "string", - "description": "One of a server-defined set of error codes." - }, - "message": { - "type": "string", - "description": "A human-readable representation of the error." - }, - "target": { - "type": "string", - "description": "The target of the error." - }, - "details": { - "type": "array", - "description": "An array of details about specific errors that led to this reported error.", - "items": { - "$ref": "#/definitions/Azure.Core.Foundations.Error" - } - }, - "innererror": { - "$ref": "#/definitions/Azure.Core.Foundations.InnerError", - "description": "An object containing more specific information than the current object about the error." - } - }, - "required": [ - "code", - "message" - ] - }, - "Azure.Core.Foundations.ErrorResponse": { - "type": "object", - "description": "A response containing error details.", - "properties": { - "error": { - "$ref": "#/definitions/Azure.Core.Foundations.Error", - "description": "The error object." - } - }, - "required": [ - "error" - ] - }, - "Azure.Core.Foundations.InnerError": { - "type": "object", - "description": "An object containing more specific information about the error. As per Azure REST API guidelines - https://aka.ms/AzureRestApiGuidelines#handling-errors.", - "properties": { - "code": { - "type": "string", - "description": "One of a server-defined set of error codes." - }, - "innererror": { - "$ref": "#/definitions/Azure.Core.Foundations.InnerError", - "description": "Inner error." - } - } - }, - "Azure.Core.Foundations.OperationState": { - "type": "string", - "description": "Enum describing allowed operation states.", - "enum": [ - "NotStarted", - "Running", - "Succeeded", - "Failed", - "Canceled" - ], - "x-ms-enum": { - "name": "OperationState", - "modelAsString": true, - "values": [ - { - "name": "NotStarted", - "value": "NotStarted", - "description": "The operation has not started." - }, - { - "name": "Running", - "value": "Running", - "description": "The operation is in progress." - }, - { - "name": "Succeeded", - "value": "Succeeded", - "description": "The operation has completed successfully." - }, - { - "name": "Failed", - "value": "Failed", - "description": "The operation has failed." - }, - { - "name": "Canceled", - "value": "Canceled", - "description": "The operation has been canceled by the user." - } - ] - } - }, - "BlobDataSource": { - "type": "object", - "description": "Blob storage data source.", - "properties": { - "containerUrl": { - "type": "string", - "format": "uri", - "description": "The URL of the blob container." - }, - "prefix": { - "type": "string", - "description": "An optional prefix to filter blobs within the container." - }, - "fileListPath": { - "type": "string", - "description": "An optional path to a file listing specific blobs to include." - } - }, - "required": [ - "containerUrl" - ], - "allOf": [ - { - "$ref": "#/definitions/DataSource" - } - ], - "x-ms-discriminator-value": "blob" - }, - "BooleanField": { - "type": "object", - "description": "Boolean field extracted from the content.", - "properties": { - "valueBoolean": { - "type": "boolean", - "description": "Boolean field value." - } - }, - "allOf": [ - { - "$ref": "#/definitions/ContentField" - } - ], - "x-ms-discriminator-value": "boolean" - }, - "BoundingBox": { - "type": "object", - "description": "Bounding box in an image.", - "properties": { - "left": { - "type": "integer", - "format": "int32", - "description": "Left coordinate of the bounding box." - }, - "top": { - "type": "integer", - "format": "int32", - "description": "Top coordinate of the bounding box." - }, - "width": { - "type": "integer", - "format": "int32", - "description": "Width of the bounding box." - }, - "height": { - "type": "integer", - "format": "int32", - "description": "Height of the bounding box." - } - }, - "required": [ - "left", - "top", - "width", - "height" - ] - }, - "ClassifierCategoryDefinition": { - "type": "object", - "description": "A classifier category.", - "properties": { - "description": { - "type": "string", - "description": "The description of the category.", - "x-ms-mutability": [ - "read", - "create" - ] - }, - "analyzerId": { - "type": "string", - "description": "Optional analyzer used to process the content." - } - } - }, - "ClassifyRequest": { - "type": "object", - "description": "Classify operation request.", - "properties": { - "url": { - "type": "string", - "format": "uri", - "description": "The URL of the document to classify." - } - } - }, - "ClassifyResult": { - "type": "object", - "description": "Classify operation result.", - "properties": { - "classifierId": { - "type": "string", - "description": "The unique identifier of the classifier.", - "pattern": "^[a-zA-Z0-9._-]{1,64}$" - }, - "apiVersion": { - "type": "string", - "description": "The version of the API used to classify the document." - }, - "createdAt": { - "type": "string", - "format": "date-time", - "description": "The date and time when the result was created." - }, - "warnings": { - "type": "array", - "description": "Warnings encountered while classifying the document.", - "items": { - "$ref": "#/definitions/Azure.Core.Foundations.Error" - } - }, - "stringEncoding": { - "type": "string", - "description": "The string encoding used for content spans.", - "default": "codePoint", - "enum": [ - "codePoint", - "utf16", - "utf8" - ], - "x-ms-enum": { - "name": "StringEncoding", - "modelAsString": true, - "values": [ - { - "name": "codePoint", - "value": "codePoint", - "description": "Unicode code point (UTF-32) encoding, used by languages such as Python, etc." - }, - { - "name": "utf16", - "value": "utf16", - "description": "UTF-16 encoding, used by languages such as C#, JavaScript, Java, etc." - }, - { - "name": "utf8", - "value": "utf8", - "description": "UTF-8 encoding, used by languages such as Go, Rust, Ruby, PHP, etc." - } - ] - } - }, - "contents": { - "type": "array", - "description": "The classified content.", - "items": { - "$ref": "#/definitions/MediaContent" - } - } - }, - "required": [ - "contents" - ] - }, - "CompareFacesParameters": { - "type": "object", - "description": "Compare faces parameters.", - "properties": { - "faceSource1": { - "$ref": "#/definitions/FaceSource", - "description": "First face to compare." - }, - "faceSource2": { - "$ref": "#/definitions/FaceSource", - "description": "Second face to compare." - } - }, - "required": [ - "faceSource1", - "faceSource2" - ] - }, - "CompareFacesResult": { - "type": "object", - "description": "Compare faces response.", - "properties": { - "detectedFace1": { - "$ref": "#/definitions/DetectedBoundingBox", - "description": "Details of the first detected face." - }, - "detectedFace2": { - "$ref": "#/definitions/DetectedBoundingBox", - "description": "Details of the second detected face." - }, - "confidence": { - "type": "number", - "format": "float", - "description": "Confidence score of the face comparison." - } - }, - "required": [ - "detectedFace1", - "detectedFace2", - "confidence" - ] - }, - "ContentAnalyzer": { - "type": "object", - "description": "Analyzer that extracts content and fields from multimodal documents.", - "properties": { - "analyzerId": { - "type": "string", - "description": "The unique identifier of the analyzer.", - "pattern": "^[a-zA-Z0-9._-]{1,64}$", - "readOnly": true - }, - "description": { - "type": "string", - "description": "A description of the analyzer." - }, - "tags": { - "type": "object", - "description": "Tags associated with the analyzer.", - "additionalProperties": { - "type": "string" - } - }, - "status": { - "$ref": "#/definitions/ResourceStatus", - "description": "The status of the analyzer.", - "readOnly": true - }, - "createdAt": { - "type": "string", - "format": "date-time", - "description": "The date and time when the analyzer was created.", - "readOnly": true - }, - "lastModifiedAt": { - "type": "string", - "format": "date-time", - "description": "The date and time when the analyzer was last modified.", - "readOnly": true - }, - "warnings": { - "type": "array", - "description": "Warnings encountered while creating the analyzer.", - "items": { - "$ref": "#/definitions/Azure.Core.Foundations.Error" - }, - "readOnly": true - }, - "baseAnalyzerId": { - "type": "string", - "description": "The analyzer to incrementally train from.", - "pattern": "^[a-zA-Z0-9._-]{1,64}$", - "x-ms-mutability": [ - "read", - "create" - ] - }, - "config": { - "$ref": "#/definitions/ContentAnalyzerConfig", - "description": "Analyzer configuration settings.", - "x-ms-mutability": [ - "read", - "create" - ] - }, - "fieldSchema": { - "$ref": "#/definitions/ContentFieldSchema", - "description": "The schema of fields to extracted.", - "x-ms-mutability": [ - "read", - "create" - ] - }, - "trainingData": { - "$ref": "#/definitions/DataSource", - "description": "The data source containing training data for the analyzer.", - "x-ms-mutability": [ - "read", - "create" - ] - }, - "processingLocation": { - "type": "string", - "description": "The location where the data may be processed.", - "default": "geography", - "enum": [ - "geography", - "dataZone", - "global" - ], - "x-ms-enum": { - "name": "ProcessingLocation", - "modelAsString": true, - "values": [ - { - "name": "geography", - "value": "geography", - "description": "Data may be processed in the same geography as the resource." - }, - { - "name": "dataZone", - "value": "dataZone", - "description": "Data may be processed in the same data zone as the resource." - }, - { - "name": "global", - "value": "global", - "description": "Data may be processed in any Azure data center globally." - } - ] - }, - "x-ms-mutability": [ - "read", - "create" - ] - }, - "mode": { - "type": "string", - "description": "The analysis mode: standard, pro. Default is standard.", - "default": "standard", - "enum": [ - "standard", - "pro" - ], - "x-ms-enum": { - "name": "AnalysisMode", - "modelAsString": true, - "values": [ - { - "name": "standard", - "value": "standard", - "description": "Standard analysis mode." - }, - { - "name": "pro", - "value": "pro", - "description": "Pro analysis mode." - } - ] - }, - "x-ms-mutability": [ - "read", - "create" - ] - }, - "knowledgeSources": { - "type": "array", - "description": "Additional knowledge sources used to enhance the analyzer.", - "items": { - "$ref": "#/definitions/KnowledgeSource" - } - } - }, - "required": [ - "analyzerId", - "status", - "createdAt", - "lastModifiedAt" - ] - }, - "ContentAnalyzerConfig": { - "type": "object", - "description": "Configuration settings for an analyzer.", - "properties": { - "returnDetails": { - "type": "boolean", - "description": "Return all content details." - }, - "locales": { - "type": "array", - "description": "List of locale hints for speech transcription.", - "items": { - "type": "string" - } - }, - "enableFace": { - "type": "boolean", - "description": "Enable face detection." - }, - "personDirectoryId": { - "type": "string", - "description": "Specify the person directory used for identifying detected faces." - }, - "enableOcr": { - "type": "boolean", - "description": "Enable optical character recognition (OCR)." - }, - "enableLayout": { - "type": "boolean", - "description": "Enable layout analysis." - }, - "tableFormat": { - "type": "string", - "description": "Representation format of tables in analyze result markdown.", - "default": "html", - "enum": [ - "html" - ], - "x-ms-enum": { - "name": "TableFormat", - "modelAsString": true, - "values": [ - { - "name": "html", - "value": "html", - "description": "Represent tables using HTML table elements: \\, \\, \\
, \\
." - } - ] - } - }, - "enableFormula": { - "type": "boolean", - "description": "Enable mathematical formula detection." - }, - "disableFaceBlurring": { - "type": "boolean", - "description": "Disable the default blurring of faces for privacy while processing the content." - }, - "disableContentFiltering": { - "type": "boolean", - "description": "Disable content filtering that detects and prevents the output of harmful content." - }, - "estimateFieldSourceAndConfidence": { - "type": "boolean", - "description": "Return grounding source and confidence for extracted fields." - }, - "segmentationMode": { - "type": "string", - "description": "Segmentation mode used to split audio/visual content.", - "default": "noSegmentation", - "enum": [ - "noSegmentation", - "auto", - "custom" - ], - "x-ms-enum": { - "name": "SegmentationMode", - "modelAsString": true, - "values": [ - { - "name": "noSegmentation", - "value": "noSegmentation", - "description": "No segmentation." - }, - { - "name": "auto", - "value": "auto", - "description": "Automatic segmentation." - }, - { - "name": "custom", - "value": "custom", - "description": "Segment according to custom segmentation definition." - } - ] - } - }, - "segmentationDefinition": { - "type": "string", - "description": "Segmentation definition for use with custom segmentation mode." - } - } - }, - "ContentAnalyzerUpdate": { - "type": "object", - "description": "Analyzer that extracts content and fields from multimodal documents.", - "properties": { - "description": { - "type": "string", - "description": "A description of the analyzer." - }, - "tags": { - "type": "object", - "description": "Tags associated with the analyzer.", - "additionalProperties": { - "type": "string" - } - }, - "knowledgeSources": { - "type": "array", - "description": "Additional knowledge sources used to enhance the analyzer.", - "items": { - "$ref": "#/definitions/KnowledgeSource" - } - } - } - }, - "ContentClassifier": { - "type": "object", - "description": "Classifier that classifies content into categories with optional splitting.", - "properties": { - "classifierId": { - "type": "string", - "description": "The unique identifier of the classifier.", - "pattern": "^[a-zA-Z0-9._-]{1,64}$", - "readOnly": true - }, - "description": { - "type": "string", - "description": "A description of the classifier." - }, - "tags": { - "type": "object", - "description": "Tags associated with the classifier.", - "additionalProperties": { - "type": "string" - } - }, - "status": { - "$ref": "#/definitions/ResourceStatus", - "description": "The status of the classifier.", - "readOnly": true - }, - "createdAt": { - "type": "string", - "format": "date-time", - "description": "The date and time when the classifier was created.", - "readOnly": true - }, - "lastModifiedAt": { - "type": "string", - "format": "date-time", - "description": "The date and time when the classifier was last modified.", - "readOnly": true - }, - "warnings": { - "type": "array", - "description": "Warnings encountered while creating the classifier.", - "items": { - "$ref": "#/definitions/Azure.Core.Foundations.Error" - }, - "readOnly": true - }, - "categories": { - "type": "object", - "description": "The categories to classify against.", - "additionalProperties": { - "$ref": "#/definitions/ClassifierCategoryDefinition" - }, - "x-ms-mutability": [ - "read", - "create" - ] - }, - "splitMode": { - "type": "string", - "description": "Mode used to split input into content objects.", - "default": "noSplit", - "enum": [ - "noSplit", - "perPage", - "auto" - ], - "x-ms-enum": { - "name": "ClassifierSplitMode", - "modelAsString": true, - "values": [ - { - "name": "noSplit", - "value": "noSplit", - "description": "Treat the entire input as a single content object." - }, - { - "name": "perPage", - "value": "perPage", - "description": "Split each page of the input into a separate content object." - }, - { - "name": "auto", - "value": "auto", - "description": "Split the input into content objects based on the input and category definitions." - } - ] - }, - "x-ms-mutability": [ - "read", - "create" - ] - }, - "processingLocation": { - "type": "string", - "description": "The location where the data may be processed.", - "default": "geography", - "enum": [ - "geography", - "dataZone", - "global" - ], - "x-ms-enum": { - "name": "ProcessingLocation", - "modelAsString": true, - "values": [ - { - "name": "geography", - "value": "geography", - "description": "Data may be processed in the same geography as the resource." - }, - { - "name": "dataZone", - "value": "dataZone", - "description": "Data may be processed in the same data zone as the resource." - }, - { - "name": "global", - "value": "global", - "description": "Data may be processed in any Azure data center globally." - } - ] - }, - "x-ms-mutability": [ - "read", - "create" - ] - } - }, - "required": [ - "classifierId", - "status", - "createdAt", - "lastModifiedAt", - "categories" - ] - }, - "ContentClassifierUpdate": { - "type": "object", - "description": "Classifier that classifies content into categories with optional splitting.", - "properties": { - "description": { - "type": "string", - "description": "A description of the classifier." - }, - "tags": { - "type": "object", - "description": "Tags associated with the classifier.", - "additionalProperties": { - "type": "string" - } - } - } - }, - "ContentField": { - "type": "object", - "description": "Field extracted from the content.", - "properties": { - "type": { - "$ref": "#/definitions/ContentFieldType", - "description": "Semantic data type of the field value." - }, - "spans": { - "type": "array", - "description": "Span(s) associated with the field value in the markdown content.", - "items": { - "$ref": "#/definitions/ContentSpan" - } - }, - "confidence": { - "type": "number", - "format": "float", - "description": "Confidence of predicting the field value.", - "minimum": 0, - "maximum": 1 - }, - "source": { - "$ref": "#/definitions/SourceExpression", - "description": "Encoded source that identifies the position of the field value in the content." - } - }, - "discriminator": "type", - "required": [ - "type" - ] - }, - "ContentFieldDefinition": { - "type": "object", - "description": "Definition of the field using a JSON Schema like syntax.", - "properties": { - "method": { - "type": "string", - "description": "Generation method.", - "default": "generate", - "enum": [ - "generate", - "extract", - "classify" - ], - "x-ms-enum": { - "name": "GenerationMethod", - "modelAsString": true, - "values": [ - { - "name": "generate", - "value": "generate", - "description": "Values are generated freely based on the content." - }, - { - "name": "extract", - "value": "extract", - "description": "Values are extracted as they appear in the content." - }, - { - "name": "classify", - "value": "classify", - "description": "Values are classified against a predefined set of categories." - } - ] - } - }, - "type": { - "$ref": "#/definitions/ContentFieldType", - "description": "Semantic data type of the field value." - }, - "description": { - "type": "string", - "description": "Field description." - }, - "items": { - "$ref": "#/definitions/ContentFieldDefinition", - "description": "Field type schema of each array element, if type is array." - }, - "properties": { - "type": "object", - "description": "Named sub-fields, if type is object.", - "additionalProperties": { - "$ref": "#/definitions/ContentFieldDefinition" - } - }, - "examples": { - "type": "array", - "description": "Examples of field values.", - "items": { - "type": "string" - } - }, - "enum": { - "type": "array", - "description": "Enumeration of possible field values.", - "items": { - "type": "string" - } - }, - "enumDescriptions": { - "type": "object", - "description": "Descriptions for each enumeration value.", - "additionalProperties": { - "type": "string" - } - }, - "$ref": { - "type": "string", - "description": "Reference to another field definition." - } - } - }, - "ContentFieldSchema": { - "type": "object", - "description": "Schema of fields to be extracted from documents.", - "properties": { - "name": { - "type": "string", - "description": "The name of the field schema.", - "x-ms-mutability": [ - "read", - "create" - ] - }, - "description": { - "type": "string", - "description": "A description of the field schema.", - "x-ms-mutability": [ - "read", - "create" - ] - }, - "fields": { - "type": "object", - "description": "The fields defined in the schema.", - "additionalProperties": { - "$ref": "#/definitions/ContentFieldDefinition" - }, - "x-ms-mutability": [ - "read", - "create" - ] - }, - "definitions": { - "type": "object", - "description": "Additional definitions referenced by the fields in the schema.", - "additionalProperties": { - "$ref": "#/definitions/ContentFieldDefinition" - }, - "x-ms-mutability": [ - "read", - "create" - ] - } - }, - "required": [ - "fields" - ] - }, - "ContentFieldType": { - "type": "string", - "description": "Semantic data type of the field value.", - "enum": [ - "string", - "date", - "time", - "number", - "integer", - "boolean", - "array", - "object" - ], - "x-ms-enum": { - "name": "ContentFieldType", - "modelAsString": true, - "values": [ - { - "name": "string", - "value": "string", - "description": "Plain text." - }, - { - "name": "date", - "value": "date", - "description": "Date, normalized to ISO 8601 (YYYY-MM-DD) format." - }, - { - "name": "time", - "value": "time", - "description": "Time, normalized to ISO 8601 (hh:mm:ss) format." - }, - { - "name": "number", - "value": "number", - "description": "Number as double precision floating point." - }, - { - "name": "integer", - "value": "integer", - "description": "Integer as 64-bit signed integer." - }, - { - "name": "boolean", - "value": "boolean", - "description": "Boolean value." - }, - { - "name": "array", - "value": "array", - "description": "List of subfields of the same type." - }, - { - "name": "object", - "value": "object", - "description": "Named list of subfields." - } - ] - } - }, - "ContentSpan": { - "type": "object", - "description": "Position of the element in markdown, specified as a character offset and length.", - "properties": { - "offset": { - "type": "integer", - "format": "int32", - "description": "Starting position (0-indexed) of the element in markdown, specified in characters." - }, - "length": { - "type": "integer", - "format": "int32", - "description": "Length of the element in markdown, specified in characters." - } - }, - "required": [ - "offset", - "length" - ] - }, - "DataSource": { - "type": "object", - "description": "Data source specifying a set of documents.", - "properties": { - "kind": { - "$ref": "#/definitions/DataSourceKind", - "description": "The kind of data source." - } - }, - "discriminator": "kind", - "required": [ - "kind" - ] - }, - "DataSourceKind": { - "type": "string", - "description": "Data source kind.", - "enum": [ - "blob" - ], - "x-ms-enum": { - "name": "DataSourceKind", - "modelAsString": true, - "values": [ - { - "name": "blob", - "value": "blob", - "description": "A blob storage data source." - } - ] - } - }, - "DateField": { - "type": "object", - "description": "Date field extracted from the content.", - "properties": { - "valueDate": { - "type": "string", - "format": "date", - "description": "Date field value, in ISO 8601 (YYYY-MM-DD) format." - } - }, - "allOf": [ - { - "$ref": "#/definitions/ContentField" - } - ], - "x-ms-discriminator-value": "date" - }, - "DetectFacesParameters": { - "type": "object", - "description": "Detect faces parameters.", - "properties": { - "url": { - "type": "string", - "description": "Image URL. Only one of url or data should be specified." - }, - "data": { - "type": "string", - "format": "byte", - "description": "Base64-encoded image data. Only one of url or data should be specified." - }, - "maxDetectedFaces": { - "type": "integer", - "format": "int32", - "description": "Maximum number of faces to return (up to 100).", - "default": 100 - } - } - }, - "DetectFacesResult": { - "type": "object", - "description": "Detect faces response.", - "properties": { - "detectedFaces": { - "type": "array", - "description": "List of detected faces.", - "items": { - "$ref": "#/definitions/DetectedBoundingBox" - } - } - }, - "required": [ - "detectedFaces" - ] - }, - "DetectedBoundingBox": { - "type": "object", - "description": "Detected bounding box of an object.", - "properties": { - "boundingBox": { - "$ref": "#/definitions/BoundingBox", - "description": "Bounding box of the detected face." - } - } - }, - "DetectedPerson": { - "type": "object", - "description": "Detected person.", - "properties": { - "personId": { - "type": "string", - "description": "Person identifier in the optional person directory if found. Otherwise, each unknown person is assigned a unique `Person-{Number}`." - }, - "confidence": { - "type": "number", - "format": "float", - "description": "Confidence of the person identification, if a person directory is provided." - }, - "source": { - "$ref": "#/definitions/SourceExpression", - "description": "Encoded source that identifies the position of the person in the input content." - } - } - }, - "DocumentBarcode": { - "type": "object", - "description": "Barcode in a document.", - "properties": { - "kind": { - "$ref": "#/definitions/DocumentBarcodeKind", - "description": "Barcode kind." - }, - "value": { - "type": "string", - "description": "Barcode value." - }, - "source": { - "$ref": "#/definitions/SourceExpression", - "description": "Encoded source that identifies the position of the barcode in the content." - }, - "span": { - "$ref": "#/definitions/ContentSpan", - "description": "Span of the barcode in the markdown content." - }, - "confidence": { - "type": "number", - "format": "float", - "description": "Confidence of predicting the barcode.", - "minimum": 0, - "maximum": 1 - } - }, - "required": [ - "kind", - "value" - ] - }, - "DocumentBarcodeKind": { - "type": "string", - "description": "Barcode kind.", - "enum": [ - "QRCode", - "PDF417", - "UPCA", - "UPCE", - "Code39", - "Code128", - "EAN8", - "EAN13", - "DataBar", - "Code93", - "Codabar", - "DataBarExpanded", - "ITF", - "MicroQRCode", - "Aztec", - "DataMatrix", - "MaxiCode" - ], - "x-ms-enum": { - "name": "DocumentBarcodeKind", - "modelAsString": true, - "values": [ - { - "name": "QRCode", - "value": "QRCode", - "description": "QR code, as defined in ISO/IEC 18004:2015." - }, - { - "name": "PDF417", - "value": "PDF417", - "description": "PDF417, as defined in ISO 15438." - }, - { - "name": "UPCA", - "value": "UPCA", - "description": "GS1 12-digit Universal Product Code." - }, - { - "name": "UPCE", - "value": "UPCE", - "description": "GS1 6-digit Universal Product Code." - }, - { - "name": "Code39", - "value": "Code39", - "description": "Code 39 barcode, as defined in ISO/IEC 16388:2007." - }, - { - "name": "Code128", - "value": "Code128", - "description": "Code 128 barcode, as defined in ISO/IEC 15417:2007." - }, - { - "name": "EAN8", - "value": "EAN8", - "description": "GS1 8-digit International Article Number (European Article Number)." - }, - { - "name": "EAN13", - "value": "EAN13", - "description": "GS1 13-digit International Article Number (European Article Number)." - }, - { - "name": "DataBar", - "value": "DataBar", - "description": "GS1 DataBar barcode." - }, - { - "name": "Code93", - "value": "Code93", - "description": "Code 93 barcode, as defined in ANSI/AIM BC5-1995." - }, - { - "name": "Codabar", - "value": "Codabar", - "description": "Codabar barcode, as defined in ANSI/AIM BC3-1995." - }, - { - "name": "DataBarExpanded", - "value": "DataBarExpanded", - "description": "GS1 DataBar Expanded barcode." - }, - { - "name": "ITF", - "value": "ITF", - "description": "Interleaved 2 of 5 barcode, as defined in ANSI/AIM BC2-1995." - }, - { - "name": "MicroQRCode", - "value": "MicroQRCode", - "description": "Micro QR code, as defined in ISO/IEC 23941:2022." - }, - { - "name": "Aztec", - "value": "Aztec", - "description": "Aztec code, as defined in ISO/IEC 24778:2008." - }, - { - "name": "DataMatrix", - "value": "DataMatrix", - "description": "Data matrix code, as defined in ISO/IEC 16022:2006." - }, - { - "name": "MaxiCode", - "value": "MaxiCode", - "description": "MaxiCode, as defined in ISO/IEC 16023:2000." - } - ] - } - }, - "DocumentCaption": { - "type": "object", - "description": "Caption of a table or figure.", - "properties": { - "content": { - "type": "string", - "description": "Content of the caption." - }, - "source": { - "$ref": "#/definitions/SourceExpression", - "description": "Encoded source that identifies the position of the caption in the content." - }, - "span": { - "$ref": "#/definitions/ContentSpan", - "description": "Span of the caption in the markdown content." - }, - "elements": { - "type": "array", - "description": "Child elements of the caption.", - "items": { - "$ref": "#/definitions/DocumentElement" - } - } - }, - "required": [ - "content" - ] - }, - "DocumentContent": { - "type": "object", - "description": "Document content. Ex. text/plain, application/pdf, image/jpeg.", - "properties": { - "startPageNumber": { - "type": "integer", - "format": "int32", - "description": "Start page number (1-indexed) of the content." - }, - "endPageNumber": { - "type": "integer", - "format": "int32", - "description": "End page number (1-indexed) of the content." - }, - "unit": { - "$ref": "#/definitions/LengthUnit", - "description": "Length unit used by the width, height, and source properties.\nFor images/tiff, the default unit is pixel. For PDF, the default unit is inch." - }, - "pages": { - "type": "array", - "description": "List of pages in the document.", - "items": { - "$ref": "#/definitions/DocumentPage" - } - }, - "paragraphs": { - "type": "array", - "description": "List of paragraphs in the document. Only if enableOcr and returnDetails are true.", - "items": { - "$ref": "#/definitions/DocumentParagraph" - } - }, - "sections": { - "type": "array", - "description": "List of sections in the document. Only if enableLayout and returnDetails are true.", - "items": { - "$ref": "#/definitions/DocumentSection" - } - }, - "tables": { - "type": "array", - "description": "List of tables in the document. Only if enableLayout and returnDetails are true.", - "items": { - "$ref": "#/definitions/DocumentTable" - } - }, - "figures": { - "type": "array", - "description": "List of figures in the document. Only if enableLayout and returnDetails are true.", - "items": { - "$ref": "#/definitions/DocumentFigure" - } - }, - "persons": { - "type": "array", - "description": "List of detected persons in the document. Only if enableFace and returnDetails are true.", - "items": { - "$ref": "#/definitions/DetectedPerson" - } - } - }, - "required": [ - "startPageNumber", - "endPageNumber" - ], - "allOf": [ - { - "$ref": "#/definitions/MediaContent" - } - ], - "x-ms-discriminator-value": "document" - }, - "DocumentElement": { - "type": "string", - "description": "JSON pointer referencing an element of the document, such as paragraph,\ntable, section, etc." - }, - "DocumentFigure": { - "type": "object", - "description": "Figure in a document.", - "properties": { - "id": { - "type": "string", - "description": "Figure identifier." - }, - "source": { - "$ref": "#/definitions/SourceExpression", - "description": "Encoded source that identifies the position of the figure in the content." - }, - "span": { - "$ref": "#/definitions/ContentSpan", - "description": "Span of the figure in the markdown content." - }, - "elements": { - "type": "array", - "description": "Child elements of the figure, excluding any caption or footnotes.", - "items": { - "$ref": "#/definitions/DocumentElement" - } - }, - "caption": { - "$ref": "#/definitions/DocumentCaption", - "description": "Figure caption." - }, - "footnotes": { - "type": "array", - "description": "List of figure footnotes.", - "items": { - "$ref": "#/definitions/DocumentFootnote" - } - } - }, - "required": [ - "id" - ] - }, - "DocumentFootnote": { - "type": "object", - "description": "Footnote of a table or figure.", - "properties": { - "content": { - "type": "string", - "description": "Content of the footnote." - }, - "source": { - "$ref": "#/definitions/SourceExpression", - "description": "Encoded source that identifies the position of the footnote in the content." - }, - "span": { - "$ref": "#/definitions/ContentSpan", - "description": "Span of the footnote in the markdown content." - }, - "elements": { - "type": "array", - "description": "Child elements of the footnote.", - "items": { - "$ref": "#/definitions/DocumentElement" - } - } - }, - "required": [ - "content" - ] - }, - "DocumentFormula": { - "type": "object", - "description": "Mathematical formula in a document.", - "properties": { - "kind": { - "$ref": "#/definitions/DocumentFormulaKind", - "description": "Formula kind." - }, - "value": { - "type": "string", - "description": "LaTex expression describing the formula." - }, - "source": { - "$ref": "#/definitions/SourceExpression", - "description": "Encoded source that identifies the position of the formula in the content." - }, - "span": { - "$ref": "#/definitions/ContentSpan", - "description": "Span of the formula in the markdown content." - }, - "confidence": { - "type": "number", - "format": "float", - "description": "Confidence of predicting the formula.", - "minimum": 0, - "maximum": 1 - } - }, - "required": [ - "kind", - "value" - ] - }, - "DocumentFormulaKind": { - "type": "string", - "description": "Formula kind.", - "enum": [ - "inline", - "display" - ], - "x-ms-enum": { - "name": "DocumentFormulaKind", - "modelAsString": true, - "values": [ - { - "name": "inline", - "value": "inline", - "description": "A formula embedded within the content of a paragraph." - }, - { - "name": "display", - "value": "display", - "description": "A formula in display mode that takes up an entire line." - } - ] - } - }, - "DocumentLine": { - "type": "object", - "description": "Line in a document, consisting of an contiguous sequence of words.", - "properties": { - "content": { - "type": "string", - "description": "Line text." - }, - "source": { - "$ref": "#/definitions/SourceExpression", - "description": "Encoded source that identifies the position of the line in the content." - }, - "span": { - "$ref": "#/definitions/ContentSpan", - "description": "Span of the line in the markdown content." - } - }, - "required": [ - "content" - ] - }, - "DocumentPage": { - "type": "object", - "description": "Content from a document page.", - "properties": { - "pageNumber": { - "type": "integer", - "format": "int32", - "description": "Page number (1-based).", - "minimum": 1 - }, - "width": { - "type": "number", - "format": "float", - "description": "Width of the page." - }, - "height": { - "type": "number", - "format": "float", - "description": "Height of the page." - }, - "spans": { - "type": "array", - "description": "Span(s) associated with the page in the markdown content.", - "items": { - "$ref": "#/definitions/ContentSpan" - } - }, - "angle": { - "type": "number", - "format": "float", - "description": "The general orientation of the content in clockwise direction,\nmeasured in degrees between (-180, 180].\nOnly if enableOcr is true.", - "maximum": 180 - }, - "words": { - "type": "array", - "description": "List of words in the page. Only if enableOcr and returnDetails are true.", - "items": { - "$ref": "#/definitions/DocumentWord" - } - }, - "lines": { - "type": "array", - "description": "List of lines in the page. Only if enableOcr and returnDetails are true.", - "items": { - "$ref": "#/definitions/DocumentLine" - } - }, - "barcodes": { - "type": "array", - "description": "List of barcodes in the page. Only if enableBarcode and returnDetails are true.", - "items": { - "$ref": "#/definitions/DocumentBarcode" - } - }, - "formulas": { - "type": "array", - "description": "List of mathematical formulas in the page. Only if enableFormula and returnDetails are true.", - "items": { - "$ref": "#/definitions/DocumentFormula" - } - } - }, - "required": [ - "pageNumber" - ] - }, - "DocumentParagraph": { - "type": "object", - "description": "Paragraph in a document, generally consisting of an contiguous sequence of lines\nwith common alignment and spacing.", - "properties": { - "role": { - "$ref": "#/definitions/ParagraphRole", - "description": "Semantic role of the paragraph." - }, - "content": { - "type": "string", - "description": "Paragraph text." - }, - "source": { - "$ref": "#/definitions/SourceExpression", - "description": "Encoded source that identifies the position of the paragraph in the content." - }, - "span": { - "$ref": "#/definitions/ContentSpan", - "description": "Span of the paragraph in the markdown content." - } - }, - "required": [ - "content" - ] - }, - "DocumentSection": { - "type": "object", - "description": "Section in a document.", - "properties": { - "span": { - "$ref": "#/definitions/ContentSpan", - "description": "Span of the section in the markdown content." - }, - "elements": { - "type": "array", - "description": "Child elements of the section.", - "items": { - "$ref": "#/definitions/DocumentElement" - } - } - } - }, - "DocumentTable": { - "type": "object", - "description": "Table in a document, consisting table cells arranged in a rectangular layout.", - "properties": { - "rowCount": { - "type": "integer", - "format": "int32", - "description": "Number of rows in the table.", - "minimum": 1 - }, - "columnCount": { - "type": "integer", - "format": "int32", - "description": "Number of columns in the table.", - "minimum": 1 - }, - "cells": { - "type": "array", - "description": "Cells contained within the table.", - "items": { - "$ref": "#/definitions/DocumentTableCell" - } - }, - "source": { - "$ref": "#/definitions/SourceExpression", - "description": "Encoded source that identifies the position of the table in the content." - }, - "span": { - "$ref": "#/definitions/ContentSpan", - "description": "Span of the table in the markdown content." - }, - "caption": { - "$ref": "#/definitions/DocumentCaption", - "description": "Table caption." - }, - "footnotes": { - "type": "array", - "description": "List of table footnotes.", - "items": { - "$ref": "#/definitions/DocumentFootnote" - } - } - }, - "required": [ - "rowCount", - "columnCount", - "cells" - ] - }, - "DocumentTableCell": { - "type": "object", - "description": "Table cell in a document table.", - "properties": { - "kind": { - "type": "string", - "description": "Table cell kind.", - "default": "content", - "enum": [ - "content", - "rowHeader", - "columnHeader", - "stubHead", - "description" - ], - "x-ms-enum": { - "name": "DocumentTableCellKind", - "modelAsString": true, - "values": [ - { - "name": "content", - "value": "content", - "description": "Main content/data." - }, - { - "name": "rowHeader", - "value": "rowHeader", - "description": "Description of the row content." - }, - { - "name": "columnHeader", - "value": "columnHeader", - "description": "Description the column content." - }, - { - "name": "stubHead", - "value": "stubHead", - "description": "Description of the row headers, usually located at the top left corner of a table." - }, - { - "name": "description", - "value": "description", - "description": "Description of the content in (parts of) the table." - } - ] - } - }, - "rowIndex": { - "type": "integer", - "format": "int32", - "description": "Row index of the cell." - }, - "columnIndex": { - "type": "integer", - "format": "int32", - "description": "Column index of the cell." - }, - "rowSpan": { - "type": "integer", - "format": "int32", - "description": "Number of rows spanned by this cell.", - "default": 1, - "minimum": 1 - }, - "columnSpan": { - "type": "integer", - "format": "int32", - "description": "Number of columns spanned by this cell.", - "default": 1, - "minimum": 1 - }, - "content": { - "type": "string", - "description": "Content of the table cell." - }, - "source": { - "$ref": "#/definitions/SourceExpression", - "description": "Encoded source that identifies the position of the table cell in the content." - }, - "span": { - "$ref": "#/definitions/ContentSpan", - "description": "Span of the table cell in the markdown content." - }, - "elements": { - "type": "array", - "description": "Child elements of the table cell.", - "items": { - "$ref": "#/definitions/DocumentElement" - } - } - }, - "required": [ - "rowIndex", - "columnIndex", - "content" - ] - }, - "DocumentWord": { - "type": "object", - "description": "Word in a document, consisting of a contiguous sequence of characters.\nFor non-space delimited languages, such as Chinese, Japanese, and Korean, \neach character is represented as its own word.", - "properties": { - "content": { - "type": "string", - "description": "Word text." - }, - "source": { - "$ref": "#/definitions/SourceExpression", - "description": "Encoded source that identifies the position of the word in the content." - }, - "span": { - "$ref": "#/definitions/ContentSpan", - "description": "Span of the word in the markdown content." - }, - "confidence": { - "type": "number", - "format": "float", - "description": "Confidence of predicting the word.", - "minimum": 0, - "maximum": 1 - } - }, - "required": [ - "content" - ] - }, - "FaceSource": { - "type": "object", - "description": "Input face source with an optional target bounding box. If not specified, the largest face will be used.", - "properties": { - "url": { - "type": "string", - "format": "uri", - "description": "Image URL. Only one of url or data should be specified." - }, - "data": { - "type": "string", - "format": "byte", - "description": "Base64-encoded image data. Only one of url or data should be specified." - }, - "imageReferenceId": { - "type": "string", - "description": "User provided identifier for the source image." - }, - "targetBoundingBox": { - "$ref": "#/definitions/BoundingBox", - "description": "Bounding box specifying the region of interest." - } - } - }, - "FindSimilarFacesParameters": { - "type": "object", - "description": "Find similar faces parameters.", - "properties": { - "faceSource": { - "$ref": "#/definitions/FaceSource", - "description": "Source of the face." - }, - "maxSimilarFaces": { - "type": "integer", - "format": "int32", - "description": "Maximum number of similar faces to return (up to 1000).", - "default": 1000 - } - } - }, - "FindSimilarFacesResult": { - "type": "object", - "description": "Find similar faces response.", - "properties": { - "detectedFace": { - "$ref": "#/definitions/DetectedBoundingBox", - "description": "Details of the detected face." - }, - "similarFaces": { - "type": "array", - "description": "List of similar faces.", - "items": { - "$ref": "#/definitions/SimilarFace" - } - } - }, - "required": [ - "detectedFace", - "similarFaces" - ] - }, - "IdentifyPersonParameters": { - "type": "object", - "description": "Identify person parameters.", - "properties": { - "faceSource": { - "$ref": "#/definitions/FaceSource", - "description": "Source of the face." - }, - "maxPersonCandidates": { - "type": "integer", - "format": "int32", - "description": "Maximum number of person candidates to return (up to 10).", - "default": 1 - } - }, - "required": [ - "faceSource" - ] - }, - "IdentifyPersonResult": { - "type": "object", - "description": "Identify person response.", - "properties": { - "detectedFace": { - "$ref": "#/definitions/DetectedBoundingBox", - "description": "Details of the detected face." - }, - "personCandidates": { - "type": "array", - "description": "List of person candidates matching the input face.", - "items": { - "$ref": "#/definitions/PersonCandidate" - } - } - }, - "required": [ - "detectedFace", - "personCandidates" - ] - }, - "IntegerField": { - "type": "object", - "description": "Integer field extracted from the content.", - "properties": { - "valueInteger": { - "type": "integer", - "format": "int64", - "description": "Integer field value." - } - }, - "allOf": [ - { - "$ref": "#/definitions/ContentField" - } - ], - "x-ms-discriminator-value": "integer" - }, - "KnowledgeSource": { - "type": "object", - "description": "Knowledge source.", - "properties": { - "kind": { - "$ref": "#/definitions/KnowledgeSourceKind", - "description": "The kind of knowledge source." - } - }, - "discriminator": "kind", - "required": [ - "kind" - ] - }, - "KnowledgeSourceKind": { - "type": "string", - "description": "Knowledge source kind.", - "enum": [ - "reference" - ], - "x-ms-enum": { - "name": "KnowledgeSourceKind", - "modelAsString": true, - "values": [ - { - "name": "reference", - "value": "reference", - "description": "A reference knowledge source." - } - ] - } - }, - "LengthUnit": { - "type": "string", - "description": "Length unit used by the width, height, and source properties.", - "enum": [ - "pixel", - "inch" - ], - "x-ms-enum": { - "name": "LengthUnit", - "modelAsString": true, - "values": [ - { - "name": "pixel", - "value": "pixel", - "description": "Pixel unit." - }, - { - "name": "inch", - "value": "inch", - "description": "Inch unit." - } - ] - } - }, - "MediaContent": { - "type": "object", - "description": "Media content base class.", - "properties": { - "kind": { - "$ref": "#/definitions/MediaContentKind", - "description": "Content kind." - }, - "mimeType": { - "type": "string", - "description": "Detected MIME type of the content. Ex. application/pdf, image/jpeg, etc." - }, - "category": { - "type": "string", - "description": "Classified content category." - }, - "path": { - "type": "string", - "format": "uri", - "description": "The path of the content in the input." - }, - "markdown": { - "type": "string", - "description": "Markdown representation of the content." - }, - "fields": { - "type": "object", - "description": "Extracted fields from the content.", - "additionalProperties": { - "$ref": "#/definitions/ContentField" - } - } - }, - "discriminator": "kind", - "required": [ - "kind" - ] - }, - "MediaContentKind": { - "type": "string", - "description": "Kind of media content.", - "enum": [ - "document", - "audioVisual" - ], - "x-ms-enum": { - "name": "MediaContentKind", - "modelAsString": true, - "values": [ - { - "name": "document", - "value": "document", - "description": "Document content, such as pdf, image, txt, etc." - }, - { - "name": "audioVisual", - "value": "audioVisual", - "description": "Audio visual content, such as mp3, mp4, etc." - } - ] - } - }, - "NumberField": { - "type": "object", - "description": "Number field extracted from the content.", - "properties": { - "valueNumber": { - "type": "number", - "format": "double", - "description": "Number field value." - } - }, - "allOf": [ - { - "$ref": "#/definitions/ContentField" - } - ], - "x-ms-discriminator-value": "number" - }, - "ObjectField": { - "type": "object", - "description": "Object field extracted from the content.", - "properties": { - "valueObject": { - "type": "object", - "description": "Object field value.", - "additionalProperties": { - "$ref": "#/definitions/ContentField" - } - } - }, - "allOf": [ - { - "$ref": "#/definitions/ContentField" - } - ], - "x-ms-discriminator-value": "object" - }, - "PagedContentAnalyzer": { - "type": "object", - "description": "Paged collection of ContentAnalyzer items", - "properties": { - "value": { - "type": "array", - "description": "The ContentAnalyzer items on this page", - "items": { - "$ref": "#/definitions/ContentAnalyzer" - } - }, - "nextLink": { - "type": "string", - "format": "uri", - "description": "The link to the next page of items" - } - }, - "required": [ - "value" - ] - }, - "PagedContentClassifier": { - "type": "object", - "description": "Paged collection of ContentClassifier items", - "properties": { - "value": { - "type": "array", - "description": "The ContentClassifier items on this page", - "items": { - "$ref": "#/definitions/ContentClassifier" - } - }, - "nextLink": { - "type": "string", - "format": "uri", - "description": "The link to the next page of items" - } - }, - "required": [ - "value" - ] - }, - "PagedPersonDirectory": { - "type": "object", - "description": "Paged collection of PersonDirectory items", - "properties": { - "value": { - "type": "array", - "description": "The PersonDirectory items on this page", - "items": { - "$ref": "#/definitions/PersonDirectory" - } - }, - "nextLink": { - "type": "string", - "format": "uri", - "description": "The link to the next page of items" - } - }, - "required": [ - "value" - ] - }, - "PagedPersonDirectoryFace": { - "type": "object", - "description": "Paged collection of PersonDirectoryFace items", - "properties": { - "value": { - "type": "array", - "description": "The PersonDirectoryFace items on this page", - "items": { - "$ref": "#/definitions/PersonDirectoryFace" - } - }, - "nextLink": { - "type": "string", - "format": "uri", - "description": "The link to the next page of items" - } - }, - "required": [ - "value" - ] - }, - "PagedPersonDirectoryPerson": { - "type": "object", - "description": "Paged collection of PersonDirectoryPerson items", - "properties": { - "value": { - "type": "array", - "description": "The PersonDirectoryPerson items on this page", - "items": { - "$ref": "#/definitions/PersonDirectoryPerson" - } - }, - "nextLink": { - "type": "string", - "format": "uri", - "description": "The link to the next page of items" - } - }, - "required": [ - "value" - ] - }, - "ParagraphRole": { - "type": "string", - "description": "Semantic role of the paragraph.", - "enum": [ - "pageHeader", - "pageFooter", - "pageNumber", - "title", - "sectionHeading", - "footnote", - "formulaBlock" - ], - "x-ms-enum": { - "name": "ParagraphRole", - "modelAsString": true, - "values": [ - { - "name": "pageHeader", - "value": "pageHeader", - "description": "Text near the top edge of the page." - }, - { - "name": "pageFooter", - "value": "pageFooter", - "description": "Text near the bottom edge of the page." - }, - { - "name": "pageNumber", - "value": "pageNumber", - "description": "Page number." - }, - { - "name": "title", - "value": "title", - "description": "Top-level title describing the entire document." - }, - { - "name": "sectionHeading", - "value": "sectionHeading", - "description": "Sub heading describing a section of the document." - }, - { - "name": "footnote", - "value": "footnote", - "description": "Note usually placed after the main content on a page." - }, - { - "name": "formulaBlock", - "value": "formulaBlock", - "description": "Block of formulas, often with shared alignment." - } - ] - } - }, - "PersonCandidate": { - "type": "object", - "description": "Identified person candidate.", - "properties": { - "personId": { - "type": "string", - "description": "The unique identifier of the person.", - "pattern": "^[a-zA-Z0-9._-]{1,64}$" - }, - "tags": { - "type": "object", - "description": "Tags associated with the person.", - "additionalProperties": { - "type": "string" - } - }, - "confidence": { - "type": "number", - "format": "float", - "description": "Confidence score of the person matching the input face." - } - }, - "required": [ - "personId", - "confidence" - ] - }, - "PersonDirectory": { - "type": "object", - "description": "Directory of people and their faces.", - "properties": { - "personDirectoryId": { - "type": "string", - "description": "The unique identifier of the person directory.", - "pattern": "^[a-zA-Z0-9._-]{1,64}$", - "readOnly": true - }, - "description": { - "type": "string", - "description": "A description of the person directory." - }, - "tags": { - "type": "object", - "description": "Tags associated with the person directory.", - "additionalProperties": { - "type": "string" - } - }, - "createdAt": { - "type": "string", - "format": "date-time", - "description": "The date and time when the person directory was created.", - "readOnly": true - }, - "lastModifiedAt": { - "type": "string", - "format": "date-time", - "description": "The date and time when the person directory was last modified.", - "readOnly": true - }, - "personCount": { - "type": "integer", - "format": "int32", - "description": "Number of people in the person directory.", - "readOnly": true - }, - "faceCount": { - "type": "integer", - "format": "int32", - "description": "Number of faces in the person directory.", - "readOnly": true - } - }, - "required": [ - "personDirectoryId", - "createdAt", - "lastModifiedAt", - "personCount", - "faceCount" - ] - }, - "PersonDirectoryFace": { - "type": "object", - "description": "Face in a person directory.", - "properties": { - "faceId": { - "type": "string", - "description": "The unique identifier of the face.", - "pattern": "^[a-zA-Z0-9._-]{1,64}$", - "readOnly": true - }, - "personId": { - "type": "string", - "description": "Person associated with the face, if any." - }, - "imageReferenceId": { - "type": "string", - "description": "User provided identifier for the source image.", - "readOnly": true - }, - "boundingBox": { - "$ref": "#/definitions/BoundingBox", - "description": "Bounding box of the face in the source image.", - "readOnly": true - } - }, - "required": [ - "faceId" - ] - }, - "PersonDirectoryFaceUpdate": { - "type": "object", - "description": "Face in a person directory.", - "properties": { - "personId": { - "type": "string", - "description": "Person associated with the face, if any." - } - } - }, - "PersonDirectoryPerson": { - "type": "object", - "description": "Person in a person directory.", - "properties": { - "personId": { - "type": "string", - "description": "The unique identifier of the person.", - "pattern": "^[a-zA-Z0-9._-]{1,64}$", - "readOnly": true - }, - "tags": { - "type": "object", - "description": "Tags associated with the person.", - "additionalProperties": { - "type": "string" - } - }, - "faceIds": { - "type": "array", - "description": "List of faces associated with the person.", - "items": { - "type": "string" - } - } - }, - "required": [ - "personId" - ] - }, - "PersonDirectoryPersonUpdate": { - "type": "object", - "description": "Person in a person directory.", - "properties": { - "tags": { - "type": "object", - "description": "Tags associated with the person.", - "additionalProperties": { - "type": "string" - } - }, - "faceIds": { - "type": "array", - "description": "List of faces associated with the person.", - "items": { - "type": "string" - } - } - } - }, - "PersonDirectoryUpdate": { - "type": "object", - "description": "Directory of people and their faces.", - "properties": { - "description": { - "type": "string", - "description": "A description of the person directory." - }, - "tags": { - "type": "object", - "description": "Tags associated with the person directory.", - "additionalProperties": { - "type": "string" - } - } - } - }, - "ReferenceKnowledgeSource": { - "type": "object", - "description": "File knowledge source.", - "properties": { - "containerUrl": { - "type": "string", - "format": "uri", - "description": "The URL of the blob container." - }, - "prefix": { - "type": "string", - "description": "An optional prefix to filter blobs within the container." - }, - "fileListPath": { - "type": "string", - "description": "Path to a file listing specific blobs to include." - } - }, - "required": [ - "containerUrl", - "fileListPath" - ], - "allOf": [ - { - "$ref": "#/definitions/KnowledgeSource" - } - ], - "x-ms-discriminator-value": "reference" - }, - "ResourceStatus": { - "type": "string", - "description": "Status of a resource.", - "enum": [ - "creating", - "ready", - "deleting", - "failed" - ], - "x-ms-enum": { - "name": "ResourceStatus", - "modelAsString": true, - "values": [ - { - "name": "creating", - "value": "creating", - "description": "The resource is being created." - }, - { - "name": "ready", - "value": "ready", - "description": "The resource is ready." - }, - { - "name": "deleting", - "value": "deleting", - "description": "The resource is being deleted." - }, - { - "name": "failed", - "value": "failed", - "description": "The resource failed during creation." - } - ] - } - }, - "SimilarFace": { - "type": "object", - "description": "Similar face found in the person directory.", - "properties": { - "faceId": { - "type": "string", - "description": "The unique identifier of the face.", - "pattern": "^[a-zA-Z0-9._-]{1,64}$", - "readOnly": true - }, - "personId": { - "type": "string", - "description": "Person associated with the face, if any." - }, - "imageReferenceId": { - "type": "string", - "description": "User provided identifier for the source image.", - "readOnly": true - }, - "boundingBox": { - "$ref": "#/definitions/BoundingBox", - "description": "Bounding box of the face in the source image.", - "readOnly": true - }, - "confidence": { - "type": "number", - "format": "float", - "description": "Confidence that this face matches the input face." - } - }, - "required": [ - "faceId", - "confidence" - ] - }, - "SourceExpression": { - "type": "string", - "description": "Encoded string expression that describes positions in the content." - }, - "StringField": { - "type": "object", - "description": "String field extracted from the content.", - "properties": { - "valueString": { - "type": "string", - "description": "String field value." - } - }, - "allOf": [ - { - "$ref": "#/definitions/ContentField" - } - ], - "x-ms-discriminator-value": "string" - }, - "TimeField": { - "type": "object", - "description": "Time field extracted from the content.", - "properties": { - "valueTime": { - "type": "string", - "format": "time", - "description": "Time field value, in ISO 8601 (hh:mm:ss) format." - } - }, - "allOf": [ - { - "$ref": "#/definitions/ContentField" - } - ], - "x-ms-discriminator-value": "time" - }, - "TranscriptPhrase": { - "type": "object", - "description": "Transcript phrase.", - "properties": { - "speaker": { - "type": "string", - "description": "Speaker index or name." - }, - "startTimeMs": { - "type": "integer", - "format": "int64", - "description": "Start time of the phrase in milliseconds." - }, - "endTimeMs": { - "type": "integer", - "format": "int64", - "description": "End time of the phrase in milliseconds." - }, - "locale": { - "type": "string", - "description": "Detected locale of the phrase. Ex. en-US." - }, - "text": { - "type": "string", - "description": "Transcript text." - }, - "confidence": { - "type": "number", - "format": "float", - "description": "Confidence of predicting the phrase.", - "minimum": 0, - "maximum": 1 - }, - "span": { - "$ref": "#/definitions/ContentSpan", - "description": "Span of the phrase in the markdown content." - }, - "words": { - "type": "array", - "description": "List of words in the phrase.", - "items": { - "$ref": "#/definitions/TranscriptWord" - } - } - }, - "required": [ - "startTimeMs", - "endTimeMs", - "text", - "words" - ] - }, - "TranscriptWord": { - "type": "object", - "description": "Transcript word.", - "properties": { - "startTimeMs": { - "type": "integer", - "format": "int64", - "description": "Start time of the word in milliseconds." - }, - "endTimeMs": { - "type": "integer", - "format": "int64", - "description": "End time of the word in milliseconds." - }, - "text": { - "type": "string", - "description": "Transcript text." - }, - "span": { - "$ref": "#/definitions/ContentSpan", - "description": "Span of the word in the markdown content." - } - }, - "required": [ - "startTimeMs", - "endTimeMs", - "text" - ] - }, - "VerifyPersonParameters": { - "type": "object", - "description": "Verify person parameters.", - "properties": { - "faceSource": { - "$ref": "#/definitions/FaceSource", - "description": "Source of the face." - } - }, - "required": [ - "faceSource" - ] - }, - "VerifyPersonResult": { - "type": "object", - "description": "Verify person response.", - "properties": { - "detectedFace": { - "$ref": "#/definitions/DetectedBoundingBox", - "description": "Details of the detected face." - }, - "confidence": { - "type": "number", - "format": "float", - "description": "Confidence score of the person verification." - } - }, - "required": [ - "detectedFace", - "confidence" - ] - } - }, - "parameters": { - "AddFaceParameters.personDirectoryId": { - "name": "personDirectoryId", - "in": "path", - "description": "The unique identifier of the person directory.", - "required": true, - "type": "string", - "x-ms-parameter-location": "method" - }, - "AddPersonParameters.personDirectoryId": { - "name": "personDirectoryId", - "in": "path", - "description": "The unique identifier of the person directory.", - "required": true, - "type": "string", - "x-ms-parameter-location": "method" - }, - "AnalyzeBinaryRequest.input": { - "name": "input", - "in": "body", - "description": "The binary content of the document to analyze.", - "required": true, - "schema": { - "type": "string", - "format": "binary" - }, - "x-ms-parameter-location": "method" - }, - "AnalyzeParameters.processingLocation": { - "name": "processingLocation", - "in": "query", - "description": "The location where the data may be processed.", - "required": false, - "type": "string", - "enum": [ - "geography", - "dataZone", - "global" - ], - "x-ms-enum": { - "name": "ProcessingLocation", - "modelAsString": true, - "values": [ - { - "name": "geography", - "value": "geography", - "description": "Data may be processed in the same geography as the resource." - }, - { - "name": "dataZone", - "value": "dataZone", - "description": "Data may be processed in the same data zone as the resource." - }, - { - "name": "global", - "value": "global", - "description": "Data may be processed in any Azure data center globally." - } - ] - }, - "x-ms-parameter-location": "method" - }, - "AnalyzeParameters.stringEncoding": { - "name": "stringEncoding", - "in": "query", - "description": "The encoding format for content spans in the response.", - "required": false, - "type": "string", - "default": "codePoint", - "enum": [ - "codePoint", - "utf16", - "utf8" - ], - "x-ms-enum": { - "name": "StringEncoding", - "modelAsString": true, - "values": [ - { - "name": "codePoint", - "value": "codePoint", - "description": "Unicode code point (UTF-32) encoding, used by languages such as Python, etc." - }, - { - "name": "utf16", - "value": "utf16", - "description": "UTF-16 encoding, used by languages such as C#, JavaScript, Java, etc." - }, - { - "name": "utf8", - "value": "utf8", - "description": "UTF-8 encoding, used by languages such as Go, Rust, Ruby, PHP, etc." - } - ] - }, - "x-ms-parameter-location": "method" - }, - "Azure.Core.ClientRequestIdHeader": { - "name": "x-ms-client-request-id", - "in": "header", - "description": "An opaque, globally-unique, client-generated string identifier for the request.", - "required": false, - "type": "string", - "format": "uuid", - "x-ms-parameter-location": "method", - "x-ms-client-name": "clientRequestId" - }, - "Azure.Core.Foundations.ApiVersionParameter": { - "name": "api-version", - "in": "query", - "description": "The API version to use for this operation.", - "required": true, - "type": "string", - "minLength": 1, - "x-ms-parameter-location": "method", - "x-ms-client-name": "apiVersion" - }, - "ClassifyBinaryRequest.input": { - "name": "input", - "in": "body", - "description": "The binary content of the document to classify.", - "required": true, - "schema": { - "type": "string", - "format": "binary" - }, - "x-ms-parameter-location": "method" - }, - "ClassifyParameters.processingLocation": { - "name": "processingLocation", - "in": "query", - "description": "The location where the data may be processed.", - "required": false, - "type": "string", - "enum": [ - "geography", - "dataZone", - "global" - ], - "x-ms-enum": { - "name": "ProcessingLocation", - "modelAsString": true, - "values": [ - { - "name": "geography", - "value": "geography", - "description": "Data may be processed in the same geography as the resource." - }, - { - "name": "dataZone", - "value": "dataZone", - "description": "Data may be processed in the same data zone as the resource." - }, - { - "name": "global", - "value": "global", - "description": "Data may be processed in any Azure data center globally." - } - ] - }, - "x-ms-parameter-location": "method" - }, - "ClassifyParameters.stringEncoding": { - "name": "stringEncoding", - "in": "query", - "description": "The encoding format for content spans in the response.", - "required": false, - "type": "string", - "default": "codePoint", - "enum": [ - "codePoint", - "utf16", - "utf8" - ], - "x-ms-enum": { - "name": "StringEncoding", - "modelAsString": true, - "values": [ - { - "name": "codePoint", - "value": "codePoint", - "description": "Unicode code point (UTF-32) encoding, used by languages such as Python, etc." - }, - { - "name": "utf16", - "value": "utf16", - "description": "UTF-16 encoding, used by languages such as C#, JavaScript, Java, etc." - }, - { - "name": "utf8", - "value": "utf8", - "description": "UTF-8 encoding, used by languages such as Go, Rust, Ruby, PHP, etc." - } - ] - }, - "x-ms-parameter-location": "method" - } - } -} diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentClassifiers_Classify.json b/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentClassifiers_Classify.json deleted file mode 100644 index ea7db282c7f8..000000000000 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentClassifiers_Classify.json +++ /dev/null @@ -1,22 +0,0 @@ -{ - "title": "Classify URL", - "operationId": "ContentClassifiers_Classify", - "parameters": { - "api-version": "2025-05-01-preview", - "classifierId": "myClassifier", - "body": { - "url": "https://host.com/doc.pdf" - } - }, - "responses": { - "202": { - "headers": { - "Operation-Location": "https://myendpoint.cognitiveservices.azure.com/contentunderstanding/classifierResults/3b31320d-8bab-4f88-b19c-2322a7f11034?api-version=2025-05-01-preview" - }, - "body": { - "id": "3b31320d-8bab-4f88-b19c-2322a7f11034", - "status": "NotStarted" - } - } - } -} diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentClassifiers_ClassifyBinary.json b/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentClassifiers_ClassifyBinary.json deleted file mode 100644 index 6967fd76a144..000000000000 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentClassifiers_ClassifyBinary.json +++ /dev/null @@ -1,20 +0,0 @@ -{ - "title": "Classify File", - "operationId": "ContentClassifiers_ClassifyBinary", - "parameters": { - "api-version": "2025-05-01-preview", - "classifierId": "myClassifier", - "input": "RXhhbXBsZSBGaWxl" - }, - "responses": { - "202": { - "headers": { - "Operation-Location": "https://myendpoint.cognitiveservices.azure.com/contentunderstanding/classifierResults/3b31320d-8bab-4f88-b19c-2322a7f11034?api-version=2025-05-01-preview" - }, - "body": { - "id": "3b31320d-8bab-4f88-b19c-2322a7f11034", - "status": "NotStarted" - } - } - } -} diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentClassifiers_CreateOrReplace.json b/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentClassifiers_CreateOrReplace.json deleted file mode 100644 index caaaa3b3198c..000000000000 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentClassifiers_CreateOrReplace.json +++ /dev/null @@ -1,73 +0,0 @@ -{ - "title": "Create or Replace Classifier", - "operationId": "ContentClassifiers_CreateOrReplace", - "parameters": { - "api-version": "2025-05-01-preview", - "classifierId": "myClassifier", - "resource": { - "description": "My classifier", - "tags": { - "createdBy": "John" - }, - "splitMode": "auto", - "categories": { - "receipt": { - "description": "Sales receipts" - }, - "invoice": { - "analyzerId": "myInvoice" - } - } - } - }, - "responses": { - "200": { - "headers": { - "Operation-Location": "https://myendpoint.cognitiveservices.azure.com/contentunderstanding/classifiers/myClassifier/operations/3b31320d-8bab-4f88-b19c-2322a7f11034?api-version=2025-05-01-preview" - }, - "body": { - "classifierId": "myClassifier", - "description": "My classifier", - "tags": { - "createdBy": "John" - }, - "status": "creating", - "createdAt": "2025-05-01T18:46:36.051Z", - "lastModifiedAt": "2025-05-01T18:46:36.051Z", - "splitMode": "auto", - "categories": { - "receipt": { - "description": "Sales receipts" - }, - "invoice": { - "analyzerId": "myInvoice" - } - } - } - }, - "201": { - "headers": { - "Operation-Location": "https://myendpoint.cognitiveservices.azure.com/contentunderstanding/classifiers/myClassifier/operations/3b31320d-8bab-4f88-b19c-2322a7f11034?api-version=2025-05-01-preview" - }, - "body": { - "classifierId": "myClassifier", - "description": "My classifier", - "tags": { - "createdBy": "John" - }, - "status": "creating", - "createdAt": "2025-05-01T18:46:36.051Z", - "lastModifiedAt": "2025-05-01T18:46:36.051Z", - "splitMode": "auto", - "categories": { - "receipt": { - "description": "Sales receipts" - }, - "invoice": { - "analyzerId": "myInvoice" - } - } - } - } - } -} diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentClassifiers_DeleteClassifier.json b/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentClassifiers_DeleteClassifier.json deleted file mode 100644 index d36f2f016d65..000000000000 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentClassifiers_DeleteClassifier.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "title": "Delete Classifier", - "operationId": "ContentClassifiers_Delete", - "parameters": { - "api-version": "2025-05-01-preview", - "classifierId": "myClassifier" - }, - "responses": { - "204": {} - } -} diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentClassifiers_GetClassifier.json b/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentClassifiers_GetClassifier.json deleted file mode 100644 index 17fe49d612c5..000000000000 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentClassifiers_GetClassifier.json +++ /dev/null @@ -1,31 +0,0 @@ -{ - "title": "Get Classifier", - "operationId": "ContentClassifiers_Get", - "parameters": { - "api-version": "2025-05-01-preview", - "classifierId": "myClassifier" - }, - "responses": { - "200": { - "body": { - "classifierId": "myClassifier", - "description": "My classifier", - "tags": { - "createdBy": "John" - }, - "status": "ready", - "createdAt": "2025-05-01T18:46:36.051Z", - "lastModifiedAt": "2025-05-01T18:46:36.051Z", - "splitMode": "auto", - "categories": { - "receipt": { - "description": "Sales receipts" - }, - "invoice": { - "analyzerId": "myInvoice" - } - } - } - } - } -} diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentClassifiers_GetOperationStatus.json b/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentClassifiers_GetOperationStatus.json deleted file mode 100644 index 7f3b1ae542b7..000000000000 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentClassifiers_GetOperationStatus.json +++ /dev/null @@ -1,36 +0,0 @@ -{ - "title": "Get Classifier Operation Status", - "operationId": "ContentClassifiers_GetOperationStatus", - "parameters": { - "api-version": "2025-05-01-preview", - "classifierId": "myClassifier", - "operationId": "3b31320d-8bab-4f88-b19c-2322a7f11034" - }, - "responses": { - "200": { - "body": { - "id": "3b31320d-8bab-4f88-b19c-2322a7f11034", - "status": "Succeeded", - "result": { - "classifierId": "myClassifier", - "description": "My classifier", - "tags": { - "createdBy": "John" - }, - "status": "ready", - "createdAt": "2025-05-01T18:46:36.051Z", - "lastModifiedAt": "2025-05-01T18:46:36.051Z", - "splitMode": "auto", - "categories": { - "receipt": { - "description": "Sales receipts" - }, - "invoice": { - "analyzerId": "myInvoice" - } - } - } - } - } - } -} diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentClassifiers_GetResult.json b/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentClassifiers_GetResult.json deleted file mode 100644 index af22f373672e..000000000000 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentClassifiers_GetResult.json +++ /dev/null @@ -1,69 +0,0 @@ -{ - "title": "Get Analysis Result", - "operationId": "ContentClassifiers_GetResult", - "parameters": { - "api-version": "2025-05-01-preview", - "classifierId": "myClassifier", - "operationId": "3b31320d-8bab-4f88-b19c-2322a7f11034" - }, - "responses": { - "200": { - "body": { - "id": "3b31320d-8bab-4f88-b19c-2322a7f11034", - "status": "Succeeded", - "result": { - "classifierId": "myClassifier", - "apiVersion": "2025-05-01-preview", - "createdAt": "2025-05-01T18:46:36.244Z", - "contents": [ - { - "kind": "document", - "startPageNumber": 1, - "endPageNumber": 3, - "category": "invoice", - "markdown": "# CONTOSO\n\n...", - "pages": [ - { - "pageNumber": 1, - "width": 8.5, - "height": 11 - }, - { - "pageNumber": 2, - "width": 8.5, - "height": 11 - } - ], - "fields": { - "Company": { - "type": "string", - "valueString": "CONTOSO", - "spans": [ - { - "offset": 7, - "length": 2 - } - ], - "confidence": 0.95, - "source": "D(1,5,1,7,1,7,1.5,5,1.5)" - } - } - }, - { - "kind": "document", - "startPageNumber": 4, - "endPageNumber": 4, - "category": "receipt" - }, - { - "kind": "document", - "startPageNumber": 5, - "endPageNumber": 5, - "category": "$OTHER" - } - ] - } - } - } - } -} diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentClassifiers_List.json b/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentClassifiers_List.json deleted file mode 100644 index b54c5a02d6ad..000000000000 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentClassifiers_List.json +++ /dev/null @@ -1,52 +0,0 @@ -{ - "title": "List Classifiers", - "operationId": "ContentClassifiers_List", - "parameters": { - "api-version": "2025-05-01-preview" - }, - "responses": { - "200": { - "body": { - "value": [ - { - "classifierId": "myClassifier", - "description": "My classifier", - "tags": { - "createdBy": "John" - }, - "status": "ready", - "createdAt": "2025-05-01T18:46:36.051Z", - "lastModifiedAt": "2025-05-01T18:46:36.051Z", - "splitMode": "auto", - "categories": { - "receipt": { - "description": "Sales receipts" - }, - "invoice": { - "analyzerId": "myInvoice" - } - } - }, - { - "classifierId": "myClassifier2", - "description": "My classifier 2", - "tags": { - "createdBy": "John" - }, - "status": "creating", - "createdAt": "2025-05-01T18:46:36.051Z", - "lastModifiedAt": "2025-05-01T18:46:36.051Z", - "splitMode": "perPage", - "categories": { - "receipt": { - "description": "Sales receipts", - "analyzerId": "myReceipt" - } - } - } - ], - "nextLink": "https://myendpoint.cognitiveservices.azure.com/contentunderstanding/classifiers?nextLink=nextLinkData&api-version=2025-05-01-preview" - } - } - } -} diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentClassifiers_Update.json b/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentClassifiers_Update.json deleted file mode 100644 index ed4f055d2c9e..000000000000 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/ContentClassifiers_Update.json +++ /dev/null @@ -1,37 +0,0 @@ -{ - "title": "Update Classifier", - "operationId": "ContentClassifiers_Update", - "parameters": { - "api-version": "2025-05-01-preview", - "classifierId": "myClassifier", - "resource": { - "description": "Updated classifier description.", - "tags": { - "reviewedBy": "Paul" - } - } - }, - "responses": { - "200": { - "body": { - "classifierId": "myClassifier", - "description": "My classifier", - "tags": { - "createdBy": "Paul" - }, - "status": "ready", - "createdAt": "2025-05-01T18:46:36.051Z", - "lastModifiedAt": "2025-05-01T18:46:36.051Z", - "splitMode": "auto", - "categories": { - "receipt": { - "description": "Sales receipts" - }, - "invoice": { - "analyzerId": "myInvoice" - } - } - } - } - } -} diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/Faces_Compare.json b/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/Faces_Compare.json deleted file mode 100644 index d6c69a9952b1..000000000000 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/Faces_Compare.json +++ /dev/null @@ -1,44 +0,0 @@ -{ - "title": "Compare the Similarity Between Two Faces", - "operationId": "Faces_Compare", - "parameters": { - "api-version": "2025-05-01-preview", - "body": { - "faceSource1": { - "url": "https://mystorageaccount.blob.core.windows.net/images/faces/face1.jpg", - "targetBoundingBox": { - "left": 33, - "top": 73, - "width": 262, - "height": 324 - } - }, - "faceSource2": { - "data": "RXhhbXBsZSBGaWxl" - } - } - }, - "responses": { - "200": { - "body": { - "detectedFace1": { - "boundingBox": { - "left": 33, - "top": 73, - "width": 262, - "height": 324 - } - }, - "detectedFace2": { - "boundingBox": { - "left": 87, - "top": 96, - "width": 235, - "height": 345 - } - }, - "confidence": 0.95 - } - } - } -} diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/Faces_Detect.json b/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/Faces_Detect.json deleted file mode 100644 index 19f17daadd1d..000000000000 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/Faces_Detect.json +++ /dev/null @@ -1,35 +0,0 @@ -{ - "title": "Detect Faces in an Image", - "operationId": "Faces_Detect", - "parameters": { - "api-version": "2025-05-01-preview", - "body": { - "url": "https://mystorageaccount.blob.core.windows.net/images/container/file.jpg", - "maxDetectedFaces": 50 - } - }, - "responses": { - "200": { - "body": { - "detectedFaces": [ - { - "boundingBox": { - "left": 33, - "top": 73, - "width": 262, - "height": 324 - } - }, - { - "boundingBox": { - "left": 87, - "top": 96, - "width": 235, - "height": 345 - } - } - ] - } - } - } -} diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_AddFace.json b/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_AddFace.json deleted file mode 100644 index 0e028543e2f4..000000000000 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_AddFace.json +++ /dev/null @@ -1,37 +0,0 @@ -{ - "title": "Add Face to Person Directory", - "operationId": "PersonDirectories_AddFace", - "parameters": { - "api-version": "2025-05-01-preview", - "personDirectoryId": "myDirectory", - "body": { - "faceSource": { - "url": "https://mystorageaccount.blob.core.windows.net/images/faces/face1.jpg", - "targetBoundingBox": { - "left": 0, - "top": 0, - "width": 640, - "height": 480 - }, - "imageReferenceId": "face1.jpg" - }, - "qualityThreshold": "medium", - "personId": "4f66b612-e57d-4d17-9ef7-b951aea2cf0f" - } - }, - "responses": { - "201": { - "body": { - "faceId": "7a87f162-8dd5-4aea-8810-373e36b96b38", - "personId": "4f66b612-e57d-4d17-9ef7-b951aea2cf0f", - "boundingBox": { - "left": 33, - "top": 73, - "width": 262, - "height": 324 - }, - "imageReferenceId": "face1.jpg" - } - } - } -} diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_AddPerson.json b/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_AddPerson.json deleted file mode 100644 index 4e7332fed60d..000000000000 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_AddPerson.json +++ /dev/null @@ -1,33 +0,0 @@ -{ - "title": "Add Person to Person Directory", - "operationId": "PersonDirectories_AddPerson", - "parameters": { - "api-version": "2025-05-01-preview", - "personDirectoryId": "myDirectory", - "body": { - "tags": { - "name": "Paul", - "age": "1" - }, - "faceIds": [ - "7a87f162-8dd5-4aea-8810-373e36b96b38", - "f28b3cda-4005-44b6-8518-6fcddef108cb" - ] - } - }, - "responses": { - "201": { - "body": { - "personId": "4f66b612-e57d-4d17-9ef7-b951aea2cf0f", - "tags": { - "name": "Paul", - "age": "1" - }, - "faceIds": [ - "7a87f162-8dd5-4aea-8810-373e36b96b38", - "f28b3cda-4005-44b6-8518-6fcddef108cb" - ] - } - } - } -} diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_Create.json b/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_Create.json deleted file mode 100644 index 9bd734ac2c3a..000000000000 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_Create.json +++ /dev/null @@ -1,31 +0,0 @@ -{ - "title": "Create Person Directory", - "operationId": "PersonDirectories_Create", - "parameters": { - "api-version": "2025-05-01-preview", - "personDirectoryId": "myDirectory", - "resource": { - "description": "My person directory", - "tags": { - "location": "Building A", - "type": "Access Control" - } - } - }, - "responses": { - "201": { - "body": { - "personDirectoryId": "myDirectory", - "description": "My person directory", - "createdAt": "2025-05-01T18:46:36.051Z", - "lastModifiedAt": "2025-05-01T18:46:36.051Z", - "tags": { - "location": "Building A", - "type": "Access Control" - }, - "personCount": 0, - "faceCount": 0 - } - } - } -} diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_Delete.json b/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_Delete.json deleted file mode 100644 index cb809327a64b..000000000000 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_Delete.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "title": "Delete Person Directory", - "operationId": "PersonDirectories_Delete", - "parameters": { - "api-version": "2025-05-01-preview", - "personDirectoryId": "myDirectory" - }, - "responses": { - "204": {} - } -} diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_DeleteFace.json b/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_DeleteFace.json deleted file mode 100644 index 6eab58b7d320..000000000000 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_DeleteFace.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "title": "Delete Face from Person Directory", - "operationId": "PersonDirectories_DeleteFace", - "parameters": { - "api-version": "2025-05-01-preview", - "personDirectoryId": "myDirectory", - "faceId": "7a87f162-8dd5-4aea-8810-373e36b96b38" - }, - "responses": { - "204": {} - } -} diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_DeletePerson.json b/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_DeletePerson.json deleted file mode 100644 index 558402d6a42e..000000000000 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_DeletePerson.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "title": "Delete Person from Person Directory", - "operationId": "PersonDirectories_DeletePerson", - "parameters": { - "api-version": "2025-05-01-preview", - "personDirectoryId": "myDirectory", - "personId": "4f66b612-e57d-4d17-9ef7-b951aea2cf0f" - }, - "responses": { - "204": {} - } -} diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_FindSimilarFaces.json b/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_FindSimilarFaces.json deleted file mode 100644 index 768a0fbfdd70..000000000000 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_FindSimilarFaces.json +++ /dev/null @@ -1,52 +0,0 @@ -{ - "title": "Find Similar Faces", - "operationId": "PersonDirectories_FindSimilarFaces", - "parameters": { - "api-version": "2025-05-01-preview", - "personDirectoryId": "myDirectory", - "body": { - "faceSource": { - "url": "https://mystorageaccount.blob.core.windows.net/images/faces/face1.jpg" - }, - "maxSimilarFaces": 10 - } - }, - "responses": { - "200": { - "body": { - "detectedFace": { - "boundingBox": { - "left": 67, - "top": 13, - "width": 273, - "height": 313 - } - }, - "similarFaces": [ - { - "faceId": "7a87f162-8dd5-4aea-8810-373e36b96b38", - "boundingBox": { - "left": 33, - "top": 73, - "width": 262, - "height": 324 - }, - "imageReferenceId": "face1.jpg", - "confidence": 0.99 - }, - { - "faceId": "f28b3cda-4005-44b6-8518-6fcddef108cb", - "boundingBox": { - "left": 87, - "top": 96, - "width": 235, - "height": 345 - }, - "imageReferenceId": "face2.jpg", - "confidence": 0.98 - } - ] - } - } - } -} diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_Get.json b/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_Get.json deleted file mode 100644 index cefebd9cb488..000000000000 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_Get.json +++ /dev/null @@ -1,25 +0,0 @@ -{ - "title": "Get Person Directory", - "operationId": "PersonDirectories_Get", - "parameters": { - "api-version": "2025-05-01-preview", - "personDirectoryId": "myDirectory" - }, - "responses": { - "200": { - "body": { - "personDirectoryId": "myDirectory", - "description": "My person directory", - "createdAt": "2025-05-01T18:46:36.051Z", - "lastModifiedAt": "2025-05-01T18:46:36.051Z", - "tags": { - "location": "Building A", - "type": "Access Control", - "updatedBy": "Paul" - }, - "personCount": 0, - "faceCount": 0 - } - } - } -} diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_GetFace.json b/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_GetFace.json deleted file mode 100644 index 33663511d2aa..000000000000 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_GetFace.json +++ /dev/null @@ -1,24 +0,0 @@ -{ - "title": "Get Face in Person Directory", - "operationId": "PersonDirectories_GetFace", - "parameters": { - "api-version": "2025-05-01-preview", - "personDirectoryId": "myDirectory", - "faceId": "7a87f162-8dd5-4aea-8810-373e36b96b38" - }, - "responses": { - "200": { - "body": { - "faceId": "7a87f162-8dd5-4aea-8810-373e36b96b38", - "personId": "Paul", - "boundingBox": { - "left": 33, - "top": 73, - "width": 262, - "height": 324 - }, - "imageReferenceId": "face1.jpg" - } - } - } -} diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_GetPerson.json b/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_GetPerson.json deleted file mode 100644 index a2bbbaf63231..000000000000 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_GetPerson.json +++ /dev/null @@ -1,24 +0,0 @@ -{ - "title": "Get Person in Person Directory", - "operationId": "PersonDirectories_GetPerson", - "parameters": { - "api-version": "2025-05-01-preview", - "personDirectoryId": "myDirectory", - "personId": "4f66b612-e57d-4d17-9ef7-b951aea2cf0f" - }, - "responses": { - "200": { - "body": { - "personId": "4f66b612-e57d-4d17-9ef7-b951aea2cf0f", - "tags": { - "name": "Paul", - "age": "1" - }, - "faceIds": [ - "7a87f162-8dd5-4aea-8810-373e36b96b38", - "f28b3cda-4005-44b6-8518-6fcddef108cb" - ] - } - } - } -} diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_IdentifyPerson.json b/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_IdentifyPerson.json deleted file mode 100644 index 604a72a16dbb..000000000000 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_IdentifyPerson.json +++ /dev/null @@ -1,46 +0,0 @@ -{ - "title": "Identify the Person from a Face", - "operationId": "PersonDirectories_IdentifyPerson", - "parameters": { - "api-version": "2025-05-01-preview", - "personDirectoryId": "myDirectory", - "body": { - "faceSource": { - "url": "https://mystorageaccount.blob.core.windows.net/images/faces/face1.jpg" - }, - "maxPersonCandidates": 5 - } - }, - "responses": { - "200": { - "body": { - "detectedFace": { - "boundingBox": { - "left": 33, - "top": 73, - "width": 262, - "height": 324 - } - }, - "personCandidates": [ - { - "personId": "4f66b612-e57d-4d17-9ef7-b951aea2cf0f", - "tags": { - "name": "Paul", - "age": "1" - }, - "confidence": 0.92 - }, - { - "personId": "19323b77-2012-487b-b131-09c318dc23df", - "tags": { - "name": "John", - "age": "2" - }, - "confidence": 0.65 - } - ] - } - } - } -} diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_List.json b/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_List.json deleted file mode 100644 index 28b0911ad434..000000000000 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_List.json +++ /dev/null @@ -1,37 +0,0 @@ -{ - "title": "List Person Directories", - "operationId": "PersonDirectories_List", - "parameters": { - "api-version": "2025-05-01-preview" - }, - "responses": { - "200": { - "body": { - "value": [ - { - "personDirectoryId": "myDirectory", - "description": "My person directory", - "createdAt": "2025-05-01T18:46:36.051Z", - "lastModifiedAt": "2025-05-01T18:46:36.051Z", - "tags": { - "location": "Building A", - "type": "Access Control" - }, - "personCount": 0, - "faceCount": 0 - }, - { - "personDirectoryId": "myDirectory2", - "description": "My person directory 2", - "createdAt": "2025-05-01T18:46:36.051Z", - "lastModifiedAt": "2025-05-01T18:46:36.051Z", - "tags": {}, - "personCount": 123, - "faceCount": 223 - } - ], - "nextLink": "https://myendpoint.cognitiveservices.azure.com/contentunderstanding/personDirectories?nextLink=nextLinkData&api-version=2025-05-01-preview" - } - } - } -} diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_ListFaces.json b/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_ListFaces.json deleted file mode 100644 index 94a42cd70034..000000000000 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_ListFaces.json +++ /dev/null @@ -1,39 +0,0 @@ -{ - "title": "List Faces in Person Directory", - "operationId": "PersonDirectories_ListFaces", - "parameters": { - "api-version": "2025-05-01-preview", - "personDirectoryId": "myDirectory" - }, - "responses": { - "200": { - "body": { - "value": [ - { - "faceId": "7a87f162-8dd5-4aea-8810-373e36b96b38", - "personId": "4f66b612-e57d-4d17-9ef7-b951aea2cf0f", - "boundingBox": { - "left": 33, - "top": 73, - "width": 262, - "height": 324 - }, - "imageReferenceId": "face1.jpg" - }, - { - "faceId": "f28b3cda-4005-44b6-8518-6fcddef108cb", - "personId": "19323b77-2012-487b-b131-09c318dc23df", - "boundingBox": { - "left": 87, - "top": 96, - "width": 235, - "height": 345 - }, - "imageReferenceId": "face2.jpg" - } - ], - "nextLink": "https://myendpoint.cognitiveservices.azure.com/contentunderstanding/personDirectories/myDirectory/faces?nextLink=nextLinkData&api-version=2025-05-01-preview" - } - } - } -} diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_ListPersons.json b/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_ListPersons.json deleted file mode 100644 index cf45f8597156..000000000000 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_ListPersons.json +++ /dev/null @@ -1,36 +0,0 @@ -{ - "title": "List Persons in Person Directory", - "operationId": "PersonDirectories_ListPersons", - "parameters": { - "api-version": "2025-05-01-preview", - "personDirectoryId": "myDirectory" - }, - "responses": { - "200": { - "body": { - "value": [ - { - "personId": "4f66b612-e57d-4d17-9ef7-b951aea2cf0f", - "tags": { - "name": "Paul", - "age": "1" - }, - "faceIds": [ - "7a87f162-8dd5-4aea-8810-373e36b96b38", - "f28b3cda-4005-44b6-8518-6fcddef108cb" - ] - }, - { - "personId": "19323b77-2012-487b-b131-09c318dc23df", - "tags": { - "name": "John", - "age": "2" - }, - "faceIds": [] - } - ], - "nextLink": "https://myendpoint.cognitiveservices.azure.com/contentunderstanding/personDirectories/myDirectory/persons?nextLink=nextLinkData&api-version=2025-05-01-preview" - } - } - } -} diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_Update.json b/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_Update.json deleted file mode 100644 index 76425fcbcf92..000000000000 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_Update.json +++ /dev/null @@ -1,30 +0,0 @@ -{ - "title": "Update Person Directory", - "operationId": "PersonDirectories_Update", - "parameters": { - "api-version": "2025-05-01-preview", - "personDirectoryId": "myDirectory", - "resource": { - "tags": { - "updatedBy": "Paul" - } - } - }, - "responses": { - "200": { - "body": { - "personDirectoryId": "myDirectory", - "description": "My person directory", - "createdAt": "2025-05-01T18:46:36.051Z", - "lastModifiedAt": "2025-05-01T18:46:36.051Z", - "tags": { - "location": "Building A", - "type": "Access Control", - "updatedBy": "Paul" - }, - "personCount": 0, - "faceCount": 0 - } - } - } -} diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_UpdateFace.json b/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_UpdateFace.json deleted file mode 100644 index d7bc893b6dc4..000000000000 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_UpdateFace.json +++ /dev/null @@ -1,27 +0,0 @@ -{ - "title": "Update Face in Person Directory", - "operationId": "PersonDirectories_UpdateFace", - "parameters": { - "api-version": "2025-05-01-preview", - "personDirectoryId": "myDirectory", - "faceId": "7a87f162-8dd5-4aea-8810-373e36b96b38", - "resource": { - "personId": "19323b77-2012-487b-b131-09c318dc23df" - } - }, - "responses": { - "200": { - "body": { - "faceId": "7a87f162-8dd5-4aea-8810-373e36b96b38", - "personId": "19323b77-2012-487b-b131-09c318dc23df", - "boundingBox": { - "left": 33, - "top": 73, - "width": 262, - "height": 324 - }, - "imageReferenceId": "face1.jpg" - } - } - } -} diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_UpdatePerson.json b/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_UpdatePerson.json deleted file mode 100644 index f274f3352934..000000000000 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_UpdatePerson.json +++ /dev/null @@ -1,32 +0,0 @@ -{ - "title": "Update Person in Person Directory", - "operationId": "PersonDirectories_UpdatePerson", - "parameters": { - "api-version": "2025-05-01-preview", - "personDirectoryId": "myDirectory", - "personId": "4f66b612-e57d-4d17-9ef7-b951aea2cf0f", - "resource": { - "tags": { - "age": null - }, - "faceIds": [ - "6995a5ae-83fa-4c64-a8b7-23aefc6cf0fc" - ] - } - }, - "responses": { - "200": { - "body": { - "personId": "4f66b612-e57d-4d17-9ef7-b951aea2cf0f", - "tags": { - "name": "Paul" - }, - "faceIds": [ - "7a87f162-8dd5-4aea-8810-373e36b96b38", - "f28b3cda-4005-44b6-8518-6fcddef108cb", - "6995a5ae-83fa-4c64-a8b7-23aefc6cf0fc" - ] - } - } - } -} diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_VerifyPerson.json b/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_VerifyPerson.json deleted file mode 100644 index 0f3928610601..000000000000 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2025-05-01-preview/examples/PersonDirectories_VerifyPerson.json +++ /dev/null @@ -1,29 +0,0 @@ -{ - "title": "Verify If a Face Matches the Person", - "operationId": "PersonDirectories_VerifyPerson", - "parameters": { - "api-version": "2025-05-01-preview", - "personDirectoryId": "myDirectory", - "personId": "4f66b612-e57d-4d17-9ef7-b951aea2cf0f", - "body": { - "faceSource": { - "url": "https://mystorageaccount.blob.core.windows.net/images/faces/face1.jpg" - } - } - }, - "responses": { - "200": { - "body": { - "detectedFace": { - "boundingBox": { - "left": 67, - "top": 13, - "width": 273, - "height": 313 - } - }, - "confidence": 0.99 - } - } - } -} diff --git a/specification/ai/data-plane/ContentUnderstanding/readme.md b/specification/ai/data-plane/ContentUnderstanding/readme.md index 2a388231e77a..7b12d8af32a0 100644 --- a/specification/ai/data-plane/ContentUnderstanding/readme.md +++ b/specification/ai/data-plane/ContentUnderstanding/readme.md @@ -4,29 +4,22 @@ Configuration for generating Content Understanding SDK. -The current release is `2025-05-01-preview`. +The current release is `2025-11-01`. ``` yaml -tag: 2025-05-01-preview +tag: 2025-11-01 add-credentials: true openapi-type: data-plane ``` # Releases -### Release 2025-05-01-preview -These settings apply only when `--tag=2024-12-01-preview` is specified on the command line. -``` yaml $(tag) == '2025-05-01-preview' +### Release 2025-11-01 +These settings apply only when `--tag=2025-11-01` is specified on the command line. +``` yaml $(tag) == '2025-11-01' input-file: - - preview/2025-05-01-preview/ContentUnderstanding.json -``` - -### Release 2024-12-01-preview -These settings apply only when `--tag=2024-12-01-preview` is specified on the command line. -``` yaml $(tag) == '2024-12-01-preview' -input-file: - - preview/2024-12-01-preview/ContentUnderstanding.json + - stable/2025-11-01/ContentUnderstanding.json ``` # Code Generation diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2024-12-01-preview/ContentUnderstanding.json b/specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/ContentUnderstanding.json similarity index 61% rename from specification/ai/data-plane/ContentUnderstanding/preview/2024-12-01-preview/ContentUnderstanding.json rename to specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/ContentUnderstanding.json index d2841b35b617..8a13bd9cd397 100644 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2024-12-01-preview/ContentUnderstanding.json +++ b/specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/ContentUnderstanding.json @@ -2,7 +2,7 @@ "swagger": "2.0", "info": { "title": "Content Understanding", - "version": "2024-12-01-preview", + "version": "2025-11-01", "description": "The Content Understanding service extracts content and fields from multimodal input.", "x-typespec-generated": [ { @@ -36,22 +36,24 @@ ], "security": [ { - "ApiKeyAuth": [] + "AzureKey": [] }, { - "OAuth2Auth": [ + "EntraIdToken": [ "https://cognitiveservices.azure.com/.default" ] } ], "securityDefinitions": { - "ApiKeyAuth": { + "AzureKey": { "type": "apiKey", + "description": "Key-based authentication using the access key of the Azure resource.", "name": "Ocp-Apim-Subscription-Key", "in": "header" }, - "OAuth2Auth": { + "EntraIdToken": { "type": "oauth2", + "description": "Microsoft Entra ID OAuth2 authentication using an access token.", "flow": "accessCode", "authorizationUrl": "https://login.microsoftonline.com/common/oauth2/authorize", "scopes": { @@ -62,9 +64,145 @@ }, "tags": [], "paths": { + "/analyzerResults/{operationId}": { + "get": { + "operationId": "ContentAnalyzers_GetResult", + "description": "Get the result of an analysis operation.", + "parameters": [ + { + "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" + }, + { + "name": "operationId", + "in": "path", + "description": "The unique ID of the operation.", + "required": true, + "type": "string" + } + ], + "responses": { + "200": { + "description": "The request has succeeded.", + "schema": { + "$ref": "#/definitions/ContentAnalyzerAnalyzeOperationStatus" + } + }, + "default": { + "description": "An unexpected error response.", + "schema": { + "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" + }, + "headers": { + "x-ms-error-code": { + "type": "string", + "description": "String error code indicating what went wrong." + } + } + } + }, + "x-ms-examples": { + "Get Analysis Result": { + "$ref": "./examples/ContentAnalyzers_GetResult.json" + } + } + }, + "delete": { + "operationId": "ContentAnalyzers_DeleteResult", + "description": "Mark the result of an analysis operation for deletion.", + "parameters": [ + { + "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" + }, + { + "name": "operationId", + "in": "path", + "description": "Operation identifier.", + "required": true, + "type": "string" + } + ], + "responses": { + "204": { + "description": "There is no content to send for this request, but the headers may be useful." + }, + "default": { + "description": "An unexpected error response.", + "schema": { + "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" + }, + "headers": { + "x-ms-error-code": { + "type": "string", + "description": "String error code indicating what went wrong." + } + } + } + }, + "x-ms-examples": { + "Delete Analyzer Result": { + "$ref": "./examples/ContentAnalyzers_DeleteResult.json" + } + } + } + }, + "/analyzerResults/{operationId}/files/{path}": { + "get": { + "operationId": "ContentAnalyzers_GetResultFile", + "description": "Get a file associated with the result of an analysis operation.", + "produces": [ + "*/*", + "application/json" + ], + "parameters": [ + { + "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" + }, + { + "name": "operationId", + "in": "path", + "description": "Operation identifier.", + "required": true, + "type": "string" + }, + { + "name": "path", + "in": "path", + "description": "File path.", + "required": true, + "type": "string", + "x-ms-skip-url-encoding": true + } + ], + "responses": { + "200": { + "description": "The request has succeeded.", + "schema": { + "type": "file" + } + }, + "default": { + "description": "An unexpected error response.", + "schema": { + "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" + }, + "headers": { + "x-ms-error-code": { + "type": "string", + "description": "String error code indicating what went wrong." + } + } + } + }, + "x-ms-examples": { + "Get Analysis Result File": { + "$ref": "./examples/ContentAnalyzers_GetResultFile.json" + } + } + } + }, "/analyzers": { "get": { - "operationId": "Analyzers_List", + "operationId": "ContentAnalyzers_List", "description": "List analyzers.", "parameters": [ { @@ -103,7 +241,7 @@ }, "x-ms-examples": { "List Analyzers": { - "$ref": "./examples/Analyzers_List.json" + "$ref": "./examples/ContentAnalyzers_List.json" } }, "x-ms-pageable": { @@ -113,7 +251,7 @@ }, "/analyzers/{analyzerId}": { "get": { - "operationId": "Analyzers_Get", + "operationId": "ContentAnalyzers_Get", "description": "Get analyzer properties.", "parameters": [ { @@ -125,6 +263,8 @@ "description": "The unique identifier of the analyzer.", "required": true, "type": "string", + "minLength": 1, + "maxLength": 64, "pattern": "^[a-zA-Z0-9._-]{1,64}$" }, { @@ -160,12 +300,12 @@ }, "x-ms-examples": { "Get Analyzer": { - "$ref": "./examples/Analyzers_GetAnalyzer.json" + "$ref": "./examples/ContentAnalyzers_GetAnalyzer.json" } } }, "put": { - "operationId": "Analyzers_CreateOrReplace", + "operationId": "ContentAnalyzers_CreateOrReplace", "description": "Create a new analyzer asynchronously.", "parameters": [ { @@ -177,8 +317,18 @@ "description": "The unique identifier of the analyzer.", "required": true, "type": "string", + "minLength": 1, + "maxLength": 64, "pattern": "^[a-zA-Z0-9._-]{1,64}$" }, + { + "name": "allowReplace", + "in": "query", + "description": "Allow the operation to replace an existing resource.", + "required": false, + "type": "boolean", + "default": false + }, { "$ref": "#/parameters/Azure.Core.ClientRequestIdHeader" }, @@ -243,14 +393,14 @@ } }, "x-ms-examples": { - "Create or Replace Custom Analyzer": { - "$ref": "./examples/Analyzers_CreateOrReplace.json" + "Create or Replace Analyzer": { + "$ref": "./examples/ContentAnalyzers_CreateOrReplace.json" } }, "x-ms-long-running-operation": true }, "patch": { - "operationId": "Analyzers_Update", + "operationId": "ContentAnalyzers_Update", "description": "Update analyzer properties.", "consumes": [ "application/merge-patch+json" @@ -265,6 +415,8 @@ "description": "The unique identifier of the analyzer.", "required": true, "type": "string", + "minLength": 1, + "maxLength": 64, "pattern": "^[a-zA-Z0-9._-]{1,64}$" }, { @@ -309,12 +461,12 @@ }, "x-ms-examples": { "Update Analyzer": { - "$ref": "./examples/Analyzers_Update.json" + "$ref": "./examples/ContentAnalyzers_Update.json" } } }, "delete": { - "operationId": "Analyzers_Delete", + "operationId": "ContentAnalyzers_Delete", "description": "Delete analyzer.", "parameters": [ { @@ -326,6 +478,8 @@ "description": "The unique identifier of the analyzer.", "required": true, "type": "string", + "minLength": 1, + "maxLength": 64, "pattern": "^[a-zA-Z0-9._-]{1,64}$" }, { @@ -357,15 +511,15 @@ } }, "x-ms-examples": { - "Delete Custom Analyzer": { - "$ref": "./examples/Analyzers_DeleteAnalyzer.json" + "Delete Analyzer": { + "$ref": "./examples/ContentAnalyzers_DeleteAnalyzer.json" } } } }, "/analyzers/{analyzerId}:analyze": { "post": { - "operationId": "Analyzers_Analyze", + "operationId": "ContentAnalyzers_Analyze", "description": "Extract content and fields from input.", "parameters": [ { @@ -377,8 +531,16 @@ "description": "The unique identifier of the analyzer.", "required": true, "type": "string", + "minLength": 1, + "maxLength": 64, "pattern": "^[a-zA-Z0-9._-]{1,64}$" }, + { + "$ref": "#/parameters/AnalyzeParameters.stringEncoding" + }, + { + "$ref": "#/parameters/AnalyzeParameters.processingLocation" + }, { "$ref": "#/parameters/Azure.Core.ClientRequestIdHeader" }, @@ -448,16 +610,19 @@ }, "x-ms-examples": { "Analyze URL": { - "$ref": "./examples/Analyzers_Analyze.json" + "$ref": "./examples/ContentAnalyzers_Analyze.json" } }, "x-ms-long-running-operation": true } }, - "/analyzers/{analyzerId}/operations/{operationId}": { - "get": { - "operationId": "Analyzers_GetOperationStatus", - "description": "Get the status of an analyzer creation operation.", + "/analyzers/{analyzerId}:analyzeBinary": { + "post": { + "operationId": "ContentAnalyzers_AnalyzeBinary", + "description": "Extract content and fields from input.", + "consumes": [ + "*/*" + ], "parameters": [ { "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" @@ -468,19 +633,29 @@ "description": "The unique identifier of the analyzer.", "required": true, "type": "string", + "minLength": 1, + "maxLength": 64, "pattern": "^[a-zA-Z0-9._-]{1,64}$" }, { - "name": "operationId", - "in": "path", - "description": "The unique ID of the operation.", - "required": true, - "type": "string" + "$ref": "#/parameters/AnalyzeParameters.stringEncoding" + }, + { + "$ref": "#/parameters/AnalyzeParameters.processingLocation" + }, + { + "$ref": "#/parameters/AnalyzeBinaryRequest.range" + }, + { + "$ref": "#/parameters/Azure.Core.ClientRequestIdHeader" + }, + { + "$ref": "#/parameters/AnalyzeBinaryRequest.input" } ], "responses": { - "200": { - "description": "The request has succeeded.", + "202": { + "description": "The request has been accepted for processing, but processing has not yet completed.", "schema": { "type": "object", "description": "Provides status details for long running operations.", @@ -498,7 +673,7 @@ "description": "Error object that describes the error when status is \"Failed\"." }, "result": { - "$ref": "#/definitions/ContentAnalyzer", + "$ref": "#/definitions/AnalyzeResult", "description": "The result of the operation." } }, @@ -506,6 +681,18 @@ "id", "status" ] + }, + "headers": { + "Operation-Location": { + "type": "string", + "format": "uri", + "description": "The location for monitoring the operation state." + }, + "x-ms-client-request-id": { + "type": "string", + "format": "uuid", + "description": "An opaque, globally-unique, client-generated string identifier for the request." + } } }, "default": { @@ -522,16 +709,17 @@ } }, "x-ms-examples": { - "Get Analyzer Operation Status": { - "$ref": "./examples/Analyzers_GetOperationStatus.json" + "Analyze File": { + "$ref": "./examples/ContentAnalyzers_AnalyzeBinary.json" } - } + }, + "x-ms-long-running-operation": true } }, - "/analyzers/{analyzerId}/results/{operationId}": { - "get": { - "operationId": "Analyzers_GetResult", - "description": "Get the result of an analysis operation.", + "/analyzers/{analyzerId}:copy": { + "post": { + "operationId": "ContentAnalyzers_Copy", + "description": "Create a copy of the source analyzer to the current location.", "parameters": [ { "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" @@ -539,21 +727,36 @@ { "name": "analyzerId", "in": "path", - "description": "Analyzer identifier.", + "description": "The unique identifier of the analyzer.", "required": true, - "type": "string" + "type": "string", + "minLength": 1, + "maxLength": 64, + "pattern": "^[a-zA-Z0-9._-]{1,64}$" }, { - "name": "operationId", - "in": "path", - "description": "The unique ID of the operation.", + "name": "allowReplace", + "in": "query", + "description": "Allow the operation to replace an existing resource.", + "required": false, + "type": "boolean", + "default": false + }, + { + "$ref": "#/parameters/Azure.Core.ClientRequestIdHeader" + }, + { + "name": "body", + "in": "body", "required": true, - "type": "string" + "schema": { + "$ref": "#/definitions/CopyRequest" + } } ], "responses": { - "200": { - "description": "The request has succeeded.", + "202": { + "description": "The request has been accepted for processing, but processing has not yet completed.", "schema": { "type": "object", "description": "Provides status details for long running operations.", @@ -571,7 +774,7 @@ "description": "Error object that describes the error when status is \"Failed\"." }, "result": { - "$ref": "#/definitions/AnalyzeResult", + "$ref": "#/definitions/ContentAnalyzer", "description": "The result of the operation." } }, @@ -579,6 +782,18 @@ "id", "status" ] + }, + "headers": { + "Operation-Location": { + "type": "string", + "format": "uri", + "description": "The location for monitoring the operation state." + }, + "x-ms-client-request-id": { + "type": "string", + "format": "uuid", + "description": "An opaque, globally-unique, client-generated string identifier for the request." + } } }, "default": { @@ -595,20 +810,17 @@ } }, "x-ms-examples": { - "Get Analysis Result": { - "$ref": "./examples/Analyzers_GetResult.json" + "Copy Analyzer": { + "$ref": "./examples/ContentAnalyzers_Copy.json" } - } + }, + "x-ms-long-running-operation": true } }, - "/analyzers/{analyzerId}/results/{operationId}/images/{imageId}": { - "get": { - "operationId": "Analyzers_GetResultImage", - "description": "Get an image associated with the result of an analysis operation.", - "produces": [ - "image/*", - "application/json" - ], + "/analyzers/{analyzerId}:grantCopyAuthorization": { + "post": { + "operationId": "ContentAnalyzers_GrantCopyAuthorization", + "description": "Get authorization for copying this analyzer to another location.", "parameters": [ { "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" @@ -616,30 +828,37 @@ { "name": "analyzerId", "in": "path", - "description": "Analyzer identifier.", + "description": "The unique identifier of the analyzer.", "required": true, - "type": "string" + "type": "string", + "minLength": 1, + "maxLength": 64, + "pattern": "^[a-zA-Z0-9._-]{1,64}$" }, { - "name": "operationId", - "in": "path", - "description": "Operation identifier.", - "required": true, - "type": "string" + "$ref": "#/parameters/Azure.Core.ClientRequestIdHeader" }, { - "name": "imageId", - "in": "path", - "description": "Image identifier.", + "name": "body", + "in": "body", "required": true, - "type": "string" + "schema": { + "$ref": "#/definitions/GrantCopyAuthorizationRequest" + } } ], "responses": { "200": { "description": "The request has succeeded.", "schema": { - "type": "file" + "$ref": "#/definitions/CopyAuthorization" + }, + "headers": { + "x-ms-client-request-id": { + "type": "string", + "format": "uuid", + "description": "An opaque, globally-unique, client-generated string identifier for the request." + } } }, "default": { @@ -656,29 +875,16 @@ } }, "x-ms-examples": { - "Get Analysis Result Image": { - "$ref": "./examples/Analyzers_GetResultImage.json" + "Grant Copy Authorization": { + "$ref": "./examples/ContentAnalyzers_GrantCopyAuthorization.json" } } } - } - }, - "x-ms-paths": { - "/analyzers/{analyzerId}:analyze?_overload=analyzeBinary": { - "post": { - "operationId": "Analyzers_AnalyzeBinary", - "description": "Extract content and fields from input.", - "consumes": [ - "application/pdf", - "image/jpeg", - "image/png", - "image/tiff", - "image/bmp", - "image/heif", - "text/html", - "audio/*", - "video/*" - ], + }, + "/analyzers/{analyzerId}/operations/{operationId}": { + "get": { + "operationId": "ContentAnalyzers_GetOperationStatus", + "description": "Get the status of an analyzer creation operation.", "parameters": [ { "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" @@ -689,56 +895,60 @@ "description": "The unique identifier of the analyzer.", "required": true, "type": "string", + "minLength": 1, + "maxLength": 64, "pattern": "^[a-zA-Z0-9._-]{1,64}$" }, { - "$ref": "#/parameters/Azure.Core.ClientRequestIdHeader" - }, - { - "$ref": "#/parameters/AnalyzeBinaryRequest.input" - } - ], + "name": "operationId", + "in": "path", + "description": "The unique ID of the operation.", + "required": true, + "type": "string" + } + ], "responses": { - "202": { - "description": "The request has been accepted for processing, but processing has not yet completed.", + "200": { + "description": "The request has succeeded.", "schema": { - "type": "object", - "description": "Provides status details for long running operations.", - "properties": { - "id": { - "type": "string", - "description": "The unique ID of the operation." - }, - "status": { - "$ref": "#/definitions/Azure.Core.Foundations.OperationState", - "description": "The status of the operation" - }, - "error": { - "$ref": "#/definitions/Azure.Core.Foundations.Error", - "description": "Error object that describes the error when status is \"Failed\"." - }, - "result": { - "$ref": "#/definitions/AnalyzeResult", - "description": "The result of the operation." - } - }, - "required": [ - "id", - "status" - ] + "$ref": "#/definitions/ContentAnalyzerOperationStatus" + } + }, + "default": { + "description": "An unexpected error response.", + "schema": { + "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" }, "headers": { - "Operation-Location": { - "type": "string", - "format": "uri", - "description": "The location for monitoring the operation state." - }, - "x-ms-client-request-id": { + "x-ms-error-code": { "type": "string", - "format": "uuid", - "description": "An opaque, globally-unique, client-generated string identifier for the request." + "description": "String error code indicating what went wrong." } } + } + }, + "x-ms-examples": { + "Get Analyzer Operation Status": { + "$ref": "./examples/ContentAnalyzers_GetOperationStatus.json" + } + } + } + }, + "/defaults": { + "get": { + "operationId": "ContentAnalyzers_GetDefaults", + "description": "Return default settings for this Content Understanding resource.", + "parameters": [ + { + "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" + } + ], + "responses": { + "200": { + "description": "The request has succeeded.", + "schema": { + "$ref": "#/definitions/ContentUnderstandingDefaults" + } }, "default": { "description": "An unexpected error response.", @@ -754,23 +964,104 @@ } }, "x-ms-examples": { - "Analyze File": { - "$ref": "./examples/Analyzers_AnalyzeBinary.json" + "Get Defaults": { + "$ref": "./examples/ContentAnalyzers_GetDefaults.json" + } + } + }, + "patch": { + "operationId": "ContentAnalyzers_UpdateDefaults", + "description": "Return default settings for this Content Understanding resource.", + "consumes": [ + "application/merge-patch+json" + ], + "parameters": [ + { + "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" + }, + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/ContentUnderstandingDefaultsMergePatchUpdate" + } + } + ], + "responses": { + "200": { + "description": "The request has succeeded.", + "schema": { + "$ref": "#/definitions/ContentUnderstandingDefaults" + } + }, + "default": { + "description": "An unexpected error response.", + "schema": { + "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" + }, + "headers": { + "x-ms-error-code": { + "type": "string", + "description": "String error code indicating what went wrong." + } + } } }, - "x-ms-long-running-operation": true + "x-ms-examples": { + "Update Defaults": { + "$ref": "./examples/ContentAnalyzers_UpdateDefaults.json" + } + } } } }, "definitions": { - "AnalyzeRequest": { + "AnalyzeInput": { "type": "object", - "description": "Analyze operation request.", + "description": "Additional input to analyze.", "properties": { "url": { "type": "string", "format": "uri", - "description": "The URL of the document to analyze." + "description": "The URL of the input to analyze. Only one of url or data should be specified." + }, + "data": { + "type": "string", + "format": "byte", + "description": "Base64-encoded binary content of the input to analyze. Only one of url or data should be specified." + }, + "name": { + "type": "string", + "description": "Name of the input." + }, + "mimeType": { + "type": "string", + "description": "The MIME type of the input content. Ex. application/pdf, image/jpeg, etc." + }, + "range": { + "$ref": "#/definitions/RangeExpression", + "description": "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." + } + } + }, + "AnalyzeRequest": { + "type": "object", + "description": "Analyze operation request.", + "properties": { + "inputs": { + "type": "array", + "description": "Inputs to analyze. Currently, only pro mode supports multiple inputs.", + "items": { + "$ref": "#/definitions/AnalyzeInput" + } + }, + "modelDeployments": { + "type": "object", + "description": "Override default mapping of model names to deployments.\nEx. { \"gpt-4.1\": \"myGpt41Deployment\", \"text-embedding-3-large\": \"myTextEmbedding3LargeDeployment\" }.", + "additionalProperties": { + "type": "string" + } } } }, @@ -781,6 +1072,8 @@ "analyzerId": { "type": "string", "description": "The unique identifier of the analyzer.", + "minLength": 1, + "maxLength": 64, "pattern": "^[a-zA-Z0-9._-]{1,64}$" }, "apiVersion": { @@ -799,6 +1092,11 @@ "$ref": "#/definitions/Azure.Core.Foundations.Error" } }, + "stringEncoding": { + "type": "string", + "description": " The string encoding format for content spans in the response.\n Possible values are 'codePoint', 'utf16', and `utf8`. Default is `codePoint`.\")", + "default": "codePoint" + }, "contents": { "type": "array", "description": "The extracted content.", @@ -854,6 +1152,14 @@ "format": "int32", "description": "Height of each video frame in pixels, if applicable." }, + "cameraShotTimesMs": { + "type": "array", + "description": "List of camera shot changes in the video, represented by its timestamp in milliseconds. Only if returnDetails is true.", + "items": { + "type": "integer", + "format": "int64" + } + }, "keyFrameTimesMs": { "type": "array", "description": "List of key frames in the video, represented by its timestamp in milliseconds. Only if returnDetails is true.", @@ -869,11 +1175,11 @@ "$ref": "#/definitions/TranscriptPhrase" } }, - "faces": { + "segments": { "type": "array", - "description": "List of faces in the video. Only if enableFace and returnDetails are true.", + "description": "List of detected content segments. Only if enableSegment is true.", "items": { - "$ref": "#/definitions/ImageFace" + "$ref": "#/definitions/AudioVisualContentSegment" } } }, @@ -888,6 +1194,41 @@ ], "x-ms-discriminator-value": "audioVisual" }, + "AudioVisualContentSegment": { + "type": "object", + "description": "Detected audio/visual content segment.", + "properties": { + "segmentId": { + "type": "string", + "description": "Segment identifier." + }, + "category": { + "type": "string", + "description": "Classified content category." + }, + "span": { + "$ref": "#/definitions/ContentSpan", + "description": "Span of the segment in the markdown content." + }, + "startTimeMs": { + "type": "integer", + "format": "int64", + "description": "Start time of the segment in milliseconds." + }, + "endTimeMs": { + "type": "integer", + "format": "int64", + "description": "End time of the segment in milliseconds." + } + }, + "required": [ + "segmentId", + "category", + "span", + "startTimeMs", + "endTimeMs" + ] + }, "Azure.Core.Foundations.Error": { "type": "object", "description": "The error object.", @@ -936,7 +1277,7 @@ }, "Azure.Core.Foundations.InnerError": { "type": "object", - "description": "An object containing more specific information about the error. As per Microsoft One API guidelines - https://github.com/microsoft/api-guidelines/blob/vNext/azure/Guidelines.md#handling-errors.", + "description": "An object containing more specific information about the error. As per Azure REST API guidelines - https://aka.ms/AzureRestApiGuidelines#handling-errors.", "properties": { "code": { "type": "string", @@ -990,34 +1331,6 @@ ] } }, - "BlobDataSource": { - "type": "object", - "description": "Blob storage data source.", - "properties": { - "containerUrl": { - "type": "string", - "format": "uri", - "description": "The URL of the blob container." - }, - "prefix": { - "type": "string", - "description": "An optional prefix to filter blobs within the container." - }, - "fileListPath": { - "type": "string", - "description": "An optional path to a file listing specific blobs to include." - } - }, - "required": [ - "containerUrl" - ], - "allOf": [ - { - "$ref": "#/definitions/DataSource" - } - ], - "x-ms-discriminator-value": "blob" - }, "BooleanField": { "type": "object", "description": "Boolean field extracted from the content.", @@ -1041,6 +1354,8 @@ "analyzerId": { "type": "string", "description": "The unique identifier of the analyzer.", + "minLength": 1, + "maxLength": 64, "pattern": "^[a-zA-Z0-9._-]{1,64}$", "readOnly": true }, @@ -1056,7 +1371,7 @@ } }, "status": { - "$ref": "#/definitions/ResourceStatus", + "$ref": "#/definitions/ContentAnalyzerStatus", "description": "The status of the analyzer.", "readOnly": true }, @@ -1072,9 +1387,20 @@ "description": "The date and time when the analyzer was last modified.", "readOnly": true }, - "scenario": { + "warnings": { + "type": "array", + "description": "Warnings encountered while creating the analyzer.", + "items": { + "$ref": "#/definitions/Azure.Core.Foundations.Error" + }, + "readOnly": true + }, + "baseAnalyzerId": { "type": "string", - "description": "The scenario for which the analyzer is optimized.", + "description": "The analyzer to incrementally train from.", + "minLength": 1, + "maxLength": 64, + "pattern": "^[a-zA-Z0-9._-]{1,64}$", "x-ms-mutability": [ "read", "create" @@ -1089,27 +1415,82 @@ ] }, "fieldSchema": { - "$ref": "#/definitions/FieldSchema", + "$ref": "#/definitions/ContentFieldSchema", "description": "The schema of fields to extracted.", "x-ms-mutability": [ "read", "create" ] }, - "trainingData": { - "$ref": "#/definitions/DataSource", - "description": "The data source containing training data for the analyzer.", + "dynamicFieldSchema": { + "type": "boolean", + "description": "Indicates whether the result may contain additional fields outside of the defined schema.", + "default": false, "x-ms-mutability": [ "read", "create" ] }, - "warnings": { + "processingLocation": { + "type": "string", + "description": "The location where the data may be processed. Defaults to global.", + "default": "global", + "enum": [ + "geography", + "dataZone", + "global" + ], + "x-ms-enum": { + "name": "ProcessingLocation", + "modelAsString": true, + "values": [ + { + "name": "geography", + "value": "geography", + "description": "Data may be processed in the same geography as the resource." + }, + { + "name": "dataZone", + "value": "dataZone", + "description": "Data may be processed in the same data zone as the resource." + }, + { + "name": "global", + "value": "global", + "description": "Data may be processed in any Azure data center globally." + } + ] + }, + "x-ms-mutability": [ + "read", + "create" + ] + }, + "knowledgeSources": { "type": "array", - "description": "Warnings encountered while creating the analyzer.", + "description": "Additional knowledge sources used to enhance the analyzer.", "items": { - "$ref": "#/definitions/Azure.Core.Foundations.Error" + "$ref": "#/definitions/KnowledgeSource" + }, + "x-ms-mutability": [ + "read", + "create" + ] + }, + "models": { + "type": "object", + "description": "Mapping of model roles to specific model names.\nEx. { \"completion\": \"gpt-4.1\", \"embedding\": \"text-embedding-3-large\" }.", + "additionalProperties": { + "type": "string" }, + "x-ms-mutability": [ + "read", + "create" + ] + }, + "supportedModels": { + "$ref": "#/definitions/SupportedModels", + "description": "Chat completion and embedding models supported by the analyzer.", "readOnly": true } }, @@ -1120,10 +1501,44 @@ "lastModifiedAt" ] }, + "ContentAnalyzerAnalyzeOperationStatus": { + "type": "object", + "description": "Provides status details for analyze operations.", + "properties": { + "id": { + "type": "string", + "description": "The unique ID of the operation." + }, + "status": { + "$ref": "#/definitions/Azure.Core.Foundations.OperationState", + "description": "The status of the operation" + }, + "error": { + "$ref": "#/definitions/Azure.Core.Foundations.Error", + "description": "Error object that describes the error when status is \"Failed\"." + }, + "result": { + "$ref": "#/definitions/AnalyzeResult", + "description": "The result of the operation." + }, + "usage": { + "$ref": "#/definitions/UsageDetails", + "description": "Usage details of the analyze operation." + } + }, + "required": [ + "id", + "status" + ] + }, "ContentAnalyzerConfig": { "type": "object", "description": "Configuration settings for an analyzer.", "properties": { + "returnDetails": { + "type": "boolean", + "description": "Return all content details." + }, "locales": { "type": "array", "description": "List of locale hints for speech transcription.", @@ -1131,11 +1546,7 @@ "type": "string" } }, - "enableFace": { - "type": "boolean", - "description": "Enable face detection." - }, - "enableOcr": { + "enableOcr": { "type": "boolean", "description": "Enable optical character recognition (OCR)." }, @@ -1143,18 +1554,186 @@ "type": "boolean", "description": "Enable layout analysis." }, - "enableBarcode": { + "enableFigureDescription": { "type": "boolean", - "description": "Enable barcode detection." + "description": "Enable generation of figure description." + }, + "enableFigureAnalysis": { + "type": "boolean", + "description": "Enable analysis of figures, such as charts and diagrams." }, "enableFormula": { "type": "boolean", "description": "Enable mathematical formula detection." }, - "returnDetails": { + "tableFormat": { + "type": "string", + "description": "Representation format of tables in analyze result markdown.", + "default": "html", + "enum": [ + "html", + "markdown" + ], + "x-ms-enum": { + "name": "TableFormat", + "modelAsString": true, + "values": [ + { + "name": "html", + "value": "html", + "description": "Represent tables using HTML table elements: \\, \\, \\
, \\
." + }, + { + "name": "markdown", + "value": "markdown", + "description": "Represent tables using GitHub Flavored Markdown table syntax, which does not support merged cells or rich headers." + } + ] + } + }, + "chartFormat": { + "type": "string", + "description": "Representation format of charts in analyze result markdown.", + "default": "chartJs", + "enum": [ + "chartJs", + "markdown" + ], + "x-ms-enum": { + "name": "ChartFormat", + "modelAsString": true, + "values": [ + { + "name": "chartJs", + "value": "chartJs", + "description": "Represent charts as Chart.js code blocks." + }, + { + "name": "markdown", + "value": "markdown", + "description": "Represent charts as markdown tables." + } + ] + } + }, + "annotationFormat": { + "type": "string", + "description": "Representation format of annotations in analyze result markdown.", + "default": "markdown", + "enum": [ + "none", + "markdown" + ], + "x-ms-enum": { + "name": "AnnotationFormat", + "modelAsString": true, + "values": [ + { + "name": "none", + "value": "none", + "description": "Do not represent annotations." + }, + { + "name": "markdown", + "value": "markdown", + "description": "Represent basic annotation information using markdown formatting." + } + ] + } + }, + "disableFaceBlurring": { "type": "boolean", - "description": "Return all content details." + "description": "Disable the default blurring of faces for privacy while processing the content." + }, + "estimateFieldSourceAndConfidence": { + "type": "boolean", + "description": "Return field grounding source and confidence." + }, + "contentCategories": { + "type": "object", + "description": "Map of categories to classify the input content(s) against.", + "additionalProperties": { + "$ref": "#/definitions/ContentCategoryDefinition" + } + }, + "enableSegment": { + "type": "boolean", + "description": "Enable segmentation of the input by contentCategories." + }, + "segmentPerPage": { + "type": "boolean", + "description": "Force segmentation of document content by page." + }, + "omitContent": { + "type": "boolean", + "description": "Omit the content for this analyzer from analyze result.\nOnly return content(s) from additional analyzers specified in contentCategories, if any." + } + } + }, + "ContentAnalyzerOperationStatus": { + "type": "object", + "description": "Provides status details for analyzer creation operations.", + "properties": { + "id": { + "type": "string", + "description": "The unique ID of the operation." + }, + "status": { + "$ref": "#/definitions/Azure.Core.Foundations.OperationState", + "description": "The status of the operation" + }, + "error": { + "$ref": "#/definitions/Azure.Core.Foundations.Error", + "description": "Error object that describes the error when status is \"Failed\"." + }, + "result": { + "$ref": "#/definitions/ContentAnalyzer", + "description": "The result of the operation." + }, + "usage": { + "$ref": "#/definitions/UsageDetails", + "description": "Usage details of the analyzer creation operation." } + }, + "required": [ + "id", + "status" + ] + }, + "ContentAnalyzerStatus": { + "type": "string", + "description": "Status of a resource.", + "enum": [ + "creating", + "ready", + "deleting", + "failed" + ], + "x-ms-enum": { + "name": "ContentAnalyzerStatus", + "modelAsString": true, + "values": [ + { + "name": "creating", + "value": "creating", + "description": "The resource is being created." + }, + { + "name": "ready", + "value": "ready", + "description": "The resource is ready." + }, + { + "name": "deleting", + "value": "deleting", + "description": "The resource is being deleted." + }, + { + "name": "failed", + "value": "failed", + "description": "The resource failed during creation." + } + ] } }, "ContentAnalyzerUpdate": { @@ -1174,12 +1753,30 @@ } } }, + "ContentCategoryDefinition": { + "type": "object", + "description": "Content category definition.", + "properties": { + "description": { + "type": "string", + "description": "The description of the category." + }, + "analyzerId": { + "type": "string", + "description": "Optional analyzer used to process the content." + }, + "analyzer": { + "$ref": "#/definitions/ContentAnalyzer", + "description": "Optional inline definition of analyzer used to process the content." + } + } + }, "ContentField": { "type": "object", "description": "Field extracted from the content.", "properties": { "type": { - "$ref": "#/definitions/FieldType", + "$ref": "#/definitions/ContentFieldType", "description": "Semantic data type of the field value." }, "spans": { @@ -1197,7 +1794,7 @@ "maximum": 1 }, "source": { - "type": "string", + "$ref": "#/definitions/SourceExpression", "description": "Encoded source that identifies the position of the field value in the content." } }, @@ -1206,6 +1803,177 @@ "type" ] }, + "ContentFieldDefinition": { + "type": "object", + "description": "Definition of the field using a JSON Schema like syntax.", + "properties": { + "method": { + "$ref": "#/definitions/GenerationMethod", + "description": "Generation method." + }, + "type": { + "$ref": "#/definitions/ContentFieldType", + "description": "Semantic data type of the field value." + }, + "description": { + "type": "string", + "description": "Field description." + }, + "items": { + "$ref": "#/definitions/ContentFieldDefinition", + "description": "Field type schema of each array element, if type is array." + }, + "properties": { + "type": "object", + "description": "Named sub-fields, if type is object.", + "additionalProperties": { + "$ref": "#/definitions/ContentFieldDefinition" + } + }, + "examples": { + "type": "array", + "description": "Examples of field values.", + "items": { + "type": "string" + } + }, + "enum": { + "type": "array", + "description": "Enumeration of possible field values.", + "items": { + "type": "string" + } + }, + "enumDescriptions": { + "type": "object", + "description": "Descriptions for each enumeration value.", + "additionalProperties": { + "type": "string" + } + }, + "$ref": { + "type": "string", + "description": "Reference to another field definition." + }, + "estimateSourceAndConfidence": { + "type": "boolean", + "description": "Return grounding source and confidence." + } + } + }, + "ContentFieldSchema": { + "type": "object", + "description": "Schema of fields to be extracted from documents.", + "properties": { + "name": { + "type": "string", + "description": "The name of the field schema.", + "x-ms-mutability": [ + "read", + "create" + ] + }, + "description": { + "type": "string", + "description": "A description of the field schema.", + "x-ms-mutability": [ + "read", + "create" + ] + }, + "fields": { + "type": "object", + "description": "The fields defined in the schema.", + "additionalProperties": { + "$ref": "#/definitions/ContentFieldDefinition" + }, + "x-ms-mutability": [ + "read", + "create" + ] + }, + "definitions": { + "type": "object", + "description": "Additional definitions referenced by the fields in the schema.", + "additionalProperties": { + "$ref": "#/definitions/ContentFieldDefinition" + }, + "x-ms-mutability": [ + "read", + "create" + ] + } + }, + "required": [ + "fields" + ] + }, + "ContentFieldType": { + "type": "string", + "description": "Semantic data type of the field value.", + "enum": [ + "string", + "date", + "time", + "number", + "integer", + "boolean", + "array", + "object", + "json" + ], + "x-ms-enum": { + "name": "ContentFieldType", + "modelAsString": true, + "values": [ + { + "name": "string", + "value": "string", + "description": "Plain text." + }, + { + "name": "date", + "value": "date", + "description": "Date, normalized to ISO 8601 (YYYY-MM-DD) format." + }, + { + "name": "time", + "value": "time", + "description": "Time, normalized to ISO 8601 (hh:mm:ss) format." + }, + { + "name": "number", + "value": "number", + "description": "Number as double precision floating point." + }, + { + "name": "integer", + "value": "integer", + "description": "Integer as 64-bit signed integer." + }, + { + "name": "boolean", + "value": "boolean", + "description": "Boolean value." + }, + { + "name": "array", + "value": "array", + "description": "List of subfields of the same type." + }, + { + "name": "object", + "value": "object", + "description": "Named list of subfields." + }, + { + "name": "json", + "value": "json", + "description": "JSON object." + } + ] + } + }, "ContentSpan": { "type": "object", "description": "Position of the element in markdown, specified as a character offset and length.", @@ -1226,55 +1994,247 @@ "length" ] }, - "DataSource": { + "ContentUnderstandingDefaults": { + "type": "object", + "description": "default settings for this Content Understanding resource.", + "properties": { + "modelDeployments": { + "type": "object", + "description": "Mapping of model names to deployments.\nEx. { \"gpt-4.1\": \"myGpt41Deployment\", \"text-embedding-3-large\": \"myTextEmbedding3LargeDeployment\" }.", + "additionalProperties": { + "type": "string" + }, + "x-ms-mutability": [ + "read", + "update", + "create" + ] + } + }, + "required": [ + "modelDeployments" + ] + }, + "ContentUnderstandingDefaultsMergePatchUpdate": { + "type": "object", + "description": "default settings for this Content Understanding resource.", + "properties": { + "modelDeployments": { + "type": "object", + "description": "Mapping of model names to deployments.\nEx. { \"gpt-4.1\": \"myGpt41Deployment\", \"text-embedding-3-large\": \"myTextEmbedding3LargeDeployment\" }.", + "additionalProperties": { + "type": "string" + } + } + } + }, + "CopyAuthorization": { + "type": "object", + "description": "Copy authorization details for cross-resource copy.", + "properties": { + "source": { + "type": "string", + "description": "Full path of the source analyzer." + }, + "targetAzureResourceId": { + "type": "string", + "description": "Azure resource ID of the target location to copy to." + }, + "expiresAt": { + "type": "string", + "format": "date-time", + "description": "Date/time when the copy authorization expires." + } + }, + "required": [ + "source", + "targetAzureResourceId", + "expiresAt" + ] + }, + "CopyRequest": { + "type": "object", + "description": "Copy operation request.", + "properties": { + "sourceAzureResourceId": { + "type": "string", + "description": "Azure resource ID of the source analyzer location. Defaults to the current resource." + }, + "sourceRegion": { + "type": "string", + "description": "Azure region of the source analyzer location. Defaults to current region." + }, + "sourceAnalyzerId": { + "type": "string", + "description": "Source analyzer ID." + } + }, + "required": [ + "sourceAnalyzerId" + ] + }, + "DateField": { + "type": "object", + "description": "Date field extracted from the content.", + "properties": { + "valueDate": { + "type": "string", + "format": "date", + "description": "Date field value, in ISO 8601 (YYYY-MM-DD) format." + } + }, + "allOf": [ + { + "$ref": "#/definitions/ContentField" + } + ], + "x-ms-discriminator-value": "date" + }, + "DocumentAnnotation": { "type": "object", - "description": "Data source specifying a set of documents.", + "description": "Annotation in a document, such as a strikethrough or a comment.", "properties": { + "id": { + "type": "string", + "description": "Annotation identifier." + }, "kind": { - "$ref": "#/definitions/DataSourceKind", - "description": "The kind of data source." + "$ref": "#/definitions/DocumentAnnotationKind", + "description": "Annotation kind." + }, + "spans": { + "type": "array", + "description": "Spans of the content associated with the annotation.", + "items": { + "$ref": "#/definitions/ContentSpan" + } + }, + "source": { + "$ref": "#/definitions/SourceExpression", + "description": "Position of the annotation." + }, + "comments": { + "type": "array", + "description": "Comments associated with the annotation.", + "items": { + "$ref": "#/definitions/DocumentAnnotationComment" + } + }, + "author": { + "type": "string", + "description": "Annotation author." + }, + "createdAt": { + "type": "string", + "format": "date-time", + "description": "Date and time when the annotation was created." + }, + "lastModifiedAt": { + "type": "string", + "format": "date-time", + "description": "Date and time when the annotation was last modified." + }, + "tags": { + "type": "array", + "description": "Tags associated with the annotation.", + "items": { + "type": "string" + } + } + }, + "required": [ + "id", + "kind" + ] + }, + "DocumentAnnotationComment": { + "type": "object", + "description": "Comment associated with a document annotation.", + "properties": { + "message": { + "type": "string", + "description": "Comment message in Markdown." + }, + "author": { + "type": "string", + "description": "Author of the comment." + }, + "createdAt": { + "type": "string", + "format": "date-time", + "description": "Date and time when the comment was created." + }, + "lastModifiedAt": { + "type": "string", + "format": "date-time", + "description": "Date and time when the comment was last modified." + }, + "tags": { + "type": "array", + "description": "Tags associated with the comment.", + "items": { + "type": "string" + } } }, - "discriminator": "kind", "required": [ - "kind" + "message" ] }, - "DataSourceKind": { + "DocumentAnnotationKind": { "type": "string", - "description": "Data source kind.", + "description": "Document annotation kind.", "enum": [ - "blob" + "highlight", + "strikethrough", + "underline", + "italic", + "bold", + "circle", + "note" ], "x-ms-enum": { - "name": "DataSourceKind", + "name": "DocumentAnnotationKind", "modelAsString": true, "values": [ { - "name": "blob", - "value": "blob", - "description": "A blob storage data source." + "name": "highlight", + "value": "highlight", + "description": "Highlight annotation." + }, + { + "name": "strikethrough", + "value": "strikethrough", + "description": "Strikethrough annotation." + }, + { + "name": "underline", + "value": "underline", + "description": "Underline annotation." + }, + { + "name": "italic", + "value": "italic", + "description": "Italic annotation." + }, + { + "name": "bold", + "value": "bold", + "description": "Bold annotation." + }, + { + "name": "circle", + "value": "circle", + "description": "Circle annotation." + }, + { + "name": "note", + "value": "note", + "description": "Note annotation." } ] } }, - "DateField": { - "type": "object", - "description": "Date field extracted from the content.", - "properties": { - "valueDate": { - "type": "string", - "format": "date", - "description": "Date field value, in ISO 8601 (YYYY-MM-DD) format." - } - }, - "allOf": [ - { - "$ref": "#/definitions/ContentField" - } - ], - "x-ms-discriminator-value": "date" - }, "DocumentBarcode": { "type": "object", "description": "Barcode in a document.", @@ -1288,7 +2248,7 @@ "description": "Barcode value." }, "source": { - "type": "string", + "$ref": "#/definitions/SourceExpression", "description": "Encoded source that identifies the position of the barcode in the content." }, "span": { @@ -1431,7 +2391,7 @@ "description": "Content of the caption." }, "source": { - "type": "string", + "$ref": "#/definitions/SourceExpression", "description": "Encoded source that identifies the position of the caption in the content." }, "span": { @@ -1450,6 +2410,26 @@ "content" ] }, + "DocumentChartFigure": { + "type": "object", + "description": "Figure containing a chart, such as a bar chart, line chart, or pie chart.", + "properties": { + "content": { + "type": "object", + "description": "Chart content represented using [Chart.js config](https://www.chartjs.org/docs/latest/configuration/).", + "additionalProperties": {} + } + }, + "required": [ + "content" + ], + "allOf": [ + { + "$ref": "#/definitions/DocumentFigure" + } + ], + "x-ms-discriminator-value": "chart" + }, "DocumentContent": { "type": "object", "description": "Document content. Ex. text/plain, application/pdf, image/jpeg.", @@ -1503,11 +2483,25 @@ "$ref": "#/definitions/DocumentFigure" } }, - "faces": { + "annotations": { + "type": "array", + "description": "List of annotations in the document. Only if enableAnnotations and returnDetails are true.", + "items": { + "$ref": "#/definitions/DocumentAnnotation" + } + }, + "hyperlinks": { + "type": "array", + "description": "List of hyperlinks in the document. Only if returnDetails are true.", + "items": { + "$ref": "#/definitions/DocumentHyperlink" + } + }, + "segments": { "type": "array", - "description": "List of faces in the document. Only if enableFace and returnDetails are true.", + "description": "List of detected content segments. Only if enableSegment is true.", "items": { - "$ref": "#/definitions/ImageFace" + "$ref": "#/definitions/DocumentContentSegment" } } }, @@ -1522,6 +2516,41 @@ ], "x-ms-discriminator-value": "document" }, + "DocumentContentSegment": { + "type": "object", + "description": "Detected document content segment.", + "properties": { + "segmentId": { + "type": "string", + "description": "Segment identifier." + }, + "category": { + "type": "string", + "description": "Classified content category." + }, + "span": { + "$ref": "#/definitions/ContentSpan", + "description": "Span of the segment in the markdown content." + }, + "startPageNumber": { + "type": "integer", + "format": "int32", + "description": "Start page number (1-indexed) of the segment." + }, + "endPageNumber": { + "type": "integer", + "format": "int32", + "description": "End page number (1-indexed) of the segment." + } + }, + "required": [ + "segmentId", + "category", + "span", + "startPageNumber", + "endPageNumber" + ] + }, "DocumentElement": { "type": "string", "description": "JSON pointer referencing an element of the document, such as paragraph,\ntable, section, etc." @@ -1530,12 +2559,43 @@ "type": "object", "description": "Figure in a document.", "properties": { + "kind": { + "type": "string", + "description": "Figure kind.", + "default": "unknown", + "enum": [ + "unknown", + "chart", + "mermaid" + ], + "x-ms-enum": { + "name": "DocumentFigureKind", + "modelAsString": true, + "values": [ + { + "name": "unknown", + "value": "unknown", + "description": "Unknown figure kind." + }, + { + "name": "chart", + "value": "chart", + "description": "Figure containing a chart, such as a bar chart, line chart, or pie chart." + }, + { + "name": "mermaid", + "value": "mermaid", + "description": "Figure containing a diagram, such as a flowchart or network diagram." + } + ] + } + }, "id": { "type": "string", "description": "Figure identifier." }, "source": { - "type": "string", + "$ref": "#/definitions/SourceExpression", "description": "Encoded source that identifies the position of the figure in the content." }, "span": { @@ -1559,9 +2619,19 @@ "items": { "$ref": "#/definitions/DocumentFootnote" } + }, + "description": { + "type": "string", + "description": "Description of the figure." + }, + "role": { + "$ref": "#/definitions/SemanticRole", + "description": "Semantic role of the figure." } }, + "discriminator": "kind", "required": [ + "kind", "id" ] }, @@ -1574,7 +2644,7 @@ "description": "Content of the footnote." }, "source": { - "type": "string", + "$ref": "#/definitions/SourceExpression", "description": "Encoded source that identifies the position of the footnote in the content." }, "span": { @@ -1606,7 +2676,7 @@ "description": "LaTex expression describing the formula." }, "source": { - "type": "string", + "$ref": "#/definitions/SourceExpression", "description": "Encoded source that identifies the position of the formula in the content." }, "span": { @@ -1650,6 +2720,32 @@ ] } }, + "DocumentHyperlink": { + "type": "object", + "description": "Hyperlink in a document, such as a link to a web page or an email address.", + "properties": { + "content": { + "type": "string", + "description": "Hyperlinked content." + }, + "url": { + "type": "string", + "description": "URL of the hyperlink." + }, + "span": { + "$ref": "#/definitions/ContentSpan", + "description": "Span of the hyperlink in the markdown content." + }, + "source": { + "$ref": "#/definitions/SourceExpression", + "description": "Position of the hyperlink." + } + }, + "required": [ + "content", + "url" + ] + }, "DocumentLine": { "type": "object", "description": "Line in a document, consisting of an contiguous sequence of words.", @@ -1659,7 +2755,7 @@ "description": "Line text." }, "source": { - "type": "string", + "$ref": "#/definitions/SourceExpression", "description": "Encoded source that identifies the position of the line in the content." }, "span": { @@ -1671,6 +2767,25 @@ "content" ] }, + "DocumentMermaidFigure": { + "type": "object", + "description": "Figure containing a diagram, such as a flowchart or network diagram.", + "properties": { + "content": { + "type": "string", + "description": "Diagram content represented using [Mermaid syntax](https://mermaid.js.org/intro/)." + } + }, + "required": [ + "content" + ], + "allOf": [ + { + "$ref": "#/definitions/DocumentFigure" + } + ], + "x-ms-discriminator-value": "mermaid" + }, "DocumentPage": { "type": "object", "description": "Content from a document page.", @@ -1742,7 +2857,7 @@ "description": "Paragraph in a document, generally consisting of an contiguous sequence of lines\nwith common alignment and spacing.", "properties": { "role": { - "$ref": "#/definitions/ParagraphRole", + "$ref": "#/definitions/SemanticRole", "description": "Semantic role of the paragraph." }, "content": { @@ -1750,7 +2865,7 @@ "description": "Paragraph text." }, "source": { - "type": "string", + "$ref": "#/definitions/SourceExpression", "description": "Encoded source that identifies the position of the paragraph in the content." }, "span": { @@ -1803,7 +2918,7 @@ } }, "source": { - "type": "string", + "$ref": "#/definitions/SourceExpression", "description": "Encoded source that identifies the position of the table in the content." }, "span": { @@ -1820,6 +2935,10 @@ "items": { "$ref": "#/definitions/DocumentFootnote" } + }, + "role": { + "$ref": "#/definitions/SemanticRole", + "description": "Semantic role of the table." } }, "required": [ @@ -1904,7 +3023,7 @@ "description": "Content of the table cell." }, "source": { - "type": "string", + "$ref": "#/definitions/SourceExpression", "description": "Encoded source that identifies the position of the table cell in the content." }, "span": { @@ -1928,237 +3047,77 @@ "DocumentWord": { "type": "object", "description": "Word in a document, consisting of a contiguous sequence of characters.\nFor non-space delimited languages, such as Chinese, Japanese, and Korean, \neach character is represented as its own word.", - "properties": { - "content": { - "type": "string", - "description": "Word text." - }, - "source": { - "type": "string", - "description": "Encoded source that identifies the position of the word in the content." - }, - "span": { - "$ref": "#/definitions/ContentSpan", - "description": "Span of the word in the markdown content." - }, - "confidence": { - "type": "number", - "format": "float", - "description": "Confidence of predicting the word.", - "minimum": 0, - "maximum": 1 - } - }, - "required": [ - "content" - ] - }, - "FieldDefinition": { - "type": "object", - "description": "Definition of the field using a JSON Schema like syntax.", - "properties": { - "method": { - "type": "string", - "description": "Generation method.", - "default": "generate", - "enum": [ - "generate", - "extract", - "classify" - ], - "x-ms-enum": { - "name": "GenerationMethod", - "modelAsString": true, - "values": [ - { - "name": "generate", - "value": "generate", - "description": "Values are generated freely based on the content." - }, - { - "name": "extract", - "value": "extract", - "description": "Values are extracted as they appear in the content." - }, - { - "name": "classify", - "value": "classify", - "description": "Values are classified against a predefined set of categories." - } - ] - } - }, - "type": { - "$ref": "#/definitions/FieldType", - "description": "Semantic data type of the field value." - }, - "description": { - "type": "string", - "description": "Field description." - }, - "items": { - "$ref": "#/definitions/FieldDefinition", - "description": "Field type schema of each array element, if type is array." - }, - "properties": { - "type": "object", - "description": "Named sub-fields, if type is object.", - "additionalProperties": { - "$ref": "#/definitions/FieldDefinition" - } - }, - "examples": { - "type": "array", - "description": "Examples of field values.", - "items": { - "type": "string" - } - }, - "enum": { - "type": "array", - "description": "Enumeration of possible field values.", - "items": { - "type": "string" - } - }, - "enumDescriptions": { - "type": "object", - "description": "Descriptions for each enumeration value.", - "additionalProperties": { - "type": "string" - } - }, - "$ref": { - "type": "string", - "description": "Reference to another field definition." - } - } - }, - "FieldSchema": { - "type": "object", - "description": "Schema of fields to be extracted from documents.", - "properties": { - "name": { - "type": "string", - "description": "The name of the field schema.", - "x-ms-mutability": [ - "read", - "create" - ] - }, - "description": { - "type": "string", - "description": "A description of the field schema.", - "x-ms-mutability": [ - "read", - "create" - ] + "properties": { + "content": { + "type": "string", + "description": "Word text." }, - "fields": { - "type": "object", - "description": "The fields defined in the schema.", - "additionalProperties": { - "$ref": "#/definitions/FieldDefinition" - }, - "x-ms-mutability": [ - "read", - "create" - ] + "source": { + "$ref": "#/definitions/SourceExpression", + "description": "Encoded source that identifies the position of the word in the content." }, - "definitions": { - "type": "object", - "description": "Additional definitions referenced by the fields in the schema.", - "additionalProperties": { - "$ref": "#/definitions/FieldDefinition" - }, - "x-ms-mutability": [ - "read", - "create" - ] + "span": { + "$ref": "#/definitions/ContentSpan", + "description": "Span of the word in the markdown content." + }, + "confidence": { + "type": "number", + "format": "float", + "description": "Confidence of predicting the word.", + "minimum": 0, + "maximum": 1 } }, "required": [ - "fields" + "content" ] }, - "FieldType": { + "GenerationMethod": { "type": "string", - "description": "Semantic data type of the field value.", + "description": "Generation method.", "enum": [ - "string", - "date", - "time", - "number", - "integer", - "boolean", - "array", - "object" + "generate", + "extract", + "classify" ], "x-ms-enum": { - "name": "FieldType", + "name": "GenerationMethod", "modelAsString": true, "values": [ { - "name": "string", - "value": "string", - "description": "Plain text." - }, - { - "name": "date", - "value": "date", - "description": "Date, normalized to ISO 8601 (YYYY-MM-DD) format." - }, - { - "name": "time", - "value": "time", - "description": "Time, normalized to ISO 8601 (hh:mm:ss) format." - }, - { - "name": "number", - "value": "number", - "description": "Number as double precision floating point." - }, - { - "name": "integer", - "value": "integer", - "description": "Integer as 64-bit signed integer." - }, - { - "name": "boolean", - "value": "boolean", - "description": "Boolean value." + "name": "generate", + "value": "generate", + "description": "Values are generated freely based on the content." }, { - "name": "array", - "value": "array", - "description": "List of subfields of the same type." + "name": "extract", + "value": "extract", + "description": "Values are extracted as they appear in the content." }, { - "name": "object", - "value": "object", - "description": "Named list of subfields." + "name": "classify", + "value": "classify", + "description": "Values are classified against a predefined set of categories." } ] } }, - "ImageFace": { + "GrantCopyAuthorizationRequest": { "type": "object", - "description": "Face in an image.", + "description": "Grant copy authorization request.", "properties": { - "faceId": { + "targetAzureResourceId": { "type": "string", - "description": "Face identifier." - }, - "confidence": { - "type": "number", - "format": "float", - "description": "Confidence of predicting the face." + "description": "Azure resource ID of the target analyzer location." }, - "source": { + "targetRegion": { "type": "string", - "description": "Encoded source that identifies the position of the face in the content." + "description": "Azure region of the target analyzer location. Defaults to current region." } - } + }, + "required": [ + "targetAzureResourceId" + ] }, "IntegerField": { "type": "object", @@ -2177,6 +3136,82 @@ ], "x-ms-discriminator-value": "integer" }, + "JsonField": { + "type": "object", + "description": "JSON field extracted from the content.", + "properties": { + "valueJson": { + "description": "JSON field value." + } + }, + "allOf": [ + { + "$ref": "#/definitions/ContentField" + } + ], + "x-ms-discriminator-value": "json" + }, + "KnowledgeSource": { + "type": "object", + "description": "Knowledge source.", + "properties": { + "kind": { + "$ref": "#/definitions/KnowledgeSourceKind", + "description": "The kind of knowledge source." + } + }, + "discriminator": "kind", + "required": [ + "kind" + ] + }, + "KnowledgeSourceKind": { + "type": "string", + "description": "Knowledge source kind.", + "enum": [ + "labeledData" + ], + "x-ms-enum": { + "name": "KnowledgeSourceKind", + "modelAsString": true, + "values": [ + { + "name": "labeledData", + "value": "labeledData", + "description": "A labeled data knowledge source." + } + ] + } + }, + "LabeledDataKnowledgeSource": { + "type": "object", + "description": "Labeled data knowledge source.", + "properties": { + "containerUrl": { + "type": "string", + "format": "uri", + "description": "The URL of the blob container containing labeled data." + }, + "prefix": { + "type": "string", + "description": "An optional prefix to filter blobs within the container." + }, + "fileListPath": { + "type": "string", + "description": "An optional path to a file listing specific blobs to include." + } + }, + "required": [ + "containerUrl", + "fileListPath" + ], + "allOf": [ + { + "$ref": "#/definitions/KnowledgeSource" + } + ], + "x-ms-discriminator-value": "labeledData" + }, "LengthUnit": { "type": "string", "description": "Length unit used by the width, height, and source properties.", @@ -2209,6 +3244,25 @@ "$ref": "#/definitions/MediaContentKind", "description": "Content kind." }, + "mimeType": { + "type": "string", + "description": "Detected MIME type of the content. Ex. application/pdf, image/jpeg, etc." + }, + "analyzerId": { + "type": "string", + "description": "The analyzer that generated this content.", + "minLength": 1, + "maxLength": 64, + "pattern": "^[a-zA-Z0-9._-]{1,64}$" + }, + "category": { + "type": "string", + "description": "Classified content category." + }, + "path": { + "type": "string", + "description": "The path of the content in the input." + }, "markdown": { "type": "string", "description": "Markdown representation of the content." @@ -2223,7 +3277,8 @@ }, "discriminator": "kind", "required": [ - "kind" + "kind", + "mimeType" ] }, "MediaContentKind": { @@ -2307,7 +3362,11 @@ "value" ] }, - "ParagraphRole": { + "RangeExpression": { + "type": "string", + "description": " Range expression for specifying parts of the input to analyze (ex. `1-3,5,9-`).\n Document content uses 1-based page numbers, while audio visual content uses integer milliseconds." + }, + "SemanticRole": { "type": "string", "description": "Semantic role of the paragraph.", "enum": [ @@ -2320,7 +3379,7 @@ "formulaBlock" ], "x-ms-enum": { - "name": "ParagraphRole", + "name": "SemanticRole", "modelAsString": true, "values": [ { @@ -2361,41 +3420,9 @@ ] } }, - "ResourceStatus": { + "SourceExpression": { "type": "string", - "description": "Status of a resource.", - "enum": [ - "creating", - "ready", - "deleting", - "failed" - ], - "x-ms-enum": { - "name": "ResourceStatus", - "modelAsString": true, - "values": [ - { - "name": "creating", - "value": "creating", - "description": "The resource is being created." - }, - { - "name": "ready", - "value": "ready", - "description": "The resource is ready." - }, - { - "name": "deleting", - "value": "deleting", - "description": "The resource is being deleted." - }, - { - "name": "failed", - "value": "failed", - "description": "The resource failed during creation." - } - ] - } + "description": "Encoded string expression that describes positions in the content." }, "StringField": { "type": "object", @@ -2413,6 +3440,30 @@ ], "x-ms-discriminator-value": "string" }, + "SupportedModels": { + "type": "object", + "description": "Chat completion and embedding models supported by the analyzer.", + "properties": { + "completion": { + "type": "object", + "description": "Chat completion models supported by the analyzer.", + "additionalProperties": { + "type": "string" + } + }, + "embedding": { + "type": "object", + "description": "Embedding models supported by the analyzer.", + "additionalProperties": { + "type": "string" + } + } + }, + "required": [ + "completion", + "embedding" + ] + }, "TimeField": { "type": "object", "description": "Time field extracted from the content.", @@ -2510,6 +3561,50 @@ "endTimeMs", "text" ] + }, + "UsageDetails": { + "type": "object", + "description": "Usage details.", + "properties": { + "documentPagesMinimal": { + "type": "integer", + "format": "int32", + "description": "The number of document pages processed at the minimal level.\nFor documents without explicit pages (ex. txt, html), every 3000 UTF-16 characters is counted as one page." + }, + "documentPagesBasic": { + "type": "integer", + "format": "int32", + "description": "The number of document pages processed at the basic level.\nFor documents without explicit pages (ex. txt, html), every 3000 UTF-16 characters is counted as one page." + }, + "documentPagesStandard": { + "type": "integer", + "format": "int32", + "description": "The number of document pages processed at the standard level.\nFor documents without explicit pages (ex. txt, html), every 3000 UTF-16 characters is counted as one page." + }, + "audioHours": { + "type": "number", + "format": "float", + "description": "The hours of audio processed." + }, + "videoHours": { + "type": "number", + "format": "float", + "description": "The hours of video processed." + }, + "contextualizationTokens": { + "type": "integer", + "format": "int32", + "description": "The number of contextualization tokens consumed for preparing context, generating confidence scores, source grounding, and output formatting." + }, + "tokens": { + "type": "object", + "description": "The number of LLM and embedding tokens consumed, grouped by model (ex. GTP 4.1) and type (ex. input, cached input, output).", + "additionalProperties": { + "format": "int32", + "type": "integer" + } + } + } } }, "parameters": { @@ -2524,6 +3619,58 @@ }, "x-ms-parameter-location": "method" }, + "AnalyzeBinaryRequest.range": { + "name": "range", + "in": "query", + "description": "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.", + "required": false, + "type": "string", + "x-ms-parameter-location": "method" + }, + "AnalyzeParameters.processingLocation": { + "name": "processingLocation", + "in": "query", + "description": "The location where the data may be processed. Defaults to global.", + "required": false, + "type": "string", + "default": "global", + "enum": [ + "geography", + "dataZone", + "global" + ], + "x-ms-enum": { + "name": "ProcessingLocation", + "modelAsString": true, + "values": [ + { + "name": "geography", + "value": "geography", + "description": "Data may be processed in the same geography as the resource." + }, + { + "name": "dataZone", + "value": "dataZone", + "description": "Data may be processed in the same data zone as the resource." + }, + { + "name": "global", + "value": "global", + "description": "Data may be processed in any Azure data center globally." + } + ] + }, + "x-ms-parameter-location": "method" + }, + "AnalyzeParameters.stringEncoding": { + "name": "stringEncoding", + "in": "query", + "description": " The string encoding format for content spans in the response.\n Possible values are 'codePoint', 'utf16', and `utf8`. Default is `codePoint`.\")", + "required": false, + "type": "string", + "default": "codePoint", + "x-ms-parameter-location": "method" + }, "Azure.Core.ClientRequestIdHeader": { "name": "x-ms-client-request-id", "in": "header", diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2024-12-01-preview/examples/Analyzers_Analyze.json b/specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_Analyze.json similarity index 55% rename from specification/ai/data-plane/ContentUnderstanding/preview/2024-12-01-preview/examples/Analyzers_Analyze.json rename to specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_Analyze.json index 915cfc04a66e..dca4bd216946 100644 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2024-12-01-preview/examples/Analyzers_Analyze.json +++ b/specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_Analyze.json @@ -1,17 +1,21 @@ { "title": "Analyze URL", - "operationId": "Analyzers_Analyze", + "operationId": "ContentAnalyzers_Analyze", "parameters": { - "api-version": "2024-12-01-preview", + "api-version": "2025-11-01", "analyzerId": "myAnalyzer", "body": { - "url": "https://host.com/doc.pdf" + "inputs": [ + { + "url": "https://host.com/doc.pdf" + } + ] } }, "responses": { "202": { "headers": { - "Operation-Location": "https://myendpoint.cognitiveservices.azure.com/contentunderstanding/analyzers/myAnalyzer/results/3b31320d-8bab-4f88-b19c-2322a7f11034?api-version=2024-12-01-preview" + "Operation-Location": "https://myendpoint.cognitiveservices.azure.com/contentunderstanding/analyzerResults/3b31320d-8bab-4f88-b19c-2322a7f11034?api-version=2025-11-01" }, "body": { "id": "3b31320d-8bab-4f88-b19c-2322a7f11034", diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2024-12-01-preview/examples/Analyzers_AnalyzeBinary.json b/specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_AnalyzeBinary.json similarity index 62% rename from specification/ai/data-plane/ContentUnderstanding/preview/2024-12-01-preview/examples/Analyzers_AnalyzeBinary.json rename to specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_AnalyzeBinary.json index 2fe20ee04938..0e42cc4b5fd0 100644 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2024-12-01-preview/examples/Analyzers_AnalyzeBinary.json +++ b/specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_AnalyzeBinary.json @@ -1,15 +1,15 @@ { "title": "Analyze File", - "operationId": "Analyzers_AnalyzeBinary", + "operationId": "ContentAnalyzers_AnalyzeBinary", "parameters": { - "api-version": "2024-12-01-preview", + "api-version": "2025-11-01", "analyzerId": "myAnalyzer", "input": "RXhhbXBsZSBGaWxl" }, "responses": { "202": { "headers": { - "Operation-Location": "https://myendpoint.cognitiveservices.azure.com/contentunderstanding/analyzers/myAnalyzer/results/3b31320d-8bab-4f88-b19c-2322a7f11034?api-version=2024-12-01-preview" + "Operation-Location": "https://myendpoint.cognitiveservices.azure.com/contentunderstanding/analyzerResults/3b31320d-8bab-4f88-b19c-2322a7f11034?api-version=2025-11-01" }, "body": { "id": "3b31320d-8bab-4f88-b19c-2322a7f11034", diff --git a/specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_Copy.json b/specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_Copy.json new file mode 100644 index 000000000000..7e3724d7c490 --- /dev/null +++ b/specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_Copy.json @@ -0,0 +1,44 @@ +{ + "title": "Copy Analyzer", + "operationId": "ContentAnalyzers_Copy", + "parameters": { + "api-version": "2025-11-01", + "analyzerId": "targetAnalyzer", + "body": { + "sourceAzureResourceId": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.CognitiveServices/accounts/myResource", + "sourceRegion": "westus2", + "sourceAnalyzerId": "sourceAnalyzer" + } + }, + "responses": { + "202": { + "headers": { + "Operation-Location": "https://myendpoint.cognitiveservices.azure.com/contentunderstanding/analyzers/targetAnalyzer/operations/3b31320d-8bab-4f88-b19c-2322a7f11034?api-version=2025-11-01" + }, + "body": { + "analyzerId": "targetAnalyzer", + "description": "My analyzer", + "status": "creating", + "createdAt": "2025-05-01T18:46:36.051Z", + "lastModifiedAt": "2025-05-01T18:46:36.051Z", + "baseAnalyzerId": "prebuilt-document", + "config": { + "enableOcr": true, + "enableLayout": true, + "returnDetails": true + }, + "fieldSchema": { + "name": "MyForm", + "description": "My form", + "fields": { + "Company": { + "type": "string", + "description": "Name of company." + } + }, + "definitions": {} + } + } + } + } +} diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2024-12-01-preview/examples/Analyzers_CreateOrReplace.json b/specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_CreateOrReplace.json similarity index 57% rename from specification/ai/data-plane/ContentUnderstanding/preview/2024-12-01-preview/examples/Analyzers_CreateOrReplace.json rename to specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_CreateOrReplace.json index baaa8f361d82..f5ba18471e3e 100644 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2024-12-01-preview/examples/Analyzers_CreateOrReplace.json +++ b/specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_CreateOrReplace.json @@ -1,26 +1,22 @@ { - "title": "Create or Replace Custom Analyzer", - "operationId": "Analyzers_CreateOrReplace", + "title": "Create or Replace Analyzer", + "operationId": "ContentAnalyzers_CreateOrReplace", "parameters": { - "api-version": "2024-12-01-preview", + "api-version": "2025-11-01", "analyzerId": "myAnalyzer", "resource": { - "description": "My custom analyzer", + "description": "My analyzer", "tags": { "createdBy": "John" }, - "scenario": "document", + "baseAnalyzerId": "prebuilt-document", "config": { - "enableFace": false, - "enableOcr": true, - "enableLayout": true, - "enableBarcode": true, "enableFormula": false, "returnDetails": true }, "fieldSchema": { "name": "MyForm", - "description": "My custom form", + "description": "My form", "fields": { "Company": { "type": "string", @@ -29,41 +25,41 @@ }, "definitions": {} }, - "trainingData": { - "kind": "blob", - "containerUrl": "https://myStorageAccount.blob.core.windows.net/myContainer?mySasToken", - "prefix": "trainingData", - "fileListPath": "trainingData/fileList.jsonl" - } + "knowledgeSources": [ + { + "kind": "labeledData", + "containerUrl": "https://myStorageAccount.blob.core.windows.net/myContainer", + "prefix": "trainingData", + "fileListPath": "trainingData/fileList.jsonl" + } + ] } }, "responses": { "200": { "headers": { - "Operation-Location": "https://myendpoint.cognitiveservices.azure.com/contentunderstanding/analyzers/myAnalyzer/operations/3b31320d-8bab-4f88-b19c-2322a7f11034?api-version=2024-12-01-preview" + "Operation-Location": "https://myendpoint.cognitiveservices.azure.com/contentunderstanding/analyzers/myAnalyzer/operations/3b31320d-8bab-4f88-b19c-2322a7f11034?api-version=2025-11-01" }, "body": { "analyzerId": "myAnalyzer", - "description": "My custom analyzer", + "description": "My analyzer", "tags": { "createdBy": "John" }, "status": "creating", - "createdAt": "2024-10-14T18:46:36.051Z", - "lastModifiedAt": "2024-10-14T18:46:36.051Z", - "scenario": "document", + "createdAt": "2025-05-01T18:46:36.051Z", + "lastModifiedAt": "2025-05-01T18:46:36.051Z", + "baseAnalyzerId": "prebuilt-document", "config": { "locales": null, - "enableFace": false, "enableOcr": true, "enableLayout": true, - "enableBarcode": true, "enableFormula": false, "returnDetails": true }, "fieldSchema": { "name": "MyForm", - "description": "My custom form", + "description": "My form", "fields": { "Company": { "type": "string", @@ -72,40 +68,40 @@ }, "definitions": {} }, - "trainingData": { - "kind": "blob", - "containerUrl": "https://myStorageAccount.blob.core.windows.net/myContainer", - "prefix": "trainingData", - "fileListPath": "trainingData/fileList.jsonl" - } + "knowledgeSources": [ + { + "kind": "labeledData", + "containerUrl": "https://myStorageAccount.blob.core.windows.net/myContainer", + "prefix": "trainingData", + "fileListPath": "trainingData/fileList.jsonl" + } + ] } }, "201": { "headers": { - "Operation-Location": "https://myendpoint.cognitiveservices.azure.com/contentunderstanding/analyzers/myAnalyzer/operations/3b31320d-8bab-4f88-b19c-2322a7f11034?api-version=2024-12-01-preview" + "Operation-Location": "https://myendpoint.cognitiveservices.azure.com/contentunderstanding/analyzers/myAnalyzer/operations/3b31320d-8bab-4f88-b19c-2322a7f11034?api-version=2025-11-01" }, "body": { "analyzerId": "myAnalyzer", - "description": "My custom analyzer", + "description": "My analyzer", "tags": { "createdBy": "John" }, "status": "creating", - "createdAt": "2024-10-14T18:46:36.051Z", - "lastModifiedAt": "2024-10-14T18:46:36.051Z", - "scenario": "document", + "createdAt": "2025-05-01T18:46:36.051Z", + "lastModifiedAt": "2025-05-01T18:46:36.051Z", + "baseAnalyzerId": "prebuilt-document", "config": { "locales": null, - "enableFace": false, "enableOcr": true, "enableLayout": true, - "enableBarcode": true, "enableFormula": false, "returnDetails": true }, "fieldSchema": { "name": "MyForm", - "description": "My custom form", + "description": "My form", "fields": { "Company": { "type": "string", @@ -114,12 +110,14 @@ }, "definitions": {} }, - "trainingData": { - "kind": "blob", - "containerUrl": "https://myStorageAccount.blob.core.windows.net/myContainer", - "prefix": "trainingData", - "fileListPath": "trainingData/fileList.jsonl" - } + "knowledgeSources": [ + { + "kind": "labeledData", + "containerUrl": "https://myStorageAccount.blob.core.windows.net/myContainer", + "prefix": "trainingData", + "fileListPath": "trainingData/fileList.jsonl" + } + ] } } } diff --git a/specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_DeleteAnalyzer.json b/specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_DeleteAnalyzer.json new file mode 100644 index 000000000000..9531dc990aa3 --- /dev/null +++ b/specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_DeleteAnalyzer.json @@ -0,0 +1,11 @@ +{ + "title": "Delete Analyzer", + "operationId": "ContentAnalyzers_Delete", + "parameters": { + "api-version": "2025-11-01", + "analyzerId": "myAnalyzer" + }, + "responses": { + "204": {} + } +} diff --git a/specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_DeleteResult.json b/specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_DeleteResult.json new file mode 100644 index 000000000000..eb5d9608eacb --- /dev/null +++ b/specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_DeleteResult.json @@ -0,0 +1,11 @@ +{ + "title": "Delete Analyzer Result", + "operationId": "ContentAnalyzers_DeleteResult", + "parameters": { + "api-version": "2025-11-01", + "operationId": "3b31320d-8bab-4f88-b19c-2322a7f11034" + }, + "responses": { + "204": {} + } +} diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2024-12-01-preview/examples/Analyzers_GetAnalyzer.json b/specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_GetAnalyzer.json similarity index 51% rename from specification/ai/data-plane/ContentUnderstanding/preview/2024-12-01-preview/examples/Analyzers_GetAnalyzer.json rename to specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_GetAnalyzer.json index 2f60b5c7d3cd..d12e41cc23d0 100644 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2024-12-01-preview/examples/Analyzers_GetAnalyzer.json +++ b/specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_GetAnalyzer.json @@ -1,34 +1,32 @@ { "title": "Get Analyzer", - "operationId": "Analyzers_Get", + "operationId": "ContentAnalyzers_Get", "parameters": { - "api-version": "2024-12-01-preview", + "api-version": "2025-11-01", "analyzerId": "myAnalyzer" }, "responses": { "200": { "body": { "analyzerId": "myAnalyzer", - "description": "My custom analyzer", + "description": "My analyzer", "tags": { "createdBy": "John" }, - "status": "succeeded", - "createdAt": "2024-10-14T18:46:36.051Z", - "lastModifiedAt": "2024-10-14T18:46:36.051Z", - "scenario": "document", + "status": "creating", + "createdAt": "2025-05-01T18:46:36.051Z", + "lastModifiedAt": "2025-05-01T18:46:36.051Z", + "baseAnalyzerId": "prebuilt-document", "config": { "locales": null, - "enableFace": false, "enableOcr": true, "enableLayout": true, - "enableBarcode": true, "enableFormula": false, "returnDetails": true }, "fieldSchema": { "name": "MyForm", - "description": "My custom form", + "description": "My form", "fields": { "Company": { "type": "string", @@ -37,12 +35,14 @@ }, "definitions": {} }, - "trainingData": { - "kind": "blob", - "containerUrl": "https://myStorageAccount.blob.core.windows.net/myContainer", - "prefix": "trainingData", - "fileListPath": "trainingData/fileList.jsonl" - } + "knowledgeSources": [ + { + "kind": "labeledData", + "containerUrl": "https://myStorageAccount.blob.core.windows.net/myContainer", + "prefix": "trainingData", + "fileListPath": "trainingData/fileList.jsonl" + } + ] } } } diff --git a/specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_GetDefaults.json b/specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_GetDefaults.json new file mode 100644 index 000000000000..7284181bec72 --- /dev/null +++ b/specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_GetDefaults.json @@ -0,0 +1,17 @@ +{ + "title": "Get Defaults", + "operationId": "ContentAnalyzers_GetDefaults", + "parameters": { + "api-version": "2025-11-01" + }, + "responses": { + "200": { + "body": { + "modelDeployments": { + "gpt-4.1": "myGpt41Deployment", + "text-embedding-3-large": "myTextEmbedding3LargeDeployment" + } + } + } + } +} diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2024-12-01-preview/examples/Analyzers_GetOperationStatus.json b/specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_GetOperationStatus.json similarity index 57% rename from specification/ai/data-plane/ContentUnderstanding/preview/2024-12-01-preview/examples/Analyzers_GetOperationStatus.json rename to specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_GetOperationStatus.json index 2ce94eba683c..29461a247bc1 100644 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2024-12-01-preview/examples/Analyzers_GetOperationStatus.json +++ b/specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_GetOperationStatus.json @@ -1,8 +1,8 @@ { "title": "Get Analyzer Operation Status", - "operationId": "Analyzers_GetOperationStatus", + "operationId": "ContentAnalyzers_GetOperationStatus", "parameters": { - "api-version": "2024-12-01-preview", + "api-version": "2025-11-01", "analyzerId": "myAnalyzer", "operationId": "3b31320d-8bab-4f88-b19c-2322a7f11034" }, @@ -13,26 +13,24 @@ "status": "Succeeded", "result": { "analyzerId": "myAnalyzer", - "description": "My custom analyzer", + "description": "My analyzer", "tags": { "createdBy": "John" }, - "status": "creating", - "createdAt": "2024-10-14T18:46:36.051Z", - "lastModifiedAt": "2024-10-14T18:46:36.051Z", - "scenario": "document", + "status": "ready", + "createdAt": "2025-05-01T18:46:36.051Z", + "lastModifiedAt": "2025-05-01T18:46:36.051Z", + "baseAnalyzerId": "prebuilt-document", "config": { "locales": null, - "enableFace": false, "enableOcr": true, "enableLayout": true, - "enableBarcode": true, "enableFormula": false, "returnDetails": true }, "fieldSchema": { "name": "MyForm", - "description": "My custom form", + "description": "My form", "fields": { "Company": { "type": "string", @@ -41,12 +39,14 @@ }, "definitions": {} }, - "trainingData": { - "kind": "blob", - "containerUrl": "https://myStorageAccount.blob.core.windows.net/myContainer", - "prefix": "trainingData", - "fileListPath": "trainingData/fileList.jsonl" - } + "knowledgeSources": [ + { + "kind": "labeledData", + "containerUrl": "https://myStorageAccount.blob.core.windows.net/myContainer", + "prefix": "trainingData", + "fileListPath": "trainingData/fileList.jsonl" + } + ] } } } diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2024-12-01-preview/examples/Analyzers_GetResult.json b/specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_GetResult.json similarity index 86% rename from specification/ai/data-plane/ContentUnderstanding/preview/2024-12-01-preview/examples/Analyzers_GetResult.json rename to specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_GetResult.json index c1adb42241fc..baa13ee5651c 100644 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2024-12-01-preview/examples/Analyzers_GetResult.json +++ b/specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_GetResult.json @@ -1,8 +1,8 @@ { "title": "Get Analysis Result", - "operationId": "Analyzers_GetResult", + "operationId": "ContentAnalyzers_GetResult", "parameters": { - "api-version": "2024-12-01-preview", + "api-version": "2025-11-01", "analyzerId": "myAnalyzer", "operationId": "3b31320d-8bab-4f88-b19c-2322a7f11034" }, @@ -13,11 +13,12 @@ "status": "Succeeded", "result": { "analyzerId": "myAnalyzer", - "apiVersion": "2024-12-01-preview", - "createdAt": "2024-10-14T18:46:36.244Z", + "apiVersion": "2025-11-01", + "createdAt": "2025-05-01T18:46:36.244Z", "contents": [ { "kind": "document", + "mimeType": "application/pdf", "markdown": "# CONTOSO\n\n...", "startPageNumber": 1, "endPageNumber": 2, diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2024-12-01-preview/examples/Analyzers_GetResultImage.json b/specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_GetResultFile.json similarity index 54% rename from specification/ai/data-plane/ContentUnderstanding/preview/2024-12-01-preview/examples/Analyzers_GetResultImage.json rename to specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_GetResultFile.json index e92a07d719c0..583f8af7abce 100644 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2024-12-01-preview/examples/Analyzers_GetResultImage.json +++ b/specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_GetResultFile.json @@ -1,11 +1,11 @@ { - "title": "Get Analysis Result Image", - "operationId": "Analyzers_GetResultImage", + "title": "Get Analysis Result File", + "operationId": "ContentAnalyzers_GetResultFile", "parameters": { - "api-version": "2024-12-01-preview", + "api-version": "2025-11-01", "analyzerId": "myAnalyzer", "operationId": "3b31320d-8bab-4f88-b19c-2322a7f11034", - "imageId": "figure-1.1" + "path": "figure-1.1" }, "responses": { "200": { diff --git a/specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_GrantCopyAuthorization.json b/specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_GrantCopyAuthorization.json new file mode 100644 index 000000000000..cc784acb03a4 --- /dev/null +++ b/specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_GrantCopyAuthorization.json @@ -0,0 +1,21 @@ +{ + "title": "Grant Copy Authorization", + "operationId": "ContentAnalyzers_GrantCopyAuthorization", + "parameters": { + "api-version": "2025-11-01", + "analyzerId": "sourceAnalyzer", + "body": { + "targetAzureResourceId": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.CognitiveServices/accounts/myResource", + "targetRegion": "westus2" + } + }, + "responses": { + "200": { + "body": { + "source": "https://myendpoint.cognitiveservices.azure.com/contentunderstanding/analyzers/sourceAnalyzer", + "targetAzureResourceId": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.CognitiveServices/accounts/myResource", + "expiresAt": "2025-12-01T18:46:36.051Z" + } + } + } +} diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2024-12-01-preview/examples/Analyzers_List.json b/specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_List.json similarity index 58% rename from specification/ai/data-plane/ContentUnderstanding/preview/2024-12-01-preview/examples/Analyzers_List.json rename to specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_List.json index aeaadb0e725b..8aa7bf8cbe99 100644 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2024-12-01-preview/examples/Analyzers_List.json +++ b/specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_List.json @@ -1,9 +1,8 @@ { "title": "List Analyzers", - "operationId": "Analyzers_List", + "operationId": "ContentAnalyzers_List", "parameters": { - "api-version": "2024-12-01-preview", - "filter": "tags.createdBy eq 'John'" + "api-version": "2025-11-01" }, "responses": { "200": { @@ -11,26 +10,24 @@ "value": [ { "analyzerId": "myAnalyzer", - "description": "My custom analyzer", + "description": "My analyzer", "tags": { "createdBy": "John" }, - "status": "succeeded", - "createdAt": "2024-10-14T18:46:36.051Z", - "lastModifiedAt": "2024-10-14T18:46:36.051Z", - "scenario": "document", + "status": "ready", + "createdAt": "2025-05-01T18:46:36.051Z", + "lastModifiedAt": "2025-05-01T18:46:36.051Z", + "baseAnalyzerId": "prebuilt-document", "config": { "locales": null, - "enableFace": false, "enableOcr": true, "enableLayout": true, - "enableBarcode": true, "enableFormula": false, "returnDetails": true }, "fieldSchema": { "name": "MyForm", - "description": "My custom form", + "description": "My form", "fields": { "Company": { "type": "string", @@ -39,35 +36,35 @@ }, "definitions": {} }, - "trainingData": { - "kind": "blob", - "containerUrl": "https://myStorageAccount.blob.core.windows.net/myContainer", - "prefix": "trainingData", - "fileListPath": "trainingData/fileList.jsonl" - } + "knowledgeSources": [ + { + "kind": "labeledData", + "containerUrl": "https://myStorageAccount.blob.core.windows.net/myContainer", + "prefix": "trainingData", + "fileListPath": "trainingData/fileList.jsonl" + } + ] }, { "analyzerId": "myAnalyzer2", - "description": "My custom analyzer 2", + "description": "My analyzer 2", "tags": { "createdBy": "John" }, - "status": "running", - "createdAt": "2024-10-14T18:46:36.051Z", - "lastModifiedAt": "2024-10-14T18:46:36.051Z", - "scenario": "image", + "status": "creating", + "createdAt": "2025-05-01T18:46:36.051Z", + "lastModifiedAt": "2025-05-01T18:46:36.051Z", + "baseAnalyzerId": "prebuilt-imageAnalyzer", "config": { "locales": null, - "enableFace": false, "enableOcr": true, "enableLayout": true, - "enableBarcode": true, "enableFormula": false, "returnDetails": true }, "fieldSchema": { "name": "MyImage", - "description": "My custom image", + "description": "My image", "fields": { "Logo": { "type": "string", @@ -78,7 +75,7 @@ } } ], - "nextLink": "https://myendpoint.cognitiveservices.azure.com/contentunderstanding/analyzers?nextLink=nextLinkData&api-version=2024-12-01-preview" + "nextLink": "https://myendpoint.cognitiveservices.azure.com/contentunderstanding/analyzers?nextLink=nextLinkData&api-version=2025-11-01" } } } diff --git a/specification/ai/data-plane/ContentUnderstanding/preview/2024-12-01-preview/examples/Analyzers_Update.json b/specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_Update.json similarity index 62% rename from specification/ai/data-plane/ContentUnderstanding/preview/2024-12-01-preview/examples/Analyzers_Update.json rename to specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_Update.json index 3ffe3600e35e..22e952b3e2f2 100644 --- a/specification/ai/data-plane/ContentUnderstanding/preview/2024-12-01-preview/examples/Analyzers_Update.json +++ b/specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_Update.json @@ -1,8 +1,8 @@ { "title": "Update Analyzer", - "operationId": "Analyzers_Update", + "operationId": "ContentAnalyzers_Update", "parameters": { - "api-version": "2024-12-01-preview", + "api-version": "2025-11-01", "analyzerId": "myAnalyzer", "resource": { "description": "Updated analyzer description.", @@ -21,21 +21,19 @@ "reviewedBy": "Paul" }, "status": "succeeded", - "createdAt": "2024-10-14T18:46:36.051Z", - "lastModifiedAt": "2024-10-14T18:46:36.051Z", - "scenario": "document", + "createdAt": "2025-05-01T18:46:36.051Z", + "lastModifiedAt": "2025-05-01T18:46:36.051Z", + "baseAnalyzerId": "prebuilt-document", "config": { "locales": null, - "enableFace": false, "enableOcr": true, "enableLayout": true, - "enableBarcode": true, "enableFormula": false, "returnDetails": true }, "fieldSchema": { "name": "MyForm", - "description": "My custom form", + "description": "My form", "fields": { "Company": { "type": "string", @@ -44,12 +42,14 @@ }, "definitions": {} }, - "trainingData": { - "kind": "blob", - "containerUrl": "https://myStorageAccount.blob.core.windows.net/myContainer", - "prefix": "trainingData", - "fileListPath": "trainingData/fileList.jsonl" - } + "knowledgeSources": [ + { + "kind": "labeledData", + "containerUrl": "https://myStorageAccount.blob.core.windows.net/myContainer", + "prefix": "trainingData", + "fileListPath": "trainingData/fileList.jsonl" + } + ] } } } diff --git a/specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_UpdateDefaults.json b/specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_UpdateDefaults.json new file mode 100644 index 000000000000..866e47085042 --- /dev/null +++ b/specification/ai/data-plane/ContentUnderstanding/stable/2025-11-01/examples/ContentAnalyzers_UpdateDefaults.json @@ -0,0 +1,22 @@ +{ + "title": "Update Defaults", + "operationId": "ContentAnalyzers_UpdateDefaults", + "parameters": { + "api-version": "2025-11-01", + "body": { + "modelDeployments": { + "gpt-4.1": "newGpt41Deployment" + } + } + }, + "responses": { + "200": { + "body": { + "modelDeployments": { + "gpt-4.1": "newGpt41Deployment", + "text-embedding-3-large": "myTextEmbedding3LargeDeployment" + } + } + } + } +}