XTranslator is a package that allows you to detect the language of a given text and translate it into various languages. With its simple and intuitive interface, you can easily integrate language detection and translation capabilities into your applications.
To install XTranslator, simply run the following command:
pip install xtranslator
To use XTranslator in your project, follow these steps:
import xtranslator
from xtranslator import detect
text = "Hello, my nam is XTranslator"
detector = "fasttext"
print(detect(text, detector))
from xtranslator import translate
text = "Hello, world!"
translator = "google"
model_name = "google"
dest_language = "sk"
detector = "fasttext"
print(translate(text, dest_language, translator, model_name, detector))
Contributions are welcome! If you have any ideas, suggestions, or bug reports, please open an issue or submit a pull request on the GitHub repository.
XTranslator is licensed under the MIT License.
15 commits
Python
100.0%
XTranslator is a package that allows you to detect the language of a given text and translate it into various languages. With its simple and intuitive interface, you can easily integrate language detection and translation capabilities into your applications.
To install XTranslator, simply run the following command:
pip install xtranslator
To use XTranslator in your project, follow these steps:
import xtranslator
from xtranslator import detect
text = "Hello, my nam is XTranslator"
detector = "fasttext"
print(detect(text, detector))
from xtranslator import translate
text = "Hello, world!"
translator = "google"
model_name = "google"
dest_language = "sk"
detector = "fasttext"
print(translate(text, dest_language, translator, model_name, detector))
Contributions are welcome! If you have any ideas, suggestions, or bug reports, please open an issue or submit a pull request on the GitHub repository.
XTranslator is licensed under the MIT License.
15 commits
Python
100.0%