Class SearchRequest.EmbeddingSpec.Builder (0.31.0)

public static final class SearchRequest.EmbeddingSpec.Builder extends GeneratedMessageV3.Builder<SearchRequest.EmbeddingSpec.Builder> implements SearchRequest.EmbeddingSpecOrBuilder

The specification that uses customized query embedding vector to do semantic document retrieval.

Protobuf type google.cloud.discoveryengine.v1beta.SearchRequest.EmbeddingSpec

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
TypeDescription
Descriptor

Methods

addAllEmbeddingVectors(Iterable<? extends SearchRequest.EmbeddingSpec.EmbeddingVector> values)

public SearchRequest.EmbeddingSpec.Builder addAllEmbeddingVectors(Iterable<? extends SearchRequest.EmbeddingSpec.EmbeddingVector> values)

The embedding vector used for retrieval. Limit to 1.

repeated .google.cloud.discoveryengine.v1beta.SearchRequest.EmbeddingSpec.EmbeddingVector embedding_vectors = 1;

Parameter
NameDescription
valuesIterable<? extends com.google.cloud.discoveryengine.v1beta.SearchRequest.EmbeddingSpec.EmbeddingVector>
Returns
TypeDescription
SearchRequest.EmbeddingSpec.Builder

addEmbeddingVectors(SearchRequest.EmbeddingSpec.EmbeddingVector value)

public SearchRequest.EmbeddingSpec.Builder addEmbeddingVectors(SearchRequest.EmbeddingSpec.EmbeddingVector value)

The embedding vector used for retrieval. Limit to 1.

repeated .google.cloud.discoveryengine.v1beta.SearchRequest.EmbeddingSpec.EmbeddingVector embedding_vectors = 1;

Parameter
NameDescription
valueSearchRequest.EmbeddingSpec.EmbeddingVector
Returns
TypeDescription
SearchRequest.EmbeddingSpec.Builder

addEmbeddingVectors(SearchRequest.EmbeddingSpec.EmbeddingVector.Builder builderForValue)

public SearchRequest.EmbeddingSpec.Builder addEmbeddingVectors(SearchRequest.EmbeddingSpec.EmbeddingVector.Builder builderForValue)

The embedding vector used for retrieval. Limit to 1.

repeated .google.cloud.discoveryengine.v1beta.SearchRequest.EmbeddingSpec.EmbeddingVector embedding_vectors = 1;

Parameter
NameDescription
builderForValueSearchRequest.EmbeddingSpec.EmbeddingVector.Builder
Returns
TypeDescription
SearchRequest.EmbeddingSpec.Builder

addEmbeddingVectors(int index, SearchRequest.EmbeddingSpec.EmbeddingVector value)

public SearchRequest.EmbeddingSpec.Builder addEmbeddingVectors(int index, SearchRequest.EmbeddingSpec.EmbeddingVector value)

The embedding vector used for retrieval. Limit to 1.

repeated .google.cloud.discoveryengine.v1beta.SearchRequest.EmbeddingSpec.EmbeddingVector embedding_vectors = 1;

Parameters
NameDescription
indexint
valueSearchRequest.EmbeddingSpec.EmbeddingVector
Returns
TypeDescription
SearchRequest.EmbeddingSpec.Builder

addEmbeddingVectors(int index, SearchRequest.EmbeddingSpec.EmbeddingVector.Builder builderForValue)

public SearchRequest.EmbeddingSpec.Builder addEmbeddingVectors(int index, SearchRequest.EmbeddingSpec.EmbeddingVector.Builder builderForValue)

The embedding vector used for retrieval. Limit to 1.

repeated .google.cloud.discoveryengine.v1beta.SearchRequest.EmbeddingSpec.EmbeddingVector embedding_vectors = 1;

Parameters
NameDescription
indexint
builderForValueSearchRequest.EmbeddingSpec.EmbeddingVector.Builder
Returns
TypeDescription
SearchRequest.EmbeddingSpec.Builder

addEmbeddingVectorsBuilder()

public SearchRequest.EmbeddingSpec.EmbeddingVector.Builder addEmbeddingVectorsBuilder()

The embedding vector used for retrieval. Limit to 1.

repeated .google.cloud.discoveryengine.v1beta.SearchRequest.EmbeddingSpec.EmbeddingVector embedding_vectors = 1;

Returns
TypeDescription
SearchRequest.EmbeddingSpec.EmbeddingVector.Builder

