audioarxiv.audio.base.validate_audio_arguments

audioarxiv.audio.base.validate_audio_arguments(rate: float, volume: float, voice: int | str | None, pause_seconds: float) dict[source]

Validate the arguments for Audio.

Parameters:
  • rate (float) – Number of words per minute.

  • volume (float) – Volume.

  • voice (int | str | None) – If it is int, it is interpreted as the index of the available voices. If it is str, it is interpreted as the ID of the voice. The available voice ids can be found with list_voices().

  • pause_seconds (float) – Duration of pause between sentences.

Returns:

rate, volume, voice, pause_seconds

Return type:

dict