Class TextToSpeechSettings (2.3.0)

TextToSpeechSettings(mapping=None, *, ignore_unknown_fields=False, **kwargs)

Instructs the speech synthesizer on how to generate the output audio content.


enable_text_to_speech bool
Optional. Indicates whether text to speech is enabled. Even when this field is false, other settings in this proto are still retained.
Required. Audio encoding of the synthesized audio content.
sample_rate_hertz int
Optional. The synthesis sample rate (in hertz) for this audio. If not provided, then the synthesizer will use the default sample rate based on the audio encoding. If this is different from the voice's natural sample rate, then the synthesizer will honor this request by converting to the desired sample rate (which might result in worse audio quality).
synthesize_speech_configs Sequence[]
Optional. Configuration of how speech should be synthesized, mapping from language ( to SynthesizeSpeechConfig.



    mapping=None, *, ignore_unknown_fields=False, **kwargs

The abstract base class for a message.

kwargs dict

Keys and values corresponding to the fields of the message.

mapping Union[dict, .Message]

A dictionary or message to be used to determine the values for this message.

ignore_unknown_fields Optional(bool)

If True, do not raise errors for unknown fields. Only applied if mapping is a mapping type or there are keyword parameters.