diff --git a/dev/cognitiveservices/data-plane/Language/analyzetext.json b/dev/cognitiveservices/data-plane/Language/analyzetext.json index 55414aef6cee..430b85f28f0b 100644 --- a/dev/cognitiveservices/data-plane/Language/analyzetext.json +++ b/dev/cognitiveservices/data-plane/Language/analyzetext.json @@ -545,29 +545,6 @@ } ] }, - "PreBuiltResult": { - "type": "object", - "properties": { - "errors": { - "type": "array", - "description": "Errors by document id.", - "items": { - "$ref": "#/definitions/DocumentError" - } - }, - "statistics": { - "$ref": "#/definitions/RequestStatistics" - }, - "modelVersion": { - "type": "string", - "description": "This field indicates which model is used for scoring." - } - }, - "required": [ - "errors", - "modelVersion" - ] - }, "CustomTaskParameters": { "type": "object", "description": "Parameters object for a text analysis task using custom models.", @@ -598,11 +575,11 @@ "type": "array", "description": "Errors by document id.", "items": { - "$ref": "#/definitions/DocumentError" + "$ref": "common.json#/definitions/DocumentError" } }, "statistics": { - "$ref": "#/definitions/RequestStatistics" + "$ref": "common.json#/definitions/RequestStatistics" }, "projectName": { "type": "string", @@ -825,7 +802,7 @@ }, "allOf": [ { - "$ref": "#/definitions/PreBuiltResult" + "$ref": "common.json#/definitions/PreBuiltResult" } ], "required": [ @@ -1168,7 +1145,7 @@ }, "allOf": [ { - "$ref": "#/definitions/PreBuiltResult" + "$ref": "common.json#/definitions/PreBuiltResult" } ], "required": [ @@ -1505,7 +1482,7 @@ }, "allOf": [ { - "$ref": "#/definitions/PreBuiltResult" + "$ref": "common.json#/definitions/PreBuiltResult" } ], "required": [ @@ -1634,7 +1611,7 @@ }, "allOf": [ { - "$ref": "#/definitions/PreBuiltResult" + "$ref": "common.json#/definitions/PreBuiltResult" } ], "required": [ @@ -1803,7 +1780,7 @@ }, "allOf": [ { - "$ref": "#/definitions/PreBuiltResult" + "$ref": "common.json#/definitions/PreBuiltResult" } ], "required": [ @@ -2247,7 +2224,7 @@ }, "allOf": [ { - "$ref": "#/definitions/PreBuiltResult" + "$ref": "common.json#/definitions/PreBuiltResult" } ], "required": [ @@ -2313,7 +2290,7 @@ }, "allOf": [ { - "$ref": "#/definitions/PreBuiltResult" + "$ref": "common.json#/definitions/PreBuiltResult" } ], "required": [ @@ -2395,7 +2372,7 @@ "AnalyzeTextJobStatistics": { "properties": { "statistics": { - "$ref": "#/definitions/RequestStatistics" + "$ref": "common.json#/definitions/RequestStatistics" } }, "type": "object" @@ -2692,24 +2669,6 @@ } } }, - "DocumentError": { - "type": "object", - "required": [ - "id", - "error" - ], - "properties": { - "id": { - "type": "string", - "description": "Document Id." - }, - "error": { - "type": "object", - "description": "Document Error.", - "$ref": "common.json#/definitions/Error" - } - } - }, "DocumentWarning": { "type": "object", "required": [ @@ -2759,38 +2718,6 @@ }, "description": "if showStats=true was specified in the request this field will contain information about the document payload." }, - "RequestStatistics": { - "type": "object", - "required": [ - "documentsCount", - "validDocumentsCount", - "erroneousDocumentsCount", - "transactionsCount" - ], - "properties": { - "documentsCount": { - "type": "integer", - "format": "int32", - "description": "Number of documents submitted in the request." - }, - "validDocumentsCount": { - "type": "integer", - "format": "int32", - "description": "Number of valid documents. This excludes empty, over-size limit or non-supported languages documents." - }, - "erroneousDocumentsCount": { - "type": "integer", - "format": "int32", - "description": "Number of invalid documents. This includes empty, over-size limit or non-supported languages documents." - }, - "transactionsCount": { - "type": "integer", - "format": "int64", - "description": "Number of transactions for the request." - } - }, - "description": "if showStats=true was specified in the request this field will contain information about the request payload." - }, "MultiLanguageInput": { "type": "object", "description": "Contains an input document to be analyzed by the service.", diff --git a/dev/cognitiveservices/data-plane/Language/common.json b/dev/cognitiveservices/data-plane/Language/common.json index b6cab8b6107f..7f583cdb4d14 100644 --- a/dev/cognitiveservices/data-plane/Language/common.json +++ b/dev/cognitiveservices/data-plane/Language/common.json @@ -301,7 +301,7 @@ }, "type": "object" }, - "InputError": { + "DocumentError": { "type": "object", "description": "Contains details of errors encountered during a job execution.", "required": [ @@ -311,7 +311,7 @@ "properties": { "id": { "type": "string", - "description": "The ID of the input." + "description": "The ID of the input document." }, "error": { "type": "object", @@ -372,16 +372,16 @@ "description": "Number of transactions for the request." } }, - "additionalProperties": true, "description": "if showStats=true was specified in the request this field will contain information about the request payload." }, "PreBuiltResult": { + "type": "object", "properties": { "errors": { "type": "array", "description": "Errors by document id.", "items": { - "$ref": "#/definitions/InputError" + "$ref": "#/definitions/DocumentError" } }, "statistics": { diff --git a/specification/cognitiveservices/data-plane/Language/stable/2023-04-01/analyzetext.json b/specification/cognitiveservices/data-plane/Language/stable/2023-04-01/analyzetext.json index 55414aef6cee..430b85f28f0b 100644 --- a/specification/cognitiveservices/data-plane/Language/stable/2023-04-01/analyzetext.json +++ b/specification/cognitiveservices/data-plane/Language/stable/2023-04-01/analyzetext.json @@ -545,29 +545,6 @@ } ] }, - "PreBuiltResult": { - "type": "object", - "properties": { - "errors": { - "type": "array", - "description": "Errors by document id.", - "items": { - "$ref": "#/definitions/DocumentError" - } - }, - "statistics": { - "$ref": "#/definitions/RequestStatistics" - }, - "modelVersion": { - "type": "string", - "description": "This field indicates which model is used for scoring." - } - }, - "required": [ - "errors", - "modelVersion" - ] - }, "CustomTaskParameters": { "type": "object", "description": "Parameters object for a text analysis task using custom models.", @@ -598,11 +575,11 @@ "type": "array", "description": "Errors by document id.", "items": { - "$ref": "#/definitions/DocumentError" + "$ref": "common.json#/definitions/DocumentError" } }, "statistics": { - "$ref": "#/definitions/RequestStatistics" + "$ref": "common.json#/definitions/RequestStatistics" }, "projectName": { "type": "string", @@ -825,7 +802,7 @@ }, "allOf": [ { - "$ref": "#/definitions/PreBuiltResult" + "$ref": "common.json#/definitions/PreBuiltResult" } ], "required": [ @@ -1168,7 +1145,7 @@ }, "allOf": [ { - "$ref": "#/definitions/PreBuiltResult" + "$ref": "common.json#/definitions/PreBuiltResult" } ], "required": [ @@ -1505,7 +1482,7 @@ }, "allOf": [ { - "$ref": "#/definitions/PreBuiltResult" + "$ref": "common.json#/definitions/PreBuiltResult" } ], "required": [ @@ -1634,7 +1611,7 @@ }, "allOf": [ { - "$ref": "#/definitions/PreBuiltResult" + "$ref": "common.json#/definitions/PreBuiltResult" } ], "required": [ @@ -1803,7 +1780,7 @@ }, "allOf": [ { - "$ref": "#/definitions/PreBuiltResult" + "$ref": "common.json#/definitions/PreBuiltResult" } ], "required": [ @@ -2247,7 +2224,7 @@ }, "allOf": [ { - "$ref": "#/definitions/PreBuiltResult" + "$ref": "common.json#/definitions/PreBuiltResult" } ], "required": [ @@ -2313,7 +2290,7 @@ }, "allOf": [ { - "$ref": "#/definitions/PreBuiltResult" + "$ref": "common.json#/definitions/PreBuiltResult" } ], "required": [ @@ -2395,7 +2372,7 @@ "AnalyzeTextJobStatistics": { "properties": { "statistics": { - "$ref": "#/definitions/RequestStatistics" + "$ref": "common.json#/definitions/RequestStatistics" } }, "type": "object" @@ -2692,24 +2669,6 @@ } } }, - "DocumentError": { - "type": "object", - "required": [ - "id", - "error" - ], - "properties": { - "id": { - "type": "string", - "description": "Document Id." - }, - "error": { - "type": "object", - "description": "Document Error.", - "$ref": "common.json#/definitions/Error" - } - } - }, "DocumentWarning": { "type": "object", "required": [ @@ -2759,38 +2718,6 @@ }, "description": "if showStats=true was specified in the request this field will contain information about the document payload." }, - "RequestStatistics": { - "type": "object", - "required": [ - "documentsCount", - "validDocumentsCount", - "erroneousDocumentsCount", - "transactionsCount" - ], - "properties": { - "documentsCount": { - "type": "integer", - "format": "int32", - "description": "Number of documents submitted in the request." - }, - "validDocumentsCount": { - "type": "integer", - "format": "int32", - "description": "Number of valid documents. This excludes empty, over-size limit or non-supported languages documents." - }, - "erroneousDocumentsCount": { - "type": "integer", - "format": "int32", - "description": "Number of invalid documents. This includes empty, over-size limit or non-supported languages documents." - }, - "transactionsCount": { - "type": "integer", - "format": "int64", - "description": "Number of transactions for the request." - } - }, - "description": "if showStats=true was specified in the request this field will contain information about the request payload." - }, "MultiLanguageInput": { "type": "object", "description": "Contains an input document to be analyzed by the service.", diff --git a/specification/cognitiveservices/data-plane/Language/stable/2023-04-01/common.json b/specification/cognitiveservices/data-plane/Language/stable/2023-04-01/common.json index b6cab8b6107f..7f583cdb4d14 100644 --- a/specification/cognitiveservices/data-plane/Language/stable/2023-04-01/common.json +++ b/specification/cognitiveservices/data-plane/Language/stable/2023-04-01/common.json @@ -301,7 +301,7 @@ }, "type": "object" }, - "InputError": { + "DocumentError": { "type": "object", "description": "Contains details of errors encountered during a job execution.", "required": [ @@ -311,7 +311,7 @@ "properties": { "id": { "type": "string", - "description": "The ID of the input." + "description": "The ID of the input document." }, "error": { "type": "object", @@ -372,16 +372,16 @@ "description": "Number of transactions for the request." } }, - "additionalProperties": true, "description": "if showStats=true was specified in the request this field will contain information about the request payload." }, "PreBuiltResult": { + "type": "object", "properties": { "errors": { "type": "array", "description": "Errors by document id.", "items": { - "$ref": "#/definitions/InputError" + "$ref": "#/definitions/DocumentError" } }, "statistics": {