Table of Contents

Class AudioTranscriptionConfig

Namespace
GenerativeAI.Types
Assembly
GenerativeAI.dll

Configuration settings for audio transcription in multimodal live sessions.

public class AudioTranscriptionConfig
Inheritance
AudioTranscriptionConfig
Inherited Members
Extension Methods

Properties

AdaptationPhrases

Deprecated. A list of phrases used for speech adaptation, which biases the ASR model to improve recognition of these specific terms. Use CustomVocabulary instead.

[Obsolete("Use CustomVocabulary instead.")]
[JsonPropertyName("adaptationPhrases")]
public List<string>? AdaptationPhrases { get; set; }

Property Value

List<string>

CustomVocabulary

A list of custom vocabulary phrases, which biases the ASR model to improve recognition of these specific terms.

[JsonPropertyName("customVocabulary")]
public List<string>? CustomVocabulary { get; set; }

Property Value

List<string>

Diarization

Configures speaker diarization.

[JsonPropertyName("diarization")]
public bool? Diarization { get; set; }

Property Value

bool?

LanguageAuto

Deprecated: Auto-detection is now the default when LanguageCodes is omitted.

[Obsolete("Auto-detection is now the default when LanguageCodes is omitted.")]
[JsonPropertyName("languageAuto")]
public LanguageAuto? LanguageAuto { get; set; }

Property Value

LanguageAuto

LanguageCodes

Optional. BCP-47 language codes providing hints about the languages present in the audio. If omitted or empty, defaults to automatic language detection.

[JsonPropertyName("languageCodes")]
public List<string>? LanguageCodes { get; set; }

Property Value

List<string>

LanguageHints

Deprecated: Use LanguageCodes instead.

[Obsolete("Use LanguageCodes instead.")]
[JsonPropertyName("languageHints")]
public LanguageHints? LanguageHints { get; set; }

Property Value

LanguageHints

Mode

Optional. Configures transcription mode. If unspecified, defaults to VERBATIM. In SMART mode, the model performs disfluency removal, light grammatical cleanup, automatic formatting and minor user edits. Timestamps and diarization are incompatible with SMART mode.

[JsonPropertyName("mode")]
public AudioTranscriptionConfigMode? Mode { get; set; }

Property Value

AudioTranscriptionConfigMode?

SourceText

Optional. The source text to be edited or rewritten via voice instructions. When provided in SMART mode, the model evaluates the audio input against this text and emits the complete replacement text rather than appending to it.

[JsonPropertyName("sourceText")]
public string? SourceText { get; set; }

Property Value

string

WordTimestamp

Configures word-level timestamp generation.

[JsonPropertyName("wordTimestamp")]
public bool? WordTimestamp { get; set; }

Property Value

bool?