Versions in this module Expand all Collapse all v0 v0.1.15 Oct 30, 2024 v0.1.14 Oct 30, 2024 Changes in this version + var ErrEmbedderWrongNumberVectors = errors.New("number of vectors from embedder does not match number of documents") + var ErrEmptyResponse = errors.New("empty response") + var ErrInvalidFilter = errors.New("invalid filter") + var ErrInvalidOptions = errors.New("invalid options") + var ErrInvalidResponse = errors.New("invalid response") + var ErrInvalidScoreThreshold = errors.New("score threshold must be between 0 and 1") + var ErrMissingTextKey = errors.New("missing text key in vector metadata") + type Option func(p *Store) + func WithAPIKey(apiKey string) Option + func WithAdditionalFields(additionalFields []string) Option + func WithAuthConfig(authConfig auth.Config) Option + func WithConnectionClient(connectionClient *http.Client) Option + func WithEmbedder(e embeddings.Embedder) Option + func WithHost(host string) Option + func WithIndexName(indexName string) Option + func WithNameSpace(nameSpace string) Option + func WithNameSpaceKey(nameSpaceKey string) Option + func WithQueryAttrs(queryAttrs []string) Option + func WithScheme(scheme string) Option + func WithTextKey(textKey string) Option + type Store struct + func New(opts ...Option) (Store, error) + func (s Store) AddDocuments(ctx context.Context, docs []schema.Document, options ...vectorstores.Option) ([]string, error) + func (s Store) MetadataSearch(ctx context.Context, numDocuments int, options ...vectorstores.Option) ([]schema.Document, error) + func (s Store) SimilaritySearch(ctx context.Context, query string, numDocuments int, ...) ([]schema.Document, error)