Skip to content
Tracon

GoogleSpeechOptions

Namespace Tracon · Assembly Tracon.Google.dll

Settings of GoogleSpeechBuilderExtensions.UseGoogleSpeech.

public sealed class GoogleSpeechOptions
Inheritance
object ← GoogleSpeechOptions
Inherited Members
object.GetType(), object.ToString(), object.Equals(object?), object.Equals(object?, object?), object.ReferenceEquals(object?, object?), object.GetHashCode()

GoogleSpeechOptions.Model is the only required setting. Tracon carries no Gemini model or voice list in code: a new model or voice needs no Tracon release.

public GoogleSpeechOptions()

Gets or sets how a dialogue names its speakers in the request. Default GoogleDialogueSpeakerMode.PartMetadata.

public GoogleDialogueSpeakerMode DialogueSpeakerMode { get; set; }

GoogleDialogueSpeakerMode

Measured against the live API (2026-10-25): the speaker format depends on the model generation, and a model refuses the other one with 400. Set the mode that matches GoogleSpeechOptions.Model.

Gets or sets the most characters one ISpeechSynthesizer.SynthesizeAsync call accepts. Default 5000.

public int MaxCharactersPerRequest { get; set; }

int

Tracon’s own guard, the same default as the built-in ElevenLabs client. It is not a Google limit: Gemini bounds the request by tokens, not characters.

Gets or sets the most characters one dialogue request carries, summed over its turns. Default 2000.

public int MaxDialogueCharactersPerRequest { get; set; }

int

Tracon’s own guard, like GoogleSpeechOptions.MaxCharactersPerRequest.

Gets or sets the Gemini text-to-speech model, for example gemini-3.8-flash-tts. Required.

public string? Model { get; set; }

string?

A request that names its own model (SpeechRequest.ModelId) uses that model. The model decides the audio container: some answer a WAV file, others raw 16-bit PCM. Tracon reads the answer’s MIME type and hands the caller the same wav or pcm whichever the model sent.

Gets or sets the registration name of the synthesizer. A caller selects it with "provider": "gemini" on POST /api/voice/speak. Default gemini.

public string Name { get; set; }

string

The name selects the registration. The tenant’s egress policy and provider bindings use the provider name google (GoogleProviderNames.Google), the name the chat provider has, so one rule covers chat, images and speech.

Gets or sets whether the registered synthesizer is also the unnamed default one. Default false.

public bool UseAsDefault { get; set; }

bool

The unnamed default serves the speak tool and the live conversation. It is registered with TryAdd: a default that is already there stays, so call UseGoogleSpeech before UseVoice to make Gemini the default.

The speak tool sends Tracon:Voice:SynthesisModelId and Tracon:Voice:OutputFormat to the default engine. Leave the model empty, or set it to a Gemini text-to-speech model, or Google refuses it. The format defaults to mp3_44100_128, which Gemini cannot produce: set it to wav, or the tool fails before any call.

Keep Gemini a named provider for the live conversation socket. A stream is raw PCM, and the shipped conversation panel decodes whole audio files.

Gets the voices GET /api/voice/voices lists for the synthesizer. Empty by default.

public IList<VoiceDescriptor> Voices { get; }

IList<VoiceDescriptor>

A static declaration: the Gemini API has no voice list. The name of a prebuilt voice, for example Kore, is the VoiceDescriptor.VoiceId a request names.