Package com.google.genai.types
Class GroundingSupport
java.lang.Object
com.google.genai.JsonSerializable
com.google.genai.types.GroundingSupport
Grounding support.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic class
Builder for GroundingSupport. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic GroundingSupport.Builder
builder()
Instantiates a builder for GroundingSupport.Confidence score of the support references.static GroundingSupport
Deserializes a JSON string to a GroundingSupport object.A list of indices (into 'grounding_chunk') specifying the citations associated with the claim.segment()
Segment of the content this support belongs to.abstract GroundingSupport.Builder
Creates a builder with the same values as this instance.Methods inherited from class com.google.genai.JsonSerializable
stringToJsonNode, toJson
-
Constructor Details
-
GroundingSupport
public GroundingSupport()
-
-
Method Details
-
confidenceScores
Confidence score of the support references. Ranges from 0 to 1. 1 is the most confident. For Gemini 2.0 and before, this list must have the same size as the grounding_chunk_indices. For Gemini 2.5 and after, this list will be empty and should be ignored. -
groundingChunkIndices
A list of indices (into 'grounding_chunk') specifying the citations associated with the claim. For instance [1,3,4] means that grounding_chunk[1], grounding_chunk[3], grounding_chunk[4] are the retrieved content attributed to the claim. -
segment
Segment of the content this support belongs to. -
builder
Instantiates a builder for GroundingSupport. -
toBuilder
Creates a builder with the same values as this instance. -
fromJson
Deserializes a JSON string to a GroundingSupport object.
-