Versions in this module Expand all Collapse all v0 v0.12.0 Aug 2, 2026 v0.11.0 Jul 22, 2026 v0.10.0 Jul 21, 2026 v0.9.0 Jul 21, 2026 Changes in this version type IndexBuildReport + SkippedDuplicateKey int v0.8.0 Jul 18, 2026 v0.7.0 Jul 12, 2026retracted Changes in this version + const IndexManifestVersion + func AdaptiveThreshold(similarities []float32) float32 + func AverageSilhouetteScore64(points [][]float64, assignments []int) float64 + func AverageSimilarity(embeddings [][]float32) float32 + func BinaryWords(dim int) int + func Clamp01(x float64) float64 + func ClusterSilhouetteScores64(points [][]float64, assignments []int) map[int]float64 + func ComputeCentroid64(points [][]float64) []float64 + func ComputeClusterCentroids64(points [][]float64, assignments []int, k int) [][]float64 + func ComputeMedians(vecs [][]float32) []float32 + func ComputeMediansChecked(vecs [][]float32) ([]float32, error) + func Cosine32(a, b []float32) float32 + func Cosine64(a, b []float64) float64 + func CosineDistance32(a, b []float32) float32 + func CosineDistance64(a, b []float64) float64 + func CosineToUnit(score float64) float64 + func DecodeFloat32Batch(blobs [][]byte) ([][]float32, error) + func DecodeFloat32Vec(blob []byte) []float32 + func DecodeFloat64Vec(data []byte) []float64 + func Dot32(a, b []float32) float64 + func Dot64(a, b []float64) float64 + func DotFromBlob(query []float32, blob []byte) float32 + func EncodeFloat32Vec(v []float32) []byte + func EncodeFloat64Vec(v []float64) []byte + func Euclidean64(a, b []float64) float64 + func FindElbowCurvature(scores []float32, minKeep int) int + func FindOptimalK(points [][]float32, minK, maxK int, rng *rand.Rand) (int, float64) + func FindOptimalK64(points [][]float64, minK, maxK int) (bestK int, bestScore float64, assignments []int, centroids [][]float64, ...) + func FindSemanticBoundaries(similarities []float32, threshold float32) []int + func GaussianSmooth(scores []float32, sigma float64) []float32 + func Gradient(scores []float32) []float32 + func HammingDistance(a, b BinaryVector) int + func HashANNProfile(profile ANNProfile) hash.Digest + func HashFloat32Slice(values []float32) string + func HashIndexProfile(fields map[string]string) string + func HashIndexProfileIdentity(fields map[string]string) supporthash.Digest + func IsUnit32(v []float32, tolerance float64) bool + func IsUnit64(v []float64, tolerance float64) bool + func JaccardWords(text1, text2 string) float64 + func MeanPool32(vecs [][]float32) []float32 + func MeanStddev(vals []float64) (mean, stddev float64) + func MinMaxNormalize(vals []float64) []float64 + func NearDuplicateGroups(vecs [][]float32, cosineThreshold float32) [][]int + func NearDuplicatePairs(vecs [][]float32, cosineThreshold float32) [][2]int + func NewBinaryIndexChecked(blobs [][]byte, groups []string, chunkIndices []int, dims int) (*BinaryIndex, IndexBuildReport) + func NewExactIndexChecked(dims int, chunks []IndexChunk, arena []byte) (*ExactIndex, IndexBuildReport) + func NormSquared32(v []float32) float64 + func NormSquared64(v []float64) float64 + func Normalize32(v []float32) float32 + func Normalize64(v []float64) float64 + func NormalizeTo32(v []float32) []float32 + func NormalizeTo64(v []float64) []float64 + func QuantizeInto(dst BinaryVector, vec, thresholds []float32) error + func SilhouetteCoefficient64(pointIdx int, points [][]float64, assignments []int) float64 + func SilhouetteScore(points [][]float32, assignments []int, k int) float64 + func SlidingWindowSimilarity(embeddings [][]float32, windowSize int) []float32 + func SmoothSimilarities(similarities []float32, windowSize int) []float32 + func TopKMaxIndices(scores []float32, k int) []int + func TopKMinIndices(scores []float32, k int) []int + func WeightedMeanPool32(vecs [][]float32, weights []float64) ([]float32, error) + type ANNProfile struct + CandidateLimit int + ExactRescore bool + ID string + Kind IndexKind + MemoryEstimate MemoryEstimate + Oversampling float64 + ProfileDigest hash.Digest + Quantization string + TransformDigest hash.Digest + type ANNProfileResult struct + EvaluatedQuery int + IndexedRows int + Latency LatencySummary + Profile ANNProfile + RecallAtK float64 + type BinaryIndex struct + func NewBinaryIndex(blobs [][]byte, groups []string, chunkIndices []int, dims int) *BinaryIndex + func (idx *BinaryIndex) Clear() + func (idx *BinaryIndex) Len() int + func (idx *BinaryIndex) Manifest(identity IndexManifestIdentity) IndexManifest + func (idx *BinaryIndex) SearchCandidates(queryVec []float32) ([]HammingCandidate, bool) + func (idx *BinaryIndex) SearchCandidatesLimit(queryVec []float32, limit int) ([]HammingCandidate, bool) + type BinaryIndexEntry struct + ChunkIndex int + Group string + type BinaryVector []uint64 + func Quantize(vec []float32, thresholds []float32) (BinaryVector, error) + type ExactIndex struct + func NewExactIndex(dims int, chunks []IndexChunk, arena []byte) *ExactIndex + func (idx *ExactIndex) Clear() + func (idx *ExactIndex) Len() int + func (idx *ExactIndex) Manifest(identity IndexManifestIdentity) IndexManifest + func (idx *ExactIndex) Search(queryVec []float32, limit int, minSimilarity float64) ([]SearchResult, bool) + func (idx *ExactIndex) SearchFiltered(queryVec []float32, limit int, minSimilarity float64, groups []string) ([]SearchResult, bool) + func (idx *ExactIndex) SearchGroupsByMaxPool(queryVec []float32, limit int) ([]SearchResult, bool) + func (idx *ExactIndex) SearchKeys(queryVec []float32, limit int, minSimilarity float64, keys []IndexKey) ([]SearchResult, bool) + type HammingCandidate struct + ChunkIndex int + Group string + Hamming int + type IndexBuildReport struct + DimensionMismatch int + IndexedRows int + InputRows int + MedianError string + QuantizeError string + SkippedBadBlob int + SkippedBadSpan int + SkippedMissingMetadata int + type IndexChunk struct + ChunkIndex int + Group string + Length int + Offset int + type IndexKey struct + ChunkIndex int + Group string + type IndexKind string + const IndexKindBinary + const IndexKindExact + type IndexManifest struct + ChunkOverlap int + ChunkSize int + ChunkStrategy string + CreatedAt time.Time + Dims int + EmbeddingModelHash string + EmbeddingModelID string + IndexProfileHash string + IndexedRows int + Kind IndexKind + MediansHash string + Version int + func NewIndexManifest(identity IndexManifestIdentity, indexedRows int) IndexManifest + func (m IndexManifest) Validate(expected IndexManifestIdentity) error + type IndexManifestIdentity struct + ChunkOverlap int + ChunkSize int + ChunkStrategy string + Dims int + EmbeddingModelHash string + EmbeddingModelID string + IndexProfileHash string + Kind IndexKind + MediansHash string + type KMeans64Config struct + K int + MaxIterations int + Seed int64 + Tolerance float64 + type KMeans64Result struct + Assignments []int + Centroids [][]float64 + Converged bool + Iterations int + K int + func KMeans64(points [][]float64, cfg KMeans64Config) *KMeans64Result + type KMeansResult struct + Assignments []int + Centroids [][]float32 + Iterations int + K int + func KMeans(points [][]float32, k int, rng *rand.Rand) *KMeansResult + type LatencySummary struct + MaxMS float64 + MinMS float64 + P50MS float64 + P95MS float64 + Samples int + type MemoryEstimate struct + Bytes int64 + Label string + type Scored struct + Index int + Score float64 + func RRF(ranked [][]int, k float64) ([]Scored, float64) + type ScoredIndex struct + Index int + Score float32 + func TopKFromBlob(query []float32, blobs [][]byte, limit int, minScore float32) []ScoredIndex + type SearchResult struct + ChunkIndex int + Group string + Score float64