LMNT

Create voice

voices.create(**kwargs: VoiceCreateParams) -> Voice
POST
/v1/ai/voice

Submits a request to create a voice with a supplied voice configuration and a batch of input audio data.

Parameters

enhance
bool
required

For unclean audio with background noise, applies processing to attempt to improve quality. Default is false as this can also degrade quality in some circumstances.

files
List[FileTypes]
required

One or more input audio files to train the voice in the form of binary wav, mp3, mp4, m4a, or webm attachments.

name
str
required

The display name for this voice

description
Optional[str]

A text description of this voice.

gender
Optional[str]

A tag describing the gender of this voice. Has no effect on voice creation.

Returns

Voice where each Voice is:

description
Optional[str]

A text description of this voice.

gender
Optional[str]

A tag describing the gender of this voice, e.g. male, female, nonbinary.

id
str
required

The unique identifier of this voice.

name
str
required

The display name of this voice.

owner
Literal["system", "me", "other"]
required

The owner of this voice.

starred
Optional[bool]

Whether this voice has been starred by you or not.

state
str
required

The state of this voice in the training pipeline (e.g., ready, training).

type
Optional[Literal["instant", "professional"]]

The method by which this voice was created: instant or professional.

preview_url
Optional[str]

A URL that returns a preview speech sample of this voice. The file can be played directly in a browser or audio player.