Class GenerateGroundedContentResponse.Candidate.GroundingMetadata.GroundingSupport.Builder
java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderT>
com.google.protobuf.GeneratedMessage.Builder<GenerateGroundedContentResponse.Candidate.GroundingMetadata.GroundingSupport.Builder>
com.google.cloud.discoveryengine.v1beta.GenerateGroundedContentResponse.Candidate.GroundingMetadata.GroundingSupport.Builder
- All Implemented Interfaces:
GenerateGroundedContentResponse.Candidate.GroundingMetadata.GroundingSupportOrBuilder,com.google.protobuf.Message.Builder,com.google.protobuf.MessageLite.Builder,com.google.protobuf.MessageLiteOrBuilder,com.google.protobuf.MessageOrBuilder,Cloneable
public static final class GenerateGroundedContentResponse.Candidate.GroundingMetadata.GroundingSupport.Builder
extends com.google.protobuf.GeneratedMessage.Builder<GenerateGroundedContentResponse.Candidate.GroundingMetadata.GroundingSupport.Builder>
implements GenerateGroundedContentResponse.Candidate.GroundingMetadata.GroundingSupportOrBuilder
Grounding info for a claim in the candidate and its support.Protobuf type
google.cloud.discoveryengine.v1beta.GenerateGroundedContentResponse.Candidate.GroundingMetadata.GroundingSupport-
Method Summary
Modifier and TypeMethodDescriptionaddAllSupportChunkIndices(Iterable<? extends Integer> values) A list of indices (into 'support_chunks') specifying the citations associated with the claim.addSupportChunkIndices(int value) A list of indices (into 'support_chunks') specifying the citations associated with the claim.build()clear()Text for the claim in the candidate.A list of indices (into 'support_chunks') specifying the citations associated with the claim.A score in the range of [0, 1] describing how grounded is a specific claim in the support chunks indicated.Text for the claim in the candidate.com.google.protobuf.ByteStringText for the claim in the candidate.static final com.google.protobuf.Descriptors.Descriptorcom.google.protobuf.Descriptors.DescriptorintgetSupportChunkIndices(int index) A list of indices (into 'support_chunks') specifying the citations associated with the claim.intA list of indices (into 'support_chunks') specifying the citations associated with the claim.A list of indices (into 'support_chunks') specifying the citations associated with the claim.floatA score in the range of [0, 1] describing how grounded is a specific claim in the support chunks indicated.booleanA score in the range of [0, 1] describing how grounded is a specific claim in the support chunks indicated.protected com.google.protobuf.GeneratedMessage.FieldAccessorTablefinal booleanmergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) mergeFrom(com.google.protobuf.Message other) setClaimText(String value) Text for the claim in the candidate.setClaimTextBytes(com.google.protobuf.ByteString value) Text for the claim in the candidate.setSupportChunkIndices(int index, int value) A list of indices (into 'support_chunks') specifying the citations associated with the claim.setSupportScore(float value) A score in the range of [0, 1] describing how grounded is a specific claim in the support chunks indicated.Methods inherited from class com.google.protobuf.GeneratedMessage.Builder
addRepeatedField, clearField, clearOneof, clone, getAllFields, getField, getFieldBuilder, getOneofFieldDescriptor, getParentForChildren, getRepeatedField, getRepeatedFieldBuilder, getRepeatedFieldCount, getUnknownFields, getUnknownFieldSetBuilder, hasField, hasOneof, internalGetMapField, internalGetMapFieldReflection, internalGetMutableMapField, internalGetMutableMapFieldReflection, isClean, markClean, mergeUnknownFields, mergeUnknownLengthDelimitedField, mergeUnknownVarintField, newBuilderForField, onBuilt, onChanged, parseUnknownField, setField, setRepeatedField, setUnknownFields, setUnknownFieldSetBuilder, setUnknownFieldsProto3Methods inherited from class com.google.protobuf.AbstractMessage.Builder
findInitializationErrors, getInitializationErrorString, internalMergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageException, toStringMethods inherited from class com.google.protobuf.AbstractMessageLite.Builder
addAll, addAll, mergeDelimitedFrom, mergeDelimitedFrom, mergeFrom, newUninitializedMessageExceptionMethods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface com.google.protobuf.Message.Builder
mergeDelimitedFrom, mergeDelimitedFromMethods inherited from interface com.google.protobuf.MessageLite.Builder
mergeFromMethods inherited from interface com.google.protobuf.MessageOrBuilder
findInitializationErrors, getAllFields, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof
-
Method Details
-
getDescriptor
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() -
internalGetFieldAccessorTable
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()- Specified by:
internalGetFieldAccessorTablein classcom.google.protobuf.GeneratedMessage.Builder<GenerateGroundedContentResponse.Candidate.GroundingMetadata.GroundingSupport.Builder>
-
clear
- Specified by:
clearin interfacecom.google.protobuf.Message.Builder- Specified by:
clearin interfacecom.google.protobuf.MessageLite.Builder- Overrides:
clearin classcom.google.protobuf.GeneratedMessage.Builder<GenerateGroundedContentResponse.Candidate.GroundingMetadata.GroundingSupport.Builder>
-
getDescriptorForType
public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()- Specified by:
getDescriptorForTypein interfacecom.google.protobuf.Message.Builder- Specified by:
getDescriptorForTypein interfacecom.google.protobuf.MessageOrBuilder- Overrides:
getDescriptorForTypein classcom.google.protobuf.GeneratedMessage.Builder<GenerateGroundedContentResponse.Candidate.GroundingMetadata.GroundingSupport.Builder>
-
getDefaultInstanceForType
public GenerateGroundedContentResponse.Candidate.GroundingMetadata.GroundingSupport getDefaultInstanceForType()- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageLiteOrBuilder- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageOrBuilder
-
build
- Specified by:
buildin interfacecom.google.protobuf.Message.Builder- Specified by:
buildin interfacecom.google.protobuf.MessageLite.Builder
-
buildPartial
- Specified by:
buildPartialin interfacecom.google.protobuf.Message.Builder- Specified by:
buildPartialin interfacecom.google.protobuf.MessageLite.Builder
-
mergeFrom
public GenerateGroundedContentResponse.Candidate.GroundingMetadata.GroundingSupport.Builder mergeFrom(com.google.protobuf.Message other) - Specified by:
mergeFromin interfacecom.google.protobuf.Message.Builder- Overrides:
mergeFromin classcom.google.protobuf.AbstractMessage.Builder<GenerateGroundedContentResponse.Candidate.GroundingMetadata.GroundingSupport.Builder>
-
mergeFrom
-
isInitialized
public final boolean isInitialized()- Specified by:
isInitializedin interfacecom.google.protobuf.MessageLiteOrBuilder- Overrides:
isInitializedin classcom.google.protobuf.GeneratedMessage.Builder<GenerateGroundedContentResponse.Candidate.GroundingMetadata.GroundingSupport.Builder>
-
mergeFrom
public GenerateGroundedContentResponse.Candidate.GroundingMetadata.GroundingSupport.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Specified by:
mergeFromin interfacecom.google.protobuf.Message.Builder- Specified by:
mergeFromin interfacecom.google.protobuf.MessageLite.Builder- Overrides:
mergeFromin classcom.google.protobuf.AbstractMessage.Builder<GenerateGroundedContentResponse.Candidate.GroundingMetadata.GroundingSupport.Builder>- Throws:
IOException
-
getClaimText
Text for the claim in the candidate. Always provided when a support is found.
string claim_text = 1;- Specified by:
getClaimTextin interfaceGenerateGroundedContentResponse.Candidate.GroundingMetadata.GroundingSupportOrBuilder- Returns:
- The claimText.
-
getClaimTextBytes
public com.google.protobuf.ByteString getClaimTextBytes()Text for the claim in the candidate. Always provided when a support is found.
string claim_text = 1;- Specified by:
getClaimTextBytesin interfaceGenerateGroundedContentResponse.Candidate.GroundingMetadata.GroundingSupportOrBuilder- Returns:
- The bytes for claimText.
-
setClaimText
public GenerateGroundedContentResponse.Candidate.GroundingMetadata.GroundingSupport.Builder setClaimText(String value) Text for the claim in the candidate. Always provided when a support is found.
string claim_text = 1;- Parameters:
value- The claimText to set.- Returns:
- This builder for chaining.
-
clearClaimText
public GenerateGroundedContentResponse.Candidate.GroundingMetadata.GroundingSupport.Builder clearClaimText()Text for the claim in the candidate. Always provided when a support is found.
string claim_text = 1;- Returns:
- This builder for chaining.
-
setClaimTextBytes
public GenerateGroundedContentResponse.Candidate.GroundingMetadata.GroundingSupport.Builder setClaimTextBytes(com.google.protobuf.ByteString value) Text for the claim in the candidate. Always provided when a support is found.
string claim_text = 1;- Parameters:
value- The bytes for claimText to set.- Returns:
- This builder for chaining.
-
getSupportChunkIndicesList
A list of indices (into 'support_chunks') specifying the citations associated with the claim. For instance [1,3,4] means that support_chunks[1], support_chunks[3], support_chunks[4] are the chunks attributed to the claim.
repeated int32 support_chunk_indices = 3;- Specified by:
getSupportChunkIndicesListin interfaceGenerateGroundedContentResponse.Candidate.GroundingMetadata.GroundingSupportOrBuilder- Returns:
- A list containing the supportChunkIndices.
-
getSupportChunkIndicesCount
public int getSupportChunkIndicesCount()A list of indices (into 'support_chunks') specifying the citations associated with the claim. For instance [1,3,4] means that support_chunks[1], support_chunks[3], support_chunks[4] are the chunks attributed to the claim.
repeated int32 support_chunk_indices = 3;- Specified by:
getSupportChunkIndicesCountin interfaceGenerateGroundedContentResponse.Candidate.GroundingMetadata.GroundingSupportOrBuilder- Returns:
- The count of supportChunkIndices.
-
getSupportChunkIndices
public int getSupportChunkIndices(int index) A list of indices (into 'support_chunks') specifying the citations associated with the claim. For instance [1,3,4] means that support_chunks[1], support_chunks[3], support_chunks[4] are the chunks attributed to the claim.
repeated int32 support_chunk_indices = 3;- Specified by:
getSupportChunkIndicesin interfaceGenerateGroundedContentResponse.Candidate.GroundingMetadata.GroundingSupportOrBuilder- Parameters:
index- The index of the element to return.- Returns:
- The supportChunkIndices at the given index.
-
setSupportChunkIndices
public GenerateGroundedContentResponse.Candidate.GroundingMetadata.GroundingSupport.Builder setSupportChunkIndices(int index, int value) A list of indices (into 'support_chunks') specifying the citations associated with the claim. For instance [1,3,4] means that support_chunks[1], support_chunks[3], support_chunks[4] are the chunks attributed to the claim.
repeated int32 support_chunk_indices = 3;- Parameters:
index- The index to set the value at.value- The supportChunkIndices to set.- Returns:
- This builder for chaining.
-
addSupportChunkIndices
public GenerateGroundedContentResponse.Candidate.GroundingMetadata.GroundingSupport.Builder addSupportChunkIndices(int value) A list of indices (into 'support_chunks') specifying the citations associated with the claim. For instance [1,3,4] means that support_chunks[1], support_chunks[3], support_chunks[4] are the chunks attributed to the claim.
repeated int32 support_chunk_indices = 3;- Parameters:
value- The supportChunkIndices to add.- Returns:
- This builder for chaining.
-
addAllSupportChunkIndices
public GenerateGroundedContentResponse.Candidate.GroundingMetadata.GroundingSupport.Builder addAllSupportChunkIndices(Iterable<? extends Integer> values) A list of indices (into 'support_chunks') specifying the citations associated with the claim. For instance [1,3,4] means that support_chunks[1], support_chunks[3], support_chunks[4] are the chunks attributed to the claim.
repeated int32 support_chunk_indices = 3;- Parameters:
values- The supportChunkIndices to add.- Returns:
- This builder for chaining.
-
clearSupportChunkIndices
public GenerateGroundedContentResponse.Candidate.GroundingMetadata.GroundingSupport.Builder clearSupportChunkIndices()A list of indices (into 'support_chunks') specifying the citations associated with the claim. For instance [1,3,4] means that support_chunks[1], support_chunks[3], support_chunks[4] are the chunks attributed to the claim.
repeated int32 support_chunk_indices = 3;- Returns:
- This builder for chaining.
-
hasSupportScore
public boolean hasSupportScore()A score in the range of [0, 1] describing how grounded is a specific claim in the support chunks indicated. Higher value means that the claim is better supported by the chunks.
optional float support_score = 2;- Specified by:
hasSupportScorein interfaceGenerateGroundedContentResponse.Candidate.GroundingMetadata.GroundingSupportOrBuilder- Returns:
- Whether the supportScore field is set.
-
getSupportScore
public float getSupportScore()A score in the range of [0, 1] describing how grounded is a specific claim in the support chunks indicated. Higher value means that the claim is better supported by the chunks.
optional float support_score = 2;- Specified by:
getSupportScorein interfaceGenerateGroundedContentResponse.Candidate.GroundingMetadata.GroundingSupportOrBuilder- Returns:
- The supportScore.
-
setSupportScore
public GenerateGroundedContentResponse.Candidate.GroundingMetadata.GroundingSupport.Builder setSupportScore(float value) A score in the range of [0, 1] describing how grounded is a specific claim in the support chunks indicated. Higher value means that the claim is better supported by the chunks.
optional float support_score = 2;- Parameters:
value- The supportScore to set.- Returns:
- This builder for chaining.
-
clearSupportScore
public GenerateGroundedContentResponse.Candidate.GroundingMetadata.GroundingSupport.Builder clearSupportScore()A score in the range of [0, 1] describing how grounded is a specific claim in the support chunks indicated. Higher value means that the claim is better supported by the chunks.
optional float support_score = 2;- Returns:
- This builder for chaining.
-