From c994b91e9b31d042e20e52c5d2bad9761ae06312 Mon Sep 17 00:00:00 2001 From: iscai-msft Date: Wed, 22 Apr 2020 16:46:02 -0400 Subject: [PATCH 1/3] regenerated with v3.0 --- .../ai/textanalytics/_generated/__init__.py | 6 + .../_generated/_configuration.py | 11 +- .../_generated/_text_analytics_client.py | 11 +- .../_generated/aio/_configuration_async.py | 9 +- .../aio/_text_analytics_client_async.py | 5 +- ..._text_analytics_client_operations_async.py | 116 +++-------- .../_generated/models/__init__.py | 5 + .../_generated/models/_models.py | 156 ++++++++++----- .../_generated/models/_models_py3.py | 187 ++++++++++++------ .../models/_text_analytics_client_enums.py | 19 +- .../_text_analytics_client_operations.py | 127 +++--------- 11 files changed, 345 insertions(+), 307 deletions(-) diff --git a/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_generated/__init__.py b/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_generated/__init__.py index b64fe33ea84d..bab4e1ff9cac 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_generated/__init__.py +++ b/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_generated/__init__.py @@ -8,3 +8,9 @@ from ._text_analytics_client import TextAnalyticsClient __all__ = ['TextAnalyticsClient'] + +try: + from ._patch import patch_sdk + patch_sdk() +except ImportError: + pass diff --git a/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_generated/_configuration.py b/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_generated/_configuration.py index 61a51a2b4725..4870417a532a 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_generated/_configuration.py +++ b/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_generated/_configuration.py @@ -6,11 +6,17 @@ # Changes may cause incorrect behavior and will be lost if the code is regenerated. # -------------------------------------------------------------------------- -from typing import Any +from typing import TYPE_CHECKING from azure.core.configuration import Configuration from azure.core.pipeline import policies +if TYPE_CHECKING: + # pylint: disable=unused-import,ungrouped-imports + from typing import Any + + from azure.core.credentials import TokenCredential + VERSION = "unknown" class TextAnalyticsClientConfiguration(Configuration): @@ -20,7 +26,7 @@ class TextAnalyticsClientConfiguration(Configuration): attributes. :param credential: Credential needed for the client to connect to Azure. - :type credential: azure.core.credentials.TokenCredential + :type credential: ~azure.core.credentials.TokenCredential :param endpoint: Supported Cognitive Services endpoints (protocol and hostname, for example: https://westus.api.cognitive.microsoft.com). :type endpoint: str """ @@ -41,6 +47,7 @@ def __init__( self.credential = credential self.endpoint = endpoint self.credential_scopes = ['https://cognitiveservices.azure.com/.default'] + self.credential_scopes.extend(kwargs.pop('credential_scopes', [])) kwargs.setdefault('sdk_moniker', 'ai-textanalytics/{}'.format(VERSION)) self._configure(**kwargs) diff --git a/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_generated/_text_analytics_client.py b/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_generated/_text_analytics_client.py index 20e6d4dac316..d54e09733c38 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_generated/_text_analytics_client.py +++ b/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_generated/_text_analytics_client.py @@ -6,11 +6,15 @@ # Changes may cause incorrect behavior and will be lost if the code is regenerated. # -------------------------------------------------------------------------- -from typing import Any +from typing import TYPE_CHECKING from azure.core import PipelineClient from msrest import Deserializer, Serializer +if TYPE_CHECKING: + # pylint: disable=unused-import,ungrouped-imports + from typing import Any + from ._configuration import TextAnalyticsClientConfiguration from .operations import TextAnalyticsClientOperationsMixin from . import models @@ -20,9 +24,10 @@ class TextAnalyticsClient(TextAnalyticsClientOperationsMixin): """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. :param credential: Credential needed for the client to connect to Azure. - :type credential: azure.core.credentials.TokenCredential + :type credential: ~azure.core.credentials.TokenCredential :param endpoint: Supported Cognitive Services endpoints (protocol and hostname, for example: https://westus.api.cognitive.microsoft.com). :type endpoint: str + :keyword int polling_interval: Default waiting time between two polls for LRO operations if no Retry-After header is present. """ def __init__( @@ -32,7 +37,7 @@ def __init__( **kwargs # type: Any ): # type: (...) -> None - base_url = '{Endpoint}/text/analytics/v3.0-preview.1' + base_url = '{Endpoint}/text/analytics/v3.0' self._config = TextAnalyticsClientConfiguration(credential, endpoint, **kwargs) self._client = PipelineClient(base_url=base_url, config=self._config, **kwargs) diff --git a/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_generated/aio/_configuration_async.py b/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_generated/aio/_configuration_async.py index 37a7e6f66a97..4865a1884975 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_generated/aio/_configuration_async.py +++ b/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_generated/aio/_configuration_async.py @@ -6,11 +6,15 @@ # Changes may cause incorrect behavior and will be lost if the code is regenerated. # -------------------------------------------------------------------------- -from typing import Any +from typing import Any, TYPE_CHECKING from azure.core.configuration import Configuration from azure.core.pipeline import policies +if TYPE_CHECKING: + # pylint: disable=unused-import,ungrouped-imports + from azure.core.credentials import TokenCredential + VERSION = "unknown" class TextAnalyticsClientConfiguration(Configuration): @@ -20,7 +24,7 @@ class TextAnalyticsClientConfiguration(Configuration): attributes. :param credential: Credential needed for the client to connect to Azure. - :type credential: azure.core.credentials.AsyncTokenCredential + :type credential: ~azure.core.credentials_async.AsyncTokenCredential :param endpoint: Supported Cognitive Services endpoints (protocol and hostname, for example: https://westus.api.cognitive.microsoft.com). :type endpoint: str """ @@ -40,6 +44,7 @@ def __init__( self.credential = credential self.endpoint = endpoint self.credential_scopes = ['https://cognitiveservices.azure.com/.default'] + self.credential_scopes.extend(kwargs.pop('credential_scopes', [])) kwargs.setdefault('sdk_moniker', 'ai-textanalytics/{}'.format(VERSION)) self._configure(**kwargs) diff --git a/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_generated/aio/_text_analytics_client_async.py b/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_generated/aio/_text_analytics_client_async.py index 08e67c8fe11b..de28032b0db2 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_generated/aio/_text_analytics_client_async.py +++ b/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_generated/aio/_text_analytics_client_async.py @@ -20,9 +20,10 @@ class TextAnalyticsClient(TextAnalyticsClientOperationsMixin): """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. :param credential: Credential needed for the client to connect to Azure. - :type credential: azure.core.credentials.AsyncTokenCredential + :type credential: ~azure.core.credentials_async.AsyncTokenCredential :param endpoint: Supported Cognitive Services endpoints (protocol and hostname, for example: https://westus.api.cognitive.microsoft.com). :type endpoint: str + :keyword int polling_interval: Default waiting time between two polls for LRO operations if no Retry-After header is present. """ def __init__( @@ -31,7 +32,7 @@ def __init__( endpoint: str, **kwargs: Any ) -> None: - base_url = '{Endpoint}/text/analytics/v3.0-preview.1' + base_url = '{Endpoint}/text/analytics/v3.0' self._config = TextAnalyticsClientConfiguration(credential, endpoint, **kwargs) self._client = AsyncPipelineClient(base_url=base_url, config=self._config, **kwargs) diff --git a/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_generated/aio/operations_async/_text_analytics_client_operations_async.py b/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_generated/aio/operations_async/_text_analytics_client_operations_async.py index 71d03e9413bb..d09be1dbc240 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_generated/aio/operations_async/_text_analytics_client_operations_async.py +++ b/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_generated/aio/operations_async/_text_analytics_client_operations_async.py @@ -21,7 +21,7 @@ class TextAnalyticsClientOperationsMixin: async def entities_recognition_general( self, - documents: List["MultiLanguageInput"], + documents: List["models.MultiLanguageInput"], model_version: Optional[str] = None, show_stats: Optional[bool] = None, **kwargs @@ -44,13 +44,14 @@ async def entities_recognition_general( :raises: ~azure.core.exceptions.HttpResponseError """ cls = kwargs.pop('cls', None) # type: ClsType["models.EntitiesResult"] - error_map = kwargs.pop('error_map', {404: ResourceNotFoundError, 409: ResourceExistsError}) + error_map = {404: ResourceNotFoundError, 409: ResourceExistsError} + error_map.update(kwargs.pop('error_map', {})) _input = models.MultiLanguageBatchInput(documents=documents) content_type = kwargs.pop("content_type", "application/json") # Construct URL - url = self.entities_recognition_general.metadata['url'] + url = self.entities_recognition_general.metadata['url'] # type: ignore path_format_arguments = { 'Endpoint': self._serialize.url("self._config.endpoint", self._config.endpoint, 'str', skip_quote=True), } @@ -88,82 +89,11 @@ async def entities_recognition_general( return cls(pipeline_response, deserialized, {}) return deserialized - entities_recognition_general.metadata = {'url': '/entities/recognition/general'} - - async def entities_recognition_pii( - self, - documents: List["MultiLanguageInput"], - model_version: Optional[str] = None, - show_stats: Optional[bool] = None, - **kwargs - ) -> "models.EntitiesResult": - """The API returns a list of entities with personal information (\"SSN\", \"Bank Account\" etc) in the document. For the list of supported entity types, check :code:`Supported Entity Types in Text Analytics API`. See the :code:`Supported languages in Text Analytics API` for the list of enabled languages. - - Entities containing personal information. - - :param documents: The set of documents to process as part of this batch. - :type documents: list[~azure.ai.textanalytics.models.MultiLanguageInput] - :param model_version: (Optional) This value indicates which model will be used for scoring. If - a model-version is not specified, the API should default to the latest, non-preview version. - :type model_version: str - :param show_stats: (Optional) if set to true, response will contain input and document level - statistics. - :type show_stats: bool - :keyword callable cls: A custom type or function that will be passed the direct response - :return: EntitiesResult or the result of cls(response) - :rtype: ~azure.ai.textanalytics.models.EntitiesResult - :raises: ~azure.core.exceptions.HttpResponseError - """ - cls = kwargs.pop('cls', None) # type: ClsType["models.EntitiesResult"] - error_map = kwargs.pop('error_map', {404: ResourceNotFoundError, 409: ResourceExistsError}) - - _input = models.MultiLanguageBatchInput(documents=documents) - content_type = kwargs.pop("content_type", "application/json") - - # Construct URL - url = self.entities_recognition_pii.metadata['url'] - path_format_arguments = { - 'Endpoint': self._serialize.url("self._config.endpoint", self._config.endpoint, 'str', skip_quote=True), - } - url = self._client.format_url(url, **path_format_arguments) - - # Construct parameters - query_parameters = {} # type: Dict[str, Any] - if model_version is not None: - query_parameters['model-version'] = self._serialize.query("model_version", model_version, 'str') - if show_stats is not None: - query_parameters['showStats'] = self._serialize.query("show_stats", show_stats, 'bool') - - # Construct headers - header_parameters = {} # type: Dict[str, Any] - header_parameters['Content-Type'] = self._serialize.header("content_type", content_type, 'str') - header_parameters['Accept'] = 'application/json' - - # Construct and send request - body_content_kwargs = {} # type: Dict[str, Any] - body_content = self._serialize.body(_input, 'MultiLanguageBatchInput') - body_content_kwargs['content'] = body_content - request = self._client.post(url, query_parameters, header_parameters, **body_content_kwargs) - - pipeline_response = await self._client._pipeline.run(request, stream=False, **kwargs) - response = pipeline_response.http_response - - if response.status_code not in [200]: - map_error(status_code=response.status_code, response=response, error_map=error_map) - error = self._deserialize(models.TextAnalyticsError, response) - raise HttpResponseError(response=response, model=error) - - deserialized = self._deserialize('EntitiesResult', pipeline_response) - - if cls: - return cls(pipeline_response, deserialized, {}) - - return deserialized - entities_recognition_pii.metadata = {'url': '/entities/recognition/pii'} + entities_recognition_general.metadata = {'url': '/entities/recognition/general'} # type: ignore async def entities_linking( self, - documents: List["MultiLanguageInput"], + documents: List["models.MultiLanguageInput"], model_version: Optional[str] = None, show_stats: Optional[bool] = None, **kwargs @@ -186,13 +116,14 @@ async def entities_linking( :raises: ~azure.core.exceptions.HttpResponseError """ cls = kwargs.pop('cls', None) # type: ClsType["models.EntityLinkingResult"] - error_map = kwargs.pop('error_map', {404: ResourceNotFoundError, 409: ResourceExistsError}) + error_map = {404: ResourceNotFoundError, 409: ResourceExistsError} + error_map.update(kwargs.pop('error_map', {})) _input = models.MultiLanguageBatchInput(documents=documents) content_type = kwargs.pop("content_type", "application/json") # Construct URL - url = self.entities_linking.metadata['url'] + url = self.entities_linking.metadata['url'] # type: ignore path_format_arguments = { 'Endpoint': self._serialize.url("self._config.endpoint", self._config.endpoint, 'str', skip_quote=True), } @@ -230,11 +161,11 @@ async def entities_linking( return cls(pipeline_response, deserialized, {}) return deserialized - entities_linking.metadata = {'url': '/entities/linking'} + entities_linking.metadata = {'url': '/entities/linking'} # type: ignore async def key_phrases( self, - documents: List["MultiLanguageInput"], + documents: List["models.MultiLanguageInput"], model_version: Optional[str] = None, show_stats: Optional[bool] = None, **kwargs @@ -257,13 +188,14 @@ async def key_phrases( :raises: ~azure.core.exceptions.HttpResponseError """ cls = kwargs.pop('cls', None) # type: ClsType["models.KeyPhraseResult"] - error_map = kwargs.pop('error_map', {404: ResourceNotFoundError, 409: ResourceExistsError}) + error_map = {404: ResourceNotFoundError, 409: ResourceExistsError} + error_map.update(kwargs.pop('error_map', {})) _input = models.MultiLanguageBatchInput(documents=documents) content_type = kwargs.pop("content_type", "application/json") # Construct URL - url = self.key_phrases.metadata['url'] + url = self.key_phrases.metadata['url'] # type: ignore path_format_arguments = { 'Endpoint': self._serialize.url("self._config.endpoint", self._config.endpoint, 'str', skip_quote=True), } @@ -301,11 +233,11 @@ async def key_phrases( return cls(pipeline_response, deserialized, {}) return deserialized - key_phrases.metadata = {'url': '/keyPhrases'} + key_phrases.metadata = {'url': '/keyPhrases'} # type: ignore async def languages( self, - documents: List["LanguageInput"], + documents: List["models.LanguageInput"], model_version: Optional[str] = None, show_stats: Optional[bool] = None, **kwargs @@ -328,13 +260,14 @@ async def languages( :raises: ~azure.core.exceptions.HttpResponseError """ cls = kwargs.pop('cls', None) # type: ClsType["models.LanguageResult"] - error_map = kwargs.pop('error_map', {404: ResourceNotFoundError, 409: ResourceExistsError}) + error_map = {404: ResourceNotFoundError, 409: ResourceExistsError} + error_map.update(kwargs.pop('error_map', {})) _input = models.LanguageBatchInput(documents=documents) content_type = kwargs.pop("content_type", "application/json") # Construct URL - url = self.languages.metadata['url'] + url = self.languages.metadata['url'] # type: ignore path_format_arguments = { 'Endpoint': self._serialize.url("self._config.endpoint", self._config.endpoint, 'str', skip_quote=True), } @@ -372,11 +305,11 @@ async def languages( return cls(pipeline_response, deserialized, {}) return deserialized - languages.metadata = {'url': '/languages'} + languages.metadata = {'url': '/languages'} # type: ignore async def sentiment( self, - documents: List["MultiLanguageInput"], + documents: List["models.MultiLanguageInput"], model_version: Optional[str] = None, show_stats: Optional[bool] = None, **kwargs @@ -399,13 +332,14 @@ async def sentiment( :raises: ~azure.core.exceptions.HttpResponseError """ cls = kwargs.pop('cls', None) # type: ClsType["models.SentimentResponse"] - error_map = kwargs.pop('error_map', {404: ResourceNotFoundError, 409: ResourceExistsError}) + error_map = {404: ResourceNotFoundError, 409: ResourceExistsError} + error_map.update(kwargs.pop('error_map', {})) _input = models.MultiLanguageBatchInput(documents=documents) content_type = kwargs.pop("content_type", "application/json") # Construct URL - url = self.sentiment.metadata['url'] + url = self.sentiment.metadata['url'] # type: ignore path_format_arguments = { 'Endpoint': self._serialize.url("self._config.endpoint", self._config.endpoint, 'str', skip_quote=True), } @@ -443,4 +377,4 @@ async def sentiment( return cls(pipeline_response, deserialized, {}) return deserialized - sentiment.metadata = {'url': '/sentiment'} + sentiment.metadata = {'url': '/sentiment'} # type: ignore diff --git a/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_generated/models/__init__.py b/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_generated/models/__init__.py index f81654bec2d3..474336e92e7a 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_generated/models/__init__.py +++ b/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_generated/models/__init__.py @@ -32,6 +32,7 @@ from ._models_py3 import SentimentConfidenceScorePerLabel from ._models_py3 import SentimentResponse from ._models_py3 import TextAnalyticsError + from ._models_py3 import TextAnalyticsWarning except (SyntaxError, ImportError): from ._models import DetectedLanguage # type: ignore from ._models import DocumentEntities # type: ignore @@ -58,12 +59,14 @@ from ._models import SentimentConfidenceScorePerLabel # type: ignore from ._models import SentimentResponse # type: ignore from ._models import TextAnalyticsError # type: ignore + from ._models import TextAnalyticsWarning # type: ignore from ._text_analytics_client_enums import ( DocumentSentimentValue, ErrorCodeValue, InnerErrorCodeValue, SentenceSentimentValue, + WarningCodeValue, ) __all__ = [ @@ -92,8 +95,10 @@ 'SentimentConfidenceScorePerLabel', 'SentimentResponse', 'TextAnalyticsError', + 'TextAnalyticsWarning', 'DocumentSentimentValue', 'ErrorCodeValue', 'InnerErrorCodeValue', 'SentenceSentimentValue', + 'WarningCodeValue', ] diff --git a/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_generated/models/_models.py b/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_generated/models/_models.py index d73eeb9479f6..91a91cd98399 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_generated/models/_models.py +++ b/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_generated/models/_models.py @@ -20,21 +20,21 @@ class DetectedLanguage(msrest.serialization.Model): :param iso6391_name: Required. A two letter representation of the detected language according to the ISO 639-1 standard (e.g. en, fr). :type iso6391_name: str - :param score: Required. A confidence score between 0 and 1. Scores close to 1 indicate 100% - certainty that the identified language is true. - :type score: float + :param confidence_score: Required. A confidence score between 0 and 1. Scores close to 1 + indicate 100% certainty that the identified language is true. + :type confidence_score: float """ _validation = { 'name': {'required': True}, 'iso6391_name': {'required': True}, - 'score': {'required': True}, + 'confidence_score': {'required': True}, } _attribute_map = { 'name': {'key': 'name', 'type': 'str'}, 'iso6391_name': {'key': 'iso6391Name', 'type': 'str'}, - 'score': {'key': 'score', 'type': 'float'}, + 'confidence_score': {'key': 'confidenceScore', 'type': 'float'}, } def __init__( @@ -44,7 +44,7 @@ def __init__( super(DetectedLanguage, self).__init__(**kwargs) self.name = kwargs['name'] self.iso6391_name = kwargs['iso6391_name'] - self.score = kwargs['score'] + self.confidence_score = kwargs['confidence_score'] class DocumentEntities(msrest.serialization.Model): @@ -56,6 +56,8 @@ class DocumentEntities(msrest.serialization.Model): :type id: str :param entities: Required. Recognized entities in the document. :type entities: list[~azure.ai.textanalytics.models.Entity] + :param warnings: Required. Warnings encountered while processing document. + :type warnings: list[~azure.ai.textanalytics.models.TextAnalyticsWarning] :param statistics: if showStats=true was specified in the request this field will contain information about the document payload. :type statistics: ~azure.ai.textanalytics.models.DocumentStatistics @@ -64,11 +66,13 @@ class DocumentEntities(msrest.serialization.Model): _validation = { 'id': {'required': True}, 'entities': {'required': True}, + 'warnings': {'required': True}, } _attribute_map = { 'id': {'key': 'id', 'type': 'str'}, 'entities': {'key': 'entities', 'type': '[Entity]'}, + 'warnings': {'key': 'warnings', 'type': '[TextAnalyticsWarning]'}, 'statistics': {'key': 'statistics', 'type': 'DocumentStatistics'}, } @@ -79,6 +83,7 @@ def __init__( super(DocumentEntities, self).__init__(**kwargs) self.id = kwargs['id'] self.entities = kwargs['entities'] + self.warnings = kwargs['warnings'] self.statistics = kwargs.get('statistics', None) @@ -122,6 +127,8 @@ class DocumentKeyPhrases(msrest.serialization.Model): :param key_phrases: Required. 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 key_phrases: list[str] + :param warnings: Required. Warnings encountered while processing document. + :type warnings: list[~azure.ai.textanalytics.models.TextAnalyticsWarning] :param statistics: if showStats=true was specified in the request this field will contain information about the document payload. :type statistics: ~azure.ai.textanalytics.models.DocumentStatistics @@ -130,11 +137,13 @@ class DocumentKeyPhrases(msrest.serialization.Model): _validation = { 'id': {'required': True}, 'key_phrases': {'required': True}, + 'warnings': {'required': True}, } _attribute_map = { 'id': {'key': 'id', 'type': 'str'}, 'key_phrases': {'key': 'keyPhrases', 'type': '[str]'}, + 'warnings': {'key': 'warnings', 'type': '[TextAnalyticsWarning]'}, 'statistics': {'key': 'statistics', 'type': 'DocumentStatistics'}, } @@ -145,6 +154,7 @@ def __init__( super(DocumentKeyPhrases, self).__init__(**kwargs) self.id = kwargs['id'] self.key_phrases = kwargs['key_phrases'] + self.warnings = kwargs['warnings'] self.statistics = kwargs.get('statistics', None) @@ -157,6 +167,8 @@ class DocumentLanguage(msrest.serialization.Model): :type id: str :param detected_languages: Required. A list of extracted languages. :type detected_languages: list[~azure.ai.textanalytics.models.DetectedLanguage] + :param warnings: Required. Warnings encountered while processing document. + :type warnings: list[~azure.ai.textanalytics.models.TextAnalyticsWarning] :param statistics: if showStats=true was specified in the request this field will contain information about the document payload. :type statistics: ~azure.ai.textanalytics.models.DocumentStatistics @@ -165,11 +177,13 @@ class DocumentLanguage(msrest.serialization.Model): _validation = { 'id': {'required': True}, 'detected_languages': {'required': True}, + 'warnings': {'required': True}, } _attribute_map = { 'id': {'key': 'id', 'type': 'str'}, 'detected_languages': {'key': 'detectedLanguages', 'type': '[DetectedLanguage]'}, + 'warnings': {'key': 'warnings', 'type': '[TextAnalyticsWarning]'}, 'statistics': {'key': 'statistics', 'type': 'DocumentStatistics'}, } @@ -180,6 +194,7 @@ def __init__( super(DocumentLanguage, self).__init__(**kwargs) self.id = kwargs['id'] self.detected_languages = kwargs['detected_languages'] + self.warnings = kwargs['warnings'] self.statistics = kwargs.get('statistics', None) @@ -192,6 +207,8 @@ class DocumentLinkedEntities(msrest.serialization.Model): :type id: str :param entities: Required. Recognized well-known entities in the document. :type entities: list[~azure.ai.textanalytics.models.LinkedEntity] + :param warnings: Required. Warnings encountered while processing document. + :type warnings: list[~azure.ai.textanalytics.models.TextAnalyticsWarning] :param statistics: if showStats=true was specified in the request this field will contain information about the document payload. :type statistics: ~azure.ai.textanalytics.models.DocumentStatistics @@ -200,11 +217,13 @@ class DocumentLinkedEntities(msrest.serialization.Model): _validation = { 'id': {'required': True}, 'entities': {'required': True}, + 'warnings': {'required': True}, } _attribute_map = { 'id': {'key': 'id', 'type': 'str'}, 'entities': {'key': 'entities', 'type': '[LinkedEntity]'}, + 'warnings': {'key': 'warnings', 'type': '[TextAnalyticsWarning]'}, 'statistics': {'key': 'statistics', 'type': 'DocumentStatistics'}, } @@ -215,6 +234,7 @@ def __init__( super(DocumentLinkedEntities, self).__init__(**kwargs) self.id = kwargs['id'] self.entities = kwargs['entities'] + self.warnings = kwargs['warnings'] self.statistics = kwargs.get('statistics', None) @@ -231,26 +251,30 @@ class DocumentSentiment(msrest.serialization.Model): :param statistics: if showStats=true was specified in the request this field will contain information about the document payload. :type statistics: ~azure.ai.textanalytics.models.DocumentStatistics - :param document_scores: Required. Document level sentiment confidence scores between 0 and 1 + :param confidence_scores: Required. Document level sentiment confidence scores between 0 and 1 for each sentiment class. - :type document_scores: ~azure.ai.textanalytics.models.SentimentConfidenceScorePerLabel + :type confidence_scores: ~azure.ai.textanalytics.models.SentimentConfidenceScorePerLabel :param sentences: Required. Sentence level sentiment analysis. :type sentences: list[~azure.ai.textanalytics.models.SentenceSentiment] + :param warnings: Required. Warnings encountered while processing document. + :type warnings: list[~azure.ai.textanalytics.models.TextAnalyticsWarning] """ _validation = { 'id': {'required': True}, 'sentiment': {'required': True}, - 'document_scores': {'required': True}, + 'confidence_scores': {'required': True}, 'sentences': {'required': True}, + 'warnings': {'required': True}, } _attribute_map = { 'id': {'key': 'id', 'type': 'str'}, 'sentiment': {'key': 'sentiment', 'type': 'str'}, 'statistics': {'key': 'statistics', 'type': 'DocumentStatistics'}, - 'document_scores': {'key': 'documentScores', 'type': 'SentimentConfidenceScorePerLabel'}, + 'confidence_scores': {'key': 'confidenceScores', 'type': 'SentimentConfidenceScorePerLabel'}, 'sentences': {'key': 'sentences', 'type': '[SentenceSentiment]'}, + 'warnings': {'key': 'warnings', 'type': '[TextAnalyticsWarning]'}, } def __init__( @@ -261,8 +285,9 @@ def __init__( self.id = kwargs['id'] self.sentiment = kwargs['sentiment'] self.statistics = kwargs.get('statistics', None) - self.document_scores = kwargs['document_scores'] + self.confidence_scores = kwargs['confidence_scores'] self.sentences = kwargs['sentences'] + self.warnings = kwargs['warnings'] class DocumentStatistics(msrest.serialization.Model): @@ -342,33 +367,33 @@ class Entity(msrest.serialization.Model): :param text: Required. Entity text as appears in the request. :type text: str - :param type: Required. Entity type, such as Person/Location/Org/SSN etc. - :type type: str - :param subtype: Entity sub type, such as Age/Year/TimeRange etc. - :type subtype: str + :param category: Required. Entity type, such as Person/Location/Org/SSN etc. + :type category: str + :param subcategory: Entity sub type, such as Age/Year/TimeRange etc. + :type subcategory: str :param offset: Required. Start position (in Unicode characters) for the entity text. :type offset: int :param length: Required. Length (in Unicode characters) for the entity text. :type length: int - :param score: Required. Confidence score between 0 and 1 of the extracted entity. - :type score: float + :param confidence_score: Required. Confidence score between 0 and 1 of the extracted entity. + :type confidence_score: float """ _validation = { 'text': {'required': True}, - 'type': {'required': True}, + 'category': {'required': True}, 'offset': {'required': True}, 'length': {'required': True}, - 'score': {'required': True}, + 'confidence_score': {'required': True}, } _attribute_map = { 'text': {'key': 'text', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'subtype': {'key': 'subtype', 'type': 'str'}, + 'category': {'key': 'category', 'type': 'str'}, + 'subcategory': {'key': 'subcategory', 'type': 'str'}, 'offset': {'key': 'offset', 'type': 'int'}, 'length': {'key': 'length', 'type': 'int'}, - 'score': {'key': 'score', 'type': 'float'}, + 'confidence_score': {'key': 'confidenceScore', 'type': 'float'}, } def __init__( @@ -377,11 +402,11 @@ def __init__( ): super(Entity, self).__init__(**kwargs) self.text = kwargs['text'] - self.type = kwargs['type'] - self.subtype = kwargs.get('subtype', None) + self.category = kwargs['category'] + self.subcategory = kwargs.get('subcategory', None) self.offset = kwargs['offset'] self.length = kwargs['length'] - self.score = kwargs['score'] + self.confidence_score = kwargs['confidence_score'] class EntityLinkingResult(msrest.serialization.Model): @@ -440,8 +465,8 @@ class InnerError(msrest.serialization.Model): :type details: dict[str, str] :param target: Error target. :type target: str - :param inner_error: Inner error contains more specific information. - :type inner_error: ~azure.ai.textanalytics.models.InnerError + :param innererror: Inner error contains more specific information. + :type innererror: ~azure.ai.textanalytics.models.InnerError """ _validation = { @@ -454,7 +479,7 @@ class InnerError(msrest.serialization.Model): 'message': {'key': 'message', 'type': 'str'}, 'details': {'key': 'details', 'type': '{str}'}, 'target': {'key': 'target', 'type': 'str'}, - 'inner_error': {'key': 'innerError', 'type': 'InnerError'}, + 'innererror': {'key': 'innererror', 'type': 'InnerError'}, } def __init__( @@ -466,7 +491,7 @@ def __init__( self.message = kwargs['message'] self.details = kwargs.get('details', None) self.target = kwargs.get('target', None) - self.inner_error = kwargs.get('inner_error', None) + self.innererror = kwargs.get('innererror', None) class KeyPhraseResult(msrest.serialization.Model): @@ -663,9 +688,9 @@ class Match(msrest.serialization.Model): All required parameters must be populated in order to send to Azure. - :param score: Required. If a well-known item is recognized, a decimal number denoting the - confidence level between 0 and 1 will be returned. - :type score: float + :param confidence_score: Required. If a well-known item is recognized, a decimal number + denoting the confidence level between 0 and 1 will be returned. + :type confidence_score: float :param text: Required. Entity text as appears in the request. :type text: str :param offset: Required. Start position (in Unicode characters) for the entity match text. @@ -675,14 +700,14 @@ class Match(msrest.serialization.Model): """ _validation = { - 'score': {'required': True}, + 'confidence_score': {'required': True}, 'text': {'required': True}, 'offset': {'required': True}, 'length': {'required': True}, } _attribute_map = { - 'score': {'key': 'score', 'type': 'float'}, + 'confidence_score': {'key': 'confidenceScore', 'type': 'float'}, 'text': {'key': 'text', 'type': 'str'}, 'offset': {'key': 'offset', 'type': 'int'}, 'length': {'key': 'length', 'type': 'int'}, @@ -693,7 +718,7 @@ def __init__( **kwargs ): super(Match, self).__init__(**kwargs) - self.score = kwargs['score'] + self.confidence_score = kwargs['confidence_score'] self.text = kwargs['text'] self.offset = kwargs['offset'] self.length = kwargs['length'] @@ -807,33 +832,33 @@ class SentenceSentiment(msrest.serialization.Model): All required parameters must be populated in order to send to Azure. + :param text: The sentence text. + :type text: str :param sentiment: Required. The predicted Sentiment for the sentence. Possible values include: "positive", "neutral", "negative". :type sentiment: str or ~azure.ai.textanalytics.models.SentenceSentimentValue - :param sentence_scores: Required. The sentiment confidence score between 0 and 1 for the + :param confidence_scores: Required. The sentiment confidence score between 0 and 1 for the sentence for all classes. - :type sentence_scores: ~azure.ai.textanalytics.models.SentimentConfidenceScorePerLabel + :type confidence_scores: ~azure.ai.textanalytics.models.SentimentConfidenceScorePerLabel :param offset: Required. The sentence offset from the start of the document. :type offset: int :param length: Required. The length of the sentence by Unicode standard. :type length: int - :param warnings: The warnings generated for the sentence. - :type warnings: list[str] """ _validation = { 'sentiment': {'required': True}, - 'sentence_scores': {'required': True}, + 'confidence_scores': {'required': True}, 'offset': {'required': True}, 'length': {'required': True}, } _attribute_map = { + 'text': {'key': 'text', 'type': 'str'}, 'sentiment': {'key': 'sentiment', 'type': 'str'}, - 'sentence_scores': {'key': 'sentenceScores', 'type': 'SentimentConfidenceScorePerLabel'}, + 'confidence_scores': {'key': 'confidenceScores', 'type': 'SentimentConfidenceScorePerLabel'}, 'offset': {'key': 'offset', 'type': 'int'}, 'length': {'key': 'length', 'type': 'int'}, - 'warnings': {'key': 'warnings', 'type': '[str]'}, } def __init__( @@ -841,11 +866,11 @@ def __init__( **kwargs ): super(SentenceSentiment, self).__init__(**kwargs) + self.text = kwargs.get('text', None) self.sentiment = kwargs['sentiment'] - self.sentence_scores = kwargs['sentence_scores'] + self.confidence_scores = kwargs['confidence_scores'] self.offset = kwargs['offset'] self.length = kwargs['length'] - self.warnings = kwargs.get('warnings', None) class SentimentConfidenceScorePerLabel(msrest.serialization.Model): @@ -935,8 +960,8 @@ class TextAnalyticsError(msrest.serialization.Model): :type message: str :param target: Error target. :type target: str - :param inner_error: Inner error contains more specific information. - :type inner_error: ~azure.ai.textanalytics.models.InnerError + :param innererror: Inner error contains more specific information. + :type innererror: ~azure.ai.textanalytics.models.InnerError :param details: Details about specific errors that led to this reported error. :type details: list[~azure.ai.textanalytics.models.TextAnalyticsError] """ @@ -950,7 +975,7 @@ class TextAnalyticsError(msrest.serialization.Model): 'code': {'key': 'code', 'type': 'str'}, 'message': {'key': 'message', 'type': 'str'}, 'target': {'key': 'target', 'type': 'str'}, - 'inner_error': {'key': 'innerError', 'type': 'InnerError'}, + 'innererror': {'key': 'innererror', 'type': 'InnerError'}, 'details': {'key': 'details', 'type': '[TextAnalyticsError]'}, } @@ -962,5 +987,40 @@ def __init__( self.code = kwargs['code'] self.message = kwargs['message'] self.target = kwargs.get('target', None) - self.inner_error = kwargs.get('inner_error', None) + self.innererror = kwargs.get('innererror', None) self.details = kwargs.get('details', None) + + +class TextAnalyticsWarning(msrest.serialization.Model): + """TextAnalyticsWarning. + + All required parameters must be populated in order to send to Azure. + + :param code: Required. Error code. Possible values include: "LongWordsInDocument", + "DocumentTruncated". + :type code: str or ~azure.ai.textanalytics.models.WarningCodeValue + :param message: Required. Warning message. + :type message: str + :param target_ref: A JSON pointer reference indicating the target object. + :type target_ref: str + """ + + _validation = { + 'code': {'required': True}, + 'message': {'required': True}, + } + + _attribute_map = { + 'code': {'key': 'code', 'type': 'str'}, + 'message': {'key': 'message', 'type': 'str'}, + 'target_ref': {'key': 'targetRef', 'type': 'str'}, + } + + def __init__( + self, + **kwargs + ): + super(TextAnalyticsWarning, self).__init__(**kwargs) + self.code = kwargs['code'] + self.message = kwargs['message'] + self.target_ref = kwargs.get('target_ref', None) diff --git a/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_generated/models/_models_py3.py b/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_generated/models/_models_py3.py index f455b6989e06..4db9520773e5 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_generated/models/_models_py3.py +++ b/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_generated/models/_models_py3.py @@ -11,6 +11,8 @@ from azure.core.exceptions import HttpResponseError import msrest.serialization +from ._text_analytics_client_enums import * + class DetectedLanguage(msrest.serialization.Model): """DetectedLanguage. @@ -22,21 +24,21 @@ class DetectedLanguage(msrest.serialization.Model): :param iso6391_name: Required. A two letter representation of the detected language according to the ISO 639-1 standard (e.g. en, fr). :type iso6391_name: str - :param score: Required. A confidence score between 0 and 1. Scores close to 1 indicate 100% - certainty that the identified language is true. - :type score: float + :param confidence_score: Required. A confidence score between 0 and 1. Scores close to 1 + indicate 100% certainty that the identified language is true. + :type confidence_score: float """ _validation = { 'name': {'required': True}, 'iso6391_name': {'required': True}, - 'score': {'required': True}, + 'confidence_score': {'required': True}, } _attribute_map = { 'name': {'key': 'name', 'type': 'str'}, 'iso6391_name': {'key': 'iso6391Name', 'type': 'str'}, - 'score': {'key': 'score', 'type': 'float'}, + 'confidence_score': {'key': 'confidenceScore', 'type': 'float'}, } def __init__( @@ -44,13 +46,13 @@ def __init__( *, name: str, iso6391_name: str, - score: float, + confidence_score: float, **kwargs ): super(DetectedLanguage, self).__init__(**kwargs) self.name = name self.iso6391_name = iso6391_name - self.score = score + self.confidence_score = confidence_score class DocumentEntities(msrest.serialization.Model): @@ -62,6 +64,8 @@ class DocumentEntities(msrest.serialization.Model): :type id: str :param entities: Required. Recognized entities in the document. :type entities: list[~azure.ai.textanalytics.models.Entity] + :param warnings: Required. Warnings encountered while processing document. + :type warnings: list[~azure.ai.textanalytics.models.TextAnalyticsWarning] :param statistics: if showStats=true was specified in the request this field will contain information about the document payload. :type statistics: ~azure.ai.textanalytics.models.DocumentStatistics @@ -70,11 +74,13 @@ class DocumentEntities(msrest.serialization.Model): _validation = { 'id': {'required': True}, 'entities': {'required': True}, + 'warnings': {'required': True}, } _attribute_map = { 'id': {'key': 'id', 'type': 'str'}, 'entities': {'key': 'entities', 'type': '[Entity]'}, + 'warnings': {'key': 'warnings', 'type': '[TextAnalyticsWarning]'}, 'statistics': {'key': 'statistics', 'type': 'DocumentStatistics'}, } @@ -83,12 +89,14 @@ def __init__( *, id: str, entities: List["Entity"], + warnings: List["TextAnalyticsWarning"], statistics: Optional["DocumentStatistics"] = None, **kwargs ): super(DocumentEntities, self).__init__(**kwargs) self.id = id self.entities = entities + self.warnings = warnings self.statistics = statistics @@ -135,6 +143,8 @@ class DocumentKeyPhrases(msrest.serialization.Model): :param key_phrases: Required. 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 key_phrases: list[str] + :param warnings: Required. Warnings encountered while processing document. + :type warnings: list[~azure.ai.textanalytics.models.TextAnalyticsWarning] :param statistics: if showStats=true was specified in the request this field will contain information about the document payload. :type statistics: ~azure.ai.textanalytics.models.DocumentStatistics @@ -143,11 +153,13 @@ class DocumentKeyPhrases(msrest.serialization.Model): _validation = { 'id': {'required': True}, 'key_phrases': {'required': True}, + 'warnings': {'required': True}, } _attribute_map = { 'id': {'key': 'id', 'type': 'str'}, 'key_phrases': {'key': 'keyPhrases', 'type': '[str]'}, + 'warnings': {'key': 'warnings', 'type': '[TextAnalyticsWarning]'}, 'statistics': {'key': 'statistics', 'type': 'DocumentStatistics'}, } @@ -156,12 +168,14 @@ def __init__( *, id: str, key_phrases: List[str], + warnings: List["TextAnalyticsWarning"], statistics: Optional["DocumentStatistics"] = None, **kwargs ): super(DocumentKeyPhrases, self).__init__(**kwargs) self.id = id self.key_phrases = key_phrases + self.warnings = warnings self.statistics = statistics @@ -174,6 +188,8 @@ class DocumentLanguage(msrest.serialization.Model): :type id: str :param detected_languages: Required. A list of extracted languages. :type detected_languages: list[~azure.ai.textanalytics.models.DetectedLanguage] + :param warnings: Required. Warnings encountered while processing document. + :type warnings: list[~azure.ai.textanalytics.models.TextAnalyticsWarning] :param statistics: if showStats=true was specified in the request this field will contain information about the document payload. :type statistics: ~azure.ai.textanalytics.models.DocumentStatistics @@ -182,11 +198,13 @@ class DocumentLanguage(msrest.serialization.Model): _validation = { 'id': {'required': True}, 'detected_languages': {'required': True}, + 'warnings': {'required': True}, } _attribute_map = { 'id': {'key': 'id', 'type': 'str'}, 'detected_languages': {'key': 'detectedLanguages', 'type': '[DetectedLanguage]'}, + 'warnings': {'key': 'warnings', 'type': '[TextAnalyticsWarning]'}, 'statistics': {'key': 'statistics', 'type': 'DocumentStatistics'}, } @@ -195,12 +213,14 @@ def __init__( *, id: str, detected_languages: List["DetectedLanguage"], + warnings: List["TextAnalyticsWarning"], statistics: Optional["DocumentStatistics"] = None, **kwargs ): super(DocumentLanguage, self).__init__(**kwargs) self.id = id self.detected_languages = detected_languages + self.warnings = warnings self.statistics = statistics @@ -213,6 +233,8 @@ class DocumentLinkedEntities(msrest.serialization.Model): :type id: str :param entities: Required. Recognized well-known entities in the document. :type entities: list[~azure.ai.textanalytics.models.LinkedEntity] + :param warnings: Required. Warnings encountered while processing document. + :type warnings: list[~azure.ai.textanalytics.models.TextAnalyticsWarning] :param statistics: if showStats=true was specified in the request this field will contain information about the document payload. :type statistics: ~azure.ai.textanalytics.models.DocumentStatistics @@ -221,11 +243,13 @@ class DocumentLinkedEntities(msrest.serialization.Model): _validation = { 'id': {'required': True}, 'entities': {'required': True}, + 'warnings': {'required': True}, } _attribute_map = { 'id': {'key': 'id', 'type': 'str'}, 'entities': {'key': 'entities', 'type': '[LinkedEntity]'}, + 'warnings': {'key': 'warnings', 'type': '[TextAnalyticsWarning]'}, 'statistics': {'key': 'statistics', 'type': 'DocumentStatistics'}, } @@ -234,12 +258,14 @@ def __init__( *, id: str, entities: List["LinkedEntity"], + warnings: List["TextAnalyticsWarning"], statistics: Optional["DocumentStatistics"] = None, **kwargs ): super(DocumentLinkedEntities, self).__init__(**kwargs) self.id = id self.entities = entities + self.warnings = warnings self.statistics = statistics @@ -256,26 +282,30 @@ class DocumentSentiment(msrest.serialization.Model): :param statistics: if showStats=true was specified in the request this field will contain information about the document payload. :type statistics: ~azure.ai.textanalytics.models.DocumentStatistics - :param document_scores: Required. Document level sentiment confidence scores between 0 and 1 + :param confidence_scores: Required. Document level sentiment confidence scores between 0 and 1 for each sentiment class. - :type document_scores: ~azure.ai.textanalytics.models.SentimentConfidenceScorePerLabel + :type confidence_scores: ~azure.ai.textanalytics.models.SentimentConfidenceScorePerLabel :param sentences: Required. Sentence level sentiment analysis. :type sentences: list[~azure.ai.textanalytics.models.SentenceSentiment] + :param warnings: Required. Warnings encountered while processing document. + :type warnings: list[~azure.ai.textanalytics.models.TextAnalyticsWarning] """ _validation = { 'id': {'required': True}, 'sentiment': {'required': True}, - 'document_scores': {'required': True}, + 'confidence_scores': {'required': True}, 'sentences': {'required': True}, + 'warnings': {'required': True}, } _attribute_map = { 'id': {'key': 'id', 'type': 'str'}, 'sentiment': {'key': 'sentiment', 'type': 'str'}, 'statistics': {'key': 'statistics', 'type': 'DocumentStatistics'}, - 'document_scores': {'key': 'documentScores', 'type': 'SentimentConfidenceScorePerLabel'}, + 'confidence_scores': {'key': 'confidenceScores', 'type': 'SentimentConfidenceScorePerLabel'}, 'sentences': {'key': 'sentences', 'type': '[SentenceSentiment]'}, + 'warnings': {'key': 'warnings', 'type': '[TextAnalyticsWarning]'}, } def __init__( @@ -283,8 +313,9 @@ def __init__( *, id: str, sentiment: Union[str, "DocumentSentimentValue"], - document_scores: "SentimentConfidenceScorePerLabel", + confidence_scores: "SentimentConfidenceScorePerLabel", sentences: List["SentenceSentiment"], + warnings: List["TextAnalyticsWarning"], statistics: Optional["DocumentStatistics"] = None, **kwargs ): @@ -292,8 +323,9 @@ def __init__( self.id = id self.sentiment = sentiment self.statistics = statistics - self.document_scores = document_scores + self.confidence_scores = confidence_scores self.sentences = sentences + self.warnings = warnings class DocumentStatistics(msrest.serialization.Model): @@ -381,53 +413,53 @@ class Entity(msrest.serialization.Model): :param text: Required. Entity text as appears in the request. :type text: str - :param type: Required. Entity type, such as Person/Location/Org/SSN etc. - :type type: str - :param subtype: Entity sub type, such as Age/Year/TimeRange etc. - :type subtype: str + :param category: Required. Entity type, such as Person/Location/Org/SSN etc. + :type category: str + :param subcategory: Entity sub type, such as Age/Year/TimeRange etc. + :type subcategory: str :param offset: Required. Start position (in Unicode characters) for the entity text. :type offset: int :param length: Required. Length (in Unicode characters) for the entity text. :type length: int - :param score: Required. Confidence score between 0 and 1 of the extracted entity. - :type score: float + :param confidence_score: Required. Confidence score between 0 and 1 of the extracted entity. + :type confidence_score: float """ _validation = { 'text': {'required': True}, - 'type': {'required': True}, + 'category': {'required': True}, 'offset': {'required': True}, 'length': {'required': True}, - 'score': {'required': True}, + 'confidence_score': {'required': True}, } _attribute_map = { 'text': {'key': 'text', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'subtype': {'key': 'subtype', 'type': 'str'}, + 'category': {'key': 'category', 'type': 'str'}, + 'subcategory': {'key': 'subcategory', 'type': 'str'}, 'offset': {'key': 'offset', 'type': 'int'}, 'length': {'key': 'length', 'type': 'int'}, - 'score': {'key': 'score', 'type': 'float'}, + 'confidence_score': {'key': 'confidenceScore', 'type': 'float'}, } def __init__( self, *, text: str, - type: str, + category: str, offset: int, length: int, - score: float, - subtype: Optional[str] = None, + confidence_score: float, + subcategory: Optional[str] = None, **kwargs ): super(Entity, self).__init__(**kwargs) self.text = text - self.type = type - self.subtype = subtype + self.category = category + self.subcategory = subcategory self.offset = offset self.length = length - self.score = score + self.confidence_score = confidence_score class EntityLinkingResult(msrest.serialization.Model): @@ -491,8 +523,8 @@ class InnerError(msrest.serialization.Model): :type details: dict[str, str] :param target: Error target. :type target: str - :param inner_error: Inner error contains more specific information. - :type inner_error: ~azure.ai.textanalytics.models.InnerError + :param innererror: Inner error contains more specific information. + :type innererror: ~azure.ai.textanalytics.models.InnerError """ _validation = { @@ -505,7 +537,7 @@ class InnerError(msrest.serialization.Model): 'message': {'key': 'message', 'type': 'str'}, 'details': {'key': 'details', 'type': '{str}'}, 'target': {'key': 'target', 'type': 'str'}, - 'inner_error': {'key': 'innerError', 'type': 'InnerError'}, + 'innererror': {'key': 'innererror', 'type': 'InnerError'}, } def __init__( @@ -515,7 +547,7 @@ def __init__( message: str, details: Optional[Dict[str, str]] = None, target: Optional[str] = None, - inner_error: Optional["InnerError"] = None, + innererror: Optional["InnerError"] = None, **kwargs ): super(InnerError, self).__init__(**kwargs) @@ -523,7 +555,7 @@ def __init__( self.message = message self.details = details self.target = target - self.inner_error = inner_error + self.innererror = innererror class KeyPhraseResult(msrest.serialization.Model): @@ -743,9 +775,9 @@ class Match(msrest.serialization.Model): All required parameters must be populated in order to send to Azure. - :param score: Required. If a well-known item is recognized, a decimal number denoting the - confidence level between 0 and 1 will be returned. - :type score: float + :param confidence_score: Required. If a well-known item is recognized, a decimal number + denoting the confidence level between 0 and 1 will be returned. + :type confidence_score: float :param text: Required. Entity text as appears in the request. :type text: str :param offset: Required. Start position (in Unicode characters) for the entity match text. @@ -755,14 +787,14 @@ class Match(msrest.serialization.Model): """ _validation = { - 'score': {'required': True}, + 'confidence_score': {'required': True}, 'text': {'required': True}, 'offset': {'required': True}, 'length': {'required': True}, } _attribute_map = { - 'score': {'key': 'score', 'type': 'float'}, + 'confidence_score': {'key': 'confidenceScore', 'type': 'float'}, 'text': {'key': 'text', 'type': 'str'}, 'offset': {'key': 'offset', 'type': 'int'}, 'length': {'key': 'length', 'type': 'int'}, @@ -771,14 +803,14 @@ class Match(msrest.serialization.Model): def __init__( self, *, - score: float, + confidence_score: float, text: str, offset: int, length: int, **kwargs ): super(Match, self).__init__(**kwargs) - self.score = score + self.confidence_score = confidence_score self.text = text self.offset = offset self.length = length @@ -903,51 +935,51 @@ class SentenceSentiment(msrest.serialization.Model): All required parameters must be populated in order to send to Azure. + :param text: The sentence text. + :type text: str :param sentiment: Required. The predicted Sentiment for the sentence. Possible values include: "positive", "neutral", "negative". :type sentiment: str or ~azure.ai.textanalytics.models.SentenceSentimentValue - :param sentence_scores: Required. The sentiment confidence score between 0 and 1 for the + :param confidence_scores: Required. The sentiment confidence score between 0 and 1 for the sentence for all classes. - :type sentence_scores: ~azure.ai.textanalytics.models.SentimentConfidenceScorePerLabel + :type confidence_scores: ~azure.ai.textanalytics.models.SentimentConfidenceScorePerLabel :param offset: Required. The sentence offset from the start of the document. :type offset: int :param length: Required. The length of the sentence by Unicode standard. :type length: int - :param warnings: The warnings generated for the sentence. - :type warnings: list[str] """ _validation = { 'sentiment': {'required': True}, - 'sentence_scores': {'required': True}, + 'confidence_scores': {'required': True}, 'offset': {'required': True}, 'length': {'required': True}, } _attribute_map = { + 'text': {'key': 'text', 'type': 'str'}, 'sentiment': {'key': 'sentiment', 'type': 'str'}, - 'sentence_scores': {'key': 'sentenceScores', 'type': 'SentimentConfidenceScorePerLabel'}, + 'confidence_scores': {'key': 'confidenceScores', 'type': 'SentimentConfidenceScorePerLabel'}, 'offset': {'key': 'offset', 'type': 'int'}, 'length': {'key': 'length', 'type': 'int'}, - 'warnings': {'key': 'warnings', 'type': '[str]'}, } def __init__( self, *, sentiment: Union[str, "SentenceSentimentValue"], - sentence_scores: "SentimentConfidenceScorePerLabel", + confidence_scores: "SentimentConfidenceScorePerLabel", offset: int, length: int, - warnings: Optional[List[str]] = None, + text: Optional[str] = None, **kwargs ): super(SentenceSentiment, self).__init__(**kwargs) + self.text = text self.sentiment = sentiment - self.sentence_scores = sentence_scores + self.confidence_scores = confidence_scores self.offset = offset self.length = length - self.warnings = warnings class SentimentConfidenceScorePerLabel(msrest.serialization.Model): @@ -1046,8 +1078,8 @@ class TextAnalyticsError(msrest.serialization.Model): :type message: str :param target: Error target. :type target: str - :param inner_error: Inner error contains more specific information. - :type inner_error: ~azure.ai.textanalytics.models.InnerError + :param innererror: Inner error contains more specific information. + :type innererror: ~azure.ai.textanalytics.models.InnerError :param details: Details about specific errors that led to this reported error. :type details: list[~azure.ai.textanalytics.models.TextAnalyticsError] """ @@ -1061,7 +1093,7 @@ class TextAnalyticsError(msrest.serialization.Model): 'code': {'key': 'code', 'type': 'str'}, 'message': {'key': 'message', 'type': 'str'}, 'target': {'key': 'target', 'type': 'str'}, - 'inner_error': {'key': 'innerError', 'type': 'InnerError'}, + 'innererror': {'key': 'innererror', 'type': 'InnerError'}, 'details': {'key': 'details', 'type': '[TextAnalyticsError]'}, } @@ -1071,7 +1103,7 @@ def __init__( code: Union[str, "ErrorCodeValue"], message: str, target: Optional[str] = None, - inner_error: Optional["InnerError"] = None, + innererror: Optional["InnerError"] = None, details: Optional[List["TextAnalyticsError"]] = None, **kwargs ): @@ -1079,5 +1111,44 @@ def __init__( self.code = code self.message = message self.target = target - self.inner_error = inner_error + self.innererror = innererror self.details = details + + +class TextAnalyticsWarning(msrest.serialization.Model): + """TextAnalyticsWarning. + + All required parameters must be populated in order to send to Azure. + + :param code: Required. Error code. Possible values include: "LongWordsInDocument", + "DocumentTruncated". + :type code: str or ~azure.ai.textanalytics.models.WarningCodeValue + :param message: Required. Warning message. + :type message: str + :param target_ref: A JSON pointer reference indicating the target object. + :type target_ref: str + """ + + _validation = { + 'code': {'required': True}, + 'message': {'required': True}, + } + + _attribute_map = { + 'code': {'key': 'code', 'type': 'str'}, + 'message': {'key': 'message', 'type': 'str'}, + 'target_ref': {'key': 'targetRef', 'type': 'str'}, + } + + def __init__( + self, + *, + code: Union[str, "WarningCodeValue"], + message: str, + target_ref: Optional[str] = None, + **kwargs + ): + super(TextAnalyticsWarning, self).__init__(**kwargs) + self.code = code + self.message = message + self.target_ref = target_ref diff --git a/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_generated/models/_text_analytics_client_enums.py b/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_generated/models/_text_analytics_client_enums.py index adc65f8c3af3..e96d02393a83 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_generated/models/_text_analytics_client_enums.py +++ b/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_generated/models/_text_analytics_client_enums.py @@ -8,6 +8,15 @@ from enum import Enum +class DocumentSentimentValue(str, Enum): + """Predicted sentiment for document (Negative, Neutral, Positive, or Mixed). + """ + + positive = "positive" + neutral = "neutral" + negative = "negative" + mixed = "mixed" + class ErrorCodeValue(str, Enum): """Error code. """ @@ -39,11 +48,9 @@ class SentenceSentimentValue(str, Enum): neutral = "neutral" negative = "negative" -class DocumentSentimentValue(str, Enum): - """Predicted sentiment for document (Negative, Neutral, Positive, or Mixed). +class WarningCodeValue(str, Enum): + """Error code. """ - positive = "positive" - neutral = "neutral" - negative = "negative" - mixed = "mixed" + long_words_in_document = "LongWordsInDocument" + document_truncated = "DocumentTruncated" diff --git a/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_generated/operations/_text_analytics_client_operations.py b/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_generated/operations/_text_analytics_client_operations.py index 34283a7291af..77c33a1778c7 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_generated/operations/_text_analytics_client_operations.py +++ b/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_generated/operations/_text_analytics_client_operations.py @@ -5,7 +5,7 @@ # Code generated by Microsoft (R) AutoRest Code Generator. # Changes may cause incorrect behavior and will be lost if the code is regenerated. # -------------------------------------------------------------------------- -from typing import Any, Callable, Dict, Generic, List, Optional, TypeVar +from typing import TYPE_CHECKING import warnings from azure.core.exceptions import HttpResponseError, ResourceExistsError, ResourceNotFoundError, map_error @@ -14,14 +14,18 @@ from .. import models -T = TypeVar('T') -ClsType = Optional[Callable[[PipelineResponse[HttpRequest, HttpResponse], T, Dict[str, Any]], Any]] +if TYPE_CHECKING: + # pylint: disable=unused-import,ungrouped-imports + from typing import Any, Callable, Dict, Generic, List, Optional, TypeVar + + T = TypeVar('T') + ClsType = Optional[Callable[[PipelineResponse[HttpRequest, HttpResponse], T, Dict[str, Any]], Any]] class TextAnalyticsClientOperationsMixin(object): def entities_recognition_general( self, - documents, # type: List["MultiLanguageInput"] + documents, # type: List["models.MultiLanguageInput"] model_version=None, # type: Optional[str] show_stats=None, # type: Optional[bool] **kwargs # type: Any @@ -45,85 +49,14 @@ def entities_recognition_general( :raises: ~azure.core.exceptions.HttpResponseError """ cls = kwargs.pop('cls', None) # type: ClsType["models.EntitiesResult"] - error_map = kwargs.pop('error_map', {404: ResourceNotFoundError, 409: ResourceExistsError}) - - _input = models.MultiLanguageBatchInput(documents=documents) - content_type = kwargs.pop("content_type", "application/json") - - # Construct URL - url = self.entities_recognition_general.metadata['url'] - path_format_arguments = { - 'Endpoint': self._serialize.url("self._config.endpoint", self._config.endpoint, 'str', skip_quote=True), - } - url = self._client.format_url(url, **path_format_arguments) - - # Construct parameters - query_parameters = {} # type: Dict[str, Any] - if model_version is not None: - query_parameters['model-version'] = self._serialize.query("model_version", model_version, 'str') - if show_stats is not None: - query_parameters['showStats'] = self._serialize.query("show_stats", show_stats, 'bool') - - # Construct headers - header_parameters = {} # type: Dict[str, Any] - header_parameters['Content-Type'] = self._serialize.header("content_type", content_type, 'str') - header_parameters['Accept'] = 'application/json' - - # Construct and send request - body_content_kwargs = {} # type: Dict[str, Any] - body_content = self._serialize.body(_input, 'MultiLanguageBatchInput') - body_content_kwargs['content'] = body_content - request = self._client.post(url, query_parameters, header_parameters, **body_content_kwargs) - - pipeline_response = self._client._pipeline.run(request, stream=False, **kwargs) - response = pipeline_response.http_response - - if response.status_code not in [200]: - map_error(status_code=response.status_code, response=response, error_map=error_map) - error = self._deserialize(models.TextAnalyticsError, response) - raise HttpResponseError(response=response, model=error) - - deserialized = self._deserialize('EntitiesResult', pipeline_response) - - if cls: - return cls(pipeline_response, deserialized, {}) - - return deserialized - entities_recognition_general.metadata = {'url': '/entities/recognition/general'} - - def entities_recognition_pii( - self, - documents, # type: List["MultiLanguageInput"] - model_version=None, # type: Optional[str] - show_stats=None, # type: Optional[bool] - **kwargs # type: Any - ): - # type: (...) -> "models.EntitiesResult" - """The API returns a list of entities with personal information (\"SSN\", \"Bank Account\" etc) in the document. For the list of supported entity types, check :code:`Supported Entity Types in Text Analytics API`. See the :code:`Supported languages in Text Analytics API` for the list of enabled languages. - - Entities containing personal information. - - :param documents: The set of documents to process as part of this batch. - :type documents: list[~azure.ai.textanalytics.models.MultiLanguageInput] - :param model_version: (Optional) This value indicates which model will be used for scoring. If - a model-version is not specified, the API should default to the latest, non-preview version. - :type model_version: str - :param show_stats: (Optional) if set to true, response will contain input and document level - statistics. - :type show_stats: bool - :keyword callable cls: A custom type or function that will be passed the direct response - :return: EntitiesResult or the result of cls(response) - :rtype: ~azure.ai.textanalytics.models.EntitiesResult - :raises: ~azure.core.exceptions.HttpResponseError - """ - cls = kwargs.pop('cls', None) # type: ClsType["models.EntitiesResult"] - error_map = kwargs.pop('error_map', {404: ResourceNotFoundError, 409: ResourceExistsError}) + error_map = {404: ResourceNotFoundError, 409: ResourceExistsError} + error_map.update(kwargs.pop('error_map', {})) _input = models.MultiLanguageBatchInput(documents=documents) content_type = kwargs.pop("content_type", "application/json") # Construct URL - url = self.entities_recognition_pii.metadata['url'] + url = self.entities_recognition_general.metadata['url'] # type: ignore path_format_arguments = { 'Endpoint': self._serialize.url("self._config.endpoint", self._config.endpoint, 'str', skip_quote=True), } @@ -161,11 +94,11 @@ def entities_recognition_pii( return cls(pipeline_response, deserialized, {}) return deserialized - entities_recognition_pii.metadata = {'url': '/entities/recognition/pii'} + entities_recognition_general.metadata = {'url': '/entities/recognition/general'} # type: ignore def entities_linking( self, - documents, # type: List["MultiLanguageInput"] + documents, # type: List["models.MultiLanguageInput"] model_version=None, # type: Optional[str] show_stats=None, # type: Optional[bool] **kwargs # type: Any @@ -189,13 +122,14 @@ def entities_linking( :raises: ~azure.core.exceptions.HttpResponseError """ cls = kwargs.pop('cls', None) # type: ClsType["models.EntityLinkingResult"] - error_map = kwargs.pop('error_map', {404: ResourceNotFoundError, 409: ResourceExistsError}) + error_map = {404: ResourceNotFoundError, 409: ResourceExistsError} + error_map.update(kwargs.pop('error_map', {})) _input = models.MultiLanguageBatchInput(documents=documents) content_type = kwargs.pop("content_type", "application/json") # Construct URL - url = self.entities_linking.metadata['url'] + url = self.entities_linking.metadata['url'] # type: ignore path_format_arguments = { 'Endpoint': self._serialize.url("self._config.endpoint", self._config.endpoint, 'str', skip_quote=True), } @@ -233,11 +167,11 @@ def entities_linking( return cls(pipeline_response, deserialized, {}) return deserialized - entities_linking.metadata = {'url': '/entities/linking'} + entities_linking.metadata = {'url': '/entities/linking'} # type: ignore def key_phrases( self, - documents, # type: List["MultiLanguageInput"] + documents, # type: List["models.MultiLanguageInput"] model_version=None, # type: Optional[str] show_stats=None, # type: Optional[bool] **kwargs # type: Any @@ -261,13 +195,14 @@ def key_phrases( :raises: ~azure.core.exceptions.HttpResponseError """ cls = kwargs.pop('cls', None) # type: ClsType["models.KeyPhraseResult"] - error_map = kwargs.pop('error_map', {404: ResourceNotFoundError, 409: ResourceExistsError}) + error_map = {404: ResourceNotFoundError, 409: ResourceExistsError} + error_map.update(kwargs.pop('error_map', {})) _input = models.MultiLanguageBatchInput(documents=documents) content_type = kwargs.pop("content_type", "application/json") # Construct URL - url = self.key_phrases.metadata['url'] + url = self.key_phrases.metadata['url'] # type: ignore path_format_arguments = { 'Endpoint': self._serialize.url("self._config.endpoint", self._config.endpoint, 'str', skip_quote=True), } @@ -305,11 +240,11 @@ def key_phrases( return cls(pipeline_response, deserialized, {}) return deserialized - key_phrases.metadata = {'url': '/keyPhrases'} + key_phrases.metadata = {'url': '/keyPhrases'} # type: ignore def languages( self, - documents, # type: List["LanguageInput"] + documents, # type: List["models.LanguageInput"] model_version=None, # type: Optional[str] show_stats=None, # type: Optional[bool] **kwargs # type: Any @@ -333,13 +268,14 @@ def languages( :raises: ~azure.core.exceptions.HttpResponseError """ cls = kwargs.pop('cls', None) # type: ClsType["models.LanguageResult"] - error_map = kwargs.pop('error_map', {404: ResourceNotFoundError, 409: ResourceExistsError}) + error_map = {404: ResourceNotFoundError, 409: ResourceExistsError} + error_map.update(kwargs.pop('error_map', {})) _input = models.LanguageBatchInput(documents=documents) content_type = kwargs.pop("content_type", "application/json") # Construct URL - url = self.languages.metadata['url'] + url = self.languages.metadata['url'] # type: ignore path_format_arguments = { 'Endpoint': self._serialize.url("self._config.endpoint", self._config.endpoint, 'str', skip_quote=True), } @@ -377,11 +313,11 @@ def languages( return cls(pipeline_response, deserialized, {}) return deserialized - languages.metadata = {'url': '/languages'} + languages.metadata = {'url': '/languages'} # type: ignore def sentiment( self, - documents, # type: List["MultiLanguageInput"] + documents, # type: List["models.MultiLanguageInput"] model_version=None, # type: Optional[str] show_stats=None, # type: Optional[bool] **kwargs # type: Any @@ -405,13 +341,14 @@ def sentiment( :raises: ~azure.core.exceptions.HttpResponseError """ cls = kwargs.pop('cls', None) # type: ClsType["models.SentimentResponse"] - error_map = kwargs.pop('error_map', {404: ResourceNotFoundError, 409: ResourceExistsError}) + error_map = {404: ResourceNotFoundError, 409: ResourceExistsError} + error_map.update(kwargs.pop('error_map', {})) _input = models.MultiLanguageBatchInput(documents=documents) content_type = kwargs.pop("content_type", "application/json") # Construct URL - url = self.sentiment.metadata['url'] + url = self.sentiment.metadata['url'] # type: ignore path_format_arguments = { 'Endpoint': self._serialize.url("self._config.endpoint", self._config.endpoint, 'str', skip_quote=True), } @@ -449,4 +386,4 @@ def sentiment( return cls(pipeline_response, deserialized, {}) return deserialized - sentiment.metadata = {'url': '/sentiment'} + sentiment.metadata = {'url': '/sentiment'} # type: ignore From a4ddd27454093c9d4d078d73a73384b629f15d01 Mon Sep 17 00:00:00 2001 From: iscai-msft Date: Thu, 23 Apr 2020 12:22:17 -0400 Subject: [PATCH 2/3] detect language and recognized entities still have errors --- .../azure/ai/textanalytics/_models.py | 21 ++- .../ai/textanalytics/_response_handlers.py | 8 +- .../textanalytics/_text_analytics_client.py | 7 +- .../aio/_text_analytics_client_async.py | 7 +- ...ment.test_all_successful_passing_dict.yaml | 17 +- ...uccessful_passing_text_document_input.yaml | 17 +- ...nalyze_sentiment.test_bad_credentials.yaml | 22 ++- ...lyze_sentiment.test_bad_model_version.yaml | 12 +- ...entiment.test_bad_model_version_error.yaml | 10 +- ..._sentiment.test_batch_size_over_limit.yaml | 12 +- ...ment.test_batch_size_over_limit_error.yaml | 12 +- ...t_client_passed_default_language_hint.yaml | 45 +++-- ...t_attribute_error_no_result_attribute.yaml | 12 +- ...attribute_error_nonexistent_attribute.yaml | 12 +- ...nalyze_sentiment.test_document_errors.yaml | 14 +- ...ze_sentiment.test_duplicate_ids_error.yaml | 12 +- ...sentiment.test_empty_credential_class.yaml | 22 ++- ..._sentiment.test_input_with_all_errors.yaml | 16 +- ...sentiment.test_input_with_some_errors.yaml | 18 +- ...sentiment.test_language_kwarg_spanish.yaml | 13 +- ...ment.test_missing_input_records_error.yaml | 42 ----- ...alyze_sentiment.test_out_of_order_ids.yaml | 14 +- .../test_analyze_sentiment.test_pass_cls.yaml | 13 +- ...ze_sentiment.test_passing_only_string.yaml | 19 +- ....test_per_item_dont_use_language_hint.yaml | 15 +- ...entiment.test_rotate_subscription_key.yaml | 52 ++++-- ...ent.test_show_stats_and_model_version.yaml | 14 +- ...est_analyze_sentiment.test_user_agent.yaml | 15 +- ...st_whole_batch_dont_use_language_hint.yaml | 16 +- ...timent.test_whole_batch_language_hint.yaml | 16 +- ...le_batch_language_hint_and_dict_input.yaml | 15 +- ...language_hint_and_dict_per_item_hints.yaml | 15 +- ...ole_batch_language_hint_and_obj_input.yaml | 25 ++- ..._language_hint_and_obj_per_item_hints.yaml | 25 ++- ...sync.test_all_successful_passing_dict.yaml | 19 +- ...uccessful_passing_text_document_input.yaml | 19 +- ..._sentiment_async.test_bad_credentials.yaml | 19 +- ...entiment_async.test_bad_model_version.yaml | 14 +- ...nt_async.test_bad_model_version_error.yaml | 12 +- ...ment_async.test_batch_size_over_limit.yaml | 14 +- ...sync.test_batch_size_over_limit_error.yaml | 14 +- ...t_client_passed_default_language_hint.yaml | 51 +++--- ...t_attribute_error_no_result_attribute.yaml | 14 +- ...attribute_error_nonexistent_attribute.yaml | 12 +- ..._sentiment_async.test_document_errors.yaml | 18 +- ...timent_async.test_duplicate_ids_error.yaml | 14 +- ...ent_async.test_empty_credential_class.yaml | 19 +- ...ment_async.test_input_with_all_errors.yaml | 18 +- ...ent_async.test_input_with_some_errors.yaml | 20 ++- ...ent_async.test_language_kwarg_spanish.yaml | 15 +- ...sync.test_missing_input_records_error.yaml | 32 ---- ...sentiment_async.test_out_of_order_ids.yaml | 16 +- ...analyze_sentiment_async.test_pass_cls.yaml | 15 +- ...timent_async.test_passing_only_string.yaml | 21 ++- ....test_per_item_dont_use_language_hint.yaml | 17 +- ...nt_async.test_rotate_subscription_key.yaml | 53 +++--- ...ync.test_show_stats_and_model_version.yaml | 16 +- ...alyze_sentiment_async.test_user_agent.yaml | 17 +- ...st_whole_batch_dont_use_language_hint.yaml | 18 +- ..._async.test_whole_batch_language_hint.yaml | 18 +- ...le_batch_language_hint_and_dict_input.yaml | 17 +- ...language_hint_and_dict_per_item_hints.yaml | 17 +- ...ole_batch_language_hint_and_obj_input.yaml | 27 ++- ..._language_hint_and_obj_per_item_hints.yaml | 27 ++- ...uage.test_all_successful_passing_dict.yaml | 47 ----- ...uccessful_passing_text_document_input.yaml | 47 ----- ..._detect_language.test_bad_credentials.yaml | 22 ++- ...etect_language.test_bad_model_version.yaml | 10 +- ...language.test_bad_model_version_error.yaml | 10 +- ...t_language.test_batch_size_over_limit.yaml | 12 +- ...uage.test_batch_size_over_limit_error.yaml | 12 +- ...st_client_passed_default_country_hint.yaml | 134 -------------- ...tect_language.test_country_hint_kwarg.yaml | 44 ----- ...etect_language.test_country_hint_none.yaml | 170 ------------------ ...t_attribute_error_no_result_attribute.yaml | 12 +- ...attribute_error_nonexistent_attribute.yaml | 12 +- ..._detect_language.test_document_errors.yaml | 12 +- ...ect_language.test_duplicate_ids_error.yaml | 12 +- ..._language.test_empty_credential_class.yaml | 22 ++- ...t_language.test_input_with_all_errors.yaml | 18 +- ..._language.test_input_with_some_errors.yaml | 52 ------ ...uage.test_missing_input_records_error.yaml | 42 ----- ...detect_language.test_out_of_order_ids.yaml | 48 ----- .../test_detect_language.test_pass_cls.yaml | 12 +- ...ect_language.test_passing_only_string.yaml | 49 ----- ...e.test_per_item_dont_use_country_hint.yaml | 46 ----- ...language.test_rotate_subscription_key.yaml | 124 ------------- ...age.test_show_stats_and_model_version.yaml | 48 ----- .../test_detect_language.test_user_agent.yaml | 46 ----- ...anguage.test_whole_batch_country_hint.yaml | 46 ----- ...ole_batch_country_hint_and_dict_input.yaml | 46 ----- ..._country_hint_and_dict_per_item_hints.yaml | 46 ----- ...hole_batch_country_hint_and_obj_input.yaml | 46 ----- ...h_country_hint_and_obj_per_item_hints.yaml | 46 ----- ...est_whole_batch_dont_use_country_hint.yaml | 46 ----- ...ases.test_all_successful_passing_dict.yaml | 14 +- ...uccessful_passing_text_document_input.yaml | 14 +- ...ract_key_phrases.test_bad_credentials.yaml | 22 ++- ...ct_key_phrases.test_bad_model_version.yaml | 10 +- ..._phrases.test_bad_model_version_error.yaml | 10 +- ...ey_phrases.test_batch_size_over_limit.yaml | 12 +- ...ases.test_batch_size_over_limit_error.yaml | 12 +- ...t_client_passed_default_language_hint.yaml | 46 ++--- ...t_attribute_error_no_result_attribute.yaml | 12 +- ...attribute_error_nonexistent_attribute.yaml | 10 +- ...ract_key_phrases.test_document_errors.yaml | 16 +- ..._key_phrases.test_duplicate_ids_error.yaml | 10 +- ...y_phrases.test_empty_credential_class.yaml | 22 ++- ...ey_phrases.test_input_with_all_errors.yaml | 14 +- ...y_phrases.test_input_with_some_errors.yaml | 12 +- ...y_phrases.test_language_kwarg_spanish.yaml | 12 +- ...ases.test_missing_input_records_error.yaml | 42 ----- ...act_key_phrases.test_out_of_order_ids.yaml | 14 +- ...est_extract_key_phrases.test_pass_cls.yaml | 10 +- ..._key_phrases.test_passing_only_string.yaml | 16 +- ....test_per_item_dont_use_language_hint.yaml | 14 +- ..._phrases.test_rotate_subscription_key.yaml | 50 +++--- ...ses.test_show_stats_and_model_version.yaml | 12 +- ...t_extract_key_phrases.test_user_agent.yaml | 14 +- ...st_whole_batch_dont_use_language_hint.yaml | 12 +- ...hrases.test_whole_batch_language_hint.yaml | 16 +- ...language_hint_and_dict_per_item_hints.yaml | 16 +- ...ole_batch_language_hint_and_obj_input.yaml | 17 +- ..._language_hint_and_obj_per_item_hints.yaml | 17 +- ...sync.test_all_successful_passing_dict.yaml | 16 +- ...uccessful_passing_text_document_input.yaml | 16 +- ...ey_phrases_async.test_bad_credentials.yaml | 19 +- ..._phrases_async.test_bad_model_version.yaml | 12 +- ...es_async.test_bad_model_version_error.yaml | 12 +- ...ases_async.test_batch_size_over_limit.yaml | 14 +- ...sync.test_batch_size_over_limit_error.yaml | 14 +- ...t_client_passed_default_language_hint.yaml | 48 ++--- ...t_attribute_error_no_result_attribute.yaml | 14 +- ...attribute_error_nonexistent_attribute.yaml | 14 +- ...ey_phrases_async.test_document_errors.yaml | 18 +- ...hrases_async.test_duplicate_ids_error.yaml | 14 +- ...ses_async.test_empty_credential_class.yaml | 19 +- ...ases_async.test_input_with_all_errors.yaml | 14 +- ...ses_async.test_input_with_some_errors.yaml | 16 +- ...ses_async.test_language_kwarg_spanish.yaml | 14 +- ...sync.test_missing_input_records_error.yaml | 32 ---- ...y_phrases_async.test_out_of_order_ids.yaml | 14 +- ...tract_key_phrases_async.test_pass_cls.yaml | 14 +- ...hrases_async.test_passing_only_string.yaml | 18 +- ....test_per_item_dont_use_language_hint.yaml | 14 +- ...es_async.test_rotate_subscription_key.yaml | 51 +++--- ...ync.test_show_stats_and_model_version.yaml | 14 +- ...act_key_phrases_async.test_user_agent.yaml | 14 +- ...st_whole_batch_dont_use_language_hint.yaml | 14 +- ..._async.test_whole_batch_language_hint.yaml | 18 +- ...language_hint_and_dict_per_item_hints.yaml | 18 +- ...ole_batch_language_hint_and_obj_input.yaml | 19 +- ..._language_hint_and_obj_per_item_hints.yaml | 17 +- ...ties.test_all_successful_passing_dict.yaml | 56 ------ ...uccessful_passing_text_document_input.yaml | 56 ------ ...cognize_entities.test_bad_credentials.yaml | 22 ++- ...gnize_entities.test_bad_model_version.yaml | 10 +- ...entities.test_bad_model_version_error.yaml | 12 +- ...e_entities.test_batch_size_over_limit.yaml | 12 +- ...ties.test_batch_size_over_limit_error.yaml | 12 +- ...t_client_passed_default_language_hint.yaml | 36 ++-- ...t_attribute_error_no_result_attribute.yaml | 14 +- ...attribute_error_nonexistent_attribute.yaml | 12 +- ...cognize_entities.test_document_errors.yaml | 18 +- ...ize_entities.test_duplicate_ids_error.yaml | 12 +- ..._entities.test_empty_credential_class.yaml | 22 ++- ...e_entities.test_input_with_all_errors.yaml | 18 +- ..._entities.test_input_with_some_errors.yaml | 24 +-- ..._entities.test_language_kwarg_spanish.yaml | 13 +- ...ties.test_missing_input_records_error.yaml | 42 ----- ...ognize_entities.test_out_of_order_ids.yaml | 16 +- ...test_recognize_entities.test_pass_cls.yaml | 12 +- ...ize_entities.test_passing_only_string.yaml | 51 +++--- ....test_per_item_dont_use_language_hint.yaml | 12 +- ...entities.test_rotate_subscription_key.yaml | 46 +++-- ...ies.test_show_stats_and_model_version.yaml | 16 +- ...st_recognize_entities.test_user_agent.yaml | 12 +- ...st_whole_batch_dont_use_language_hint.yaml | 12 +- ...tities.test_whole_batch_language_hint.yaml | 12 +- ...language_hint_and_dict_per_item_hints.yaml | 12 +- ...ole_batch_language_hint_and_obj_input.yaml | 12 +- ..._language_hint_and_obj_per_item_hints.yaml | 12 +- ...ties.test_all_successful_passing_dict.yaml | 22 +-- ...uccessful_passing_text_document_input.yaml | 23 +-- ..._linked_entities.test_bad_credentials.yaml | 22 ++- ...inked_entities.test_bad_model_version.yaml | 12 +- ...entities.test_bad_model_version_error.yaml | 12 +- ...d_entities.test_batch_size_over_limit.yaml | 12 +- ...ties.test_batch_size_over_limit_error.yaml | 12 +- ...t_client_passed_default_language_hint.yaml | 36 ++-- ...t_attribute_error_no_result_attribute.yaml | 12 +- ...attribute_error_nonexistent_attribute.yaml | 12 +- ..._linked_entities.test_document_errors.yaml | 16 +- ...ked_entities.test_duplicate_ids_error.yaml | 12 +- ..._entities.test_empty_credential_class.yaml | 22 ++- ...d_entities.test_input_with_all_errors.yaml | 12 +- ..._entities.test_input_with_some_errors.yaml | 19 +- ..._entities.test_language_kwarg_spanish.yaml | 18 +- ...ties.test_missing_input_records_error.yaml | 42 ----- ...linked_entities.test_out_of_order_ids.yaml | 14 +- ...cognize_linked_entities.test_pass_cls.yaml | 12 +- ...ked_entities.test_passing_only_string.yaml | 25 +-- ....test_per_item_dont_use_language_hint.yaml | 12 +- ...entities.test_rotate_subscription_key.yaml | 44 +++-- ...ies.test_show_stats_and_model_version.yaml | 14 +- ...gnize_linked_entities.test_user_agent.yaml | 10 +- ...st_whole_batch_dont_use_language_hint.yaml | 12 +- ...tities.test_whole_batch_language_hint.yaml | 16 +- ...language_hint_and_dict_per_item_hints.yaml | 12 +- ...ole_batch_language_hint_and_obj_input.yaml | 14 +- ..._language_hint_and_obj_per_item_hints.yaml | 10 +- ...t_text_analytics.test_detect_language.yaml | 44 ----- .../azure-ai-textanalytics/tests/testcase.py | 7 +- 213 files changed, 1768 insertions(+), 2986 deletions(-) delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_missing_input_records_error.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_missing_input_records_error.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_all_successful_passing_dict.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_all_successful_passing_text_document_input.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_client_passed_default_country_hint.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_country_hint_kwarg.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_country_hint_none.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_input_with_some_errors.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_missing_input_records_error.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_out_of_order_ids.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_passing_only_string.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_per_item_dont_use_country_hint.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_rotate_subscription_key.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_show_stats_and_model_version.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_user_agent.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_whole_batch_country_hint.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_whole_batch_country_hint_and_dict_input.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_whole_batch_country_hint_and_dict_per_item_hints.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_whole_batch_country_hint_and_obj_input.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_whole_batch_country_hint_and_obj_per_item_hints.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_whole_batch_dont_use_country_hint.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_missing_input_records_error.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_missing_input_records_error.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_all_successful_passing_dict.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_all_successful_passing_text_document_input.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_missing_input_records_error.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_missing_input_records_error.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_text_analytics.test_detect_language.yaml diff --git a/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_models.py b/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_models.py index f1b5aa5821c3..1d720a0796e3 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_models.py +++ b/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_models.py @@ -182,11 +182,11 @@ def __init__(self, **kwargs): def _from_generated(cls, entity): return cls( text=entity.text, - category=entity.type, - subcategory=entity.subtype, + category=entity.category, + subcategory=entity.subcategory, grapheme_offset=entity.offset, grapheme_length=entity.length, - confidence_score=entity.score, + confidence_score=entity.confidence_score, ) def __repr__(self): @@ -219,11 +219,11 @@ def __init__(self, **kwargs): @classmethod def _from_generated(cls, err): - if err.inner_error: + if err.innererror: return cls( - code=err.inner_error.code, - message=err.inner_error.message, - target=err.inner_error.target + code=err.innererror.code, + message=err.innererror.message, + target=err.innererror.target ) return cls( code=err.code, @@ -518,7 +518,7 @@ def __init__(self, **kwargs): @classmethod def _from_generated(cls, match): return cls( - confidence_score=match.score, + confidence_score=match.confidence_score, text=match.text, grapheme_offset=match.offset, grapheme_length=match.length @@ -624,10 +624,9 @@ def __init__(self, **kwargs): def _from_generated(cls, sentence): return cls( sentiment=sentence.sentiment, - confidence_scores=SentimentConfidenceScores._from_generated(sentence.sentence_scores), # pylint: disable=protected-access + confidence_scores=SentimentConfidenceScores._from_generated(sentence.confidence_scores), # pylint: disable=protected-access grapheme_offset=sentence.offset, - grapheme_length=sentence.length, - warnings=sentence.warnings, + grapheme_length=sentence.length ) def __repr__(self): diff --git a/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_response_handlers.py b/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_response_handlers.py index 15c949f97e02..ec1525a5f85e 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_response_handlers.py +++ b/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_response_handlers.py @@ -26,14 +26,13 @@ TextAnalyticsError ) - class CSODataV4Format(ODataV4Format): INNERERROR_LABEL = "innerError" # Service plans to fix casing ("innererror") to reflect ODataV4 error spec def __init__(self, odata_error): try: - if odata_error["error"]["innerError"]: - super(CSODataV4Format, self).__init__(odata_error["error"]["innerError"]) + if odata_error["error"]["innererror"]: + super(CSODataV4Format, self).__init__(odata_error["error"]["innererror"]) except KeyError: super(CSODataV4Format, self).__init__(odata_error) @@ -46,7 +45,6 @@ def process_batch_error(error): raise_error = ClientAuthenticationError raise raise_error(response=error.response, error_format=CSODataV4Format) - def order_results(response, combined): """Order results in the order the user passed them in. @@ -120,6 +118,6 @@ def sentiment_result(sentiment): id=sentiment.id, sentiment=sentiment.sentiment, statistics=TextDocumentStatistics._from_generated(sentiment.statistics), # pylint: disable=protected-access - confidence_scores=SentimentConfidenceScores._from_generated(sentiment.document_scores), # pylint: disable=protected-access + confidence_scores=SentimentConfidenceScores._from_generated(sentiment.confidence_scores), # pylint: disable=protected-access sentences=[SentenceSentiment._from_generated(s) for s in sentiment.sentences], # pylint: disable=protected-access ) diff --git a/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_text_analytics_client.py b/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_text_analytics_client.py index 3d32c1dad8bb..eb4d8f22b4a9 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_text_analytics_client.py +++ b/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/_text_analytics_client.py @@ -13,7 +13,7 @@ TYPE_CHECKING, ) from azure.core.tracing.decorator import distributed_trace -from azure.core.exceptions import HttpResponseError +from azure.core.exceptions import HttpResponseError, ClientAuthenticationError from ._base_client import TextAnalyticsClientBase from ._request_handlers import _validate_batch_input from ._response_handlers import ( @@ -148,6 +148,7 @@ def detect_language( # type: ignore model_version=model_version, show_stats=show_stats, cls=kwargs.pop("cls", language_result), + error_map={401: ClientAuthenticationError}, **kwargs ) except HttpResponseError as error: @@ -212,6 +213,7 @@ def recognize_entities( # type: ignore model_version=model_version, show_stats=show_stats, cls=kwargs.pop("cls", entities_result), + error_map={401: ClientAuthenticationError}, **kwargs ) except HttpResponseError as error: @@ -277,6 +279,7 @@ def recognize_linked_entities( # type: ignore model_version=model_version, show_stats=show_stats, cls=kwargs.pop("cls", linked_entities_result), + error_map={401: ClientAuthenticationError}, **kwargs ) except HttpResponseError as error: @@ -342,6 +345,7 @@ def extract_key_phrases( # type: ignore model_version=model_version, show_stats=show_stats, cls=kwargs.pop("cls", key_phrases_result), + error_map={401: ClientAuthenticationError}, **kwargs ) except HttpResponseError as error: @@ -406,6 +410,7 @@ def analyze_sentiment( # type: ignore model_version=model_version, show_stats=show_stats, cls=kwargs.pop("cls", sentiment_result), + error_map={401: ClientAuthenticationError}, **kwargs ) except HttpResponseError as error: diff --git a/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/aio/_text_analytics_client_async.py b/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/aio/_text_analytics_client_async.py index 5c649e1f5c4d..44d0d39de179 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/aio/_text_analytics_client_async.py +++ b/sdk/textanalytics/azure-ai-textanalytics/azure/ai/textanalytics/aio/_text_analytics_client_async.py @@ -13,7 +13,7 @@ TYPE_CHECKING ) from azure.core.tracing.decorator_async import distributed_trace_async -from azure.core.exceptions import HttpResponseError +from azure.core.exceptions import HttpResponseError, ClientAuthenticationError from ._base_client_async import AsyncTextAnalyticsClientBase from .._request_handlers import _validate_batch_input from .._response_handlers import ( @@ -152,6 +152,7 @@ async def detect_language( # type: ignore model_version=model_version, show_stats=show_stats, cls=kwargs.pop("cls", language_result), + error_map={401: ClientAuthenticationError}, **kwargs ) except HttpResponseError as error: @@ -215,6 +216,7 @@ async def recognize_entities( # type: ignore model_version=model_version, show_stats=show_stats, cls=kwargs.pop("cls", entities_result), + error_map={401: ClientAuthenticationError}, **kwargs ) except HttpResponseError as error: @@ -279,6 +281,7 @@ async def recognize_linked_entities( # type: ignore model_version=model_version, show_stats=show_stats, cls=kwargs.pop("cls", linked_entities_result), + error_map={401: ClientAuthenticationError}, **kwargs ) except HttpResponseError as error: @@ -343,6 +346,7 @@ async def extract_key_phrases( # type: ignore model_version=model_version, show_stats=show_stats, cls=kwargs.pop("cls", key_phrases_result), + error_map={401: ClientAuthenticationError}, **kwargs ) except HttpResponseError as error: @@ -406,6 +410,7 @@ async def analyze_sentiment( # type: ignore model_version=model_version, show_stats=show_stats, cls=kwargs.pop("cls", sentiment_result), + error_map={401: ClientAuthenticationError}, **kwargs ) except HttpResponseError as error: diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_all_successful_passing_dict.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_all_successful_passing_dict.yaml index b889ad5c2ada..8f25ba14afb8 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_all_successful_passing_dict.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_all_successful_passing_dict.yaml @@ -17,22 +17,27 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=true + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=true response: body: - string: '{"statistics":{"documentsCount":3,"validDocumentsCount":3,"erroneousDocumentsCount":0,"transactionsCount":3},"documents":[{"id":"1","sentiment":"neutral","statistics":{"charactersCount":51,"transactionsCount":1},"documentScores":{"positive":0.01,"neutral":0.99,"negative":0.0},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.01,"neutral":0.99,"negative":0.0},"offset":0,"length":51}]},{"id":"2","sentiment":"negative","statistics":{"charactersCount":60,"transactionsCount":1},"documentScores":{"positive":0.01,"neutral":0.22,"negative":0.77},"sentences":[{"sentiment":"negative","sentenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"offset":0,"length":38},{"sentiment":"negative","sentenceScores":{"positive":0.0,"neutral":0.0,"negative":1.0},"offset":39,"length":21}]},{"id":"3","sentiment":"positive","statistics":{"charactersCount":60,"transactionsCount":1},"documentScores":{"positive":0.98,"neutral":0.02,"negative":0.0},"sentences":[{"sentiment":"positive","sentenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"offset":0,"length":36},{"sentiment":"positive","sentenceScores":{"positive":0.96,"neutral":0.03,"negative":0.01},"offset":37,"length":23}]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"statistics":{"documentsCount":3,"validDocumentsCount":3,"erroneousDocumentsCount":0,"transactionsCount":3},"documents":[{"id":"1","sentiment":"neutral","statistics":{"charactersCount":51,"transactionsCount":1},"confidenceScores":{"positive":0.01,"neutral":0.99,"negative":0.0},"sentences":[{"sentiment":"neutral","confidenceScores":{"positive":0.01,"neutral":0.99,"negative":0.0},"offset":0,"length":51,"text":"Microsoft + was founded by Bill Gates and Paul Allen."}],"warnings":[]},{"id":"2","sentiment":"negative","statistics":{"charactersCount":60,"transactionsCount":1},"confidenceScores":{"positive":0.01,"neutral":0.22,"negative":0.77},"sentences":[{"sentiment":"negative","confidenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"offset":0,"length":38,"text":"I + did not like the hotel we stayed at."},{"sentiment":"negative","confidenceScores":{"positive":0.0,"neutral":0.0,"negative":1.0},"offset":39,"length":21,"text":"It + was too expensive."}],"warnings":[]},{"id":"3","sentiment":"positive","statistics":{"charactersCount":60,"transactionsCount":1},"confidenceScores":{"positive":0.98,"neutral":0.02,"negative":0.0},"sentences":[{"sentiment":"positive","confidenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"offset":0,"length":36,"text":"The + restaurant had really good food."},{"sentiment":"positive","confidenceScores":{"positive":0.96,"neutral":0.03,"negative":0.01},"offset":37,"length":23,"text":"I + recommend you try it."}],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - 858f85df-8043-42a6-99fe-3c82c71bd179 + - 3f247cdd-5a72-43e8-bf89-87e53760011b content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:05:51 GMT + - Wed, 22 Apr 2020 22:41:45 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -40,7 +45,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '134' + - '133' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_all_successful_passing_text_document_input.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_all_successful_passing_text_document_input.yaml index 3c383cc1905a..17174c4b284e 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_all_successful_passing_text_document_input.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_all_successful_passing_text_document_input.yaml @@ -17,22 +17,27 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"documents":[{"id":"1","sentiment":"neutral","documentScores":{"positive":0.01,"neutral":0.99,"negative":0.0},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.01,"neutral":0.99,"negative":0.0},"offset":0,"length":51}]},{"id":"2","sentiment":"negative","documentScores":{"positive":0.01,"neutral":0.22,"negative":0.77},"sentences":[{"sentiment":"negative","sentenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"offset":0,"length":38},{"sentiment":"negative","sentenceScores":{"positive":0.0,"neutral":0.0,"negative":1.0},"offset":39,"length":21}]},{"id":"3","sentiment":"positive","documentScores":{"positive":0.98,"neutral":0.02,"negative":0.0},"sentences":[{"sentiment":"positive","sentenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"offset":0,"length":36},{"sentiment":"positive","sentenceScores":{"positive":0.96,"neutral":0.03,"negative":0.01},"offset":37,"length":23}]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"1","sentiment":"neutral","confidenceScores":{"positive":0.01,"neutral":0.99,"negative":0.0},"sentences":[{"sentiment":"neutral","confidenceScores":{"positive":0.01,"neutral":0.99,"negative":0.0},"offset":0,"length":51,"text":"Microsoft + was founded by Bill Gates and Paul Allen."}],"warnings":[]},{"id":"2","sentiment":"negative","confidenceScores":{"positive":0.01,"neutral":0.22,"negative":0.77},"sentences":[{"sentiment":"negative","confidenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"offset":0,"length":38,"text":"I + did not like the hotel we stayed at."},{"sentiment":"negative","confidenceScores":{"positive":0.0,"neutral":0.0,"negative":1.0},"offset":39,"length":21,"text":"It + was too expensive."}],"warnings":[]},{"id":"3","sentiment":"positive","confidenceScores":{"positive":0.98,"neutral":0.02,"negative":0.0},"sentences":[{"sentiment":"positive","confidenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"offset":0,"length":36,"text":"The + restaurant had really good food."},{"sentiment":"positive","confidenceScores":{"positive":0.96,"neutral":0.03,"negative":0.01},"offset":37,"length":23,"text":"I + recommend you try it."}],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - ba050179-1c97-48d4-b587-2dc11de78d35 + - 121950a2-31a7-4fcb-b8cf-97a4633a6d8f content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:05:51 GMT + - Wed, 22 Apr 2020 22:41:45 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -40,7 +45,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '129' + - '146' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_bad_credentials.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_bad_credentials.yaml index 58d447069bb6..97890fc94060 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_bad_credentials.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_bad_credentials.yaml @@ -14,21 +14,31 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"error":{"code":"401","message":"Access denied due to invalid subscription + string: '{"error":{"code":"401","message": "Access denied due to invalid subscription key or wrong API endpoint. Make sure to provide a valid key for an active subscription and use a correct regional API endpoint for your resource."}}' headers: + apim-request-id: + - f514284c-166f-4475-919d-9e708e127da8 content-length: - - '224' + - '225' + content-type: + - application/json date: - - Thu, 02 Apr 2020 15:05:51 GMT + - Wed, 22 Apr 2020 22:41:45 GMT + strict-transport-security: + - max-age=31536000; includeSubDomains; preload + www-authenticate: + - AzureApiManagementKey realm="https://westus2.ppe.cognitiveservices.azure.com/text/analytics",name="Ocp-Apim-Subscription-Key",type="header" + x-content-type-options: + - nosniff status: code: 401 - message: PermissionDenied + message: Access Denied version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_bad_model_version.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_bad_model_version.yaml index e90888253106..60d9fb8b1f95 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_bad_model_version.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_bad_model_version.yaml @@ -14,21 +14,21 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?model-version=old&showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?model-version=old&showStats=false response: body: string: '{"error":{"code":"InvalidRequest","message":"Specified Model version - is incorrect. Allowed values are latest,2019-10-01"}}' + is incorrect. Allowed values are latest,2019-10-01,2020-04-01"}}' headers: apim-request-id: - - 51878960-b983-4ab4-8070-dc81ce57fef9 + - 2dd6cb06-302d-45c7-bdf1-074982682fa4 content-type: - application/json; charset=utf-8 date: - - Thu, 02 Apr 2020 15:05:52 GMT + - Wed, 22 Apr 2020 22:41:45 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -36,7 +36,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '4' + - '6' status: code: 400 message: Bad Request diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_bad_model_version_error.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_bad_model_version_error.yaml index fc57e8c7173a..0b7466bad0c3 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_bad_model_version_error.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_bad_model_version_error.yaml @@ -14,21 +14,21 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?model-version=bad&showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?model-version=bad&showStats=false response: body: string: '{"error":{"code":"InvalidRequest","message":"Specified Model version - is incorrect. Allowed values are latest,2019-10-01"}}' + is incorrect. Allowed values are latest,2019-10-01,2020-04-01"}}' headers: apim-request-id: - - d88ac287-df85-4e79-8bc2-f5805153551e + - 3c8f80e8-1d75-4bc2-bbb2-ecb7f11a2e05 content-type: - application/json; charset=utf-8 date: - - Thu, 02 Apr 2020 15:05:52 GMT + - Wed, 22 Apr 2020 22:41:46 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_batch_size_over_limit.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_batch_size_over_limit.yaml index 3fabd4eb06d9..93da724c8a77 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_batch_size_over_limit.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_batch_size_over_limit.yaml @@ -758,21 +758,21 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innerError":{"code":"InvalidDocumentBatch","message":"Batch + string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innererror":{"code":"InvalidDocumentBatch","message":"Batch request contains too many records. Max 1000 records are permitted."}}}' headers: apim-request-id: - - 91964ae9-68ea-4691-a3c5-257055464cba + - 9fba11f8-3af5-4514-8899-7a6198a48011 content-type: - application/json; charset=utf-8 date: - - Thu, 02 Apr 2020 15:05:53 GMT + - Wed, 22 Apr 2020 22:41:47 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -780,7 +780,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '12' + - '14' status: code: 400 message: Bad Request diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_batch_size_over_limit_error.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_batch_size_over_limit_error.yaml index 0ecbe28eee79..e32a44a7be1c 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_batch_size_over_limit_error.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_batch_size_over_limit_error.yaml @@ -723,21 +723,21 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innerError":{"code":"InvalidDocumentBatch","message":"Batch + string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innererror":{"code":"InvalidDocumentBatch","message":"Batch request contains too many records. Max 1000 records are permitted."}}}' headers: apim-request-id: - - c26d09fa-64fb-4428-a63e-9e330a6c2efe + - cdd3c43c-ef9c-46bd-949f-ab67c74202ae content-type: - application/json; charset=utf-8 date: - - Thu, 02 Apr 2020 15:05:54 GMT + - Wed, 22 Apr 2020 22:41:48 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -745,7 +745,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '13' + - '12' status: code: 400 message: Bad Request diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_client_passed_default_language_hint.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_client_passed_default_language_hint.yaml index 0cc8a0a34661..b1a64cb9e13b 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_client_passed_default_language_hint.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_client_passed_default_language_hint.yaml @@ -16,22 +16,25 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"documents":[{"id":"1","sentiment":"neutral","documentScores":{"positive":0.04,"neutral":0.95,"negative":0.01},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.04,"neutral":0.95,"negative":0.01},"offset":0,"length":22}]},{"id":"2","sentiment":"neutral","documentScores":{"positive":0.01,"neutral":0.5,"negative":0.49},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.01,"neutral":0.5,"negative":0.49},"offset":0,"length":38}]},{"id":"3","sentiment":"positive","documentScores":{"positive":0.97,"neutral":0.02,"negative":0.01},"sentences":[{"sentiment":"positive","sentenceScores":{"positive":0.97,"neutral":0.02,"negative":0.01},"offset":0,"length":36}]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"1","sentiment":"neutral","confidenceScores":{"positive":0.04,"neutral":0.95,"negative":0.01},"sentences":[{"sentiment":"neutral","confidenceScores":{"positive":0.04,"neutral":0.95,"negative":0.01},"offset":0,"length":22,"text":"I + will go to the park."}],"warnings":[]},{"id":"2","sentiment":"neutral","confidenceScores":{"positive":0.01,"neutral":0.5,"negative":0.49},"sentences":[{"sentiment":"neutral","confidenceScores":{"positive":0.01,"neutral":0.5,"negative":0.49},"offset":0,"length":38,"text":"I + did not like the hotel we stayed at."}],"warnings":[]},{"id":"3","sentiment":"positive","confidenceScores":{"positive":0.97,"neutral":0.02,"negative":0.01},"sentences":[{"sentiment":"positive","confidenceScores":{"positive":0.97,"neutral":0.02,"negative":0.01},"offset":0,"length":36,"text":"The + restaurant had really good food."}],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - fc2fb6f1-4a94-434c-9f07-958a92b19cd4 + - 66bc6b35-5660-42ad-bdb0-ac41f2558b30 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:05:55 GMT + - Wed, 22 Apr 2020 22:41:49 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -39,7 +42,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '187' + - '160' status: code: 200 message: OK @@ -60,22 +63,25 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"documents":[{"id":"1","sentiment":"neutral","documentScores":{"positive":0.09,"neutral":0.9,"negative":0.01},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.09,"neutral":0.9,"negative":0.01},"offset":0,"length":22}]},{"id":"2","sentiment":"negative","documentScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"sentences":[{"sentiment":"negative","sentenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"offset":0,"length":38}]},{"id":"3","sentiment":"positive","documentScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"sentences":[{"sentiment":"positive","sentenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"offset":0,"length":36}]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"1","sentiment":"neutral","confidenceScores":{"positive":0.09,"neutral":0.9,"negative":0.01},"sentences":[{"sentiment":"neutral","confidenceScores":{"positive":0.09,"neutral":0.9,"negative":0.01},"offset":0,"length":22,"text":"I + will go to the park."}],"warnings":[]},{"id":"2","sentiment":"negative","confidenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"sentences":[{"sentiment":"negative","confidenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"offset":0,"length":38,"text":"I + did not like the hotel we stayed at."}],"warnings":[]},{"id":"3","sentiment":"positive","confidenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"sentences":[{"sentiment":"positive","confidenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"offset":0,"length":36,"text":"The + restaurant had really good food."}],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - 329d8c15-fe1f-49de-bb09-99967f23dcd7 + - 6918b9e8-432e-4aef-ab2b-99a79a25a154 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:05:55 GMT + - Wed, 22 Apr 2020 22:41:49 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -83,7 +89,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '135' + - '136' status: code: 200 message: OK @@ -104,22 +110,25 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"documents":[{"id":"1","sentiment":"neutral","documentScores":{"positive":0.04,"neutral":0.95,"negative":0.01},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.04,"neutral":0.95,"negative":0.01},"offset":0,"length":22}]},{"id":"2","sentiment":"neutral","documentScores":{"positive":0.01,"neutral":0.5,"negative":0.49},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.01,"neutral":0.5,"negative":0.49},"offset":0,"length":38}]},{"id":"3","sentiment":"positive","documentScores":{"positive":0.97,"neutral":0.02,"negative":0.01},"sentences":[{"sentiment":"positive","sentenceScores":{"positive":0.97,"neutral":0.02,"negative":0.01},"offset":0,"length":36}]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"1","sentiment":"neutral","confidenceScores":{"positive":0.04,"neutral":0.95,"negative":0.01},"sentences":[{"sentiment":"neutral","confidenceScores":{"positive":0.04,"neutral":0.95,"negative":0.01},"offset":0,"length":22,"text":"I + will go to the park."}],"warnings":[]},{"id":"2","sentiment":"neutral","confidenceScores":{"positive":0.01,"neutral":0.5,"negative":0.49},"sentences":[{"sentiment":"neutral","confidenceScores":{"positive":0.01,"neutral":0.5,"negative":0.49},"offset":0,"length":38,"text":"I + did not like the hotel we stayed at."}],"warnings":[]},{"id":"3","sentiment":"positive","confidenceScores":{"positive":0.97,"neutral":0.02,"negative":0.01},"sentences":[{"sentiment":"positive","confidenceScores":{"positive":0.97,"neutral":0.02,"negative":0.01},"offset":0,"length":36,"text":"The + restaurant had really good food."}],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - baec31d4-9c3d-492b-9908-c7f50810fbc4 + - 5c384722-d196-4e56-acb5-0992e5b21c1b content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:05:55 GMT + - Wed, 22 Apr 2020 22:41:49 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -127,7 +136,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '286' + - '177' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_document_attribute_error_no_result_attribute.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_document_attribute_error_no_result_attribute.yaml index 9e9f06893ec7..ca75e5d61ff7 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_document_attribute_error_no_result_attribute.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_document_attribute_error_no_result_attribute.yaml @@ -13,22 +13,22 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: string: '{"documents":[],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}}],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - 45a91127-7cbf-4be2-a299-571cff509486 + - 56efbd6d-3592-4514-97ff-7bf31cf51d0b content-type: - application/json; charset=utf-8 date: - - Thu, 02 Apr 2020 15:05:55 GMT + - Wed, 22 Apr 2020 22:41:50 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -36,7 +36,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '3' + - '2' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_document_attribute_error_nonexistent_attribute.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_document_attribute_error_nonexistent_attribute.yaml index a0260b6f00c5..9ad671690aa0 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_document_attribute_error_nonexistent_attribute.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_document_attribute_error_nonexistent_attribute.yaml @@ -13,22 +13,22 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: string: '{"documents":[],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}}],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - 833f3057-f2b2-4722-9306-dae3fe54845a + - 1a65d927-7ba6-4118-9666-8033091d6c9c content-type: - application/json; charset=utf-8 date: - - Thu, 02 Apr 2020 15:05:56 GMT + - Wed, 22 Apr 2020 22:41:50 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -36,7 +36,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '3' + - '2' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_document_errors.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_document_errors.yaml index 91e481a48b06..0fda0bfcbdd0 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_document_errors.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_document_errors.yaml @@ -16,28 +16,28 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: string: '{"documents":[],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}},{"id":"2","error":{"code":"InvalidArgument","message":"Invalid - Language Code.","innerError":{"code":"UnsupportedLanguageCode","message":"Supplied + Language Code.","innererror":{"code":"UnsupportedLanguageCode","message":"Supplied language not supported. Pass in one of: de,en,es,fr,it,ja,ko,nl,pt-PT,zh-Hans,zh-Hant"}}},{"id":"3","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"A + document in request.","innererror":{"code":"InvalidDocument","message":"A document within the request was too large to be processed. Limit document size to: 5120 text elements. For additional details on the data limitations see https://aka.ms/text-analytics-data-limits"}}}],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - 37c4371e-59ac-41fb-9d7e-e5a9bc54dd73 + - 8ecdace5-6df9-4e33-8c8c-fa4d51225136 content-type: - application/json; charset=utf-8 date: - - Thu, 02 Apr 2020 15:05:56 GMT + - Wed, 22 Apr 2020 22:41:50 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_duplicate_ids_error.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_duplicate_ids_error.yaml index 2f29c316f970..1841e5711077 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_duplicate_ids_error.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_duplicate_ids_error.yaml @@ -14,21 +14,21 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innerError":{"code":"InvalidDocument","message":"Request + string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innererror":{"code":"InvalidDocument","message":"Request contains duplicated Ids. Make sure each document has a unique Id."}}}' headers: apim-request-id: - - 718c0d73-50fd-46fd-9a14-0ae131b89657 + - 029daaf5-64d5-4c1a-97bb-8318da214af8 content-type: - application/json; charset=utf-8 date: - - Thu, 02 Apr 2020 15:05:57 GMT + - Wed, 22 Apr 2020 22:41:50 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -36,7 +36,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '5' + - '4' status: code: 400 message: Bad Request diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_empty_credential_class.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_empty_credential_class.yaml index 508f9778d50e..1ab8a0923d1d 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_empty_credential_class.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_empty_credential_class.yaml @@ -14,21 +14,31 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"error":{"code":"401","message":"Access denied due to invalid subscription + string: '{"error":{"code":"401","message": "Access denied due to invalid subscription key or wrong API endpoint. Make sure to provide a valid key for an active subscription and use a correct regional API endpoint for your resource."}}' headers: + apim-request-id: + - f80ad449-75f2-46e9-a88d-1a8f9cc7eed8 content-length: - - '224' + - '225' + content-type: + - application/json date: - - Thu, 02 Apr 2020 15:05:58 GMT + - Wed, 22 Apr 2020 22:41:51 GMT + strict-transport-security: + - max-age=31536000; includeSubDomains; preload + www-authenticate: + - AzureApiManagementKey realm="https://westus2.ppe.cognitiveservices.azure.com/text/analytics",name="Ocp-Apim-Subscription-Key",type="header" + x-content-type-options: + - nosniff status: code: 401 - message: PermissionDenied + message: Access Denied version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_input_with_all_errors.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_input_with_all_errors.yaml index dd1415187076..43c725cbbdb3 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_input_with_all_errors.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_input_with_all_errors.yaml @@ -15,26 +15,26 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: string: '{"documents":[],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}},{"id":"2","error":{"code":"InvalidArgument","message":"Invalid - Language Code.","innerError":{"code":"UnsupportedLanguageCode","message":"Supplied + Language Code.","innererror":{"code":"UnsupportedLanguageCode","message":"Supplied language not supported. Pass in one of: de,en,es,fr,it,ja,ko,nl,pt-PT,zh-Hans,zh-Hant"}}},{"id":"3","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}}],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - f3f5b028-bf0d-478c-8e9a-c7520b4d41d3 + - 31e877c7-d76c-4f22-8cd6-3308217987d9 content-type: - application/json; charset=utf-8 date: - - Thu, 02 Apr 2020 15:05:57 GMT + - Wed, 22 Apr 2020 22:41:52 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -42,7 +42,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '3' + - '2' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_input_with_some_errors.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_input_with_some_errors.yaml index 344f1096b823..4b2b8f756229 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_input_with_some_errors.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_input_with_some_errors.yaml @@ -16,26 +16,28 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"documents":[{"id":"3","sentiment":"positive","documentScores":{"positive":0.98,"neutral":0.02,"negative":0.0},"sentences":[{"sentiment":"positive","sentenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"offset":0,"length":36},{"sentiment":"positive","sentenceScores":{"positive":0.96,"neutral":0.03,"negative":0.01},"offset":37,"length":23}]}],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + string: '{"documents":[{"id":"3","sentiment":"positive","confidenceScores":{"positive":0.98,"neutral":0.02,"negative":0.0},"sentences":[{"sentiment":"positive","confidenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"offset":0,"length":36,"text":"The + restaurant had really good food."},{"sentiment":"positive","confidenceScores":{"positive":0.96,"neutral":0.03,"negative":0.01},"offset":37,"length":23,"text":"I + recommend you try it."}],"warnings":[]}],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}},{"id":"2","error":{"code":"InvalidArgument","message":"Invalid - Language Code.","innerError":{"code":"UnsupportedLanguageCode","message":"Supplied + Language Code.","innererror":{"code":"UnsupportedLanguageCode","message":"Supplied language not supported. Pass in one of: de,en,es,fr,it,ja,ko,nl,pt-PT,zh-Hans,zh-Hant"}}}],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - b3687236-0d41-4560-87ec-34eeb69a53ce + - 8d30f161-1bcf-4b85-a41e-4668b1d99f48 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=1 date: - - Thu, 02 Apr 2020 15:05:58 GMT + - Wed, 22 Apr 2020 22:41:52 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -43,7 +45,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '120' + - '128' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_language_kwarg_spanish.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_language_kwarg_spanish.yaml index b595f27bef8f..032d6b53b476 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_language_kwarg_spanish.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_language_kwarg_spanish.yaml @@ -14,22 +14,23 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?model-version=latest&showStats=true + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?model-version=latest&showStats=true response: body: - string: '{"statistics":{"documentsCount":1,"validDocumentsCount":1,"erroneousDocumentsCount":0,"transactionsCount":1},"documents":[{"id":"0","sentiment":"neutral","statistics":{"charactersCount":35,"transactionsCount":1},"documentScores":{"positive":0.01,"neutral":0.98,"negative":0.01},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.01,"neutral":0.98,"negative":0.01},"offset":0,"length":35}]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"statistics":{"documentsCount":1,"validDocumentsCount":1,"erroneousDocumentsCount":0,"transactionsCount":1},"documents":[{"id":"0","sentiment":"neutral","statistics":{"charactersCount":35,"transactionsCount":1},"confidenceScores":{"positive":0.01,"neutral":0.98,"negative":0.01},"sentences":[{"sentiment":"neutral","confidenceScores":{"positive":0.01,"neutral":0.98,"negative":0.01},"offset":0,"length":35,"text":"Bill + Gates is the CEO of Microsoft."}],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - d2e296c9-85e4-4a20-ac9a-b6ee181f4404 + - 51f356c3-907c-447d-907e-563e8f35d7e8 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=1 date: - - Thu, 02 Apr 2020 15:05:58 GMT + - Wed, 22 Apr 2020 22:41:52 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -37,7 +38,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '123' + - '131' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_missing_input_records_error.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_missing_input_records_error.yaml deleted file mode 100644 index 8350224eefdc..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_missing_input_records_error.yaml +++ /dev/null @@ -1,42 +0,0 @@ -interactions: -- request: - body: '{"documents": []}' - headers: - Accept: - - application/json - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '17' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false - response: - body: - string: '{"error":{"code":"InvalidRequest","message":"Invalid Request.","innerError":{"code":"MissingInputRecords","message":"Missing - input records."}}}' - headers: - apim-request-id: - - 24025da5-197b-4a60-a9f3-c45377be80ec - content-type: - - application/json; charset=utf-8 - date: - - Thu, 02 Apr 2020 15:05:59 GMT - strict-transport-security: - - max-age=31536000; includeSubDomains; preload - transfer-encoding: - - chunked - x-content-type-options: - - nosniff - x-envoy-upstream-service-time: - - '4' - status: - code: 400 - message: Bad Request -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_out_of_order_ids.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_out_of_order_ids.yaml index 061c92fde7db..6b8d006e7d4a 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_out_of_order_ids.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_out_of_order_ids.yaml @@ -16,24 +16,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"documents":[{"id":"56","sentiment":"positive","documentScores":{"positive":0.89,"neutral":0.1,"negative":0.01},"sentences":[{"sentiment":"positive","sentenceScores":{"positive":0.89,"neutral":0.1,"negative":0.01},"offset":0,"length":2}]},{"id":"0","sentiment":"negative","documentScores":{"positive":0.0,"neutral":0.02,"negative":0.98},"sentences":[{"sentiment":"negative","sentenceScores":{"positive":0.0,"neutral":0.02,"negative":0.98},"offset":0,"length":2}]},{"id":"19","sentiment":"neutral","documentScores":{"positive":0.3,"neutral":0.67,"negative":0.03},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.3,"neutral":0.67,"negative":0.03},"offset":0,"length":2}]},{"id":"1","sentiment":"positive","documentScores":{"positive":0.89,"neutral":0.1,"negative":0.01},"sentences":[{"sentiment":"positive","sentenceScores":{"positive":0.89,"neutral":0.1,"negative":0.01},"offset":0,"length":2}]}],"errors":[{"id":"22","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + string: '{"documents":[{"id":"56","sentiment":"positive","confidenceScores":{"positive":0.89,"neutral":0.1,"negative":0.01},"sentences":[{"sentiment":"positive","confidenceScores":{"positive":0.89,"neutral":0.1,"negative":0.01},"offset":0,"length":2,"text":":)"}],"warnings":[]},{"id":"0","sentiment":"negative","confidenceScores":{"positive":0.0,"neutral":0.02,"negative":0.98},"sentences":[{"sentiment":"negative","confidenceScores":{"positive":0.0,"neutral":0.02,"negative":0.98},"offset":0,"length":2,"text":":("}],"warnings":[]},{"id":"19","sentiment":"neutral","confidenceScores":{"positive":0.3,"neutral":0.67,"negative":0.03},"sentences":[{"sentiment":"neutral","confidenceScores":{"positive":0.3,"neutral":0.67,"negative":0.03},"offset":0,"length":2,"text":":P"}],"warnings":[]},{"id":"1","sentiment":"positive","confidenceScores":{"positive":0.89,"neutral":0.1,"negative":0.01},"sentences":[{"sentiment":"positive","confidenceScores":{"positive":0.89,"neutral":0.1,"negative":0.01},"offset":0,"length":2,"text":":D"}],"warnings":[]}],"errors":[{"id":"22","error":{"code":"InvalidArgument","message":"Invalid + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}}],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - 9f788bb9-4633-4f43-918c-d0dfd4e682a1 + - 97d007bb-442d-42d7-8126-e17ca39014be content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=4 date: - - Thu, 02 Apr 2020 15:05:59 GMT + - Wed, 22 Apr 2020 22:41:54 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -41,7 +41,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '127' + - '114' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_pass_cls.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_pass_cls.yaml index d1d2de4b036b..3788ef04bb48 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_pass_cls.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_pass_cls.yaml @@ -14,22 +14,23 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"documents":[{"id":"0","sentiment":"neutral","documentScores":{"positive":0.32,"neutral":0.65,"negative":0.03},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.32,"neutral":0.65,"negative":0.03},"offset":0,"length":28}]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"0","sentiment":"neutral","confidenceScores":{"positive":0.32,"neutral":0.65,"negative":0.03},"sentences":[{"sentiment":"neutral","confidenceScores":{"positive":0.32,"neutral":0.65,"negative":0.03},"offset":0,"length":28,"text":"Test + passing cls to endpoint"}],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - 77c3bec8-8326-46a0-b130-d4309ed11b6d + - 21b2ce3a-c179-47e6-8d0b-c27fde1b0e5c content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=1 date: - - Thu, 02 Apr 2020 15:06:00 GMT + - Wed, 22 Apr 2020 22:41:54 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -37,7 +38,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '113' + - '97' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_passing_only_string.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_passing_only_string.yaml index 6118164acfcc..1f6d3e119cd3 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_passing_only_string.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_passing_only_string.yaml @@ -17,24 +17,29 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"documents":[{"id":"0","sentiment":"neutral","documentScores":{"positive":0.01,"neutral":0.99,"negative":0.0},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.01,"neutral":0.99,"negative":0.0},"offset":0,"length":51}]},{"id":"1","sentiment":"negative","documentScores":{"positive":0.01,"neutral":0.22,"negative":0.77},"sentences":[{"sentiment":"negative","sentenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"offset":0,"length":38},{"sentiment":"negative","sentenceScores":{"positive":0.0,"neutral":0.0,"negative":1.0},"offset":39,"length":21}]},{"id":"2","sentiment":"positive","documentScores":{"positive":0.98,"neutral":0.02,"negative":0.0},"sentences":[{"sentiment":"positive","sentenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"offset":0,"length":36},{"sentiment":"positive","sentenceScores":{"positive":0.96,"neutral":0.03,"negative":0.01},"offset":37,"length":23}]}],"errors":[{"id":"3","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + string: '{"documents":[{"id":"0","sentiment":"neutral","confidenceScores":{"positive":0.01,"neutral":0.99,"negative":0.0},"sentences":[{"sentiment":"neutral","confidenceScores":{"positive":0.01,"neutral":0.99,"negative":0.0},"offset":0,"length":51,"text":"Microsoft + was founded by Bill Gates and Paul Allen."}],"warnings":[]},{"id":"1","sentiment":"negative","confidenceScores":{"positive":0.01,"neutral":0.22,"negative":0.77},"sentences":[{"sentiment":"negative","confidenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"offset":0,"length":38,"text":"I + did not like the hotel we stayed at."},{"sentiment":"negative","confidenceScores":{"positive":0.0,"neutral":0.0,"negative":1.0},"offset":39,"length":21,"text":"It + was too expensive."}],"warnings":[]},{"id":"2","sentiment":"positive","confidenceScores":{"positive":0.98,"neutral":0.02,"negative":0.0},"sentences":[{"sentiment":"positive","confidenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"offset":0,"length":36,"text":"The + restaurant had really good food."},{"sentiment":"positive","confidenceScores":{"positive":0.96,"neutral":0.03,"negative":0.01},"offset":37,"length":23,"text":"I + recommend you try it."}],"warnings":[]}],"errors":[{"id":"3","error":{"code":"InvalidArgument","message":"Invalid + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}}],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - 36e2e82f-ce41-494a-a392-4d84750c4a07 + - 0b057a55-d277-4ae4-bae0-5927aa76be2b content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:06:01 GMT + - Wed, 22 Apr 2020 22:41:56 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -42,7 +47,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '145' + - '128' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_per_item_dont_use_language_hint.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_per_item_dont_use_language_hint.yaml index db7f3fe0233b..5813a84feb98 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_per_item_dont_use_language_hint.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_per_item_dont_use_language_hint.yaml @@ -16,22 +16,25 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"documents":[{"id":"1","sentiment":"neutral","documentScores":{"positive":0.09,"neutral":0.9,"negative":0.01},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.09,"neutral":0.9,"negative":0.01},"offset":0,"length":22}]},{"id":"2","sentiment":"negative","documentScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"sentences":[{"sentiment":"negative","sentenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"offset":0,"length":38}]},{"id":"3","sentiment":"positive","documentScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"sentences":[{"sentiment":"positive","sentenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"offset":0,"length":36}]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"1","sentiment":"neutral","confidenceScores":{"positive":0.09,"neutral":0.9,"negative":0.01},"sentences":[{"sentiment":"neutral","confidenceScores":{"positive":0.09,"neutral":0.9,"negative":0.01},"offset":0,"length":22,"text":"I + will go to the park."}],"warnings":[]},{"id":"2","sentiment":"negative","confidenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"sentences":[{"sentiment":"negative","confidenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"offset":0,"length":38,"text":"I + did not like the hotel we stayed at."}],"warnings":[]},{"id":"3","sentiment":"positive","confidenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"sentences":[{"sentiment":"positive","confidenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"offset":0,"length":36,"text":"The + restaurant had really good food."}],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - d63571a2-b485-4656-95ba-596c10d67e0e + - 2778933e-af4f-44aa-b3d3-5714d854569f content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:06:01 GMT + - Wed, 22 Apr 2020 22:41:56 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -39,7 +42,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '118' + - '128' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_rotate_subscription_key.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_rotate_subscription_key.yaml index 3c228e84a85b..e3a009974f2f 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_rotate_subscription_key.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_rotate_subscription_key.yaml @@ -16,22 +16,25 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"documents":[{"id":"1","sentiment":"neutral","documentScores":{"positive":0.09,"neutral":0.9,"negative":0.01},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.09,"neutral":0.9,"negative":0.01},"offset":0,"length":22}]},{"id":"2","sentiment":"negative","documentScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"sentences":[{"sentiment":"negative","sentenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"offset":0,"length":38}]},{"id":"3","sentiment":"positive","documentScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"sentences":[{"sentiment":"positive","sentenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"offset":0,"length":36}]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"1","sentiment":"neutral","confidenceScores":{"positive":0.09,"neutral":0.9,"negative":0.01},"sentences":[{"sentiment":"neutral","confidenceScores":{"positive":0.09,"neutral":0.9,"negative":0.01},"offset":0,"length":22,"text":"I + will go to the park."}],"warnings":[]},{"id":"2","sentiment":"negative","confidenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"sentences":[{"sentiment":"negative","confidenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"offset":0,"length":38,"text":"I + did not like the hotel we stayed at."}],"warnings":[]},{"id":"3","sentiment":"positive","confidenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"sentences":[{"sentiment":"positive","confidenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"offset":0,"length":36,"text":"The + restaurant had really good food."}],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - dcf9b29b-2b27-4f02-9c40-b6a9e08a1f93 + - 28593fa5-9ca6-4c39-bcd8-d282cc70ca09 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:06:01 GMT + - Wed, 22 Apr 2020 22:41:57 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -39,7 +42,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '119' + - '122' status: code: 200 message: OK @@ -60,23 +63,33 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"error":{"code":"401","message":"Access denied due to invalid subscription + string: '{"error":{"code":"401","message": "Access denied due to invalid subscription key or wrong API endpoint. Make sure to provide a valid key for an active subscription and use a correct regional API endpoint for your resource."}}' headers: + apim-request-id: + - bfbb778d-3fa3-4302-a76f-e23e7aabab52 content-length: - - '224' + - '225' + content-type: + - application/json date: - - Thu, 02 Apr 2020 15:06:01 GMT + - Wed, 22 Apr 2020 22:41:57 GMT + strict-transport-security: + - max-age=31536000; includeSubDomains; preload + www-authenticate: + - AzureApiManagementKey realm="https://westus2.ppe.cognitiveservices.azure.com/text/analytics",name="Ocp-Apim-Subscription-Key",type="header" + x-content-type-options: + - nosniff status: code: 401 - message: PermissionDenied + message: Access Denied - request: body: '{"documents": [{"id": "1", "text": "I will go to the park.", "language": "en"}, {"id": "2", "text": "I did not like the hotel we stayed at.", "language": @@ -94,22 +107,25 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"documents":[{"id":"1","sentiment":"neutral","documentScores":{"positive":0.09,"neutral":0.9,"negative":0.01},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.09,"neutral":0.9,"negative":0.01},"offset":0,"length":22}]},{"id":"2","sentiment":"negative","documentScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"sentences":[{"sentiment":"negative","sentenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"offset":0,"length":38}]},{"id":"3","sentiment":"positive","documentScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"sentences":[{"sentiment":"positive","sentenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"offset":0,"length":36}]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"1","sentiment":"neutral","confidenceScores":{"positive":0.09,"neutral":0.9,"negative":0.01},"sentences":[{"sentiment":"neutral","confidenceScores":{"positive":0.09,"neutral":0.9,"negative":0.01},"offset":0,"length":22,"text":"I + will go to the park."}],"warnings":[]},{"id":"2","sentiment":"negative","confidenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"sentences":[{"sentiment":"negative","confidenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"offset":0,"length":38,"text":"I + did not like the hotel we stayed at."}],"warnings":[]},{"id":"3","sentiment":"positive","confidenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"sentences":[{"sentiment":"positive","confidenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"offset":0,"length":36,"text":"The + restaurant had really good food."}],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - de789333-8b28-40b3-9bcd-5cf9bcdaf988 + - b2767314-ee94-4f26-a023-45692fc58be2 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:06:02 GMT + - Wed, 22 Apr 2020 22:41:57 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -117,7 +133,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '129' + - '116' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_show_stats_and_model_version.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_show_stats_and_model_version.yaml index 566fd582f4f7..76263b0e8d34 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_show_stats_and_model_version.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_show_stats_and_model_version.yaml @@ -16,24 +16,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?model-version=latest&showStats=true + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?model-version=latest&showStats=true response: body: - string: '{"statistics":{"documentsCount":5,"validDocumentsCount":4,"erroneousDocumentsCount":1,"transactionsCount":4},"documents":[{"id":"56","sentiment":"positive","statistics":{"charactersCount":2,"transactionsCount":1},"documentScores":{"positive":0.89,"neutral":0.1,"negative":0.01},"sentences":[{"sentiment":"positive","sentenceScores":{"positive":0.89,"neutral":0.1,"negative":0.01},"offset":0,"length":2}]},{"id":"0","sentiment":"negative","statistics":{"charactersCount":2,"transactionsCount":1},"documentScores":{"positive":0.0,"neutral":0.02,"negative":0.98},"sentences":[{"sentiment":"negative","sentenceScores":{"positive":0.0,"neutral":0.02,"negative":0.98},"offset":0,"length":2}]},{"id":"19","sentiment":"neutral","statistics":{"charactersCount":2,"transactionsCount":1},"documentScores":{"positive":0.3,"neutral":0.67,"negative":0.03},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.3,"neutral":0.67,"negative":0.03},"offset":0,"length":2}]},{"id":"1","sentiment":"positive","statistics":{"charactersCount":2,"transactionsCount":1},"documentScores":{"positive":0.89,"neutral":0.1,"negative":0.01},"sentences":[{"sentiment":"positive","sentenceScores":{"positive":0.89,"neutral":0.1,"negative":0.01},"offset":0,"length":2}]}],"errors":[{"id":"22","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + string: '{"statistics":{"documentsCount":5,"validDocumentsCount":4,"erroneousDocumentsCount":1,"transactionsCount":4},"documents":[{"id":"56","sentiment":"positive","statistics":{"charactersCount":2,"transactionsCount":1},"confidenceScores":{"positive":0.89,"neutral":0.1,"negative":0.01},"sentences":[{"sentiment":"positive","confidenceScores":{"positive":0.89,"neutral":0.1,"negative":0.01},"offset":0,"length":2,"text":":)"}],"warnings":[]},{"id":"0","sentiment":"negative","statistics":{"charactersCount":2,"transactionsCount":1},"confidenceScores":{"positive":0.0,"neutral":0.02,"negative":0.98},"sentences":[{"sentiment":"negative","confidenceScores":{"positive":0.0,"neutral":0.02,"negative":0.98},"offset":0,"length":2,"text":":("}],"warnings":[]},{"id":"19","sentiment":"neutral","statistics":{"charactersCount":2,"transactionsCount":1},"confidenceScores":{"positive":0.3,"neutral":0.67,"negative":0.03},"sentences":[{"sentiment":"neutral","confidenceScores":{"positive":0.3,"neutral":0.67,"negative":0.03},"offset":0,"length":2,"text":":P"}],"warnings":[]},{"id":"1","sentiment":"positive","statistics":{"charactersCount":2,"transactionsCount":1},"confidenceScores":{"positive":0.89,"neutral":0.1,"negative":0.01},"sentences":[{"sentiment":"positive","confidenceScores":{"positive":0.89,"neutral":0.1,"negative":0.01},"offset":0,"length":2,"text":":D"}],"warnings":[]}],"errors":[{"id":"22","error":{"code":"InvalidArgument","message":"Invalid + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}}],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - a76c260b-6efa-4632-8d35-ac4a55af49c7 + - 9085ab0e-40e9-422c-a65a-18e924ba2e33 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=4 date: - - Thu, 02 Apr 2020 15:06:03 GMT + - Wed, 22 Apr 2020 22:41:58 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -41,7 +41,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '134' + - '129' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_user_agent.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_user_agent.yaml index eab63043ea1b..22c7a7223efe 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_user_agent.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_user_agent.yaml @@ -16,22 +16,25 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"documents":[{"id":"1","sentiment":"neutral","documentScores":{"positive":0.09,"neutral":0.9,"negative":0.01},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.09,"neutral":0.9,"negative":0.01},"offset":0,"length":22}]},{"id":"2","sentiment":"negative","documentScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"sentences":[{"sentiment":"negative","sentenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"offset":0,"length":38}]},{"id":"3","sentiment":"positive","documentScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"sentences":[{"sentiment":"positive","sentenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"offset":0,"length":36}]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"1","sentiment":"neutral","confidenceScores":{"positive":0.09,"neutral":0.9,"negative":0.01},"sentences":[{"sentiment":"neutral","confidenceScores":{"positive":0.09,"neutral":0.9,"negative":0.01},"offset":0,"length":22,"text":"I + will go to the park."}],"warnings":[]},{"id":"2","sentiment":"negative","confidenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"sentences":[{"sentiment":"negative","confidenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"offset":0,"length":38,"text":"I + did not like the hotel we stayed at."}],"warnings":[]},{"id":"3","sentiment":"positive","confidenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"sentences":[{"sentiment":"positive","confidenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"offset":0,"length":36,"text":"The + restaurant had really good food."}],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - fc0132fe-2a63-4ee2-9685-0b71da7b6927 + - b6f8b8cd-51f6-4268-a402-4d1d638e687d content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:06:03 GMT + - Wed, 22 Apr 2020 22:41:58 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -39,7 +42,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '114' + - '112' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_whole_batch_dont_use_language_hint.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_whole_batch_dont_use_language_hint.yaml index d2496dee917b..c87da35284da 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_whole_batch_dont_use_language_hint.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_whole_batch_dont_use_language_hint.yaml @@ -16,22 +16,26 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"documents":[{"id":"0","sentiment":"positive","documentScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"sentences":[{"sentiment":"positive","sentenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"offset":0,"length":33}]},{"id":"1","sentiment":"negative","documentScores":{"positive":0.01,"neutral":0.22,"negative":0.77},"sentences":[{"sentiment":"negative","sentenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"offset":0,"length":38},{"sentiment":"negative","sentenceScores":{"positive":0.0,"neutral":0.0,"negative":1.0},"offset":39,"length":21}]},{"id":"2","sentiment":"negative","documentScores":{"positive":0.01,"neutral":0.0,"negative":0.99},"sentences":[{"sentiment":"negative","sentenceScores":{"positive":0.01,"neutral":0.0,"negative":0.99},"offset":0,"length":42}]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"0","sentiment":"positive","confidenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"sentences":[{"sentiment":"positive","confidenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"offset":0,"length":33,"text":"This + was the best day of my life."}],"warnings":[]},{"id":"1","sentiment":"negative","confidenceScores":{"positive":0.01,"neutral":0.22,"negative":0.77},"sentences":[{"sentiment":"negative","confidenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"offset":0,"length":38,"text":"I + did not like the hotel we stayed at."},{"sentiment":"negative","confidenceScores":{"positive":0.0,"neutral":0.0,"negative":1.0},"offset":39,"length":21,"text":"It + was too expensive."}],"warnings":[]},{"id":"2","sentiment":"negative","confidenceScores":{"positive":0.01,"neutral":0.0,"negative":0.99},"sentences":[{"sentiment":"negative","confidenceScores":{"positive":0.01,"neutral":0.0,"negative":0.99},"offset":0,"length":42,"text":"The + restaurant was not as good as I hoped."}],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - 3196903f-e628-42a6-a3ce-6557114db8ae + - 559cb92b-189b-4268-8d57-836e1fe6632b content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:06:04 GMT + - Wed, 22 Apr 2020 22:41:59 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -39,7 +43,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '131' + - '142' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_whole_batch_language_hint.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_whole_batch_language_hint.yaml index cc7a7ff4ee8d..47f4db971711 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_whole_batch_language_hint.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_whole_batch_language_hint.yaml @@ -16,22 +16,26 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"documents":[{"id":"0","sentiment":"neutral","documentScores":{"positive":0.07,"neutral":0.93,"negative":0.0},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.07,"neutral":0.93,"negative":0.0},"offset":0,"length":33}]},{"id":"1","sentiment":"negative","documentScores":{"positive":0.0,"neutral":0.03,"negative":0.97},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.0,"neutral":0.92,"negative":0.08},"offset":0,"length":38},{"sentiment":"negative","sentenceScores":{"positive":0.0,"neutral":0.03,"negative":0.97},"offset":39,"length":21}]},{"id":"2","sentiment":"negative","documentScores":{"positive":0.01,"neutral":0.32,"negative":0.67},"sentences":[{"sentiment":"negative","sentenceScores":{"positive":0.01,"neutral":0.32,"negative":0.67},"offset":0,"length":42}]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"0","sentiment":"neutral","confidenceScores":{"positive":0.07,"neutral":0.93,"negative":0.0},"sentences":[{"sentiment":"neutral","confidenceScores":{"positive":0.07,"neutral":0.93,"negative":0.0},"offset":0,"length":33,"text":"This + was the best day of my life."}],"warnings":[]},{"id":"1","sentiment":"negative","confidenceScores":{"positive":0.0,"neutral":0.03,"negative":0.97},"sentences":[{"sentiment":"neutral","confidenceScores":{"positive":0.0,"neutral":0.92,"negative":0.08},"offset":0,"length":38,"text":"I + did not like the hotel we stayed at."},{"sentiment":"negative","confidenceScores":{"positive":0.0,"neutral":0.03,"negative":0.97},"offset":39,"length":21,"text":"It + was too expensive."}],"warnings":[]},{"id":"2","sentiment":"negative","confidenceScores":{"positive":0.01,"neutral":0.32,"negative":0.67},"sentences":[{"sentiment":"negative","confidenceScores":{"positive":0.01,"neutral":0.32,"negative":0.67},"offset":0,"length":42,"text":"The + restaurant was not as good as I hoped."}],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - 5b08c956-07f4-4a15-bff3-1100df001e71 + - 3d651968-20b6-46a0-8c50-2a7508c7ee26 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:06:04 GMT + - Wed, 22 Apr 2020 22:41:59 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -39,7 +43,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '135' + - '156' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_whole_batch_language_hint_and_dict_input.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_whole_batch_language_hint_and_dict_input.yaml index 5e2c023d5d57..b9277045ab45 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_whole_batch_language_hint_and_dict_input.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_whole_batch_language_hint_and_dict_input.yaml @@ -16,22 +16,25 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"documents":[{"id":"1","sentiment":"neutral","documentScores":{"positive":0.04,"neutral":0.95,"negative":0.01},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.04,"neutral":0.95,"negative":0.01},"offset":0,"length":22}]},{"id":"2","sentiment":"neutral","documentScores":{"positive":0.01,"neutral":0.5,"negative":0.49},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.01,"neutral":0.5,"negative":0.49},"offset":0,"length":38}]},{"id":"3","sentiment":"positive","documentScores":{"positive":0.97,"neutral":0.02,"negative":0.01},"sentences":[{"sentiment":"positive","sentenceScores":{"positive":0.97,"neutral":0.02,"negative":0.01},"offset":0,"length":36}]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"1","sentiment":"neutral","confidenceScores":{"positive":0.04,"neutral":0.95,"negative":0.01},"sentences":[{"sentiment":"neutral","confidenceScores":{"positive":0.04,"neutral":0.95,"negative":0.01},"offset":0,"length":22,"text":"I + will go to the park."}],"warnings":[]},{"id":"2","sentiment":"neutral","confidenceScores":{"positive":0.01,"neutral":0.5,"negative":0.49},"sentences":[{"sentiment":"neutral","confidenceScores":{"positive":0.01,"neutral":0.5,"negative":0.49},"offset":0,"length":38,"text":"I + did not like the hotel we stayed at."}],"warnings":[]},{"id":"3","sentiment":"positive","confidenceScores":{"positive":0.97,"neutral":0.02,"negative":0.01},"sentences":[{"sentiment":"positive","confidenceScores":{"positive":0.97,"neutral":0.02,"negative":0.01},"offset":0,"length":36,"text":"The + restaurant had really good food."}],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - 8a8b68f3-682e-4544-a2b8-562b1de4cd1e + - bbe0cbc0-755f-40f6-a897-c52a317d4684 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:06:04 GMT + - Wed, 22 Apr 2020 22:42:00 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -39,7 +42,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '138' + - '158' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_whole_batch_language_hint_and_dict_per_item_hints.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_whole_batch_language_hint_and_dict_per_item_hints.yaml index f5ee0ec2a836..a396d4548fea 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_whole_batch_language_hint_and_dict_per_item_hints.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_whole_batch_language_hint_and_dict_per_item_hints.yaml @@ -16,22 +16,25 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"documents":[{"id":"1","sentiment":"neutral","documentScores":{"positive":0.04,"neutral":0.95,"negative":0.01},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.04,"neutral":0.95,"negative":0.01},"offset":0,"length":22}]},{"id":"2","sentiment":"neutral","documentScores":{"positive":0.01,"neutral":0.5,"negative":0.49},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.01,"neutral":0.5,"negative":0.49},"offset":0,"length":38}]},{"id":"3","sentiment":"positive","documentScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"sentences":[{"sentiment":"positive","sentenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"offset":0,"length":36}]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"1","sentiment":"neutral","confidenceScores":{"positive":0.04,"neutral":0.95,"negative":0.01},"sentences":[{"sentiment":"neutral","confidenceScores":{"positive":0.04,"neutral":0.95,"negative":0.01},"offset":0,"length":22,"text":"I + will go to the park."}],"warnings":[]},{"id":"2","sentiment":"neutral","confidenceScores":{"positive":0.01,"neutral":0.5,"negative":0.49},"sentences":[{"sentiment":"neutral","confidenceScores":{"positive":0.01,"neutral":0.5,"negative":0.49},"offset":0,"length":38,"text":"I + did not like the hotel we stayed at."}],"warnings":[]},{"id":"3","sentiment":"positive","confidenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"sentences":[{"sentiment":"positive","confidenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"offset":0,"length":36,"text":"The + restaurant had really good food."}],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - 3b14c403-b65f-47ba-bf7c-2ffae7e5e0c5 + - db30608f-fbb2-4308-9eec-bb7c284bf9d8 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:06:05 GMT + - Wed, 22 Apr 2020 22:42:00 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -39,7 +42,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '136' + - '154' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_whole_batch_language_hint_and_obj_input.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_whole_batch_language_hint_and_obj_input.yaml index 06b0d425c38d..735ebe132e4b 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_whole_batch_language_hint_and_obj_input.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_whole_batch_language_hint_and_obj_input.yaml @@ -16,22 +16,35 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"documents":[{"id":"1","sentiment":"neutral","documentScores":{"positive":0.15,"neutral":0.81,"negative":0.04},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.15,"neutral":0.81,"negative":0.04},"offset":0,"length":41}]},{"id":"4","sentiment":"neutral","documentScores":{"positive":0.38,"neutral":0.48,"negative":0.14},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.38,"neutral":0.48,"negative":0.14},"offset":0,"length":39}]},{"id":"3","sentiment":"neutral","documentScores":{"positive":0.15,"neutral":0.79,"negative":0.06},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.15,"neutral":0.79,"negative":0.06},"offset":0,"length":4}]}],"errors":[],"modelVersion":"2019-10-01"}' + string: "{\"documents\":[{\"id\":\"1\",\"sentiment\":\"neutral\",\"confidenceScores\"\ + :{\"positive\":0.15,\"neutral\":0.81,\"negative\":0.04},\"sentences\":[{\"\ + sentiment\":\"neutral\",\"confidenceScores\":{\"positive\":0.15,\"neutral\"\ + :0.81,\"negative\":0.04},\"offset\":0,\"length\":41,\"text\":\"I should take\ + \ my cat to the veterinarian.\"}],\"warnings\":[]},{\"id\":\"4\",\"sentiment\"\ + :\"neutral\",\"confidenceScores\":{\"positive\":0.38,\"neutral\":0.48,\"negative\"\ + :0.14},\"sentences\":[{\"sentiment\":\"neutral\",\"confidenceScores\":{\"\ + positive\":0.38,\"neutral\":0.48,\"negative\":0.14},\"offset\":0,\"length\"\ + :39,\"text\":\"Este es un document escrito en Espa\xF1ol.\"}],\"warnings\"\ + :[]},{\"id\":\"3\",\"sentiment\":\"neutral\",\"confidenceScores\":{\"positive\"\ + :0.15,\"neutral\":0.79,\"negative\":0.06},\"sentences\":[{\"sentiment\":\"\ + neutral\",\"confidenceScores\":{\"positive\":0.15,\"neutral\":0.79,\"negative\"\ + :0.06},\"offset\":0,\"length\":4,\"text\":\"\u732B\u306F\u5E78\u305B\"}],\"\ + warnings\":[]}],\"errors\":[],\"modelVersion\":\"2019-10-01\"}" headers: apim-request-id: - - 21042b83-26bf-4398-a1fb-97fc97fd026f + - 7b3b9b1e-28c0-4b44-8cbb-56a14ba0d696 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:06:06 GMT + - Wed, 22 Apr 2020 22:42:01 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -39,7 +52,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '128' + - '163' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_whole_batch_language_hint_and_obj_per_item_hints.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_whole_batch_language_hint_and_obj_per_item_hints.yaml index 5f01d2f25769..9834e168b8ae 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_whole_batch_language_hint_and_obj_per_item_hints.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment.test_whole_batch_language_hint_and_obj_per_item_hints.yaml @@ -16,22 +16,35 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"documents":[{"id":"1","sentiment":"neutral","documentScores":{"positive":0.05,"neutral":0.94,"negative":0.01},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.05,"neutral":0.94,"negative":0.01},"offset":0,"length":41}]},{"id":"2","sentiment":"neutral","documentScores":{"positive":0.03,"neutral":0.92,"negative":0.05},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.03,"neutral":0.92,"negative":0.05},"offset":0,"length":39}]},{"id":"3","sentiment":"neutral","documentScores":{"positive":0.13,"neutral":0.81,"negative":0.06},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.13,"neutral":0.81,"negative":0.06},"offset":0,"length":4}]}],"errors":[],"modelVersion":"2019-10-01"}' + string: "{\"documents\":[{\"id\":\"1\",\"sentiment\":\"neutral\",\"confidenceScores\"\ + :{\"positive\":0.05,\"neutral\":0.94,\"negative\":0.01},\"sentences\":[{\"\ + sentiment\":\"neutral\",\"confidenceScores\":{\"positive\":0.05,\"neutral\"\ + :0.94,\"negative\":0.01},\"offset\":0,\"length\":41,\"text\":\"I should take\ + \ my cat to the veterinarian.\"}],\"warnings\":[]},{\"id\":\"2\",\"sentiment\"\ + :\"neutral\",\"confidenceScores\":{\"positive\":0.03,\"neutral\":0.92,\"negative\"\ + :0.05},\"sentences\":[{\"sentiment\":\"neutral\",\"confidenceScores\":{\"\ + positive\":0.03,\"neutral\":0.92,\"negative\":0.05},\"offset\":0,\"length\"\ + :39,\"text\":\"Este es un document escrito en Espa\xF1ol.\"}],\"warnings\"\ + :[]},{\"id\":\"3\",\"sentiment\":\"neutral\",\"confidenceScores\":{\"positive\"\ + :0.13,\"neutral\":0.81,\"negative\":0.06},\"sentences\":[{\"sentiment\":\"\ + neutral\",\"confidenceScores\":{\"positive\":0.13,\"neutral\":0.81,\"negative\"\ + :0.06},\"offset\":0,\"length\":4,\"text\":\"\u732B\u306F\u5E78\u305B\"}],\"\ + warnings\":[]}],\"errors\":[],\"modelVersion\":\"2019-10-01\"}" headers: apim-request-id: - - 0108a604-401c-433a-9ef5-8ee4d98ce984 + - af7e7144-1511-46c9-bb28-ece516629837 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:06:06 GMT + - Wed, 22 Apr 2020 22:42:01 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -39,7 +52,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '123' + - '132' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_all_successful_passing_dict.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_all_successful_passing_dict.yaml index 6e1cf5d4be6a..2c433c008d25 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_all_successful_passing_dict.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_all_successful_passing_dict.yaml @@ -13,24 +13,29 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=true + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=true response: body: - string: '{"statistics":{"documentsCount":3,"validDocumentsCount":3,"erroneousDocumentsCount":0,"transactionsCount":3},"documents":[{"id":"1","sentiment":"neutral","statistics":{"charactersCount":51,"transactionsCount":1},"documentScores":{"positive":0.01,"neutral":0.99,"negative":0.0},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.01,"neutral":0.99,"negative":0.0},"offset":0,"length":51}]},{"id":"2","sentiment":"negative","statistics":{"charactersCount":60,"transactionsCount":1},"documentScores":{"positive":0.01,"neutral":0.22,"negative":0.77},"sentences":[{"sentiment":"negative","sentenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"offset":0,"length":38},{"sentiment":"negative","sentenceScores":{"positive":0.0,"neutral":0.0,"negative":1.0},"offset":39,"length":21}]},{"id":"3","sentiment":"positive","statistics":{"charactersCount":60,"transactionsCount":1},"documentScores":{"positive":0.98,"neutral":0.02,"negative":0.0},"sentences":[{"sentiment":"positive","sentenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"offset":0,"length":36},{"sentiment":"positive","sentenceScores":{"positive":0.96,"neutral":0.03,"negative":0.01},"offset":37,"length":23}]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"statistics":{"documentsCount":3,"validDocumentsCount":3,"erroneousDocumentsCount":0,"transactionsCount":3},"documents":[{"id":"1","sentiment":"neutral","statistics":{"charactersCount":51,"transactionsCount":1},"confidenceScores":{"positive":0.01,"neutral":0.99,"negative":0.0},"sentences":[{"sentiment":"neutral","confidenceScores":{"positive":0.01,"neutral":0.99,"negative":0.0},"offset":0,"length":51,"text":"Microsoft + was founded by Bill Gates and Paul Allen."}],"warnings":[]},{"id":"2","sentiment":"negative","statistics":{"charactersCount":60,"transactionsCount":1},"confidenceScores":{"positive":0.01,"neutral":0.22,"negative":0.77},"sentences":[{"sentiment":"negative","confidenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"offset":0,"length":38,"text":"I + did not like the hotel we stayed at."},{"sentiment":"negative","confidenceScores":{"positive":0.0,"neutral":0.0,"negative":1.0},"offset":39,"length":21,"text":"It + was too expensive."}],"warnings":[]},{"id":"3","sentiment":"positive","statistics":{"charactersCount":60,"transactionsCount":1},"confidenceScores":{"positive":0.98,"neutral":0.02,"negative":0.0},"sentences":[{"sentiment":"positive","confidenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"offset":0,"length":36,"text":"The + restaurant had really good food."},{"sentiment":"positive","confidenceScores":{"positive":0.96,"neutral":0.03,"negative":0.01},"offset":37,"length":23,"text":"I + recommend you try it."}],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: - apim-request-id: 9f1de859-43c3-4589-9f3f-465b0ff4a710 + apim-request-id: 511fe6f2-3e06-4dde-8538-e2ef6f3f6a20 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:06:07 GMT + date: Wed, 22 Apr 2020 22:45:58 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '108' + x-envoy-upstream-service-time: '138' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/sentiment?showStats=true + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=true version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_all_successful_passing_text_document_input.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_all_successful_passing_text_document_input.yaml index 98178b7d2d72..0e9bd29a195f 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_all_successful_passing_text_document_input.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_all_successful_passing_text_document_input.yaml @@ -13,24 +13,29 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"documents":[{"id":"1","sentiment":"neutral","documentScores":{"positive":0.01,"neutral":0.99,"negative":0.0},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.01,"neutral":0.99,"negative":0.0},"offset":0,"length":51}]},{"id":"2","sentiment":"negative","documentScores":{"positive":0.01,"neutral":0.22,"negative":0.77},"sentences":[{"sentiment":"negative","sentenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"offset":0,"length":38},{"sentiment":"negative","sentenceScores":{"positive":0.0,"neutral":0.0,"negative":1.0},"offset":39,"length":21}]},{"id":"3","sentiment":"positive","documentScores":{"positive":0.98,"neutral":0.02,"negative":0.0},"sentences":[{"sentiment":"positive","sentenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"offset":0,"length":36},{"sentiment":"positive","sentenceScores":{"positive":0.96,"neutral":0.03,"negative":0.01},"offset":37,"length":23}]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"1","sentiment":"neutral","confidenceScores":{"positive":0.01,"neutral":0.99,"negative":0.0},"sentences":[{"sentiment":"neutral","confidenceScores":{"positive":0.01,"neutral":0.99,"negative":0.0},"offset":0,"length":51,"text":"Microsoft + was founded by Bill Gates and Paul Allen."}],"warnings":[]},{"id":"2","sentiment":"negative","confidenceScores":{"positive":0.01,"neutral":0.22,"negative":0.77},"sentences":[{"sentiment":"negative","confidenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"offset":0,"length":38,"text":"I + did not like the hotel we stayed at."},{"sentiment":"negative","confidenceScores":{"positive":0.0,"neutral":0.0,"negative":1.0},"offset":39,"length":21,"text":"It + was too expensive."}],"warnings":[]},{"id":"3","sentiment":"positive","confidenceScores":{"positive":0.98,"neutral":0.02,"negative":0.0},"sentences":[{"sentiment":"positive","confidenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"offset":0,"length":36,"text":"The + restaurant had really good food."},{"sentiment":"positive","confidenceScores":{"positive":0.96,"neutral":0.03,"negative":0.01},"offset":37,"length":23,"text":"I + recommend you try it."}],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: - apim-request-id: 9c8c0ec9-ab43-4642-a904-456382e7f357 + apim-request-id: 845952a5-509c-4620-bcb0-9dc35a03f40a content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:06:07 GMT + date: Wed, 22 Apr 2020 22:45:58 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '141' + x-envoy-upstream-service-time: '137' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/sentiment?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_bad_credentials.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_bad_credentials.yaml index d22155cc36fb..5c812072a2e0 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_bad_credentials.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_bad_credentials.yaml @@ -10,20 +10,25 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"error":{"code":"401","message":"Access denied due to invalid subscription + string: '{"error":{"code":"401","message": "Access denied due to invalid subscription key or wrong API endpoint. Make sure to provide a valid key for an active subscription and use a correct regional API endpoint for your resource."}}' headers: - content-length: '224' - date: Thu, 02 Apr 2020 15:06:07 GMT + apim-request-id: c4c3a7b0-1eb1-4911-aace-755d76fd4dd0 + content-length: '225' + content-type: application/json + date: Wed, 22 Apr 2020 22:45:58 GMT + strict-transport-security: max-age=31536000; includeSubDomains; preload + www-authenticate: AzureApiManagementKey realm="https://westus2.ppe.cognitiveservices.azure.com/text/analytics",name="Ocp-Apim-Subscription-Key",type="header" + x-content-type-options: nosniff status: code: 401 - message: PermissionDenied - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/sentiment?showStats=false + message: Access Denied + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_bad_model_version.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_bad_model_version.yaml index 0b7ac58e6d18..6d722d869632 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_bad_model_version.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_bad_model_version.yaml @@ -10,24 +10,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?model-version=old&showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?model-version=old&showStats=false response: body: string: '{"error":{"code":"InvalidRequest","message":"Specified Model version - is incorrect. Allowed values are latest,2019-10-01"}}' + is incorrect. Allowed values are latest,2019-10-01,2020-04-01"}}' headers: - apim-request-id: 6a6f6ebe-fdaa-48b0-84ec-647a4f7cf56e + apim-request-id: cb4658d9-7cdb-46c0-99ea-76710acf3cca content-type: application/json; charset=utf-8 - date: Thu, 02 Apr 2020 15:06:08 GMT + date: Wed, 22 Apr 2020 22:45:58 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '3' + x-envoy-upstream-service-time: '9' status: code: 400 message: Bad Request - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/sentiment?model-version=old&showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?model-version=old&showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_bad_model_version_error.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_bad_model_version_error.yaml index ed6a18f3b702..cdae51a7deb1 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_bad_model_version_error.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_bad_model_version_error.yaml @@ -10,18 +10,18 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?model-version=bad&showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?model-version=bad&showStats=false response: body: string: '{"error":{"code":"InvalidRequest","message":"Specified Model version - is incorrect. Allowed values are latest,2019-10-01"}}' + is incorrect. Allowed values are latest,2019-10-01,2020-04-01"}}' headers: - apim-request-id: f09f51ea-19a8-4324-9791-1153d134802a + apim-request-id: d54663c1-7b47-4a51-ba77-7eca833abb8f content-type: application/json; charset=utf-8 - date: Thu, 02 Apr 2020 15:06:08 GMT + date: Wed, 22 Apr 2020 22:45:59 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff @@ -29,5 +29,5 @@ interactions: status: code: 400 message: Bad Request - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/sentiment?model-version=bad&showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?model-version=bad&showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_batch_size_over_limit.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_batch_size_over_limit.yaml index 25f9b026c0d2..5a0c2f1d2eea 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_batch_size_over_limit.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_batch_size_over_limit.yaml @@ -754,24 +754,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innerError":{"code":"InvalidDocumentBatch","message":"Batch + string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innererror":{"code":"InvalidDocumentBatch","message":"Batch request contains too many records. Max 1000 records are permitted."}}}' headers: - apim-request-id: 85be4b8f-68c2-416e-8948-78de5a93477f + apim-request-id: 4668f7e8-f1dd-4f22-9720-adc446bfafcf content-type: application/json; charset=utf-8 - date: Thu, 02 Apr 2020 15:06:09 GMT + date: Wed, 22 Apr 2020 22:46:00 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '11' + x-envoy-upstream-service-time: '16' status: code: 400 message: Bad Request - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/sentiment?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_batch_size_over_limit_error.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_batch_size_over_limit_error.yaml index 1f1a360f336a..5fd771c2dec9 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_batch_size_over_limit_error.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_batch_size_over_limit_error.yaml @@ -719,24 +719,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innerError":{"code":"InvalidDocumentBatch","message":"Batch + string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innererror":{"code":"InvalidDocumentBatch","message":"Batch request contains too many records. Max 1000 records are permitted."}}}' headers: - apim-request-id: 1b30d770-3283-4285-975e-4ab301e97897 + apim-request-id: 2bd433d7-ae5d-4aa2-a174-3d0731f9fe7e content-type: application/json; charset=utf-8 - date: Thu, 02 Apr 2020 15:06:10 GMT + date: Wed, 22 Apr 2020 22:46:01 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '13' + x-envoy-upstream-service-time: '10' status: code: 400 message: Bad Request - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/sentiment?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_client_passed_default_language_hint.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_client_passed_default_language_hint.yaml index 6f93c64f6b00..2fb4b0b57ffe 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_client_passed_default_language_hint.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_client_passed_default_language_hint.yaml @@ -12,26 +12,29 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"documents":[{"id":"1","sentiment":"neutral","documentScores":{"positive":0.04,"neutral":0.95,"negative":0.01},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.04,"neutral":0.95,"negative":0.01},"offset":0,"length":22}]},{"id":"2","sentiment":"neutral","documentScores":{"positive":0.01,"neutral":0.5,"negative":0.49},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.01,"neutral":0.5,"negative":0.49},"offset":0,"length":38}]},{"id":"3","sentiment":"positive","documentScores":{"positive":0.97,"neutral":0.02,"negative":0.01},"sentences":[{"sentiment":"positive","sentenceScores":{"positive":0.97,"neutral":0.02,"negative":0.01},"offset":0,"length":36}]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"1","sentiment":"neutral","confidenceScores":{"positive":0.04,"neutral":0.95,"negative":0.01},"sentences":[{"sentiment":"neutral","confidenceScores":{"positive":0.04,"neutral":0.95,"negative":0.01},"offset":0,"length":22,"text":"I + will go to the park."}],"warnings":[]},{"id":"2","sentiment":"neutral","confidenceScores":{"positive":0.01,"neutral":0.5,"negative":0.49},"sentences":[{"sentiment":"neutral","confidenceScores":{"positive":0.01,"neutral":0.5,"negative":0.49},"offset":0,"length":38,"text":"I + did not like the hotel we stayed at."}],"warnings":[]},{"id":"3","sentiment":"positive","confidenceScores":{"positive":0.97,"neutral":0.02,"negative":0.01},"sentences":[{"sentiment":"positive","confidenceScores":{"positive":0.97,"neutral":0.02,"negative":0.01},"offset":0,"length":36,"text":"The + restaurant had really good food."}],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: - apim-request-id: 980096b2-7a5b-479c-a34f-448a258019e5 + apim-request-id: 419d2fc6-48a7-4ae7-8815-ea60def51422 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:06:11 GMT + date: Wed, 22 Apr 2020 22:46:02 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '335' + x-envoy-upstream-service-time: '137' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/sentiment?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false - request: body: '{"documents": [{"id": "1", "text": "I will go to the park.", "language": "en"}, {"id": "2", "text": "I did not like the hotel we stayed at.", "language": @@ -45,26 +48,29 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"documents":[{"id":"1","sentiment":"neutral","documentScores":{"positive":0.09,"neutral":0.9,"negative":0.01},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.09,"neutral":0.9,"negative":0.01},"offset":0,"length":22}]},{"id":"2","sentiment":"negative","documentScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"sentences":[{"sentiment":"negative","sentenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"offset":0,"length":38}]},{"id":"3","sentiment":"positive","documentScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"sentences":[{"sentiment":"positive","sentenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"offset":0,"length":36}]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"1","sentiment":"neutral","confidenceScores":{"positive":0.09,"neutral":0.9,"negative":0.01},"sentences":[{"sentiment":"neutral","confidenceScores":{"positive":0.09,"neutral":0.9,"negative":0.01},"offset":0,"length":22,"text":"I + will go to the park."}],"warnings":[]},{"id":"2","sentiment":"negative","confidenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"sentences":[{"sentiment":"negative","confidenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"offset":0,"length":38,"text":"I + did not like the hotel we stayed at."}],"warnings":[]},{"id":"3","sentiment":"positive","confidenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"sentences":[{"sentiment":"positive","confidenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"offset":0,"length":36,"text":"The + restaurant had really good food."}],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: - apim-request-id: e292ad8c-344e-4240-a2a0-b518a73c0859 + apim-request-id: 462dc080-77a3-4124-82a1-b720203eb745 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:06:11 GMT + date: Wed, 22 Apr 2020 22:46:02 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '111' + x-envoy-upstream-service-time: '266' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/sentiment?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false - request: body: '{"documents": [{"id": "1", "text": "I will go to the park.", "language": "es"}, {"id": "2", "text": "I did not like the hotel we stayed at.", "language": @@ -78,24 +84,27 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"documents":[{"id":"1","sentiment":"neutral","documentScores":{"positive":0.04,"neutral":0.95,"negative":0.01},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.04,"neutral":0.95,"negative":0.01},"offset":0,"length":22}]},{"id":"2","sentiment":"neutral","documentScores":{"positive":0.01,"neutral":0.5,"negative":0.49},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.01,"neutral":0.5,"negative":0.49},"offset":0,"length":38}]},{"id":"3","sentiment":"positive","documentScores":{"positive":0.97,"neutral":0.02,"negative":0.01},"sentences":[{"sentiment":"positive","sentenceScores":{"positive":0.97,"neutral":0.02,"negative":0.01},"offset":0,"length":36}]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"1","sentiment":"neutral","confidenceScores":{"positive":0.04,"neutral":0.95,"negative":0.01},"sentences":[{"sentiment":"neutral","confidenceScores":{"positive":0.04,"neutral":0.95,"negative":0.01},"offset":0,"length":22,"text":"I + will go to the park."}],"warnings":[]},{"id":"2","sentiment":"neutral","confidenceScores":{"positive":0.01,"neutral":0.5,"negative":0.49},"sentences":[{"sentiment":"neutral","confidenceScores":{"positive":0.01,"neutral":0.5,"negative":0.49},"offset":0,"length":38,"text":"I + did not like the hotel we stayed at."}],"warnings":[]},{"id":"3","sentiment":"positive","confidenceScores":{"positive":0.97,"neutral":0.02,"negative":0.01},"sentences":[{"sentiment":"positive","confidenceScores":{"positive":0.97,"neutral":0.02,"negative":0.01},"offset":0,"length":36,"text":"The + restaurant had really good food."}],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: - apim-request-id: 2b375d10-d3ea-425f-9cbc-6d3d863c1620 + apim-request-id: 8219d0a9-b5d0-4aad-b17d-c1cef48f2270 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:06:12 GMT + date: Wed, 22 Apr 2020 22:46:02 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '141' + x-envoy-upstream-service-time: '177' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/sentiment?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_document_attribute_error_no_result_attribute.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_document_attribute_error_no_result_attribute.yaml index b433d3bc1ae4..978e022e0145 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_document_attribute_error_no_result_attribute.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_document_attribute_error_no_result_attribute.yaml @@ -9,25 +9,25 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: string: '{"documents":[],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}}],"modelVersion":"2019-10-01"}' headers: - apim-request-id: c2c0a51e-7827-46fc-a76c-4023ad63754d + apim-request-id: c78d238c-e2e9-47a3-9c27-e4c3810b331a content-type: application/json; charset=utf-8 - date: Thu, 02 Apr 2020 15:06:12 GMT + date: Wed, 22 Apr 2020 22:46:03 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '3' + x-envoy-upstream-service-time: '2' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/sentiment?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_document_attribute_error_nonexistent_attribute.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_document_attribute_error_nonexistent_attribute.yaml index 83c6431bf3e4..4711bfa0f6fd 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_document_attribute_error_nonexistent_attribute.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_document_attribute_error_nonexistent_attribute.yaml @@ -9,19 +9,19 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: string: '{"documents":[],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}}],"modelVersion":"2019-10-01"}' headers: - apim-request-id: ac7edc14-1e76-4223-9f75-e6092765ec53 + apim-request-id: 7f5703c2-0a73-40b4-9219-d838fc1c808b content-type: application/json; charset=utf-8 - date: Thu, 02 Apr 2020 15:06:12 GMT + date: Wed, 22 Apr 2020 22:46:03 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff @@ -29,5 +29,5 @@ interactions: status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/sentiment?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_document_errors.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_document_errors.yaml index 4762222ab389..7b4f320afd05 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_document_errors.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_document_errors.yaml @@ -12,31 +12,31 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: string: '{"documents":[],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}},{"id":"2","error":{"code":"InvalidArgument","message":"Invalid - Language Code.","innerError":{"code":"UnsupportedLanguageCode","message":"Supplied + Language Code.","innererror":{"code":"UnsupportedLanguageCode","message":"Supplied language not supported. Pass in one of: de,en,es,fr,it,ja,ko,nl,pt-PT,zh-Hans,zh-Hant"}}},{"id":"3","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"A + document in request.","innererror":{"code":"InvalidDocument","message":"A document within the request was too large to be processed. Limit document size to: 5120 text elements. For additional details on the data limitations see https://aka.ms/text-analytics-data-limits"}}}],"modelVersion":"2019-10-01"}' headers: - apim-request-id: f59301bc-6169-4102-94f0-81867176f8ba + apim-request-id: e9a1cc89-4fe7-4f1d-b126-40784752674b content-type: application/json; charset=utf-8 - date: Thu, 02 Apr 2020 15:06:13 GMT + date: Wed, 22 Apr 2020 22:46:03 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '3' + x-envoy-upstream-service-time: '2' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/sentiment?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_duplicate_ids_error.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_duplicate_ids_error.yaml index d5cac9d918d8..330a78149d21 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_duplicate_ids_error.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_duplicate_ids_error.yaml @@ -10,24 +10,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innerError":{"code":"InvalidDocument","message":"Request + string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innererror":{"code":"InvalidDocument","message":"Request contains duplicated Ids. Make sure each document has a unique Id."}}}' headers: - apim-request-id: 66e15df7-4bf6-4f9e-9de8-cc32ca2acc6e + apim-request-id: ec199aaa-1810-4bf6-8be9-d6cb9f0bc019 content-type: application/json; charset=utf-8 - date: Thu, 02 Apr 2020 15:06:13 GMT + date: Wed, 22 Apr 2020 22:46:03 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '5' + x-envoy-upstream-service-time: '4' status: code: 400 message: Bad Request - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/sentiment?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_empty_credential_class.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_empty_credential_class.yaml index b76f0222ff40..5bb6df8b10a3 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_empty_credential_class.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_empty_credential_class.yaml @@ -10,20 +10,25 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"error":{"code":"401","message":"Access denied due to invalid subscription + string: '{"error":{"code":"401","message": "Access denied due to invalid subscription key or wrong API endpoint. Make sure to provide a valid key for an active subscription and use a correct regional API endpoint for your resource."}}' headers: - content-length: '224' - date: Thu, 02 Apr 2020 15:06:13 GMT + apim-request-id: 8e37488d-3feb-4d4b-8603-9402d0a1e1d0 + content-length: '225' + content-type: application/json + date: Wed, 22 Apr 2020 22:46:04 GMT + strict-transport-security: max-age=31536000; includeSubDomains; preload + www-authenticate: AzureApiManagementKey realm="https://westus2.ppe.cognitiveservices.azure.com/text/analytics",name="Ocp-Apim-Subscription-Key",type="header" + x-content-type-options: nosniff status: code: 401 - message: PermissionDenied - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/sentiment?showStats=false + message: Access Denied + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_input_with_all_errors.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_input_with_all_errors.yaml index 73e98b18d69a..99a7b277d058 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_input_with_all_errors.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_input_with_all_errors.yaml @@ -11,29 +11,29 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: string: '{"documents":[],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}},{"id":"2","error":{"code":"InvalidArgument","message":"Invalid - Language Code.","innerError":{"code":"UnsupportedLanguageCode","message":"Supplied + Language Code.","innererror":{"code":"UnsupportedLanguageCode","message":"Supplied language not supported. Pass in one of: de,en,es,fr,it,ja,ko,nl,pt-PT,zh-Hans,zh-Hant"}}},{"id":"3","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}}],"modelVersion":"2019-10-01"}' headers: - apim-request-id: d9455523-f876-45d6-a164-8cdfcd918779 + apim-request-id: fbe84abd-45b7-4768-ab2f-c67f686bead4 content-type: application/json; charset=utf-8 - date: Thu, 02 Apr 2020 15:06:13 GMT + date: Wed, 22 Apr 2020 22:46:04 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '3' + x-envoy-upstream-service-time: '2' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/sentiment?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_input_with_some_errors.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_input_with_some_errors.yaml index 33c255f59443..79ffd2f9fd3b 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_input_with_some_errors.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_input_with_some_errors.yaml @@ -12,28 +12,30 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"documents":[{"id":"3","sentiment":"positive","documentScores":{"positive":0.98,"neutral":0.02,"negative":0.0},"sentences":[{"sentiment":"positive","sentenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"offset":0,"length":36},{"sentiment":"positive","sentenceScores":{"positive":0.96,"neutral":0.03,"negative":0.01},"offset":37,"length":23}]}],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + string: '{"documents":[{"id":"3","sentiment":"positive","confidenceScores":{"positive":0.98,"neutral":0.02,"negative":0.0},"sentences":[{"sentiment":"positive","confidenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"offset":0,"length":36,"text":"The + restaurant had really good food."},{"sentiment":"positive","confidenceScores":{"positive":0.96,"neutral":0.03,"negative":0.01},"offset":37,"length":23,"text":"I + recommend you try it."}],"warnings":[]}],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}},{"id":"2","error":{"code":"InvalidArgument","message":"Invalid - Language Code.","innerError":{"code":"UnsupportedLanguageCode","message":"Supplied + Language Code.","innererror":{"code":"UnsupportedLanguageCode","message":"Supplied language not supported. Pass in one of: de,en,es,fr,it,ja,ko,nl,pt-PT,zh-Hans,zh-Hant"}}}],"modelVersion":"2019-10-01"}' headers: - apim-request-id: bb357944-277c-420a-91f0-021e716b5aeb + apim-request-id: b34d264a-07db-4ea3-8e03-35093413583b content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=1 - date: Thu, 02 Apr 2020 15:06:14 GMT + date: Wed, 22 Apr 2020 22:46:04 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '108' + x-envoy-upstream-service-time: '103' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/sentiment?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_language_kwarg_spanish.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_language_kwarg_spanish.yaml index 8aed8aa17157..ecf660b5d7f3 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_language_kwarg_spanish.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_language_kwarg_spanish.yaml @@ -10,24 +10,25 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?model-version=latest&showStats=true + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?model-version=latest&showStats=true response: body: - string: '{"statistics":{"documentsCount":1,"validDocumentsCount":1,"erroneousDocumentsCount":0,"transactionsCount":1},"documents":[{"id":"0","sentiment":"neutral","statistics":{"charactersCount":35,"transactionsCount":1},"documentScores":{"positive":0.01,"neutral":0.98,"negative":0.01},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.01,"neutral":0.98,"negative":0.01},"offset":0,"length":35}]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"statistics":{"documentsCount":1,"validDocumentsCount":1,"erroneousDocumentsCount":0,"transactionsCount":1},"documents":[{"id":"0","sentiment":"neutral","statistics":{"charactersCount":35,"transactionsCount":1},"confidenceScores":{"positive":0.01,"neutral":0.98,"negative":0.01},"sentences":[{"sentiment":"neutral","confidenceScores":{"positive":0.01,"neutral":0.98,"negative":0.01},"offset":0,"length":35,"text":"Bill + Gates is the CEO of Microsoft."}],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: - apim-request-id: 5b5092f0-5d6f-46b1-954b-1c2e8c2c90a8 + apim-request-id: 808cf631-c1aa-4b6b-b53d-4853ad8b113f content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=1 - date: Thu, 02 Apr 2020 15:06:15 GMT + date: Wed, 22 Apr 2020 22:46:04 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '125' + x-envoy-upstream-service-time: '127' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/sentiment?model-version=latest&showStats=true + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?model-version=latest&showStats=true version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_missing_input_records_error.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_missing_input_records_error.yaml deleted file mode 100644 index ef45ca375e14..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_missing_input_records_error.yaml +++ /dev/null @@ -1,32 +0,0 @@ -interactions: -- request: - body: '{"documents": []}' - headers: - Accept: - - application/json - Content-Length: - - '17' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false - response: - body: - string: '{"error":{"code":"InvalidRequest","message":"Invalid Request.","innerError":{"code":"MissingInputRecords","message":"Missing - input records."}}}' - headers: - apim-request-id: e45bc4b8-dcb7-4908-99bf-f04de6dea903 - content-type: application/json; charset=utf-8 - date: Thu, 02 Apr 2020 15:06:15 GMT - strict-transport-security: max-age=31536000; includeSubDomains; preload - transfer-encoding: chunked - x-content-type-options: nosniff - x-envoy-upstream-service-time: '5' - status: - code: 400 - message: Bad Request - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/sentiment?showStats=false -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_out_of_order_ids.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_out_of_order_ids.yaml index 558163ffcb92..947c212324a9 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_out_of_order_ids.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_out_of_order_ids.yaml @@ -12,26 +12,26 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"documents":[{"id":"56","sentiment":"positive","documentScores":{"positive":0.89,"neutral":0.1,"negative":0.01},"sentences":[{"sentiment":"positive","sentenceScores":{"positive":0.89,"neutral":0.1,"negative":0.01},"offset":0,"length":2}]},{"id":"0","sentiment":"negative","documentScores":{"positive":0.0,"neutral":0.02,"negative":0.98},"sentences":[{"sentiment":"negative","sentenceScores":{"positive":0.0,"neutral":0.02,"negative":0.98},"offset":0,"length":2}]},{"id":"19","sentiment":"neutral","documentScores":{"positive":0.3,"neutral":0.67,"negative":0.03},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.3,"neutral":0.67,"negative":0.03},"offset":0,"length":2}]},{"id":"1","sentiment":"positive","documentScores":{"positive":0.89,"neutral":0.1,"negative":0.01},"sentences":[{"sentiment":"positive","sentenceScores":{"positive":0.89,"neutral":0.1,"negative":0.01},"offset":0,"length":2}]}],"errors":[{"id":"22","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + string: '{"documents":[{"id":"56","sentiment":"positive","confidenceScores":{"positive":0.89,"neutral":0.1,"negative":0.01},"sentences":[{"sentiment":"positive","confidenceScores":{"positive":0.89,"neutral":0.1,"negative":0.01},"offset":0,"length":2,"text":":)"}],"warnings":[]},{"id":"0","sentiment":"negative","confidenceScores":{"positive":0.0,"neutral":0.02,"negative":0.98},"sentences":[{"sentiment":"negative","confidenceScores":{"positive":0.0,"neutral":0.02,"negative":0.98},"offset":0,"length":2,"text":":("}],"warnings":[]},{"id":"19","sentiment":"neutral","confidenceScores":{"positive":0.3,"neutral":0.67,"negative":0.03},"sentences":[{"sentiment":"neutral","confidenceScores":{"positive":0.3,"neutral":0.67,"negative":0.03},"offset":0,"length":2,"text":":P"}],"warnings":[]},{"id":"1","sentiment":"positive","confidenceScores":{"positive":0.89,"neutral":0.1,"negative":0.01},"sentences":[{"sentiment":"positive","confidenceScores":{"positive":0.89,"neutral":0.1,"negative":0.01},"offset":0,"length":2,"text":":D"}],"warnings":[]}],"errors":[{"id":"22","error":{"code":"InvalidArgument","message":"Invalid + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}}],"modelVersion":"2019-10-01"}' headers: - apim-request-id: ea1a87d0-564a-4e56-9d14-5811832bea96 + apim-request-id: 7475a1bc-f309-4388-a901-5c9942287859 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=4 - date: Thu, 02 Apr 2020 15:06:16 GMT + date: Wed, 22 Apr 2020 22:46:06 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '118' + x-envoy-upstream-service-time: '102' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/sentiment?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_pass_cls.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_pass_cls.yaml index 80bba7ad0ae3..f89bb1353fbf 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_pass_cls.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_pass_cls.yaml @@ -10,24 +10,25 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"documents":[{"id":"0","sentiment":"neutral","documentScores":{"positive":0.32,"neutral":0.65,"negative":0.03},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.32,"neutral":0.65,"negative":0.03},"offset":0,"length":28}]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"0","sentiment":"neutral","confidenceScores":{"positive":0.32,"neutral":0.65,"negative":0.03},"sentences":[{"sentiment":"neutral","confidenceScores":{"positive":0.32,"neutral":0.65,"negative":0.03},"offset":0,"length":28,"text":"Test + passing cls to endpoint"}],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: - apim-request-id: 43e42a2d-b6c5-4eca-ac5f-0d2a47b17389 + apim-request-id: f83d2a46-15fa-4c4c-a79f-770d897a1fe3 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=1 - date: Thu, 02 Apr 2020 15:06:16 GMT + date: Wed, 22 Apr 2020 22:46:06 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '100' + x-envoy-upstream-service-time: '101' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/sentiment?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_passing_only_string.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_passing_only_string.yaml index d351b766de73..c3dd3bfdf0eb 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_passing_only_string.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_passing_only_string.yaml @@ -13,26 +13,31 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"documents":[{"id":"0","sentiment":"neutral","documentScores":{"positive":0.01,"neutral":0.99,"negative":0.0},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.01,"neutral":0.99,"negative":0.0},"offset":0,"length":51}]},{"id":"1","sentiment":"negative","documentScores":{"positive":0.01,"neutral":0.22,"negative":0.77},"sentences":[{"sentiment":"negative","sentenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"offset":0,"length":38},{"sentiment":"negative","sentenceScores":{"positive":0.0,"neutral":0.0,"negative":1.0},"offset":39,"length":21}]},{"id":"2","sentiment":"positive","documentScores":{"positive":0.98,"neutral":0.02,"negative":0.0},"sentences":[{"sentiment":"positive","sentenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"offset":0,"length":36},{"sentiment":"positive","sentenceScores":{"positive":0.96,"neutral":0.03,"negative":0.01},"offset":37,"length":23}]}],"errors":[{"id":"3","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + string: '{"documents":[{"id":"0","sentiment":"neutral","confidenceScores":{"positive":0.01,"neutral":0.99,"negative":0.0},"sentences":[{"sentiment":"neutral","confidenceScores":{"positive":0.01,"neutral":0.99,"negative":0.0},"offset":0,"length":51,"text":"Microsoft + was founded by Bill Gates and Paul Allen."}],"warnings":[]},{"id":"1","sentiment":"negative","confidenceScores":{"positive":0.01,"neutral":0.22,"negative":0.77},"sentences":[{"sentiment":"negative","confidenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"offset":0,"length":38,"text":"I + did not like the hotel we stayed at."},{"sentiment":"negative","confidenceScores":{"positive":0.0,"neutral":0.0,"negative":1.0},"offset":39,"length":21,"text":"It + was too expensive."}],"warnings":[]},{"id":"2","sentiment":"positive","confidenceScores":{"positive":0.98,"neutral":0.02,"negative":0.0},"sentences":[{"sentiment":"positive","confidenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"offset":0,"length":36,"text":"The + restaurant had really good food."},{"sentiment":"positive","confidenceScores":{"positive":0.96,"neutral":0.03,"negative":0.01},"offset":37,"length":23,"text":"I + recommend you try it."}],"warnings":[]}],"errors":[{"id":"3","error":{"code":"InvalidArgument","message":"Invalid + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}}],"modelVersion":"2019-10-01"}' headers: - apim-request-id: 82e19695-e3c7-4f9f-a518-f71d0b5a5e82 + apim-request-id: 4dac937b-3f0e-4c83-969e-342eb818951f content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:06:17 GMT + date: Wed, 22 Apr 2020 22:46:06 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '107' + x-envoy-upstream-service-time: '135' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/sentiment?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_per_item_dont_use_language_hint.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_per_item_dont_use_language_hint.yaml index bfe826e385d3..86879339c146 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_per_item_dont_use_language_hint.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_per_item_dont_use_language_hint.yaml @@ -12,24 +12,27 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"documents":[{"id":"1","sentiment":"neutral","documentScores":{"positive":0.09,"neutral":0.9,"negative":0.01},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.09,"neutral":0.9,"negative":0.01},"offset":0,"length":22}]},{"id":"2","sentiment":"negative","documentScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"sentences":[{"sentiment":"negative","sentenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"offset":0,"length":38}]},{"id":"3","sentiment":"positive","documentScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"sentences":[{"sentiment":"positive","sentenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"offset":0,"length":36}]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"1","sentiment":"neutral","confidenceScores":{"positive":0.09,"neutral":0.9,"negative":0.01},"sentences":[{"sentiment":"neutral","confidenceScores":{"positive":0.09,"neutral":0.9,"negative":0.01},"offset":0,"length":22,"text":"I + will go to the park."}],"warnings":[]},{"id":"2","sentiment":"negative","confidenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"sentences":[{"sentiment":"negative","confidenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"offset":0,"length":38,"text":"I + did not like the hotel we stayed at."}],"warnings":[]},{"id":"3","sentiment":"positive","confidenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"sentences":[{"sentiment":"positive","confidenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"offset":0,"length":36,"text":"The + restaurant had really good food."}],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: - apim-request-id: f4328b44-9d5e-43e2-ae2f-7ac3af561158 + apim-request-id: 600f5763-a0db-4cde-9c03-05b21c9c1540 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:06:17 GMT + date: Wed, 22 Apr 2020 22:46:06 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '101' + x-envoy-upstream-service-time: '117' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/sentiment?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_rotate_subscription_key.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_rotate_subscription_key.yaml index 22ad02419c25..1b8d36e6cad8 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_rotate_subscription_key.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_rotate_subscription_key.yaml @@ -12,26 +12,29 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"documents":[{"id":"1","sentiment":"neutral","documentScores":{"positive":0.09,"neutral":0.9,"negative":0.01},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.09,"neutral":0.9,"negative":0.01},"offset":0,"length":22}]},{"id":"2","sentiment":"negative","documentScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"sentences":[{"sentiment":"negative","sentenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"offset":0,"length":38}]},{"id":"3","sentiment":"positive","documentScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"sentences":[{"sentiment":"positive","sentenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"offset":0,"length":36}]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"1","sentiment":"neutral","confidenceScores":{"positive":0.09,"neutral":0.9,"negative":0.01},"sentences":[{"sentiment":"neutral","confidenceScores":{"positive":0.09,"neutral":0.9,"negative":0.01},"offset":0,"length":22,"text":"I + will go to the park."}],"warnings":[]},{"id":"2","sentiment":"negative","confidenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"sentences":[{"sentiment":"negative","confidenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"offset":0,"length":38,"text":"I + did not like the hotel we stayed at."}],"warnings":[]},{"id":"3","sentiment":"positive","confidenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"sentences":[{"sentiment":"positive","confidenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"offset":0,"length":36,"text":"The + restaurant had really good food."}],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: - apim-request-id: 5f331bb7-bea0-45ce-86ed-3ba820313e4b + apim-request-id: c680fa33-dafc-44cf-8d3b-c38870261498 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:06:17 GMT + date: Wed, 22 Apr 2020 22:46:08 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '106' + x-envoy-upstream-service-time: '131' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/sentiment?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false - request: body: '{"documents": [{"id": "1", "text": "I will go to the park.", "language": "en"}, {"id": "2", "text": "I did not like the hotel we stayed at.", "language": @@ -45,22 +48,27 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"error":{"code":"401","message":"Access denied due to invalid subscription + string: '{"error":{"code":"401","message": "Access denied due to invalid subscription key or wrong API endpoint. Make sure to provide a valid key for an active subscription and use a correct regional API endpoint for your resource."}}' headers: - content-length: '224' - date: Thu, 02 Apr 2020 15:06:17 GMT + apim-request-id: 8d694288-e2b6-4732-a893-3cfd0557a921 + content-length: '225' + content-type: application/json + date: Wed, 22 Apr 2020 22:46:08 GMT + strict-transport-security: max-age=31536000; includeSubDomains; preload + www-authenticate: AzureApiManagementKey realm="https://westus2.ppe.cognitiveservices.azure.com/text/analytics",name="Ocp-Apim-Subscription-Key",type="header" + x-content-type-options: nosniff status: code: 401 - message: PermissionDenied - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/sentiment?showStats=false + message: Access Denied + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false - request: body: '{"documents": [{"id": "1", "text": "I will go to the park.", "language": "en"}, {"id": "2", "text": "I did not like the hotel we stayed at.", "language": @@ -74,24 +82,27 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"documents":[{"id":"1","sentiment":"neutral","documentScores":{"positive":0.09,"neutral":0.9,"negative":0.01},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.09,"neutral":0.9,"negative":0.01},"offset":0,"length":22}]},{"id":"2","sentiment":"negative","documentScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"sentences":[{"sentiment":"negative","sentenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"offset":0,"length":38}]},{"id":"3","sentiment":"positive","documentScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"sentences":[{"sentiment":"positive","sentenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"offset":0,"length":36}]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"1","sentiment":"neutral","confidenceScores":{"positive":0.09,"neutral":0.9,"negative":0.01},"sentences":[{"sentiment":"neutral","confidenceScores":{"positive":0.09,"neutral":0.9,"negative":0.01},"offset":0,"length":22,"text":"I + will go to the park."}],"warnings":[]},{"id":"2","sentiment":"negative","confidenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"sentences":[{"sentiment":"negative","confidenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"offset":0,"length":38,"text":"I + did not like the hotel we stayed at."}],"warnings":[]},{"id":"3","sentiment":"positive","confidenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"sentences":[{"sentiment":"positive","confidenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"offset":0,"length":36,"text":"The + restaurant had really good food."}],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: - apim-request-id: 6cfa1ac6-5b70-4385-91be-caf344fdc4b4 + apim-request-id: 29c509e6-ce62-49ee-8ce5-88807d8e6d1c content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:06:17 GMT + date: Wed, 22 Apr 2020 22:46:08 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '112' + x-envoy-upstream-service-time: '127' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/sentiment?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_show_stats_and_model_version.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_show_stats_and_model_version.yaml index e6b281c08a0f..2afd625a820c 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_show_stats_and_model_version.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_show_stats_and_model_version.yaml @@ -12,26 +12,26 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?model-version=latest&showStats=true + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?model-version=latest&showStats=true response: body: - string: '{"statistics":{"documentsCount":5,"validDocumentsCount":4,"erroneousDocumentsCount":1,"transactionsCount":4},"documents":[{"id":"56","sentiment":"positive","statistics":{"charactersCount":2,"transactionsCount":1},"documentScores":{"positive":0.89,"neutral":0.1,"negative":0.01},"sentences":[{"sentiment":"positive","sentenceScores":{"positive":0.89,"neutral":0.1,"negative":0.01},"offset":0,"length":2}]},{"id":"0","sentiment":"negative","statistics":{"charactersCount":2,"transactionsCount":1},"documentScores":{"positive":0.0,"neutral":0.02,"negative":0.98},"sentences":[{"sentiment":"negative","sentenceScores":{"positive":0.0,"neutral":0.02,"negative":0.98},"offset":0,"length":2}]},{"id":"19","sentiment":"neutral","statistics":{"charactersCount":2,"transactionsCount":1},"documentScores":{"positive":0.3,"neutral":0.67,"negative":0.03},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.3,"neutral":0.67,"negative":0.03},"offset":0,"length":2}]},{"id":"1","sentiment":"positive","statistics":{"charactersCount":2,"transactionsCount":1},"documentScores":{"positive":0.89,"neutral":0.1,"negative":0.01},"sentences":[{"sentiment":"positive","sentenceScores":{"positive":0.89,"neutral":0.1,"negative":0.01},"offset":0,"length":2}]}],"errors":[{"id":"22","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + string: '{"statistics":{"documentsCount":5,"validDocumentsCount":4,"erroneousDocumentsCount":1,"transactionsCount":4},"documents":[{"id":"56","sentiment":"positive","statistics":{"charactersCount":2,"transactionsCount":1},"confidenceScores":{"positive":0.89,"neutral":0.1,"negative":0.01},"sentences":[{"sentiment":"positive","confidenceScores":{"positive":0.89,"neutral":0.1,"negative":0.01},"offset":0,"length":2,"text":":)"}],"warnings":[]},{"id":"0","sentiment":"negative","statistics":{"charactersCount":2,"transactionsCount":1},"confidenceScores":{"positive":0.0,"neutral":0.02,"negative":0.98},"sentences":[{"sentiment":"negative","confidenceScores":{"positive":0.0,"neutral":0.02,"negative":0.98},"offset":0,"length":2,"text":":("}],"warnings":[]},{"id":"19","sentiment":"neutral","statistics":{"charactersCount":2,"transactionsCount":1},"confidenceScores":{"positive":0.3,"neutral":0.67,"negative":0.03},"sentences":[{"sentiment":"neutral","confidenceScores":{"positive":0.3,"neutral":0.67,"negative":0.03},"offset":0,"length":2,"text":":P"}],"warnings":[]},{"id":"1","sentiment":"positive","statistics":{"charactersCount":2,"transactionsCount":1},"confidenceScores":{"positive":0.89,"neutral":0.1,"negative":0.01},"sentences":[{"sentiment":"positive","confidenceScores":{"positive":0.89,"neutral":0.1,"negative":0.01},"offset":0,"length":2,"text":":D"}],"warnings":[]}],"errors":[{"id":"22","error":{"code":"InvalidArgument","message":"Invalid + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}}],"modelVersion":"2019-10-01"}' headers: - apim-request-id: 65b0d88a-bef9-4cfb-b8f9-e5ec070d26fe + apim-request-id: 3627219d-93f8-4bca-9eba-4c8783027668 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=4 - date: Thu, 02 Apr 2020 15:06:18 GMT + date: Wed, 22 Apr 2020 22:46:09 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '109' + x-envoy-upstream-service-time: '132' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/sentiment?model-version=latest&showStats=true + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?model-version=latest&showStats=true version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_user_agent.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_user_agent.yaml index b852a1270138..3d4838d75c23 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_user_agent.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_user_agent.yaml @@ -12,24 +12,27 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"documents":[{"id":"1","sentiment":"neutral","documentScores":{"positive":0.09,"neutral":0.9,"negative":0.01},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.09,"neutral":0.9,"negative":0.01},"offset":0,"length":22}]},{"id":"2","sentiment":"negative","documentScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"sentences":[{"sentiment":"negative","sentenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"offset":0,"length":38}]},{"id":"3","sentiment":"positive","documentScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"sentences":[{"sentiment":"positive","sentenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"offset":0,"length":36}]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"1","sentiment":"neutral","confidenceScores":{"positive":0.09,"neutral":0.9,"negative":0.01},"sentences":[{"sentiment":"neutral","confidenceScores":{"positive":0.09,"neutral":0.9,"negative":0.01},"offset":0,"length":22,"text":"I + will go to the park."}],"warnings":[]},{"id":"2","sentiment":"negative","confidenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"sentences":[{"sentiment":"negative","confidenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"offset":0,"length":38,"text":"I + did not like the hotel we stayed at."}],"warnings":[]},{"id":"3","sentiment":"positive","confidenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"sentences":[{"sentiment":"positive","confidenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"offset":0,"length":36,"text":"The + restaurant had really good food."}],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: - apim-request-id: 7956afc9-a842-44da-8af8-63cf28c62ac6 + apim-request-id: fcb2e848-ba50-478b-a1f2-d7e20e815a9b content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:06:19 GMT + date: Wed, 22 Apr 2020 22:46:09 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '121' + x-envoy-upstream-service-time: '150' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/sentiment?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_whole_batch_dont_use_language_hint.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_whole_batch_dont_use_language_hint.yaml index 1fdae9174207..44c4c58f9aad 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_whole_batch_dont_use_language_hint.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_whole_batch_dont_use_language_hint.yaml @@ -12,24 +12,28 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"documents":[{"id":"0","sentiment":"positive","documentScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"sentences":[{"sentiment":"positive","sentenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"offset":0,"length":33}]},{"id":"1","sentiment":"negative","documentScores":{"positive":0.01,"neutral":0.22,"negative":0.77},"sentences":[{"sentiment":"negative","sentenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"offset":0,"length":38},{"sentiment":"negative","sentenceScores":{"positive":0.0,"neutral":0.0,"negative":1.0},"offset":39,"length":21}]},{"id":"2","sentiment":"negative","documentScores":{"positive":0.01,"neutral":0.0,"negative":0.99},"sentences":[{"sentiment":"negative","sentenceScores":{"positive":0.01,"neutral":0.0,"negative":0.99},"offset":0,"length":42}]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"0","sentiment":"positive","confidenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"sentences":[{"sentiment":"positive","confidenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"offset":0,"length":33,"text":"This + was the best day of my life."}],"warnings":[]},{"id":"1","sentiment":"negative","confidenceScores":{"positive":0.01,"neutral":0.22,"negative":0.77},"sentences":[{"sentiment":"negative","confidenceScores":{"positive":0.01,"neutral":0.45,"negative":0.54},"offset":0,"length":38,"text":"I + did not like the hotel we stayed at."},{"sentiment":"negative","confidenceScores":{"positive":0.0,"neutral":0.0,"negative":1.0},"offset":39,"length":21,"text":"It + was too expensive."}],"warnings":[]},{"id":"2","sentiment":"negative","confidenceScores":{"positive":0.01,"neutral":0.0,"negative":0.99},"sentences":[{"sentiment":"negative","confidenceScores":{"positive":0.01,"neutral":0.0,"negative":0.99},"offset":0,"length":42,"text":"The + restaurant was not as good as I hoped."}],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: - apim-request-id: fee9cc64-82f6-4ae4-a431-875e1c59be2a + apim-request-id: 37065f4e-6fc8-417e-a505-66dc82f62216 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:06:19 GMT + date: Wed, 22 Apr 2020 22:46:09 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '124' + x-envoy-upstream-service-time: '105' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/sentiment?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_whole_batch_language_hint.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_whole_batch_language_hint.yaml index a2faf8378e5b..262a32abacbe 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_whole_batch_language_hint.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_whole_batch_language_hint.yaml @@ -12,24 +12,28 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"documents":[{"id":"0","sentiment":"neutral","documentScores":{"positive":0.07,"neutral":0.93,"negative":0.0},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.07,"neutral":0.93,"negative":0.0},"offset":0,"length":33}]},{"id":"1","sentiment":"negative","documentScores":{"positive":0.0,"neutral":0.03,"negative":0.97},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.0,"neutral":0.92,"negative":0.08},"offset":0,"length":38},{"sentiment":"negative","sentenceScores":{"positive":0.0,"neutral":0.03,"negative":0.97},"offset":39,"length":21}]},{"id":"2","sentiment":"negative","documentScores":{"positive":0.01,"neutral":0.32,"negative":0.67},"sentences":[{"sentiment":"negative","sentenceScores":{"positive":0.01,"neutral":0.32,"negative":0.67},"offset":0,"length":42}]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"0","sentiment":"neutral","confidenceScores":{"positive":0.07,"neutral":0.93,"negative":0.0},"sentences":[{"sentiment":"neutral","confidenceScores":{"positive":0.07,"neutral":0.93,"negative":0.0},"offset":0,"length":33,"text":"This + was the best day of my life."}],"warnings":[]},{"id":"1","sentiment":"negative","confidenceScores":{"positive":0.0,"neutral":0.03,"negative":0.97},"sentences":[{"sentiment":"neutral","confidenceScores":{"positive":0.0,"neutral":0.92,"negative":0.08},"offset":0,"length":38,"text":"I + did not like the hotel we stayed at."},{"sentiment":"negative","confidenceScores":{"positive":0.0,"neutral":0.03,"negative":0.97},"offset":39,"length":21,"text":"It + was too expensive."}],"warnings":[]},{"id":"2","sentiment":"negative","confidenceScores":{"positive":0.01,"neutral":0.32,"negative":0.67},"sentences":[{"sentiment":"negative","confidenceScores":{"positive":0.01,"neutral":0.32,"negative":0.67},"offset":0,"length":42,"text":"The + restaurant was not as good as I hoped."}],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: - apim-request-id: b77e171d-ba04-4ede-8994-df6a08a4aa4c + apim-request-id: 77ef59ac-b8a6-454d-b085-058646c092cd content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:06:19 GMT + date: Wed, 22 Apr 2020 22:46:10 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '104' + x-envoy-upstream-service-time: '138' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/sentiment?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_whole_batch_language_hint_and_dict_input.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_whole_batch_language_hint_and_dict_input.yaml index 98b8f4570142..d75b750c16a7 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_whole_batch_language_hint_and_dict_input.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_whole_batch_language_hint_and_dict_input.yaml @@ -12,24 +12,27 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"documents":[{"id":"1","sentiment":"neutral","documentScores":{"positive":0.04,"neutral":0.95,"negative":0.01},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.04,"neutral":0.95,"negative":0.01},"offset":0,"length":22}]},{"id":"2","sentiment":"neutral","documentScores":{"positive":0.01,"neutral":0.5,"negative":0.49},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.01,"neutral":0.5,"negative":0.49},"offset":0,"length":38}]},{"id":"3","sentiment":"positive","documentScores":{"positive":0.97,"neutral":0.02,"negative":0.01},"sentences":[{"sentiment":"positive","sentenceScores":{"positive":0.97,"neutral":0.02,"negative":0.01},"offset":0,"length":36}]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"1","sentiment":"neutral","confidenceScores":{"positive":0.04,"neutral":0.95,"negative":0.01},"sentences":[{"sentiment":"neutral","confidenceScores":{"positive":0.04,"neutral":0.95,"negative":0.01},"offset":0,"length":22,"text":"I + will go to the park."}],"warnings":[]},{"id":"2","sentiment":"neutral","confidenceScores":{"positive":0.01,"neutral":0.5,"negative":0.49},"sentences":[{"sentiment":"neutral","confidenceScores":{"positive":0.01,"neutral":0.5,"negative":0.49},"offset":0,"length":38,"text":"I + did not like the hotel we stayed at."}],"warnings":[]},{"id":"3","sentiment":"positive","confidenceScores":{"positive":0.97,"neutral":0.02,"negative":0.01},"sentences":[{"sentiment":"positive","confidenceScores":{"positive":0.97,"neutral":0.02,"negative":0.01},"offset":0,"length":36,"text":"The + restaurant had really good food."}],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: - apim-request-id: 571b280d-83dc-456e-86c7-dd0f7d710b0e + apim-request-id: 0f3c4d25-1b6c-4515-98a7-784786058e0b content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:06:20 GMT + date: Wed, 22 Apr 2020 22:46:11 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '126' + x-envoy-upstream-service-time: '142' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/sentiment?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_whole_batch_language_hint_and_dict_per_item_hints.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_whole_batch_language_hint_and_dict_per_item_hints.yaml index 4a5f50091737..2848c77d1fd1 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_whole_batch_language_hint_and_dict_per_item_hints.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_whole_batch_language_hint_and_dict_per_item_hints.yaml @@ -12,24 +12,27 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"documents":[{"id":"1","sentiment":"neutral","documentScores":{"positive":0.04,"neutral":0.95,"negative":0.01},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.04,"neutral":0.95,"negative":0.01},"offset":0,"length":22}]},{"id":"2","sentiment":"neutral","documentScores":{"positive":0.01,"neutral":0.5,"negative":0.49},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.01,"neutral":0.5,"negative":0.49},"offset":0,"length":38}]},{"id":"3","sentiment":"positive","documentScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"sentences":[{"sentiment":"positive","sentenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"offset":0,"length":36}]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"1","sentiment":"neutral","confidenceScores":{"positive":0.04,"neutral":0.95,"negative":0.01},"sentences":[{"sentiment":"neutral","confidenceScores":{"positive":0.04,"neutral":0.95,"negative":0.01},"offset":0,"length":22,"text":"I + will go to the park."}],"warnings":[]},{"id":"2","sentiment":"neutral","confidenceScores":{"positive":0.01,"neutral":0.5,"negative":0.49},"sentences":[{"sentiment":"neutral","confidenceScores":{"positive":0.01,"neutral":0.5,"negative":0.49},"offset":0,"length":38,"text":"I + did not like the hotel we stayed at."}],"warnings":[]},{"id":"3","sentiment":"positive","confidenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"sentences":[{"sentiment":"positive","confidenceScores":{"positive":1.0,"neutral":0.0,"negative":0.0},"offset":0,"length":36,"text":"The + restaurant had really good food."}],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: - apim-request-id: f06d6e20-0849-4cdd-9799-414b27c13724 + apim-request-id: 40785a29-ae1c-4b21-9d9b-f64c6c796f68 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:06:20 GMT + date: Wed, 22 Apr 2020 22:46:11 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '119' + x-envoy-upstream-service-time: '151' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/sentiment?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_whole_batch_language_hint_and_obj_input.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_whole_batch_language_hint_and_obj_input.yaml index 5f101c2b5f32..fcda8b1be6c8 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_whole_batch_language_hint_and_obj_input.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_whole_batch_language_hint_and_obj_input.yaml @@ -12,24 +12,37 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"documents":[{"id":"1","sentiment":"neutral","documentScores":{"positive":0.15,"neutral":0.81,"negative":0.04},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.15,"neutral":0.81,"negative":0.04},"offset":0,"length":41}]},{"id":"4","sentiment":"neutral","documentScores":{"positive":0.38,"neutral":0.48,"negative":0.14},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.38,"neutral":0.48,"negative":0.14},"offset":0,"length":39}]},{"id":"3","sentiment":"neutral","documentScores":{"positive":0.15,"neutral":0.79,"negative":0.06},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.15,"neutral":0.79,"negative":0.06},"offset":0,"length":4}]}],"errors":[],"modelVersion":"2019-10-01"}' + string: "{\"documents\":[{\"id\":\"1\",\"sentiment\":\"neutral\",\"confidenceScores\"\ + :{\"positive\":0.15,\"neutral\":0.81,\"negative\":0.04},\"sentences\":[{\"\ + sentiment\":\"neutral\",\"confidenceScores\":{\"positive\":0.15,\"neutral\"\ + :0.81,\"negative\":0.04},\"offset\":0,\"length\":41,\"text\":\"I should take\ + \ my cat to the veterinarian.\"}],\"warnings\":[]},{\"id\":\"4\",\"sentiment\"\ + :\"neutral\",\"confidenceScores\":{\"positive\":0.38,\"neutral\":0.48,\"negative\"\ + :0.14},\"sentences\":[{\"sentiment\":\"neutral\",\"confidenceScores\":{\"\ + positive\":0.38,\"neutral\":0.48,\"negative\":0.14},\"offset\":0,\"length\"\ + :39,\"text\":\"Este es un document escrito en Espa\xF1ol.\"}],\"warnings\"\ + :[]},{\"id\":\"3\",\"sentiment\":\"neutral\",\"confidenceScores\":{\"positive\"\ + :0.15,\"neutral\":0.79,\"negative\":0.06},\"sentences\":[{\"sentiment\":\"\ + neutral\",\"confidenceScores\":{\"positive\":0.15,\"neutral\":0.79,\"negative\"\ + :0.06},\"offset\":0,\"length\":4,\"text\":\"\u732B\u306F\u5E78\u305B\"}],\"\ + warnings\":[]}],\"errors\":[],\"modelVersion\":\"2019-10-01\"}" headers: - apim-request-id: 810f4c88-8722-421b-9df0-1af53de89ecd + apim-request-id: b46c3d39-905e-4e23-a70f-77daae79674e content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:06:21 GMT + date: Wed, 22 Apr 2020 22:46:11 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '146' + x-envoy-upstream-service-time: '119' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/sentiment?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_whole_batch_language_hint_and_obj_per_item_hints.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_whole_batch_language_hint_and_obj_per_item_hints.yaml index a00afe6ca646..353bf8771f46 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_whole_batch_language_hint_and_obj_per_item_hints.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_analyze_sentiment_async.test_whole_batch_language_hint_and_obj_per_item_hints.yaml @@ -12,24 +12,37 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/sentiment?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false response: body: - string: '{"documents":[{"id":"1","sentiment":"neutral","documentScores":{"positive":0.05,"neutral":0.94,"negative":0.01},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.05,"neutral":0.94,"negative":0.01},"offset":0,"length":41}]},{"id":"2","sentiment":"neutral","documentScores":{"positive":0.03,"neutral":0.92,"negative":0.05},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.03,"neutral":0.92,"negative":0.05},"offset":0,"length":39}]},{"id":"3","sentiment":"neutral","documentScores":{"positive":0.13,"neutral":0.81,"negative":0.06},"sentences":[{"sentiment":"neutral","sentenceScores":{"positive":0.13,"neutral":0.81,"negative":0.06},"offset":0,"length":4}]}],"errors":[],"modelVersion":"2019-10-01"}' + string: "{\"documents\":[{\"id\":\"1\",\"sentiment\":\"neutral\",\"confidenceScores\"\ + :{\"positive\":0.05,\"neutral\":0.94,\"negative\":0.01},\"sentences\":[{\"\ + sentiment\":\"neutral\",\"confidenceScores\":{\"positive\":0.05,\"neutral\"\ + :0.94,\"negative\":0.01},\"offset\":0,\"length\":41,\"text\":\"I should take\ + \ my cat to the veterinarian.\"}],\"warnings\":[]},{\"id\":\"2\",\"sentiment\"\ + :\"neutral\",\"confidenceScores\":{\"positive\":0.03,\"neutral\":0.92,\"negative\"\ + :0.05},\"sentences\":[{\"sentiment\":\"neutral\",\"confidenceScores\":{\"\ + positive\":0.03,\"neutral\":0.92,\"negative\":0.05},\"offset\":0,\"length\"\ + :39,\"text\":\"Este es un document escrito en Espa\xF1ol.\"}],\"warnings\"\ + :[]},{\"id\":\"3\",\"sentiment\":\"neutral\",\"confidenceScores\":{\"positive\"\ + :0.13,\"neutral\":0.81,\"negative\":0.06},\"sentences\":[{\"sentiment\":\"\ + neutral\",\"confidenceScores\":{\"positive\":0.13,\"neutral\":0.81,\"negative\"\ + :0.06},\"offset\":0,\"length\":4,\"text\":\"\u732B\u306F\u5E78\u305B\"}],\"\ + warnings\":[]}],\"errors\":[],\"modelVersion\":\"2019-10-01\"}" headers: - apim-request-id: 779b8b8f-f910-452a-9a02-34e57a483f49 + apim-request-id: 265199e7-45ea-45c9-adec-a0e0d0299928 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:06:22 GMT + date: Wed, 22 Apr 2020 22:46:12 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '125' + x-envoy-upstream-service-time: '126' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/sentiment?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/sentiment?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_all_successful_passing_dict.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_all_successful_passing_dict.yaml deleted file mode 100644 index 5daea694dfba..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_all_successful_passing_dict.yaml +++ /dev/null @@ -1,47 +0,0 @@ -interactions: -- request: - body: '{"documents": [{"id": "1", "text": "I should take my cat to the veterinarian.", - "countryHint": "US"}, {"id": "2", "text": "Este es un document escrito en Espa\u00f1ol.", - "countryHint": "US"}, {"id": "3", "text": "\u732b\u306f\u5e78\u305b", "countryHint": - "US"}, {"id": "4", "text": "Fahrt nach Stuttgart und dann zum Hotel zu Fu.", - "countryHint": "US"}]}' - headers: - Accept: - - application/json - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '354' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=true - response: - body: - string: '{"statistics":{"documentsCount":4,"validDocumentsCount":4,"erroneousDocumentsCount":0,"transactionsCount":4},"documents":[{"id":"1","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}],"statistics":{"charactersCount":41,"transactionsCount":1}},{"id":"2","detectedLanguages":[{"name":"Spanish","iso6391Name":"es","score":1.0}],"statistics":{"charactersCount":39,"transactionsCount":1}},{"id":"3","detectedLanguages":[{"name":"Japanese","iso6391Name":"ja","score":1.0}],"statistics":{"charactersCount":4,"transactionsCount":1}},{"id":"4","detectedLanguages":[{"name":"German","iso6391Name":"de","score":1.0}],"statistics":{"charactersCount":46,"transactionsCount":1}}],"errors":[],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: - - 4851d5a8-81fb-4e98-9406-e3343024cab2 - content-type: - - application/json; charset=utf-8 - csp-billing-usage: - - CognitiveServices.TextAnalytics.BatchScoring=4 - date: - - Thu, 02 Apr 2020 15:06:22 GMT - strict-transport-security: - - max-age=31536000; includeSubDomains; preload - transfer-encoding: - - chunked - x-content-type-options: - - nosniff - x-envoy-upstream-service-time: - - '4' - status: - code: 200 - message: OK -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_all_successful_passing_text_document_input.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_all_successful_passing_text_document_input.yaml deleted file mode 100644 index e620b2d22367..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_all_successful_passing_text_document_input.yaml +++ /dev/null @@ -1,47 +0,0 @@ -interactions: -- request: - body: '{"documents": [{"id": "1", "text": "I should take my cat to the veterinarian", - "language": "US"}, {"id": "2", "text": "Este es un document escrito en Espa\u00f1ol.", - "language": "US"}, {"id": "3", "text": "\u732b\u306f\u5e78\u305b", "language": - "US"}, {"id": "4", "text": "Fahrt nach Stuttgart und dann zum Hotel zu Fu.", - "language": "US"}]}' - headers: - Accept: - - application/json - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '341' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"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":"Japanese","iso6391Name":"ja","score":1.0}]},{"id":"4","detectedLanguages":[{"name":"German","iso6391Name":"de","score":1.0}]}],"errors":[],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: - - f66a1b5b-8da7-4c94-a705-0f7e36d7d618 - content-type: - - application/json; charset=utf-8 - csp-billing-usage: - - CognitiveServices.TextAnalytics.BatchScoring=4 - date: - - Thu, 02 Apr 2020 15:06:23 GMT - strict-transport-security: - - max-age=31536000; includeSubDomains; preload - transfer-encoding: - - chunked - x-content-type-options: - - nosniff - x-envoy-upstream-service-time: - - '2' - status: - code: 200 - message: OK -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_bad_credentials.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_bad_credentials.yaml index e4d19ecb9ac0..73e58cd2541d 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_bad_credentials.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_bad_credentials.yaml @@ -14,21 +14,31 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/languages?showStats=false response: body: - string: '{"error":{"code":"401","message":"Access denied due to invalid subscription + string: '{"error":{"code":"401","message": "Access denied due to invalid subscription key or wrong API endpoint. Make sure to provide a valid key for an active subscription and use a correct regional API endpoint for your resource."}}' headers: + apim-request-id: + - 4249adf5-1b75-4725-9b2a-a3def110d26e content-length: - - '224' + - '225' + content-type: + - application/json date: - - Thu, 02 Apr 2020 15:06:24 GMT + - Wed, 22 Apr 2020 22:46:50 GMT + strict-transport-security: + - max-age=31536000; includeSubDomains; preload + www-authenticate: + - AzureApiManagementKey realm="https://westus2.ppe.cognitiveservices.azure.com/text/analytics",name="Ocp-Apim-Subscription-Key",type="header" + x-content-type-options: + - nosniff status: code: 401 - message: PermissionDenied + message: Access Denied version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_bad_model_version.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_bad_model_version.yaml index 0f2d4aed3835..94d4ccb334cf 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_bad_model_version.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_bad_model_version.yaml @@ -14,21 +14,21 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?model-version=old&showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/languages?model-version=old&showStats=false response: body: string: '{"error":{"code":"InvalidRequest","message":"Specified Model version is incorrect. Allowed values are latest,2019-10-01"}}' headers: apim-request-id: - - 4348cf49-e795-4443-8812-6161afd73126 + - 3311ba23-80c3-42cc-b9ff-5d7d1bc178e8 content-type: - application/json; charset=utf-8 date: - - Thu, 02 Apr 2020 15:06:23 GMT + - Wed, 22 Apr 2020 22:46:50 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -36,7 +36,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '5' + - '145' status: code: 400 message: Bad Request diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_bad_model_version_error.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_bad_model_version_error.yaml index 73763e28df2a..d037b266378d 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_bad_model_version_error.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_bad_model_version_error.yaml @@ -14,21 +14,21 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?model-version=bad&showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/languages?model-version=bad&showStats=false response: body: string: '{"error":{"code":"InvalidRequest","message":"Specified Model version is incorrect. Allowed values are latest,2019-10-01"}}' headers: apim-request-id: - - 753a1e36-390d-467c-ab08-e2114d104d7a + - 200e6b5e-385f-48e9-999d-9e008d7ff34c content-type: - application/json; charset=utf-8 date: - - Thu, 02 Apr 2020 15:06:24 GMT + - Wed, 22 Apr 2020 22:46:51 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -36,7 +36,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '5' + - '127' status: code: 400 message: Bad Request diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_batch_size_over_limit.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_batch_size_over_limit.yaml index 09b7f1d52507..99e327145616 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_batch_size_over_limit.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_batch_size_over_limit.yaml @@ -763,21 +763,21 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/languages?showStats=false response: body: - string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innerError":{"code":"InvalidDocumentBatch","message":"Batch + string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innererror":{"code":"InvalidDocumentBatch","message":"Batch request contains too many records. Max 1000 records are permitted."}}}' headers: apim-request-id: - - 52822706-7519-4b31-a4b4-d11f7c8ac20e + - 139bb311-dd88-444f-98c5-2942d03af785 content-type: - application/json; charset=utf-8 date: - - Thu, 02 Apr 2020 15:06:25 GMT + - Wed, 22 Apr 2020 22:46:52 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -785,7 +785,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '24' + - '43' status: code: 400 message: Bad Request diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_batch_size_over_limit_error.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_batch_size_over_limit_error.yaml index ce79b29d9192..94f1d3642b1b 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_batch_size_over_limit_error.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_batch_size_over_limit_error.yaml @@ -728,21 +728,21 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/languages?showStats=false response: body: - string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innerError":{"code":"InvalidDocumentBatch","message":"Batch + string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innererror":{"code":"InvalidDocumentBatch","message":"Batch request contains too many records. Max 1000 records are permitted."}}}' headers: apim-request-id: - - 6ac32ddc-8cdf-443a-a6ee-ddc85e6955f0 + - 81d7a3b9-afb8-4ab6-a3a2-08389590a3e0 content-type: - application/json; charset=utf-8 date: - - Thu, 02 Apr 2020 15:06:26 GMT + - Wed, 22 Apr 2020 22:46:53 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -750,7 +750,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '19' + - '218' status: code: 400 message: Bad Request diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_client_passed_default_country_hint.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_client_passed_default_country_hint.yaml deleted file mode 100644 index 90735aa16d1e..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_client_passed_default_country_hint.yaml +++ /dev/null @@ -1,134 +0,0 @@ -interactions: -- request: - body: '{"documents": [{"id": "1", "text": "I will go to the park.", "countryHint": - "CA"}, {"id": "2", "text": "I did not like the hotel we stayed at.", "countryHint": - "CA"}, {"id": "3", "text": "The restaurant had really good food.", "countryHint": - "CA"}]}' - headers: - Accept: - - application/json - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '249' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"documents":[{"id":"1","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"2","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"3","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]}],"errors":[],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: - - 1aacaa92-8097-4bc3-a399-3f58f895dbf7 - content-type: - - application/json; charset=utf-8 - csp-billing-usage: - - CognitiveServices.TextAnalytics.BatchScoring=3 - date: - - Thu, 02 Apr 2020 15:06:27 GMT - strict-transport-security: - - max-age=31536000; includeSubDomains; preload - transfer-encoding: - - chunked - x-content-type-options: - - nosniff - x-envoy-upstream-service-time: - - '3' - status: - code: 200 - message: OK -- request: - body: '{"documents": [{"id": "1", "text": "I will go to the park.", "countryHint": - "DE"}, {"id": "2", "text": "I did not like the hotel we stayed at.", "countryHint": - "DE"}, {"id": "3", "text": "The restaurant had really good food.", "countryHint": - "DE"}]}' - headers: - Accept: - - application/json - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '249' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"documents":[{"id":"1","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"2","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"3","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]}],"errors":[],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: - - e8fcd73f-1ea5-4d06-b24a-ac37c3efcc31 - content-type: - - application/json; charset=utf-8 - csp-billing-usage: - - CognitiveServices.TextAnalytics.BatchScoring=3 - date: - - Thu, 02 Apr 2020 15:06:27 GMT - strict-transport-security: - - max-age=31536000; includeSubDomains; preload - transfer-encoding: - - chunked - x-content-type-options: - - nosniff - x-envoy-upstream-service-time: - - '4' - status: - code: 200 - message: OK -- request: - body: '{"documents": [{"id": "1", "text": "I will go to the park.", "countryHint": - "CA"}, {"id": "2", "text": "I did not like the hotel we stayed at.", "countryHint": - "CA"}, {"id": "3", "text": "The restaurant had really good food.", "countryHint": - "CA"}]}' - headers: - Accept: - - application/json - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '249' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"documents":[{"id":"1","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"2","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"3","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]}],"errors":[],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: - - 0544079e-f574-457d-94c0-4678a3e533ee - content-type: - - application/json; charset=utf-8 - csp-billing-usage: - - CognitiveServices.TextAnalytics.BatchScoring=3 - date: - - Thu, 02 Apr 2020 15:06:27 GMT - strict-transport-security: - - max-age=31536000; includeSubDomains; preload - transfer-encoding: - - chunked - x-content-type-options: - - nosniff - x-envoy-upstream-service-time: - - '3' - status: - code: 200 - message: OK -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_country_hint_kwarg.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_country_hint_kwarg.yaml deleted file mode 100644 index 49723bc4e34d..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_country_hint_kwarg.yaml +++ /dev/null @@ -1,44 +0,0 @@ -interactions: -- request: - body: '{"documents": [{"id": "0", "text": "this is written in english", "countryHint": - "ES"}]}' - headers: - Accept: - - application/json - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '87' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?model-version=latest&showStats=true - response: - body: - string: '{"statistics":{"documentsCount":1,"validDocumentsCount":1,"erroneousDocumentsCount":0,"transactionsCount":1},"documents":[{"id":"0","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}],"statistics":{"charactersCount":26,"transactionsCount":1}}],"errors":[],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: - - c2486a24-b4a3-439c-89bb-17c2d3ee528e - content-type: - - application/json; charset=utf-8 - csp-billing-usage: - - CognitiveServices.TextAnalytics.BatchScoring=1 - date: - - Thu, 02 Apr 2020 15:06:27 GMT - strict-transport-security: - - max-age=31536000; includeSubDomains; preload - transfer-encoding: - - chunked - x-content-type-options: - - nosniff - x-envoy-upstream-service-time: - - '4' - status: - code: 200 - message: OK -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_country_hint_none.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_country_hint_none.yaml deleted file mode 100644 index 9fe361d9ae9a..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_country_hint_none.yaml +++ /dev/null @@ -1,170 +0,0 @@ -interactions: -- request: - body: '{"documents": [{"id": "0", "text": "This is written in English.", "countryHint": - ""}]}' - headers: - Accept: - - application/json - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '86' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"documents":[{"id":"0","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]}],"errors":[],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: - - d9d451e5-b3d9-4ed2-bf77-6db1a222bb58 - content-type: - - application/json; charset=utf-8 - csp-billing-usage: - - CognitiveServices.TextAnalytics.BatchScoring=1 - date: - - Thu, 02 Apr 2020 15:06:27 GMT - strict-transport-security: - - max-age=31536000; includeSubDomains; preload - transfer-encoding: - - chunked - x-content-type-options: - - nosniff - x-envoy-upstream-service-time: - - '3' - status: - code: 200 - message: OK -- request: - body: '{"documents": [{"id": "1", "text": "This is written in English.", "countryHint": - ""}]}' - headers: - Accept: - - application/json - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '86' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"documents":[{"id":"1","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]}],"errors":[],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: - - cab09860-5dd5-46d7-9395-8eeb9a3ba631 - content-type: - - application/json; charset=utf-8 - csp-billing-usage: - - CognitiveServices.TextAnalytics.BatchScoring=1 - date: - - Thu, 02 Apr 2020 15:06:27 GMT - strict-transport-security: - - max-age=31536000; includeSubDomains; preload - transfer-encoding: - - chunked - x-content-type-options: - - nosniff - x-envoy-upstream-service-time: - - '3' - status: - code: 200 - message: OK -- request: - body: '{"documents": [{"id": "0", "text": "this is written in english", "countryHint": - ""}]}' - headers: - Accept: - - application/json - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '85' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"documents":[{"id":"0","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]}],"errors":[],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: - - 11149e30-1eb7-409a-8586-17c40a8373df - content-type: - - application/json; charset=utf-8 - csp-billing-usage: - - CognitiveServices.TextAnalytics.BatchScoring=1 - date: - - Thu, 02 Apr 2020 15:06:27 GMT - strict-transport-security: - - max-age=31536000; includeSubDomains; preload - transfer-encoding: - - chunked - x-content-type-options: - - nosniff - x-envoy-upstream-service-time: - - '3' - status: - code: 200 - message: OK -- request: - body: '{"documents": [{"id": "0", "text": "this is written in english", "countryHint": - ""}]}' - headers: - Accept: - - application/json - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '85' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"documents":[{"id":"0","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]}],"errors":[],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: - - f618efd6-8bd5-4cf0-834c-f547452a57d9 - content-type: - - application/json; charset=utf-8 - csp-billing-usage: - - CognitiveServices.TextAnalytics.BatchScoring=1 - date: - - Thu, 02 Apr 2020 15:06:27 GMT - strict-transport-security: - - max-age=31536000; includeSubDomains; preload - transfer-encoding: - - chunked - x-content-type-options: - - nosniff - x-envoy-upstream-service-time: - - '3' - status: - code: 200 - message: OK -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_document_attribute_error_no_result_attribute.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_document_attribute_error_no_result_attribute.yaml index 517c6559a9b5..e67e7bb41a61 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_document_attribute_error_no_result_attribute.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_document_attribute_error_no_result_attribute.yaml @@ -13,24 +13,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/languages?showStats=false response: body: string: '{"documents":[],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}}],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - 17747ebd-2590-4df2-ac12-0064fd218b84 + - 56433000-4f81-417d-838e-bd6c28f269ec content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=0 date: - - Thu, 02 Apr 2020 15:06:29 GMT + - Wed, 22 Apr 2020 22:46:54 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -38,7 +38,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '3' + - '7' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_document_attribute_error_nonexistent_attribute.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_document_attribute_error_nonexistent_attribute.yaml index afa76c0b19ad..7567e0e26f52 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_document_attribute_error_nonexistent_attribute.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_document_attribute_error_nonexistent_attribute.yaml @@ -13,24 +13,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/languages?showStats=false response: body: string: '{"documents":[],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}}],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - 8c04d159-626b-470f-bd5e-ae96a06aeb56 + - 460042f8-28fe-43bf-bd66-2115b98d7a4a content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=0 date: - - Thu, 02 Apr 2020 15:06:28 GMT + - Wed, 22 Apr 2020 22:46:55 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -38,7 +38,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '4' + - '2' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_document_errors.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_document_errors.yaml index ad1fb0ed6313..1f1ce241a57e 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_document_errors.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_document_errors.yaml @@ -15,28 +15,28 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/languages?showStats=false response: body: string: '{"documents":[],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}},{"id":"2","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"A + document in request.","innererror":{"code":"InvalidDocument","message":"A document within the request was too large to be processed. Limit document size to: 5120 text elements. For additional details on the data limitations see https://aka.ms/text-analytics-data-limits"}}}],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - 35afd862-96e7-4601-9756-8a34e925a656 + - fe0c1bac-3df2-4cb9-927f-c17ba8d65c6a content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=0 date: - - Thu, 02 Apr 2020 15:06:29 GMT + - Wed, 22 Apr 2020 22:46:55 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_duplicate_ids_error.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_duplicate_ids_error.yaml index 6b933fae1943..bf7d7dc1b7ba 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_duplicate_ids_error.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_duplicate_ids_error.yaml @@ -15,21 +15,21 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/languages?showStats=false response: body: - string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innerError":{"code":"InvalidDocument","message":"Request + string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innererror":{"code":"InvalidDocument","message":"Request contains duplicated Ids. Make sure each document has a unique Id."}}}' headers: apim-request-id: - - aceadd06-d91a-430a-a2fa-59c20ce70858 + - 5e870ebf-026d-4129-abe3-b87cbb9e7f95 content-type: - application/json; charset=utf-8 date: - - Thu, 02 Apr 2020 15:06:30 GMT + - Wed, 22 Apr 2020 22:46:55 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -37,7 +37,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '4' + - '3' status: code: 400 message: Bad Request diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_empty_credential_class.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_empty_credential_class.yaml index 8331e3ceb560..655a46f003e1 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_empty_credential_class.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_empty_credential_class.yaml @@ -14,21 +14,31 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/languages?showStats=false response: body: - string: '{"error":{"code":"401","message":"Access denied due to invalid subscription + string: '{"error":{"code":"401","message": "Access denied due to invalid subscription key or wrong API endpoint. Make sure to provide a valid key for an active subscription and use a correct regional API endpoint for your resource."}}' headers: + apim-request-id: + - 050960b8-1206-4bbf-afc6-ccc000077141 content-length: - - '224' + - '225' + content-type: + - application/json date: - - Thu, 02 Apr 2020 15:06:30 GMT + - Wed, 22 Apr 2020 22:46:56 GMT + strict-transport-security: + - max-age=31536000; includeSubDomains; preload + www-authenticate: + - AzureApiManagementKey realm="https://westus2.ppe.cognitiveservices.azure.com/text/analytics",name="Ocp-Apim-Subscription-Key",type="header" + x-content-type-options: + - nosniff status: code: 401 - message: PermissionDenied + message: Access Denied version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_input_with_all_errors.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_input_with_all_errors.yaml index b95c290d725f..b3e9591505ac 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_input_with_all_errors.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_input_with_all_errors.yaml @@ -16,32 +16,32 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/languages?showStats=false response: body: string: '{"documents":[],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}},{"id":"2","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}},{"id":"3","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}},{"id":"4","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"A + document in request.","innererror":{"code":"InvalidDocument","message":"A document within the request was too large to be processed. Limit document size to: 5120 text elements. For additional details on the data limitations see https://aka.ms/text-analytics-data-limits"}}}],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - bc60de3b-dacf-4a52-ab33-23c3f5a4569d + - 101d01ac-8784-41cb-9f4c-ad7bbbb9e58b content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=0 date: - - Thu, 02 Apr 2020 15:06:30 GMT + - Wed, 22 Apr 2020 22:46:57 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -49,7 +49,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '4' + - '22' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_input_with_some_errors.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_input_with_some_errors.yaml deleted file mode 100644 index ef90d881d412..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_input_with_some_errors.yaml +++ /dev/null @@ -1,52 +0,0 @@ -interactions: -- request: - body: '{"documents": [{"id": "1", "text": "I should take my cat to the veterinarian.", - "countryHint": "United States"}, {"id": "2", "text": "Este es un document escrito - en Espa\u00f1ol.", "countryHint": "US"}, {"id": "3", "text": "", "countryHint": - "US"}, {"id": "4", "text": "Fahrt nach Stuttgart und dann zum Hotel zu Fu.", - "countryHint": "US"}]}' - headers: - Accept: - - application/json - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '341' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"documents":[{"id":"2","detectedLanguages":[{"name":"Spanish","iso6391Name":"es","score":1.0}]},{"id":"4","detectedLanguages":[{"name":"German","iso6391Name":"de","score":1.0}]}],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - Country Hint.","innerError":{"code":"InvalidCountryHint","message":"Country - hint is not valid. Please specify an ISO 3166-1 alpha-2 two letter country - code."}}},{"id":"3","error":{"code":"InvalidArgument","message":"Invalid document - in request.","innerError":{"code":"InvalidDocument","message":"Document text - is empty."}}}],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: - - 81fed47a-30c7-4bd0-b5a3-040162acd096 - content-type: - - application/json; charset=utf-8 - csp-billing-usage: - - CognitiveServices.TextAnalytics.BatchScoring=2 - date: - - Thu, 02 Apr 2020 15:06:31 GMT - strict-transport-security: - - max-age=31536000; includeSubDomains; preload - transfer-encoding: - - chunked - x-content-type-options: - - nosniff - x-envoy-upstream-service-time: - - '3' - status: - code: 200 - message: OK -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_missing_input_records_error.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_missing_input_records_error.yaml deleted file mode 100644 index 316afde06e74..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_missing_input_records_error.yaml +++ /dev/null @@ -1,42 +0,0 @@ -interactions: -- request: - body: '{"documents": []}' - headers: - Accept: - - application/json - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '17' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"error":{"code":"InvalidRequest","message":"Invalid Request.","innerError":{"code":"MissingInputRecords","message":"Missing - input records."}}}' - headers: - apim-request-id: - - 424cd8b9-b706-475f-8301-f00737529a62 - content-type: - - application/json; charset=utf-8 - date: - - Thu, 02 Apr 2020 15:06:32 GMT - strict-transport-security: - - max-age=31536000; includeSubDomains; preload - transfer-encoding: - - chunked - x-content-type-options: - - nosniff - x-envoy-upstream-service-time: - - '2' - status: - code: 400 - message: Bad Request -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_out_of_order_ids.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_out_of_order_ids.yaml deleted file mode 100644 index 20f9ce91dabc..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_out_of_order_ids.yaml +++ /dev/null @@ -1,48 +0,0 @@ -interactions: -- request: - body: '{"documents": [{"id": "56", "text": ":)", "countryHint": "US"}, {"id": - "0", "text": ":(", "countryHint": "US"}, {"id": "22", "text": "", "countryHint": - "US"}, {"id": "19", "text": ":P", "countryHint": "US"}, {"id": "1", "text": - ":D", "countryHint": "US"}]}' - headers: - Accept: - - application/json - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '256' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"documents":[{"id":"56","detectedLanguages":[{"name":"(Unknown)","iso6391Name":"(Unknown)","score":0.0}]},{"id":"0","detectedLanguages":[{"name":"(Unknown)","iso6391Name":"(Unknown)","score":0.0}]},{"id":"19","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"1","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]}],"errors":[{"id":"22","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document - text is empty."}}}],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: - - e0ab3969-4772-4e3b-a7d1-d0d6d56469c3 - content-type: - - application/json; charset=utf-8 - csp-billing-usage: - - CognitiveServices.TextAnalytics.BatchScoring=4 - date: - - Thu, 02 Apr 2020 15:06:31 GMT - strict-transport-security: - - max-age=31536000; includeSubDomains; preload - transfer-encoding: - - chunked - x-content-type-options: - - nosniff - x-envoy-upstream-service-time: - - '5' - status: - code: 200 - message: OK -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_pass_cls.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_pass_cls.yaml index 96a1d32938f0..ebb9b837472c 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_pass_cls.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_pass_cls.yaml @@ -14,22 +14,22 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/languages?showStats=false response: body: - string: '{"documents":[{"id":"0","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"0","detectedLanguage":{"name":"English","iso6391Name":"en","confidenceScore":1.0},"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - d48a981c-19f5-4128-a73d-f784ec87674c + - d2e785b2-f179-4f6d-9572-98e534c5c580 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=1 date: - - Thu, 02 Apr 2020 15:06:33 GMT + - Wed, 22 Apr 2020 22:46:57 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -37,7 +37,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '3' + - '2' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_passing_only_string.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_passing_only_string.yaml deleted file mode 100644 index 610b28538216..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_passing_only_string.yaml +++ /dev/null @@ -1,49 +0,0 @@ -interactions: -- request: - body: '{"documents": [{"id": "0", "text": "I should take my cat to the veterinarian.", - "countryHint": "US"}, {"id": "1", "text": "Este es un document escrito en Espa\u00f1ol.", - "countryHint": "US"}, {"id": "2", "text": "\u732b\u306f\u5e78\u305b", "countryHint": - "US"}, {"id": "3", "text": "Fahrt nach Stuttgart und dann zum Hotel zu Fu.", - "countryHint": "US"}, {"id": "4", "text": "", "countryHint": "US"}]}' - headers: - Accept: - - application/json - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '400' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"documents":[{"id":"0","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"1","detectedLanguages":[{"name":"Spanish","iso6391Name":"es","score":1.0}]},{"id":"2","detectedLanguages":[{"name":"Japanese","iso6391Name":"ja","score":1.0}]},{"id":"3","detectedLanguages":[{"name":"German","iso6391Name":"de","score":1.0}]}],"errors":[{"id":"4","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document - text is empty."}}}],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: - - 2f16ff95-5e09-4348-a19c-177499e8ff7d - content-type: - - application/json; charset=utf-8 - csp-billing-usage: - - CognitiveServices.TextAnalytics.BatchScoring=4 - date: - - Thu, 02 Apr 2020 15:06:33 GMT - strict-transport-security: - - max-age=31536000; includeSubDomains; preload - transfer-encoding: - - chunked - x-content-type-options: - - nosniff - x-envoy-upstream-service-time: - - '4' - status: - code: 200 - message: OK -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_per_item_dont_use_country_hint.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_per_item_dont_use_country_hint.yaml deleted file mode 100644 index 26b797009a7f..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_per_item_dont_use_country_hint.yaml +++ /dev/null @@ -1,46 +0,0 @@ -interactions: -- request: - body: '{"documents": [{"id": "1", "text": "I will go to the park.", "countryHint": - ""}, {"id": "2", "text": "I did not like the hotel we stayed at.", "countryHint": - ""}, {"id": "3", "text": "The restaurant had really good food.", "countryHint": - "US"}]}' - headers: - Accept: - - application/json - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '245' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"documents":[{"id":"1","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"2","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"3","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]}],"errors":[],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: - - 7a2adda0-d30a-4db2-a4ed-6e8587ee2fcf - content-type: - - application/json; charset=utf-8 - csp-billing-usage: - - CognitiveServices.TextAnalytics.BatchScoring=3 - date: - - Thu, 02 Apr 2020 15:06:33 GMT - strict-transport-security: - - max-age=31536000; includeSubDomains; preload - transfer-encoding: - - chunked - x-content-type-options: - - nosniff - x-envoy-upstream-service-time: - - '4' - status: - code: 200 - message: OK -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_rotate_subscription_key.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_rotate_subscription_key.yaml deleted file mode 100644 index 91c31ce32d88..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_rotate_subscription_key.yaml +++ /dev/null @@ -1,124 +0,0 @@ -interactions: -- request: - body: '{"documents": [{"id": "1", "text": "I will go to the park.", "countryHint": - "US"}, {"id": "2", "text": "I did not like the hotel we stayed at.", "countryHint": - "US"}, {"id": "3", "text": "The restaurant had really good food.", "countryHint": - "US"}]}' - headers: - Accept: - - application/json - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '249' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"documents":[{"id":"1","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"2","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"3","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]}],"errors":[],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: - - 6e95855e-5c54-4c57-b4a3-d5c3e1a2445c - content-type: - - application/json; charset=utf-8 - csp-billing-usage: - - CognitiveServices.TextAnalytics.BatchScoring=3 - date: - - Thu, 02 Apr 2020 15:06:34 GMT - strict-transport-security: - - max-age=31536000; includeSubDomains; preload - transfer-encoding: - - chunked - x-content-type-options: - - nosniff - x-envoy-upstream-service-time: - - '3' - status: - code: 200 - message: OK -- request: - body: '{"documents": [{"id": "1", "text": "I will go to the park.", "countryHint": - "US"}, {"id": "2", "text": "I did not like the hotel we stayed at.", "countryHint": - "US"}, {"id": "3", "text": "The restaurant had really good food.", "countryHint": - "US"}]}' - headers: - Accept: - - application/json - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '249' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"error":{"code":"401","message":"Access denied due to invalid subscription - key or wrong API endpoint. Make sure to provide a valid key for an active - subscription and use a correct regional API endpoint for your resource."}}' - headers: - content-length: - - '224' - date: - - Thu, 02 Apr 2020 15:06:34 GMT - status: - code: 401 - message: PermissionDenied -- request: - body: '{"documents": [{"id": "1", "text": "I will go to the park.", "countryHint": - "US"}, {"id": "2", "text": "I did not like the hotel we stayed at.", "countryHint": - "US"}, {"id": "3", "text": "The restaurant had really good food.", "countryHint": - "US"}]}' - headers: - Accept: - - application/json - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '249' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"documents":[{"id":"1","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"2","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"3","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]}],"errors":[],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: - - 07f897aa-3fa5-49b0-930f-1708fbd617f1 - content-type: - - application/json; charset=utf-8 - csp-billing-usage: - - CognitiveServices.TextAnalytics.BatchScoring=3 - date: - - Thu, 02 Apr 2020 15:06:34 GMT - strict-transport-security: - - max-age=31536000; includeSubDomains; preload - transfer-encoding: - - chunked - x-content-type-options: - - nosniff - x-envoy-upstream-service-time: - - '3' - status: - code: 200 - message: OK -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_show_stats_and_model_version.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_show_stats_and_model_version.yaml deleted file mode 100644 index d28f268543c3..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_show_stats_and_model_version.yaml +++ /dev/null @@ -1,48 +0,0 @@ -interactions: -- request: - body: '{"documents": [{"id": "56", "text": ":)", "countryHint": "US"}, {"id": - "0", "text": ":(", "countryHint": "US"}, {"id": "22", "text": "", "countryHint": - "US"}, {"id": "19", "text": ":P", "countryHint": "US"}, {"id": "1", "text": - ":D", "countryHint": "US"}]}' - headers: - Accept: - - application/json - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '256' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?model-version=latest&showStats=true - response: - body: - string: '{"statistics":{"documentsCount":5,"validDocumentsCount":4,"erroneousDocumentsCount":1,"transactionsCount":4},"documents":[{"id":"56","detectedLanguages":[{"name":"(Unknown)","iso6391Name":"(Unknown)","score":0.0}],"statistics":{"charactersCount":2,"transactionsCount":1}},{"id":"0","detectedLanguages":[{"name":"(Unknown)","iso6391Name":"(Unknown)","score":0.0}],"statistics":{"charactersCount":2,"transactionsCount":1}},{"id":"19","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}],"statistics":{"charactersCount":2,"transactionsCount":1}},{"id":"1","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}],"statistics":{"charactersCount":2,"transactionsCount":1}}],"errors":[{"id":"22","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document - text is empty."}}}],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: - - d1abc569-556b-4c71-917e-5ee1b0e5f51c - content-type: - - application/json; charset=utf-8 - csp-billing-usage: - - CognitiveServices.TextAnalytics.BatchScoring=4 - date: - - Thu, 02 Apr 2020 15:06:34 GMT - strict-transport-security: - - max-age=31536000; includeSubDomains; preload - transfer-encoding: - - chunked - x-content-type-options: - - nosniff - x-envoy-upstream-service-time: - - '4' - status: - code: 200 - message: OK -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_user_agent.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_user_agent.yaml deleted file mode 100644 index 6002c881243a..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_user_agent.yaml +++ /dev/null @@ -1,46 +0,0 @@ -interactions: -- request: - body: '{"documents": [{"id": "1", "text": "I will go to the park.", "countryHint": - "US"}, {"id": "2", "text": "I did not like the hotel we stayed at.", "countryHint": - "US"}, {"id": "3", "text": "The restaurant had really good food.", "countryHint": - "US"}]}' - headers: - Accept: - - application/json - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '249' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"documents":[{"id":"1","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"2","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"3","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]}],"errors":[],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: - - fb28ec86-c7bd-4738-b447-3774d6bf42da - content-type: - - application/json; charset=utf-8 - csp-billing-usage: - - CognitiveServices.TextAnalytics.BatchScoring=3 - date: - - Thu, 02 Apr 2020 15:06:35 GMT - strict-transport-security: - - max-age=31536000; includeSubDomains; preload - transfer-encoding: - - chunked - x-content-type-options: - - nosniff - x-envoy-upstream-service-time: - - '4' - status: - code: 200 - message: OK -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_whole_batch_country_hint.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_whole_batch_country_hint.yaml deleted file mode 100644 index e80d6611a264..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_whole_batch_country_hint.yaml +++ /dev/null @@ -1,46 +0,0 @@ -interactions: -- request: - body: '{"documents": [{"id": "0", "text": "This was the best day of my life.", - "countryHint": "CA"}, {"id": "1", "text": "I did not like the hotel we stayed - at. It was too expensive.", "countryHint": "CA"}, {"id": "2", "text": "The restaurant - was not as good as I hoped.", "countryHint": "CA"}]}' - headers: - Accept: - - application/json - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '288' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"documents":[{"id":"0","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"1","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"2","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]}],"errors":[],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: - - 165eb625-c58c-4194-8f72-4288d27991ce - content-type: - - application/json; charset=utf-8 - csp-billing-usage: - - CognitiveServices.TextAnalytics.BatchScoring=3 - date: - - Thu, 02 Apr 2020 15:06:35 GMT - strict-transport-security: - - max-age=31536000; includeSubDomains; preload - transfer-encoding: - - chunked - x-content-type-options: - - nosniff - x-envoy-upstream-service-time: - - '213' - status: - code: 200 - message: OK -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_whole_batch_country_hint_and_dict_input.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_whole_batch_country_hint_and_dict_input.yaml deleted file mode 100644 index 88a49d7040fb..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_whole_batch_country_hint_and_dict_input.yaml +++ /dev/null @@ -1,46 +0,0 @@ -interactions: -- request: - body: '{"documents": [{"id": "1", "text": "I will go to the park.", "countryHint": - "CA"}, {"id": "2", "text": "I did not like the hotel we stayed at.", "countryHint": - "CA"}, {"id": "3", "text": "The restaurant had really good food.", "countryHint": - "CA"}]}' - headers: - Accept: - - application/json - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '249' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"documents":[{"id":"1","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"2","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"3","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]}],"errors":[],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: - - f280ec54-e13b-4d99-9a84-dc5db56955e8 - content-type: - - application/json; charset=utf-8 - csp-billing-usage: - - CognitiveServices.TextAnalytics.BatchScoring=3 - date: - - Thu, 02 Apr 2020 15:06:35 GMT - strict-transport-security: - - max-age=31536000; includeSubDomains; preload - transfer-encoding: - - chunked - x-content-type-options: - - nosniff - x-envoy-upstream-service-time: - - '3' - status: - code: 200 - message: OK -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_whole_batch_country_hint_and_dict_per_item_hints.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_whole_batch_country_hint_and_dict_per_item_hints.yaml deleted file mode 100644 index 9caaf402ccfb..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_whole_batch_country_hint_and_dict_per_item_hints.yaml +++ /dev/null @@ -1,46 +0,0 @@ -interactions: -- request: - body: '{"documents": [{"id": "1", "text": "I will go to the park.", "countryHint": - "US"}, {"id": "2", "text": "I did not like the hotel we stayed at.", "countryHint": - "US"}, {"id": "3", "text": "The restaurant had really good food.", "countryHint": - "CA"}]}' - headers: - Accept: - - application/json - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '249' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"documents":[{"id":"1","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"2","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"3","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]}],"errors":[],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: - - 98983815-067b-4d80-9c33-f84d90611920 - content-type: - - application/json; charset=utf-8 - csp-billing-usage: - - CognitiveServices.TextAnalytics.BatchScoring=3 - date: - - Thu, 02 Apr 2020 15:06:36 GMT - strict-transport-security: - - max-age=31536000; includeSubDomains; preload - transfer-encoding: - - chunked - x-content-type-options: - - nosniff - x-envoy-upstream-service-time: - - '3' - status: - code: 200 - message: OK -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_whole_batch_country_hint_and_obj_input.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_whole_batch_country_hint_and_obj_input.yaml deleted file mode 100644 index a44091017c05..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_whole_batch_country_hint_and_obj_input.yaml +++ /dev/null @@ -1,46 +0,0 @@ -interactions: -- request: - body: '{"documents": [{"id": "1", "text": "I should take my cat to the veterinarian.", - "countryHint": "CA"}, {"id": "2", "text": "Este es un document escrito en Espa\u00f1ol.", - "countryHint": "CA"}, {"id": "3", "text": "\u732b\u306f\u5e78\u305b", "countryHint": - "CA"}]}' - headers: - Accept: - - application/json - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '262' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"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":"Japanese","iso6391Name":"ja","score":1.0}]}],"errors":[],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: - - ac1162fa-2a27-4c88-bab1-826c3f1bf47d - content-type: - - application/json; charset=utf-8 - csp-billing-usage: - - CognitiveServices.TextAnalytics.BatchScoring=3 - date: - - Thu, 02 Apr 2020 15:06:36 GMT - strict-transport-security: - - max-age=31536000; includeSubDomains; preload - transfer-encoding: - - chunked - x-content-type-options: - - nosniff - x-envoy-upstream-service-time: - - '3' - status: - code: 200 - message: OK -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_whole_batch_country_hint_and_obj_per_item_hints.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_whole_batch_country_hint_and_obj_per_item_hints.yaml deleted file mode 100644 index c201e71927f7..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_whole_batch_country_hint_and_obj_per_item_hints.yaml +++ /dev/null @@ -1,46 +0,0 @@ -interactions: -- request: - body: '{"documents": [{"id": "1", "text": "I should take my cat to the veterinarian.", - "countryHint": "CA"}, {"id": "4", "text": "Este es un document escrito en Espa\u00f1ol.", - "countryHint": "CA"}, {"id": "3", "text": "\u732b\u306f\u5e78\u305b", "countryHint": - "US"}]}' - headers: - Accept: - - application/json - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '262' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"documents":[{"id":"1","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"4","detectedLanguages":[{"name":"Spanish","iso6391Name":"es","score":1.0}]},{"id":"3","detectedLanguages":[{"name":"Japanese","iso6391Name":"ja","score":1.0}]}],"errors":[],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: - - 736bd1ac-7db4-4a3a-ab62-b9886eb90c6c - content-type: - - application/json; charset=utf-8 - csp-billing-usage: - - CognitiveServices.TextAnalytics.BatchScoring=3 - date: - - Thu, 02 Apr 2020 15:06:36 GMT - strict-transport-security: - - max-age=31536000; includeSubDomains; preload - transfer-encoding: - - chunked - x-content-type-options: - - nosniff - x-envoy-upstream-service-time: - - '3' - status: - code: 200 - message: OK -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_whole_batch_dont_use_country_hint.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_whole_batch_dont_use_country_hint.yaml deleted file mode 100644 index ea5936e5692b..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language.test_whole_batch_dont_use_country_hint.yaml +++ /dev/null @@ -1,46 +0,0 @@ -interactions: -- request: - body: '{"documents": [{"id": "0", "text": "This was the best day of my life.", - "countryHint": ""}, {"id": "1", "text": "I did not like the hotel we stayed - at. It was too expensive.", "countryHint": ""}, {"id": "2", "text": "The restaurant - was not as good as I hoped.", "countryHint": ""}]}' - headers: - Accept: - - application/json - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '282' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"documents":[{"id":"0","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"1","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"2","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]}],"errors":[],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: - - 05430281-9588-4edf-98ae-ca8690e7161d - content-type: - - application/json; charset=utf-8 - csp-billing-usage: - - CognitiveServices.TextAnalytics.BatchScoring=3 - date: - - Thu, 02 Apr 2020 15:06:37 GMT - strict-transport-security: - - max-age=31536000; includeSubDomains; preload - transfer-encoding: - - chunked - x-content-type-options: - - nosniff - x-envoy-upstream-service-time: - - '3' - status: - code: 200 - message: OK -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_all_successful_passing_dict.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_all_successful_passing_dict.yaml index 10031e11973f..3449236b13a7 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_all_successful_passing_dict.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_all_successful_passing_dict.yaml @@ -15,24 +15,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=true + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=true response: body: string: '{"statistics":{"documentsCount":2,"validDocumentsCount":2,"erroneousDocumentsCount":0,"transactionsCount":2},"documents":[{"id":"1","keyPhrases":["Bill - Gates","Paul Allen","Microsoft"],"statistics":{"charactersCount":50,"transactionsCount":1}},{"id":"2","keyPhrases":["Bill - Gates","Paul Allen","Microsoft"],"statistics":{"charactersCount":49,"transactionsCount":1}}],"errors":[],"modelVersion":"2019-10-01"}' + Gates","Paul Allen","Microsoft"],"statistics":{"charactersCount":50,"transactionsCount":1},"warnings":[]},{"id":"2","keyPhrases":["Bill + Gates","Paul Allen","Microsoft"],"statistics":{"charactersCount":49,"transactionsCount":1},"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - e692a9e5-5f28-4b0c-8992-502889244e5f + - 9d030614-6d2e-4aa6-b08c-46bf04b88044 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=2 date: - - Thu, 02 Apr 2020 15:06:51 GMT + - Thu, 23 Apr 2020 15:16:57 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -40,7 +40,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '6' + - '18' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_all_successful_passing_text_document_input.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_all_successful_passing_text_document_input.yaml index bd8243b1d9a3..fa415ab19cd9 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_all_successful_passing_text_document_input.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_all_successful_passing_text_document_input.yaml @@ -15,23 +15,23 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: - string: '{"documents":[{"id":"1","keyPhrases":["Bill Gates","Paul Allen","Microsoft"]},{"id":"2","keyPhrases":["Bill - Gates","Paul Allen","Microsoft"]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"1","keyPhrases":["Bill Gates","Paul Allen","Microsoft"],"warnings":[]},{"id":"2","keyPhrases":["Bill + Gates","Paul Allen","Microsoft"],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - 9872192a-85c4-4a65-b9e6-c397defc3f59 + - 8e9a607c-934e-49fa-8775-e7386bf00ea6 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=2 date: - - Thu, 02 Apr 2020 15:06:51 GMT + - Thu, 23 Apr 2020 15:16:58 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -39,7 +39,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '7' + - '8' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_bad_credentials.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_bad_credentials.yaml index fe516f39b61c..78e81129fa74 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_bad_credentials.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_bad_credentials.yaml @@ -14,21 +14,31 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: - string: '{"error":{"code":"401","message":"Access denied due to invalid subscription + string: '{"error":{"code":"401","message": "Access denied due to invalid subscription key or wrong API endpoint. Make sure to provide a valid key for an active subscription and use a correct regional API endpoint for your resource."}}' headers: + apim-request-id: + - 744eed49-160a-439c-a712-1264cdf3f2b8 content-length: - - '224' + - '225' + content-type: + - application/json date: - - Thu, 02 Apr 2020 15:06:52 GMT + - Thu, 23 Apr 2020 15:16:58 GMT + strict-transport-security: + - max-age=31536000; includeSubDomains; preload + www-authenticate: + - AzureApiManagementKey realm="https://westus2.ppe.cognitiveservices.azure.com/text/analytics",name="Ocp-Apim-Subscription-Key",type="header" + x-content-type-options: + - nosniff status: code: 401 - message: PermissionDenied + message: Access Denied version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_bad_model_version.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_bad_model_version.yaml index ec02a172bf0c..7f10a07c3ab3 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_bad_model_version.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_bad_model_version.yaml @@ -14,21 +14,21 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?model-version=old&showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?model-version=old&showStats=false response: body: string: '{"error":{"code":"InvalidRequest","message":"Specified Model version is incorrect. Allowed values are latest,2019-10-01"}}' headers: apim-request-id: - - 5c587b66-bbf4-4870-8d5c-d143c94cec7a + - 6bbbaac4-c167-4c8a-9779-68ea422e9fb8 content-type: - application/json; charset=utf-8 date: - - Thu, 02 Apr 2020 15:06:53 GMT + - Thu, 23 Apr 2020 15:16:58 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -36,7 +36,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '4' + - '130' status: code: 400 message: Bad Request diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_bad_model_version_error.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_bad_model_version_error.yaml index 1682197f6e95..00d47ab76efd 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_bad_model_version_error.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_bad_model_version_error.yaml @@ -14,21 +14,21 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?model-version=bad&showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?model-version=bad&showStats=false response: body: string: '{"error":{"code":"InvalidRequest","message":"Specified Model version is incorrect. Allowed values are latest,2019-10-01"}}' headers: apim-request-id: - - 13981811-65ec-4c4c-9ba5-844df527a2e6 + - 0f4af2d5-342a-4dca-ba76-449389e52ea4 content-type: - application/json; charset=utf-8 date: - - Thu, 02 Apr 2020 15:06:53 GMT + - Thu, 23 Apr 2020 15:16:58 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -36,7 +36,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '4' + - '9' status: code: 400 message: Bad Request diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_batch_size_over_limit.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_batch_size_over_limit.yaml index 0ef0daec5bd1..ef311cb5c2e7 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_batch_size_over_limit.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_batch_size_over_limit.yaml @@ -758,21 +758,21 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: - string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innerError":{"code":"InvalidDocumentBatch","message":"Batch + string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innererror":{"code":"InvalidDocumentBatch","message":"Batch request contains too many records. Max 1000 records are permitted."}}}' headers: apim-request-id: - - b68508a3-4099-42a5-b8dc-e710b826ac0e + - 1c543022-bba2-4348-be46-dc4418b2f17a content-type: - application/json; charset=utf-8 date: - - Thu, 02 Apr 2020 15:06:55 GMT + - Thu, 23 Apr 2020 15:17:00 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -780,7 +780,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '856' + - '163' status: code: 400 message: Bad Request diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_batch_size_over_limit_error.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_batch_size_over_limit_error.yaml index 96667ae180b8..5892d258576a 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_batch_size_over_limit_error.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_batch_size_over_limit_error.yaml @@ -723,21 +723,21 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: - string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innerError":{"code":"InvalidDocumentBatch","message":"Batch + string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innererror":{"code":"InvalidDocumentBatch","message":"Batch request contains too many records. Max 1000 records are permitted."}}}' headers: apim-request-id: - - f39ce077-fbbb-45c9-b57c-d8d070ba2ce7 + - 188acd8b-aa94-4114-aedb-c4ec2dd5614f content-type: - application/json; charset=utf-8 date: - - Thu, 02 Apr 2020 15:06:56 GMT + - Thu, 23 Apr 2020 15:17:00 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -745,7 +745,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '22' + - '34' status: code: 400 message: Bad Request diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_client_passed_default_language_hint.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_client_passed_default_language_hint.yaml index 2ca6baf12ab0..3940976ea3d2 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_client_passed_default_language_hint.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_client_passed_default_language_hint.yaml @@ -16,24 +16,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: - string: '{"documents":[{"id":"1","keyPhrases":["the park","I will go"]},{"id":"2","keyPhrases":["I - did not like the hotel we stayed at"]},{"id":"3","keyPhrases":["The restaurant - had really good food"]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"1","keyPhrases":["the park","I will go"],"warnings":[]},{"id":"2","keyPhrases":["I + did not like the hotel we stayed at"],"warnings":[]},{"id":"3","keyPhrases":["The + restaurant had really good food"],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - 604f4cd6-614f-44f7-a211-b0d28aa70355 + - c59586da-3199-490e-8478-44147e11cb07 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:06:57 GMT + - Thu, 23 Apr 2020 15:17:02 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -41,7 +41,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '6' + - '7' status: code: 200 message: OK @@ -62,23 +62,23 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: - string: '{"documents":[{"id":"1","keyPhrases":["park"]},{"id":"2","keyPhrases":["hotel"]},{"id":"3","keyPhrases":["restaurant","good - food"]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"1","keyPhrases":["park"],"warnings":[]},{"id":"2","keyPhrases":["hotel"],"warnings":[]},{"id":"3","keyPhrases":["restaurant","good + food"],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - e74e38cb-7553-405b-b65c-ff81bffd3169 + - e056bd10-a45f-47db-9a88-e90e2235fd86 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:06:57 GMT + - Thu, 23 Apr 2020 15:17:02 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -86,7 +86,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '5' + - '14' status: code: 200 message: OK @@ -107,24 +107,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: - string: '{"documents":[{"id":"1","keyPhrases":["the park","I will go"]},{"id":"2","keyPhrases":["I - did not like the hotel we stayed at"]},{"id":"3","keyPhrases":["The restaurant - had really good food"]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"1","keyPhrases":["the park","I will go"],"warnings":[]},{"id":"2","keyPhrases":["I + did not like the hotel we stayed at"],"warnings":[]},{"id":"3","keyPhrases":["The + restaurant had really good food"],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - 4b797807-fae4-4d62-827c-cf4b3dbfb6bc + - eea05b25-b558-476f-98df-cfb1efdbebf5 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:06:57 GMT + - Thu, 23 Apr 2020 15:17:02 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -132,7 +132,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '6' + - '7' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_document_attribute_error_no_result_attribute.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_document_attribute_error_no_result_attribute.yaml index 3f5ba9d40974..54d96058ac7e 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_document_attribute_error_no_result_attribute.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_document_attribute_error_no_result_attribute.yaml @@ -13,24 +13,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: string: '{"documents":[],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}}],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - 45c1e4a7-344c-49ba-a163-cf8422c0cfbe + - d9a81478-b2ec-4ff3-b4ee-5fb7e66d4c47 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=0 date: - - Thu, 02 Apr 2020 15:06:57 GMT + - Thu, 23 Apr 2020 15:17:02 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -38,7 +38,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '3' + - '6' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_document_attribute_error_nonexistent_attribute.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_document_attribute_error_nonexistent_attribute.yaml index 006601710545..3e227f2d358f 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_document_attribute_error_nonexistent_attribute.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_document_attribute_error_nonexistent_attribute.yaml @@ -13,24 +13,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: string: '{"documents":[],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}}],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - adfc2ed6-5e3e-48a1-9d15-12fae487d3b2 + - 069e8ef2-b42f-49aa-bce9-e9a4d31e1474 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=0 date: - - Thu, 02 Apr 2020 15:06:57 GMT + - Thu, 23 Apr 2020 15:17:03 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_document_errors.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_document_errors.yaml index 481cdd6ad670..58a1abbf55e3 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_document_errors.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_document_errors.yaml @@ -16,30 +16,30 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: string: '{"documents":[],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}},{"id":"2","error":{"code":"InvalidArgument","message":"Invalid - Language Code.","innerError":{"code":"UnsupportedLanguageCode","message":"Supplied + Language Code.","innererror":{"code":"UnsupportedLanguageCode","message":"Supplied language not supported. Pass in one of: da,de,en,es,fi,fr,it,ja,ko,nl,no,pl,pt-BR,pt-PT,ru,sv"}}},{"id":"3","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"A + document in request.","innererror":{"code":"InvalidDocument","message":"A document within the request was too large to be processed. Limit document size to: 5120 text elements. For additional details on the data limitations see https://aka.ms/text-analytics-data-limits"}}}],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - fb70ae72-79a3-410c-9e60-1f13d21c62b0 + - 56edd2e8-b903-4451-a434-e55640e4e468 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=0 date: - - Thu, 02 Apr 2020 15:06:58 GMT + - Thu, 23 Apr 2020 15:17:02 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -47,7 +47,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '3' + - '14' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_duplicate_ids_error.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_duplicate_ids_error.yaml index d7bc84136d78..016053f3ee13 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_duplicate_ids_error.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_duplicate_ids_error.yaml @@ -14,21 +14,21 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: - string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innerError":{"code":"InvalidDocument","message":"Request + string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innererror":{"code":"InvalidDocument","message":"Request contains duplicated Ids. Make sure each document has a unique Id."}}}' headers: apim-request-id: - - 1f90d27f-2684-4014-bd9a-305f97b5d5c2 + - 87fb01dc-3737-4258-8890-e6faedde348a content-type: - application/json; charset=utf-8 date: - - Thu, 02 Apr 2020 15:06:58 GMT + - Thu, 23 Apr 2020 15:17:03 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_empty_credential_class.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_empty_credential_class.yaml index 87627aa28171..f6b260fd7044 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_empty_credential_class.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_empty_credential_class.yaml @@ -14,21 +14,31 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: - string: '{"error":{"code":"401","message":"Access denied due to invalid subscription + string: '{"error":{"code":"401","message": "Access denied due to invalid subscription key or wrong API endpoint. Make sure to provide a valid key for an active subscription and use a correct regional API endpoint for your resource."}}' headers: + apim-request-id: + - 5b16c4df-db3d-4663-87cd-9d0e22db0481 content-length: - - '224' + - '225' + content-type: + - application/json date: - - Thu, 02 Apr 2020 15:06:59 GMT + - Thu, 23 Apr 2020 15:17:04 GMT + strict-transport-security: + - max-age=31536000; includeSubDomains; preload + www-authenticate: + - AzureApiManagementKey realm="https://westus2.ppe.cognitiveservices.azure.com/text/analytics",name="Ocp-Apim-Subscription-Key",type="header" + x-content-type-options: + - nosniff status: code: 401 - message: PermissionDenied + message: Access Denied version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_input_with_all_errors.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_input_with_all_errors.yaml index dd37322e8521..3570c2de1e56 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_input_with_all_errors.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_input_with_all_errors.yaml @@ -15,26 +15,26 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: string: '{"documents":[],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - Language Code.","innerError":{"code":"UnsupportedLanguageCode","message":"Supplied + Language Code.","innererror":{"code":"UnsupportedLanguageCode","message":"Supplied language not supported. Pass in one of: da,de,en,es,fi,fr,it,ja,ko,nl,no,pl,pt-BR,pt-PT,ru,sv"}}},{"id":"2","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}}],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - 0a08f1d6-588d-4112-af7a-81d93ae91b1c + - d876f08c-652f-4a10-8465-2ba47a19e863 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=0 date: - - Thu, 02 Apr 2020 15:06:59 GMT + - Thu, 23 Apr 2020 15:17:04 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -42,7 +42,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '3' + - '10' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_input_with_some_errors.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_input_with_some_errors.yaml index 6aca30645c47..6dcad70bffbb 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_input_with_some_errors.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_input_with_some_errors.yaml @@ -15,24 +15,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: - string: '{"documents":[{"id":"2","keyPhrases":["Bill Gates","Paul Allen","Microsoft"]}],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - Language Code.","innerError":{"code":"UnsupportedLanguageCode","message":"Supplied + string: '{"documents":[{"id":"2","keyPhrases":["Bill Gates","Paul Allen","Microsoft"],"warnings":[]}],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid + Language Code.","innererror":{"code":"UnsupportedLanguageCode","message":"Supplied language not supported. Pass in one of: da,de,en,es,fi,fr,it,ja,ko,nl,no,pl,pt-BR,pt-PT,ru,sv"}}}],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - 278ef602-2385-47e3-8743-4b36d8902492 + - 9199ff43-5e2b-483e-b892-fbbfbb03d7ce content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=1 date: - - Thu, 02 Apr 2020 15:06:59 GMT + - Thu, 23 Apr 2020 15:17:04 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_language_kwarg_spanish.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_language_kwarg_spanish.yaml index 952ad9bd8552..962029e20cb8 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_language_kwarg_spanish.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_language_kwarg_spanish.yaml @@ -14,23 +14,23 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?model-version=latest&showStats=true + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?model-version=latest&showStats=true response: body: string: '{"statistics":{"documentsCount":1,"validDocumentsCount":1,"erroneousDocumentsCount":0,"transactionsCount":1},"documents":[{"id":"0","keyPhrases":["Bill - Gates","the CEO of Microsoft"],"statistics":{"charactersCount":35,"transactionsCount":1}}],"errors":[],"modelVersion":"2019-10-01"}' + Gates","the CEO of Microsoft"],"statistics":{"charactersCount":35,"transactionsCount":1},"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - a8f2683c-74e2-4b35-9868-c7e838188b5e + - 2c64201c-0c45-4550-8dad-a74f71c029c5 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=1 date: - - Thu, 02 Apr 2020 15:07:00 GMT + - Thu, 23 Apr 2020 15:17:05 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -38,7 +38,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '21' + - '5' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_missing_input_records_error.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_missing_input_records_error.yaml deleted file mode 100644 index 59859a4fd8dc..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_missing_input_records_error.yaml +++ /dev/null @@ -1,42 +0,0 @@ -interactions: -- request: - body: '{"documents": []}' - headers: - Accept: - - application/json - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '17' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false - response: - body: - string: '{"error":{"code":"InvalidRequest","message":"Invalid Request.","innerError":{"code":"MissingInputRecords","message":"Missing - input records."}}}' - headers: - apim-request-id: - - 5ecb4b7a-1c3a-474d-a2b6-8e0efe704453 - content-type: - - application/json; charset=utf-8 - date: - - Thu, 02 Apr 2020 15:07:00 GMT - strict-transport-security: - - max-age=31536000; includeSubDomains; preload - transfer-encoding: - - chunked - x-content-type-options: - - nosniff - x-envoy-upstream-service-time: - - '4' - status: - code: 400 - message: Bad Request -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_out_of_order_ids.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_out_of_order_ids.yaml index d3376740f216..e0e6d7a304d9 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_out_of_order_ids.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_out_of_order_ids.yaml @@ -16,24 +16,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: - string: '{"documents":[{"id":"56","keyPhrases":[]},{"id":"0","keyPhrases":[]},{"id":"19","keyPhrases":[]},{"id":"1","keyPhrases":[]}],"errors":[{"id":"22","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + string: '{"documents":[{"id":"56","keyPhrases":[],"warnings":[]},{"id":"0","keyPhrases":[],"warnings":[]},{"id":"19","keyPhrases":[],"warnings":[]},{"id":"1","keyPhrases":[],"warnings":[]}],"errors":[{"id":"22","error":{"code":"InvalidArgument","message":"Invalid + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}}],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - 0ebd394a-4c3b-4d2d-b6c1-fd4069765d55 + - 31e87e2b-9122-40b9-9ede-479ae8ba687c content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=4 date: - - Thu, 02 Apr 2020 15:07:01 GMT + - Thu, 23 Apr 2020 15:17:05 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -41,7 +41,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '4' + - '8' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_pass_cls.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_pass_cls.yaml index 8c817d49b0ca..c616fdfeeda2 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_pass_cls.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_pass_cls.yaml @@ -14,22 +14,22 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: - string: '{"documents":[{"id":"0","keyPhrases":["Test","cls","endpoint"]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"0","keyPhrases":["Test","cls","endpoint"],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - 9b724afc-e085-49cd-9086-c4486aa46c26 + - 7ac0da3e-5801-4c12-862a-a0603bcae696 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=1 date: - - Thu, 02 Apr 2020 15:07:01 GMT + - Thu, 23 Apr 2020 15:17:05 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_passing_only_string.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_passing_only_string.yaml index 3bbf6f8d2d8a..2c9e89e03b8e 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_passing_only_string.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_passing_only_string.yaml @@ -16,25 +16,25 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: - string: '{"documents":[{"id":"0","keyPhrases":["Bill Gates","Paul Allen","Microsoft"]},{"id":"1","keyPhrases":["Microsoft - fue fundado por Bill Gates y Paul Allen"]}],"errors":[{"id":"2","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + string: '{"documents":[{"id":"0","keyPhrases":["Bill Gates","Paul Allen","Microsoft"],"warnings":[]},{"id":"1","keyPhrases":["Microsoft + fue fundado por Bill Gates y Paul Allen"],"warnings":[]}],"errors":[{"id":"2","error":{"code":"InvalidArgument","message":"Invalid + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}}],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - c011c751-7333-4f8c-9341-3213aef22e38 + - 7c9a71c2-3341-4db9-86a0-b5350445d219 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=2 date: - - Thu, 02 Apr 2020 15:07:01 GMT + - Thu, 23 Apr 2020 15:17:05 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -42,7 +42,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '8' + - '5' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_per_item_dont_use_language_hint.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_per_item_dont_use_language_hint.yaml index fb7ba4ce6096..3a07eca929d3 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_per_item_dont_use_language_hint.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_per_item_dont_use_language_hint.yaml @@ -16,23 +16,23 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: - string: '{"documents":[{"id":"1","keyPhrases":["park"]},{"id":"2","keyPhrases":["hotel"]},{"id":"3","keyPhrases":["restaurant","good - food"]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"1","keyPhrases":["park"],"warnings":[]},{"id":"2","keyPhrases":["hotel"],"warnings":[]},{"id":"3","keyPhrases":["restaurant","good + food"],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - 793fb42b-b279-4145-b855-ee1828a41b3a + - 0de93608-6c56-4a5f-a1be-245069654655 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:07:01 GMT + - Thu, 23 Apr 2020 15:17:06 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -40,7 +40,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '6' + - '4' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_rotate_subscription_key.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_rotate_subscription_key.yaml index 8bc2ec97b811..930176a12d5d 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_rotate_subscription_key.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_rotate_subscription_key.yaml @@ -16,23 +16,23 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: - string: '{"documents":[{"id":"1","keyPhrases":["park"]},{"id":"2","keyPhrases":["hotel"]},{"id":"3","keyPhrases":["restaurant","good - food"]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"1","keyPhrases":["park"],"warnings":[]},{"id":"2","keyPhrases":["hotel"],"warnings":[]},{"id":"3","keyPhrases":["restaurant","good + food"],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - c18071d1-fd6e-48cb-b6f1-a07e52304eca + - 92001602-3ab7-4934-9548-606c388de447 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:07:02 GMT + - Thu, 23 Apr 2020 15:17:07 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -40,7 +40,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '7' + - '9' status: code: 200 message: OK @@ -61,23 +61,33 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: - string: '{"error":{"code":"401","message":"Access denied due to invalid subscription + string: '{"error":{"code":"401","message": "Access denied due to invalid subscription key or wrong API endpoint. Make sure to provide a valid key for an active subscription and use a correct regional API endpoint for your resource."}}' headers: + apim-request-id: + - 7bd54716-e5f0-4d16-92f5-749075e37595 content-length: - - '224' + - '225' + content-type: + - application/json date: - - Thu, 02 Apr 2020 15:07:02 GMT + - Thu, 23 Apr 2020 15:17:07 GMT + strict-transport-security: + - max-age=31536000; includeSubDomains; preload + www-authenticate: + - AzureApiManagementKey realm="https://westus2.ppe.cognitiveservices.azure.com/text/analytics",name="Ocp-Apim-Subscription-Key",type="header" + x-content-type-options: + - nosniff status: code: 401 - message: PermissionDenied + message: Access Denied - request: body: '{"documents": [{"id": "1", "text": "I will go to the park.", "language": "en"}, {"id": "2", "text": "I did not like the hotel we stayed at.", "language": @@ -95,23 +105,23 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: - string: '{"documents":[{"id":"1","keyPhrases":["park"]},{"id":"2","keyPhrases":["hotel"]},{"id":"3","keyPhrases":["restaurant","good - food"]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"1","keyPhrases":["park"],"warnings":[]},{"id":"2","keyPhrases":["hotel"],"warnings":[]},{"id":"3","keyPhrases":["restaurant","good + food"],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - 60383c89-401d-444b-ae05-100252f48caf + - 3a12d8b2-7c66-4e92-9302-62c2d5650200 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:07:02 GMT + - Thu, 23 Apr 2020 15:17:07 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -119,7 +129,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '6' + - '5' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_show_stats_and_model_version.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_show_stats_and_model_version.yaml index a4150b9ed2db..fe9df95a0c6a 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_show_stats_and_model_version.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_show_stats_and_model_version.yaml @@ -16,24 +16,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?model-version=latest&showStats=true + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?model-version=latest&showStats=true response: body: - string: '{"statistics":{"documentsCount":5,"validDocumentsCount":4,"erroneousDocumentsCount":1,"transactionsCount":4},"documents":[{"id":"56","keyPhrases":[],"statistics":{"charactersCount":2,"transactionsCount":1}},{"id":"0","keyPhrases":[],"statistics":{"charactersCount":2,"transactionsCount":1}},{"id":"19","keyPhrases":[],"statistics":{"charactersCount":2,"transactionsCount":1}},{"id":"1","keyPhrases":[],"statistics":{"charactersCount":2,"transactionsCount":1}}],"errors":[{"id":"22","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + string: '{"statistics":{"documentsCount":5,"validDocumentsCount":4,"erroneousDocumentsCount":1,"transactionsCount":4},"documents":[{"id":"56","keyPhrases":[],"statistics":{"charactersCount":2,"transactionsCount":1},"warnings":[]},{"id":"0","keyPhrases":[],"statistics":{"charactersCount":2,"transactionsCount":1},"warnings":[]},{"id":"19","keyPhrases":[],"statistics":{"charactersCount":2,"transactionsCount":1},"warnings":[]},{"id":"1","keyPhrases":[],"statistics":{"charactersCount":2,"transactionsCount":1},"warnings":[]}],"errors":[{"id":"22","error":{"code":"InvalidArgument","message":"Invalid + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}}],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - e7c6642b-6924-4b1e-a468-8fe91418d569 + - 28f8d474-b9de-468c-b8d0-d3da73ecf513 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=4 date: - - Thu, 02 Apr 2020 15:07:03 GMT + - Thu, 23 Apr 2020 15:17:07 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_user_agent.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_user_agent.yaml index cce44e15fa72..ff9d9eaa65f1 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_user_agent.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_user_agent.yaml @@ -16,23 +16,23 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: - string: '{"documents":[{"id":"1","keyPhrases":["park"]},{"id":"2","keyPhrases":["hotel"]},{"id":"3","keyPhrases":["restaurant","good - food"]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"1","keyPhrases":["park"],"warnings":[]},{"id":"2","keyPhrases":["hotel"],"warnings":[]},{"id":"3","keyPhrases":["restaurant","good + food"],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - bf34780f-a829-4046-b528-f3954626d874 + - cc2cfc52-8165-4958-a53f-144098db277f content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:07:03 GMT + - Thu, 23 Apr 2020 15:17:07 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -40,7 +40,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '6' + - '5' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_whole_batch_dont_use_language_hint.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_whole_batch_dont_use_language_hint.yaml index a85598c0085c..f1a701aa8199 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_whole_batch_dont_use_language_hint.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_whole_batch_dont_use_language_hint.yaml @@ -16,22 +16,22 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: - string: '{"documents":[{"id":"0","keyPhrases":["best day","life"]},{"id":"1","keyPhrases":["hotel"]},{"id":"2","keyPhrases":["restaurant"]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"0","keyPhrases":["best day","life"],"warnings":[]},{"id":"1","keyPhrases":["hotel"],"warnings":[]},{"id":"2","keyPhrases":["restaurant"],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - 7e44102c-a05f-42df-b456-692dc3fde3d7 + - 1755fe5d-c55b-4cf1-9ff9-fc8b9718a018 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:07:04 GMT + - Thu, 23 Apr 2020 15:17:08 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -39,7 +39,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '6' + - '7' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_whole_batch_language_hint.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_whole_batch_language_hint.yaml index fc557ea4e134..7346bf8fd51d 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_whole_batch_language_hint.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_whole_batch_language_hint.yaml @@ -16,24 +16,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: - string: '{"documents":[{"id":"0","keyPhrases":["This was the best day","my"]},{"id":"1","keyPhrases":["like - the hotel we stayed","It was too expensive","I did"]},{"id":"2","keyPhrases":["as - good as I hoped","The restaurant was"]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"0","keyPhrases":["This was the best day","my"],"warnings":[]},{"id":"1","keyPhrases":["like + the hotel we stayed","It was too expensive","I did"],"warnings":[]},{"id":"2","keyPhrases":["as + good as I hoped","The restaurant was"],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - b9fc63db-54b4-4996-98cc-b581e9fe9c1d + - 412b58ad-2a1c-4e43-91b5-e39244814f3c content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:07:04 GMT + - Thu, 23 Apr 2020 15:17:09 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -41,7 +41,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '3' + - '7' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_whole_batch_language_hint_and_dict_per_item_hints.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_whole_batch_language_hint_and_dict_per_item_hints.yaml index 36c9dcfd587b..b676f9c3accd 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_whole_batch_language_hint_and_dict_per_item_hints.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_whole_batch_language_hint_and_dict_per_item_hints.yaml @@ -16,24 +16,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: - string: '{"documents":[{"id":"1","keyPhrases":["the park","I will go"]},{"id":"2","keyPhrases":["I - did not like the hotel we stayed at"]},{"id":"3","keyPhrases":["restaurant","good - food"]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"1","keyPhrases":["the park","I will go"],"warnings":[]},{"id":"2","keyPhrases":["I + did not like the hotel we stayed at"],"warnings":[]},{"id":"3","keyPhrases":["restaurant","good + food"],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: apim-request-id: - - 8ba47703-aef6-4476-bdc6-f08ada217d0f + - a2bf2025-bd86-49b8-8867-86e4a2370383 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:07:05 GMT + - Thu, 23 Apr 2020 15:17:08 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -41,7 +41,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '5' + - '4' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_whole_batch_language_hint_and_obj_input.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_whole_batch_language_hint_and_obj_input.yaml index 1a6b7d236242..0c237aaf110f 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_whole_batch_language_hint_and_obj_input.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_whole_batch_language_hint_and_obj_input.yaml @@ -16,25 +16,26 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: string: "{\"documents\":[{\"id\":\"1\",\"keyPhrases\":[\"should take my cat\ - \ to the veterinarian\"]},{\"id\":\"4\",\"keyPhrases\":[\"Espa\xF1ol\",\"\ - Este\",\"un document escrito\"]},{\"id\":\"3\",\"keyPhrases\":[\"\u732B\u306F\ - \u5E78\u305B\"]}],\"errors\":[],\"modelVersion\":\"2019-10-01\"}" + \ to the veterinarian\"],\"warnings\":[]},{\"id\":\"4\",\"keyPhrases\":[\"\ + Espa\xF1ol\",\"Este\",\"un document escrito\"],\"warnings\":[]},{\"id\":\"\ + 3\",\"keyPhrases\":[\"\u732B\u306F\u5E78\u305B\"],\"warnings\":[]}],\"errors\"\ + :[],\"modelVersion\":\"2019-10-01\"}" headers: apim-request-id: - - a234024d-2bb6-401b-bca8-0f68df8a9e24 + - 39e4de61-0248-4caf-9df0-c4ee6055c604 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:07:05 GMT + - Thu, 23 Apr 2020 15:17:09 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -42,7 +43,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '4' + - '7' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_whole_batch_language_hint_and_obj_per_item_hints.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_whole_batch_language_hint_and_obj_per_item_hints.yaml index 38a053826f7c..00a68ff5ab43 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_whole_batch_language_hint_and_obj_per_item_hints.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases.test_whole_batch_language_hint_and_obj_per_item_hints.yaml @@ -16,25 +16,26 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: string: "{\"documents\":[{\"id\":\"1\",\"keyPhrases\":[\"I should take my cat\"\ - ,\"the veterinarian\"]},{\"id\":\"2\",\"keyPhrases\":[\"document escrito\"\ - ,\"Espa\xF1ol\"]},{\"id\":\"3\",\"keyPhrases\":[\"\u732B\u306F\u5E78\u305B\ - \"]}],\"errors\":[],\"modelVersion\":\"2019-10-01\"}" + ,\"the veterinarian\"],\"warnings\":[]},{\"id\":\"2\",\"keyPhrases\":[\"document\ + \ escrito\",\"Espa\xF1ol\"],\"warnings\":[]},{\"id\":\"3\",\"keyPhrases\"\ + :[\"\u732B\u306F\u5E78\u305B\"],\"warnings\":[]}],\"errors\":[],\"modelVersion\"\ + :\"2019-10-01\"}" headers: apim-request-id: - - 3ab09d0b-2d83-4534-8ef1-0b1777c7ffc2 + - 1cbd75c5-5ab2-49dd-975a-3bbb4c97080f content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:07:05 GMT + - Thu, 23 Apr 2020 15:17:09 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -42,7 +43,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '6' + - '3' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_all_successful_passing_dict.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_all_successful_passing_dict.yaml index cbbac77f968a..52d609386a90 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_all_successful_passing_dict.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_all_successful_passing_dict.yaml @@ -11,26 +11,26 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=true + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=true response: body: string: '{"statistics":{"documentsCount":2,"validDocumentsCount":2,"erroneousDocumentsCount":0,"transactionsCount":2},"documents":[{"id":"1","keyPhrases":["Bill - Gates","Paul Allen","Microsoft"],"statistics":{"charactersCount":50,"transactionsCount":1}},{"id":"2","keyPhrases":["Bill - Gates","Paul Allen","Microsoft"],"statistics":{"charactersCount":49,"transactionsCount":1}}],"errors":[],"modelVersion":"2019-10-01"}' + Gates","Paul Allen","Microsoft"],"statistics":{"charactersCount":50,"transactionsCount":1},"warnings":[]},{"id":"2","keyPhrases":["Bill + Gates","Paul Allen","Microsoft"],"statistics":{"charactersCount":49,"transactionsCount":1},"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: - apim-request-id: 2515cfa6-22ba-44d3-aa66-eeeca09b8f04 + apim-request-id: 844280f2-5f5b-4948-b907-3b35ffb5b0ad content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=2 - date: Thu, 02 Apr 2020 15:07:06 GMT + date: Thu, 23 Apr 2020 15:23:36 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '6' + x-envoy-upstream-service-time: '14' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/keyPhrases?showStats=true + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=true version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_all_successful_passing_text_document_input.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_all_successful_passing_text_document_input.yaml index 685d6b32b715..3832bc367903 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_all_successful_passing_text_document_input.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_all_successful_passing_text_document_input.yaml @@ -11,25 +11,25 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: - string: '{"documents":[{"id":"1","keyPhrases":["Bill Gates","Paul Allen","Microsoft"]},{"id":"2","keyPhrases":["Bill - Gates","Paul Allen","Microsoft"]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"1","keyPhrases":["Bill Gates","Paul Allen","Microsoft"],"warnings":[]},{"id":"2","keyPhrases":["Bill + Gates","Paul Allen","Microsoft"],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: - apim-request-id: db489157-de9b-4208-aa76-ffb7c5020e17 + apim-request-id: 0ddc65ce-0992-435c-afd3-3fc0f97c010f content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=2 - date: Thu, 02 Apr 2020 15:07:05 GMT + date: Thu, 23 Apr 2020 15:23:37 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '5' + x-envoy-upstream-service-time: '6' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/keyPhrases?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_bad_credentials.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_bad_credentials.yaml index 401790cf53de..52ae7ecec78f 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_bad_credentials.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_bad_credentials.yaml @@ -10,20 +10,25 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: - string: '{"error":{"code":"401","message":"Access denied due to invalid subscription + string: '{"error":{"code":"401","message": "Access denied due to invalid subscription key or wrong API endpoint. Make sure to provide a valid key for an active subscription and use a correct regional API endpoint for your resource."}}' headers: - content-length: '224' - date: Thu, 02 Apr 2020 15:07:06 GMT + apim-request-id: ad1d9642-84cf-43e1-aea4-733c051f17cf + content-length: '225' + content-type: application/json + date: Thu, 23 Apr 2020 15:23:36 GMT + strict-transport-security: max-age=31536000; includeSubDomains; preload + www-authenticate: AzureApiManagementKey realm="https://westus2.ppe.cognitiveservices.azure.com/text/analytics",name="Ocp-Apim-Subscription-Key",type="header" + x-content-type-options: nosniff status: code: 401 - message: PermissionDenied - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/keyPhrases?showStats=false + message: Access Denied + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_bad_model_version.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_bad_model_version.yaml index 65a6c5fc83b1..ef0a9c8aef79 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_bad_model_version.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_bad_model_version.yaml @@ -10,24 +10,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?model-version=old&showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?model-version=old&showStats=false response: body: string: '{"error":{"code":"InvalidRequest","message":"Specified Model version is incorrect. Allowed values are latest,2019-10-01"}}' headers: - apim-request-id: 5f30d997-d01e-4044-8010-b433b0421059 + apim-request-id: c6647179-c94e-41c0-9364-2f5a5b8a02db content-type: application/json; charset=utf-8 - date: Thu, 02 Apr 2020 15:07:07 GMT + date: Thu, 23 Apr 2020 15:23:37 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '4' + x-envoy-upstream-service-time: '3' status: code: 400 message: Bad Request - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/keyPhrases?model-version=old&showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?model-version=old&showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_bad_model_version_error.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_bad_model_version_error.yaml index 21d12a7d4aff..d68febcd4ce8 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_bad_model_version_error.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_bad_model_version_error.yaml @@ -10,24 +10,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?model-version=bad&showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?model-version=bad&showStats=false response: body: string: '{"error":{"code":"InvalidRequest","message":"Specified Model version is incorrect. Allowed values are latest,2019-10-01"}}' headers: - apim-request-id: ff0eae61-7240-4649-adba-b2e267d327b3 + apim-request-id: f3e63046-52af-402a-a7d8-e31618917668 content-type: application/json; charset=utf-8 - date: Thu, 02 Apr 2020 15:07:07 GMT + date: Thu, 23 Apr 2020 15:23:38 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '4' + x-envoy-upstream-service-time: '118' status: code: 400 message: Bad Request - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/keyPhrases?model-version=bad&showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?model-version=bad&showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_batch_size_over_limit.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_batch_size_over_limit.yaml index 391886e45583..61136643324b 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_batch_size_over_limit.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_batch_size_over_limit.yaml @@ -754,24 +754,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: - string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innerError":{"code":"InvalidDocumentBatch","message":"Batch + string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innererror":{"code":"InvalidDocumentBatch","message":"Batch request contains too many records. Max 1000 records are permitted."}}}' headers: - apim-request-id: e518075f-a168-4a64-b11c-eb8253dc7a84 + apim-request-id: c09faaf9-3c0e-46cb-8e82-6f20afa4eb27 content-type: application/json; charset=utf-8 - date: Thu, 02 Apr 2020 15:07:08 GMT + date: Thu, 23 Apr 2020 15:23:39 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '21' + x-envoy-upstream-service-time: '22' status: code: 400 message: Bad Request - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/keyPhrases?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_batch_size_over_limit_error.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_batch_size_over_limit_error.yaml index b0f74fac8d86..21eefcd0e8ff 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_batch_size_over_limit_error.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_batch_size_over_limit_error.yaml @@ -719,24 +719,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: - string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innerError":{"code":"InvalidDocumentBatch","message":"Batch + string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innererror":{"code":"InvalidDocumentBatch","message":"Batch request contains too many records. Max 1000 records are permitted."}}}' headers: - apim-request-id: 4af94f80-466d-4f83-ba4a-dc6aef2e6786 + apim-request-id: 9e32c746-d3e3-435e-8c93-4794aaa48ede content-type: application/json; charset=utf-8 - date: Thu, 02 Apr 2020 15:07:09 GMT + date: Thu, 23 Apr 2020 15:23:39 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '20' + x-envoy-upstream-service-time: '50' status: code: 400 message: Bad Request - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/keyPhrases?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_client_passed_default_language_hint.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_client_passed_default_language_hint.yaml index a122f24302a1..deed8df56c10 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_client_passed_default_language_hint.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_client_passed_default_language_hint.yaml @@ -12,28 +12,28 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: - string: '{"documents":[{"id":"1","keyPhrases":["the park","I will go"]},{"id":"2","keyPhrases":["I - did not like the hotel we stayed at"]},{"id":"3","keyPhrases":["The restaurant - had really good food"]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"1","keyPhrases":["the park","I will go"],"warnings":[]},{"id":"2","keyPhrases":["I + did not like the hotel we stayed at"],"warnings":[]},{"id":"3","keyPhrases":["The + restaurant had really good food"],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: - apim-request-id: f5c743c2-718a-4237-bcf8-520a8e2283cc + apim-request-id: afe7dec0-224d-42b3-8494-810b2c7778e7 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:07:09 GMT + date: Thu, 23 Apr 2020 15:23:40 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '5' + x-envoy-upstream-service-time: '4' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/keyPhrases?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false - request: body: '{"documents": [{"id": "1", "text": "I will go to the park.", "language": "en"}, {"id": "2", "text": "I did not like the hotel we stayed at.", "language": @@ -47,19 +47,19 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: - string: '{"documents":[{"id":"1","keyPhrases":["park"]},{"id":"2","keyPhrases":["hotel"]},{"id":"3","keyPhrases":["restaurant","good - food"]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"1","keyPhrases":["park"],"warnings":[]},{"id":"2","keyPhrases":["hotel"],"warnings":[]},{"id":"3","keyPhrases":["restaurant","good + food"],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: - apim-request-id: 09746fdd-39e2-4614-8dd7-daa1fc29e3f5 + apim-request-id: d13b6cb3-4b32-4b10-bdc0-4b02c72c55bf content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:07:09 GMT + date: Thu, 23 Apr 2020 15:23:40 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff @@ -67,7 +67,7 @@ interactions: status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/keyPhrases?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false - request: body: '{"documents": [{"id": "1", "text": "I will go to the park.", "language": "es"}, {"id": "2", "text": "I did not like the hotel we stayed at.", "language": @@ -81,20 +81,20 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: - string: '{"documents":[{"id":"1","keyPhrases":["the park","I will go"]},{"id":"2","keyPhrases":["I - did not like the hotel we stayed at"]},{"id":"3","keyPhrases":["The restaurant - had really good food"]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"1","keyPhrases":["the park","I will go"],"warnings":[]},{"id":"2","keyPhrases":["I + did not like the hotel we stayed at"],"warnings":[]},{"id":"3","keyPhrases":["The + restaurant had really good food"],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: - apim-request-id: 1b371199-f616-4dd1-9320-aae0384b1b96 + apim-request-id: dec44474-d9f7-4e5a-adf6-baee3259bfb5 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:07:09 GMT + date: Thu, 23 Apr 2020 15:23:40 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff @@ -102,5 +102,5 @@ interactions: status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/keyPhrases?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_document_attribute_error_no_result_attribute.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_document_attribute_error_no_result_attribute.yaml index bfa066f579c4..2945b985433a 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_document_attribute_error_no_result_attribute.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_document_attribute_error_no_result_attribute.yaml @@ -9,26 +9,26 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: string: '{"documents":[],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}}],"modelVersion":"2019-10-01"}' headers: - apim-request-id: 6f7a2e6d-fdde-4455-835b-6c018e5365d9 + apim-request-id: 4ffed3a4-eb28-4fb2-b217-fa32270814bc content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=0 - date: Thu, 02 Apr 2020 15:07:10 GMT + date: Thu, 23 Apr 2020 15:23:39 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '6' + x-envoy-upstream-service-time: '2' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/keyPhrases?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_document_attribute_error_nonexistent_attribute.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_document_attribute_error_nonexistent_attribute.yaml index 71552dd50036..28e58ec98960 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_document_attribute_error_nonexistent_attribute.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_document_attribute_error_nonexistent_attribute.yaml @@ -9,26 +9,26 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: string: '{"documents":[],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}}],"modelVersion":"2019-10-01"}' headers: - apim-request-id: fd0d817c-572b-4964-9c69-cbab6f57df67 + apim-request-id: 3f0b19ae-882b-4942-af7e-ed86a1995326 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=0 - date: Thu, 02 Apr 2020 15:07:10 GMT + date: Thu, 23 Apr 2020 15:23:40 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '3' + x-envoy-upstream-service-time: '2' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/keyPhrases?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_document_errors.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_document_errors.yaml index ab161b89c533..cabb8bd747a3 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_document_errors.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_document_errors.yaml @@ -12,32 +12,32 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: string: '{"documents":[],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}},{"id":"2","error":{"code":"InvalidArgument","message":"Invalid - Language Code.","innerError":{"code":"UnsupportedLanguageCode","message":"Supplied + Language Code.","innererror":{"code":"UnsupportedLanguageCode","message":"Supplied language not supported. Pass in one of: da,de,en,es,fi,fr,it,ja,ko,nl,no,pl,pt-BR,pt-PT,ru,sv"}}},{"id":"3","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"A + document in request.","innererror":{"code":"InvalidDocument","message":"A document within the request was too large to be processed. Limit document size to: 5120 text elements. For additional details on the data limitations see https://aka.ms/text-analytics-data-limits"}}}],"modelVersion":"2019-10-01"}' headers: - apim-request-id: 5ae68610-0e3a-4505-bd02-9140d3d23fc3 + apim-request-id: f7dd4432-1368-495b-a8e4-c5175aec25e2 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=0 - date: Thu, 02 Apr 2020 15:07:10 GMT + date: Thu, 23 Apr 2020 15:23:41 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '3' + x-envoy-upstream-service-time: '7' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/keyPhrases?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_duplicate_ids_error.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_duplicate_ids_error.yaml index 5ab63a13c321..25d63f2f09ac 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_duplicate_ids_error.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_duplicate_ids_error.yaml @@ -10,24 +10,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: - string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innerError":{"code":"InvalidDocument","message":"Request + string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innererror":{"code":"InvalidDocument","message":"Request contains duplicated Ids. Make sure each document has a unique Id."}}}' headers: - apim-request-id: 97d1bba6-c420-4397-93ec-9ae7c9f8f52b + apim-request-id: c12b9775-83c1-49c0-8efc-6611e631bcb0 content-type: application/json; charset=utf-8 - date: Thu, 02 Apr 2020 15:07:11 GMT + date: Thu, 23 Apr 2020 15:23:42 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '4' + x-envoy-upstream-service-time: '3' status: code: 400 message: Bad Request - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/keyPhrases?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_empty_credential_class.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_empty_credential_class.yaml index f5908b6d6459..ecce6632f175 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_empty_credential_class.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_empty_credential_class.yaml @@ -10,20 +10,25 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: - string: '{"error":{"code":"401","message":"Access denied due to invalid subscription + string: '{"error":{"code":"401","message": "Access denied due to invalid subscription key or wrong API endpoint. Make sure to provide a valid key for an active subscription and use a correct regional API endpoint for your resource."}}' headers: - content-length: '224' - date: Thu, 02 Apr 2020 15:07:12 GMT + apim-request-id: 1588988e-dd93-4994-b825-e98957371972 + content-length: '225' + content-type: application/json + date: Thu, 23 Apr 2020 15:23:41 GMT + strict-transport-security: max-age=31536000; includeSubDomains; preload + www-authenticate: AzureApiManagementKey realm="https://westus2.ppe.cognitiveservices.azure.com/text/analytics",name="Ocp-Apim-Subscription-Key",type="header" + x-content-type-options: nosniff status: code: 401 - message: PermissionDenied - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/keyPhrases?showStats=false + message: Access Denied + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_input_with_all_errors.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_input_with_all_errors.yaml index d9e92b4c1a2b..1ad083c7c44b 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_input_with_all_errors.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_input_with_all_errors.yaml @@ -11,22 +11,22 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: string: '{"documents":[],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - Language Code.","innerError":{"code":"UnsupportedLanguageCode","message":"Supplied + Language Code.","innererror":{"code":"UnsupportedLanguageCode","message":"Supplied language not supported. Pass in one of: da,de,en,es,fi,fr,it,ja,ko,nl,no,pl,pt-BR,pt-PT,ru,sv"}}},{"id":"2","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}}],"modelVersion":"2019-10-01"}' headers: - apim-request-id: d61f5186-d81c-4065-a4bc-87d1eafbeecb + apim-request-id: df092574-421b-43e7-8bd0-fba987a203e2 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=0 - date: Thu, 02 Apr 2020 15:07:11 GMT + date: Thu, 23 Apr 2020 15:23:42 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff @@ -34,5 +34,5 @@ interactions: status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/keyPhrases?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_input_with_some_errors.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_input_with_some_errors.yaml index 7fb4ec53630b..e49ee47b84c0 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_input_with_some_errors.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_input_with_some_errors.yaml @@ -11,26 +11,26 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: - string: '{"documents":[{"id":"2","keyPhrases":["Bill Gates","Paul Allen","Microsoft"]}],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - Language Code.","innerError":{"code":"UnsupportedLanguageCode","message":"Supplied + string: '{"documents":[{"id":"2","keyPhrases":["Bill Gates","Paul Allen","Microsoft"],"warnings":[]}],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid + Language Code.","innererror":{"code":"UnsupportedLanguageCode","message":"Supplied language not supported. Pass in one of: da,de,en,es,fi,fr,it,ja,ko,nl,no,pl,pt-BR,pt-PT,ru,sv"}}}],"modelVersion":"2019-10-01"}' headers: - apim-request-id: 90d54c5c-089e-4dae-b942-7e0bbbb2bb48 + apim-request-id: 87473fe7-7b6f-44a5-9267-e2b514b61715 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=1 - date: Thu, 02 Apr 2020 15:07:12 GMT + date: Thu, 23 Apr 2020 15:23:43 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '4' + x-envoy-upstream-service-time: '3' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/keyPhrases?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_language_kwarg_spanish.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_language_kwarg_spanish.yaml index edac6dfb142a..1111b6e5f8a3 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_language_kwarg_spanish.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_language_kwarg_spanish.yaml @@ -10,25 +10,25 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?model-version=latest&showStats=true + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?model-version=latest&showStats=true response: body: string: '{"statistics":{"documentsCount":1,"validDocumentsCount":1,"erroneousDocumentsCount":0,"transactionsCount":1},"documents":[{"id":"0","keyPhrases":["Bill - Gates","the CEO of Microsoft"],"statistics":{"charactersCount":35,"transactionsCount":1}}],"errors":[],"modelVersion":"2019-10-01"}' + Gates","the CEO of Microsoft"],"statistics":{"charactersCount":35,"transactionsCount":1},"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: - apim-request-id: fa5b1d32-008d-402b-984d-aa4b9f68c5c5 + apim-request-id: 09ed2caa-3533-451c-bb0e-54d3e91f051f content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=1 - date: Thu, 02 Apr 2020 15:07:13 GMT + date: Thu, 23 Apr 2020 15:23:43 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '5' + x-envoy-upstream-service-time: '3' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/keyPhrases?model-version=latest&showStats=true + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?model-version=latest&showStats=true version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_missing_input_records_error.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_missing_input_records_error.yaml deleted file mode 100644 index a3251fdfc8bd..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_missing_input_records_error.yaml +++ /dev/null @@ -1,32 +0,0 @@ -interactions: -- request: - body: '{"documents": []}' - headers: - Accept: - - application/json - Content-Length: - - '17' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false - response: - body: - string: '{"error":{"code":"InvalidRequest","message":"Invalid Request.","innerError":{"code":"MissingInputRecords","message":"Missing - input records."}}}' - headers: - apim-request-id: 425eb425-c524-4d24-9ea5-88f4a4cf8aa6 - content-type: application/json; charset=utf-8 - date: Thu, 02 Apr 2020 15:07:13 GMT - strict-transport-security: max-age=31536000; includeSubDomains; preload - transfer-encoding: chunked - x-content-type-options: nosniff - x-envoy-upstream-service-time: '3' - status: - code: 400 - message: Bad Request - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/keyPhrases?showStats=false -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_out_of_order_ids.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_out_of_order_ids.yaml index bb282e11c575..7f85fa40238b 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_out_of_order_ids.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_out_of_order_ids.yaml @@ -12,20 +12,20 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: - string: '{"documents":[{"id":"56","keyPhrases":[]},{"id":"0","keyPhrases":[]},{"id":"19","keyPhrases":[]},{"id":"1","keyPhrases":[]}],"errors":[{"id":"22","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + string: '{"documents":[{"id":"56","keyPhrases":[],"warnings":[]},{"id":"0","keyPhrases":[],"warnings":[]},{"id":"19","keyPhrases":[],"warnings":[]},{"id":"1","keyPhrases":[],"warnings":[]}],"errors":[{"id":"22","error":{"code":"InvalidArgument","message":"Invalid + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}}],"modelVersion":"2019-10-01"}' headers: - apim-request-id: 6ed72153-c356-4f9b-af2f-b258014c24fd + apim-request-id: 541e8ab1-9fbe-4f0f-b8c8-e58f66066f6b content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=4 - date: Thu, 02 Apr 2020 15:07:13 GMT + date: Thu, 23 Apr 2020 15:23:43 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff @@ -33,5 +33,5 @@ interactions: status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/keyPhrases?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_pass_cls.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_pass_cls.yaml index 61010bc28065..02664ba647e3 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_pass_cls.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_pass_cls.yaml @@ -10,24 +10,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: - string: '{"documents":[{"id":"0","keyPhrases":["Test","cls","endpoint"]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"0","keyPhrases":["Test","cls","endpoint"],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: - apim-request-id: 23da7542-1be8-47f2-952b-129026bd00cf + apim-request-id: a07ec0f3-838d-4b64-8420-a89231e5eb00 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=1 - date: Thu, 02 Apr 2020 15:07:14 GMT + date: Thu, 23 Apr 2020 15:23:44 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '6' + x-envoy-upstream-service-time: '3' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/keyPhrases?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_passing_only_string.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_passing_only_string.yaml index 578578a9c697..6d0e28e7fec1 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_passing_only_string.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_passing_only_string.yaml @@ -12,27 +12,27 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: - string: '{"documents":[{"id":"0","keyPhrases":["Bill Gates","Paul Allen","Microsoft"]},{"id":"1","keyPhrases":["Microsoft - fue fundado por Bill Gates y Paul Allen"]}],"errors":[{"id":"2","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + string: '{"documents":[{"id":"0","keyPhrases":["Bill Gates","Paul Allen","Microsoft"],"warnings":[]},{"id":"1","keyPhrases":["Microsoft + fue fundado por Bill Gates y Paul Allen"],"warnings":[]}],"errors":[{"id":"2","error":{"code":"InvalidArgument","message":"Invalid + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}}],"modelVersion":"2019-10-01"}' headers: - apim-request-id: 54ff367b-2803-456d-986d-712707300ebb + apim-request-id: 374ce9a6-4b57-467a-9013-8499b21bf3cb content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=2 - date: Thu, 02 Apr 2020 15:07:14 GMT + date: Thu, 23 Apr 2020 15:23:44 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '5' + x-envoy-upstream-service-time: '6' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/keyPhrases?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_per_item_dont_use_language_hint.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_per_item_dont_use_language_hint.yaml index 6be4e6e49a40..680e57cb5124 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_per_item_dont_use_language_hint.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_per_item_dont_use_language_hint.yaml @@ -12,19 +12,19 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: - string: '{"documents":[{"id":"1","keyPhrases":["park"]},{"id":"2","keyPhrases":["hotel"]},{"id":"3","keyPhrases":["restaurant","good - food"]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"1","keyPhrases":["park"],"warnings":[]},{"id":"2","keyPhrases":["hotel"],"warnings":[]},{"id":"3","keyPhrases":["restaurant","good + food"],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: - apim-request-id: d1f3f1cd-59fe-4a32-9c9b-4c6c62797a94 + apim-request-id: cacc9480-9ee9-423f-90f3-1f36b5ab271e content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:07:14 GMT + date: Thu, 23 Apr 2020 15:23:44 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff @@ -32,5 +32,5 @@ interactions: status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/keyPhrases?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_rotate_subscription_key.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_rotate_subscription_key.yaml index 9b5dc0586e06..06f81cefe875 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_rotate_subscription_key.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_rotate_subscription_key.yaml @@ -12,27 +12,27 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: - string: '{"documents":[{"id":"1","keyPhrases":["park"]},{"id":"2","keyPhrases":["hotel"]},{"id":"3","keyPhrases":["restaurant","good - food"]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"1","keyPhrases":["park"],"warnings":[]},{"id":"2","keyPhrases":["hotel"],"warnings":[]},{"id":"3","keyPhrases":["restaurant","good + food"],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: - apim-request-id: 54e2e757-a107-49c1-8993-c1a665c0ed78 + apim-request-id: 44fe5c7e-16a4-4894-aa69-ad5865199626 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:07:15 GMT + date: Thu, 23 Apr 2020 15:23:44 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '6' + x-envoy-upstream-service-time: '7' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/keyPhrases?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false - request: body: '{"documents": [{"id": "1", "text": "I will go to the park.", "language": "en"}, {"id": "2", "text": "I did not like the hotel we stayed at.", "language": @@ -46,22 +46,27 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: - string: '{"error":{"code":"401","message":"Access denied due to invalid subscription + string: '{"error":{"code":"401","message": "Access denied due to invalid subscription key or wrong API endpoint. Make sure to provide a valid key for an active subscription and use a correct regional API endpoint for your resource."}}' headers: - content-length: '224' - date: Thu, 02 Apr 2020 15:07:15 GMT + apim-request-id: 39713439-51b0-434b-a507-6c1526fd45e5 + content-length: '225' + content-type: application/json + date: Thu, 23 Apr 2020 15:23:44 GMT + strict-transport-security: max-age=31536000; includeSubDomains; preload + www-authenticate: AzureApiManagementKey realm="https://westus2.ppe.cognitiveservices.azure.com/text/analytics",name="Ocp-Apim-Subscription-Key",type="header" + x-content-type-options: nosniff status: code: 401 - message: PermissionDenied - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/keyPhrases?showStats=false + message: Access Denied + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false - request: body: '{"documents": [{"id": "1", "text": "I will go to the park.", "language": "en"}, {"id": "2", "text": "I did not like the hotel we stayed at.", "language": @@ -75,25 +80,25 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: - string: '{"documents":[{"id":"1","keyPhrases":["park"]},{"id":"2","keyPhrases":["hotel"]},{"id":"3","keyPhrases":["restaurant","good - food"]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"1","keyPhrases":["park"],"warnings":[]},{"id":"2","keyPhrases":["hotel"],"warnings":[]},{"id":"3","keyPhrases":["restaurant","good + food"],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: - apim-request-id: 6c940658-e45e-4e18-9f0c-be63c6a6a4d2 + apim-request-id: 66c368ce-34ae-4468-84aa-341832aa8c8c content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:07:15 GMT + date: Thu, 23 Apr 2020 15:23:44 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '7' + x-envoy-upstream-service-time: '6' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/keyPhrases?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_show_stats_and_model_version.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_show_stats_and_model_version.yaml index 39e4cd082b16..071b4fc88cc7 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_show_stats_and_model_version.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_show_stats_and_model_version.yaml @@ -12,20 +12,20 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?model-version=latest&showStats=true + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?model-version=latest&showStats=true response: body: - string: '{"statistics":{"documentsCount":5,"validDocumentsCount":4,"erroneousDocumentsCount":1,"transactionsCount":4},"documents":[{"id":"56","keyPhrases":[],"statistics":{"charactersCount":2,"transactionsCount":1}},{"id":"0","keyPhrases":[],"statistics":{"charactersCount":2,"transactionsCount":1}},{"id":"19","keyPhrases":[],"statistics":{"charactersCount":2,"transactionsCount":1}},{"id":"1","keyPhrases":[],"statistics":{"charactersCount":2,"transactionsCount":1}}],"errors":[{"id":"22","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + string: '{"statistics":{"documentsCount":5,"validDocumentsCount":4,"erroneousDocumentsCount":1,"transactionsCount":4},"documents":[{"id":"56","keyPhrases":[],"statistics":{"charactersCount":2,"transactionsCount":1},"warnings":[]},{"id":"0","keyPhrases":[],"statistics":{"charactersCount":2,"transactionsCount":1},"warnings":[]},{"id":"19","keyPhrases":[],"statistics":{"charactersCount":2,"transactionsCount":1},"warnings":[]},{"id":"1","keyPhrases":[],"statistics":{"charactersCount":2,"transactionsCount":1},"warnings":[]}],"errors":[{"id":"22","error":{"code":"InvalidArgument","message":"Invalid + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}}],"modelVersion":"2019-10-01"}' headers: - apim-request-id: 7fd95820-0190-4921-b305-85c20bc02ed6 + apim-request-id: e6b1791c-f94a-4ea3-9ccd-3456aa2d5ce3 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=4 - date: Thu, 02 Apr 2020 15:07:15 GMT + date: Thu, 23 Apr 2020 15:23:46 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff @@ -33,5 +33,5 @@ interactions: status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/keyPhrases?model-version=latest&showStats=true + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?model-version=latest&showStats=true version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_user_agent.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_user_agent.yaml index aaa79e0db5d4..e50e2af2b2da 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_user_agent.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_user_agent.yaml @@ -12,19 +12,19 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: - string: '{"documents":[{"id":"1","keyPhrases":["park"]},{"id":"2","keyPhrases":["hotel"]},{"id":"3","keyPhrases":["restaurant","good - food"]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"1","keyPhrases":["park"],"warnings":[]},{"id":"2","keyPhrases":["hotel"],"warnings":[]},{"id":"3","keyPhrases":["restaurant","good + food"],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: - apim-request-id: e697fa0d-145a-403b-9572-42066fa40445 + apim-request-id: 719e6057-a326-4dc2-9db9-e1ac554e2cd1 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:07:16 GMT + date: Thu, 23 Apr 2020 15:23:46 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff @@ -32,5 +32,5 @@ interactions: status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/keyPhrases?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_whole_batch_dont_use_language_hint.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_whole_batch_dont_use_language_hint.yaml index 34b3a6bb28fc..07b59f28693d 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_whole_batch_dont_use_language_hint.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_whole_batch_dont_use_language_hint.yaml @@ -12,24 +12,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: - string: '{"documents":[{"id":"0","keyPhrases":["best day","life"]},{"id":"1","keyPhrases":["hotel"]},{"id":"2","keyPhrases":["restaurant"]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"0","keyPhrases":["best day","life"],"warnings":[]},{"id":"1","keyPhrases":["hotel"],"warnings":[]},{"id":"2","keyPhrases":["restaurant"],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: - apim-request-id: 1e86e0b4-e50e-47de-abc6-58f556f34798 + apim-request-id: c02841a1-49b5-4f36-94c4-bc03610ecaa7 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:07:16 GMT + date: Thu, 23 Apr 2020 15:23:46 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '9' + x-envoy-upstream-service-time: '6' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/keyPhrases?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_whole_batch_language_hint.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_whole_batch_language_hint.yaml index 8b0af727bf4d..81b0374a2401 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_whole_batch_language_hint.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_whole_batch_language_hint.yaml @@ -12,26 +12,26 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: - string: '{"documents":[{"id":"0","keyPhrases":["This was the best day","my"]},{"id":"1","keyPhrases":["like - the hotel we stayed","It was too expensive","I did"]},{"id":"2","keyPhrases":["as - good as I hoped","The restaurant was"]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"0","keyPhrases":["This was the best day","my"],"warnings":[]},{"id":"1","keyPhrases":["like + the hotel we stayed","It was too expensive","I did"],"warnings":[]},{"id":"2","keyPhrases":["as + good as I hoped","The restaurant was"],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: - apim-request-id: 4805e12a-43c0-46dd-8782-22df999d3db1 + apim-request-id: d3a95067-be72-4d0d-bb4b-b8205c7e0e74 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:07:17 GMT + date: Thu, 23 Apr 2020 15:23:46 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '5' + x-envoy-upstream-service-time: '7' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/keyPhrases?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_whole_batch_language_hint_and_dict_per_item_hints.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_whole_batch_language_hint_and_dict_per_item_hints.yaml index 275bee0f486c..e34b70b1affc 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_whole_batch_language_hint_and_dict_per_item_hints.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_whole_batch_language_hint_and_dict_per_item_hints.yaml @@ -12,26 +12,26 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: - string: '{"documents":[{"id":"1","keyPhrases":["the park","I will go"]},{"id":"2","keyPhrases":["I - did not like the hotel we stayed at"]},{"id":"3","keyPhrases":["restaurant","good - food"]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"1","keyPhrases":["the park","I will go"],"warnings":[]},{"id":"2","keyPhrases":["I + did not like the hotel we stayed at"],"warnings":[]},{"id":"3","keyPhrases":["restaurant","good + food"],"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: - apim-request-id: fc22709f-ca68-41de-9a1b-700c392d2296 + apim-request-id: bde7ee61-8b27-4b3e-8533-920efdc43237 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:07:16 GMT + date: Thu, 23 Apr 2020 15:23:47 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '6' + x-envoy-upstream-service-time: '5' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/keyPhrases?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_whole_batch_language_hint_and_obj_input.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_whole_batch_language_hint_and_obj_input.yaml index 06d9286b26b2..ada43a59e4d4 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_whole_batch_language_hint_and_obj_input.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_whole_batch_language_hint_and_obj_input.yaml @@ -12,27 +12,28 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: string: "{\"documents\":[{\"id\":\"1\",\"keyPhrases\":[\"should take my cat\ - \ to the veterinarian\"]},{\"id\":\"4\",\"keyPhrases\":[\"Espa\xF1ol\",\"\ - Este\",\"un document escrito\"]},{\"id\":\"3\",\"keyPhrases\":[\"\u732B\u306F\ - \u5E78\u305B\"]}],\"errors\":[],\"modelVersion\":\"2019-10-01\"}" + \ to the veterinarian\"],\"warnings\":[]},{\"id\":\"4\",\"keyPhrases\":[\"\ + Espa\xF1ol\",\"Este\",\"un document escrito\"],\"warnings\":[]},{\"id\":\"\ + 3\",\"keyPhrases\":[\"\u732B\u306F\u5E78\u305B\"],\"warnings\":[]}],\"errors\"\ + :[],\"modelVersion\":\"2019-10-01\"}" headers: - apim-request-id: be570a53-288e-48fc-81e3-d75b5e27b78b + apim-request-id: e9f9969d-3c1a-4582-8f50-c6acc8a95f47 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:07:17 GMT + date: Thu, 23 Apr 2020 15:23:47 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '4' + x-envoy-upstream-service-time: '7' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/keyPhrases?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_whole_batch_language_hint_and_obj_per_item_hints.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_whole_batch_language_hint_and_obj_per_item_hints.yaml index b71b83979663..139dba115d91 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_whole_batch_language_hint_and_obj_per_item_hints.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_extract_key_phrases_async.test_whole_batch_language_hint_and_obj_per_item_hints.yaml @@ -12,21 +12,22 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/keyPhrases?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false response: body: string: "{\"documents\":[{\"id\":\"1\",\"keyPhrases\":[\"I should take my cat\"\ - ,\"the veterinarian\"]},{\"id\":\"2\",\"keyPhrases\":[\"document escrito\"\ - ,\"Espa\xF1ol\"]},{\"id\":\"3\",\"keyPhrases\":[\"\u732B\u306F\u5E78\u305B\ - \"]}],\"errors\":[],\"modelVersion\":\"2019-10-01\"}" + ,\"the veterinarian\"],\"warnings\":[]},{\"id\":\"2\",\"keyPhrases\":[\"document\ + \ escrito\",\"Espa\xF1ol\"],\"warnings\":[]},{\"id\":\"3\",\"keyPhrases\"\ + :[\"\u732B\u306F\u5E78\u305B\"],\"warnings\":[]}],\"errors\":[],\"modelVersion\"\ + :\"2019-10-01\"}" headers: - apim-request-id: 40cac3d7-36a1-47e1-8589-4784b0a51a33 + apim-request-id: a22c5b76-ca93-43f5-8e24-6088b2e8bdbb content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:07:17 GMT + date: Thu, 23 Apr 2020 15:23:47 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff @@ -34,5 +35,5 @@ interactions: status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/keyPhrases?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/keyPhrases?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_all_successful_passing_dict.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_all_successful_passing_dict.yaml deleted file mode 100644 index fe686538f96f..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_all_successful_passing_dict.yaml +++ /dev/null @@ -1,56 +0,0 @@ -interactions: -- request: - body: '{"documents": [{"id": "1", "text": "Microsoft was founded by Bill Gates - and Paul Allen on April 4, 1975.", "language": "en"}, {"id": "2", "text": "Microsoft - fue fundado por Bill Gates y Paul Allen el 4 de abril de 1975.", "language": - "es"}, {"id": "3", "text": "Microsoft wurde am 4. April 1975 von Bill Gates - und Paul Allen gegr\u00fcndet.", "language": "de"}]}' - headers: - Accept: - - application/json - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '362' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=true - response: - body: - string: '{"statistics":{"documentsCount":3,"validDocumentsCount":3,"erroneousDocumentsCount":0,"transactionsCount":3},"documents":[{"id":"1","statistics":{"charactersCount":68,"transactionsCount":1},"entities":[{"text":"Microsoft","type":"Organization","offset":0,"length":9,"score":1.0},{"text":"Bill - Gates","type":"Person","offset":25,"length":10,"score":0.67},{"text":"Paul - Allen","type":"Person","offset":40,"length":10,"score":0.81},{"text":"April - 4, 1975","type":"DateTime","subtype":"Date","offset":54,"length":13,"score":0.8}]},{"id":"2","statistics":{"charactersCount":72,"transactionsCount":1},"entities":[{"text":"Microsoft","type":"Organization","offset":0,"length":9,"score":1.0},{"text":"Bill - Gates","type":"Person","offset":26,"length":10,"score":0.8},{"text":"Paul - Allen","type":"Person","offset":39,"length":10,"score":0.78},{"text":"4 de - abril de 1975","type":"DateTime","subtype":"Date","offset":53,"length":18,"score":0.8}]},{"id":"3","statistics":{"charactersCount":73,"transactionsCount":1},"entities":[{"text":"Microsoft","type":"Organization","offset":0,"length":9,"score":1.0},{"text":"4. - April 1975","type":"DateTime","subtype":"Date","offset":19,"length":13,"score":0.8},{"text":"Bill - Gates","type":"Person","offset":37,"length":10,"score":0.86},{"text":"Paul - Allen","type":"Person","offset":52,"length":10,"score":0.98}]}],"errors":[],"modelVersion":"2020-02-01"}' - headers: - apim-request-id: - - a2ee1b79-0ec5-4007-946e-a2cfc8e5e46b - content-type: - - application/json; charset=utf-8 - csp-billing-usage: - - CognitiveServices.TextAnalytics.BatchScoring=3 - date: - - Thu, 02 Apr 2020 15:07:19 GMT - strict-transport-security: - - max-age=31536000; includeSubDomains; preload - transfer-encoding: - - chunked - x-content-type-options: - - nosniff - x-envoy-upstream-service-time: - - '60' - status: - code: 200 - message: OK -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_all_successful_passing_text_document_input.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_all_successful_passing_text_document_input.yaml deleted file mode 100644 index c5065c16c248..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_all_successful_passing_text_document_input.yaml +++ /dev/null @@ -1,56 +0,0 @@ -interactions: -- request: - body: '{"documents": [{"id": "1", "text": "Microsoft was founded by Bill Gates - and Paul Allen on April 4, 1975.", "language": "en"}, {"id": "2", "text": "Microsoft - fue fundado por Bill Gates y Paul Allen el 4 de abril de 1975.", "language": - "es"}, {"id": "3", "text": "Microsoft wurde am 4. April 1975 von Bill Gates - und Paul Allen gegr\u00fcndet.", "language": "de"}]}' - headers: - Accept: - - application/json - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '362' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false - response: - body: - string: '{"documents":[{"id":"1","entities":[{"text":"Microsoft","type":"Organization","offset":0,"length":9,"score":1.0},{"text":"Bill - Gates","type":"Person","offset":25,"length":10,"score":0.67},{"text":"Paul - Allen","type":"Person","offset":40,"length":10,"score":0.81},{"text":"April - 4, 1975","type":"DateTime","subtype":"Date","offset":54,"length":13,"score":0.8}]},{"id":"2","entities":[{"text":"Microsoft","type":"Organization","offset":0,"length":9,"score":1.0},{"text":"Bill - Gates","type":"Person","offset":26,"length":10,"score":0.8},{"text":"Paul - Allen","type":"Person","offset":39,"length":10,"score":0.78},{"text":"4 de - abril de 1975","type":"DateTime","subtype":"Date","offset":53,"length":18,"score":0.8}]},{"id":"3","entities":[{"text":"Microsoft","type":"Organization","offset":0,"length":9,"score":1.0},{"text":"4. - April 1975","type":"DateTime","subtype":"Date","offset":19,"length":13,"score":0.8},{"text":"Bill - Gates","type":"Person","offset":37,"length":10,"score":0.86},{"text":"Paul - Allen","type":"Person","offset":52,"length":10,"score":0.98}]}],"errors":[],"modelVersion":"2020-02-01"}' - headers: - apim-request-id: - - d319e5b4-512d-443f-9156-00bb0f8ad024 - content-type: - - application/json; charset=utf-8 - csp-billing-usage: - - CognitiveServices.TextAnalytics.BatchScoring=3 - date: - - Thu, 02 Apr 2020 15:07:19 GMT - strict-transport-security: - - max-age=31536000; includeSubDomains; preload - transfer-encoding: - - chunked - x-content-type-options: - - nosniff - x-envoy-upstream-service-time: - - '56' - status: - code: 200 - message: OK -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_bad_credentials.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_bad_credentials.yaml index 70d2bd1380c2..d78e13fab976 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_bad_credentials.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_bad_credentials.yaml @@ -14,21 +14,31 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: - string: '{"error":{"code":"401","message":"Access denied due to invalid subscription + string: '{"error":{"code":"401","message": "Access denied due to invalid subscription key or wrong API endpoint. Make sure to provide a valid key for an active subscription and use a correct regional API endpoint for your resource."}}' headers: + apim-request-id: + - 5a97cdb0-5be6-426f-8bdb-c26e6f5ac671 content-length: - - '224' + - '225' + content-type: + - application/json date: - - Thu, 02 Apr 2020 15:07:19 GMT + - Thu, 23 Apr 2020 15:53:55 GMT + strict-transport-security: + - max-age=31536000; includeSubDomains; preload + www-authenticate: + - AzureApiManagementKey realm="https://westus2.ppe.cognitiveservices.azure.com/text/analytics",name="Ocp-Apim-Subscription-Key",type="header" + x-content-type-options: + - nosniff status: code: 401 - message: PermissionDenied + message: Access Denied version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_bad_model_version.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_bad_model_version.yaml index 5d510bf33e6c..f873be880e1e 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_bad_model_version.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_bad_model_version.yaml @@ -14,21 +14,21 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?model-version=old&showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?model-version=old&showStats=false response: body: string: '{"error":{"code":"InvalidRequest","message":"Specified Model version - is incorrect. Allowed values are latest,2019-10-01,2020-02-01"}}' + is incorrect. Allowed values are latest,2020-04-01,2019-10-01,2020-02-01"}}' headers: apim-request-id: - - a932797b-901c-4c62-a042-5bdc64b2964d + - 684d6552-b629-47f1-8bed-000e7dff9978 content-type: - application/json; charset=utf-8 date: - - Thu, 02 Apr 2020 15:07:19 GMT + - Thu, 23 Apr 2020 15:53:55 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_bad_model_version_error.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_bad_model_version_error.yaml index 80b46cd25080..a2a36468e461 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_bad_model_version_error.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_bad_model_version_error.yaml @@ -14,21 +14,21 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?model-version=bad&showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?model-version=bad&showStats=false response: body: string: '{"error":{"code":"InvalidRequest","message":"Specified Model version - is incorrect. Allowed values are latest,2019-10-01,2020-02-01"}}' + is incorrect. Allowed values are latest,2020-04-01,2019-10-01,2020-02-01"}}' headers: apim-request-id: - - 562305b2-24e4-4a92-8fd7-ce1f1afa7d7a + - 2f689747-4713-43a4-bc90-a89664f0d2f2 content-type: - application/json; charset=utf-8 date: - - Thu, 02 Apr 2020 15:07:20 GMT + - Thu, 23 Apr 2020 15:53:56 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -36,7 +36,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '5' + - '4' status: code: 400 message: Bad Request diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_batch_size_over_limit.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_batch_size_over_limit.yaml index bd0f5bb01e2d..564ecfd4693b 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_batch_size_over_limit.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_batch_size_over_limit.yaml @@ -758,21 +758,21 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: - string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innerError":{"code":"InvalidDocumentBatch","message":"Batch + string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innererror":{"code":"InvalidDocumentBatch","message":"Batch request contains too many records. Max 1000 records are permitted."}}}' headers: apim-request-id: - - 7d6995f8-592f-4d5b-a86f-801c8e30a547 + - 7f2760cf-e463-47b5-a569-c47c04cfca8d content-type: - application/json; charset=utf-8 date: - - Thu, 02 Apr 2020 15:07:21 GMT + - Thu, 23 Apr 2020 15:53:57 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -780,7 +780,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '14' + - '10' status: code: 400 message: Bad Request diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_batch_size_over_limit_error.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_batch_size_over_limit_error.yaml index 8deb1f16743b..8fd6d4b052b7 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_batch_size_over_limit_error.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_batch_size_over_limit_error.yaml @@ -723,21 +723,21 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: - string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innerError":{"code":"InvalidDocumentBatch","message":"Batch + string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innererror":{"code":"InvalidDocumentBatch","message":"Batch request contains too many records. Max 1000 records are permitted."}}}' headers: apim-request-id: - - 5db296b7-5b19-4724-8168-87de764a1d00 + - 797c3472-2405-4755-a44c-3e3bbf6c37af content-type: - application/json; charset=utf-8 date: - - Thu, 02 Apr 2020 15:07:21 GMT + - Thu, 23 Apr 2020 15:53:57 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -745,7 +745,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '12' + - '10' status: code: 400 message: Bad Request diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_client_passed_default_language_hint.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_client_passed_default_language_hint.yaml index 63fb40dccc6e..8f3b33a5c477 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_client_passed_default_language_hint.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_client_passed_default_language_hint.yaml @@ -16,22 +16,22 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: - string: '{"documents":[{"id":"1","entities":[]},{"id":"2","entities":[]},{"id":"3","entities":[]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"1","entities":[],"warnings":[]},{"id":"2","entities":[],"warnings":[]},{"id":"3","entities":[],"warnings":[]}],"errors":[],"modelVersion":"2020-04-01"}' headers: apim-request-id: - - f0ec5a95-cb17-43bd-b669-f9b03c845304 + - e2a27e2e-8cfd-4417-acd8-9ed3c44aa213 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:07:22 GMT + - Thu, 23 Apr 2020 15:53:58 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -39,7 +39,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '17' + - '11' status: code: 200 message: OK @@ -60,22 +60,22 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: - string: '{"documents":[{"id":"1","entities":[{"text":"park","type":"Location","offset":17,"length":4,"score":0.73}]},{"id":"2","entities":[{"text":"hotel","type":"Location","offset":19,"length":5,"score":0.75}]},{"id":"3","entities":[{"text":"restaurant","type":"Location","offset":4,"length":10,"score":0.83}]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"1","entities":[{"text":"park","category":"Location","subcategory":"LOCATION.STRUCTURAL","offset":17,"length":4,"confidenceScore":0.83}],"warnings":[]},{"id":"2","entities":[{"text":"hotel","category":"Location","offset":19,"length":5,"confidenceScore":0.75}],"warnings":[]},{"id":"3","entities":[{"text":"restaurant","category":"Location","subcategory":"LOCATION.STRUCTURAL","offset":4,"length":10,"confidenceScore":0.71}],"warnings":[]}],"errors":[],"modelVersion":"2020-04-01"}' headers: apim-request-id: - - a7b8926c-e538-40ba-8b85-41aa8a20cf0a + - c02cfe8f-03eb-42d2-b2ba-6441cbbde28f content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:07:22 GMT + - Thu, 23 Apr 2020 15:53:58 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -83,7 +83,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '47' + - '87' status: code: 200 message: OK @@ -104,22 +104,22 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: - string: '{"documents":[{"id":"1","entities":[]},{"id":"2","entities":[]},{"id":"3","entities":[]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"1","entities":[],"warnings":[]},{"id":"2","entities":[],"warnings":[]},{"id":"3","entities":[],"warnings":[]}],"errors":[],"modelVersion":"2020-04-01"}' headers: apim-request-id: - - 41636e3f-2114-42d2-91fd-966e7ab881c5 + - 327ebd52-f744-4eba-92dc-99f2a4418496 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:07:22 GMT + - Thu, 23 Apr 2020 15:53:58 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -127,7 +127,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '11' + - '16' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_document_attribute_error_no_result_attribute.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_document_attribute_error_no_result_attribute.yaml index c70c5c17bcdc..8984fe9bf0a9 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_document_attribute_error_no_result_attribute.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_document_attribute_error_no_result_attribute.yaml @@ -13,22 +13,22 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: string: '{"documents":[],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document - text is empty."}}}],"modelVersion":"2020-02-01"}' + document in request.","innererror":{"code":"InvalidDocument","message":"Document + text is empty."}}}],"modelVersion":"2020-04-01"}' headers: apim-request-id: - - 3c7e7387-b634-45ca-a470-2e5853745232 + - f2b8c563-cae0-4a84-a35a-859cdc1e1878 content-type: - application/json; charset=utf-8 date: - - Thu, 02 Apr 2020 15:07:23 GMT + - Thu, 23 Apr 2020 15:53:59 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -36,7 +36,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '2' + - '1' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_document_attribute_error_nonexistent_attribute.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_document_attribute_error_nonexistent_attribute.yaml index 7b43960597f6..57ad59230d70 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_document_attribute_error_nonexistent_attribute.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_document_attribute_error_nonexistent_attribute.yaml @@ -13,22 +13,22 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: string: '{"documents":[],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document - text is empty."}}}],"modelVersion":"2020-02-01"}' + document in request.","innererror":{"code":"InvalidDocument","message":"Document + text is empty."}}}],"modelVersion":"2020-04-01"}' headers: apim-request-id: - - 10a9f81e-15ae-4045-b90e-9312e9e4d738 + - 0d255538-3c82-4c4f-9209-3d96fa127f7e content-type: - application/json; charset=utf-8 date: - - Thu, 02 Apr 2020 15:07:23 GMT + - Thu, 23 Apr 2020 15:53:59 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_document_errors.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_document_errors.yaml index 6f352a43957d..e98fb855e97d 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_document_errors.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_document_errors.yaml @@ -16,28 +16,28 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: string: '{"documents":[],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}},{"id":"2","error":{"code":"InvalidArgument","message":"Invalid - Language Code.","innerError":{"code":"UnsupportedLanguageCode","message":"Supplied + Language Code.","innererror":{"code":"UnsupportedLanguageCode","message":"Supplied language not supported. Pass in one of: ar,cs,da,de,en,es,fi,fr,hu,it,ja,ko,nl,no,pl,pt-BR,pt-PT,ru,sv,tr,zh-Hans"}}},{"id":"3","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"A + document in request.","innererror":{"code":"InvalidDocument","message":"A document within the request was too large to be processed. Limit document size to: 5120 text elements. For additional details on the data limitations - see https://aka.ms/text-analytics-data-limits"}}}],"modelVersion":"2020-02-01"}' + see https://aka.ms/text-analytics-data-limits"}}}],"modelVersion":"2020-04-01"}' headers: apim-request-id: - - aed9d2db-b6f5-4aec-89b1-51fe5c3c33ad + - 1223cbe6-2468-4491-a3d2-e0c188167096 content-type: - application/json; charset=utf-8 date: - - Thu, 02 Apr 2020 15:07:23 GMT + - Thu, 23 Apr 2020 15:53:59 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -45,7 +45,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '3' + - '2' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_duplicate_ids_error.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_duplicate_ids_error.yaml index 1e5e10af82e6..bed35ea12d23 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_duplicate_ids_error.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_duplicate_ids_error.yaml @@ -14,21 +14,21 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: - string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innerError":{"code":"InvalidDocument","message":"Request + string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innererror":{"code":"InvalidDocument","message":"Request contains duplicated Ids. Make sure each document has a unique Id."}}}' headers: apim-request-id: - - fd64962e-3fea-4928-be94-ade99c15b321 + - 2a2f1f32-cdfe-4d4c-ba97-3b1c428570b5 content-type: - application/json; charset=utf-8 date: - - Thu, 02 Apr 2020 15:07:24 GMT + - Thu, 23 Apr 2020 15:53:59 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -36,7 +36,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '5' + - '6' status: code: 400 message: Bad Request diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_empty_credential_class.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_empty_credential_class.yaml index be5bdd738272..27f986dc5dc3 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_empty_credential_class.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_empty_credential_class.yaml @@ -14,21 +14,31 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: - string: '{"error":{"code":"401","message":"Access denied due to invalid subscription + string: '{"error":{"code":"401","message": "Access denied due to invalid subscription key or wrong API endpoint. Make sure to provide a valid key for an active subscription and use a correct regional API endpoint for your resource."}}' headers: + apim-request-id: + - f72fc7f6-c511-4f0d-aec1-1e4a85968076 content-length: - - '224' + - '225' + content-type: + - application/json date: - - Thu, 02 Apr 2020 15:07:24 GMT + - Thu, 23 Apr 2020 15:54:00 GMT + strict-transport-security: + - max-age=31536000; includeSubDomains; preload + www-authenticate: + - AzureApiManagementKey realm="https://westus2.ppe.cognitiveservices.azure.com/text/analytics",name="Ocp-Apim-Subscription-Key",type="header" + x-content-type-options: + - nosniff status: code: 401 - message: PermissionDenied + message: Access Denied version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_input_with_all_errors.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_input_with_all_errors.yaml index d964ab0290e4..840d7dbd95d9 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_input_with_all_errors.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_input_with_all_errors.yaml @@ -14,26 +14,26 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: string: '{"documents":[],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}},{"id":"2","error":{"code":"InvalidArgument","message":"Invalid - Language Code.","innerError":{"code":"UnsupportedLanguageCode","message":"Supplied + Language Code.","innererror":{"code":"UnsupportedLanguageCode","message":"Supplied language not supported. Pass in one of: ar,cs,da,de,en,es,fi,fr,hu,it,ja,ko,nl,no,pl,pt-BR,pt-PT,ru,sv,tr,zh-Hans"}}},{"id":"3","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document - text is empty."}}}],"modelVersion":"2020-02-01"}' + document in request.","innererror":{"code":"InvalidDocument","message":"Document + text is empty."}}}],"modelVersion":"2020-04-01"}' headers: apim-request-id: - - 6ff880b1-40be-479d-b097-99fc08874006 + - e34a5f66-0ffc-4655-8d1b-f56132e0895b content-type: - application/json; charset=utf-8 date: - - Thu, 02 Apr 2020 15:07:25 GMT + - Thu, 23 Apr 2020 15:54:01 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -41,7 +41,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '3' + - '2' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_input_with_some_errors.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_input_with_some_errors.yaml index d7e4cd7d945c..09d08f328061 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_input_with_some_errors.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_input_with_some_errors.yaml @@ -15,29 +15,29 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: - string: '{"documents":[{"id":"1","entities":[{"text":"Microsoft","type":"Organization","offset":0,"length":9,"score":1.0},{"text":"Bill - Gates","type":"Person","offset":25,"length":10,"score":0.67},{"text":"Paul - Allen","type":"Person","offset":40,"length":10,"score":0.81},{"text":"April - 4, 1975","type":"DateTime","subtype":"Date","offset":54,"length":13,"score":0.8}]}],"errors":[{"id":"2","error":{"code":"InvalidArgument","message":"Invalid - Language Code.","innerError":{"code":"UnsupportedLanguageCode","message":"Supplied + string: '{"documents":[{"id":"1","entities":[{"text":"Microsoft","category":"Organization","offset":0,"length":9,"confidenceScore":0.49},{"text":"Bill + Gates","category":"Person","offset":25,"length":10,"confidenceScore":0.47},{"text":"Paul + Allen","category":"Person","offset":40,"length":10,"confidenceScore":0.69},{"text":"April + 4, 1975","category":"DateTime","subcategory":"Date","offset":54,"length":13,"confidenceScore":0.8}],"warnings":[]}],"errors":[{"id":"2","error":{"code":"InvalidArgument","message":"Invalid + Language Code.","innererror":{"code":"UnsupportedLanguageCode","message":"Supplied language not supported. Pass in one of: ar,cs,da,de,en,es,fi,fr,hu,it,ja,ko,nl,no,pl,pt-BR,pt-PT,ru,sv,tr,zh-Hans"}}},{"id":"3","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document - text is empty."}}}],"modelVersion":"2020-02-01"}' + document in request.","innererror":{"code":"InvalidDocument","message":"Document + text is empty."}}}],"modelVersion":"2020-04-01"}' headers: apim-request-id: - - bcd28325-ceec-47eb-b1a4-34d31f6e4a47 + - d3f88045-0d97-443c-a0c9-79a1bd369ce7 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=1 date: - - Thu, 02 Apr 2020 15:07:25 GMT + - Thu, 23 Apr 2020 15:54:00 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -45,7 +45,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '53' + - '85' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_language_kwarg_spanish.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_language_kwarg_spanish.yaml index 52243e1814ca..707e9a4b2f7a 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_language_kwarg_spanish.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_language_kwarg_spanish.yaml @@ -14,23 +14,22 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?model-version=latest&showStats=true + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?model-version=latest&showStats=true response: body: - string: '{"statistics":{"documentsCount":1,"validDocumentsCount":1,"erroneousDocumentsCount":0,"transactionsCount":1},"documents":[{"id":"0","statistics":{"charactersCount":35,"transactionsCount":1},"entities":[{"text":"Bill - Gates","type":"Person","offset":0,"length":10,"score":0.8},{"text":"Microsoft","type":"Organization","offset":25,"length":9,"score":0.98}]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"statistics":{"documentsCount":1,"validDocumentsCount":1,"erroneousDocumentsCount":0,"transactionsCount":1},"documents":[{"id":"0","statistics":{"charactersCount":35,"transactionsCount":1},"entities":[],"warnings":[]}],"errors":[],"modelVersion":"2020-04-01"}' headers: apim-request-id: - - 197567be-b542-4538-8a76-5d098b5ed384 + - eb6d790a-0d3d-49a6-a8c6-6758faf14117 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=1 date: - - Thu, 02 Apr 2020 15:07:26 GMT + - Thu, 23 Apr 2020 15:54:01 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -38,7 +37,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '12' + - '14' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_missing_input_records_error.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_missing_input_records_error.yaml deleted file mode 100644 index 59adad475e3d..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_missing_input_records_error.yaml +++ /dev/null @@ -1,42 +0,0 @@ -interactions: -- request: - body: '{"documents": []}' - headers: - Accept: - - application/json - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '17' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false - response: - body: - string: '{"error":{"code":"InvalidRequest","message":"Invalid Request.","innerError":{"code":"MissingInputRecords","message":"Missing - input records."}}}' - headers: - apim-request-id: - - 74501eb5-1fad-4381-bcf1-dc092c80e858 - content-type: - - application/json; charset=utf-8 - date: - - Thu, 02 Apr 2020 15:07:26 GMT - strict-transport-security: - - max-age=31536000; includeSubDomains; preload - transfer-encoding: - - chunked - x-content-type-options: - - nosniff - x-envoy-upstream-service-time: - - '4' - status: - code: 400 - message: Bad Request -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_out_of_order_ids.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_out_of_order_ids.yaml index 77d92e00e911..39dc25bee542 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_out_of_order_ids.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_out_of_order_ids.yaml @@ -16,24 +16,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: - string: '{"documents":[{"id":"56","entities":[]},{"id":"0","entities":[]},{"id":"19","entities":[]},{"id":"1","entities":[]}],"errors":[{"id":"22","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document - text is empty."}}}],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"56","entities":[],"warnings":[]},{"id":"0","entities":[],"warnings":[]},{"id":"19","entities":[],"warnings":[]},{"id":"1","entities":[],"warnings":[]}],"errors":[{"id":"22","error":{"code":"InvalidArgument","message":"Invalid + document in request.","innererror":{"code":"InvalidDocument","message":"Document + text is empty."}}}],"modelVersion":"2020-04-01"}' headers: apim-request-id: - - 077444ac-ba74-4f41-8c79-ec15529a2991 + - 03890bc4-8935-4706-be86-dc9966bb7303 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=4 date: - - Thu, 02 Apr 2020 15:07:27 GMT + - Thu, 23 Apr 2020 15:54:02 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -41,7 +41,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '49' + - '61' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_pass_cls.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_pass_cls.yaml index 4c2b6ca999b1..af345adf8e3d 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_pass_cls.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_pass_cls.yaml @@ -14,22 +14,22 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: - string: '{"documents":[{"id":"0","entities":[{"text":"cls","type":"Skill","offset":13,"length":3,"score":0.8}]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"0","entities":[],"warnings":[]}],"errors":[],"modelVersion":"2020-04-01"}' headers: apim-request-id: - - de4358ce-b5b3-46b6-872b-a7aead30d4a6 + - bb6291de-7d1c-4a05-95e3-04210383ebc6 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=1 date: - - Thu, 02 Apr 2020 15:07:27 GMT + - Thu, 23 Apr 2020 15:54:02 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -37,7 +37,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '42' + - '62' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_passing_only_string.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_passing_only_string.yaml index 2d34317ad835..7b71bbe2aa5c 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_passing_only_string.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_passing_only_string.yaml @@ -18,43 +18,42 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: string: "{\"documents\":[{\"id\":\"0\",\"entities\":[{\"text\":\"Microsoft\"\ - ,\"type\":\"Organization\",\"offset\":0,\"length\":9,\"score\":1.0},{\"text\"\ - :\"Bill Gates\",\"type\":\"Person\",\"offset\":25,\"length\":10,\"score\"\ - :0.67},{\"text\":\"Paul Allen\",\"type\":\"Person\",\"offset\":40,\"length\"\ - :10,\"score\":0.81},{\"text\":\"April 4, 1975\",\"type\":\"DateTime\",\"subtype\"\ - :\"Date\",\"offset\":54,\"length\":13,\"score\":0.8}]},{\"id\":\"1\",\"entities\"\ - :[{\"text\":\"Microsoft\",\"type\":\"Organization\",\"offset\":0,\"length\"\ - :9,\"score\":1.0},{\"text\":\"Bill Gates\",\"type\":\"Person\",\"offset\"\ - :26,\"length\":10,\"score\":0.45},{\"text\":\"Paul Allen\",\"type\":\"Person\"\ - ,\"offset\":39,\"length\":10,\"score\":0.69},{\"text\":\"4\",\"type\":\"Quantity\"\ - ,\"subtype\":\"Number\",\"offset\":53,\"length\":1,\"score\":0.8},{\"text\"\ - :\"1975\",\"type\":\"DateTime\",\"subtype\":\"DateRange\",\"offset\":67,\"\ - length\":4,\"score\":0.8}]},{\"id\":\"2\",\"entities\":[{\"text\":\"Microsoft\"\ - ,\"type\":\"Organization\",\"offset\":0,\"length\":9,\"score\":1.0},{\"text\"\ - :\"4\",\"type\":\"Quantity\",\"subtype\":\"Number\",\"offset\":19,\"length\"\ - :1,\"score\":0.8},{\"text\":\"April 1975\",\"type\":\"DateTime\",\"subtype\"\ - :\"DateRange\",\"offset\":22,\"length\":10,\"score\":0.8},{\"text\":\"Paul\ - \ Allen gegr\xFCndet\",\"type\":\"Person\",\"offset\":52,\"length\":20,\"\ - score\":0.47}]}],\"errors\":[{\"id\":\"3\",\"error\":{\"code\":\"InvalidArgument\"\ - ,\"message\":\"Invalid document in request.\",\"innerError\":{\"code\":\"\ - InvalidDocument\",\"message\":\"Document text is empty.\"}}}],\"modelVersion\"\ - :\"2020-02-01\"}" + ,\"category\":\"Organization\",\"offset\":0,\"length\":9,\"confidenceScore\"\ + :0.5},{\"text\":\"Bill Gates\",\"category\":\"Person\",\"offset\":25,\"length\"\ + :10,\"confidenceScore\":0.47},{\"text\":\"Paul Allen\",\"category\":\"Person\"\ + ,\"offset\":40,\"length\":10,\"confidenceScore\":0.7},{\"text\":\"April 4,\ + \ 1975\",\"category\":\"DateTime\",\"subcategory\":\"Date\",\"offset\":54,\"\ + length\":13,\"confidenceScore\":0.8}],\"warnings\":[]},{\"id\":\"1\",\"entities\"\ + :[{\"text\":\"4\",\"category\":\"Quantity\",\"subcategory\":\"Number\",\"\ + offset\":53,\"length\":1,\"confidenceScore\":0.8},{\"text\":\"1975\",\"category\"\ + :\"DateTime\",\"subcategory\":\"DateRange\",\"offset\":67,\"length\":4,\"\ + confidenceScore\":0.8}],\"warnings\":[]},{\"id\":\"2\",\"entities\":[{\"text\"\ + :\"Microsoft\",\"category\":\"Organization\",\"offset\":0,\"length\":9,\"\ + confidenceScore\":0.33},{\"text\":\"4\",\"category\":\"Quantity\",\"subcategory\"\ + :\"Number\",\"offset\":19,\"length\":1,\"confidenceScore\":0.8},{\"text\"\ + :\"April 1975\",\"category\":\"DateTime\",\"subcategory\":\"DateRange\",\"\ + offset\":22,\"length\":10,\"confidenceScore\":0.8},{\"text\":\"von Bill Gates\ + \ und Paul Allen gegr\xFCndet\",\"category\":\"Person\",\"offset\":33,\"length\"\ + :39,\"confidenceScore\":0.52}],\"warnings\":[]}],\"errors\":[{\"id\":\"3\"\ + ,\"error\":{\"code\":\"InvalidArgument\",\"message\":\"Invalid document in\ + \ request.\",\"innererror\":{\"code\":\"InvalidDocument\",\"message\":\"Document\ + \ text is empty.\"}}}],\"modelVersion\":\"2020-04-01\"}" headers: apim-request-id: - - e6769828-fff2-40d0-bc0c-af6e9f4c544f + - 658fac52-9a0b-4647-bf02-b93c5511c7cc content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:07:27 GMT + - Thu, 23 Apr 2020 15:54:02 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -62,7 +61,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '90' + - '122' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_per_item_dont_use_language_hint.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_per_item_dont_use_language_hint.yaml index 88f97f10b302..80e7cf220037 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_per_item_dont_use_language_hint.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_per_item_dont_use_language_hint.yaml @@ -16,22 +16,22 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: - string: '{"documents":[{"id":"1","entities":[{"text":"park","type":"Location","offset":17,"length":4,"score":0.73}]},{"id":"2","entities":[{"text":"hotel","type":"Location","offset":19,"length":5,"score":0.75}]},{"id":"3","entities":[{"text":"restaurant","type":"Location","offset":4,"length":10,"score":0.83}]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"1","entities":[{"text":"park","category":"Location","subcategory":"LOCATION.STRUCTURAL","offset":17,"length":4,"confidenceScore":0.83}],"warnings":[]},{"id":"2","entities":[{"text":"hotel","category":"Location","offset":19,"length":5,"confidenceScore":0.75}],"warnings":[]},{"id":"3","entities":[{"text":"restaurant","category":"Location","subcategory":"LOCATION.STRUCTURAL","offset":4,"length":10,"confidenceScore":0.71}],"warnings":[]}],"errors":[],"modelVersion":"2020-04-01"}' headers: apim-request-id: - - 414c2bd2-69da-4eb6-8276-604ffc35cc1f + - 5ec301df-567e-4d79-a495-30421681274d content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:07:28 GMT + - Thu, 23 Apr 2020 15:54:03 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -39,7 +39,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '61' + - '87' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_rotate_subscription_key.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_rotate_subscription_key.yaml index d77d9df180b3..425ba90836f3 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_rotate_subscription_key.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_rotate_subscription_key.yaml @@ -16,22 +16,22 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: - string: '{"documents":[{"id":"1","entities":[{"text":"park","type":"Location","offset":17,"length":4,"score":0.73}]},{"id":"2","entities":[{"text":"hotel","type":"Location","offset":19,"length":5,"score":0.75}]},{"id":"3","entities":[{"text":"restaurant","type":"Location","offset":4,"length":10,"score":0.83}]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"1","entities":[{"text":"park","category":"Location","subcategory":"LOCATION.STRUCTURAL","offset":17,"length":4,"confidenceScore":0.83}],"warnings":[]},{"id":"2","entities":[{"text":"hotel","category":"Location","offset":19,"length":5,"confidenceScore":0.75}],"warnings":[]},{"id":"3","entities":[{"text":"restaurant","category":"Location","subcategory":"LOCATION.STRUCTURAL","offset":4,"length":10,"confidenceScore":0.71}],"warnings":[]}],"errors":[],"modelVersion":"2020-04-01"}' headers: apim-request-id: - - 362c0399-3809-4bb0-8b61-28df9c775401 + - 25863ce9-d015-43fb-b461-11528b3a8e09 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:07:28 GMT + - Thu, 23 Apr 2020 15:54:03 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -39,7 +39,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '52' + - '87' status: code: 200 message: OK @@ -60,23 +60,33 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: - string: '{"error":{"code":"401","message":"Access denied due to invalid subscription + string: '{"error":{"code":"401","message": "Access denied due to invalid subscription key or wrong API endpoint. Make sure to provide a valid key for an active subscription and use a correct regional API endpoint for your resource."}}' headers: + apim-request-id: + - a97d11c7-a0a7-4284-940e-7350c40fa40f content-length: - - '224' + - '225' + content-type: + - application/json date: - - Thu, 02 Apr 2020 15:07:28 GMT + - Thu, 23 Apr 2020 15:54:03 GMT + strict-transport-security: + - max-age=31536000; includeSubDomains; preload + www-authenticate: + - AzureApiManagementKey realm="https://westus2.ppe.cognitiveservices.azure.com/text/analytics",name="Ocp-Apim-Subscription-Key",type="header" + x-content-type-options: + - nosniff status: code: 401 - message: PermissionDenied + message: Access Denied - request: body: '{"documents": [{"id": "1", "text": "I will go to the park.", "language": "en"}, {"id": "2", "text": "I did not like the hotel we stayed at.", "language": @@ -94,22 +104,22 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: - string: '{"documents":[{"id":"1","entities":[{"text":"park","type":"Location","offset":17,"length":4,"score":0.73}]},{"id":"2","entities":[{"text":"hotel","type":"Location","offset":19,"length":5,"score":0.75}]},{"id":"3","entities":[{"text":"restaurant","type":"Location","offset":4,"length":10,"score":0.83}]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"1","entities":[{"text":"park","category":"Location","subcategory":"LOCATION.STRUCTURAL","offset":17,"length":4,"confidenceScore":0.83}],"warnings":[]},{"id":"2","entities":[{"text":"hotel","category":"Location","offset":19,"length":5,"confidenceScore":0.75}],"warnings":[]},{"id":"3","entities":[{"text":"restaurant","category":"Location","subcategory":"LOCATION.STRUCTURAL","offset":4,"length":10,"confidenceScore":0.71}],"warnings":[]}],"errors":[],"modelVersion":"2020-04-01"}' headers: apim-request-id: - - 7074a093-2d15-42ae-aaa4-3f24271f8bbd + - d86a3f2c-e113-4dc3-a3cb-12acc186dba3 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:07:28 GMT + - Thu, 23 Apr 2020 15:54:03 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -117,7 +127,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '50' + - '84' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_show_stats_and_model_version.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_show_stats_and_model_version.yaml index 558aecf2403c..095145b0887e 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_show_stats_and_model_version.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_show_stats_and_model_version.yaml @@ -16,24 +16,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?model-version=latest&showStats=true + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?model-version=latest&showStats=true response: body: - string: '{"statistics":{"documentsCount":5,"validDocumentsCount":4,"erroneousDocumentsCount":1,"transactionsCount":4},"documents":[{"id":"56","statistics":{"charactersCount":2,"transactionsCount":1},"entities":[]},{"id":"0","statistics":{"charactersCount":2,"transactionsCount":1},"entities":[]},{"id":"19","statistics":{"charactersCount":2,"transactionsCount":1},"entities":[]},{"id":"1","statistics":{"charactersCount":2,"transactionsCount":1},"entities":[]}],"errors":[{"id":"22","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document - text is empty."}}}],"modelVersion":"2020-02-01"}' + string: '{"statistics":{"documentsCount":5,"validDocumentsCount":4,"erroneousDocumentsCount":1,"transactionsCount":4},"documents":[{"id":"56","statistics":{"charactersCount":2,"transactionsCount":1},"entities":[],"warnings":[]},{"id":"0","statistics":{"charactersCount":2,"transactionsCount":1},"entities":[],"warnings":[]},{"id":"19","statistics":{"charactersCount":2,"transactionsCount":1},"entities":[],"warnings":[]},{"id":"1","statistics":{"charactersCount":2,"transactionsCount":1},"entities":[],"warnings":[]}],"errors":[{"id":"22","error":{"code":"InvalidArgument","message":"Invalid + document in request.","innererror":{"code":"InvalidDocument","message":"Document + text is empty."}}}],"modelVersion":"2020-04-01"}' headers: apim-request-id: - - 0018ac1c-d6c5-4a61-aef6-8994ee03af63 + - f96db59e-286b-44d0-be3e-89fe150e62b2 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=4 date: - - Thu, 02 Apr 2020 15:07:30 GMT + - Thu, 23 Apr 2020 15:54:04 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -41,7 +41,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '40' + - '131' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_user_agent.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_user_agent.yaml index 14d9f2a25815..5cf5846d664d 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_user_agent.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_user_agent.yaml @@ -16,22 +16,22 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: - string: '{"documents":[{"id":"1","entities":[{"text":"park","type":"Location","offset":17,"length":4,"score":0.73}]},{"id":"2","entities":[{"text":"hotel","type":"Location","offset":19,"length":5,"score":0.75}]},{"id":"3","entities":[{"text":"restaurant","type":"Location","offset":4,"length":10,"score":0.83}]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"1","entities":[{"text":"park","category":"Location","subcategory":"LOCATION.STRUCTURAL","offset":17,"length":4,"confidenceScore":0.83}],"warnings":[]},{"id":"2","entities":[{"text":"hotel","category":"Location","offset":19,"length":5,"confidenceScore":0.75}],"warnings":[]},{"id":"3","entities":[{"text":"restaurant","category":"Location","subcategory":"LOCATION.STRUCTURAL","offset":4,"length":10,"confidenceScore":0.71}],"warnings":[]}],"errors":[],"modelVersion":"2020-04-01"}' headers: apim-request-id: - - 120d020e-ecb7-4423-80a0-3c250853b654 + - 4ac6b010-93d4-407a-b91c-7262104483cc content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:07:29 GMT + - Thu, 23 Apr 2020 15:54:05 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -39,7 +39,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '49' + - '92' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_whole_batch_dont_use_language_hint.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_whole_batch_dont_use_language_hint.yaml index ecd0e6a9fdb7..edbe93831683 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_whole_batch_dont_use_language_hint.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_whole_batch_dont_use_language_hint.yaml @@ -16,22 +16,22 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: - string: '{"documents":[{"id":"0","entities":[]},{"id":"1","entities":[{"text":"hotel","type":"Location","offset":19,"length":5,"score":0.74}]},{"id":"2","entities":[{"text":"restaurant","type":"Location","offset":4,"length":10,"score":0.83}]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"0","entities":[],"warnings":[]},{"id":"1","entities":[{"text":"hotel","category":"Location","offset":19,"length":5,"confidenceScore":0.74}],"warnings":[]},{"id":"2","entities":[{"text":"restaurant","category":"Location","subcategory":"LOCATION.STRUCTURAL","offset":4,"length":10,"confidenceScore":0.73}],"warnings":[]}],"errors":[],"modelVersion":"2020-04-01"}' headers: apim-request-id: - - 64993052-b329-4c89-a68e-4390b5410d67 + - 50b5265a-2985-41dc-b6b8-363a1f104883 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:07:30 GMT + - Thu, 23 Apr 2020 15:54:05 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -39,7 +39,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '57' + - '101' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_whole_batch_language_hint.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_whole_batch_language_hint.yaml index d6a56bde9061..efdf049807f3 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_whole_batch_language_hint.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_whole_batch_language_hint.yaml @@ -16,22 +16,22 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: - string: '{"documents":[{"id":"0","entities":[]},{"id":"1","entities":[]},{"id":"2","entities":[]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"0","entities":[],"warnings":[]},{"id":"1","entities":[],"warnings":[]},{"id":"2","entities":[],"warnings":[]}],"errors":[],"modelVersion":"2020-04-01"}' headers: apim-request-id: - - bf3487a4-19ec-43fa-98ab-71004fff3f19 + - 01bf3601-c963-4d72-8ceb-b527ebb9554d content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:07:31 GMT + - Thu, 23 Apr 2020 15:54:05 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -39,7 +39,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '24' + - '32' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_whole_batch_language_hint_and_dict_per_item_hints.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_whole_batch_language_hint_and_dict_per_item_hints.yaml index 9fcf1fedc78b..01a6f66864ca 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_whole_batch_language_hint_and_dict_per_item_hints.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_whole_batch_language_hint_and_dict_per_item_hints.yaml @@ -16,22 +16,22 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: - string: '{"documents":[{"id":"1","entities":[]},{"id":"2","entities":[]},{"id":"3","entities":[{"text":"restaurant","type":"Location","offset":4,"length":10,"score":0.83}]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"1","entities":[],"warnings":[]},{"id":"2","entities":[],"warnings":[]},{"id":"3","entities":[{"text":"restaurant","category":"Location","subcategory":"LOCATION.STRUCTURAL","offset":4,"length":10,"confidenceScore":0.72}],"warnings":[]}],"errors":[],"modelVersion":"2020-04-01"}' headers: apim-request-id: - - 21e0e851-7bfb-4829-a9fa-0021edbec829 + - 5196ccc3-ce98-4eb1-a941-3e7da18d164b content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:07:30 GMT + - Thu, 23 Apr 2020 15:54:07 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -39,7 +39,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '39' + - '67' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_whole_batch_language_hint_and_obj_input.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_whole_batch_language_hint_and_obj_input.yaml index 5028ca6ffdeb..c12ee4ddcf60 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_whole_batch_language_hint_and_obj_input.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_whole_batch_language_hint_and_obj_input.yaml @@ -16,22 +16,22 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: - string: '{"documents":[{"id":"1","entities":[]},{"id":"4","entities":[]},{"id":"3","entities":[]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"1","entities":[],"warnings":[]},{"id":"4","entities":[],"warnings":[]},{"id":"3","entities":[],"warnings":[]}],"errors":[],"modelVersion":"2020-04-01"}' headers: apim-request-id: - - 075b18b8-89a3-4ffe-821f-cf916df7bf8d + - 258490a4-42c1-49f0-bcb7-2cde17d9420b content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:07:31 GMT + - Thu, 23 Apr 2020 15:54:08 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -39,7 +39,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '20' + - '16' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_whole_batch_language_hint_and_obj_per_item_hints.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_whole_batch_language_hint_and_obj_per_item_hints.yaml index b75457738364..ef9ec05480db 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_whole_batch_language_hint_and_obj_per_item_hints.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities.test_whole_batch_language_hint_and_obj_per_item_hints.yaml @@ -16,22 +16,22 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: - string: '{"documents":[{"id":"1","entities":[]},{"id":"2","entities":[{"text":"un","type":"Quantity","subtype":"Number","offset":8,"length":2,"score":0.8}]},{"id":"3","entities":[]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"1","entities":[],"warnings":[]},{"id":"2","entities":[{"text":"un","category":"Quantity","subcategory":"Number","offset":8,"length":2,"confidenceScore":0.8}],"warnings":[]},{"id":"3","entities":[],"warnings":[]}],"errors":[],"modelVersion":"2020-04-01"}' headers: apim-request-id: - - dbd2f899-1cd6-465f-b80b-47a70e4ac100 + - 97e23c09-2f5e-43cd-ac92-e3fe418e96a2 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:07:31 GMT + - Thu, 23 Apr 2020 15:54:08 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -39,7 +39,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '29' + - '50' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_all_successful_passing_dict.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_all_successful_passing_dict.yaml index f2ba43b30c87..6ec62cbd706a 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_all_successful_passing_dict.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_all_successful_passing_dict.yaml @@ -15,30 +15,30 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=true + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=true response: body: string: '{"statistics":{"documentsCount":2,"validDocumentsCount":2,"erroneousDocumentsCount":0,"transactionsCount":2},"documents":[{"id":"1","statistics":{"charactersCount":50,"transactionsCount":1},"entities":[{"name":"Bill - Gates","matches":[{"text":"Bill Gates","offset":25,"length":10,"score":0.0}],"language":"en","id":"Bill + Gates","matches":[{"text":"Bill Gates","offset":25,"length":10,"confidenceScore":0.0}],"language":"en","id":"Bill Gates","url":"https://en.wikipedia.org/wiki/Bill_Gates","dataSource":"Wikipedia"},{"name":"Paul - Allen","matches":[{"text":"Paul Allen","offset":40,"length":10,"score":0.0}],"language":"en","id":"Paul - Allen","url":"https://en.wikipedia.org/wiki/Paul_Allen","dataSource":"Wikipedia"},{"name":"Microsoft","matches":[{"text":"Microsoft","offset":0,"length":9,"score":0.0}],"language":"en","id":"Microsoft","url":"https://en.wikipedia.org/wiki/Microsoft","dataSource":"Wikipedia"}]},{"id":"2","statistics":{"charactersCount":49,"transactionsCount":1},"entities":[{"name":"Bill - Gates","matches":[{"text":"Bill Gates","offset":26,"length":10,"score":0.0}],"language":"es","id":"Bill + Allen","matches":[{"text":"Paul Allen","offset":40,"length":10,"confidenceScore":0.0}],"language":"en","id":"Paul + Allen","url":"https://en.wikipedia.org/wiki/Paul_Allen","dataSource":"Wikipedia"},{"name":"Microsoft","matches":[{"text":"Microsoft","offset":0,"length":9,"confidenceScore":0.0}],"language":"en","id":"Microsoft","url":"https://en.wikipedia.org/wiki/Microsoft","dataSource":"Wikipedia"}],"warnings":[]},{"id":"2","statistics":{"charactersCount":49,"transactionsCount":1},"entities":[{"name":"Bill + Gates","matches":[{"text":"Bill Gates","offset":26,"length":10,"confidenceScore":0.0}],"language":"es","id":"Bill Gates","url":"https://es.wikipedia.org/wiki/Bill_Gates","dataSource":"Wikipedia"},{"name":"Paul - Allen","matches":[{"text":"Paul Allen","offset":39,"length":10,"score":0.0}],"language":"es","id":"Paul - Allen","url":"https://es.wikipedia.org/wiki/Paul_Allen","dataSource":"Wikipedia"},{"name":"Microsoft","matches":[{"text":"Microsoft","offset":0,"length":9,"score":0.0}],"language":"es","id":"Microsoft","url":"https://es.wikipedia.org/wiki/Microsoft","dataSource":"Wikipedia"}]}],"errors":[],"modelVersion":"2020-02-01"}' + Allen","matches":[{"text":"Paul Allen","offset":39,"length":10,"confidenceScore":0.0}],"language":"es","id":"Paul + Allen","url":"https://es.wikipedia.org/wiki/Paul_Allen","dataSource":"Wikipedia"},{"name":"Microsoft","matches":[{"text":"Microsoft","offset":0,"length":9,"confidenceScore":0.0}],"language":"es","id":"Microsoft","url":"https://es.wikipedia.org/wiki/Microsoft","dataSource":"Wikipedia"}],"warnings":[]}],"errors":[],"modelVersion":"2020-02-01"}' headers: apim-request-id: - - d875e5b5-4d21-47cc-a653-2ef83691ff58 + - eb1e6310-65c2-4d6c-9112-f2b56796f6c8 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=2 date: - - Thu, 02 Apr 2020 15:07:46 GMT + - Thu, 23 Apr 2020 15:56:00 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -46,7 +46,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '18' + - '22' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_all_successful_passing_text_document_input.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_all_successful_passing_text_document_input.yaml index 937fbdc85d37..61518b3284fa 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_all_successful_passing_text_document_input.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_all_successful_passing_text_document_input.yaml @@ -15,29 +15,30 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: string: '{"documents":[{"id":"1","entities":[{"name":"Bill Gates","matches":[{"text":"Bill - Gates","offset":25,"length":10,"score":0.0}],"language":"en","id":"Bill Gates","url":"https://en.wikipedia.org/wiki/Bill_Gates","dataSource":"Wikipedia"},{"name":"Paul - Allen","matches":[{"text":"Paul Allen","offset":40,"length":10,"score":0.0}],"language":"en","id":"Paul - Allen","url":"https://en.wikipedia.org/wiki/Paul_Allen","dataSource":"Wikipedia"},{"name":"Microsoft","matches":[{"text":"Microsoft","offset":0,"length":9,"score":0.0}],"language":"en","id":"Microsoft","url":"https://en.wikipedia.org/wiki/Microsoft","dataSource":"Wikipedia"}]},{"id":"2","entities":[{"name":"Bill - Gates","matches":[{"text":"Bill Gates","offset":26,"length":10,"score":0.0}],"language":"en","id":"Bill + Gates","offset":25,"length":10,"confidenceScore":0.0}],"language":"en","id":"Bill Gates","url":"https://en.wikipedia.org/wiki/Bill_Gates","dataSource":"Wikipedia"},{"name":"Paul - Allen","matches":[{"text":"Paul Allen","offset":39,"length":10,"score":0.0}],"language":"en","id":"Paul - Allen","url":"https://en.wikipedia.org/wiki/Paul_Allen","dataSource":"Wikipedia"},{"name":"Microsoft","matches":[{"text":"Microsoft","offset":0,"length":9,"score":0.0}],"language":"en","id":"Microsoft","url":"https://en.wikipedia.org/wiki/Microsoft","dataSource":"Wikipedia"}]}],"errors":[],"modelVersion":"2020-02-01"}' + Allen","matches":[{"text":"Paul Allen","offset":40,"length":10,"confidenceScore":0.0}],"language":"en","id":"Paul + Allen","url":"https://en.wikipedia.org/wiki/Paul_Allen","dataSource":"Wikipedia"},{"name":"Microsoft","matches":[{"text":"Microsoft","offset":0,"length":9,"confidenceScore":0.0}],"language":"en","id":"Microsoft","url":"https://en.wikipedia.org/wiki/Microsoft","dataSource":"Wikipedia"}],"warnings":[]},{"id":"2","entities":[{"name":"Bill + Gates","matches":[{"text":"Bill Gates","offset":26,"length":10,"confidenceScore":0.0}],"language":"en","id":"Bill + Gates","url":"https://en.wikipedia.org/wiki/Bill_Gates","dataSource":"Wikipedia"},{"name":"Paul + Allen","matches":[{"text":"Paul Allen","offset":39,"length":10,"confidenceScore":0.0}],"language":"en","id":"Paul + Allen","url":"https://en.wikipedia.org/wiki/Paul_Allen","dataSource":"Wikipedia"},{"name":"Microsoft","matches":[{"text":"Microsoft","offset":0,"length":9,"confidenceScore":0.0}],"language":"en","id":"Microsoft","url":"https://en.wikipedia.org/wiki/Microsoft","dataSource":"Wikipedia"}],"warnings":[]}],"errors":[],"modelVersion":"2020-02-01"}' headers: apim-request-id: - - f482e55e-5a0f-4e2b-b321-760798a5036f + - 35855ef8-6198-4049-9f6e-abb6337d6f18 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=2 date: - - Thu, 02 Apr 2020 15:07:46 GMT + - Thu, 23 Apr 2020 15:56:01 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -45,7 +46,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '18' + - '19' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_bad_credentials.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_bad_credentials.yaml index 04388796249e..5306ce903776 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_bad_credentials.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_bad_credentials.yaml @@ -14,21 +14,31 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: - string: '{"error":{"code":"401","message":"Access denied due to invalid subscription + string: '{"error":{"code":"401","message": "Access denied due to invalid subscription key or wrong API endpoint. Make sure to provide a valid key for an active subscription and use a correct regional API endpoint for your resource."}}' headers: + apim-request-id: + - cb43908b-0cd8-4378-9617-0bc244ada2ac content-length: - - '224' + - '225' + content-type: + - application/json date: - - Thu, 02 Apr 2020 15:07:46 GMT + - Thu, 23 Apr 2020 15:56:00 GMT + strict-transport-security: + - max-age=31536000; includeSubDomains; preload + www-authenticate: + - AzureApiManagementKey realm="https://westus2.ppe.cognitiveservices.azure.com/text/analytics",name="Ocp-Apim-Subscription-Key",type="header" + x-content-type-options: + - nosniff status: code: 401 - message: PermissionDenied + message: Access Denied version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_bad_model_version.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_bad_model_version.yaml index a3bfadc30adc..82898180d8da 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_bad_model_version.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_bad_model_version.yaml @@ -14,21 +14,21 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?model-version=old&showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?model-version=old&showStats=false response: body: string: '{"error":{"code":"InvalidRequest","message":"Specified Model version - is incorrect. Allowed values are latest,2019-10-01,2020-02-01"}}' + is incorrect. Allowed values are latest,2020-02-01"}}' headers: apim-request-id: - - e8dcdd30-1a24-45e2-a7b6-eaaa444f9035 + - 5ea79c41-52b9-4b32-a835-9aaf1366f81a content-type: - application/json; charset=utf-8 date: - - Thu, 02 Apr 2020 15:07:47 GMT + - Thu, 23 Apr 2020 15:56:01 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -36,7 +36,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '5' + - '4' status: code: 400 message: Bad Request diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_bad_model_version_error.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_bad_model_version_error.yaml index ecb7257bbad8..532b4925fd58 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_bad_model_version_error.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_bad_model_version_error.yaml @@ -14,21 +14,21 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?model-version=bad&showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?model-version=bad&showStats=false response: body: string: '{"error":{"code":"InvalidRequest","message":"Specified Model version - is incorrect. Allowed values are latest,2019-10-01,2020-02-01"}}' + is incorrect. Allowed values are latest,2020-02-01"}}' headers: apim-request-id: - - bc9859be-f2b1-4149-b782-a8badf5c550b + - e740fbe6-29bd-4f73-84ce-0b880bff0500 content-type: - application/json; charset=utf-8 date: - - Thu, 02 Apr 2020 15:07:47 GMT + - Thu, 23 Apr 2020 15:56:02 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -36,7 +36,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '5' + - '3' status: code: 400 message: Bad Request diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_batch_size_over_limit.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_batch_size_over_limit.yaml index 00f973d2116a..2e897ed2f574 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_batch_size_over_limit.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_batch_size_over_limit.yaml @@ -758,21 +758,21 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: - string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innerError":{"code":"InvalidDocumentBatch","message":"Batch + string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innererror":{"code":"InvalidDocumentBatch","message":"Batch request contains too many records. Max 1000 records are permitted."}}}' headers: apim-request-id: - - 9aaba0e1-576a-4d42-bfe9-306ac8b3b091 + - 22dbc727-b4b2-4bd9-b783-839adb5790a7 content-type: - application/json; charset=utf-8 date: - - Thu, 02 Apr 2020 15:07:48 GMT + - Thu, 23 Apr 2020 15:56:03 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -780,7 +780,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '12' + - '14' status: code: 400 message: Bad Request diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_batch_size_over_limit_error.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_batch_size_over_limit_error.yaml index a1e3128c5676..65b2dd01e695 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_batch_size_over_limit_error.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_batch_size_over_limit_error.yaml @@ -723,21 +723,21 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: - string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innerError":{"code":"InvalidDocumentBatch","message":"Batch + string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innererror":{"code":"InvalidDocumentBatch","message":"Batch request contains too many records. Max 1000 records are permitted."}}}' headers: apim-request-id: - - 28c8603c-4765-4033-996e-32a1dc616c11 + - 0b337943-aa5c-4fef-89ab-604641d324df content-type: - application/json; charset=utf-8 date: - - Thu, 02 Apr 2020 15:07:49 GMT + - Thu, 23 Apr 2020 15:56:03 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -745,7 +745,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '12' + - '10' status: code: 400 message: Bad Request diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_client_passed_default_language_hint.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_client_passed_default_language_hint.yaml index 32b5438f6955..0cda1784f28a 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_client_passed_default_language_hint.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_client_passed_default_language_hint.yaml @@ -16,22 +16,22 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: - string: '{"documents":[{"id":"1","entities":[]},{"id":"2","entities":[]},{"id":"3","entities":[]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"1","entities":[],"warnings":[]},{"id":"2","entities":[],"warnings":[]},{"id":"3","entities":[],"warnings":[]}],"errors":[],"modelVersion":"2020-02-01"}' headers: apim-request-id: - - 10faa5b9-d9c3-4fa9-9476-27decc5de905 + - 9b9ed7c0-6b14-4b58-90d5-70c170bca6c9 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:07:49 GMT + - Thu, 23 Apr 2020 15:56:04 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -39,7 +39,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '10' + - '12' status: code: 200 message: OK @@ -60,22 +60,22 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: - string: '{"documents":[{"id":"1","entities":[]},{"id":"2","entities":[]},{"id":"3","entities":[]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"1","entities":[],"warnings":[]},{"id":"2","entities":[],"warnings":[]},{"id":"3","entities":[],"warnings":[]}],"errors":[],"modelVersion":"2020-02-01"}' headers: apim-request-id: - - 67c00a60-e45a-418f-a888-2b94bf4c5914 + - 6fc396e5-204c-4843-8e2e-1440a2130fa0 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:07:49 GMT + - Thu, 23 Apr 2020 15:56:04 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -83,7 +83,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '20' + - '21' status: code: 200 message: OK @@ -104,22 +104,22 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: - string: '{"documents":[{"id":"1","entities":[]},{"id":"2","entities":[]},{"id":"3","entities":[]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"1","entities":[],"warnings":[]},{"id":"2","entities":[],"warnings":[]},{"id":"3","entities":[],"warnings":[]}],"errors":[],"modelVersion":"2020-02-01"}' headers: apim-request-id: - - 834f0076-c4fc-4161-9f6b-ad9bf20a54bb + - 06d213fe-3cec-4758-b099-518afdabce74 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:07:49 GMT + - Thu, 23 Apr 2020 15:56:04 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -127,7 +127,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '12' + - '10' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_document_attribute_error_no_result_attribute.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_document_attribute_error_no_result_attribute.yaml index a68c1401cb8b..6be288d938e9 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_document_attribute_error_no_result_attribute.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_document_attribute_error_no_result_attribute.yaml @@ -13,22 +13,22 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: string: '{"documents":[],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}}],"modelVersion":"2020-02-01"}' headers: apim-request-id: - - a7c25a06-2214-4b52-8e81-30af5e2d6a51 + - 7d0cb3c2-87ba-4f96-8526-cb81fe644571 content-type: - application/json; charset=utf-8 date: - - Thu, 02 Apr 2020 15:07:49 GMT + - Thu, 23 Apr 2020 15:56:05 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -36,7 +36,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '3' + - '2' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_document_attribute_error_nonexistent_attribute.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_document_attribute_error_nonexistent_attribute.yaml index 0f654066516d..6452ee5a7a34 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_document_attribute_error_nonexistent_attribute.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_document_attribute_error_nonexistent_attribute.yaml @@ -13,22 +13,22 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: string: '{"documents":[],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}}],"modelVersion":"2020-02-01"}' headers: apim-request-id: - - 9b3647cc-11af-4be9-b7a8-6c9e4c211f46 + - f76962de-4594-4254-9075-1c90769003d7 content-type: - application/json; charset=utf-8 date: - - Thu, 02 Apr 2020 15:07:50 GMT + - Thu, 23 Apr 2020 15:56:05 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -36,7 +36,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '2' + - '1' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_document_errors.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_document_errors.yaml index 8c8c1827e0e7..ce853195c5e0 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_document_errors.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_document_errors.yaml @@ -16,28 +16,28 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: string: '{"documents":[],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}},{"id":"2","error":{"code":"InvalidArgument","message":"Invalid - Language Code.","innerError":{"code":"UnsupportedLanguageCode","message":"Supplied + Language Code.","innererror":{"code":"UnsupportedLanguageCode","message":"Supplied language not supported. Pass in one of: en,es"}}},{"id":"3","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"A + document in request.","innererror":{"code":"InvalidDocument","message":"A document within the request was too large to be processed. Limit document size to: 5120 text elements. For additional details on the data limitations see https://aka.ms/text-analytics-data-limits"}}}],"modelVersion":"2020-02-01"}' headers: apim-request-id: - - ee09efeb-4ae3-4e41-9c15-f3399e15b77b + - f6fb26df-f7e1-4b51-818c-0c7a74b67ec1 content-type: - application/json; charset=utf-8 date: - - Thu, 02 Apr 2020 15:07:51 GMT + - Thu, 23 Apr 2020 15:56:05 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -45,7 +45,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '3' + - '2' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_duplicate_ids_error.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_duplicate_ids_error.yaml index d806d2b1d66a..52b6ffb15c6f 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_duplicate_ids_error.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_duplicate_ids_error.yaml @@ -14,21 +14,21 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: - string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innerError":{"code":"InvalidDocument","message":"Request + string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innererror":{"code":"InvalidDocument","message":"Request contains duplicated Ids. Make sure each document has a unique Id."}}}' headers: apim-request-id: - - b156f974-6437-4f20-9b26-faf547df4b4e + - 869c58ce-e24e-42bb-8980-021afbc90ab1 content-type: - application/json; charset=utf-8 date: - - Thu, 02 Apr 2020 15:07:51 GMT + - Thu, 23 Apr 2020 15:56:05 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -36,7 +36,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '5' + - '4' status: code: 400 message: Bad Request diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_empty_credential_class.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_empty_credential_class.yaml index ad9d77bfc729..8e3797e4b63d 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_empty_credential_class.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_empty_credential_class.yaml @@ -14,21 +14,31 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: - string: '{"error":{"code":"401","message":"Access denied due to invalid subscription + string: '{"error":{"code":"401","message": "Access denied due to invalid subscription key or wrong API endpoint. Make sure to provide a valid key for an active subscription and use a correct regional API endpoint for your resource."}}' headers: + apim-request-id: + - cb911f8d-aeb1-48b9-a1fc-b6cc97091e58 content-length: - - '224' + - '225' + content-type: + - application/json date: - - Thu, 02 Apr 2020 15:07:52 GMT + - Thu, 23 Apr 2020 15:56:06 GMT + strict-transport-security: + - max-age=31536000; includeSubDomains; preload + www-authenticate: + - AzureApiManagementKey realm="https://westus2.ppe.cognitiveservices.azure.com/text/analytics",name="Ocp-Apim-Subscription-Key",type="header" + x-content-type-options: + - nosniff status: code: 401 - message: PermissionDenied + message: Access Denied version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_input_with_all_errors.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_input_with_all_errors.yaml index 29ca5cbb1dcb..fb8b510b2cd8 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_input_with_all_errors.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_input_with_all_errors.yaml @@ -14,24 +14,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: string: '{"documents":[],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}},{"id":"2","error":{"code":"InvalidArgument","message":"Invalid - Language Code.","innerError":{"code":"UnsupportedLanguageCode","message":"Supplied + Language Code.","innererror":{"code":"UnsupportedLanguageCode","message":"Supplied language not supported. Pass in one of: en,es"}}}],"modelVersion":"2020-02-01"}' headers: apim-request-id: - - b3e772e5-feb6-4f8f-9944-3c3b1583ee08 + - 9ab0eaa3-694a-42e9-9d8d-31a2cc2dbb48 content-type: - application/json; charset=utf-8 date: - - Thu, 02 Apr 2020 15:07:52 GMT + - Thu, 23 Apr 2020 15:56:07 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_input_with_some_errors.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_input_with_some_errors.yaml index e350f594a117..6d4650aa3bc9 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_input_with_some_errors.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_input_with_some_errors.yaml @@ -14,27 +14,28 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: string: '{"documents":[{"id":"2","entities":[{"name":"Bill Gates","matches":[{"text":"Bill - Gates","offset":26,"length":10,"score":0.0}],"language":"es","id":"Bill Gates","url":"https://es.wikipedia.org/wiki/Bill_Gates","dataSource":"Wikipedia"},{"name":"Paul - Allen","matches":[{"text":"Paul Allen","offset":39,"length":10,"score":0.0}],"language":"es","id":"Paul - Allen","url":"https://es.wikipedia.org/wiki/Paul_Allen","dataSource":"Wikipedia"},{"name":"Microsoft","matches":[{"text":"Microsoft","offset":0,"length":9,"score":0.0}],"language":"es","id":"Microsoft","url":"https://es.wikipedia.org/wiki/Microsoft","dataSource":"Wikipedia"}]}],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + Gates","offset":26,"length":10,"confidenceScore":0.0}],"language":"es","id":"Bill + Gates","url":"https://es.wikipedia.org/wiki/Bill_Gates","dataSource":"Wikipedia"},{"name":"Paul + Allen","matches":[{"text":"Paul Allen","offset":39,"length":10,"confidenceScore":0.0}],"language":"es","id":"Paul + Allen","url":"https://es.wikipedia.org/wiki/Paul_Allen","dataSource":"Wikipedia"},{"name":"Microsoft","matches":[{"text":"Microsoft","offset":0,"length":9,"confidenceScore":0.0}],"language":"es","id":"Microsoft","url":"https://es.wikipedia.org/wiki/Microsoft","dataSource":"Wikipedia"}],"warnings":[]}],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}}],"modelVersion":"2020-02-01"}' headers: apim-request-id: - - 83a3ea08-9dd2-4882-89e6-6fd24b8895ac + - d9125756-9a42-4887-a213-57c6b9126e76 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=1 date: - - Thu, 02 Apr 2020 15:07:52 GMT + - Thu, 23 Apr 2020 15:56:06 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -42,7 +43,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '12' + - '14' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_language_kwarg_spanish.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_language_kwarg_spanish.yaml index 0e03bb7d6ccf..896145be6fa1 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_language_kwarg_spanish.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_language_kwarg_spanish.yaml @@ -14,26 +14,26 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?model-version=latest&showStats=true + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?model-version=latest&showStats=true response: body: string: '{"statistics":{"documentsCount":1,"validDocumentsCount":1,"erroneousDocumentsCount":0,"transactionsCount":1},"documents":[{"id":"0","statistics":{"charactersCount":35,"transactionsCount":1},"entities":[{"name":"Bill - Gates","matches":[{"text":"Bill Gates","offset":0,"length":10,"score":0.0}],"language":"es","id":"Bill - Gates","url":"https://es.wikipedia.org/wiki/Bill_Gates","dataSource":"Wikipedia"},{"name":"Microsoft","matches":[{"text":"Microsoft","offset":25,"length":9,"score":0.0}],"language":"es","id":"Microsoft","url":"https://es.wikipedia.org/wiki/Microsoft","dataSource":"Wikipedia"},{"name":"Director - ejecutivo","matches":[{"text":"CEO","offset":18,"length":3,"score":0.0}],"language":"es","id":"Director - ejecutivo","url":"https://es.wikipedia.org/wiki/Director_ejecutivo","dataSource":"Wikipedia"}]}],"errors":[],"modelVersion":"2020-02-01"}' + Gates","matches":[{"text":"Bill Gates","offset":0,"length":10,"confidenceScore":0.0}],"language":"es","id":"Bill + Gates","url":"https://es.wikipedia.org/wiki/Bill_Gates","dataSource":"Wikipedia"},{"name":"Microsoft","matches":[{"text":"Microsoft","offset":25,"length":9,"confidenceScore":0.0}],"language":"es","id":"Microsoft","url":"https://es.wikipedia.org/wiki/Microsoft","dataSource":"Wikipedia"},{"name":"Director + ejecutivo","matches":[{"text":"CEO","offset":18,"length":3,"confidenceScore":0.0}],"language":"es","id":"Director + ejecutivo","url":"https://es.wikipedia.org/wiki/Director_ejecutivo","dataSource":"Wikipedia"}],"warnings":[]}],"errors":[],"modelVersion":"2020-02-01"}' headers: apim-request-id: - - 0f4ada53-2e6f-4831-a7b6-a7fd9768ae20 + - 21685082-771a-442b-881e-dc18e0feaa74 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=1 date: - - Thu, 02 Apr 2020 15:07:53 GMT + - Thu, 23 Apr 2020 15:56:07 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -41,7 +41,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '11' + - '10' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_missing_input_records_error.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_missing_input_records_error.yaml deleted file mode 100644 index e0a02fe103ae..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_missing_input_records_error.yaml +++ /dev/null @@ -1,42 +0,0 @@ -interactions: -- request: - body: '{"documents": []}' - headers: - Accept: - - application/json - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '17' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false - response: - body: - string: '{"error":{"code":"InvalidRequest","message":"Invalid Request.","innerError":{"code":"MissingInputRecords","message":"Missing - input records."}}}' - headers: - apim-request-id: - - 131ec89a-e17e-45f6-85a9-a393fdefd3d3 - content-type: - - application/json; charset=utf-8 - date: - - Thu, 02 Apr 2020 15:07:53 GMT - strict-transport-security: - - max-age=31536000; includeSubDomains; preload - transfer-encoding: - - chunked - x-content-type-options: - - nosniff - x-envoy-upstream-service-time: - - '3' - status: - code: 400 - message: Bad Request -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_out_of_order_ids.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_out_of_order_ids.yaml index 67680baa10c9..1107d35f71a9 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_out_of_order_ids.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_out_of_order_ids.yaml @@ -16,24 +16,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: - string: '{"documents":[{"id":"56","entities":[]},{"id":"0","entities":[]},{"id":"19","entities":[]},{"id":"1","entities":[]}],"errors":[{"id":"22","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + string: '{"documents":[{"id":"56","entities":[],"warnings":[]},{"id":"0","entities":[],"warnings":[]},{"id":"19","entities":[],"warnings":[]},{"id":"1","entities":[],"warnings":[]}],"errors":[{"id":"22","error":{"code":"InvalidArgument","message":"Invalid + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}}],"modelVersion":"2020-02-01"}' headers: apim-request-id: - - e9516a78-d87e-4e1d-b417-8d0ff65d4d45 + - 9d9a75f8-17c2-4371-8b69-e73174136e23 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=4 date: - - Thu, 02 Apr 2020 15:07:53 GMT + - Thu, 23 Apr 2020 15:56:08 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -41,7 +41,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '17' + - '18' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_pass_cls.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_pass_cls.yaml index 4f93111155ec..0b4ac571d3df 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_pass_cls.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_pass_cls.yaml @@ -14,22 +14,22 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: - string: '{"documents":[{"id":"0","entities":[{"name":".test","matches":[{"text":"Test","offset":0,"length":4,"score":0.0}],"language":"en","id":".test","url":"https://en.wikipedia.org/wiki/.test","dataSource":"Wikipedia"}]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"0","entities":[{"name":".test","matches":[{"text":"Test","offset":0,"length":4,"confidenceScore":0.0}],"language":"en","id":".test","url":"https://en.wikipedia.org/wiki/.test","dataSource":"Wikipedia"}],"warnings":[]}],"errors":[],"modelVersion":"2020-02-01"}' headers: apim-request-id: - - 67804baa-ad8c-4ff4-b55d-cae966ca4b94 + - fe828adf-7db9-4177-96c7-c7351a9e1406 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=1 date: - - Thu, 02 Apr 2020 15:07:54 GMT + - Thu, 23 Apr 2020 15:56:08 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -37,7 +37,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '18' + - '25' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_passing_only_string.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_passing_only_string.yaml index e965833dc7ae..f54f0a6ed7cd 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_passing_only_string.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_passing_only_string.yaml @@ -16,31 +16,32 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: string: '{"documents":[{"id":"0","entities":[{"name":"Bill Gates","matches":[{"text":"Bill - Gates","offset":25,"length":10,"score":0.0}],"language":"en","id":"Bill Gates","url":"https://en.wikipedia.org/wiki/Bill_Gates","dataSource":"Wikipedia"},{"name":"Paul - Allen","matches":[{"text":"Paul Allen","offset":40,"length":10,"score":0.0}],"language":"en","id":"Paul - Allen","url":"https://en.wikipedia.org/wiki/Paul_Allen","dataSource":"Wikipedia"},{"name":"Microsoft","matches":[{"text":"Microsoft","offset":0,"length":9,"score":0.0}],"language":"en","id":"Microsoft","url":"https://en.wikipedia.org/wiki/Microsoft","dataSource":"Wikipedia"}]},{"id":"1","entities":[{"name":"Bill - Gates","matches":[{"text":"Bill Gates","offset":26,"length":10,"score":0.0}],"language":"en","id":"Bill + Gates","offset":25,"length":10,"confidenceScore":0.0}],"language":"en","id":"Bill Gates","url":"https://en.wikipedia.org/wiki/Bill_Gates","dataSource":"Wikipedia"},{"name":"Paul - Allen","matches":[{"text":"Paul Allen","offset":39,"length":10,"score":0.0}],"language":"en","id":"Paul - Allen","url":"https://en.wikipedia.org/wiki/Paul_Allen","dataSource":"Wikipedia"},{"name":"Microsoft","matches":[{"text":"Microsoft","offset":0,"length":9,"score":0.0}],"language":"en","id":"Microsoft","url":"https://en.wikipedia.org/wiki/Microsoft","dataSource":"Wikipedia"}]}],"errors":[{"id":"2","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + Allen","matches":[{"text":"Paul Allen","offset":40,"length":10,"confidenceScore":0.0}],"language":"en","id":"Paul + Allen","url":"https://en.wikipedia.org/wiki/Paul_Allen","dataSource":"Wikipedia"},{"name":"Microsoft","matches":[{"text":"Microsoft","offset":0,"length":9,"confidenceScore":0.0}],"language":"en","id":"Microsoft","url":"https://en.wikipedia.org/wiki/Microsoft","dataSource":"Wikipedia"}],"warnings":[]},{"id":"1","entities":[{"name":"Bill + Gates","matches":[{"text":"Bill Gates","offset":26,"length":10,"confidenceScore":0.0}],"language":"en","id":"Bill + Gates","url":"https://en.wikipedia.org/wiki/Bill_Gates","dataSource":"Wikipedia"},{"name":"Paul + Allen","matches":[{"text":"Paul Allen","offset":39,"length":10,"confidenceScore":0.0}],"language":"en","id":"Paul + Allen","url":"https://en.wikipedia.org/wiki/Paul_Allen","dataSource":"Wikipedia"},{"name":"Microsoft","matches":[{"text":"Microsoft","offset":0,"length":9,"confidenceScore":0.0}],"language":"en","id":"Microsoft","url":"https://en.wikipedia.org/wiki/Microsoft","dataSource":"Wikipedia"}],"warnings":[]}],"errors":[{"id":"2","error":{"code":"InvalidArgument","message":"Invalid + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}}],"modelVersion":"2020-02-01"}' headers: apim-request-id: - - 3505a86f-f0ad-412c-aa19-53e76dfc9124 + - 88d38710-3a05-4828-ba53-ad82a4fcec4d content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=2 date: - - Thu, 02 Apr 2020 15:07:54 GMT + - Thu, 23 Apr 2020 15:56:08 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -48,7 +49,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '20' + - '21' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_per_item_dont_use_language_hint.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_per_item_dont_use_language_hint.yaml index e0db0e2295cf..397e6c57c45c 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_per_item_dont_use_language_hint.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_per_item_dont_use_language_hint.yaml @@ -16,22 +16,22 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: - string: '{"documents":[{"id":"1","entities":[]},{"id":"2","entities":[]},{"id":"3","entities":[]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"1","entities":[],"warnings":[]},{"id":"2","entities":[],"warnings":[]},{"id":"3","entities":[],"warnings":[]}],"errors":[],"modelVersion":"2020-02-01"}' headers: apim-request-id: - - 89576643-4bb2-49ea-b4d4-4bc0622d64d6 + - 14b68506-9c69-4e53-9e52-926eea320dcc content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:07:55 GMT + - Thu, 23 Apr 2020 15:56:08 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -39,7 +39,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '17' + - '21' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_rotate_subscription_key.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_rotate_subscription_key.yaml index 710a88b6706a..1864c564dd8e 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_rotate_subscription_key.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_rotate_subscription_key.yaml @@ -16,22 +16,22 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: - string: '{"documents":[{"id":"1","entities":[]},{"id":"2","entities":[]},{"id":"3","entities":[]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"1","entities":[],"warnings":[]},{"id":"2","entities":[],"warnings":[]},{"id":"3","entities":[],"warnings":[]}],"errors":[],"modelVersion":"2020-02-01"}' headers: apim-request-id: - - d43ce7db-44ff-4063-8002-5361ae1f35f0 + - 56faa3fd-a15d-411a-9816-c35c299444aa content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:07:55 GMT + - Thu, 23 Apr 2020 15:56:10 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -39,7 +39,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '23' + - '21' status: code: 200 message: OK @@ -60,23 +60,33 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: - string: '{"error":{"code":"401","message":"Access denied due to invalid subscription + string: '{"error":{"code":"401","message": "Access denied due to invalid subscription key or wrong API endpoint. Make sure to provide a valid key for an active subscription and use a correct regional API endpoint for your resource."}}' headers: + apim-request-id: + - 6bb31a35-5283-49eb-bf69-51d5bedcddec content-length: - - '224' + - '225' + content-type: + - application/json date: - - Thu, 02 Apr 2020 15:07:55 GMT + - Thu, 23 Apr 2020 15:56:10 GMT + strict-transport-security: + - max-age=31536000; includeSubDomains; preload + www-authenticate: + - AzureApiManagementKey realm="https://westus2.ppe.cognitiveservices.azure.com/text/analytics",name="Ocp-Apim-Subscription-Key",type="header" + x-content-type-options: + - nosniff status: code: 401 - message: PermissionDenied + message: Access Denied - request: body: '{"documents": [{"id": "1", "text": "I will go to the park.", "language": "en"}, {"id": "2", "text": "I did not like the hotel we stayed at.", "language": @@ -94,22 +104,22 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: - string: '{"documents":[{"id":"1","entities":[]},{"id":"2","entities":[]},{"id":"3","entities":[]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"1","entities":[],"warnings":[]},{"id":"2","entities":[],"warnings":[]},{"id":"3","entities":[],"warnings":[]}],"errors":[],"modelVersion":"2020-02-01"}' headers: apim-request-id: - - 8c8653ca-eb30-44fb-ba52-07d1ff963f3c + - f3d3dffd-63b4-43c8-b74c-d54034f0dad6 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:07:55 GMT + - Thu, 23 Apr 2020 15:56:10 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_show_stats_and_model_version.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_show_stats_and_model_version.yaml index d4b710f922ec..3a0750300113 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_show_stats_and_model_version.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_show_stats_and_model_version.yaml @@ -16,24 +16,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?model-version=latest&showStats=true + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?model-version=latest&showStats=true response: body: - string: '{"statistics":{"documentsCount":5,"validDocumentsCount":4,"erroneousDocumentsCount":1,"transactionsCount":4},"documents":[{"id":"56","statistics":{"charactersCount":2,"transactionsCount":1},"entities":[]},{"id":"0","statistics":{"charactersCount":2,"transactionsCount":1},"entities":[]},{"id":"19","statistics":{"charactersCount":2,"transactionsCount":1},"entities":[]},{"id":"1","statistics":{"charactersCount":2,"transactionsCount":1},"entities":[]}],"errors":[{"id":"22","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + string: '{"statistics":{"documentsCount":5,"validDocumentsCount":4,"erroneousDocumentsCount":1,"transactionsCount":4},"documents":[{"id":"56","statistics":{"charactersCount":2,"transactionsCount":1},"entities":[],"warnings":[]},{"id":"0","statistics":{"charactersCount":2,"transactionsCount":1},"entities":[],"warnings":[]},{"id":"19","statistics":{"charactersCount":2,"transactionsCount":1},"entities":[],"warnings":[]},{"id":"1","statistics":{"charactersCount":2,"transactionsCount":1},"entities":[],"warnings":[]}],"errors":[{"id":"22","error":{"code":"InvalidArgument","message":"Invalid + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}}],"modelVersion":"2020-02-01"}' headers: apim-request-id: - - 64ea8c4c-f908-44cb-8fe4-20926e9d83c7 + - 32760d5b-d7ea-4a40-a1e3-f3211c3aea2b content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=4 date: - - Thu, 02 Apr 2020 15:07:56 GMT + - Thu, 23 Apr 2020 15:56:10 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -41,7 +41,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '19' + - '18' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_user_agent.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_user_agent.yaml index c5da40bfa459..0e5572ca103b 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_user_agent.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_user_agent.yaml @@ -16,22 +16,22 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: - string: '{"documents":[{"id":"1","entities":[]},{"id":"2","entities":[]},{"id":"3","entities":[]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"1","entities":[],"warnings":[]},{"id":"2","entities":[],"warnings":[]},{"id":"3","entities":[],"warnings":[]}],"errors":[],"modelVersion":"2020-02-01"}' headers: apim-request-id: - - a63ab469-a9cb-4736-9132-7b135a13156b + - a8f49470-4ddd-42f5-b0fa-42f4059a54c7 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:07:56 GMT + - Thu, 23 Apr 2020 15:56:11 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_whole_batch_dont_use_language_hint.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_whole_batch_dont_use_language_hint.yaml index f17d6824fa23..fd32b73d1984 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_whole_batch_dont_use_language_hint.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_whole_batch_dont_use_language_hint.yaml @@ -16,22 +16,22 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: - string: '{"documents":[{"id":"0","entities":[]},{"id":"1","entities":[]},{"id":"2","entities":[]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"0","entities":[],"warnings":[]},{"id":"1","entities":[],"warnings":[]},{"id":"2","entities":[],"warnings":[]}],"errors":[],"modelVersion":"2020-02-01"}' headers: apim-request-id: - - dddefeb7-130d-429c-9cf5-9469debcac12 + - 33c4932d-a57a-4ffe-bad3-12ce0b3c24cb content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:07:57 GMT + - Thu, 23 Apr 2020 15:56:10 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -39,7 +39,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '21' + - '30' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_whole_batch_language_hint.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_whole_batch_language_hint.yaml index 973005852f98..d2e974e64c17 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_whole_batch_language_hint.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_whole_batch_language_hint.yaml @@ -16,26 +16,26 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: string: '{"documents":[],"errors":[{"id":"0","error":{"code":"InvalidArgument","message":"Invalid - Language Code.","innerError":{"code":"UnsupportedLanguageCode","message":"Supplied + Language Code.","innererror":{"code":"UnsupportedLanguageCode","message":"Supplied language not supported. Pass in one of: en,es"}}},{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - Language Code.","innerError":{"code":"UnsupportedLanguageCode","message":"Supplied + Language Code.","innererror":{"code":"UnsupportedLanguageCode","message":"Supplied language not supported. Pass in one of: en,es"}}},{"id":"2","error":{"code":"InvalidArgument","message":"Invalid - Language Code.","innerError":{"code":"UnsupportedLanguageCode","message":"Supplied + Language Code.","innererror":{"code":"UnsupportedLanguageCode","message":"Supplied language not supported. Pass in one of: en,es"}}}],"modelVersion":"2020-02-01"}' headers: apim-request-id: - - 51ebf033-8827-4b54-bb62-2a77b722328f + - 96b04a1b-03ad-4798-8d3c-fc4e43fe75d3 content-type: - application/json; charset=utf-8 date: - - Thu, 02 Apr 2020 15:07:57 GMT + - Thu, 23 Apr 2020 15:56:11 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -43,7 +43,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '11' + - '2' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_whole_batch_language_hint_and_dict_per_item_hints.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_whole_batch_language_hint_and_dict_per_item_hints.yaml index d6e52e66b352..53cd3734fdae 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_whole_batch_language_hint_and_dict_per_item_hints.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_whole_batch_language_hint_and_dict_per_item_hints.yaml @@ -16,22 +16,22 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: - string: '{"documents":[{"id":"1","entities":[]},{"id":"2","entities":[]},{"id":"3","entities":[]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"1","entities":[],"warnings":[]},{"id":"2","entities":[],"warnings":[]},{"id":"3","entities":[],"warnings":[]}],"errors":[],"modelVersion":"2020-02-01"}' headers: apim-request-id: - - 69d41403-a27b-4462-83e9-fcf8204cb36a + - ea17e258-3afc-4064-988d-72dc97bfd914 content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:07:57 GMT + - Thu, 23 Apr 2020 15:56:12 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: @@ -39,7 +39,7 @@ interactions: x-content-type-options: - nosniff x-envoy-upstream-service-time: - - '15' + - '17' status: code: 200 message: OK diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_whole_batch_language_hint_and_obj_input.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_whole_batch_language_hint_and_obj_input.yaml index bdcfa467d8a8..00b11d7a47d1 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_whole_batch_language_hint_and_obj_input.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_whole_batch_language_hint_and_obj_input.yaml @@ -16,26 +16,26 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: string: '{"documents":[],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - Language Code.","innerError":{"code":"UnsupportedLanguageCode","message":"Supplied + Language Code.","innererror":{"code":"UnsupportedLanguageCode","message":"Supplied language not supported. Pass in one of: en,es"}}},{"id":"4","error":{"code":"InvalidArgument","message":"Invalid - Language Code.","innerError":{"code":"UnsupportedLanguageCode","message":"Supplied + Language Code.","innererror":{"code":"UnsupportedLanguageCode","message":"Supplied language not supported. Pass in one of: en,es"}}},{"id":"3","error":{"code":"InvalidArgument","message":"Invalid - Language Code.","innerError":{"code":"UnsupportedLanguageCode","message":"Supplied + Language Code.","innererror":{"code":"UnsupportedLanguageCode","message":"Supplied language not supported. Pass in one of: en,es"}}}],"modelVersion":"2020-02-01"}' headers: apim-request-id: - - 80a9f023-4398-423e-b62e-da5e00375b1b + - 8334db5b-5e08-4999-ae81-4efea49178b6 content-type: - application/json; charset=utf-8 date: - - Thu, 02 Apr 2020 15:07:58 GMT + - Thu, 23 Apr 2020 15:56:12 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_whole_batch_language_hint_and_obj_per_item_hints.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_whole_batch_language_hint_and_obj_per_item_hints.yaml index ec972bd800bd..e2014f2d66ae 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_whole_batch_language_hint_and_obj_per_item_hints.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities.test_whole_batch_language_hint_and_obj_per_item_hints.yaml @@ -16,22 +16,22 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: - string: '{"documents":[{"id":"1","entities":[]},{"id":"2","entities":[]},{"id":"3","entities":[]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"1","entities":[],"warnings":[]},{"id":"2","entities":[],"warnings":[]},{"id":"3","entities":[],"warnings":[]}],"errors":[],"modelVersion":"2020-02-01"}' headers: apim-request-id: - - ded7fad8-f170-4d0b-982e-6cebe35f7204 + - 2502e0f4-6a65-411a-bb1d-a2b29eb9eded content-type: - application/json; charset=utf-8 csp-billing-usage: - CognitiveServices.TextAnalytics.BatchScoring=3 date: - - Thu, 02 Apr 2020 15:07:58 GMT + - Thu, 23 Apr 2020 15:56:12 GMT strict-transport-security: - max-age=31536000; includeSubDomains; preload transfer-encoding: diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_text_analytics.test_detect_language.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_text_analytics.test_detect_language.yaml deleted file mode 100644 index dab34b45726e..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_text_analytics.test_detect_language.yaml +++ /dev/null @@ -1,44 +0,0 @@ -interactions: -- request: - body: '{"documents": [{"id": "1", "text": "I had a wonderful experience! The rooms - were wonderful and the staff was helpful.", "countryHint": "US"}]}' - headers: - Accept: - - application/json - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '142' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"documents":[{"id":"1","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]}],"errors":[],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: - - 4162f231-ccf5-4dc1-868b-54a71ab1c188 - content-type: - - application/json; charset=utf-8 - csp-billing-usage: - - CognitiveServices.TextAnalytics.BatchScoring=1 - date: - - Thu, 02 Apr 2020 15:08:12 GMT - strict-transport-security: - - max-age=31536000; includeSubDomains; preload - transfer-encoding: - - chunked - x-content-type-options: - - nosniff - x-envoy-upstream-service-time: - - '3' - status: - code: 200 - message: OK -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/testcase.py b/sdk/textanalytics/azure-ai-textanalytics/tests/testcase.py index 483d63cabcd3..9fe76afc6b7d 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/testcase.py +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/testcase.py @@ -6,6 +6,7 @@ # license information. # -------------------------------------------------------------------------- import pytest +import os from azure.core.credentials import AccessToken, AzureKeyCredential from devtools_testutils import ( @@ -128,15 +129,15 @@ def create_text_analytics_client(self, **kwargs): def text_analytics_account(): test_case = AzureTestCase("__init__") rg_preparer = ResourceGroupPreparer(random_name_enabled=True, name_prefix='pycog') - text_analytics_preparer = CognitiveServicesAccountPreparer(random_name_enabled=True, name_prefix='pycog') + text_analytics_preparer = CognitiveServicesAccountPreparer(random_name_enabled=True, name_prefix='pycog', sku='S0') try: rg_name, rg_kwargs = rg_preparer._prepare_create_resource(test_case) TextAnalyticsTest._RESOURCE_GROUP = rg_kwargs['resource_group'] try: text_analytics_name, text_analytics_kwargs = text_analytics_preparer._prepare_create_resource(test_case, **rg_kwargs) - TextAnalyticsTest._TEXT_ANALYTICS_ACCOUNT = text_analytics_kwargs['cognitiveservices_account'] - TextAnalyticsTest._TEXT_ANALYTICS_KEY = text_analytics_kwargs['cognitiveservices_account_key'] + TextAnalyticsTest._TEXT_ANALYTICS_ACCOUNT = os.environ['AZURE_TEXT_ANALYTICS_ENDPOINT'] #text_analytics_kwargs['cognitiveservices_account'] + TextAnalyticsTest._TEXT_ANALYTICS_KEY = os.environ['AZURE_TEXT_ANALYTICS_KEY'] # text_analytics_kwargs['cognitiveservices_account_key'] yield finally: text_analytics_preparer.remove_resource( From aea7cac1179a5474aca410f38a9011ab8cf74f65 Mon Sep 17 00:00:00 2001 From: iscai-msft Date: Thu, 23 Apr 2020 14:35:17 -0400 Subject: [PATCH 3/3] recorded more tests --- ...sync.test_all_successful_passing_dict.yaml | 36 ----- ...uccessful_passing_text_document_input.yaml | 36 ----- ...t_language_async.test_bad_credentials.yaml | 19 ++- ...language_async.test_bad_model_version.yaml | 12 +- ...ge_async.test_bad_model_version_error.yaml | 12 +- ...uage_async.test_batch_size_over_limit.yaml | 14 +- ...sync.test_batch_size_over_limit_error.yaml | 14 +- ...st_client_passed_default_country_hint.yaml | 101 -------------- ...anguage_async.test_country_hint_kwarg.yaml | 33 ----- ...language_async.test_country_hint_none.yaml | 126 ------------------ ...t_attribute_error_no_result_attribute.yaml | 14 +- ...attribute_error_nonexistent_attribute.yaml | 14 +- ...t_language_async.test_document_errors.yaml | 16 +-- ...nguage_async.test_duplicate_ids_error.yaml | 14 +- ...age_async.test_empty_credential_class.yaml | 19 ++- ...uage_async.test_input_with_all_errors.yaml | 18 +-- ...age_async.test_input_with_some_errors.yaml | 41 ------ ...sync.test_missing_input_records_error.yaml | 32 ----- ..._language_async.test_out_of_order_ids.yaml | 37 ----- ...t_detect_language_async.test_pass_cls.yaml | 14 +- ...nguage_async.test_passing_only_string.yaml | 38 ------ ...c.test_per_item_dont_use_country_hint.yaml | 35 ----- ...ge_async.test_rotate_subscription_key.yaml | 97 -------------- ...ync.test_show_stats_and_model_version.yaml | 37 ----- ...detect_language_async.test_user_agent.yaml | 35 ----- ...e_async.test_whole_batch_country_hint.yaml | 35 ----- ...ole_batch_country_hint_and_dict_input.yaml | 35 ----- ..._country_hint_and_dict_per_item_hints.yaml | 35 ----- ...hole_batch_country_hint_and_obj_input.yaml | 35 ----- ...h_country_hint_and_obj_per_item_hints.yaml | 35 ----- ...est_whole_batch_dont_use_country_hint.yaml | 35 ----- ...sync.test_all_successful_passing_dict.yaml | 45 ------- ...uccessful_passing_text_document_input.yaml | 45 ------- ...e_entities_async.test_bad_credentials.yaml | 19 ++- ...entities_async.test_bad_model_version.yaml | 14 +- ...es_async.test_bad_model_version_error.yaml | 14 +- ...ties_async.test_batch_size_over_limit.yaml | 14 +- ...sync.test_batch_size_over_limit_error.yaml | 14 +- ...t_client_passed_default_language_hint.yaml | 42 +++--- ...t_attribute_error_no_result_attribute.yaml | 16 +-- ...attribute_error_nonexistent_attribute.yaml | 14 +- ...e_entities_async.test_document_errors.yaml | 18 +-- ...tities_async.test_duplicate_ids_error.yaml | 14 +- ...ies_async.test_empty_credential_class.yaml | 19 ++- ...ties_async.test_input_with_all_errors.yaml | 20 +-- ...ies_async.test_input_with_some_errors.yaml | 26 ++-- ...ies_async.test_language_kwarg_spanish.yaml | 15 +-- ...sync.test_missing_input_records_error.yaml | 32 ----- ..._entities_async.test_out_of_order_ids.yaml | 18 +-- ...ecognize_entities_async.test_pass_cls.yaml | 14 +- ...tities_async.test_passing_only_string.yaml | 53 ++++---- ....test_per_item_dont_use_language_hint.yaml | 14 +- ...es_async.test_rotate_subscription_key.yaml | 47 ++++--- ...ync.test_show_stats_and_model_version.yaml | 18 +-- ...ognize_entities_async.test_user_agent.yaml | 14 +- ...st_whole_batch_dont_use_language_hint.yaml | 14 +- ..._async.test_whole_batch_language_hint.yaml | 14 +- ...language_hint_and_dict_per_item_hints.yaml | 14 +- ...ole_batch_language_hint_and_obj_input.yaml | 14 +- ..._language_hint_and_obj_per_item_hints.yaml | 14 +- ...sync.test_all_successful_passing_dict.yaml | 24 ++-- ...uccessful_passing_text_document_input.yaml | 25 ++-- ...d_entities_async.test_bad_credentials.yaml | 19 ++- ...entities_async.test_bad_model_version.yaml | 12 +- ...es_async.test_bad_model_version_error.yaml | 14 +- ...ties_async.test_batch_size_over_limit.yaml | 12 +- ...sync.test_batch_size_over_limit_error.yaml | 14 +- ...t_client_passed_default_language_hint.yaml | 40 +++--- ...t_attribute_error_no_result_attribute.yaml | 12 +- ...attribute_error_nonexistent_attribute.yaml | 12 +- ...d_entities_async.test_document_errors.yaml | 16 +-- ...tities_async.test_duplicate_ids_error.yaml | 14 +- ...ies_async.test_empty_credential_class.yaml | 19 ++- ...ties_async.test_input_with_all_errors.yaml | 16 +-- ...ies_async.test_input_with_some_errors.yaml | 21 +-- ...ies_async.test_language_kwarg_spanish.yaml | 20 +-- ...sync.test_missing_input_records_error.yaml | 32 ----- ..._entities_async.test_out_of_order_ids.yaml | 16 +-- ...e_linked_entities_async.test_pass_cls.yaml | 14 +- ...tities_async.test_passing_only_string.yaml | 27 ++-- ....test_per_item_dont_use_language_hint.yaml | 14 +- ...es_async.test_rotate_subscription_key.yaml | 45 ++++--- ...ync.test_show_stats_and_model_version.yaml | 16 +-- ...linked_entities_async.test_user_agent.yaml | 14 +- ...st_whole_batch_dont_use_language_hint.yaml | 14 +- ..._async.test_whole_batch_language_hint.yaml | 16 +-- ...language_hint_and_dict_per_item_hints.yaml | 14 +- ...ole_batch_language_hint_and_obj_input.yaml | 16 +-- ..._language_hint_and_obj_per_item_hints.yaml | 14 +- 89 files changed, 619 insertions(+), 1626 deletions(-) delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_all_successful_passing_dict.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_all_successful_passing_text_document_input.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_client_passed_default_country_hint.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_country_hint_kwarg.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_country_hint_none.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_input_with_some_errors.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_missing_input_records_error.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_out_of_order_ids.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_passing_only_string.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_per_item_dont_use_country_hint.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_rotate_subscription_key.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_show_stats_and_model_version.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_user_agent.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_whole_batch_country_hint.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_whole_batch_country_hint_and_dict_input.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_whole_batch_country_hint_and_dict_per_item_hints.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_whole_batch_country_hint_and_obj_input.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_whole_batch_country_hint_and_obj_per_item_hints.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_whole_batch_dont_use_country_hint.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_all_successful_passing_dict.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_all_successful_passing_text_document_input.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_missing_input_records_error.yaml delete mode 100644 sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_missing_input_records_error.yaml diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_all_successful_passing_dict.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_all_successful_passing_dict.yaml deleted file mode 100644 index c67afe4a3dd3..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_all_successful_passing_dict.yaml +++ /dev/null @@ -1,36 +0,0 @@ -interactions: -- request: - body: '{"documents": [{"id": "1", "text": "I should take my cat to the veterinarian.", - "countryHint": "US"}, {"id": "2", "text": "Este es un document escrito en Espa\u00f1ol.", - "countryHint": "US"}, {"id": "3", "text": "\u732b\u306f\u5e78\u305b", "countryHint": - "US"}, {"id": "4", "text": "Fahrt nach Stuttgart und dann zum Hotel zu Fu.", - "countryHint": "US"}]}' - headers: - Accept: - - application/json - Content-Length: - - '354' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=true - response: - body: - string: '{"statistics":{"documentsCount":4,"validDocumentsCount":4,"erroneousDocumentsCount":0,"transactionsCount":4},"documents":[{"id":"1","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}],"statistics":{"charactersCount":41,"transactionsCount":1}},{"id":"2","detectedLanguages":[{"name":"Spanish","iso6391Name":"es","score":1.0}],"statistics":{"charactersCount":39,"transactionsCount":1}},{"id":"3","detectedLanguages":[{"name":"Japanese","iso6391Name":"ja","score":1.0}],"statistics":{"charactersCount":4,"transactionsCount":1}},{"id":"4","detectedLanguages":[{"name":"German","iso6391Name":"de","score":1.0}],"statistics":{"charactersCount":46,"transactionsCount":1}}],"errors":[],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: 08ec703a-52df-489b-8bbf-e44700bb172d - content-type: application/json; charset=utf-8 - csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=4 - date: Thu, 02 Apr 2020 15:06:37 GMT - strict-transport-security: max-age=31536000; includeSubDomains; preload - transfer-encoding: chunked - x-content-type-options: nosniff - x-envoy-upstream-service-time: '4' - status: - code: 200 - message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/languages?showStats=true -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_all_successful_passing_text_document_input.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_all_successful_passing_text_document_input.yaml deleted file mode 100644 index 0e51bf49af6f..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_all_successful_passing_text_document_input.yaml +++ /dev/null @@ -1,36 +0,0 @@ -interactions: -- request: - body: '{"documents": [{"id": "1", "text": "I should take my cat to the veterinarian", - "language": "US"}, {"id": "2", "text": "Este es un document escrito en Espa\u00f1ol.", - "language": "US"}, {"id": "3", "text": "\u732b\u306f\u5e78\u305b", "language": - "US"}, {"id": "4", "text": "Fahrt nach Stuttgart und dann zum Hotel zu Fu.", - "language": "US"}]}' - headers: - Accept: - - application/json - Content-Length: - - '341' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"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":"Japanese","iso6391Name":"ja","score":1.0}]},{"id":"4","detectedLanguages":[{"name":"German","iso6391Name":"de","score":1.0}]}],"errors":[],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: 1dcf7534-590b-4116-b081-4e308728dcac - content-type: application/json; charset=utf-8 - csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=4 - date: Thu, 02 Apr 2020 15:06:38 GMT - strict-transport-security: max-age=31536000; includeSubDomains; preload - transfer-encoding: chunked - x-content-type-options: nosniff - x-envoy-upstream-service-time: '4' - status: - code: 200 - message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/languages?showStats=false -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_bad_credentials.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_bad_credentials.yaml index 716c364059ce..bed5f9723d17 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_bad_credentials.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_bad_credentials.yaml @@ -10,20 +10,25 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/languages?showStats=false response: body: - string: '{"error":{"code":"401","message":"Access denied due to invalid subscription + string: '{"error":{"code":"401","message": "Access denied due to invalid subscription key or wrong API endpoint. Make sure to provide a valid key for an active subscription and use a correct regional API endpoint for your resource."}}' headers: - content-length: '224' - date: Thu, 02 Apr 2020 15:06:38 GMT + apim-request-id: cb634baf-cae8-4e45-ba42-8ecda4cc4948 + content-length: '225' + content-type: application/json + date: Thu, 23 Apr 2020 18:33:51 GMT + strict-transport-security: max-age=31536000; includeSubDomains; preload + www-authenticate: AzureApiManagementKey realm="https://westus2.ppe.cognitiveservices.azure.com/text/analytics",name="Ocp-Apim-Subscription-Key",type="header" + x-content-type-options: nosniff status: code: 401 - message: PermissionDenied - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/languages?showStats=false + message: Access Denied + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/languages?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_bad_model_version.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_bad_model_version.yaml index 066a0ca45b38..424eca618e8e 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_bad_model_version.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_bad_model_version.yaml @@ -10,24 +10,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?model-version=old&showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/languages?model-version=old&showStats=false response: body: string: '{"error":{"code":"InvalidRequest","message":"Specified Model version is incorrect. Allowed values are latest,2019-10-01"}}' headers: - apim-request-id: 62102494-b75c-4d81-b3fb-fcde2b8f792e + apim-request-id: 6cd3ee00-928a-4edb-b538-2cc8f5363492 content-type: application/json; charset=utf-8 - date: Thu, 02 Apr 2020 15:06:38 GMT + date: Thu, 23 Apr 2020 18:33:52 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '4' + x-envoy-upstream-service-time: '12' status: code: 400 message: Bad Request - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/languages?model-version=old&showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/languages?model-version=old&showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_bad_model_version_error.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_bad_model_version_error.yaml index f1500da99b52..d1053ef234ba 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_bad_model_version_error.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_bad_model_version_error.yaml @@ -10,24 +10,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?model-version=bad&showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/languages?model-version=bad&showStats=false response: body: string: '{"error":{"code":"InvalidRequest","message":"Specified Model version is incorrect. Allowed values are latest,2019-10-01"}}' headers: - apim-request-id: 7f1fec05-90b3-4d0a-87fc-ae0080d13605 + apim-request-id: 51ed96eb-f667-46dc-9bea-3c8c98bda4a1 content-type: application/json; charset=utf-8 - date: Thu, 02 Apr 2020 15:06:39 GMT + date: Thu, 23 Apr 2020 18:33:53 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '3' + x-envoy-upstream-service-time: '8' status: code: 400 message: Bad Request - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/languages?model-version=bad&showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/languages?model-version=bad&showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_batch_size_over_limit.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_batch_size_over_limit.yaml index e66d9d22a2eb..05abb8128aed 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_batch_size_over_limit.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_batch_size_over_limit.yaml @@ -759,24 +759,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/languages?showStats=false response: body: - string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innerError":{"code":"InvalidDocumentBatch","message":"Batch + string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innererror":{"code":"InvalidDocumentBatch","message":"Batch request contains too many records. Max 1000 records are permitted."}}}' headers: - apim-request-id: 894680ec-9e54-4adf-97fc-c440dd2ef380 + apim-request-id: fa5ec43b-90b1-439a-bdb2-90687db32311 content-type: application/json; charset=utf-8 - date: Thu, 02 Apr 2020 15:06:39 GMT + date: Thu, 23 Apr 2020 18:33:54 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '22' + x-envoy-upstream-service-time: '23' status: code: 400 message: Bad Request - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/languages?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/languages?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_batch_size_over_limit_error.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_batch_size_over_limit_error.yaml index d418e5200ece..e2d22cce640f 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_batch_size_over_limit_error.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_batch_size_over_limit_error.yaml @@ -724,24 +724,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/languages?showStats=false response: body: - string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innerError":{"code":"InvalidDocumentBatch","message":"Batch + string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innererror":{"code":"InvalidDocumentBatch","message":"Batch request contains too many records. Max 1000 records are permitted."}}}' headers: - apim-request-id: c1cc3beb-c8c5-43af-be4d-81c9fa65e3c6 + apim-request-id: 3f11faed-58c5-4951-b770-6622f58d174f content-type: application/json; charset=utf-8 - date: Thu, 02 Apr 2020 15:06:40 GMT + date: Thu, 23 Apr 2020 18:33:55 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '21' + x-envoy-upstream-service-time: '24' status: code: 400 message: Bad Request - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/languages?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/languages?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_client_passed_default_country_hint.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_client_passed_default_country_hint.yaml deleted file mode 100644 index bff7f89cca5a..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_client_passed_default_country_hint.yaml +++ /dev/null @@ -1,101 +0,0 @@ -interactions: -- request: - body: '{"documents": [{"id": "1", "text": "I will go to the park.", "countryHint": - "CA"}, {"id": "2", "text": "I did not like the hotel we stayed at.", "countryHint": - "CA"}, {"id": "3", "text": "The restaurant had really good food.", "countryHint": - "CA"}]}' - headers: - Accept: - - application/json - Content-Length: - - '249' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"documents":[{"id":"1","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"2","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"3","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]}],"errors":[],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: a0145fc4-2266-4363-9652-88fe89546d41 - content-type: application/json; charset=utf-8 - csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:06:41 GMT - strict-transport-security: max-age=31536000; includeSubDomains; preload - transfer-encoding: chunked - x-content-type-options: nosniff - x-envoy-upstream-service-time: '4' - status: - code: 200 - message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/languages?showStats=false -- request: - body: '{"documents": [{"id": "1", "text": "I will go to the park.", "countryHint": - "DE"}, {"id": "2", "text": "I did not like the hotel we stayed at.", "countryHint": - "DE"}, {"id": "3", "text": "The restaurant had really good food.", "countryHint": - "DE"}]}' - headers: - Accept: - - application/json - Content-Length: - - '249' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"documents":[{"id":"1","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"2","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"3","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]}],"errors":[],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: aa59c003-9a27-4cbf-b15d-4c0fa87d19fe - content-type: application/json; charset=utf-8 - csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:06:41 GMT - strict-transport-security: max-age=31536000; includeSubDomains; preload - transfer-encoding: chunked - x-content-type-options: nosniff - x-envoy-upstream-service-time: '4' - status: - code: 200 - message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/languages?showStats=false -- request: - body: '{"documents": [{"id": "1", "text": "I will go to the park.", "countryHint": - "CA"}, {"id": "2", "text": "I did not like the hotel we stayed at.", "countryHint": - "CA"}, {"id": "3", "text": "The restaurant had really good food.", "countryHint": - "CA"}]}' - headers: - Accept: - - application/json - Content-Length: - - '249' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"documents":[{"id":"1","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"2","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"3","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]}],"errors":[],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: 79ea23df-5b7f-4487-ae1d-31b4dd19209b - content-type: application/json; charset=utf-8 - csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:06:41 GMT - strict-transport-security: max-age=31536000; includeSubDomains; preload - transfer-encoding: chunked - x-content-type-options: nosniff - x-envoy-upstream-service-time: '4' - status: - code: 200 - message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/languages?showStats=false -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_country_hint_kwarg.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_country_hint_kwarg.yaml deleted file mode 100644 index 0c7569531962..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_country_hint_kwarg.yaml +++ /dev/null @@ -1,33 +0,0 @@ -interactions: -- request: - body: '{"documents": [{"id": "0", "text": "this is written in english", "countryHint": - "ES"}]}' - headers: - Accept: - - application/json - Content-Length: - - '87' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?model-version=latest&showStats=true - response: - body: - string: '{"statistics":{"documentsCount":1,"validDocumentsCount":1,"erroneousDocumentsCount":0,"transactionsCount":1},"documents":[{"id":"0","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}],"statistics":{"charactersCount":26,"transactionsCount":1}}],"errors":[],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: 4814b150-27f4-4ded-b3d2-56d9975831ad - content-type: application/json; charset=utf-8 - csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=1 - date: Thu, 02 Apr 2020 15:06:42 GMT - strict-transport-security: max-age=31536000; includeSubDomains; preload - transfer-encoding: chunked - x-content-type-options: nosniff - x-envoy-upstream-service-time: '4' - status: - code: 200 - message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/languages?model-version=latest&showStats=true -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_country_hint_none.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_country_hint_none.yaml deleted file mode 100644 index b111bb24844e..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_country_hint_none.yaml +++ /dev/null @@ -1,126 +0,0 @@ -interactions: -- request: - body: '{"documents": [{"id": "0", "text": "This is written in English.", "countryHint": - ""}]}' - headers: - Accept: - - application/json - Content-Length: - - '86' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"documents":[{"id":"0","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]}],"errors":[],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: 7df1519a-6897-46d8-88d7-4d944c1115ce - content-type: application/json; charset=utf-8 - csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=1 - date: Thu, 02 Apr 2020 15:06:42 GMT - strict-transport-security: max-age=31536000; includeSubDomains; preload - transfer-encoding: chunked - x-content-type-options: nosniff - x-envoy-upstream-service-time: '3' - status: - code: 200 - message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/languages?showStats=false -- request: - body: '{"documents": [{"id": "1", "text": "This is written in English.", "countryHint": - ""}]}' - headers: - Accept: - - application/json - Content-Length: - - '86' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"documents":[{"id":"1","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]}],"errors":[],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: 1b40e6fc-ccf3-4c1f-9fec-e5498dae10e0 - content-type: application/json; charset=utf-8 - csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=1 - date: Thu, 02 Apr 2020 15:06:42 GMT - strict-transport-security: max-age=31536000; includeSubDomains; preload - transfer-encoding: chunked - x-content-type-options: nosniff - x-envoy-upstream-service-time: '3' - status: - code: 200 - message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/languages?showStats=false -- request: - body: '{"documents": [{"id": "0", "text": "this is written in english", "countryHint": - ""}]}' - headers: - Accept: - - application/json - Content-Length: - - '85' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"documents":[{"id":"0","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]}],"errors":[],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: 1252b841-b431-4a00-9e41-62bd32a03771 - content-type: application/json; charset=utf-8 - csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=1 - date: Thu, 02 Apr 2020 15:06:42 GMT - strict-transport-security: max-age=31536000; includeSubDomains; preload - transfer-encoding: chunked - x-content-type-options: nosniff - x-envoy-upstream-service-time: '3' - status: - code: 200 - message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/languages?showStats=false -- request: - body: '{"documents": [{"id": "0", "text": "this is written in english", "countryHint": - ""}]}' - headers: - Accept: - - application/json - Content-Length: - - '85' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"documents":[{"id":"0","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]}],"errors":[],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: 90d4c0f8-b28b-46ed-8114-ca7105331088 - content-type: application/json; charset=utf-8 - csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=1 - date: Thu, 02 Apr 2020 15:06:43 GMT - strict-transport-security: max-age=31536000; includeSubDomains; preload - transfer-encoding: chunked - x-content-type-options: nosniff - x-envoy-upstream-service-time: '3' - status: - code: 200 - message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/languages?showStats=false -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_document_attribute_error_no_result_attribute.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_document_attribute_error_no_result_attribute.yaml index 96a4bf3e77a7..e0248007a484 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_document_attribute_error_no_result_attribute.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_document_attribute_error_no_result_attribute.yaml @@ -9,26 +9,26 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/languages?showStats=false response: body: string: '{"documents":[],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}}],"modelVersion":"2019-10-01"}' headers: - apim-request-id: b515ae18-29d6-4063-b321-16c5c4cd1be4 + apim-request-id: 97effa82-ec05-4175-b0ef-d60c6e8a36da content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=0 - date: Thu, 02 Apr 2020 15:06:43 GMT + date: Thu, 23 Apr 2020 18:33:56 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '3' + x-envoy-upstream-service-time: '2' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/languages?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/languages?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_document_attribute_error_nonexistent_attribute.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_document_attribute_error_nonexistent_attribute.yaml index 6bf6927a9c9f..8c9433b87439 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_document_attribute_error_nonexistent_attribute.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_document_attribute_error_nonexistent_attribute.yaml @@ -9,26 +9,26 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/languages?showStats=false response: body: string: '{"documents":[],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}}],"modelVersion":"2019-10-01"}' headers: - apim-request-id: 3cc9aae0-9dc8-4ae9-9927-e1b8efd3c8a1 + apim-request-id: 2b6dfcfc-0d06-4bfa-9fdf-b4c65d4b89e4 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=0 - date: Thu, 02 Apr 2020 15:06:43 GMT + date: Thu, 23 Apr 2020 18:33:57 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '3' + x-envoy-upstream-service-time: '6' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/languages?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/languages?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_document_errors.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_document_errors.yaml index 9d55b4027c50..5aa2e9cca5ac 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_document_errors.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_document_errors.yaml @@ -11,30 +11,30 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/languages?showStats=false response: body: string: '{"documents":[],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}},{"id":"2","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"A + document in request.","innererror":{"code":"InvalidDocument","message":"A document within the request was too large to be processed. Limit document size to: 5120 text elements. For additional details on the data limitations see https://aka.ms/text-analytics-data-limits"}}}],"modelVersion":"2019-10-01"}' headers: - apim-request-id: d16ea006-411c-4490-9b18-932be8786aed + apim-request-id: 80488ba5-65d7-4d01-9735-1519d0177edc content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=0 - date: Thu, 02 Apr 2020 15:06:44 GMT + date: Thu, 23 Apr 2020 18:33:57 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '3' + x-envoy-upstream-service-time: '2' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/languages?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/languages?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_duplicate_ids_error.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_duplicate_ids_error.yaml index 71ed36faba41..ad82586b2fbf 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_duplicate_ids_error.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_duplicate_ids_error.yaml @@ -11,24 +11,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/languages?showStats=false response: body: - string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innerError":{"code":"InvalidDocument","message":"Request + string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innererror":{"code":"InvalidDocument","message":"Request contains duplicated Ids. Make sure each document has a unique Id."}}}' headers: - apim-request-id: 1025592a-7fde-46e0-a0b3-cc695fb8fa9c + apim-request-id: ec720d9a-f227-4648-b007-094b15c07084 content-type: application/json; charset=utf-8 - date: Thu, 02 Apr 2020 15:06:44 GMT + date: Thu, 23 Apr 2020 18:33:57 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '4' + x-envoy-upstream-service-time: '3' status: code: 400 message: Bad Request - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/languages?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/languages?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_empty_credential_class.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_empty_credential_class.yaml index e88bc583b4ff..d0c2fce9a0d9 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_empty_credential_class.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_empty_credential_class.yaml @@ -10,20 +10,25 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/languages?showStats=false response: body: - string: '{"error":{"code":"401","message":"Access denied due to invalid subscription + string: '{"error":{"code":"401","message": "Access denied due to invalid subscription key or wrong API endpoint. Make sure to provide a valid key for an active subscription and use a correct regional API endpoint for your resource."}}' headers: - content-length: '224' - date: Thu, 02 Apr 2020 15:06:45 GMT + apim-request-id: 5830f7fc-fa59-419d-a84b-4d20494646a5 + content-length: '225' + content-type: application/json + date: Thu, 23 Apr 2020 18:33:59 GMT + strict-transport-security: max-age=31536000; includeSubDomains; preload + www-authenticate: AzureApiManagementKey realm="https://westus2.ppe.cognitiveservices.azure.com/text/analytics",name="Ocp-Apim-Subscription-Key",type="header" + x-content-type-options: nosniff status: code: 401 - message: PermissionDenied - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/languages?showStats=false + message: Access Denied + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/languages?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_input_with_all_errors.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_input_with_all_errors.yaml index e4cb95504807..23792f014a50 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_input_with_all_errors.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_input_with_all_errors.yaml @@ -12,28 +12,28 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/languages?showStats=false response: body: string: '{"documents":[],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}},{"id":"2","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}},{"id":"3","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}},{"id":"4","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"A + document in request.","innererror":{"code":"InvalidDocument","message":"A document within the request was too large to be processed. Limit document size to: 5120 text elements. For additional details on the data limitations see https://aka.ms/text-analytics-data-limits"}}}],"modelVersion":"2019-10-01"}' headers: - apim-request-id: 54fd9db6-6592-4838-b88a-45cabfb415bb + apim-request-id: 1209d03b-b129-441a-ae76-1fb62e455636 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=0 - date: Thu, 02 Apr 2020 15:06:45 GMT + date: Thu, 23 Apr 2020 18:33:59 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff @@ -41,5 +41,5 @@ interactions: status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/languages?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/languages?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_input_with_some_errors.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_input_with_some_errors.yaml deleted file mode 100644 index 3feaca75605a..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_input_with_some_errors.yaml +++ /dev/null @@ -1,41 +0,0 @@ -interactions: -- request: - body: '{"documents": [{"id": "1", "text": "I should take my cat to the veterinarian.", - "countryHint": "United States"}, {"id": "2", "text": "Este es un document escrito - en Espa\u00f1ol.", "countryHint": "US"}, {"id": "3", "text": "", "countryHint": - "US"}, {"id": "4", "text": "Fahrt nach Stuttgart und dann zum Hotel zu Fu.", - "countryHint": "US"}]}' - headers: - Accept: - - application/json - Content-Length: - - '341' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"documents":[{"id":"2","detectedLanguages":[{"name":"Spanish","iso6391Name":"es","score":1.0}]},{"id":"4","detectedLanguages":[{"name":"German","iso6391Name":"de","score":1.0}]}],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - Country Hint.","innerError":{"code":"InvalidCountryHint","message":"Country - hint is not valid. Please specify an ISO 3166-1 alpha-2 two letter country - code."}}},{"id":"3","error":{"code":"InvalidArgument","message":"Invalid document - in request.","innerError":{"code":"InvalidDocument","message":"Document text - is empty."}}}],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: d56b34d9-abfa-443d-a981-401b47e3de88 - content-type: application/json; charset=utf-8 - csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=2 - date: Thu, 02 Apr 2020 15:06:45 GMT - strict-transport-security: max-age=31536000; includeSubDomains; preload - transfer-encoding: chunked - x-content-type-options: nosniff - x-envoy-upstream-service-time: '4' - status: - code: 200 - message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/languages?showStats=false -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_missing_input_records_error.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_missing_input_records_error.yaml deleted file mode 100644 index e7ce0b894558..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_missing_input_records_error.yaml +++ /dev/null @@ -1,32 +0,0 @@ -interactions: -- request: - body: '{"documents": []}' - headers: - Accept: - - application/json - Content-Length: - - '17' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"error":{"code":"InvalidRequest","message":"Invalid Request.","innerError":{"code":"MissingInputRecords","message":"Missing - input records."}}}' - headers: - apim-request-id: ef9f6ea2-9805-4dd5-9a83-eb22eab77220 - content-type: application/json; charset=utf-8 - date: Thu, 02 Apr 2020 15:06:46 GMT - strict-transport-security: max-age=31536000; includeSubDomains; preload - transfer-encoding: chunked - x-content-type-options: nosniff - x-envoy-upstream-service-time: '4' - status: - code: 400 - message: Bad Request - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/languages?showStats=false -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_out_of_order_ids.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_out_of_order_ids.yaml deleted file mode 100644 index 52b68eb7d2b3..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_out_of_order_ids.yaml +++ /dev/null @@ -1,37 +0,0 @@ -interactions: -- request: - body: '{"documents": [{"id": "56", "text": ":)", "countryHint": "US"}, {"id": - "0", "text": ":(", "countryHint": "US"}, {"id": "22", "text": "", "countryHint": - "US"}, {"id": "19", "text": ":P", "countryHint": "US"}, {"id": "1", "text": - ":D", "countryHint": "US"}]}' - headers: - Accept: - - application/json - Content-Length: - - '256' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"documents":[{"id":"56","detectedLanguages":[{"name":"(Unknown)","iso6391Name":"(Unknown)","score":0.0}]},{"id":"0","detectedLanguages":[{"name":"(Unknown)","iso6391Name":"(Unknown)","score":0.0}]},{"id":"19","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"1","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]}],"errors":[{"id":"22","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document - text is empty."}}}],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: a99ad506-dd1e-48e3-8a24-855b99c45309 - content-type: application/json; charset=utf-8 - csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=4 - date: Thu, 02 Apr 2020 15:06:46 GMT - strict-transport-security: max-age=31536000; includeSubDomains; preload - transfer-encoding: chunked - x-content-type-options: nosniff - x-envoy-upstream-service-time: '3' - status: - code: 200 - message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/languages?showStats=false -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_pass_cls.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_pass_cls.yaml index 3c654407b2ee..6ecb7bf5c0eb 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_pass_cls.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_pass_cls.yaml @@ -10,24 +10,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/languages?showStats=false response: body: - string: '{"documents":[{"id":"0","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]}],"errors":[],"modelVersion":"2019-10-01"}' + string: '{"documents":[{"id":"0","detectedLanguage":{"name":"English","iso6391Name":"en","confidenceScore":1.0},"warnings":[]}],"errors":[],"modelVersion":"2019-10-01"}' headers: - apim-request-id: 69e3b93e-6f25-4f23-ae5a-0bbf00dd4f3f + apim-request-id: 987f54e3-5537-4608-b7a3-598e3a8abc32 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=1 - date: Thu, 02 Apr 2020 15:06:47 GMT + date: Thu, 23 Apr 2020 18:34:00 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '4' + x-envoy-upstream-service-time: '2' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/languages?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/languages?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_passing_only_string.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_passing_only_string.yaml deleted file mode 100644 index a44fef9687e2..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_passing_only_string.yaml +++ /dev/null @@ -1,38 +0,0 @@ -interactions: -- request: - body: '{"documents": [{"id": "0", "text": "I should take my cat to the veterinarian.", - "countryHint": "US"}, {"id": "1", "text": "Este es un document escrito en Espa\u00f1ol.", - "countryHint": "US"}, {"id": "2", "text": "\u732b\u306f\u5e78\u305b", "countryHint": - "US"}, {"id": "3", "text": "Fahrt nach Stuttgart und dann zum Hotel zu Fu.", - "countryHint": "US"}, {"id": "4", "text": "", "countryHint": "US"}]}' - headers: - Accept: - - application/json - Content-Length: - - '400' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"documents":[{"id":"0","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"1","detectedLanguages":[{"name":"Spanish","iso6391Name":"es","score":1.0}]},{"id":"2","detectedLanguages":[{"name":"Japanese","iso6391Name":"ja","score":1.0}]},{"id":"3","detectedLanguages":[{"name":"German","iso6391Name":"de","score":1.0}]}],"errors":[{"id":"4","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document - text is empty."}}}],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: 57c8da38-59fc-4b76-be53-f1fe7d7e43ca - content-type: application/json; charset=utf-8 - csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=4 - date: Thu, 02 Apr 2020 15:06:47 GMT - strict-transport-security: max-age=31536000; includeSubDomains; preload - transfer-encoding: chunked - x-content-type-options: nosniff - x-envoy-upstream-service-time: '3' - status: - code: 200 - message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/languages?showStats=false -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_per_item_dont_use_country_hint.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_per_item_dont_use_country_hint.yaml deleted file mode 100644 index 4ea1afb7d27d..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_per_item_dont_use_country_hint.yaml +++ /dev/null @@ -1,35 +0,0 @@ -interactions: -- request: - body: '{"documents": [{"id": "1", "text": "I will go to the park.", "countryHint": - ""}, {"id": "2", "text": "I did not like the hotel we stayed at.", "countryHint": - ""}, {"id": "3", "text": "The restaurant had really good food.", "countryHint": - "US"}]}' - headers: - Accept: - - application/json - Content-Length: - - '245' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"documents":[{"id":"1","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"2","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"3","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]}],"errors":[],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: 1fb40ace-b239-4e88-b5c8-dfb959a8af34 - content-type: application/json; charset=utf-8 - csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:06:47 GMT - strict-transport-security: max-age=31536000; includeSubDomains; preload - transfer-encoding: chunked - x-content-type-options: nosniff - x-envoy-upstream-service-time: '3' - status: - code: 200 - message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/languages?showStats=false -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_rotate_subscription_key.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_rotate_subscription_key.yaml deleted file mode 100644 index d2d5c2981ee8..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_rotate_subscription_key.yaml +++ /dev/null @@ -1,97 +0,0 @@ -interactions: -- request: - body: '{"documents": [{"id": "1", "text": "I will go to the park.", "countryHint": - "US"}, {"id": "2", "text": "I did not like the hotel we stayed at.", "countryHint": - "US"}, {"id": "3", "text": "The restaurant had really good food.", "countryHint": - "US"}]}' - headers: - Accept: - - application/json - Content-Length: - - '249' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"documents":[{"id":"1","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"2","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"3","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]}],"errors":[],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: 74eb69d1-0ffc-4d0b-96b6-d7bb8fd16611 - content-type: application/json; charset=utf-8 - csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:06:48 GMT - strict-transport-security: max-age=31536000; includeSubDomains; preload - transfer-encoding: chunked - x-content-type-options: nosniff - x-envoy-upstream-service-time: '4' - status: - code: 200 - message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/languages?showStats=false -- request: - body: '{"documents": [{"id": "1", "text": "I will go to the park.", "countryHint": - "US"}, {"id": "2", "text": "I did not like the hotel we stayed at.", "countryHint": - "US"}, {"id": "3", "text": "The restaurant had really good food.", "countryHint": - "US"}]}' - headers: - Accept: - - application/json - Content-Length: - - '249' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"error":{"code":"401","message":"Access denied due to invalid subscription - key or wrong API endpoint. Make sure to provide a valid key for an active - subscription and use a correct regional API endpoint for your resource."}}' - headers: - content-length: '224' - date: Thu, 02 Apr 2020 15:06:48 GMT - status: - code: 401 - message: PermissionDenied - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/languages?showStats=false -- request: - body: '{"documents": [{"id": "1", "text": "I will go to the park.", "countryHint": - "US"}, {"id": "2", "text": "I did not like the hotel we stayed at.", "countryHint": - "US"}, {"id": "3", "text": "The restaurant had really good food.", "countryHint": - "US"}]}' - headers: - Accept: - - application/json - Content-Length: - - '249' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"documents":[{"id":"1","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"2","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"3","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]}],"errors":[],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: 64827d4d-416b-4e69-a0ec-d035ce236bdd - content-type: application/json; charset=utf-8 - csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:06:48 GMT - strict-transport-security: max-age=31536000; includeSubDomains; preload - transfer-encoding: chunked - x-content-type-options: nosniff - x-envoy-upstream-service-time: '3' - status: - code: 200 - message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/languages?showStats=false -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_show_stats_and_model_version.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_show_stats_and_model_version.yaml deleted file mode 100644 index 05e7dff95721..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_show_stats_and_model_version.yaml +++ /dev/null @@ -1,37 +0,0 @@ -interactions: -- request: - body: '{"documents": [{"id": "56", "text": ":)", "countryHint": "US"}, {"id": - "0", "text": ":(", "countryHint": "US"}, {"id": "22", "text": "", "countryHint": - "US"}, {"id": "19", "text": ":P", "countryHint": "US"}, {"id": "1", "text": - ":D", "countryHint": "US"}]}' - headers: - Accept: - - application/json - Content-Length: - - '256' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?model-version=latest&showStats=true - response: - body: - string: '{"statistics":{"documentsCount":5,"validDocumentsCount":4,"erroneousDocumentsCount":1,"transactionsCount":4},"documents":[{"id":"56","detectedLanguages":[{"name":"(Unknown)","iso6391Name":"(Unknown)","score":0.0}],"statistics":{"charactersCount":2,"transactionsCount":1}},{"id":"0","detectedLanguages":[{"name":"(Unknown)","iso6391Name":"(Unknown)","score":0.0}],"statistics":{"charactersCount":2,"transactionsCount":1}},{"id":"19","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}],"statistics":{"charactersCount":2,"transactionsCount":1}},{"id":"1","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}],"statistics":{"charactersCount":2,"transactionsCount":1}}],"errors":[{"id":"22","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document - text is empty."}}}],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: f3fc98ce-e813-4332-b6fa-c4472a887b43 - content-type: application/json; charset=utf-8 - csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=4 - date: Thu, 02 Apr 2020 15:06:48 GMT - strict-transport-security: max-age=31536000; includeSubDomains; preload - transfer-encoding: chunked - x-content-type-options: nosniff - x-envoy-upstream-service-time: '4' - status: - code: 200 - message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/languages?model-version=latest&showStats=true -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_user_agent.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_user_agent.yaml deleted file mode 100644 index a5198ccd946d..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_user_agent.yaml +++ /dev/null @@ -1,35 +0,0 @@ -interactions: -- request: - body: '{"documents": [{"id": "1", "text": "I will go to the park.", "countryHint": - "US"}, {"id": "2", "text": "I did not like the hotel we stayed at.", "countryHint": - "US"}, {"id": "3", "text": "The restaurant had really good food.", "countryHint": - "US"}]}' - headers: - Accept: - - application/json - Content-Length: - - '249' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"documents":[{"id":"1","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"2","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"3","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]}],"errors":[],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: 738d2f46-cc1b-45b7-980d-9e2deb1339d3 - content-type: application/json; charset=utf-8 - csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:06:48 GMT - strict-transport-security: max-age=31536000; includeSubDomains; preload - transfer-encoding: chunked - x-content-type-options: nosniff - x-envoy-upstream-service-time: '3' - status: - code: 200 - message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/languages?showStats=false -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_whole_batch_country_hint.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_whole_batch_country_hint.yaml deleted file mode 100644 index 766439883efa..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_whole_batch_country_hint.yaml +++ /dev/null @@ -1,35 +0,0 @@ -interactions: -- request: - body: '{"documents": [{"id": "0", "text": "This was the best day of my life.", - "countryHint": "CA"}, {"id": "1", "text": "I did not like the hotel we stayed - at. It was too expensive.", "countryHint": "CA"}, {"id": "2", "text": "The restaurant - was not as good as I hoped.", "countryHint": "CA"}]}' - headers: - Accept: - - application/json - Content-Length: - - '288' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"documents":[{"id":"0","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"1","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"2","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]}],"errors":[],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: 3e8bed5c-9150-46ab-ac76-1ef9977b0073 - content-type: application/json; charset=utf-8 - csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:06:49 GMT - strict-transport-security: max-age=31536000; includeSubDomains; preload - transfer-encoding: chunked - x-content-type-options: nosniff - x-envoy-upstream-service-time: '3' - status: - code: 200 - message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/languages?showStats=false -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_whole_batch_country_hint_and_dict_input.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_whole_batch_country_hint_and_dict_input.yaml deleted file mode 100644 index 312abc38ffbe..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_whole_batch_country_hint_and_dict_input.yaml +++ /dev/null @@ -1,35 +0,0 @@ -interactions: -- request: - body: '{"documents": [{"id": "1", "text": "I will go to the park.", "countryHint": - "CA"}, {"id": "2", "text": "I did not like the hotel we stayed at.", "countryHint": - "CA"}, {"id": "3", "text": "The restaurant had really good food.", "countryHint": - "CA"}]}' - headers: - Accept: - - application/json - Content-Length: - - '249' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"documents":[{"id":"1","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"2","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"3","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]}],"errors":[],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: 0a7a289b-bb67-4e32-9a92-7ac06f1d850e - content-type: application/json; charset=utf-8 - csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:06:50 GMT - strict-transport-security: max-age=31536000; includeSubDomains; preload - transfer-encoding: chunked - x-content-type-options: nosniff - x-envoy-upstream-service-time: '3' - status: - code: 200 - message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/languages?showStats=false -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_whole_batch_country_hint_and_dict_per_item_hints.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_whole_batch_country_hint_and_dict_per_item_hints.yaml deleted file mode 100644 index 5223f3e95b85..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_whole_batch_country_hint_and_dict_per_item_hints.yaml +++ /dev/null @@ -1,35 +0,0 @@ -interactions: -- request: - body: '{"documents": [{"id": "1", "text": "I will go to the park.", "countryHint": - "US"}, {"id": "2", "text": "I did not like the hotel we stayed at.", "countryHint": - "US"}, {"id": "3", "text": "The restaurant had really good food.", "countryHint": - "CA"}]}' - headers: - Accept: - - application/json - Content-Length: - - '249' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"documents":[{"id":"1","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"2","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"3","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]}],"errors":[],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: b085cbe2-1c41-4942-b66a-c57e3223b2ac - content-type: application/json; charset=utf-8 - csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:06:50 GMT - strict-transport-security: max-age=31536000; includeSubDomains; preload - transfer-encoding: chunked - x-content-type-options: nosniff - x-envoy-upstream-service-time: '3' - status: - code: 200 - message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/languages?showStats=false -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_whole_batch_country_hint_and_obj_input.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_whole_batch_country_hint_and_obj_input.yaml deleted file mode 100644 index e8a4c431f5c1..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_whole_batch_country_hint_and_obj_input.yaml +++ /dev/null @@ -1,35 +0,0 @@ -interactions: -- request: - body: '{"documents": [{"id": "1", "text": "I should take my cat to the veterinarian.", - "countryHint": "CA"}, {"id": "2", "text": "Este es un document escrito en Espa\u00f1ol.", - "countryHint": "CA"}, {"id": "3", "text": "\u732b\u306f\u5e78\u305b", "countryHint": - "CA"}]}' - headers: - Accept: - - application/json - Content-Length: - - '262' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"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":"Japanese","iso6391Name":"ja","score":1.0}]}],"errors":[],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: c6a55b24-7732-407d-9f46-c45bc59da52f - content-type: application/json; charset=utf-8 - csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:06:51 GMT - strict-transport-security: max-age=31536000; includeSubDomains; preload - transfer-encoding: chunked - x-content-type-options: nosniff - x-envoy-upstream-service-time: '3' - status: - code: 200 - message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/languages?showStats=false -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_whole_batch_country_hint_and_obj_per_item_hints.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_whole_batch_country_hint_and_obj_per_item_hints.yaml deleted file mode 100644 index 279bdc23cb27..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_whole_batch_country_hint_and_obj_per_item_hints.yaml +++ /dev/null @@ -1,35 +0,0 @@ -interactions: -- request: - body: '{"documents": [{"id": "1", "text": "I should take my cat to the veterinarian.", - "countryHint": "CA"}, {"id": "4", "text": "Este es un document escrito en Espa\u00f1ol.", - "countryHint": "CA"}, {"id": "3", "text": "\u732b\u306f\u5e78\u305b", "countryHint": - "US"}]}' - headers: - Accept: - - application/json - Content-Length: - - '262' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"documents":[{"id":"1","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"4","detectedLanguages":[{"name":"Spanish","iso6391Name":"es","score":1.0}]},{"id":"3","detectedLanguages":[{"name":"Japanese","iso6391Name":"ja","score":1.0}]}],"errors":[],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: c2ee5fcb-edaa-43dd-bed0-1836c7978999 - content-type: application/json; charset=utf-8 - csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:06:51 GMT - strict-transport-security: max-age=31536000; includeSubDomains; preload - transfer-encoding: chunked - x-content-type-options: nosniff - x-envoy-upstream-service-time: '4' - status: - code: 200 - message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/languages?showStats=false -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_whole_batch_dont_use_country_hint.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_whole_batch_dont_use_country_hint.yaml deleted file mode 100644 index ad1daa3edb77..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_detect_language_async.test_whole_batch_dont_use_country_hint.yaml +++ /dev/null @@ -1,35 +0,0 @@ -interactions: -- request: - body: '{"documents": [{"id": "0", "text": "This was the best day of my life.", - "countryHint": ""}, {"id": "1", "text": "I did not like the hotel we stayed - at. It was too expensive.", "countryHint": ""}, {"id": "2", "text": "The restaurant - was not as good as I hoped.", "countryHint": ""}]}' - headers: - Accept: - - application/json - Content-Length: - - '282' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/languages?showStats=false - response: - body: - string: '{"documents":[{"id":"0","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"1","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]},{"id":"2","detectedLanguages":[{"name":"English","iso6391Name":"en","score":1.0}]}],"errors":[],"modelVersion":"2019-10-01"}' - headers: - apim-request-id: 450a9d3b-6b31-4456-81e4-dc2c87caee1b - content-type: application/json; charset=utf-8 - csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:06:51 GMT - strict-transport-security: max-age=31536000; includeSubDomains; preload - transfer-encoding: chunked - x-content-type-options: nosniff - x-envoy-upstream-service-time: '3' - status: - code: 200 - message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/languages?showStats=false -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_all_successful_passing_dict.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_all_successful_passing_dict.yaml deleted file mode 100644 index 2448266ba004..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_all_successful_passing_dict.yaml +++ /dev/null @@ -1,45 +0,0 @@ -interactions: -- request: - body: '{"documents": [{"id": "1", "text": "Microsoft was founded by Bill Gates - and Paul Allen on April 4, 1975.", "language": "en"}, {"id": "2", "text": "Microsoft - fue fundado por Bill Gates y Paul Allen el 4 de abril de 1975.", "language": - "es"}, {"id": "3", "text": "Microsoft wurde am 4. April 1975 von Bill Gates - und Paul Allen gegr\u00fcndet.", "language": "de"}]}' - headers: - Accept: - - application/json - Content-Length: - - '362' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=true - response: - body: - string: '{"statistics":{"documentsCount":3,"validDocumentsCount":3,"erroneousDocumentsCount":0,"transactionsCount":3},"documents":[{"id":"1","statistics":{"charactersCount":68,"transactionsCount":1},"entities":[{"text":"Microsoft","type":"Organization","offset":0,"length":9,"score":1.0},{"text":"Bill - Gates","type":"Person","offset":25,"length":10,"score":0.67},{"text":"Paul - Allen","type":"Person","offset":40,"length":10,"score":0.81},{"text":"April - 4, 1975","type":"DateTime","subtype":"Date","offset":54,"length":13,"score":0.8}]},{"id":"2","statistics":{"charactersCount":72,"transactionsCount":1},"entities":[{"text":"Microsoft","type":"Organization","offset":0,"length":9,"score":1.0},{"text":"Bill - Gates","type":"Person","offset":26,"length":10,"score":0.8},{"text":"Paul - Allen","type":"Person","offset":39,"length":10,"score":0.78},{"text":"4 de - abril de 1975","type":"DateTime","subtype":"Date","offset":53,"length":18,"score":0.8}]},{"id":"3","statistics":{"charactersCount":73,"transactionsCount":1},"entities":[{"text":"Microsoft","type":"Organization","offset":0,"length":9,"score":1.0},{"text":"4. - April 1975","type":"DateTime","subtype":"Date","offset":19,"length":13,"score":0.8},{"text":"Bill - Gates","type":"Person","offset":37,"length":10,"score":0.86},{"text":"Paul - Allen","type":"Person","offset":52,"length":10,"score":0.98}]}],"errors":[],"modelVersion":"2020-02-01"}' - headers: - apim-request-id: eebd3023-6aea-44f6-9565-66a5c637da77 - content-type: application/json; charset=utf-8 - csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:07:32 GMT - strict-transport-security: max-age=31536000; includeSubDomains; preload - transfer-encoding: chunked - x-content-type-options: nosniff - x-envoy-upstream-service-time: '60' - status: - code: 200 - message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/recognition/general?showStats=true -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_all_successful_passing_text_document_input.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_all_successful_passing_text_document_input.yaml deleted file mode 100644 index fb86e98e7b47..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_all_successful_passing_text_document_input.yaml +++ /dev/null @@ -1,45 +0,0 @@ -interactions: -- request: - body: '{"documents": [{"id": "1", "text": "Microsoft was founded by Bill Gates - and Paul Allen on April 4, 1975.", "language": "en"}, {"id": "2", "text": "Microsoft - fue fundado por Bill Gates y Paul Allen el 4 de abril de 1975.", "language": - "es"}, {"id": "3", "text": "Microsoft wurde am 4. April 1975 von Bill Gates - und Paul Allen gegr\u00fcndet.", "language": "de"}]}' - headers: - Accept: - - application/json - Content-Length: - - '362' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false - response: - body: - string: '{"documents":[{"id":"1","entities":[{"text":"Microsoft","type":"Organization","offset":0,"length":9,"score":1.0},{"text":"Bill - Gates","type":"Person","offset":25,"length":10,"score":0.67},{"text":"Paul - Allen","type":"Person","offset":40,"length":10,"score":0.81},{"text":"April - 4, 1975","type":"DateTime","subtype":"Date","offset":54,"length":13,"score":0.8}]},{"id":"2","entities":[{"text":"Microsoft","type":"Organization","offset":0,"length":9,"score":1.0},{"text":"Bill - Gates","type":"Person","offset":26,"length":10,"score":0.8},{"text":"Paul - Allen","type":"Person","offset":39,"length":10,"score":0.78},{"text":"4 de - abril de 1975","type":"DateTime","subtype":"Date","offset":53,"length":18,"score":0.8}]},{"id":"3","entities":[{"text":"Microsoft","type":"Organization","offset":0,"length":9,"score":1.0},{"text":"4. - April 1975","type":"DateTime","subtype":"Date","offset":19,"length":13,"score":0.8},{"text":"Bill - Gates","type":"Person","offset":37,"length":10,"score":0.86},{"text":"Paul - Allen","type":"Person","offset":52,"length":10,"score":0.98}]}],"errors":[],"modelVersion":"2020-02-01"}' - headers: - apim-request-id: 9a7646f2-90fe-46ba-b7e5-25b2813d9443 - content-type: application/json; charset=utf-8 - csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:07:32 GMT - strict-transport-security: max-age=31536000; includeSubDomains; preload - transfer-encoding: chunked - x-content-type-options: nosniff - x-envoy-upstream-service-time: '59' - status: - code: 200 - message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_bad_credentials.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_bad_credentials.yaml index 106993028720..70d1ca74f538 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_bad_credentials.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_bad_credentials.yaml @@ -10,20 +10,25 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: - string: '{"error":{"code":"401","message":"Access denied due to invalid subscription + string: '{"error":{"code":"401","message": "Access denied due to invalid subscription key or wrong API endpoint. Make sure to provide a valid key for an active subscription and use a correct regional API endpoint for your resource."}}' headers: - content-length: '224' - date: Thu, 02 Apr 2020 15:07:33 GMT + apim-request-id: 61905e73-8f5b-4a25-a644-db1532badc53 + content-length: '225' + content-type: application/json + date: Thu, 23 Apr 2020 18:32:42 GMT + strict-transport-security: max-age=31536000; includeSubDomains; preload + www-authenticate: AzureApiManagementKey realm="https://westus2.ppe.cognitiveservices.azure.com/text/analytics",name="Ocp-Apim-Subscription-Key",type="header" + x-content-type-options: nosniff status: code: 401 - message: PermissionDenied - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + message: Access Denied + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_bad_model_version.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_bad_model_version.yaml index 587450410b8b..8aa4226f14bf 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_bad_model_version.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_bad_model_version.yaml @@ -10,24 +10,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?model-version=old&showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?model-version=old&showStats=false response: body: string: '{"error":{"code":"InvalidRequest","message":"Specified Model version - is incorrect. Allowed values are latest,2019-10-01,2020-02-01"}}' + is incorrect. Allowed values are latest,2020-04-01,2019-10-01,2020-02-01"}}' headers: - apim-request-id: 7b5d1c6e-3000-4ca3-b067-682d13288c3f + apim-request-id: 2bd6d988-808e-44d1-addd-1511712a375e content-type: application/json; charset=utf-8 - date: Thu, 02 Apr 2020 15:07:33 GMT + date: Thu, 23 Apr 2020 18:32:43 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '5' + x-envoy-upstream-service-time: '4' status: code: 400 message: Bad Request - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/recognition/general?model-version=old&showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?model-version=old&showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_bad_model_version_error.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_bad_model_version_error.yaml index 48ba09a38d2f..c2bd748e2089 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_bad_model_version_error.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_bad_model_version_error.yaml @@ -10,24 +10,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?model-version=bad&showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?model-version=bad&showStats=false response: body: string: '{"error":{"code":"InvalidRequest","message":"Specified Model version - is incorrect. Allowed values are latest,2019-10-01,2020-02-01"}}' + is incorrect. Allowed values are latest,2020-04-01,2019-10-01,2020-02-01"}}' headers: - apim-request-id: 92e8a57a-6652-4d73-8226-fe7dc9efdd52 + apim-request-id: e7da4a41-3988-4f25-bb65-bf2f2a57f864 content-type: application/json; charset=utf-8 - date: Thu, 02 Apr 2020 15:07:33 GMT + date: Thu, 23 Apr 2020 18:32:44 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '5' + x-envoy-upstream-service-time: '3' status: code: 400 message: Bad Request - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/recognition/general?model-version=bad&showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?model-version=bad&showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_batch_size_over_limit.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_batch_size_over_limit.yaml index dcc3f9365489..a424a710b8c3 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_batch_size_over_limit.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_batch_size_over_limit.yaml @@ -754,24 +754,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: - string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innerError":{"code":"InvalidDocumentBatch","message":"Batch + string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innererror":{"code":"InvalidDocumentBatch","message":"Batch request contains too many records. Max 1000 records are permitted."}}}' headers: - apim-request-id: c4b22725-af35-4226-b66c-536854f039bb + apim-request-id: d6adda55-c4a3-40dd-a86d-0bb78c4266a7 content-type: application/json; charset=utf-8 - date: Thu, 02 Apr 2020 15:07:35 GMT + date: Thu, 23 Apr 2020 18:32:45 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '12' + x-envoy-upstream-service-time: '19' status: code: 400 message: Bad Request - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_batch_size_over_limit_error.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_batch_size_over_limit_error.yaml index f862f6ccd597..99270a80a790 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_batch_size_over_limit_error.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_batch_size_over_limit_error.yaml @@ -719,24 +719,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: - string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innerError":{"code":"InvalidDocumentBatch","message":"Batch + string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innererror":{"code":"InvalidDocumentBatch","message":"Batch request contains too many records. Max 1000 records are permitted."}}}' headers: - apim-request-id: e7ed60d7-a87b-4f7d-bd04-061ee79d00b4 + apim-request-id: 6fbbabf3-73ac-4e0d-9b55-4c6d2a89afba content-type: application/json; charset=utf-8 - date: Thu, 02 Apr 2020 15:07:35 GMT + date: Thu, 23 Apr 2020 18:32:45 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '14' + x-envoy-upstream-service-time: '21' status: code: 400 message: Bad Request - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_client_passed_default_language_hint.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_client_passed_default_language_hint.yaml index 6dbfecac036f..67f86a164f34 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_client_passed_default_language_hint.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_client_passed_default_language_hint.yaml @@ -12,26 +12,26 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: - string: '{"documents":[{"id":"1","entities":[]},{"id":"2","entities":[]},{"id":"3","entities":[]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"1","entities":[],"warnings":[]},{"id":"2","entities":[],"warnings":[]},{"id":"3","entities":[],"warnings":[]}],"errors":[],"modelVersion":"2020-04-01"}' headers: - apim-request-id: b8598bd8-e5e1-461d-8d7e-b95834738afd + apim-request-id: 93ed1cc2-504f-437e-8a68-bbeffd2e8399 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:07:35 GMT + date: Thu, 23 Apr 2020 18:32:46 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '14' + x-envoy-upstream-service-time: '16' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false - request: body: '{"documents": [{"id": "1", "text": "I will go to the park.", "language": "en"}, {"id": "2", "text": "I did not like the hotel we stayed at.", "language": @@ -45,26 +45,26 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: - string: '{"documents":[{"id":"1","entities":[{"text":"park","type":"Location","offset":17,"length":4,"score":0.73}]},{"id":"2","entities":[{"text":"hotel","type":"Location","offset":19,"length":5,"score":0.75}]},{"id":"3","entities":[{"text":"restaurant","type":"Location","offset":4,"length":10,"score":0.83}]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"1","entities":[{"text":"park","category":"Location","subcategory":"LOCATION.STRUCTURAL","offset":17,"length":4,"confidenceScore":0.83}],"warnings":[]},{"id":"2","entities":[{"text":"hotel","category":"Location","offset":19,"length":5,"confidenceScore":0.75}],"warnings":[]},{"id":"3","entities":[{"text":"restaurant","category":"Location","subcategory":"LOCATION.STRUCTURAL","offset":4,"length":10,"confidenceScore":0.71}],"warnings":[]}],"errors":[],"modelVersion":"2020-04-01"}' headers: - apim-request-id: 20428de5-ea4c-4add-b987-ac16f874eb39 + apim-request-id: fd09d6a6-b203-4429-971a-0bc02ec44900 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:07:35 GMT + date: Thu, 23 Apr 2020 18:32:46 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '66' + x-envoy-upstream-service-time: '94' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false - request: body: '{"documents": [{"id": "1", "text": "I will go to the park.", "language": "es"}, {"id": "2", "text": "I did not like the hotel we stayed at.", "language": @@ -78,24 +78,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: - string: '{"documents":[{"id":"1","entities":[]},{"id":"2","entities":[]},{"id":"3","entities":[]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"1","entities":[],"warnings":[]},{"id":"2","entities":[],"warnings":[]},{"id":"3","entities":[],"warnings":[]}],"errors":[],"modelVersion":"2020-04-01"}' headers: - apim-request-id: 6f89088e-9047-4771-9e8d-6e2df9cc3d31 + apim-request-id: 8beccbb7-042d-4f59-a0d9-0a71e1e6e6e8 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:07:36 GMT + date: Thu, 23 Apr 2020 18:32:46 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '12' + x-envoy-upstream-service-time: '22' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_document_attribute_error_no_result_attribute.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_document_attribute_error_no_result_attribute.yaml index b3e3ceb960b2..d89a5e27d6af 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_document_attribute_error_no_result_attribute.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_document_attribute_error_no_result_attribute.yaml @@ -9,25 +9,25 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: string: '{"documents":[],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document - text is empty."}}}],"modelVersion":"2020-02-01"}' + document in request.","innererror":{"code":"InvalidDocument","message":"Document + text is empty."}}}],"modelVersion":"2020-04-01"}' headers: - apim-request-id: fd76e426-bf77-4876-9733-129a2af8f6ea + apim-request-id: 33637288-4d32-4fa9-aa62-a4c5ff018fbc content-type: application/json; charset=utf-8 - date: Thu, 02 Apr 2020 15:07:36 GMT + date: Thu, 23 Apr 2020 18:32:47 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '2' + x-envoy-upstream-service-time: '1' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_document_attribute_error_nonexistent_attribute.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_document_attribute_error_nonexistent_attribute.yaml index b3a3592b15c4..cc1a321b67e6 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_document_attribute_error_nonexistent_attribute.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_document_attribute_error_nonexistent_attribute.yaml @@ -9,19 +9,19 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: string: '{"documents":[],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document - text is empty."}}}],"modelVersion":"2020-02-01"}' + document in request.","innererror":{"code":"InvalidDocument","message":"Document + text is empty."}}}],"modelVersion":"2020-04-01"}' headers: - apim-request-id: c26c7226-6b07-4bfe-a06f-b9dfd265965a + apim-request-id: 9e017d67-6872-4103-8f5a-9180bf704283 content-type: application/json; charset=utf-8 - date: Thu, 02 Apr 2020 15:07:37 GMT + date: Thu, 23 Apr 2020 18:32:47 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff @@ -29,5 +29,5 @@ interactions: status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_document_errors.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_document_errors.yaml index 137436bd8d11..1274542b96c9 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_document_errors.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_document_errors.yaml @@ -12,25 +12,25 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: string: '{"documents":[],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}},{"id":"2","error":{"code":"InvalidArgument","message":"Invalid - Language Code.","innerError":{"code":"UnsupportedLanguageCode","message":"Supplied + Language Code.","innererror":{"code":"UnsupportedLanguageCode","message":"Supplied language not supported. Pass in one of: ar,cs,da,de,en,es,fi,fr,hu,it,ja,ko,nl,no,pl,pt-BR,pt-PT,ru,sv,tr,zh-Hans"}}},{"id":"3","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"A + document in request.","innererror":{"code":"InvalidDocument","message":"A document within the request was too large to be processed. Limit document size to: 5120 text elements. For additional details on the data limitations - see https://aka.ms/text-analytics-data-limits"}}}],"modelVersion":"2020-02-01"}' + see https://aka.ms/text-analytics-data-limits"}}}],"modelVersion":"2020-04-01"}' headers: - apim-request-id: b635a236-1a0e-403f-9201-1509ba7d0ccf + apim-request-id: 0deaae36-719a-420c-9306-468094820996 content-type: application/json; charset=utf-8 - date: Thu, 02 Apr 2020 15:07:37 GMT + date: Thu, 23 Apr 2020 18:32:47 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff @@ -38,5 +38,5 @@ interactions: status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_duplicate_ids_error.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_duplicate_ids_error.yaml index 4cca3e6bb3ec..90e820ff4132 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_duplicate_ids_error.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_duplicate_ids_error.yaml @@ -10,24 +10,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: - string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innerError":{"code":"InvalidDocument","message":"Request + string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innererror":{"code":"InvalidDocument","message":"Request contains duplicated Ids. Make sure each document has a unique Id."}}}' headers: - apim-request-id: 8710e209-8c31-4e8b-95f6-e78a612bdbeb + apim-request-id: ae95c3e5-6c7e-4086-9256-79afd1c2d626 content-type: application/json; charset=utf-8 - date: Thu, 02 Apr 2020 15:07:37 GMT + date: Thu, 23 Apr 2020 18:32:47 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '6' + x-envoy-upstream-service-time: '4' status: code: 400 message: Bad Request - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_empty_credential_class.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_empty_credential_class.yaml index 8ea7f632644a..2c217c6c3229 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_empty_credential_class.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_empty_credential_class.yaml @@ -10,20 +10,25 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: - string: '{"error":{"code":"401","message":"Access denied due to invalid subscription + string: '{"error":{"code":"401","message": "Access denied due to invalid subscription key or wrong API endpoint. Make sure to provide a valid key for an active subscription and use a correct regional API endpoint for your resource."}}' headers: - content-length: '224' - date: Thu, 02 Apr 2020 15:07:38 GMT + apim-request-id: 9e802b1e-09e8-481e-9aa5-7e55eff56a5d + content-length: '225' + content-type: application/json + date: Thu, 23 Apr 2020 18:32:48 GMT + strict-transport-security: max-age=31536000; includeSubDomains; preload + www-authenticate: AzureApiManagementKey realm="https://westus2.ppe.cognitiveservices.azure.com/text/analytics",name="Ocp-Apim-Subscription-Key",type="header" + x-content-type-options: nosniff status: code: 401 - message: PermissionDenied - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + message: Access Denied + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_input_with_all_errors.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_input_with_all_errors.yaml index 07aaa71ac8b7..daefaf6477a4 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_input_with_all_errors.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_input_with_all_errors.yaml @@ -10,29 +10,29 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: string: '{"documents":[],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}},{"id":"2","error":{"code":"InvalidArgument","message":"Invalid - Language Code.","innerError":{"code":"UnsupportedLanguageCode","message":"Supplied + Language Code.","innererror":{"code":"UnsupportedLanguageCode","message":"Supplied language not supported. Pass in one of: ar,cs,da,de,en,es,fi,fr,hu,it,ja,ko,nl,no,pl,pt-BR,pt-PT,ru,sv,tr,zh-Hans"}}},{"id":"3","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document - text is empty."}}}],"modelVersion":"2020-02-01"}' + document in request.","innererror":{"code":"InvalidDocument","message":"Document + text is empty."}}}],"modelVersion":"2020-04-01"}' headers: - apim-request-id: c611f921-f78f-4e73-a5cb-8e432ac26363 + apim-request-id: c11594d6-4864-41fe-8c7d-fc10e817087d content-type: application/json; charset=utf-8 - date: Thu, 02 Apr 2020 15:07:38 GMT + date: Thu, 23 Apr 2020 18:32:48 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '3' + x-envoy-upstream-service-time: '2' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_input_with_some_errors.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_input_with_some_errors.yaml index d7f810621671..e27eb801b75f 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_input_with_some_errors.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_input_with_some_errors.yaml @@ -11,31 +11,31 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: - string: '{"documents":[{"id":"1","entities":[{"text":"Microsoft","type":"Organization","offset":0,"length":9,"score":1.0},{"text":"Bill - Gates","type":"Person","offset":25,"length":10,"score":0.67},{"text":"Paul - Allen","type":"Person","offset":40,"length":10,"score":0.81},{"text":"April - 4, 1975","type":"DateTime","subtype":"Date","offset":54,"length":13,"score":0.8}]}],"errors":[{"id":"2","error":{"code":"InvalidArgument","message":"Invalid - Language Code.","innerError":{"code":"UnsupportedLanguageCode","message":"Supplied + string: '{"documents":[{"id":"1","entities":[{"text":"Microsoft","category":"Organization","offset":0,"length":9,"confidenceScore":0.49},{"text":"Bill + Gates","category":"Person","offset":25,"length":10,"confidenceScore":0.47},{"text":"Paul + Allen","category":"Person","offset":40,"length":10,"confidenceScore":0.69},{"text":"April + 4, 1975","category":"DateTime","subcategory":"Date","offset":54,"length":13,"confidenceScore":0.8}],"warnings":[]}],"errors":[{"id":"2","error":{"code":"InvalidArgument","message":"Invalid + Language Code.","innererror":{"code":"UnsupportedLanguageCode","message":"Supplied language not supported. Pass in one of: ar,cs,da,de,en,es,fi,fr,hu,it,ja,ko,nl,no,pl,pt-BR,pt-PT,ru,sv,tr,zh-Hans"}}},{"id":"3","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document - text is empty."}}}],"modelVersion":"2020-02-01"}' + document in request.","innererror":{"code":"InvalidDocument","message":"Document + text is empty."}}}],"modelVersion":"2020-04-01"}' headers: - apim-request-id: 6a1a505a-e4d8-4f52-a280-9fd8b5b042a9 + apim-request-id: 21aad5b9-83c4-4ffb-9998-04b99bebb6ec content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=1 - date: Thu, 02 Apr 2020 15:07:38 GMT + date: Thu, 23 Apr 2020 18:32:48 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '62' + x-envoy-upstream-service-time: '94' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_language_kwarg_spanish.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_language_kwarg_spanish.yaml index 23bede5d3790..4834a8076fdd 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_language_kwarg_spanish.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_language_kwarg_spanish.yaml @@ -10,25 +10,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?model-version=latest&showStats=true + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?model-version=latest&showStats=true response: body: - string: '{"statistics":{"documentsCount":1,"validDocumentsCount":1,"erroneousDocumentsCount":0,"transactionsCount":1},"documents":[{"id":"0","statistics":{"charactersCount":35,"transactionsCount":1},"entities":[{"text":"Bill - Gates","type":"Person","offset":0,"length":10,"score":0.8},{"text":"Microsoft","type":"Organization","offset":25,"length":9,"score":0.98}]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"statistics":{"documentsCount":1,"validDocumentsCount":1,"erroneousDocumentsCount":0,"transactionsCount":1},"documents":[{"id":"0","statistics":{"charactersCount":35,"transactionsCount":1},"entities":[],"warnings":[]}],"errors":[],"modelVersion":"2020-04-01"}' headers: - apim-request-id: aee8a027-007b-4b91-8284-637976fff833 + apim-request-id: 8309d578-1691-46c4-9843-f8f7d488858d content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=1 - date: Thu, 02 Apr 2020 15:07:39 GMT + date: Thu, 23 Apr 2020 18:32:48 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '11' + x-envoy-upstream-service-time: '13' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/recognition/general?model-version=latest&showStats=true + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?model-version=latest&showStats=true version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_missing_input_records_error.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_missing_input_records_error.yaml deleted file mode 100644 index 2028f50f7ac3..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_missing_input_records_error.yaml +++ /dev/null @@ -1,32 +0,0 @@ -interactions: -- request: - body: '{"documents": []}' - headers: - Accept: - - application/json - Content-Length: - - '17' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false - response: - body: - string: '{"error":{"code":"InvalidRequest","message":"Invalid Request.","innerError":{"code":"MissingInputRecords","message":"Missing - input records."}}}' - headers: - apim-request-id: d002935e-f5e9-463f-a7f7-49b24bb0db37 - content-type: application/json; charset=utf-8 - date: Thu, 02 Apr 2020 15:07:40 GMT - strict-transport-security: max-age=31536000; includeSubDomains; preload - transfer-encoding: chunked - x-content-type-options: nosniff - x-envoy-upstream-service-time: '3' - status: - code: 400 - message: Bad Request - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_out_of_order_ids.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_out_of_order_ids.yaml index b3d8c61dfb2f..f968d8dd8e0e 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_out_of_order_ids.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_out_of_order_ids.yaml @@ -12,26 +12,26 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: - string: '{"documents":[{"id":"56","entities":[]},{"id":"0","entities":[]},{"id":"19","entities":[]},{"id":"1","entities":[]}],"errors":[{"id":"22","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document - text is empty."}}}],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"56","entities":[],"warnings":[]},{"id":"0","entities":[],"warnings":[]},{"id":"19","entities":[],"warnings":[]},{"id":"1","entities":[],"warnings":[]}],"errors":[{"id":"22","error":{"code":"InvalidArgument","message":"Invalid + document in request.","innererror":{"code":"InvalidDocument","message":"Document + text is empty."}}}],"modelVersion":"2020-04-01"}' headers: - apim-request-id: 3edcd9d5-60a3-4ecb-998d-5047a6ec6bcb + apim-request-id: 64eba858-5e82-49c0-bc46-caa0e5f33a97 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=4 - date: Thu, 02 Apr 2020 15:07:40 GMT + date: Thu, 23 Apr 2020 18:32:50 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '39' + x-envoy-upstream-service-time: '63' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_pass_cls.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_pass_cls.yaml index 3ba5adc87a19..06eacc1a66b2 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_pass_cls.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_pass_cls.yaml @@ -10,24 +10,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: - string: '{"documents":[{"id":"0","entities":[{"text":"cls","type":"Skill","offset":13,"length":3,"score":0.8}]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"0","entities":[],"warnings":[]}],"errors":[],"modelVersion":"2020-04-01"}' headers: - apim-request-id: e0d9eebc-c92e-428f-b7cf-e33a472da04d + apim-request-id: b9e14841-87c2-4148-bb2b-3223aa7e4627 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=1 - date: Thu, 02 Apr 2020 15:07:40 GMT + date: Thu, 23 Apr 2020 18:32:50 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '37' + x-envoy-upstream-service-time: '69' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_passing_only_string.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_passing_only_string.yaml index 91e14c15dd8a..90bdb9b88cd3 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_passing_only_string.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_passing_only_string.yaml @@ -14,45 +14,44 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: string: "{\"documents\":[{\"id\":\"0\",\"entities\":[{\"text\":\"Microsoft\"\ - ,\"type\":\"Organization\",\"offset\":0,\"length\":9,\"score\":1.0},{\"text\"\ - :\"Bill Gates\",\"type\":\"Person\",\"offset\":25,\"length\":10,\"score\"\ - :0.67},{\"text\":\"Paul Allen\",\"type\":\"Person\",\"offset\":40,\"length\"\ - :10,\"score\":0.81},{\"text\":\"April 4, 1975\",\"type\":\"DateTime\",\"subtype\"\ - :\"Date\",\"offset\":54,\"length\":13,\"score\":0.8}]},{\"id\":\"1\",\"entities\"\ - :[{\"text\":\"Microsoft\",\"type\":\"Organization\",\"offset\":0,\"length\"\ - :9,\"score\":1.0},{\"text\":\"Bill Gates\",\"type\":\"Person\",\"offset\"\ - :26,\"length\":10,\"score\":0.45},{\"text\":\"Paul Allen\",\"type\":\"Person\"\ - ,\"offset\":39,\"length\":10,\"score\":0.69},{\"text\":\"4\",\"type\":\"Quantity\"\ - ,\"subtype\":\"Number\",\"offset\":53,\"length\":1,\"score\":0.8},{\"text\"\ - :\"1975\",\"type\":\"DateTime\",\"subtype\":\"DateRange\",\"offset\":67,\"\ - length\":4,\"score\":0.8}]},{\"id\":\"2\",\"entities\":[{\"text\":\"Microsoft\"\ - ,\"type\":\"Organization\",\"offset\":0,\"length\":9,\"score\":1.0},{\"text\"\ - :\"4\",\"type\":\"Quantity\",\"subtype\":\"Number\",\"offset\":19,\"length\"\ - :1,\"score\":0.8},{\"text\":\"April 1975\",\"type\":\"DateTime\",\"subtype\"\ - :\"DateRange\",\"offset\":22,\"length\":10,\"score\":0.8},{\"text\":\"Paul\ - \ Allen gegr\xFCndet\",\"type\":\"Person\",\"offset\":52,\"length\":20,\"\ - score\":0.47}]}],\"errors\":[{\"id\":\"3\",\"error\":{\"code\":\"InvalidArgument\"\ - ,\"message\":\"Invalid document in request.\",\"innerError\":{\"code\":\"\ - InvalidDocument\",\"message\":\"Document text is empty.\"}}}],\"modelVersion\"\ - :\"2020-02-01\"}" + ,\"category\":\"Organization\",\"offset\":0,\"length\":9,\"confidenceScore\"\ + :0.5},{\"text\":\"Bill Gates\",\"category\":\"Person\",\"offset\":25,\"length\"\ + :10,\"confidenceScore\":0.47},{\"text\":\"Paul Allen\",\"category\":\"Person\"\ + ,\"offset\":40,\"length\":10,\"confidenceScore\":0.7},{\"text\":\"April 4,\ + \ 1975\",\"category\":\"DateTime\",\"subcategory\":\"Date\",\"offset\":54,\"\ + length\":13,\"confidenceScore\":0.8}],\"warnings\":[]},{\"id\":\"1\",\"entities\"\ + :[{\"text\":\"4\",\"category\":\"Quantity\",\"subcategory\":\"Number\",\"\ + offset\":53,\"length\":1,\"confidenceScore\":0.8},{\"text\":\"1975\",\"category\"\ + :\"DateTime\",\"subcategory\":\"DateRange\",\"offset\":67,\"length\":4,\"\ + confidenceScore\":0.8}],\"warnings\":[]},{\"id\":\"2\",\"entities\":[{\"text\"\ + :\"Microsoft\",\"category\":\"Organization\",\"offset\":0,\"length\":9,\"\ + confidenceScore\":0.33},{\"text\":\"4\",\"category\":\"Quantity\",\"subcategory\"\ + :\"Number\",\"offset\":19,\"length\":1,\"confidenceScore\":0.8},{\"text\"\ + :\"April 1975\",\"category\":\"DateTime\",\"subcategory\":\"DateRange\",\"\ + offset\":22,\"length\":10,\"confidenceScore\":0.8},{\"text\":\"von Bill Gates\ + \ und Paul Allen gegr\xFCndet\",\"category\":\"Person\",\"offset\":33,\"length\"\ + :39,\"confidenceScore\":0.52}],\"warnings\":[]}],\"errors\":[{\"id\":\"3\"\ + ,\"error\":{\"code\":\"InvalidArgument\",\"message\":\"Invalid document in\ + \ request.\",\"innererror\":{\"code\":\"InvalidDocument\",\"message\":\"Document\ + \ text is empty.\"}}}],\"modelVersion\":\"2020-04-01\"}" headers: - apim-request-id: 29c06732-3855-493a-b91c-5d51d848186e + apim-request-id: 5db852cc-61bf-430e-aa94-0b56159e7197 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:07:41 GMT + date: Thu, 23 Apr 2020 18:32:50 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '80' + x-envoy-upstream-service-time: '121' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_per_item_dont_use_language_hint.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_per_item_dont_use_language_hint.yaml index d1110cdf41a8..b8d5cbbd1258 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_per_item_dont_use_language_hint.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_per_item_dont_use_language_hint.yaml @@ -12,24 +12,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: - string: '{"documents":[{"id":"1","entities":[{"text":"park","type":"Location","offset":17,"length":4,"score":0.73}]},{"id":"2","entities":[{"text":"hotel","type":"Location","offset":19,"length":5,"score":0.75}]},{"id":"3","entities":[{"text":"restaurant","type":"Location","offset":4,"length":10,"score":0.83}]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"1","entities":[{"text":"park","category":"Location","subcategory":"LOCATION.STRUCTURAL","offset":17,"length":4,"confidenceScore":0.83}],"warnings":[]},{"id":"2","entities":[{"text":"hotel","category":"Location","offset":19,"length":5,"confidenceScore":0.75}],"warnings":[]},{"id":"3","entities":[{"text":"restaurant","category":"Location","subcategory":"LOCATION.STRUCTURAL","offset":4,"length":10,"confidenceScore":0.71}],"warnings":[]}],"errors":[],"modelVersion":"2020-04-01"}' headers: - apim-request-id: 42e8aa8a-8adf-4cf3-9cd1-bcf975632fae + apim-request-id: 865c3557-eded-46b3-b7e1-0dc47c5a473a content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:07:41 GMT + date: Thu, 23 Apr 2020 18:32:50 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '60' + x-envoy-upstream-service-time: '97' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_rotate_subscription_key.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_rotate_subscription_key.yaml index ef550b0e6df3..6ed17ed19372 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_rotate_subscription_key.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_rotate_subscription_key.yaml @@ -12,26 +12,26 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: - string: '{"documents":[{"id":"1","entities":[{"text":"park","type":"Location","offset":17,"length":4,"score":0.73}]},{"id":"2","entities":[{"text":"hotel","type":"Location","offset":19,"length":5,"score":0.75}]},{"id":"3","entities":[{"text":"restaurant","type":"Location","offset":4,"length":10,"score":0.83}]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"1","entities":[{"text":"park","category":"Location","subcategory":"LOCATION.STRUCTURAL","offset":17,"length":4,"confidenceScore":0.83}],"warnings":[]},{"id":"2","entities":[{"text":"hotel","category":"Location","offset":19,"length":5,"confidenceScore":0.75}],"warnings":[]},{"id":"3","entities":[{"text":"restaurant","category":"Location","subcategory":"LOCATION.STRUCTURAL","offset":4,"length":10,"confidenceScore":0.71}],"warnings":[]}],"errors":[],"modelVersion":"2020-04-01"}' headers: - apim-request-id: d0d203b6-9fc7-4fb1-81b4-9d18c18cf3af + apim-request-id: 5a7691b0-aef3-44be-ab06-920b52818429 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:07:42 GMT + date: Thu, 23 Apr 2020 18:32:52 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '64' + x-envoy-upstream-service-time: '85' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false - request: body: '{"documents": [{"id": "1", "text": "I will go to the park.", "language": "en"}, {"id": "2", "text": "I did not like the hotel we stayed at.", "language": @@ -45,22 +45,27 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: - string: '{"error":{"code":"401","message":"Access denied due to invalid subscription + string: '{"error":{"code":"401","message": "Access denied due to invalid subscription key or wrong API endpoint. Make sure to provide a valid key for an active subscription and use a correct regional API endpoint for your resource."}}' headers: - content-length: '224' - date: Thu, 02 Apr 2020 15:07:42 GMT + apim-request-id: f0f1e1f9-9f70-4656-94a3-ef6c14a6ba84 + content-length: '225' + content-type: application/json + date: Thu, 23 Apr 2020 18:32:52 GMT + strict-transport-security: max-age=31536000; includeSubDomains; preload + www-authenticate: AzureApiManagementKey realm="https://westus2.ppe.cognitiveservices.azure.com/text/analytics",name="Ocp-Apim-Subscription-Key",type="header" + x-content-type-options: nosniff status: code: 401 - message: PermissionDenied - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + message: Access Denied + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false - request: body: '{"documents": [{"id": "1", "text": "I will go to the park.", "language": "en"}, {"id": "2", "text": "I did not like the hotel we stayed at.", "language": @@ -74,24 +79,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: - string: '{"documents":[{"id":"1","entities":[{"text":"park","type":"Location","offset":17,"length":4,"score":0.73}]},{"id":"2","entities":[{"text":"hotel","type":"Location","offset":19,"length":5,"score":0.75}]},{"id":"3","entities":[{"text":"restaurant","type":"Location","offset":4,"length":10,"score":0.83}]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"1","entities":[{"text":"park","category":"Location","subcategory":"LOCATION.STRUCTURAL","offset":17,"length":4,"confidenceScore":0.83}],"warnings":[]},{"id":"2","entities":[{"text":"hotel","category":"Location","offset":19,"length":5,"confidenceScore":0.75}],"warnings":[]},{"id":"3","entities":[{"text":"restaurant","category":"Location","subcategory":"LOCATION.STRUCTURAL","offset":4,"length":10,"confidenceScore":0.71}],"warnings":[]}],"errors":[],"modelVersion":"2020-04-01"}' headers: - apim-request-id: cf4ef033-b512-46f5-96ce-8ea4dbe0b3f0 + apim-request-id: da7b5831-2d1d-4234-91ad-5d2cabb85e27 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:07:42 GMT + date: Thu, 23 Apr 2020 18:32:52 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '60' + x-envoy-upstream-service-time: '87' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_show_stats_and_model_version.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_show_stats_and_model_version.yaml index 145f6c502ae8..c196b20f7e15 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_show_stats_and_model_version.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_show_stats_and_model_version.yaml @@ -12,26 +12,26 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?model-version=latest&showStats=true + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?model-version=latest&showStats=true response: body: - string: '{"statistics":{"documentsCount":5,"validDocumentsCount":4,"erroneousDocumentsCount":1,"transactionsCount":4},"documents":[{"id":"56","statistics":{"charactersCount":2,"transactionsCount":1},"entities":[]},{"id":"0","statistics":{"charactersCount":2,"transactionsCount":1},"entities":[]},{"id":"19","statistics":{"charactersCount":2,"transactionsCount":1},"entities":[]},{"id":"1","statistics":{"charactersCount":2,"transactionsCount":1},"entities":[]}],"errors":[{"id":"22","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document - text is empty."}}}],"modelVersion":"2020-02-01"}' + string: '{"statistics":{"documentsCount":5,"validDocumentsCount":4,"erroneousDocumentsCount":1,"transactionsCount":4},"documents":[{"id":"56","statistics":{"charactersCount":2,"transactionsCount":1},"entities":[],"warnings":[]},{"id":"0","statistics":{"charactersCount":2,"transactionsCount":1},"entities":[],"warnings":[]},{"id":"19","statistics":{"charactersCount":2,"transactionsCount":1},"entities":[],"warnings":[]},{"id":"1","statistics":{"charactersCount":2,"transactionsCount":1},"entities":[],"warnings":[]}],"errors":[{"id":"22","error":{"code":"InvalidArgument","message":"Invalid + document in request.","innererror":{"code":"InvalidDocument","message":"Document + text is empty."}}}],"modelVersion":"2020-04-01"}' headers: - apim-request-id: 06c7ebe8-3590-4c0f-a72b-7f2b96895730 + apim-request-id: 38eab1e8-5ac5-4f8f-baea-26fd8b4edae3 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=4 - date: Thu, 02 Apr 2020 15:07:42 GMT + date: Thu, 23 Apr 2020 18:32:52 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '35' + x-envoy-upstream-service-time: '63' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/recognition/general?model-version=latest&showStats=true + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?model-version=latest&showStats=true version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_user_agent.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_user_agent.yaml index 2c2eb1cd7441..4f3b78b2e1d6 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_user_agent.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_user_agent.yaml @@ -12,24 +12,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: - string: '{"documents":[{"id":"1","entities":[{"text":"park","type":"Location","offset":17,"length":4,"score":0.73}]},{"id":"2","entities":[{"text":"hotel","type":"Location","offset":19,"length":5,"score":0.75}]},{"id":"3","entities":[{"text":"restaurant","type":"Location","offset":4,"length":10,"score":0.83}]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"1","entities":[{"text":"park","category":"Location","subcategory":"LOCATION.STRUCTURAL","offset":17,"length":4,"confidenceScore":0.83}],"warnings":[]},{"id":"2","entities":[{"text":"hotel","category":"Location","offset":19,"length":5,"confidenceScore":0.75}],"warnings":[]},{"id":"3","entities":[{"text":"restaurant","category":"Location","subcategory":"LOCATION.STRUCTURAL","offset":4,"length":10,"confidenceScore":0.71}],"warnings":[]}],"errors":[],"modelVersion":"2020-04-01"}' headers: - apim-request-id: 99fe1cdd-33a8-4fa5-82a0-759d57047f78 + apim-request-id: 335921d7-648c-4dd8-98e2-3e86b2650ea0 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:07:43 GMT + date: Thu, 23 Apr 2020 18:32:53 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '58' + x-envoy-upstream-service-time: '90' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_whole_batch_dont_use_language_hint.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_whole_batch_dont_use_language_hint.yaml index 8eb6d0235a07..51f62dc61d18 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_whole_batch_dont_use_language_hint.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_whole_batch_dont_use_language_hint.yaml @@ -12,24 +12,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: - string: '{"documents":[{"id":"0","entities":[]},{"id":"1","entities":[{"text":"hotel","type":"Location","offset":19,"length":5,"score":0.74}]},{"id":"2","entities":[{"text":"restaurant","type":"Location","offset":4,"length":10,"score":0.83}]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"0","entities":[],"warnings":[]},{"id":"1","entities":[{"text":"hotel","category":"Location","offset":19,"length":5,"confidenceScore":0.74}],"warnings":[]},{"id":"2","entities":[{"text":"restaurant","category":"Location","subcategory":"LOCATION.STRUCTURAL","offset":4,"length":10,"confidenceScore":0.73}],"warnings":[]}],"errors":[],"modelVersion":"2020-04-01"}' headers: - apim-request-id: 641d1cd4-ba63-4587-9c02-5c778de74f5c + apim-request-id: 5590c349-988e-4ca3-8f7f-c5268ab665af content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:07:43 GMT + date: Thu, 23 Apr 2020 18:32:52 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '60' + x-envoy-upstream-service-time: '92' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_whole_batch_language_hint.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_whole_batch_language_hint.yaml index 218dac777ecc..7ada4d047075 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_whole_batch_language_hint.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_whole_batch_language_hint.yaml @@ -12,24 +12,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: - string: '{"documents":[{"id":"0","entities":[]},{"id":"1","entities":[]},{"id":"2","entities":[]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"0","entities":[],"warnings":[]},{"id":"1","entities":[],"warnings":[]},{"id":"2","entities":[],"warnings":[]}],"errors":[],"modelVersion":"2020-04-01"}' headers: - apim-request-id: 293ba9f8-dbe4-494e-931e-506f28c54cf2 + apim-request-id: d654aa3b-d931-4c3a-a0d1-c7d8849cbf60 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:07:43 GMT + date: Thu, 23 Apr 2020 18:32:53 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '24' + x-envoy-upstream-service-time: '26' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_whole_batch_language_hint_and_dict_per_item_hints.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_whole_batch_language_hint_and_dict_per_item_hints.yaml index c34ddb72f7d7..6fe9726c0f1c 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_whole_batch_language_hint_and_dict_per_item_hints.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_whole_batch_language_hint_and_dict_per_item_hints.yaml @@ -12,24 +12,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: - string: '{"documents":[{"id":"1","entities":[]},{"id":"2","entities":[]},{"id":"3","entities":[{"text":"restaurant","type":"Location","offset":4,"length":10,"score":0.83}]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"1","entities":[],"warnings":[]},{"id":"2","entities":[],"warnings":[]},{"id":"3","entities":[{"text":"restaurant","category":"Location","subcategory":"LOCATION.STRUCTURAL","offset":4,"length":10,"confidenceScore":0.72}],"warnings":[]}],"errors":[],"modelVersion":"2020-04-01"}' headers: - apim-request-id: 19a19666-e3dc-4f9a-b741-097713bab437 + apim-request-id: d7d9aa74-28de-47c1-a374-57f82523cdb5 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:07:44 GMT + date: Thu, 23 Apr 2020 18:32:53 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '49' + x-envoy-upstream-service-time: '68' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_whole_batch_language_hint_and_obj_input.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_whole_batch_language_hint_and_obj_input.yaml index 0148a60bd14a..96ab9f555c6d 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_whole_batch_language_hint_and_obj_input.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_whole_batch_language_hint_and_obj_input.yaml @@ -12,24 +12,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: - string: '{"documents":[{"id":"1","entities":[]},{"id":"4","entities":[]},{"id":"3","entities":[]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"1","entities":[],"warnings":[]},{"id":"4","entities":[],"warnings":[]},{"id":"3","entities":[],"warnings":[]}],"errors":[],"modelVersion":"2020-04-01"}' headers: - apim-request-id: c493f99f-bc39-4b3d-9c53-3f269d7c5f03 + apim-request-id: 155437f6-a2d5-40b5-abd9-96d4a216fc54 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:07:45 GMT + date: Thu, 23 Apr 2020 18:32:54 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '21' + x-envoy-upstream-service-time: '20' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_whole_batch_language_hint_and_obj_per_item_hints.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_whole_batch_language_hint_and_obj_per_item_hints.yaml index d7fcca2fdf7d..e58700061cf4 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_whole_batch_language_hint_and_obj_per_item_hints.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_entities_async.test_whole_batch_language_hint_and_obj_per_item_hints.yaml @@ -12,24 +12,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false response: body: - string: '{"documents":[{"id":"1","entities":[]},{"id":"2","entities":[{"text":"un","type":"Quantity","subtype":"Number","offset":8,"length":2,"score":0.8}]},{"id":"3","entities":[]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"1","entities":[],"warnings":[]},{"id":"2","entities":[{"text":"un","category":"Quantity","subcategory":"Number","offset":8,"length":2,"confidenceScore":0.8}],"warnings":[]},{"id":"3","entities":[],"warnings":[]}],"errors":[],"modelVersion":"2020-04-01"}' headers: - apim-request-id: d41598e7-0f49-4671-a0b1-c2c65baebc35 + apim-request-id: 963f0ff0-f22b-418e-83cf-0fd80af72b6a content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:07:45 GMT + date: Thu, 23 Apr 2020 18:32:55 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '28' + x-envoy-upstream-service-time: '50' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/recognition/general?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/recognition/general?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_all_successful_passing_dict.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_all_successful_passing_dict.yaml index df0a8735179f..222d4deed0bb 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_all_successful_passing_dict.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_all_successful_passing_dict.yaml @@ -11,32 +11,32 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=true + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=true response: body: string: '{"statistics":{"documentsCount":2,"validDocumentsCount":2,"erroneousDocumentsCount":0,"transactionsCount":2},"documents":[{"id":"1","statistics":{"charactersCount":50,"transactionsCount":1},"entities":[{"name":"Bill - Gates","matches":[{"text":"Bill Gates","offset":25,"length":10,"score":0.0}],"language":"en","id":"Bill + Gates","matches":[{"text":"Bill Gates","offset":25,"length":10,"confidenceScore":0.0}],"language":"en","id":"Bill Gates","url":"https://en.wikipedia.org/wiki/Bill_Gates","dataSource":"Wikipedia"},{"name":"Paul - Allen","matches":[{"text":"Paul Allen","offset":40,"length":10,"score":0.0}],"language":"en","id":"Paul - Allen","url":"https://en.wikipedia.org/wiki/Paul_Allen","dataSource":"Wikipedia"},{"name":"Microsoft","matches":[{"text":"Microsoft","offset":0,"length":9,"score":0.0}],"language":"en","id":"Microsoft","url":"https://en.wikipedia.org/wiki/Microsoft","dataSource":"Wikipedia"}]},{"id":"2","statistics":{"charactersCount":49,"transactionsCount":1},"entities":[{"name":"Bill - Gates","matches":[{"text":"Bill Gates","offset":26,"length":10,"score":0.0}],"language":"es","id":"Bill + Allen","matches":[{"text":"Paul Allen","offset":40,"length":10,"confidenceScore":0.0}],"language":"en","id":"Paul + Allen","url":"https://en.wikipedia.org/wiki/Paul_Allen","dataSource":"Wikipedia"},{"name":"Microsoft","matches":[{"text":"Microsoft","offset":0,"length":9,"confidenceScore":0.0}],"language":"en","id":"Microsoft","url":"https://en.wikipedia.org/wiki/Microsoft","dataSource":"Wikipedia"}],"warnings":[]},{"id":"2","statistics":{"charactersCount":49,"transactionsCount":1},"entities":[{"name":"Bill + Gates","matches":[{"text":"Bill Gates","offset":26,"length":10,"confidenceScore":0.0}],"language":"es","id":"Bill Gates","url":"https://es.wikipedia.org/wiki/Bill_Gates","dataSource":"Wikipedia"},{"name":"Paul - Allen","matches":[{"text":"Paul Allen","offset":39,"length":10,"score":0.0}],"language":"es","id":"Paul - Allen","url":"https://es.wikipedia.org/wiki/Paul_Allen","dataSource":"Wikipedia"},{"name":"Microsoft","matches":[{"text":"Microsoft","offset":0,"length":9,"score":0.0}],"language":"es","id":"Microsoft","url":"https://es.wikipedia.org/wiki/Microsoft","dataSource":"Wikipedia"}]}],"errors":[],"modelVersion":"2020-02-01"}' + Allen","matches":[{"text":"Paul Allen","offset":39,"length":10,"confidenceScore":0.0}],"language":"es","id":"Paul + Allen","url":"https://es.wikipedia.org/wiki/Paul_Allen","dataSource":"Wikipedia"},{"name":"Microsoft","matches":[{"text":"Microsoft","offset":0,"length":9,"confidenceScore":0.0}],"language":"es","id":"Microsoft","url":"https://es.wikipedia.org/wiki/Microsoft","dataSource":"Wikipedia"}],"warnings":[]}],"errors":[],"modelVersion":"2020-02-01"}' headers: - apim-request-id: acc33434-79b6-455f-80e7-41fb1a05a8b4 + apim-request-id: 2cc46f68-00b5-4785-87bf-1325656b6399 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=2 - date: Thu, 02 Apr 2020 15:07:58 GMT + date: Thu, 23 Apr 2020 18:31:25 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '20' + x-envoy-upstream-service-time: '34' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/linking?showStats=true + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=true version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_all_successful_passing_text_document_input.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_all_successful_passing_text_document_input.yaml index 7a27a409ccfb..768000c56c8a 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_all_successful_passing_text_document_input.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_all_successful_passing_text_document_input.yaml @@ -11,31 +11,32 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: string: '{"documents":[{"id":"1","entities":[{"name":"Bill Gates","matches":[{"text":"Bill - Gates","offset":25,"length":10,"score":0.0}],"language":"en","id":"Bill Gates","url":"https://en.wikipedia.org/wiki/Bill_Gates","dataSource":"Wikipedia"},{"name":"Paul - Allen","matches":[{"text":"Paul Allen","offset":40,"length":10,"score":0.0}],"language":"en","id":"Paul - Allen","url":"https://en.wikipedia.org/wiki/Paul_Allen","dataSource":"Wikipedia"},{"name":"Microsoft","matches":[{"text":"Microsoft","offset":0,"length":9,"score":0.0}],"language":"en","id":"Microsoft","url":"https://en.wikipedia.org/wiki/Microsoft","dataSource":"Wikipedia"}]},{"id":"2","entities":[{"name":"Bill - Gates","matches":[{"text":"Bill Gates","offset":26,"length":10,"score":0.0}],"language":"en","id":"Bill + Gates","offset":25,"length":10,"confidenceScore":0.0}],"language":"en","id":"Bill Gates","url":"https://en.wikipedia.org/wiki/Bill_Gates","dataSource":"Wikipedia"},{"name":"Paul - Allen","matches":[{"text":"Paul Allen","offset":39,"length":10,"score":0.0}],"language":"en","id":"Paul - Allen","url":"https://en.wikipedia.org/wiki/Paul_Allen","dataSource":"Wikipedia"},{"name":"Microsoft","matches":[{"text":"Microsoft","offset":0,"length":9,"score":0.0}],"language":"en","id":"Microsoft","url":"https://en.wikipedia.org/wiki/Microsoft","dataSource":"Wikipedia"}]}],"errors":[],"modelVersion":"2020-02-01"}' + Allen","matches":[{"text":"Paul Allen","offset":40,"length":10,"confidenceScore":0.0}],"language":"en","id":"Paul + Allen","url":"https://en.wikipedia.org/wiki/Paul_Allen","dataSource":"Wikipedia"},{"name":"Microsoft","matches":[{"text":"Microsoft","offset":0,"length":9,"confidenceScore":0.0}],"language":"en","id":"Microsoft","url":"https://en.wikipedia.org/wiki/Microsoft","dataSource":"Wikipedia"}],"warnings":[]},{"id":"2","entities":[{"name":"Bill + Gates","matches":[{"text":"Bill Gates","offset":26,"length":10,"confidenceScore":0.0}],"language":"en","id":"Bill + Gates","url":"https://en.wikipedia.org/wiki/Bill_Gates","dataSource":"Wikipedia"},{"name":"Paul + Allen","matches":[{"text":"Paul Allen","offset":39,"length":10,"confidenceScore":0.0}],"language":"en","id":"Paul + Allen","url":"https://en.wikipedia.org/wiki/Paul_Allen","dataSource":"Wikipedia"},{"name":"Microsoft","matches":[{"text":"Microsoft","offset":0,"length":9,"confidenceScore":0.0}],"language":"en","id":"Microsoft","url":"https://en.wikipedia.org/wiki/Microsoft","dataSource":"Wikipedia"}],"warnings":[]}],"errors":[],"modelVersion":"2020-02-01"}' headers: - apim-request-id: 0e4aff2e-eb82-4346-a4f3-e26d3ba78ff6 + apim-request-id: 48741dbf-211f-46b0-8879-ee9f4783072e content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=2 - date: Thu, 02 Apr 2020 15:08:00 GMT + date: Thu, 23 Apr 2020 18:31:25 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '19' + x-envoy-upstream-service-time: '21' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/linking?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_bad_credentials.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_bad_credentials.yaml index c3fb9fc1e336..af8c14eafbe9 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_bad_credentials.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_bad_credentials.yaml @@ -10,20 +10,25 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: - string: '{"error":{"code":"401","message":"Access denied due to invalid subscription + string: '{"error":{"code":"401","message": "Access denied due to invalid subscription key or wrong API endpoint. Make sure to provide a valid key for an active subscription and use a correct regional API endpoint for your resource."}}' headers: - content-length: '224' - date: Thu, 02 Apr 2020 15:07:59 GMT + apim-request-id: 16073830-b8ba-4d4c-a6b7-7ed371a64e8d + content-length: '225' + content-type: application/json + date: Thu, 23 Apr 2020 18:31:25 GMT + strict-transport-security: max-age=31536000; includeSubDomains; preload + www-authenticate: AzureApiManagementKey realm="https://westus2.ppe.cognitiveservices.azure.com/text/analytics",name="Ocp-Apim-Subscription-Key",type="header" + x-content-type-options: nosniff status: code: 401 - message: PermissionDenied - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/linking?showStats=false + message: Access Denied + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_bad_model_version.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_bad_model_version.yaml index e0e64502dac5..5158e9ad0701 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_bad_model_version.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_bad_model_version.yaml @@ -10,18 +10,18 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?model-version=old&showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?model-version=old&showStats=false response: body: string: '{"error":{"code":"InvalidRequest","message":"Specified Model version - is incorrect. Allowed values are latest,2019-10-01,2020-02-01"}}' + is incorrect. Allowed values are latest,2020-02-01"}}' headers: - apim-request-id: 68b4cfa2-879e-4f11-8026-3dd2f28b05f3 + apim-request-id: 23934162-c4ea-4a14-82c1-9ab8d2abc519 content-type: application/json; charset=utf-8 - date: Thu, 02 Apr 2020 15:08:00 GMT + date: Thu, 23 Apr 2020 18:31:25 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff @@ -29,5 +29,5 @@ interactions: status: code: 400 message: Bad Request - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/linking?model-version=old&showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?model-version=old&showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_bad_model_version_error.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_bad_model_version_error.yaml index a45a877af831..16a8d9d29372 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_bad_model_version_error.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_bad_model_version_error.yaml @@ -10,24 +10,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?model-version=bad&showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?model-version=bad&showStats=false response: body: string: '{"error":{"code":"InvalidRequest","message":"Specified Model version - is incorrect. Allowed values are latest,2019-10-01,2020-02-01"}}' + is incorrect. Allowed values are latest,2020-02-01"}}' headers: - apim-request-id: 7d079347-3ada-4cac-bc15-2b739fe1200d + apim-request-id: fa1537f3-82f3-483c-ab33-ea2a85d40433 content-type: application/json; charset=utf-8 - date: Thu, 02 Apr 2020 15:08:00 GMT + date: Thu, 23 Apr 2020 18:31:26 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '5' + x-envoy-upstream-service-time: '10' status: code: 400 message: Bad Request - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/linking?model-version=bad&showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?model-version=bad&showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_batch_size_over_limit.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_batch_size_over_limit.yaml index 11cb6096c768..d4489a485607 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_batch_size_over_limit.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_batch_size_over_limit.yaml @@ -754,18 +754,18 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: - string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innerError":{"code":"InvalidDocumentBatch","message":"Batch + string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innererror":{"code":"InvalidDocumentBatch","message":"Batch request contains too many records. Max 1000 records are permitted."}}}' headers: - apim-request-id: 3ea2863b-5ba0-4441-9cbe-4f1c2d2a3241 + apim-request-id: 025d710c-342a-44c1-ab8c-c7e12d00a6c5 content-type: application/json; charset=utf-8 - date: Thu, 02 Apr 2020 15:08:01 GMT + date: Thu, 23 Apr 2020 18:31:27 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff @@ -773,5 +773,5 @@ interactions: status: code: 400 message: Bad Request - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/linking?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_batch_size_over_limit_error.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_batch_size_over_limit_error.yaml index a0091452765d..905d831c6752 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_batch_size_over_limit_error.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_batch_size_over_limit_error.yaml @@ -719,24 +719,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: - string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innerError":{"code":"InvalidDocumentBatch","message":"Batch + string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innererror":{"code":"InvalidDocumentBatch","message":"Batch request contains too many records. Max 1000 records are permitted."}}}' headers: - apim-request-id: b64f2eb8-4bca-4aea-be04-57a0c4d7207a + apim-request-id: f2bc5b53-3faf-4ac4-8314-566425fa06dc content-type: application/json; charset=utf-8 - date: Thu, 02 Apr 2020 15:08:02 GMT + date: Thu, 23 Apr 2020 18:31:28 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '10' + x-envoy-upstream-service-time: '14' status: code: 400 message: Bad Request - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/linking?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_client_passed_default_language_hint.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_client_passed_default_language_hint.yaml index a5920bd1756f..c5742a9deed4 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_client_passed_default_language_hint.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_client_passed_default_language_hint.yaml @@ -12,18 +12,18 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: - string: '{"documents":[{"id":"1","entities":[]},{"id":"2","entities":[]},{"id":"3","entities":[]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"1","entities":[],"warnings":[]},{"id":"2","entities":[],"warnings":[]},{"id":"3","entities":[],"warnings":[]}],"errors":[],"modelVersion":"2020-02-01"}' headers: - apim-request-id: f0fd49da-3ad6-48b6-bb0d-317869203bf5 + apim-request-id: a7f49e4c-0134-4fdb-9626-21a7d78001f6 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:08:02 GMT + date: Thu, 23 Apr 2020 18:31:28 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff @@ -31,7 +31,7 @@ interactions: status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/linking?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false - request: body: '{"documents": [{"id": "1", "text": "I will go to the park.", "language": "en"}, {"id": "2", "text": "I did not like the hotel we stayed at.", "language": @@ -45,26 +45,26 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: - string: '{"documents":[{"id":"1","entities":[]},{"id":"2","entities":[]},{"id":"3","entities":[]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"1","entities":[],"warnings":[]},{"id":"2","entities":[],"warnings":[]},{"id":"3","entities":[],"warnings":[]}],"errors":[],"modelVersion":"2020-02-01"}' headers: - apim-request-id: 1e97b012-fb81-4fd3-b531-b7387b4d3af5 + apim-request-id: 09c0ab3a-f03e-40de-9294-69f6581233a9 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:08:02 GMT + date: Thu, 23 Apr 2020 18:31:28 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '19' + x-envoy-upstream-service-time: '29' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/linking?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false - request: body: '{"documents": [{"id": "1", "text": "I will go to the park.", "language": "es"}, {"id": "2", "text": "I did not like the hotel we stayed at.", "language": @@ -78,24 +78,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: - string: '{"documents":[{"id":"1","entities":[]},{"id":"2","entities":[]},{"id":"3","entities":[]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"1","entities":[],"warnings":[]},{"id":"2","entities":[],"warnings":[]},{"id":"3","entities":[],"warnings":[]}],"errors":[],"modelVersion":"2020-02-01"}' headers: - apim-request-id: 611111c5-b8cf-43da-9b9f-01b84a6dcc11 + apim-request-id: b9295b93-9975-4d42-b8ee-d0d6873650b0 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:08:02 GMT + date: Thu, 23 Apr 2020 18:31:28 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '13' + x-envoy-upstream-service-time: '18' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/linking?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_document_attribute_error_no_result_attribute.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_document_attribute_error_no_result_attribute.yaml index 6ba14a1d37b2..b484154b8741 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_document_attribute_error_no_result_attribute.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_document_attribute_error_no_result_attribute.yaml @@ -9,19 +9,19 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: string: '{"documents":[],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}}],"modelVersion":"2020-02-01"}' headers: - apim-request-id: d0af066d-7b4c-4f38-b9eb-b2fc271462e0 + apim-request-id: 7e3f214d-337f-4bc1-9d69-a686082bf56f content-type: application/json; charset=utf-8 - date: Thu, 02 Apr 2020 15:08:02 GMT + date: Thu, 23 Apr 2020 18:31:29 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff @@ -29,5 +29,5 @@ interactions: status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/linking?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_document_attribute_error_nonexistent_attribute.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_document_attribute_error_nonexistent_attribute.yaml index 1d62be819f54..6786142c729b 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_document_attribute_error_nonexistent_attribute.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_document_attribute_error_nonexistent_attribute.yaml @@ -9,19 +9,19 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: string: '{"documents":[],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}}],"modelVersion":"2020-02-01"}' headers: - apim-request-id: 72f341e8-8b00-45eb-8a36-13b8048ad4f2 + apim-request-id: 54b856a2-48a8-4e2a-94e9-232f5b53faa8 content-type: application/json; charset=utf-8 - date: Thu, 02 Apr 2020 15:08:03 GMT + date: Thu, 23 Apr 2020 18:31:29 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff @@ -29,5 +29,5 @@ interactions: status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/linking?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_document_errors.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_document_errors.yaml index 324a03488dbe..f2963230fd4e 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_document_errors.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_document_errors.yaml @@ -12,25 +12,25 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: string: '{"documents":[],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}},{"id":"2","error":{"code":"InvalidArgument","message":"Invalid - Language Code.","innerError":{"code":"UnsupportedLanguageCode","message":"Supplied + Language Code.","innererror":{"code":"UnsupportedLanguageCode","message":"Supplied language not supported. Pass in one of: en,es"}}},{"id":"3","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"A + document in request.","innererror":{"code":"InvalidDocument","message":"A document within the request was too large to be processed. Limit document size to: 5120 text elements. For additional details on the data limitations see https://aka.ms/text-analytics-data-limits"}}}],"modelVersion":"2020-02-01"}' headers: - apim-request-id: ad97870b-16e2-45df-9fb0-2624e4ab29f6 + apim-request-id: fb0ead21-c5f7-4117-b3e2-34e0b3213cf7 content-type: application/json; charset=utf-8 - date: Thu, 02 Apr 2020 15:08:03 GMT + date: Thu, 23 Apr 2020 18:31:29 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff @@ -38,5 +38,5 @@ interactions: status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/linking?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_duplicate_ids_error.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_duplicate_ids_error.yaml index 3067db7c7458..efffb92ebeb9 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_duplicate_ids_error.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_duplicate_ids_error.yaml @@ -10,24 +10,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: - string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innerError":{"code":"InvalidDocument","message":"Request + string: '{"error":{"code":"InvalidRequest","message":"Invalid document in request.","innererror":{"code":"InvalidDocument","message":"Request contains duplicated Ids. Make sure each document has a unique Id."}}}' headers: - apim-request-id: 3ea932b9-b4b4-4892-8718-af1bb13c8ad3 + apim-request-id: c416fcca-8bda-4254-86ae-f04c86487b90 content-type: application/json; charset=utf-8 - date: Thu, 02 Apr 2020 15:08:04 GMT + date: Thu, 23 Apr 2020 18:31:29 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '8' + x-envoy-upstream-service-time: '5' status: code: 400 message: Bad Request - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/linking?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_empty_credential_class.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_empty_credential_class.yaml index e3b0d921fc6d..0595541b391d 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_empty_credential_class.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_empty_credential_class.yaml @@ -10,20 +10,25 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: - string: '{"error":{"code":"401","message":"Access denied due to invalid subscription + string: '{"error":{"code":"401","message": "Access denied due to invalid subscription key or wrong API endpoint. Make sure to provide a valid key for an active subscription and use a correct regional API endpoint for your resource."}}' headers: - content-length: '224' - date: Thu, 02 Apr 2020 15:08:05 GMT + apim-request-id: ad88bf1e-f77d-4188-b5b8-90e7e8bf90e9 + content-length: '225' + content-type: application/json + date: Thu, 23 Apr 2020 18:31:31 GMT + strict-transport-security: max-age=31536000; includeSubDomains; preload + www-authenticate: AzureApiManagementKey realm="https://westus2.ppe.cognitiveservices.azure.com/text/analytics",name="Ocp-Apim-Subscription-Key",type="header" + x-content-type-options: nosniff status: code: 401 - message: PermissionDenied - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/linking?showStats=false + message: Access Denied + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_input_with_all_errors.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_input_with_all_errors.yaml index 9e9dea1c2ebf..50f65e591c34 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_input_with_all_errors.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_input_with_all_errors.yaml @@ -10,27 +10,27 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: string: '{"documents":[],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}},{"id":"2","error":{"code":"InvalidArgument","message":"Invalid - Language Code.","innerError":{"code":"UnsupportedLanguageCode","message":"Supplied + Language Code.","innererror":{"code":"UnsupportedLanguageCode","message":"Supplied language not supported. Pass in one of: en,es"}}}],"modelVersion":"2020-02-01"}' headers: - apim-request-id: a54c26d9-1ef6-4b51-aae6-81bd02a6f1b9 + apim-request-id: b1e27801-b392-449e-93a4-81620c6dec6d content-type: application/json; charset=utf-8 - date: Thu, 02 Apr 2020 15:08:05 GMT + date: Thu, 23 Apr 2020 18:31:31 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '2' + x-envoy-upstream-service-time: '1' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/linking?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_input_with_some_errors.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_input_with_some_errors.yaml index b66cd5a7a857..3bc2c9ff1e47 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_input_with_some_errors.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_input_with_some_errors.yaml @@ -10,29 +10,30 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: string: '{"documents":[{"id":"2","entities":[{"name":"Bill Gates","matches":[{"text":"Bill - Gates","offset":26,"length":10,"score":0.0}],"language":"es","id":"Bill Gates","url":"https://es.wikipedia.org/wiki/Bill_Gates","dataSource":"Wikipedia"},{"name":"Paul - Allen","matches":[{"text":"Paul Allen","offset":39,"length":10,"score":0.0}],"language":"es","id":"Paul - Allen","url":"https://es.wikipedia.org/wiki/Paul_Allen","dataSource":"Wikipedia"},{"name":"Microsoft","matches":[{"text":"Microsoft","offset":0,"length":9,"score":0.0}],"language":"es","id":"Microsoft","url":"https://es.wikipedia.org/wiki/Microsoft","dataSource":"Wikipedia"}]}],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + Gates","offset":26,"length":10,"confidenceScore":0.0}],"language":"es","id":"Bill + Gates","url":"https://es.wikipedia.org/wiki/Bill_Gates","dataSource":"Wikipedia"},{"name":"Paul + Allen","matches":[{"text":"Paul Allen","offset":39,"length":10,"confidenceScore":0.0}],"language":"es","id":"Paul + Allen","url":"https://es.wikipedia.org/wiki/Paul_Allen","dataSource":"Wikipedia"},{"name":"Microsoft","matches":[{"text":"Microsoft","offset":0,"length":9,"confidenceScore":0.0}],"language":"es","id":"Microsoft","url":"https://es.wikipedia.org/wiki/Microsoft","dataSource":"Wikipedia"}],"warnings":[]}],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}}],"modelVersion":"2020-02-01"}' headers: - apim-request-id: 18d67e95-a77e-4490-87bf-dcc2f0595a55 + apim-request-id: dfdfb943-98b3-4202-807c-7bfeb61149dc content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=1 - date: Thu, 02 Apr 2020 15:08:06 GMT + date: Thu, 23 Apr 2020 18:31:31 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '14' + x-envoy-upstream-service-time: '12' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/linking?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_language_kwarg_spanish.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_language_kwarg_spanish.yaml index 82ec28fe1917..645ce319d49a 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_language_kwarg_spanish.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_language_kwarg_spanish.yaml @@ -10,28 +10,28 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?model-version=latest&showStats=true + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?model-version=latest&showStats=true response: body: string: '{"statistics":{"documentsCount":1,"validDocumentsCount":1,"erroneousDocumentsCount":0,"transactionsCount":1},"documents":[{"id":"0","statistics":{"charactersCount":35,"transactionsCount":1},"entities":[{"name":"Bill - Gates","matches":[{"text":"Bill Gates","offset":0,"length":10,"score":0.0}],"language":"es","id":"Bill - Gates","url":"https://es.wikipedia.org/wiki/Bill_Gates","dataSource":"Wikipedia"},{"name":"Microsoft","matches":[{"text":"Microsoft","offset":25,"length":9,"score":0.0}],"language":"es","id":"Microsoft","url":"https://es.wikipedia.org/wiki/Microsoft","dataSource":"Wikipedia"},{"name":"Director - ejecutivo","matches":[{"text":"CEO","offset":18,"length":3,"score":0.0}],"language":"es","id":"Director - ejecutivo","url":"https://es.wikipedia.org/wiki/Director_ejecutivo","dataSource":"Wikipedia"}]}],"errors":[],"modelVersion":"2020-02-01"}' + Gates","matches":[{"text":"Bill Gates","offset":0,"length":10,"confidenceScore":0.0}],"language":"es","id":"Bill + Gates","url":"https://es.wikipedia.org/wiki/Bill_Gates","dataSource":"Wikipedia"},{"name":"Microsoft","matches":[{"text":"Microsoft","offset":25,"length":9,"confidenceScore":0.0}],"language":"es","id":"Microsoft","url":"https://es.wikipedia.org/wiki/Microsoft","dataSource":"Wikipedia"},{"name":"Director + ejecutivo","matches":[{"text":"CEO","offset":18,"length":3,"confidenceScore":0.0}],"language":"es","id":"Director + ejecutivo","url":"https://es.wikipedia.org/wiki/Director_ejecutivo","dataSource":"Wikipedia"}],"warnings":[]}],"errors":[],"modelVersion":"2020-02-01"}' headers: - apim-request-id: 1fbf3e11-bb69-462c-8e84-2319a28c194d + apim-request-id: cbd505b3-cc00-42b8-bb7d-e9cd686dd27f content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=1 - date: Thu, 02 Apr 2020 15:08:05 GMT + date: Thu, 23 Apr 2020 18:31:31 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '12' + x-envoy-upstream-service-time: '10' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/linking?model-version=latest&showStats=true + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?model-version=latest&showStats=true version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_missing_input_records_error.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_missing_input_records_error.yaml deleted file mode 100644 index 4612b5715e5d..000000000000 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_missing_input_records_error.yaml +++ /dev/null @@ -1,32 +0,0 @@ -interactions: -- request: - body: '{"documents": []}' - headers: - Accept: - - application/json - Content-Length: - - '17' - Content-Type: - - application/json - User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) - method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false - response: - body: - string: '{"error":{"code":"InvalidRequest","message":"Invalid Request.","innerError":{"code":"MissingInputRecords","message":"Missing - input records."}}}' - headers: - apim-request-id: e596e6e8-acb1-4d55-bdf9-16bb9c0d1f08 - content-type: application/json; charset=utf-8 - date: Thu, 02 Apr 2020 15:08:06 GMT - strict-transport-security: max-age=31536000; includeSubDomains; preload - transfer-encoding: chunked - x-content-type-options: nosniff - x-envoy-upstream-service-time: '4' - status: - code: 400 - message: Bad Request - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/linking?showStats=false -version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_out_of_order_ids.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_out_of_order_ids.yaml index f5383c19e901..09d5260600e5 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_out_of_order_ids.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_out_of_order_ids.yaml @@ -12,26 +12,26 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: - string: '{"documents":[{"id":"56","entities":[]},{"id":"0","entities":[]},{"id":"19","entities":[]},{"id":"1","entities":[]}],"errors":[{"id":"22","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + string: '{"documents":[{"id":"56","entities":[],"warnings":[]},{"id":"0","entities":[],"warnings":[]},{"id":"19","entities":[],"warnings":[]},{"id":"1","entities":[],"warnings":[]}],"errors":[{"id":"22","error":{"code":"InvalidArgument","message":"Invalid + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}}],"modelVersion":"2020-02-01"}' headers: - apim-request-id: 6d4d61b7-3513-40eb-9b04-4b4249bac2c9 + apim-request-id: 224e32cd-270b-42ff-bcc8-59b2d7491faa content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=4 - date: Thu, 02 Apr 2020 15:08:07 GMT + date: Thu, 23 Apr 2020 18:31:32 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '19' + x-envoy-upstream-service-time: '20' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/linking?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_pass_cls.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_pass_cls.yaml index 4acb00dc7f96..992896b27b2e 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_pass_cls.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_pass_cls.yaml @@ -10,24 +10,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: - string: '{"documents":[{"id":"0","entities":[{"name":".test","matches":[{"text":"Test","offset":0,"length":4,"score":0.0}],"language":"en","id":".test","url":"https://en.wikipedia.org/wiki/.test","dataSource":"Wikipedia"}]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"0","entities":[{"name":".test","matches":[{"text":"Test","offset":0,"length":4,"confidenceScore":0.0}],"language":"en","id":".test","url":"https://en.wikipedia.org/wiki/.test","dataSource":"Wikipedia"}],"warnings":[]}],"errors":[],"modelVersion":"2020-02-01"}' headers: - apim-request-id: 497e0abf-ed7b-474f-a786-6a7def4c4adf + apim-request-id: db05316a-c52d-427f-a4b0-10aab7c12983 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=1 - date: Thu, 02 Apr 2020 15:08:06 GMT + date: Thu, 23 Apr 2020 18:31:33 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '18' + x-envoy-upstream-service-time: '19' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/linking?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_passing_only_string.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_passing_only_string.yaml index 440234e8b05f..f054815fa81e 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_passing_only_string.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_passing_only_string.yaml @@ -12,33 +12,34 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: string: '{"documents":[{"id":"0","entities":[{"name":"Bill Gates","matches":[{"text":"Bill - Gates","offset":25,"length":10,"score":0.0}],"language":"en","id":"Bill Gates","url":"https://en.wikipedia.org/wiki/Bill_Gates","dataSource":"Wikipedia"},{"name":"Paul - Allen","matches":[{"text":"Paul Allen","offset":40,"length":10,"score":0.0}],"language":"en","id":"Paul - Allen","url":"https://en.wikipedia.org/wiki/Paul_Allen","dataSource":"Wikipedia"},{"name":"Microsoft","matches":[{"text":"Microsoft","offset":0,"length":9,"score":0.0}],"language":"en","id":"Microsoft","url":"https://en.wikipedia.org/wiki/Microsoft","dataSource":"Wikipedia"}]},{"id":"1","entities":[{"name":"Bill - Gates","matches":[{"text":"Bill Gates","offset":26,"length":10,"score":0.0}],"language":"en","id":"Bill + Gates","offset":25,"length":10,"confidenceScore":0.0}],"language":"en","id":"Bill Gates","url":"https://en.wikipedia.org/wiki/Bill_Gates","dataSource":"Wikipedia"},{"name":"Paul - Allen","matches":[{"text":"Paul Allen","offset":39,"length":10,"score":0.0}],"language":"en","id":"Paul - Allen","url":"https://en.wikipedia.org/wiki/Paul_Allen","dataSource":"Wikipedia"},{"name":"Microsoft","matches":[{"text":"Microsoft","offset":0,"length":9,"score":0.0}],"language":"en","id":"Microsoft","url":"https://en.wikipedia.org/wiki/Microsoft","dataSource":"Wikipedia"}]}],"errors":[{"id":"2","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + Allen","matches":[{"text":"Paul Allen","offset":40,"length":10,"confidenceScore":0.0}],"language":"en","id":"Paul + Allen","url":"https://en.wikipedia.org/wiki/Paul_Allen","dataSource":"Wikipedia"},{"name":"Microsoft","matches":[{"text":"Microsoft","offset":0,"length":9,"confidenceScore":0.0}],"language":"en","id":"Microsoft","url":"https://en.wikipedia.org/wiki/Microsoft","dataSource":"Wikipedia"}],"warnings":[]},{"id":"1","entities":[{"name":"Bill + Gates","matches":[{"text":"Bill Gates","offset":26,"length":10,"confidenceScore":0.0}],"language":"en","id":"Bill + Gates","url":"https://en.wikipedia.org/wiki/Bill_Gates","dataSource":"Wikipedia"},{"name":"Paul + Allen","matches":[{"text":"Paul Allen","offset":39,"length":10,"confidenceScore":0.0}],"language":"en","id":"Paul + Allen","url":"https://en.wikipedia.org/wiki/Paul_Allen","dataSource":"Wikipedia"},{"name":"Microsoft","matches":[{"text":"Microsoft","offset":0,"length":9,"confidenceScore":0.0}],"language":"en","id":"Microsoft","url":"https://en.wikipedia.org/wiki/Microsoft","dataSource":"Wikipedia"}],"warnings":[]}],"errors":[{"id":"2","error":{"code":"InvalidArgument","message":"Invalid + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}}],"modelVersion":"2020-02-01"}' headers: - apim-request-id: d2da5aad-8139-4d76-bc12-d2a0570c625f + apim-request-id: 431a525a-1c10-4714-acf7-ff5b66c09904 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=2 - date: Thu, 02 Apr 2020 15:08:08 GMT + date: Thu, 23 Apr 2020 18:31:32 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '18' + x-envoy-upstream-service-time: '21' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/linking?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_per_item_dont_use_language_hint.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_per_item_dont_use_language_hint.yaml index 1a134686b5f5..4156c46fb1c4 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_per_item_dont_use_language_hint.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_per_item_dont_use_language_hint.yaml @@ -12,24 +12,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: - string: '{"documents":[{"id":"1","entities":[]},{"id":"2","entities":[]},{"id":"3","entities":[]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"1","entities":[],"warnings":[]},{"id":"2","entities":[],"warnings":[]},{"id":"3","entities":[],"warnings":[]}],"errors":[],"modelVersion":"2020-02-01"}' headers: - apim-request-id: a848649e-62ed-4073-b400-db8ca4b8dc9b + apim-request-id: 639ed970-7247-4582-94e1-510559193ae1 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:08:08 GMT + date: Thu, 23 Apr 2020 18:31:33 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '19' + x-envoy-upstream-service-time: '27' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/linking?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_rotate_subscription_key.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_rotate_subscription_key.yaml index fc7e98f247d5..76b1b47bc472 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_rotate_subscription_key.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_rotate_subscription_key.yaml @@ -12,18 +12,18 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: - string: '{"documents":[{"id":"1","entities":[]},{"id":"2","entities":[]},{"id":"3","entities":[]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"1","entities":[],"warnings":[]},{"id":"2","entities":[],"warnings":[]},{"id":"3","entities":[],"warnings":[]}],"errors":[],"modelVersion":"2020-02-01"}' headers: - apim-request-id: eddd8eaa-3e55-4030-bd54-1f5f9b9c0d1c + apim-request-id: 1ce90b16-e00c-4389-bad4-47b57db41861 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:08:08 GMT + date: Thu, 23 Apr 2020 18:31:34 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff @@ -31,7 +31,7 @@ interactions: status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/linking?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false - request: body: '{"documents": [{"id": "1", "text": "I will go to the park.", "language": "en"}, {"id": "2", "text": "I did not like the hotel we stayed at.", "language": @@ -45,22 +45,27 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: - string: '{"error":{"code":"401","message":"Access denied due to invalid subscription + string: '{"error":{"code":"401","message": "Access denied due to invalid subscription key or wrong API endpoint. Make sure to provide a valid key for an active subscription and use a correct regional API endpoint for your resource."}}' headers: - content-length: '224' - date: Thu, 02 Apr 2020 15:08:08 GMT + apim-request-id: 9b572bb6-dbb5-4fbf-b247-db42dc47c483 + content-length: '225' + content-type: application/json + date: Thu, 23 Apr 2020 18:31:34 GMT + strict-transport-security: max-age=31536000; includeSubDomains; preload + www-authenticate: AzureApiManagementKey realm="https://westus2.ppe.cognitiveservices.azure.com/text/analytics",name="Ocp-Apim-Subscription-Key",type="header" + x-content-type-options: nosniff status: code: 401 - message: PermissionDenied - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/linking?showStats=false + message: Access Denied + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false - request: body: '{"documents": [{"id": "1", "text": "I will go to the park.", "language": "en"}, {"id": "2", "text": "I did not like the hotel we stayed at.", "language": @@ -74,24 +79,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: - string: '{"documents":[{"id":"1","entities":[]},{"id":"2","entities":[]},{"id":"3","entities":[]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"1","entities":[],"warnings":[]},{"id":"2","entities":[],"warnings":[]},{"id":"3","entities":[],"warnings":[]}],"errors":[],"modelVersion":"2020-02-01"}' headers: - apim-request-id: 833f1c44-c363-41f4-bf2b-8c378cd024a1 + apim-request-id: 88ec1ea0-815c-4988-94b7-09e10c2a51da content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:08:08 GMT + date: Thu, 23 Apr 2020 18:31:34 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '21' + x-envoy-upstream-service-time: '22' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/linking?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_show_stats_and_model_version.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_show_stats_and_model_version.yaml index 2a47f3cbefef..772e937b865c 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_show_stats_and_model_version.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_show_stats_and_model_version.yaml @@ -12,26 +12,26 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?model-version=latest&showStats=true + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?model-version=latest&showStats=true response: body: - string: '{"statistics":{"documentsCount":5,"validDocumentsCount":4,"erroneousDocumentsCount":1,"transactionsCount":4},"documents":[{"id":"56","statistics":{"charactersCount":2,"transactionsCount":1},"entities":[]},{"id":"0","statistics":{"charactersCount":2,"transactionsCount":1},"entities":[]},{"id":"19","statistics":{"charactersCount":2,"transactionsCount":1},"entities":[]},{"id":"1","statistics":{"charactersCount":2,"transactionsCount":1},"entities":[]}],"errors":[{"id":"22","error":{"code":"InvalidArgument","message":"Invalid - document in request.","innerError":{"code":"InvalidDocument","message":"Document + string: '{"statistics":{"documentsCount":5,"validDocumentsCount":4,"erroneousDocumentsCount":1,"transactionsCount":4},"documents":[{"id":"56","statistics":{"charactersCount":2,"transactionsCount":1},"entities":[],"warnings":[]},{"id":"0","statistics":{"charactersCount":2,"transactionsCount":1},"entities":[],"warnings":[]},{"id":"19","statistics":{"charactersCount":2,"transactionsCount":1},"entities":[],"warnings":[]},{"id":"1","statistics":{"charactersCount":2,"transactionsCount":1},"entities":[],"warnings":[]}],"errors":[{"id":"22","error":{"code":"InvalidArgument","message":"Invalid + document in request.","innererror":{"code":"InvalidDocument","message":"Document text is empty."}}}],"modelVersion":"2020-02-01"}' headers: - apim-request-id: 2f4b1dd3-d754-4139-9e54-5f518f75d803 + apim-request-id: 05f055b3-a43f-4c7f-b647-59bc1ab6cfab content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=4 - date: Thu, 02 Apr 2020 15:08:09 GMT + date: Thu, 23 Apr 2020 18:31:34 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '17' + x-envoy-upstream-service-time: '19' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/linking?model-version=latest&showStats=true + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?model-version=latest&showStats=true version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_user_agent.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_user_agent.yaml index 5c4297a7d819..f26e48117ffc 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_user_agent.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_user_agent.yaml @@ -12,24 +12,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: - string: '{"documents":[{"id":"1","entities":[]},{"id":"2","entities":[]},{"id":"3","entities":[]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"1","entities":[],"warnings":[]},{"id":"2","entities":[],"warnings":[]},{"id":"3","entities":[],"warnings":[]}],"errors":[],"modelVersion":"2020-02-01"}' headers: - apim-request-id: 95853eca-6b2e-4282-bd7c-0605c61c5f9b + apim-request-id: 3f239c60-d31f-40ec-8966-795453d383df content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:08:09 GMT + date: Thu, 23 Apr 2020 18:31:34 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '17' + x-envoy-upstream-service-time: '21' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/linking?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_whole_batch_dont_use_language_hint.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_whole_batch_dont_use_language_hint.yaml index 60a805e413ed..8ba6ce30537e 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_whole_batch_dont_use_language_hint.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_whole_batch_dont_use_language_hint.yaml @@ -12,24 +12,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: - string: '{"documents":[{"id":"0","entities":[]},{"id":"1","entities":[]},{"id":"2","entities":[]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"0","entities":[],"warnings":[]},{"id":"1","entities":[],"warnings":[]},{"id":"2","entities":[],"warnings":[]}],"errors":[],"modelVersion":"2020-02-01"}' headers: - apim-request-id: ffeb83b2-0292-4607-a847-015714b4fdaf + apim-request-id: 3615165b-1726-4f1e-a1af-a3336e016abb content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:08:09 GMT + date: Thu, 23 Apr 2020 18:31:34 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '24' + x-envoy-upstream-service-time: '23' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/linking?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_whole_batch_language_hint.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_whole_batch_language_hint.yaml index 0efe8b296dab..96a76bb88bfa 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_whole_batch_language_hint.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_whole_batch_language_hint.yaml @@ -12,23 +12,23 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: string: '{"documents":[],"errors":[{"id":"0","error":{"code":"InvalidArgument","message":"Invalid - Language Code.","innerError":{"code":"UnsupportedLanguageCode","message":"Supplied + Language Code.","innererror":{"code":"UnsupportedLanguageCode","message":"Supplied language not supported. Pass in one of: en,es"}}},{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - Language Code.","innerError":{"code":"UnsupportedLanguageCode","message":"Supplied + Language Code.","innererror":{"code":"UnsupportedLanguageCode","message":"Supplied language not supported. Pass in one of: en,es"}}},{"id":"2","error":{"code":"InvalidArgument","message":"Invalid - Language Code.","innerError":{"code":"UnsupportedLanguageCode","message":"Supplied + Language Code.","innererror":{"code":"UnsupportedLanguageCode","message":"Supplied language not supported. Pass in one of: en,es"}}}],"modelVersion":"2020-02-01"}' headers: - apim-request-id: 42dbd842-f510-4eb2-bb8d-37b20bcbb5f6 + apim-request-id: 62fbcc5a-6cb1-474e-b58c-f9ff98081003 content-type: application/json; charset=utf-8 - date: Thu, 02 Apr 2020 15:08:10 GMT + date: Thu, 23 Apr 2020 18:31:35 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff @@ -36,5 +36,5 @@ interactions: status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/linking?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_whole_batch_language_hint_and_dict_per_item_hints.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_whole_batch_language_hint_and_dict_per_item_hints.yaml index 482a4881e00e..e201377066b7 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_whole_batch_language_hint_and_dict_per_item_hints.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_whole_batch_language_hint_and_dict_per_item_hints.yaml @@ -12,24 +12,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: - string: '{"documents":[{"id":"1","entities":[]},{"id":"2","entities":[]},{"id":"3","entities":[]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"1","entities":[],"warnings":[]},{"id":"2","entities":[],"warnings":[]},{"id":"3","entities":[],"warnings":[]}],"errors":[],"modelVersion":"2020-02-01"}' headers: - apim-request-id: e820fc87-438b-4409-a00f-0a51df1cbefa + apim-request-id: 99b0d447-95df-470f-a079-62a877c1ec9c content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:08:10 GMT + date: Thu, 23 Apr 2020 18:31:36 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '19' + x-envoy-upstream-service-time: '22' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/linking?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_whole_batch_language_hint_and_obj_input.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_whole_batch_language_hint_and_obj_input.yaml index fe78fcc76014..bf000204b2fc 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_whole_batch_language_hint_and_obj_input.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_whole_batch_language_hint_and_obj_input.yaml @@ -12,23 +12,23 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: string: '{"documents":[],"errors":[{"id":"1","error":{"code":"InvalidArgument","message":"Invalid - Language Code.","innerError":{"code":"UnsupportedLanguageCode","message":"Supplied + Language Code.","innererror":{"code":"UnsupportedLanguageCode","message":"Supplied language not supported. Pass in one of: en,es"}}},{"id":"4","error":{"code":"InvalidArgument","message":"Invalid - Language Code.","innerError":{"code":"UnsupportedLanguageCode","message":"Supplied + Language Code.","innererror":{"code":"UnsupportedLanguageCode","message":"Supplied language not supported. Pass in one of: en,es"}}},{"id":"3","error":{"code":"InvalidArgument","message":"Invalid - Language Code.","innerError":{"code":"UnsupportedLanguageCode","message":"Supplied + Language Code.","innererror":{"code":"UnsupportedLanguageCode","message":"Supplied language not supported. Pass in one of: en,es"}}}],"modelVersion":"2020-02-01"}' headers: - apim-request-id: c7af4795-010b-4f10-88f8-5e827a0a5b76 + apim-request-id: f00d83f7-da71-4642-8b10-5d9fadb89741 content-type: application/json; charset=utf-8 - date: Thu, 02 Apr 2020 15:08:10 GMT + date: Thu, 23 Apr 2020 18:31:36 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff @@ -36,5 +36,5 @@ interactions: status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/linking?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false version: 1 diff --git a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_whole_batch_language_hint_and_obj_per_item_hints.yaml b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_whole_batch_language_hint_and_obj_per_item_hints.yaml index 40fd963bdafc..88bb06ba1b2b 100644 --- a/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_whole_batch_language_hint_and_obj_per_item_hints.yaml +++ b/sdk/textanalytics/azure-ai-textanalytics/tests/recordings/test_recognize_linked_entities_async.test_whole_batch_language_hint_and_obj_per_item_hints.yaml @@ -12,24 +12,24 @@ interactions: Content-Type: - application/json User-Agent: - - azsdk-python-ai-textanalytics/1.0.0b4 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) + - azsdk-python-ai-textanalytics/1.0.0b5 Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) Python/3.7.7 (Darwin-17.7.0-x86_64-i386-64bit) method: POST - uri: https://westus2.api.cognitive.microsoft.com/text/analytics/v3.0-preview.1/entities/linking?showStats=false + uri: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false response: body: - string: '{"documents":[{"id":"1","entities":[]},{"id":"2","entities":[]},{"id":"3","entities":[]}],"errors":[],"modelVersion":"2020-02-01"}' + string: '{"documents":[{"id":"1","entities":[],"warnings":[]},{"id":"2","entities":[],"warnings":[]},{"id":"3","entities":[],"warnings":[]}],"errors":[],"modelVersion":"2020-02-01"}' headers: - apim-request-id: b8c3262e-de2d-4f60-9034-320b07652a91 + apim-request-id: c233a483-6683-455d-85d2-d6bbad370482 content-type: application/json; charset=utf-8 csp-billing-usage: CognitiveServices.TextAnalytics.BatchScoring=3 - date: Thu, 02 Apr 2020 15:08:11 GMT + date: Thu, 23 Apr 2020 18:31:36 GMT strict-transport-security: max-age=31536000; includeSubDomains; preload transfer-encoding: chunked x-content-type-options: nosniff - x-envoy-upstream-service-time: '16' + x-envoy-upstream-service-time: '15' status: code: 200 message: OK - url: https://westus2.api.cognitive.microsoft.com//text/analytics/v3.0-preview.1/entities/linking?showStats=false + url: https://westus2.ppe.cognitiveservices.azure.com/text/analytics/v3.0/entities/linking?showStats=false version: 1