addEmbeddingVectorsBuilder(int index)

public SearchRequest.EmbeddingSpec.EmbeddingVector.Builder addEmbeddingVectorsBuilder(int index)

The embedding vector used for retrieval. Limit to 1.

repeated .google.cloud.discoveryengine.v1beta.SearchRequest.EmbeddingSpec.EmbeddingVector embedding_vectors = 1;

Parameter
NameDescription
indexint
Returns
TypeDescription
SearchRequest.EmbeddingSpec.EmbeddingVector.Builder

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public SearchRequest.EmbeddingSpec.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
SearchRequest.EmbeddingSpec.Builder
Overrides

build()

public SearchRequest.EmbeddingSpec build()
Returns
TypeDescription
SearchRequest.EmbeddingSpec

buildPartial()

public SearchRequest.EmbeddingSpec buildPartial()
Returns
TypeDescription
SearchRequest.EmbeddingSpec

clear()

public SearchRequest.EmbeddingSpec.Builder clear()
Returns
TypeDescription
SearchRequest.EmbeddingSpec.Builder
Overrides

clearEmbeddingVectors()

public SearchRequest.EmbeddingSpec.Builder clearEmbeddingVectors()

The embedding vector used for retrieval. Limit to 1.

repeated .google.cloud.discoveryengine.v1beta.SearchRequest.EmbeddingSpec.EmbeddingVector embedding_vectors = 1;

Returns
TypeDescription
SearchRequest.EmbeddingSpec.Builder

clearField(Descriptors.FieldDescriptor field)

public SearchRequest.EmbeddingSpec.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
NameDescription
fieldFieldDescriptor
Returns
TypeDescription
SearchRequest.EmbeddingSpec.Builder
Overrides

clearOneof(Descriptors.OneofDescriptor oneof)

public SearchRequest.EmbeddingSpec.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
NameDescription
oneofOneofDescriptor
Returns
TypeDescription
SearchRequest.EmbeddingSpec.Builder
Overrides

clone()

public SearchRequest.EmbeddingSpec.Builder clone()
Returns
TypeDescription
SearchRequest.EmbeddingSpec.Builder
Overrides

getDefaultInstanceForType()

public SearchRequest.EmbeddingSpec getDefaultInstanceForType()
Returns
TypeDescription
SearchRequest.EmbeddingSpec

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

getEmbeddingVectors(int index)

public SearchRequest.EmbeddingSpec.EmbeddingVector getEmbeddingVectors(int index)

The embedding vector used for retrieval. Limit to 1.

repeated .google.cloud.discoveryengine.v1beta.SearchRequest.EmbeddingSpec.EmbeddingVector embedding_vectors = 1;

Parameter
NameDescription
indexint
Returns
TypeDescription
SearchRequest.EmbeddingSpec.EmbeddingVector

getEmbeddingVectorsBuilder(int index)

public SearchRequest.EmbeddingSpec.EmbeddingVector.Builder getEmbeddingVectorsBuilder(int index)

The embedding vector used for retrieval. Limit to 1.

repeated .google.cloud.discoveryengine.v1beta.SearchRequest.EmbeddingSpec.EmbeddingVector embedding_vectors = 1;

Parameter
NameDescription
indexint
Returns
TypeDescription
SearchRequest.EmbeddingSpec.EmbeddingVector.Builder

getEmbeddingVectorsBuilderList()

public List<SearchRequest.EmbeddingSpec.EmbeddingVector.Builder> getEmbeddingVectorsBuilderList()

The embedding vector used for retrieval. Limit to 1.

repeated .google.cloud.discoveryengine.v1beta.SearchRequest.EmbeddingSpec.EmbeddingVector embedding_vectors = 1;

Returns
TypeDescription
List<Builder>

getEmbeddingVectorsCount()

public int getEmbeddingVectorsCount()

The embedding vector used for retrieval. Limit to 1.

repeated .google.cloud.discoveryengine.v1beta.SearchRequest.EmbeddingSpec.EmbeddingVector embedding_vectors = 1;

Returns
TypeDescription
int

getEmbeddingVectorsList()

public List<SearchRequest.EmbeddingSpec.EmbeddingVector> getEmbeddingVectorsList()

The embedding vector used for retrieval. Limit to 1.

repeated .google.cloud.discoveryengine.v1beta.SearchRequest.EmbeddingSpec.EmbeddingVector embedding_vectors = 1;

Returns
TypeDescription
List<EmbeddingVector>

