Versions in this module Expand all Collapse all v2 v2.0.0 Mar 18, 2026 Changes in this version + const EnvPrefix + var ErrEmptyInputString = errors.New("empty input string") + var ErrShingleResultIsEmpty = errors.New("error shingle result is empty") + func CalculateJaccardOptimized(sourceSet set.GenericDataSet[string], targetStr string, shingleSize int) float64 + func EstimateJaccard(sig1, sig2 []uint64) float64 + func Shingle(input string, size int) set.GenericDataSet[string] + type Config struct + JaccardThreshold float64 + ShingleSize int + func GetConfigFromEnv() (*Config, error) + func (c *Config) CalculateApproximateThreshold() float64 + func (c *Config) HashVersion(group string) (string, error) + func (c *Config) Validate() error + type Hasher struct + func NewHasher(bands, rows int, seed int64) *Hasher + func (h *Hasher) ComputeSignature(tokens set.GenericDataSet[string], sig []uint64) + type Record struct + GroupID string + ID string + Input string + Signature []uint64 + type Service struct + func NewService(repo repositories.Storage, config *Config) (*Service, error) + func (s *Service) GetNewID(input string) string + func (s *Service) Upsert(ctx context.Context, group, input string) (string, error) + func (s *Service) WithMetrics(m *lsh.Instruments)