Class ContentEmbedding

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

public abstract class ContentEmbedding extends JsonSerializable
The embedding generated from an input content.
  • Constructor Details

    • ContentEmbedding

      public ContentEmbedding()
  • Method Details

    • values

      public abstract Optional<List<Float>> values()
      A list of floats representing an embedding.
    • statistics

      public abstract Optional<ContentEmbeddingStatistics> statistics()
      Vertex API only. Statistics of the input text associated with this embedding.
    • builder

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

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

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