getEmbeddingVectorsOrBuilder(int index)

public SearchRequest.EmbeddingSpec.EmbeddingVectorOrBuilder getEmbeddingVectorsOrBuilder(int index)

The embedding vector used for retrieval. Limit to 1.

repeated .google.cloud.discoveryengine.v1beta.SearchRequest.EmbeddingSpec.EmbeddingVector embedding_vectors = 1;

Parameter
NameDescription
indexint
Returns
TypeDescription
SearchRequest.EmbeddingSpec.EmbeddingVectorOrBuilder

getEmbeddingVectorsOrBuilderList()

public List<? extends SearchRequest.EmbeddingSpec.EmbeddingVectorOrBuilder> getEmbeddingVectorsOrBuilderList()

The embedding vector used for retrieval. Limit to 1.

repeated .google.cloud.discoveryengine.v1beta.SearchRequest.EmbeddingSpec.EmbeddingVector embedding_vectors = 1;

Returns
TypeDescription
List<? extends com.google.cloud.discoveryengine.v1beta.SearchRequest.EmbeddingSpec.EmbeddingVectorOrBuilder>

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

mergeFrom(SearchRequest.EmbeddingSpec other)

public SearchRequest.EmbeddingSpec.Builder mergeFrom(SearchRequest.EmbeddingSpec other)
Parameter
NameDescription
otherSearchRequest.EmbeddingSpec
Returns
TypeDescription
SearchRequest.EmbeddingSpec.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public SearchRequest.EmbeddingSpec.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
SearchRequest.EmbeddingSpec.Builder
Overrides
Exceptions
TypeDescription
IOException

mergeFrom(Message other)

public SearchRequest.EmbeddingSpec.Builder mergeFrom(Message other)
Parameter
NameDescription
otherMessage
Returns
TypeDescription
SearchRequest.EmbeddingSpec.Builder
Overrides

mergeUnknownFields(UnknownFieldSet unknownFields)

public final SearchRequest.EmbeddingSpec.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
SearchRequest.EmbeddingSpec.Builder
Overrides

removeEmbeddingVectors(int index)

public SearchRequest.EmbeddingSpec.Builder removeEmbeddingVectors(int index)

The embedding vector used for retrieval. Limit to 1.

repeated .google.cloud.discoveryengine.v1beta.SearchRequest.EmbeddingSpec.EmbeddingVector embedding_vectors = 1;

Parameter
NameDescription
indexint
Returns
TypeDescription
SearchRequest.EmbeddingSpec.Builder

setEmbeddingVectors(int index, SearchRequest.EmbeddingSpec.EmbeddingVector value)

public SearchRequest.EmbeddingSpec.Builder setEmbeddingVectors(int index, SearchRequest.EmbeddingSpec.EmbeddingVector value)

The embedding vector used for retrieval. Limit to 1.

repeated .google.cloud.discoveryengine.v1beta.SearchRequest.EmbeddingSpec.EmbeddingVector embedding_vectors = 1;

Parameters
NameDescription
indexint
valueSearchRequest.EmbeddingSpec.EmbeddingVector
Returns
TypeDescription
SearchRequest.EmbeddingSpec.Builder

setEmbeddingVectors(int index, SearchRequest.EmbeddingSpec.EmbeddingVector.Builder builderForValue)

public SearchRequest.EmbeddingSpec.Builder setEmbeddingVectors(int index, SearchRequest.EmbeddingSpec.EmbeddingVector.Builder builderForValue)

The embedding vector used for retrieval. Limit to 1.

repeated .google.cloud.discoveryengine.v1beta.SearchRequest.EmbeddingSpec.EmbeddingVector embedding_vectors = 1;

Parameters
NameDescription
indexint
builderForValueSearchRequest.EmbeddingSpec.EmbeddingVector.Builder
Returns
TypeDescription
SearchRequest.EmbeddingSpec.Builder

setField(Descriptors.FieldDescriptor field, Object value)

public SearchRequest.EmbeddingSpec.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
SearchRequest.EmbeddingSpec.Builder
Overrides

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

public SearchRequest.EmbeddingSpec.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
NameDescription
fieldFieldDescriptor
indexint
valueObject
Returns
TypeDescription
SearchRequest.EmbeddingSpec.Builder
Overrides

setUnknownFields(UnknownFieldSet unknownFields)

public final SearchRequest.EmbeddingSpec.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
SearchRequest.EmbeddingSpec.Builder
Overrides