Class EmbedContentParameters

java.lang.Object
com.google.genai.JsonSerializable
com.google.genai.types.EmbedContentParameters

@InternalApi public abstract class EmbedContentParameters extends JsonSerializable
Parameters for the embed_content method.
  • Constructor Details

    • EmbedContentParameters

      public EmbedContentParameters()
  • Method Details

    • model

      public abstract Optional<String> model()
      ID of the model to use. For a list of models, see `Google models <https://cloud.google.com/vertex-ai/generative-ai/docs/learn/models>`_.
    • contents

      public abstract Optional<List<Content>> contents()
      The content to embed. Only the `parts.text` fields will be counted.
    • config

      public abstract Optional<EmbedContentConfig> config()
      Configuration that contains optional parameters.
    • builder

      public static EmbedContentParameters.Builder builder()
      Instantiates a builder for EmbedContentParameters.
    • toBuilder

      public abstract EmbedContentParameters.Builder toBuilder()
      Creates a builder with the same values as this instance.
    • fromJson

      public static EmbedContentParameters fromJson(String jsonString)
      Deserializes a JSON string to a EmbedContentParameters object.