Class SearchVectorsEnhancedRequest.Builder
-
Method Summary
Modifier and TypeMethodDescriptionaddAttributeToProject(String attributeToProject) Adds a single attribute name to be retrieved from the database.addNestedAttributesToProject(Collection<NestedAttributeName> nestedAttributeNames) addNestedAttributesToProject(NestedAttributeName... nestedAttributeNames) addNestedAttributeToProject(NestedAttributeName nestedAttributeName) attributesToProject(String... attributesToProject) Sets one or more attribute names to be retrieved from the database.attributesToProject(Collection<String> attributesToProject) Sets a collection of attribute names to be retrieved from the database.build()returnConsumedCapacity(String returnConsumedCapacity) returnConsumedCapacity(ReturnConsumedCapacity returnConsumedCapacity) searchConditionExpression(Expression searchConditionExpression) searchVector(float[] searchVector) Sets the query embedding as afloat[](canonical representation).searchVector(List<Float> searchVector) Sets the query embedding from a list ofFloatvalues.topK(int topK)
-
Method Details
-
searchVector
Sets the query embedding as afloat[](canonical representation). -
searchVector
Sets the query embedding from a list ofFloatvalues. -
topK
-
topK
-
searchConditionExpression
public SearchVectorsEnhancedRequest.Builder searchConditionExpression(Expression searchConditionExpression) -
attributesToProject
public SearchVectorsEnhancedRequest.Builder attributesToProject(Collection<String> attributesToProject) Sets a collection of attribute names to be retrieved from the database. These attributes can include scalars, sets, or elements of a JSON document.If no attribute names are specified, then all attributes will be returned. If any of the requested attributes are not found, they will not appear in the result.
If there are nested attributes, use any of the addNestedAttributesToProject methods, such as
addNestedAttributesToProject(NestedAttributeName...).- Parameters:
attributesToProject- A collection of the attributes names to be retrieved from the database.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
attributesToProject
Sets one or more attribute names to be retrieved from the database. These attributes can include scalars, sets, or elements of a JSON document.If no attribute names are specified, then all attributes will be returned. If any of the requested attributes are not found, they will not appear in the result.
If there are nested attributes, use any of the addNestedAttributesToProject methods, such as
addNestedAttributesToProject(NestedAttributeName...).- Parameters:
attributesToProject- One or more attributes names to be retrieved from the database.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
addAttributeToProject
Adds a single attribute name to be retrieved from the database. The attribute can include scalars, sets, or elements of a JSON document.If there are nested attributes, use any of the addNestedAttributesToProject methods, such as
addNestedAttributesToProject(NestedAttributeName...).- Parameters:
attributeToProject- An additional single attribute name to be retrieved from the database.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
addNestedAttributeToProject
public SearchVectorsEnhancedRequest.Builder addNestedAttributeToProject(NestedAttributeName nestedAttributeName) -
addNestedAttributesToProject
public SearchVectorsEnhancedRequest.Builder addNestedAttributesToProject(NestedAttributeName... nestedAttributeNames) -
addNestedAttributesToProject
public SearchVectorsEnhancedRequest.Builder addNestedAttributesToProject(Collection<NestedAttributeName> nestedAttributeNames) -
returnConsumedCapacity
public SearchVectorsEnhancedRequest.Builder returnConsumedCapacity(ReturnConsumedCapacity returnConsumedCapacity) -
returnConsumedCapacity
-
build
-