Class LiveClientSetup.Builder

java.lang.Object
com.google.genai.types.LiveClientSetup.Builder
Enclosing class:
LiveClientSetup

public abstract static class LiveClientSetup.Builder extends Object
Builder for LiveClientSetup.
  • Constructor Details

    • Builder

      public Builder()
  • Method Details

    • model

      public abstract LiveClientSetup.Builder model(String model)
      Setter for model.

      model: The fully qualified name of the publisher model or tuned model endpoint to use.

    • generationConfig

      public abstract LiveClientSetup.Builder generationConfig(GenerationConfig generationConfig)
      Setter for generationConfig.

      generationConfig: The generation configuration for the session. Note: only a subset of fields are supported.

    • generationConfig

      public LiveClientSetup.Builder generationConfig(GenerationConfig.Builder generationConfigBuilder)
      Setter for generationConfig builder.

      generationConfig: The generation configuration for the session. Note: only a subset of fields are supported.

    • systemInstruction

      public abstract LiveClientSetup.Builder systemInstruction(Content systemInstruction)
      Setter for systemInstruction.

      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.

    • systemInstruction

      public LiveClientSetup.Builder systemInstruction(Content.Builder systemInstructionBuilder)
      Setter for systemInstruction builder.

      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

      public abstract LiveClientSetup.Builder tools(List<Tool> tools)
      Setter for tools.

      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.

    • tools

      public LiveClientSetup.Builder tools(Tool... tools)
      Setter for tools.

      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.

    • tools

      public LiveClientSetup.Builder tools(Tool.Builder... toolsBuilders)
      Setter for tools builder.

      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

      public abstract LiveClientSetup.Builder realtimeInputConfig(RealtimeInputConfig realtimeInputConfig)
      Setter for realtimeInputConfig.

      realtimeInputConfig: Configures the realtime input behavior in BidiGenerateContent.

    • realtimeInputConfig

      public LiveClientSetup.Builder realtimeInputConfig(RealtimeInputConfig.Builder realtimeInputConfigBuilder)
      Setter for realtimeInputConfig builder.

      realtimeInputConfig: Configures the realtime input behavior in BidiGenerateContent.

    • sessionResumption

      public abstract LiveClientSetup.Builder sessionResumption(SessionResumptionConfig sessionResumption)
      Setter for sessionResumption.

      sessionResumption: Configures session resumption mechanism.

      If included server will send SessionResumptionUpdate messages.

    • sessionResumption

      public LiveClientSetup.Builder sessionResumption(SessionResumptionConfig.Builder sessionResumptionBuilder)
      Setter for sessionResumption builder.

      sessionResumption: Configures session resumption mechanism.

      If included server will send SessionResumptionUpdate messages.

    • contextWindowCompression

      public abstract LiveClientSetup.Builder contextWindowCompression(ContextWindowCompressionConfig contextWindowCompression)
      Setter for contextWindowCompression.

      contextWindowCompression: Configures context window compression mechanism.

      If included, server will compress context window to fit into given length.

    • contextWindowCompression

      public LiveClientSetup.Builder contextWindowCompression(ContextWindowCompressionConfig.Builder contextWindowCompressionBuilder)
      Setter for contextWindowCompression builder.

      contextWindowCompression: Configures context window compression mechanism.

      If included, server will compress context window to fit into given length.

    • inputAudioTranscription

      public abstract LiveClientSetup.Builder inputAudioTranscription(AudioTranscriptionConfig inputAudioTranscription)
      Setter for inputAudioTranscription.

      inputAudioTranscription: The transcription of the input aligns with the input audio language.

    • inputAudioTranscription

      public LiveClientSetup.Builder inputAudioTranscription(AudioTranscriptionConfig.Builder inputAudioTranscriptionBuilder)
      Setter for inputAudioTranscription builder.

      inputAudioTranscription: The transcription of the input aligns with the input audio language.

    • outputAudioTranscription

      public abstract LiveClientSetup.Builder outputAudioTranscription(AudioTranscriptionConfig outputAudioTranscription)
      Setter for outputAudioTranscription.

      outputAudioTranscription: The transcription of the output aligns with the language code specified for the output audio.

    • outputAudioTranscription

      public LiveClientSetup.Builder outputAudioTranscription(AudioTranscriptionConfig.Builder outputAudioTranscriptionBuilder)
      Setter for outputAudioTranscription builder.

      outputAudioTranscription: The transcription of the output aligns with the language code specified for the output audio.

    • proactivity

      public abstract LiveClientSetup.Builder proactivity(ProactivityConfig proactivity)
      Setter for proactivity.

      proactivity: Configures the proactivity of the model. This allows the model to respond proactively to the input and to ignore irrelevant input.

    • proactivity

      public LiveClientSetup.Builder proactivity(ProactivityConfig.Builder proactivityBuilder)
      Setter for proactivity builder.

      proactivity: Configures the proactivity of the model. This allows the model to respond proactively to the input and to ignore irrelevant input.

    • build

      public abstract LiveClientSetup build()