Class RetrievalMetadata.Builder (3.55.0)

public static final class RetrievalMetadata.Builder extends GeneratedMessageV3.Builder<RetrievalMetadata.Builder> implements RetrievalMetadataOrBuilder

Metadata related to retrieval in the grounding flow.

Protobuf type google.cloud.aiplatform.v1.RetrievalMetadata

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
Type Description
Descriptor

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public RetrievalMetadata.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
RetrievalMetadata.Builder
Overrides

build()

public RetrievalMetadata build()
Returns
Type Description
RetrievalMetadata

buildPartial()

public RetrievalMetadata buildPartial()
Returns
Type Description
RetrievalMetadata

clear()

public RetrievalMetadata.Builder clear()
Returns
Type Description
RetrievalMetadata.Builder
Overrides

clearField(Descriptors.FieldDescriptor field)

public RetrievalMetadata.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
Name Description
field FieldDescriptor
Returns
Type Description
RetrievalMetadata.Builder
Overrides

clearGoogleSearchDynamicRetrievalScore()

public RetrievalMetadata.Builder clearGoogleSearchDynamicRetrievalScore()

Optional. Score indicating how likely information from Google Search could help answer the prompt. The score is in the range [0, 1], where 0 is the least likely and 1 is the most likely. This score is only populated when Google Search grounding and dynamic retrieval is enabled. It will be compared to the threshold to determine whether to trigger Google Search.

float google_search_dynamic_retrieval_score = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
RetrievalMetadata.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

public RetrievalMetadata.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
Name Description
oneof OneofDescriptor
Returns
Type Description
RetrievalMetadata.Builder
Overrides

clone()

public RetrievalMetadata.Builder clone()
Returns
Type Description
RetrievalMetadata.Builder
Overrides

getDefaultInstanceForType()

public RetrievalMetadata getDefaultInstanceForType()
Returns
Type Description
RetrievalMetadata

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
Type Description
Descriptor
Overrides

getGoogleSearchDynamicRetrievalScore()

public float getGoogleSearchDynamicRetrievalScore()

Optional. Score indicating how likely information from Google Search could help answer the prompt. The score is in the range [0, 1], where 0 is the least likely and 1 is the most likely. This score is only populated when Google Search grounding and dynamic retrieval is enabled. It will be compared to the threshold to determine whether to trigger Google Search.

float google_search_dynamic_retrieval_score = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
float

The googleSearchDynamicRetrievalScore.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Type Description
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(RetrievalMetadata other)

public RetrievalMetadata.Builder mergeFrom(RetrievalMetadata other)
Parameter
Name Description
other RetrievalMetadata
Returns
Type Description
RetrievalMetadata.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public RetrievalMetadata.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input CodedInputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
RetrievalMetadata.Builder
Overrides
Exceptions
Type Description
IOException

mergeFrom(Message other)

public RetrievalMetadata.Builder mergeFrom(Message other)
Parameter
Name Description
other Message
Returns
Type Description
RetrievalMetadata.Builder
Overrides

mergeUnknownFields(UnknownFieldSet unknownFields)

public final RetrievalMetadata.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
RetrievalMetadata.Builder
Overrides

setField(Descriptors.FieldDescriptor field, Object value)

public RetrievalMetadata.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
RetrievalMetadata.Builder
Overrides

setGoogleSearchDynamicRetrievalScore(float value)

public RetrievalMetadata.Builder setGoogleSearchDynamicRetrievalScore(float value)

Optional. Score indicating how likely information from Google Search could help answer the prompt. The score is in the range [0, 1], where 0 is the least likely and 1 is the most likely. This score is only populated when Google Search grounding and dynamic retrieval is enabled. It will be compared to the threshold to determine whether to trigger Google Search.

float google_search_dynamic_retrieval_score = 2 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value float

The googleSearchDynamicRetrievalScore to set.

Returns
Type Description
RetrievalMetadata.Builder

This builder for chaining.

setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)

public RetrievalMetadata.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
Name Description
field FieldDescriptor
index int
value Object
Returns
Type Description
RetrievalMetadata.Builder
Overrides

setUnknownFields(UnknownFieldSet unknownFields)

public final RetrievalMetadata.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
RetrievalMetadata.Builder
Overrides