Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[AutoPR cognitiveservices/data-plane/TranslatorText] Translator Text API V3 #4387

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions azure-cognitiveservices-translatortext/HISTORY.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
.. :changelog:

Release History
===============

0.1.0 (1970-01-01)
++++++++++++++++++

* Initial Release
4 changes: 4 additions & 0 deletions azure-cognitiveservices-translatortext/MANIFEST.in
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
include *.rst
include azure/__init__.py
include azure/cognitiveservices/__init__.py

30 changes: 30 additions & 0 deletions azure-cognitiveservices-translatortext/README.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
Microsoft Azure SDK for Python
==============================

This is the Microsoft Azure MyService Management Client Library.

Azure Resource Manager (ARM) is the next generation of management APIs that
replace the old Azure Service Management (ASM).

This package has been tested with Python 2.7, 3.4, 3.5, 3.6 and 3.7.

For the older Azure Service Management (ASM) libraries, see
`azure-servicemanagement-legacy <https://pypi.python.org/pypi/azure-servicemanagement-legacy>`__ library.

For a more complete set of Azure libraries, see the `azure <https://pypi.python.org/pypi/azure>`__ bundle package.


Usage
=====

For code examples, see `MyService Management
<https://docs.microsoft.com/python/api/overview/azure/>`__
on docs.microsoft.com.


Provide Feedback
================

If you encounter any bugs or have suggestions, please file an issue in the
`Issues <https://github.com/Azure/azure-sdk-for-python/issues>`__
section of the project.
1 change: 1 addition & 0 deletions azure-cognitiveservices-translatortext/azure/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
__path__ = __import__('pkgutil').extend_path(__path__, __name__)
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
__path__ = __import__('pkgutil').extend_path(__path__, __name__)
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# coding=utf-8
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for
# license information.
#
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may cause incorrect behavior and will be lost if the code is
# regenerated.
# --------------------------------------------------------------------------

from .translator_text_client import TranslatorTextClient
from .version import VERSION

__all__ = ['TranslatorTextClient']

__version__ = VERSION

Original file line number Diff line number Diff line change
@@ -0,0 +1,124 @@
# coding=utf-8
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for
# license information.
#
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may cause incorrect behavior and will be lost if the code is
# regenerated.
# --------------------------------------------------------------------------

