Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/alekssamos/yandexfreetranslate
Yandex Translate free unlim python
https://github.com/alekssamos/yandexfreetranslate
translate translation translator yandex-api yandex-translate
Last synced: 15 days ago
JSON representation
Yandex Translate free unlim python
- Host: GitHub
- URL: https://github.com/alekssamos/yandexfreetranslate
- Owner: alekssamos
- License: mit
- Created: 2020-08-29T11:43:23.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2021-04-25T14:28:04.000Z (almost 4 years ago)
- Last Synced: 2024-11-08T16:05:20.286Z (3 months ago)
- Topics: translate, translation, translator, yandex-api, yandex-translate
- Language: HTML
- Homepage: https://pypi.org/project/yandexfreetranslate/
- Size: 65.4 KB
- Stars: 38
- Watchers: 2
- Forks: 7
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
Yandex Free Translate! More than six million requests! No limits or restrictions! Tested within a year!
Яндекс Переводчик бесплатно (Более шести миллионов запросов! Никаких ограничений и лимитов! Проверено в течение года!)
## Installing (Установка)
`python3 -m pip install git+https://github.com/alekssamos/yandexfreetranslate.git`or (или)
`python3 -m pip install yandexfreetranslate`
### Using (Использование)
> Если не работает, то при создании класса поменяйте API на "ios", по умолчанию используется "web".
> If it doesn't work, then when creating the class, change the API to "ios", use "web" by default.
```python3
from yandexfreetranslate import YandexFreeTranslate
yt = YandexFreeTranslate()
# yt = YandexFreeTranslate(api = "web")
# yt = YandexFreeTranslate(api = "ios")# yt.set_proxy("socks5", "localhost", 9050, "username", "password")
print(yt.translate("en", "ru", "Hello, world!"))
```
Or from command line (Или из командной строки):
```bash
# for use socks4, socks5 or https proxy (Для использования socks4, socks5 или https proxy):
export https_proxy=127.0.0.1:9050
# or (или)
export https_proxy=username:[email protected]:9050python3 yandexfreetranslate/__init__.py en ru "Hello, world!"
# or (или)
python3 yandexfreetranslate/__init__.py en ru in.txt
# or (или)
python3 yandexfreetranslate/__init__.py en ru in.txt out.txt
```
## Runing tests (Запуск тестов)
```bash
git clone https://github.com/alekssamos/yandexfreetranslate.git
cd yandexfreetranslate
python3 -m unittest# or
python3 -m pip install tox
python3 -m tox
```