module

TTS

Constants

VERSION = "0.1.0"

Class methods

authenticate(json_path : String)
  • json_path: Path to the credentials json file
Source
to_file(text : String, lang : String, path : String)

Convert text to speech and save the result in a .mp3 file.

  • text: Text to convert
  • lang: Language
  • path: Path to the new file

Example:

TTS.authenticate "./credentials.json" # Authenticate
TTS.to_file("Hi, how are you?", "en", "./audio.mp3")
Source

Nested types