try:
from .languages_result_translation_language_code_py3 import LanguagesResultTranslationLanguageCode
from .languages_result_translation_py3 import LanguagesResultTranslation
from .languages_result_transliteration_language_code_scripts_item_to_scripts_item_py3 import LanguagesResultTransliterationLanguageCodeScriptsItemToScriptsItem
from .languages_result_transliteration_language_code_scripts_item_py3 import LanguagesResultTransliterationLanguageCodeScriptsItem
from .languages_result_transliteration_language_code_py3 import LanguagesResultTransliterationLanguageCode
from .languages_result_transliteration_py3 import LanguagesResultTransliteration
from .languages_result_dictionary_language_code_translations_item_py3 import LanguagesResultDictionaryLanguageCodeTranslationsItem
from .languages_result_dictionary_language_code_py3 import LanguagesResultDictionaryLanguageCode
from .languages_result_dictionary_py3 import LanguagesResultDictionary
from .languages_result_py3 import LanguagesResult
from .dictionary_example_result_item_examples_item_py3 import DictionaryExampleResultItemExamplesItem
from .dictionary_example_result_item_py3 import DictionaryExampleResultItem
from .dictionary_lookup_result_item_translations_item_back_translations_item_py3 import DictionaryLookupResultItemTranslationsItemBackTranslationsItem
from .dictionary_lookup_result_item_translations_item_py3 import DictionaryLookupResultItemTranslationsItem
from .dictionary_lookup_result_item_py3 import DictionaryLookupResultItem
from .translate_result_item_translation_item_py3 import TranslateResultItemTranslationItem
from .translate_result_item_py3 import TranslateResultItem
from .translate_result_all_item_detected_language_py3 import TranslateResultAllItemDetectedLanguage
from .translate_result_all_item_translations_item_transliteration_py3 import TranslateResultAllItemTranslationsItemTransliteration
from .translate_result_all_item_translations_item_alignment_py3 import TranslateResultAllItemTranslationsItemAlignment
from .translate_result_all_item_translations_item_sent_len_src_sent_len_item_py3 import TranslateResultAllItemTranslationsItemSentLenSrcSentLenItem
from .translate_result_all_item_translations_item_sent_len_trans_sent_len_item_py3 import TranslateResultAllItemTranslationsItemSentLenTransSentLenItem
from .translate_result_all_item_translations_item_sent_len_py3 import TranslateResultAllItemTranslationsItemSentLen
from .translate_result_all_item_translations_item_py3 import TranslateResultAllItemTranslationsItem
from .translate_result_all_item_py3 import TranslateResultAllItem
from .break_sentence_result_item_py3 import BreakSentenceResultItem
from .transliterate_result_item_py3 import TransliterateResultItem
from .detect_result_item_py3 import DetectResultItem
from .break_sentence_text_input_py3 import BreakSentenceTextInput
from .error_message_error_py3 import ErrorMessageError
from .error_message_py3 import ErrorMessage, ErrorMessageException
from .detect_text_input_py3 import DetectTextInput
from .dictionary_lookup_text_input_py3 import DictionaryLookupTextInput
from .dictionary_example_text_input_py3 import DictionaryExampleTextInput
from .translate_text_input_py3 import TranslateTextInput
from .transliterate_text_input_py3 import TransliterateTextInput
except (SyntaxError, ImportError):
from .languages_result_translation_language_code import LanguagesResultTranslationLanguageCode
from .languages_result_translation import LanguagesResultTranslation
from .languages_result_transliteration_language_code_scripts_item_to_scripts_item import LanguagesResultTransliterationLanguageCodeScriptsItemToScriptsItem
from .languages_result_transliteration_language_code_scripts_item import LanguagesResultTransliterationLanguageCodeScriptsItem
from .languages_result_transliteration_language_code import LanguagesResultTransliterationLanguageCode
from .languages_result_transliteration import LanguagesResultTransliteration
from .languages_result_dictionary_language_code_translations_item import LanguagesResultDictionaryLanguageCodeTranslationsItem
from .languages_result_dictionary_language_code import LanguagesResultDictionaryLanguageCode
from .languages_result_dictionary import LanguagesResultDictionary
from .languages_result import LanguagesResult
from .dictionary_example_result_item_examples_item import DictionaryExampleResultItemExamplesItem
from .dictionary_example_result_item import DictionaryExampleResultItem
from .dictionary_lookup_result_item_translations_item_back_translations_item import DictionaryLookupResultItemTranslationsItemBackTranslationsItem
from .dictionary_lookup_result_item_translations_item import DictionaryLookupResultItemTranslationsItem
from .dictionary_lookup_result_item import DictionaryLookupResultItem
from .translate_result_item_translation_item import TranslateResultItemTranslationItem
from .translate_result_item import TranslateResultItem
from .translate_result_all_item_detected_language import TranslateResultAllItemDetectedLanguage
from .translate_result_all_item_translations_item_transliteration import TranslateResultAllItemTranslationsItemTransliteration
from .translate_result_all_item_translations_item_alignment import TranslateResultAllItemTranslationsItemAlignment
from .translate_result_all_item_translations_item_sent_len_src_sent_len_item import TranslateResultAllItemTranslationsItemSentLenSrcSentLenItem
from .translate_result_all_item_translations_item_sent_len_trans_sent_len_item import TranslateResultAllItemTranslationsItemSentLenTransSentLenItem
from .translate_result_all_item_translations_item_sent_len import TranslateResultAllItemTranslationsItemSentLen
from .translate_result_all_item_translations_item import TranslateResultAllItemTranslationsItem
from .translate_result_all_item import TranslateResultAllItem
from .break_sentence_result_item import BreakSentenceResultItem
from .transliterate_result_item import TransliterateResultItem
from .detect_result_item import DetectResultItem
from .break_sentence_text_input import BreakSentenceTextInput
from .error_message_error import ErrorMessageError
from .error_message import ErrorMessage, ErrorMessageException
from .detect_text_input import DetectTextInput
from .dictionary_lookup_text_input import DictionaryLookupTextInput
from .dictionary_example_text_input import DictionaryExampleTextInput
from .translate_text_input import TranslateTextInput
from .transliterate_text_input import TransliterateTextInput

