类 TTSOptions.Builder
java.lang.Object
io.agentscope.core.model.tts.TTSOptions.Builder
- 封闭类:
TTSOptions
Builder for constructing TTSOptions instances.
-
构造器概要
构造器 -
方法概要
修饰符和类型方法说明build()Builds the TTSOptions instance.Sets the output audio format.Sets the language type.Sets the speech pitch.sampleRate(Integer sampleRate) Sets the audio sample rate.Sets the speech speed.Sets the voice for synthesis.Sets the audio volume.
-
构造器详细资料
-
Builder
public Builder()
-
-
方法详细资料
-
voice
Sets the voice for synthesis.- 参数:
voice- the voice name/ID- 返回:
- this builder
-
sampleRate
Sets the audio sample rate.- 参数:
sampleRate- sample rate in Hz- 返回:
- this builder
-
format
Sets the output audio format.- 参数:
format- audio format (e.g., "wav", "mp3")- 返回:
- this builder
-
speed
Sets the speech speed.- 参数:
speed- speed multiplier (0.5-2.0)- 返回:
- this builder
-
volume
Sets the audio volume.- 参数:
volume- volume level (0-100)- 返回:
- this builder
-
pitch
Sets the speech pitch.- 参数:
pitch- pitch multiplier (0.5-2.0)- 返回:
- this builder
-
language
Sets the language type.- 参数:
language- language code (e.g., "Chinese")- 返回:
- this builder
-
build
Builds the TTSOptions instance.- 返回:
- a new TTSOptions
-