diff --git a/specification/cognitiveservices/data-plane/TextAnalytics/preview/v2.1/TextAnalytics.json b/specification/cognitiveservices/data-plane/TextAnalytics/preview/v2.1/TextAnalytics.json
index b5b5b3c7b662..34c7948655ea 100644
--- a/specification/cognitiveservices/data-plane/TextAnalytics/preview/v2.1/TextAnalytics.json
+++ b/specification/cognitiveservices/data-plane/TextAnalytics/preview/v2.1/TextAnalytics.json
@@ -595,4 +595,4 @@
"x-ms-skip-url-encoding": true
}
}
-}
+}
\ No newline at end of file
diff --git a/specification/cognitiveservices/data-plane/TextAnalytics/readme.md b/specification/cognitiveservices/data-plane/TextAnalytics/readme.md
index 13bb690d2276..046fce5e9b6c 100644
--- a/specification/cognitiveservices/data-plane/TextAnalytics/readme.md
+++ b/specification/cognitiveservices/data-plane/TextAnalytics/readme.md
@@ -118,7 +118,7 @@ The current release is `release_2_0`.
A preview release `release_2_1` is also available.
``` yaml
-tag: release_2_0
+tag: release_2_1
add-credentials: true
```
@@ -131,11 +131,20 @@ input-file: stable/v2.0/TextAnalytics.json
log-file: logs/log.txt
```
-### Release 2.1-Preview
+### Release 2.1
These settings apply only when `--tag=release_2_1` is specified on the command line.
``` yaml $(tag) == 'release_2_1'
+input-file: stable/v2.1/TextAnalytics.json
+log-file: logs/log.txt
+```
+
+### Release 2.1-Preview
+
+These settings apply only when `--tag=release_2_1_preview` is specified on the command line.
+
+``` yaml $(tag) == 'release_2_1_preview'
input-file: preview/v2.1/TextAnalytics.json
log-file: logs/log.txt
```
diff --git a/specification/cognitiveservices/data-plane/TextAnalytics/stable/v2.1/TextAnalytics.json b/specification/cognitiveservices/data-plane/TextAnalytics/stable/v2.1/TextAnalytics.json
new file mode 100644
index 000000000000..6f399f0d2990
--- /dev/null
+++ b/specification/cognitiveservices/data-plane/TextAnalytics/stable/v2.1/TextAnalytics.json
@@ -0,0 +1,716 @@
+{
+ "swagger": "2.0",
+ "info": {
+ "version": "v2.1",
+ "contact": {
+ "name": "Microsoft Cognitive Services",
+ "url": "https://azure.microsoft.com/en-us/services/cognitive-services/text-analytics/",
+ "email": "mlapi@microsoft.com"
+ },
+ "title": "Text Analytics Client",
+ "description": "The Text Analytics API is a suite of text analytics web services built with best-in-class Microsoft machine learning algorithms. The API can be used to analyze unstructured text for tasks such as sentiment analysis, key phrase extraction and language detection. No training data is needed to use this API; just bring your text data. This API uses advanced natural language processing techniques to deliver best in class predictions. Further documentation can be found in https://docs.microsoft.com/en-us/azure/cognitive-services/text-analytics/overview"
+ },
+ "securityDefinitions": {
+ "apim_key": {
+ "type": "apiKey",
+ "name": "Ocp-Apim-Subscription-Key",
+ "in": "header"
+ }
+ },
+ "security": [
+ {
+ "apim_key": []
+ }
+ ],
+ "x-ms-parameterized-host": {
+ "hostTemplate": "{Endpoint}/text/analytics/v2.1",
+ "useSchemePrefix": false,
+ "parameters": [
+ {
+ "$ref": "#/parameters/Endpoint"
+ }
+ ]
+ },
+ "paths": {
+ "/languages": {
+ "post": {
+ "tags": [
+ "Detect Language"
+ ],
+ "description": "Scores close to 1 indicate 100% certainty that the identified language is true. A total of 120 languages are supported.",
+ "operationId": "Detect Language",
+ "summary": "The API returns the detected language and a numeric score between 0 and 1.",
+ "parameters": [
+ {
+ "name": "showStats",
+ "in": "query",
+ "description": "(optional) if set to true, response will contain input and document level statistics.",
+ "type": "boolean"
+ },
+ {
+ "name": "languageBatchInput",
+ "in": "body",
+ "schema": {
+ "$ref": "#/definitions/LanguageBatchInput"
+ },
+ "description": "Collection of documents to analyze."
+ }
+ ],
+ "consumes": [
+ "application/json",
+ "text/json"
+ ],
+ "responses": {
+ "200": {
+ "description": "A successful call results in the detected language with the highest probability for each valid document",
+ "schema": {
+ "$ref": "#/definitions/LanguageBatchResult"
+ }
+ },
+ "default": {
+ "description": "Error Response",
+ "schema": {
+ "$ref": "#/definitions/ErrorResponse"
+ }
+ }
+ },
+ "x-ms-examples": {
+ "Successful Detect Language request": {
+ "$ref": ".//examples//SuccessfulLanguagesRequest.json"
+ }
+ },
+ "deprecated": false,
+ "produces": [
+ "application/json",
+ "text/json"
+ ]
+ }
+ },
+ "/entities": {
+ "post": {
+ "tags": [
+ "Entities"
+ ],
+ "description": "To get even more information on each recognized entity we recommend using the Bing Entity Search API by querying for the recognized entities names. See the Supported languages in Text Analytics API for the list of enabled languages.",
+ "operationId": "Entities",
+ "summary": "The API returns a list of recognized entities in a given document.",
+ "parameters": [
+ {
+ "name": "showStats",
+ "in": "query",
+ "description": "(optional) if set to true, response will contain input and document level statistics.",
+ "type": "boolean"
+ },
+ {
+ "name": "multiLanguageBatchInput",
+ "in": "body",
+ "schema": {
+ "$ref": "#/definitions/MultiLanguageBatchInput"
+ },
+ "description": "Collection of documents to analyze."
+ }
+ ],
+ "consumes": [
+ "application/json",
+ "text/json"
+ ],
+ "responses": {
+ "200": {
+ "description": "A successful call results in a list of recognized entities returned for each valid document",
+ "schema": {
+ "$ref": "#/definitions/EntitiesBatchResult"
+ }
+ },
+ "default": {
+ "description": "Error Response",
+ "schema": {
+ "$ref": "#/definitions/ErrorResponse"
+ }
+ }
+ },
+ "x-ms-examples": {
+ "Successful Detect Language request": {
+ "$ref": ".//examples//SuccessfulEntitiesRequest.json"
+ }
+ },
+ "deprecated": false,
+ "produces": [
+ "application/json",
+ "text/json"
+ ]
+ }
+ },
+ "/keyPhrases": {
+ "post": {
+ "tags": [
+ "Key Phrases"
+ ],
+ "description": "See the Text Analytics Documentation for details about the languages that are supported by key phrase extraction.",
+ "operationId": "Key Phrases",
+ "summary": "The API returns a list of strings denoting the key talking points in the input text.",
+ "parameters": [
+ {
+ "name": "showStats",
+ "in": "query",
+ "description": "(optional) if set to true, response will contain input and document level statistics.",
+ "type": "boolean"
+ },
+ {
+ "name": "multiLanguageBatchInput",
+ "in": "body",
+ "schema": {
+ "$ref": "#/definitions/MultiLanguageBatchInput"
+ },
+ "description": "Collection of documents to analyze. Documents can now contain a language field to indicate the text language"
+ }
+ ],
+ "consumes": [
+ "application/json",
+ "text/json"
+ ],
+ "responses": {
+ "200": {
+ "description": "A successful response results in 0 or more key phrases identified in each valid document",
+ "schema": {
+ "$ref": "#/definitions/KeyPhraseBatchResult"
+ }
+ },
+ "default": {
+ "description": "Error Response",
+ "schema": {
+ "$ref": "#/definitions/ErrorResponse"
+ }
+ }
+ },
+ "x-ms-examples": {
+ "Successful Detect Language request": {
+ "$ref": ".//examples//SuccessfulKeyPhrasesRequest.json"
+ }
+ },
+ "deprecated": false,
+ "produces": [
+ "application/json",
+ "text/json"
+ ]
+ }
+ },
+ "/sentiment": {
+ "post": {
+ "tags": [
+ "Sentiment"
+ ],
+ "description": "Scores close to 1 indicate positive sentiment, while scores close to 0 indicate negative sentiment. A score of 0.5 indicates the lack of sentiment (e.g. a factoid statement). See the Text Analytics Documentation for details about the languages that are supported by sentiment analysis.",
+ "operationId": "Sentiment",
+ "summary": "The API returns a numeric score between 0 and 1.",
+ "parameters": [
+ {
+ "name": "showStats",
+ "in": "query",
+ "description": "(optional) if set to true, response will contain input and document level statistics.",
+ "type": "boolean"
+ },
+ {
+ "name": "multiLanguageBatchInput",
+ "in": "body",
+ "schema": {
+ "$ref": "#/definitions/MultiLanguageBatchInput"
+ },
+ "description": "Collection of documents to analyze."
+ }
+ ],
+ "consumes": [
+ "application/json",
+ "text/json"
+ ],
+ "responses": {
+ "200": {
+ "description": "A successful call results in each valid document getting a sentiment score between 0 and 1",
+ "schema": {
+ "$ref": "#/definitions/SentimentBatchResult"
+ }
+ },
+ "500": {
+ "description": "Error Response",
+ "schema": {
+ "$ref": "#/definitions/ErrorResponse"
+ }
+ }
+ },
+ "x-ms-examples": {
+ "Successful Detect Language request": {
+ "$ref": ".//examples//SuccessfulSentimentRequest.json"
+ }
+ },
+ "deprecated": false,
+ "produces": [
+ "application/json",
+ "text/json"
+ ]
+ }
+ }
+ },
+ "definitions": {
+ "MultiLanguageBatchInput": {
+ "type": "object",
+ "properties": {
+ "documents": {
+ "type": "array",
+ "items": {
+ "$ref": "#/definitions/MultiLanguageInput"
+ }
+ }
+ },
+ "example": {
+ "documents": [
+ {
+ "language": "en",
+ "id": "1",
+ "text": "Hello world. This is some input text that I love."
+ },
+ {
+ "language": "fr",
+ "id": "2",
+ "text": "Bonjour tout le monde"
+ },
+ {
+ "language": "es",
+ "id": "3",
+ "text": "La carretera estaba atascada. Había mucho tráfico el día de ayer."
+ }
+ ]
+ }
+ },
+ "MultiLanguageInput": {
+ "type": "object",
+ "properties": {
+ "language": {
+ "description": "This is the 2 letter ISO 639-1 representation of a language. For example, use \"en\" for English; \"es\" for Spanish etc.,",
+ "type": "string"
+ },
+ "id": {
+ "description": "Unique, non-empty document identifier.",
+ "type": "string"
+ },
+ "text": {
+ "type": "string"
+ }
+ }
+ },
+ "Object": {
+ "type": "object",
+ "properties": {}
+ },
+ "EntitiesBatchResult": {
+ "type": "object",
+ "properties": {
+ "documents": {
+ "description": "Response by document",
+ "type": "array",
+ "items": {
+ "$ref": "#/definitions/EntitiesBatchResultItem"
+ },
+ "readOnly": true
+ },
+ "errors": {
+ "description": "Errors and Warnings by document",
+ "type": "array",
+ "items": {
+ "$ref": "#/definitions/ErrorRecord"
+ },
+ "readOnly": true
+ },
+ "statistics": {
+ "$ref": "#/definitions/RequestStatistics",
+ "description": "(Optional) if showStats=true was specified in the request this field will contain information about the request payload.",
+ "readOnly": true
+ }
+ }
+ },
+ "EntitiesBatchResultItem": {
+ "type": "object",
+ "properties": {
+ "id": {
+ "description": "Unique, non-empty document identifier.",
+ "type": "string"
+ },
+ "entities": {
+ "description": "Recognized entities in the document.",
+ "type": "array",
+ "items": {
+ "$ref": "#/definitions/EntityRecord"
+ },
+ "readOnly": true
+ },
+ "statistics": {
+ "$ref": "#/definitions/DocumentStatistics",
+ "description": "(Optional) if showStats=true was specified in the request this field will contain information about the document payload."
+ }
+ }
+ },
+ "ErrorRecord": {
+ "type": "object",
+ "properties": {
+ "id": {
+ "description": "Input document unique identifier the error refers to.",
+ "type": "string"
+ },
+ "message": {
+ "description": "Error message.",
+ "type": "string"
+ }
+ }
+ },
+ "RequestStatistics": {
+ "type": "object",
+ "properties": {
+ "documentsCount": {
+ "format": "int32",
+ "description": "Number of documents submitted in the request.",
+ "type": "integer"
+ },
+ "validDocumentsCount": {
+ "format": "int32",
+ "description": "Number of valid documents. This excludes empty, over-size limit or non-supported languages documents.",
+ "type": "integer"
+ },
+ "erroneousDocumentsCount": {
+ "format": "int32",
+ "description": "Number of invalid documents. This includes empty, over-size limit or non-supported languages documents.",
+ "type": "integer"
+ },
+ "transactionsCount": {
+ "format": "int64",
+ "description": "Number of transactions for the request.",
+ "type": "integer"
+ }
+ }
+ },
+ "EntityRecord": {
+ "type": "object",
+ "properties": {
+ "name": {
+ "description": "Entity formal name.",
+ "type": "string"
+ },
+ "matches": {
+ "description": "List of instances this entity appears in the text.",
+ "type": "array",
+ "items": {
+ "$ref": "#/definitions/MatchRecord"
+ }
+ },
+ "wikipediaLanguage": {
+ "description": "Wikipedia language for which the WikipediaId and WikipediaUrl refers to.",
+ "type": "string"
+ },
+ "wikipediaId": {
+ "description": "Wikipedia unique identifier of the recognized entity.",
+ "type": "string"
+ },
+ "wikipediaUrl": {
+ "description": "URL for the entity's Wikipedia page.",
+ "type": "string",
+ "readOnly": true
+ },
+ "bingId": {
+ "description": "Bing unique identifier of the recognized entity. Use in conjunction with the Bing Entity Search API to fetch additional relevant information.",
+ "type": "string"
+ },
+ "type": {
+ "description": "Entity type from Named Entity Recognition model",
+ "type": "string"
+ },
+ "subType": {
+ "description": "Entity sub type from Named Entity Recognition model",
+ "type": "string"
+ }
+ }
+ },
+ "DocumentStatistics": {
+ "type": "object",
+ "properties": {
+ "charactersCount": {
+ "format": "int32",
+ "description": "Number of text elements recognized in the document.",
+ "type": "integer"
+ },
+ "transactionsCount": {
+ "format": "int32",
+ "description": "Number of transactions for the document.",
+ "type": "integer"
+ }
+ }
+ },
+ "MatchRecord": {
+ "type": "object",
+ "properties": {
+ "wikipediaScore": {
+ "format": "double",
+ "description": "(optional) If a well-known item with Wikipedia link is recognized, a decimal number denoting the confidence level of the Wikipedia info will be returned.",
+ "type": "number"
+ },
+ "entityTypeScore": {
+ "format": "double",
+ "description": "(optional) If an entity type is recognized, a decimal number denoting the confidence level of the entity type will be returned.",
+ "type": "number"
+ },
+ "text": {
+ "description": "Entity text as appears in the request.",
+ "type": "string"
+ },
+ "offset": {
+ "format": "int32",
+ "description": "Start position (in Unicode characters) for the entity match text.",
+ "type": "integer"
+ },
+ "length": {
+ "format": "int32",
+ "description": "Length (in Unicode characters) for the entity match text.",
+ "type": "integer"
+ }
+ }
+ },
+ "ErrorResponse": {
+ "type": "object",
+ "properties": {
+ "code": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "target": {
+ "type": "string"
+ },
+ "innerError": {
+ "$ref": "#/definitions/InternalError"
+ }
+ }
+ },
+ "InternalError": {
+ "type": "object",
+ "properties": {
+ "code": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "innerError": {
+ "$ref": "#/definitions/InternalError"
+ }
+ }
+ },
+ "KeyPhraseBatchResult": {
+ "type": "object",
+ "properties": {
+ "documents": {
+ "description": "Response by document",
+ "type": "array",
+ "items": {
+ "$ref": "#/definitions/KeyPhraseBatchResultItem"
+ },
+ "readOnly": true
+ },
+ "errors": {
+ "description": "Errors and Warnings by document",
+ "type": "array",
+ "items": {
+ "$ref": "#/definitions/ErrorRecord"
+ },
+ "readOnly": true
+ },
+ "statistics": {
+ "$ref": "#/definitions/RequestStatistics",
+ "description": "=(Optional) if showStats=true was specified in the request this field will contain information about the request payload.",
+ "readOnly": true
+ }
+ }
+ },
+ "KeyPhraseBatchResultItem": {
+ "type": "object",
+ "properties": {
+ "id": {
+ "description": "Unique, non-empty document identifier.",
+ "type": "string"
+ },
+ "keyPhrases": {
+ "description": "A list of representative words or phrases. The number of key phrases returned is proportional to the number of words in the input document.",
+ "type": "array",
+ "items": {
+ "type": "string"
+ },
+ "readOnly": true
+ },
+ "statistics": {
+ "$ref": "#/definitions/DocumentStatistics",
+ "description": "(Optional) if showStats=true was specified in the request this field will contain information about the document payload."
+ }
+ }
+ },
+ "LanguageBatchInput": {
+ "type": "object",
+ "properties": {
+ "documents": {
+ "type": "array",
+ "items": {
+ "$ref": "#/definitions/LanguageInput"
+ }
+ }
+ },
+ "example": {
+ "documents": [
+ {
+ "countryHint": "en",
+ "id": "1",
+ "text": "Hello world. This is some input text that I love."
+ },
+ {
+ "countryHint": "fr",
+ "id": "2",
+ "text": "Bonjour tout le monde"
+ },
+ {
+ "countryHint": "es",
+ "id": "3",
+ "text": "La carretera estaba atascada. Había mucho tráfico el día de ayer."
+ }
+ ]
+ }
+ },
+ "LanguageInput": {
+ "type": "object",
+ "properties": {
+ "countryHint": {
+ "type": "string"
+ },
+ "id": {
+ "description": "Unique, non-empty document identifier.",
+ "type": "string"
+ },
+ "text": {
+ "type": "string"
+ }
+ }
+ },
+ "LanguageBatchResult": {
+ "type": "object",
+ "properties": {
+ "documents": {
+ "description": "Response by document",
+ "type": "array",
+ "items": {
+ "$ref": "#/definitions/LanguageBatchResultItem"
+ },
+ "readOnly": true
+ },
+ "errors": {
+ "description": "Errors and Warnings by document",
+ "type": "array",
+ "items": {
+ "$ref": "#/definitions/ErrorRecord"
+ },
+ "readOnly": true
+ },
+ "statistics": {
+ "$ref": "#/definitions/RequestStatistics",
+ "description": "(Optional) if showStats=true was specified in the request this field will contain information about the request payload.",
+ "readOnly": true
+ }
+ }
+ },
+ "LanguageBatchResultItem": {
+ "type": "object",
+ "properties": {
+ "id": {
+ "description": "Unique, non-empty document identifier.",
+ "type": "string"
+ },
+ "detectedLanguages": {
+ "description": "A list of extracted languages.",
+ "type": "array",
+ "items": {
+ "$ref": "#/definitions/DetectedLanguage"
+ }
+ },
+ "statistics": {
+ "$ref": "#/definitions/DocumentStatistics",
+ "description": "(Optional) if showStats=true was specified in the request this field will contain information about the document payload."
+ }
+ }
+ },
+ "DetectedLanguage": {
+ "type": "object",
+ "properties": {
+ "name": {
+ "description": "Long name of a detected language (e.g. English, French).",
+ "type": "string"
+ },
+ "iso6391Name": {
+ "description": "A two letter representation of the detected language according to the ISO 639-1 standard (e.g. en, fr).",
+ "type": "string"
+ },
+ "score": {
+ "format": "double",
+ "description": "A confidence score between 0 and 1. Scores close to 1 indicate 100% certainty that the identified language is true.",
+ "type": "number"
+ }
+ }
+ },
+ "SentimentBatchResult": {
+ "type": "object",
+ "properties": {
+ "documents": {
+ "description": "Response by document",
+ "type": "array",
+ "items": {
+ "$ref": "#/definitions/SentimentBatchResultItem"
+ },
+ "readOnly": true
+ },
+ "errors": {
+ "description": "Errors and Warnings by document",
+ "type": "array",
+ "items": {
+ "$ref": "#/definitions/ErrorRecord"
+ },
+ "readOnly": true
+ },
+ "statistics": {
+ "$ref": "#/definitions/RequestStatistics",
+ "description": "(Optional) if showStats=true was specified in the request this field will contain information about the request payload.",
+ "readOnly": true
+ }
+ }
+ },
+ "SentimentBatchResultItem": {
+ "type": "object",
+ "properties": {
+ "id": {
+ "description": "Unique, non-empty document identifier.",
+ "type": "string"
+ },
+ "score": {
+ "format": "double",
+ "description": "A decimal number between 0 and 1 denoting the sentiment of the document. A score above 0.7 usually refers to a positive document while a score below 0.3 normally has a negative connotation. Mid values refer to neutral text.",
+ "type": "number"
+ },
+ "statistics": {
+ "$ref": "#/definitions/DocumentStatistics",
+ "description": "(Optional) if showStats=true was specified in the request this field will contain information about the document payload."
+ }
+ }
+ }
+ },
+ "parameters": {
+ "Endpoint": {
+ "name": "Endpoint",
+ "description": "Supported Cognitive Services endpoints (protocol and hostname, for example: https://westus.api.cognitive.microsoft.com).",
+ "x-ms-parameter-location": "client",
+ "required": true,
+ "type": "string",
+ "in": "path",
+ "x-ms-skip-url-encoding": true
+ }
+ }
+}
\ No newline at end of file
diff --git a/specification/cognitiveservices/data-plane/TextAnalytics/stable/v2.1/examples/SuccessfulEntitiesRequest.json b/specification/cognitiveservices/data-plane/TextAnalytics/stable/v2.1/examples/SuccessfulEntitiesRequest.json
new file mode 100644
index 000000000000..421eee8e23ed
--- /dev/null
+++ b/specification/cognitiveservices/data-plane/TextAnalytics/stable/v2.1/examples/SuccessfulEntitiesRequest.json
@@ -0,0 +1,119 @@
+{
+ "parameters": {
+ "Ocp-Apim-Subscription-Key": "{API key}",
+ "Endpoint": "{Endpoint}",
+ "input": {
+ "documents": [
+ {
+ "language": "en",
+ "id": "1",
+ "text": "Microsoft released Windows 10"
+ },
+ {
+ "language": "en",
+ "id": "2",
+ "text": "In 1975, Bill Gates III and Paul Allen founded the company."
+ }
+ ]
+ }
+ },
+ "responses": {
+ "200": {
+ "headers": {},
+ "body": {
+ "documents": [
+ {
+ "id": "1",
+ "entities": [
+ {
+ "name": "Microsoft",
+ "matches": [
+ {
+ "wikipediaScore": 0.12508682244047509,
+ "entityTypeScore": 0.99999618530273438,
+ "text": "Microsoft",
+ "offset": 0,
+ "length": 9
+ }
+ ],
+ "wikipediaLanguage": "en",
+ "wikipediaId": "Microsoft",
+ "wikipediaUrl": "https://en.wikipedia.org/wiki/Microsoft",
+ "bingId": "a093e9b9-90f5-a3d5-c4b8-5855e1b01f85",
+ "type": "Organization"
+ },
+ {
+ "name": "Windows 10",
+ "matches": [
+ {
+ "wikipediaScore": 0.35750355694656766,
+ "text": "Windows 10",
+ "offset": 19,
+ "length": 10
+ }
+ ],
+ "wikipediaLanguage": "en",
+ "wikipediaId": "Windows 10",
+ "wikipediaUrl": "https://en.wikipedia.org/wiki/Windows_10",
+ "bingId": "5f9fbd03-49c4-39ef-cc95-de83ab897b94"
+ }
+ ]
+ },
+ {
+ "id": "2",
+ "entities": [
+ {
+ "name": "1975",
+ "matches": [
+ {
+ "entityTypeScore": 0.8,
+ "text": "1975",
+ "offset": 3,
+ "length": 4
+ }
+ ],
+ "type": "DateTime",
+ "subType": "DateRange"
+ },
+ {
+ "name": "Bill Gates",
+ "matches": [
+ {
+ "wikipediaScore": 0.84403697401993427,
+ "entityTypeScore": 0.99642062187194824,
+ "text": "Bill Gates III",
+ "offset": 9,
+ "length": 14
+ }
+ ],
+ "wikipediaLanguage": "en",
+ "wikipediaId": "Bill Gates",
+ "wikipediaUrl": "https://en.wikipedia.org/wiki/Bill_Gates",
+ "bingId": "0d47c987-0042-5576-15e8-97af601614fa",
+ "type": "Person"
+ },
+ {
+ "name": "Paul Allen",
+ "matches": [
+ {
+ "wikipediaScore": 0.41878879328253582,
+ "entityTypeScore": 0.99664866924285889,
+ "text": "Paul Allen",
+ "offset": 28,
+ "length": 10
+ }
+ ],
+ "wikipediaLanguage": "en",
+ "wikipediaId": "Paul Allen",
+ "wikipediaUrl": "https://en.wikipedia.org/wiki/Paul_Allen",
+ "bingId": "df2c4376-9923-6a54-893f-2ee5a5badbc7",
+ "type": "Person"
+ }
+ ]
+ }
+ ],
+ "errors": []
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git a/specification/cognitiveservices/data-plane/TextAnalytics/stable/v2.1/examples/SuccessfulKeyPhrasesRequest.json b/specification/cognitiveservices/data-plane/TextAnalytics/stable/v2.1/examples/SuccessfulKeyPhrasesRequest.json
new file mode 100644
index 000000000000..2c79c9965846
--- /dev/null
+++ b/specification/cognitiveservices/data-plane/TextAnalytics/stable/v2.1/examples/SuccessfulKeyPhrasesRequest.json
@@ -0,0 +1,64 @@
+{
+ "parameters": {
+ "Ocp-Apim-Subscription-Key": "{API key}",
+ "Endpoint": "{Endpoint}",
+ "input": {
+ "documents": [
+ {
+ "id": "1",
+ "text": "If this demo doesn't work I will be super sad",
+ "language": "en"
+ },
+ {
+ "id": "2",
+ "text": "Español es muy difícil de aprender",
+ "language": "es"
+ },
+ {
+ "id": "3",
+ "text": "I really really love machine learning",
+ "language": "en"
+ },
+ {
+ "id": "4",
+ "text": "Le soleil se lève à l'Est",
+ "language": "fr"
+ }
+ ]
+ }
+ },
+ "responses": {
+ "200": {
+ "headers": {},
+ "body": {
+ "documents": [
+ {
+ "keyPhrases": [
+ "demo"
+ ],
+ "id": "1"
+ },
+ {
+ "keyPhrases": [
+ "Español"
+ ],
+ "id": "2"
+ },
+ {
+ "keyPhrases": [
+ "machine"
+ ],
+ "id": "3"
+ },
+ {
+ "keyPhrases": [
+ "soleil"
+ ],
+ "id": "4"
+ }
+ ],
+ "errors": []
+ }
+ }
+ }
+}
diff --git a/specification/cognitiveservices/data-plane/TextAnalytics/stable/v2.1/examples/SuccessfulLanguagesRequest.json b/specification/cognitiveservices/data-plane/TextAnalytics/stable/v2.1/examples/SuccessfulLanguagesRequest.json
new file mode 100644
index 000000000000..e2d44e5f9c28
--- /dev/null
+++ b/specification/cognitiveservices/data-plane/TextAnalytics/stable/v2.1/examples/SuccessfulLanguagesRequest.json
@@ -0,0 +1,76 @@
+{
+ "parameters": {
+ "Ocp-Apim-Subscription-Key": "{API key}",
+ "Endpoint": "{Endpoint}",
+ "input": {
+ "documents": [
+ {
+ "id": "1",
+ "text": "If this demo doesn't work I will be super sad"
+ },
+ {
+ "id": "2",
+ "text": "Español es muy difícil de aprender"
+ },
+ {
+ "id": "3",
+ "text": "I really really love machine learning"
+ },
+ {
+ "id": "4",
+ "text": "Le soleil se lève à l'Est"
+ }
+ ]
+ }
+ },
+ "responses": {
+ "200": {
+ "headers": {},
+ "body": {
+ "documents": [
+ {
+ "id": "1",
+ "detectedLanguages": [
+ {
+ "name": "English",
+ "iso6391Name": "en",
+ "score": 1.0
+ }
+ ]
+ },
+ {
+ "id": "2",
+ "detectedLanguages": [
+ {
+ "name": "Spanish",
+ "iso6391Name": "es",
+ "score": 1.0
+ }
+ ]
+ },
+ {
+ "id": "3",
+ "detectedLanguages": [
+ {
+ "name": "English",
+ "iso6391Name": "en",
+ "score": 1.0
+ }
+ ]
+ },
+ {
+ "id": "4",
+ "detectedLanguages": [
+ {
+ "name": "French",
+ "iso6391Name": "fr",
+ "score": 1.0
+ }
+ ]
+ }
+ ],
+ "errors": []
+ }
+ }
+ }
+}
diff --git a/specification/cognitiveservices/data-plane/TextAnalytics/stable/v2.1/examples/SuccessfulSentimentRequest.json b/specification/cognitiveservices/data-plane/TextAnalytics/stable/v2.1/examples/SuccessfulSentimentRequest.json
new file mode 100644
index 000000000000..58f93a0bd9b6
--- /dev/null
+++ b/specification/cognitiveservices/data-plane/TextAnalytics/stable/v2.1/examples/SuccessfulSentimentRequest.json
@@ -0,0 +1,56 @@
+{
+ "parameters": {
+ "Ocp-Apim-Subscription-Key": "{API key}",
+ "Endpoint": "{Endpoint}",
+ "input": {
+ "documents": [
+ {
+ "id": "1",
+ "text": "If this demo doesn't work I will be super sad",
+ "language": "en"
+ },
+ {
+ "id": "2",
+ "text": "Español es muy difícil de aprender",
+ "language": "es"
+ },
+ {
+ "id": "3",
+ "text": "I really really love machine learning",
+ "language": "en"
+ },
+ {
+ "id": "4",
+ "text": "Le soleil se lève à l'Est",
+ "language": "fr"
+ }
+ ]
+ }
+ },
+ "responses": {
+ "200": {
+ "headers": {},
+ "body": {
+ "documents": [
+ {
+ "score": 0.0065730810165405273,
+ "id": "1"
+ },
+ {
+ "score": 0.97333031892776489,
+ "id": "3"
+ },
+ {
+ "score": 0.44219660758972168,
+ "id": "2"
+ },
+ {
+ "score": 0.53425812721252441,
+ "id": "4"
+ }
+ ],
+ "errors": []
+ }
+ }
+ }
+}