Python library and CLI tool to interface with Google Translate's text-to-speech API
Clone or download
Latest commit 98e9d27 Jan 2, 2019
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
docs Update module.rst Jan 2, 2019
gtts Version bump 2.0.3 Dec 15, 2018
news Update Changelog Jan 3, 2019
.appveyor.yml cleanup CI files Nov 11, 2018
.gitignore Updated Docs & Co. Apr 29, 2018
.readthedocs.yml ReadTheDocs conf. Apr 30, 2018
.travis.yml osx default py3 [skip appveyor]" Nov 11, 2018
CHANGELOG.rst Version bump 2.0.3 Dec 15, 2018
CONTRIBUTING.rst Updated Docs & Co. Apr 29, 2018
LICENSE Updated Docs & Co. Apr 29, 2018
MANIFEST.in Updated Manifest Dec 15, 2018
README.md modernize setup Jul 16, 2018
pyproject.toml New Changelog & Changes for 2.0.0 Apr 30, 2018
setup.cfg Require gtts_token 1.1.3 Dec 24, 2018
setup.py modernize setup Jul 16, 2018

README.md

gTTS

gTTS (Google Text-to-Speech), a Python library and CLI tool to interface with Google Translate's text-to-speech API. Writes spoken mp3 data to a file, a file-like object (bytestring) for further audio manipulation, or stdout. http://gtts.readthedocs.org/

PyPI version Python versions Build Status AppVeyor Coveralls Commits Since PyPi Downloads

Features

  • Customizable speech-specific sentence tokenizer that allows for unlimited lengths of text to be read, all while keeping proper intonation, abbreviations, decimals and more;
  • Customizable text pre-processors which can, for example, provide pronunciation corrections;
  • Automatic retrieval of supported languages.

Installation

$ pip install gTTS

Quickstart

Command Line:

$ gtts-cli 'hello' --output hello.mp3

Module:

>>> from gtts import gTTS
>>> tts = gTTS('hello')
>>> tts.save('hello.mp3')

See http://gtts.readthedocs.org/ for documentation and examples.

Project

Licence

The MIT License (MIT) Copyright © 2014-2018 Pierre Nicolas Durette