cloudlanguagetools 11.6.1__tar.gz → 11.6.2__tar.gz
Sign up to get free protection for your applications and to get access to all the features.
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/PKG-INFO +1 -1
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/alibaba.py +7 -10
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools.egg-info/PKG-INFO +1 -1
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/setup.py +1 -1
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/LICENSE +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/README.rst +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/__init__.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/amazon.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/argostranslate.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/audio_processing.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/azure.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/cereproc.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/chatapi.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/constants.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/deepl.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/dictionarylookup.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/easypronunciation.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/elevenlabs.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/encryption.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/epitran.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/errors.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/forvo.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/fptai.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/google.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/keys.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/languages.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/libretranslate.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/mandarincantonese.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/naver.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/openai.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/options.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/pythainlp.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/service.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/servicemanager.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/spacy.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/test_services.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/tokenization.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/translationlanguage.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/transliterationlanguage.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/ttsvoice.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/vocalware.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/voicen.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/watson.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/wenlin.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools.egg-info/SOURCES.txt +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools.egg-info/dependency_links.txt +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools.egg-info/requires.txt +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools.egg-info/top_level.txt +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/setup.cfg +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/tests/test_audio.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/tests/test_breakdown.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/tests/test_chatapi.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/tests/test_dictionary_lookup.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/tests/test_llm.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/tests/test_mock_services.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/tests/test_servicemanager.py +0 -0
- {cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/tests/test_translation.py +0 -0
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.1
|
2
2
|
Name: cloudlanguagetools
|
3
|
-
Version: 11.6.
|
3
|
+
Version: 11.6.2
|
4
4
|
Summary: Interface with various cloud APIs for language processing such as translation, text to speech
|
5
5
|
Home-page: https://github.com/Language-Tools/cloud-language-tools-core
|
6
6
|
Author: Luc
|
@@ -97,6 +97,7 @@ class AlibabaService(cloudlanguagetools.service.Service):
|
|
97
97
|
logger.info(f"Got access token: {self.access_token}")
|
98
98
|
|
99
99
|
def get_tts_audio(self, text, voice_key, options):
|
100
|
+
logger.debug(f'get_tts_audio, text: {text} voice_key: {voice_key}')
|
100
101
|
if not self.access_token or self.access_token["ExpireTime"] <= int(time.time()):
|
101
102
|
self.refresh_token()
|
102
103
|
|
@@ -120,6 +121,8 @@ class AlibabaService(cloudlanguagetools.service.Service):
|
|
120
121
|
timeout=cloudlanguagetools.constants.RequestTimeout
|
121
122
|
)
|
122
123
|
|
124
|
+
logger.debug(f'response status code: {response.status_code} headers: {pprint.pformat(response.headers)} length of response: {len(response.content)}')
|
125
|
+
|
123
126
|
if response.status_code != 200:
|
124
127
|
data = response.json()
|
125
128
|
error_message = f'could not retrieve audio using Alibaba: {response.content}'
|
@@ -133,18 +136,12 @@ class AlibabaService(cloudlanguagetools.service.Service):
|
|
133
136
|
f'Got bad content type in response: {response.headers["Content-Type"]}'
|
134
137
|
)
|
135
138
|
|
136
|
-
# check the content length
|
137
|
-
if len(response.content) == 0:
|
138
|
-
# empty sound response
|
139
|
-
error_message = f'empty sound response. headers: {pprint.pformat(response.headers)}'
|
140
|
-
logger.error(error_message)
|
141
|
-
raise cloudlanguagetools.errors.RequestError(text, voice, f'empty sound result')
|
142
|
-
|
143
|
-
|
144
139
|
# Create a temporary file and write the audio content to it
|
145
140
|
output_temp_file = tempfile.NamedTemporaryFile(prefix=f'cloudlanguage_tools_{self.__class__.__name__}_audio', suffix='.mp3')
|
146
|
-
output_temp_file.
|
147
|
-
|
141
|
+
output_temp_filename = output_temp_file.name
|
142
|
+
with open(output_temp_filename, 'wb') as audio:
|
143
|
+
audio.write(response.content)
|
144
|
+
logger.debug(f'result temporary file name: {output_temp_file.name}')
|
148
145
|
return output_temp_file
|
149
146
|
|
150
147
|
def get_tts_voice_list(self):
|
{cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools.egg-info/PKG-INFO
RENAMED
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.1
|
2
2
|
Name: cloudlanguagetools
|
3
|
-
Version: 11.6.
|
3
|
+
Version: 11.6.2
|
4
4
|
Summary: Interface with various cloud APIs for language processing such as translation, text to speech
|
5
5
|
Home-page: https://github.com/Language-Tools/cloud-language-tools-core
|
6
6
|
Author: Luc
|
@@ -6,7 +6,7 @@ from setuptools.command.install import install
|
|
6
6
|
# twine upload dist/*
|
7
7
|
|
8
8
|
setup(name='cloudlanguagetools',
|
9
|
-
version='11.6.
|
9
|
+
version='11.6.2',
|
10
10
|
description='Interface with various cloud APIs for language processing such as translation, text to speech',
|
11
11
|
long_description=open('README.rst', encoding='utf-8').read(),
|
12
12
|
url='https://github.com/Language-Tools/cloud-language-tools-core',
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
{cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/argostranslate.py
RENAMED
File without changes
|
{cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/audio_processing.py
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
{cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/dictionarylookup.py
RENAMED
File without changes
|
{cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/easypronunciation.py
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
{cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/libretranslate.py
RENAMED
File without changes
|
{cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/mandarincantonese.py
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
{cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/servicemanager.py
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
{cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools/translationlanguage.py
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
{cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools.egg-info/SOURCES.txt
RENAMED
File without changes
|
File without changes
|
{cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools.egg-info/requires.txt
RENAMED
File without changes
|
{cloudlanguagetools-11.6.1 → cloudlanguagetools-11.6.2}/cloudlanguagetools.egg-info/top_level.txt
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|