Skip to content
/ PyTransLingo Public template

PyTransLingo is a command-line translation and text-to-speech tool. Translate text between languages, get the meaning of translated text, perform Google searches, and listen to search results using text-to-speech.Run "PyTransLingo" in the terminal or command prompt to use the pip.

License

MIT, MIT licenses found

Licenses found

MIT
LICENSE
MIT
LICENCE.txt
Notifications You must be signed in to change notification settings

Hp-0420/PyTransLingo

Repository files navigation

PyTransLingo

PyTransLingo is a Python package that provides translation and search functionality using various APIs. It allows you to translate text between different languages and search for information on Google.

Installation

To install PyTransLingo, use the following command:

pip install PyTransLingo

Dependencies

PyTransLingo requires the following dependencies, which can be installed using pip:

pip install pyttsx3 translate PyDictionary requests bs4 tabulate

Usage

Import the necessary modules:

import pyttsx3
from translate import Translator
from PyDictionary import PyDictionary
import requests
from bs4 import BeautifulSoup
from tabulate import tabulate

Use the translator_menu() function to interact with the translation and search functionalities:

translator_menu()

Examples:

  1. Translating text:
source_lang = 'en'
target_lang = 'fr'
text = 'Hello, how are you?'
translate_and_speak(source_lang, target_lang, text)
  1. Searching on Google:
search_text = 'Python programming
search_google(search_text)

Contributing

Contributions to PyTransLingo are welcome! If you find any issues or have suggestions for improvement, please open an issue or submit a pull request on GitHub.

Setting up a virtual environment

If you prefer to work in a virtual environment, follow these steps:

  1. In the command prompt or terminal, navigate to the project directory.

  2. Run the following command to create a virtual environment named "myenv" and activate it:

For Unix/macOS/Linux:

python3 -m venv myenv
source myenv/bin/activate

For Windows:

python3 -m venv myenv
myenv\Scripts\activate.bat

This will create a virtual environment and activate it, allowing you to work within an isolated Python environment.

Note: Make sure you have Python 3.x installed before creating the virtual environment.

About

PyTransLingo is a command-line translation and text-to-speech tool. Translate text between languages, get the meaning of translated text, perform Google searches, and listen to search results using text-to-speech.Run "PyTransLingo" in the terminal or command prompt to use the pip.

Topics

Resources

License

MIT, MIT licenses found

Licenses found

MIT
LICENSE
MIT
LICENCE.txt

Stars

Watchers

Forks

Packages

No packages published

Languages