Class SynthesisInput (2.23.0)

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

Contains text input to be synthesized. Either text or ssml must be supplied. Supplying both or neither returns google.rpc.Code.INVALID_ARGUMENT][google.rpc.Code.INVALID_ARGUMENT]. The input size is limited to 5000 bytes.

This message has oneof_ fields (mutually exclusive fields). For each oneof, at most one member field can be set at the same time. Setting any member of the oneof automatically clears all other members.

.. _oneof: https://proto-plus-python.readthedocs.io/en/stable/fields.html#oneofs-mutually-exclusive-fields

Attributes

Name Description
text str
The raw text to be synthesized. This field is a member of oneof_ input_source.
ssml str
The SSML document to be synthesized. The SSML document must be valid and well-formed. Otherwise the RPC will fail and return google.rpc.Code.INVALID_ARGUMENT][google.rpc.Code.INVALID_ARGUMENT]. For more information, see SSML __. This field is a member of oneof_ input_source.
multi_speaker_markup google.cloud.texttospeech_v1.types.MultiSpeakerMarkup
The multi-speaker input to be synthesized. Only applicable for multi-speaker synthesis. This field is a member of oneof_ input_source.
custom_pronunciations google.cloud.texttospeech_v1.types.CustomPronunciations
Optional. The pronunciation customizations to be applied to the input. If this is set, the input will be synthesized using the given pronunciation customizations. The initial support will be for EFIGS (English, French, Italian, German, Spanish) languages, as provided in VoiceSelectionParams. Journey and Instant Clone voices are not supported yet. In order to customize the pronunciation of a phrase, there must be an exact match of the phrase in the input types. If using SSML, the phrase must not be inside a phoneme tag (entirely or partially).