GoogleTrans TTS
GoogleTrans provides free text-to-speech capabilities through Google Translate's speech synthesis. It's useful for basic TTS needs without requiring API keys or authentication.
Platform Support
GoogleTrans works on all platforms with internet connectivity:
from tts_wrapper import GoogleTransClient
# Initialize client (no credentials needed)
tts = GoogleTransClient()
Features
Language Selection
Select from available languages:
# Set language
tts.set_voice("en", "en") # Language code for English
# Different languages
tts.set_voice("fr", "fr") # French
tts.set_voice("es", "es") # Spanish
tts.set_voice("de", "de") # German
Basic Synthesis
Simple text-to-speech conversion:
# Basic speech synthesis
tts.speak("Hello, this is a test of Google Translate TTS")
# Different languages
tts.set_voice("fr", "fr")
tts.speak("Bonjour, ceci est un test")
File Output
Save synthesized speech to file:
# Save as MP3
tts.synth_to_file("Hello world", "output.mp3", "mp3")
# Save as WAV
tts.synth_to_file("Hello world", "output.wav", "wav")