Skip to content

bodhi-realtime-agent / GeminiLiveTranscribeSTTProviderConfig

Interface: GeminiLiveTranscribeSTTProviderConfig ​

Defined in: src/transport/gemini-live-transcribe-stt-provider.ts:97

Transcribe Live with a credential fetched for each connection.

Extends ​

Properties ​

apiKey? ​

optional apiKey?: undefined

Defined in: src/transport/gemini-live-transcribe-stt-provider.ts:107


connectTimeoutMs? ​

optional connectTimeoutMs?: number

Defined in: src/transport/gemini-live-transcribe-stt-provider.ts:71

Longest wait for setupComplete before a connection counts as failed. With a credentialProvider it is one deadline over the credential fetch, the dial and setupComplete; the fetch may use at most half of it.

Inherited from ​

GeminiLiveTranscribeSTTOptions.connectTimeoutMs


createSocket? ​

optional createSocket?: (url) => WebSocketLike

Defined in: src/transport/gemini-live-transcribe-stt-provider.ts:76

Test seam.

Parameters ​

url ​

string

Returns ​

WebSocketLike

Inherited from ​

GeminiLiveTranscribeSTTOptions.createSocket


credentialProvider ​

credentialProvider: GeminiCredentialProvider

Defined in: src/transport/gemini-live-transcribe-stt-provider.ts:106

Called for every connection (start, rotation, reconnect, retry) with the setup it sends, { model, config: { responseModalities: ['TEXT'], inputAudioTranscription } } deep-frozen, so a token can be locked to it. signal aborts when its half of connectTimeoutMs runs out or the connection is closed meanwhile (stop(), a timeout); a credential that arrives after that is dropped unused. Rejecting with retryable: false ends the run without a retry (onFatal). The rest of the contract is GeminiCredentialProvider's.


customVocabulary? ​

optional customVocabulary?: string[]

Defined in: src/transport/gemini-live-transcribe-stt-provider.ts:60

Up to 1000 names/terms the model should spell correctly.

Inherited from ​

GeminiLiveTranscribeSTTOptions.customVocabulary


drainMs? ​

optional drainMs?: number

Defined in: src/transport/gemini-live-transcribe-stt-provider.ts:67

How long the old socket stays open after audioStreamEnd.

Inherited from ​

GeminiLiveTranscribeSTTOptions.drainMs


languageCodes? ​

optional languageCodes?: string[]

Defined in: src/transport/gemini-live-transcribe-stt-provider.ts:58

BCP-47 hints; empty = auto-detect (handles mixed Chinese/English).

Inherited from ​

GeminiLiveTranscribeSTTOptions.languageCodes


log? ​

optional log?: (msg) => void

Defined in: src/transport/gemini-live-transcribe-stt-provider.ts:77

Parameters ​

msg ​

string

Returns ​

void

Inherited from ​

GeminiLiveTranscribeSTTOptions.log


maxRetries? ​

optional maxRetries?: number

Defined in: src/transport/gemini-live-transcribe-stt-provider.ts:73

Retries for a connection that fails before it is ready; the delay grows per attempt.

Inherited from ​

GeminiLiveTranscribeSTTOptions.maxRetries


minCredentialLifetimeMs? ​

optional minCredentialLifetimeMs?: number

Defined in: src/transport/gemini-live-transcribe-stt-provider.ts:114

The least use, in ms, a credential must leave after the connect deadline: one that expires sooner is refused, failing that connection. Default 60000; as GeminiProviderTransportConfig.minCredentialLifetimeMs. A rotation starts connectTimeoutMs + pauseWaitMs + drainMs before expiry, so the minimum applied is never less than that plus 1000 ms: a shorter-lived credential would rotate as soon as it is set up.


mode? ​

optional mode?: "VERBATIM" | "SMART"

Defined in: src/transport/gemini-live-transcribe-stt-provider.ts:61

Inherited from ​

GeminiLiveTranscribeSTTOptions.mode


model? ​

optional model?: string

Defined in: src/transport/gemini-live-transcribe-stt-provider.ts:56

Inherited from ​

GeminiLiveTranscribeSTTOptions.model


onConnectionLifecycle? ​

optional onConnectionLifecycle?: (event) => void

Defined in: src/transport/gemini-live-transcribe-stt-provider.ts:80

Each connection's dial, setup and close, for a caller that tracks the credentials it issued. Also settable as a property.

Parameters ​

event ​

GeminiLiveTranscribeLifecycleEvent

Returns ​

void

Inherited from ​

GeminiLiveTranscribeSTTOptions.onConnectionLifecycle


onFatal? ​

optional onFatal?: (error) => void

Defined in: src/transport/gemini-live-transcribe-stt-provider.ts:87

The run ended on its own, after start() resolved: a lost connection could not be replaced within maxRetries, or the credential provider failed permanently (retryable: false). The provider has stopped (a later start() begins a new run) and no more transcripts come. Before start() resolves, a failure rejects start() instead. The error carries the last attempt's connectFailure. Also settable as a property.

Parameters ​

error ​

Error

Returns ​

void

Inherited from ​

GeminiLiveTranscribeSTTOptions.onFatal


pauseWaitMs? ​

optional pauseWaitMs?: number

Defined in: src/transport/gemini-live-transcribe-stt-provider.ts:65

Longest wait for a pause before handing over anyway.

Inherited from ​

GeminiLiveTranscribeSTTOptions.pauseWaitMs


retryDelayMs? ​

optional retryDelayMs?: number

Defined in: src/transport/gemini-live-transcribe-stt-provider.ts:74

Inherited from ​

GeminiLiveTranscribeSTTOptions.retryDelayMs


rotateAfterMs? ​

optional rotateAfterMs?: number

Defined in: src/transport/gemini-live-transcribe-stt-provider.ts:63

Rotate before the server's 10-minute cap.

Inherited from ​

GeminiLiveTranscribeSTTOptions.rotateAfterMs

Built with VitePress