@@ -54,13 +54,11 @@ def analyze_status(
5454 :type skip: int
5555 :keyword callable cls: A custom type or function that will be passed the direct response
5656 :return: AnalyzeJobState, or the result of cls(response)
57- :rtype: ~azure.ai.textanalytics.v3_1_preview_3 .models.AnalyzeJobState
57+ :rtype: ~azure.ai.textanalytics.v3_1_preview_4 .models.AnalyzeJobState
5858 :raises: ~azure.core.exceptions.HttpResponseError
5959 """
6060 api_version = self ._get_api_version ('analyze_status' )
61- if api_version == 'v3.1-preview.3' :
62- from .v3_1_preview_3 .operations import TextAnalyticsClientOperationsMixin as OperationClass
63- elif api_version == 'v3.1-preview.4' :
61+ if api_version == 'v3.1-preview.4' :
6462 from .v3_1_preview_4 .operations import TextAnalyticsClientOperationsMixin as OperationClass
6563 else :
6664 raise ValueError ("API version {} does not have operation 'analyze_status'" .format (api_version ))
@@ -83,21 +81,19 @@ def begin_analyze(
8381 executed.
8482
8583 :param body: Collection of documents to analyze and tasks to execute.
86- :type body: ~azure.ai.textanalytics.v3_1_preview_3 .models.AnalyzeBatchInput
84+ :type body: ~azure.ai.textanalytics.v3_1_preview_4 .models.AnalyzeBatchInput
8785 :keyword callable cls: A custom type or function that will be passed the direct response
8886 :keyword str continuation_token: A continuation token to restart a poller from a saved state.
8987 :keyword polling: Pass in True if you'd like the AnalyzeBatchActionsLROPollingMethod polling method,
9088 False for no polling, or your own initialized polling object for a personal polling strategy.
9189 :paramtype polling: bool or ~azure.core.polling.PollingMethod
9290 :keyword int polling_interval: Default waiting time between two polls for LRO operations if no Retry-After header is present.
9391 :return: An instance of AnalyzeBatchActionsLROPoller that returns either AnalyzeJobState or the result of cls(response)
94- :rtype: ~...._lro.AnalyzeBatchActionsLROPoller[~azure.ai.textanalytics.v3_1_preview_3 .models.AnalyzeJobState]
92+ :rtype: ~...._lro.AnalyzeBatchActionsLROPoller[~azure.ai.textanalytics.v3_1_preview_4 .models.AnalyzeJobState]
9593 :raises ~azure.core.exceptions.HttpResponseError:
9694 """
9795 api_version = self ._get_api_version ('begin_analyze' )
98- if api_version == 'v3.1-preview.3' :
99- from .v3_1_preview_3 .operations import TextAnalyticsClientOperationsMixin as OperationClass
100- elif api_version == 'v3.1-preview.4' :
96+ if api_version == 'v3.1-preview.4' :
10197 from .v3_1_preview_4 .operations import TextAnalyticsClientOperationsMixin as OperationClass
10298 else :
10399 raise ValueError ("API version {} does not have operation 'begin_analyze'" .format (api_version ))
@@ -131,9 +127,7 @@ def begin_cancel_health_job(
131127 :raises ~azure.core.exceptions.HttpResponseError:
132128 """
133129 api_version = self ._get_api_version ('begin_cancel_health_job' )
134- if api_version == 'v3.1-preview.3' :
135- from .v3_1_preview_3 .operations import TextAnalyticsClientOperationsMixin as OperationClass
136- elif api_version == 'v3.1-preview.4' :
130+ if api_version == 'v3.1-preview.4' :
137131 from .v3_1_preview_4 .operations import TextAnalyticsClientOperationsMixin as OperationClass
138132 else :
139133 raise ValueError ("API version {} does not have operation 'begin_cancel_health_job'" .format (api_version ))
@@ -158,28 +152,26 @@ def begin_health(
158152 symptoms, etc) and their relations.
159153
160154 :param documents: The set of documents to process as part of this batch.
161- :type documents: list[~azure.ai.textanalytics.v3_1_preview_3 .models.MultiLanguageInput]
155+ :type documents: list[~azure.ai.textanalytics.v3_1_preview_4 .models.MultiLanguageInput]
162156 :param model_version: (Optional) This value indicates which model will be used for scoring. If
163157 a model-version is not specified, the API should default to the latest, non-preview version.
164158 :type model_version: str
165159 :param string_index_type: (Optional) Specifies the method used to interpret string offsets.
166160 Defaults to Text Elements (Graphemes) according to Unicode v8.0.0. For additional information
167161 see https://aka.ms/text-analytics-offsets.
168- :type string_index_type: str or ~azure.ai.textanalytics.v3_1_preview_3 .models.StringIndexType
162+ :type string_index_type: str or ~azure.ai.textanalytics.v3_1_preview_4 .models.StringIndexType
169163 :keyword callable cls: A custom type or function that will be passed the direct response
170164 :keyword str continuation_token: A continuation token to restart a poller from a saved state.
171165 :keyword polling: Pass in True if you'd like the AnalyzeHealthcareEntitiesLROPollingMethod polling method,
172166 False for no polling, or your own initialized polling object for a personal polling strategy.
173167 :paramtype polling: bool or ~azure.core.polling.PollingMethod
174168 :keyword int polling_interval: Default waiting time between two polls for LRO operations if no Retry-After header is present.
175169 :return: An instance of AnalyzeHealthcareEntitiesLROPoller that returns either HealthcareJobState or the result of cls(response)
176- :rtype: ~...._lro.AnalyzeHealthcareEntitiesLROPoller[~azure.ai.textanalytics.v3_1_preview_3 .models.HealthcareJobState]
170+ :rtype: ~...._lro.AnalyzeHealthcareEntitiesLROPoller[~azure.ai.textanalytics.v3_1_preview_4 .models.HealthcareJobState]
177171 :raises ~azure.core.exceptions.HttpResponseError:
178172 """
179173 api_version = self ._get_api_version ('begin_health' )
180- if api_version == 'v3.1-preview.3' :
181- from .v3_1_preview_3 .operations import TextAnalyticsClientOperationsMixin as OperationClass
182- elif api_version == 'v3.1-preview.4' :
174+ if api_version == 'v3.1-preview.4' :
183175 from .v3_1_preview_4 .operations import TextAnalyticsClientOperationsMixin as OperationClass
184176 else :
185177 raise ValueError ("API version {} does not have operation 'begin_health'" .format (api_version ))
@@ -220,8 +212,6 @@ def entities_linking(
220212 api_version = self ._get_api_version ('entities_linking' )
221213 if api_version == 'v3.0' :
222214 from .v3_0 .operations import TextAnalyticsClientOperationsMixin as OperationClass
223- elif api_version == 'v3.1-preview.3' :
224- from .v3_1_preview_3 .operations import TextAnalyticsClientOperationsMixin as OperationClass
225215 elif api_version == 'v3.1-preview.4' :
226216 from .v3_1_preview_4 .operations import TextAnalyticsClientOperationsMixin as OperationClass
227217 else :
@@ -264,8 +254,6 @@ def entities_recognition_general(
264254 api_version = self ._get_api_version ('entities_recognition_general' )
265255 if api_version == 'v3.0' :
266256 from .v3_0 .operations import TextAnalyticsClientOperationsMixin as OperationClass
267- elif api_version == 'v3.1-preview.3' :
268- from .v3_1_preview_3 .operations import TextAnalyticsClientOperationsMixin as OperationClass
269257 elif api_version == 'v3.1-preview.4' :
270258 from .v3_1_preview_4 .operations import TextAnalyticsClientOperationsMixin as OperationClass
271259 else :
@@ -285,6 +273,7 @@ def entities_recognition_pii(
285273 show_stats = None , # type: Optional[bool]
286274 domain = None , # type: Optional[str]
287275 string_index_type = "TextElements_v8" , # type: Optional[Union[str, "_models.StringIndexType"]]
276+ pii_categories = None , # type: Optional[List[Union[str, "_models.PiiCategory"]]]
288277 ** kwargs # type: Any
289278 ):
290279 """Entities containing personal information.
@@ -296,7 +285,7 @@ def entities_recognition_pii(
296285 list of enabled languages.
297286
298287 :param documents: The set of documents to process as part of this batch.
299- :type documents: list[~azure.ai.textanalytics.v3_1_preview_3 .models.MultiLanguageInput]
288+ :type documents: list[~azure.ai.textanalytics.v3_1_preview_4 .models.MultiLanguageInput]
300289 :param model_version: (Optional) This value indicates which model will be used for scoring. If
301290 a model-version is not specified, the API should default to the latest, non-preview version.
302291 :type model_version: str
@@ -309,16 +298,16 @@ def entities_recognition_pii(
309298 :param string_index_type: (Optional) Specifies the method used to interpret string offsets.
310299 Defaults to Text Elements (Graphemes) according to Unicode v8.0.0. For additional information
311300 see https://aka.ms/text-analytics-offsets.
312- :type string_index_type: str or ~azure.ai.textanalytics.v3_1_preview_3.models.StringIndexType
301+ :type string_index_type: str or ~azure.ai.textanalytics.v3_1_preview_4.models.StringIndexType
302+ :param pii_categories: (Optional) describes the PII categories to return.
303+ :type pii_categories: list[str or ~azure.ai.textanalytics.v3_1_preview_4.models.PiiCategory]
313304 :keyword callable cls: A custom type or function that will be passed the direct response
314305 :return: PiiResult, or the result of cls(response)
315- :rtype: ~azure.ai.textanalytics.v3_1_preview_3 .models.PiiResult
306+ :rtype: ~azure.ai.textanalytics.v3_1_preview_4 .models.PiiResult
316307 :raises: ~azure.core.exceptions.HttpResponseError
317308 """
318309 api_version = self ._get_api_version ('entities_recognition_pii' )
319- if api_version == 'v3.1-preview.3' :
320- from .v3_1_preview_3 .operations import TextAnalyticsClientOperationsMixin as OperationClass
321- elif api_version == 'v3.1-preview.4' :
310+ if api_version == 'v3.1-preview.4' :
322311 from .v3_1_preview_4 .operations import TextAnalyticsClientOperationsMixin as OperationClass
323312 else :
324313 raise ValueError ("API version {} does not have operation 'entities_recognition_pii'" .format (api_version ))
@@ -328,7 +317,7 @@ def entities_recognition_pii(
328317 mixin_instance ._serialize = Serializer (self ._models_dict (api_version ))
329318 mixin_instance ._serialize .client_side_validation = False
330319 mixin_instance ._deserialize = Deserializer (self ._models_dict (api_version ))
331- return mixin_instance .entities_recognition_pii (documents , model_version , show_stats , domain , string_index_type , ** kwargs )
320+ return mixin_instance .entities_recognition_pii (documents , model_version , show_stats , domain , string_index_type , pii_categories , ** kwargs )
332321
333322 def health_status (
334323 self ,
@@ -355,13 +344,11 @@ def health_status(
355344 :type show_stats: bool
356345 :keyword callable cls: A custom type or function that will be passed the direct response
357346 :return: HealthcareJobState, or the result of cls(response)
358- :rtype: ~azure.ai.textanalytics.v3_1_preview_3 .models.HealthcareJobState
347+ :rtype: ~azure.ai.textanalytics.v3_1_preview_4 .models.HealthcareJobState
359348 :raises: ~azure.core.exceptions.HttpResponseError
360349 """
361350 api_version = self ._get_api_version ('health_status' )
362- if api_version == 'v3.1-preview.3' :
363- from .v3_1_preview_3 .operations import TextAnalyticsClientOperationsMixin as OperationClass
364- elif api_version == 'v3.1-preview.4' :
351+ if api_version == 'v3.1-preview.4' :
365352 from .v3_1_preview_4 .operations import TextAnalyticsClientOperationsMixin as OperationClass
366353 else :
367354 raise ValueError ("API version {} does not have operation 'health_status'" .format (api_version ))
@@ -402,8 +389,6 @@ def key_phrases(
402389 api_version = self ._get_api_version ('key_phrases' )
403390 if api_version == 'v3.0' :
404391 from .v3_0 .operations import TextAnalyticsClientOperationsMixin as OperationClass
405- elif api_version == 'v3.1-preview.3' :
406- from .v3_1_preview_3 .operations import TextAnalyticsClientOperationsMixin as OperationClass
407392 elif api_version == 'v3.1-preview.4' :
408393 from .v3_1_preview_4 .operations import TextAnalyticsClientOperationsMixin as OperationClass
409394 else :
@@ -446,8 +431,6 @@ def languages(
446431 api_version = self ._get_api_version ('languages' )
447432 if api_version == 'v3.0' :
448433 from .v3_0 .operations import TextAnalyticsClientOperationsMixin as OperationClass
449- elif api_version == 'v3.1-preview.3' :
450- from .v3_1_preview_3 .operations import TextAnalyticsClientOperationsMixin as OperationClass
451434 elif api_version == 'v3.1-preview.4' :
452435 from .v3_1_preview_4 .operations import TextAnalyticsClientOperationsMixin as OperationClass
453436 else :
@@ -490,8 +473,6 @@ def sentiment(
490473 api_version = self ._get_api_version ('sentiment' )
491474 if api_version == 'v3.0' :
492475 from .v3_0 .operations import TextAnalyticsClientOperationsMixin as OperationClass
493- elif api_version == 'v3.1-preview.3' :
494- from .v3_1_preview_3 .operations import TextAnalyticsClientOperationsMixin as OperationClass
495476 elif api_version == 'v3.1-preview.4' :
496477 from .v3_1_preview_4 .operations import TextAnalyticsClientOperationsMixin as OperationClass
497478 else :
0 commit comments