FishAudioProvider.FishSpeechModel
Namespace: Vercel.AI.FishAudio
public sealed class FishAudioProvider.FishSpeechModel : ISpeechModel, ISpeechCallerFish Audio speech model. Posts to /v1/tts and selects the model with a model header.
Inheritance: object
Implements: ISpeechModel, ISpeechCaller
Constructors
Section titled “Constructors”FishSpeechModel(FishAudioProvider, string, Func<DateTime>?)
Section titled “FishSpeechModel(FishAudioProvider, string, Func<DateTime>?)”public FishSpeechModel(FishAudioProvider provider, string modelId, Func<DateTime>? clock = null)Creates a speech model. <code class=“paramref”>clock</code> sets the response timestamp.
Parameters
| Name | Type | Description |
|---|---|---|
provider |
FishAudioProvider | |
modelId |
string | |
clock |
Func<DateTime> |
Properties
Section titled “Properties”ModelId
Section titled “ModelId”public string ModelId { get; }Model id.
Value: string
Provider
Section titled “Provider”public string Provider { get; }Provider id.
Value: string
SpecificationVersion
Section titled “SpecificationVersion”public string SpecificationVersion { get; }Specification version.
Value: string
Methods
Section titled “Methods”DoGenerateAsync(SpeechModelCall, CancellationToken)
Section titled “DoGenerateAsync(SpeechModelCall, CancellationToken)”public Task<SpeechModelResult> DoGenerateAsync(SpeechModelCall call, CancellationToken cancellationToken)Generates speech audio.
Parameters
| Name | Type | Description |
|---|---|---|
call |
SpeechModelCall | |
cancellationToken |
CancellationToken |
Returns: Task<SpeechModelResult>
DoGenerateAsync(SpeechCallOptions, CancellationToken)
Section titled “DoGenerateAsync(SpeechCallOptions, CancellationToken)”public Task<SpeechResult> DoGenerateAsync(SpeechCallOptions options, CancellationToken cancellationToken)Synthesizes speech.
Parameters
| Name | Type | Description |
|---|---|---|
options |
SpeechCallOptions | |
cancellationToken |
CancellationToken |
Returns: Task<SpeechResult>
Apache-2.0 · Copyright 2023 Vercel, Inc. · unofficial community port, not an official Vercel product