__all__ = [
'LanguagesResultTranslationLanguageCode',
'LanguagesResultTranslation',
'LanguagesResultTransliterationLanguageCodeScriptsItemToScriptsItem',
'LanguagesResultTransliterationLanguageCodeScriptsItem',
'LanguagesResultTransliterationLanguageCode',
'LanguagesResultTransliteration',
'LanguagesResultDictionaryLanguageCodeTranslationsItem',
'LanguagesResultDictionaryLanguageCode',
'LanguagesResultDictionary',
'LanguagesResult',
'DictionaryExampleResultItemExamplesItem',
'DictionaryExampleResultItem',
'DictionaryLookupResultItemTranslationsItemBackTranslationsItem',
'DictionaryLookupResultItemTranslationsItem',
'DictionaryLookupResultItem',
'TranslateResultItemTranslationItem',
'TranslateResultItem',
'TranslateResultAllItemDetectedLanguage',
'TranslateResultAllItemTranslationsItemTransliteration',
'TranslateResultAllItemTranslationsItemAlignment',
'TranslateResultAllItemTranslationsItemSentLenSrcSentLenItem',
'TranslateResultAllItemTranslationsItemSentLenTransSentLenItem',
'TranslateResultAllItemTranslationsItemSentLen',
'TranslateResultAllItemTranslationsItem',
'TranslateResultAllItem',
'BreakSentenceResultItem',
'TransliterateResultItem',
'DetectResultItem',
'BreakSentenceTextInput',
'ErrorMessageError',
'ErrorMessage', 'ErrorMessageException',
'DetectTextInput',
'DictionaryLookupTextInput',
'DictionaryExampleTextInput',
'TranslateTextInput',
'TransliterateTextInput',
]
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# coding=utf-8
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for
# license information.
#
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may cause incorrect behavior and will be lost if the code is
# regenerated.
# --------------------------------------------------------------------------

from msrest.serialization import Model


class BreakSentenceResultItem(Model):
"""BreakSentenceResultItem.

:param sent_len:
:type sent_len: list[int]
"""

_attribute_map = {
'sent_len': {'key': 'sentLen', 'type': '[int]'},
}

def __init__(self, **kwargs):
super(BreakSentenceResultItem, self).__init__(**kwargs)
self.sent_len = kwargs.get('sent_len', None)
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# coding=utf-8
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for
# license information.
#
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may cause incorrect behavior and will be lost if the code is
# regenerated.
# --------------------------------------------------------------------------

from msrest.serialization import Model


class BreakSentenceResultItem(Model):
"""BreakSentenceResultItem.

:param sent_len:
:type sent_len: list[int]
"""

_attribute_map = {
'sent_len': {'key': 'sentLen', 'type': '[int]'},
}

def __init__(self, *, sent_len=None, **kwargs) -> None:
super(BreakSentenceResultItem, self).__init__(**kwargs)
self.sent_len = sent_len
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# coding=utf-8
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for
# license information.
#
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may cause incorrect behavior and will be lost if the code is
# regenerated.
# --------------------------------------------------------------------------

from msrest.serialization import Model


class BreakSentenceTextInput(Model):
"""Text needed for break sentence request.

:param text:
:type text: str
"""

_attribute_map = {
'text': {'key': 'text', 'type': 'str'},
}

def __init__(self, **kwargs):
super(BreakSentenceTextInput, self).__init__(**kwargs)
self.text = kwargs.get('text', None)
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# coding=utf-8
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for
# license information.
#
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may cause incorrect behavior and will be lost if the code is
# regenerated.
# --------------------------------------------------------------------------

from msrest.serialization import Model


class BreakSentenceTextInput(Model):
"""Text needed for break sentence request.

:param text:
:type text: str
"""

_attribute_map = {
'text': {'key': 'text', 'type': 'str'},
}

def __init__(self, *, text: str=None, **kwargs) -> None:
super(BreakSentenceTextInput, self).__init__(**kwargs)
self.text = text
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# coding=utf-8
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for
# license information.
#
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may cause incorrect behavior and will be lost if the code is
# regenerated.
# --------------------------------------------------------------------------

from msrest.serialization import Model


class DetectResultItem(Model):
"""DetectResultItem.

:param text:
:type text: str
"""

_attribute_map = {
'text': {'key': 'text', 'type': 'str'},
}

def __init__(self, **kwargs):
super(DetectResultItem, self).__init__(**kwargs)
self.text = kwargs.get('text', None)
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# coding=utf-8
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for
# license information.
#
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may cause incorrect behavior and will be lost if the code is
# regenerated.
# --------------------------------------------------------------------------

from msrest.serialization import Model


class DetectResultItem(Model):
"""DetectResultItem.

:param text:
:type text: str
"""

_attribute_map = {
'text': {'key': 'text', 'type': 'str'},
}

def __init__(self, *, text: str=None, **kwargs) -> None:
super(DetectResultItem, self).__init__(**kwargs)
self.text = text
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# coding=utf-8
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for
# license information.
#
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may cause incorrect behavior and will be lost if the code is
# regenerated.
# --------------------------------------------------------------------------

from msrest.serialization import Model


class DetectTextInput(Model):
"""Text needed for detect request .

:param text:
:type text: str
"""

_attribute_map = {
'text': {'key': 'text', 'type': 'str'},
}

def __init__(self, **kwargs):
super(DetectTextInput, self).__init__(**kwargs)
self.text = kwargs.get('text', None)
Loading