Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ValidateUserConfigUpdate ¶
func ValidateUserConfigUpdate(initial, updated schemaconfig.VectorIndexConfig) error
Types ¶
type Config ¶
type Config struct { ID string TargetVector string Logger logrus.FieldLogger RootPath string ShardName string ClassName string PrometheusMetrics *monitoring.PrometheusMetrics VectorForIDThunk common.VectorForID[float32] TempVectorForIDThunk common.TempVectorForID DistanceProvider distancer.Provider MakeCommitLoggerThunk hnsw.MakeCommitLogger TombstoneCallbacks cyclemanager.CycleCallbackGroup }
type DynamicStats ¶ added in v1.25.13
type DynamicStats struct{}
func (*DynamicStats) IndexType ¶ added in v1.25.13
func (s *DynamicStats) IndexType() common.IndexType
type VectorIndex ¶
type VectorIndex interface { Dump(labels ...string) Add(ctx context.Context, id uint64, vector []float32) error AddBatch(ctx context.Context, id []uint64, vector [][]float32) error Delete(id ...uint64) error SearchByVector(ctx context.Context, vector []float32, k int, allow helpers.AllowList) ([]uint64, []float32, error) SearchByVectorDistance(ctx context.Context, vector []float32, dist float32, maxLimit int64, allow helpers.AllowList) ([]uint64, []float32, error) UpdateUserConfig(updated schemaconfig.VectorIndexConfig, callback func()) error Drop(ctx context.Context) error Shutdown(ctx context.Context) error Flush() error SwitchCommitLogs(ctx context.Context) error ListFiles(ctx context.Context, basePath string) ([]string, error) PostStartup() Compressed() bool ValidateBeforeInsert(vector []float32) error DistanceBetweenVectors(x, y []float32) (float32, error) ContainsNode(id uint64) bool DistancerProvider() distancer.Provider AlreadyIndexed() uint64 QueryVectorDistancer(queryVector []float32) common.QueryVectorDistancer // Iterate over all nodes in the index. // Consistency is not guaranteed, as the // index may be concurrently modified. // If the callback returns false, the iteration will stop. Iterate(fn func(id uint64) bool) Stats() (common.IndexStats, error) }
Click to show internal directories.
Click to hide internal directories.