Documentation ¶
Index ¶
- func NewHammingSimilarity() interfaces.SimilarityMeasure
- func NewInMemoryStore() interfaces.Store
- func NewXXHASH64HashFamily(count int) interfaces.HashFamily
- type LSH
- func (s *LSH) Add(ctx context.Context, vectorID types.VectorID, vector types.Vector) error
- func (s *LSH) QueryByVector(ctx context.Context, vector types.Vector, count int) ([]types.VectorID, error)
- func (s *LSH) QueryByVectorID(ctx context.Context, vectorID types.VectorID, count int) ([]types.VectorID, error)
- type LSHConfig
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewHammingSimilarity ¶ added in v0.3.1
func NewHammingSimilarity() interfaces.SimilarityMeasure
func NewInMemoryStore ¶ added in v0.3.1
func NewInMemoryStore() interfaces.Store
func NewXXHASH64HashFamily ¶ added in v0.3.1
func NewXXHASH64HashFamily(count int) interfaces.HashFamily
Types ¶
type LSH ¶
type LSH struct {
// contains filtered or unexported fields
}
LSH represents the Locality Sensitive Hashing service.
func NewLSH ¶
func NewLSH( config LSHConfig, hashFamily interfaces.HashFamily, similarityMeasure interfaces.SimilarityMeasure, store interfaces.Store, ) (*LSH, error)
NewLSH creates a new instance of LSH.
Click to show internal directories.
Click to hide internal directories.