Usage

rvtts

Convert text or input file to to mp3 using ResponsiveVoice’s API.

rvtts [OPTIONS]

Options

-l, --lang

Print all supported voice.

-t, --text <text>

Text to convert.

-i, --input <input>

Input file. For example: -i doc-ton-tam-gioi-chuong-0001.txt

-o, --output <output>

Output file. For example: -o doc-ton-tam-gioi-chuong-0001.mp3 [required]

-v, --voice <voice>

Output voices. For example: -v vietnamese_male [required]

--pitch <pitch>

Adjust pitch (range 0 to 1). Default: 0.5

--rate <rate>

Adjust rate (range 0 to 1). Default: 0.5

--volume <volume>

Adjust volume (range 0 to 1). Default: 1

-d, --debug

Debug mode.

--version

Show the version and exit.

rvtts.rvtts.responsiveVoice

class rvtts.rvtts.responsiveVoice(text='', pitch=0.5, rate=0.5, vol=1, pre_processor_funcs=[<function tone_marks>, <function end_of_line>, <function abbreviations>, <function word_sub>], tokenizer_func=<bound method Tokenizer.run of re.compile('(?<=\?).|(?<=!).|(?<=?).|(?<=!).|(?<!\.[a-z])\. |(?<!\.[a-z]), |(?<!\d):|,|—|、|。|\]|:|\)|\[|\n|¡|¿|;|‥|،|…|\(', re.IGNORECASE) from: [<function tone_marks>, <function period_comma>, <function colon>, <function other_punctuation>]>)

rvTTS

A CLI tool to convert text to MP3 using ResponsiveVoice’s API.

Parameters
  • text (string) – text to be converted.

  • pitch (float, optional) – adjust pitch output. Default is 0.5.

  • rate (float, optional) – adjust rate output. Default is 0.5.

  • vol (float, optional) – adjust volume output. Default is 1.

get_mp3(output_file='', voice_name='english_us_male', pitch=0.5, rate=0.5, volume=1)

Call the API and write to file.

Parameters
  • output_file (string) – Filename to write to.

  • voice_name (string) – voice name. Default is english_us_male. Use rvtts –lang to get all supported voices.

  • pitch (float, optional) – adjust pitch output. Default is 0.5.

  • rate (float, optional) – adjust rate output. Default is 0.5.

  • vol (float, optional) – adjust volume output. Default is 1.