Class: Google::Cloud::VectorSearch::V1::VectorSearch

Inherits:
Object
  • Object
show all
Extended by:
Protobuf::MessageExts::ClassMethods
Includes:
Protobuf::MessageExts
Defined in:
proto_docs/google/cloud/vectorsearch/v1/data_object_search_service.rb

Overview

Defines a search operation using a query vector.

Instance Attribute Summary collapse

Instance Attribute Details

#distance_metric::Google::Cloud::VectorSearch::V1::DistanceMetric

Returns Optional. The distance metric to use for the KNN search. If not specified, DOT_PRODUCT will be used as the default.

Returns:



129
130
131
132
# File 'proto_docs/google/cloud/vectorsearch/v1/data_object_search_service.rb', line 129

class VectorSearch
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods
end

#filter::Google::Protobuf::Struct

Returns Optional. A JSON filter expression, e.g. {"genre": \{"$eq": "sci-fi"}}, represented as a google.protobuf.Struct.

Returns:

  • (::Google::Protobuf::Struct)

    Optional. A JSON filter expression, e.g. {"genre": \{"$eq": "sci-fi"}}, represented as a google.protobuf.Struct.



129
130
131
132
# File 'proto_docs/google/cloud/vectorsearch/v1/data_object_search_service.rb', line 129

class VectorSearch
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods
end

#output_fields::Google::Cloud::VectorSearch::V1::OutputFields

Returns Optional. Mask specifying which fields to return.

Returns:



129
130
131
132
# File 'proto_docs/google/cloud/vectorsearch/v1/data_object_search_service.rb', line 129

class VectorSearch
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods
end

#search_field::String

Returns Required. The vector field to search.

Returns:

  • (::String)

    Required. The vector field to search.



129
130
131
132
# File 'proto_docs/google/cloud/vectorsearch/v1/data_object_search_service.rb', line 129

class VectorSearch
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods
end

#search_hint::Google::Cloud::VectorSearch::V1::SearchHint

Returns Optional. Sets the search hint. If no strategy is specified, the service will use an index if one is available, and fall back to the default KNN search otherwise.

Returns:



129
130
131
132
# File 'proto_docs/google/cloud/vectorsearch/v1/data_object_search_service.rb', line 129

class VectorSearch
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods
end

#sparse_vector::Google::Cloud::VectorSearch::V1::SparseVector

Returns A sparse vector for the query.

Note: The following fields are mutually exclusive: sparse_vector, vector. If a field in that set is populated, all other fields in the set will automatically be cleared.

Returns:

  • (::Google::Cloud::VectorSearch::V1::SparseVector)

    A sparse vector for the query.

    Note: The following fields are mutually exclusive: sparse_vector, vector. If a field in that set is populated, all other fields in the set will automatically be cleared.



129
130
131
132
# File 'proto_docs/google/cloud/vectorsearch/v1/data_object_search_service.rb', line 129

class VectorSearch
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods
end

#top_k::Integer

Returns Optional. The number of nearest neighbors to return.

Returns:

  • (::Integer)

    Optional. The number of nearest neighbors to return.



129
130
131
132
# File 'proto_docs/google/cloud/vectorsearch/v1/data_object_search_service.rb', line 129

class VectorSearch
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods
end

#vector::Google::Cloud::VectorSearch::V1::DenseVector

Returns A dense vector for the query.

Note: The following fields are mutually exclusive: vector, sparse_vector. If a field in that set is populated, all other fields in the set will automatically be cleared.

Returns:

  • (::Google::Cloud::VectorSearch::V1::DenseVector)

    A dense vector for the query.

    Note: The following fields are mutually exclusive: vector, sparse_vector. If a field in that set is populated, all other fields in the set will automatically be cleared.



129
130
131
132
# File 'proto_docs/google/cloud/vectorsearch/v1/data_object_search_service.rb', line 129

class VectorSearch
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods
end