Class LiveClientSetup
-
- All Implemented Interfaces:
public abstract class LiveClientSetup extends JsonSerializable
Message contains configuration that will apply for the duration of the streaming session.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public abstract classLiveClientSetup.BuilderBuilder for LiveClientSetup.
-
Field Summary
Fields Modifier and Type Field Description public final static StringMAX_READ_LENGTH_PROPERTY
-
Constructor Summary
Constructors Constructor Description LiveClientSetup()
-
Method Summary
Modifier and Type Method Description abstract Optional<String>model()The fully qualified name of the publisher model or tuned model endpoint to use. abstract Optional<GenerationConfig>generationConfig()The generation configuration for the session. abstract Optional<Content>systemInstruction()The user provided system instructions for the model. abstract Optional<List<Tool>>tools()A list of `Tools` the model may use to generate the next response. abstract Optional<RealtimeInputConfig>realtimeInputConfig()Configures the realtime input behavior in BidiGenerateContent. abstract Optional<SessionResumptionConfig>sessionResumption()Configures session resumption mechanism. abstract Optional<ContextWindowCompressionConfig>contextWindowCompression()Configures context window compression mechanism. abstract Optional<AudioTranscriptionConfig>inputAudioTranscription()The transcription of the input aligns with the input audio language. abstract Optional<AudioTranscriptionConfig>outputAudioTranscription()The transcription of the output aligns with the language code specified for the output audio. abstract Optional<ProactivityConfig>proactivity()Configures the proactivity of the model. abstract Optional<Boolean>explicitVadSignal()Configures the explicit VAD signal. abstract Optional<AvatarConfig>avatarConfig()Configures the avatar model behavior. abstract Optional<List<SafetySetting>>safetySettings()Safety settings in the request to block unsafe content in the response. static LiveClientSetup.Builderbuilder()Instantiates a builder for LiveClientSetup. abstract LiveClientSetup.BuildertoBuilder()Creates a builder with the same values as this instance. static LiveClientSetupfromJson(String jsonString)Deserializes a JSON string to a LiveClientSetup object. -
Methods inherited from class com.google.genai.JsonSerializable
fromJsonNode, fromJsonString, objectMapper, setMaxReadLength, stringToJsonNode, toJson, toJsonNode, toJsonString -
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-
Method Detail
-
model
abstract Optional<String> model()
The fully qualified name of the publisher model or tuned model endpoint to use.
-
generationConfig
abstract Optional<GenerationConfig> generationConfig()
The generation configuration for the session. Note: only a subset of fields are supported.
-
systemInstruction
abstract Optional<Content> systemInstruction()
The user provided system instructions for the model. Note: only text should be used in parts and content in each part will be in a separate paragraph.
-
tools
abstract Optional<List<Tool>> tools()
A list of `Tools` the model may use to generate the next response.
A `Tool` is a piece of code that enables the system to interact with external systems to perform an action, or set of actions, outside of knowledge and scope of the model.
-
realtimeInputConfig
abstract Optional<RealtimeInputConfig> realtimeInputConfig()
Configures the realtime input behavior in BidiGenerateContent.
-
sessionResumption
abstract Optional<SessionResumptionConfig> sessionResumption()
Configures session resumption mechanism.
If included server will send SessionResumptionUpdate messages.
-
contextWindowCompression
abstract Optional<ContextWindowCompressionConfig> contextWindowCompression()
Configures context window compression mechanism.
If included, server will compress context window to fit into given length.
-
inputAudioTranscription
abstract Optional<AudioTranscriptionConfig> inputAudioTranscription()
The transcription of the input aligns with the input audio language.
-
outputAudioTranscription
abstract Optional<AudioTranscriptionConfig> outputAudioTranscription()
The transcription of the output aligns with the language code specified for the output audio.
-
proactivity
abstract Optional<ProactivityConfig> proactivity()
Configures the proactivity of the model. This allows the model to respond proactively to the input and to ignore irrelevant input.
-
explicitVadSignal
abstract Optional<Boolean> explicitVadSignal()
Configures the explicit VAD signal. If enabled, the client will send vad_signal to indicate the start and end of speech. This allows the server to process the audio more efficiently.
-
avatarConfig
abstract Optional<AvatarConfig> avatarConfig()
Configures the avatar model behavior.
-
safetySettings
abstract Optional<List<SafetySetting>> safetySettings()
Safety settings in the request to block unsafe content in the response.
-
builder
static LiveClientSetup.Builder builder()
Instantiates a builder for LiveClientSetup.
-
toBuilder
abstract LiveClientSetup.Builder toBuilder()
Creates a builder with the same values as this instance.
-
fromJson
static LiveClientSetup fromJson(String jsonString)
Deserializes a JSON string to a LiveClientSetup object.
-
-
-
-