Easy Google Translate
Project description
easygoogletranslate
Unofficial Google Translate API.
This library does not need an api key or something else to use, it's free and simple. You can either use a string or a file to translate but the text must be equal to or less than 5000 character. You can split your text into 5000 characters to translate more.
Google Translate supports 108 different languages. You can use any of them as source and target language in this application. If source language is not specified, it will detect source language automatically. This application supports multi thread translation, you can use it to translate multiple languages at once. Detailed language list can be found here: https://cloud.google.com/translate/docs/languages
Examples:
-
Specify default source and target language at beginning and use it any time.
translator = EasyGoogleTranslate( source_language='en', target_language='de', timeout=10 ) result = translator.translate('This is an example.') print(result)
-
Don't specify default parameters.
translator = EasyGoogleTranslate() result = translator.translate('This is an example.', target_language='tr') print(result)
-
Override default parameters.
translator = EasyGoogleTranslate(target_language='tr') result = translator.translate('This is an example.', target_language='fr') print(result)
-
Translate a text in multiple languages at once via multi-threading.
translator = EasyGoogleTranslate() result = translator.translate(text='This is an example.', target_language=['tr', 'fr', 'de']) print(result)
-
Translate a file in multiple languages at once via multi-threading.
translator = EasyGoogleTranslate() result = translator.translate_file(file_path='text.txt', target_language=['tr', 'fr', 'de']) print(result)
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for easygoogletranslate-0.0.1.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 8884ade7a8d0745d32366342e99670380944471bb203575d5d64d6ac6f562006 |
|
MD5 | 50675d7dd4b1e645d154fe6afd624932 |
|
BLAKE2b-256 | b460d3e5944a0f25e894f589b3b66d32ca96167ba852a2f1ca95f7e4e7ae1d4d |
Hashes for easygoogletranslate-0.0.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | dfe4c3e7770ba0c9597839af3f0273675f40142bfa60795e6e8a5030e2899e7e |
|
MD5 | 1efb9b3b0f240308d020d3310da19ec5 |
|
BLAKE2b-256 | 97923ef8fd0f1345a753e82ee225380b8545d3995bfd9c8a4c98930c430612b1 |